Files
editor/assets/index-xcIkDGFp.js
2024-03-14 19:03:54 +00:00

821 lines
3.2 MiB
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
var L$=Object.defineProperty;var U$=(e,n,t)=>n in e?L$(e,n,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[n]=t;var an=(e,n,t)=>(U$(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 ch=typeof globalThis<"u"?globalThis:typeof window<"u"||typeof window<"u"?window:typeof self<"u"?self:{};function fa(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function EO(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 EF={exports:{}},kC={},OF={exports:{}},Oa={};/*
object-assign
(c) Sindre Sorhus
@license MIT
*/var Bk=Object.getOwnPropertySymbols,R$=Object.prototype.hasOwnProperty,z$=Object.prototype.propertyIsEnumerable;function j$(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function W$(){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 BF=W$()?Object.assign:function(e,n){for(var t,r=j$(e),i,o=1;o<arguments.length;o++){t=Object(arguments[o]);for(var s in t)R$.call(t,s)&&(r[s]=t[s]);if(Bk){i=Bk(t);for(var a=0;a<i.length;a++)z$.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 OO=BF,dh=typeof Symbol=="function"&&Symbol.for,IC=dh?Symbol.for("react.element"):60103,N$=dh?Symbol.for("react.portal"):60106,G$=dh?Symbol.for("react.fragment"):60107,Q$=dh?Symbol.for("react.strict_mode"):60108,$$=dh?Symbol.for("react.profiler"):60114,Y$=dh?Symbol.for("react.provider"):60109,q$=dh?Symbol.for("react.context"):60110,H$=dh?Symbol.for("react.forward_ref"):60112,V$=dh?Symbol.for("react.suspense"):60113,Z$=dh?Symbol.for("react.memo"):60115,X$=dh?Symbol.for("react.lazy"):60116,kk=typeof Symbol=="function"&&Symbol.iterator;function TC(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 kF={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},IF={};function Dy(e,n,t){this.props=e,this.context=n,this.refs=IF,this.updater=t||kF}Dy.prototype.isReactComponent={};Dy.prototype.setState=function(e,n){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error(TC(85));this.updater.enqueueSetState(this,e,n,"setState")};Dy.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function TF(){}TF.prototype=Dy.prototype;function BO(e,n,t){this.props=e,this.context=n,this.refs=IF,this.updater=t||kF}var kO=BO.prototype=new TF;kO.constructor=BO;OO(kO,Dy.prototype);kO.isPureReactComponent=!0;var IO={current:null},KF=Object.prototype.hasOwnProperty,PF={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)KF.call(n,r)&&!PF.hasOwnProperty(r)&&(i[r]=n[r]);var a=arguments.length-2;if(a===1)i.children=t;else if(1<a){for(var h=Array(a),g=0;g<a;g++)h[g]=arguments[g+2];i.children=h}if(e&&e.defaultProps)for(r in a=e.defaultProps,a)i[r]===void 0&&(i[r]=a[r]);return{$$typeof:IC,type:e,key:o,ref:s,props:i,_owner:IO.current}}function J$(e,n){return{$$typeof:IC,type:e.type,key:n,ref:e.ref,props:e.props,_owner:e._owner}}function TO(e){return typeof e=="object"&&e!==null&&e.$$typeof===IC}function eY(e){var n={"=":"=0",":":"=2"};return"$"+(""+e).replace(/[=:]/g,function(t){return n[t]})}var DF=/\/+/g,I2=[];function LF(e,n,t,r){if(I2.length){var i=I2.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 UF(e){e.result=null,e.keyPrefix=null,e.func=null,e.context=null,e.count=0,10>I2.length&&I2.push(e)}function BS(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 IC:case N$:o=!0}}if(o)return t(r,e,n===""?"."+Uw(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+Uw(i,s);o+=BS(i,a,t,r)}else if(e===null||typeof e!="object"?a=null:(a=kk&&e[kk]||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+Uw(i,s++),o+=BS(i,a,t,r);else if(i==="object")throw t=""+e,Error(TC(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t,""));return o}function kS(e,n,t){return e==null?0:BS(e,"",n,t)}function Uw(e,n){return typeof e=="object"&&e!==null&&e.key!=null?eY(e.key):n.toString(36)}function tY(e,n){e.func.call(e.context,n,e.count++)}function nY(e,n,t){var r=e.result,i=e.keyPrefix;e=e.func.call(e.context,n,e.count++),Array.isArray(e)?IS(e,r,t,function(o){return o}):e!=null&&(TO(e)&&(e=J$(e,i+(!e.key||n&&n.key===e.key?"":(""+e.key).replace(DF,"$&/")+"/")+t)),r.push(e))}function IS(e,n,t,r,i){var o="";t!=null&&(o=(""+t).replace(DF,"$&/")+"/"),n=LF(n,o,r,i),kS(e,nY,n),UF(n)}var RF={current:null};function Ep(){var e=RF.current;if(e===null)throw Error(TC(321));return e}var rY={ReactCurrentDispatcher:RF,ReactCurrentBatchConfig:{suspense:null},ReactCurrentOwner:IO,IsSomeRendererActing:{current:!1},assign:OO};Oa.Children={map:function(e,n,t){if(e==null)return e;var r=[];return IS(e,r,null,n,t),r},forEach:function(e,n,t){if(e==null)return e;n=LF(null,null,n,t),kS(e,tY,n),UF(n)},count:function(e){return kS(e,function(){return null},null)},toArray:function(e){var n=[];return IS(e,n,null,function(t){return t}),n},only:function(e){if(!TO(e))throw Error(TC(143));return e}};Oa.Component=Dy;Oa.Fragment=G$;Oa.Profiler=$$;Oa.PureComponent=BO;Oa.StrictMode=Q$;Oa.Suspense=V$;Oa.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=rY;Oa.cloneElement=function(e,n,t){if(e==null)throw Error(TC(267,e));var r=OO({},e.props),i=e.key,o=e.ref,s=e._owner;if(n!=null){if(n.ref!==void 0&&(o=n.ref,s=IO.current),n.key!==void 0&&(i=""+n.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(h in n)KF.call(n,h)&&!PF.hasOwnProperty(h)&&(r[h]=n[h]===void 0&&a!==void 0?a[h]:n[h])}var h=arguments.length-2;if(h===1)r.children=t;else if(1<h){a=Array(h);for(var g=0;g<h;g++)a[g]=arguments[g+2];r.children=a}return{$$typeof:IC,type:e.type,key:i,ref:o,props:r,_owner:s}};Oa.createContext=function(e,n){return n===void 0&&(n=null),e={$$typeof:q$,_calculateChangedBits:n,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider={$$typeof:Y$,_context:e},e.Consumer=e};Oa.createElement=FF;Oa.createFactory=function(e){var n=FF.bind(null,e);return n.type=e,n};Oa.createRef=function(){return{current:null}};Oa.forwardRef=function(e){return{$$typeof:H$,render:e}};Oa.isValidElement=TO;Oa.lazy=function(e){return{$$typeof:X$,_ctor:e,_status:-1,_result:null}};Oa.memo=function(e,n){return{$$typeof:Z$,type:e,compare:n===void 0?null:n}};Oa.useCallback=function(e,n){return Ep().useCallback(e,n)};Oa.useContext=function(e,n){return Ep().useContext(e,n)};Oa.useDebugValue=function(){};Oa.useEffect=function(e,n){return Ep().useEffect(e,n)};Oa.useImperativeHandle=function(e,n,t){return Ep().useImperativeHandle(e,n,t)};Oa.useLayoutEffect=function(e,n){return Ep().useLayoutEffect(e,n)};Oa.useMemo=function(e,n){return Ep().useMemo(e,n)};Oa.useReducer=function(e,n,t){return Ep().useReducer(e,n,t)};Oa.useRef=function(e){return Ep().useRef(e)};Oa.useState=function(e){return Ep().useState(e)};Oa.version="16.14.0";OF.exports=Oa;var Br=OF.exports;const Sn=fa(Br);/** @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 iY=Br,zF=60103;kC.Fragment=60107;if(typeof Symbol=="function"&&Symbol.for){var Ik=Symbol.for;zF=Ik("react.element"),kC.Fragment=Ik("react.fragment")}var oY=iY.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,aY=Object.prototype.hasOwnProperty,sY={key:!0,ref:!0,__self:!0,__source:!0};function jF(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)aY.call(n,r)&&!sY.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:zF,type:e,key:o,ref:s,props:i,_owner:oY.current}}kC.jsx=jF;kC.jsxs=jF;EF.exports=kC;var G=EF.exports,WF={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},TS=Sn.createContext&&Sn.createContext(WF),wm=function(){return wm=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},wm.apply(this,arguments)},lY=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 NF(e){return e&&e.map(function(n,t){return Sn.createElement(n.tag,wm({key:t},n.attr),NF(n.child))})}function sl(e){return function(n){return Sn.createElement(uY,wm({attr:wm({},e.attr)},n),NF(e.child))}}function uY(e){var n=function(t){var r=e.attr,i=e.size,o=e.title,s=lY(e,["attr","size","title"]),a=i||t.size||"1em",h;return t.className&&(h=t.className),e.className&&(h=(h?h+" ":"")+e.className),Sn.createElement("svg",wm({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},t.attr,r,s,{className:h,style:wm(wm({color:e.color||t.color},t.style),e.style),height:a,width:a,xmlns:"http://www.w3.org/2000/svg"}),o&&Sn.createElement("title",null,o),e.children)};return TS!==void 0?Sn.createElement(TS.Consumer,null,function(t){return n(t)}):n(WF)}var GF={exports:{}},Md={},QF={exports:{}},$F={};/** @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,h=function(){if(s!==null)try{var gt=e.unstable_now();s(!0,gt),s=null}catch(at){throw setTimeout(h,0),at}},g=Date.now();e.unstable_now=function(){return Date.now()-g},n=function(gt){s!==null?setTimeout(n,0,gt):(s=gt,setTimeout(h,0))},t=function(gt,at){a=setTimeout(gt,at)},r=function(){clearTimeout(a)},i=function(){return!1},o=e.unstable_forceFrameRate=function(){}}else{var C=window.performance,B=window.Date,k=window.setTimeout,P=window.clearTimeout;if(typeof console<"u"){var L=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 L!="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 C=="object"&&typeof C.now=="function")e.unstable_now=function(){return C.now()};else{var J=B.now();e.unstable_now=function(){return B.now()-J}}var N=!1,$=null,q=-1,oe=5,ce=0;i=function(){return e.unstable_now()>=ce},o=function(){},e.unstable_forceFrameRate=function(gt){0>gt||125<gt?console.error("forceFrameRate takes a positive int between 0 and 125, forcing framerates higher than 125 fps is not unsupported"):oe=0<gt?Math.floor(1e3/gt):5};var me=new MessageChannel,he=me.port2;me.port1.onmessage=function(){if($!==null){var gt=e.unstable_now();ce=gt+oe;try{$(!0,gt)?he.postMessage(null):(N=!1,$=null)}catch(at){throw he.postMessage(null),at}}else N=!1},n=function(gt){$=gt,N||(N=!0,he.postMessage(null))},t=function(gt,at){q=k(function(){gt(e.unstable_now())},at)},r=function(){P(q),q=-1}}function V(gt,at){var It=gt.length;gt.push(at);e:for(;;){var Lt=It-1>>>1,Me=gt[Lt];if(Me!==void 0&&0<Oe(Me,at))gt[Lt]=at,gt[It]=Me,It=Lt;else break e}}function ae(gt){return gt=gt[0],gt===void 0?null:gt}function ye(gt){var at=gt[0];if(at!==void 0){var It=gt.pop();if(It!==at){gt[0]=It;e:for(var Lt=0,Me=gt.length;Lt<Me;){var fe=2*(Lt+1)-1,xe=gt[fe],Ue=fe+1,et=gt[Ue];if(xe!==void 0&&0>Oe(xe,It))et!==void 0&&0>Oe(et,xe)?(gt[Lt]=et,gt[Ue]=It,Lt=Ue):(gt[Lt]=xe,gt[fe]=It,Lt=fe);else if(et!==void 0&&0>Oe(et,It))gt[Lt]=et,gt[Ue]=It,Lt=Ue;else break e}}return at}return null}function Oe(gt,at){var It=gt.sortIndex-at.sortIndex;return It!==0?It:gt.id-at.id}var De=[],He=[],ke=1,nt=null,be=3,Bt=!1,kt=!1,Yt=!1;function jt(gt){for(var at=ae(He);at!==null;){if(at.callback===null)ye(He);else if(at.startTime<=gt)ye(He),at.sortIndex=at.expirationTime,V(De,at);else break;at=ae(He)}}function Xe(gt){if(Yt=!1,jt(gt),!kt)if(ae(De)!==null)kt=!0,n(rt);else{var at=ae(He);at!==null&&t(Xe,at.startTime-gt)}}function rt(gt,at){kt=!1,Yt&&(Yt=!1,r()),Bt=!0;var It=be;try{for(jt(at),nt=ae(De);nt!==null&&(!(nt.expirationTime>at)||gt&&!i());){var Lt=nt.callback;if(Lt!==null){nt.callback=null,be=nt.priorityLevel;var Me=Lt(nt.expirationTime<=at);at=e.unstable_now(),typeof Me=="function"?nt.callback=Me:nt===ae(De)&&ye(De),jt(at)}else ye(De);nt=ae(De)}if(nt!==null)var fe=!0;else{var xe=ae(He);xe!==null&&t(Xe,xe.startTime-at),fe=!1}return fe}finally{nt=null,be=It,Bt=!1}}function ot(gt){switch(gt){case 1:return-1;case 2:return 250;case 5:return 1073741823;case 4:return 1e4;default:return 5e3}}var on=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(gt){gt.callback=null},e.unstable_continueExecution=function(){kt||Bt||(kt=!0,n(rt))},e.unstable_getCurrentPriorityLevel=function(){return be},e.unstable_getFirstCallbackNode=function(){return ae(De)},e.unstable_next=function(gt){switch(be){case 1:case 2:case 3:var at=3;break;default:at=be}var It=be;be=at;try{return gt()}finally{be=It}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=on,e.unstable_runWithPriority=function(gt,at){switch(gt){case 1:case 2:case 3:case 4:case 5:break;default:gt=3}var It=be;be=gt;try{return at()}finally{be=It}},e.unstable_scheduleCallback=function(gt,at,It){var Lt=e.unstable_now();if(typeof It=="object"&&It!==null){var Me=It.delay;Me=typeof Me=="number"&&0<Me?Lt+Me:Lt,It=typeof It.timeout=="number"?It.timeout:ot(gt)}else It=ot(gt),Me=Lt;return It=Me+It,gt={id:ke++,callback:at,priorityLevel:gt,startTime:Me,expirationTime:It,sortIndex:-1},Me>Lt?(gt.sortIndex=Me,V(He,gt),ae(De)===null&&gt===ae(He)&&(Yt?r():Yt=!0,t(Xe,Me-Lt))):(gt.sortIndex=It,V(De,gt),kt||Bt||(kt=!0,n(rt))),gt},e.unstable_shouldYield=function(){var gt=e.unstable_now();jt(gt);var at=ae(De);return at!==nt&&nt!==null&&at!==null&&at.callback!==null&&at.startTime<=gt&&at.expirationTime<nt.expirationTime||i()},e.unstable_wrapCallback=function(gt){var at=be;return function(){var It=be;be=at;try{return gt.apply(this,arguments)}finally{be=It}}}})($F);QF.exports=$F;var AY=QF.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 T4=Br,BA=BF,Ku=AY;function Gn(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(!T4)throw Error(Gn(227));function cY(e,n,t,r,i,o,s,a,h){var g=Array.prototype.slice.call(arguments,3);try{n.apply(t,g)}catch(C){this.onError(C)}}var y_=!1,T2=null,K2=!1,KS=null,dY={onError:function(e){y_=!0,T2=e}};function hY(e,n,t,r,i,o,s,a,h){y_=!1,T2=null,cY.apply(dY,arguments)}function fY(e,n,t,r,i,o,s,a,h){if(hY.apply(this,arguments),y_){if(y_){var g=T2;y_=!1,T2=null}else throw Error(Gn(198));K2||(K2=!0,KS=g)}}var KO=null,YF=null,qF=null;function Tk(e,n,t){var r=e.type||"unknown-event";e.currentTarget=qF(t),fY(r,n,void 0,e),e.currentTarget=null}var P2=null,Ig={};function HF(){if(P2)for(var e in Ig){var n=Ig[e],t=P2.indexOf(e);if(!(-1<t))throw Error(Gn(96,e));if(!F2[t]){if(!n.extractEvents)throw Error(Gn(97,e));F2[t]=n,t=n.eventTypes;for(var r in t){var i=void 0,o=t[r],s=n,a=r;if(PS.hasOwnProperty(a))throw Error(Gn(99,a));PS[a]=o;var h=o.phasedRegistrationNames;if(h){for(i in h)h.hasOwnProperty(i)&&Kk(h[i],s,a);i=!0}else o.registrationName?(Kk(o.registrationName,s,a),i=!0):i=!1;if(!i)throw Error(Gn(98,r,e))}}}}function Kk(e,n,t){if(vy[e])throw Error(Gn(100,e));vy[e]=n,PO[e]=n.eventTypes[t].dependencies}var F2=[],PS={},vy={},PO={};function VF(e){var n=!1,t;for(t in e)if(e.hasOwnProperty(t)){var r=e[t];if(!Ig.hasOwnProperty(t)||Ig[t]!==r){if(Ig[t])throw Error(Gn(102,t));Ig[t]=r,n=!0}}n&&HF()}var Gm=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),FS=null,qg=null,Hg=null;function Pk(e){if(e=YF(e)){if(typeof FS!="function")throw Error(Gn(280));var n=e.stateNode;n&&(n=KO(n),FS(e.stateNode,e.type,n))}}function ZF(e){qg?Hg?Hg.push(e):Hg=[e]:qg=e}function XF(){if(qg){var e=qg,n=Hg;if(Hg=qg=null,Pk(e),n)for(e=0;e<n.length;e++)Pk(n[e])}}function FO(e,n){return e(n)}function JF(e,n,t,r,i){return e(n,t,r,i)}function DO(){}var eD=FO,F0=!1,Rw=!1;function LO(){(qg!==null||Hg!==null)&&(DO(),XF())}function tD(e,n,t){if(Rw)return e(n,t);Rw=!0;try{return eD(e,n,t)}finally{Rw=!1,LO()}}var pY=/^[: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]*$/,Fk=Object.prototype.hasOwnProperty,Dk={},Lk={};function mY(e){return Fk.call(Lk,e)?!0:Fk.call(Dk,e)?!1:pY.test(e)?Lk[e]=!0:(Dk[e]=!0,!1)}function gY(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 yY(e,n,t,r){if(n===null||typeof n>"u"||gY(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 kA(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 Pu={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Pu[e]=new kA(e,0,!1,e,null,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var n=e[0];Pu[n]=new kA(n,1,!1,e[1],null,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Pu[e]=new kA(e,2,!1,e.toLowerCase(),null,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Pu[e]=new kA(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){Pu[e]=new kA(e,3,!1,e.toLowerCase(),null,!1)});["checked","multiple","muted","selected"].forEach(function(e){Pu[e]=new kA(e,3,!0,e,null,!1)});["capture","download"].forEach(function(e){Pu[e]=new kA(e,4,!1,e,null,!1)});["cols","rows","size","span"].forEach(function(e){Pu[e]=new kA(e,6,!1,e,null,!1)});["rowSpan","start"].forEach(function(e){Pu[e]=new kA(e,5,!1,e.toLowerCase(),null,!1)});var UO=/[\-:]([a-z])/g;function RO(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(UO,RO);Pu[n]=new kA(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(UO,RO);Pu[n]=new kA(n,1,!1,e,"http://www.w3.org/1999/xlink",!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var n=e.replace(UO,RO);Pu[n]=new kA(n,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1)});["tabIndex","crossOrigin"].forEach(function(e){Pu[e]=new kA(e,1,!1,e.toLowerCase(),null,!1)});Pu.xlinkHref=new kA("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0);["src","href","action","formAction"].forEach(function(e){Pu[e]=new kA(e,1,!1,e.toLowerCase(),null,!0)});var uh=T4.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;uh.hasOwnProperty("ReactCurrentDispatcher")||(uh.ReactCurrentDispatcher={current:null});uh.hasOwnProperty("ReactCurrentBatchConfig")||(uh.ReactCurrentBatchConfig={suspense:null});function zO(e,n,t,r){var i=Pu.hasOwnProperty(n)?Pu[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||(yY(n,t,i,r)&&(t=null),r||i===null?mY(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 vY=/^(.*)[\\\/]/,ac=typeof Symbol=="function"&&Symbol.for,ax=ac?Symbol.for("react.element"):60103,Tg=ac?Symbol.for("react.portal"):60106,B0=ac?Symbol.for("react.fragment"):60107,nD=ac?Symbol.for("react.strict_mode"):60108,n2=ac?Symbol.for("react.profiler"):60114,rD=ac?Symbol.for("react.provider"):60109,iD=ac?Symbol.for("react.context"):60110,_Y=ac?Symbol.for("react.concurrent_mode"):60111,jO=ac?Symbol.for("react.forward_ref"):60112,r2=ac?Symbol.for("react.suspense"):60113,DS=ac?Symbol.for("react.suspense_list"):60120,WO=ac?Symbol.for("react.memo"):60115,oD=ac?Symbol.for("react.lazy"):60116,aD=ac?Symbol.for("react.block"):60121,Uk=typeof Symbol=="function"&&Symbol.iterator;function Iv(e){return e===null||typeof e!="object"?null:(e=Uk&&e[Uk]||e["@@iterator"],typeof e=="function"?e:null)}function CY(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 Cp(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 B0:return"Fragment";case Tg:return"Portal";case n2:return"Profiler";case nD:return"StrictMode";case r2:return"Suspense";case DS:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case iD:return"Context.Consumer";case rD:return"Context.Provider";case jO:var n=e.render;return n=n.displayName||n.name||"",e.displayName||(n!==""?"ForwardRef("+n+")":"ForwardRef");case WO:return Cp(e.type);case aD:return Cp(e.render);case oD:if(e=e._status===1?e._result:null)return Cp(e)}return null}function NO(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=Cp(e.type);t=null,r&&(t=Cp(r.type)),r=o,o="",i?o=" (at "+i.fileName.replace(vY,"")+":"+i.lineNumber+")":t&&(o=" (created by "+t+")"),t=`
in `+(r||"Unknown")+o}n+=t,e=e.return}while(e);return n}function Um(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function sD(e){var n=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function bY(e){var n=sD(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 sx(e){e._valueTracker||(e._valueTracker=bY(e))}function lD(e){if(!e)return!1;var n=e._valueTracker;if(!n)return!0;var t=n.getValue(),r="";return e&&(r=sD(e)?e.checked?"true":"false":e.value),e=r,e!==t?(n.setValue(e),!0):!1}function LS(e,n){var t=n.checked;return BA({},n,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:t??e._wrapperState.initialChecked})}function Rk(e,n){var t=n.defaultValue==null?"":n.defaultValue,r=n.checked!=null?n.checked:n.defaultChecked;t=Um(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 uD(e,n){n=n.checked,n!=null&&zO(e,"checked",n,!1)}function US(e,n){uD(e,n);var t=Um(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")?RS(e,n.type,t):n.hasOwnProperty("defaultValue")&&RS(e,n.type,Um(n.defaultValue)),n.checked==null&&n.defaultChecked!=null&&(e.defaultChecked=!!n.defaultChecked)}function zk(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 RS(e,n,t){(n!=="number"||e.ownerDocument.activeElement!==e)&&(t==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+t&&(e.defaultValue=""+t))}function xY(e){var n="";return T4.Children.forEach(e,function(t){t!=null&&(n+=t)}),n}function zS(e,n){return e=BA({children:void 0},n),(n=xY(n.children))&&(e.children=n),e}function Vg(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=""+Um(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 jS(e,n){if(n.dangerouslySetInnerHTML!=null)throw Error(Gn(91));return BA({},n,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function jk(e,n){var t=n.value;if(t==null){if(t=n.children,n=n.defaultValue,t!=null){if(n!=null)throw Error(Gn(92));if(Array.isArray(t)){if(!(1>=t.length))throw Error(Gn(93));t=t[0]}n=t}n==null&&(n=""),t=n}e._wrapperState={initialValue:Um(t)}}function AD(e,n){var t=Um(n.value),r=Um(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 Wk(e){var n=e.textContent;n===e._wrapperState.initialValue&&n!==""&&n!==null&&(e.value=n)}var cD={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};function dD(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 WS(e,n){return e==null||e==="http://www.w3.org/1999/xhtml"?dD(n):e==="http://www.w3.org/2000/svg"&&n==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var lx,hD=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!==cD.svg||"innerHTML"in e)e.innerHTML=n;else{for(lx=lx||document.createElement("div"),lx.innerHTML="<svg>"+n.valueOf().toString()+"</svg>",n=lx.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;n.firstChild;)e.appendChild(n.firstChild)}});function Q_(e,n){if(n){var t=e.firstChild;if(t&&t===e.lastChild&&t.nodeType===3){t.nodeValue=n;return}}e.textContent=n}function ux(e,n){var t={};return t[e.toLowerCase()]=n.toLowerCase(),t["Webkit"+e]="webkit"+n,t["Moz"+e]="moz"+n,t}var Kg={animationend:ux("Animation","AnimationEnd"),animationiteration:ux("Animation","AnimationIteration"),animationstart:ux("Animation","AnimationStart"),transitionend:ux("Transition","TransitionEnd")},zw={},fD={};Gm&&(fD=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 K4(e){if(zw[e])return zw[e];if(!Kg[e])return e;var n=Kg[e],t;for(t in n)if(n.hasOwnProperty(t)&&t in fD)return zw[e]=n[t];return e}var pD=K4("animationend"),mD=K4("animationiteration"),gD=K4("animationstart"),yD=K4("transitionend"),e_="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Nk=new(typeof WeakMap=="function"?WeakMap:Map);function GO(e){var n=Nk.get(e);return n===void 0&&(n=new Map,Nk.set(e,n)),n}function g1(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 vD(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 Gk(e){if(g1(e)!==e)throw Error(Gn(188))}function wY(e){var n=e.alternate;if(!n){if(n=g1(e),n===null)throw Error(Gn(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 Gk(i),e;if(o===r)return Gk(i),n;o=o.sibling}throw Error(Gn(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(Gn(189))}}if(t.alternate!==r)throw Error(Gn(190))}if(t.tag!==3)throw Error(Gn(188));return t.stateNode.current===t?e:n}function _D(e){if(e=wY(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 _y(e,n){if(n==null)throw Error(Gn(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 QO(e,n,t){Array.isArray(e)?e.forEach(n,t):e&&n.call(t,e)}var Tv=null;function MY(e){if(e){var n=e._dispatchListeners,t=e._dispatchInstances;if(Array.isArray(n))for(var r=0;r<n.length&&!e.isPropagationStopped();r++)Tk(e,n[r],t[r]);else n&&Tk(e,n,t);e._dispatchListeners=null,e._dispatchInstances=null,e.isPersistent()||e.constructor.release(e)}}function P4(e){if(e!==null&&(Tv=_y(Tv,e)),e=Tv,Tv=null,e){if(QO(e,MY),Tv)throw Error(Gn(95));if(K2)throw e=KS,K2=!1,KS=null,e}}function $O(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}function CD(e){if(!Gm)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 D2=[];function bD(e){e.topLevelType=null,e.nativeEvent=null,e.targetInst=null,e.ancestors.length=0,10>D2.length&&D2.push(e)}function xD(e,n,t,r){if(D2.length){var i=D2.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 wD(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=PC(r)}while(t);for(t=0;t<e.ancestors.length;t++){n=e.ancestors[t];var i=$O(e.nativeEvent);r=e.topLevelType;var o=e.nativeEvent,s=e.eventSystemFlags;t===0&&(s|=64);for(var a=null,h=0;h<F2.length;h++){var g=F2[h];g&&(g=g.extractEvents(r,n,o,i,s))&&(a=_y(a,g))}P4(a)}}function NS(e,n,t){if(!t.has(e)){switch(e){case"scroll":t_(n,"scroll",!0);break;case"focus":case"blur":t_(n,"focus",!0),t_(n,"blur",!0),t.set("blur",null),t.set("focus",null);break;case"cancel":case"close":CD(e)&&t_(n,e,!0);break;case"invalid":case"submit":case"reset":break;default:e_.indexOf(e)===-1&&$s(e,n)}t.set(e,null)}}var MD,YO,SD,GS=!1,lf=[],Mm=null,Sm=null,Em=null,$_=new Map,Y_=new Map,Kv=[],QS="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(" "),SY="focus blur dragenter dragleave mouseover mouseout pointerover pointerout gotpointercapture lostpointercapture".split(" ");function EY(e,n){var t=GO(n);QS.forEach(function(r){NS(r,n,t)}),SY.forEach(function(r){NS(r,n,t)})}function $S(e,n,t,r,i){return{blockedOn:e,topLevelType:n,eventSystemFlags:t|32,nativeEvent:i,container:r}}function Qk(e,n){switch(e){case"focus":case"blur":Mm=null;break;case"dragenter":case"dragleave":Sm=null;break;case"mouseover":case"mouseout":Em=null;break;case"pointerover":case"pointerout":$_.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":Y_.delete(n.pointerId)}}function Pv(e,n,t,r,i,o){return e===null||e.nativeEvent!==o?(e=$S(n,t,r,i,o),n!==null&&(n=FC(n),n!==null&&YO(n)),e):(e.eventSystemFlags|=r,e)}function OY(e,n,t,r,i){switch(n){case"focus":return Mm=Pv(Mm,e,n,t,r,i),!0;case"dragenter":return Sm=Pv(Sm,e,n,t,r,i),!0;case"mouseover":return Em=Pv(Em,e,n,t,r,i),!0;case"pointerover":var o=i.pointerId;return $_.set(o,Pv($_.get(o)||null,e,n,t,r,i)),!0;case"gotpointercapture":return o=i.pointerId,Y_.set(o,Pv(Y_.get(o)||null,e,n,t,r,i)),!0}return!1}function BY(e){var n=PC(e.target);if(n!==null){var t=g1(n);if(t!==null){if(n=t.tag,n===13){if(n=vD(t),n!==null){e.blockedOn=n,Ku.unstable_runWithPriority(e.priority,function(){SD(t)});return}}else if(n===3&&t.stateNode.hydrate){e.blockedOn=t.tag===3?t.stateNode.containerInfo:null;return}}}e.blockedOn=null}function i2(e){if(e.blockedOn!==null)return!1;var n=VO(e.topLevelType,e.eventSystemFlags,e.container,e.nativeEvent);if(n!==null){var t=FC(n);return t!==null&&YO(t),e.blockedOn=n,!1}return!0}function $k(e,n,t){i2(e)&&t.delete(n)}function kY(){for(GS=!1;0<lf.length;){var e=lf[0];if(e.blockedOn!==null){e=FC(e.blockedOn),e!==null&&MD(e);break}var n=VO(e.topLevelType,e.eventSystemFlags,e.container,e.nativeEvent);n!==null?e.blockedOn=n:lf.shift()}Mm!==null&&i2(Mm)&&(Mm=null),Sm!==null&&i2(Sm)&&(Sm=null),Em!==null&&i2(Em)&&(Em=null),$_.forEach($k),Y_.forEach($k)}function Fv(e,n){e.blockedOn===n&&(e.blockedOn=null,GS||(GS=!0,Ku.unstable_scheduleCallback(Ku.unstable_NormalPriority,kY)))}function ED(e){function n(i){return Fv(i,e)}if(0<lf.length){Fv(lf[0],e);for(var t=1;t<lf.length;t++){var r=lf[t];r.blockedOn===e&&(r.blockedOn=null)}}for(Mm!==null&&Fv(Mm,e),Sm!==null&&Fv(Sm,e),Em!==null&&Fv(Em,e),$_.forEach(n),Y_.forEach(n),t=0;t<Kv.length;t++)r=Kv[t],r.blockedOn===e&&(r.blockedOn=null);for(;0<Kv.length&&(t=Kv[0],t.blockedOn===null);)BY(t),t.blockedOn===null&&Kv.shift()}var OD={},BD=new Map,qO=new Map,IY=["abort","abort",pD,"animationEnd",mD,"animationIteration",gD,"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",yD,"transitionEnd","waiting","waiting"];function HO(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},qO.set(r,n),BD.set(r,o),OD[i]=o}}HO("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);HO("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);HO(IY,2);for(var Yk="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),jw=0;jw<Yk.length;jw++)qO.set(Yk[jw],0);var TY=Ku.unstable_UserBlockingPriority,KY=Ku.unstable_runWithPriority,o2=!0;function $s(e,n){t_(n,e,!1)}function t_(e,n,t){var r=qO.get(n);switch(r===void 0?2:r){case 0:r=PY.bind(null,n,1,e);break;case 1:r=FY.bind(null,n,1,e);break;default:r=F4.bind(null,n,1,e)}t?e.addEventListener(n,r,!0):e.addEventListener(n,r,!1)}function PY(e,n,t,r){F0||DO();var i=F4,o=F0;F0=!0;try{JF(i,e,n,t,r)}finally{(F0=o)||LO()}}function FY(e,n,t,r){KY(TY,F4.bind(null,e,n,t,r))}function F4(e,n,t,r){if(o2)if(0<lf.length&&-1<QS.indexOf(e))e=$S(null,e,n,t,r),lf.push(e);else{var i=VO(e,n,t,r);if(i===null)Qk(e,r);else if(-1<QS.indexOf(e))e=$S(i,e,n,t,r),lf.push(e);else if(!OY(i,e,n,t,r)){Qk(e,r),e=xD(e,r,null,n);try{tD(wD,e)}finally{bD(e)}}}}function VO(e,n,t,r){if(t=$O(r),t=PC(t),t!==null){var i=g1(t);if(i===null)t=null;else{var o=i.tag;if(o===13){if(t=vD(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=xD(e,r,t,n);try{tD(wD,e)}finally{bD(e)}return null}var v_={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},DY=["Webkit","ms","Moz","O"];Object.keys(v_).forEach(function(e){DY.forEach(function(n){n=n+e.charAt(0).toUpperCase()+e.substring(1),v_[n]=v_[e]})});function kD(e,n,t){return n==null||typeof n=="boolean"||n===""?"":t||typeof n!="number"||n===0||v_.hasOwnProperty(e)&&v_[e]?(""+n).trim():n+"px"}function ID(e,n){e=e.style;for(var t in n)if(n.hasOwnProperty(t)){var r=t.indexOf("--")===0,i=kD(t,n[t],r);t==="float"&&(t="cssFloat"),r?e.setProperty(t,i):e[t]=i}}var LY=BA({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 YS(e,n){if(n){if(LY[e]&&(n.children!=null||n.dangerouslySetInnerHTML!=null))throw Error(Gn(137,e,""));if(n.dangerouslySetInnerHTML!=null){if(n.children!=null)throw Error(Gn(60));if(!(typeof n.dangerouslySetInnerHTML=="object"&&"__html"in n.dangerouslySetInnerHTML))throw Error(Gn(61))}if(n.style!=null&&typeof n.style!="object")throw Error(Gn(62,""))}}function qS(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 qk=cD.html;function rp(e,n){e=e.nodeType===9||e.nodeType===11?e:e.ownerDocument;var t=GO(e);n=PO[n];for(var r=0;r<n.length;r++)NS(n[r],e,t)}function L2(){}function HS(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 Hk(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Vk(e,n){var t=Hk(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=Hk(t)}}function TD(e,n){return e&&n?e===n?!0:e&&e.nodeType===3?!1:n&&n.nodeType===3?TD(e,n.parentNode):"contains"in e?e.contains(n):e.compareDocumentPosition?!!(e.compareDocumentPosition(n)&16):!1:!1}function Zk(){for(var e=window,n=HS();n instanceof e.HTMLIFrameElement;){try{var t=typeof n.contentWindow.location.href=="string"}catch{t=!1}if(t)e=n.contentWindow;else break;n=HS(e.document)}return n}function VS(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 KD="$",PD="/$",ZO="$?",XO="$!",Ww=null,Nw=null;function FD(e,n){switch(e){case"button":case"input":case"select":case"textarea":return!!n.autoFocus}return!1}function ZS(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 Gw=typeof setTimeout=="function"?setTimeout:void 0,UY=typeof clearTimeout=="function"?clearTimeout:void 0;function Zg(e){for(;e!=null;e=e.nextSibling){var n=e.nodeType;if(n===1||n===3)break}return e}function Xk(e){e=e.previousSibling;for(var n=0;e;){if(e.nodeType===8){var t=e.data;if(t===KD||t===XO||t===ZO){if(n===0)return e;n--}else t===PD&&n++}e=e.previousSibling}return null}var JO=Math.random().toString(36).slice(2),hm="__reactInternalInstance$"+JO,U2="__reactEventHandlers$"+JO,KC="__reactContainere$"+JO;function PC(e){var n=e[hm];if(n)return n;for(var t=e.parentNode;t;){if(n=t[KC]||t[hm]){if(t=n.alternate,n.child!==null||t!==null&&t.child!==null)for(e=Xk(e);e!==null;){if(t=e[hm])return t;e=Xk(e)}return n}e=t,t=e.parentNode}return null}function FC(e){return e=e[hm]||e[KC],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function r1(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(Gn(33))}function eB(e){return e[U2]||null}function ip(e){do e=e.return;while(e&&e.tag!==5);return e||null}function DD(e,n){var t=e.stateNode;if(!t)return null;var r=KO(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(Gn(231,n,typeof t));return t}function Jk(e,n,t){(n=DD(e,t.dispatchConfig.phasedRegistrationNames[n]))&&(t._dispatchListeners=_y(t._dispatchListeners,n),t._dispatchInstances=_y(t._dispatchInstances,e))}function RY(e){if(e&&e.dispatchConfig.phasedRegistrationNames){for(var n=e._targetInst,t=[];n;)t.push(n),n=ip(n);for(n=t.length;0<n--;)Jk(t[n],"captured",e);for(n=0;n<t.length;n++)Jk(t[n],"bubbled",e)}}function XS(e,n,t){e&&t&&t.dispatchConfig.registrationName&&(n=DD(e,t.dispatchConfig.registrationName))&&(t._dispatchListeners=_y(t._dispatchListeners,n),t._dispatchInstances=_y(t._dispatchInstances,e))}function zY(e){e&&e.dispatchConfig.registrationName&&XS(e._targetInst,null,e)}function Cy(e){QO(e,RY)}var fm=null,tB=null,a2=null;function LD(){if(a2)return a2;var e,n=tB,t=n.length,r,i="value"in fm?fm.value:fm.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 a2=i.slice(e,1<r?1-r:void 0)}function s2(){return!0}function R2(){return!1}function zc(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)?s2:R2,this.isPropagationStopped=R2,this}BA(zc.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!="unknown"&&(e.returnValue=!1),this.isDefaultPrevented=s2)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!="unknown"&&(e.cancelBubble=!0),this.isPropagationStopped=s2)},persist:function(){this.isPersistent=s2},isPersistent:R2,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=R2,this._dispatchInstances=this._dispatchListeners=null}});zc.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};zc.extend=function(e){function n(){}function t(){return r.apply(this,arguments)}var r=this;n.prototype=r.prototype;var i=new n;return BA(i,t.prototype),t.prototype=i,t.prototype.constructor=t,t.Interface=BA({},r.Interface,e),t.extend=r.extend,UD(t),t};UD(zc);function jY(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 WY(e){if(!(e instanceof this))throw Error(Gn(279));e.destructor(),10>this.eventPool.length&&this.eventPool.push(e)}function UD(e){e.eventPool=[],e.getPooled=jY,e.release=WY}var NY=zc.extend({data:null}),GY=zc.extend({data:null}),QY=[9,13,27,32],nB=Gm&&"CompositionEvent"in window,__=null;Gm&&"documentMode"in document&&(__=document.documentMode);var $Y=Gm&&"TextEvent"in window&&!__,RD=Gm&&(!nB||__&&8<__&&11>=__),eI=" ",Zf={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(" ")}},tI=!1;function zD(e,n){switch(e){case"keyup":return QY.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"blur":return!0;default:return!1}}function jD(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Pg=!1;function YY(e,n){switch(e){case"compositionend":return jD(n);case"keypress":return n.which!==32?null:(tI=!0,eI);case"textInput":return e=n.data,e===eI&&tI?null:e;default:return null}}function qY(e,n){if(Pg)return e==="compositionend"||!nB&&zD(e,n)?(e=LD(),a2=tB=fm=null,Pg=!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 RD&&n.locale!=="ko"?null:n.data;default:return null}}var HY={eventTypes:Zf,extractEvents:function(e,n,t,r){var i;if(nB)e:{switch(e){case"compositionstart":var o=Zf.compositionStart;break e;case"compositionend":o=Zf.compositionEnd;break e;case"compositionupdate":o=Zf.compositionUpdate;break e}o=void 0}else Pg?zD(e,t)&&(o=Zf.compositionEnd):e==="keydown"&&t.keyCode===229&&(o=Zf.compositionStart);return o?(RD&&t.locale!=="ko"&&(Pg||o!==Zf.compositionStart?o===Zf.compositionEnd&&Pg&&(i=LD()):(fm=r,tB="value"in fm?fm.value:fm.textContent,Pg=!0)),o=NY.getPooled(o,n,t,r),i?o.data=i:(i=jD(t),i!==null&&(o.data=i)),Cy(o),i=o):i=null,(e=$Y?YY(e,t):qY(e,t))?(n=GY.getPooled(Zf.beforeInput,n,t,r),n.data=e,Cy(n)):n=null,i===null?n:n===null?i:[i,n]}},VY={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 WD(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n==="input"?!!VY[e.type]:n==="textarea"}var ND={change:{phasedRegistrationNames:{bubbled:"onChange",captured:"onChangeCapture"},dependencies:"blur change click focus input keydown keyup selectionchange".split(" ")}};function GD(e,n,t){return e=zc.getPooled(ND.change,e,n,t),e.type="change",ZF(t),Cy(e),e}var C_=null,q_=null;function ZY(e){P4(e)}function D4(e){var n=r1(e);if(lD(n))return e}function XY(e,n){if(e==="change")return n}var JS=!1;Gm&&(JS=CD("input")&&(!document.documentMode||9<document.documentMode));function nI(){C_&&(C_.detachEvent("onpropertychange",QD),q_=C_=null)}function QD(e){if(e.propertyName==="value"&&D4(q_))if(e=GD(q_,e,$O(e)),F0)P4(e);else{F0=!0;try{FO(ZY,e)}finally{F0=!1,LO()}}}function JY(e,n,t){e==="focus"?(nI(),C_=n,q_=t,C_.attachEvent("onpropertychange",QD)):e==="blur"&&nI()}function eq(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return D4(q_)}function tq(e,n){if(e==="click")return D4(n)}function nq(e,n){if(e==="input"||e==="change")return D4(n)}var rq={eventTypes:ND,_isInputEventSupported:JS,extractEvents:function(e,n,t,r){var i=n?r1(n):window,o=i.nodeName&&i.nodeName.toLowerCase();if(o==="select"||o==="input"&&i.type==="file")var s=XY;else if(WD(i))if(JS)s=nq;else{s=eq;var a=JY}else(o=i.nodeName)&&o.toLowerCase()==="input"&&(i.type==="checkbox"||i.type==="radio")&&(s=tq);if(s&&(s=s(e,n)))return GD(s,t,r);a&&a(e,i,n),e==="blur"&&(e=i._wrapperState)&&e.controlled&&i.type==="number"&&RS(i,"number",i.value)}},DC=zc.extend({view:null,detail:null}),iq={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function oq(e){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(e):(e=iq[e])?!!n[e]:!1}function rB(){return oq}var rI=0,iI=0,oI=!1,aI=!1,LC=DC.extend({screenX:null,screenY:null,clientX:null,clientY:null,pageX:null,pageY:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,getModifierState:rB,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=rI;return rI=e.screenX,oI?e.type==="mousemove"?e.screenX-n:0:(oI=!0,0)},movementY:function(e){if("movementY"in e)return e.movementY;var n=iI;return iI=e.screenY,aI?e.type==="mousemove"?e.screenY-n:0:(aI=!0,0)}}),$D=LC.extend({pointerId:null,width:null,height:null,pressure:null,tangentialPressure:null,tiltX:null,tiltY:null,twist:null,pointerType:null,isPrimary:null}),Dv={mouseEnter:{registrationName:"onMouseEnter",dependencies:["mouseout","mouseover"]},mouseLeave:{registrationName:"onMouseLeave",dependencies:["mouseout","mouseover"]},pointerEnter:{registrationName:"onPointerEnter",dependencies:["pointerout","pointerover"]},pointerLeave:{registrationName:"onPointerLeave",dependencies:["pointerout","pointerover"]}},aq={eventTypes:Dv,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)?PC(n):null,n!==null){var a=g1(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 h=LC,g=Dv.mouseLeave,C=Dv.mouseEnter,B="mouse";else(e==="pointerout"||e==="pointerover")&&(h=$D,g=Dv.pointerLeave,C=Dv.pointerEnter,B="pointer");if(e=s==null?o:r1(s),o=n==null?o:r1(n),g=h.getPooled(g,s,t,r),g.type=B+"leave",g.target=e,g.relatedTarget=o,t=h.getPooled(C,n,t,r),t.type=B+"enter",t.target=o,t.relatedTarget=e,r=s,B=n,r&&B)e:{for(h=r,C=B,s=0,e=h;e;e=ip(e))s++;for(e=0,n=C;n;n=ip(n))e++;for(;0<s-e;)h=ip(h),s--;for(;0<e-s;)C=ip(C),e--;for(;s--;){if(h===C||h===C.alternate)break e;h=ip(h),C=ip(C)}h=null}else h=null;for(C=h,h=[];r&&r!==C&&(s=r.alternate,!(s!==null&&s===C));)h.push(r),r=ip(r);for(r=[];B&&B!==C&&(s=B.alternate,!(s!==null&&s===C));)r.push(B),B=ip(B);for(B=0;B<h.length;B++)XS(h[B],"bubbled",g);for(B=r.length;0<B--;)XS(r[B],"captured",t);return i&64?[g,t]:[g]}};function sq(e,n){return e===n&&(e!==0||1/e===1/n)||e!==e&&n!==n}var i1=typeof Object.is=="function"?Object.is:sq,lq=Object.prototype.hasOwnProperty;function H_(e,n){if(i1(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(!lq.call(n,t[r])||!i1(e[t[r]],n[t[r]]))return!1;return!0}var uq=Gm&&"documentMode"in document&&11>=document.documentMode,YD={select:{phasedRegistrationNames:{bubbled:"onSelect",captured:"onSelectCapture"},dependencies:"blur contextmenu dragend focus keydown keyup mousedown mouseup selectionchange".split(" ")}},Fg=null,e6=null,b_=null,t6=!1;function sI(e,n){var t=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;return t6||Fg==null||Fg!==HS(t)?null:(t=Fg,"selectionStart"in t&&VS(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}),b_&&H_(b_,t)?null:(b_=t,e=zc.getPooled(YD.select,e6,e,n),e.type="select",e.target=Fg,Cy(e),e))}var Aq={eventTypes:YD,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=GO(i),o=PO.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?r1(n):window,e){case"focus":(WD(i)||i.contentEditable==="true")&&(Fg=i,e6=n,b_=null);break;case"blur":b_=e6=Fg=null;break;case"mousedown":t6=!0;break;case"contextmenu":case"mouseup":case"dragend":return t6=!1,sI(t,r);case"selectionchange":if(uq)break;case"keydown":case"keyup":return sI(t,r)}return null}},cq=zc.extend({animationName:null,elapsedTime:null,pseudoElement:null}),dq=zc.extend({clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),hq=DC.extend({relatedTarget:null});function l2(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 fq={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},pq={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"},mq=DC.extend({key:function(e){if(e.key){var n=fq[e.key]||e.key;if(n!=="Unidentified")return n}return e.type==="keypress"?(e=l2(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?pq[e.keyCode]||"Unidentified":""},location:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,repeat:null,locale:null,getModifierState:rB,charCode:function(e){return e.type==="keypress"?l2(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?l2(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),gq=LC.extend({dataTransfer:null}),yq=DC.extend({touches:null,targetTouches:null,changedTouches:null,altKey:null,metaKey:null,ctrlKey:null,shiftKey:null,getModifierState:rB}),vq=zc.extend({propertyName:null,elapsedTime:null,pseudoElement:null}),_q=LC.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}),Cq={eventTypes:OD,extractEvents:function(e,n,t,r){var i=BD.get(e);if(!i)return null;switch(e){case"keypress":if(l2(t)===0)return null;case"keydown":case"keyup":e=mq;break;case"blur":case"focus":e=hq;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=LC;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":e=gq;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":e=yq;break;case pD:case mD:case gD:e=cq;break;case yD:e=vq;break;case"scroll":e=DC;break;case"wheel":e=_q;break;case"copy":case"cut":case"paste":e=dq;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":e=$D;break;default:e=zc}return n=e.getPooled(i,n,t,r),Cy(n),n}};if(P2)throw Error(Gn(101));P2=Array.prototype.slice.call("ResponderEventPlugin SimpleEventPlugin EnterLeaveEventPlugin ChangeEventPlugin SelectEventPlugin BeforeInputEventPlugin".split(" "));HF();var bq=FC;KO=eB;YF=bq;qF=r1;VF({SimpleEventPlugin:Cq,EnterLeaveEventPlugin:aq,ChangeEventPlugin:rq,SelectEventPlugin:Aq,BeforeInputEventPlugin:HY});var n6=[],Dg=-1;function Os(e){0>Dg||(e.current=n6[Dg],n6[Dg]=null,Dg--)}function ml(e,n){Dg++,n6[Dg]=e.current,e.current=n}var Rm={},oA={current:Rm},ec={current:!1},o1=Rm;function by(e,n){var t=e.type.contextTypes;if(!t)return Rm;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 tc(e){return e=e.childContextTypes,e!=null}function z2(){Os(ec),Os(oA)}function lI(e,n,t){if(oA.current!==Rm)throw Error(Gn(168));ml(oA,n),ml(ec,t)}function qD(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(Gn(108,Cp(n)||"Unknown",i));return BA({},t,{},r)}function u2(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Rm,o1=oA.current,ml(oA,e),ml(ec,ec.current),!0}function uI(e,n,t){var r=e.stateNode;if(!r)throw Error(Gn(169));t?(e=qD(e,n,o1),r.__reactInternalMemoizedMergedChildContext=e,Os(ec),Os(oA),ml(oA,e)):Os(ec),ml(ec,t)}var xq=Ku.unstable_runWithPriority,iB=Ku.unstable_scheduleCallback,HD=Ku.unstable_cancelCallback,AI=Ku.unstable_requestPaint,r6=Ku.unstable_now,wq=Ku.unstable_getCurrentPriorityLevel,L4=Ku.unstable_ImmediatePriority,VD=Ku.unstable_UserBlockingPriority,ZD=Ku.unstable_NormalPriority,XD=Ku.unstable_LowPriority,JD=Ku.unstable_IdlePriority,eL={},Mq=Ku.unstable_shouldYield,Sq=AI!==void 0?AI:function(){},cp=null,A2=null,Qw=!1,cI=r6(),md=1e4>cI?r6:function(){return r6()-cI};function U4(){switch(wq()){case L4:return 99;case VD:return 98;case ZD:return 97;case XD:return 96;case JD:return 95;default:throw Error(Gn(332))}}function tL(e){switch(e){case 99:return L4;case 98:return VD;case 97:return ZD;case 96:return XD;case 95:return JD;default:throw Error(Gn(332))}}function zm(e,n){return e=tL(e),xq(e,n)}function nL(e,n,t){return e=tL(e),iB(e,n,t)}function dI(e){return cp===null?(cp=[e],A2=iB(L4,rL)):cp.push(e),eL}function Mf(){if(A2!==null){var e=A2;A2=null,HD(e)}rL()}function rL(){if(!Qw&&cp!==null){Qw=!0;var e=0;try{var n=cp;zm(99,function(){for(;e<n.length;e++){var t=n[e];do t=t(!0);while(t!==null)}}),cp=null}catch(t){throw cp!==null&&(cp=cp.slice(e+1)),iB(L4,Mf),t}finally{Qw=!1}}}function c2(e,n,t){return t/=10,1073741821-(((1073741821-e+n/10)/t|0)+1)*t}function oh(e,n){if(e&&e.defaultProps){n=BA({},n),e=e.defaultProps;for(var t in e)n[t]===void 0&&(n[t]=e[t])}return n}var j2={current:null},W2=null,Lg=null,N2=null;function oB(){N2=Lg=W2=null}function aB(e){var n=j2.current;Os(j2),e.type._context._currentValue=n}function iL(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 Xg(e,n){W2=e,N2=Lg=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.expirationTime>=n&&(uf=!0),e.firstContext=null)}function bd(e,n){if(N2!==e&&n!==!1&&n!==0)if((typeof n!="number"||n===1073741823)&&(N2=e,n=1073741823),n={context:e,observedBits:n,next:null},Lg===null){if(W2===null)throw Error(Gn(308));Lg=n,W2.dependencies={expirationTime:0,firstContext:n,responders:null}}else Lg=Lg.next=n;return e._currentValue}var om=!1;function sB(e){e.updateQueue={baseState:e.memoizedState,baseQueue:null,shared:{pending:null},effects:null}}function lB(e,n){e=e.updateQueue,n.updateQueue===e&&(n.updateQueue={baseState:e.baseState,baseQueue:e.baseQueue,shared:e.shared,effects:e.effects})}function Om(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 hI(e,n){var t=e.alternate;t!==null&&lB(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 V_(e,n,t,r){var i=e.updateQueue;om=!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 h=i.baseState,g=0,C=null,B=null,k=null;if(a!==null){var P=a;do{if(s=P.expirationTime,s<r){var L={expirationTime:P.expirationTime,suspenseConfig:P.suspenseConfig,tag:P.tag,payload:P.payload,callback:P.callback,next:null};k===null?(B=k=L,C=h):k=k.next=L,s>g&&(g=s)}else{k!==null&&(k=k.next={expirationTime:1073741823,suspenseConfig:P.suspenseConfig,tag:P.tag,payload:P.payload,callback:P.callback,next:null}),PL(s,P.suspenseConfig);e:{var J=e,N=P;switch(s=n,L=t,N.tag){case 1:if(J=N.payload,typeof J=="function"){h=J.call(L,h,s);break e}h=J;break e;case 3:J.effectTag=J.effectTag&-4097|64;case 0:if(J=N.payload,s=typeof J=="function"?J.call(L,h,s):J,s==null)break e;h=BA({},h,s);break e;case 2:om=!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)}k===null?C=h:k.next=B,i.baseState=C,i.baseQueue=k,N4(g),e.expirationTime=g,e.memoizedState=h}}function fI(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(Gn(191,r));r.call(i)}}}var x_=uh.ReactCurrentBatchConfig,oL=new T4.Component().refs;function G2(e,n,t,r){n=e.memoizedState,t=t(r,n),t=t==null?n:BA({},n,t),e.memoizedState=t,e.expirationTime===0&&(e.updateQueue.baseState=t)}var R4={isMounted:function(e){return(e=e._reactInternalFiber)?g1(e)===e:!1},enqueueSetState:function(e,n,t){e=e._reactInternalFiber;var r=ff(),i=x_.suspense;r=q0(r,e,i),i=Om(r,i),i.payload=n,t!=null&&(i.callback=t),Bm(e,i),Im(e,r)},enqueueReplaceState:function(e,n,t){e=e._reactInternalFiber;var r=ff(),i=x_.suspense;r=q0(r,e,i),i=Om(r,i),i.tag=1,i.payload=n,t!=null&&(i.callback=t),Bm(e,i),Im(e,r)},enqueueForceUpdate:function(e,n){e=e._reactInternalFiber;var t=ff(),r=x_.suspense;t=q0(t,e,r),r=Om(t,r),r.tag=2,n!=null&&(r.callback=n),Bm(e,r),Im(e,t)}};function pI(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?!H_(t,r)||!H_(i,o):!0}function aL(e,n,t){var r=!1,i=Rm,o=n.contextType;return typeof o=="object"&&o!==null?o=bd(o):(i=tc(n)?o1:oA.current,r=n.contextTypes,o=(r=r!=null)?by(e,i):Rm),n=new n(t,o),e.memoizedState=n.state!==null&&n.state!==void 0?n.state:null,n.updater=R4,e.stateNode=n,n._reactInternalFiber=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=o),n}function mI(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&&R4.enqueueReplaceState(n,n.state,null)}function i6(e,n,t,r){var i=e.stateNode;i.props=t,i.state=e.memoizedState,i.refs=oL,sB(e);var o=n.contextType;typeof o=="object"&&o!==null?i.context=bd(o):(o=tc(n)?o1:oA.current,i.context=by(e,o)),V_(e,t,i,r),i.state=e.memoizedState,o=n.getDerivedStateFromProps,typeof o=="function"&&(G2(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&&R4.enqueueReplaceState(i,i.state,null),V_(e,t,i,r),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.effectTag|=4)}var Ax=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(Gn(309));var r=t.stateNode}if(!r)throw Error(Gn(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===oL&&(s=r.refs={}),o===null?delete s[i]:s[i]=o},n._stringRef=i,n)}if(typeof e!="string")throw Error(Gn(284));if(!t._owner)throw Error(Gn(290,e))}return e}function cx(e,n){if(e.type!=="textarea")throw Error(Gn(31,Object.prototype.toString.call(n)==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":n,""))}function sL(e){function n(N,$){if(e){var q=N.lastEffect;q!==null?(q.nextEffect=$,N.lastEffect=$):N.firstEffect=N.lastEffect=$,$.nextEffect=null,$.effectTag=8}}function t(N,$){if(!e)return null;for(;$!==null;)n(N,$),$=$.sibling;return null}function r(N,$){for(N=new Map;$!==null;)$.key!==null?N.set($.key,$):N.set($.index,$),$=$.sibling;return N}function i(N,$){return N=a1(N,$),N.index=0,N.sibling=null,N}function o(N,$,q){return N.index=q,e?(q=N.alternate,q!==null?(q=q.index,q<$?(N.effectTag=2,$):q):(N.effectTag=2,$)):$}function s(N){return e&&N.alternate===null&&(N.effectTag=2),N}function a(N,$,q,oe){return $===null||$.tag!==6?($=Zw(q,N.mode,oe),$.return=N,$):($=i($,q),$.return=N,$)}function h(N,$,q,oe){return $!==null&&$.elementType===q.type?(oe=i($,q.props),oe.ref=Lv(N,$,q),oe.return=N,oe):(oe=p2(q.type,q.key,q.props,null,N.mode,oe),oe.ref=Lv(N,$,q),oe.return=N,oe)}function g(N,$,q,oe){return $===null||$.tag!==4||$.stateNode.containerInfo!==q.containerInfo||$.stateNode.implementation!==q.implementation?($=Xw(q,N.mode,oe),$.return=N,$):($=i($,q.children||[]),$.return=N,$)}function C(N,$,q,oe,ce){return $===null||$.tag!==7?($=gm(q,N.mode,oe,ce),$.return=N,$):($=i($,q),$.return=N,$)}function B(N,$,q){if(typeof $=="string"||typeof $=="number")return $=Zw(""+$,N.mode,q),$.return=N,$;if(typeof $=="object"&&$!==null){switch($.$$typeof){case ax:return q=p2($.type,$.key,$.props,null,N.mode,q),q.ref=Lv(N,null,$),q.return=N,q;case Tg:return $=Xw($,N.mode,q),$.return=N,$}if(Ax($)||Iv($))return $=gm($,N.mode,q,null),$.return=N,$;cx(N,$)}return null}function k(N,$,q,oe){var ce=$!==null?$.key:null;if(typeof q=="string"||typeof q=="number")return ce!==null?null:a(N,$,""+q,oe);if(typeof q=="object"&&q!==null){switch(q.$$typeof){case ax:return q.key===ce?q.type===B0?C(N,$,q.props.children,oe,ce):h(N,$,q,oe):null;case Tg:return q.key===ce?g(N,$,q,oe):null}if(Ax(q)||Iv(q))return ce!==null?null:C(N,$,q,oe,null);cx(N,q)}return null}function P(N,$,q,oe,ce){if(typeof oe=="string"||typeof oe=="number")return N=N.get(q)||null,a($,N,""+oe,ce);if(typeof oe=="object"&&oe!==null){switch(oe.$$typeof){case ax:return N=N.get(oe.key===null?q:oe.key)||null,oe.type===B0?C($,N,oe.props.children,ce,oe.key):h($,N,oe,ce);case Tg:return N=N.get(oe.key===null?q:oe.key)||null,g($,N,oe,ce)}if(Ax(oe)||Iv(oe))return N=N.get(q)||null,C($,N,oe,ce,null);cx($,oe)}return null}function L(N,$,q,oe){for(var ce=null,me=null,he=$,V=$=0,ae=null;he!==null&&V<q.length;V++){he.index>V?(ae=he,he=null):ae=he.sibling;var ye=k(N,he,q[V],oe);if(ye===null){he===null&&(he=ae);break}e&&he&&ye.alternate===null&&n(N,he),$=o(ye,$,V),me===null?ce=ye:me.sibling=ye,me=ye,he=ae}if(V===q.length)return t(N,he),ce;if(he===null){for(;V<q.length;V++)he=B(N,q[V],oe),he!==null&&($=o(he,$,V),me===null?ce=he:me.sibling=he,me=he);return ce}for(he=r(N,he);V<q.length;V++)ae=P(he,N,V,q[V],oe),ae!==null&&(e&&ae.alternate!==null&&he.delete(ae.key===null?V:ae.key),$=o(ae,$,V),me===null?ce=ae:me.sibling=ae,me=ae);return e&&he.forEach(function(Oe){return n(N,Oe)}),ce}function J(N,$,q,oe){var ce=Iv(q);if(typeof ce!="function")throw Error(Gn(150));if(q=ce.call(q),q==null)throw Error(Gn(151));for(var me=ce=null,he=$,V=$=0,ae=null,ye=q.next();he!==null&&!ye.done;V++,ye=q.next()){he.index>V?(ae=he,he=null):ae=he.sibling;var Oe=k(N,he,ye.value,oe);if(Oe===null){he===null&&(he=ae);break}e&&he&&Oe.alternate===null&&n(N,he),$=o(Oe,$,V),me===null?ce=Oe:me.sibling=Oe,me=Oe,he=ae}if(ye.done)return t(N,he),ce;if(he===null){for(;!ye.done;V++,ye=q.next())ye=B(N,ye.value,oe),ye!==null&&($=o(ye,$,V),me===null?ce=ye:me.sibling=ye,me=ye);return ce}for(he=r(N,he);!ye.done;V++,ye=q.next())ye=P(he,N,V,ye.value,oe),ye!==null&&(e&&ye.alternate!==null&&he.delete(ye.key===null?V:ye.key),$=o(ye,$,V),me===null?ce=ye:me.sibling=ye,me=ye);return e&&he.forEach(function(De){return n(N,De)}),ce}return function(N,$,q,oe){var ce=typeof q=="object"&&q!==null&&q.type===B0&&q.key===null;ce&&(q=q.props.children);var me=typeof q=="object"&&q!==null;if(me)switch(q.$$typeof){case ax:e:{for(me=q.key,ce=$;ce!==null;){if(ce.key===me){switch(ce.tag){case 7:if(q.type===B0){t(N,ce.sibling),$=i(ce,q.props.children),$.return=N,N=$;break e}break;default:if(ce.elementType===q.type){t(N,ce.sibling),$=i(ce,q.props),$.ref=Lv(N,ce,q),$.return=N,N=$;break e}}t(N,ce);break}else n(N,ce);ce=ce.sibling}q.type===B0?($=gm(q.props.children,N.mode,oe,q.key),$.return=N,N=$):(oe=p2(q.type,q.key,q.props,null,N.mode,oe),oe.ref=Lv(N,$,q),oe.return=N,N=oe)}return s(N);case Tg:e:{for(ce=q.key;$!==null;){if($.key===ce)if($.tag===4&&$.stateNode.containerInfo===q.containerInfo&&$.stateNode.implementation===q.implementation){t(N,$.sibling),$=i($,q.children||[]),$.return=N,N=$;break e}else{t(N,$);break}else n(N,$);$=$.sibling}$=Xw(q,N.mode,oe),$.return=N,N=$}return s(N)}if(typeof q=="string"||typeof q=="number")return q=""+q,$!==null&&$.tag===6?(t(N,$.sibling),$=i($,q),$.return=N,N=$):(t(N,$),$=Zw(q,N.mode,oe),$.return=N,N=$),s(N);if(Ax(q))return L(N,$,q,oe);if(Iv(q))return J(N,$,q,oe);if(me&&cx(N,q),typeof q>"u"&&!ce)switch(N.tag){case 1:case 0:throw N=N.type,Error(Gn(152,N.displayName||N.name||"Component"))}return t(N,$)}}var xy=sL(!0),uB=sL(!1),UC={},hf={current:UC},Z_={current:UC},X_={current:UC};function D0(e){if(e===UC)throw Error(Gn(174));return e}function o6(e,n){switch(ml(X_,n),ml(Z_,e),ml(hf,UC),e=n.nodeType,e){case 9:case 11:n=(n=n.documentElement)?n.namespaceURI:WS(null,"");break;default:e=e===8?n.parentNode:n,n=e.namespaceURI||null,e=e.tagName,n=WS(n,e)}Os(hf),ml(hf,n)}function wy(){Os(hf),Os(Z_),Os(X_)}function gI(e){D0(X_.current);var n=D0(hf.current),t=WS(n,e.type);n!==t&&(ml(Z_,e),ml(hf,t))}function AB(e){Z_.current===e&&(Os(hf),Os(Z_))}var ol={current:0};function Q2(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===ZO||t.data===XO))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 cB(e,n){return{responder:e,props:n}}var d2=uh.ReactCurrentDispatcher,vd=uh.ReactCurrentBatchConfig,pm=0,Hl=null,rA=null,iA=null,$2=!1;function Oc(){throw Error(Gn(321))}function dB(e,n){if(n===null)return!1;for(var t=0;t<n.length&&t<e.length;t++)if(!i1(e[t],n[t]))return!1;return!0}function hB(e,n,t,r,i,o){if(pm=o,Hl=n,n.memoizedState=null,n.updateQueue=null,n.expirationTime=0,d2.current=e===null||e.memoizedState===null?Eq:Oq,e=t(r,i),n.expirationTime===pm){o=0;do{if(n.expirationTime=0,!(25>o))throw Error(Gn(301));o+=1,iA=rA=null,n.updateQueue=null,d2.current=Bq,e=t(r,i)}while(n.expirationTime===pm)}if(d2.current=H2,n=rA!==null&&rA.next!==null,pm=0,iA=rA=Hl=null,$2=!1,n)throw Error(Gn(300));return e}function Jg(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return iA===null?Hl.memoizedState=iA=e:iA=iA.next=e,iA}function Ly(){if(rA===null){var e=Hl.alternate;e=e!==null?e.memoizedState:null}else e=rA.next;var n=iA===null?Hl.memoizedState:iA.next;if(n!==null)iA=n,rA=e;else{if(e===null)throw Error(Gn(310));rA=e,e={memoizedState:rA.memoizedState,baseState:rA.baseState,baseQueue:rA.baseQueue,queue:rA.queue,next:null},iA===null?Hl.memoizedState=iA=e:iA=iA.next=e}return iA}function Q0(e,n){return typeof n=="function"?n(e):n}function dx(e){var n=Ly(),t=n.queue;if(t===null)throw Error(Gn(311));t.lastRenderedReducer=e;var r=rA,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,h=i;do{var g=h.expirationTime;if(g<pm){var C={expirationTime:h.expirationTime,suspenseConfig:h.suspenseConfig,action:h.action,eagerReducer:h.eagerReducer,eagerState:h.eagerState,next:null};a===null?(s=a=C,o=r):a=a.next=C,g>Hl.expirationTime&&(Hl.expirationTime=g,N4(g))}else a!==null&&(a=a.next={expirationTime:1073741823,suspenseConfig:h.suspenseConfig,action:h.action,eagerReducer:h.eagerReducer,eagerState:h.eagerState,next:null}),PL(g,h.suspenseConfig),r=h.eagerReducer===e?h.eagerState:e(r,h.action);h=h.next}while(h!==null&&h!==i);a===null?o=r:a.next=s,i1(r,n.memoizedState)||(uf=!0),n.memoizedState=r,n.baseState=o,n.baseQueue=a,t.lastRenderedState=r}return[n.memoizedState,t.dispatch]}function hx(e){var n=Ly(),t=n.queue;if(t===null)throw Error(Gn(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);i1(o,n.memoizedState)||(uf=!0),n.memoizedState=o,n.baseQueue===null&&(n.baseState=o),t.lastRenderedState=o}return[o,r]}function $w(e){var n=Jg();return typeof e=="function"&&(e=e()),n.memoizedState=n.baseState=e,e=n.queue={pending:null,dispatch:null,lastRenderedReducer:Q0,lastRenderedState:e},e=e.dispatch=hL.bind(null,Hl,e),[n.memoizedState,e]}function a6(e,n,t,r){return e={tag:e,create:n,destroy:t,deps:r,next:null},n=Hl.updateQueue,n===null?(n={lastEffect:null},Hl.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 lL(){return Ly().memoizedState}function s6(e,n,t,r){var i=Jg();Hl.effectTag|=e,i.memoizedState=a6(1|n,t,void 0,r===void 0?null:r)}function fB(e,n,t,r){var i=Ly();r=r===void 0?null:r;var o=void 0;if(rA!==null){var s=rA.memoizedState;if(o=s.destroy,r!==null&&dB(r,s.deps)){a6(n,t,o,r);return}}Hl.effectTag|=e,i.memoizedState=a6(1|n,t,o,r)}function yI(e,n){return s6(516,4,e,n)}function Y2(e,n){return fB(516,4,e,n)}function uL(e,n){return fB(4,2,e,n)}function AL(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 cL(e,n,t){return t=t!=null?t.concat([e]):null,fB(4,2,AL.bind(null,n,e),t)}function pB(){}function vI(e,n){return Jg().memoizedState=[e,n===void 0?null:n],e}function q2(e,n){var t=Ly();n=n===void 0?null:n;var r=t.memoizedState;return r!==null&&n!==null&&dB(n,r[1])?r[0]:(t.memoizedState=[e,n],e)}function dL(e,n){var t=Ly();n=n===void 0?null:n;var r=t.memoizedState;return r!==null&&n!==null&&dB(n,r[1])?r[0]:(e=e(),t.memoizedState=[e,n],e)}function mB(e,n,t){var r=U4();zm(98>r?98:r,function(){e(!0)}),zm(97<r?97:r,function(){var i=vd.suspense;vd.suspense=n===void 0?null:n;try{e(!1),t()}finally{vd.suspense=i}})}function hL(e,n,t){var r=ff(),i=x_.suspense;r=q0(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===Hl||o!==null&&o===Hl)$2=!0,i.expirationTime=pm,Hl.expirationTime=pm;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,i1(a,s))return}catch{}finally{}Im(e,r)}}var H2={readContext:bd,useCallback:Oc,useContext:Oc,useEffect:Oc,useImperativeHandle:Oc,useLayoutEffect:Oc,useMemo:Oc,useReducer:Oc,useRef:Oc,useState:Oc,useDebugValue:Oc,useResponder:Oc,useDeferredValue:Oc,useTransition:Oc},Eq={readContext:bd,useCallback:vI,useContext:bd,useEffect:yI,useImperativeHandle:function(e,n,t){return t=t!=null?t.concat([e]):null,s6(4,2,AL.bind(null,n,e),t)},useLayoutEffect:function(e,n){return s6(4,2,e,n)},useMemo:function(e,n){var t=Jg();return n=n===void 0?null:n,e=e(),t.memoizedState=[e,n],e},useReducer:function(e,n,t){var r=Jg();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=hL.bind(null,Hl,e),[r.memoizedState,e]},useRef:function(e){var n=Jg();return e={current:e},n.memoizedState=e},useState:$w,useDebugValue:pB,useResponder:cB,useDeferredValue:function(e,n){var t=$w(e),r=t[0],i=t[1];return yI(function(){var o=vd.suspense;vd.suspense=n===void 0?null:n;try{i(e)}finally{vd.suspense=o}},[e,n]),r},useTransition:function(e){var n=$w(!1),t=n[0];return n=n[1],[vI(mB.bind(null,n,e),[n,e]),t]}},Oq={readContext:bd,useCallback:q2,useContext:bd,useEffect:Y2,useImperativeHandle:cL,useLayoutEffect:uL,useMemo:dL,useReducer:dx,useRef:lL,useState:function(){return dx(Q0)},useDebugValue:pB,useResponder:cB,useDeferredValue:function(e,n){var t=dx(Q0),r=t[0],i=t[1];return Y2(function(){var o=vd.suspense;vd.suspense=n===void 0?null:n;try{i(e)}finally{vd.suspense=o}},[e,n]),r},useTransition:function(e){var n=dx(Q0),t=n[0];return n=n[1],[q2(mB.bind(null,n,e),[n,e]),t]}},Bq={readContext:bd,useCallback:q2,useContext:bd,useEffect:Y2,useImperativeHandle:cL,useLayoutEffect:uL,useMemo:dL,useReducer:hx,useRef:lL,useState:function(){return hx(Q0)},useDebugValue:pB,useResponder:cB,useDeferredValue:function(e,n){var t=hx(Q0),r=t[0],i=t[1];return Y2(function(){var o=vd.suspense;vd.suspense=n===void 0?null:n;try{i(e)}finally{vd.suspense=o}},[e,n]),r},useTransition:function(e){var n=hx(Q0),t=n[0];return n=n[1],[q2(mB.bind(null,n,e),[n,e]),t]}},vp=null,mm=null,$0=!1;function fL(e,n){var t=Af(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 _I(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 l6(e){if($0){var n=mm;if(n){var t=n;if(!_I(e,n)){if(n=Zg(t.nextSibling),!n||!_I(e,n)){e.effectTag=e.effectTag&-1025|2,$0=!1,vp=e;return}fL(vp,t)}vp=e,mm=Zg(n.firstChild)}else e.effectTag=e.effectTag&-1025|2,$0=!1,vp=e}}function CI(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;vp=e}function fx(e){if(e!==vp)return!1;if(!$0)return CI(e),$0=!0,!1;var n=e.type;if(e.tag!==5||n!=="head"&&n!=="body"&&!ZS(n,e.memoizedProps))for(n=mm;n;)fL(e,n),n=Zg(n.nextSibling);if(CI(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Gn(317));e:{for(e=e.nextSibling,n=0;e;){if(e.nodeType===8){var t=e.data;if(t===PD){if(n===0){mm=Zg(e.nextSibling);break e}n--}else t!==KD&&t!==XO&&t!==ZO||n++}e=e.nextSibling}mm=null}}else mm=vp?Zg(e.stateNode.nextSibling):null;return!0}function Yw(){mm=vp=null,$0=!1}var kq=uh.ReactCurrentOwner,uf=!1;function kc(e,n,t,r){n.child=e===null?uB(n,null,t,r):xy(n,e.child,t,r)}function bI(e,n,t,r,i){t=t.render;var o=n.ref;return Xg(n,i),r=hB(e,n,t,r,o,i),e!==null&&!uf?(n.updateQueue=e.updateQueue,n.effectTag&=-517,e.expirationTime<=i&&(e.expirationTime=0),_p(e,n,i)):(n.effectTag|=1,kc(e,n,r,i),n.child)}function xI(e,n,t,r,i,o){if(e===null){var s=t.type;return typeof s=="function"&&!CB(s)&&s.defaultProps===void 0&&t.compare===null&&t.defaultProps===void 0?(n.tag=15,n.type=s,pL(e,n,s,r,i,o)):(e=p2(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:H_,t(i,r)&&e.ref===n.ref)?_p(e,n,o):(n.effectTag|=1,e=a1(s,r),e.ref=n.ref,e.return=n,n.child=e)}function pL(e,n,t,r,i,o){return e!==null&&H_(e.memoizedProps,r)&&e.ref===n.ref&&(uf=!1,i<o)?(n.expirationTime=e.expirationTime,_p(e,n,o)):u6(e,n,t,r,o)}function mL(e,n){var t=n.ref;(e===null&&t!==null||e!==null&&e.ref!==t)&&(n.effectTag|=128)}function u6(e,n,t,r,i){var o=tc(t)?o1:oA.current;return o=by(n,o),Xg(n,i),t=hB(e,n,t,r,o,i),e!==null&&!uf?(n.updateQueue=e.updateQueue,n.effectTag&=-517,e.expirationTime<=i&&(e.expirationTime=0),_p(e,n,i)):(n.effectTag|=1,kc(e,n,t,i),n.child)}function wI(e,n,t,r,i){if(tc(t)){var o=!0;u2(n)}else o=!1;if(Xg(n,i),n.stateNode===null)e!==null&&(e.alternate=null,n.alternate=null,n.effectTag|=2),aL(n,t,r),i6(n,t,r,i),r=!0;else if(e===null){var s=n.stateNode,a=n.memoizedProps;s.props=a;var h=s.context,g=t.contextType;typeof g=="object"&&g!==null?g=bd(g):(g=tc(t)?o1:oA.current,g=by(n,g));var C=t.getDerivedStateFromProps,B=typeof C=="function"||typeof s.getSnapshotBeforeUpdate=="function";B||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(a!==r||h!==g)&&mI(n,s,r,g),om=!1;var k=n.memoizedState;s.state=k,V_(n,r,s,i),h=n.memoizedState,a!==r||k!==h||ec.current||om?(typeof C=="function"&&(G2(n,t,C,r),h=n.memoizedState),(a=om||pI(n,t,a,r,k,h,g))?(B||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=h),s.props=r,s.state=h,s.context=g,r=a):(typeof s.componentDidMount=="function"&&(n.effectTag|=4),r=!1)}else s=n.stateNode,lB(e,n),a=n.memoizedProps,s.props=n.type===n.elementType?a:oh(n.type,a),h=s.context,g=t.contextType,typeof g=="object"&&g!==null?g=bd(g):(g=tc(t)?o1:oA.current,g=by(n,g)),C=t.getDerivedStateFromProps,(B=typeof C=="function"||typeof s.getSnapshotBeforeUpdate=="function")||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(a!==r||h!==g)&&mI(n,s,r,g),om=!1,h=n.memoizedState,s.state=h,V_(n,r,s,i),k=n.memoizedState,a!==r||h!==k||ec.current||om?(typeof C=="function"&&(G2(n,t,C,r),k=n.memoizedState),(C=om||pI(n,t,a,r,h,k,g))?(B||typeof s.UNSAFE_componentWillUpdate!="function"&&typeof s.componentWillUpdate!="function"||(typeof s.componentWillUpdate=="function"&&s.componentWillUpdate(r,k,g),typeof s.UNSAFE_componentWillUpdate=="function"&&s.UNSAFE_componentWillUpdate(r,k,g)),typeof s.componentDidUpdate=="function"&&(n.effectTag|=4),typeof s.getSnapshotBeforeUpdate=="function"&&(n.effectTag|=256)):(typeof s.componentDidUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(n.effectTag|=4),typeof s.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(n.effectTag|=256),n.memoizedProps=r,n.memoizedState=k),s.props=r,s.state=k,s.context=g,r=C):(typeof s.componentDidUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(n.effectTag|=4),typeof s.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(n.effectTag|=256),r=!1);return A6(e,n,t,r,o,i)}function A6(e,n,t,r,i,o){mL(e,n);var s=(n.effectTag&64)!==0;if(!r&&!s)return i&&uI(n,t,!1),_p(e,n,o);r=n.stateNode,kq.current=n;var a=s&&typeof t.getDerivedStateFromError!="function"?null:r.render();return n.effectTag|=1,e!==null&&s?(n.child=xy(n,e.child,null,o),n.child=xy(n,null,a,o)):kc(e,n,a,o),n.memoizedState=r.state,i&&uI(n,t,!0),n.child}function MI(e){var n=e.stateNode;n.pendingContext?lI(e,n.pendingContext,n.pendingContext!==n.context):n.context&&lI(e,n.context,!1),o6(e,n.containerInfo)}var qw={dehydrated:null,retryTime:0};function SI(e,n,t){var r=n.mode,i=n.pendingProps,o=ol.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),ml(ol,o&1),e===null){if(i.fallback!==void 0&&l6(n),s){if(s=i.fallback,i=gm(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=gm(s,r,t,null),t.return=n,i.sibling=t,n.memoizedState=qw,n.child=i,t}return r=i.children,n.memoizedState=null,n.child=uB(n,null,r,t)}if(e.memoizedState!==null){if(e=e.child,r=e.sibling,s){if(i=i.fallback,t=a1(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=a1(r,i),r.return=n,t.sibling=r,t.childExpirationTime=0,n.memoizedState=qw,n.child=t,r}return t=xy(n,e.child,i.children,t),n.memoizedState=null,n.child=t}if(e=e.child,s){if(s=i.fallback,i=gm(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=gm(s,r,t,null),t.return=n,i.sibling=t,t.effectTag|=2,i.childExpirationTime=0,n.memoizedState=qw,n.child=i,t}return n.memoizedState=null,n.child=xy(n,e,i.children,t)}function EI(e,n){e.expirationTime<n&&(e.expirationTime=n);var t=e.alternate;t!==null&&t.expirationTime<n&&(t.expirationTime=n),iL(e.return,n)}function Hw(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 OI(e,n,t){var r=n.pendingProps,i=r.revealOrder,o=r.tail;if(kc(e,n,r.children,t),r=ol.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&&EI(e,t);else if(e.tag===19)EI(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(ml(ol,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&&Q2(e)===null&&(i=t),t=t.sibling;t=i,t===null?(i=n.child,n.child=null):(i=t.sibling,t.sibling=null),Hw(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&&Q2(e)===null){n.child=i;break}e=i.sibling,i.sibling=t,t=i,i=e}Hw(n,!0,t,null,o,n.lastEffect);break;case"together":Hw(n,!1,null,null,void 0,n.lastEffect);break;default:n.memoizedState=null}return n.child}function _p(e,n,t){e!==null&&(n.dependencies=e.dependencies);var r=n.expirationTime;if(r!==0&&N4(r),n.childExpirationTime<t)return null;if(e!==null&&n.child!==e.child)throw Error(Gn(153));if(n.child!==null){for(e=n.child,t=a1(e,e.pendingProps),n.child=t,t.return=n;e.sibling!==null;)e=e.sibling,t=t.sibling=a1(e,e.pendingProps),t.return=n;t.sibling=null}return n.child}var gL,c6,yL,vL;gL=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}};c6=function(){};yL=function(e,n,t,r,i){var o=e.memoizedProps;if(o!==r){var s=n.stateNode;switch(D0(hf.current),e=null,t){case"input":o=LS(s,o),r=LS(s,r),e=[];break;case"option":o=zS(s,o),r=zS(s,r),e=[];break;case"select":o=BA({},o,{value:void 0}),r=BA({},r,{value:void 0}),e=[];break;case"textarea":o=jS(s,o),r=jS(s,r),e=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(s.onclick=L2)}YS(t,r);var a,h;t=null;for(a in o)if(!r.hasOwnProperty(a)&&o.hasOwnProperty(a)&&o[a]!=null)if(a==="style")for(h in s=o[a],s)s.hasOwnProperty(h)&&(t||(t={}),t[h]="");else a!=="dangerouslySetInnerHTML"&&a!=="children"&&a!=="suppressContentEditableWarning"&&a!=="suppressHydrationWarning"&&a!=="autoFocus"&&(vy.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(h in s)!s.hasOwnProperty(h)||g&&g.hasOwnProperty(h)||(t||(t={}),t[h]="");for(h in g)g.hasOwnProperty(h)&&s[h]!==g[h]&&(t||(t={}),t[h]=g[h])}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"&&(vy.hasOwnProperty(a)?(g!=null&&rp(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)}};vL=function(e,n,t,r){t!==r&&(n.effectTag|=4)};function px(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 Iq(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 tc(n.type)&&z2(),null;case 3:return wy(),Os(ec),Os(oA),t=n.stateNode,t.pendingContext&&(t.context=t.pendingContext,t.pendingContext=null),e!==null&&e.child!==null||!fx(n)||(n.effectTag|=4),c6(n),null;case 5:AB(n),t=D0(X_.current);var i=n.type;if(e!==null&&n.stateNode!=null)yL(e,n,i,r,t),e.ref!==n.ref&&(n.effectTag|=128);else{if(!r){if(n.stateNode===null)throw Error(Gn(166));return null}if(e=D0(hf.current),fx(n)){r=n.stateNode,i=n.type;var o=n.memoizedProps;switch(r[hm]=n,r[U2]=o,i){case"iframe":case"object":case"embed":$s("load",r);break;case"video":case"audio":for(e=0;e<e_.length;e++)$s(e_[e],r);break;case"source":$s("error",r);break;case"img":case"image":case"link":$s("error",r),$s("load",r);break;case"form":$s("reset",r),$s("submit",r);break;case"details":$s("toggle",r);break;case"input":Rk(r,o),$s("invalid",r),rp(t,"onChange");break;case"select":r._wrapperState={wasMultiple:!!o.multiple},$s("invalid",r),rp(t,"onChange");break;case"textarea":jk(r,o),$s("invalid",r),rp(t,"onChange")}YS(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]):vy.hasOwnProperty(s)&&a!=null&&rp(t,s)}switch(i){case"input":sx(r),zk(r,o,!0);break;case"textarea":sx(r),Wk(r);break;case"select":case"option":break;default:typeof o.onClick=="function"&&(r.onclick=L2)}t=e,n.updateQueue=t,t!==null&&(n.effectTag|=4)}else{switch(s=t.nodeType===9?t:t.ownerDocument,e===qk&&(e=dD(i)),e===qk?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[hm]=n,e[U2]=r,gL(e,n,!1,!1),n.stateNode=e,s=qS(i,r),i){case"iframe":case"object":case"embed":$s("load",e),a=r;break;case"video":case"audio":for(a=0;a<e_.length;a++)$s(e_[a],e);a=r;break;case"source":$s("error",e),a=r;break;case"img":case"image":case"link":$s("error",e),$s("load",e),a=r;break;case"form":$s("reset",e),$s("submit",e),a=r;break;case"details":$s("toggle",e),a=r;break;case"input":Rk(e,r),a=LS(e,r),$s("invalid",e),rp(t,"onChange");break;case"option":a=zS(e,r);break;case"select":e._wrapperState={wasMultiple:!!r.multiple},a=BA({},r,{value:void 0}),$s("invalid",e),rp(t,"onChange");break;case"textarea":jk(e,r),a=jS(e,r),$s("invalid",e),rp(t,"onChange");break;default:a=r}YS(i,a);var h=a;for(o in h)if(h.hasOwnProperty(o)){var g=h[o];o==="style"?ID(e,g):o==="dangerouslySetInnerHTML"?(g=g?g.__html:void 0,g!=null&&hD(e,g)):o==="children"?typeof g=="string"?(i!=="textarea"||g!=="")&&Q_(e,g):typeof g=="number"&&Q_(e,""+g):o!=="suppressContentEditableWarning"&&o!=="suppressHydrationWarning"&&o!=="autoFocus"&&(vy.hasOwnProperty(o)?g!=null&&rp(t,o):g!=null&&zO(e,o,g,s))}switch(i){case"input":sx(e),zk(e,r,!1);break;case"textarea":sx(e),Wk(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Um(r.value));break;case"select":e.multiple=!!r.multiple,t=r.value,t!=null?Vg(e,!!r.multiple,t,!1):r.defaultValue!=null&&Vg(e,!!r.multiple,r.defaultValue,!0);break;default:typeof a.onClick=="function"&&(e.onclick=L2)}FD(i,r)&&(n.effectTag|=4)}n.ref!==null&&(n.effectTag|=128)}return null;case 6:if(e&&n.stateNode!=null)vL(e,n,e.memoizedProps,r);else{if(typeof r!="string"&&n.stateNode===null)throw Error(Gn(166));t=D0(X_.current),D0(hf.current),fx(n)?(t=n.stateNode,r=n.memoizedProps,t[hm]=n,t.nodeValue!==r&&(n.effectTag|=4)):(t=(t.nodeType===9?t:t.ownerDocument).createTextNode(r),t[hm]=n,n.stateNode=t)}return null;case 13:return Os(ol),r=n.memoizedState,n.effectTag&64?(n.expirationTime=t,n):(t=r!==null,r=!1,e===null?n.memoizedProps.fallback!==void 0&&fx(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||ol.current&1?fu===Y0&&(fu=X2):((fu===Y0||fu===X2)&&(fu=z4),eC!==0&&Lc!==null&&(R0(Lc,nc),RL(Lc,eC)))),(t||r)&&(n.effectTag|=4),null);case 4:return wy(),c6(n),null;case 10:return aB(n),null;case 17:return tc(n.type)&&z2(),null;case 19:if(Os(ol),r=n.memoizedState,r===null)return null;if(i=(n.effectTag&64)!==0,o=r.rendering,o===null){if(i)px(r,!1);else if(fu!==Y0||e!==null&&e.effectTag&64)for(o=n.child;o!==null;){if(e=Q2(o),e!==null){for(n.effectTag|=64,px(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 ml(ol,ol.current&1|2),n.child}o=o.sibling}}else{if(!i)if(e=Q2(o),e!==null){if(n.effectTag|=64,i=!0,t=e.updateQueue,t!==null&&(n.updateQueue=t,n.effectTag|=4),px(r,!0),r.tail===null&&r.tailMode==="hidden"&&!o.alternate)return n=n.lastEffect=r.lastEffect,n!==null&&(n.nextEffect=null),null}else 2*md()-r.renderingStartTime>r.tailExpiration&&1<t&&(n.effectTag|=64,i=!0,px(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=md()+500),t=r.tail,r.rendering=t,r.tail=t.sibling,r.lastEffect=n.lastEffect,r.renderingStartTime=md(),t.sibling=null,n=ol.current,ml(ol,i?n&1|2:n&1),t):null}throw Error(Gn(156,n.tag))}function Tq(e){switch(e.tag){case 1:tc(e.type)&&z2();var n=e.effectTag;return n&4096?(e.effectTag=n&-4097|64,e):null;case 3:if(wy(),Os(ec),Os(oA),n=e.effectTag,n&64)throw Error(Gn(285));return e.effectTag=n&-4097|64,e;case 5:return AB(e),null;case 13:return Os(ol),n=e.effectTag,n&4096?(e.effectTag=n&-4097|64,e):null;case 19:return Os(ol),null;case 4:return wy(),null;case 10:return aB(e),null;default:return null}}function gB(e,n){return{value:e,source:n,stack:NO(n)}}var Kq=typeof WeakSet=="function"?WeakSet:Set;function d6(e,n){var t=n.source,r=n.stack;r===null&&t!==null&&(r=NO(t)),t!==null&&Cp(t.type),n=n.value,e!==null&&e.tag===1&&Cp(e.type);try{console.error(n)}catch(i){setTimeout(function(){throw i})}}function Pq(e,n){try{n.props=e.memoizedProps,n.state=e.memoizedState,n.componentWillUnmount()}catch(t){H0(e,t)}}function BI(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 Fq(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:oh(n.type,t),r),e.__reactInternalSnapshotBeforeUpdate=n}return;case 3:case 5:case 6:case 4:case 17:return}throw Error(Gn(163))}function _L(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 CL(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 Dq(e,n,t){switch(t.tag){case 0:case 11:case 15:case 22:CL(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:oh(t.type,n.memoizedProps);e.componentDidUpdate(r,n.memoizedState,e.__reactInternalSnapshotBeforeUpdate)}n=t.updateQueue,n!==null&&fI(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}fI(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&&ED(t))));return;case 19:case 17:case 20:case 21:return}throw Error(Gn(163))}function kI(e,n,t){switch(typeof _6=="function"&&_6(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;zm(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:BI(n),t=n.stateNode,typeof t.componentWillUnmount=="function"&&Pq(n,t);break;case 5:BI(n);break;case 4:xL(e,n,t)}}function bL(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&&bL(n)}function II(e){return e.tag===5||e.tag===3||e.tag===4}function TI(e){e:{for(var n=e.return;n!==null;){if(II(n)){var t=n;break e}n=n.return}throw Error(Gn(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(Gn(161))}t.effectTag&16&&(Q_(n,""),t.effectTag&=-17);e:t:for(t=e;;){for(;t.sibling===null;){if(t.return===null||II(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?h6(e,t,n):f6(e,t,n)}function h6(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=L2));else if(r!==4&&(e=e.child,e!==null))for(h6(e,n,t),e=e.sibling;e!==null;)h6(e,n,t),e=e.sibling}function f6(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(f6(e,n,t),e=e.sibling;e!==null;)f6(e,n,t),e=e.sibling}function xL(e,n,t){for(var r=n,i=!1,o,s;;){if(!i){i=r.return;e:for(;;){if(i===null)throw Error(Gn(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,h=r,g=t,C=h;;)if(kI(a,C,g),C.child!==null&&C.tag!==4)C.child.return=C,C=C.child;else{if(C===h)break e;for(;C.sibling===null;){if(C.return===null||C.return===h)break e;C=C.return}C.sibling.return=C.return,C=C.sibling}s?(a=o,h=r.stateNode,a.nodeType===8?a.parentNode.removeChild(h):a.removeChild(h)):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(kI(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 Vw(e,n){switch(n.tag){case 0:case 11:case 14:case 15:case 22:_L(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[U2]=r,e==="input"&&r.type==="radio"&&r.name!=null&&uD(t,r),qS(e,i),n=qS(e,r),i=0;i<o.length;i+=2){var s=o[i],a=o[i+1];s==="style"?ID(t,a):s==="dangerouslySetInnerHTML"?hD(t,a):s==="children"?Q_(t,a):zO(t,s,a,n)}switch(e){case"input":US(t,r);break;case"textarea":AD(t,r);break;case"select":n=t._wrapperState.wasMultiple,t._wrapperState.wasMultiple=!!r.multiple,e=r.value,e!=null?Vg(t,!!r.multiple,e,!1):n!==!!r.multiple&&(r.defaultValue!=null?Vg(t,!!r.multiple,r.defaultValue,!0):Vg(t,!!r.multiple,r.multiple?[]:"",!1))}}}return;case 6:if(n.stateNode===null)throw Error(Gn(162));n.stateNode.nodeValue=n.memoizedProps;return;case 3:n=n.stateNode,n.hydrate&&(n.hydrate=!1,ED(n.containerInfo));return;case 12:return;case 13:if(t=n,n.memoizedState===null?r=!1:(r=!0,t=n.child,_B=md()),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=kD("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}KI(n);return;case 19:KI(n);return;case 17:return}throw Error(Gn(163))}function KI(e){var n=e.updateQueue;if(n!==null){e.updateQueue=null;var t=e.stateNode;t===null&&(t=e.stateNode=new Kq),n.forEach(function(r){var i=$q.bind(null,e,r);t.has(r)||(t.add(r),r.then(i,i))})}}var Lq=typeof WeakMap=="function"?WeakMap:Map;function wL(e,n,t){t=Om(t,null),t.tag=3,t.payload={element:null};var r=n.value;return t.callback=function(){t3||(t3=!0,p6=r),d6(e,n)},t}function ML(e,n,t){t=Om(t,null),t.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=n.value;t.payload=function(){return d6(e,n),r(i)}}var o=e.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(t.callback=function(){typeof r!="function"&&(km===null?km=new Set([this]):km.add(this),d6(e,n));var s=n.stack;this.componentDidCatch(n.value,{componentStack:s!==null?s:""})}),t}var Uq=Math.ceil,V2=uh.ReactCurrentDispatcher,SL=uh.ReactCurrentOwner,pu=0,yB=8,Ah=16,gf=32,Y0=0,Z2=1,EL=2,X2=3,z4=4,vB=5,Wi=pu,Lc=null,ro=null,nc=0,fu=Y0,j4=null,pp=1073741823,J_=1073741823,J2=null,eC=0,e3=!1,_B=0,OL=500,Vr=null,t3=!1,p6=null,km=null,n3=!1,w_=null,n_=90,L0=null,M_=0,m6=null,h2=0;function ff(){return(Wi&(Ah|gf))!==pu?1073741821-(md()/10|0):h2!==0?h2:h2=1073741821-(md()/10|0)}function q0(e,n,t){if(n=n.mode,!(n&2))return 1073741823;var r=U4();if(!(n&4))return r===99?1073741823:1073741822;if((Wi&Ah)!==pu)return nc;if(t!==null)e=c2(e,t.timeoutMs|0||5e3,250);else switch(r){case 99:e=1073741823;break;case 98:e=c2(e,150,100);break;case 97:case 96:e=c2(e,5e3,250);break;case 95:e=2;break;default:throw Error(Gn(326))}return Lc!==null&&e===nc&&--e,e}function Im(e,n){if(50<M_)throw M_=0,m6=null,Error(Gn(185));if(e=W4(e,n),e!==null){var t=U4();n===1073741823?(Wi&yB)!==pu&&(Wi&(Ah|gf))===pu?g6(e):(Uc(e),Wi===pu&&Mf()):Uc(e),(Wi&4)===pu||t!==98&&t!==99||(L0===null?L0=new Map([[e,n]]):(t=L0.get(e),(t===void 0||t>n)&&L0.set(e,n)))}}function W4(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&&(N4(n),fu===z4&&R0(i,nc)),RL(i,n)),i}function f2(e){var n=e.lastExpiredTime;if(n!==0||(n=e.firstPendingTime,!UL(e,n)))return n;var t=e.lastPingedTime;return e=e.nextKnownPendingLevel,e=t>e?t:e,2>=e&&n!==e?0:e}function Uc(e){if(e.lastExpiredTime!==0)e.callbackExpirationTime=1073741823,e.callbackPriority=99,e.callbackNode=dI(g6.bind(null,e));else{var n=f2(e),t=e.callbackNode;if(n===0)t!==null&&(e.callbackNode=null,e.callbackExpirationTime=0,e.callbackPriority=90);else{var r=ff();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!==eL&&HD(t)}e.callbackExpirationTime=n,e.callbackPriority=r,n=n===1073741823?dI(g6.bind(null,e)):nL(r,BL.bind(null,e),{timeout:10*(1073741821-n)-md()}),e.callbackNode=n}}}function BL(e,n){if(h2=0,n)return n=ff(),C6(e,n),Uc(e),null;var t=f2(e);if(t!==0){if(n=e.callbackNode,(Wi&(Ah|gf))!==pu)throw Error(Gn(327));if(Uy(),e===Lc&&t===nc||U0(e,t),ro!==null){var r=Wi;Wi|=Ah;var i=KL();do try{jq();break}catch(a){TL(e,a)}while(!0);if(oB(),Wi=r,V2.current=i,fu===Z2)throw n=j4,U0(e,t),R0(e,t),Uc(e),n;if(ro===null)switch(i=e.finishedWork=e.current.alternate,e.finishedExpirationTime=t,r=fu,Lc=null,r){case Y0:case Z2:throw Error(Gn(345));case EL:C6(e,2<t?2:t);break;case X2:if(R0(e,t),r=e.lastSuspendedTime,t===r&&(e.nextKnownPendingLevel=y6(i)),pp===1073741823&&(i=_B+OL-md(),10<i)){if(e3){var o=e.lastPingedTime;if(o===0||o>=t){e.lastPingedTime=t,U0(e,t);break}}if(o=f2(e),o!==0&&o!==t)break;if(r!==0&&r!==t){e.lastPingedTime=r;break}e.timeoutHandle=Gw(w0.bind(null,e),i);break}w0(e);break;case z4:if(R0(e,t),r=e.lastSuspendedTime,t===r&&(e.nextKnownPendingLevel=y6(i)),e3&&(i=e.lastPingedTime,i===0||i>=t)){e.lastPingedTime=t,U0(e,t);break}if(i=f2(e),i!==0&&i!==t)break;if(r!==0&&r!==t){e.lastPingedTime=r;break}if(J_!==1073741823?r=10*(1073741821-J_)-md():pp===1073741823?r=0:(r=10*(1073741821-pp)-5e3,i=md(),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*Uq(r/1960))-r,t<r&&(r=t)),10<r){e.timeoutHandle=Gw(w0.bind(null,e),r);break}w0(e);break;case vB:if(pp!==1073741823&&J2!==null){o=pp;var s=J2;if(r=s.busyMinDurationMs|0,0>=r?r=0:(i=s.busyDelayMs|0,o=md()-(10*(1073741821-o)-(s.timeoutMs|0||5e3)),r=o<=i?0:i+r-o),10<r){R0(e,t),e.timeoutHandle=Gw(w0.bind(null,e),r);break}}w0(e);break;default:throw Error(Gn(329))}if(Uc(e),e.callbackNode===n)return BL.bind(null,e)}}return null}function g6(e){var n=e.lastExpiredTime;if(n=n!==0?n:1073741823,(Wi&(Ah|gf))!==pu)throw Error(Gn(327));if(Uy(),e===Lc&&n===nc||U0(e,n),ro!==null){var t=Wi;Wi|=Ah;var r=KL();do try{zq();break}catch(i){TL(e,i)}while(!0);if(oB(),Wi=t,V2.current=r,fu===Z2)throw t=j4,U0(e,n),R0(e,n),Uc(e),t;if(ro!==null)throw Error(Gn(261));e.finishedWork=e.current.alternate,e.finishedExpirationTime=n,Lc=null,w0(e),Uc(e)}return null}function Rq(){if(L0!==null){var e=L0;L0=null,e.forEach(function(n,t){C6(t,n),Uc(t)}),Mf()}}function kL(e,n){var t=Wi;Wi|=1;try{return e(n)}finally{Wi=t,Wi===pu&&Mf()}}function IL(e,n){var t=Wi;Wi&=-2,Wi|=yB;try{return e(n)}finally{Wi=t,Wi===pu&&Mf()}}function U0(e,n){e.finishedWork=null,e.finishedExpirationTime=0;var t=e.timeoutHandle;if(t!==-1&&(e.timeoutHandle=-1,UY(t)),ro!==null)for(t=ro.return;t!==null;){var r=t;switch(r.tag){case 1:r=r.type.childContextTypes,r!=null&&z2();break;case 3:wy(),Os(ec),Os(oA);break;case 5:AB(r);break;case 4:wy();break;case 13:Os(ol);break;case 19:Os(ol);break;case 10:aB(r)}t=t.return}Lc=e,ro=a1(e.current,null),nc=n,fu=Y0,j4=null,J_=pp=1073741823,J2=null,eC=0,e3=!1}function TL(e,n){do{try{if(oB(),d2.current=H2,$2)for(var t=Hl.memoizedState;t!==null;){var r=t.queue;r!==null&&(r.pending=null),t=t.next}if(pm=0,iA=rA=Hl=null,$2=!1,ro===null||ro.return===null)return fu=Z2,j4=n,ro=null;e:{var i=e,o=ro.return,s=ro,a=n;if(n=nc,s.effectTag|=2048,s.firstEffect=s.lastEffect=null,a!==null&&typeof a=="object"&&typeof a.then=="function"){var h=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 C=(ol.current&1)!==0,B=o;do{var k;if(k=B.tag===13){var P=B.memoizedState;if(P!==null)k=P.dehydrated!==null;else{var L=B.memoizedProps;k=L.fallback===void 0?!1:L.unstable_avoidThisFallback!==!0?!0:!C}}if(k){var J=B.updateQueue;if(J===null){var N=new Set;N.add(h),B.updateQueue=N}else J.add(h);if(!(B.mode&2)){if(B.effectTag|=64,s.effectTag&=-2981,s.tag===1)if(s.alternate===null)s.tag=17;else{var $=Om(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 Lq,a=new Set,q.set(h,a)):(a=q.get(h),a===void 0&&(a=new Set,q.set(h,a))),!a.has(s)){a.add(s);var oe=Qq.bind(null,i,h,s);h.then(oe,oe)}B.effectTag|=4096,B.expirationTime=n;break e}B=B.return}while(B!==null);a=Error((Cp(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.`+NO(s))}fu!==vB&&(fu=EL),a=gB(a,s),B=o;do{switch(B.tag){case 3:h=a,B.effectTag|=4096,B.expirationTime=n;var ce=wL(B,h,n);hI(B,ce);break e;case 1:h=a;var me=B.type,he=B.stateNode;if(!(B.effectTag&64)&&(typeof me.getDerivedStateFromError=="function"||he!==null&&typeof he.componentDidCatch=="function"&&(km===null||!km.has(he)))){B.effectTag|=4096,B.expirationTime=n;var V=ML(B,h,n);hI(B,V);break e}}B=B.return}while(B!==null)}ro=DL(ro)}catch(ae){n=ae;continue}break}while(!0)}function KL(){var e=V2.current;return V2.current=H2,e===null?H2:e}function PL(e,n){e<pp&&2<e&&(pp=e),n!==null&&e<J_&&2<e&&(J_=e,J2=n)}function N4(e){e>eC&&(eC=e)}function zq(){for(;ro!==null;)ro=FL(ro)}function jq(){for(;ro!==null&&!Mq();)ro=FL(ro)}function FL(e){var n=LL(e.alternate,e,nc);return e.memoizedProps=e.pendingProps,n===null&&(n=DL(e)),SL.current=null,n}function DL(e){ro=e;do{var n=ro.alternate;if(e=ro.return,ro.effectTag&2048){if(n=Tq(ro),n!==null)return n.effectTag&=2047,n;e!==null&&(e.firstEffect=e.lastEffect=null,e.effectTag|=2048)}else{if(n=Iq(n,ro,nc),nc===1||ro.childExpirationTime!==1){for(var t=0,r=ro.child;r!==null;){var i=r.expirationTime,o=r.childExpirationTime;i>t&&(t=i),o>t&&(t=o),r=r.sibling}ro.childExpirationTime=t}if(n!==null)return n;e!==null&&!(e.effectTag&2048)&&(e.firstEffect===null&&(e.firstEffect=ro.firstEffect),ro.lastEffect!==null&&(e.lastEffect!==null&&(e.lastEffect.nextEffect=ro.firstEffect),e.lastEffect=ro.lastEffect),1<ro.effectTag&&(e.lastEffect!==null?e.lastEffect.nextEffect=ro:e.firstEffect=ro,e.lastEffect=ro))}if(n=ro.sibling,n!==null)return n;ro=e}while(ro!==null);return fu===Y0&&(fu=vB),null}function y6(e){var n=e.expirationTime;return e=e.childExpirationTime,n>e?n:e}function w0(e){var n=U4();return zm(99,Wq.bind(null,e,n)),null}function Wq(e,n){do Uy();while(w_!==null);if((Wi&(Ah|gf))!==pu)throw Error(Gn(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(Gn(177));e.callbackNode=null,e.callbackExpirationTime=0,e.callbackPriority=90,e.nextKnownPendingLevel=0;var i=y6(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&&(ro=Lc=null,nc=0),1<t.effectTag?t.lastEffect!==null?(t.lastEffect.nextEffect=t,i=t.firstEffect):i=t:i=t.firstEffect,i!==null){var o=Wi;Wi|=gf,SL.current=null,Ww=o2;var s=Zk();if(VS(s)){if("selectionStart"in s)var a={start:s.selectionStart,end:s.selectionEnd};else e:{a=(a=s.ownerDocument)&&a.defaultView||window;var h=a.getSelection&&a.getSelection();if(h&&h.rangeCount!==0){a=h.anchorNode;var g=h.anchorOffset,C=h.focusNode;h=h.focusOffset;try{a.nodeType,C.nodeType}catch{a=null;break e}var B=0,k=-1,P=-1,L=0,J=0,N=s,$=null;t:for(;;){for(var q;N!==a||g!==0&&N.nodeType!==3||(k=B+g),N!==C||h!==0&&N.nodeType!==3||(P=B+h),N.nodeType===3&&(B+=N.nodeValue.length),(q=N.firstChild)!==null;)$=N,N=q;for(;;){if(N===s)break t;if($===a&&++L===g&&(k=B),$===C&&++J===h&&(P=B),(q=N.nextSibling)!==null)break;N=$,$=N.parentNode}N=q}a=k===-1||P===-1?null:{start:k,end:P}}else a=null}a=a||{start:0,end:0}}else a=null;Nw={activeElementDetached:null,focusedElem:s,selectionRange:a},o2=!1,Vr=i;do try{Nq()}catch(ye){if(Vr===null)throw Error(Gn(330));H0(Vr,ye),Vr=Vr.nextEffect}while(Vr!==null);Vr=i;do try{for(s=e,a=n;Vr!==null;){var oe=Vr.effectTag;if(oe&16&&Q_(Vr.stateNode,""),oe&128){var ce=Vr.alternate;if(ce!==null){var me=ce.ref;me!==null&&(typeof me=="function"?me(null):me.current=null)}}switch(oe&1038){case 2:TI(Vr),Vr.effectTag&=-3;break;case 6:TI(Vr),Vr.effectTag&=-3,Vw(Vr.alternate,Vr);break;case 1024:Vr.effectTag&=-1025;break;case 1028:Vr.effectTag&=-1025,Vw(Vr.alternate,Vr);break;case 4:Vw(Vr.alternate,Vr);break;case 8:g=Vr,xL(s,g,a),bL(g)}Vr=Vr.nextEffect}}catch(ye){if(Vr===null)throw Error(Gn(330));H0(Vr,ye),Vr=Vr.nextEffect}while(Vr!==null);if(me=Nw,ce=Zk(),oe=me.focusedElem,a=me.selectionRange,ce!==oe&&oe&&oe.ownerDocument&&TD(oe.ownerDocument.documentElement,oe)){for(a!==null&&VS(oe)&&(ce=a.start,me=a.end,me===void 0&&(me=ce),"selectionStart"in oe?(oe.selectionStart=ce,oe.selectionEnd=Math.min(me,oe.value.length)):(me=(ce=oe.ownerDocument||document)&&ce.defaultView||window,me.getSelection&&(me=me.getSelection(),g=oe.textContent.length,s=Math.min(a.start,g),a=a.end===void 0?s:Math.min(a.end,g),!me.extend&&s>a&&(g=a,a=s,s=g),g=Vk(oe,s),C=Vk(oe,a),g&&C&&(me.rangeCount!==1||me.anchorNode!==g.node||me.anchorOffset!==g.offset||me.focusNode!==C.node||me.focusOffset!==C.offset)&&(ce=ce.createRange(),ce.setStart(g.node,g.offset),me.removeAllRanges(),s>a?(me.addRange(ce),me.extend(C.node,C.offset)):(ce.setEnd(C.node,C.offset),me.addRange(ce)))))),ce=[],me=oe;me=me.parentNode;)me.nodeType===1&&ce.push({element:me,left:me.scrollLeft,top:me.scrollTop});for(typeof oe.focus=="function"&&oe.focus(),oe=0;oe<ce.length;oe++)me=ce[oe],me.element.scrollLeft=me.left,me.element.scrollTop=me.top}o2=!!Ww,Nw=Ww=null,e.current=t,Vr=i;do try{for(oe=e;Vr!==null;){var he=Vr.effectTag;if(he&36&&Dq(oe,Vr.alternate,Vr),he&128){ce=void 0;var V=Vr.ref;if(V!==null){var ae=Vr.stateNode;switch(Vr.tag){case 5:ce=ae;break;default:ce=ae}typeof V=="function"?V(ce):V.current=ce}}Vr=Vr.nextEffect}}catch(ye){if(Vr===null)throw Error(Gn(330));H0(Vr,ye),Vr=Vr.nextEffect}while(Vr!==null);Vr=null,Sq(),Wi=o}else e.current=t;if(n3)n3=!1,w_=e,n_=n;else for(Vr=i;Vr!==null;)n=Vr.nextEffect,Vr.nextEffect=null,Vr=n;if(n=e.firstPendingTime,n===0&&(km=null),n===1073741823?e===m6?M_++:(M_=0,m6=e):M_=0,typeof v6=="function"&&v6(t.stateNode,r),Uc(e),t3)throw t3=!1,e=p6,p6=null,e;return(Wi&yB)!==pu||Mf(),null}function Nq(){for(;Vr!==null;){var e=Vr.effectTag;e&256&&Fq(Vr.alternate,Vr),!(e&512)||n3||(n3=!0,nL(97,function(){return Uy(),null})),Vr=Vr.nextEffect}}function Uy(){if(n_!==90){var e=97<n_?97:n_;return n_=90,zm(e,Gq)}}function Gq(){if(w_===null)return!1;var e=w_;if(w_=null,(Wi&(Ah|gf))!==pu)throw Error(Gn(331));var n=Wi;for(Wi|=gf,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:_L(5,t),CL(5,t)}}catch(r){if(e===null)throw Error(Gn(330));H0(e,r)}t=e.nextEffect,e.nextEffect=null,e=t}return Wi=n,Mf(),!0}function PI(e,n,t){n=gB(t,n),n=wL(e,n,1073741823),Bm(e,n),e=W4(e,1073741823),e!==null&&Uc(e)}function H0(e,n){if(e.tag===3)PI(e,e,n);else for(var t=e.return;t!==null;){if(t.tag===3){PI(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(km===null||!km.has(r))){e=gB(n,e),e=ML(t,e,1073741823),Bm(t,e),t=W4(t,1073741823),t!==null&&Uc(t);break}}t=t.return}}function Qq(e,n,t){var r=e.pingCache;r!==null&&r.delete(n),Lc===e&&nc===t?fu===z4||fu===X2&&pp===1073741823&&md()-_B<OL?U0(e,nc):e3=!0:UL(e,t)&&(n=e.lastPingedTime,n!==0&&n<t||(e.lastPingedTime=t,Uc(e)))}function $q(e,n){var t=e.stateNode;t!==null&&t.delete(n),n=0,n===0&&(n=ff(),n=q0(n,e,null)),e=W4(e,n),e!==null&&Uc(e)}var LL;LL=function(e,n,t){var r=n.expirationTime;if(e!==null){var i=n.pendingProps;if(e.memoizedProps!==i||ec.current)uf=!0;else{if(r<t){switch(uf=!1,n.tag){case 3:MI(n),Yw();break;case 5:if(gI(n),n.mode&4&&t!==1&&i.hidden)return n.expirationTime=n.childExpirationTime=1,null;break;case 1:tc(n.type)&&u2(n);break;case 4:o6(n,n.stateNode.containerInfo);break;case 10:r=n.memoizedProps.value,i=n.type._context,ml(j2,i._currentValue),i._currentValue=r;break;case 13:if(n.memoizedState!==null)return r=n.child.childExpirationTime,r!==0&&r>=t?SI(e,n,t):(ml(ol,ol.current&1),n=_p(e,n,t),n!==null?n.sibling:null);ml(ol,ol.current&1);break;case 19:if(r=n.childExpirationTime>=t,e.effectTag&64){if(r)return OI(e,n,t);n.effectTag|=64}if(i=n.memoizedState,i!==null&&(i.rendering=null,i.tail=null),ml(ol,ol.current),!r)return null}return _p(e,n,t)}uf=!1}}else uf=!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=by(n,oA.current),Xg(n,t),i=hB(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,tc(r)){var o=!0;u2(n)}else o=!1;n.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,sB(n);var s=r.getDerivedStateFromProps;typeof s=="function"&&G2(n,r,s,e),i.updater=R4,n.stateNode=i,i._reactInternalFiber=n,i6(n,r,e,t),n=A6(null,n,r,!0,o,t)}else n.tag=0,kc(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,CY(i),i._status!==1)throw i._result;switch(i=i._result,n.type=i,o=n.tag=Hq(i),e=oh(i,e),o){case 0:n=u6(null,n,i,e,t);break e;case 1:n=wI(null,n,i,e,t);break e;case 11:n=bI(null,n,i,e,t);break e;case 14:n=xI(null,n,i,oh(i.type,e),r,t);break e}throw Error(Gn(306,i,""))}return n;case 0:return r=n.type,i=n.pendingProps,i=n.elementType===r?i:oh(r,i),u6(e,n,r,i,t);case 1:return r=n.type,i=n.pendingProps,i=n.elementType===r?i:oh(r,i),wI(e,n,r,i,t);case 3:if(MI(n),r=n.updateQueue,e===null||r===null)throw Error(Gn(282));if(r=n.pendingProps,i=n.memoizedState,i=i!==null?i.element:null,lB(e,n),V_(n,r,null,t),r=n.memoizedState.element,r===i)Yw(),n=_p(e,n,t);else{if((i=n.stateNode.hydrate)&&(mm=Zg(n.stateNode.containerInfo.firstChild),vp=n,i=$0=!0),i)for(t=uB(n,null,r,t),n.child=t;t;)t.effectTag=t.effectTag&-3|1024,t=t.sibling;else kc(e,n,r,t),Yw();n=n.child}return n;case 5:return gI(n),e===null&&l6(n),r=n.type,i=n.pendingProps,o=e!==null?e.memoizedProps:null,s=i.children,ZS(r,i)?s=null:o!==null&&ZS(r,o)&&(n.effectTag|=16),mL(e,n),n.mode&4&&t!==1&&i.hidden?(n.expirationTime=n.childExpirationTime=1,n=null):(kc(e,n,s,t),n=n.child),n;case 6:return e===null&&l6(n),null;case 13:return SI(e,n,t);case 4:return o6(n,n.stateNode.containerInfo),r=n.pendingProps,e===null?n.child=xy(n,null,r,t):kc(e,n,r,t),n.child;case 11:return r=n.type,i=n.pendingProps,i=n.elementType===r?i:oh(r,i),bI(e,n,r,i,t);case 7:return kc(e,n,n.pendingProps,t),n.child;case 8:return kc(e,n,n.pendingProps.children,t),n.child;case 12:return kc(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(ml(j2,a._currentValue),a._currentValue=o,s!==null)if(a=s.value,o=i1(a,o)?0:(typeof r._calculateChangedBits=="function"?r._calculateChangedBits(a,o):1073741823)|0,o===0){if(s.children===i.children&&!ec.current){n=_p(e,n,t);break e}}else for(a=n.child,a!==null&&(a.return=n);a!==null;){var h=a.dependencies;if(h!==null){s=a.child;for(var g=h.firstContext;g!==null;){if(g.context===r&&g.observedBits&o){a.tag===1&&(g=Om(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),iL(a.return,t),h.expirationTime<t&&(h.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}kc(e,n,i.children,t),n=n.child}return n;case 9:return i=n.type,o=n.pendingProps,r=o.children,Xg(n,t),i=bd(i,o.unstable_observedBits),r=r(i),n.effectTag|=1,kc(e,n,r,t),n.child;case 14:return i=n.type,o=oh(i,n.pendingProps),o=oh(i.type,o),xI(e,n,i,o,r,t);case 15:return pL(e,n,n.type,n.pendingProps,r,t);case 17:return r=n.type,i=n.pendingProps,i=n.elementType===r?i:oh(r,i),e!==null&&(e.alternate=null,n.alternate=null,n.effectTag|=2),n.tag=1,tc(r)?(e=!0,u2(n)):e=!1,Xg(n,t),aL(n,r,i),i6(n,r,i,t),A6(null,n,r,!0,e,t);case 19:return OI(e,n,t)}throw Error(Gn(156,n.tag))};var v6=null,_6=null;function Yq(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);v6=function(r){try{n.onCommitFiberRoot(t,r,void 0,(r.current.effectTag&64)===64)}catch{}},_6=function(r){try{n.onCommitFiberUnmount(t,r)}catch{}}}catch{}return!0}function qq(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 Af(e,n,t,r){return new qq(e,n,t,r)}function CB(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Hq(e){if(typeof e=="function")return CB(e)?1:0;if(e!=null){if(e=e.$$typeof,e===jO)return 11;if(e===WO)return 14}return 2}function a1(e,n){var t=e.alternate;return t===null?(t=Af(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 p2(e,n,t,r,i,o){var s=2;if(r=e,typeof e=="function")CB(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case B0:return gm(t.children,i,o,n);case _Y:s=8,i|=7;break;case nD:s=8,i|=1;break;case n2:return e=Af(12,t,n,i|8),e.elementType=n2,e.type=n2,e.expirationTime=o,e;case r2:return e=Af(13,t,n,i),e.type=r2,e.elementType=r2,e.expirationTime=o,e;case DS:return e=Af(19,t,n,i),e.elementType=DS,e.expirationTime=o,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case rD:s=10;break e;case iD:s=9;break e;case jO:s=11;break e;case WO:s=14;break e;case oD:s=16,r=null;break e;case aD:s=22;break e}throw Error(Gn(130,e==null?e:typeof e,""))}return n=Af(s,t,n,i),n.elementType=e,n.type=r,n.expirationTime=o,n}function gm(e,n,t,r){return e=Af(7,e,r,n),e.expirationTime=t,e}function Zw(e,n,t){return e=Af(6,e,null,n),e.expirationTime=t,e}function Xw(e,n,t){return n=Af(4,e.children!==null?e.children:[],e.key,n),n.expirationTime=t,n.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},n}function Vq(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 UL(e,n){var t=e.firstSuspendedTime;return e=e.lastSuspendedTime,t!==0&&t>=n&&e<=n}function R0(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 RL(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 C6(e,n){var t=e.lastExpiredTime;(t===0||t>n)&&(e.lastExpiredTime=n)}function r3(e,n,t,r){var i=n.current,o=ff(),s=x_.suspense;o=q0(o,i,s);e:if(t){t=t._reactInternalFiber;t:{if(g1(t)!==t||t.tag!==1)throw Error(Gn(170));var a=t;do{switch(a.tag){case 3:a=a.stateNode.context;break t;case 1:if(tc(a.type)){a=a.stateNode.__reactInternalMemoizedMergedChildContext;break t}}a=a.return}while(a!==null);throw Error(Gn(171))}if(t.tag===1){var h=t.type;if(tc(h)){t=qD(t,h,a);break e}}t=a}else t=Rm;return n.context===null?n.context=t:n.pendingContext=t,n=Om(o,s),n.payload={element:e},r=r===void 0?null:r,r!==null&&(n.callback=r),Bm(i,n),Im(i,o),o}function Jw(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 FI(e,n){e=e.memoizedState,e!==null&&e.dehydrated!==null&&e.retryTime<n&&(e.retryTime=n)}function bB(e,n){FI(e,n),(e=e.alternate)&&FI(e,n)}function xB(e,n,t){t=t!=null&&t.hydrate===!0;var r=new Vq(e,n,t),i=Af(3,null,null,n===2?7:n===1?3:0);r.current=i,i.stateNode=r,sB(i),e[KC]=r.current,t&&n!==0&&EY(e,e.nodeType===9?e:e.ownerDocument),this._internalRoot=r}xB.prototype.render=function(e){r3(e,this._internalRoot,null,null)};xB.prototype.unmount=function(){var e=this._internalRoot,n=e.containerInfo;r3(null,e,null,function(){n[KC]=null})};function RC(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function Zq(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 xB(e,0,n?{hydrate:!0}:void 0)}function G4(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=Jw(s);a.call(g)}}r3(n,s,e,i)}else{if(o=t._reactRootContainer=Zq(t,r),s=o._internalRoot,typeof i=="function"){var h=i;i=function(){var g=Jw(s);h.call(g)}}IL(function(){r3(n,s,e,i)})}return Jw(s)}function Xq(e,n,t){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Tg,key:r==null?null:""+r,children:e,containerInfo:n,implementation:t}}MD=function(e){if(e.tag===13){var n=c2(ff(),150,100);Im(e,n),bB(e,n)}};YO=function(e){e.tag===13&&(Im(e,3),bB(e,3))};SD=function(e){if(e.tag===13){var n=ff();n=q0(n,e,null),Im(e,n),bB(e,n)}};FS=function(e,n,t){switch(n){case"input":if(US(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=eB(r);if(!i)throw Error(Gn(90));lD(r),US(r,i)}}}break;case"textarea":AD(e,t);break;case"select":n=t.value,n!=null&&Vg(e,!!t.multiple,n,!1)}};FO=kL;JF=function(e,n,t,r,i){var o=Wi;Wi|=4;try{return zm(98,e.bind(null,n,t,r,i))}finally{Wi=o,Wi===pu&&Mf()}};DO=function(){(Wi&(1|Ah|gf))===pu&&(Rq(),Uy())};eD=function(e,n){var t=Wi;Wi|=2;try{return e(n)}finally{Wi=t,Wi===pu&&Mf()}};function zL(e,n){var t=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!RC(n))throw Error(Gn(200));return Xq(e,n,null,t)}var Jq={Events:[FC,r1,eB,VF,PS,Cy,function(e){QO(e,zY)},ZF,XF,F4,P4,Uy,{current:!1}]};(function(e){var n=e.findFiberByHostInstance;return Yq(BA({},e,{overrideHookState:null,overrideProps:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:uh.ReactCurrentDispatcher,findHostInstanceByFiber:function(t){return t=_D(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:PC,bundleType:0,version:"16.14.0",rendererPackageName:"react-dom"});Md.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Jq;Md.createPortal=zL;Md.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(Gn(188)):Error(Gn(268,Object.keys(e)));return e=_D(n),e=e===null?null:e.stateNode,e};Md.flushSync=function(e,n){if((Wi&(Ah|gf))!==pu)throw Error(Gn(187));var t=Wi;Wi|=1;try{return zm(99,e.bind(null,n))}finally{Wi=t,Mf()}};Md.hydrate=function(e,n,t){if(!RC(n))throw Error(Gn(200));return G4(null,e,n,!0,t)};Md.render=function(e,n,t){if(!RC(n))throw Error(Gn(200));return G4(null,e,n,!1,t)};Md.unmountComponentAtNode=function(e){if(!RC(e))throw Error(Gn(40));return e._reactRootContainer?(IL(function(){G4(null,null,e,!1,function(){e._reactRootContainer=null,e[KC]=null})}),!0):!1};Md.unstable_batchedUpdates=kL;Md.unstable_createPortal=function(e,n){return zL(e,n,2<arguments.length&&arguments[2]!==void 0?arguments[2]:null)};Md.unstable_renderSubtreeIntoContainer=function(e,n,t,r){if(!RC(t))throw Error(Gn(200));if(e==null||e._reactInternalFiber===void 0)throw Error(Gn(38));return G4(e,n,t,!1,r)};Md.version="16.14.0";function jL(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(jL)}catch(e){console.error(e)}}jL(),GF.exports=Md;var Qm=GF.exports;const WL=fa(Qm);var b6={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(h){var g=Object.getOwnPropertyDescriptor(a,h);if(g===void 0){console.warn('Autobind: "'+h+'" method not found in class.');return}t.indexOf(h)!==-1||typeof g.value!="function"||Object.defineProperty(a,h,o(a,h,g))})}function o(s,a,h){var g=h.value;return{configurable:!0,get:function(){if(this===s||this.hasOwnProperty(a))return g;var B=g.bind(this);return Object.defineProperty(this,a,{value:B,configurable:!0,writable:!0}),B}}}e.exports=n.default})(b6,b6.exports);var eH=b6.exports,tH=eH;const nH=fa(tH);var i3={exports:{}};i3.exports;(function(e,n){var t=200,r="__lodash_hash_undefined__",i=9007199254740991,o="[object Arguments]",s="[object Array]",a="[object Boolean]",h="[object Date]",g="[object Error]",C="[object Function]",B="[object GeneratorFunction]",k="[object Map]",P="[object Number]",L="[object Object]",J="[object Promise]",N="[object RegExp]",$="[object Set]",q="[object String]",oe="[object Symbol]",ce="[object WeakMap]",me="[object ArrayBuffer]",he="[object DataView]",V="[object Float32Array]",ae="[object Float64Array]",ye="[object Int8Array]",Oe="[object Int16Array]",De="[object Int32Array]",He="[object Uint8Array]",ke="[object Uint8ClampedArray]",nt="[object Uint16Array]",be="[object Uint32Array]",Bt=/[\\^$.*+?()[\]{}|]/g,kt=/\w*$/,Yt=/^\[object .+?Constructor\]$/,jt=/^(?:0|[1-9]\d*)$/,Xe={};Xe[o]=Xe[s]=Xe[me]=Xe[he]=Xe[a]=Xe[h]=Xe[V]=Xe[ae]=Xe[ye]=Xe[Oe]=Xe[De]=Xe[k]=Xe[P]=Xe[L]=Xe[N]=Xe[$]=Xe[q]=Xe[oe]=Xe[He]=Xe[ke]=Xe[nt]=Xe[be]=!0,Xe[g]=Xe[C]=Xe[ce]=!1;var rt=typeof window=="object"&&window&&window.Object===Object&&window,ot=typeof self=="object"&&self&&self.Object===Object&&self,on=rt||ot||Function("return this")(),gt=n&&!n.nodeType&&n,at=gt&&!0&&e&&!e.nodeType&&e,It=at&&at.exports===gt;function Lt(R,se){return R.set(se[0],se[1]),R}function Me(R,se){return R.add(se),R}function fe(R,se){for(var Le=-1,mt=R?R.length:0;++Le<mt&&se(R[Le],Le,R)!==!1;);return R}function xe(R,se){for(var Le=-1,mt=se.length,Dn=R.length;++Le<mt;)R[Dn+Le]=se[Le];return R}function Ue(R,se,Le,mt){var Dn=-1,en=R?R.length:0;for(mt&&en&&(Le=R[++Dn]);++Dn<en;)Le=se(Le,R[Dn],Dn,R);return Le}function et(R,se){for(var Le=-1,mt=Array(R);++Le<R;)mt[Le]=se(Le);return mt}function it(R,se){return R==null?void 0:R[se]}function bt(R){var se=!1;if(R!=null&&typeof R.toString!="function")try{se=!!(R+"")}catch{}return se}function Ut(R){var se=-1,Le=Array(R.size);return R.forEach(function(mt,Dn){Le[++se]=[Dn,mt]}),Le}function Rt(R,se){return function(Le){return R(se(Le))}}function pt(R){var se=-1,Le=Array(R.size);return R.forEach(function(mt){Le[++se]=mt}),Le}var rr=Array.prototype,mn=Function.prototype,vn=Object.prototype,Xn=on["__core-js_shared__"],cr=function(){var R=/[^.]+$/.exec(Xn&&Xn.keys&&Xn.keys.IE_PROTO||"");return R?"Symbol(src)_1."+R:""}(),Mr=mn.toString,Gr=vn.hasOwnProperty,gr=vn.toString,mi=RegExp("^"+Mr.call(Gr).replace(Bt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Se=It?on.Buffer:void 0,X=on.Symbol,H=on.Uint8Array,Te=Rt(Object.getPrototypeOf,Object),At=Object.create,St=vn.propertyIsEnumerable,Et=rr.splice,Nt=Object.getOwnPropertySymbols,pn=Se?Se.isBuffer:void 0,Kn=Rt(Object.keys,Object),En=ia(on,"DataView"),m=ia(on,"Map"),Kt=ia(on,"Promise"),Dr=ia(on,"Set"),Fn=ia(on,"WeakMap"),Fe=ia(Object,"create"),de=Wo(En),Ce=Wo(m),Be=Wo(Kt),ze=Wo(Dr),tt=Wo(Fn),lt=X?X.prototype:void 0,ft=lt?lt.valueOf:void 0;function Ve(R){var se=-1,Le=R?R.length:0;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function xt(){this.__data__=Fe?Fe(null):{}}function Xt(R){return this.has(R)&&delete this.__data__[R]}function Vt(R){var se=this.__data__;if(Fe){var Le=se[R];return Le===r?void 0:Le}return Gr.call(se,R)?se[R]:void 0}function Ht(R){var se=this.__data__;return Fe?se[R]!==void 0:Gr.call(se,R)}function Qn(R,se){var Le=this.__data__;return Le[R]=Fe&&se===void 0?r:se,this}Ve.prototype.clear=xt,Ve.prototype.delete=Xt,Ve.prototype.get=Vt,Ve.prototype.has=Ht,Ve.prototype.set=Qn;function Mn(R){var se=-1,Le=R?R.length:0;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function or(){this.__data__=[]}function ar(R){var se=this.__data__,Le=eo(se,R);if(Le<0)return!1;var mt=se.length-1;return Le==mt?se.pop():Et.call(se,Le,1),!0}function kr(R){var se=this.__data__,Le=eo(se,R);return Le<0?void 0:se[Le][1]}function jr(R){return eo(this.__data__,R)>-1}function Lr(R,se){var Le=this.__data__,mt=eo(Le,R);return mt<0?Le.push([R,se]):Le[mt][1]=se,this}Mn.prototype.clear=or,Mn.prototype.delete=ar,Mn.prototype.get=kr,Mn.prototype.has=jr,Mn.prototype.set=Lr;function Wr(R){var se=-1,Le=R?R.length:0;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function ir(){this.__data__={hash:new Ve,map:new(m||Mn),string:new Ve}}function ui(R){return as(this,R).delete(R)}function Oi(R){return as(this,R).get(R)}function Yi(R){return as(this,R).has(R)}function _o(R,se){return as(this,R).set(R,se),this}Wr.prototype.clear=ir,Wr.prototype.delete=ui,Wr.prototype.get=Oi,Wr.prototype.has=Yi,Wr.prototype.set=_o;function Jr(R){this.__data__=new Mn(R)}function xo(){this.__data__=new Mn}function Wa(R){return this.__data__.delete(R)}function Ba(R){return this.__data__.get(R)}function bi(R){return this.__data__.has(R)}function os(R,se){var Le=this.__data__;if(Le instanceof Mn){var mt=Le.__data__;if(!m||mt.length<t-1)return mt.push([R,se]),this;Le=this.__data__=new Wr(mt)}return Le.set(R,se),this}Jr.prototype.clear=xo,Jr.prototype.delete=Wa,Jr.prototype.get=Ba,Jr.prototype.has=bi,Jr.prototype.set=os;function hi(R,se){var Le=ll(R)||ss(R)?et(R.length,String):[],mt=Le.length,Dn=!!mt;for(var en in R)(se||Gr.call(R,en))&&!(Dn&&(en=="length"||Du(en,mt)))&&Le.push(en);return Le}function Wn(R,se,Le){var mt=R[se];(!(Gr.call(R,se)&&Uu(mt,Le))||Le===void 0&&!(se in R))&&(R[se]=Le)}function eo(R,se){for(var Le=R.length;Le--;)if(Uu(R[Le][0],se))return Le;return-1}function io(R,se){return R&&ka(se,AA(se),R)}function qi(R,se,Le,mt,Dn,en,Sr){var Ur;if(mt&&(Ur=en?mt(R,Dn,en,Sr):mt(R)),Ur!==void 0)return Ur;if(!oa(R))return R;var yr=ll(R);if(yr){if(Ur=Fu(R),!se)return Ks(R,Ur)}else{var Ir=vs(R),Bi=Ir==C||Ir==B;if(vl(R))return Cn(R,se);if(Ir==L||Ir==o||Bi&&!en){if(bt(R))return en?R:{};if(Ur=ma(Bi?{}:R),!se)return pa(R,io(Ur,R))}else{if(!Xe[Ir])return en?R:{};Ur=lA(R,Ir,qi,se)}}Sr||(Sr=new Jr);var fo=Sr.get(R);if(fo)return fo;if(Sr.set(R,Ur),!yr)var xi=Le?Zl(R):AA(R);return fe(xi||R,function(Hr,Hi){xi&&(Hi=Hr,Hr=R[Hi]),Wn(Ur,Hi,qi(Hr,se,Le,mt,Hi,R,Sr))}),Ur}function ve(R){return oa(R)?At(R):{}}function Ye(R,se,Le){var mt=se(R);return ll(R)?mt:xe(mt,Le(R))}function Jt(R){return gr.call(R)}function sn(R){if(!oa(R)||mu(R))return!1;var se=_l(R)||bt(R)?mi:Yt;return se.test(Wo(R))}function Ft(R){if(!uA(R))return Kn(R);var se=[];for(var Le in Object(R))Gr.call(R,Le)&&Le!="constructor"&&se.push(Le);return se}function Cn(R,se){if(se)return R.slice();var Le=new R.constructor(R.length);return R.copy(Le),Le}function ur(R){var se=new R.constructor(R.byteLength);return new H(se).set(new H(R)),se}function fi(R,se){var Le=se?ur(R.buffer):R.buffer;return new R.constructor(Le,R.byteOffset,R.byteLength)}function ei(R,se,Le){var mt=se?Le(Ut(R),!0):Ut(R);return Ue(mt,Lt,new R.constructor)}function Zo(R){var se=new R.constructor(R.source,kt.exec(R));return se.lastIndex=R.lastIndex,se}function Fa(R,se,Le){var mt=se?Le(pt(R),!0):pt(R);return Ue(mt,Me,new R.constructor)}function Or(R){return ft?Object(ft.call(R)):{}}function gi(R,se){var Le=se?ur(R.buffer):R.buffer;return new R.constructor(Le,R.byteOffset,R.length)}function Ks(R,se){var Le=-1,mt=R.length;for(se||(se=Array(mt));++Le<mt;)se[Le]=R[Le];return se}function ka(R,se,Le,mt){Le||(Le={});for(var Dn=-1,en=se.length;++Dn<en;){var Sr=se[Dn],Ur=mt?mt(Le[Sr],R[Sr],Sr,Le,R):void 0;Wn(Le,Sr,Ur===void 0?R[Sr]:Ur)}return Le}function pa(R,se){return ka(R,qo(R),se)}function Zl(R){return Ye(R,AA,qo)}function as(R,se){var Le=R.__data__;return Lu(se)?Le[typeof se=="string"?"string":"hash"]:Le.map}function ia(R,se){var Le=it(R,se);return sn(Le)?Le:void 0}var qo=Nt?Rt(Nt,Object):go,vs=Jt;(En&&vs(new En(new ArrayBuffer(1)))!=he||m&&vs(new m)!=k||Kt&&vs(Kt.resolve())!=J||Dr&&vs(new Dr)!=$||Fn&&vs(new Fn)!=ce)&&(vs=function(R){var se=gr.call(R),Le=se==L?R.constructor:void 0,mt=Le?Wo(Le):void 0;if(mt)switch(mt){case de:return he;case Ce:return k;case Be:return J;case ze:return $;case tt:return ce}return se});function Fu(R){var se=R.length,Le=R.constructor(se);return se&&typeof R[0]=="string"&&Gr.call(R,"index")&&(Le.index=R.index,Le.input=R.input),Le}function ma(R){return typeof R.constructor=="function"&&!uA(R)?ve(Te(R)):{}}function lA(R,se,Le,mt){var Dn=R.constructor;switch(se){case me:return ur(R);case a:case h:return new Dn(+R);case he:return fi(R,mt);case V:case ae:case ye:case Oe:case De:case He:case ke:case nt:case be:return gi(R,mt);case k:return ei(R,mt,Le);case P:case q:return new Dn(R);case N:return Zo(R);case $:return Fa(R,mt,Le);case oe:return Or(R)}}function Du(R,se){return se=se??i,!!se&&(typeof R=="number"||jt.test(R))&&R>-1&&R%1==0&&R<se}function Lu(R){var se=typeof R;return se=="string"||se=="number"||se=="symbol"||se=="boolean"?R!=="__proto__":R===null}function mu(R){return!!cr&&cr in R}function uA(R){var se=R&&R.constructor,Le=typeof se=="function"&&se.prototype||vn;return R===Le}function Wo(R){if(R!=null){try{return Mr.call(R)}catch{}try{return R+""}catch{}}return""}function Na(R){return qi(R,!0,!0)}function Uu(R,se){return R===se||R!==R&&se!==se}function ss(R){return gu(R)&&Gr.call(R,"callee")&&(!St.call(R,"callee")||gr.call(R)==o)}var ll=Array.isArray;function Do(R){return R!=null&&Dl(R.length)&&!_l(R)}function gu(R){return Cl(R)&&Do(R)}var vl=pn||oo;function _l(R){var se=oa(R)?gr.call(R):"";return se==C||se==B}function Dl(R){return typeof R=="number"&&R>-1&&R%1==0&&R<=i}function oa(R){var se=typeof R;return!!R&&(se=="object"||se=="function")}function Cl(R){return!!R&&typeof R=="object"}function AA(R){return Do(R)?hi(R):Ft(R)}function go(){return[]}function oo(){return!1}e.exports=Na})(i3,i3.exports);var rH=i3.exports;const DI=fa(rH);var LI=NaN,iH="[object Symbol]",oH=/^\s+|\s+$/g,aH=/^[-+]0x[0-9a-f]+$/i,sH=/^0b[01]+$/i,lH=/^0o[0-7]+$/i,uH=parseInt,AH=Object.prototype,cH=AH.toString;function dH(e,n,t){return e===e&&(t!==void 0&&(e=e<=t?e:t),n!==void 0&&(e=e>=n?e:n)),e}function UI(e){var n=typeof e;return!!e&&(n=="object"||n=="function")}function hH(e){return!!e&&typeof e=="object"}function fH(e){return typeof e=="symbol"||hH(e)&&cH.call(e)==iH}function eM(e){if(typeof e=="number")return e;if(fH(e))return LI;if(UI(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=UI(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=e.replace(oH,"");var t=sH.test(e);return t||lH.test(e)?uH(e.slice(2),t?2:8):aH.test(e)?LI:+e}function pH(e,n,t){return t===void 0&&(t=n,n=void 0),t!==void 0&&(t=eM(t),t=t===t?t:0),n!==void 0&&(n=eM(n),n=n===n?n:0),dH(eM(e),n,t)}var mH=pH;const RI=fa(mH);var NL={},Q4={};Q4.byteLength=vH;Q4.toByteArray=CH;Q4.fromByteArray=wH;var of=[],hd=[],gH=typeof Uint8Array<"u"?Uint8Array:Array,tM="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var ag=0,yH=tM.length;ag<yH;++ag)of[ag]=tM[ag],hd[tM.charCodeAt(ag)]=ag;hd[45]=62;hd[95]=63;function GL(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 vH(e){var n=GL(e),t=n[0],r=n[1];return(t+r)*3/4-r}function _H(e,n,t){return(n+t)*3/4-t}function CH(e){var n,t=GL(e),r=t[0],i=t[1],o=new gH(_H(e,r,i)),s=0,a=i>0?r-4:r,h;for(h=0;h<a;h+=4)n=hd[e.charCodeAt(h)]<<18|hd[e.charCodeAt(h+1)]<<12|hd[e.charCodeAt(h+2)]<<6|hd[e.charCodeAt(h+3)],o[s++]=n>>16&255,o[s++]=n>>8&255,o[s++]=n&255;return i===2&&(n=hd[e.charCodeAt(h)]<<2|hd[e.charCodeAt(h+1)]>>4,o[s++]=n&255),i===1&&(n=hd[e.charCodeAt(h)]<<10|hd[e.charCodeAt(h+1)]<<4|hd[e.charCodeAt(h+2)]>>2,o[s++]=n>>8&255,o[s++]=n&255),o}function bH(e){return of[e>>18&63]+of[e>>12&63]+of[e>>6&63]+of[e&63]}function xH(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(bH(r));return i.join("")}function wH(e){for(var n,t=e.length,r=t%3,i=[],o=16383,s=0,a=t-r;s<a;s+=o)i.push(xH(e,s,s+o>a?a:s+o));return r===1?(n=e[t-1],i.push(of[n>>2]+of[n<<4&63]+"==")):r===2&&(n=(e[t-2]<<8)+e[t-1],i.push(of[n>>10]+of[n>>4&63]+of[n<<2&63]+"=")),i.join("")}var $4={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */$4.read=function(e,n,t,r,i){var o,s,a=i*8-r-1,h=(1<<a)-1,g=h>>1,C=-7,B=t?i-1:0,k=t?-1:1,P=e[n+B];for(B+=k,o=P&(1<<-C)-1,P>>=-C,C+=a;C>0;o=o*256+e[n+B],B+=k,C-=8);for(s=o&(1<<-C)-1,o>>=-C,C+=r;C>0;s=s*256+e[n+B],B+=k,C-=8);if(o===0)o=1-g;else{if(o===h)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)};$4.write=function(e,n,t,r,i,o){var s,a,h,g=o*8-i-1,C=(1<<g)-1,B=C>>1,k=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,P=r?0:o-1,L=r?1:-1,J=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=C):(s=Math.floor(Math.log(n)/Math.LN2),n*(h=Math.pow(2,-s))<1&&(s--,h*=2),s+B>=1?n+=k/h:n+=k*Math.pow(2,1-B),n*h>=2&&(s++,h/=2),s+B>=C?(a=0,s=C):s+B>=1?(a=(n*h-1)*Math.pow(2,i),s=s+B):(a=n*Math.pow(2,B-1)*Math.pow(2,i),s=0));i>=8;e[t+P]=a&255,P+=L,a/=256,i-=8);for(s=s<<i|a,g+=i;g>0;e[t+P]=s&255,P+=L,s/=256,g-=8);e[t+P-L]|=J*128};/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <https://feross.org>
* @license MIT
*/(function(e){const n=Q4,t=$4,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 Se=new Uint8Array(1),X={foo:function(){return 42}};return Object.setPrototypeOf(X,Uint8Array.prototype),Object.setPrototypeOf(Se,X),Se.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(Se){if(Se>i)throw new RangeError('The value "'+Se+'" is invalid for option "size"');const X=new Uint8Array(Se);return Object.setPrototypeOf(X,a.prototype),X}function a(Se,X,H){if(typeof Se=="number"){if(typeof X=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return B(Se)}return h(Se,X,H)}a.poolSize=8192;function h(Se,X,H){if(typeof Se=="string")return k(Se,X);if(ArrayBuffer.isView(Se))return L(Se);if(Se==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof Se);if(cr(Se,ArrayBuffer)||Se&&cr(Se.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(cr(Se,SharedArrayBuffer)||Se&&cr(Se.buffer,SharedArrayBuffer)))return J(Se,X,H);if(typeof Se=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const Te=Se.valueOf&&Se.valueOf();if(Te!=null&&Te!==Se)return a.from(Te,X,H);const At=N(Se);if(At)return At;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof Se[Symbol.toPrimitive]=="function")return a.from(Se[Symbol.toPrimitive]("string"),X,H);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof Se)}a.from=function(Se,X,H){return h(Se,X,H)},Object.setPrototypeOf(a.prototype,Uint8Array.prototype),Object.setPrototypeOf(a,Uint8Array);function g(Se){if(typeof Se!="number")throw new TypeError('"size" argument must be of type number');if(Se<0)throw new RangeError('The value "'+Se+'" is invalid for option "size"')}function C(Se,X,H){return g(Se),Se<=0?s(Se):X!==void 0?typeof H=="string"?s(Se).fill(X,H):s(Se).fill(X):s(Se)}a.alloc=function(Se,X,H){return C(Se,X,H)};function B(Se){return g(Se),s(Se<0?0:$(Se)|0)}a.allocUnsafe=function(Se){return B(Se)},a.allocUnsafeSlow=function(Se){return B(Se)};function k(Se,X){if((typeof X!="string"||X==="")&&(X="utf8"),!a.isEncoding(X))throw new TypeError("Unknown encoding: "+X);const H=oe(Se,X)|0;let Te=s(H);const At=Te.write(Se,X);return At!==H&&(Te=Te.slice(0,At)),Te}function P(Se){const X=Se.length<0?0:$(Se.length)|0,H=s(X);for(let Te=0;Te<X;Te+=1)H[Te]=Se[Te]&255;return H}function L(Se){if(cr(Se,Uint8Array)){const X=new Uint8Array(Se);return J(X.buffer,X.byteOffset,X.byteLength)}return P(Se)}function J(Se,X,H){if(X<0||Se.byteLength<X)throw new RangeError('"offset" is outside of buffer bounds');if(Se.byteLength<X+(H||0))throw new RangeError('"length" is outside of buffer bounds');let Te;return X===void 0&&H===void 0?Te=new Uint8Array(Se):H===void 0?Te=new Uint8Array(Se,X):Te=new Uint8Array(Se,X,H),Object.setPrototypeOf(Te,a.prototype),Te}function N(Se){if(a.isBuffer(Se)){const X=$(Se.length)|0,H=s(X);return H.length===0||Se.copy(H,0,0,X),H}if(Se.length!==void 0)return typeof Se.length!="number"||Mr(Se.length)?s(0):P(Se);if(Se.type==="Buffer"&&Array.isArray(Se.data))return P(Se.data)}function $(Se){if(Se>=i)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return Se|0}function q(Se){return+Se!=Se&&(Se=0),a.alloc(+Se)}a.isBuffer=function(X){return X!=null&&X._isBuffer===!0&&X!==a.prototype},a.compare=function(X,H){if(cr(X,Uint8Array)&&(X=a.from(X,X.offset,X.byteLength)),cr(H,Uint8Array)&&(H=a.from(H,H.offset,H.byteLength)),!a.isBuffer(X)||!a.isBuffer(H))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(X===H)return 0;let Te=X.length,At=H.length;for(let St=0,Et=Math.min(Te,At);St<Et;++St)if(X[St]!==H[St]){Te=X[St],At=H[St];break}return Te<At?-1:At<Te?1:0},a.isEncoding=function(X){switch(String(X).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(X,H){if(!Array.isArray(X))throw new TypeError('"list" argument must be an Array of Buffers');if(X.length===0)return a.alloc(0);let Te;if(H===void 0)for(H=0,Te=0;Te<X.length;++Te)H+=X[Te].length;const At=a.allocUnsafe(H);let St=0;for(Te=0;Te<X.length;++Te){let Et=X[Te];if(cr(Et,Uint8Array))St+Et.length>At.length?(a.isBuffer(Et)||(Et=a.from(Et)),Et.copy(At,St)):Uint8Array.prototype.set.call(At,Et,St);else if(a.isBuffer(Et))Et.copy(At,St);else throw new TypeError('"list" argument must be an Array of Buffers');St+=Et.length}return At};function oe(Se,X){if(a.isBuffer(Se))return Se.length;if(ArrayBuffer.isView(Se)||cr(Se,ArrayBuffer))return Se.byteLength;if(typeof Se!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof Se);const H=Se.length,Te=arguments.length>2&&arguments[2]===!0;if(!Te&&H===0)return 0;let At=!1;for(;;)switch(X){case"ascii":case"latin1":case"binary":return H;case"utf8":case"utf-8":return pt(Se).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return H*2;case"hex":return H>>>1;case"base64":return vn(Se).length;default:if(At)return Te?-1:pt(Se).length;X=(""+X).toLowerCase(),At=!0}}a.byteLength=oe;function ce(Se,X,H){let Te=!1;if((X===void 0||X<0)&&(X=0),X>this.length||((H===void 0||H>this.length)&&(H=this.length),H<=0)||(H>>>=0,X>>>=0,H<=X))return"";for(Se||(Se="utf8");;)switch(Se){case"hex":return jt(this,X,H);case"utf8":case"utf-8":return nt(this,X,H);case"ascii":return kt(this,X,H);case"latin1":case"binary":return Yt(this,X,H);case"base64":return ke(this,X,H);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Xe(this,X,H);default:if(Te)throw new TypeError("Unknown encoding: "+Se);Se=(Se+"").toLowerCase(),Te=!0}}a.prototype._isBuffer=!0;function me(Se,X,H){const Te=Se[X];Se[X]=Se[H],Se[H]=Te}a.prototype.swap16=function(){const X=this.length;if(X%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let H=0;H<X;H+=2)me(this,H,H+1);return this},a.prototype.swap32=function(){const X=this.length;if(X%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let H=0;H<X;H+=4)me(this,H,H+3),me(this,H+1,H+2);return this},a.prototype.swap64=function(){const X=this.length;if(X%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let H=0;H<X;H+=8)me(this,H,H+7),me(this,H+1,H+6),me(this,H+2,H+5),me(this,H+3,H+4);return this},a.prototype.toString=function(){const X=this.length;return X===0?"":arguments.length===0?nt(this,0,X):ce.apply(this,arguments)},a.prototype.toLocaleString=a.prototype.toString,a.prototype.equals=function(X){if(!a.isBuffer(X))throw new TypeError("Argument must be a Buffer");return this===X?!0:a.compare(this,X)===0},a.prototype.inspect=function(){let X="";const H=e.INSPECT_MAX_BYTES;return X=this.toString("hex",0,H).replace(/(.{2})/g,"$1 ").trim(),this.length>H&&(X+=" ... "),"<Buffer "+X+">"},r&&(a.prototype[r]=a.prototype.inspect),a.prototype.compare=function(X,H,Te,At,St){if(cr(X,Uint8Array)&&(X=a.from(X,X.offset,X.byteLength)),!a.isBuffer(X))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof X);if(H===void 0&&(H=0),Te===void 0&&(Te=X?X.length:0),At===void 0&&(At=0),St===void 0&&(St=this.length),H<0||Te>X.length||At<0||St>this.length)throw new RangeError("out of range index");if(At>=St&&H>=Te)return 0;if(At>=St)return-1;if(H>=Te)return 1;if(H>>>=0,Te>>>=0,At>>>=0,St>>>=0,this===X)return 0;let Et=St-At,Nt=Te-H;const pn=Math.min(Et,Nt),Kn=this.slice(At,St),En=X.slice(H,Te);for(let m=0;m<pn;++m)if(Kn[m]!==En[m]){Et=Kn[m],Nt=En[m];break}return Et<Nt?-1:Nt<Et?1:0};function he(Se,X,H,Te,At){if(Se.length===0)return-1;if(typeof H=="string"?(Te=H,H=0):H>2147483647?H=2147483647:H<-2147483648&&(H=-2147483648),H=+H,Mr(H)&&(H=At?0:Se.length-1),H<0&&(H=Se.length+H),H>=Se.length){if(At)return-1;H=Se.length-1}else if(H<0)if(At)H=0;else return-1;if(typeof X=="string"&&(X=a.from(X,Te)),a.isBuffer(X))return X.length===0?-1:V(Se,X,H,Te,At);if(typeof X=="number")return X=X&255,typeof Uint8Array.prototype.indexOf=="function"?At?Uint8Array.prototype.indexOf.call(Se,X,H):Uint8Array.prototype.lastIndexOf.call(Se,X,H):V(Se,[X],H,Te,At);throw new TypeError("val must be string, number or Buffer")}function V(Se,X,H,Te,At){let St=1,Et=Se.length,Nt=X.length;if(Te!==void 0&&(Te=String(Te).toLowerCase(),Te==="ucs2"||Te==="ucs-2"||Te==="utf16le"||Te==="utf-16le")){if(Se.length<2||X.length<2)return-1;St=2,Et/=2,Nt/=2,H/=2}function pn(En,m){return St===1?En[m]:En.readUInt16BE(m*St)}let Kn;if(At){let En=-1;for(Kn=H;Kn<Et;Kn++)if(pn(Se,Kn)===pn(X,En===-1?0:Kn-En)){if(En===-1&&(En=Kn),Kn-En+1===Nt)return En*St}else En!==-1&&(Kn-=Kn-En),En=-1}else for(H+Nt>Et&&(H=Et-Nt),Kn=H;Kn>=0;Kn--){let En=!0;for(let m=0;m<Nt;m++)if(pn(Se,Kn+m)!==pn(X,m)){En=!1;break}if(En)return Kn}return-1}a.prototype.includes=function(X,H,Te){return this.indexOf(X,H,Te)!==-1},a.prototype.indexOf=function(X,H,Te){return he(this,X,H,Te,!0)},a.prototype.lastIndexOf=function(X,H,Te){return he(this,X,H,Te,!1)};function ae(Se,X,H,Te){H=Number(H)||0;const At=Se.length-H;Te?(Te=Number(Te),Te>At&&(Te=At)):Te=At;const St=X.length;Te>St/2&&(Te=St/2);let Et;for(Et=0;Et<Te;++Et){const Nt=parseInt(X.substr(Et*2,2),16);if(Mr(Nt))return Et;Se[H+Et]=Nt}return Et}function ye(Se,X,H,Te){return Xn(pt(X,Se.length-H),Se,H,Te)}function Oe(Se,X,H,Te){return Xn(rr(X),Se,H,Te)}function De(Se,X,H,Te){return Xn(vn(X),Se,H,Te)}function He(Se,X,H,Te){return Xn(mn(X,Se.length-H),Se,H,Te)}a.prototype.write=function(X,H,Te,At){if(H===void 0)At="utf8",Te=this.length,H=0;else if(Te===void 0&&typeof H=="string")At=H,Te=this.length,H=0;else if(isFinite(H))H=H>>>0,isFinite(Te)?(Te=Te>>>0,At===void 0&&(At="utf8")):(At=Te,Te=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const St=this.length-H;if((Te===void 0||Te>St)&&(Te=St),X.length>0&&(Te<0||H<0)||H>this.length)throw new RangeError("Attempt to write outside buffer bounds");At||(At="utf8");let Et=!1;for(;;)switch(At){case"hex":return ae(this,X,H,Te);case"utf8":case"utf-8":return ye(this,X,H,Te);case"ascii":case"latin1":case"binary":return Oe(this,X,H,Te);case"base64":return De(this,X,H,Te);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return He(this,X,H,Te);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 ke(Se,X,H){return X===0&&H===Se.length?n.fromByteArray(Se):n.fromByteArray(Se.slice(X,H))}function nt(Se,X,H){H=Math.min(Se.length,H);const Te=[];let At=X;for(;At<H;){const St=Se[At];let Et=null,Nt=St>239?4:St>223?3:St>191?2:1;if(At+Nt<=H){let pn,Kn,En,m;switch(Nt){case 1:St<128&&(Et=St);break;case 2:pn=Se[At+1],(pn&192)===128&&(m=(St&31)<<6|pn&63,m>127&&(Et=m));break;case 3:pn=Se[At+1],Kn=Se[At+2],(pn&192)===128&&(Kn&192)===128&&(m=(St&15)<<12|(pn&63)<<6|Kn&63,m>2047&&(m<55296||m>57343)&&(Et=m));break;case 4:pn=Se[At+1],Kn=Se[At+2],En=Se[At+3],(pn&192)===128&&(Kn&192)===128&&(En&192)===128&&(m=(St&15)<<18|(pn&63)<<12|(Kn&63)<<6|En&63,m>65535&&m<1114112&&(Et=m))}}Et===null?(Et=65533,Nt=1):Et>65535&&(Et-=65536,Te.push(Et>>>10&1023|55296),Et=56320|Et&1023),Te.push(Et),At+=Nt}return Bt(Te)}const be=4096;function Bt(Se){const X=Se.length;if(X<=be)return String.fromCharCode.apply(String,Se);let H="",Te=0;for(;Te<X;)H+=String.fromCharCode.apply(String,Se.slice(Te,Te+=be));return H}function kt(Se,X,H){let Te="";H=Math.min(Se.length,H);for(let At=X;At<H;++At)Te+=String.fromCharCode(Se[At]&127);return Te}function Yt(Se,X,H){let Te="";H=Math.min(Se.length,H);for(let At=X;At<H;++At)Te+=String.fromCharCode(Se[At]);return Te}function jt(Se,X,H){const Te=Se.length;(!X||X<0)&&(X=0),(!H||H<0||H>Te)&&(H=Te);let At="";for(let St=X;St<H;++St)At+=Gr[Se[St]];return At}function Xe(Se,X,H){const Te=Se.slice(X,H);let At="";for(let St=0;St<Te.length-1;St+=2)At+=String.fromCharCode(Te[St]+Te[St+1]*256);return At}a.prototype.slice=function(X,H){const Te=this.length;X=~~X,H=H===void 0?Te:~~H,X<0?(X+=Te,X<0&&(X=0)):X>Te&&(X=Te),H<0?(H+=Te,H<0&&(H=0)):H>Te&&(H=Te),H<X&&(H=X);const At=this.subarray(X,H);return Object.setPrototypeOf(At,a.prototype),At};function rt(Se,X,H){if(Se%1!==0||Se<0)throw new RangeError("offset is not uint");if(Se+X>H)throw new RangeError("Trying to access beyond buffer length")}a.prototype.readUintLE=a.prototype.readUIntLE=function(X,H,Te){X=X>>>0,H=H>>>0,Te||rt(X,H,this.length);let At=this[X],St=1,Et=0;for(;++Et<H&&(St*=256);)At+=this[X+Et]*St;return At},a.prototype.readUintBE=a.prototype.readUIntBE=function(X,H,Te){X=X>>>0,H=H>>>0,Te||rt(X,H,this.length);let At=this[X+--H],St=1;for(;H>0&&(St*=256);)At+=this[X+--H]*St;return At},a.prototype.readUint8=a.prototype.readUInt8=function(X,H){return X=X>>>0,H||rt(X,1,this.length),this[X]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(X,H){return X=X>>>0,H||rt(X,2,this.length),this[X]|this[X+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(X,H){return X=X>>>0,H||rt(X,2,this.length),this[X]<<8|this[X+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(X,H){return X=X>>>0,H||rt(X,4,this.length),(this[X]|this[X+1]<<8|this[X+2]<<16)+this[X+3]*16777216},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(X,H){return X=X>>>0,H||rt(X,4,this.length),this[X]*16777216+(this[X+1]<<16|this[X+2]<<8|this[X+3])},a.prototype.readBigUInt64LE=gr(function(X){X=X>>>0,it(X,"offset");const H=this[X],Te=this[X+7];(H===void 0||Te===void 0)&&bt(X,this.length-8);const At=H+this[++X]*2**8+this[++X]*2**16+this[++X]*2**24,St=this[++X]+this[++X]*2**8+this[++X]*2**16+Te*2**24;return BigInt(At)+(BigInt(St)<<BigInt(32))}),a.prototype.readBigUInt64BE=gr(function(X){X=X>>>0,it(X,"offset");const H=this[X],Te=this[X+7];(H===void 0||Te===void 0)&&bt(X,this.length-8);const At=H*2**24+this[++X]*2**16+this[++X]*2**8+this[++X],St=this[++X]*2**24+this[++X]*2**16+this[++X]*2**8+Te;return(BigInt(At)<<BigInt(32))+BigInt(St)}),a.prototype.readIntLE=function(X,H,Te){X=X>>>0,H=H>>>0,Te||rt(X,H,this.length);let At=this[X],St=1,Et=0;for(;++Et<H&&(St*=256);)At+=this[X+Et]*St;return St*=128,At>=St&&(At-=Math.pow(2,8*H)),At},a.prototype.readIntBE=function(X,H,Te){X=X>>>0,H=H>>>0,Te||rt(X,H,this.length);let At=H,St=1,Et=this[X+--At];for(;At>0&&(St*=256);)Et+=this[X+--At]*St;return St*=128,Et>=St&&(Et-=Math.pow(2,8*H)),Et},a.prototype.readInt8=function(X,H){return X=X>>>0,H||rt(X,1,this.length),this[X]&128?(255-this[X]+1)*-1:this[X]},a.prototype.readInt16LE=function(X,H){X=X>>>0,H||rt(X,2,this.length);const Te=this[X]|this[X+1]<<8;return Te&32768?Te|4294901760:Te},a.prototype.readInt16BE=function(X,H){X=X>>>0,H||rt(X,2,this.length);const Te=this[X+1]|this[X]<<8;return Te&32768?Te|4294901760:Te},a.prototype.readInt32LE=function(X,H){return X=X>>>0,H||rt(X,4,this.length),this[X]|this[X+1]<<8|this[X+2]<<16|this[X+3]<<24},a.prototype.readInt32BE=function(X,H){return X=X>>>0,H||rt(X,4,this.length),this[X]<<24|this[X+1]<<16|this[X+2]<<8|this[X+3]},a.prototype.readBigInt64LE=gr(function(X){X=X>>>0,it(X,"offset");const H=this[X],Te=this[X+7];(H===void 0||Te===void 0)&&bt(X,this.length-8);const At=this[X+4]+this[X+5]*2**8+this[X+6]*2**16+(Te<<24);return(BigInt(At)<<BigInt(32))+BigInt(H+this[++X]*2**8+this[++X]*2**16+this[++X]*2**24)}),a.prototype.readBigInt64BE=gr(function(X){X=X>>>0,it(X,"offset");const H=this[X],Te=this[X+7];(H===void 0||Te===void 0)&&bt(X,this.length-8);const At=(H<<24)+this[++X]*2**16+this[++X]*2**8+this[++X];return(BigInt(At)<<BigInt(32))+BigInt(this[++X]*2**24+this[++X]*2**16+this[++X]*2**8+Te)}),a.prototype.readFloatLE=function(X,H){return X=X>>>0,H||rt(X,4,this.length),t.read(this,X,!0,23,4)},a.prototype.readFloatBE=function(X,H){return X=X>>>0,H||rt(X,4,this.length),t.read(this,X,!1,23,4)},a.prototype.readDoubleLE=function(X,H){return X=X>>>0,H||rt(X,8,this.length),t.read(this,X,!0,52,8)},a.prototype.readDoubleBE=function(X,H){return X=X>>>0,H||rt(X,8,this.length),t.read(this,X,!1,52,8)};function ot(Se,X,H,Te,At,St){if(!a.isBuffer(Se))throw new TypeError('"buffer" argument must be a Buffer instance');if(X>At||X<St)throw new RangeError('"value" argument is out of bounds');if(H+Te>Se.length)throw new RangeError("Index out of range")}a.prototype.writeUintLE=a.prototype.writeUIntLE=function(X,H,Te,At){if(X=+X,H=H>>>0,Te=Te>>>0,!At){const Nt=Math.pow(2,8*Te)-1;ot(this,X,H,Te,Nt,0)}let St=1,Et=0;for(this[H]=X&255;++Et<Te&&(St*=256);)this[H+Et]=X/St&255;return H+Te},a.prototype.writeUintBE=a.prototype.writeUIntBE=function(X,H,Te,At){if(X=+X,H=H>>>0,Te=Te>>>0,!At){const Nt=Math.pow(2,8*Te)-1;ot(this,X,H,Te,Nt,0)}let St=Te-1,Et=1;for(this[H+St]=X&255;--St>=0&&(Et*=256);)this[H+St]=X/Et&255;return H+Te},a.prototype.writeUint8=a.prototype.writeUInt8=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,1,255,0),this[H]=X&255,H+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,2,65535,0),this[H]=X&255,this[H+1]=X>>>8,H+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,2,65535,0),this[H]=X>>>8,this[H+1]=X&255,H+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,4,4294967295,0),this[H+3]=X>>>24,this[H+2]=X>>>16,this[H+1]=X>>>8,this[H]=X&255,H+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,4,4294967295,0),this[H]=X>>>24,this[H+1]=X>>>16,this[H+2]=X>>>8,this[H+3]=X&255,H+4};function on(Se,X,H,Te,At){et(X,Te,At,Se,H,7);let St=Number(X&BigInt(4294967295));Se[H++]=St,St=St>>8,Se[H++]=St,St=St>>8,Se[H++]=St,St=St>>8,Se[H++]=St;let Et=Number(X>>BigInt(32)&BigInt(4294967295));return Se[H++]=Et,Et=Et>>8,Se[H++]=Et,Et=Et>>8,Se[H++]=Et,Et=Et>>8,Se[H++]=Et,H}function gt(Se,X,H,Te,At){et(X,Te,At,Se,H,7);let St=Number(X&BigInt(4294967295));Se[H+7]=St,St=St>>8,Se[H+6]=St,St=St>>8,Se[H+5]=St,St=St>>8,Se[H+4]=St;let Et=Number(X>>BigInt(32)&BigInt(4294967295));return Se[H+3]=Et,Et=Et>>8,Se[H+2]=Et,Et=Et>>8,Se[H+1]=Et,Et=Et>>8,Se[H]=Et,H+8}a.prototype.writeBigUInt64LE=gr(function(X,H=0){return on(this,X,H,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeBigUInt64BE=gr(function(X,H=0){return gt(this,X,H,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeIntLE=function(X,H,Te,At){if(X=+X,H=H>>>0,!At){const pn=Math.pow(2,8*Te-1);ot(this,X,H,Te,pn-1,-pn)}let St=0,Et=1,Nt=0;for(this[H]=X&255;++St<Te&&(Et*=256);)X<0&&Nt===0&&this[H+St-1]!==0&&(Nt=1),this[H+St]=(X/Et>>0)-Nt&255;return H+Te},a.prototype.writeIntBE=function(X,H,Te,At){if(X=+X,H=H>>>0,!At){const pn=Math.pow(2,8*Te-1);ot(this,X,H,Te,pn-1,-pn)}let St=Te-1,Et=1,Nt=0;for(this[H+St]=X&255;--St>=0&&(Et*=256);)X<0&&Nt===0&&this[H+St+1]!==0&&(Nt=1),this[H+St]=(X/Et>>0)-Nt&255;return H+Te},a.prototype.writeInt8=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,1,127,-128),X<0&&(X=255+X+1),this[H]=X&255,H+1},a.prototype.writeInt16LE=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,2,32767,-32768),this[H]=X&255,this[H+1]=X>>>8,H+2},a.prototype.writeInt16BE=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,2,32767,-32768),this[H]=X>>>8,this[H+1]=X&255,H+2},a.prototype.writeInt32LE=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,4,2147483647,-2147483648),this[H]=X&255,this[H+1]=X>>>8,this[H+2]=X>>>16,this[H+3]=X>>>24,H+4},a.prototype.writeInt32BE=function(X,H,Te){return X=+X,H=H>>>0,Te||ot(this,X,H,4,2147483647,-2147483648),X<0&&(X=4294967295+X+1),this[H]=X>>>24,this[H+1]=X>>>16,this[H+2]=X>>>8,this[H+3]=X&255,H+4},a.prototype.writeBigInt64LE=gr(function(X,H=0){return on(this,X,H,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),a.prototype.writeBigInt64BE=gr(function(X,H=0){return gt(this,X,H,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function at(Se,X,H,Te,At,St){if(H+Te>Se.length)throw new RangeError("Index out of range");if(H<0)throw new RangeError("Index out of range")}function It(Se,X,H,Te,At){return X=+X,H=H>>>0,At||at(Se,X,H,4),t.write(Se,X,H,Te,23,4),H+4}a.prototype.writeFloatLE=function(X,H,Te){return It(this,X,H,!0,Te)},a.prototype.writeFloatBE=function(X,H,Te){return It(this,X,H,!1,Te)};function Lt(Se,X,H,Te,At){return X=+X,H=H>>>0,At||at(Se,X,H,8),t.write(Se,X,H,Te,52,8),H+8}a.prototype.writeDoubleLE=function(X,H,Te){return Lt(this,X,H,!0,Te)},a.prototype.writeDoubleBE=function(X,H,Te){return Lt(this,X,H,!1,Te)},a.prototype.copy=function(X,H,Te,At){if(!a.isBuffer(X))throw new TypeError("argument should be a Buffer");if(Te||(Te=0),!At&&At!==0&&(At=this.length),H>=X.length&&(H=X.length),H||(H=0),At>0&&At<Te&&(At=Te),At===Te||X.length===0||this.length===0)return 0;if(H<0)throw new RangeError("targetStart out of bounds");if(Te<0||Te>=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),X.length-H<At-Te&&(At=X.length-H+Te);const St=At-Te;return this===X&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(H,Te,At):Uint8Array.prototype.set.call(X,this.subarray(Te,At),H),St},a.prototype.fill=function(X,H,Te,At){if(typeof X=="string"){if(typeof H=="string"?(At=H,H=0,Te=this.length):typeof Te=="string"&&(At=Te,Te=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(X.length===1){const Et=X.charCodeAt(0);(At==="utf8"&&Et<128||At==="latin1")&&(X=Et)}}else typeof X=="number"?X=X&255:typeof X=="boolean"&&(X=Number(X));if(H<0||this.length<H||this.length<Te)throw new RangeError("Out of range index");if(Te<=H)return this;H=H>>>0,Te=Te===void 0?this.length:Te>>>0,X||(X=0);let St;if(typeof X=="number")for(St=H;St<Te;++St)this[St]=X;else{const Et=a.isBuffer(X)?X:a.from(X,At),Nt=Et.length;if(Nt===0)throw new TypeError('The value "'+X+'" is invalid for argument "value"');for(St=0;St<Te-H;++St)this[St+H]=Et[St%Nt]}return this};const Me={};function fe(Se,X,H){Me[Se]=class extends H{constructor(){super(),Object.defineProperty(this,"message",{value:X.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${Se}]`,this.stack,delete this.name}get code(){return Se}set code(At){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:At,writable:!0})}toString(){return`${this.name} [${Se}]: ${this.message}`}}}fe("ERR_BUFFER_OUT_OF_BOUNDS",function(Se){return Se?`${Se} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),fe("ERR_INVALID_ARG_TYPE",function(Se,X){return`The "${Se}" argument must be of type number. Received type ${typeof X}`},TypeError),fe("ERR_OUT_OF_RANGE",function(Se,X,H){let Te=`The value of "${Se}" is out of range.`,At=H;return Number.isInteger(H)&&Math.abs(H)>2**32?At=xe(String(H)):typeof H=="bigint"&&(At=String(H),(H>BigInt(2)**BigInt(32)||H<-(BigInt(2)**BigInt(32)))&&(At=xe(At)),At+="n"),Te+=` It must be ${X}. Received ${At}`,Te},RangeError);function xe(Se){let X="",H=Se.length;const Te=Se[0]==="-"?1:0;for(;H>=Te+4;H-=3)X=`_${Se.slice(H-3,H)}${X}`;return`${Se.slice(0,H)}${X}`}function Ue(Se,X,H){it(X,"offset"),(Se[X]===void 0||Se[X+H]===void 0)&&bt(X,Se.length-(H+1))}function et(Se,X,H,Te,At,St){if(Se>H||Se<X){const Et=typeof X=="bigint"?"n":"";let Nt;throw St>3?X===0||X===BigInt(0)?Nt=`>= 0${Et} and < 2${Et} ** ${(St+1)*8}${Et}`:Nt=`>= -(2${Et} ** ${(St+1)*8-1}${Et}) and < 2 ** ${(St+1)*8-1}${Et}`:Nt=`>= ${X}${Et} and <= ${H}${Et}`,new Me.ERR_OUT_OF_RANGE("value",Nt,Se)}Ue(Te,At,St)}function it(Se,X){if(typeof Se!="number")throw new Me.ERR_INVALID_ARG_TYPE(X,"number",Se)}function bt(Se,X,H){throw Math.floor(Se)!==Se?(it(Se,H),new Me.ERR_OUT_OF_RANGE(H||"offset","an integer",Se)):X<0?new Me.ERR_BUFFER_OUT_OF_BOUNDS:new Me.ERR_OUT_OF_RANGE(H||"offset",`>= ${H?1:0} and <= ${X}`,Se)}const Ut=/[^+/0-9A-Za-z-_]/g;function Rt(Se){if(Se=Se.split("=")[0],Se=Se.trim().replace(Ut,""),Se.length<2)return"";for(;Se.length%4!==0;)Se=Se+"=";return Se}function pt(Se,X){X=X||1/0;let H;const Te=Se.length;let At=null;const St=[];for(let Et=0;Et<Te;++Et){if(H=Se.charCodeAt(Et),H>55295&&H<57344){if(!At){if(H>56319){(X-=3)>-1&&St.push(239,191,189);continue}else if(Et+1===Te){(X-=3)>-1&&St.push(239,191,189);continue}At=H;continue}if(H<56320){(X-=3)>-1&&St.push(239,191,189),At=H;continue}H=(At-55296<<10|H-56320)+65536}else At&&(X-=3)>-1&&St.push(239,191,189);if(At=null,H<128){if((X-=1)<0)break;St.push(H)}else if(H<2048){if((X-=2)<0)break;St.push(H>>6|192,H&63|128)}else if(H<65536){if((X-=3)<0)break;St.push(H>>12|224,H>>6&63|128,H&63|128)}else if(H<1114112){if((X-=4)<0)break;St.push(H>>18|240,H>>12&63|128,H>>6&63|128,H&63|128)}else throw new Error("Invalid code point")}return St}function rr(Se){const X=[];for(let H=0;H<Se.length;++H)X.push(Se.charCodeAt(H)&255);return X}function mn(Se,X){let H,Te,At;const St=[];for(let Et=0;Et<Se.length&&!((X-=2)<0);++Et)H=Se.charCodeAt(Et),Te=H>>8,At=H%256,St.push(At),St.push(Te);return St}function vn(Se){return n.toByteArray(Rt(Se))}function Xn(Se,X,H,Te){let At;for(At=0;At<Te&&!(At+H>=X.length||At>=Se.length);++At)X[At+H]=Se[At];return At}function cr(Se,X){return Se instanceof X||Se!=null&&Se.constructor!=null&&Se.constructor.name!=null&&Se.constructor.name===X.name}function Mr(Se){return Se!==Se}const Gr=function(){const Se="0123456789abcdef",X=new Array(256);for(let H=0;H<16;++H){const Te=H*16;for(let At=0;At<16;++At)X[Te+At]=Se[H]+Se[At]}return X}();function gr(Se){return typeof BigInt>"u"?mi:Se}function mi(){throw new Error("BigInt not supported")}})(NL);const MH=fa(NL);var SH="Expected a function",QL="__lodash_hash_undefined__",$L=1/0,EH="[object Function]",OH="[object GeneratorFunction]",BH="[object Symbol]",kH=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,IH=/^\w*$/,TH=/^\./,KH=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,PH=/[\\^$.*+?()[\]{}|]/g,FH=/\\(\\)?/g,DH=/^\[object .+?Constructor\]$/,LH=typeof window=="object"&&window&&window.Object===Object&&window,UH=typeof self=="object"&&self&&self.Object===Object&&self,wB=LH||UH||Function("return this")();function RH(e,n){return e==null?void 0:e[n]}function zH(e){var n=!1;if(e!=null&&typeof e.toString!="function")try{n=!!(e+"")}catch{}return n}var jH=Array.prototype,WH=Function.prototype,YL=Object.prototype,nM=wB["__core-js_shared__"],zI=function(){var e=/[^.]+$/.exec(nM&&nM.keys&&nM.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),qL=WH.toString,MB=YL.hasOwnProperty,HL=YL.toString,NH=RegExp("^"+qL.call(MB).replace(PH,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),jI=wB.Symbol,GH=jH.splice,QH=VL(wB,"Map"),tC=VL(Object,"create"),WI=jI?jI.prototype:void 0,NI=WI?WI.toString:void 0;function s1(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 $H(){this.__data__=tC?tC(null):{}}function YH(e){return this.has(e)&&delete this.__data__[e]}function qH(e){var n=this.__data__;if(tC){var t=n[e];return t===QL?void 0:t}return MB.call(n,e)?n[e]:void 0}function HH(e){var n=this.__data__;return tC?n[e]!==void 0:MB.call(n,e)}function VH(e,n){var t=this.__data__;return t[e]=tC&&n===void 0?QL:n,this}s1.prototype.clear=$H;s1.prototype.delete=YH;s1.prototype.get=qH;s1.prototype.has=HH;s1.prototype.set=VH;function Ry(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 ZH(){this.__data__=[]}function XH(e){var n=this.__data__,t=Y4(n,e);if(t<0)return!1;var r=n.length-1;return t==r?n.pop():GH.call(n,t,1),!0}function JH(e){var n=this.__data__,t=Y4(n,e);return t<0?void 0:n[t][1]}function eV(e){return Y4(this.__data__,e)>-1}function tV(e,n){var t=this.__data__,r=Y4(t,e);return r<0?t.push([e,n]):t[r][1]=n,this}Ry.prototype.clear=ZH;Ry.prototype.delete=XH;Ry.prototype.get=JH;Ry.prototype.has=eV;Ry.prototype.set=tV;function y1(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 nV(){this.__data__={hash:new s1,map:new(QH||Ry),string:new s1}}function rV(e){return q4(this,e).delete(e)}function iV(e){return q4(this,e).get(e)}function oV(e){return q4(this,e).has(e)}function aV(e,n){return q4(this,e).set(e,n),this}y1.prototype.clear=nV;y1.prototype.delete=rV;y1.prototype.get=iV;y1.prototype.has=oV;y1.prototype.set=aV;function Y4(e,n){for(var t=e.length;t--;)if(gV(e[t][0],n))return t;return-1}function sV(e,n){n=cV(n,e)?[n]:AV(n);for(var t=0,r=n.length;e!=null&&t<r;)e=e[pV(n[t++])];return t&&t==r?e:void 0}function lV(e){if(!XL(e)||hV(e))return!1;var n=yV(e)||zH(e)?NH:DH;return n.test(mV(e))}function uV(e){if(typeof e=="string")return e;if(EB(e))return NI?NI.call(e):"";var n=e+"";return n=="0"&&1/e==-$L?"-0":n}function AV(e){return ZL(e)?e:fV(e)}function q4(e,n){var t=e.__data__;return dV(n)?t[typeof n=="string"?"string":"hash"]:t.map}function VL(e,n){var t=RH(e,n);return lV(t)?t:void 0}function cV(e,n){if(ZL(e))return!1;var t=typeof e;return t=="number"||t=="symbol"||t=="boolean"||e==null||EB(e)?!0:IH.test(e)||!kH.test(e)||n!=null&&e in Object(n)}function dV(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null}function hV(e){return!!zI&&zI in e}var fV=SB(function(e){e=_V(e);var n=[];return TH.test(e)&&n.push(""),e.replace(KH,function(t,r,i,o){n.push(i?o.replace(FH,"$1"):r||t)}),n});function pV(e){if(typeof e=="string"||EB(e))return e;var n=e+"";return n=="0"&&1/e==-$L?"-0":n}function mV(e){if(e!=null){try{return qL.call(e)}catch{}try{return e+""}catch{}}return""}function SB(e,n){if(typeof e!="function"||n&&typeof n!="function")throw new TypeError(SH);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(SB.Cache||y1),t}SB.Cache=y1;function gV(e,n){return e===n||e!==e&&n!==n}var ZL=Array.isArray;function yV(e){var n=XL(e)?HL.call(e):"";return n==EH||n==OH}function XL(e){var n=typeof e;return!!e&&(n=="object"||n=="function")}function vV(e){return!!e&&typeof e=="object"}function EB(e){return typeof e=="symbol"||vV(e)&&HL.call(e)==BH}function _V(e){return e==null?"":uV(e)}function CV(e,n,t){var r=e==null?void 0:sV(e,n);return r===void 0?t:r}var bV=CV;const xV=fa(bV);var o3={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
*/o3.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`",h="__lodash_hash_undefined__",g=500,C="__lodash_placeholder__",B=1,k=2,P=4,L=1,J=2,N=1,$=2,q=4,oe=8,ce=16,me=32,he=64,V=128,ae=256,ye=512,Oe=30,De="...",He=800,ke=16,nt=1,be=2,Bt=3,kt=1/0,Yt=9007199254740991,jt=17976931348623157e292,Xe=NaN,rt=4294967295,ot=rt-1,on=rt>>>1,gt=[["ary",V],["bind",N],["bindKey",$],["curry",oe],["curryRight",ce],["flip",ye],["partial",me],["partialRight",he],["rearg",ae]],at="[object Arguments]",It="[object Array]",Lt="[object AsyncFunction]",Me="[object Boolean]",fe="[object Date]",xe="[object DOMException]",Ue="[object Error]",et="[object Function]",it="[object GeneratorFunction]",bt="[object Map]",Ut="[object Number]",Rt="[object Null]",pt="[object Object]",rr="[object Promise]",mn="[object Proxy]",vn="[object RegExp]",Xn="[object Set]",cr="[object String]",Mr="[object Symbol]",Gr="[object Undefined]",gr="[object WeakMap]",mi="[object WeakSet]",Se="[object ArrayBuffer]",X="[object DataView]",H="[object Float32Array]",Te="[object Float64Array]",At="[object Int8Array]",St="[object Int16Array]",Et="[object Int32Array]",Nt="[object Uint8Array]",pn="[object Uint8ClampedArray]",Kn="[object Uint16Array]",En="[object Uint32Array]",m=/\b__p \+= '';/g,Kt=/\b(__p \+=) '' \+/g,Dr=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Fn=/&(?:amp|lt|gt|quot|#39);/g,Fe=/[&<>"']/g,de=RegExp(Fn.source),Ce=RegExp(Fe.source),Be=/<%-([\s\S]+?)%>/g,ze=/<%([\s\S]+?)%>/g,tt=/<%=([\s\S]+?)%>/g,lt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ft=/^\w*$/,Ve=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,xt=/[\\^$.*+?()[\]{}|]/g,Xt=RegExp(xt.source),Vt=/^\s+/,Ht=/\s/,Qn=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Mn=/\{\n\/\* \[wrapped with (.+)\] \*/,or=/,? & /,ar=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,kr=/[()=,{}\[\]\/\s]/,jr=/\\(\\)?/g,Lr=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Wr=/\w*$/,ir=/^[-+]0x[0-9a-f]+$/i,ui=/^0b[01]+$/i,Oi=/^\[object .+?Constructor\]$/,Yi=/^0o[0-7]+$/i,_o=/^(?:0|[1-9]\d*)$/,Jr=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,xo=/($^)/,Wa=/['\n\r\u2028\u2029\\]/g,Ba="\\ud800-\\udfff",bi="\\u0300-\\u036f",os="\\ufe20-\\ufe2f",hi="\\u20d0-\\u20ff",Wn=bi+os+hi,eo="\\u2700-\\u27bf",io="a-z\\xdf-\\xf6\\xf8-\\xff",qi="\\xac\\xb1\\xd7\\xf7",ve="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Ye="\\u2000-\\u206f",Jt=" \\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",sn="A-Z\\xc0-\\xd6\\xd8-\\xde",Ft="\\ufe0e\\ufe0f",Cn=qi+ve+Ye+Jt,ur="[']",fi="["+Ba+"]",ei="["+Cn+"]",Zo="["+Wn+"]",Fa="\\d+",Or="["+eo+"]",gi="["+io+"]",Ks="[^"+Ba+Cn+Fa+eo+io+sn+"]",ka="\\ud83c[\\udffb-\\udfff]",pa="(?:"+Zo+"|"+ka+")",Zl="[^"+Ba+"]",as="(?:\\ud83c[\\udde6-\\uddff]){2}",ia="[\\ud800-\\udbff][\\udc00-\\udfff]",qo="["+sn+"]",vs="\\u200d",Fu="(?:"+gi+"|"+Ks+")",ma="(?:"+qo+"|"+Ks+")",lA="(?:"+ur+"(?:d|ll|m|re|s|t|ve))?",Du="(?:"+ur+"(?:D|LL|M|RE|S|T|VE))?",Lu=pa+"?",mu="["+Ft+"]?",uA="(?:"+vs+"(?:"+[Zl,as,ia].join("|")+")"+mu+Lu+")*",Wo="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Na="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Uu=mu+Lu+uA,ss="(?:"+[Or,as,ia].join("|")+")"+Uu,ll="(?:"+[Zl+Zo+"?",Zo,as,ia,fi].join("|")+")",Do=RegExp(ur,"g"),gu=RegExp(Zo,"g"),vl=RegExp(ka+"(?="+ka+")|"+ll+Uu,"g"),_l=RegExp([qo+"?"+gi+"+"+lA+"(?="+[ei,qo,"$"].join("|")+")",ma+"+"+Du+"(?="+[ei,qo+Fu,"$"].join("|")+")",qo+"?"+Fu+"+"+lA,qo+"+"+Du,Na,Wo,Fa,ss].join("|"),"g"),Dl=RegExp("["+vs+Ba+Wn+Ft+"]"),oa=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Cl=["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"],AA=-1,go={};go[H]=go[Te]=go[At]=go[St]=go[Et]=go[Nt]=go[pn]=go[Kn]=go[En]=!0,go[at]=go[It]=go[Se]=go[Me]=go[X]=go[fe]=go[Ue]=go[et]=go[bt]=go[Ut]=go[pt]=go[vn]=go[Xn]=go[cr]=go[gr]=!1;var oo={};oo[at]=oo[It]=oo[Se]=oo[X]=oo[Me]=oo[fe]=oo[H]=oo[Te]=oo[At]=oo[St]=oo[Et]=oo[bt]=oo[Ut]=oo[pt]=oo[vn]=oo[Xn]=oo[cr]=oo[Mr]=oo[Nt]=oo[pn]=oo[Kn]=oo[En]=!0,oo[Ue]=oo[et]=oo[gr]=!1;var R={À:"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"},se={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Le={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},mt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Dn=parseFloat,en=parseInt,Sr=typeof window=="object"&&window&&window.Object===Object&&window,Ur=typeof self=="object"&&self&&self.Object===Object&&self,yr=Sr||Ur||Function("return this")(),Ir=n&&!n.nodeType&&n,Bi=Ir&&!0&&e&&!e.nodeType&&e,fo=Bi&&Bi.exports===Ir,xi=fo&&Sr.process,Hr=function(){try{var wt=Bi&&Bi.require&&Bi.require("util").types;return wt||xi&&xi.binding&&xi.binding("util")}catch{}}(),Hi=Hr&&Hr.isArrayBuffer,Io=Hr&&Hr.isDate,wo=Hr&&Hr.isMap,Ga=Hr&&Hr.isRegExp,Ll=Hr&&Hr.isSet,Xl=Hr&&Hr.isTypedArray;function ga(wt,ln,Wt){switch(Wt.length){case 0:return wt.call(ln);case 1:return wt.call(ln,Wt[0]);case 2:return wt.call(ln,Wt[0],Wt[1]);case 3:return wt.call(ln,Wt[0],Wt[1],Wt[2])}return wt.apply(ln,Wt)}function qm(wt,ln,Wt,hr){for(var ai=-1,ao=wt==null?0:wt.length;++ai<ao;){var sa=wt[ai];ln(hr,sa,Wt(sa),wt)}return hr}function Jl(wt,ln){for(var Wt=-1,hr=wt==null?0:wt.length;++Wt<hr&&ln(wt[Wt],Wt,wt)!==!1;);return wt}function mh(wt,ln){for(var Wt=wt==null?0:wt.length;Wt--&&ln(wt[Wt],Wt,wt)!==!1;);return wt}function Wc(wt,ln){for(var Wt=-1,hr=wt==null?0:wt.length;++Wt<hr;)if(!ln(wt[Wt],Wt,wt))return!1;return!0}function Ru(wt,ln){for(var Wt=-1,hr=wt==null?0:wt.length,ai=0,ao=[];++Wt<hr;){var sa=wt[Wt];ln(sa,Wt,wt)&&(ao[ai++]=sa)}return ao}function Nc(wt,ln){var Wt=wt==null?0:wt.length;return!!Wt&&No(wt,ln,0)>-1}function IA(wt,ln,Wt){for(var hr=-1,ai=wt==null?0:wt.length;++hr<ai;)if(Wt(ln,wt[hr]))return!0;return!1}function Xo(wt,ln){for(var Wt=-1,hr=wt==null?0:wt.length,ai=Array(hr);++Wt<hr;)ai[Wt]=ln(wt[Wt],Wt,wt);return ai}function zu(wt,ln){for(var Wt=-1,hr=ln.length,ai=wt.length;++Wt<hr;)wt[ai+Wt]=ln[Wt];return wt}function Od(wt,ln,Wt,hr){var ai=-1,ao=wt==null?0:wt.length;for(hr&&ao&&(Wt=wt[++ai]);++ai<ao;)Wt=ln(Wt,wt[ai],ai,wt);return Wt}function TA(wt,ln,Wt,hr){var ai=wt==null?0:wt.length;for(hr&&ai&&(Wt=wt[--ai]);ai--;)Wt=ln(Wt,wt[ai],ai,wt);return Wt}function lc(wt,ln){for(var Wt=-1,hr=wt==null?0:wt.length;++Wt<hr;)if(ln(wt[Wt],Wt,wt))return!0;return!1}var yu=ya("length");function Gc(wt){return wt.split("")}function kp(wt){return wt.match(ar)||[]}function gh(wt,ln,Wt){var hr;return Wt(wt,function(ai,ao,sa){if(ln(ai,ao,sa))return hr=ao,!1}),hr}function wi(wt,ln,Wt,hr){for(var ai=wt.length,ao=Wt+(hr?1:-1);hr?ao--:++ao<ai;)if(ln(wt[ao],ao,wt))return ao;return-1}function No(wt,ln,Wt){return ln===ln?cA(wt,ln,Wt):wi(wt,yh,Wt)}function Hm(wt,ln,Wt,hr){for(var ai=Wt-1,ao=wt.length;++ai<ao;)if(hr(wt[ai],ln))return ai;return-1}function yh(wt){return wt!==wt}function ju(wt,ln){var Wt=wt==null?0:wt.length;return Wt?To(wt,ln)/Wt:Xe}function ya(wt){return function(ln){return ln==null?t:ln[wt]}}function vh(wt){return function(ln){return wt==null?t:wt[ln]}}function Li(wt,ln,Wt,hr,ai){return ai(wt,function(ao,sa,yo){Wt=hr?(hr=!1,ao):ln(Wt,ao,sa,yo)}),Wt}function Bd(wt,ln){var Wt=wt.length;for(wt.sort(ln);Wt--;)wt[Wt]=wt[Wt].value;return wt}function To(wt,ln){for(var Wt,hr=-1,ai=wt.length;++hr<ai;){var ao=ln(wt[hr]);ao!==t&&(Wt=Wt===t?ao:Wt+ao)}return Wt}function Mo(wt,ln){for(var Wt=-1,hr=Array(wt);++Wt<wt;)hr[Wt]=ln(Wt);return hr}function uc(wt,ln){return Xo(ln,function(Wt){return[Wt,wt[Wt]]})}function Qc(wt){return wt&&wt.slice(0,bh(wt)+1).replace(Vt,"")}function Hs(wt){return function(ln){return wt(ln)}}function _h(wt,ln){return Xo(ln,function(Wt){return wt[Wt]})}function eu(wt,ln){return wt.has(ln)}function Ul(wt,ln){for(var Wt=-1,hr=wt.length;++Wt<hr&&No(ln,wt[Wt],0)>-1;);return Wt}function KA(wt,ln){for(var Wt=wt.length;Wt--&&No(ln,wt[Wt],0)>-1;);return Wt}function Ch(wt,ln){for(var Wt=wt.length,hr=0;Wt--;)wt[Wt]===ln&&++hr;return hr}var kd=vh(R),vu=vh(se);function Wu(wt){return"\\"+mt[wt]}function $c(wt,ln){return wt==null?t:wt[ln]}function PA(wt){return Dl.test(wt)}function kf(wt){return oa.test(wt)}function Ip(wt){for(var ln,Wt=[];!(ln=wt.next()).done;)Wt.push(ln.value);return Wt}function Ac(wt){var ln=-1,Wt=Array(wt.size);return wt.forEach(function(hr,ai){Wt[++ln]=[ai,hr]}),Wt}function Yc(wt,ln){return function(Wt){return wt(ln(Wt))}}function Rl(wt,ln){for(var Wt=-1,hr=wt.length,ai=0,ao=[];++Wt<hr;){var sa=wt[Wt];(sa===ln||sa===C)&&(wt[Wt]=C,ao[ai++]=Wt)}return ao}function bl(wt){var ln=-1,Wt=Array(wt.size);return wt.forEach(function(hr){Wt[++ln]=hr}),Wt}function aa(wt){var ln=-1,Wt=Array(wt.size);return wt.forEach(function(hr){Wt[++ln]=[hr,hr]}),Wt}function cA(wt,ln,Wt){for(var hr=Wt-1,ai=wt.length;++hr<ai;)if(wt[hr]===ln)return hr;return-1}function ul(wt,ln,Wt){for(var hr=Wt+1;hr--;)if(wt[hr]===ln)return hr;return hr}function FA(wt){return PA(wt)?tu(wt):yu(wt)}function xl(wt){return PA(wt)?cc(wt):Gc(wt)}function bh(wt){for(var ln=wt.length;ln--&&Ht.test(wt.charAt(ln)););return ln}var dA=vh(Le);function tu(wt){for(var ln=vl.lastIndex=0;vl.test(wt);)++ln;return ln}function cc(wt){return wt.match(vl)||[]}function Id(wt){return wt.match(_l)||[]}var Td=function wt(ln){ln=ln==null?yr:_u.defaults(yr.Object(),ln,_u.pick(yr,Cl));var Wt=ln.Array,hr=ln.Date,ai=ln.Error,ao=ln.Function,sa=ln.Math,yo=ln.Object,_s=ln.RegExp,qc=ln.String,Cs=ln.TypeError,Kd=Wt.prototype,Ps=ao.prototype,la=yo.prototype,Cu=ln["__core-js_shared__"],Fs=Ps.toString,to=la.hasOwnProperty,xh=0,wh=function(){var v=/[^.]+$/.exec(Cu&&Cu.keys&&Cu.keys.IE_PROTO||"");return v?"Symbol(src)_1."+v:""}(),wl=la.toString,DA=Fs.call(yo),Da=yr._,Vs=_s("^"+Fs.call(to).replace(xt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Nn=fo?ln.Buffer:t,zl=ln.Symbol,hA=ln.Uint8Array,dc=Nn?Nn.allocUnsafe:t,bu=Yc(yo.getPrototypeOf,yo),$n=yo.create,hc=la.propertyIsEnumerable,LA=Kd.splice,If=zl?zl.isConcatSpreadable:t,Nu=zl?zl.iterator:t,xu=zl?zl.toStringTag:t,UA=function(){try{var v=sd(yo,"defineProperty");return v({},"",{}),v}catch{}}(),Tf=ln.clearTimeout!==yr.clearTimeout&&ln.clearTimeout,fc=hr&&hr.now!==yr.Date.now&&hr.now,Gu=ln.setTimeout!==yr.setTimeout&&ln.setTimeout,So=sa.ceil,wu=sa.floor,Hc=yo.getOwnPropertySymbols,Tp=Nn?Nn.isBuffer:t,Kf=ln.isFinite,Pd=Kd.join,Mh=Yc(yo.keys,yo),so=sa.max,ua=sa.min,vr=hr.now,Tr=ln.parseInt,RA=sa.random,pc=Kd.reverse,Vc=sd(ln,"DataView"),Jo=sd(ln,"Map"),fA=sd(ln,"Promise"),Ia=sd(ln,"Set"),pA=sd(ln,"WeakMap"),Ml=sd(yo,"create"),Go=pA&&new pA,Qo={},Pf=us(Vc),Qu=us(Jo),$u=us(fA),mA=us(Ia),Ff=us(pA),Zc=zl?zl.prototype:t,Yu=Zc?Zc.valueOf:t,Sh=Zc?Zc.toString:t;function Pe(v){if(gn(v)&&!ne(v)&&!(v instanceof Yr)){if(v instanceof lo)return v;if(to.call(v,"__wrapped__"))return Ol(v)}return new lo(v)}var Sl=function(){function v(){}return function(S){if(!wn(S))return{};if($n)return $n(S);v.prototype=S;var F=new v;return v.prototype=t,F}}();function Qa(){}function lo(v,S){this.__wrapped__=v,this.__actions__=[],this.__chain__=!!S,this.__index__=0,this.__values__=t}Pe.templateSettings={escape:Be,evaluate:ze,interpolate:tt,variable:"",imports:{_:Pe}},Pe.prototype=Qa.prototype,Pe.prototype.constructor=Pe,lo.prototype=Sl(Qa.prototype),lo.prototype.constructor=lo;function Yr(v){this.__wrapped__=v,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=rt,this.__views__=[]}function va(){var v=new Yr(this.__wrapped__);return v.__actions__=Js(this.__actions__),v.__dir__=this.__dir__,v.__filtered__=this.__filtered__,v.__iteratees__=Js(this.__iteratees__),v.__takeCount__=this.__takeCount__,v.__views__=Js(this.__views__),v}function mc(){if(this.__filtered__){var v=new Yr(this);v.__dir__=-1,v.__filtered__=!0}else v=this.clone(),v.__dir__*=-1;return v}function gc(){var v=this.__wrapped__.value(),S=this.__dir__,F=ne(v),ee=S<0,we=F?v.length:0,je=av(0,we,this.__views__),ut=je.start,vt=je.end,Pt=vt-ut,yn=ee?vt:ut-1,_n=this.__iteratees__,In=_n.length,fr=0,qr=ua(Pt,this.__takeCount__);if(!F||!ee&&we==Pt&&qr==Pt)return Ph(v,this.__actions__);var yi=[];e:for(;Pt--&&fr<qr;){yn+=S;for(var uo=-1,vi=v[yn];++uo<In;){var bo=_n[uo],Po=bo.iteratee,Sc=bo.type,xA=Po(vi);if(Sc==be)vi=xA;else if(!xA){if(Sc==nt)continue e;break e}}yi[fr++]=vi}return yi}Yr.prototype=Sl(Qa.prototype),Yr.prototype.constructor=Yr;function Zs(v){var S=-1,F=v==null?0:v.length;for(this.clear();++S<F;){var ee=v[S];this.set(ee[0],ee[1])}}function Df(){this.__data__=Ml?Ml(null):{},this.size=0}function Fd(v){var S=this.has(v)&&delete this.__data__[v];return this.size-=S?1:0,S}function yc(v){var S=this.__data__;if(Ml){var F=S[v];return F===h?t:F}return to.call(S,v)?S[v]:t}function Dd(v){var S=this.__data__;return Ml?S[v]!==t:to.call(S,v)}function Eh(v,S){var F=this.__data__;return this.size+=this.has(v)?0:1,F[v]=Ml&&S===t?h:S,this}Zs.prototype.clear=Df,Zs.prototype.delete=Fd,Zs.prototype.get=yc,Zs.prototype.has=Dd,Zs.prototype.set=Eh;function El(v){var S=-1,F=v==null?0:v.length;for(this.clear();++S<F;){var ee=v[S];this.set(ee[0],ee[1])}}function Lf(){this.__data__=[],this.size=0}function O(v){var S=this.__data__,F=An(S,v);if(F<0)return!1;var ee=S.length-1;return F==ee?S.pop():LA.call(S,F,1),--this.size,!0}function u(v){var S=this.__data__,F=An(S,v);return F<0?t:S[F][1]}function p(v){return An(this.__data__,v)>-1}function _(v,S){var F=this.__data__,ee=An(F,v);return ee<0?(++this.size,F.push([v,S])):F[ee][1]=S,this}El.prototype.clear=Lf,El.prototype.delete=O,El.prototype.get=u,El.prototype.has=p,El.prototype.set=_;function M(v){var S=-1,F=v==null?0:v.length;for(this.clear();++S<F;){var ee=v[S];this.set(ee[0],ee[1])}}function I(){this.size=0,this.__data__={hash:new Zs,map:new(Jo||El),string:new Zs}}function z(v){var S=Gh(this,v).delete(v);return this.size-=S?1:0,S}function W(v){return Gh(this,v).get(v)}function Q(v){return Gh(this,v).has(v)}function re(v,S){var F=Gh(this,v),ee=F.size;return F.set(v,S),this.size+=F.size==ee?0:1,this}M.prototype.clear=I,M.prototype.delete=z,M.prototype.get=W,M.prototype.has=Q,M.prototype.set=re;function ue(v){var S=-1,F=v==null?0:v.length;for(this.__data__=new M;++S<F;)this.add(v[S])}function pe(v){return this.__data__.set(v,h),this}function Ie(v){return this.__data__.has(v)}ue.prototype.add=ue.prototype.push=pe,ue.prototype.has=Ie;function Ne(v){var S=this.__data__=new El(v);this.size=S.size}function Re(){this.__data__=new El,this.size=0}function $e(v){var S=this.__data__,F=S.delete(v);return this.size=S.size,F}function Ge(v){return this.__data__.get(v)}function ht(v){return this.__data__.has(v)}function Tt(v,S){var F=this.__data__;if(F instanceof El){var ee=F.__data__;if(!Jo||ee.length<i-1)return ee.push([v,S]),this.size=++F.size,this;F=this.__data__=new M(ee)}return F.set(v,S),this.size=F.size,this}Ne.prototype.clear=Re,Ne.prototype.delete=$e,Ne.prototype.get=Ge,Ne.prototype.has=ht,Ne.prototype.set=Tt;function Ze(v,S){var F=ne(v),ee=!F&&Z(v),we=!F&&!ee&&We(v),je=!F&&!ee&&!we&&Ns(v),ut=F||ee||we||je,vt=ut?Mo(v.length,qc):[],Pt=vt.length;for(var yn in v)(S||to.call(v,yn))&&!(ut&&(yn=="length"||we&&(yn=="offset"||yn=="parent")||je&&(yn=="buffer"||yn=="byteLength"||yn=="byteOffset")||x(yn,Pt)))&&vt.push(yn);return vt}function Ct(v){var S=v.length;return S?v[Pp(0,S-1)]:t}function $t(v,S){return qa(Js(v),Jn(S,0,v.length))}function Dt(v){return qa(Js(v))}function tn(v,S,F){(F!==t&&!K(v[S],F)||F===t&&!(S in v))&&Tn(v,S,F)}function dn(v,S,F){var ee=v[S];(!(to.call(v,S)&&K(ee,F))||F===t&&!(S in v))&&Tn(v,S,F)}function An(v,S){for(var F=v.length;F--;)if(K(v[F][0],S))return F;return-1}function bn(v,S,F,ee){return Ui(v,function(we,je,ut){S(ee,we,F(we),ut)}),ee}function tr(v,S){return v&&Vu(S,Tl(S),v)}function Pr(v,S){return v&&Vu(S,Va(S),v)}function Tn(v,S,F){S=="__proto__"&&UA?UA(v,S,{configurable:!0,enumerable:!0,value:F,writable:!0}):v[S]=F}function xr(v,S){for(var F=-1,ee=S.length,we=Wt(ee),je=v==null;++F<ee;)we[F]=je?t:Bv(v,S[F]);return we}function Jn(v,S,F){return v===v&&(F!==t&&(v=v<=F?v:F),S!==t&&(v=v>=S?v:S)),v}function Ni(v,S,F,ee,we,je){var ut,vt=S&B,Pt=S&k,yn=S&P;if(F&&(ut=we?F(v,ee,we,je):F(v)),ut!==t)return ut;if(!wn(v))return v;var _n=ne(v);if(_n){if(ut=sv(v),!vt)return Js(v,ut)}else{var In=Rs(v),fr=In==et||In==it;if(We(v))return n0(v,vt);if(In==pt||In==at||fr&&!we){if(ut=Pt||fr?{}:s0(v),!vt)return Pt?Gf(v,Pr(ut,v)):r0(v,tr(ut,v))}else{if(!oo[In])return we?v:{};ut=Qh(v,In,vt)}}je||(je=new Ne);var qr=je.get(v);if(qr)return qr;je.set(v,ut),ds(v)?v.forEach(function(vi){ut.add(Ni(vi,S,F,vi,v,je))}):lr(v)&&v.forEach(function(vi,bo){ut.set(bo,Ni(vi,S,F,bo,v,je))});var yi=yn?Pt?Wh:Gp:Pt?Va:Tl,uo=_n?t:yi(v);return Jl(uo||v,function(vi,bo){uo&&(bo=vi,vi=v[bo]),dn(ut,bo,Ni(vi,S,F,bo,v,je))}),ut}function ki(v){var S=Tl(v);return function(F){return ri(F,v,S)}}function ri(v,S,F){var ee=F.length;if(v==null)return!ee;for(v=yo(v);ee--;){var we=F[ee],je=S[we],ut=v[we];if(ut===t&&!(we in v)||!je(ut))return!1}return!0}function Mi(v,S,F){if(typeof v!="function")throw new Cs(s);return Kr(function(){v.apply(t,F)},S)}function ea(v,S,F,ee){var we=-1,je=Nc,ut=!0,vt=v.length,Pt=[],yn=S.length;if(!vt)return Pt;F&&(S=Xo(S,Hs(F))),ee?(je=IA,ut=!1):S.length>=i&&(je=eu,ut=!1,S=new ue(S));e:for(;++we<vt;){var _n=v[we],In=F==null?_n:F(_n);if(_n=ee||_n!==0?_n:0,ut&&In===In){for(var fr=yn;fr--;)if(S[fr]===In)continue e;Pt.push(_n)}else je(S,In,ee)||Pt.push(_n)}return Pt}var Ui=Nd(Us),Ds=Nd(Mu,!0);function bs(v,S){var F=!0;return Ui(v,function(ee,we,je){return F=!!S(ee,we,je),F}),F}function Ho(v,S,F){for(var ee=-1,we=v.length;++ee<we;){var je=v[ee],ut=S(je);if(ut!=null&&(vt===t?ut===ut&&!Vo(ut):F(ut,vt)))var vt=ut,Pt=je}return Pt}function Ls(v,S,F,ee){var we=v.length;for(F=Xr(F),F<0&&(F=-F>we?0:we+F),ee=ee===t||ee>we?we:Xr(ee),ee<0&&(ee+=we),ee=F>ee?0:Es(ee);F<ee;)v[F++]=S;return v}function Ta(v,S){var F=[];return Ui(v,function(ee,we,je){S(ee,we,je)&&F.push(ee)}),F}function Eo(v,S,F,ee,we){var je=-1,ut=v.length;for(F||(F=f),we||(we=[]);++je<ut;){var vt=v[je];S>0&&F(vt)?S>1?Eo(vt,S-1,F,ee,we):zu(we,vt):ee||(we[we.length]=vt)}return we}var jl=F1(),zA=F1(!0);function Us(v,S){return v&&jl(v,S,Tl)}function Mu(v,S){return v&&zA(v,S,Tl)}function Ka(v,S){return Ru(S,function(F){return Un(v[F])})}function Lo(v,S){S=id(S,v);for(var F=0,ee=S.length;v!=null&&F<ee;)v=v[Ua(S[F++])];return F&&F==ee?v:t}function Pi(v,S,F){var ee=S(v);return ne(v)?ee:zu(ee,F(v))}function vo(v){return v==null?v===t?Gr:Rt:xu&&xu in yo(v)?Yf(v):hn(v)}function Ko(v,S){return v>S}function $a(v,S){return v!=null&&to.call(v,S)}function ls(v,S){return v!=null&&S in yo(v)}function Aa(v,S,F){return v>=ua(S,F)&&v<so(S,F)}function vc(v,S,F){for(var ee=F?IA:Nc,we=v[0].length,je=v.length,ut=je,vt=Wt(je),Pt=1/0,yn=[];ut--;){var _n=v[ut];ut&&S&&(_n=Xo(_n,Hs(S))),Pt=ua(_n.length,Pt),vt[ut]=!F&&(S||we>=120&&_n.length>=120)?new ue(ut&&_n):t}_n=v[0];var In=-1,fr=vt[0];e:for(;++In<we&&yn.length<Pt;){var qr=_n[In],yi=S?S(qr):qr;if(qr=F||qr!==0?qr:0,!(fr?eu(fr,yi):ee(yn,yi,F))){for(ut=je;--ut;){var uo=vt[ut];if(!(uo?eu(uo,yi):ee(v[ut],yi,F)))continue e}fr&&fr.push(yi),yn.push(qr)}}return yn}function _a(v,S,F,ee){return Us(v,function(we,je,ut){S(ee,F(we),je,ut)}),ee}function jA(v,S,F){S=id(S,v),v=Yn(v,S);var ee=v==null?v:v[Ua(vA(S))];return ee==null?t:ga(ee,v,F)}function Oh(v){return gn(v)&&vo(v)==at}function nu(v){return gn(v)&&vo(v)==Se}function WA(v){return gn(v)&&vo(v)==fe}function Xs(v,S,F,ee,we){return v===S?!0:v==null||S==null||!gn(v)&&!gn(S)?v!==v&&S!==S:Ld(v,S,F,ee,Xs,we)}function Ld(v,S,F,ee,we,je){var ut=ne(v),vt=ne(S),Pt=ut?It:Rs(v),yn=vt?It:Rs(S);Pt=Pt==at?pt:Pt,yn=yn==at?pt:yn;var _n=Pt==pt,In=yn==pt,fr=Pt==yn;if(fr&&We(v)){if(!We(S))return!1;ut=!0,_n=!1}if(fr&&!_n)return je||(je=new Ne),ut||Ns(v)?Ou(v,S,F,ee,we,je):Np(v,S,Pt,F,ee,we,je);if(!(F&L)){var qr=_n&&to.call(v,"__wrapped__"),yi=In&&to.call(S,"__wrapped__");if(qr||yi){var uo=qr?v.value():v,vi=yi?S.value():S;return je||(je=new Ne),we(uo,vi,F,ee,je)}}return fr?(je||(je=new Ne),a0(v,S,F,ee,we,je)):!1}function _c(v){return gn(v)&&Rs(v)==bt}function Bh(v,S,F,ee){var we=F.length,je=we,ut=!ee;if(v==null)return!je;for(v=yo(v);we--;){var vt=F[we];if(ut&&vt[2]?vt[1]!==v[vt[0]]:!(vt[0]in v))return!1}for(;++we<je;){vt=F[we];var Pt=vt[0],yn=v[Pt],_n=vt[1];if(ut&&vt[2]){if(yn===t&&!(Pt in v))return!1}else{var In=new Ne;if(ee)var fr=ee(yn,_n,Pt,v,S,In);if(!(fr===t?Xs(_n,yn,L|J,ee,In):fr))return!1}}return!0}function qu(v){if(!wn(v)||te(v))return!1;var S=Un(v)?Vs:Oi;return S.test(us(v))}function Uf(v){return gn(v)&&vo(v)==vn}function Xc(v){return gn(v)&&Rs(v)==Xn}function B1(v){return gn(v)&&qn(v.length)&&!!go[vo(v)]}function Jc(v){return typeof v=="function"?v:v==null?VA:typeof v=="object"?ne(v)?Th(v[0],v[1]):Ih(v):Ek(v)}function ed(v){if(!ge(v))return Mh(v);var S=[];for(var F in yo(v))to.call(v,F)&&F!="constructor"&&S.push(F);return S}function kh(v){if(!wn(v))return zt(v);var S=ge(v),F=[];for(var ee in v)ee=="constructor"&&(S||!to.call(v,ee))||F.push(ee);return F}function Hu(v,S){return v<S}function Vm(v,S){var F=-1,ee=_e(v)?Wt(v.length):[];return Ui(v,function(we,je,ut){ee[++F]=S(we,je,ut)}),ee}function Ih(v){var S=Oo(v);return S.length==1&&S[0][2]?Je(S[0][0],S[0][1]):function(F){return F===v||Bh(F,v,S)}}function Th(v,S){return E(v)&&Qe(S)?Je(Ua(v),S):function(F){var ee=Bv(F,v);return ee===t&&ee===S?kv(F,v):Xs(S,ee,L|J)}}function ru(v,S,F,ee,we){v!==S&&jl(S,function(je,ut){if(we||(we=new Ne),wn(je))Ud(v,S,ut,F,ru,ee,we);else{var vt=ee?ee(Ln(v,ut),je,ut+"",v,S,we):t;vt===t&&(vt=je),tn(v,ut,vt)}},Va)}function Ud(v,S,F,ee,we,je,ut){var vt=Ln(v,F),Pt=Ln(S,F),yn=ut.get(Pt);if(yn){tn(v,F,yn);return}var _n=je?je(vt,Pt,F+"",v,S,ut):t,In=_n===t;if(In){var fr=ne(Pt),qr=!fr&&We(Pt),yi=!fr&&!qr&&Ns(Pt);_n=Pt,fr||qr||yi?ne(vt)?_n=vt:Ee(vt)?_n=Js(vt):qr?(In=!1,_n=n0(Pt,!0)):yi?(In=!1,_n=Ca(Pt,!0)):_n=[]:Ra(Pt)||Z(Pt)?(_n=vt,Z(vt)?_n=kl(vt):(!wn(vt)||Un(vt))&&(_n=s0(Pt))):In=!1}In&&(ut.set(Pt,_n),we(_n,Pt,ee,je,ut),ut.delete(Pt)),tn(v,F,_n)}function Rd(v,S){var F=v.length;if(F)return S+=S<0?F:0,x(S,F)?v[S]:t}function k1(v,S,F){S.length?S=Xo(S,function(je){return ne(je)?function(ut){return Lo(ut,je.length===1?je[0]:je)}:je}):S=[VA];var ee=-1;S=Xo(S,Hs(Zr()));var we=Vm(v,function(je,ut,vt){var Pt=Xo(S,function(yn){return yn(je)});return{criteria:Pt,index:++ee,value:je}});return Bd(we,function(je,ut){return P1(je,ut,F)})}function Al(v,S){return zd(v,S,function(F,ee){return kv(v,ee)})}function zd(v,S,F){for(var ee=-1,we=S.length,je={};++ee<we;){var ut=S[ee],vt=Lo(v,ut);F(vt,ut)&&Kh(je,id(ut,v),vt)}return je}function Zm(v){return function(S){return Lo(S,v)}}function Kp(v,S,F,ee){var we=ee?Hm:No,je=-1,ut=S.length,vt=v;for(v===S&&(S=Js(S)),F&&(vt=Xo(v,Hs(F)));++je<ut;)for(var Pt=0,yn=S[je],_n=F?F(yn):yn;(Pt=we(vt,_n,Pt,ee))>-1;)vt!==v&&LA.call(vt,Pt,1),LA.call(v,Pt,1);return v}function xs(v,S){for(var F=v?S.length:0,ee=F-1;F--;){var we=S[F];if(F==ee||we!==je){var je=we;x(we)?LA.call(v,we,1):Lp(v,we)}}return v}function Pp(v,S){return v+wu(RA()*(S-v+1))}function Fp(v,S,F,ee){for(var we=-1,je=so(So((S-v)/(F||1)),0),ut=Wt(je);je--;)ut[ee?je:++we]=v,v+=F;return ut}function Xm(v,S){var F="";if(!v||S<1||S>Yt)return F;do S%2&&(F+=v),S=wu(S/2),S&&(v+=v);while(S);return F}function Gi(v,S){return _r(kn(v,S,VA),v+"")}function Jm(v){return Ct(og(v))}function e0(v,S){var F=og(v);return qa(F,Jn(S,0,F.length))}function Kh(v,S,F,ee){if(!wn(v))return v;S=id(S,v);for(var we=-1,je=S.length,ut=je-1,vt=v;vt!=null&&++we<je;){var Pt=Ua(S[we]),yn=F;if(Pt==="__proto__"||Pt==="constructor"||Pt==="prototype")return v;if(we!=ut){var _n=vt[Pt];yn=ee?ee(_n,Pt,vt):t,yn===t&&(yn=wn(_n)?_n:x(S[we+1])?[]:{})}dn(vt,Pt,yn),vt=vt[Pt]}return v}var Dp=Go?function(v,S){return Go.set(v,S),v}:VA,I1=UA?function(v,S){return UA(v,"toString",{configurable:!0,enumerable:!1,value:Tw(S),writable:!0})}:VA;function t0(v){return qa(og(v))}function La(v,S,F){var ee=-1,we=v.length;S<0&&(S=-S>we?0:we+S),F=F>we?we:F,F<0&&(F+=we),we=S>F?0:F-S>>>0,S>>>=0;for(var je=Wt(we);++ee<we;)je[ee]=v[ee+S];return je}function cl(v,S){var F;return Ui(v,function(ee,we,je){return F=S(ee,we,je),!F}),!!F}function td(v,S,F){var ee=0,we=v==null?ee:v.length;if(typeof S=="number"&&S===S&&we<=on){for(;ee<we;){var je=ee+we>>>1,ut=v[je];ut!==null&&!Vo(ut)&&(F?ut<=S:ut<S)?ee=je+1:we=je}return we}return jd(v,S,VA,F)}function jd(v,S,F,ee){var we=0,je=v==null?0:v.length;if(je===0)return 0;S=F(S);for(var ut=S!==S,vt=S===null,Pt=Vo(S),yn=S===t;we<je;){var _n=wu((we+je)/2),In=F(v[_n]),fr=In!==t,qr=In===null,yi=In===In,uo=Vo(In);if(ut)var vi=ee||yi;else yn?vi=yi&&(ee||fr):vt?vi=yi&&fr&&(ee||!qr):Pt?vi=yi&&fr&&!qr&&(ee||!uo):qr||uo?vi=!1:vi=ee?In<=S:In<S;vi?we=_n+1:je=_n}return ua(je,ot)}function gA(v,S){for(var F=-1,ee=v.length,we=0,je=[];++F<ee;){var ut=v[F],vt=S?S(ut):ut;if(!F||!K(vt,Pt)){var Pt=vt;je[we++]=ut===0?0:ut}}return je}function T1(v){return typeof v=="number"?v:Vo(v)?Xe:+v}function Su(v){if(typeof v=="string")return v;if(ne(v))return Xo(v,Su)+"";if(Vo(v))return Sh?Sh.call(v):"";var S=v+"";return S=="0"&&1/v==-kt?"-0":S}function Eu(v,S,F){var ee=-1,we=Nc,je=v.length,ut=!0,vt=[],Pt=vt;if(F)ut=!1,we=IA;else if(je>=i){var yn=S?null:L1(v);if(yn)return bl(yn);ut=!1,we=eu,Pt=new ue}else Pt=S?[]:vt;e:for(;++ee<je;){var _n=v[ee],In=S?S(_n):_n;if(_n=F||_n!==0?_n:0,ut&&In===In){for(var fr=Pt.length;fr--;)if(Pt[fr]===In)continue e;S&&Pt.push(In),vt.push(_n)}else we(Pt,In,F)||(Pt!==vt&&Pt.push(In),vt.push(_n))}return vt}function Lp(v,S){return S=id(S,v),v=Yn(v,S),v==null||delete v[Ua(vA(S))]}function Rf(v,S,F,ee){return Kh(v,S,F(Lo(v,S)),ee)}function nd(v,S,F,ee){for(var we=v.length,je=ee?we:-1;(ee?je--:++je<we)&&S(v[je],je,v););return F?La(v,ee?0:je,ee?je+1:we):La(v,ee?je+1:0,ee?we:je)}function Ph(v,S){var F=v;return F instanceof Yr&&(F=F.value()),Od(S,function(ee,we){return we.func.apply(we.thisArg,zu([ee],we.args))},F)}function iu(v,S,F){var ee=v.length;if(ee<2)return ee?Eu(v[0]):[];for(var we=-1,je=Wt(ee);++we<ee;)for(var ut=v[we],vt=-1;++vt<ee;)vt!=we&&(je[we]=ea(je[we]||ut,v[vt],S,F));return Eu(Eo(je,1),S,F)}function rd(v,S,F){for(var ee=-1,we=v.length,je=S.length,ut={};++ee<we;){var vt=ee<je?S[ee]:t;F(ut,v[ee],vt)}return ut}function zf(v){return Ee(v)?v:[]}function jf(v){return typeof v=="function"?v:VA}function id(v,S){return ne(v)?v:E(v,S)?[v]:ba(ci(v))}var Wf=Gi;function Cc(v,S,F){var ee=v.length;return F=F===t?ee:F,!S&&F>=ee?v:La(v,S,F)}var K1=Tf||function(v){return yr.clearTimeout(v)};function n0(v,S){if(S)return v.slice();var F=v.length,ee=dc?dc(F):new v.constructor(F);return v.copy(ee),ee}function od(v){var S=new v.constructor(v.byteLength);return new hA(S).set(new hA(v)),S}function iv(v,S){var F=S?od(v.buffer):v.buffer;return new v.constructor(F,v.byteOffset,v.byteLength)}function Fh(v){var S=new v.constructor(v.source,Wr.exec(v));return S.lastIndex=v.lastIndex,S}function Nf(v){return Yu?yo(Yu.call(v)):{}}function Ca(v,S){var F=S?od(v.buffer):v.buffer;return new v.constructor(F,v.byteOffset,v.length)}function Dh(v,S){if(v!==S){var F=v!==t,ee=v===null,we=v===v,je=Vo(v),ut=S!==t,vt=S===null,Pt=S===S,yn=Vo(S);if(!vt&&!yn&&!je&&v>S||je&&ut&&Pt&&!vt&&!yn||ee&&ut&&Pt||!F&&Pt||!we)return 1;if(!ee&&!je&&!yn&&v<S||yn&&F&&we&&!ee&&!je||vt&&F&&we||!ut&&we||!Pt)return-1}return 0}function P1(v,S,F){for(var ee=-1,we=v.criteria,je=S.criteria,ut=we.length,vt=F.length;++ee<ut;){var Pt=Dh(we[ee],je[ee]);if(Pt){if(ee>=vt)return Pt;var yn=F[ee];return Pt*(yn=="desc"?-1:1)}}return v.index-S.index}function Wd(v,S,F,ee){for(var we=-1,je=v.length,ut=F.length,vt=-1,Pt=S.length,yn=so(je-ut,0),_n=Wt(Pt+yn),In=!ee;++vt<Pt;)_n[vt]=S[vt];for(;++we<ut;)(In||we<je)&&(_n[F[we]]=v[we]);for(;yn--;)_n[vt++]=v[we++];return _n}function Lh(v,S,F,ee){for(var we=-1,je=v.length,ut=-1,vt=F.length,Pt=-1,yn=S.length,_n=so(je-vt,0),In=Wt(_n+yn),fr=!ee;++we<_n;)In[we]=v[we];for(var qr=we;++Pt<yn;)In[qr+Pt]=S[Pt];for(;++ut<vt;)(fr||we<je)&&(In[qr+F[ut]]=v[we++]);return In}function Js(v,S){var F=-1,ee=v.length;for(S||(S=Wt(ee));++F<ee;)S[F]=v[F];return S}function Vu(v,S,F,ee){var we=!F;F||(F={});for(var je=-1,ut=S.length;++je<ut;){var vt=S[je],Pt=ee?ee(F[vt],v[vt],vt,F,v):t;Pt===t&&(Pt=v[vt]),we?Tn(F,vt,Pt):dn(F,vt,Pt)}return F}function r0(v,S){return Vu(v,xc(v),S)}function Gf(v,S){return Vu(v,R1(v),S)}function ad(v,S){return function(F,ee){var we=ne(F)?qm:bn,je=S?S():{};return we(F,v,Zr(ee,2),je)}}function Zu(v){return Gi(function(S,F){var ee=-1,we=F.length,je=we>1?F[we-1]:t,ut=we>2?F[2]:t;for(je=v.length>3&&typeof je=="function"?(we--,je):t,ut&&b(F[0],F[1],ut)&&(je=we<3?t:je,we=1),S=yo(S);++ee<we;){var vt=F[ee];vt&&v(S,vt,ee,je)}return S})}function Nd(v,S){return function(F,ee){if(F==null)return F;if(!_e(F))return v(F,ee);for(var we=F.length,je=S?we:-1,ut=yo(F);(S?je--:++je<we)&&ee(ut[je],je,ut)!==!1;);return F}}function F1(v){return function(S,F,ee){for(var we=-1,je=yo(S),ut=ee(S),vt=ut.length;vt--;){var Pt=ut[v?vt:++we];if(F(je[Pt],Pt,je)===!1)break}return S}}function i0(v,S,F){var ee=S&N,we=Gd(v);function je(){var ut=this&&this!==yr&&this instanceof je?we:v;return ut.apply(ee?F:this,arguments)}return je}function Uh(v){return function(S){S=ci(S);var F=PA(S)?xl(S):t,ee=F?F[0]:S.charAt(0),we=F?Cc(F,1).join(""):S.slice(1);return ee[v]()+we}}function Rh(v){return function(S){return Od(Mk(wk(S).replace(Do,"")),v,"")}}function Gd(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=Sl(v.prototype),ee=v.apply(F,S);return wn(ee)?ee:F}}function ov(v,S,F){var ee=Gd(v);function we(){for(var je=arguments.length,ut=Wt(je),vt=je,Pt=Nh(we);vt--;)ut[vt]=arguments[vt];var yn=je<3&&ut[0]!==Pt&&ut[je-1]!==Pt?[]:Rl(ut,Pt);if(je-=yn.length,je<F)return Xu(v,S,zh,we.placeholder,t,ut,yn,t,t,F-je);var _n=this&&this!==yr&&this instanceof we?ee:v;return ga(_n,this,ut)}return we}function Qf(v){return function(S,F,ee){var we=yo(S);if(!_e(S)){var je=Zr(F,3);S=Tl(S),F=function(vt){return je(we[vt],vt,we)}}var ut=v(S,F,ee);return ut>-1?we[je?S[ut]:ut]:t}}function Up(v){return NA(function(S){var F=S.length,ee=F,we=lo.prototype.thru;for(v&&S.reverse();ee--;){var je=S[ee];if(typeof je!="function")throw new Cs(s);if(we&&!ut&&qd(je)=="wrapper")var ut=new lo([],!0)}for(ee=ut?ee:F;++ee<F;){je=S[ee];var vt=qd(je),Pt=vt=="wrapper"?bc(je):t;Pt&&Y(Pt[0])&&Pt[1]==(V|oe|me|ae)&&!Pt[4].length&&Pt[9]==1?ut=ut[qd(Pt[0])].apply(ut,Pt[3]):ut=je.length==1&&Y(je)?ut[vt]():ut.thru(je)}return function(){var yn=arguments,_n=yn[0];if(ut&&yn.length==1&&ne(_n))return ut.plant(_n).value();for(var In=0,fr=F?S[In].apply(this,yn):_n;++In<F;)fr=S[In].call(this,fr);return fr}})}function zh(v,S,F,ee,we,je,ut,vt,Pt,yn){var _n=S&V,In=S&N,fr=S&$,qr=S&(oe|ce),yi=S&ye,uo=fr?t:Gd(v);function vi(){for(var bo=arguments.length,Po=Wt(bo),Sc=bo;Sc--;)Po[Sc]=arguments[Sc];if(qr)var xA=Nh(vi),Ec=Ch(Po,xA);if(ee&&(Po=Wd(Po,ee,we,qr)),je&&(Po=Lh(Po,je,ut,qr)),bo-=Ec,qr&&bo<yn){var dl=Rl(Po,xA);return Xu(v,S,zh,vi.placeholder,F,Po,dl,vt,Pt,yn-bo)}var th=In?F:this,Vf=fr?th[v]:v;return bo=Po.length,vt?Po=xn(Po,vt):yi&&bo>1&&Po.reverse(),_n&&Pt<bo&&(Po.length=Pt),this&&this!==yr&&this instanceof vi&&(Vf=uo||Gd(Vf)),Vf.apply(th,Po)}return vi}function Rp(v,S){return function(F,ee){return _a(F,v,S(ee),{})}}function Qd(v,S){return function(F,ee){var we;if(F===t&&ee===t)return S;if(F!==t&&(we=F),ee!==t){if(we===t)return ee;typeof F=="string"||typeof ee=="string"?(F=Su(F),ee=Su(ee)):(F=T1(F),ee=T1(ee)),we=v(F,ee)}return we}}function zp(v){return NA(function(S){return S=Xo(S,Hs(Zr())),Gi(function(F){var ee=this;return v(S,function(we){return ga(we,ee,F)})})})}function jp(v,S){S=S===t?" ":Su(S);var F=S.length;if(F<2)return F?Xm(S,v):S;var ee=Xm(S,So(v/FA(S)));return PA(S)?Cc(xl(ee),0,v).join(""):ee.slice(0,v)}function D1(v,S,F,ee){var we=S&N,je=Gd(v);function ut(){for(var vt=-1,Pt=arguments.length,yn=-1,_n=ee.length,In=Wt(_n+Pt),fr=this&&this!==yr&&this instanceof ut?je:v;++yn<_n;)In[yn]=ee[yn];for(;Pt--;)In[yn++]=arguments[++vt];return ga(fr,we?F:this,In)}return ut}function $d(v){return function(S,F,ee){return ee&&typeof ee!="number"&&b(S,F,ee)&&(F=ee=t),S=hs(S),F===t?(F=S,S=0):F=hs(F),ee=ee===t?S<F?1:-1:hs(ee),Fp(S,F,ee,v)}}function $f(v){return function(S,F){return typeof S=="string"&&typeof F=="string"||(S=ii(S),F=ii(F)),v(S,F)}}function Xu(v,S,F,ee,we,je,ut,vt,Pt,yn){var _n=S&oe,In=_n?ut:t,fr=_n?t:ut,qr=_n?je:t,yi=_n?t:je;S|=_n?me:he,S&=~(_n?he:me),S&q||(S&=~(N|$));var uo=[v,S,we,qr,In,yi,fr,vt,Pt,yn],vi=F.apply(t,uo);return Y(v)&&sr(vi,uo),vi.placeholder=ee,Ai(vi,v,S)}function o0(v){var S=sa[v];return function(F,ee){if(F=ii(F),ee=ee==null?0:ua(Xr(ee),292),ee&&Kf(F)){var we=(ci(F)+"e").split("e"),je=S(we[0]+"e"+(+we[1]+ee));return we=(ci(je)+"e").split("e"),+(we[0]+"e"+(+we[1]-ee))}return S(F)}}var L1=Ia&&1/bl(new Ia([,-0]))[1]==kt?function(v){return new Ia(v)}:Fw;function Yd(v){return function(S){var F=Rs(S);return F==bt?Ac(S):F==Xn?aa(S):uc(S,v(S))}}function Co(v,S,F,ee,we,je,ut,vt){var Pt=S&$;if(!Pt&&typeof v!="function")throw new Cs(s);var yn=ee?ee.length:0;if(yn||(S&=~(me|he),ee=we=t),ut=ut===t?ut:so(Xr(ut),0),vt=vt===t?vt:Xr(vt),yn-=we?we.length:0,S&he){var _n=ee,In=we;ee=we=t}var fr=Pt?t:bc(v),qr=[v,S,F,ee,we,_n,In,je,ut,vt];if(fr&&yt(qr,fr),v=qr[0],S=qr[1],F=qr[2],ee=qr[3],we=qr[4],vt=qr[9]=qr[9]===t?Pt?0:v.length:so(qr[9]-yn,0),!vt&&S&(oe|ce)&&(S&=~(oe|ce)),!S||S==N)var yi=i0(v,S,F);else S==oe||S==ce?yi=ov(v,S,vt):(S==me||S==(N|me))&&!we.length?yi=D1(v,S,F,ee):yi=zh.apply(t,qr);var uo=fr?Dp:sr;return Ai(uo(yi,qr),v,S)}function U1(v,S,F,ee){return v===t||K(v,la[F])&&!to.call(ee,F)?S:v}function Wp(v,S,F,ee,we,je){return wn(v)&&wn(S)&&(je.set(S,v),ru(v,S,t,Wp,je),je.delete(S)),v}function jh(v){return Ra(v)?t:v}function Ou(v,S,F,ee,we,je){var ut=F&L,vt=v.length,Pt=S.length;if(vt!=Pt&&!(ut&&Pt>vt))return!1;var yn=je.get(v),_n=je.get(S);if(yn&&_n)return yn==S&&_n==v;var In=-1,fr=!0,qr=F&J?new ue:t;for(je.set(v,S),je.set(S,v);++In<vt;){var yi=v[In],uo=S[In];if(ee)var vi=ut?ee(uo,yi,In,S,v,je):ee(yi,uo,In,v,S,je);if(vi!==t){if(vi)continue;fr=!1;break}if(qr){if(!lc(S,function(bo,Po){if(!eu(qr,Po)&&(yi===bo||we(yi,bo,F,ee,je)))return qr.push(Po)})){fr=!1;break}}else if(!(yi===uo||we(yi,uo,F,ee,je))){fr=!1;break}}return je.delete(v),je.delete(S),fr}function Np(v,S,F,ee,we,je,ut){switch(F){case X:if(v.byteLength!=S.byteLength||v.byteOffset!=S.byteOffset)return!1;v=v.buffer,S=S.buffer;case Se:return!(v.byteLength!=S.byteLength||!je(new hA(v),new hA(S)));case Me:case fe:case Ut:return K(+v,+S);case Ue:return v.name==S.name&&v.message==S.message;case vn:case cr:return v==S+"";case bt:var vt=Ac;case Xn:var Pt=ee&L;if(vt||(vt=bl),v.size!=S.size&&!Pt)return!1;var yn=ut.get(v);if(yn)return yn==S;ee|=J,ut.set(v,S);var _n=Ou(vt(v),vt(S),ee,we,je,ut);return ut.delete(v),_n;case Mr:if(Yu)return Yu.call(v)==Yu.call(S)}return!1}function a0(v,S,F,ee,we,je){var ut=F&L,vt=Gp(v),Pt=vt.length,yn=Gp(S),_n=yn.length;if(Pt!=_n&&!ut)return!1;for(var In=Pt;In--;){var fr=vt[In];if(!(ut?fr in S:to.call(S,fr)))return!1}var qr=je.get(v),yi=je.get(S);if(qr&&yi)return qr==S&&yi==v;var uo=!0;je.set(v,S),je.set(S,v);for(var vi=ut;++In<Pt;){fr=vt[In];var bo=v[fr],Po=S[fr];if(ee)var Sc=ut?ee(Po,bo,fr,S,v,je):ee(bo,Po,fr,v,S,je);if(!(Sc===t?bo===Po||we(bo,Po,F,ee,je):Sc)){uo=!1;break}vi||(vi=fr=="constructor")}if(uo&&!vi){var xA=v.constructor,Ec=S.constructor;xA!=Ec&&"constructor"in v&&"constructor"in S&&!(typeof xA=="function"&&xA instanceof xA&&typeof Ec=="function"&&Ec instanceof Ec)&&(uo=!1)}return je.delete(v),je.delete(S),uo}function NA(v){return _r(kn(v,t,Ha),v+"")}function Gp(v){return Pi(v,Tl,xc)}function Wh(v){return Pi(v,Va,R1)}var bc=Go?function(v){return Go.get(v)}:Fw;function qd(v){for(var S=v.name+"",F=Qo[S],ee=to.call(Qo,S)?F.length:0;ee--;){var we=F[ee],je=we.func;if(je==null||je==v)return we.name}return S}function Nh(v){var S=to.call(Pe,"placeholder")?Pe:v;return S.placeholder}function Zr(){var v=Pe.iteratee||Kw;return v=v===Kw?Jc:v,arguments.length?v(arguments[0],arguments[1]):v}function Gh(v,S){var F=v.__data__;return U(S)?F[typeof S=="string"?"string":"hash"]:F.map}function Oo(v){for(var S=Tl(v),F=S.length;F--;){var ee=S[F],we=v[ee];S[F]=[ee,we,Qe(we)]}return S}function sd(v,S){var F=$c(v,S);return qu(F)?F:t}function Yf(v){var S=to.call(v,xu),F=v[xu];try{v[xu]=t;var ee=!0}catch{}var we=wl.call(v);return ee&&(S?v[xu]=F:delete v[xu]),we}var xc=Hc?function(v){return v==null?[]:(v=yo(v),Ru(Hc(v),function(S){return hc.call(v,S)}))}:Dw,R1=Hc?function(v){for(var S=[];v;)zu(S,xc(v)),v=bu(v);return S}:Dw,Rs=vo;(Vc&&Rs(new Vc(new ArrayBuffer(1)))!=X||Jo&&Rs(new Jo)!=bt||fA&&Rs(fA.resolve())!=rr||Ia&&Rs(new Ia)!=Xn||pA&&Rs(new pA)!=gr)&&(Rs=function(v){var S=vo(v),F=S==pt?v.constructor:t,ee=F?us(F):"";if(ee)switch(ee){case Pf:return X;case Qu:return bt;case $u:return rr;case mA:return Xn;case Ff:return gr}return S});function av(v,S,F){for(var ee=-1,we=F.length;++ee<we;){var je=F[ee],ut=je.size;switch(je.type){case"drop":v+=ut;break;case"dropRight":S-=ut;break;case"take":S=ua(S,v+ut);break;case"takeRight":v=so(v,S-ut);break}}return{start:v,end:S}}function Ya(v){var S=v.match(Mn);return S?S[1].split(or):[]}function z1(v,S,F){S=id(S,v);for(var ee=-1,we=S.length,je=!1;++ee<we;){var ut=Ua(S[ee]);if(!(je=v!=null&&F(v,ut)))break;v=v[ut]}return je||++ee!=we?je:(we=v==null?0:v.length,!!we&&qn(we)&&x(ut,we)&&(ne(v)||Z(v)))}function sv(v){var S=v.length,F=new v.constructor(S);return S&&typeof v[0]=="string"&&to.call(v,"index")&&(F.index=v.index,F.input=v.input),F}function s0(v){return typeof v.constructor=="function"&&!ge(v)?Sl(bu(v)):{}}function Qh(v,S,F){var ee=v.constructor;switch(S){case Se:return od(v);case Me:case fe:return new ee(+v);case X:return iv(v,F);case H:case Te:case At:case St:case Et:case Nt:case pn:case Kn:case En:return Ca(v,F);case bt:return new ee;case Ut:case cr:return new ee(v);case vn:return Fh(v);case Xn:return new ee;case Mr:return Nf(v)}}function A(v,S){var F=S.length;if(!F)return v;var ee=F-1;return S[ee]=(F>1?"& ":"")+S[ee],S=S.join(F>2?", ":" "),v.replace(Qn,`{
/* [wrapped with `+S+`] */
`)}function f(v){return ne(v)||Z(v)||!!(If&&v&&v[If])}function x(v,S){var F=typeof v;return S=S??Yt,!!S&&(F=="number"||F!="symbol"&&_o.test(v))&&v>-1&&v%1==0&&v<S}function b(v,S,F){if(!wn(F))return!1;var ee=typeof S;return(ee=="number"?_e(F)&&x(S,F.length):ee=="string"&&S in F)?K(F[S],v):!1}function E(v,S){if(ne(v))return!1;var F=typeof v;return F=="number"||F=="symbol"||F=="boolean"||v==null||Vo(v)?!0:ft.test(v)||!lt.test(v)||S!=null&&v in yo(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=qd(v),F=Pe[S];if(typeof F!="function"||!(S in Yr.prototype))return!1;if(v===F)return!0;var ee=bc(F);return!!ee&&v===ee[0]}function te(v){return!!wh&&wh in v}var le=Cu?Un:Lw;function ge(v){var S=v&&v.constructor,F=typeof S=="function"&&S.prototype||la;return v===F}function Qe(v){return v===v&&!wn(v)}function Je(v,S){return function(F){return F==null?!1:F[v]===S&&(S!==t||v in yo(F))}}function Mt(v){var S=Vp(v,function(ee){return F.size===g&&F.clear(),ee}),F=S.cache;return S}function yt(v,S){var F=v[1],ee=S[1],we=F|ee,je=we<(N|$|V),ut=ee==V&&F==oe||ee==V&&F==ae&&v[7].length<=S[8]||ee==(V|ae)&&S[7].length<=S[8]&&F==oe;if(!(je||ut))return v;ee&N&&(v[2]=S[2],we|=F&N?0:q);var vt=S[3];if(vt){var Pt=v[3];v[3]=Pt?Wd(Pt,vt,S[4]):vt,v[4]=Pt?Rl(v[3],C):S[4]}return vt=S[5],vt&&(Pt=v[5],v[5]=Pt?Lh(Pt,vt,S[6]):vt,v[6]=Pt?Rl(v[5],C):S[6]),vt=S[7],vt&&(v[7]=vt),ee&V&&(v[8]=v[8]==null?S[8]:ua(v[8],S[8])),v[9]==null&&(v[9]=S[9]),v[0]=S[0],v[1]=we,v}function zt(v){var S=[];if(v!=null)for(var F in yo(v))S.push(F);return S}function hn(v){return wl.call(v)}function kn(v,S,F){return S=so(S===t?v.length-1:S,0),function(){for(var ee=arguments,we=-1,je=so(ee.length-S,0),ut=Wt(je);++we<je;)ut[we]=ee[S+we];we=-1;for(var vt=Wt(S+1);++we<S;)vt[we]=ee[we];return vt[S]=F(ut),ga(v,this,vt)}}function Yn(v,S){return S.length<2?v:Lo(v,La(S,0,-1))}function xn(v,S){for(var F=v.length,ee=ua(S.length,F),we=Js(v);ee--;){var je=S[ee];v[ee]=x(je,F)?we[je]:t}return v}function Ln(v,S){if(!(S==="constructor"&&typeof v[S]=="function")&&S!="__proto__")return v[S]}var sr=Uo(Dp),Kr=Gu||function(v,S){return yr.setTimeout(v,S)},_r=Uo(I1);function Ai(v,S,F){var ee=S+"";return _r(v,A(ee,As(Ya(ee),F)))}function Uo(v){var S=0,F=0;return function(){var ee=vr(),we=ke-(ee-F);if(F=ee,we>0){if(++S>=He)return arguments[0]}else S=0;return v.apply(t,arguments)}}function qa(v,S){var F=-1,ee=v.length,we=ee-1;for(S=S===t?ee:S;++F<S;){var je=Pp(F,we),ut=v[je];v[je]=v[F],v[F]=ut}return v.length=S,v}var ba=Mt(function(v){var S=[];return v.charCodeAt(0)===46&&S.push(""),v.replace(Ve,function(F,ee,we,je){S.push(we?je.replace(jr,"$1"):ee||F)}),S});function Ua(v){if(typeof v=="string"||Vo(v))return v;var S=v+"";return S=="0"&&1/v==-kt?"-0":S}function us(v){if(v!=null){try{return Fs.call(v)}catch{}try{return v+""}catch{}}return""}function As(v,S){return Jl(gt,function(F){var ee="_."+F[0];S&F[1]&&!Nc(v,ee)&&v.push(ee)}),v.sort()}function Ol(v){if(v instanceof Yr)return v.clone();var S=new lo(v.__wrapped__,v.__chain__);return S.__actions__=Js(v.__actions__),S.__index__=v.__index__,S.__values__=v.__values__,S}function el(v,S,F){(F?b(v,S,F):S===t)?S=1:S=so(Xr(S),0);var ee=v==null?0:v.length;if(!ee||S<1)return[];for(var we=0,je=0,ut=Wt(So(ee/S));we<ee;)ut[je++]=La(v,we,we+=S);return ut}function ws(v){for(var S=-1,F=v==null?0:v.length,ee=0,we=[];++S<F;){var je=v[S];je&&(we[ee++]=je)}return we}function cs(){var v=arguments.length;if(!v)return[];for(var S=Wt(v-1),F=arguments[0],ee=v;ee--;)S[ee-1]=arguments[ee];return zu(ne(F)?Js(F):[F],Eo(S,1))}var ca=Gi(function(v,S){return Ee(v)?ea(v,Eo(S,1,Ee,!0)):[]}),Ms=Gi(function(v,S){var F=vA(S);return Ee(F)&&(F=t),Ee(v)?ea(v,Eo(S,1,Ee,!0),Zr(F,2)):[]}),Hd=Gi(function(v,S){var F=vA(S);return Ee(F)&&(F=t),Ee(v)?ea(v,Eo(S,1,Ee,!0),t,F):[]});function GA(v,S,F){var ee=v==null?0:v.length;return ee?(S=F||S===t?1:Xr(S),La(v,S<0?0:S,ee)):[]}function zs(v,S,F){var ee=v==null?0:v.length;return ee?(S=F||S===t?1:Xr(S),S=ee-S,La(v,0,S<0?0:S)):[]}function QA(v,S){return v&&v.length?nd(v,Zr(S,3),!0,!0):[]}function js(v,S){return v&&v.length?nd(v,Zr(S,3),!0):[]}function l0(v,S,F,ee){var we=v==null?0:v.length;return we?(F&&typeof F!="number"&&b(v,S,F)&&(F=0,ee=we),Ls(v,S,F,ee)):[]}function yA(v,S,F){var ee=v==null?0:v.length;if(!ee)return-1;var we=F==null?0:Xr(F);return we<0&&(we=so(ee+we,0)),wi(v,Zr(S,3),we)}function wc(v,S,F){var ee=v==null?0:v.length;if(!ee)return-1;var we=ee-1;return F!==t&&(we=Xr(F),we=F<0?so(ee+we,0):ua(we,ee-1)),wi(v,Zr(S,3),we,!0)}function Ha(v){var S=v==null?0:v.length;return S?Eo(v,1):[]}function tl(v){var S=v==null?0:v.length;return S?Eo(v,kt):[]}function Vd(v,S){var F=v==null?0:v.length;return F?(S=S===t?1:Xr(S),Eo(v,S)):[]}function $A(v){for(var S=-1,F=v==null?0:v.length,ee={};++S<F;){var we=v[S];ee[we[0]]=we[1]}return ee}function Qp(v){return v&&v.length?v[0]:t}function u0(v,S,F){var ee=v==null?0:v.length;if(!ee)return-1;var we=F==null?0:Xr(F);return we<0&&(we=so(ee+we,0)),No(v,S,we)}function $p(v){var S=v==null?0:v.length;return S?La(v,0,-1):[]}var j1=Gi(function(v){var S=Xo(v,zf);return S.length&&S[0]===v[0]?vc(S):[]}),W1=Gi(function(v){var S=vA(v),F=Xo(v,zf);return S===vA(F)?S=t:F.pop(),F.length&&F[0]===v[0]?vc(F,Zr(S,2)):[]}),rw=Gi(function(v){var S=vA(v),F=Xo(v,zf);return S=typeof S=="function"?S:t,S&&F.pop(),F.length&&F[0]===v[0]?vc(F,t,S):[]});function Mb(v,S){return v==null?"":Pd.call(v,S)}function vA(v){var S=v==null?0:v.length;return S?v[S-1]:t}function iw(v,S,F){var ee=v==null?0:v.length;if(!ee)return-1;var we=ee;return F!==t&&(we=Xr(F),we=we<0?so(ee+we,0):ua(we,ee-1)),S===S?ul(v,S,we):wi(v,yh,we,!0)}function Sb(v,S){return v&&v.length?Rd(v,Xr(S)):t}var Eb=Gi(N1);function N1(v,S){return v&&v.length&&S&&S.length?Kp(v,S):v}function lv(v,S,F){return v&&v.length&&S&&S.length?Kp(v,S,Zr(F,2)):v}function ow(v,S,F){return v&&v.length&&S&&S.length?Kp(v,S,t,F):v}var aw=NA(function(v,S){var F=v==null?0:v.length,ee=xr(v,S);return xs(v,Xo(S,function(we){return x(we,F)?+we:we}).sort(Dh)),ee});function Ob(v,S){var F=[];if(!(v&&v.length))return F;var ee=-1,we=[],je=v.length;for(S=Zr(S,3);++ee<je;){var ut=v[ee];S(ut,ee,v)&&(F.push(ut),we.push(ee))}return xs(v,we),F}function qf(v){return v==null?v:pc.call(v)}function ld(v,S,F){var ee=v==null?0:v.length;return ee?(F&&typeof F!="number"&&b(v,S,F)?(S=0,F=ee):(S=S==null?0:Xr(S),F=F===t?ee:Xr(F)),La(v,S,F)):[]}function $h(v,S){return td(v,S)}function Bb(v,S,F){return jd(v,S,Zr(F,2))}function uv(v,S){var F=v==null?0:v.length;if(F){var ee=td(v,S);if(ee<F&&K(v[ee],S))return ee}return-1}function sw(v,S){return td(v,S,!0)}function lw(v,S,F){return jd(v,S,Zr(F,2),!0)}function G1(v,S){var F=v==null?0:v.length;if(F){var ee=td(v,S,!0)-1;if(K(v[ee],S))return ee}return-1}function Av(v){return v&&v.length?gA(v):[]}function uw(v,S){return v&&v.length?gA(v,Zr(S,2)):[]}function cv(v){var S=v==null?0:v.length;return S?La(v,1,S):[]}function dv(v,S,F){return v&&v.length?(S=F||S===t?1:Xr(S),La(v,0,S<0?0:S)):[]}function Yp(v,S,F){var ee=v==null?0:v.length;return ee?(S=F||S===t?1:Xr(S),S=ee-S,La(v,S<0?0:S,ee)):[]}function kb(v,S){return v&&v.length?nd(v,Zr(S,3),!1,!0):[]}function Ib(v,S){return v&&v.length?nd(v,Zr(S,3)):[]}var hv=Gi(function(v){return Eu(Eo(v,1,Ee,!0))}),Tb=Gi(function(v){var S=vA(v);return Ee(S)&&(S=t),Eu(Eo(v,1,Ee,!0),Zr(S,2))}),Q1=Gi(function(v){var S=vA(v);return S=typeof S=="function"?S:t,Eu(Eo(v,1,Ee,!0),t,S)});function Kb(v){return v&&v.length?Eu(v):[]}function Aw(v,S){return v&&v.length?Eu(v,Zr(S,2)):[]}function cw(v,S){return S=typeof S=="function"?S:t,v&&v.length?Eu(v,t,S):[]}function $1(v){if(!(v&&v.length))return[];var S=0;return v=Ru(v,function(F){if(Ee(F))return S=so(F.length,S),!0}),Mo(S,function(F){return Xo(v,ya(F))})}function Pb(v,S){if(!(v&&v.length))return[];var F=$1(v);return S==null?F:Xo(F,function(ee){return ga(S,t,ee)})}var dw=Gi(function(v,S){return Ee(v)?ea(v,S):[]}),hw=Gi(function(v){return iu(Ru(v,Ee))}),fw=Gi(function(v){var S=vA(v);return Ee(S)&&(S=t),iu(Ru(v,Ee),Zr(S,2))}),fv=Gi(function(v){var S=vA(v);return S=typeof S=="function"?S:t,iu(Ru(v,Ee),t,S)}),Yh=Gi($1);function Fb(v,S){return rd(v||[],S||[],dn)}function Db(v,S){return rd(v||[],S||[],Kh)}var Lb=Gi(function(v){var S=v.length,F=S>1?v[S-1]:t;return F=typeof F=="function"?(v.pop(),F):t,Pb(v,F)});function pv(v){var S=Pe(v);return S.__chain__=!0,S}function Ub(v,S){return S(v),v}function qp(v,S){return S(v)}var Y1=NA(function(v){var S=v.length,F=S?v[0]:0,ee=this.__wrapped__,we=function(je){return xr(je,v)};return S>1||this.__actions__.length||!(ee instanceof Yr)||!x(F)?this.thru(we):(ee=ee.slice(F,+F+(S?1:0)),ee.__actions__.push({func:qp,args:[we],thisArg:t}),new lo(ee,this.__chain__).thru(function(je){return S&&!je.length&&je.push(t),je}))});function Rb(){return pv(this)}function mv(){return new lo(this.value(),this.__chain__)}function zb(){this.__values__===t&&(this.__values__=Bl(this.value()));var v=this.__index__>=this.__values__.length,S=v?t:this.__values__[this.__index__++];return{done:v,value:S}}function _A(){return this}function A0(v){for(var S,F=this;F instanceof Qa;){var ee=Ol(F);ee.__index__=0,ee.__values__=t,S?we.__wrapped__=ee:S=ee;var we=ee;F=F.__wrapped__}return we.__wrapped__=v,S}function jb(){var v=this.__wrapped__;if(v instanceof Yr){var S=v;return this.__actions__.length&&(S=new Yr(this)),S=S.reverse(),S.__actions__.push({func:qp,args:[qf],thisArg:t}),new lo(S,this.__chain__)}return this.thru(qf)}function Wb(){return Ph(this.__wrapped__,this.__actions__)}var Nb=ad(function(v,S,F){to.call(v,F)?++v[F]:Tn(v,F,1)});function Gb(v,S,F){var ee=ne(v)?Wc:bs;return F&&b(v,S,F)&&(S=t),ee(v,Zr(S,3))}function Qb(v,S){var F=ne(v)?Ru:Ta;return F(v,Zr(S,3))}var $b=Qf(yA),pw=Qf(wc);function Yb(v,S){return Eo(Zd(v,S),1)}function qh(v,S){return Eo(Zd(v,S),kt)}function qb(v,S,F){return F=F===t?1:Xr(F),Eo(Zd(v,S),F)}function gv(v,S){var F=ne(v)?Jl:Ui;return F(v,Zr(S,3))}function yv(v,S){var F=ne(v)?mh:Ds;return F(v,Zr(S,3))}var Hb=ad(function(v,S,F){to.call(v,F)?v[F].push(S):Tn(v,F,[S])});function mw(v,S,F,ee){v=_e(v)?v:og(v),F=F&&!ee?Xr(F):0;var we=v.length;return F<0&&(F=so(we+F,0)),Ss(v)?F<=we&&v.indexOf(S,F)>-1:!!we&&No(v,S,F)>-1}var gw=Gi(function(v,S,F){var ee=-1,we=typeof S=="function",je=_e(v)?Wt(v.length):[];return Ui(v,function(ut){je[++ee]=we?ga(S,ut,F):jA(ut,S,F)}),je}),Vb=ad(function(v,S,F){Tn(v,F,S)});function Zd(v,S){var F=ne(v)?Xo:Vm;return F(v,Zr(S,3))}function Zb(v,S,F,ee){return v==null?[]:(ne(S)||(S=S==null?[]:[S]),F=ee?t:F,ne(F)||(F=F==null?[]:[F]),k1(v,S,F))}var q1=ad(function(v,S,F){v[F?0:1].push(S)},function(){return[[],[]]});function Xb(v,S,F){var ee=ne(v)?Od:Li,we=arguments.length<3;return ee(v,Zr(S,4),F,we,Ui)}function H1(v,S,F){var ee=ne(v)?TA:Li,we=arguments.length<3;return ee(v,Zr(S,4),F,we,Ds)}function V1(v,S){var F=ne(v)?Ru:Ta;return F(v,c0(Zr(S,3)))}function Z1(v){var S=ne(v)?Ct:Jm;return S(v)}function yw(v,S,F){(F?b(v,S,F):S===t)?S=1:S=Xr(S);var ee=ne(v)?$t:e0;return ee(v,S)}function vw(v){var S=ne(v)?Dt:t0;return S(v)}function _w(v){if(v==null)return 0;if(_e(v))return Ss(v)?FA(v):v.length;var S=Rs(v);return S==bt||S==Xn?v.size:ed(v).length}function Cw(v,S,F){var ee=ne(v)?lc:cl;return F&&b(v,S,F)&&(S=t),ee(v,Zr(S,3))}var Hp=Gi(function(v,S){if(v==null)return[];var F=S.length;return F>1&&b(v,S[0],S[1])?S=[]:F>2&&b(S[0],S[1],S[2])&&(S=[S[0]]),k1(v,Eo(S,1),[])}),Ws=fc||function(){return yr.Date.now()};function Hh(v,S){if(typeof S!="function")throw new Cs(s);return v=Xr(v),function(){if(--v<1)return S.apply(this,arguments)}}function X1(v,S,F){return S=F?t:S,S=v&&S==null?v.length:S,Co(v,V,t,t,t,t,S)}function vv(v,S){var F;if(typeof S!="function")throw new Cs(s);return v=Xr(v),function(){return--v>0&&(F=S.apply(this,arguments)),v<=1&&(S=t),F}}var J1=Gi(function(v,S,F){var ee=N;if(F.length){var we=Rl(F,Nh(J1));ee|=me}return Co(v,ee,S,F,we)}),eg=Gi(function(v,S,F){var ee=N|$;if(F.length){var we=Rl(F,Nh(eg));ee|=me}return Co(S,ee,v,F,we)});function Jb(v,S,F){S=F?t:S;var ee=Co(v,oe,t,t,t,t,t,S);return ee.placeholder=Jb.placeholder,ee}function _v(v,S,F){S=F?t:S;var ee=Co(v,ce,t,t,t,t,t,S);return ee.placeholder=_v.placeholder,ee}function Cv(v,S,F){var ee,we,je,ut,vt,Pt,yn=0,_n=!1,In=!1,fr=!0;if(typeof v!="function")throw new Cs(s);S=ii(S)||0,wn(F)&&(_n=!!F.leading,In="maxWait"in F,je=In?so(ii(F.maxWait)||0,S):je,fr="trailing"in F?!!F.trailing:fr);function qr(dl){var th=ee,Vf=we;return ee=we=t,yn=dl,ut=v.apply(Vf,th),ut}function yi(dl){return yn=dl,vt=Kr(bo,S),_n?qr(dl):ut}function uo(dl){var th=dl-Pt,Vf=dl-yn,Ok=S-th;return In?ua(Ok,je-Vf):Ok}function vi(dl){var th=dl-Pt,Vf=dl-yn;return Pt===t||th>=S||th<0||In&&Vf>=je}function bo(){var dl=Ws();if(vi(dl))return Po(dl);vt=Kr(bo,uo(dl))}function Po(dl){return vt=t,fr&&ee?qr(dl):(ee=we=t,ut)}function Sc(){vt!==t&&K1(vt),yn=0,ee=Pt=we=vt=t}function xA(){return vt===t?ut:Po(Ws())}function Ec(){var dl=Ws(),th=vi(dl);if(ee=arguments,we=this,Pt=dl,th){if(vt===t)return yi(Pt);if(In)return K1(vt),vt=Kr(bo,S),qr(Pt)}return vt===t&&(vt=Kr(bo,S)),ut}return Ec.cancel=Sc,Ec.flush=xA,Ec}var bw=Gi(function(v,S){return Mi(v,1,S)}),ex=Gi(function(v,S,F){return Mi(v,ii(S)||0,F)});function bv(v){return Co(v,ye)}function Vp(v,S){if(typeof v!="function"||S!=null&&typeof S!="function")throw new Cs(s);var F=function(){var ee=arguments,we=S?S.apply(this,ee):ee[0],je=F.cache;if(je.has(we))return je.get(we);var ut=v.apply(this,ee);return F.cache=je.set(we,ut)||je,ut};return F.cache=new(Vp.Cache||M),F}Vp.Cache=M;function c0(v){if(typeof v!="function")throw new Cs(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 d0(v){return vv(2,v)}var xv=Wf(function(v,S){S=S.length==1&&ne(S[0])?Xo(S[0],Hs(Zr())):Xo(Eo(S,1),Hs(Zr()));var F=S.length;return Gi(function(ee){for(var we=-1,je=ua(ee.length,F);++we<je;)ee[we]=S[we].call(this,ee[we]);return ga(v,this,ee)})}),tg=Gi(function(v,S){var F=Rl(S,Nh(tg));return Co(v,me,t,S,F)}),ng=Gi(function(v,S){var F=Rl(S,Nh(ng));return Co(v,he,t,S,F)}),rg=NA(function(v,S){return Co(v,ae,t,t,t,S)});function h0(v,S){if(typeof v!="function")throw new Cs(s);return S=S===t?S:Xr(S),Gi(v,S)}function wv(v,S){if(typeof v!="function")throw new Cs(s);return S=S==null?0:so(Xr(S),0),Gi(function(F){var ee=F[S],we=Cc(F,0,S);return ee&&zu(we,ee),ga(v,this,we)})}function Mv(v,S,F){var ee=!0,we=!0;if(typeof v!="function")throw new Cs(s);return wn(F)&&(ee="leading"in F?!!F.leading:ee,we="trailing"in F?!!F.trailing:we),Cv(v,S,{leading:ee,maxWait:S,trailing:we})}function Sv(v){return X1(v,1)}function xw(v,S){return tg(jf(S),v)}function c(){if(!arguments.length)return[];var v=arguments[0];return ne(v)?v:[v]}function l(v){return Ni(v,P)}function d(v,S){return S=typeof S=="function"?S:t,Ni(v,P,S)}function y(v){return Ni(v,B|P)}function w(v,S){return S=typeof S=="function"?S:t,Ni(v,B|P,S)}function T(v,S){return S==null||ri(v,S,Tl(S))}function K(v,S){return v===S||v!==v&&S!==S}var D=$f(Ko),j=$f(function(v,S){return v>=S}),Z=Oh(function(){return arguments}())?Oh:function(v){return gn(v)&&to.call(v,"callee")&&!hc.call(v,"callee")},ne=Wt.isArray,Ae=Hi?Hs(Hi):nu;function _e(v){return v!=null&&qn(v.length)&&!Un(v)}function Ee(v){return gn(v)&&_e(v)}function Ke(v){return v===!0||v===!1||gn(v)&&vo(v)==Me}var We=Tp||Lw,qe=Io?Hs(Io):WA;function st(v){return gn(v)&&v.nodeType===1&&!Ra(v)}function Ot(v){if(v==null)return!0;if(_e(v)&&(ne(v)||typeof v=="string"||typeof v.splice=="function"||We(v)||Ns(v)||Z(v)))return!v.length;var S=Rs(v);if(S==bt||S==Xn)return!v.size;if(ge(v))return!ed(v).length;for(var F in v)if(to.call(v,F))return!1;return!0}function ct(v,S){return Xs(v,S)}function _t(v,S,F){F=typeof F=="function"?F:t;var ee=F?F(v,S):t;return ee===t?Xs(v,S,t,F):!!ee}function nn(v){if(!gn(v))return!1;var S=vo(v);return S==Ue||S==xe||typeof v.message=="string"&&typeof v.name=="string"&&!Ra(v)}function cn(v){return typeof v=="number"&&Kf(v)}function Un(v){if(!wn(v))return!1;var S=vo(v);return S==et||S==it||S==Lt||S==mn}function Cr(v){return typeof v=="number"&&v==Xr(v)}function qn(v){return typeof v=="number"&&v>-1&&v%1==0&&v<=Yt}function wn(v){var S=typeof v;return v!=null&&(S=="object"||S=="function")}function gn(v){return v!=null&&typeof v=="object"}var lr=wo?Hs(wo):_c;function Rn(v,S){return v===S||Bh(v,S,Oo(S))}function On(v,S,F){return F=typeof F=="function"?F:t,Bh(v,S,Oo(S),F)}function Fr(v){return ha(v)&&v!=+v}function wr(v){if(le(v))throw new ai(o);return qu(v)}function Fi(v){return v===null}function da(v){return v==null}function ha(v){return typeof v=="number"||gn(v)&&vo(v)==Ut}function Ra(v){if(!gn(v)||vo(v)!=pt)return!1;var S=bu(v);if(S===null)return!0;var F=to.call(S,"constructor")&&S.constructor;return typeof F=="function"&&F instanceof F&&Fs.call(F)==DA}var ou=Ga?Hs(Ga):Uf;function au(v){return Cr(v)&&v>=-Yt&&v<=Yt}var ds=Ll?Hs(Ll):Xc;function Ss(v){return typeof v=="string"||!ne(v)&&gn(v)&&vo(v)==cr}function Vo(v){return typeof v=="symbol"||gn(v)&&vo(v)==Mr}var Ns=Xl?Hs(Xl):B1;function su(v){return v===t}function Gs(v){return gn(v)&&Rs(v)==gr}function Qs(v){return gn(v)&&vo(v)==mi}var Wl=$f(Hu),lu=$f(function(v,S){return v<=S});function Bl(v){if(!v)return[];if(_e(v))return Ss(v)?xl(v):Js(v);if(Nu&&v[Nu])return Ip(v[Nu]());var S=Rs(v),F=S==bt?Ac:S==Xn?bl:og;return F(v)}function hs(v){if(!v)return v===0?v:0;if(v=ii(v),v===kt||v===-kt){var S=v<0?-1:1;return S*jt}return v===v?v:0}function Xr(v){var S=hs(v),F=S%1;return S===S?F?S-F:S:0}function Es(v){return v?Jn(Xr(v),0,rt):0}function ii(v){if(typeof v=="number")return v;if(Vo(v))return Xe;if(wn(v)){var S=typeof v.valueOf=="function"?v.valueOf():v;v=wn(S)?S+"":S}if(typeof v!="string")return v===0?v:+v;v=Qc(v);var F=ui.test(v);return F||Yi.test(v)?en(v.slice(2),F?2:8):ir.test(v)?Xe:+v}function kl(v){return Vu(v,Va(v))}function Il(v){return v?Jn(Xr(v),-Yt,Yt):v===0?v:0}function ci(v){return v==null?"":Su(v)}var YA=Zu(function(v,S){if(ge(S)||_e(S)){Vu(S,Tl(S),v);return}for(var F in S)to.call(S,F)&&dn(v,F,S[F])}),qA=Zu(function(v,S){Vu(S,Va(S),v)}),Ju=Zu(function(v,S,F,ee){Vu(S,Va(S),v,ee)}),Xd=Zu(function(v,S,F,ee){Vu(S,Tl(S),v,ee)}),HA=NA(xr);function CA(v,S){var F=Sl(v);return S==null?F:tr(F,S)}var Bu=Gi(function(v,S){v=yo(v);var F=-1,ee=S.length,we=ee>2?S[2]:t;for(we&&b(S[0],S[1],we)&&(ee=1);++F<ee;)for(var je=S[F],ut=Va(je),vt=-1,Pt=ut.length;++vt<Pt;){var yn=ut[vt],_n=v[yn];(_n===t||K(_n,la[yn])&&!to.call(v,yn))&&(v[yn]=je[yn])}return v}),Jd=Gi(function(v){return v.push(t,Wp),ga(ox,t,v)});function f0(v,S){return gh(v,Zr(S,3),Us)}function tx(v,S){return gh(v,Zr(S,3),Mu)}function Ev(v,S){return v==null?v:jl(v,Zr(S,3),Va)}function Ov(v,S){return v==null?v:zA(v,Zr(S,3),Va)}function eh(v,S){return v&&Us(v,Zr(S,3))}function nx(v,S){return v&&Mu(v,Zr(S,3))}function rx(v){return v==null?[]:Ka(v,Tl(v))}function ww(v){return v==null?[]:Ka(v,Va(v))}function Bv(v,S,F){var ee=v==null?t:Lo(v,S);return ee===t?F:ee}function Mw(v,S){return v!=null&&z1(v,S,$a)}function kv(v,S){return v!=null&&z1(v,S,ls)}var Sw=Rp(function(v,S,F){S!=null&&typeof S.toString!="function"&&(S=wl.call(S)),v[S]=F},Tw(VA)),Ew=Rp(function(v,S,F){S!=null&&typeof S.toString!="function"&&(S=wl.call(S)),to.call(v,S)?v[S].push(F):v[S]=[F]},Zr),Ow=Gi(jA);function Tl(v){return _e(v)?Ze(v):ed(v)}function Va(v){return _e(v)?Ze(v,!0):kh(v)}function ig(v,S){var F={};return S=Zr(S,3),Us(v,function(ee,we,je){Tn(F,S(ee,we,je),ee)}),F}function ix(v,S){var F={};return S=Zr(S,3),Us(v,function(ee,we,je){Tn(F,we,S(ee,we,je))}),F}var Bw=Zu(function(v,S,F){ru(v,S,F)}),ox=Zu(function(v,S,F,ee){ru(v,S,F,ee)}),kw=NA(function(v,S){var F={};if(v==null)return F;var ee=!1;S=Xo(S,function(je){return je=id(je,v),ee||(ee=je.length>1),je}),Vu(v,Wh(v),F),ee&&(F=Ni(F,B|k|P,jh));for(var we=S.length;we--;)Lp(F,S[we]);return F});function Nl(v,S){return Vh(v,c0(Zr(S)))}var bA=NA(function(v,S){return v==null?{}:Al(v,S)});function Vh(v,S){if(v==null)return{};var F=Xo(Wh(v),function(ee){return[ee]});return S=Zr(S),zd(v,F,function(ee,we){return S(ee,we[0])})}function Mc(v,S,F){S=id(S,v);var ee=-1,we=S.length;for(we||(we=1,v=t);++ee<we;){var je=v==null?t:v[Ua(S[ee])];je===t&&(ee=we,je=F),v=Un(je)?je.call(v):je}return v}function Hf(v,S,F){return v==null?v:Kh(v,S,F)}function ud(v,S,F,ee){return ee=typeof ee=="function"?ee:t,v==null?v:Kh(v,S,F,ee)}var Ck=Yd(Tl),bk=Yd(Va);function yQ(v,S,F){var ee=ne(v),we=ee||We(v)||Ns(v);if(S=Zr(S,4),F==null){var je=v&&v.constructor;we?F=ee?new je:[]:wn(v)?F=Un(je)?Sl(bu(v)):{}:F={}}return(we?Jl:Us)(v,function(ut,vt,Pt){return S(F,ut,vt,Pt)}),F}function vQ(v,S){return v==null?!0:Lp(v,S)}function _Q(v,S,F){return v==null?v:Rf(v,S,jf(F))}function CQ(v,S,F,ee){return ee=typeof ee=="function"?ee:t,v==null?v:Rf(v,S,jf(F),ee)}function og(v){return v==null?[]:_h(v,Tl(v))}function bQ(v){return v==null?[]:_h(v,Va(v))}function xQ(v,S,F){return F===t&&(F=S,S=t),F!==t&&(F=ii(F),F=F===F?F:0),S!==t&&(S=ii(S),S=S===S?S:0),Jn(ii(v),S,F)}function wQ(v,S,F){return S=hs(S),F===t?(F=S,S=0):F=hs(F),v=ii(v),Aa(v,S,F)}function MQ(v,S,F){if(F&&typeof F!="boolean"&&b(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=hs(v),S===t?(S=v,v=0):S=hs(S)),v>S){var ee=v;v=S,S=ee}if(F||v%1||S%1){var we=RA();return ua(v+we*(S-v+Dn("1e-"+((we+"").length-1))),S)}return Pp(v,S)}var SQ=Rh(function(v,S,F){return S=S.toLowerCase(),v+(F?xk(S):S)});function xk(v){return Iw(ci(v).toLowerCase())}function wk(v){return v=ci(v),v&&v.replace(Jr,kd).replace(gu,"")}function EQ(v,S,F){v=ci(v),S=Su(S);var ee=v.length;F=F===t?ee:Jn(Xr(F),0,ee);var we=F;return F-=S.length,F>=0&&v.slice(F,we)==S}function OQ(v){return v=ci(v),v&&Ce.test(v)?v.replace(Fe,vu):v}function BQ(v){return v=ci(v),v&&Xt.test(v)?v.replace(xt,"\\$&"):v}var kQ=Rh(function(v,S,F){return v+(F?"-":"")+S.toLowerCase()}),IQ=Rh(function(v,S,F){return v+(F?" ":"")+S.toLowerCase()}),TQ=Uh("toLowerCase");function KQ(v,S,F){v=ci(v),S=Xr(S);var ee=S?FA(v):0;if(!S||ee>=S)return v;var we=(S-ee)/2;return jp(wu(we),F)+v+jp(So(we),F)}function PQ(v,S,F){v=ci(v),S=Xr(S);var ee=S?FA(v):0;return S&&ee<S?v+jp(S-ee,F):v}function FQ(v,S,F){v=ci(v),S=Xr(S);var ee=S?FA(v):0;return S&&ee<S?jp(S-ee,F)+v:v}function DQ(v,S,F){return F||S==null?S=0:S&&(S=+S),Tr(ci(v).replace(Vt,""),S||0)}function LQ(v,S,F){return(F?b(v,S,F):S===t)?S=1:S=Xr(S),Xm(ci(v),S)}function UQ(){var v=arguments,S=ci(v[0]);return v.length<3?S:S.replace(v[1],v[2])}var RQ=Rh(function(v,S,F){return v+(F?"_":"")+S.toLowerCase()});function zQ(v,S,F){return F&&typeof F!="number"&&b(v,S,F)&&(S=F=t),F=F===t?rt:F>>>0,F?(v=ci(v),v&&(typeof S=="string"||S!=null&&!ou(S))&&(S=Su(S),!S&&PA(v))?Cc(xl(v),0,F):v.split(S,F)):[]}var jQ=Rh(function(v,S,F){return v+(F?" ":"")+Iw(S)});function WQ(v,S,F){return v=ci(v),F=F==null?0:Jn(Xr(F),0,v.length),S=Su(S),v.slice(F,F+S.length)==S}function NQ(v,S,F){var ee=Pe.templateSettings;F&&b(v,S,F)&&(S=t),v=ci(v),S=Ju({},S,ee,U1);var we=Ju({},S.imports,ee.imports,U1),je=Tl(we),ut=_h(we,je),vt,Pt,yn=0,_n=S.interpolate||xo,In="__p += '",fr=_s((S.escape||xo).source+"|"+_n.source+"|"+(_n===tt?Lr:xo).source+"|"+(S.evaluate||xo).source+"|$","g"),qr="//# sourceURL="+(to.call(S,"sourceURL")?(S.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++AA+"]")+`
`;v.replace(fr,function(vi,bo,Po,Sc,xA,Ec){return Po||(Po=Sc),In+=v.slice(yn,Ec).replace(Wa,Wu),bo&&(vt=!0,In+=`' +
__e(`+bo+`) +
'`),xA&&(Pt=!0,In+=`';
`+xA+`;
__p += '`),Po&&(In+=`' +
((__t = (`+Po+`)) == null ? '' : __t) +
'`),yn=Ec+vi.length,vi}),In+=`';
`;var yi=to.call(S,"variable")&&S.variable;if(!yi)In=`with (obj) {
`+In+`
}
`;else if(kr.test(yi))throw new ai(a);In=(Pt?In.replace(m,""):In).replace(Kt,"$1").replace(Dr,"$1;"),In="function("+(yi||"obj")+`) {
`+(yi?"":`obj || (obj = {});
`)+"var __t, __p = ''"+(vt?", __e = _.escape":"")+(Pt?`, __j = Array.prototype.join;
function print() { __p += __j.call(arguments, '') }
`:`;
`)+In+`return __p
}`;var uo=Sk(function(){return ao(je,qr+"return "+In).apply(t,ut)});if(uo.source=In,nn(uo))throw uo;return uo}function GQ(v){return ci(v).toLowerCase()}function QQ(v){return ci(v).toUpperCase()}function $Q(v,S,F){if(v=ci(v),v&&(F||S===t))return Qc(v);if(!v||!(S=Su(S)))return v;var ee=xl(v),we=xl(S),je=Ul(ee,we),ut=KA(ee,we)+1;return Cc(ee,je,ut).join("")}function YQ(v,S,F){if(v=ci(v),v&&(F||S===t))return v.slice(0,bh(v)+1);if(!v||!(S=Su(S)))return v;var ee=xl(v),we=KA(ee,xl(S))+1;return Cc(ee,0,we).join("")}function qQ(v,S,F){if(v=ci(v),v&&(F||S===t))return v.replace(Vt,"");if(!v||!(S=Su(S)))return v;var ee=xl(v),we=Ul(ee,xl(S));return Cc(ee,we).join("")}function HQ(v,S){var F=Oe,ee=De;if(wn(S)){var we="separator"in S?S.separator:we;F="length"in S?Xr(S.length):F,ee="omission"in S?Su(S.omission):ee}v=ci(v);var je=v.length;if(PA(v)){var ut=xl(v);je=ut.length}if(F>=je)return v;var vt=F-FA(ee);if(vt<1)return ee;var Pt=ut?Cc(ut,0,vt).join(""):v.slice(0,vt);if(we===t)return Pt+ee;if(ut&&(vt+=Pt.length-vt),ou(we)){if(v.slice(vt).search(we)){var yn,_n=Pt;for(we.global||(we=_s(we.source,ci(Wr.exec(we))+"g")),we.lastIndex=0;yn=we.exec(_n);)var In=yn.index;Pt=Pt.slice(0,In===t?vt:In)}}else if(v.indexOf(Su(we),vt)!=vt){var fr=Pt.lastIndexOf(we);fr>-1&&(Pt=Pt.slice(0,fr))}return Pt+ee}function VQ(v){return v=ci(v),v&&de.test(v)?v.replace(Fn,dA):v}var ZQ=Rh(function(v,S,F){return v+(F?" ":"")+S.toUpperCase()}),Iw=Uh("toUpperCase");function Mk(v,S,F){return v=ci(v),S=F?t:S,S===t?kf(v)?Id(v):kp(v):v.match(S)||[]}var Sk=Gi(function(v,S){try{return ga(v,t,S)}catch(F){return nn(F)?F:new ai(F)}}),XQ=NA(function(v,S){return Jl(S,function(F){F=Ua(F),Tn(v,F,J1(v[F],v))}),v});function JQ(v){var S=v==null?0:v.length,F=Zr();return v=S?Xo(v,function(ee){if(typeof ee[1]!="function")throw new Cs(s);return[F(ee[0]),ee[1]]}):[],Gi(function(ee){for(var we=-1;++we<S;){var je=v[we];if(ga(je[0],this,ee))return ga(je[1],this,ee)}})}function e$(v){return ki(Ni(v,B))}function Tw(v){return function(){return v}}function t$(v,S){return v==null||v!==v?S:v}var n$=Up(),r$=Up(!0);function VA(v){return v}function Kw(v){return Jc(typeof v=="function"?v:Ni(v,B))}function i$(v){return Ih(Ni(v,B))}function o$(v,S){return Th(v,Ni(S,B))}var a$=Gi(function(v,S){return function(F){return jA(F,v,S)}}),s$=Gi(function(v,S){return function(F){return jA(v,F,S)}});function Pw(v,S,F){var ee=Tl(S),we=Ka(S,ee);F==null&&!(wn(S)&&(we.length||!ee.length))&&(F=S,S=v,v=this,we=Ka(S,Tl(S)));var je=!(wn(F)&&"chain"in F)||!!F.chain,ut=Un(v);return Jl(we,function(vt){var Pt=S[vt];v[vt]=Pt,ut&&(v.prototype[vt]=function(){var yn=this.__chain__;if(je||yn){var _n=v(this.__wrapped__),In=_n.__actions__=Js(this.__actions__);return In.push({func:Pt,args:arguments,thisArg:v}),_n.__chain__=yn,_n}return Pt.apply(v,zu([this.value()],arguments))})}),v}function l$(){return yr._===this&&(yr._=Da),this}function Fw(){}function u$(v){return v=Xr(v),Gi(function(S){return Rd(S,v)})}var A$=zp(Xo),c$=zp(Wc),d$=zp(lc);function Ek(v){return E(v)?ya(Ua(v)):Zm(v)}function h$(v){return function(S){return v==null?t:Lo(v,S)}}var f$=$d(),p$=$d(!0);function Dw(){return[]}function Lw(){return!1}function m$(){return{}}function g$(){return""}function y$(){return!0}function v$(v,S){if(v=Xr(v),v<1||v>Yt)return[];var F=rt,ee=ua(v,rt);S=Zr(S),v-=rt;for(var we=Mo(ee,S);++F<v;)S(F);return we}function _$(v){return ne(v)?Xo(v,Ua):Vo(v)?[v]:Js(ba(ci(v)))}function C$(v){var S=++xh;return ci(v)+S}var b$=Qd(function(v,S){return v+S},0),x$=o0("ceil"),w$=Qd(function(v,S){return v/S},1),M$=o0("floor");function S$(v){return v&&v.length?Ho(v,VA,Ko):t}function E$(v,S){return v&&v.length?Ho(v,Zr(S,2),Ko):t}function O$(v){return ju(v,VA)}function B$(v,S){return ju(v,Zr(S,2))}function k$(v){return v&&v.length?Ho(v,VA,Hu):t}function I$(v,S){return v&&v.length?Ho(v,Zr(S,2),Hu):t}var T$=Qd(function(v,S){return v*S},1),K$=o0("round"),P$=Qd(function(v,S){return v-S},0);function F$(v){return v&&v.length?To(v,VA):0}function D$(v,S){return v&&v.length?To(v,Zr(S,2)):0}return Pe.after=Hh,Pe.ary=X1,Pe.assign=YA,Pe.assignIn=qA,Pe.assignInWith=Ju,Pe.assignWith=Xd,Pe.at=HA,Pe.before=vv,Pe.bind=J1,Pe.bindAll=XQ,Pe.bindKey=eg,Pe.castArray=c,Pe.chain=pv,Pe.chunk=el,Pe.compact=ws,Pe.concat=cs,Pe.cond=JQ,Pe.conforms=e$,Pe.constant=Tw,Pe.countBy=Nb,Pe.create=CA,Pe.curry=Jb,Pe.curryRight=_v,Pe.debounce=Cv,Pe.defaults=Bu,Pe.defaultsDeep=Jd,Pe.defer=bw,Pe.delay=ex,Pe.difference=ca,Pe.differenceBy=Ms,Pe.differenceWith=Hd,Pe.drop=GA,Pe.dropRight=zs,Pe.dropRightWhile=QA,Pe.dropWhile=js,Pe.fill=l0,Pe.filter=Qb,Pe.flatMap=Yb,Pe.flatMapDeep=qh,Pe.flatMapDepth=qb,Pe.flatten=Ha,Pe.flattenDeep=tl,Pe.flattenDepth=Vd,Pe.flip=bv,Pe.flow=n$,Pe.flowRight=r$,Pe.fromPairs=$A,Pe.functions=rx,Pe.functionsIn=ww,Pe.groupBy=Hb,Pe.initial=$p,Pe.intersection=j1,Pe.intersectionBy=W1,Pe.intersectionWith=rw,Pe.invert=Sw,Pe.invertBy=Ew,Pe.invokeMap=gw,Pe.iteratee=Kw,Pe.keyBy=Vb,Pe.keys=Tl,Pe.keysIn=Va,Pe.map=Zd,Pe.mapKeys=ig,Pe.mapValues=ix,Pe.matches=i$,Pe.matchesProperty=o$,Pe.memoize=Vp,Pe.merge=Bw,Pe.mergeWith=ox,Pe.method=a$,Pe.methodOf=s$,Pe.mixin=Pw,Pe.negate=c0,Pe.nthArg=u$,Pe.omit=kw,Pe.omitBy=Nl,Pe.once=d0,Pe.orderBy=Zb,Pe.over=A$,Pe.overArgs=xv,Pe.overEvery=c$,Pe.overSome=d$,Pe.partial=tg,Pe.partialRight=ng,Pe.partition=q1,Pe.pick=bA,Pe.pickBy=Vh,Pe.property=Ek,Pe.propertyOf=h$,Pe.pull=Eb,Pe.pullAll=N1,Pe.pullAllBy=lv,Pe.pullAllWith=ow,Pe.pullAt=aw,Pe.range=f$,Pe.rangeRight=p$,Pe.rearg=rg,Pe.reject=V1,Pe.remove=Ob,Pe.rest=h0,Pe.reverse=qf,Pe.sampleSize=yw,Pe.set=Hf,Pe.setWith=ud,Pe.shuffle=vw,Pe.slice=ld,Pe.sortBy=Hp,Pe.sortedUniq=Av,Pe.sortedUniqBy=uw,Pe.split=zQ,Pe.spread=wv,Pe.tail=cv,Pe.take=dv,Pe.takeRight=Yp,Pe.takeRightWhile=kb,Pe.takeWhile=Ib,Pe.tap=Ub,Pe.throttle=Mv,Pe.thru=qp,Pe.toArray=Bl,Pe.toPairs=Ck,Pe.toPairsIn=bk,Pe.toPath=_$,Pe.toPlainObject=kl,Pe.transform=yQ,Pe.unary=Sv,Pe.union=hv,Pe.unionBy=Tb,Pe.unionWith=Q1,Pe.uniq=Kb,Pe.uniqBy=Aw,Pe.uniqWith=cw,Pe.unset=vQ,Pe.unzip=$1,Pe.unzipWith=Pb,Pe.update=_Q,Pe.updateWith=CQ,Pe.values=og,Pe.valuesIn=bQ,Pe.without=dw,Pe.words=Mk,Pe.wrap=xw,Pe.xor=hw,Pe.xorBy=fw,Pe.xorWith=fv,Pe.zip=Yh,Pe.zipObject=Fb,Pe.zipObjectDeep=Db,Pe.zipWith=Lb,Pe.entries=Ck,Pe.entriesIn=bk,Pe.extend=qA,Pe.extendWith=Ju,Pw(Pe,Pe),Pe.add=b$,Pe.attempt=Sk,Pe.camelCase=SQ,Pe.capitalize=xk,Pe.ceil=x$,Pe.clamp=xQ,Pe.clone=l,Pe.cloneDeep=y,Pe.cloneDeepWith=w,Pe.cloneWith=d,Pe.conformsTo=T,Pe.deburr=wk,Pe.defaultTo=t$,Pe.divide=w$,Pe.endsWith=EQ,Pe.eq=K,Pe.escape=OQ,Pe.escapeRegExp=BQ,Pe.every=Gb,Pe.find=$b,Pe.findIndex=yA,Pe.findKey=f0,Pe.findLast=pw,Pe.findLastIndex=wc,Pe.findLastKey=tx,Pe.floor=M$,Pe.forEach=gv,Pe.forEachRight=yv,Pe.forIn=Ev,Pe.forInRight=Ov,Pe.forOwn=eh,Pe.forOwnRight=nx,Pe.get=Bv,Pe.gt=D,Pe.gte=j,Pe.has=Mw,Pe.hasIn=kv,Pe.head=Qp,Pe.identity=VA,Pe.includes=mw,Pe.indexOf=u0,Pe.inRange=wQ,Pe.invoke=Ow,Pe.isArguments=Z,Pe.isArray=ne,Pe.isArrayBuffer=Ae,Pe.isArrayLike=_e,Pe.isArrayLikeObject=Ee,Pe.isBoolean=Ke,Pe.isBuffer=We,Pe.isDate=qe,Pe.isElement=st,Pe.isEmpty=Ot,Pe.isEqual=ct,Pe.isEqualWith=_t,Pe.isError=nn,Pe.isFinite=cn,Pe.isFunction=Un,Pe.isInteger=Cr,Pe.isLength=qn,Pe.isMap=lr,Pe.isMatch=Rn,Pe.isMatchWith=On,Pe.isNaN=Fr,Pe.isNative=wr,Pe.isNil=da,Pe.isNull=Fi,Pe.isNumber=ha,Pe.isObject=wn,Pe.isObjectLike=gn,Pe.isPlainObject=Ra,Pe.isRegExp=ou,Pe.isSafeInteger=au,Pe.isSet=ds,Pe.isString=Ss,Pe.isSymbol=Vo,Pe.isTypedArray=Ns,Pe.isUndefined=su,Pe.isWeakMap=Gs,Pe.isWeakSet=Qs,Pe.join=Mb,Pe.kebabCase=kQ,Pe.last=vA,Pe.lastIndexOf=iw,Pe.lowerCase=IQ,Pe.lowerFirst=TQ,Pe.lt=Wl,Pe.lte=lu,Pe.max=S$,Pe.maxBy=E$,Pe.mean=O$,Pe.meanBy=B$,Pe.min=k$,Pe.minBy=I$,Pe.stubArray=Dw,Pe.stubFalse=Lw,Pe.stubObject=m$,Pe.stubString=g$,Pe.stubTrue=y$,Pe.multiply=T$,Pe.nth=Sb,Pe.noConflict=l$,Pe.noop=Fw,Pe.now=Ws,Pe.pad=KQ,Pe.padEnd=PQ,Pe.padStart=FQ,Pe.parseInt=DQ,Pe.random=MQ,Pe.reduce=Xb,Pe.reduceRight=H1,Pe.repeat=LQ,Pe.replace=UQ,Pe.result=Mc,Pe.round=K$,Pe.runInContext=wt,Pe.sample=Z1,Pe.size=_w,Pe.snakeCase=RQ,Pe.some=Cw,Pe.sortedIndex=$h,Pe.sortedIndexBy=Bb,Pe.sortedIndexOf=uv,Pe.sortedLastIndex=sw,Pe.sortedLastIndexBy=lw,Pe.sortedLastIndexOf=G1,Pe.startCase=jQ,Pe.startsWith=WQ,Pe.subtract=P$,Pe.sum=F$,Pe.sumBy=D$,Pe.template=NQ,Pe.times=v$,Pe.toFinite=hs,Pe.toInteger=Xr,Pe.toLength=Es,Pe.toLower=GQ,Pe.toNumber=ii,Pe.toSafeInteger=Il,Pe.toString=ci,Pe.toUpper=QQ,Pe.trim=$Q,Pe.trimEnd=YQ,Pe.trimStart=qQ,Pe.truncate=HQ,Pe.unescape=VQ,Pe.uniqueId=C$,Pe.upperCase=ZQ,Pe.upperFirst=Iw,Pe.each=gv,Pe.eachRight=yv,Pe.first=Qp,Pw(Pe,function(){var v={};return Us(Pe,function(S,F){to.call(Pe.prototype,F)||(v[F]=S)}),v}(),{chain:!1}),Pe.VERSION=r,Jl(["bind","bindKey","curry","curryRight","partial","partialRight"],function(v){Pe[v].placeholder=Pe}),Jl(["drop","take"],function(v,S){Yr.prototype[v]=function(F){F=F===t?1:so(Xr(F),0);var ee=this.__filtered__&&!S?new Yr(this):this.clone();return ee.__filtered__?ee.__takeCount__=ua(F,ee.__takeCount__):ee.__views__.push({size:ua(F,rt),type:v+(ee.__dir__<0?"Right":"")}),ee},Yr.prototype[v+"Right"]=function(F){return this.reverse()[v](F).reverse()}}),Jl(["filter","map","takeWhile"],function(v,S){var F=S+1,ee=F==nt||F==Bt;Yr.prototype[v]=function(we){var je=this.clone();return je.__iteratees__.push({iteratee:Zr(we,3),type:F}),je.__filtered__=je.__filtered__||ee,je}}),Jl(["head","last"],function(v,S){var F="take"+(S?"Right":"");Yr.prototype[v]=function(){return this[F](1).value()[0]}}),Jl(["initial","tail"],function(v,S){var F="drop"+(S?"":"Right");Yr.prototype[v]=function(){return this.__filtered__?new Yr(this):this[F](1)}}),Yr.prototype.compact=function(){return this.filter(VA)},Yr.prototype.find=function(v){return this.filter(v).head()},Yr.prototype.findLast=function(v){return this.reverse().find(v)},Yr.prototype.invokeMap=Gi(function(v,S){return typeof v=="function"?new Yr(this):this.map(function(F){return jA(F,v,S)})}),Yr.prototype.reject=function(v){return this.filter(c0(Zr(v)))},Yr.prototype.slice=function(v,S){v=Xr(v);var F=this;return F.__filtered__&&(v>0||S<0)?new Yr(F):(v<0?F=F.takeRight(-v):v&&(F=F.drop(v)),S!==t&&(S=Xr(S),F=S<0?F.dropRight(-S):F.take(S-v)),F)},Yr.prototype.takeRightWhile=function(v){return this.reverse().takeWhile(v).reverse()},Yr.prototype.toArray=function(){return this.take(rt)},Us(Yr.prototype,function(v,S){var F=/^(?:filter|find|map|reject)|While$/.test(S),ee=/^(?:head|last)$/.test(S),we=Pe[ee?"take"+(S=="last"?"Right":""):S],je=ee||/^find/.test(S);we&&(Pe.prototype[S]=function(){var ut=this.__wrapped__,vt=ee?[1]:arguments,Pt=ut instanceof Yr,yn=vt[0],_n=Pt||ne(ut),In=function(bo){var Po=we.apply(Pe,zu([bo],vt));return ee&&fr?Po[0]:Po};_n&&F&&typeof yn=="function"&&yn.length!=1&&(Pt=_n=!1);var fr=this.__chain__,qr=!!this.__actions__.length,yi=je&&!fr,uo=Pt&&!qr;if(!je&&_n){ut=uo?ut:new Yr(this);var vi=v.apply(ut,vt);return vi.__actions__.push({func:qp,args:[In],thisArg:t}),new lo(vi,fr)}return yi&&uo?v.apply(this,vt):(vi=this.thru(In),yi?ee?vi.value()[0]:vi.value():vi)})}),Jl(["pop","push","shift","sort","splice","unshift"],function(v){var S=Kd[v],F=/^(?:push|sort|unshift)$/.test(v)?"tap":"thru",ee=/^(?:pop|shift)$/.test(v);Pe.prototype[v]=function(){var we=arguments;if(ee&&!this.__chain__){var je=this.value();return S.apply(ne(je)?je:[],we)}return this[F](function(ut){return S.apply(ne(ut)?ut:[],we)})}}),Us(Yr.prototype,function(v,S){var F=Pe[S];if(F){var ee=F.name+"";to.call(Qo,ee)||(Qo[ee]=[]),Qo[ee].push({name:S,func:F})}}),Qo[zh(t,$).name]=[{name:"wrapper",func:t}],Yr.prototype.clone=va,Yr.prototype.reverse=mc,Yr.prototype.value=gc,Pe.prototype.at=Y1,Pe.prototype.chain=Rb,Pe.prototype.commit=mv,Pe.prototype.next=zb,Pe.prototype.plant=A0,Pe.prototype.reverse=jb,Pe.prototype.toJSON=Pe.prototype.valueOf=Pe.prototype.value=Wb,Pe.prototype.first=Pe.prototype.head,Nu&&(Pe.prototype[Nu]=_A),Pe},_u=Td();Bi?((Bi.exports=_u)._=_u,Ir._=_u):yr._=_u}).call(ch)})(o3,o3.exports);var H4=o3.exports;const x6=fa(H4);function wV(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 MV(e){for(var n=5381,t=e.length;t;)n=n*33^e.charCodeAt(--t);return n>>>0}var SV=MV;const GI=fa(SV);var EV=8,OV={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"}},BV={"*":{type:"source"}},kV=["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],IV={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:"*"}},TV={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:"*"}},KV={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:"*"}},PV={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"}},FV={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"}}},DV={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"}}},LV={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"}},UV=["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background"],RV={visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},zV={"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"}},jV={"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"}},WV={visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},NV={"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"}},GV={"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"}},QV={visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},$V={visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},YV={type:"array",value:"*"},qV={type:"enum",values:{"==":{},"!=":{},">":{},">=":{},"<":{},"<=":{},in:{},"!in":{},all:{},any:{},none:{},has:{},"!has":{},within:{}}},HV={type:"enum",values:{Point:{},LineString:{},Polygon:{}}},VV={type:"array",minimum:0,maximum:24,value:["number","color"],length:2},ZV={type:"array",value:"*",minimum:1},XV={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}},JV={"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}},eZ={source:{type:"string",required:!0},exaggeration:{type:"number",minimum:0,default:1}},tZ=["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background"],nZ={"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"}},rZ={"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"}},iZ={"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"}},oZ={"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"}},aZ={"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"}},sZ={"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"}},lZ={"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"}},uZ={"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"}},AZ={duration:{type:"number",default:300,minimum:0,units:"milliseconds"},delay:{type:"number",default:0,minimum:0,units:"milliseconds"}},cZ={"*":{type:"string"}},Ea={$version:EV,$root:OV,sources:BV,source:kV,source_vector:IV,source_raster:TV,source_raster_dem:KV,source_geojson:PV,source_video:FV,source_image:DV,layer:LV,layout:UV,layout_background:RV,layout_fill:zV,layout_circle:jV,layout_heatmap:WV,"layout_fill-extrusion":{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_line:NV,layout_symbol:GV,layout_raster:QV,layout_hillshade:$V,filter:YV,filter_operator:qV,geometry_type:HV,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:VV,expression:ZV,light:XV,sky:JV,terrain:eZ,paint:tZ,paint_fill:nZ,"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:rZ,paint_circle:iZ,paint_heatmap:oZ,paint_symbol:aZ,paint_raster:sZ,paint_hillshade:lZ,paint_background:uZ,transition:AZ,"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:cZ};const dZ=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function hZ(e,n){const t={};for(const r in e)r!=="ref"&&(t[r]=e[r]);return dZ.forEach(r=>{r in n&&(t[r]=n[r])}),t}function fZ(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]=hZ(e[t],n[e[t].ref]));return e}function ns(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(!ns(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(!ns(e[r],n[r]))return!1;return!0}return e===n}function fd(e,n){e.push(n)}function JL(e,n,t){fd(t,{command:"addSource",args:[e,n[e]]})}function eU(e,n,t){fd(n,{command:"removeSource",args:[e]}),t[e]=!0}function pZ(e,n,t,r){eU(e,t,r),JL(e,n,t)}function mZ(e,n,t){let r;for(r in e[t])if(Object.prototype.hasOwnProperty.call(e[t],r)&&r!=="data"&&!ns(e[t][r],n[t][r]))return!1;for(r in n[t])if(Object.prototype.hasOwnProperty.call(n[t],r)&&r!=="data"&&!ns(e[t][r],n[t][r]))return!1;return!0}function gZ(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)||eU(i,t,r));for(i in n)Object.prototype.hasOwnProperty.call(n,i)&&(Object.prototype.hasOwnProperty.call(e,i)?ns(e[i],n[i])||(e[i].type==="geojson"&&n[i].type==="geojson"&&mZ(e,n,i)?fd(t,{command:"setGeoJSONSourceData",args:[i,n[i].data]}):pZ(i,n,t,r)):JL(i,n,t))}function mx(e,n,t,r,i,o){e=e||{},n=n||{};for(const s in e)Object.prototype.hasOwnProperty.call(e,s)&&(ns(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)||ns(e[s],n[s])||t.push({command:o,args:[r,s,n[s],i]})}function QI(e){return e.id}function $I(e,n){return e[n.id]=n,e}function yZ(e,n,t){e=e||[],n=n||[];const r=e.map(QI),i=n.map(QI),o=e.reduce($I,{}),s=n.reduce($I,{}),a=r.slice(),h=Object.create(null);let g,C,B,k,P;for(let L=0,J=0;L<r.length;L++)g=r[L],Object.prototype.hasOwnProperty.call(s,g)?J++:(fd(t,{command:"removeLayer",args:[g]}),a.splice(a.indexOf(g,J),1));for(let L=0,J=0;L<i.length;L++)g=i[i.length-1-L],a[a.length-1-L]!==g&&(Object.prototype.hasOwnProperty.call(o,g)?(fd(t,{command:"removeLayer",args:[g]}),a.splice(a.lastIndexOf(g,a.length-J),1)):J++,k=a[a.length-L],fd(t,{command:"addLayer",args:[s[g],k]}),a.splice(a.length-L,0,g),h[g]=!0);for(let L=0;L<i.length;L++)if(g=i[L],C=o[g],B=s[g],!(h[g]||ns(C,B))){if(!ns(C.source,B.source)||!ns(C["source-layer"],B["source-layer"])||!ns(C.type,B.type)){fd(t,{command:"removeLayer",args:[g]}),k=a[a.lastIndexOf(g)+1],fd(t,{command:"addLayer",args:[B,k]});continue}mx(C.layout,B.layout,t,g,null,"setLayoutProperty"),mx(C.paint,B.paint,t,g,null,"setPaintProperty"),ns(C.filter,B.filter)||fd(t,{command:"setFilter",args:[g,B.filter]}),(!ns(C.minzoom,B.minzoom)||!ns(C.maxzoom,B.maxzoom))&&fd(t,{command:"setLayerZoomRange",args:[g,B.minzoom,B.maxzoom]});for(P in C)Object.prototype.hasOwnProperty.call(C,P)&&(P==="layout"||P==="paint"||P==="filter"||P==="metadata"||P==="minzoom"||P==="maxzoom"||(P.indexOf("paint.")===0?mx(C[P],B[P],t,g,P.slice(6),"setPaintProperty"):ns(C[P],B[P])||fd(t,{command:"setLayerProperty",args:[g,P,B[P]]})));for(P in B)!Object.prototype.hasOwnProperty.call(B,P)||Object.prototype.hasOwnProperty.call(C,P)||P==="layout"||P==="paint"||P==="filter"||P==="metadata"||P==="minzoom"||P==="maxzoom"||(P.indexOf("paint.")===0?mx(C[P],B[P],t,g,P.slice(6),"setPaintProperty"):ns(C[P],B[P])||fd(t,{command:"setLayerProperty",args:[g,P,B[P]]}))}}function vZ(e,n){if(!e)return[{command:"setStyle",args:[n]}];let t=[];try{if(!ns(e.version,n.version))return[{command:"setStyle",args:[n]}];ns(e.center,n.center)||t.push({command:"setCenter",args:[n.center]}),ns(e.zoom,n.zoom)||t.push({command:"setZoom",args:[n.zoom]}),ns(e.bearing,n.bearing)||t.push({command:"setBearing",args:[n.bearing]}),ns(e.pitch,n.pitch)||t.push({command:"setPitch",args:[n.pitch]}),ns(e.sprite,n.sprite)||t.push({command:"setSprite",args:[n.sprite]}),ns(e.glyphs,n.glyphs)||t.push({command:"setGlyphs",args:[n.glyphs]}),ns(e.transition,n.transition)||t.push({command:"setTransition",args:[n.transition]}),ns(e.light,n.light)||t.push({command:"setLight",args:[n.light]}),ns(e.terrain,n.terrain)||t.push({command:"setTerrain",args:[n.terrain]});const r={},i=[];gZ(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),yZ(o,n.layers,t)}catch(r){console.warn("Unable to compute style diff:",r),t=[{command:"setStyle",args:[n]}]}return t}class Zn{constructor(n,t,r,i){this.message=(n?`${n}: `:"")+r,i&&(this.identifier=i),t!=null&&t.__line__&&(this.line=t.__line__)}}function My(e,...n){for(const t of n)for(const r in t)e[r]=t[r];return e}class af extends Error{constructor(n,t){super(t),this.message=t,this.key=n}}let _Z=class tU{constructor(n,t=[]){this.parent=n,this.bindings={};for(const[r,i]of t)this.bindings[r]=i}concat(n){return new tU(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 V4={kind:"null"},nr={kind:"number"},mo={kind:"string"},Vi={kind:"boolean"},pf={kind:"color"},ey={kind:"object"},Xi={kind:"value"},CZ={kind:"error"},Z4={kind:"collator"},X4={kind:"formatted"},J4={kind:"padding"},zC={kind:"resolvedImage"},e5={kind:"variableAnchorOffsetCollection"};function Tc(e,n){return{kind:"array",itemType:e,N:n}}function Bs(e){if(e.kind==="array"){const n=Bs(e.itemType);return typeof e.N=="number"?`array<${n}, ${e.N}>`:e.itemType.kind==="value"?"array":`array<${n}>`}else return e.kind}const bZ=[V4,nr,mo,Vi,pf,X4,ey,Tc(Xi),J4,zC,e5];function nC(e,n){if(n.kind==="error")return null;if(e.kind==="array"){if(n.kind==="array"&&(n.N===0&&n.itemType.kind==="value"||!nC(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 bZ)if(!nC(t,n))return null}}return`Expected ${Bs(e)} but found ${Bs(n)} instead.`}function OB(e,n){return n.some(t=>t.kind===e.kind)}function rC(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 Uv(e,n){return e.kind==="array"&&n.kind==="array"?e.itemType.kind===n.itemType.kind&&typeof e.N=="number":e.kind===n.kind}const nU=.96422,rU=1,iU=.82521,oU=4/29,ty=6/29,aU=3*ty*ty,xZ=ty*ty*ty,wZ=Math.PI/180,MZ=180/Math.PI;function sU(e){return e=e%360,e<0&&(e+=360),e}function lU([e,n,t,r]){e=rM(e),n=rM(n),t=rM(t);let i,o;const s=iM((.2225045*e+.7168786*n+.0606169*t)/rU);e===n&&n===t?i=o=s:(i=iM((.4360747*e+.3850649*n+.1430804*t)/nU),o=iM((.0139322*e+.0971045*n+.7141733*t)/iU));const a=116*s-16;return[a<0?0:a,500*(i-s),200*(s-o),r]}function rM(e){return e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function iM(e){return e>xZ?Math.pow(e,1/3):e/aU+oU}function uU([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=rU*aM(i),o=nU*aM(o),s=iU*aM(s),[oM(3.1338561*o-1.6168667*i-.4906146*s),oM(-.9787684*o+1.9161415*i+.033454*s),oM(.0719453*o-.2289914*i+1.4052427*s),r]}function oM(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 aM(e){return e>ty?e*e*e:aU*(e-oU)}function SZ(e){const[n,t,r,i]=lU(e),o=Math.sqrt(t*t+r*r);return[Math.round(o*1e4)?sU(Math.atan2(r,t)*MZ):NaN,o,n,i]}function EZ([e,n,t,r]){return e=isNaN(e)?0:e*wZ,uU([t,Math.cos(e)*n,Math.sin(e)*n,r])}function OZ([e,n,t,r]){e=sU(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 BZ(e){if(e=e.toLowerCase().trim(),e==="transparent")return[0,0,0,0];const n=kZ[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[gx(e.slice(s,s+=o)),gx(e.slice(s,s+=o)),gx(e.slice(s,s+=o)),gx(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,h,g,C,B,k,P,L,J,N,$]=o,q=[g||" ",k||" ",J].join("");if(q===" "||q===" /"||q===",,"||q===",,,"){const oe=[h,B,L].join(""),ce=oe==="%%%"?100:oe===""?255:0;if(ce){const me=[_g(+a/ce,0,1),_g(+C/ce,0,1),_g(+P/ce,0,1),N?YI(+N,$):1];if(qI(me))return me}}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,h,g,C,B,k]=r,P=[s||" ",h||" ",C].join("");if(P===" "||P===" /"||P===",,"||P===",,,"){const L=[+o,_g(+a,0,100),_g(+g,0,100),B?YI(+B,k):1];if(qI(L))return OZ(L)}}}function gx(e){return parseInt(e.padEnd(2,e),16)/255}function YI(e,n){return _g(n?e/100:e,0,1)}function _g(e,n,t){return Math.min(Math.max(n,e),t)}function qI(e){return!e.some(Number.isNaN)}const kZ={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 Is=class w6{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 w6)return n;if(typeof n!="string")return;const t=BZ(n);if(t)return new w6(...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",SZ(this.rgb))}get lab(){return this.overwriteGetter("lab",lU(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})`}};Is.black=new Is(0,0,0,1);Is.white=new Is(1,1,1,1);Is.transparent=new Is(0,0,0,0);Is.red=new Is(1,0,0,1);let BB=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}},M6=class{constructor(n,t,r,i,o){this.text=n,this.image=t,this.scale=r,this.fontStack=i,this.textColor=o}},zy=class m2{constructor(n){this.sections=n}static fromString(n){return new m2([new M6(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 m2?n:m2.fromString(n)}toString(){return this.sections.length===0?"":this.sections.map(n=>n.text).join("")}};class Rc{constructor(n){this.values=n.slice()}static parse(n){if(n instanceof Rc)return n;if(typeof n=="number")return new Rc([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 Rc(n)}}toString(){return JSON.stringify(this.values)}}const IZ=new Set(["center","left","right","top","bottom","top-left","top-right","bottom-left","bottom-right"]);class yf{constructor(n){this.values=n.slice()}static parse(n){if(n instanceof yf)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"||!IZ.has(r)||!Array.isArray(i)||i.length!==2||typeof i[0]!="number"||typeof i[1]!="number")return}return new yf(n)}}toString(){return JSON.stringify(this.values)}}let v1=class AU{constructor(n){this.name=n.name,this.available=n.available}toString(){return this.name}static fromString(n){return n?new AU({name:n,available:!1}):null}};function cU(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 a3(e){if(e===null||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||e instanceof Is||e instanceof BB||e instanceof zy||e instanceof Rc||e instanceof yf||e instanceof v1)return!0;if(Array.isArray(e)){for(const n of e)if(!a3(n))return!1;return!0}else if(typeof e=="object"){for(const n in e)if(!a3(e[n]))return!1;return!0}else return!1}function Yl(e){if(e===null)return V4;if(typeof e=="string")return mo;if(typeof e=="boolean")return Vi;if(typeof e=="number")return nr;if(e instanceof Is)return pf;if(e instanceof BB)return Z4;if(e instanceof zy)return X4;if(e instanceof Rc)return J4;if(e instanceof yf)return e5;if(e instanceof v1)return zC;if(Array.isArray(e)){const n=e.length;let t;for(const r of e){const i=Yl(r);if(!t)t=i;else{if(t===i)continue;t=Xi;break}}return Tc(t||Xi,n)}else return ey}function S_(e){const n=typeof e;return e===null?"":n==="string"||n==="number"||n==="boolean"?String(e):e instanceof Is||e instanceof zy||e instanceof Rc||e instanceof yf||e instanceof v1?e.toString():JSON.stringify(e)}let s3=class dU{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(!a3(n[1]))return t.error("invalid value");const r=n[1];let i=Yl(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 dU(i,r)}evaluate(){return this.value}eachChild(){}outputDefined(){return!0}},yl=class{constructor(n){this.name="ExpressionEvaluationError",this.message=n}toJSON(){return this.message}};const yx={string:mo,number:nr,boolean:Vi,object:ey};let mp=class hU{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 yx)||g==="object")return t.error('The item type argument of "array" must be one of string, number, boolean',1);a=yx[g],r++}else a=Xi;let h;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);h=n[2],r++}i=Tc(a,h)}else{if(!yx[o])throw new Error(`Types doesn't contain name = ${o}`);i=yx[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 hU(i,s)}evaluate(n){for(let t=0;t<this.args.length;t++){const r=this.args[t].evaluate(n);if(nC(this.type,Yl(r))){if(t===this.args.length-1)throw new yl(`Expected value to be of type ${Bs(this.type)}, but found ${Bs(Yl(r))} instead.`)}else return r}throw new Error}eachChild(n){this.args.forEach(n)}outputDefined(){return this.args.every(n=>n.outputDefined())}};const HI={"to-boolean":Vi,"to-color":pf,"to-number":nr,"to-string":mo};let Ug=class fU{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(!HI[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=HI[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 fU(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 Is)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=cU(t[0],t[1],t[2],t[3]),!r))return new Is(t[0]/255,t[1]/255,t[2]/255,t[3])}throw new yl(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=Rc.parse(t);if(i)return i}throw new yl(`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=yf.parse(t);if(i)return i}throw new yl(`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 yl(`Could not convert ${JSON.stringify(t)} to number.`)}case"formatted":return zy.fromString(S_(this.args[0].evaluate(n)));case"resolvedImage":return v1.fromString(S_(this.args[0].evaluate(n)));default:return S_(this.args[0].evaluate(n))}}eachChild(n){this.args.forEach(n)}outputDefined(){return this.args.every(n=>n.outputDefined())}};const TZ=["Unknown","Point","LineString","Polygon"];let pU=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"?TZ[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]=Is.parse(n)),t}},mU=class gU{constructor(n,t,r=[],i,o=new _Z,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 mp(o,[i]):s==="coerce"?new Ug(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,h=s.type;if((a.kind==="string"||a.kind==="number"||a.kind==="boolean"||a.kind==="object"||a.kind==="array")&&h.kind==="value")s=r(s,a,t.typeAnnotation||"assert");else if((a.kind==="color"||a.kind==="formatted"||a.kind==="resolvedImage")&&(h.kind==="value"||h.kind==="string"))s=r(s,a,t.typeAnnotation||"coerce");else if(a.kind==="padding"&&(h.kind==="value"||h.kind==="number"||h.kind==="array"))s=r(s,a,t.typeAnnotation||"coerce");else if(a.kind==="variableAnchorOffsetCollection"&&(h.kind==="value"||h.kind==="array"))s=r(s,a,t.typeAnnotation||"coerce");else if(this.checkSubtype(a,h))return null}if(!(s instanceof s3)&&s.type.kind!=="resolvedImage"&&this._isConstant(s)){const a=new pU;try{s=new s3(s.type,s.evaluate(a))}catch(h){return this.error(h.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 gU(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 af(r,n))}checkSubtype(n,t){const r=nC(n,t);return r&&this.error(r),r}},yU=class vU{constructor(n,t,r){this.type=Z4,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,mo),!s)?null:new vU(i,o,s)}evaluate(n){return new BB(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 Tm=8192;function kB(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 KZ(e){return(180+e)/360}function PZ(e){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+e*Math.PI/360)))/360}function l3(e,n){return!(e[0]<=n[0]||e[2]>=n[2]||e[1]<=n[1]||e[3]>=n[3])}function FZ(e,n){const t=KZ(e[0]),r=PZ(e[1]),i=Math.pow(2,n.z);return[Math.round(t*i*Tm),Math.round(r*i*Tm)]}function DZ(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 LZ(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 IB(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(DZ(e,o[s],o[s+1]))return!1;LZ(e,o[s],o[s+1])&&(t=!t)}}return t}function UZ(e,n){for(let t=0;t<n.length;t++)if(IB(e,n[t]))return!0;return!1}function RZ(e,n){return e[0]*n[1]-e[1]*n[0]}function VI(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],h=r[0]-t[0],g=r[1]-t[1],C=i*g-h*o,B=s*g-h*a;return C>0&&B<0||C<0&&B>0}function zZ(e,n,t,r){const i=[n[0]-e[0],n[1]-e[1]],o=[r[0]-t[0],r[1]-t[1]];return RZ(o,i)===0?!1:!!(VI(e,n,t,r)&&VI(t,r,e,n))}function jZ(e,n,t){for(const r of t)for(let i=0;i<r.length-1;++i)if(zZ(e,n,r[i],r[i+1]))return!0;return!1}function _U(e,n){for(let t=0;t<e.length;++t)if(!IB(e[t],n))return!1;for(let t=0;t<e.length-1;++t)if(jZ(e[t],e[t+1],n))return!1;return!0}function WZ(e,n){for(let t=0;t<n.length;t++)if(_U(e,n[t]))return!0;return!1}function TB(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=FZ(e[i][s],t);kB(n,a),o.push(a)}r.push(o)}return r}function CU(e,n,t){const r=[];for(let i=0;i<e.length;i++){const o=TB(e[i],n,t);r.push(o)}return r}function bU(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}kB(n,e)}function NZ(e){e[0]=e[1]=1/0,e[2]=e[3]=-1/0}function ZI(e,n,t,r){const i=Math.pow(2,r.z)*Tm,o=[r.x*Tm,r.y*Tm],s=[];for(const a of e)for(const h of a){const g=[h.x+o[0],h.y+o[1]];bU(g,n,t,i),s.push(g)}return s}function XI(e,n,t,r){const i=Math.pow(2,r.z)*Tm,o=[r.x*Tm,r.y*Tm],s=[];for(const a of e){const h=[];for(const g of a){const C=[g.x+o[0],g.y+o[1]];kB(n,C),h.push(C)}s.push(h)}if(n[2]-n[0]<=i/2){NZ(n);for(const a of s)for(const h of a)bU(h,n,t,i)}return s}function GZ(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=TB(n.coordinates,r,i),s=ZI(e.geometry(),t,r,i);if(!l3(t,r))return!1;for(const a of s)if(!IB(a,o))return!1}if(n.type==="MultiPolygon"){const o=CU(n.coordinates,r,i),s=ZI(e.geometry(),t,r,i);if(!l3(t,r))return!1;for(const a of s)if(!UZ(a,o))return!1}return!0}function QZ(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=TB(n.coordinates,r,i),s=XI(e.geometry(),t,r,i);if(!l3(t,r))return!1;for(const a of s)if(!_U(a,o))return!1}if(n.type==="MultiPolygon"){const o=CU(n.coordinates,r,i),s=XI(e.geometry(),t,r,i);if(!l3(t,r))return!1;for(const a of s)if(!WZ(a,o))return!1}return!0}let KB=class g2{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(a3(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 g2(r,o)}}else if(r.type==="Feature"){const i=r.geometry.type;if(i==="Polygon"||i==="MultiPolygon")return new g2(r,r.geometry)}else if(r.type==="Polygon"||r.type==="MultiPolygon")return new g2(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 GZ(n,this.geometries);if(n.geometryType()==="LineString")return QZ(n,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}},xU=class wU{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 wU(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}},jy=class r_{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=r_.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 h=null;for(const[g,C]of a){h=new mU(t.registry,u3,t.path,null,t.scope);const B=[];let k=!1;for(let P=1;P<n.length;P++){const L=n[P],J=Array.isArray(g)?g[P-1]:g.type,N=h.parse(L,1+B.length,J);if(!N){k=!0;break}B.push(N)}if(!k){if(Array.isArray(g)&&g.length!==B.length){h.error(`Expected ${g.length} arguments, but found ${B.length} instead.`);continue}for(let P=0;P<B.length;P++){const L=Array.isArray(g)?g[P]:g.type,J=B[P];h.concat(P+1).checkSubtype(L,J.type)}if(h.errors.length===0)return new r_(r,o,C,B)}}if(a.length===1)t.errors.push(...h.errors);else{const C=(a.length?a:s).map(([k])=>$Z(k)).join(" | "),B=[];for(let k=1;k<n.length;k++){const P=t.parse(n[k],1+B.length);if(!P)return null;B.push(Bs(P.type))}t.error(`Expected arguments of type ${C}, but found (${B.join(", ")}) instead.`)}return null}static register(n,t){r_.definitions=t;for(const r in t)n[r]=r_}};function $Z(e){return Array.isArray(e)?`(${e.map(Bs).join(", ")})`:`(${Bs(e.type)}...)`}function u3(e){if(e instanceof xU)return u3(e.boundExpression);if(e instanceof jy&&e.name==="error")return!1;if(e instanceof yU)return!1;if(e instanceof KB)return!1;const n=e instanceof Ug||e instanceof mp;let t=!0;return e.eachChild(r=>{n?t=t&&u3(r):t=t&&r instanceof s3}),t?t5(e)&&n5(e,["zoom","heatmap-density","line-progress","accumulated","is-supported-script"]):!1}function t5(e){if(e instanceof jy){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 KB)return!1;let n=!0;return e.eachChild(t=>{n&&!t5(t)&&(n=!1)}),n}function iC(e){if(e instanceof jy&&e.name==="feature-state")return!1;let n=!0;return e.eachChild(t=>{n&&!iC(t)&&(n=!1)}),n}function n5(e,n){if(e instanceof jy&&n.indexOf(e.name)>=0)return!1;let t=!0;return e.eachChild(r=>{t&&!n5(r,n)&&(t=!1)}),t}function r5(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 yl("Input is not a number.");return 0}let MU=class SU{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,nr);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],h=n[s+1],g=s,C=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 B=t.parse(h,C,o);if(!B)return null;o=o||B.type,i.push([a,B])}return new SU(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=r5(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 YZ(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var qZ=EU;function EU(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}EU.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 HZ=YZ(qZ);function VZ(e){return e==="rgb"||e==="hcl"||e==="lab"}function V0(e,n,t){return e+t*(n-e)}function ZZ(e,n,t,r="rgb"){switch(r){case"rgb":{const[i,o,s,a]=A3(e.rgb,n.rgb,t);return new Is(i,o,s,a,!1)}case"hcl":{const[i,o,s,a]=e.hcl,[h,g,C,B]=n.hcl;let k,P;if(!isNaN(i)&&!isNaN(h)){let q=h-i;h>i&&q>180?q-=360:h<i&&i-h>180&&(q+=360),k=i+t*q}else isNaN(i)?isNaN(h)?k=NaN:(k=h,(s===1||s===0)&&(P=g)):(k=i,(C===1||C===0)&&(P=o));const[L,J,N,$]=EZ([k,P??V0(o,g,t),V0(s,C,t),V0(a,B,t)]);return new Is(L,J,N,$,!1)}case"lab":{const[i,o,s,a]=uU(A3(e.lab,n.lab,t));return new Is(i,o,s,a,!1)}}}function A3(e,n,t){return e.map((r,i)=>V0(r,n[i],t))}function XZ(e,n,t){return new Rc(A3(e.values,n.values,t))}function JZ(e,n,t){const r=e.values,i=n.values;if(r.length!==i.length)throw new yl(`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 yl(`Cannot interpolate values containing mismatched anchors. from[${s}]: ${r[s]}, to[${s}]: ${i[s]}`);o.push(r[s]);const[a,h]=r[s+1],[g,C]=i[s+1];o.push([V0(a,g,t),V0(h,C,t)])}return new yf(o)}const y2={number:V0,color:ZZ,array:A3,padding:XZ,variableAnchorOffsetCollection:JZ};let bp=class S6{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=sM(t,n.base,r,i);else if(n.name==="linear")o=sM(t,1,r,i);else if(n.name==="cubic-bezier"){const s=n.controlPoints;o=new HZ(s[0],s[1],s[2],s[3]).solve(sM(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(C=>typeof C!="number"||C<0||C>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,nr),!o)return null;const a=[];let h=null;r==="interpolate-hcl"||r==="interpolate-lab"?h=pf:t.expectedType&&t.expectedType.kind!=="value"&&(h=t.expectedType);for(let g=0;g<s.length;g+=2){const C=s[g],B=s[g+1],k=g+3,P=g+4;if(typeof C!="number")return t.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',k);if(a.length&&a[a.length-1][0]>=C)return t.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',k);const L=t.parse(B,P,h);if(!L)return null;h=h||L.type,a.push([C,L])}return!Uv(h,nr)&&!Uv(h,pf)&&!Uv(h,J4)&&!Uv(h,e5)&&!Uv(h,Tc(nr))?t.error(`Type ${Bs(h)} is not interpolatable.`):new S6(h,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=r5(t,i),a=t[s],h=t[s+1],g=S6.interpolationFactor(this.interpolation,i,a,h),C=r[s].evaluate(n),B=r[s+1].evaluate(n);switch(this.operator){case"interpolate":return y2[this.type.kind](C,B,g);case"interpolate-hcl":return y2.color(C,B,g,"hcl");case"interpolate-lab":return y2.color(C,B,g,"lab")}}eachChild(n){n(this.input);for(const t of this.outputs)n(t)}outputDefined(){return this.outputs.every(n=>n.outputDefined())}};function sM(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 OU=class E6{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 h=t.parse(a,1+o.length,r,void 0,{typeAnnotation:"omit"});if(!h)return null;r=r||h.type,o.push(h)}if(!r)throw new Error("No output type");return i&&o.some(a=>nC(i,a.type))?new E6(Xi,o):new E6(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 v1&&!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())}},BU=class kU{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 kU(r,i):null}outputDefined(){return this.result.outputDefined()}},eX=class IU{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,nr),i=t.parse(n[2],2,Tc(t.expectedType||Xi));if(!r||!i)return null;const o=i.type;return new IU(o.itemType,r,i)}evaluate(n){const t=this.index.evaluate(n),r=this.input.evaluate(n);if(t<0)throw new yl(`Array index out of bounds: ${t} < 0.`);if(t>=r.length)throw new yl(`Array index out of bounds: ${t} > ${r.length-1}.`);if(t!==Math.floor(t))throw new yl(`Array index must be an integer, but found ${t} instead.`);return r[t]}eachChild(n){n(this.index),n(this.input)}outputDefined(){return!1}},tX=class TU{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,Xi),i=t.parse(n[2],2,Xi);return!r||!i?null:OB(r.type,[Vi,mo,nr,V4,Xi])?new TU(r,i):t.error(`Expected first argument to be of type boolean, string, number or null, but found ${Bs(r.type)} instead`)}evaluate(n){const t=this.needle.evaluate(n),r=this.haystack.evaluate(n);if(!r)return!1;if(!rC(t,["boolean","string","number","null"]))throw new yl(`Expected first argument to be of type boolean, string, number or null, but found ${Bs(Yl(t))} instead.`);if(!rC(r,["string","array"]))throw new yl(`Expected second argument to be of type array or string, but found ${Bs(Yl(r))} instead.`);return r.indexOf(t)>=0}eachChild(n){n(this.needle),n(this.haystack)}outputDefined(){return!0}},nX=class O6{constructor(n,t,r){this.type=nr,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(!OB(r.type,[Vi,mo,nr,V4,Xi]))return t.error(`Expected first argument to be of type boolean, string, number or null, but found ${Bs(r.type)} instead`);if(n.length===4){const o=t.parse(n[3],3,nr);return o?new O6(r,i,o):null}else return new O6(r,i)}evaluate(n){const t=this.needle.evaluate(n),r=this.haystack.evaluate(n);if(!rC(t,["boolean","string","number","null"]))throw new yl(`Expected first argument to be of type boolean, string, number or null, but found ${Bs(Yl(t))} instead.`);if(!rC(r,["string","array"]))throw new yl(`Expected second argument to be of type array or string, but found ${Bs(Yl(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}},rX=class KU{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 C=n[g];const B=n[g+1];Array.isArray(C)||(C=[C]);const k=t.concat(g);if(C.length===0)return k.error("Expected at least one branch label.");for(const L of C){if(typeof L!="number"&&typeof L!="string")return k.error("Branch labels must be numbers or strings.");if(typeof L=="number"&&Math.abs(L)>Number.MAX_SAFE_INTEGER)return k.error(`Branch labels must be integers no larger than ${Number.MAX_SAFE_INTEGER}.`);if(typeof L=="number"&&Math.floor(L)!==L)return k.error("Numeric branch labels must be integer values.");if(!r)r=Yl(L);else if(k.checkSubtype(r,Yl(L)))return null;if(typeof o[String(L)]<"u")return k.error("Branch labels must be unique.");o[String(L)]=s.length}const P=t.parse(B,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 h=t.parse(n[n.length-1],n.length-1,i);return!h||a.type.kind!=="value"&&t.concat(1).checkSubtype(r,a.type)?null:new KU(r,i,a,o,s,h)}evaluate(n){const t=this.input.evaluate(n);return(Yl(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()}},iX=class PU{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 h=t.parse(n[s+1],s+1,r);if(!h)return null;i.push([a,h]),r=r||h.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 PU(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()}},oX=class B6{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,nr);if(!r||!i)return null;if(!OB(r.type,[Tc(Xi),mo,Xi]))return t.error(`Expected first argument to be of type array or string, but found ${Bs(r.type)} instead`);if(n.length===4){const o=t.parse(n[3],3,nr);return o?new B6(r.type,r,i,o):null}else return new B6(r.type,r,i)}evaluate(n){const t=this.input.evaluate(n),r=this.beginIndex.evaluate(n);if(!rC(t,["string","array"]))throw new yl(`Expected first argument to be of type array or string, but found ${Bs(Yl(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 JI(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 aX(e,n,t){return n===t}function sX(e,n,t){return n!==t}function lX(e,n,t){return n<t}function uX(e,n,t){return n>t}function AX(e,n,t){return n<=t}function cX(e,n,t){return n>=t}function FU(e,n,t,r){return r.compare(n,t)===0}function dX(e,n,t,r){return!FU(e,n,t,r)}function hX(e,n,t,r){return r.compare(n,t)<0}function fX(e,n,t,r){return r.compare(n,t)>0}function pX(e,n,t,r){return r.compare(n,t)<=0}function mX(e,n,t,r){return r.compare(n,t)>=0}function Wy(e,n,t){const r=e!=="=="&&e!=="!=";return class DU{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 h=s.parse(o[1],1,Xi);if(!h)return null;if(!JI(a,h.type))return s.concat(1).error(`"${a}" comparisons are not supported for type '${Bs(h.type)}'.`);let g=s.parse(o[2],2,Xi);if(!g)return null;if(!JI(a,g.type))return s.concat(2).error(`"${a}" comparisons are not supported for type '${Bs(g.type)}'.`);if(h.type.kind!==g.type.kind&&h.type.kind!=="value"&&g.type.kind!=="value")return s.error(`Cannot compare types '${Bs(h.type)}' and '${Bs(g.type)}'.`);r&&(h.type.kind==="value"&&g.type.kind!=="value"?h=new mp(g.type,[h]):h.type.kind!=="value"&&g.type.kind==="value"&&(g=new mp(h.type,[g])));let C=null;if(o.length===4){if(h.type.kind!=="string"&&g.type.kind!=="string"&&h.type.kind!=="value"&&g.type.kind!=="value")return s.error("Cannot use collator to compare non-string types.");if(C=s.parse(o[3],3,Z4),!C)return null}return new DU(h,g,C)}evaluate(o){const s=this.lhs.evaluate(o),a=this.rhs.evaluate(o);if(r&&this.hasUntypedArgument){const h=Yl(s),g=Yl(a);if(h.kind!==g.kind||!(h.kind==="string"||h.kind==="number"))throw new yl(`Expected arguments for "${e}" to be (string, string) or (number, number), but found (${h.kind}, ${g.kind}) instead.`)}if(this.collator&&!r&&this.hasUntypedArgument){const h=Yl(s),g=Yl(a);if(h.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 gX=Wy("==",aX,FU),yX=Wy("!=",sX,dX),vX=Wy("<",lX,hX),_X=Wy(">",uX,fX),CX=Wy("<=",AX,pX),bX=Wy(">=",cX,mX);let xX=class LU{constructor(n,t,r,i,o){this.type=mo,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,nr);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,mo),!o))return null;let s=null;if(i.currency&&(s=t.parse(i.currency,1,mo),!s))return null;let a=null;if(i["min-fraction-digits"]&&(a=t.parse(i["min-fraction-digits"],1,nr),!a))return null;let h=null;return i["max-fraction-digits"]&&(h=t.parse(i["max-fraction-digits"],1,nr),!h)?null:new LU(r,o,s,a,h)}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}},wX=class UU{constructor(n){this.type=X4,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 h=null;if(a["font-scale"]&&(h=t.parse(a["font-scale"],1,nr),!h))return null;let g=null;if(a["text-font"]&&(g=t.parse(a["text-font"],1,Tc(mo)),!g))return null;let C=null;if(a["text-color"]&&(C=t.parse(a["text-color"],1,pf),!C))return null;const B=i[i.length-1];B.scale=h,B.font=g,B.textColor=C}else{const h=t.parse(n[s],1,Xi);if(!h)return null;const g=h.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:h,scale:null,font:null,textColor:null})}}return new UU(i)}evaluate(n){const t=r=>{const i=r.content.evaluate(n);return Yl(i)===zC?new M6("",i,null,null,null):new M6(S_(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 zy(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}},MX=class RU{constructor(n){this.type=zC,this.input=n}static parse(n,t){if(n.length!==2)return t.error("Expected two arguments.");const r=t.parse(n[1],1,mo);return r?new RU(r):t.error("No image name provided.")}evaluate(n){const t=this.input.evaluate(n),r=v1.fromString(t);return r&&n.availableImages&&(r.available=n.availableImages.indexOf(t)>-1),r}eachChild(n){n(this.input)}outputDefined(){return!1}},SX=class zU{constructor(n){this.type=nr,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 ${Bs(r.type)} instead.`):new zU(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 yl(`Expected value to be of type string or array, but found ${Bs(Yl(t))} instead.`)}eachChild(n){n(this.input)}outputDefined(){return!1}};const PB={"==":gX,"!=":yX,">":_X,"<":vX,">=":bX,"<=":CX,array:mp,at:eX,boolean:mp,case:iX,coalesce:OU,collator:yU,format:wX,image:MX,in:tX,"index-of":nX,interpolate:bp,"interpolate-hcl":bp,"interpolate-lab":bp,length:SX,let:BU,literal:s3,match:rX,number:mp,"number-format":xX,object:mp,slice:oX,step:MU,string:mp,"to-boolean":Ug,"to-color":Ug,"to-number":Ug,"to-string":Ug,var:xU,within:KB};function e9(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=cU(n,t,r,o);if(s)throw new yl(s);return new Is(n/255,t/255,r/255,o,!1)}function t9(e,n){return e in n}function lM(e,n){const t=n[e];return typeof t>"u"?null:t}function EX(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 p0(e){return{type:e}}jy.register(PB,{error:[CZ,[mo],(e,[n])=>{throw new yl(n.evaluate(e))}],typeof:[mo,[Xi],(e,[n])=>Bs(Yl(n.evaluate(e)))],"to-rgba":[Tc(nr,4),[pf],(e,[n])=>{const[t,r,i,o]=n.evaluate(e).rgb;return[t*255,r*255,i*255,o]}],rgb:[pf,[nr,nr,nr],e9],rgba:[pf,[nr,nr,nr,nr],e9],has:{type:Vi,overloads:[[[mo],(e,[n])=>t9(n.evaluate(e),e.properties())],[[mo,ey],(e,[n,t])=>t9(n.evaluate(e),t.evaluate(e))]]},get:{type:Xi,overloads:[[[mo],(e,[n])=>lM(n.evaluate(e),e.properties())],[[mo,ey],(e,[n,t])=>lM(n.evaluate(e),t.evaluate(e))]]},"feature-state":[Xi,[mo],(e,[n])=>lM(n.evaluate(e),e.featureState||{})],properties:[ey,[],e=>e.properties()],"geometry-type":[mo,[],e=>e.geometryType()],id:[Xi,[],e=>e.id()],zoom:[nr,[],e=>e.globals.zoom],"heatmap-density":[nr,[],e=>e.globals.heatmapDensity||0],"line-progress":[nr,[],e=>e.globals.lineProgress||0],accumulated:[Xi,[],e=>e.globals.accumulated===void 0?null:e.globals.accumulated],"+":[nr,p0(nr),(e,n)=>{let t=0;for(const r of n)t+=r.evaluate(e);return t}],"*":[nr,p0(nr),(e,n)=>{let t=1;for(const r of n)t*=r.evaluate(e);return t}],"-":{type:nr,overloads:[[[nr,nr],(e,[n,t])=>n.evaluate(e)-t.evaluate(e)],[[nr],(e,[n])=>-n.evaluate(e)]]},"/":[nr,[nr,nr],(e,[n,t])=>n.evaluate(e)/t.evaluate(e)],"%":[nr,[nr,nr],(e,[n,t])=>n.evaluate(e)%t.evaluate(e)],ln2:[nr,[],()=>Math.LN2],pi:[nr,[],()=>Math.PI],e:[nr,[],()=>Math.E],"^":[nr,[nr,nr],(e,[n,t])=>Math.pow(n.evaluate(e),t.evaluate(e))],sqrt:[nr,[nr],(e,[n])=>Math.sqrt(n.evaluate(e))],log10:[nr,[nr],(e,[n])=>Math.log(n.evaluate(e))/Math.LN10],ln:[nr,[nr],(e,[n])=>Math.log(n.evaluate(e))],log2:[nr,[nr],(e,[n])=>Math.log(n.evaluate(e))/Math.LN2],sin:[nr,[nr],(e,[n])=>Math.sin(n.evaluate(e))],cos:[nr,[nr],(e,[n])=>Math.cos(n.evaluate(e))],tan:[nr,[nr],(e,[n])=>Math.tan(n.evaluate(e))],asin:[nr,[nr],(e,[n])=>Math.asin(n.evaluate(e))],acos:[nr,[nr],(e,[n])=>Math.acos(n.evaluate(e))],atan:[nr,[nr],(e,[n])=>Math.atan(n.evaluate(e))],min:[nr,p0(nr),(e,n)=>Math.min(...n.map(t=>t.evaluate(e)))],max:[nr,p0(nr),(e,n)=>Math.max(...n.map(t=>t.evaluate(e)))],abs:[nr,[nr],(e,[n])=>Math.abs(n.evaluate(e))],round:[nr,[nr],(e,[n])=>{const t=n.evaluate(e);return t<0?-Math.round(-t):Math.round(t)}],floor:[nr,[nr],(e,[n])=>Math.floor(n.evaluate(e))],ceil:[nr,[nr],(e,[n])=>Math.ceil(n.evaluate(e))],"filter-==":[Vi,[mo,Xi],(e,[n,t])=>e.properties()[n.value]===t.value],"filter-id-==":[Vi,[Xi],(e,[n])=>e.id()===n.value],"filter-type-==":[Vi,[mo],(e,[n])=>e.geometryType()===n.value],"filter-<":[Vi,[mo,Xi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r<i}],"filter-id-<":[Vi,[Xi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t<r}],"filter->":[Vi,[mo,Xi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r>i}],"filter-id->":[Vi,[Xi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t>r}],"filter-<=":[Vi,[mo,Xi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r<=i}],"filter-id-<=":[Vi,[Xi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t<=r}],"filter->=":[Vi,[mo,Xi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r>=i}],"filter-id->=":[Vi,[Xi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t>=r}],"filter-has":[Vi,[Xi],(e,[n])=>n.value in e.properties()],"filter-has-id":[Vi,[],e=>e.id()!==null&&e.id()!==void 0],"filter-type-in":[Vi,[Tc(mo)],(e,[n])=>n.value.indexOf(e.geometryType())>=0],"filter-id-in":[Vi,[Tc(Xi)],(e,[n])=>n.value.indexOf(e.id())>=0],"filter-in-small":[Vi,[mo,Tc(Xi)],(e,[n,t])=>t.value.indexOf(e.properties()[n.value])>=0],"filter-in-large":[Vi,[mo,Tc(Xi)],(e,[n,t])=>EX(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)],[p0(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)],[p0(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,[mo],(e,[n])=>{const t=e.globals&&e.globals.isSupportedScript;return t?t(n.evaluate(e)):!0}],upcase:[mo,[mo],(e,[n])=>n.evaluate(e).toUpperCase()],downcase:[mo,[mo],(e,[n])=>n.evaluate(e).toLowerCase()],concat:[mo,p0(Xi),(e,n)=>n.map(t=>S_(t.evaluate(e))).join("")],"resolved-locale":[mo,[Z4],(e,[n])=>n.evaluate(e).resolvedLocale()]});function k6(e){return{result:"success",value:e}}function Cg(e){return{result:"error",value:e}}function c3(e){return e["property-type"]==="data-driven"||e["property-type"]==="cross-faded-data-driven"}function jU(e){return!!e.expression&&e.expression.parameters.indexOf("zoom")>-1}function FB(e){return!!e.expression&&e.expression.interpolated}function jo(e){return e instanceof Number?"number":e instanceof String?"string":e instanceof Boolean?"boolean":Array.isArray(e)?"array":e===null?"null":typeof e}function jC(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function OX(e){return e}function DB(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||(FB(n)?"exponential":"interval");if(t||n.type==="padding"){const C=t?Is.parse:Rc.parse;e=My({},e),e.stops&&(e.stops=e.stops.map(B=>[B[0],C(B[1])])),e.default?e.default=C(e.default):e.default=C(n.default)}if(e.colorSpace&&!VZ(e.colorSpace))throw new Error(`Unknown color space: "${e.colorSpace}"`);let a,h,g;if(s==="exponential")a=n9;else if(s==="interval")a=kX;else if(s==="categorical"){a=BX,h=Object.create(null);for(const C of e.stops)h[C[0]]=C[1];g=typeof e.stops[0][0]}else if(s==="identity")a=IX;else throw new Error(`Unknown function type "${s}"`);if(r){const C={},B=[];for(let L=0;L<e.stops.length;L++){const J=e.stops[L],N=J[0].zoom;C[N]===void 0&&(C[N]={zoom:N,type:e.type,property:e.property,default:e.default,stops:[]},B.push(N)),C[N].stops.push([J[0].value,J[1]])}const k=[];for(const L of B)k.push([C[L].zoom,DB(C[L],n)]);const P={name:"linear"};return{kind:"composite",interpolationType:P,interpolationFactor:bp.interpolationFactor.bind(void 0,P),zoomStops:k.map(L=>L[0]),evaluate({zoom:L},J){return n9({stops:k,base:e.base},n,L).evaluate(L,J)}}}else if(o){const C=s==="exponential"?{name:"exponential",base:e.base!==void 0?e.base:1}:null;return{kind:"camera",interpolationType:C,interpolationFactor:bp.interpolationFactor.bind(void 0,C),zoomStops:e.stops.map(B=>B[0]),evaluate:({zoom:B})=>a(e,n,B,h,g)}}else return{kind:"source",evaluate(C,B){const k=B&&B.properties?B.properties[e.property]:void 0;return k===void 0?WC(e.default,n.default):a(e,n,k,h,g)}}}function WC(e,n,t){if(e!==void 0)return e;if(n!==void 0)return n;if(t!==void 0)return t}function BX(e,n,t,r,i){const o=typeof t===i?r[t]:void 0;return WC(o,e.default,n.default)}function kX(e,n,t){if(jo(t)!=="number")return WC(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=r5(e.stops.map(o=>o[0]),t);return e.stops[i][1]}function n9(e,n,t){const r=e.base!==void 0?e.base:1;if(jo(t)!=="number")return WC(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=r5(e.stops.map(C=>C[0]),t),s=TX(t,r,e.stops[o][0],e.stops[o+1][0]),a=e.stops[o][1],h=e.stops[o+1][1],g=y2[n.type]||OX;return typeof a.evaluate=="function"?{evaluate(...C){const B=a.evaluate.apply(void 0,C),k=h.evaluate.apply(void 0,C);if(!(B===void 0||k===void 0))return g(B,k,s,e.colorSpace)}}:g(a,h,s,e.colorSpace)}function IX(e,n,t){switch(n.type){case"color":t=Is.parse(t);break;case"formatted":t=zy.fromString(t.toString());break;case"resolvedImage":t=v1.fromString(t.toString());break;case"padding":t=Rc.parse(t);break;default:jo(t)!==n.type&&(n.type!=="enum"||!n.values[t])&&(t=void 0)}return WC(t,e.default,n.default)}function TX(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 WU=class{constructor(n,t){this.expression=n,this._warningHistory={},this._evaluator=new pU,this._defaultValue=t?DX(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 yl(`Expected value to be one of ${Object.keys(this._enumValues).map(h=>JSON.stringify(h)).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 NC(e){return Array.isArray(e)&&e.length>0&&typeof e[0]=="string"&&e[0]in PB}function LB(e,n){const t=new mU(PB,u3,[],n?FX(n):void 0),r=t.parse(e,void 0,void 0,void 0,n&&n.type==="string"?{typeAnnotation:"coerce"}:void 0);return r?k6(new WU(r,n)):Cg(t.errors)}let I6=class{constructor(n,t){this.kind=n,this._styleExpression=t,this.isStateDependent=n!=="constant"&&!iC(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)}},T6=class{constructor(n,t,r,i){this.kind=n,this.zoomStops=r,this._styleExpression=t,this.isStateDependent=n!=="camera"&&!iC(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?bp.interpolationFactor(this.interpolationType,n,t,r):0}};function KX(e){return e._styleExpression!==void 0}function UB(e,n){const t=LB(e,n);if(t.result==="error")return t;const r=t.value.expression,i=t5(r);if(!i&&!c3(n))return Cg([new af("","data expressions not supported")]);const o=n5(r,["zoom"]);if(!o&&!jU(n))return Cg([new af("","zoom expressions not supported")]);const s=v2(r);if(!s&&!o)return Cg([new af("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')]);if(s instanceof af)return Cg([s]);if(s instanceof bp&&!FB(n))return Cg([new af("",'"interpolate" expressions cannot be used with this property')]);if(!s)return k6(i?new I6("constant",t.value):new I6("source",t.value));const a=s instanceof bp?s.interpolation:void 0;return k6(i?new T6("camera",t.value,s.labels,a):new T6("composite",t.value,s.labels,a))}let NU=class GU{constructor(n,t){this._parameters=n,this._specification=t,My(this,DB(this._parameters,this._specification))}static deserialize(n){return new GU(n._parameters,n._specification)}static serialize(n){return{_parameters:n._parameters,_specification:n._specification}}};function PX(e,n){if(jC(e))return new NU(e,n);if(NC(e)){const t=UB(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=Is.parse(e):n.type==="padding"&&(typeof e=="number"||Array.isArray(e))?t=Rc.parse(e):n.type==="variableAnchorOffsetCollection"&&Array.isArray(e)&&(t=yf.parse(e)),{kind:"constant",evaluate:()=>t}}}function v2(e){let n=null;if(e instanceof BU)n=v2(e.result);else if(e instanceof OU){for(const t of e.args)if(n=v2(t),n)break}else(e instanceof MU||e instanceof bp)&&e.input instanceof jy&&e.input.name==="zoom"&&(n=e);return n instanceof af||e.eachChild(t=>{const r=v2(t);r instanceof af?n=r:!n&&r?n=new af("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):n&&r&&n!==r&&(n=new af("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),n}function FX(e){const n={color:pf,string:mo,number:nr,enum:mo,boolean:Vi,formatted:X4,padding:J4,resolvedImage:zC,variableAnchorOffsetCollection:e5};return e.type==="array"?Tc(n[e.value]||Xi,e.length):n[e.type]}function DX(e){return e.type==="color"&&jC(e.default)?new Is(0,0,0,0):e.type==="color"?Is.parse(e.default)||null:e.type==="padding"?Rc.parse(e.default)||null:e.type==="variableAnchorOffsetCollection"?yf.parse(e.default)||null:e.default===void 0?null:e.default}function i5(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(!i5(n)&&typeof n!="boolean")return!1;return!0;default:return!0}}function E_(e,n={}){if(i5(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 UX(i,o,r,n)}case"any":{const[,...i]=t;return["any",...i.map(s=>{const a={},h=E_(s,a),g=LX(a);return g===!0?h:["case",g,h,!1]})]}case"all":{const[,...i]=t,o=i.map(s=>E_(s,n));return o.length>1?["all",...o]:o[0]}case"none":{const[,...i]=t;return["!",E_(["any",...i],{})]}case"in":{const[,i,...o]=t;return r9(i,o)}case"!in":{const[,i,...o]=t;return r9(i,o,!0)}case"has":return i9(t[1]);case"!has":return["!",i9(t[1])];default:return!0}}function LX(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 UX(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 r9(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,h)=>h===0||n[h-1]!==a);return["match",r,s,!t,t]}return t?["all",...n.map(s=>["!=",r,s])]:["any",...n.map(s=>["==",r,s])]}function i9(e){return e==="$type"?!0:e==="$id"?["!=",["id"],null]:["has",e]}function oC(e){return typeof e=="object"?["literal",e]:e}function QU(e,n){let t=e.stops;if(!t)return RX(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],$U(s[1])]:[s[0],oC(s[1])]),r?zX(e,n,t):o?WX(e,n,t):K6(e,n,t)}function RX(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,oC(e.default)];return n.type==="array"&&r.splice(1,0,n.value,n.length||null),r}}function RB(e){switch(e.colorSpace){case"hcl":return"interpolate-hcl";case"lab":return"interpolate-lab";default:return"interpolate"}}function zX(e,n,t){const r={},i={},o=[];for(let a=0;a<t.length;a++){const h=t[a],g=h[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([h[0].value,h[1]])}if(jB({},n)==="exponential"){const a=[RB(e),["linear"],["zoom"]];for(const h of o){const g=K6(r[h],n,i[h]);ny(a,h,g,!1)}return a}else{const a=["step",["zoom"]];for(const h of o){const g=K6(r[h],n,i[h]);ny(a,h,g,!0)}return zB(a),a}}function jX(e,n){if(e!==void 0)return e;if(n!==void 0)return n}function o9(e,n){const t=oC(jX(e.default,n.default));return t===void 0&&n.type==="resolvedImage"?"":t}function K6(e,n,t){const r=jB(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(o9(e,n)),o}else if(r==="categorical"){const o=["match",i];for(const s of t)ny(o,s[0],s[1],!1);return o.push(o9(e,n)),o}else if(r==="interval"){const o=["step",["number",i]];for(const s of t)ny(o,s[0],s[1],!0);return zB(o),e.default===void 0?o:["case",["==",["typeof",i],"number"],o,oC(e.default)]}else if(r==="exponential"){const o=e.base!==void 0?e.base:1,s=[RB(e),o===1?["linear"]:["exponential",o],["number",i]];for(const a of t)ny(s,a[0],a[1],!1);return e.default===void 0?s:["case",["==",["typeof",i],"number"],s,oC(e.default)]}else throw new Error(`Unknown property function type ${r}`)}function WX(e,n,t,r=["zoom"]){const i=jB(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=[RB(e),a===1?["linear"]:["exponential",a],r]}else throw new Error(`Unknown zoom function type "${i}"`);for(const a of t)ny(o,a[0],a[1],s);return zB(o),o}function zB(e){e[0]==="step"&&e.length===3&&(e.push(0),e.push(e[3]))}function ny(e,n,t,r){e.length>3&&n===e[e.length-2]||(r&&e.length===2||e.push(n),e.push(t))}function jB(e,n){return e.type?e.type:n.expression.interpolated?"exponential":"interval"}function $U(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 NX(e){for(let n=0;n<Ea.layout.length;n++)for(const t in Ea[Ea.layout[n]])if(t===e)return Ea[Ea.layout[n]][t];for(let n=0;n<Ea.paint.length;n++)for(const t in Ea[Ea.paint[n]])if(t===e)return Ea[Ea.paint[n]][t];return null}function GX(e,n){for(const t in e.sources)n(e.sources[t])}function O_(e,n){for(const t of e.layers)n(t)}function WB(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:NX(a),set(h){s[a]=h}})})}O_(e,i=>{n.paint&&r(i,"paint"),n.layout&&r(i,"layout")})}function YU(e){const n=e.key,t=e.value;return t?[new Zn(n,t,"constants have been deprecated as of v8")]:[]}function al(e){return e instanceof Number||e instanceof String||e instanceof Boolean?e.valueOf():e}function l1(e){if(Array.isArray(e))return e.map(l1);if(e instanceof Object&&!(e instanceof Number||e instanceof String||e instanceof Boolean)){const n={};for(const t in e)n[t]=l1(e[t]);return n}return al(e)}function gd(e){const n=e.key,t=e.value,r=e.valueSpec||{},i=e.objectElementValidators||{},o=e.style,s=e.styleSpec,a=e.validateSpec;let h=[];const g=jo(t);if(g!=="object")return[new Zn(n,t,`object expected, ${g} found`)];for(const C in t){const B=C.split(".")[0],k=r[B]||r["*"];let P;if(i[B])P=i[B];else if(r[B])P=a;else if(i["*"])P=i["*"];else if(r["*"])P=a;else{h.push(new Zn(n,t[C],`unknown property "${C}"`));continue}h=h.concat(P({key:(n&&`${n}.`)+C,value:t[C],valueSpec:k,style:o,styleSpec:s,object:t,objectKey:C,validateSpec:a},t))}for(const C in r)i[C]||r[C].required&&r[C].default===void 0&&t[C]===void 0&&h.push(new Zn(n,t,`missing required property "${C}"`));return h}function NB(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(jo(n)!=="array")return[new Zn(s,n,`array expected, ${jo(n)} found`)];if(t.length&&n.length!==t.length)return[new Zn(s,n,`array length ${t.length} expected, length ${n.length} found`)];if(t["min-length"]&&n.length<t["min-length"])return[new Zn(s,n,`array length at least ${t["min-length"]} expected, length ${n.length} found`)];let h={type:t.value,values:t.values};o.$version<7&&(h.function=t.function),jo(t.value)==="object"&&(h=t.value);let g=[];for(let C=0;C<n.length;C++)g=g.concat(a({array:n,arrayIndex:C,value:n[C],valueSpec:h,validateSpec:e.validateSpec,style:i,styleSpec:o,key:`${s}[${C}]`}));return g}function GB(e){const n=e.key,t=e.value,r=e.valueSpec;let i=jo(t);return i==="number"&&t!==t&&(i="NaN"),i!=="number"?[new Zn(n,t,`number expected, ${i} found`)]:"minimum"in r&&t<r.minimum?[new Zn(n,t,`${t} is less than the minimum value ${r.minimum}`)]:"maximum"in r&&t>r.maximum?[new Zn(n,t,`${t} is greater than the maximum value ${r.maximum}`)]:[]}function qU(e){const n=e.valueSpec,t=al(e.value.type);let r,i={},o,s;const a=t!=="categorical"&&e.value.property===void 0,h=!a,g=jo(e.value.stops)==="array"&&jo(e.value.stops[0])==="array"&&jo(e.value.stops[0][0])==="object",C=gd({key:e.key,value:e.value,valueSpec:e.styleSpec.function,validateSpec:e.validateSpec,style:e.style,styleSpec:e.styleSpec,objectElementValidators:{stops:B,default:L}});return t==="identity"&&a&&C.push(new Zn(e.key,e.value,'missing required property "property"')),t!=="identity"&&!e.value.stops&&C.push(new Zn(e.key,e.value,'missing required property "stops"')),t==="exponential"&&e.valueSpec.expression&&!FB(e.valueSpec)&&C.push(new Zn(e.key,e.value,"exponential functions not supported")),e.styleSpec.$version>=8&&(h&&!c3(e.valueSpec)?C.push(new Zn(e.key,e.value,"property functions not supported")):a&&!jU(e.valueSpec)&&C.push(new Zn(e.key,e.value,"zoom functions not supported"))),(t==="categorical"||g)&&e.value.property===void 0&&C.push(new Zn(e.key,e.value,'"property" property is required')),C;function B(J){if(t==="identity")return[new Zn(J.key,J.value,'identity function may not have a "stops" property')];let N=[];const $=J.value;return N=N.concat(NB({key:J.key,value:$,valueSpec:J.valueSpec,validateSpec:J.validateSpec,style:J.style,styleSpec:J.styleSpec,arrayElementValidator:k})),jo($)==="array"&&$.length===0&&N.push(new Zn(J.key,$,"array must have at least one stop")),N}function k(J){let N=[];const $=J.value,q=J.key;if(jo($)!=="array")return[new Zn(q,$,`array expected, ${jo($)} found`)];if($.length!==2)return[new Zn(q,$,`array length 2 expected, length ${$.length} found`)];if(g){if(jo($[0])!=="object")return[new Zn(q,$,`object expected, ${jo($[0])} found`)];if($[0].zoom===void 0)return[new Zn(q,$,"object stop key must have zoom")];if($[0].value===void 0)return[new Zn(q,$,"object stop key must have value")];if(s&&s>al($[0].zoom))return[new Zn(q,$[0].zoom,"stop zoom values must appear in ascending order")];al($[0].zoom)!==s&&(s=al($[0].zoom),o=void 0,i={}),N=N.concat(gd({key:`${q}[0]`,value:$[0],valueSpec:{zoom:{}},validateSpec:J.validateSpec,style:J.style,styleSpec:J.styleSpec,objectElementValidators:{zoom:GB,value:P}}))}else N=N.concat(P({key:`${q}[0]`,value:$[0],valueSpec:{},validateSpec:J.validateSpec,style:J.style,styleSpec:J.styleSpec},$));return NC(l1($[1]))?N.concat([new Zn(`${q}[1]`,$[1],"expressions are not allowed in function stops.")]):N.concat(J.validateSpec({key:`${q}[1]`,value:$[1],valueSpec:n,validateSpec:J.validateSpec,style:J.style,styleSpec:J.styleSpec}))}function P(J,N){const $=jo(J.value),q=al(J.value),oe=J.value!==null?J.value:N;if(!r)r=$;else if($!==r)return[new Zn(J.key,oe,`${$} stop domain type must match previous stop domain type ${r}`)];if($!=="number"&&$!=="string"&&$!=="boolean")return[new Zn(J.key,oe,"stop domain value must be a number, string, or boolean")];if($!=="number"&&t!=="categorical"){let ce=`number expected, ${$} found`;return c3(n)&&t===void 0&&(ce+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new Zn(J.key,oe,ce)]}return t==="categorical"&&$==="number"&&(!isFinite(q)||Math.floor(q)!==q)?[new Zn(J.key,oe,`integer expected, found ${q}`)]:t!=="categorical"&&$==="number"&&o!==void 0&&q<o?[new Zn(J.key,oe,"stop domain values must appear in ascending order")]:(o=q,t==="categorical"&&q in i?[new Zn(J.key,oe,"stop domain values must be unique")]:(i[q]=!0,[]))}function L(J){return J.validateSpec({key:J.key,value:J.value,valueSpec:n,validateSpec:J.validateSpec,style:J.style,styleSpec:J.styleSpec})}}function Sy(e){const n=(e.expressionContext==="property"?UB:LB)(l1(e.value),e.valueSpec);if(n.result==="error")return n.value.map(r=>new Zn(`${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 Zn(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"&&!iC(t))return[new Zn(e.key,e.value,'"feature-state" data expressions are not supported with layout properties.')];if(e.expressionContext==="filter"&&!iC(t))return[new Zn(e.key,e.value,'"feature-state" data expressions are not supported with filters.')];if(e.expressionContext&&e.expressionContext.indexOf("cluster")===0){if(!n5(t,["zoom","feature-state"]))return[new Zn(e.key,e.value,'"zoom" and "feature-state" expressions are not supported with cluster properties.')];if(e.expressionContext==="cluster-initial"&&!t5(t))return[new Zn(e.key,e.value,"Feature data expressions are not supported with initial expression part of cluster properties.")]}return[]}function QX(e){const n=e.value,t=e.key,r=jo(n);return r!=="boolean"?[new Zn(t,n,`boolean expected, ${r} found`)]:[]}function $X(e){const n=e.key,t=e.value,r=jo(t);return r!=="string"?[new Zn(n,t,`color expected, ${r} found`)]:Is.parse(String(t))?[]:[new Zn(n,t,`color expected, "${t}" found`)]}function aC(e){const n=e.key,t=e.value,r=e.valueSpec,i=[];return Array.isArray(r.values)?r.values.indexOf(al(t))===-1&&i.push(new Zn(n,t,`expected one of [${r.values.join(", ")}], ${JSON.stringify(t)} found`)):Object.keys(r.values).indexOf(al(t))===-1&&i.push(new Zn(n,t,`expected one of [${Object.keys(r.values).join(", ")}], ${JSON.stringify(t)} found`)),i}function QB(e){return i5(l1(e.value))?Sy(My({},e,{expressionContext:"filter",valueSpec:{value:"boolean"}})):HU(e)}function HU(e){const n=e.value,t=e.key;if(jo(n)!=="array")return[new Zn(t,n,`array expected, ${jo(n)} found`)];const r=e.styleSpec;let i,o=[];if(n.length<1)return[new Zn(t,n,"filter array must have at least 1 element")];switch(o=o.concat(aC({key:`${t}[0]`,value:n[0],valueSpec:r.filter_operator,style:e.style,styleSpec:e.styleSpec})),al(n[0])){case"<":case"<=":case">":case">=":n.length>=2&&al(n[1])==="$type"&&o.push(new Zn(t,n,`"$type" cannot be use with operator "${n[0]}"`));case"==":case"!=":n.length!==3&&o.push(new Zn(t,n,`filter array for operator "${n[0]}" must have 3 elements`));case"in":case"!in":n.length>=2&&(i=jo(n[1]),i!=="string"&&o.push(new Zn(`${t}[1]`,n[1],`string expected, ${i} found`)));for(let s=2;s<n.length;s++)i=jo(n[s]),al(n[1])==="$type"?o=o.concat(aC({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 Zn(`${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(HU({key:`${t}[${s}]`,value:n[s],style:e.style,styleSpec:e.styleSpec}));break;case"has":case"!has":i=jo(n[1]),n.length!==2?o.push(new Zn(t,n,`filter array for "${n[0]}" operator must have 2 elements`)):i!=="string"&&o.push(new Zn(`${t}[1]`,n[1],`string expected, ${i} found`));break;case"within":i=jo(n[1]),n.length!==2?o.push(new Zn(t,n,`filter array for "${n[0]}" operator must have 2 elements`)):i!=="object"&&o.push(new Zn(`${t}[1]`,n[1],`object expected, ${i} found`));break}return o}function VU(e,n){const t=e.key,r=e.validateSpec,i=e.style,o=e.styleSpec,s=e.value,a=e.objectKey,h=o[`${n}_${e.layerType}`];if(!h)return[];const g=a.match(/^(.*)-transition$/);if(n==="paint"&&g&&h[g[1]]&&h[g[1]].transition)return r({key:t,value:s,valueSpec:o.transition,style:i,styleSpec:o});const C=e.valueSpec||h[a];if(!C)return[new Zn(t,s,`unknown property "${a}"`)];let B;if(jo(s)==="string"&&c3(C)&&!C.tokens&&(B=/^{([^}]+)}$/.exec(s)))return[new Zn(t,s,`"${a}" does not support interpolation syntax
Use an identity property function instead: \`{ "type": "identity", "property": ${JSON.stringify(B[1])} }\`.`)];const k=[];return e.layerType==="symbol"&&(a==="text-field"&&i&&!i.glyphs&&k.push(new Zn(t,s,'use of "text-field" requires a style "glyphs" property')),a==="text-font"&&jC(l1(s))&&al(s.type)==="identity"&&k.push(new Zn(t,s,'"text-font" does not support identity functions'))),k.concat(r({key:e.key,value:s,valueSpec:C,style:i,styleSpec:o,expressionContext:"property",propertyType:n,propertyKey:a}))}function ZU(e){return VU(e,"paint")}function XU(e){return VU(e,"layout")}function JU(e){let n=[];const t=e.value,r=e.key,i=e.style,o=e.styleSpec;!t.type&&!t.ref&&n.push(new Zn(r,t,'either "type" or "ref" is required'));let s=al(t.type);const a=al(t.ref);if(t.id){const h=al(t.id);for(let g=0;g<e.arrayIndex;g++){const C=i.layers[g];al(C.id)===h&&n.push(new Zn(r,t.id,`duplicate layer id "${t.id}", previously used at line ${C.id.__line__}`))}}if("ref"in t){["type","source","source-layer","filter","layout"].forEach(g=>{g in t&&n.push(new Zn(r,t[g],`"${g}" is prohibited for ref layers`))});let h;i.layers.forEach(g=>{al(g.id)===a&&(h=g)}),h?h.ref?n.push(new Zn(r,t.ref,"ref cannot reference another ref layer")):s=al(h.type):n.push(new Zn(r,t.ref,`ref layer "${a}" not found`))}else if(s!=="background")if(!t.source)n.push(new Zn(r,t,'missing required property "source"'));else{const h=i.sources&&i.sources[t.source],g=h&&al(h.type);h?g==="vector"&&s==="raster"?n.push(new Zn(r,t.source,`layer "${t.id}" requires a raster source`)):g!=="raster-dem"&&s==="hillshade"?n.push(new Zn(r,t.source,`layer "${t.id}" requires a raster-dem source`)):g==="raster"&&s!=="raster"?n.push(new Zn(r,t.source,`layer "${t.id}" requires a vector source`)):g==="vector"&&!t["source-layer"]?n.push(new Zn(r,t,`layer "${t.id}" must specify a "source-layer"`)):g==="raster-dem"&&s!=="hillshade"?n.push(new Zn(r,t.source,"raster-dem source can only be used with layer type 'hillshade'.")):s==="line"&&t.paint&&t.paint["line-gradient"]&&(g!=="geojson"||!h.lineMetrics)&&n.push(new Zn(r,t,`layer "${t.id}" specifies a line-gradient, which requires a GeoJSON source with \`lineMetrics\` enabled.`)):n.push(new Zn(r,t.source,`source "${t.source}" not found`))}return n=n.concat(gd({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:QB,layout(h){return gd({layer:t,key:h.key,value:h.value,style:h.style,styleSpec:h.styleSpec,validateSpec:h.validateSpec,objectElementValidators:{"*"(g){return XU(My({layerType:s},g))}}})},paint(h){return gd({layer:t,key:h.key,value:h.value,style:h.style,styleSpec:h.styleSpec,validateSpec:h.validateSpec,objectElementValidators:{"*"(g){return ZU(My({layerType:s},g))}}})}}})),n}function u1(e){const n=e.value,t=e.key,r=jo(n);return r!=="string"?[new Zn(t,n,`string expected, ${r} found`)]:[]}function YX(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 h=jo(r);if(r===void 0)return a;if(h!=="object")return a.push(new Zn("source_raster_dem",r,`object expected, ${h} found`)),a;const C=al(r.encoding)==="custom",B=["redFactor","greenFactor","blueFactor","baseShift"],k=e.value.encoding?`"${e.value.encoding}"`:"Default";for(const P in r)!C&&B.includes(P)?a.push(new Zn(P,r[P],`In "${t}": "${P}" is only valid when "encoding" is set to "custom". ${k} 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 Zn(P,r[P],`unknown property "${P}"`));return a}const a9={promoteId:qX};function eR(e){const n=e.value,t=e.key,r=e.styleSpec,i=e.style,o=e.validateSpec;if(!n.type)return[new Zn(t,n,'"type" is required')];const s=al(n.type);let a;switch(s){case"vector":case"raster":return a=gd({key:t,value:n,valueSpec:r[`source_${s.replace("-","_")}`],style:e.style,styleSpec:r,objectElementValidators:a9,validateSpec:o}),a;case"raster-dem":return a=YX({sourceName:t,value:n,style:e.style,styleSpec:r,validateSpec:o}),a;case"geojson":if(a=gd({key:t,value:n,valueSpec:r.source_geojson,style:i,styleSpec:r,validateSpec:o,objectElementValidators:a9}),n.cluster)for(const h in n.clusterProperties){const[g,C]=n.clusterProperties[h],B=typeof g=="string"?[g,["accumulated"],["get",h]]:g;a.push(...Sy({key:`${t}.${h}.map`,value:C,validateSpec:o,expressionContext:"cluster-map"})),a.push(...Sy({key:`${t}.${h}.reduce`,value:B,validateSpec:o,expressionContext:"cluster-reduce"}))}return a;case"video":return gd({key:t,value:n,valueSpec:r.source_video,style:i,validateSpec:o,styleSpec:r});case"image":return gd({key:t,value:n,valueSpec:r.source_image,style:i,validateSpec:o,styleSpec:r});case"canvas":return[new Zn(t,null,"Please use runtime APIs to add canvas sources, rather than including them in stylesheets.","source.canvas")];default:return aC({key:`${t}.type`,value:n.type,valueSpec:{values:["vector","raster","raster-dem","geojson","video","image"]},style:i,validateSpec:o,styleSpec:r})}}function qX({key:e,value:n}){if(jo(n)==="string")return u1({key:e,value:n});{const t=[];for(const r in n)t.push(...u1({key:`${e}.${r}`,value:n[r]}));return t}}function tR(e){const n=e.value,t=e.styleSpec,r=t.light,i=e.style;let o=[];const s=jo(n);if(n===void 0)return o;if(s!=="object")return o=o.concat([new Zn("light",n,`object expected, ${s} found`)]),o;for(const a in n){const h=a.match(/^(.*)-transition$/);h&&r[h[1]]&&r[h[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 Zn(a,n[a],`unknown property "${a}"`)])}return o}function nR(e){const n=e.value,t=e.styleSpec,r=t.sky,i=e.style,o=jo(n);if(n===void 0)return[];if(o!=="object")return[new Zn("sky",n,`object expected, ${o} found`)];let s=[];for(const a in n)r[a]?s=s.concat(ry({key:a,value:n[a],valueSpec:r[a],style:i,styleSpec:t})):s=s.concat([new Zn(a,n[a],`unknown property "${a}"`)]);return s}function rR(e){const n=e.value,t=e.styleSpec,r=t.terrain,i=e.style;let o=[];const s=jo(n);if(n===void 0)return o;if(s!=="object")return o=o.concat([new Zn("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 Zn(a,n[a],`unknown property "${a}"`)]);return o}function HX(e){return u1(e).length===0?[]:Sy(e)}function VX(e){return u1(e).length===0?[]:Sy(e)}function ZX(e){const n=e.key,t=e.value;if(jo(t)==="array"){if(t.length<1||t.length>4)return[new Zn(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 GB({key:n,value:t,valueSpec:{}})}function XX(e){const n=e.key,t=e.value,r=jo(t),i=e.styleSpec;if(r!=="array"||t.length<1||t.length%2!==0)return[new Zn(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(aC({key:`${n}[${s}]`,value:t[s],valueSpec:i.layout_symbol["text-anchor"]})),o=o.concat(NB({key:`${n}[${s+1}]`,value:t[s+1],valueSpec:{length:2,value:"number"},validateSpec:e.validateSpec,style:e.style,styleSpec:i}));return o}function iR(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 Zn(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 Zn(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(gd({key:`${r}[${s}]`,value:t[s],valueSpec:a,validateSpec:e.validateSpec}))}return n}else return u1({key:r,value:t})}const s9={"*"(){return[]},array:NB,boolean:QX,number:GB,color:$X,constants:YU,enum:aC,filter:QB,function:qU,layer:JU,object:gd,source:eR,light:tR,sky:nR,terrain:rR,string:u1,formatted:HX,resolvedImage:VX,padding:ZX,variableAnchorOffsetCollection:XX,sprite:iR};function ry(e){const n=e.value,t=e.valueSpec,r=e.styleSpec;return e.validateSpec=ry,t.expression&&jC(al(n))?qU(e):t.expression&&NC(l1(n))?Sy(e):t.type&&s9[t.type]?s9[t.type](e):gd(My({},e,{valueSpec:t.type?r[t.type]:t}))}function oR(e){const n=e.value,t=e.key,r=u1(e);return r.length||(n.indexOf("{fontstack}")===-1&&r.push(new Zn(t,n,'"glyphs" url must include a "{fontstack}" token')),n.indexOf("{range}")===-1&&r.push(new Zn(t,n,'"glyphs" url must include a "{range}" token'))),r}function Sd(e,n=Ea){let t=[];return t=t.concat(ry({key:"",value:e,valueSpec:n.$root,styleSpec:n,style:e,validateSpec:ry,objectElementValidators:{glyphs:oR,"*"(){return[]}}})),e.constants&&(t=t.concat(YU({key:"constants",value:e.constants,style:e,styleSpec:n,validateSpec:ry}))),aR(t)}Sd.source=Ef(Sf(eR));Sd.sprite=Ef(Sf(iR));Sd.glyphs=Ef(Sf(oR));Sd.light=Ef(Sf(tR));Sd.sky=Ef(Sf(nR));Sd.terrain=Ef(Sf(rR));Sd.layer=Ef(Sf(JU));Sd.filter=Ef(Sf(QB));Sd.paintProperty=Ef(Sf(ZU));Sd.layoutProperty=Ef(Sf(XU));function Sf(e){return function(n){return e({...n,validateSpec:ry})}}function aR(e){return[].concat(e).sort((n,t)=>n.line-t.line)}function Ef(e){return function(...n){return aR(e.apply(this,n))}}const JX=/("(?:[^\\"]|\\.)*")|[:,]/g;function eJ(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,h){s&&typeof s.toJSON=="function"&&(s=s.toJSON());const g=JSON.stringify(s,i);if(g===void 0)return g;const C=r-a.length-h;if(g.length<=C){const B=g.replace(JX,(k,P)=>P||`${k} `);if(B.length<=C)return B}if(i!=null&&(s=JSON.parse(g),i=void 0),typeof s=="object"&&s!==null){const B=a+t,k=[];let P=0,L,J;if(Array.isArray(s)){L="[",J="]";const{length:N}=s;for(;P<N;P++)k.push(o(s[P],B,P===N-1?0:1)||"null")}else{L="{",J="}";const N=Object.keys(s),{length:$}=N;for(;P<$;P++){const q=N[P],oe=`${JSON.stringify(q)}: `,ce=o(s[q],B,oe.length+(P===$-1?0:1));ce!==void 0&&k.push(oe+ce)}}if(k.length>0)return[L,t+k.join(`,
${B}`),J].join(`
${a}`)}return g}(e,"",0)}function l9(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 sR(e,n=2){return e=l9(e,Ea.$root),e.layers&&(e.layers=e.layers.map(t=>l9(t,Ea.layer))),eJ(e,{indent:n})}function uM(e,n){for(const t in e)t.indexOf("layout")===0&&n(e[t],t)}function u9(e,n){for(const t in e)t.indexOf("paint")===0&&n(e[t],t)}function P6(e,n){return typeof n=="string"&&n[0]==="@"?P6(e,e.constants[n]):n}function tJ(e){return Array.isArray(e.stops)}function Rv(e,n,t){e[t]=e[n],delete e[n]}function nJ(e){e.version=8,GX(e,i=>{i.type==="video"&&i.url!==void 0&&Rv(i,"url","urls"),i.type==="video"&&i.coordinates.forEach(o=>o.reverse())}),O_(e,i=>{uM(i,o=>{o["symbol-min-distance"]!==void 0&&Rv(o,"symbol-min-distance","symbol-spacing")}),u9(i,o=>{o["background-image"]!==void 0&&Rv(o,"background-image","background-pattern"),o["line-image"]!==void 0&&Rv(o,"line-image","line-pattern"),o["fill-image"]!==void 0&&Rv(o,"fill-image","fill-pattern")})}),WB(e,{paint:!0,layout:!0},i=>{const o=P6(e,i.value);tJ(o)&&o.stops.forEach(s=>{s[1]=P6(e,s[1])}),i.set(o)}),delete e.constants,O_(e,i=>{uM(i,o=>{delete o["text-max-size"],delete o["icon-max-size"]}),u9(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")}O_(e,i=>{uM(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 rJ(e){const n=[];return O_(e,t=>{t.filter&&(t.filter=E_(t.filter))}),WB(e,{paint:!0,layout:!0},({path:t,value:r,reference:i,set:o})=>{NC(r)||(typeof r=="object"&&!Array.isArray(r)?(o(QU(r,i)),n.push(t.join("."))):i.tokens&&typeof r=="string"&&o($U(r)))}),e}function iJ(e){return JSON.parse(oJ(JSON.stringify(e)))}function oJ(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(h=>h.endsWith("%")?h:`${parseFloat(h)*100}%`),`"hsl${typeof a=="string"?"a":""}(${[i,o,s,a].filter(Boolean).join(",")})"`}return n})}function aJ(e){let n=!1;if(e.version===7&&(e=nJ(e),n=!0),e.version===8&&(n=!!rJ(e),n=!0),WB(e,{paint:!0,layout:!0},({value:t,reference:r,set:i})=>{r.type==="color"&&i(iJ(t))}),!n)throw new Error(`Cannot migrate from ${e.version}`);return e}const sJ={StyleExpression:WU,StylePropertyFunction:NU,ZoomConstantExpression:I6,ZoomDependentExpression:T6,createExpression:LB,createPropertyExpression:UB,isExpression:NC,isExpressionFilter:i5,isZoomExpression:KX,normalizePropertyExpression:PX},lJ={convertFunction:QU,createFunction:DB,isFunction:jC};var lR={exports:{}};(function(e,n){(function(t,r){e.exports=r()})(ch,function(){var t={},r={};function i(s,a,h){if(r[s]=h,s==="index"){var g="var sharedModule = {}; ("+r.shared+")(sharedModule); ("+r.worker+")(sharedModule);",C={};return r.shared(C),r.index(t,C),typeof window<"u"&&t.setWorkerUrl(window.URL.createObjectURL(new Blob([g],{type:"text/javascript"}))),t}}i("shared",["exports"],function(s){function a(c,l,d,y){return new(d||(d=Promise))(function(w,T){function K(Z){try{j(y.next(Z))}catch(ne){T(ne)}}function D(Z){try{j(y.throw(Z))}catch(ne){T(ne)}}function j(Z){var ne;Z.done?w(Z.value):(ne=Z.value,ne instanceof d?ne:new d(function(Ae){Ae(ne)})).then(K,D)}j((y=y.apply(c,l||[])).next())})}function h(c){return c&&c.__esModule&&Object.prototype.hasOwnProperty.call(c,"default")?c.default:c}typeof SuppressedError=="function"&&SuppressedError;var g=C;function C(c,l){this.x=c,this.y=l}C.prototype={clone:function(){return new C(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}},C.convert=function(c){return c instanceof C?c:Array.isArray(c)?new C(c[0],c[1]):c};var B=h(g),k=P;function P(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}P.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 L=h(k);let J,N;function $(){return J==null&&(J=typeof OffscreenCanvas<"u"&&new OffscreenCanvas(1,1).getContext("2d")&&typeof createImageBitmap=="function"),J}function q(){if(N==null&&(N=!1,$())){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){N=!0;break}}}return N||!1}function oe(c,l,d,y){const w=new L(c,l,d,y);return function(T){return w.solve(T)}}const ce=oe(.25,.1,.25,1);function me(c,l,d){return Math.min(d,Math.max(l,c))}function he(c,l,d){const y=d-l,w=((c-l)%y+y)%y+l;return w===l?d:w}function V(c,...l){for(const d of l)for(const y in d)c[y]=d[y];return c}let ae=1;function ye(c,l,d){const y={};for(const w in c)y[w]=l.call(d||this,c[w],w,c);return y}function Oe(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 De(c){return Array.isArray(c)?c.map(De):typeof c=="object"&&c?ye(c,De):c}const He={};function ke(c){He[c]||(typeof console<"u"&&console.warn(c),He[c]=!0)}function nt(c,l,d){return(d.y-c.y)*(l.x-c.x)>(l.y-c.y)*(d.x-c.x)}function be(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 Bt(c){return typeof WorkerGlobalScope<"u"&&c!==void 0&&c instanceof WorkerGlobalScope}let kt=null;function Yt(c){return typeof ImageBitmap<"u"&&c instanceof ImageBitmap}const jt="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=";function Xe(c,l,d,y,w){return a(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"),j=new Uint8ClampedArray(y*w*4);if(yield T.copyTo(j,function(Z,ne,Ae,_e,Ee){const Ke=4*Math.max(-ne,0),We=(Math.max(0,Ae)-Ae)*_e*4+Ke,qe=4*_e,st=Math.max(0,ne),Ot=Math.max(0,Ae);return{rect:{x:st,y:Ot,width:Math.min(Z.width,ne+_e)-st,height:Math.min(Z.height,Ae+Ee)-Ot},layout:[{offset:We,stride:qe}]}}(c,l,d,y,w)),D)for(let Z=0;Z<j.length;Z+=4){const ne=j[Z];j[Z]=j[Z+2],j[Z+2]=ne}return j}finally{T.close()}})}let rt,ot;const on="AbortError";function gt(){return new Error(on)}const at={MAX_PARALLEL_IMAGE_REQUESTS:16,MAX_PARALLEL_IMAGE_REQUESTS_PER_FRAME:8,MAX_TILE_CACHE_ZOOM_LEVELS:5,REGISTERED_PROTOCOLS:{},WORKER_URL:""};function It(c){return at.REGISTERED_PROTOCOLS[c.substring(0,c.indexOf("://"))]}const Lt="global-dispatcher";class Me 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 fe=()=>Bt(self)?self.worker&&self.worker.referrer:(window.location.protocol==="blob:"?window.parent:window).location.href,xe=function(c,l){if(/:\/\//.test(c.url)&&!/^https?:|^file:/.test(c.url)){const y=It(c.url);if(y)return y(c,l);if(Bt(self)&&self.worker&&self.worker.actor)return self.worker.actor.sendAsync({type:"getResource",data:c,targetMapId:Lt},l)}if(!(/^file:/.test(d=c.url)||/^file:/.test(fe())&&!/^\w+:/.test(d))){if(fetch&&Request&&AbortController&&Object.prototype.hasOwnProperty.call(Request.prototype,"signal"))return function(y,w){return a(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:fe(),signal:w.signal});y.type==="json"&&T.headers.set("Accept","application/json");const K=yield fetch(T);if(!K.ok){const Z=yield K.blob();throw new Me(K.status,K.statusText,y.url,Z)}const D=y.type==="arrayBuffer"||y.type==="image"?K.arrayBuffer():y.type==="json"?K.json():K.text(),j=yield D;if(w.signal.aborted)throw gt();return{data:j,cacheControl:K.headers.get("Cache-Control"),expires:K.headers.get("Expires")}})}(c,l);if(Bt(self)&&self.worker&&self.worker.actor)return self.worker.actor.sendAsync({type:"getResource",data:c,mustQueue:!0,targetMapId:Lt},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 j in y.headers)D.setRequestHeader(j,y.headers[j]);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 j=D.response;if(y.type==="json")try{j=JSON.parse(D.response)}catch(Z){return void K(Z)}T({data:j,cacheControl:D.getResponseHeader("Cache-Control"),expires:D.getResponseHeader("Expires")})}else{const j=new Blob([D.response],{type:D.getResponseHeader("Content-Type")});K(new Me(D.status,D.statusText,y.url,j))}},w.signal.addEventListener("abort",()=>{D.abort(),K(gt())}),D.send(y.body)})}(c,l)};function Ue(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 et(c,l,d){d[c]&&d[c].indexOf(l)!==-1||(d[c]=d[c]||[],d[c].push(l))}function it(c,l,d){if(d&&d[c]){const y=d[c].indexOf(l);y!==-1&&d[c].splice(y,1)}}class bt{constructor(l,d={}){V(this,d),this.type=l}}class Ut extends bt{constructor(l,d={}){super("error",V({error:l},d))}}class Rt{on(l,d){return this._listeners=this._listeners||{},et(l,d,this._listeners),this}off(l,d){return it(l,d,this._listeners),it(l,d,this._oneTimeListeners),this}once(l,d){return d?(this._oneTimeListeners=this._oneTimeListeners||{},et(l,d,this._oneTimeListeners),this):new Promise(y=>this.once(l,y))}fire(l,d){typeof l=="string"&&(l=new bt(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)it(y,D,this._oneTimeListeners),D.call(this,l);const K=this._eventedParent;K&&(V(l,typeof this._eventedParentData=="function"?this._eventedParentData():this._eventedParentData),K.fire(l))}else l instanceof Ut&&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 pt={$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 rr=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function mn(c,l){const d={};for(const y in c)y!=="ref"&&(d[y]=c[y]);return rr.forEach(y=>{y in l&&(d[y]=l[y])}),d}function vn(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(!vn(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(!vn(c[d],l[d]))return!1;return!0}return c===l}function Xn(c,l){c.push(l)}function cr(c,l,d){Xn(d,{command:"addSource",args:[c,l[c]]})}function Mr(c,l,d){Xn(l,{command:"removeSource",args:[c]}),d[c]=!0}function Gr(c,l,d,y){Mr(c,d,y),cr(c,l,d)}function gr(c,l,d){let y;for(y in c[d])if(Object.prototype.hasOwnProperty.call(c[d],y)&&y!=="data"&&!vn(c[d][y],l[d][y]))return!1;for(y in l[d])if(Object.prototype.hasOwnProperty.call(l[d],y)&&y!=="data"&&!vn(c[d][y],l[d][y]))return!1;return!0}function mi(c,l,d,y,w,T){c=c||{},l=l||{};for(const K in c)Object.prototype.hasOwnProperty.call(c,K)&&(vn(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)&&(vn(c[K],l[K])||d.push({command:T,args:[y,K,l[K],w]}))}function Se(c){return c.id}function X(c,l){return c[l.id]=l,c}class H{constructor(l,d,y,w){this.message=(l?`${l}: `:"")+y,w&&(this.identifier=w),d!=null&&d.__line__&&(this.line=d.__line__)}}function Te(c,...l){for(const d of l)for(const y in d)c[y]=d[y];return c}class At extends Error{constructor(l,d){super(d),this.message=d,this.key=l}}class St{constructor(l,d=[]){this.parent=l,this.bindings={};for(const[y,w]of d)this.bindings[y]=w}concat(l){return new St(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 Et={kind:"null"},Nt={kind:"number"},pn={kind:"string"},Kn={kind:"boolean"},En={kind:"color"},m={kind:"object"},Kt={kind:"value"},Dr={kind:"collator"},Fn={kind:"formatted"},Fe={kind:"padding"},de={kind:"resolvedImage"},Ce={kind:"variableAnchorOffsetCollection"};function Be(c,l){return{kind:"array",itemType:c,N:l}}function ze(c){if(c.kind==="array"){const l=ze(c.itemType);return typeof c.N=="number"?`array<${l}, ${c.N}>`:c.itemType.kind==="value"?"array":`array<${l}>`}return c.kind}const tt=[Et,Nt,pn,Kn,En,Fn,m,Be(Kt),Fe,de,Ce];function lt(c,l){if(l.kind==="error")return null;if(c.kind==="array"){if(l.kind==="array"&&(l.N===0&&l.itemType.kind==="value"||!lt(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 tt)if(!lt(d,l))return null}}return`Expected ${ze(c)} but found ${ze(l)} instead.`}function ft(c,l){return l.some(d=>d.kind===c.kind)}function Ve(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 xt(c,l){return c.kind==="array"&&l.kind==="array"?c.itemType.kind===l.itemType.kind&&typeof c.N=="number":c.kind===l.kind}const Xt=.96422,Vt=.82521,Ht=4/29,Qn=6/29,Mn=3*Qn*Qn,or=Qn*Qn*Qn,ar=Math.PI/180,kr=180/Math.PI;function jr(c){return(c%=360)<0&&(c+=360),c}function Lr([c,l,d,y]){let w,T;const K=ir((.2225045*(c=Wr(c))+.7168786*(l=Wr(l))+.0606169*(d=Wr(d)))/1);c===l&&l===d?w=T=K:(w=ir((.4360747*c+.3850649*l+.1430804*d)/Xt),T=ir((.0139322*c+.0971045*l+.7141733*d)/Vt));const D=116*K-16;return[D<0?0:D,500*(w-K),200*(K-T),y]}function Wr(c){return c<=.04045?c/12.92:Math.pow((c+.055)/1.055,2.4)}function ir(c){return c>or?Math.pow(c,1/3):c/Mn+Ht}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*Yi(w),T=Xt*Yi(T),K=Vt*Yi(K),[Oi(3.1338561*T-1.6168667*w-.4906146*K),Oi(-.9787684*T+1.9161415*w+.033454*K),Oi(.0719453*T-.2289914*w+1.4052427*K),y]}function Oi(c){return(c=c<=.00304?12.92*c:1.055*Math.pow(c,1/2.4)-.055)<0?0:c>1?1:c}function Yi(c){return c>Qn?c*c*c:Mn*(c-Ht)}function _o(c){return parseInt(c.padEnd(2,c),16)/255}function Jr(c,l){return xo(l?c/100:c,0,1)}function xo(c,l,d){return Math.min(Math.max(l,c),d)}function Wa(c){return!c.some(Number.isNaN)}const Ba={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 bi{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 bi)return l;if(typeof l!="string")return;const d=function(y){if((y=y.toLowerCase().trim())==="transparent")return[0,0,0,0];const w=Ba[y];if(w){const[K,D,j]=w;return[K/255,D/255,j/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[_o(y.slice(D,D+=K)),_o(y.slice(D,D+=K)),_o(y.slice(D,D+=K)),_o(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,j,Z,ne,Ae,_e,Ee,Ke,We,qe,st,Ot]=K,ct=[ne||" ",Ee||" ",qe].join("");if(ct===" "||ct===" /"||ct===",,"||ct===",,,"){const _t=[Z,_e,We].join(""),nn=_t==="%%%"?100:_t===""?255:0;if(nn){const cn=[xo(+j/nn,0,1),xo(+Ae/nn,0,1),xo(+Ke/nn,0,1),st?Jr(+st,Ot):1];if(Wa(cn))return cn}}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,j,Z,ne,Ae,_e,Ee,Ke]=T,We=[j||" ",ne||" ",_e].join("");if(We===" "||We===" /"||We===",,"||We===",,,"){const qe=[+D,xo(+Z,0,100),xo(+Ae,0,100),Ee?Jr(+Ee,Ke):1];if(Wa(qe))return function([st,Ot,ct,_t]){function nn(cn){const Un=(cn+st/30)%12,Cr=Ot*Math.min(ct,1-ct);return ct-Cr*Math.max(-1,Math.min(Un-3,9-Un,1))}return st=jr(st),Ot/=100,ct/=100,[nn(0),nn(8),nn(4),_t]}(qe)}}}(l);return d?new bi(...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]=Lr(l),K=Math.sqrt(y*y+w*w);return[Math.round(1e4*K)?jr(Math.atan2(w,y)*kr):NaN,K,d,T]}(this.rgb))}get lab(){return this.overwriteGetter("lab",Lr(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})`}}bi.black=new bi(0,0,0,1),bi.white=new bi(1,1,1,1),bi.transparent=new bi(0,0,0,0),bi.red=new bi(1,0,0,1);class os{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 hi{constructor(l,d,y,w,T){this.text=l,this.image=d,this.scale=y,this.fontStack=w,this.textColor=T}}class Wn{constructor(l){this.sections=l}static fromString(l){return new Wn([new hi(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 Wn?l:Wn.fromString(l)}toString(){return this.sections.length===0?"":this.sections.map(l=>l.text).join("")}}class eo{constructor(l){this.values=l.slice()}static parse(l){if(l instanceof eo)return l;if(typeof l=="number")return new eo([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 eo(l)}}toString(){return JSON.stringify(this.values)}}const io=new Set(["center","left","right","top","bottom","top-left","top-right","bottom-left","bottom-right"]);class qi{constructor(l){this.values=l.slice()}static parse(l){if(l instanceof qi)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"||!io.has(y)||!Array.isArray(w)||w.length!==2||typeof w[0]!="number"||typeof w[1]!="number")return}return new qi(l)}}toString(){return JSON.stringify(this.values)}}class ve{constructor(l){this.name=l.name,this.available=l.available}toString(){return this.name}static fromString(l){return l?new ve({name:l,available:!1}):null}}function Ye(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 Jt(c){if(c===null||typeof c=="string"||typeof c=="boolean"||typeof c=="number"||c instanceof bi||c instanceof os||c instanceof Wn||c instanceof eo||c instanceof qi||c instanceof ve)return!0;if(Array.isArray(c)){for(const l of c)if(!Jt(l))return!1;return!0}if(typeof c=="object"){for(const l in c)if(!Jt(c[l]))return!1;return!0}return!1}function sn(c){if(c===null)return Et;if(typeof c=="string")return pn;if(typeof c=="boolean")return Kn;if(typeof c=="number")return Nt;if(c instanceof bi)return En;if(c instanceof os)return Dr;if(c instanceof Wn)return Fn;if(c instanceof eo)return Fe;if(c instanceof qi)return Ce;if(c instanceof ve)return de;if(Array.isArray(c)){const l=c.length;let d;for(const y of c){const w=sn(y);if(d){if(d===w)continue;d=Kt;break}d=w}return Be(d||Kt,l)}return m}function Ft(c){const l=typeof c;return c===null?"":l==="string"||l==="number"||l==="boolean"?String(c):c instanceof bi||c instanceof Wn||c instanceof eo||c instanceof qi||c instanceof ve?c.toString():JSON.stringify(c)}class Cn{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(!Jt(l[1]))return d.error("invalid value");const y=l[1];let w=sn(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 Cn(w,y)}evaluate(){return this.value}eachChild(){}outputDefined(){return!0}}class ur{constructor(l){this.name="ExpressionEvaluationError",this.message=l}toJSON(){return this.message}}const fi={string:pn,number:Nt,boolean:Kn,object:m};class ei{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,j;if(l.length>2){const Z=l[1];if(typeof Z!="string"||!(Z in fi)||Z==="object")return d.error('The item type argument of "array" must be one of string, number, boolean',1);D=fi[Z],w++}else D=Kt;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);j=l[2],w++}y=Be(D,j)}else{if(!fi[T])throw new Error(`Types doesn't contain name = ${T}`);y=fi[T]}const K=[];for(;w<l.length;w++){const D=d.parse(l[w],w,Kt);if(!D)return null;K.push(D)}return new ei(y,K)}evaluate(l){for(let d=0;d<this.args.length;d++){const y=this.args[d].evaluate(l);if(!lt(this.type,sn(y)))return y;if(d===this.args.length-1)throw new ur(`Expected value to be of type ${ze(this.type)}, but found ${ze(sn(y))} instead.`)}throw new Error}eachChild(l){this.args.forEach(l)}outputDefined(){return this.args.every(l=>l.outputDefined())}}const Zo={"to-boolean":Kn,"to-color":En,"to-number":Nt,"to-string":pn};class Fa{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(!Zo[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=Zo[y],T=[];for(let K=1;K<l.length;K++){const D=d.parse(l[K],K,Kt);if(!D)return null;T.push(D)}return new Fa(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 bi)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.`:Ye(d[0],d[1],d[2],d[3]),!y))return new bi(d[0]/255,d[1]/255,d[2]/255,d[3])}throw new ur(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=eo.parse(d);if(w)return w}throw new ur(`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=qi.parse(d);if(w)return w}throw new ur(`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 ur(`Could not convert ${JSON.stringify(d)} to number.`)}case"formatted":return Wn.fromString(Ft(this.args[0].evaluate(l)));case"resolvedImage":return ve.fromString(Ft(this.args[0].evaluate(l)));default:return Ft(this.args[0].evaluate(l))}}eachChild(l){this.args.forEach(l)}outputDefined(){return this.args.every(l=>l.outputDefined())}}const Or=["Unknown","Point","LineString","Polygon"];class gi{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"?Or[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]=bi.parse(l)),d}}class Ks{constructor(l,d,y=[],w,T=new St,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 ei(T,[w]):K==="coerce"?new Fa(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,j=K.type;if(D.kind!=="string"&&D.kind!=="number"&&D.kind!=="boolean"&&D.kind!=="object"&&D.kind!=="array"||j.kind!=="value")if(D.kind!=="color"&&D.kind!=="formatted"&&D.kind!=="resolvedImage"||j.kind!=="value"&&j.kind!=="string")if(D.kind!=="padding"||j.kind!=="value"&&j.kind!=="number"&&j.kind!=="array")if(D.kind!=="variableAnchorOffsetCollection"||j.kind!=="value"&&j.kind!=="array"){if(this.checkSubtype(D,j))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 Cn)&&K.type.kind!=="resolvedImage"&&this._isConstant(K)){const D=new gi;try{K=new Cn(K.type,K.evaluate(D))}catch(j){return this.error(j.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 Ks(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 At(y,l))}checkSubtype(l,d){const y=lt(l,d);return y&&this.error(y),y}}class ka{constructor(l,d,y){this.type=Dr,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,Kn);if(!w)return null;const T=d.parse(y["diacritic-sensitive"]!==void 0&&y["diacritic-sensitive"],1,Kn);if(!T)return null;let K=null;return y.locale&&(K=d.parse(y.locale,1,pn),!K)?null:new ka(w,T,K)}evaluate(l){return new os(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 pa=8192;function Zl(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 as(c,l){return!(c[0]<=l[0]||c[2]>=l[2]||c[1]<=l[1]||c[3]>=l[3])}function ia(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*pa),Math.round(y*w*pa)]}function qo(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 vs(c,l){let d=!1;for(let K=0,D=l.length;K<D;K++){const j=l[K];for(let Z=0,ne=j.length;Z<ne-1;Z++){if(qo(c,j[Z],j[Z+1]))return!1;(w=j[Z])[1]>(y=c)[1]!=(T=j[Z+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 Fu(c,l){for(let d=0;d<l.length;d++)if(vs(c,l[d]))return!0;return!1}function ma(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 lA(c,l,d){for(const Z of d)for(let ne=0;ne<Z.length-1;++ne)if((D=[(K=Z[ne+1])[0]-(T=Z[ne])[0],K[1]-T[1]])[0]*(j=[(w=l)[0]-(y=c)[0],w[1]-y[1]])[1]-D[1]*j[0]!=0&&ma(y,w,T,K)&&ma(T,K,y,w))return!0;var y,w,T,K,D,j;return!1}function Du(c,l){for(let d=0;d<c.length;++d)if(!vs(c[d],l))return!1;for(let d=0;d<c.length-1;++d)if(lA(c[d],c[d+1],l))return!1;return!0}function Lu(c,l){for(let d=0;d<l.length;d++)if(Du(c,l[d]))return!0;return!1}function mu(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=ia(c[w][K],d);Zl(l,D),T.push(D)}y.push(T)}return y}function uA(c,l,d){const y=[];for(let w=0;w<c.length;w++){const T=mu(c[w],l,d);y.push(T)}return y}function Wo(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}Zl(l,c)}function Na(c,l,d,y){const w=Math.pow(2,y.z)*pa,T=[y.x*pa,y.y*pa],K=[];for(const D of c)for(const j of D){const Z=[j.x+T[0],j.y+T[1]];Wo(Z,l,d,w),K.push(Z)}return K}function Uu(c,l,d,y){const w=Math.pow(2,y.z)*pa,T=[y.x*pa,y.y*pa],K=[];for(const j of c){const Z=[];for(const ne of j){const Ae=[ne.x+T[0],ne.y+T[1]];Zl(l,Ae),Z.push(Ae)}K.push(Z)}if(l[2]-l[0]<=w/2){(D=l)[0]=D[1]=1/0,D[2]=D[3]=-1/0;for(const j of K)for(const Z of j)Wo(Z,l,d,w)}var D;return K}class ss{constructor(l,d){this.type=Kn,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(Jt(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 ss(y,{type:"MultiPolygon",coordinates:w})}else if(y.type==="Feature"){const w=y.geometry.type;if(w==="Polygon"||w==="MultiPolygon")return new ss(y,y.geometry)}else if(y.type==="Polygon"||y.type==="MultiPolygon")return new ss(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=mu(y.coordinates,T,K),j=Na(d.geometry(),w,T,K);if(!as(w,T))return!1;for(const Z of j)if(!vs(Z,D))return!1}if(y.type==="MultiPolygon"){const D=uA(y.coordinates,T,K),j=Na(d.geometry(),w,T,K);if(!as(w,T))return!1;for(const Z of j)if(!Fu(Z,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=mu(y.coordinates,T,K),j=Uu(d.geometry(),w,T,K);if(!as(w,T))return!1;for(const Z of j)if(!Du(Z,D))return!1}if(y.type==="MultiPolygon"){const D=uA(y.coordinates,T,K),j=Uu(d.geometry(),w,T,K);if(!as(w,T))return!1;for(const Z of j)if(!Lu(Z,D))return!1}return!0}(l,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}}class ll{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 ll(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 Do{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=Do.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(([Z])=>!Array.isArray(Z)||Z.length===l.length-1);let j=null;for(const[Z,ne]of D){j=new Ks(d.registry,gu,d.path,null,d.scope);const Ae=[];let _e=!1;for(let Ee=1;Ee<l.length;Ee++){const Ke=l[Ee],We=Array.isArray(Z)?Z[Ee-1]:Z.type,qe=j.parse(Ke,1+Ae.length,We);if(!qe){_e=!0;break}Ae.push(qe)}if(!_e)if(Array.isArray(Z)&&Z.length!==Ae.length)j.error(`Expected ${Z.length} arguments, but found ${Ae.length} instead.`);else{for(let Ee=0;Ee<Ae.length;Ee++){const Ke=Array.isArray(Z)?Z[Ee]:Z.type,We=Ae[Ee];j.concat(Ee+1).checkSubtype(Ke,We.type)}if(j.errors.length===0)return new Do(y,T,ne,Ae)}}if(D.length===1)d.errors.push(...j.errors);else{const Z=(D.length?D:K).map(([Ae])=>{return _e=Ae,Array.isArray(_e)?`(${_e.map(ze).join(", ")})`:`(${ze(_e.type)}...)`;var _e}).join(" | "),ne=[];for(let Ae=1;Ae<l.length;Ae++){const _e=d.parse(l[Ae],1+ne.length);if(!_e)return null;ne.push(ze(_e.type))}d.error(`Expected arguments of type ${Z}, but found (${ne.join(", ")}) instead.`)}return null}static register(l,d){Do.definitions=d;for(const y in d)l[y]=Do}}function gu(c){if(c instanceof ll)return gu(c.boundExpression);if(c instanceof Do&&c.name==="error"||c instanceof ka||c instanceof ss)return!1;const l=c instanceof Fa||c instanceof ei;let d=!0;return c.eachChild(y=>{d=l?d&&gu(y):d&&y instanceof Cn}),!!d&&vl(c)&&Dl(c,["zoom","heatmap-density","line-progress","accumulated","is-supported-script"])}function vl(c){if(c instanceof Do&&(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 ss)return!1;let l=!0;return c.eachChild(d=>{l&&!vl(d)&&(l=!1)}),l}function _l(c){if(c instanceof Do&&c.name==="feature-state")return!1;let l=!0;return c.eachChild(d=>{l&&!_l(d)&&(l=!1)}),l}function Dl(c,l){if(c instanceof Do&&l.indexOf(c.name)>=0)return!1;let d=!0;return c.eachChild(y=>{d&&!Dl(y,l)&&(d=!1)}),d}function oa(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 ur("Input is not a number.");K=D-1}return 0}class Cl{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,Nt);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],j=l[K+1],Z=K,ne=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.',Z);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.',Z);const Ae=d.parse(j,ne,T);if(!Ae)return null;T=T||Ae.type,w.push([D,Ae])}return new Cl(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[oa(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 AA(c){return c&&c.__esModule&&Object.prototype.hasOwnProperty.call(c,"default")?c.default:c}var go=oo;function oo(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}oo.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 R=AA(go);function se(c,l,d){return c+d*(l-c)}function Le(c,l,d){return c.map((y,w)=>se(y,l[w],d))}const mt={number:se,color:function(c,l,d,y="rgb"){switch(y){case"rgb":{const[w,T,K,D]=Le(c.rgb,l.rgb,d);return new bi(w,T,K,D,!1)}case"hcl":{const[w,T,K,D]=c.hcl,[j,Z,ne,Ae]=l.hcl;let _e,Ee;if(isNaN(w)||isNaN(j))isNaN(w)?isNaN(j)?_e=NaN:(_e=j,K!==1&&K!==0||(Ee=Z)):(_e=w,ne!==1&&ne!==0||(Ee=T));else{let Ot=j-w;j>w&&Ot>180?Ot-=360:j<w&&w-j>180&&(Ot+=360),_e=w+d*Ot}const[Ke,We,qe,st]=function([Ot,ct,_t,nn]){return Ot=isNaN(Ot)?0:Ot*ar,ui([_t,Math.cos(Ot)*ct,Math.sin(Ot)*ct,nn])}([_e,Ee??se(T,Z,d),se(K,ne,d),se(D,Ae,d)]);return new bi(Ke,We,qe,st,!1)}case"lab":{const[w,T,K,D]=ui(Le(c.lab,l.lab,d));return new bi(w,T,K,D,!1)}}},array:Le,padding:function(c,l,d){return new eo(Le(c.values,l.values,d))},variableAnchorOffsetCollection:function(c,l,d){const y=c.values,w=l.values;if(y.length!==w.length)throw new ur(`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 ur(`Cannot interpolate values containing mismatched anchors. from[${K}]: ${y[K]}, to[${K}]: ${w[K]}`);T.push(y[K]);const[D,j]=y[K+1],[Z,ne]=w[K+1];T.push([se(D,Z,d),se(j,ne,d)])}return new qi(T)}};class Dn{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=en(d,l.base,y,w);else if(l.name==="linear")T=en(d,1,y,w);else if(l.name==="cubic-bezier"){const K=l.controlPoints;T=new R(K[0],K[1],K[2],K[3]).solve(en(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 Z=w[1];if(typeof Z!="number")return d.error("Exponential interpolation requires a numeric base.",1,1);w={name:"exponential",base:Z}}else{if(w[0]!=="cubic-bezier")return d.error(`Unknown interpolation type ${String(w[0])}`,1,0);{const Z=w.slice(1);if(Z.length!==4||Z.some(ne=>typeof ne!="number"||ne<0||ne>1))return d.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);w={name:"cubic-bezier",controlPoints:Z}}}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,Nt),!T)return null;const D=[];let j=null;y==="interpolate-hcl"||y==="interpolate-lab"?j=En:d.expectedType&&d.expectedType.kind!=="value"&&(j=d.expectedType);for(let Z=0;Z<K.length;Z+=2){const ne=K[Z],Ae=K[Z+1],_e=Z+3,Ee=Z+4;if(typeof ne!="number")return d.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',_e);if(D.length&&D[D.length-1][0]>=ne)return d.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',_e);const Ke=d.parse(Ae,Ee,j);if(!Ke)return null;j=j||Ke.type,D.push([ne,Ke])}return xt(j,Nt)||xt(j,En)||xt(j,Fe)||xt(j,Ce)||xt(j,Be(Nt))?new Dn(j,y,w,T,D):d.error(`Type ${ze(j)} 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=oa(d,w),D=Dn.interpolationFactor(this.interpolation,w,d[K],d[K+1]),j=y[K].evaluate(l),Z=y[K+1].evaluate(l);switch(this.operator){case"interpolate":return mt[this.type.kind](j,Z,D);case"interpolate-hcl":return mt.color(j,Z,D,"hcl");case"interpolate-lab":return mt.color(j,Z,D,"lab")}}eachChild(l){l(this.input);for(const d of this.outputs)l(d)}outputDefined(){return this.outputs.every(l=>l.outputDefined())}}function en(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 Sr{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 j=d.parse(D,1+T.length,y,void 0,{typeAnnotation:"omit"});if(!j)return null;y=y||j.type,T.push(j)}if(!y)throw new Error("No output type");const K=w&&T.some(D=>lt(w,D.type));return new Sr(K?Kt: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 ve&&!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 Ur{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 Ur(y,w):null}outputDefined(){return this.result.outputDefined()}}class yr{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,Nt),w=d.parse(l[2],2,Be(d.expectedType||Kt));return y&&w?new yr(w.type.itemType,y,w):null}evaluate(l){const d=this.index.evaluate(l),y=this.input.evaluate(l);if(d<0)throw new ur(`Array index out of bounds: ${d} < 0.`);if(d>=y.length)throw new ur(`Array index out of bounds: ${d} > ${y.length-1}.`);if(d!==Math.floor(d))throw new ur(`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 Ir{constructor(l,d){this.type=Kn,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,Kt),w=d.parse(l[2],2,Kt);return y&&w?ft(y.type,[Kn,pn,Nt,Et,Kt])?new Ir(y,w):d.error(`Expected first argument to be of type boolean, string, number or null, but found ${ze(y.type)} instead`):null}evaluate(l){const d=this.needle.evaluate(l),y=this.haystack.evaluate(l);if(!y)return!1;if(!Ve(d,["boolean","string","number","null"]))throw new ur(`Expected first argument to be of type boolean, string, number or null, but found ${ze(sn(d))} instead.`);if(!Ve(y,["string","array"]))throw new ur(`Expected second argument to be of type array or string, but found ${ze(sn(y))} instead.`);return y.indexOf(d)>=0}eachChild(l){l(this.needle),l(this.haystack)}outputDefined(){return!0}}class Bi{constructor(l,d,y){this.type=Nt,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,Kt),w=d.parse(l[2],2,Kt);if(!y||!w)return null;if(!ft(y.type,[Kn,pn,Nt,Et,Kt]))return d.error(`Expected first argument to be of type boolean, string, number or null, but found ${ze(y.type)} instead`);if(l.length===4){const T=d.parse(l[3],3,Nt);return T?new Bi(y,w,T):null}return new Bi(y,w)}evaluate(l){const d=this.needle.evaluate(l),y=this.haystack.evaluate(l);if(!Ve(d,["boolean","string","number","null"]))throw new ur(`Expected first argument to be of type boolean, string, number or null, but found ${ze(sn(d))} instead.`);if(!Ve(y,["string","array"]))throw new ur(`Expected second argument to be of type array or string, but found ${ze(sn(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 fo{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 Z=2;Z<l.length-1;Z+=2){let ne=l[Z];const Ae=l[Z+1];Array.isArray(ne)||(ne=[ne]);const _e=d.concat(Z);if(ne.length===0)return _e.error("Expected at least one branch label.");for(const Ke of ne){if(typeof Ke!="number"&&typeof Ke!="string")return _e.error("Branch labels must be numbers or strings.");if(typeof Ke=="number"&&Math.abs(Ke)>Number.MAX_SAFE_INTEGER)return _e.error(`Branch labels must be integers no larger than ${Number.MAX_SAFE_INTEGER}.`);if(typeof Ke=="number"&&Math.floor(Ke)!==Ke)return _e.error("Numeric branch labels must be integer values.");if(y){if(_e.checkSubtype(y,sn(Ke)))return null}else y=sn(Ke);if(T[String(Ke)]!==void 0)return _e.error("Branch labels must be unique.");T[String(Ke)]=K.length}const Ee=d.parse(Ae,Z,w);if(!Ee)return null;w=w||Ee.type,K.push(Ee)}const D=d.parse(l[1],1,Kt);if(!D)return null;const j=d.parse(l[l.length-1],l.length-1,w);return j?D.type.kind!=="value"&&d.concat(1).checkSubtype(y,D.type)?null:new fo(y,w,D,T,K,j):null}evaluate(l){const d=this.input.evaluate(l);return(sn(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 xi{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,Kn);if(!D)return null;const j=d.parse(l[K+1],K+1,y);if(!j)return null;w.push([D,j]),y=y||j.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 xi(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 Hr{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,Kt),w=d.parse(l[2],2,Nt);if(!y||!w)return null;if(!ft(y.type,[Be(Kt),pn,Kt]))return d.error(`Expected first argument to be of type array or string, but found ${ze(y.type)} instead`);if(l.length===4){const T=d.parse(l[3],3,Nt);return T?new Hr(y.type,y,w,T):null}return new Hr(y.type,y,w)}evaluate(l){const d=this.input.evaluate(l),y=this.beginIndex.evaluate(l);if(!Ve(d,["string","array"]))throw new ur(`Expected first argument to be of type array or string, but found ${ze(sn(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 Hi(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 Io(c,l,d,y){return y.compare(l,d)===0}function wo(c,l,d){const y=c!=="=="&&c!=="!=";return class uR{constructor(T,K,D){this.type=Kn,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 j=K.parse(T[1],1,Kt);if(!j)return null;if(!Hi(D,j.type))return K.concat(1).error(`"${D}" comparisons are not supported for type '${ze(j.type)}'.`);let Z=K.parse(T[2],2,Kt);if(!Z)return null;if(!Hi(D,Z.type))return K.concat(2).error(`"${D}" comparisons are not supported for type '${ze(Z.type)}'.`);if(j.type.kind!==Z.type.kind&&j.type.kind!=="value"&&Z.type.kind!=="value")return K.error(`Cannot compare types '${ze(j.type)}' and '${ze(Z.type)}'.`);y&&(j.type.kind==="value"&&Z.type.kind!=="value"?j=new ei(Z.type,[j]):j.type.kind!=="value"&&Z.type.kind==="value"&&(Z=new ei(j.type,[Z])));let ne=null;if(T.length===4){if(j.type.kind!=="string"&&Z.type.kind!=="string"&&j.type.kind!=="value"&&Z.type.kind!=="value")return K.error("Cannot use collator to compare non-string types.");if(ne=K.parse(T[3],3,Dr),!ne)return null}return new uR(j,Z,ne)}evaluate(T){const K=this.lhs.evaluate(T),D=this.rhs.evaluate(T);if(y&&this.hasUntypedArgument){const j=sn(K),Z=sn(D);if(j.kind!==Z.kind||j.kind!=="string"&&j.kind!=="number")throw new ur(`Expected arguments for "${c}" to be (string, string) or (number, number), but found (${j.kind}, ${Z.kind}) instead.`)}if(this.collator&&!y&&this.hasUntypedArgument){const j=sn(K),Z=sn(D);if(j.kind!=="string"||Z.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 Ga=wo("==",function(c,l,d){return l===d},Io),Ll=wo("!=",function(c,l,d){return l!==d},function(c,l,d,y){return!Io(0,l,d,y)}),Xl=wo("<",function(c,l,d){return l<d},function(c,l,d,y){return y.compare(l,d)<0}),ga=wo(">",function(c,l,d){return l>d},function(c,l,d,y){return y.compare(l,d)>0}),qm=wo("<=",function(c,l,d){return l<=d},function(c,l,d,y){return y.compare(l,d)<=0}),Jl=wo(">=",function(c,l,d){return l>=d},function(c,l,d,y){return y.compare(l,d)>=0});class mh{constructor(l,d,y,w,T){this.type=pn,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,Nt);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,pn),!T))return null;let K=null;if(w.currency&&(K=d.parse(w.currency,1,pn),!K))return null;let D=null;if(w["min-fraction-digits"]&&(D=d.parse(w["min-fraction-digits"],1,Nt),!D))return null;let j=null;return w["max-fraction-digits"]&&(j=d.parse(w["max-fraction-digits"],1,Nt),!j)?null:new mh(y,T,K,D,j)}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 Wc{constructor(l){this.type=Fn,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 j=null;if(D["font-scale"]&&(j=d.parse(D["font-scale"],1,Nt),!j))return null;let Z=null;if(D["text-font"]&&(Z=d.parse(D["text-font"],1,Be(pn)),!Z))return null;let ne=null;if(D["text-color"]&&(ne=d.parse(D["text-color"],1,En),!ne))return null;const Ae=w[w.length-1];Ae.scale=j,Ae.font=Z,Ae.textColor=ne}else{const j=d.parse(l[K],1,Kt);if(!j)return null;const Z=j.type.kind;if(Z!=="string"&&Z!=="value"&&Z!=="null"&&Z!=="resolvedImage")return d.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");T=!0,w.push({content:j,scale:null,font:null,textColor:null})}}return new Wc(w)}evaluate(l){return new Wn(this.sections.map(d=>{const y=d.content.evaluate(l);return sn(y)===de?new hi("",y,null,null,null):new hi(Ft(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 Ru{constructor(l){this.type=de,this.input=l}static parse(l,d){if(l.length!==2)return d.error("Expected two arguments.");const y=d.parse(l[1],1,pn);return y?new Ru(y):d.error("No image name provided.")}evaluate(l){const d=this.input.evaluate(l),y=ve.fromString(d);return y&&l.availableImages&&(y.available=l.availableImages.indexOf(d)>-1),y}eachChild(l){l(this.input)}outputDefined(){return!1}}class Nc{constructor(l){this.type=Nt,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 ${ze(y.type)} instead.`):new Nc(y):null}evaluate(l){const d=this.input.evaluate(l);if(typeof d=="string"||Array.isArray(d))return d.length;throw new ur(`Expected value to be of type string or array, but found ${ze(sn(d))} instead.`)}eachChild(l){l(this.input)}outputDefined(){return!1}}const IA={"==":Ga,"!=":Ll,">":ga,"<":Xl,">=":Jl,"<=":qm,array:ei,at:yr,boolean:ei,case:xi,coalesce:Sr,collator:ka,format:Wc,image:Ru,in:Ir,"index-of":Bi,interpolate:Dn,"interpolate-hcl":Dn,"interpolate-lab":Dn,length:Nc,let:Ur,literal:Cn,match:fo,number:ei,"number-format":mh,object:ei,slice:Hr,step:Cl,string:ei,"to-boolean":Fa,"to-color":Fa,"to-number":Fa,"to-string":Fa,var:ll,within:ss};function Xo(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=Ye(l,d,y,T);if(K)throw new ur(K);return new bi(l/255,d/255,y/255,T,!1)}function zu(c,l){return c in l}function Od(c,l){const d=l[c];return d===void 0?null:d}function TA(c){return{type:c}}function lc(c){return{result:"success",value:c}}function yu(c){return{result:"error",value:c}}function Gc(c){return c["property-type"]==="data-driven"||c["property-type"]==="cross-faded-data-driven"}function kp(c){return!!c.expression&&c.expression.parameters.indexOf("zoom")>-1}function gh(c){return!!c.expression&&c.expression.interpolated}function wi(c){return c instanceof Number?"number":c instanceof String?"string":c instanceof Boolean?"boolean":Array.isArray(c)?"array":c===null?"null":typeof c}function No(c){return typeof c=="object"&&c!==null&&!Array.isArray(c)}function Hm(c){return c}function yh(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||(gh(l)?"exponential":"interval");if(d||l.type==="padding"){const ne=d?bi.parse:eo.parse;(c=Te({},c)).stops&&(c.stops=c.stops.map(Ae=>[Ae[0],ne(Ae[1])])),c.default=ne(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,j,Z;if(T==="exponential")D=Li;else if(T==="interval")D=vh;else if(T==="categorical"){D=ya,j=Object.create(null);for(const ne of c.stops)j[ne[0]]=ne[1];Z=typeof c.stops[0][0]}else{if(T!=="identity")throw new Error(`Unknown function type "${T}"`);D=Bd}if(y){const ne={},Ae=[];for(let Ke=0;Ke<c.stops.length;Ke++){const We=c.stops[Ke],qe=We[0].zoom;ne[qe]===void 0&&(ne[qe]={zoom:qe,type:c.type,property:c.property,default:c.default,stops:[]},Ae.push(qe)),ne[qe].stops.push([We[0].value,We[1]])}const _e=[];for(const Ke of Ae)_e.push([ne[Ke].zoom,yh(ne[Ke],l)]);const Ee={name:"linear"};return{kind:"composite",interpolationType:Ee,interpolationFactor:Dn.interpolationFactor.bind(void 0,Ee),zoomStops:_e.map(Ke=>Ke[0]),evaluate:({zoom:Ke},We)=>Li({stops:_e,base:c.base},l,Ke).evaluate(Ke,We)}}if(w){const ne=T==="exponential"?{name:"exponential",base:c.base!==void 0?c.base:1}:null;return{kind:"camera",interpolationType:ne,interpolationFactor:Dn.interpolationFactor.bind(void 0,ne),zoomStops:c.stops.map(Ae=>Ae[0]),evaluate:({zoom:Ae})=>D(c,l,Ae,j,Z)}}return{kind:"source",evaluate(ne,Ae){const _e=Ae&&Ae.properties?Ae.properties[c.property]:void 0;return _e===void 0?ju(c.default,l.default):D(c,l,_e,j,Z)}}}function ju(c,l,d){return c!==void 0?c:l!==void 0?l:d!==void 0?d:void 0}function ya(c,l,d,y,w){return ju(typeof d===w?y[d]:void 0,c.default,l.default)}function vh(c,l,d){if(wi(d)!=="number")return ju(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=oa(c.stops.map(T=>T[0]),d);return c.stops[w][1]}function Li(c,l,d){const y=c.base!==void 0?c.base:1;if(wi(d)!=="number")return ju(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=oa(c.stops.map(ne=>ne[0]),d),K=function(ne,Ae,_e,Ee){const Ke=Ee-_e,We=ne-_e;return Ke===0?0:Ae===1?We/Ke:(Math.pow(Ae,We)-1)/(Math.pow(Ae,Ke)-1)}(d,y,c.stops[T][0],c.stops[T+1][0]),D=c.stops[T][1],j=c.stops[T+1][1],Z=mt[l.type]||Hm;return typeof D.evaluate=="function"?{evaluate(...ne){const Ae=D.evaluate.apply(void 0,ne),_e=j.evaluate.apply(void 0,ne);if(Ae!==void 0&&_e!==void 0)return Z(Ae,_e,K,c.colorSpace)}}:Z(D,j,K,c.colorSpace)}function Bd(c,l,d){switch(l.type){case"color":d=bi.parse(d);break;case"formatted":d=Wn.fromString(d.toString());break;case"resolvedImage":d=ve.fromString(d.toString());break;case"padding":d=eo.parse(d);break;default:wi(d)===l.type||l.type==="enum"&&l.values[d]||(d=void 0)}return ju(d,c.default,l.default)}Do.register(IA,{error:[{kind:"error"},[pn],(c,[l])=>{throw new ur(l.evaluate(c))}],typeof:[pn,[Kt],(c,[l])=>ze(sn(l.evaluate(c)))],"to-rgba":[Be(Nt,4),[En],(c,[l])=>{const[d,y,w,T]=l.evaluate(c).rgb;return[255*d,255*y,255*w,T]}],rgb:[En,[Nt,Nt,Nt],Xo],rgba:[En,[Nt,Nt,Nt,Nt],Xo],has:{type:Kn,overloads:[[[pn],(c,[l])=>zu(l.evaluate(c),c.properties())],[[pn,m],(c,[l,d])=>zu(l.evaluate(c),d.evaluate(c))]]},get:{type:Kt,overloads:[[[pn],(c,[l])=>Od(l.evaluate(c),c.properties())],[[pn,m],(c,[l,d])=>Od(l.evaluate(c),d.evaluate(c))]]},"feature-state":[Kt,[pn],(c,[l])=>Od(l.evaluate(c),c.featureState||{})],properties:[m,[],c=>c.properties()],"geometry-type":[pn,[],c=>c.geometryType()],id:[Kt,[],c=>c.id()],zoom:[Nt,[],c=>c.globals.zoom],"heatmap-density":[Nt,[],c=>c.globals.heatmapDensity||0],"line-progress":[Nt,[],c=>c.globals.lineProgress||0],accumulated:[Kt,[],c=>c.globals.accumulated===void 0?null:c.globals.accumulated],"+":[Nt,TA(Nt),(c,l)=>{let d=0;for(const y of l)d+=y.evaluate(c);return d}],"*":[Nt,TA(Nt),(c,l)=>{let d=1;for(const y of l)d*=y.evaluate(c);return d}],"-":{type:Nt,overloads:[[[Nt,Nt],(c,[l,d])=>l.evaluate(c)-d.evaluate(c)],[[Nt],(c,[l])=>-l.evaluate(c)]]},"/":[Nt,[Nt,Nt],(c,[l,d])=>l.evaluate(c)/d.evaluate(c)],"%":[Nt,[Nt,Nt],(c,[l,d])=>l.evaluate(c)%d.evaluate(c)],ln2:[Nt,[],()=>Math.LN2],pi:[Nt,[],()=>Math.PI],e:[Nt,[],()=>Math.E],"^":[Nt,[Nt,Nt],(c,[l,d])=>Math.pow(l.evaluate(c),d.evaluate(c))],sqrt:[Nt,[Nt],(c,[l])=>Math.sqrt(l.evaluate(c))],log10:[Nt,[Nt],(c,[l])=>Math.log(l.evaluate(c))/Math.LN10],ln:[Nt,[Nt],(c,[l])=>Math.log(l.evaluate(c))],log2:[Nt,[Nt],(c,[l])=>Math.log(l.evaluate(c))/Math.LN2],sin:[Nt,[Nt],(c,[l])=>Math.sin(l.evaluate(c))],cos:[Nt,[Nt],(c,[l])=>Math.cos(l.evaluate(c))],tan:[Nt,[Nt],(c,[l])=>Math.tan(l.evaluate(c))],asin:[Nt,[Nt],(c,[l])=>Math.asin(l.evaluate(c))],acos:[Nt,[Nt],(c,[l])=>Math.acos(l.evaluate(c))],atan:[Nt,[Nt],(c,[l])=>Math.atan(l.evaluate(c))],min:[Nt,TA(Nt),(c,l)=>Math.min(...l.map(d=>d.evaluate(c)))],max:[Nt,TA(Nt),(c,l)=>Math.max(...l.map(d=>d.evaluate(c)))],abs:[Nt,[Nt],(c,[l])=>Math.abs(l.evaluate(c))],round:[Nt,[Nt],(c,[l])=>{const d=l.evaluate(c);return d<0?-Math.round(-d):Math.round(d)}],floor:[Nt,[Nt],(c,[l])=>Math.floor(l.evaluate(c))],ceil:[Nt,[Nt],(c,[l])=>Math.ceil(l.evaluate(c))],"filter-==":[Kn,[pn,Kt],(c,[l,d])=>c.properties()[l.value]===d.value],"filter-id-==":[Kn,[Kt],(c,[l])=>c.id()===l.value],"filter-type-==":[Kn,[pn],(c,[l])=>c.geometryType()===l.value],"filter-<":[Kn,[pn,Kt],(c,[l,d])=>{const y=c.properties()[l.value],w=d.value;return typeof y==typeof w&&y<w}],"filter-id-<":[Kn,[Kt],(c,[l])=>{const d=c.id(),y=l.value;return typeof d==typeof y&&d<y}],"filter->":[Kn,[pn,Kt],(c,[l,d])=>{const y=c.properties()[l.value],w=d.value;return typeof y==typeof w&&y>w}],"filter-id->":[Kn,[Kt],(c,[l])=>{const d=c.id(),y=l.value;return typeof d==typeof y&&d>y}],"filter-<=":[Kn,[pn,Kt],(c,[l,d])=>{const y=c.properties()[l.value],w=d.value;return typeof y==typeof w&&y<=w}],"filter-id-<=":[Kn,[Kt],(c,[l])=>{const d=c.id(),y=l.value;return typeof d==typeof y&&d<=y}],"filter->=":[Kn,[pn,Kt],(c,[l,d])=>{const y=c.properties()[l.value],w=d.value;return typeof y==typeof w&&y>=w}],"filter-id->=":[Kn,[Kt],(c,[l])=>{const d=c.id(),y=l.value;return typeof d==typeof y&&d>=y}],"filter-has":[Kn,[Kt],(c,[l])=>l.value in c.properties()],"filter-has-id":[Kn,[],c=>c.id()!==null&&c.id()!==void 0],"filter-type-in":[Kn,[Be(pn)],(c,[l])=>l.value.indexOf(c.geometryType())>=0],"filter-id-in":[Kn,[Be(Kt)],(c,[l])=>l.value.indexOf(c.id())>=0],"filter-in-small":[Kn,[pn,Be(Kt)],(c,[l,d])=>d.value.indexOf(c.properties()[l.value])>=0],"filter-in-large":[Kn,[pn,Be(Kt)],(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:Kn,overloads:[[[Kn,Kn],(c,[l,d])=>l.evaluate(c)&&d.evaluate(c)],[TA(Kn),(c,l)=>{for(const d of l)if(!d.evaluate(c))return!1;return!0}]]},any:{type:Kn,overloads:[[[Kn,Kn],(c,[l,d])=>l.evaluate(c)||d.evaluate(c)],[TA(Kn),(c,l)=>{for(const d of l)if(d.evaluate(c))return!0;return!1}]]},"!":[Kn,[Kn],(c,[l])=>!l.evaluate(c)],"is-supported-script":[Kn,[pn],(c,[l])=>{const d=c.globals&&c.globals.isSupportedScript;return!d||d(l.evaluate(c))}],upcase:[pn,[pn],(c,[l])=>l.evaluate(c).toUpperCase()],downcase:[pn,[pn],(c,[l])=>l.evaluate(c).toLowerCase()],concat:[pn,TA(Kt),(c,l)=>l.map(d=>Ft(d.evaluate(c))).join("")],"resolved-locale":[pn,[Dr],(c,[l])=>l.evaluate(c).resolvedLocale()]});class To{constructor(l,d){var y;this.expression=l,this._warningHistory={},this._evaluator=new gi,this._defaultValue=d?(y=d).type==="color"&&No(y.default)?new bi(0,0,0,0):y.type==="color"?bi.parse(y.default)||null:y.type==="padding"?eo.parse(y.default)||null:y.type==="variableAnchorOffsetCollection"?qi.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 ur(`Expected value to be one of ${Object.keys(this._enumValues).map(j=>JSON.stringify(j)).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 Mo(c){return Array.isArray(c)&&c.length>0&&typeof c[0]=="string"&&c[0]in IA}function uc(c,l){const d=new Ks(IA,gu,[],l?function(w){const T={color:En,string:pn,number:Nt,enum:pn,boolean:Kn,formatted:Fn,padding:Fe,resolvedImage:de,variableAnchorOffsetCollection:Ce};return w.type==="array"?Be(T[w.value]||Kt,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?lc(new To(y,l)):yu(d.errors)}class Qc{constructor(l,d){this.kind=l,this._styleExpression=d,this.isStateDependent=l!=="constant"&&!_l(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 Hs{constructor(l,d,y,w){this.kind=l,this.zoomStops=y,this._styleExpression=d,this.isStateDependent=l!=="camera"&&!_l(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?Dn.interpolationFactor(this.interpolationType,l,d,y):0}}function _h(c,l){const d=uc(c,l);if(d.result==="error")return d;const y=d.value.expression,w=vl(y);if(!w&&!Gc(l))return yu([new At("","data expressions not supported")]);const T=Dl(y,["zoom"]);if(!T&&!kp(l))return yu([new At("","zoom expressions not supported")]);const K=Ul(y);return K||T?K instanceof At?yu([K]):K instanceof Dn&&!gh(l)?yu([new At("",'"interpolate" expressions cannot be used with this property')]):lc(K?new Hs(w?"camera":"composite",d.value,K.labels,K instanceof Dn?K.interpolation:void 0):new Qc(w?"constant":"source",d.value)):yu([new At("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')])}class eu{constructor(l,d){this._parameters=l,this._specification=d,Te(this,yh(this._parameters,this._specification))}static deserialize(l){return new eu(l._parameters,l._specification)}static serialize(l){return{_parameters:l._parameters,_specification:l._specification}}}function Ul(c){let l=null;if(c instanceof Ur)l=Ul(c.result);else if(c instanceof Sr){for(const d of c.args)if(l=Ul(d),l)break}else(c instanceof Cl||c instanceof Dn)&&c.input instanceof Do&&c.input.name==="zoom"&&(l=c);return l instanceof At||c.eachChild(d=>{const y=Ul(d);y instanceof At?l=y:!l&&y?l=new At("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):l&&y&&l!==y&&(l=new At("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),l}function KA(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(!KA(l)&&typeof l!="boolean")return!1;return!0;default:return!0}}const Ch={type:"boolean",default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}};function kd(c){if(c==null)return{filter:()=>!0,needGeometry:!1};KA(c)||(c=$c(c));const l=uc(c,Ch);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:Wu(c)}}function vu(c,l){return c<l?-1:c>l?1:0}function Wu(c){if(!Array.isArray(c))return!1;if(c[0]==="within")return!0;for(let l=1;l<c.length;l++)if(Wu(c[l]))return!0;return!1}function $c(c){if(!c)return!0;const l=c[0];return c.length<=1?l!=="any":l==="=="?PA(c[1],c[2],"=="):l==="!="?Ac(PA(c[1],c[2],"==")):l==="<"||l===">"||l==="<="||l===">="?PA(c[1],c[2],l):l==="any"?(d=c.slice(1),["any"].concat(d.map($c))):l==="all"?["all"].concat(c.slice(1).map($c)):l==="none"?["all"].concat(c.slice(1).map($c).map(Ac)):l==="in"?kf(c[1],c.slice(2)):l==="!in"?Ac(kf(c[1],c.slice(2))):l==="has"?Ip(c[1]):l==="!has"?Ac(Ip(c[1])):l!=="within"||c;var d}function PA(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 kf(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(vu)]]:["filter-in-small",c,["literal",l]]}}function Ip(c){switch(c){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",c]}}function Ac(c){return["!",c]}function Yc(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+=`${Yc(T)},`;return`${w}]`}const d=Object.keys(c).sort();let y="{";for(let w=0;w<d.length;w++)y+=`${JSON.stringify(d[w])}:${Yc(c[d[w]])},`;return`${y}}`}function Rl(c){let l="";for(const d of rr)l+=`/${Yc(c[d])}`;return l}function bl(c){const l=c.value;return l?[new H(c.key,l,"constants have been deprecated as of v8")]:[]}function aa(c){return c instanceof Number||c instanceof String||c instanceof Boolean?c.valueOf():c}function cA(c){if(Array.isArray(c))return c.map(cA);if(c instanceof Object&&!(c instanceof Number||c instanceof String||c instanceof Boolean)){const l={};for(const d in c)l[d]=cA(c[d]);return l}return aa(c)}function ul(c){const l=c.key,d=c.value,y=c.valueSpec||{},w=c.objectElementValidators||{},T=c.style,K=c.styleSpec,D=c.validateSpec;let j=[];const Z=wi(d);if(Z!=="object")return[new H(l,d,`object expected, ${Z} found`)];for(const ne in d){const Ae=ne.split(".")[0],_e=y[Ae]||y["*"];let Ee;if(w[Ae])Ee=w[Ae];else if(y[Ae])Ee=D;else if(w["*"])Ee=w["*"];else{if(!y["*"]){j.push(new H(l,d[ne],`unknown property "${ne}"`));continue}Ee=D}j=j.concat(Ee({key:(l&&`${l}.`)+ne,value:d[ne],valueSpec:_e,style:T,styleSpec:K,object:d,objectKey:ne,validateSpec:D},d))}for(const ne in y)w[ne]||y[ne].required&&y[ne].default===void 0&&d[ne]===void 0&&j.push(new H(l,d,`missing required property "${ne}"`));return j}function FA(c){const l=c.value,d=c.valueSpec,y=c.style,w=c.styleSpec,T=c.key,K=c.arrayElementValidator||c.validateSpec;if(wi(l)!=="array")return[new H(T,l,`array expected, ${wi(l)} found`)];if(d.length&&l.length!==d.length)return[new H(T,l,`array length ${d.length} expected, length ${l.length} found`)];if(d["min-length"]&&l.length<d["min-length"])return[new H(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),wi(d.value)==="object"&&(D=d.value);let j=[];for(let Z=0;Z<l.length;Z++)j=j.concat(K({array:l,arrayIndex:Z,value:l[Z],valueSpec:D,validateSpec:c.validateSpec,style:y,styleSpec:w,key:`${T}[${Z}]`}));return j}function xl(c){const l=c.key,d=c.value,y=c.valueSpec;let w=wi(d);return w==="number"&&d!=d&&(w="NaN"),w!=="number"?[new H(l,d,`number expected, ${w} found`)]:"minimum"in y&&d<y.minimum?[new H(l,d,`${d} is less than the minimum value ${y.minimum}`)]:"maximum"in y&&d>y.maximum?[new H(l,d,`${d} is greater than the maximum value ${y.maximum}`)]:[]}function bh(c){const l=c.valueSpec,d=aa(c.value.type);let y,w,T,K={};const D=d!=="categorical"&&c.value.property===void 0,j=!D,Z=wi(c.value.stops)==="array"&&wi(c.value.stops[0])==="array"&&wi(c.value.stops[0][0])==="object",ne=ul({key:c.key,value:c.value,valueSpec:c.styleSpec.function,validateSpec:c.validateSpec,style:c.style,styleSpec:c.styleSpec,objectElementValidators:{stops:function(Ee){if(d==="identity")return[new H(Ee.key,Ee.value,'identity function may not have a "stops" property')];let Ke=[];const We=Ee.value;return Ke=Ke.concat(FA({key:Ee.key,value:We,valueSpec:Ee.valueSpec,validateSpec:Ee.validateSpec,style:Ee.style,styleSpec:Ee.styleSpec,arrayElementValidator:Ae})),wi(We)==="array"&&We.length===0&&Ke.push(new H(Ee.key,We,"array must have at least one stop")),Ke},default:function(Ee){return Ee.validateSpec({key:Ee.key,value:Ee.value,valueSpec:l,validateSpec:Ee.validateSpec,style:Ee.style,styleSpec:Ee.styleSpec})}}});return d==="identity"&&D&&ne.push(new H(c.key,c.value,'missing required property "property"')),d==="identity"||c.value.stops||ne.push(new H(c.key,c.value,'missing required property "stops"')),d==="exponential"&&c.valueSpec.expression&&!gh(c.valueSpec)&&ne.push(new H(c.key,c.value,"exponential functions not supported")),c.styleSpec.$version>=8&&(j&&!Gc(c.valueSpec)?ne.push(new H(c.key,c.value,"property functions not supported")):D&&!kp(c.valueSpec)&&ne.push(new H(c.key,c.value,"zoom functions not supported"))),d!=="categorical"&&!Z||c.value.property!==void 0||ne.push(new H(c.key,c.value,'"property" property is required')),ne;function Ae(Ee){let Ke=[];const We=Ee.value,qe=Ee.key;if(wi(We)!=="array")return[new H(qe,We,`array expected, ${wi(We)} found`)];if(We.length!==2)return[new H(qe,We,`array length 2 expected, length ${We.length} found`)];if(Z){if(wi(We[0])!=="object")return[new H(qe,We,`object expected, ${wi(We[0])} found`)];if(We[0].zoom===void 0)return[new H(qe,We,"object stop key must have zoom")];if(We[0].value===void 0)return[new H(qe,We,"object stop key must have value")];if(T&&T>aa(We[0].zoom))return[new H(qe,We[0].zoom,"stop zoom values must appear in ascending order")];aa(We[0].zoom)!==T&&(T=aa(We[0].zoom),w=void 0,K={}),Ke=Ke.concat(ul({key:`${qe}[0]`,value:We[0],valueSpec:{zoom:{}},validateSpec:Ee.validateSpec,style:Ee.style,styleSpec:Ee.styleSpec,objectElementValidators:{zoom:xl,value:_e}}))}else Ke=Ke.concat(_e({key:`${qe}[0]`,value:We[0],valueSpec:{},validateSpec:Ee.validateSpec,style:Ee.style,styleSpec:Ee.styleSpec},We));return Mo(cA(We[1]))?Ke.concat([new H(`${qe}[1]`,We[1],"expressions are not allowed in function stops.")]):Ke.concat(Ee.validateSpec({key:`${qe}[1]`,value:We[1],valueSpec:l,validateSpec:Ee.validateSpec,style:Ee.style,styleSpec:Ee.styleSpec}))}function _e(Ee,Ke){const We=wi(Ee.value),qe=aa(Ee.value),st=Ee.value!==null?Ee.value:Ke;if(y){if(We!==y)return[new H(Ee.key,st,`${We} stop domain type must match previous stop domain type ${y}`)]}else y=We;if(We!=="number"&&We!=="string"&&We!=="boolean")return[new H(Ee.key,st,"stop domain value must be a number, string, or boolean")];if(We!=="number"&&d!=="categorical"){let Ot=`number expected, ${We} found`;return Gc(l)&&d===void 0&&(Ot+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new H(Ee.key,st,Ot)]}return d!=="categorical"||We!=="number"||isFinite(qe)&&Math.floor(qe)===qe?d!=="categorical"&&We==="number"&&w!==void 0&&qe<w?[new H(Ee.key,st,"stop domain values must appear in ascending order")]:(w=qe,d==="categorical"&&qe in K?[new H(Ee.key,st,"stop domain values must be unique")]:(K[qe]=!0,[])):[new H(Ee.key,st,`integer expected, found ${qe}`)]}}function dA(c){const l=(c.expressionContext==="property"?_h:uc)(cA(c.value),c.valueSpec);if(l.result==="error")return l.value.map(y=>new H(`${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 H(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"&&!_l(d))return[new H(c.key,c.value,'"feature-state" data expressions are not supported with layout properties.')];if(c.expressionContext==="filter"&&!_l(d))return[new H(c.key,c.value,'"feature-state" data expressions are not supported with filters.')];if(c.expressionContext&&c.expressionContext.indexOf("cluster")===0){if(!Dl(d,["zoom","feature-state"]))return[new H(c.key,c.value,'"zoom" and "feature-state" expressions are not supported with cluster properties.')];if(c.expressionContext==="cluster-initial"&&!vl(d))return[new H(c.key,c.value,"Feature data expressions are not supported with initial expression part of cluster properties.")]}return[]}function tu(c){const l=c.key,d=c.value,y=c.valueSpec,w=[];return Array.isArray(y.values)?y.values.indexOf(aa(d))===-1&&w.push(new H(l,d,`expected one of [${y.values.join(", ")}], ${JSON.stringify(d)} found`)):Object.keys(y.values).indexOf(aa(d))===-1&&w.push(new H(l,d,`expected one of [${Object.keys(y.values).join(", ")}], ${JSON.stringify(d)} found`)),w}function cc(c){return KA(cA(c.value))?dA(Te({},c,{expressionContext:"filter",valueSpec:{value:"boolean"}})):Id(c)}function Id(c){const l=c.value,d=c.key;if(wi(l)!=="array")return[new H(d,l,`array expected, ${wi(l)} found`)];const y=c.styleSpec;let w,T=[];if(l.length<1)return[new H(d,l,"filter array must have at least 1 element")];switch(T=T.concat(tu({key:`${d}[0]`,value:l[0],valueSpec:y.filter_operator,style:c.style,styleSpec:c.styleSpec})),aa(l[0])){case"<":case"<=":case">":case">=":l.length>=2&&aa(l[1])==="$type"&&T.push(new H(d,l,`"$type" cannot be use with operator "${l[0]}"`));case"==":case"!=":l.length!==3&&T.push(new H(d,l,`filter array for operator "${l[0]}" must have 3 elements`));case"in":case"!in":l.length>=2&&(w=wi(l[1]),w!=="string"&&T.push(new H(`${d}[1]`,l[1],`string expected, ${w} found`)));for(let K=2;K<l.length;K++)w=wi(l[K]),aa(l[1])==="$type"?T=T.concat(tu({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 H(`${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(Id({key:`${d}[${K}]`,value:l[K],style:c.style,styleSpec:c.styleSpec}));break;case"has":case"!has":w=wi(l[1]),l.length!==2?T.push(new H(d,l,`filter array for "${l[0]}" operator must have 2 elements`)):w!=="string"&&T.push(new H(`${d}[1]`,l[1],`string expected, ${w} found`));break;case"within":w=wi(l[1]),l.length!==2?T.push(new H(d,l,`filter array for "${l[0]}" operator must have 2 elements`)):w!=="object"&&T.push(new H(`${d}[1]`,l[1],`object expected, ${w} found`))}return T}function Td(c,l){const d=c.key,y=c.validateSpec,w=c.style,T=c.styleSpec,K=c.value,D=c.objectKey,j=T[`${l}_${c.layerType}`];if(!j)return[];const Z=D.match(/^(.*)-transition$/);if(l==="paint"&&Z&&j[Z[1]]&&j[Z[1]].transition)return y({key:d,value:K,valueSpec:T.transition,style:w,styleSpec:T});const ne=c.valueSpec||j[D];if(!ne)return[new H(d,K,`unknown property "${D}"`)];let Ae;if(wi(K)==="string"&&Gc(ne)&&!ne.tokens&&(Ae=/^{([^}]+)}$/.exec(K)))return[new H(d,K,`"${D}" does not support interpolation syntax
Use an identity property function instead: \`{ "type": "identity", "property": ${JSON.stringify(Ae[1])} }\`.`)];const _e=[];return c.layerType==="symbol"&&(D==="text-field"&&w&&!w.glyphs&&_e.push(new H(d,K,'use of "text-field" requires a style "glyphs" property')),D==="text-font"&&No(cA(K))&&aa(K.type)==="identity"&&_e.push(new H(d,K,'"text-font" does not support identity functions'))),_e.concat(y({key:c.key,value:K,valueSpec:ne,style:w,styleSpec:T,expressionContext:"property",propertyType:l,propertyKey:D}))}function _u(c){return Td(c,"paint")}function wt(c){return Td(c,"layout")}function ln(c){let l=[];const d=c.value,y=c.key,w=c.style,T=c.styleSpec;d.type||d.ref||l.push(new H(y,d,'either "type" or "ref" is required'));let K=aa(d.type);const D=aa(d.ref);if(d.id){const j=aa(d.id);for(let Z=0;Z<c.arrayIndex;Z++){const ne=w.layers[Z];aa(ne.id)===j&&l.push(new H(y,d.id,`duplicate layer id "${d.id}", previously used at line ${ne.id.__line__}`))}}if("ref"in d){let j;["type","source","source-layer","filter","layout"].forEach(Z=>{Z in d&&l.push(new H(y,d[Z],`"${Z}" is prohibited for ref layers`))}),w.layers.forEach(Z=>{aa(Z.id)===D&&(j=Z)}),j?j.ref?l.push(new H(y,d.ref,"ref cannot reference another ref layer")):K=aa(j.type):l.push(new H(y,d.ref,`ref layer "${D}" not found`))}else if(K!=="background")if(d.source){const j=w.sources&&w.sources[d.source],Z=j&&aa(j.type);j?Z==="vector"&&K==="raster"?l.push(new H(y,d.source,`layer "${d.id}" requires a raster source`)):Z!=="raster-dem"&&K==="hillshade"?l.push(new H(y,d.source,`layer "${d.id}" requires a raster-dem source`)):Z==="raster"&&K!=="raster"?l.push(new H(y,d.source,`layer "${d.id}" requires a vector source`)):Z!=="vector"||d["source-layer"]?Z==="raster-dem"&&K!=="hillshade"?l.push(new H(y,d.source,"raster-dem source can only be used with layer type 'hillshade'.")):K!=="line"||!d.paint||!d.paint["line-gradient"]||Z==="geojson"&&j.lineMetrics||l.push(new H(y,d,`layer "${d.id}" specifies a line-gradient, which requires a GeoJSON source with \`lineMetrics\` enabled.`)):l.push(new H(y,d,`layer "${d.id}" must specify a "source-layer"`)):l.push(new H(y,d.source,`source "${d.source}" not found`))}else l.push(new H(y,d,'missing required property "source"'));return l=l.concat(ul({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:cc,layout:j=>ul({layer:d,key:j.key,value:j.value,style:j.style,styleSpec:j.styleSpec,validateSpec:j.validateSpec,objectElementValidators:{"*":Z=>wt(Te({layerType:K},Z))}}),paint:j=>ul({layer:d,key:j.key,value:j.value,style:j.style,styleSpec:j.styleSpec,validateSpec:j.validateSpec,objectElementValidators:{"*":Z=>_u(Te({layerType:K},Z))}})}})),l}function Wt(c){const l=c.value,d=c.key,y=wi(l);return y!=="string"?[new H(d,l,`string expected, ${y} found`)]:[]}const hr={promoteId:function({key:c,value:l}){if(wi(l)==="string")return Wt({key:c,value:l});{const d=[];for(const y in l)d.push(...Wt({key:`${c}.${y}`,value:l[y]}));return d}}};function ai(c){const l=c.value,d=c.key,y=c.styleSpec,w=c.style,T=c.validateSpec;if(!l.type)return[new H(d,l,'"type" is required')];const K=aa(l.type);let D;switch(K){case"vector":case"raster":return D=ul({key:d,value:l,valueSpec:y[`source_${K.replace("-","_")}`],style:c.style,styleSpec:y,objectElementValidators:hr,validateSpec:T}),D;case"raster-dem":return D=function(j){var Z;const ne=(Z=j.sourceName)!==null&&Z!==void 0?Z:"",Ae=j.value,_e=j.styleSpec,Ee=_e.source_raster_dem,Ke=j.style;let We=[];const qe=wi(Ae);if(Ae===void 0)return We;if(qe!=="object")return We.push(new H("source_raster_dem",Ae,`object expected, ${qe} found`)),We;const st=aa(Ae.encoding)==="custom",Ot=["redFactor","greenFactor","blueFactor","baseShift"],ct=j.value.encoding?`"${j.value.encoding}"`:"Default";for(const _t in Ae)!st&&Ot.includes(_t)?We.push(new H(_t,Ae[_t],`In "${ne}": "${_t}" is only valid when "encoding" is set to "custom". ${ct} encoding found`)):Ee[_t]?We=We.concat(j.validateSpec({key:_t,value:Ae[_t],valueSpec:Ee[_t],validateSpec:j.validateSpec,style:Ke,styleSpec:_e})):We.push(new H(_t,Ae[_t],`unknown property "${_t}"`));return We}({sourceName:d,value:l,style:c.style,styleSpec:y,validateSpec:T}),D;case"geojson":if(D=ul({key:d,value:l,valueSpec:y.source_geojson,style:w,styleSpec:y,validateSpec:T,objectElementValidators:hr}),l.cluster)for(const j in l.clusterProperties){const[Z,ne]=l.clusterProperties[j],Ae=typeof Z=="string"?[Z,["accumulated"],["get",j]]:Z;D.push(...dA({key:`${d}.${j}.map`,value:ne,validateSpec:T,expressionContext:"cluster-map"})),D.push(...dA({key:`${d}.${j}.reduce`,value:Ae,validateSpec:T,expressionContext:"cluster-reduce"}))}return D;case"video":return ul({key:d,value:l,valueSpec:y.source_video,style:w,validateSpec:T,styleSpec:y});case"image":return ul({key:d,value:l,valueSpec:y.source_image,style:w,validateSpec:T,styleSpec:y});case"canvas":return[new H(d,null,"Please use runtime APIs to add canvas sources, rather than including them in stylesheets.","source.canvas")];default:return tu({key:`${d}.type`,value:l.type,valueSpec:{values:["vector","raster","raster-dem","geojson","video","image"]},style:w,validateSpec:T,styleSpec:y})}}function ao(c){const l=c.value,d=c.styleSpec,y=d.light,w=c.style;let T=[];const K=wi(l);if(l===void 0)return T;if(K!=="object")return T=T.concat([new H("light",l,`object expected, ${K} found`)]),T;for(const D in l){const j=D.match(/^(.*)-transition$/);T=T.concat(j&&y[j[1]]&&y[j[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 H(D,l[D],`unknown property "${D}"`)])}return T}function sa(c){const l=c.value,d=c.styleSpec,y=d.sky,w=c.style,T=wi(l);if(l===void 0)return[];if(T!=="object")return[new H("sky",l,`object expected, ${T} found`)];let K=[];for(const D in l)K=K.concat(y[D]?Cs({key:D,value:l[D],valueSpec:y[D],style:w,styleSpec:d}):[new H(D,l[D],`unknown property "${D}"`)]);return K}function yo(c){const l=c.value,d=c.styleSpec,y=d.terrain,w=c.style;let T=[];const K=wi(l);if(l===void 0)return T;if(K!=="object")return T=T.concat([new H("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 H(D,l[D],`unknown property "${D}"`)]);return T}function _s(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 H(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 H(y,d,`all the sprites' URLs must be unique, but ${d[K].url} is duplicated`)),T.push(d[K].url),l=l.concat(ul({key:`${y}[${K}]`,value:d[K],valueSpec:{id:{type:"string",required:!0},url:{type:"string",required:!0}},validateSpec:c.validateSpec}));return l}return Wt({key:y,value:d})}const qc={"*":()=>[],array:FA,boolean:function(c){const l=c.value,d=c.key,y=wi(l);return y!=="boolean"?[new H(d,l,`boolean expected, ${y} found`)]:[]},number:xl,color:function(c){const l=c.key,d=c.value,y=wi(d);return y!=="string"?[new H(l,d,`color expected, ${y} found`)]:bi.parse(String(d))?[]:[new H(l,d,`color expected, "${d}" found`)]},constants:bl,enum:tu,filter:cc,function:bh,layer:ln,object:ul,source:ai,light:ao,sky:sa,terrain:yo,string:Wt,formatted:function(c){return Wt(c).length===0?[]:dA(c)},resolvedImage:function(c){return Wt(c).length===0?[]:dA(c)},padding:function(c){const l=c.key,d=c.value;if(wi(d)==="array"){if(d.length<1||d.length>4)return[new H(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 xl({key:l,value:d,valueSpec:{}})},variableAnchorOffsetCollection:function(c){const l=c.key,d=c.value,y=wi(d),w=c.styleSpec;if(y!=="array"||d.length<1||d.length%2!=0)return[new H(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(tu({key:`${l}[${K}]`,value:d[K],valueSpec:w.layout_symbol["text-anchor"]})),T=T.concat(FA({key:`${l}[${K+1}]`,value:d[K+1],valueSpec:{length:2,value:"number"},validateSpec:c.validateSpec,style:c.style,styleSpec:w}));return T},sprite:_s};function Cs(c){const l=c.value,d=c.valueSpec,y=c.styleSpec;return c.validateSpec=Cs,d.expression&&No(aa(l))?bh(c):d.expression&&Mo(cA(l))?dA(c):d.type&&qc[d.type]?qc[d.type](c):ul(Te({},c,{valueSpec:d.type?y[d.type]:d}))}function Kd(c){const l=c.value,d=c.key,y=Wt(c);return y.length||(l.indexOf("{fontstack}")===-1&&y.push(new H(d,l,'"glyphs" url must include a "{fontstack}" token')),l.indexOf("{range}")===-1&&y.push(new H(d,l,'"glyphs" url must include a "{range}" token'))),y}function Ps(c,l=pt){let d=[];return d=d.concat(Cs({key:"",value:c,valueSpec:l.$root,styleSpec:l,style:c,validateSpec:Cs,objectElementValidators:{glyphs:Kd,"*":()=>[]}})),c.constants&&(d=d.concat(bl({key:"constants",value:c.constants,style:c,styleSpec:l,validateSpec:Cs}))),Cu(d)}function la(c){return function(l){return c({...l,validateSpec:Cs})}}function Cu(c){return[].concat(c).sort((l,d)=>l.line-d.line)}function Fs(c){return function(...l){return Cu(c.apply(this,l))}}Ps.source=Fs(la(ai)),Ps.sprite=Fs(la(_s)),Ps.glyphs=Fs(la(Kd)),Ps.light=Fs(la(ao)),Ps.sky=Fs(la(sa)),Ps.terrain=Fs(la(yo)),Ps.layer=Fs(la(ln)),Ps.filter=Fs(la(cc)),Ps.paintProperty=Fs(la(_u)),Ps.layoutProperty=Fs(la(wt));const to=Ps,xh=to.light,wh=to.paintProperty,wl=to.layoutProperty;function DA(c,l){let d=!1;if(l&&l.length)for(const y of l)c.fire(new Ut(new Error(y.message))),d=!0;return d}class Da{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 j=0;j<this.d*this.d;j++){const Z=K[3+j],ne=K[3+j+1];w.push(Z===ne?null:K.subarray(Z,ne))}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 j=[];return this._forEachCell(l,d,y,w,this._queryCell,j,{},T),j}}_queryCell(l,d,y,w,T,K,D,j){const Z=this.cells[T];if(Z!==null){const ne=this.keys,Ae=this.bboxes;for(let _e=0;_e<Z.length;_e++){const Ee=Z[_e];if(D[Ee]===void 0){const Ke=4*Ee;(j?j(Ae[Ke+0],Ae[Ke+1],Ae[Ke+2],Ae[Ke+3]):l<=Ae[Ke+2]&&d<=Ae[Ke+3]&&y>=Ae[Ke+0]&&w>=Ae[Ke+1])?(D[Ee]=!0,K.push(ne[Ee])):D[Ee]=!1}}}}_forEachCell(l,d,y,w,T,K,D,j){const Z=this._convertToCellCoord(l),ne=this._convertToCellCoord(d),Ae=this._convertToCellCoord(y),_e=this._convertToCellCoord(w);for(let Ee=Z;Ee<=Ae;Ee++)for(let Ke=ne;Ke<=_e;Ke++){const We=this.d*Ke+Ee;if((!j||j(this._convertFromCellCoord(Ee),this._convertFromCellCoord(Ke),this._convertFromCellCoord(Ee+1),this._convertFromCellCoord(Ke+1)))&&T.call(this,l,d,y,w,We,K,D,j))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 Da(l.buffer)}}const Vs={};function Nn(c,l,d={}){if(Vs[c])throw new Error(`${c} is already registered.`);Object.defineProperty(l,"_classRegistryKey",{value:c,writeable:!1}),Vs[c]={klass:l,omit:d.omit||[],shallow:d.shallow||[]}}Nn("Object",Object),Nn("TransferableGridIndex",Da),Nn("Color",bi),Nn("Error",Error),Nn("AJAXError",Me),Nn("ResolvedImage",ve),Nn("StylePropertyFunction",eu),Nn("StyleExpression",To,{omit:["_evaluator"]}),Nn("ZoomDependentExpression",Hs),Nn("ZoomConstantExpression",Qc),Nn("CompoundExpression",Do,{omit:["_evaluate"]});for(const c in IA)IA[c]._classRegistryKey||Nn(`Expression_${c}`,IA[c]);function zl(c){return c&&typeof ArrayBuffer<"u"&&(c instanceof ArrayBuffer||c.constructor&&c.constructor.name==="ArrayBuffer")}function hA(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(zl(c)||Yt(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(hA(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(!Vs[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)||Vs[y].omit.indexOf(T)>=0)continue;const K=c[T];w[T]=Vs[y].shallow.indexOf(T)>=0?K:hA(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 dc(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||zl(c)||Yt(c)||ArrayBuffer.isView(c)||c instanceof ImageData)return c;if(Array.isArray(c))return c.map(dc);if(typeof c=="object"){const l=c.$name||"Object";if(!Vs[l])throw new Error(`can't deserialize unregistered class ${l}`);const{klass:d}=Vs[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]=Vs[l].shallow.indexOf(w)>=0?T:dc(T)}return y}throw new Error("can't deserialize object of type "+typeof c)}class bu{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 $n={"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 hc(c){for(const l of c)if(Nu(l.charCodeAt(0)))return!0;return!1}function LA(c){for(const l of c)if(!If(l.charCodeAt(0)))return!1;return!0}function If(c){return!($n.Arabic(c)||$n["Arabic Supplement"](c)||$n["Arabic Extended-A"](c)||$n["Arabic Presentation Forms-A"](c)||$n["Arabic Presentation Forms-B"](c))}function Nu(c){return!(c!==746&&c!==747&&(c<4352||!($n["Bopomofo Extended"](c)||$n.Bopomofo(c)||$n["CJK Compatibility Forms"](c)&&!(c>=65097&&c<=65103)||$n["CJK Compatibility Ideographs"](c)||$n["CJK Compatibility"](c)||$n["CJK Radicals Supplement"](c)||$n["CJK Strokes"](c)||!(!$n["CJK Symbols and Punctuation"](c)||c>=12296&&c<=12305||c>=12308&&c<=12319||c===12336)||$n["CJK Unified Ideographs Extension A"](c)||$n["CJK Unified Ideographs"](c)||$n["Enclosed CJK Letters and Months"](c)||$n["Hangul Compatibility Jamo"](c)||$n["Hangul Jamo Extended-A"](c)||$n["Hangul Jamo Extended-B"](c)||$n["Hangul Jamo"](c)||$n["Hangul Syllables"](c)||$n.Hiragana(c)||$n["Ideographic Description Characters"](c)||$n.Kanbun(c)||$n["Kangxi Radicals"](c)||$n["Katakana Phonetic Extensions"](c)||$n.Katakana(c)&&c!==12540||!(!$n["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)||!(!$n["Small Form Variants"](c)||c>=65112&&c<=65118||c>=65123&&c<=65126)||$n["Unified Canadian Aboriginal Syllabics"](c)||$n["Unified Canadian Aboriginal Syllabics Extended"](c)||$n["Vertical Forms"](c)||$n["Yijing Hexagram Symbols"](c)||$n["Yi Syllables"](c)||$n["Yi Radicals"](c))))}function xu(c){return!(Nu(c)||function(l){return!!($n["Latin-1 Supplement"](l)&&(l===167||l===169||l===174||l===177||l===188||l===189||l===190||l===215||l===247)||$n["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)||$n["Letterlike Symbols"](l)||$n["Number Forms"](l)||$n["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)||$n["Control Pictures"](l)&&l!==9251||$n["Optical Character Recognition"](l)||$n["Enclosed Alphanumerics"](l)||$n["Geometric Shapes"](l)||$n["Miscellaneous Symbols"](l)&&!(l>=9754&&l<=9759)||$n["Miscellaneous Symbols and Arrows"](l)&&(l>=11026&&l<=11055||l>=11088&&l<=11097||l>=11192&&l<=11243)||$n["CJK Symbols and Punctuation"](l)||$n.Katakana(l)||$n["Private Use Area"](l)||$n["CJK Compatibility Forms"](l)||$n["Small Form Variants"](l)||$n["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 UA(c){return c>=1424&&c<=2303||$n["Arabic Presentation Forms-A"](c)||$n["Arabic Presentation Forms-B"](c)}function Tf(c,l){return!(!l&&UA(c)||c>=2304&&c<=3583||c>=3840&&c<=4255||$n.Khmer(c))}function fc(c){for(const l of c)if(UA(l.charCodeAt(0)))return!0;return!1}const Gu=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 So{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 bu,this.transition={})}isSupportedScript(l){return function(d,y){for(const w of d)if(!Tf(w.charCodeAt(0),y))return!1;return!0}(l,Gu.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 wu{constructor(l,d){this.property=l,this.value=d,this.expression=function(y,w){if(No(y))return new eu(y,w);if(Mo(y)){const T=_h(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=bi.parse(y):w.type!=="padding"||typeof y!="number"&&!Array.isArray(y)?w.type==="variableAnchorOffsetCollection"&&Array.isArray(y)&&(T=qi.parse(y)):T=eo.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 Hc{constructor(l){this.property=l,this.value=new wu(l,void 0)}transitioned(l,d){return new Kf(this.property,this.value,d,V({},l.transition,this.transition),l.now)}untransitioned(){return new Kf(this.property,this.value,null,{},0)}}class Tp{constructor(l){this._properties=l,this._values=Object.create(l.defaultTransitionablePropertyValues)}getValue(l){return De(this._values[l].value.value)}setValue(l,d){Object.prototype.hasOwnProperty.call(this._values,l)||(this._values[l]=new Hc(this._values[l].property)),this._values[l].value=new wu(this._values[l].property,d===null?void 0:De(d))}getTransition(l){return De(this._values[l].transition)}setTransition(l,d){Object.prototype.hasOwnProperty.call(this._values,l)||(this._values[l]=new Hc(this._values[l].property)),this._values[l].transition=De(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 Pd(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 Pd(this._properties);for(const d of Object.keys(this._values))l._values[d]=this._values[d].untransitioned();return l}}class Kf{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(j){if(j<=0)return 0;if(j>=1)return 1;const Z=j*j,ne=Z*j;return 4*(j<.5?ne:3*(j-Z)+ne-.75)}(D))}}return T}}class Pd{constructor(l){this._properties=l,this._values=Object.create(l.defaultTransitioningPropertyValues)}possiblyEvaluate(l,d,y){const w=new ua(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 Mh{constructor(l){this._properties=l,this._values=Object.create(l.defaultPropertyValues)}hasValue(l){return this._values[l].value!==void 0}getValue(l){return De(this._values[l].value)}setValue(l,d){this._values[l]=new wu(this._values[l].property,d===null?void 0:De(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 ua(this._properties);for(const T of Object.keys(this._values))w._values[T]=this._values[T].possiblyEvaluate(l,d,y);return w}}class so{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 ua{constructor(l){this._properties=l,this._values=Object.create(l.defaultPossiblyEvaluatedValues)}get(l){return this._values[l]}}class vr{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=mt[this.specification.type];return w?w(l,d,y):l}}class Tr{constructor(l,d){this.specification=l,this.overrides=d}possiblyEvaluate(l,d,y,w){return new so(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 so(this,{kind:"constant",value:void 0},l.parameters);const w=mt[this.specification.type];if(w){const T=w(l.value.value,d.value.value,y);return new so(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 RA extends Tr{possiblyEvaluate(l,d,y,w){if(l.value===void 0)return new so(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 so(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 so(this,{kind:"constant",value:T},d)}return new so(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 pc{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 So(Math.floor(d.zoom-1),d)),l.expression.evaluate(new So(Math.floor(d.zoom),d)),l.expression.evaluate(new So(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 Vc{constructor(l){this.specification=l}possiblyEvaluate(l,d,y,w){return!!l.expression.evaluate(d,null,{},y,w)}interpolate(){return!1}}class Jo{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 wu(y,void 0),T=this.defaultTransitionablePropertyValues[d]=new Hc(y);this.defaultTransitioningPropertyValues[d]=T.untransitioned(),this.defaultPossiblyEvaluatedValues[d]=w.possiblyEvaluate({})}}}Nn("DataDrivenProperty",Tr),Nn("DataConstantProperty",vr),Nn("CrossFadedDataDrivenProperty",RA),Nn("CrossFadedProperty",pc),Nn("ColorRampProperty",Vc);const fA="-transition";class Ia extends Rt{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 Mh(d.layout)),d.paint)){this._transitionablePaint=new Tp(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 ua(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(wl,`layers.${this.id}.layout.${l}`,l,d,y)||(l!=="visibility"?this._unevaluatedLayout.setValue(l,d):this.visibility=d)}getPaintProperty(l){return l.endsWith(fA)?this._transitionablePaint.getTransition(l.slice(0,-11)):this._transitionablePaint.getValue(l)}setPaintProperty(l,d,y={}){if(d!=null&&this._validate(wh,`layers.${this.id}.paint.${l}`,l,d,y))return!1;if(l.endsWith(fA))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 j=this._transitionablePaint._values[l].value;return j.isDataDriven()||K||T||this._handleOverridablePaintPropertyUpdate(l,D,j)}}_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),Oe(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)&&DA(this,l.call(to,{key:d,layerType:this.type,objectKey:y,value:w,styleSpec:pt,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 so&&Gc(d.property.specification)&&(d.value.kind==="source"||d.value.kind==="composite")&&d.value.isStateDependent)return!0}return!1}}const pA={Int8:Int8Array,Uint8:Uint8Array,Int16:Int16Array,Uint16:Uint16Array,Int32:Int32Array,Uint32:Uint32Array,Float32:Float32Array};class Ml{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 Go{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 Qo(c,l=1){let d=0,y=0;return{members:c.map(w=>{const T=pA[w.type].BYTES_PER_ELEMENT,K=d=Pf(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:Pf(d,Math.max(y,l)),alignment:l}}function Pf(c,l){return Math.ceil(c/l)*l}class Qu extends Go{_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}}Qu.prototype.bytesPerElement=4,Nn("StructArrayLayout2i4",Qu);class $u extends Go{_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}}$u.prototype.bytesPerElement=6,Nn("StructArrayLayout3i6",$u);class mA extends Go{_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}}mA.prototype.bytesPerElement=8,Nn("StructArrayLayout4i8",mA);class Ff extends Go{_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 j=6*l;return this.int16[j+0]=d,this.int16[j+1]=y,this.int16[j+2]=w,this.int16[j+3]=T,this.int16[j+4]=K,this.int16[j+5]=D,l}}Ff.prototype.bytesPerElement=12,Nn("StructArrayLayout2i4i12",Ff);class Zc extends Go{_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 j=4*l,Z=8*l;return this.int16[j+0]=d,this.int16[j+1]=y,this.uint8[Z+4]=w,this.uint8[Z+5]=T,this.uint8[Z+6]=K,this.uint8[Z+7]=D,l}}Zc.prototype.bytesPerElement=8,Nn("StructArrayLayout2i4ub8",Zc);class Yu extends Go{_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}}Yu.prototype.bytesPerElement=8,Nn("StructArrayLayout2f8",Yu);class Sh extends Go{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K,D,j,Z,ne){const Ae=this.length;return this.resize(Ae+1),this.emplace(Ae,l,d,y,w,T,K,D,j,Z,ne)}emplace(l,d,y,w,T,K,D,j,Z,ne,Ae){const _e=10*l;return this.uint16[_e+0]=d,this.uint16[_e+1]=y,this.uint16[_e+2]=w,this.uint16[_e+3]=T,this.uint16[_e+4]=K,this.uint16[_e+5]=D,this.uint16[_e+6]=j,this.uint16[_e+7]=Z,this.uint16[_e+8]=ne,this.uint16[_e+9]=Ae,l}}Sh.prototype.bytesPerElement=20,Nn("StructArrayLayout10ui20",Sh);class Pe extends Go{_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,j,Z,ne,Ae,_e){const Ee=this.length;return this.resize(Ee+1),this.emplace(Ee,l,d,y,w,T,K,D,j,Z,ne,Ae,_e)}emplace(l,d,y,w,T,K,D,j,Z,ne,Ae,_e,Ee){const Ke=12*l;return this.int16[Ke+0]=d,this.int16[Ke+1]=y,this.int16[Ke+2]=w,this.int16[Ke+3]=T,this.uint16[Ke+4]=K,this.uint16[Ke+5]=D,this.uint16[Ke+6]=j,this.uint16[Ke+7]=Z,this.int16[Ke+8]=ne,this.int16[Ke+9]=Ae,this.int16[Ke+10]=_e,this.int16[Ke+11]=Ee,l}}Pe.prototype.bytesPerElement=24,Nn("StructArrayLayout4i4ui4i24",Pe);class Sl extends Go{_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}}Sl.prototype.bytesPerElement=12,Nn("StructArrayLayout3f12",Sl);class Qa extends Go{_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}}Qa.prototype.bytesPerElement=4,Nn("StructArrayLayout1ul4",Qa);class lo extends Go{_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,j,Z){const ne=this.length;return this.resize(ne+1),this.emplace(ne,l,d,y,w,T,K,D,j,Z)}emplace(l,d,y,w,T,K,D,j,Z,ne){const Ae=10*l,_e=5*l;return this.int16[Ae+0]=d,this.int16[Ae+1]=y,this.int16[Ae+2]=w,this.int16[Ae+3]=T,this.int16[Ae+4]=K,this.int16[Ae+5]=D,this.uint32[_e+3]=j,this.uint16[Ae+8]=Z,this.uint16[Ae+9]=ne,l}}lo.prototype.bytesPerElement=20,Nn("StructArrayLayout6i1ul2ui20",lo);class Yr extends Go{_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 j=6*l;return this.int16[j+0]=d,this.int16[j+1]=y,this.int16[j+2]=w,this.int16[j+3]=T,this.int16[j+4]=K,this.int16[j+5]=D,l}}Yr.prototype.bytesPerElement=12,Nn("StructArrayLayout2i2i2i12",Yr);class va extends Go{_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,j=8*l;return this.float32[D+0]=d,this.float32[D+1]=y,this.float32[D+2]=w,this.int16[j+6]=T,this.int16[j+7]=K,l}}va.prototype.bytesPerElement=16,Nn("StructArrayLayout2f1f2i16",va);class mc extends Go{_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}}mc.prototype.bytesPerElement=12,Nn("StructArrayLayout2ub2f12",mc);class gc extends Go{_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}}gc.prototype.bytesPerElement=6,Nn("StructArrayLayout3ui6",gc);class Zs extends Go{_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,j,Z,ne,Ae,_e,Ee,Ke,We,qe,st){const Ot=this.length;return this.resize(Ot+1),this.emplace(Ot,l,d,y,w,T,K,D,j,Z,ne,Ae,_e,Ee,Ke,We,qe,st)}emplace(l,d,y,w,T,K,D,j,Z,ne,Ae,_e,Ee,Ke,We,qe,st,Ot){const ct=24*l,_t=12*l,nn=48*l;return this.int16[ct+0]=d,this.int16[ct+1]=y,this.uint16[ct+2]=w,this.uint16[ct+3]=T,this.uint32[_t+2]=K,this.uint32[_t+3]=D,this.uint32[_t+4]=j,this.uint16[ct+10]=Z,this.uint16[ct+11]=ne,this.uint16[ct+12]=Ae,this.float32[_t+7]=_e,this.float32[_t+8]=Ee,this.uint8[nn+36]=Ke,this.uint8[nn+37]=We,this.uint8[nn+38]=qe,this.uint32[_t+10]=st,this.int16[ct+22]=Ot,l}}Zs.prototype.bytesPerElement=48,Nn("StructArrayLayout2i2ui3ul3ui2f3ub1ul1i48",Zs);class Df extends Go{_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,j,Z,ne,Ae,_e,Ee,Ke,We,qe,st,Ot,ct,_t,nn,cn,Un,Cr,qn,wn,gn,lr){const Rn=this.length;return this.resize(Rn+1),this.emplace(Rn,l,d,y,w,T,K,D,j,Z,ne,Ae,_e,Ee,Ke,We,qe,st,Ot,ct,_t,nn,cn,Un,Cr,qn,wn,gn,lr)}emplace(l,d,y,w,T,K,D,j,Z,ne,Ae,_e,Ee,Ke,We,qe,st,Ot,ct,_t,nn,cn,Un,Cr,qn,wn,gn,lr,Rn){const On=32*l,Fr=16*l;return this.int16[On+0]=d,this.int16[On+1]=y,this.int16[On+2]=w,this.int16[On+3]=T,this.int16[On+4]=K,this.int16[On+5]=D,this.int16[On+6]=j,this.int16[On+7]=Z,this.uint16[On+8]=ne,this.uint16[On+9]=Ae,this.uint16[On+10]=_e,this.uint16[On+11]=Ee,this.uint16[On+12]=Ke,this.uint16[On+13]=We,this.uint16[On+14]=qe,this.uint16[On+15]=st,this.uint16[On+16]=Ot,this.uint16[On+17]=ct,this.uint16[On+18]=_t,this.uint16[On+19]=nn,this.uint16[On+20]=cn,this.uint16[On+21]=Un,this.uint16[On+22]=Cr,this.uint32[Fr+12]=qn,this.float32[Fr+13]=wn,this.float32[Fr+14]=gn,this.uint16[On+30]=lr,this.uint16[On+31]=Rn,l}}Df.prototype.bytesPerElement=64,Nn("StructArrayLayout8i15ui1ul2f2ui64",Df);class Fd extends Go{_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}}Fd.prototype.bytesPerElement=4,Nn("StructArrayLayout1f4",Fd);class yc extends Go{_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}}yc.prototype.bytesPerElement=12,Nn("StructArrayLayout1ui2f12",yc);class Dd extends Go{_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}}Dd.prototype.bytesPerElement=8,Nn("StructArrayLayout1ul2ui8",Dd);class Eh extends Go{_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}}Eh.prototype.bytesPerElement=4,Nn("StructArrayLayout2ui4",Eh);class El extends Go{_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}}El.prototype.bytesPerElement=2,Nn("StructArrayLayout1ui2",El);class Lf extends Go{_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}}Lf.prototype.bytesPerElement=16,Nn("StructArrayLayout4f16",Lf);class O extends Ml{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 lo{get(l){return new O(this,l)}}Nn("CollisionBoxArray",u);class p extends Ml{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 _ extends Zs{get(l){return new p(this,l)}}Nn("PlacedSymbolArray",_);class M extends Ml{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 Df{get(l){return new M(this,l)}}Nn("SymbolInstanceArray",I);class z extends Fd{getoffsetX(l){return this.float32[1*l+0]}}Nn("GlyphOffsetArray",z);class W extends $u{getx(l){return this.int16[3*l+0]}gety(l){return this.int16[3*l+1]}gettileUnitDistanceFromAnchor(l){return this.int16[3*l+2]}}Nn("SymbolLineVertexArray",W);class Q extends Ml{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]}}Q.prototype.size=12;class re extends yc{get(l){return new Q(this,l)}}Nn("TextAnchorOffsetArray",re);class ue extends Ml{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]}}ue.prototype.size=8;class pe extends Dd{get(l){return new ue(this,l)}}Nn("FeatureIndexArray",pe);class Ie extends Qu{}class Ne extends Qu{}class Re extends Qu{}class $e extends Ff{}class Ge extends Zc{}class ht extends Yu{}class Tt extends Sh{}class Ze extends Pe{}class Ct extends Sl{}class $t extends Qa{}class Dt extends Yr{}class tn extends mc{}class dn extends gc{}class An extends Eh{}const bn=Qo([{name:"a_pos",components:2,type:"Int16"}],4),{members:tr}=bn;class Pr{constructor(l=[]){this.segments=l}prepareSegment(l,d,y,w){let T=this.segments[this.segments.length-1];return l>Pr.MAX_VERTEX_ARRAY_LENGTH&&ke(`Max vertices per segment is ${Pr.MAX_VERTEX_ARRAY_LENGTH}: bucket requested ${l}`),(!T||T.vertexLength+l>Pr.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 Pr([{vertexOffset:l,primitiveOffset:d,vertexLength:y,primitiveLength:w,vaos:{},sortKey:0}])}}function Tn(c,l){return 256*(c=me(Math.floor(c),0,255))+me(Math.floor(l),0,255)}Pr.MAX_VERTEX_ARRAY_LENGTH=Math.pow(2,16)-1,Nn("SegmentVector",Pr);const xr=Qo([{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 Jn={exports:{}},Ni={exports:{}};Ni.exports=function(c,l){var d,y,w,T,K,D,j,Z;for(y=c.length-(d=3&c.length),w=l,K=3432918353,D=461845907,Z=0;Z<y;)j=255&c.charCodeAt(Z)|(255&c.charCodeAt(++Z))<<8|(255&c.charCodeAt(++Z))<<16|(255&c.charCodeAt(++Z))<<24,++Z,w=27492+(65535&(T=5*(65535&(w=(w^=j=(65535&(j=(j=(65535&j)*K+(((j>>>16)*K&65535)<<16)&4294967295)<<15|j>>>17))*D+(((j>>>16)*D&65535)<<16)&4294967295)<<13|w>>>19))+((5*(w>>>16)&65535)<<16)&4294967295))+((58964+(T>>>16)&65535)<<16);switch(j=0,d){case 3:j^=(255&c.charCodeAt(Z+2))<<16;case 2:j^=(255&c.charCodeAt(Z+1))<<8;case 1:w^=j=(65535&(j=(j=(65535&(j^=255&c.charCodeAt(Z)))*K+(((j>>>16)*K&65535)<<16)&4294967295)<<15|j>>>17))*D+(((j>>>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 ki=Ni.exports,ri={exports:{}};ri.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 Mi=ki,ea=ri.exports;Jn.exports=Mi,Jn.exports.murmur3=Mi,Jn.exports.murmur2=ea;var Ui=h(Jn.exports);class Ds{constructor(){this.ids=[],this.positions=[],this.indexed=!1}add(l,d,y,w){this.ids.push(bs(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=bs(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 Ho(y,w,0,y.length-1),d&&d.push(y.buffer,w.buffer),{ids:y,positions:w}}static deserialize(l){const d=new Ds;return d.ids=l.ids,d.positions=l.positions,d.indexed=!0,d}}function bs(c){const l=+c;return!isNaN(l)&&l<=Number.MAX_SAFE_INTEGER?l:Ui(String(c))}function Ho(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;Ls(c,T,K),Ls(l,3*T,3*K),Ls(l,3*T+1,3*K+1),Ls(l,3*T+2,3*K+2)}K-d<y-K?(Ho(c,l,d,K),d=K+1):(Ho(c,l,K+1,y),y=K)}}function Ls(c,l,d){const y=c[l];c[l]=c[d],c[d]=y}Nn("FeaturePositionMap",Ds);class Ta{constructor(l,d){this.gl=l.gl,this.location=d}}class Eo extends Ta{constructor(l,d){super(l,d),this.current=0}set(l){this.current!==l&&(this.current=l,this.gl.uniform1f(this.location,l))}}class jl extends Ta{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 zA extends Ta{constructor(l,d){super(l,d),this.current=bi.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 Us=new Float32Array(16);function Mu(c){return[Tn(255*c.r,255*c.g),Tn(255*c.b,255*c.a)]}class Ka{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 zA(l,d):new Eo(l,d)}}class Lo{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 jl(l,d):new Eo(l,d)}}class Pi{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 So(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=Mu(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 vo{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 So(this.zoom),d,{},w,[],T),D=this.expression.evaluate(new So(this.zoom+1),d,{},w,[],T),j=this.paintVertexArray.length;this.paintVertexArray.resize(l),this._setPaintValue(j,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=Mu(y),K=Mu(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=me(this.expression.interpolationFactor(y,this.zoom,this.zoom+1),0,1);l.set(w)}getBinding(l,d,y){return new Eo(l,d)}}class Ko{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,j=w[T],Z=w[K],ne=w[D];if(j&&Z&&ne)for(let Ae=l;Ae<d;Ae++)this.zoomInPaintVertexArray.emplace(Ae,Z.tl[0],Z.tl[1],Z.br[0],Z.br[1],j.tl[0],j.tl[1],j.br[0],j.br[1],Z.pixelRatio,j.pixelRatio),this.zoomOutPaintVertexArray.emplace(Ae,Z.tl[0],Z.tl[1],Z.br[0],Z.br[1],ne.tl[0],ne.tl[1],ne.br[0],ne.br[1],Z.pixelRatio,ne.pixelRatio)}upload(l){this.zoomInPaintVertexArray&&this.zoomInPaintVertexArray.arrayBuffer&&this.zoomOutPaintVertexArray&&this.zoomOutPaintVertexArray.arrayBuffer&&(this.zoomInPaintVertexBuffer=l.createVertexBuffer(this.zoomInPaintVertexArray,xr.members,this.expression.isStateDependent),this.zoomOutPaintVertexBuffer=l.createVertexBuffer(this.zoomOutPaintVertexArray,xr.members,this.expression.isStateDependent))}destroy(){this.zoomOutPaintVertexBuffer&&this.zoomOutPaintVertexBuffer.destroy(),this.zoomInPaintVertexBuffer&&this.zoomInPaintVertexBuffer.destroy()}}class $a{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 so&&Gc(K.property.specification)))continue;const D=Aa(T,l.type),j=K.value,Z=K.property.specification.type,ne=K.property.useIntegerZoom,Ae=K.property.specification["property-type"],_e=Ae==="cross-faded"||Ae==="cross-faded-data-driven";if(j.kind==="constant")this.binders[T]=_e?new Lo(j.value,D):new Ka(j.value,D,Z),w.push(`/u_${T}`);else if(j.kind==="source"||_e){const Ee=vc(T,Z,"source");this.binders[T]=_e?new Ko(j,Z,ne,d,Ee,l.id):new Pi(j,D,Z,Ee),w.push(`/a_${T}`)}else{const Ee=vc(T,Z,"composite");this.binders[T]=new vo(j,D,Z,ne,d,Ee),w.push(`/z_${T}`)}}this.cacheKey=w.sort().join("")}getMaxValue(l){const d=this.binders[l];return d instanceof Pi||d instanceof vo?d.maxValue:0}populatePaintArrays(l,d,y,w,T){for(const K in this.binders){const D=this.binders[K];(D instanceof Pi||D instanceof vo||D instanceof Ko)&&D.populatePaintArray(l,d,y,w,T)}}setConstantPatternPositions(l,d){for(const y in this.binders){const w=this.binders[y];w instanceof Lo&&w.setConstantPatternPositions(l,d)}}updatePaintArrays(l,d,y,w,T){let K=!1;for(const D in l){const j=d.getPositions(D);for(const Z of j){const ne=y.feature(Z.index);for(const Ae in this.binders){const _e=this.binders[Ae];if((_e instanceof Pi||_e instanceof vo||_e instanceof Ko)&&_e.expression.isStateDependent===!0){const Ee=w.paint.get(Ae);_e.expression=Ee.value,_e.updatePaintArray(Z.start,Z.end,ne,l[D],T),K=!0}}}}return K}defines(){const l=[];for(const d in this.binders){const y=this.binders[d];(y instanceof Ka||y instanceof Lo)&&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 Pi||y instanceof vo)for(let w=0;w<y.paintVertexAttributes.length;w++)l.push(y.paintVertexAttributes[w].name);else if(y instanceof Ko)for(let w=0;w<xr.members.length;w++)l.push(xr.members[w].name)}return l}getBinderUniforms(){const l=[];for(const d in this.binders){const y=this.binders[d];if(y instanceof Ka||y instanceof Lo||y instanceof vo)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 Ka||T instanceof Lo||T instanceof vo){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 Ko){const w=l.fromScale===2?y.zoomInPaintVertexBuffer:y.zoomOutPaintVertexBuffer;w&&this._buffers.push(w)}else(y instanceof Pi||y instanceof vo)&&y.paintVertexBuffer&&this._buffers.push(y.paintVertexBuffer)}}upload(l){for(const d in this.binders){const y=this.binders[d];(y instanceof Pi||y instanceof vo||y instanceof Ko)&&y.upload(l)}this.updatePaintBuffers()}destroy(){for(const l in this.binders){const d=this.binders[l];(d instanceof Pi||d instanceof vo||d instanceof Ko)&&d.destroy()}}}class ls{constructor(l,d,y=()=>!0){this.programConfigurations={};for(const w of l)this.programConfigurations[w.id]=new $a(w,d,y);this.needsUpload=!1,this._featureMap=new Ds,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 Aa(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 vc(c,l,d){const y={color:{source:Yu,composite:Lf},number:{source:Fd,composite:Yu}},w=function(T){return{"line-pattern":{source:Tt,composite:Tt},"fill-pattern":{source:Tt,composite:Tt},"fill-extrusion-pattern":{source:Tt,composite:Tt}}[T]}(c);return w&&w[d]||y[l][d]}Nn("ConstantBinder",Ka),Nn("CrossFadedConstantBinder",Lo),Nn("SourceExpressionBinder",Pi),Nn("CrossFadedCompositeBinder",Ko),Nn("CompositeExpressionBinder",vo),Nn("ProgramConfiguration",$a,{omit:["_buffers"]}),Nn("ProgramConfigurationSet",ls);const _a=8192,jA=Math.pow(2,14)-1,Oh=-jA-1;function nu(c){const l=_a/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),j=Math.round(K.y*l);K.x=me(D,Oh,jA),K.y=me(j,Oh,jA),(D<K.x||D>K.x+1||j<K.y||j>K.y+1)&&ke("Geometry exceeds allowed extent, reduce your vector tile buffer size")}}return d}function WA(c,l){return{type:c.type,id:c.id,properties:c.properties,geometry:l?nu(c):[]}}function Xs(c,l,d,y,w){c.emplaceBack(2*l+(y+1)/2,2*d+(w+1)/2)}class Ld{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 Ne,this.indexArray=new dn,this.segments=new Pr,this.programConfigurations=new ls(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:j,id:Z,index:ne,sourceLayerIndex:Ae}of l){const _e=this.layers[0]._featureFilter.needGeometry,Ee=WA(j,_e);if(!this.layers[0]._featureFilter.filter(new So(this.zoom),Ee,y))continue;const Ke=D?K.evaluate(Ee,{},y):void 0,We={id:Z,properties:j.properties,type:j.type,sourceLayerIndex:Ae,index:ne,geometry:_e?Ee.geometry:nu(j),patterns:{},sortKey:Ke};T.push(We)}D&&T.sort((j,Z)=>j.sortKey-Z.sortKey);for(const j of T){const{geometry:Z,index:ne,sourceLayerIndex:Ae}=j,_e=l[ne].feature;this.addFeature(j,Z,ne,y),d.featureIndex.insert(_e,Z,ne,Ae,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,tr),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,j=K.y;if(D<0||D>=_a||j<0||j>=_a)continue;const Z=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray,l.sortKey),ne=Z.vertexLength;Xs(this.layoutVertexArray,D,j,-1,-1),Xs(this.layoutVertexArray,D,j,1,-1),Xs(this.layoutVertexArray,D,j,1,1),Xs(this.layoutVertexArray,D,j,-1,1),this.indexArray.emplaceBack(ne,ne+1,ne+2),this.indexArray.emplaceBack(ne,ne+3,ne+2),Z.vertexLength+=4,Z.primitiveLength+=2}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,l,y,{},w)}}function _c(c,l){for(let d=0;d<c.length;d++)if(Hu(l,c[d]))return!0;for(let d=0;d<l.length;d++)if(Hu(c,l[d]))return!0;return!!Xc(c,l)}function Bh(c,l,d){return!!Hu(c,l)||!!Jc(l,c,d)}function qu(c,l){if(c.length===1)return kh(l,c[0]);for(let d=0;d<l.length;d++){const y=l[d];for(let w=0;w<y.length;w++)if(Hu(c,y[w]))return!0}for(let d=0;d<c.length;d++)if(kh(l,c[d]))return!0;for(let d=0;d<l.length;d++)if(Xc(c,l[d]))return!0;return!1}function Uf(c,l,d){if(c.length>1){if(Xc(c,l))return!0;for(let y=0;y<l.length;y++)if(Jc(l[y],c,d))return!0}for(let y=0;y<c.length;y++)if(Jc(c[y],l,d))return!0;return!1}function Xc(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(B1(y,w,l[T],l[T+1]))return!0}return!1}function B1(c,l,d,y){return nt(c,d,y)!==nt(l,d,y)&&nt(c,l,d)!==nt(c,l,y)}function Jc(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(ed(c,l[w-1],l[w])<y)return!0;return!1}function ed(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 kh(c,l){let d,y,w,T=!1;for(let K=0;K<c.length;K++){d=c[K];for(let D=0,j=d.length-1;D<d.length;j=D++)y=d[D],w=d[j],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 Hu(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 Vm(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=nt(c,l,d[0]);return T!==nt(c,l,d[1])||T!==nt(c,l,d[2])||T!==nt(c,l,d[3])}function Ih(c,l,d){const y=l.paint.get(c).value;return y.kind==="constant"?y.value:d.programConfigurations.get(l.id).getMaxValue(c)}function Th(c){return Math.sqrt(c[0]*c[0]+c[1]*c[1])}function ru(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 Ud,Rd;Nn("CircleBucket",Ld,{omit:["layers"]});var k1={get paint(){return Rd=Rd||new Jo({"circle-radius":new Tr(pt.paint_circle["circle-radius"]),"circle-color":new Tr(pt.paint_circle["circle-color"]),"circle-blur":new Tr(pt.paint_circle["circle-blur"]),"circle-opacity":new Tr(pt.paint_circle["circle-opacity"]),"circle-translate":new vr(pt.paint_circle["circle-translate"]),"circle-translate-anchor":new vr(pt.paint_circle["circle-translate-anchor"]),"circle-pitch-scale":new vr(pt.paint_circle["circle-pitch-scale"]),"circle-pitch-alignment":new vr(pt.paint_circle["circle-pitch-alignment"]),"circle-stroke-width":new Tr(pt.paint_circle["circle-stroke-width"]),"circle-stroke-color":new Tr(pt.paint_circle["circle-stroke-color"]),"circle-stroke-opacity":new Tr(pt.paint_circle["circle-stroke-opacity"])})},get layout(){return Ud=Ud||new Jo({"circle-sort-key":new Tr(pt.layout_circle["circle-sort-key"])})}},Al=1e-6,zd=typeof Float32Array<"u"?Float32Array:Array;function Zm(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 Kp(c,l,d){var y=l[0],w=l[1],T=l[2],K=l[3],D=l[4],j=l[5],Z=l[6],ne=l[7],Ae=l[8],_e=l[9],Ee=l[10],Ke=l[11],We=l[12],qe=l[13],st=l[14],Ot=l[15],ct=d[0],_t=d[1],nn=d[2],cn=d[3];return c[0]=ct*y+_t*D+nn*Ae+cn*We,c[1]=ct*w+_t*j+nn*_e+cn*qe,c[2]=ct*T+_t*Z+nn*Ee+cn*st,c[3]=ct*K+_t*ne+nn*Ke+cn*Ot,c[4]=(ct=d[4])*y+(_t=d[5])*D+(nn=d[6])*Ae+(cn=d[7])*We,c[5]=ct*w+_t*j+nn*_e+cn*qe,c[6]=ct*T+_t*Z+nn*Ee+cn*st,c[7]=ct*K+_t*ne+nn*Ke+cn*Ot,c[8]=(ct=d[8])*y+(_t=d[9])*D+(nn=d[10])*Ae+(cn=d[11])*We,c[9]=ct*w+_t*j+nn*_e+cn*qe,c[10]=ct*T+_t*Z+nn*Ee+cn*st,c[11]=ct*K+_t*ne+nn*Ke+cn*Ot,c[12]=(ct=d[12])*y+(_t=d[13])*D+(nn=d[14])*Ae+(cn=d[15])*We,c[13]=ct*w+_t*j+nn*_e+cn*qe,c[14]=ct*T+_t*Z+nn*Ee+cn*st,c[15]=ct*K+_t*ne+nn*Ke+cn*Ot,c}Math.hypot||(Math.hypot=function(){for(var c=0,l=arguments.length;l--;)c+=arguments[l]*arguments[l];return Math.sqrt(c)});var xs,Pp=Kp;function Fp(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}xs=new zd(4),zd!=Float32Array&&(xs[0]=0,xs[1]=0,xs[2]=0,xs[3]=0);class Xm extends Ia{constructor(l){super(l,k1)}createBucket(l){return new Ld(l)}queryRadius(l){const d=l;return Ih("circle-radius",this,d)+Ih("circle-stroke-width",this,d)+Th(this.paint.get("circle-translate"))}queryIntersectsFeature(l,d,y,w,T,K,D,j){const Z=ru(l,this.paint.get("circle-translate"),this.paint.get("circle-translate-anchor"),K.angle,D),ne=this.paint.get("circle-radius").evaluate(d,y)+this.paint.get("circle-stroke-width").evaluate(d,y),Ae=this.paint.get("circle-pitch-alignment")==="map",_e=Ae?Z:function(Ke,We){return Ke.map(qe=>Gi(qe,We))}(Z,j),Ee=Ae?ne*D:ne;for(const Ke of w)for(const We of Ke){const qe=Ae?We:Gi(We,j);let st=Ee;const Ot=Fp([],[We.x,We.y,0,1],j);if(this.paint.get("circle-pitch-scale")==="viewport"&&this.paint.get("circle-pitch-alignment")==="map"?st*=Ot[3]/K.cameraToCenterDistance:this.paint.get("circle-pitch-scale")==="map"&&this.paint.get("circle-pitch-alignment")==="viewport"&&(st*=K.cameraToCenterDistance/Ot[3]),Bh(_e,qe,st))return!0}return!1}}function Gi(c,l){const d=Fp([],[c.x,c.y,0,1],l);return new B(d[0]/d[3],d[1]/d[3])}class Jm extends Ld{}let e0;Nn("HeatmapBucket",Jm,{omit:["layers"]});var Kh={get paint(){return e0=e0||new Jo({"heatmap-radius":new Tr(pt.paint_heatmap["heatmap-radius"]),"heatmap-weight":new Tr(pt.paint_heatmap["heatmap-weight"]),"heatmap-intensity":new vr(pt.paint_heatmap["heatmap-intensity"]),"heatmap-color":new Vc(pt.paint_heatmap["heatmap-color"]),"heatmap-opacity":new vr(pt.paint_heatmap["heatmap-opacity"])})}};function Dp(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 I1(c,{width:l,height:d},y){if(l===c.width&&d===c.height)return;const w=Dp({},{width:l,height:d},y);t0(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 t0(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 j=0;j<w.height;j++){const Z=((d.y+j)*c.width+d.x)*T,ne=((y.y+j)*l.width+y.x)*T;for(let Ae=0;Ae<w.width*T;Ae++)D[ne+Ae]=K[Z+Ae]}return l}class La{constructor(l,d){Dp(this,l,1,d)}resize(l){I1(this,l,1)}clone(){return new La({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(l,d,y,w,T){t0(l,d,y,w,T,1)}}class cl{constructor(l,d){Dp(this,l,4,d)}resize(l){I1(this,l,4)}replace(l,d){d?this.data.set(l):this.data=l instanceof Uint8ClampedArray?new Uint8Array(l.buffer):l}clone(){return new cl({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(l,d,y,w,T){t0(l,d,y,w,T,4)}}function td(c){const l={},d=c.resolution||256,y=c.clips?c.clips.length:1,w=c.image||new cl({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,j)=>{l[c.evaluationKey]=j;const Z=c.expression.evaluate(l);w.data[K+D+0]=Math.floor(255*Z.r/Z.a),w.data[K+D+1]=Math.floor(255*Z.g/Z.a),w.data[K+D+2]=Math.floor(255*Z.b/Z.a),w.data[K+D+3]=Math.floor(255*Z.a)};if(c.clips)for(let K=0,D=0;K<y;++K,D+=4*d)for(let j=0,Z=0;j<d;j++,Z+=4){const ne=j/(d-1),{start:Ae,end:_e}=c.clips[K];T(D,Z,Ae*(1-ne)+_e*ne)}else for(let K=0,D=0;K<d;K++,D+=4)T(0,D,K/(d-1));return w}Nn("AlphaImage",La),Nn("RGBAImage",cl);class jd extends Ia{createBucket(l){return new Jm(l)}constructor(l){super(l,Kh),this._updateColorRamp()}_handleSpecialPaintPropertyUpdate(l){l==="heatmap-color"&&this._updateColorRamp()}_updateColorRamp(){this.colorRamp=td({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 gA;var T1={get paint(){return gA=gA||new Jo({"hillshade-illumination-direction":new vr(pt.paint_hillshade["hillshade-illumination-direction"]),"hillshade-illumination-anchor":new vr(pt.paint_hillshade["hillshade-illumination-anchor"]),"hillshade-exaggeration":new vr(pt.paint_hillshade["hillshade-exaggeration"]),"hillshade-shadow-color":new vr(pt.paint_hillshade["hillshade-shadow-color"]),"hillshade-highlight-color":new vr(pt.paint_hillshade["hillshade-highlight-color"]),"hillshade-accent-color":new vr(pt.paint_hillshade["hillshade-accent-color"])})}};class Su extends Ia{constructor(l){super(l,T1)}hasOffscreenPass(){return this.paint.get("hillshade-exaggeration")!==0&&this.visibility!=="none"}}const Eu=Qo([{name:"a_pos",components:2,type:"Int16"}],4),{members:Lp}=Eu;var Rf={exports:{}};function nd(c,l,d){d=d||2;var y,w,T,K,D,j,Z,ne=l&&l.length,Ae=ne?l[0]*d:c.length,_e=Ph(c,0,Ae,d,!0),Ee=[];if(!_e||_e.next===_e.prev)return Ee;if(ne&&(_e=function(We,qe,st,Ot){var ct,_t,nn,cn=[];for(ct=0,_t=qe.length;ct<_t;ct++)(nn=Ph(We,qe[ct]*Ot,ct<_t-1?qe[ct+1]*Ot:We.length,Ot,!1))===nn.next&&(nn.steiner=!0),cn.push(iv(nn));for(cn.sort(Cc),ct=0;ct<cn.length;ct++)st=K1(cn[ct],st);return st}(c,l,_e,d)),c.length>80*d){y=T=c[0],w=K=c[1];for(var Ke=d;Ke<Ae;Ke+=d)(D=c[Ke])<y&&(y=D),(j=c[Ke+1])<w&&(w=j),D>T&&(T=D),j>K&&(K=j);Z=(Z=Math.max(T-y,K-w))!==0?32767/Z:0}return rd(_e,Ee,d,y,w,Z,0),Ee}function Ph(c,l,d,y,w){var T,K;if(w===Zu(c,l,d,y)>0)for(T=l;T<d;T+=y)K=r0(T,c[T],c[T+1],K);else for(T=d-y;T>=l;T-=y)K=r0(T,c[T],c[T+1],K);return K&&Dh(K,K.next)&&(Gf(K),K=K.next),K}function iu(c,l){if(!c)return c;l||(l=c);var d,y=c;do if(d=!1,y.steiner||!Dh(y,y.next)&&Ca(y.prev,y,y.next)!==0)y=y.next;else{if(Gf(y),(y=l=y.prev)===y.next)break;d=!0}while(d||y!==l);return l}function rd(c,l,d,y,w,T,K){if(c){!K&&T&&function(ne,Ae,_e,Ee){var Ke=ne;do Ke.z===0&&(Ke.z=od(Ke.x,Ke.y,Ae,_e,Ee)),Ke.prevZ=Ke.prev,Ke.nextZ=Ke.next,Ke=Ke.next;while(Ke!==ne);Ke.prevZ.nextZ=null,Ke.prevZ=null,function(We){var qe,st,Ot,ct,_t,nn,cn,Un,Cr=1;do{for(st=We,We=null,_t=null,nn=0;st;){for(nn++,Ot=st,cn=0,qe=0;qe<Cr&&(cn++,Ot=Ot.nextZ);qe++);for(Un=Cr;cn>0||Un>0&&Ot;)cn!==0&&(Un===0||!Ot||st.z<=Ot.z)?(ct=st,st=st.nextZ,cn--):(ct=Ot,Ot=Ot.nextZ,Un--),_t?_t.nextZ=ct:We=ct,ct.prevZ=_t,_t=ct;st=Ot}_t.nextZ=null,Cr*=2}while(nn>1)}(Ke)}(c,y,w,T);for(var D,j,Z=c;c.prev!==c.next;)if(D=c.prev,j=c.next,T?jf(c,y,w,T):zf(c))l.push(D.i/d|0),l.push(c.i/d|0),l.push(j.i/d|0),Gf(c),c=j.next,Z=j.next;else if((c=j)===Z){K?K===1?rd(c=id(iu(c),l,d),l,d,y,w,T,2):K===2&&Wf(c,l,d,y,w,T):rd(iu(c),l,d,y,w,T,1);break}}}function zf(c){var l=c.prev,d=c,y=c.next;if(Ca(l,d,y)>=0)return!1;for(var w=l.x,T=d.x,K=y.x,D=l.y,j=d.y,Z=y.y,ne=w<T?w<K?w:K:T<K?T:K,Ae=D<j?D<Z?D:Z:j<Z?j:Z,_e=w>T?w>K?w:K:T>K?T:K,Ee=D>j?D>Z?D:Z:j>Z?j:Z,Ke=y.next;Ke!==l;){if(Ke.x>=ne&&Ke.x<=_e&&Ke.y>=Ae&&Ke.y<=Ee&&Fh(w,D,T,j,K,Z,Ke.x,Ke.y)&&Ca(Ke.prev,Ke,Ke.next)>=0)return!1;Ke=Ke.next}return!0}function jf(c,l,d,y){var w=c.prev,T=c,K=c.next;if(Ca(w,T,K)>=0)return!1;for(var D=w.x,j=T.x,Z=K.x,ne=w.y,Ae=T.y,_e=K.y,Ee=D<j?D<Z?D:Z:j<Z?j:Z,Ke=ne<Ae?ne<_e?ne:_e:Ae<_e?Ae:_e,We=D>j?D>Z?D:Z:j>Z?j:Z,qe=ne>Ae?ne>_e?ne:_e:Ae>_e?Ae:_e,st=od(Ee,Ke,l,d,y),Ot=od(We,qe,l,d,y),ct=c.prevZ,_t=c.nextZ;ct&&ct.z>=st&&_t&&_t.z<=Ot;){if(ct.x>=Ee&&ct.x<=We&&ct.y>=Ke&&ct.y<=qe&&ct!==w&&ct!==K&&Fh(D,ne,j,Ae,Z,_e,ct.x,ct.y)&&Ca(ct.prev,ct,ct.next)>=0||(ct=ct.prevZ,_t.x>=Ee&&_t.x<=We&&_t.y>=Ke&&_t.y<=qe&&_t!==w&&_t!==K&&Fh(D,ne,j,Ae,Z,_e,_t.x,_t.y)&&Ca(_t.prev,_t,_t.next)>=0))return!1;_t=_t.nextZ}for(;ct&&ct.z>=st;){if(ct.x>=Ee&&ct.x<=We&&ct.y>=Ke&&ct.y<=qe&&ct!==w&&ct!==K&&Fh(D,ne,j,Ae,Z,_e,ct.x,ct.y)&&Ca(ct.prev,ct,ct.next)>=0)return!1;ct=ct.prevZ}for(;_t&&_t.z<=Ot;){if(_t.x>=Ee&&_t.x<=We&&_t.y>=Ke&&_t.y<=qe&&_t!==w&&_t!==K&&Fh(D,ne,j,Ae,Z,_e,_t.x,_t.y)&&Ca(_t.prev,_t,_t.next)>=0)return!1;_t=_t.nextZ}return!0}function id(c,l,d){var y=c;do{var w=y.prev,T=y.next.next;!Dh(w,T)&&P1(w,y,y.next,T)&&Js(w,T)&&Js(T,w)&&(l.push(w.i/d|0),l.push(y.i/d|0),l.push(T.i/d|0),Gf(y),Gf(y.next),y=c=T),y=y.next}while(y!==c);return iu(y)}function Wf(c,l,d,y,w,T){var K=c;do{for(var D=K.next.next;D!==K.prev;){if(K.i!==D.i&&Nf(K,D)){var j=Vu(K,D);return K=iu(K,K.next),j=iu(j,j.next),rd(K,l,d,y,w,T,0),void rd(j,l,d,y,w,T,0)}D=D.next}K=K.next}while(K!==c)}function Cc(c,l){return c.x-l.x}function K1(c,l){var d=function(w,T){var K,D=T,j=w.x,Z=w.y,ne=-1/0;do{if(Z<=D.y&&Z>=D.next.y&&D.next.y!==D.y){var Ae=D.x+(Z-D.y)*(D.next.x-D.x)/(D.next.y-D.y);if(Ae<=j&&Ae>ne&&(ne=Ae,K=D.x<D.next.x?D:D.next,Ae===j))return K}D=D.next}while(D!==T);if(!K)return null;var _e,Ee=K,Ke=K.x,We=K.y,qe=1/0;D=K;do j>=D.x&&D.x>=Ke&&j!==D.x&&Fh(Z<We?j:ne,Z,Ke,We,Z<We?ne:j,Z,D.x,D.y)&&(_e=Math.abs(Z-D.y)/(j-D.x),Js(D,w)&&(_e<qe||_e===qe&&(D.x>K.x||D.x===K.x&&n0(K,D)))&&(K=D,qe=_e)),D=D.next;while(D!==Ee);return K}(c,l);if(!d)return l;var y=Vu(d,c);return iu(y,y.next),iu(d,d.next)}function n0(c,l){return Ca(c.prev,c,l.prev)<0&&Ca(l.next,c,c.next)<0}function od(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 iv(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 Fh(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 Nf(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&&P1(w,w.next,d,y))return!0;w=w.next}while(w!==d);return!1}(c,l)&&(Js(c,l)&&Js(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)&&(Ca(c.prev,c,l.prev)||Ca(c,l.prev,l))||Dh(c,l)&&Ca(c.prev,c,c.next)>0&&Ca(l.prev,l,l.next)>0)}function Ca(c,l,d){return(l.y-c.y)*(d.x-l.x)-(l.x-c.x)*(d.y-l.y)}function Dh(c,l){return c.x===l.x&&c.y===l.y}function P1(c,l,d,y){var w=Lh(Ca(c,l,d)),T=Lh(Ca(c,l,y)),K=Lh(Ca(d,y,c)),D=Lh(Ca(d,y,l));return w!==T&&K!==D||!(w!==0||!Wd(c,d,l))||!(T!==0||!Wd(c,y,l))||!(K!==0||!Wd(d,c,y))||!(D!==0||!Wd(d,l,y))}function Wd(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 Lh(c){return c>0?1:c<0?-1:0}function Js(c,l){return Ca(c.prev,c,c.next)<0?Ca(c,l,c.next)>=0&&Ca(c,c.prev,l)>=0:Ca(c,l,c.prev)<0||Ca(c,c.next,l)<0}function Vu(c,l){var d=new ad(c.i,c.x,c.y),y=new ad(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 r0(c,l,d,y){var w=new ad(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 Gf(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 ad(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 Zu(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}Rf.exports=nd,Rf.exports.default=nd,nd.deviation=function(c,l,d,y){var w=l&&l.length,T=Math.abs(Zu(c,0,w?l[0]*d:c.length,d));if(w)for(var K=0,D=l.length;K<D;K++)T-=Math.abs(Zu(c,l[K]*d,K<D-1?l[K+1]*d:c.length,d));var j=0;for(K=0;K<y.length;K+=3){var Z=y[K]*d,ne=y[K+1]*d,Ae=y[K+2]*d;j+=Math.abs((c[Z]-c[Ae])*(c[ne+1]-c[Z+1])-(c[Z]-c[ne])*(c[Ae+1]-c[Z+1]))}return T===0&&j===0?0:Math.abs((j-T)/T)},nd.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 Nd=h(Rf.exports);function F1(c,l,d,y,w){i0(c,l,d||0,y||c.length-1,w||Rh)}function i0(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),j=.5*Math.exp(2*D/3),Z=.5*Math.sqrt(D*j*(T-j)/T)*(K-T/2<0?-1:1);i0(c,l,Math.max(d,Math.floor(l-K*j/T+Z)),Math.min(y,Math.floor(l+(T-K)*j/T+Z)),w)}var ne=c[l],Ae=d,_e=y;for(Uh(c,d,l),w(c[y],ne)>0&&Uh(c,d,y);Ae<_e;){for(Uh(c,Ae,_e),Ae++,_e--;w(c[Ae],ne)<0;)Ae++;for(;w(c[_e],ne)>0;)_e--}w(c[d],ne)===0?Uh(c,d,_e):Uh(c,++_e,y),_e<=l&&(d=_e+1),l<=_e&&(y=_e-1)}}function Uh(c,l,d){var y=c[l];c[l]=c[d],c[d]=y}function Rh(c,l){return c<l?-1:c>l?1:0}function Gd(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=be(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||(F1(y[K],l,1,y[K].length-1,ov),y[K]=y[K].slice(0,l));return y}function ov(c,l){return l.area-c.area}function Qf(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 Up(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 j=D.evaluate({zoom:y-1},d,{},w.availableImages),Z=D.evaluate({zoom:y},d,{},w.availableImages),ne=D.evaluate({zoom:y+1},d,{},w.availableImages);j=j&&j.name?j.name:j,Z=Z&&Z.name?Z.name:Z,ne=ne&&ne.name?ne.name:ne,T[j]=!0,T[Z]=!0,T[ne]=!0,d.patterns[K.id]={min:j,mid:Z,max:ne}}}return d}class zh{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 Re,this.indexArray=new dn,this.indexArray2=new An,this.programConfigurations=new ls(l.layers,l.zoom),this.segments=new Pr,this.segments2=new Pr,this.stateDependentLayerIds=this.layers.filter(d=>d.isStateDependent()).map(d=>d.id)}populate(l,d,y){this.hasPattern=Qf("fill",this.layers,d);const w=this.layers[0].layout.get("fill-sort-key"),T=!w.isConstant(),K=[];for(const{feature:D,id:j,index:Z,sourceLayerIndex:ne}of l){const Ae=this.layers[0]._featureFilter.needGeometry,_e=WA(D,Ae);if(!this.layers[0]._featureFilter.filter(new So(this.zoom),_e,y))continue;const Ee=T?w.evaluate(_e,{},y,d.availableImages):void 0,Ke={id:j,properties:D.properties,type:D.type,sourceLayerIndex:ne,index:Z,geometry:Ae?_e.geometry:nu(D),patterns:{},sortKey:Ee};K.push(Ke)}T&&K.sort((D,j)=>D.sortKey-j.sortKey);for(const D of K){const{geometry:j,index:Z,sourceLayerIndex:ne}=D;if(this.hasPattern){const Ae=Up("fill",this.layers,D,this.zoom,d);this.patternFeatures.push(Ae)}else this.addFeature(D,j,Z,y,{});d.featureIndex.insert(l[Z].feature,j,Z,ne,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,Lp),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 Gd(d,500)){let D=0;for(const Ee of K)D+=Ee.length;const j=this.segments.prepareSegment(D,this.layoutVertexArray,this.indexArray),Z=j.vertexLength,ne=[],Ae=[];for(const Ee of K){if(Ee.length===0)continue;Ee!==K[0]&&Ae.push(ne.length/2);const Ke=this.segments2.prepareSegment(Ee.length,this.layoutVertexArray,this.indexArray2),We=Ke.vertexLength;this.layoutVertexArray.emplaceBack(Ee[0].x,Ee[0].y),this.indexArray2.emplaceBack(We+Ee.length-1,We),ne.push(Ee[0].x),ne.push(Ee[0].y);for(let qe=1;qe<Ee.length;qe++)this.layoutVertexArray.emplaceBack(Ee[qe].x,Ee[qe].y),this.indexArray2.emplaceBack(We+qe-1,We+qe),ne.push(Ee[qe].x),ne.push(Ee[qe].y);Ke.vertexLength+=Ee.length,Ke.primitiveLength+=Ee.length}const _e=Nd(ne,Ae);for(let Ee=0;Ee<_e.length;Ee+=3)this.indexArray.emplaceBack(Z+_e[Ee],Z+_e[Ee+1],Z+_e[Ee+2]);j.vertexLength+=D,j.primitiveLength+=_e.length/3}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,l,y,T,w)}}let Rp,Qd;Nn("FillBucket",zh,{omit:["layers","patternFeatures"]});var zp={get paint(){return Qd=Qd||new Jo({"fill-antialias":new vr(pt.paint_fill["fill-antialias"]),"fill-opacity":new Tr(pt.paint_fill["fill-opacity"]),"fill-color":new Tr(pt.paint_fill["fill-color"]),"fill-outline-color":new Tr(pt.paint_fill["fill-outline-color"]),"fill-translate":new vr(pt.paint_fill["fill-translate"]),"fill-translate-anchor":new vr(pt.paint_fill["fill-translate-anchor"]),"fill-pattern":new RA(pt.paint_fill["fill-pattern"])})},get layout(){return Rp=Rp||new Jo({"fill-sort-key":new Tr(pt.layout_fill["fill-sort-key"])})}};class jp extends Ia{constructor(l){super(l,zp)}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 zh(l)}queryRadius(){return Th(this.paint.get("fill-translate"))}queryIntersectsFeature(l,d,y,w,T,K,D){return qu(ru(l,this.paint.get("fill-translate"),this.paint.get("fill-translate-anchor"),K.angle,D),w)}isTileClipped(){return!0}}const D1=Qo([{name:"a_pos",components:2,type:"Int16"},{name:"a_normal_ed",components:4,type:"Int16"}],4),$d=Qo([{name:"a_centroid",components:2,type:"Int16"}],4),{members:$f}=D1;var Xu={},o0=g,L1=Yd;function Yd(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(Co,this,l)}function Co(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 U1(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}Yd.types=["Unknown","Point","LineString","Polygon"],Yd.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 j=c.readVarint();y=7&j,w=j>>3}if(w--,y===1||y===2)T+=c.readSVarint(),K+=c.readSVarint(),y===1&&(l&&D.push(l),l=[]),l.push(new o0(T,K));else{if(y!==7)throw new Error("unknown command "+y);l&&l.push(l[0].clone())}}return l&&D.push(l),D},Yd.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,j=1/0,Z=-1/0;c.pos<l;){if(y<=0){var ne=c.readVarint();d=7&ne,y=ne>>3}if(y--,d===1||d===2)(w+=c.readSVarint())<K&&(K=w),w>D&&(D=w),(T+=c.readSVarint())<j&&(j=T),T>Z&&(Z=T);else if(d!==7)throw new Error("unknown command "+d)}return[K,j,D,Z]},Yd.prototype.toGeoJSON=function(c,l,d){var y,w,T=this.extent*Math.pow(2,d),K=this.extent*c,D=this.extent*l,j=this.loadGeometry(),Z=Yd.types[this.type];function ne(Ee){for(var Ke=0;Ke<Ee.length;Ke++){var We=Ee[Ke];Ee[Ke]=[360*(We.x+K)/T-180,360/Math.PI*Math.atan(Math.exp((180-360*(We.y+D)/T)*Math.PI/180))-90]}}switch(this.type){case 1:var Ae=[];for(y=0;y<j.length;y++)Ae[y]=j[y][0];ne(j=Ae);break;case 2:for(y=0;y<j.length;y++)ne(j[y]);break;case 3:for(j=function(Ee){var Ke=Ee.length;if(Ke<=1)return[Ee];for(var We,qe,st=[],Ot=0;Ot<Ke;Ot++){var ct=U1(Ee[Ot]);ct!==0&&(qe===void 0&&(qe=ct<0),qe===ct<0?(We&&st.push(We),We=[Ee[Ot]]):We.push(Ee[Ot]))}return We&&st.push(We),st}(j),y=0;y<j.length;y++)for(w=0;w<j[y].length;w++)ne(j[y][w])}j.length===1?j=j[0]:Z="Multi"+Z;var _e={type:"Feature",geometry:{type:Z,coordinates:j},properties:this.properties};return"id"in this&&(_e.id=this.id),_e};var Wp=L1,jh=Ou;function Ou(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(Np,this,l),this.length=this._features.length}function Np(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))}Ou.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 Wp(this._pbf,l,this.extent,this._keys,this._values)};var a0=jh;function NA(c,l,d){if(c===3){var y=new a0(d,d.readVarint()+d.pos);y.length&&(l[y.name]=y)}}Xu.VectorTile=function(c,l){this.layers=c.readFields(NA,{},l)},Xu.VectorTileFeature=L1,Xu.VectorTileLayer=jh;const Gp=Xu.VectorTileFeature.types,Wh=Math.pow(2,13);function bc(c,l,d,y,w,T,K,D){c.emplaceBack(l,d,2*Math.floor(y*Wh)+K,w*Wh*2,T*Wh*2,Math.round(D))}class qd{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 $e,this.centroidVertexArray=new Ie,this.indexArray=new dn,this.programConfigurations=new ls(l.layers,l.zoom),this.segments=new Pr,this.stateDependentLayerIds=this.layers.filter(d=>d.isStateDependent()).map(d=>d.id)}populate(l,d,y){this.features=[],this.hasPattern=Qf("fill-extrusion",this.layers,d);for(const{feature:w,id:T,index:K,sourceLayerIndex:D}of l){const j=this.layers[0]._featureFilter.needGeometry,Z=WA(w,j);if(!this.layers[0]._featureFilter.filter(new So(this.zoom),Z,y))continue;const ne={id:T,sourceLayerIndex:D,index:K,geometry:j?Z.geometry:nu(w),properties:w.properties,type:w.type,patterns:{}};this.hasPattern?this.features.push(Up("fill-extrusion",this.layers,ne,this.zoom,d)):this.addFeature(ne,ne.geometry,K,y,{}),d.featureIndex.insert(w,ne.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,$f),this.centroidVertexBuffer=l.createVertexBuffer(this.centroidVertexArray,$d.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 Gd(d,500)){let j=0;for(const Ke of D)j+=Ke.length;let Z=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray);for(const Ke of D){if(Ke.length===0||Zr(Ke))continue;let We=0;for(let qe=0;qe<Ke.length;qe++){const st=Ke[qe];if(qe>=1){const Ot=Ke[qe-1];if(!Nh(st,Ot)){Z.vertexLength+4>Pr.MAX_VERTEX_ARRAY_LENGTH&&(Z=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray));const ct=st.sub(Ot)._perp()._unit(),_t=Ot.dist(st);We+_t>32768&&(We=0),bc(this.layoutVertexArray,st.x,st.y,ct.x,ct.y,0,0,We),bc(this.layoutVertexArray,st.x,st.y,ct.x,ct.y,0,1,We),K.x+=2*st.x,K.y+=2*st.y,K.vertexCount+=2,We+=_t,bc(this.layoutVertexArray,Ot.x,Ot.y,ct.x,ct.y,0,0,We),bc(this.layoutVertexArray,Ot.x,Ot.y,ct.x,ct.y,0,1,We),K.x+=2*Ot.x,K.y+=2*Ot.y,K.vertexCount+=2;const nn=Z.vertexLength;this.indexArray.emplaceBack(nn,nn+2,nn+1),this.indexArray.emplaceBack(nn+1,nn+2,nn+3),Z.vertexLength+=4,Z.primitiveLength+=2}}}}if(Z.vertexLength+j>Pr.MAX_VERTEX_ARRAY_LENGTH&&(Z=this.segments.prepareSegment(j,this.layoutVertexArray,this.indexArray)),Gp[l.type]!=="Polygon")continue;const ne=[],Ae=[],_e=Z.vertexLength;for(const Ke of D)if(Ke.length!==0){Ke!==D[0]&&Ae.push(ne.length/2);for(let We=0;We<Ke.length;We++){const qe=Ke[We];bc(this.layoutVertexArray,qe.x,qe.y,0,0,1,1,0),K.x+=qe.x,K.y+=qe.y,K.vertexCount+=1,ne.push(qe.x),ne.push(qe.y)}}const Ee=Nd(ne,Ae);for(let Ke=0;Ke<Ee.length;Ke+=3)this.indexArray.emplaceBack(_e+Ee[Ke],_e+Ee[Ke+2],_e+Ee[Ke+1]);Z.primitiveLength+=Ee.length/3,Z.vertexLength+=j}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 Nh(c,l){return c.x===l.x&&(c.x<0||c.x>_a)||c.y===l.y&&(c.y<0||c.y>_a)}function Zr(c){return c.every(l=>l.x<0)||c.every(l=>l.x>_a)||c.every(l=>l.y<0)||c.every(l=>l.y>_a)}let Gh;Nn("FillExtrusionBucket",qd,{omit:["layers","features"]});var Oo={get paint(){return Gh=Gh||new Jo({"fill-extrusion-opacity":new vr(pt["paint_fill-extrusion"]["fill-extrusion-opacity"]),"fill-extrusion-color":new Tr(pt["paint_fill-extrusion"]["fill-extrusion-color"]),"fill-extrusion-translate":new vr(pt["paint_fill-extrusion"]["fill-extrusion-translate"]),"fill-extrusion-translate-anchor":new vr(pt["paint_fill-extrusion"]["fill-extrusion-translate-anchor"]),"fill-extrusion-pattern":new RA(pt["paint_fill-extrusion"]["fill-extrusion-pattern"]),"fill-extrusion-height":new Tr(pt["paint_fill-extrusion"]["fill-extrusion-height"]),"fill-extrusion-base":new Tr(pt["paint_fill-extrusion"]["fill-extrusion-base"]),"fill-extrusion-vertical-gradient":new vr(pt["paint_fill-extrusion"]["fill-extrusion-vertical-gradient"])})}};class sd extends Ia{constructor(l){super(l,Oo)}createBucket(l){return new qd(l)}queryRadius(){return Th(this.paint.get("fill-extrusion-translate"))}is3D(){return!0}queryIntersectsFeature(l,d,y,w,T,K,D,j){const Z=ru(l,this.paint.get("fill-extrusion-translate"),this.paint.get("fill-extrusion-translate-anchor"),K.angle,D),ne=this.paint.get("fill-extrusion-height").evaluate(d,y),Ae=this.paint.get("fill-extrusion-base").evaluate(d,y),_e=function(Ke,We,qe,st){const Ot=[];for(const ct of Ke){const _t=[ct.x,ct.y,0,1];Fp(_t,_t,We),Ot.push(new B(_t[0]/_t[3],_t[1]/_t[3]))}return Ot}(Z,j),Ee=function(Ke,We,qe,st){const Ot=[],ct=[],_t=st[8]*We,nn=st[9]*We,cn=st[10]*We,Un=st[11]*We,Cr=st[8]*qe,qn=st[9]*qe,wn=st[10]*qe,gn=st[11]*qe;for(const lr of Ke){const Rn=[],On=[];for(const Fr of lr){const wr=Fr.x,Fi=Fr.y,da=st[0]*wr+st[4]*Fi+st[12],ha=st[1]*wr+st[5]*Fi+st[13],Ra=st[2]*wr+st[6]*Fi+st[14],ou=st[3]*wr+st[7]*Fi+st[15],au=Ra+cn,ds=ou+Un,Ss=da+Cr,Vo=ha+qn,Ns=Ra+wn,su=ou+gn,Gs=new B((da+_t)/ds,(ha+nn)/ds);Gs.z=au/ds,Rn.push(Gs);const Qs=new B(Ss/su,Vo/su);Qs.z=Ns/su,On.push(Qs)}Ot.push(Rn),ct.push(On)}return[Ot,ct]}(w,Ae,ne,j);return function(Ke,We,qe){let st=1/0;qu(qe,We)&&(st=xc(qe,We[0]));for(let Ot=0;Ot<We.length;Ot++){const ct=We[Ot],_t=Ke[Ot];for(let nn=0;nn<ct.length-1;nn++){const cn=ct[nn],Un=[cn,ct[nn+1],_t[nn+1],_t[nn],cn];_c(qe,Un)&&(st=Math.min(st,xc(qe,Un)))}}return st!==1/0&&st}(Ee[0],Ee[1],_e)}}function Yf(c,l){return c.x*l.x+c.y*l.y}function xc(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),j=T.sub(y),Z=K.sub(y),ne=Yf(D,D),Ae=Yf(D,j),_e=Yf(j,j),Ee=Yf(Z,D),Ke=Yf(Z,j),We=ne*_e-Ae*Ae,qe=(_e*Ee-Ae*Ke)/We,st=(ne*Ke-Ae*Ee)/We,Ot=y.z*(1-qe-st)+w.z*qe+T.z*st;if(isFinite(Ot))return Ot}return 1/0}{let d=1/0;for(const y of l)d=Math.min(d,y.z);return d}}const R1=Qo([{name:"a_pos_normal",components:2,type:"Int16"},{name:"a_data",components:4,type:"Uint8"}],4),{members:Rs}=R1,av=Qo([{name:"a_uv_x",components:1,type:"Float32"},{name:"a_split_index",components:1,type:"Float32"}]),{members:Ya}=av,z1=Xu.VectorTileFeature.types,sv=Math.cos(Math.PI/180*37.5),s0=Math.pow(2,14)/.5;class Qh{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 Ge,this.layoutVertexArray2=new ht,this.indexArray=new dn,this.programConfigurations=new ls(l.layers,l.zoom),this.segments=new Pr,this.maxLineLength=0,this.stateDependentLayerIds=this.layers.filter(d=>d.isStateDependent()).map(d=>d.id)}populate(l,d,y){this.hasPattern=Qf("line",this.layers,d);const w=this.layers[0].layout.get("line-sort-key"),T=!w.isConstant(),K=[];for(const{feature:D,id:j,index:Z,sourceLayerIndex:ne}of l){const Ae=this.layers[0]._featureFilter.needGeometry,_e=WA(D,Ae);if(!this.layers[0]._featureFilter.filter(new So(this.zoom),_e,y))continue;const Ee=T?w.evaluate(_e,{},y):void 0,Ke={id:j,properties:D.properties,type:D.type,sourceLayerIndex:ne,index:Z,geometry:Ae?_e.geometry:nu(D),patterns:{},sortKey:Ee};K.push(Ke)}T&&K.sort((D,j)=>D.sortKey-j.sortKey);for(const D of K){const{geometry:j,index:Z,sourceLayerIndex:ne}=D;if(this.hasPattern){const Ae=Up("line",this.layers,D,this.zoom,d);this.patternFeatures.push(Ae)}else this.addFeature(D,j,Z,y,{});d.featureIndex.insert(l[Z].feature,j,Z,ne,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,Ya)),this.layoutVertexBuffer=l.createVertexBuffer(this.layoutVertexArray,Rs),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,{}),j=K.get("line-cap"),Z=K.get("line-miter-limit"),ne=K.get("line-round-limit");this.lineClips=this.lineFeatureClips(l);for(const Ae of d)this.addLine(Ae,l,D,j,Z,ne);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 st=0;st<l.length-1;st++)this.totalDistance+=l[st].dist(l[st+1]);this.updateScaledDistance(),this.maxLineLength=Math.max(this.maxLineLength,this.totalDistance)}const D=z1[d.type]==="Polygon";let j=l.length;for(;j>=2&&l[j-1].equals(l[j-2]);)j--;let Z=0;for(;Z<j-1&&l[Z].equals(l[Z+1]);)Z++;if(j<(D?3:2))return;y==="bevel"&&(T=1.05);const ne=this.overscaling<=16?15*_a/(512*this.overscaling):0,Ae=this.segments.prepareSegment(10*j,this.layoutVertexArray,this.indexArray);let _e,Ee,Ke,We,qe;this.e1=this.e2=-1,D&&(_e=l[j-2],qe=l[Z].sub(_e)._unit()._perp());for(let st=Z;st<j;st++){if(Ke=st===j-1?D?l[Z+1]:void 0:l[st+1],Ke&&l[st].equals(Ke))continue;qe&&(We=qe),_e&&(Ee=_e),_e=l[st],qe=Ke?Ke.sub(_e)._unit()._perp():We,We=We||qe;let Ot=We.add(qe);Ot.x===0&&Ot.y===0||Ot._unit();const ct=We.x*qe.x+We.y*qe.y,_t=Ot.x*qe.x+Ot.y*qe.y,nn=_t!==0?1/_t:1/0,cn=2*Math.sqrt(2-2*_t),Un=_t<sv&&Ee&&Ke,Cr=We.x*qe.y-We.y*qe.x>0;if(Un&&st>Z){const gn=_e.dist(Ee);if(gn>2*ne){const lr=_e.sub(_e.sub(Ee)._mult(ne/gn)._round());this.updateDistance(Ee,lr),this.addCurrentVertex(lr,We,0,0,Ae),Ee=lr}}const qn=Ee&&Ke;let wn=qn?y:D?"butt":w;if(qn&&wn==="round"&&(nn<K?wn="miter":nn<=2&&(wn="fakeround")),wn==="miter"&&nn>T&&(wn="bevel"),wn==="bevel"&&(nn>2&&(wn="flipbevel"),nn<T&&(wn="miter")),Ee&&this.updateDistance(Ee,_e),wn==="miter")Ot._mult(nn),this.addCurrentVertex(_e,Ot,0,0,Ae);else if(wn==="flipbevel"){if(nn>100)Ot=qe.mult(-1);else{const gn=nn*We.add(qe).mag()/We.sub(qe).mag();Ot._perp()._mult(gn*(Cr?-1:1))}this.addCurrentVertex(_e,Ot,0,0,Ae),this.addCurrentVertex(_e,Ot.mult(-1),0,0,Ae)}else if(wn==="bevel"||wn==="fakeround"){const gn=-Math.sqrt(nn*nn-1),lr=Cr?gn:0,Rn=Cr?0:gn;if(Ee&&this.addCurrentVertex(_e,We,lr,Rn,Ae),wn==="fakeround"){const On=Math.round(180*cn/Math.PI/20);for(let Fr=1;Fr<On;Fr++){let wr=Fr/On;if(wr!==.5){const da=wr-.5;wr+=wr*da*(wr-1)*((1.0904+ct*(ct*(3.55645-1.43519*ct)-3.2452))*da*da+(.848013+ct*(.215638*ct-1.06021)))}const Fi=qe.sub(We)._mult(wr)._add(We)._unit()._mult(Cr?-1:1);this.addHalfVertex(_e,Fi.x,Fi.y,!1,Cr,0,Ae)}}Ke&&this.addCurrentVertex(_e,qe,-lr,-Rn,Ae)}else if(wn==="butt")this.addCurrentVertex(_e,Ot,0,0,Ae);else if(wn==="square"){const gn=Ee?1:-1;this.addCurrentVertex(_e,Ot,gn,gn,Ae)}else wn==="round"&&(Ee&&(this.addCurrentVertex(_e,We,0,0,Ae),this.addCurrentVertex(_e,We,1,1,Ae,!0)),Ke&&(this.addCurrentVertex(_e,qe,-1,-1,Ae,!0),this.addCurrentVertex(_e,qe,0,0,Ae)));if(Un&&st<j-1){const gn=_e.dist(Ke);if(gn>2*ne){const lr=_e.add(Ke.sub(_e)._mult(ne/gn)._round());this.updateDistance(_e,lr),this.addCurrentVertex(lr,qe,0,0,Ae),_e=lr}}}}addCurrentVertex(l,d,y,w,T,K=!1){const D=d.y*w-d.x,j=-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,j,K,!0,-w,T),this.distance>s0/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,j){const Z=.5*(this.lineClips?this.scaledDistance*(s0-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&Z)<<2,Z>>6),this.lineClips&&this.layoutVertexArray2.emplaceBack((this.scaledDistance-this.lineClips.start)/(this.lineClips.end-this.lineClips.start),this.lineClipsArray.length);const ne=j.vertexLength++;this.e1>=0&&this.e2>=0&&(this.indexArray.emplaceBack(this.e1,this.e2,ne),j.primitiveLength++),K?this.e2=ne:this.e1=ne}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 A,f;Nn("LineBucket",Qh,{omit:["layers","patternFeatures"]});var x={get paint(){return f=f||new Jo({"line-opacity":new Tr(pt.paint_line["line-opacity"]),"line-color":new Tr(pt.paint_line["line-color"]),"line-translate":new vr(pt.paint_line["line-translate"]),"line-translate-anchor":new vr(pt.paint_line["line-translate-anchor"]),"line-width":new Tr(pt.paint_line["line-width"]),"line-gap-width":new Tr(pt.paint_line["line-gap-width"]),"line-offset":new Tr(pt.paint_line["line-offset"]),"line-blur":new Tr(pt.paint_line["line-blur"]),"line-dasharray":new pc(pt.paint_line["line-dasharray"]),"line-pattern":new RA(pt.paint_line["line-pattern"]),"line-gradient":new Vc(pt.paint_line["line-gradient"])})},get layout(){return A=A||new Jo({"line-cap":new vr(pt.layout_line["line-cap"]),"line-join":new Tr(pt.layout_line["line-join"]),"line-miter-limit":new vr(pt.layout_line["line-miter-limit"]),"line-round-limit":new vr(pt.layout_line["line-round-limit"]),"line-sort-key":new Tr(pt.layout_line["line-sort-key"])})}};class b extends Tr{possiblyEvaluate(l,d){return d=new So(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=V({},d,{zoom:Math.floor(d.zoom)}),super.evaluate(l,d,y,w)}}let E;class U extends Ia{constructor(l){super(l,x),this.gradientVersion=0,E||(E=new b(x.paint.properties["line-width"].specification),E.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 Cl,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"]=E.possiblyEvaluate(this._transitioningPaint._values["line-width"].value,l)}createBucket(l){return new Qh(l)}queryRadius(l){const d=l,y=Y(Ih("line-width",this,d),Ih("line-gap-width",this,d)),w=Ih("line-offset",this,d);return y/2+Math.abs(w)+Th(this.paint.get("line-translate"))}queryIntersectsFeature(l,d,y,w,T,K,D){const j=ru(l,this.paint.get("line-translate"),this.paint.get("line-translate-anchor"),K.angle,D),Z=D/2*Y(this.paint.get("line-width").evaluate(d,y),this.paint.get("line-gap-width").evaluate(d,y)),ne=this.paint.get("line-offset").evaluate(d,y);return ne&&(w=function(Ae,_e){const Ee=[];for(let Ke=0;Ke<Ae.length;Ke++){const We=Ae[Ke],qe=[];for(let st=0;st<We.length;st++){const Ot=We[st-1],ct=We[st],_t=We[st+1],nn=st===0?new B(0,0):ct.sub(Ot)._unit()._perp(),cn=st===We.length-1?new B(0,0):_t.sub(ct)._unit()._perp(),Un=nn._add(cn)._unit(),Cr=Un.x*cn.x+Un.y*cn.y;Cr!==0&&Un._mult(1/Cr),qe.push(Un._mult(_e)._add(ct))}Ee.push(qe)}return Ee}(w,ne*D)),function(Ae,_e,Ee){for(let Ke=0;Ke<_e.length;Ke++){const We=_e[Ke];if(Ae.length>=3){for(let qe=0;qe<We.length;qe++)if(Hu(Ae,We[qe]))return!0}if(Uf(Ae,We,Ee))return!0}return!1}(j,w,Z)}isTileClipped(){return!0}}function Y(c,l){return l>0?l+2*c:c}const te=Qo([{name:"a_pos_offset",components:4,type:"Int16"},{name:"a_data",components:4,type:"Uint16"},{name:"a_pixeloffset",components:4,type:"Int16"}],4),le=Qo([{name:"a_projected_pos",components:3,type:"Float32"}],4);Qo([{name:"a_fade_opacity",components:1,type:"Uint32"}],4);const ge=Qo([{name:"a_placed",components:2,type:"Uint8"},{name:"a_shift",components:2,type:"Float32"}]);Qo([{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 Qe=Qo([{name:"a_pos",components:2,type:"Int16"},{name:"a_anchor_pos",components:2,type:"Int16"},{name:"a_extrude",components:2,type:"Int16"}],4),Je=Qo([{name:"a_pos",components:2,type:"Float32"},{name:"a_radius",components:1,type:"Float32"},{name:"a_flags",components:2,type:"Int16"}],4);function Mt(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()),Gu.applyArabicShaping&&(w=Gu.applyArabicShaping(w)),w}(y.text,l,d)}),c}Qo([{name:"triangle",components:3,type:"Uint16"}]),Qo([{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"}]),Qo([{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"}]),Qo([{type:"Float32",name:"offsetX"}]),Qo([{type:"Int16",name:"x"},{type:"Int16",name:"y"},{type:"Int16",name:"tileUnitDistanceFromAnchor"}]),Qo([{type:"Uint16",name:"textAnchor"},{type:"Float32",components:2,name:"textOffset"}]);const yt={"!":"︕","#":"",$:"","%":"","&":"","(":"︵",")":"︶","*":"","+":"",",":"︐","-":"︲",".":"・","/":"",":":"︓",";":"︔","<":"︿","=":"",">":"﹀","?":"︖","@":"","[":"﹇","\\":"","]":"﹈","^":"",_:"︳","`":"","{":"︷","|":"―","}":"︸","~":"","¢":"¢","£":"£","¥":"¥","¦":"¦","¬":"¬","¯":" ̄","":"︲","—":"︱","":"﹃","":"﹄","“":"﹁","”":"﹂","…":"︙","‧":"・","₩":"₩","、":"︑","。":"︒","〈":"︿","〉":"﹀","《":"︽","》":"︾","「":"﹁","」":"﹂","『":"﹃","』":"﹄","【":"︻","】":"︼","":"︹","":"︺","〖":"︗","〗":"︘","":"︕","":"︵","":"︶","":"︐","":"︲","":"・","":"︓","":"︔","":"︿","":"﹀","":"︖","":"﹇","":"﹈","_":"︳","":"︷","":"―","":"︸","⦅":"︵","⦆":"︶","。":"︒","「":"﹁","」":"﹂"};var zt=24,hn=xn,kn=function(c,l,d,y,w){var T,K,D=8*w-y-1,j=(1<<D)-1,Z=j>>1,ne=-7,Ae=d?w-1:0,_e=d?-1:1,Ee=c[l+Ae];for(Ae+=_e,T=Ee&(1<<-ne)-1,Ee>>=-ne,ne+=D;ne>0;T=256*T+c[l+Ae],Ae+=_e,ne-=8);for(K=T&(1<<-ne)-1,T>>=-ne,ne+=y;ne>0;K=256*K+c[l+Ae],Ae+=_e,ne-=8);if(T===0)T=1-Z;else{if(T===j)return K?NaN:1/0*(Ee?-1:1);K+=Math.pow(2,y),T-=Z}return(Ee?-1:1)*K*Math.pow(2,T-y)},Yn=function(c,l,d,y,w,T){var K,D,j,Z=8*T-w-1,ne=(1<<Z)-1,Ae=ne>>1,_e=w===23?Math.pow(2,-24)-Math.pow(2,-77):0,Ee=y?0:T-1,Ke=y?1:-1,We=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=ne):(K=Math.floor(Math.log(l)/Math.LN2),l*(j=Math.pow(2,-K))<1&&(K--,j*=2),(l+=K+Ae>=1?_e/j:_e*Math.pow(2,1-Ae))*j>=2&&(K++,j/=2),K+Ae>=ne?(D=0,K=ne):K+Ae>=1?(D=(l*j-1)*Math.pow(2,w),K+=Ae):(D=l*Math.pow(2,Ae-1)*Math.pow(2,w),K=0));w>=8;c[d+Ee]=255&D,Ee+=Ke,D/=256,w-=8);for(K=K<<w|D,Z+=w;Z>0;c[d+Ee]=255&K,Ee+=Ke,K/=256,Z-=8);c[d+Ee-Ke]|=128*We};function xn(c){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(c)?c:new Uint8Array(c||0),this.pos=0,this.type=0,this.length=this.buf.length}xn.Varint=0,xn.Fixed64=1,xn.Bytes=2,xn.Fixed32=5;var Ln=4294967296,sr=1/Ln,Kr=typeof TextDecoder>"u"?null:new TextDecoder("utf8");function _r(c){return c.type===xn.Bytes?c.readVarint()+c.pos:c.pos+1}function Ai(c,l,d){return d?4294967296*l+(c>>>0):4294967296*(l>>>0)+(c>>>0)}function Uo(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 qa(c,l){for(var d=0;d<c.length;d++)l.writeVarint(c[d])}function ba(c,l){for(var d=0;d<c.length;d++)l.writeSVarint(c[d])}function Ua(c,l){for(var d=0;d<c.length;d++)l.writeFloat(c[d])}function us(c,l){for(var d=0;d<c.length;d++)l.writeDouble(c[d])}function As(c,l){for(var d=0;d<c.length;d++)l.writeBoolean(c[d])}function Ol(c,l){for(var d=0;d<c.length;d++)l.writeFixed32(c[d])}function el(c,l){for(var d=0;d<c.length;d++)l.writeSFixed32(c[d])}function ws(c,l){for(var d=0;d<c.length;d++)l.writeFixed64(c[d])}function cs(c,l){for(var d=0;d<c.length;d++)l.writeSFixed64(c[d])}function ca(c,l){return(c[l]|c[l+1]<<8|c[l+2]<<16)+16777216*c[l+3]}function Ms(c,l,d){c[d]=l,c[d+1]=l>>>8,c[d+2]=l>>>16,c[d+3]=l>>>24}function Hd(c,l){return(c[l]|c[l+1]<<8|c[l+2]<<16)+(c[l+3]<<24)}xn.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=ca(this.buf,this.pos);return this.pos+=4,c},readSFixed32:function(){var c=Hd(this.buf,this.pos);return this.pos+=4,c},readFixed64:function(){var c=ca(this.buf,this.pos)+ca(this.buf,this.pos+4)*Ln;return this.pos+=8,c},readSFixed64:function(){var c=ca(this.buf,this.pos)+Hd(this.buf,this.pos+4)*Ln;return this.pos+=8,c},readFloat:function(){var c=kn(this.buf,this.pos,!0,23,4);return this.pos+=4,c},readDouble:function(){var c=kn(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,j,Z=K.buf;if(D=(112&(j=Z[K.pos++]))>>4,j<128||(D|=(127&(j=Z[K.pos++]))<<3,j<128)||(D|=(127&(j=Z[K.pos++]))<<10,j<128)||(D|=(127&(j=Z[K.pos++]))<<17,j<128)||(D|=(127&(j=Z[K.pos++]))<<24,j<128)||(D|=(1&(j=Z[K.pos++]))<<31,j<128))return Ai(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&&Kr?function(d,y,w){return Kr.decode(d.subarray(y,w))}(this.buf,l,c):function(d,y,w){for(var T="",K=y;K<w;){var D,j,Z,ne=d[K],Ae=null,_e=ne>239?4:ne>223?3:ne>191?2:1;if(K+_e>w)break;_e===1?ne<128&&(Ae=ne):_e===2?(192&(D=d[K+1]))==128&&(Ae=(31&ne)<<6|63&D)<=127&&(Ae=null):_e===3?(j=d[K+2],(192&(D=d[K+1]))==128&&(192&j)==128&&((Ae=(15&ne)<<12|(63&D)<<6|63&j)<=2047||Ae>=55296&&Ae<=57343)&&(Ae=null)):_e===4&&(j=d[K+2],Z=d[K+3],(192&(D=d[K+1]))==128&&(192&j)==128&&(192&Z)==128&&((Ae=(15&ne)<<18|(63&D)<<12|(63&j)<<6|63&Z)<=65535||Ae>=1114112)&&(Ae=null)),Ae===null?(Ae=65533,_e=1):Ae>65535&&(Ae-=65536,T+=String.fromCharCode(Ae>>>10&1023|55296),Ae=56320|1023&Ae),T+=String.fromCharCode(Ae),K+=_e}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!==xn.Bytes)return c.push(this.readVarint(l));var d=_r(this);for(c=c||[];this.pos<d;)c.push(this.readVarint(l));return c},readPackedSVarint:function(c){if(this.type!==xn.Bytes)return c.push(this.readSVarint());var l=_r(this);for(c=c||[];this.pos<l;)c.push(this.readSVarint());return c},readPackedBoolean:function(c){if(this.type!==xn.Bytes)return c.push(this.readBoolean());var l=_r(this);for(c=c||[];this.pos<l;)c.push(this.readBoolean());return c},readPackedFloat:function(c){if(this.type!==xn.Bytes)return c.push(this.readFloat());var l=_r(this);for(c=c||[];this.pos<l;)c.push(this.readFloat());return c},readPackedDouble:function(c){if(this.type!==xn.Bytes)return c.push(this.readDouble());var l=_r(this);for(c=c||[];this.pos<l;)c.push(this.readDouble());return c},readPackedFixed32:function(c){if(this.type!==xn.Bytes)return c.push(this.readFixed32());var l=_r(this);for(c=c||[];this.pos<l;)c.push(this.readFixed32());return c},readPackedSFixed32:function(c){if(this.type!==xn.Bytes)return c.push(this.readSFixed32());var l=_r(this);for(c=c||[];this.pos<l;)c.push(this.readSFixed32());return c},readPackedFixed64:function(c){if(this.type!==xn.Bytes)return c.push(this.readFixed64());var l=_r(this);for(c=c||[];this.pos<l;)c.push(this.readFixed64());return c},readPackedSFixed64:function(c){if(this.type!==xn.Bytes)return c.push(this.readSFixed64());var l=_r(this);for(c=c||[];this.pos<l;)c.push(this.readSFixed64());return c},skip:function(c){var l=7&c;if(l===xn.Varint)for(;this.buf[this.pos++]>127;);else if(l===xn.Bytes)this.pos=this.readVarint()+this.pos;else if(l===xn.Fixed32)this.pos+=4;else{if(l!==xn.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),Ms(this.buf,c,this.pos),this.pos+=4},writeSFixed32:function(c){this.realloc(4),Ms(this.buf,c,this.pos),this.pos+=4},writeFixed64:function(c){this.realloc(8),Ms(this.buf,-1&c,this.pos),Ms(this.buf,Math.floor(c*sr),this.pos+4),this.pos+=8},writeSFixed64:function(c){this.realloc(8),Ms(this.buf,-1&c,this.pos),Ms(this.buf,Math.floor(c*sr),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,j=0;j<w.length;j++){if((K=w.charCodeAt(j))>55295&&K<57344){if(!D){K>56319||j+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&&Uo(l,d,this),this.pos=l-1,this.writeVarint(d),this.pos+=d},writeFloat:function(c){this.realloc(4),Yn(this.buf,c,this.pos,!0,23,4),this.pos+=4},writeDouble:function(c){this.realloc(8),Yn(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&&Uo(d,y,this),this.pos=d-1,this.writeVarint(y),this.pos+=y},writeMessage:function(c,l,d){this.writeTag(c,xn.Bytes),this.writeRawMessage(l,d)},writePackedVarint:function(c,l){l.length&&this.writeMessage(c,qa,l)},writePackedSVarint:function(c,l){l.length&&this.writeMessage(c,ba,l)},writePackedBoolean:function(c,l){l.length&&this.writeMessage(c,As,l)},writePackedFloat:function(c,l){l.length&&this.writeMessage(c,Ua,l)},writePackedDouble:function(c,l){l.length&&this.writeMessage(c,us,l)},writePackedFixed32:function(c,l){l.length&&this.writeMessage(c,Ol,l)},writePackedSFixed32:function(c,l){l.length&&this.writeMessage(c,el,l)},writePackedFixed64:function(c,l){l.length&&this.writeMessage(c,ws,l)},writePackedSFixed64:function(c,l){l.length&&this.writeMessage(c,cs,l)},writeBytesField:function(c,l){this.writeTag(c,xn.Bytes),this.writeBytes(l)},writeFixed32Field:function(c,l){this.writeTag(c,xn.Fixed32),this.writeFixed32(l)},writeSFixed32Field:function(c,l){this.writeTag(c,xn.Fixed32),this.writeSFixed32(l)},writeFixed64Field:function(c,l){this.writeTag(c,xn.Fixed64),this.writeFixed64(l)},writeSFixed64Field:function(c,l){this.writeTag(c,xn.Fixed64),this.writeSFixed64(l)},writeVarintField:function(c,l){this.writeTag(c,xn.Varint),this.writeVarint(l)},writeSVarintField:function(c,l){this.writeTag(c,xn.Varint),this.writeSVarint(l)},writeStringField:function(c,l){this.writeTag(c,xn.Bytes),this.writeString(l)},writeFloatField:function(c,l){this.writeTag(c,xn.Fixed32),this.writeFloat(l)},writeDoubleField:function(c,l){this.writeTag(c,xn.Fixed64),this.writeDouble(l)},writeBooleanField:function(c,l){this.writeVarintField(c,!!l)}};var GA=h(hn);const zs=3;function QA(c,l,d){c===1&&d.readMessage(js,l)}function js(c,l,d){if(c===3){const{id:y,bitmap:w,width:T,height:K,left:D,top:j,advance:Z}=d.readMessage(l0,{});l.push({id:y,bitmap:new La({width:T+2*zs,height:K+2*zs},w),metrics:{width:T,height:K,left:D,top:j,advance:Z}})}}function l0(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 yA=zs;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 j=y[D];if(!(K.w>j.w||K.h>j.h)){if(K.x=j.x,K.y=j.y,T=Math.max(T,K.y+K.h),w=Math.max(w,K.x+K.w),K.w===j.w&&K.h===j.h){const Z=y.pop();D<y.length&&(y[D]=Z)}else K.h===j.h?(j.x+=K.w,j.w-=K.w):K.w===j.w?(j.y+=K.h,j.h-=K.h):(y.push({x:j.x+K.w,y:j.y,w:j.w-K.w,h:K.h}),j.y+=K.h,j.h-=K.h);break}}return{w,h:T,fill:l/(w*T)||0}}const Ha=1;class tl{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+Ha,this.paddedRect.y+Ha]}get br(){return[this.paddedRect.x+this.paddedRect.w-Ha,this.paddedRect.y+this.paddedRect.h-Ha]}get tlbr(){return this.tl.concat(this.br)}get displaySize(){return[(this.paddedRect.w-2*Ha)/this.pixelRatio,(this.paddedRect.h-2*Ha)/this.pixelRatio]}}class Vd{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),j=new cl({width:K||1,height:D||1});for(const Z in l){const ne=l[Z],Ae=y[Z].paddedRect;cl.copy(ne.data,j,{x:0,y:0},{x:Ae.x+Ha,y:Ae.y+Ha},ne.data)}for(const Z in d){const ne=d[Z],Ae=w[Z].paddedRect,_e=Ae.x+Ha,Ee=Ae.y+Ha,Ke=ne.data.width,We=ne.data.height;cl.copy(ne.data,j,{x:0,y:0},{x:_e,y:Ee},ne.data),cl.copy(ne.data,j,{x:0,y:We-1},{x:_e,y:Ee-1},{width:Ke,height:1}),cl.copy(ne.data,j,{x:0,y:0},{x:_e,y:Ee+We},{width:Ke,height:1}),cl.copy(ne.data,j,{x:Ke-1,y:0},{x:_e-1,y:Ee},{width:1,height:We}),cl.copy(ne.data,j,{x:0,y:0},{x:_e+Ke,y:Ee},{width:1,height:We})}this.image=j,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*Ha,h:T.data.height+2*Ha};y.push(K),d[w]=new tl(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 $A;Nn("ImagePosition",tl),Nn("ImageAtlas",Vd),s.ah=void 0,($A=s.ah||(s.ah={}))[$A.none=0]="none",$A[$A.horizontal=1]="horizontal",$A[$A.vertical=2]="vertical",$A[$A.horizontalOnly=3]="horizontalOnly";const Qp=-17;class u0{constructor(){this.scale=1,this.fontStack="",this.imageName=null}static forText(l,d){const y=new u0;return y.scale=l||1,y.fontStack=d,y}static forImage(l){const d=new u0;return d.imageName=l,d}}class $p{constructor(){this.text="",this.sectionIndex=[],this.sections=[],this.imageSectionID=null}static fromFeature(l,d){const y=new $p;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&&xu(w)&&!yt[l[y+1]]||T&&xu(T)&&!yt[l[y-1]]||!yt[l[y]]?l[y]:yt[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 $p;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(u0.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 ke("Can't add FormattedSection with an empty image.");const y=this.getNextImageSectionCharCode();y?(this.text+=String.fromCharCode(y),this.sections.push(u0.forImage(d)),this.sectionIndex.push(this.sections.length-1)):ke("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,j,Z,ne,Ae,_e,Ee,Ke,We){const qe=$p.fromFeature(c,w);let st;Ae===s.ah.vertical&&qe.verticalizePunctuation();const{processBidirectionalText:Ot,processStyledBidirectionalText:ct}=Gu;if(Ot&&qe.sections.length===1){st=[];const cn=Ot(qe.toString(),N1(qe,Z,T,l,y,Ee,Ke));for(const Un of cn){const Cr=new $p;Cr.text=Un,Cr.sections=qe.sections;for(let qn=0;qn<Un.length;qn++)Cr.sectionIndex.push(0);st.push(Cr)}}else if(ct){st=[];const cn=ct(qe.text,qe.sectionIndex,N1(qe,Z,T,l,y,Ee,Ke));for(const Un of cn){const Cr=new $p;Cr.text=Un[0],Cr.sectionIndex=Un[1],Cr.sections=qe.sections,st.push(Cr)}}else st=function(cn,Un){const Cr=[],qn=cn.text;let wn=0;for(const gn of Un)Cr.push(cn.substring(wn,gn)),wn=gn;return wn<qn.length&&Cr.push(cn.substring(wn,qn.length)),Cr}(qe,N1(qe,Z,T,l,y,Ee,Ke));const _t=[],nn={positionedLines:_t,text:qe.toString(),top:ne[1],bottom:ne[1],left:ne[0],right:ne[0],writingMode:Ae,iconsInText:!1,verticalizable:!1};return function(cn,Un,Cr,qn,wn,gn,lr,Rn,On,Fr,wr,Fi){let da=0,ha=Qp,Ra=0,ou=0;const au=Rn==="right"?1:Rn==="left"?0:.5;let ds=0;for(const Gs of wn){Gs.trim();const Qs=Gs.getMaxScale(),Wl=(Qs-1)*zt,lu={positionedGlyphs:[],lineOffset:0};cn.positionedLines[ds]=lu;const Bl=lu.positionedGlyphs;let hs=0;if(!Gs.length()){ha+=gn,++ds;continue}for(let Es=0;Es<Gs.length();Es++){const ii=Gs.getSection(Es),kl=Gs.getSectionIndex(Es),Il=Gs.getCharCode(Es);let ci=0,YA=null,qA=null,Ju=null,Xd=zt;const HA=!(On===s.ah.horizontal||!wr&&!Nu(Il)||wr&&(W1[Il]||(Ss=Il,$n.Arabic(Ss)||$n["Arabic Supplement"](Ss)||$n["Arabic Extended-A"](Ss)||$n["Arabic Presentation Forms-A"](Ss)||$n["Arabic Presentation Forms-B"](Ss))));if(ii.imageName){const CA=qn[ii.imageName];if(!CA)continue;Ju=ii.imageName,cn.iconsInText=cn.iconsInText||!0,qA=CA.paddedRect;const Bu=CA.displaySize;ii.scale=ii.scale*zt/Fi,YA={width:Bu[0],height:Bu[1],left:Ha,top:-yA,advance:HA?Bu[1]:Bu[0]},ci=Wl+(zt-Bu[1]*ii.scale),Xd=YA.advance;const Jd=HA?Bu[0]*ii.scale-zt*Qs:Bu[1]*ii.scale-zt*Qs;Jd>0&&Jd>hs&&(hs=Jd)}else{const CA=Cr[ii.fontStack],Bu=CA&&CA[Il];if(Bu&&Bu.rect)qA=Bu.rect,YA=Bu.metrics;else{const Jd=Un[ii.fontStack],f0=Jd&&Jd[Il];if(!f0)continue;YA=f0.metrics}ci=(Qs-ii.scale)*zt}HA?(cn.verticalizable=!0,Bl.push({glyph:Il,imageName:Ju,x:da,y:ha+ci,vertical:HA,scale:ii.scale,fontStack:ii.fontStack,sectionIndex:kl,metrics:YA,rect:qA}),da+=Xd*ii.scale+Fr):(Bl.push({glyph:Il,imageName:Ju,x:da,y:ha+ci,vertical:HA,scale:ii.scale,fontStack:ii.fontStack,sectionIndex:kl,metrics:YA,rect:qA}),da+=YA.advance*ii.scale+Fr)}Bl.length!==0&&(Ra=Math.max(da-Fr,Ra),ow(Bl,0,Bl.length-1,au,hs)),da=0;const Xr=gn*Qs+hs;lu.lineOffset=Math.max(hs,Wl),ha+=Xr,ou=Math.max(Xr,ou),++ds}var Ss;const Vo=ha-Qp,{horizontalAlign:Ns,verticalAlign:su}=lv(lr);(function(Gs,Qs,Wl,lu,Bl,hs,Xr,Es,ii){const kl=(Qs-Wl)*Bl;let Il=0;Il=hs!==Xr?-Es*lu-Qp:(-lu*ii+.5)*Xr;for(const ci of Gs)for(const YA of ci.positionedGlyphs)YA.x+=kl,YA.y+=Il})(cn.positionedLines,au,Ns,su,Ra,ou,gn,Vo,wn.length),cn.top+=-su*Vo,cn.bottom=cn.top+Vo,cn.left+=-Ns*Ra,cn.right=cn.left+Ra}(nn,l,d,y,st,K,D,j,Ae,Z,_e,We),!function(cn){for(const Un of cn)if(Un.positionedGlyphs.length!==0)return!1;return!0}(_t)&&nn}const W1={9:!0,10:!0,11:!0,12:!0,13:!0,32:!0},rw={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 Mb(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 vA(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 iw(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=vA(l,d,w,T);for(const j of y){const Z=vA(l-j.x,d,w,T)+j.badness;Z<=D&&(K=j,D=Z)}return{index:c,x:l,priorBreak:K,badness:D}}function Eb(c){return c?Eb(c.priorBreak).concat(c.index):[]}function N1(c,l,d,y,w,T,K){if(T!=="point")return[];if(!c)return[];const D=[],j=function(_e,Ee,Ke,We,qe,st){let Ot=0;for(let ct=0;ct<_e.length();ct++){const _t=_e.getSection(ct);Ot+=Mb(_e.getCharCode(ct),_t,We,qe,Ee,st)}return Ot/Math.max(1,Math.ceil(Ot/Ke))}(c,l,d,y,w,K),Z=c.text.indexOf("")>=0;let ne=0;for(let _e=0;_e<c.length();_e++){const Ee=c.getSection(_e),Ke=c.getCharCode(_e);if(W1[Ke]||(ne+=Mb(Ke,Ee,y,w,l,K)),_e<c.length()-1){const We=!((Ae=Ke)<11904||!($n["Bopomofo Extended"](Ae)||$n.Bopomofo(Ae)||$n["CJK Compatibility Forms"](Ae)||$n["CJK Compatibility Ideographs"](Ae)||$n["CJK Compatibility"](Ae)||$n["CJK Radicals Supplement"](Ae)||$n["CJK Strokes"](Ae)||$n["CJK Symbols and Punctuation"](Ae)||$n["CJK Unified Ideographs Extension A"](Ae)||$n["CJK Unified Ideographs"](Ae)||$n["Enclosed CJK Letters and Months"](Ae)||$n["Halfwidth and Fullwidth Forms"](Ae)||$n.Hiragana(Ae)||$n["Ideographic Description Characters"](Ae)||$n["Kangxi Radicals"](Ae)||$n["Katakana Phonetic Extensions"](Ae)||$n.Katakana(Ae)||$n["Vertical Forms"](Ae)||$n["Yi Radicals"](Ae)||$n["Yi Syllables"](Ae)));(rw[Ke]||We||Ee.imageName)&&D.push(Sb(_e+1,ne,j,D,iw(Ke,c.getCharCode(_e+1),We&&Z),!1))}}var Ae;return Eb(Sb(c.length(),ne,j,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 ow(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 aw(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 Ob(c,l,d,y,w,T){const K=c.image;let D;if(K.content){const qe=K.content,st=K.pixelRatio||1;D=[qe[0]/st,qe[1]/st,K.displaySize[0]-qe[2]/st,K.displaySize[1]-qe[3]/st]}const j=l.left*T,Z=l.right*T;let ne,Ae,_e,Ee;d==="width"||d==="both"?(Ee=w[0]+j-y[3],Ae=w[0]+Z+y[1]):(Ee=w[0]+(j+Z-K.displaySize[0])/2,Ae=Ee+K.displaySize[0]);const Ke=l.top*T,We=l.bottom*T;return d==="height"||d==="both"?(ne=w[1]+Ke-y[0],_e=w[1]+We+y[2]):(ne=w[1]+(Ke+We-K.displaySize[1])/2,_e=ne+K.displaySize[1]),{image:K,top:ne,right:Ae,bottom:_e,left:Ee,collisionPadding:D}}const qf=255,ld=128,$h=qf*ld;function Bb(c,l){const{expression:d}=l;if(d.kind==="constant")return{kind:"constant",layoutSize:d.evaluate(new So(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],j=y[K];return d.kind==="composite"?{kind:"composite",minZoom:D,maxZoom:j,interpolationType:w}:{kind:"camera",minZoom:D,maxZoom:j,minSize:d.evaluate(new So(D)),maxSize:d.evaluate(new So(j)),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 sw=Xu.VectorTileFeature.types,lw=[{name:"a_fade_opacity",components:1,type:"Uint8",offset:0}];function G1(c,l,d,y,w,T,K,D,j,Z,ne,Ae,_e){const Ee=D?Math.min($h,Math.round(D[0])):0,Ke=D?Math.min($h,Math.round(D[1])):0;c.emplaceBack(l,d,Math.round(32*y),Math.round(32*w),T,K,(Ee<<1)+(j?1:0),Ke,16*Z,16*ne,256*Ae,256*_e)}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 uw(c){for(const l of c.sections)if(fc(l.text))return!0;return!1}class cv{constructor(l){this.layoutVertexArray=new Ze,this.indexArray=new dn,this.programConfigurations=l,this.segments=new Pr,this.dynamicLayoutVertexArray=new Ct,this.opacityVertexArray=new $t,this.hasVisibleVertices=!1,this.placedSymbolArray=new _}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,te.members),this.indexBuffer=l.createIndexBuffer(this.indexArray,d),this.dynamicLayoutVertexBuffer=l.createVertexBuffer(this.dynamicLayoutVertexArray,le.members,!0),this.opacityVertexBuffer=l.createVertexBuffer(this.opacityVertexArray,lw,!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())}}Nn("SymbolBuffers",cv);class dv{constructor(l,d,y){this.layoutVertexArray=new l,this.layoutAttributes=d,this.indexArray=new y,this.segments=new Pr,this.collisionVertexArray=new tn}upload(l){this.layoutVertexBuffer=l.createVertexBuffer(this.layoutVertexArray,this.layoutAttributes),this.indexBuffer=l.createIndexBuffer(this.indexArray),this.collisionVertexBuffer=l.createVertexBuffer(this.collisionVertexArray,ge.members,!0)}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.segments.destroy(),this.collisionVertexBuffer.destroy())}}Nn("CollisionBuffers",dv);class Yp{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=Zm([]),this.placementViewportMatrix=Zm([]);const d=this.layers[0]._unevaluatedLayout._values;this.textSizeData=Bb(this.zoom,d["text-size"]),this.iconSizeData=Bb(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=>s.ah[K])),this.stateDependentLayerIds=this.layers.filter(K=>K.isStateDependent()).map(K=>K.id),this.sourceID=l.sourceID}createArrays(){this.text=new cv(new ls(this.layers,this.zoom,l=>/^text/.test(l))),this.icon=new cv(new ls(this.layers,this.zoom,l=>/^icon/.test(l))),this.glyphOffsetArray=new z,this.lineVertexArray=new W,this.symbolInstances=new I,this.textAnchorOffsets=new re}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=yt[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"),j=T.get("icon-image"),Z=(D.value.kind!=="constant"||D.value.value instanceof Wn&&!D.value.value.isEmpty()||D.value.value.toString().length>0)&&(K.value.kind!=="constant"||K.value.value.length>0),ne=j.value.kind!=="constant"||!!j.value.value||Object.keys(j.parameters).length>0,Ae=T.get("symbol-sort-key");if(this.features=[],!Z&&!ne)return;const _e=d.iconDependencies,Ee=d.glyphDependencies,Ke=d.availableImages,We=new So(this.zoom);for(const{feature:qe,id:st,index:Ot,sourceLayerIndex:ct}of l){const _t=w._featureFilter.needGeometry,nn=WA(qe,_t);if(!w._featureFilter.filter(We,nn,y))continue;let cn,Un;if(_t||(nn.geometry=nu(qe)),Z){const qn=w.getValueAndResolveTokens("text-field",nn,y,Ke),wn=Wn.factory(qn);uw(wn)&&(this.hasRTLText=!0),(!this.hasRTLText||Gu.getRTLTextPluginStatus()==="unavailable"||this.hasRTLText&&Gu.isParsed())&&(cn=Mt(wn,w,nn))}if(ne){const qn=w.getValueAndResolveTokens("icon-image",nn,y,Ke);Un=qn instanceof ve?qn:ve.fromString(qn)}if(!cn&&!Un)continue;const Cr=this.sortFeaturesByKey?Ae.evaluate(nn,{},y):void 0;if(this.features.push({id:st,text:cn,icon:Un,index:Ot,sourceLayerIndex:ct,geometry:nn.geometry,properties:qe.properties,type:sw[qe.type],sortKey:Cr}),Un&&(_e[Un.name]=!0),cn){const qn=K.evaluate(nn,{},y).join(","),wn=T.get("text-rotation-alignment")!=="viewport"&&T.get("symbol-placement")!=="point";this.allowVerticalPlacement=this.writingModes&&this.writingModes.indexOf(s.ah.vertical)>=0;for(const gn of cn.sections)if(gn.image)_e[gn.image.name]=!0;else{const lr=hc(cn.toString()),Rn=gn.fontStack||qn,On=Ee[Rn]=Ee[Rn]||{};this.calculateGlyphDependencies(gn.text,On,wn,this.allowVerticalPlacement,lr)}}}T.get("symbol-placement")==="line"&&(this.features=function(qe){const st={},Ot={},ct=[];let _t=0;function nn(qn){ct.push(qe[qn]),_t++}function cn(qn,wn,gn){const lr=Ot[qn];return delete Ot[qn],Ot[wn]=lr,ct[lr].geometry[0].pop(),ct[lr].geometry[0]=ct[lr].geometry[0].concat(gn[0]),lr}function Un(qn,wn,gn){const lr=st[wn];return delete st[wn],st[qn]=lr,ct[lr].geometry[0].shift(),ct[lr].geometry[0]=gn[0].concat(ct[lr].geometry[0]),lr}function Cr(qn,wn,gn){const lr=gn?wn[0][wn[0].length-1]:wn[0][0];return`${qn}:${lr.x}:${lr.y}`}for(let qn=0;qn<qe.length;qn++){const wn=qe[qn],gn=wn.geometry,lr=wn.text?wn.text.toString():null;if(!lr){nn(qn);continue}const Rn=Cr(lr,gn),On=Cr(lr,gn,!0);if(Rn in Ot&&On in st&&Ot[Rn]!==st[On]){const Fr=Un(Rn,On,gn),wr=cn(Rn,On,ct[Fr].geometry);delete st[Rn],delete Ot[On],Ot[Cr(lr,ct[wr].geometry,!0)]=wr,ct[Fr].geometry=null}else Rn in Ot?cn(Rn,On,gn):On in st?Un(Rn,On,gn):(nn(qn),st[Rn]=_t-1,Ot[On]=_t-1)}return ct.filter(qn=>qn.geometry)}(this.features)),this.sortFeaturesByKey&&this.features.sort((qe,st)=>qe.sortKey-st.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 j=K[D];this.lineVertexArray.emplaceBack(j.x,j.y,j.tileUnitDistanceFromAnchor)}}return{lineStartIndex:y,lineLength:this.lineVertexArray.length-y}}addSymbols(l,d,y,w,T,K,D,j,Z,ne,Ae,_e){const Ee=l.indexArray,Ke=l.layoutVertexArray,We=l.segments.prepareSegment(4*d.length,Ke,Ee,this.canOverlap?K.sortKey:void 0),qe=this.glyphOffsetArray.length,st=We.vertexLength,Ot=this.allowVerticalPlacement&&D===s.ah.vertical?Math.PI/2:0,ct=K.text&&K.text.sections;for(let _t=0;_t<d.length;_t++){const{tl:nn,tr:cn,bl:Un,br:Cr,tex:qn,pixelOffsetTL:wn,pixelOffsetBR:gn,minFontScaleX:lr,minFontScaleY:Rn,glyphOffset:On,isSDF:Fr,sectionIndex:wr}=d[_t],Fi=We.vertexLength,da=On[1];G1(Ke,j.x,j.y,nn.x,da+nn.y,qn.x,qn.y,y,Fr,wn.x,wn.y,lr,Rn),G1(Ke,j.x,j.y,cn.x,da+cn.y,qn.x+qn.w,qn.y,y,Fr,gn.x,wn.y,lr,Rn),G1(Ke,j.x,j.y,Un.x,da+Un.y,qn.x,qn.y+qn.h,y,Fr,wn.x,gn.y,lr,Rn),G1(Ke,j.x,j.y,Cr.x,da+Cr.y,qn.x+qn.w,qn.y+qn.h,y,Fr,gn.x,gn.y,lr,Rn),Av(l.dynamicLayoutVertexArray,j,Ot),Ee.emplaceBack(Fi,Fi+1,Fi+2),Ee.emplaceBack(Fi+1,Fi+2,Fi+3),We.vertexLength+=4,We.primitiveLength+=2,this.glyphOffsetArray.emplaceBack(On[0]),_t!==d.length-1&&wr===d[_t+1].sectionIndex||l.programConfigurations.populatePaintArrays(Ke.length,K,K.index,{},_e,ct&&ct[wr])}l.placedSymbolArray.emplaceBack(j.x,j.y,qe,this.glyphOffsetArray.length-qe,st,Z,ne,j.segment,y?y[0]:0,y?y[1]:0,w[0],w[1],D,0,!1,0,Ae)}_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 j=T.segments.prepareSegment(4,T.layoutVertexArray,T.indexArray),Z=j.vertexLength,ne=T.layoutVertexArray,Ae=T.collisionVertexArray,_e=D.anchorX,Ee=D.anchorY;this._addCollisionDebugVertex(ne,Ae,K,_e,Ee,new B(l,d)),this._addCollisionDebugVertex(ne,Ae,K,_e,Ee,new B(y,d)),this._addCollisionDebugVertex(ne,Ae,K,_e,Ee,new B(y,w)),this._addCollisionDebugVertex(ne,Ae,K,_e,Ee,new B(l,w)),j.vertexLength+=4;const Ke=T.indexArray;Ke.emplaceBack(Z,Z+1),Ke.emplaceBack(Z+1,Z+2),Ke.emplaceBack(Z+2,Z+3),Ke.emplaceBack(Z+3,Z),j.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(Dt,Qe.members,An),this.iconCollisionBox=new dv(Dt,Qe.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,j,Z){const ne={};for(let Ae=d;Ae<y;Ae++){const _e=l.get(Ae);ne.textBox={x1:_e.x1,y1:_e.y1,x2:_e.x2,y2:_e.y2,anchorPointX:_e.anchorPointX,anchorPointY:_e.anchorPointY},ne.textFeatureIndex=_e.featureIndex;break}for(let Ae=w;Ae<T;Ae++){const _e=l.get(Ae);ne.verticalTextBox={x1:_e.x1,y1:_e.y1,x2:_e.x2,y2:_e.y2,anchorPointX:_e.anchorPointX,anchorPointY:_e.anchorPointY},ne.verticalTextFeatureIndex=_e.featureIndex;break}for(let Ae=K;Ae<D;Ae++){const _e=l.get(Ae);ne.iconBox={x1:_e.x1,y1:_e.y1,x2:_e.x2,y2:_e.y2,anchorPointX:_e.anchorPointX,anchorPointY:_e.anchorPointY},ne.iconFeatureIndex=_e.featureIndex;break}for(let Ae=j;Ae<Z;Ae++){const _e=l.get(Ae);ne.verticalIconBox={x1:_e.x1,y1:_e.y1,x2:_e.x2,y2:_e.y2,anchorPointX:_e.anchorPointX,anchorPointY:_e.anchorPointY},ne.verticalIconFeatureIndex=_e.featureIndex;break}return ne}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 j=this.symbolInstances.get(D);w.push(0|Math.round(d*j.anchorX+y*j.anchorY)),T.push(j.featureIndex)}return K.sort((D,j)=>w[D]-w[j]||T[j]-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 kb,Ib;Nn("SymbolBucket",Yp,{omit:["layers","collisionBoxArray","features","compareText"]}),Yp.MAX_GLYPHS=65535,Yp.addDynamicAttributes=Av;var hv={get paint(){return Ib=Ib||new Jo({"icon-opacity":new Tr(pt.paint_symbol["icon-opacity"]),"icon-color":new Tr(pt.paint_symbol["icon-color"]),"icon-halo-color":new Tr(pt.paint_symbol["icon-halo-color"]),"icon-halo-width":new Tr(pt.paint_symbol["icon-halo-width"]),"icon-halo-blur":new Tr(pt.paint_symbol["icon-halo-blur"]),"icon-translate":new vr(pt.paint_symbol["icon-translate"]),"icon-translate-anchor":new vr(pt.paint_symbol["icon-translate-anchor"]),"text-opacity":new Tr(pt.paint_symbol["text-opacity"]),"text-color":new Tr(pt.paint_symbol["text-color"],{runtimeType:En,getOverride:c=>c.textColor,hasOverride:c=>!!c.textColor}),"text-halo-color":new Tr(pt.paint_symbol["text-halo-color"]),"text-halo-width":new Tr(pt.paint_symbol["text-halo-width"]),"text-halo-blur":new Tr(pt.paint_symbol["text-halo-blur"]),"text-translate":new vr(pt.paint_symbol["text-translate"]),"text-translate-anchor":new vr(pt.paint_symbol["text-translate-anchor"])})},get layout(){return kb=kb||new Jo({"symbol-placement":new vr(pt.layout_symbol["symbol-placement"]),"symbol-spacing":new vr(pt.layout_symbol["symbol-spacing"]),"symbol-avoid-edges":new vr(pt.layout_symbol["symbol-avoid-edges"]),"symbol-sort-key":new Tr(pt.layout_symbol["symbol-sort-key"]),"symbol-z-order":new vr(pt.layout_symbol["symbol-z-order"]),"icon-allow-overlap":new vr(pt.layout_symbol["icon-allow-overlap"]),"icon-overlap":new vr(pt.layout_symbol["icon-overlap"]),"icon-ignore-placement":new vr(pt.layout_symbol["icon-ignore-placement"]),"icon-optional":new vr(pt.layout_symbol["icon-optional"]),"icon-rotation-alignment":new vr(pt.layout_symbol["icon-rotation-alignment"]),"icon-size":new Tr(pt.layout_symbol["icon-size"]),"icon-text-fit":new vr(pt.layout_symbol["icon-text-fit"]),"icon-text-fit-padding":new vr(pt.layout_symbol["icon-text-fit-padding"]),"icon-image":new Tr(pt.layout_symbol["icon-image"]),"icon-rotate":new Tr(pt.layout_symbol["icon-rotate"]),"icon-padding":new Tr(pt.layout_symbol["icon-padding"]),"icon-keep-upright":new vr(pt.layout_symbol["icon-keep-upright"]),"icon-offset":new Tr(pt.layout_symbol["icon-offset"]),"icon-anchor":new Tr(pt.layout_symbol["icon-anchor"]),"icon-pitch-alignment":new vr(pt.layout_symbol["icon-pitch-alignment"]),"text-pitch-alignment":new vr(pt.layout_symbol["text-pitch-alignment"]),"text-rotation-alignment":new vr(pt.layout_symbol["text-rotation-alignment"]),"text-field":new Tr(pt.layout_symbol["text-field"]),"text-font":new Tr(pt.layout_symbol["text-font"]),"text-size":new Tr(pt.layout_symbol["text-size"]),"text-max-width":new Tr(pt.layout_symbol["text-max-width"]),"text-line-height":new vr(pt.layout_symbol["text-line-height"]),"text-letter-spacing":new Tr(pt.layout_symbol["text-letter-spacing"]),"text-justify":new Tr(pt.layout_symbol["text-justify"]),"text-radial-offset":new Tr(pt.layout_symbol["text-radial-offset"]),"text-variable-anchor":new vr(pt.layout_symbol["text-variable-anchor"]),"text-variable-anchor-offset":new Tr(pt.layout_symbol["text-variable-anchor-offset"]),"text-anchor":new Tr(pt.layout_symbol["text-anchor"]),"text-max-angle":new vr(pt.layout_symbol["text-max-angle"]),"text-writing-mode":new vr(pt.layout_symbol["text-writing-mode"]),"text-rotate":new Tr(pt.layout_symbol["text-rotate"]),"text-padding":new vr(pt.layout_symbol["text-padding"]),"text-keep-upright":new vr(pt.layout_symbol["text-keep-upright"]),"text-transform":new Tr(pt.layout_symbol["text-transform"]),"text-offset":new Tr(pt.layout_symbol["text-offset"]),"text-allow-overlap":new vr(pt.layout_symbol["text-allow-overlap"]),"text-overlap":new vr(pt.layout_symbol["text-overlap"]),"text-ignore-placement":new vr(pt.layout_symbol["text-ignore-placement"]),"text-optional":new vr(pt.layout_symbol["text-optional"])})}};class Tb{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:Et,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}}Nn("FormatSectionOverride",Tb,{omit:["defaultValue"]});class Q1 extends Ia{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()||Mo(K.value)||!T?T:function(D,j){return j.replace(/{([^{}]+)}/g,(Z,ne)=>D&&ne in D?String(D[ne]):"")}(d.properties,T)}createBucket(l){return new Yp(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 Tb(d),w=new To(y,d.property.specification);let T=null;T=d.value.kind==="constant"||d.value.kind==="source"?new Qc("source",w):new Hs("composite",w,d.value.zoomStops),this.paint._values[l]=new so(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 j of D)if(w.overrides&&w.overrides.hasOverride(j))return void(T=!0)};if(y.value.kind==="constant"&&y.value.value instanceof Wn)K(y.value.value.sections);else if(y.value.kind==="source"){const D=Z=>{T||(Z instanceof Cn&&sn(Z.value)===Fn?K(Z.value.sections):Z instanceof Wc?K(Z.sections):Z.eachChild(D))},j=y.value;j._styleExpression&&D(j._styleExpression.expression)}return T}}let Kb;var Aw={get paint(){return Kb=Kb||new Jo({"background-color":new vr(pt.paint_background["background-color"]),"background-pattern":new pc(pt.paint_background["background-pattern"]),"background-opacity":new vr(pt.paint_background["background-opacity"])})}};class cw extends Ia{constructor(l){super(l,Aw)}}let $1;var Pb={get paint(){return $1=$1||new Jo({"raster-opacity":new vr(pt.paint_raster["raster-opacity"]),"raster-hue-rotate":new vr(pt.paint_raster["raster-hue-rotate"]),"raster-brightness-min":new vr(pt.paint_raster["raster-brightness-min"]),"raster-brightness-max":new vr(pt.paint_raster["raster-brightness-max"]),"raster-saturation":new vr(pt.paint_raster["raster-saturation"]),"raster-contrast":new vr(pt.paint_raster["raster-contrast"]),"raster-resampling":new vr(pt.paint_raster["raster-resampling"]),"raster-fade-duration":new vr(pt.paint_raster["raster-fade-duration"])})}};class dw extends Ia{constructor(l){super(l,Pb)}}class hw extends Ia{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 fw{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 fv=63710088e-1;class Yh{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 Yh(he(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 fv*Math.acos(Math.min(T,1))}static convert(l){if(l instanceof Yh)return l;if(Array.isArray(l)&&(l.length===2||l.length===3))return new Yh(Number(l[0]),Number(l[1]));if(!Array.isArray(l)&&typeof l=="object"&&l!==null)return new Yh(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 Fb=2*Math.PI*fv;function Db(c){return Fb*Math.cos(c*Math.PI/180)}function Lb(c){return(180+c)/360}function pv(c){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+c*Math.PI/360)))/360}function Ub(c,l){return c/Db(l)}function qp(c){return 360/Math.PI*Math.atan(Math.exp((180-360*c)*Math.PI/180))-90}class Y1{constructor(l,d,y=0){this.x=+l,this.y=+d,this.z=+y}static fromLngLat(l,d=0){const y=Yh.convert(l);return new Y1(Lb(y.lng),pv(y.lat),Ub(d,y.lat))}toLngLat(){return new Yh(360*this.x-180,qp(this.y))}toAltitude(){return this.z*Db(qp(this.y))}meterInMercatorCoordinateUnits(){return 1/Fb*(l=qp(this.y),1/Math.cos(l*Math.PI/180));var l}}function Rb(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 mv{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,j=Rb(256*(T=this.x),256*(K=Math.pow(2,D)-K-1),D),Z=Rb(256*(T+1),256*(K+1),D),j[0]+","+j[1]+","+Z[0]+","+Z[1]);var T,K,D,j,Z;const ne=function(Ae,_e,Ee){let Ke,We="";for(let qe=Ae;qe>0;qe--)Ke=1<<qe-1,We+=(_e&Ke?1:0)+(Ee&Ke?2:0);return We}(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,ne).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)*_a,(l.y*d-this.y)*_a)}toString(){return`${this.z}/${this.x}/${this.y}`}}class zb{constructor(l,d){this.wrap=l,this.canonical=d,this.key=A0(l,d.z,d.z,d.x,d.y)}}class _A{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 mv(y,+w,+T),this.key=A0(d,l,y,w,T)}clone(){return new _A(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 _A(l,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new _A(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 _A(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 _A(d,this.wrap,d,y,w),new _A(d,this.wrap,d,y+1,w),new _A(d,this.wrap,d,y,w+1),new _A(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 _A(this.overscaledZ,0,this.canonical.z,this.canonical.x,this.canonical.y)}unwrapTo(l){return new _A(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 zb(this.wrap,this.canonical)}toString(){return`${this.overscaledZ}/${this.canonical.x}/${this.canonical.y}`}getTilePoint(l){return this.canonical.getTilePoint(new Y1(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)}Nn("CanonicalTileID",mv),Nn("OverscaledTileID",_A,{omit:["posMatrix"]});class jb{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 ke(`"${y}" is not a valid encoding type. Valid types include "mapbox", "terrarium" and "custom".`);this.stride=d.height;const j=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 Z=0;Z<j;Z++)this.data[this._idx(-1,Z)]=this.data[this._idx(0,Z)],this.data[this._idx(j,Z)]=this.data[this._idx(j-1,Z)],this.data[this._idx(Z,-1)]=this.data[this._idx(Z,0)],this.data[this._idx(Z,j)]=this.data[this._idx(Z,j-1)];this.data[this._idx(-1,-1)]=this.data[this._idx(0,0)],this.data[this._idx(j,-1)]=this.data[this._idx(j-1,0)],this.data[this._idx(-1,j)]=this.data[this._idx(0,j-1)],this.data[this._idx(j,j)]=this.data[this._idx(j-1,j-1)],this.min=Number.MAX_SAFE_INTEGER,this.max=Number.MIN_SAFE_INTEGER;for(let Z=0;Z<j;Z++)for(let ne=0;ne<j;ne++){const Ae=this.get(Z,ne);Ae>this.max&&(this.max=Ae),Ae<this.min&&(this.min=Ae)}}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 cl({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 j=-d*this.dim,Z=-y*this.dim;for(let ne=K;ne<D;ne++)for(let Ae=w;Ae<T;Ae++)this.data[this._idx(Ae,ne)]=l.data[this._idx(Ae+j,ne+Z)]}}Nn("DEMData",jb);class Wb{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 Nb{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 Gb{constructor(l,d){this.tileID=l,this.x=l.canonical.x,this.y=l.canonical.y,this.z=l.canonical.z,this.grid=new Da(_a,16,0),this.grid3D=new Da(_a,16,0),this.featureIndexArray=new pe,this.promoteId=d}insert(l,d,y,w,T,K){const D=this.featureIndexArray.length;this.featureIndexArray.emplaceBack(y,w,T);const j=K?this.grid3D:this.grid;for(let Z=0;Z<d.length;Z++){const ne=d[Z],Ae=[1/0,1/0,-1/0,-1/0];for(let _e=0;_e<ne.length;_e++){const Ee=ne[_e];Ae[0]=Math.min(Ae[0],Ee.x),Ae[1]=Math.min(Ae[1],Ee.y),Ae[2]=Math.max(Ae[2],Ee.x),Ae[3]=Math.max(Ae[3],Ee.y)}Ae[0]<_a&&Ae[1]<_a&&Ae[2]>=0&&Ae[3]>=0&&j.insert(D,Ae[0],Ae[1],Ae[2],Ae[3])}}loadVTLayers(){return this.vtLayers||(this.vtLayers=new Xu.VectorTile(new GA(this.rawTileData)).layers,this.sourceLayerCoder=new Wb(this.vtLayers?Object.keys(this.vtLayers).sort():["_geojsonTileLayer"])),this.vtLayers}query(l,d,y,w){this.loadVTLayers();const T=l.params||{},K=_a/l.tileSize/l.scale,D=kd(T.filter),j=l.queryGeometry,Z=l.queryPadding*K,ne=$b(j),Ae=this.grid.query(ne.minX-Z,ne.minY-Z,ne.maxX+Z,ne.maxY+Z),_e=$b(l.cameraQueryGeometry),Ee=this.grid3D.query(_e.minX-Z,_e.minY-Z,_e.maxX+Z,_e.maxY+Z,(qe,st,Ot,ct)=>function(_t,nn,cn,Un,Cr){for(const wn of _t)if(nn<=wn.x&&cn<=wn.y&&Un>=wn.x&&Cr>=wn.y)return!0;const qn=[new B(nn,cn),new B(nn,Cr),new B(Un,Cr),new B(Un,cn)];if(_t.length>2){for(const wn of qn)if(Hu(_t,wn))return!0}for(let wn=0;wn<_t.length-1;wn++)if(Vm(_t[wn],_t[wn+1],qn))return!0;return!1}(l.cameraQueryGeometry,qe-Z,st-Z,Ot+Z,ct+Z));for(const qe of Ee)Ae.push(qe);Ae.sort(pw);const Ke={};let We;for(let qe=0;qe<Ae.length;qe++){const st=Ae[qe];if(st===We)continue;We=st;const Ot=this.featureIndexArray.get(st);let ct=null;this.loadMatchingFeature(Ke,Ot.bucketIndex,Ot.sourceLayerIndex,Ot.featureIndex,D,T.layers,T.availableImages,d,y,w,(_t,nn,cn)=>(ct||(ct=nu(_t)),nn.queryIntersectsFeature(j,_t,cn,ct,this.z,l.transform,K,l.pixelPosMatrix)))}return Ke}loadMatchingFeature(l,d,y,w,T,K,D,j,Z,ne,Ae){const _e=this.bucketLayerIDs[d];if(K&&!function(qe,st){for(let Ot=0;Ot<qe.length;Ot++)if(st.indexOf(qe[Ot])>=0)return!0;return!1}(K,_e))return;const Ee=this.sourceLayerCoder.decode(y),Ke=this.vtLayers[Ee].feature(w);if(T.needGeometry){const qe=WA(Ke,!0);if(!T.filter(new So(this.tileID.overscaledZ),qe,this.tileID.canonical))return}else if(!T.filter(new So(this.tileID.overscaledZ),Ke))return;const We=this.getId(Ke,Ee);for(let qe=0;qe<_e.length;qe++){const st=_e[qe];if(K&&K.indexOf(st)<0)continue;const Ot=j[st];if(!Ot)continue;let ct={};We&&ne&&(ct=ne.getState(Ot.sourceLayer||"_geojsonTileLayer",We));const _t=V({},Z[st]);_t.paint=Qb(_t.paint,Ot.paint,Ke,ct,D),_t.layout=Qb(_t.layout,Ot.layout,Ke,ct,D);const nn=!Ae||Ae(Ke,Ot,ct);if(!nn)continue;const cn=new Nb(Ke,this.z,this.x,this.y,We);cn.layer=_t;let Un=l[st];Un===void 0&&(Un=l[st]=[]),Un.push({featureIndex:w,feature:cn,intersectionZ:nn})}}lookupSymbolFeatures(l,d,y,w,T,K,D,j){const Z={};this.loadVTLayers();const ne=kd(T);for(const Ae of l)this.loadMatchingFeature(Z,y,w,Ae,ne,K,D,j,d);return Z}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 Qb(c,l,d,y,w){return ye(c,(T,K)=>{const D=l instanceof ua?l.get(K):null;return D&&D.evaluate?D.evaluate(d,y,w):D})}function $b(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 pw(c,l){return l-c}function Yb(c,l,d,y,w){const T=[];for(let K=0;K<c.length;K++){const D=c[K];let j;for(let Z=0;Z<D.length-1;Z++){let ne=D[Z],Ae=D[Z+1];ne.x<l&&Ae.x<l||(ne.x<l?ne=new B(l,ne.y+(l-ne.x)/(Ae.x-ne.x)*(Ae.y-ne.y))._round():Ae.x<l&&(Ae=new B(l,ne.y+(l-ne.x)/(Ae.x-ne.x)*(Ae.y-ne.y))._round()),ne.y<d&&Ae.y<d||(ne.y<d?ne=new B(ne.x+(d-ne.y)/(Ae.y-ne.y)*(Ae.x-ne.x),d)._round():Ae.y<d&&(Ae=new B(ne.x+(d-ne.y)/(Ae.y-ne.y)*(Ae.x-ne.x),d)._round()),ne.x>=y&&Ae.x>=y||(ne.x>=y?ne=new B(y,ne.y+(y-ne.x)/(Ae.x-ne.x)*(Ae.y-ne.y))._round():Ae.x>=y&&(Ae=new B(y,ne.y+(y-ne.x)/(Ae.x-ne.x)*(Ae.y-ne.y))._round()),ne.y>=w&&Ae.y>=w||(ne.y>=w?ne=new B(ne.x+(w-ne.y)/(Ae.y-ne.y)*(Ae.x-ne.x),w)._round():Ae.y>=w&&(Ae=new B(ne.x+(w-ne.y)/(Ae.y-ne.y)*(Ae.x-ne.x),w)._round()),j&&ne.equals(j[j.length-1])||(j=[ne],T.push(j)),j.push(Ae)))))}}return T}Nn("FeatureIndex",Gb,{omit:["rawTileData","sourceLayerCoder"]});class qh extends B{constructor(l,d,y,w){super(l,d),this.angle=y,w!==void 0&&(this.segment=w)}clone(){return new qh(this.x,this.y,this.angle,this.segment)}}function qb(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 j=[];let Z=0;for(;D<d/2;){const ne=c[K],Ae=c[K+1];if(!Ae)return!1;let _e=c[K-1].angleTo(ne)-ne.angleTo(Ae);for(_e=Math.abs((_e+3*Math.PI)%(2*Math.PI)-Math.PI),j.push({distance:D,angleDelta:_e}),Z+=_e;D-j[0].distance>y;)Z-=j.shift().angleDelta;if(Z>w)return!1;K++,D+=ne.dist(Ae)}return!0}function gv(c){let l=0;for(let d=0;d<c.length-1;d++)l+=c[d].dist(c[d+1]);return l}function yv(c,l,d){return c?.6*l*d:0}function Hb(c,l){return Math.max(c?c.right-c.left:0,l?l.right-l.left:0)}function mw(c,l,d,y,w,T){const K=yv(d,w,T),D=Hb(d,y)*T;let j=0;const Z=gv(c)/2;for(let ne=0;ne<c.length-1;ne++){const Ae=c[ne],_e=c[ne+1],Ee=Ae.dist(_e);if(j+Ee>Z){const Ke=(Z-j)/Ee,We=mt.number(Ae.x,_e.x,Ke),qe=mt.number(Ae.y,_e.y,Ke),st=new qh(We,qe,_e.angleTo(Ae),ne);return st._round(),!K||qb(c,st,D,K,l)?st:void 0}j+=Ee}}function gw(c,l,d,y,w,T,K,D,j){const Z=yv(y,T,K),ne=Hb(y,w),Ae=ne*K,_e=c[0].x===0||c[0].x===j||c[0].y===0||c[0].y===j;return l-Ae<l/4&&(l=Ae+l/4),Vb(c,_e?l/2*D%l:(ne/2+2*T)*K*D%l,l,Z,d,Ae,_e,!1,j)}function Vb(c,l,d,y,w,T,K,D,j){const Z=T/2,ne=gv(c);let Ae=0,_e=l-d,Ee=[];for(let Ke=0;Ke<c.length-1;Ke++){const We=c[Ke],qe=c[Ke+1],st=We.dist(qe),Ot=qe.angleTo(We);for(;_e+d<Ae+st;){_e+=d;const ct=(_e-Ae)/st,_t=mt.number(We.x,qe.x,ct),nn=mt.number(We.y,qe.y,ct);if(_t>=0&&_t<j&&nn>=0&&nn<j&&_e-Z>=0&&_e+Z<=ne){const cn=new qh(_t,nn,Ot,Ke);cn._round(),y&&!qb(c,cn,T,y,w)||Ee.push(cn)}}Ae+=st}return D||Ee.length||K||(Ee=Vb(c,Ae/2,d,y,w,T,K,!0,j)),Ee}Nn("Anchor",qh);const Zd=Ha;function Zb(c,l,d,y){const w=[],T=c.image,K=T.pixelRatio,D=T.paddedRect.w-2*Zd,j=T.paddedRect.h-2*Zd,Z=c.right-c.left,ne=c.bottom-c.top,Ae=T.stretchX||[[0,D]],_e=T.stretchY||[[0,j]],Ee=(gn,lr)=>gn+lr[1]-lr[0],Ke=Ae.reduce(Ee,0),We=_e.reduce(Ee,0),qe=D-Ke,st=j-We;let Ot=0,ct=Ke,_t=0,nn=We,cn=0,Un=qe,Cr=0,qn=st;if(T.content&&y){const gn=T.content;Ot=q1(Ae,0,gn[0]),_t=q1(_e,0,gn[1]),ct=q1(Ae,gn[0],gn[2]),nn=q1(_e,gn[1],gn[3]),cn=gn[0]-Ot,Cr=gn[1]-_t,Un=gn[2]-gn[0]-ct,qn=gn[3]-gn[1]-nn}const wn=(gn,lr,Rn,On)=>{const Fr=H1(gn.stretch-Ot,ct,Z,c.left),wr=V1(gn.fixed-cn,Un,gn.stretch,Ke),Fi=H1(lr.stretch-_t,nn,ne,c.top),da=V1(lr.fixed-Cr,qn,lr.stretch,We),ha=H1(Rn.stretch-Ot,ct,Z,c.left),Ra=V1(Rn.fixed-cn,Un,Rn.stretch,Ke),ou=H1(On.stretch-_t,nn,ne,c.top),au=V1(On.fixed-Cr,qn,On.stretch,We),ds=new B(Fr,Fi),Ss=new B(ha,Fi),Vo=new B(ha,ou),Ns=new B(Fr,ou),su=new B(wr/K,da/K),Gs=new B(Ra/K,au/K),Qs=l*Math.PI/180;if(Qs){const Bl=Math.sin(Qs),hs=Math.cos(Qs),Xr=[hs,-Bl,Bl,hs];ds._matMult(Xr),Ss._matMult(Xr),Ns._matMult(Xr),Vo._matMult(Xr)}const Wl=gn.stretch+gn.fixed,lu=lr.stretch+lr.fixed;return{tl:ds,tr:Ss,bl:Ns,br:Vo,tex:{x:T.paddedRect.x+Zd+Wl,y:T.paddedRect.y+Zd+lu,w:Rn.stretch+Rn.fixed-Wl,h:On.stretch+On.fixed-lu},writingMode:void 0,glyphOffset:[0,0],sectionIndex:0,pixelOffsetTL:su,pixelOffsetBR:Gs,minFontScaleX:Un/K/Z,minFontScaleY:qn/K/ne,isSDF:d}};if(y&&(T.stretchX||T.stretchY)){const gn=Xb(Ae,qe,Ke),lr=Xb(_e,st,We);for(let Rn=0;Rn<gn.length-1;Rn++){const On=gn[Rn],Fr=gn[Rn+1];for(let wr=0;wr<lr.length-1;wr++)w.push(wn(On,lr[wr],Fr,lr[wr+1]))}}else w.push(wn({fixed:0,stretch:-1},{fixed:0,stretch:-1},{fixed:0,stretch:D+1},{fixed:0,stretch:j+1}));return w}function q1(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 Xb(c,l,d){const y=[{fixed:-Zd,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+Zd,stretch:d}),y}function H1(c,l,d,y){return c/l*d+y}function V1(c,l,d,y){return c-l*d/y}class Z1{constructor(l,d,y,w,T,K,D,j,Z,ne){if(this.boxStartIndex=l.length,Z){let Ae=K.top,_e=K.bottom;const Ee=K.collisionPadding;Ee&&(Ae-=Ee[1],_e+=Ee[3]);let Ke=_e-Ae;Ke>0&&(Ke=Math.max(10,Ke),this.circleDiameter=Ke)}else{let Ae=K.top*D-j[0],_e=K.bottom*D+j[2],Ee=K.left*D-j[3],Ke=K.right*D+j[1];const We=K.collisionPadding;if(We&&(Ee-=We[0]*D,Ae-=We[1]*D,Ke+=We[2]*D,_e+=We[3]*D),ne){const qe=new B(Ee,Ae),st=new B(Ke,Ae),Ot=new B(Ee,_e),ct=new B(Ke,_e),_t=ne*Math.PI/180;qe._rotate(_t),st._rotate(_t),Ot._rotate(_t),ct._rotate(_t),Ee=Math.min(qe.x,st.x,Ot.x,ct.x),Ke=Math.max(qe.x,st.x,Ot.x,ct.x),Ae=Math.min(qe.y,st.y,Ot.y,ct.y),_e=Math.max(qe.y,st.y,Ot.y,ct.y)}l.emplaceBack(d.x,d.y,Ee,Ae,Ke,_e,y,w,T)}this.boxEndIndex=l.length}}class yw{constructor(l=[],d=vw){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 j=K+1;if(j<this.length&&y(d[j],D)<0&&(K=j,D=d[j]),y(D,T)>=0)break;d[l]=D,l=K}d[l]=T}}function vw(c,l){return c<l?-1:c>l?1:0}function _w(c,l=1,d=!1){let y=1/0,w=1/0,T=-1/0,K=-1/0;const D=c[0];for(let Ee=0;Ee<D.length;Ee++){const Ke=D[Ee];(!Ee||Ke.x<y)&&(y=Ke.x),(!Ee||Ke.y<w)&&(w=Ke.y),(!Ee||Ke.x>T)&&(T=Ke.x),(!Ee||Ke.y>K)&&(K=Ke.y)}const j=Math.min(T-y,K-w);let Z=j/2;const ne=new yw([],Cw);if(j===0)return new B(y,w);for(let Ee=y;Ee<T;Ee+=j)for(let Ke=w;Ke<K;Ke+=j)ne.push(new Hp(Ee+Z,Ke+Z,Z,c));let Ae=function(Ee){let Ke=0,We=0,qe=0;const st=Ee[0];for(let Ot=0,ct=st.length,_t=ct-1;Ot<ct;_t=Ot++){const nn=st[Ot],cn=st[_t],Un=nn.x*cn.y-cn.x*nn.y;We+=(nn.x+cn.x)*Un,qe+=(nn.y+cn.y)*Un,Ke+=3*Un}return new Hp(We/Ke,qe/Ke,0,Ee)}(c),_e=ne.length;for(;ne.length;){const Ee=ne.pop();(Ee.d>Ae.d||!Ae.d)&&(Ae=Ee,d&&console.log("found best %d after %d probes",Math.round(1e4*Ee.d)/1e4,_e)),Ee.max-Ae.d<=l||(Z=Ee.h/2,ne.push(new Hp(Ee.p.x-Z,Ee.p.y-Z,Z,c)),ne.push(new Hp(Ee.p.x+Z,Ee.p.y-Z,Z,c)),ne.push(new Hp(Ee.p.x-Z,Ee.p.y+Z,Z,c)),ne.push(new Hp(Ee.p.x+Z,Ee.p.y+Z,Z,c)),_e+=4)}return d&&(console.log(`num probes: ${_e}`),console.log(`best distance: ${Ae.d}`)),Ae.p}function Cw(c,l){return l.max-c.max}function Hp(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 j=0;j<T.length;j++){const Z=T[j];for(let ne=0,Ae=Z.length,_e=Ae-1;ne<Ae;_e=ne++){const Ee=Z[ne],Ke=Z[_e];Ee.y>w.y!=Ke.y>w.y&&w.x<(Ke.x-Ee.x)*(w.y-Ee.y)/(Ke.y-Ee.y)+Ee.x&&(K=!K),D=Math.min(D,ed(w,Ee,Ke))}}return(K?1:-1)*Math.sqrt(D)}(this.p,y),this.max=this.d+this.h*Math.SQRT2}var Ws;s.ap=void 0,(Ws=s.ap||(s.ap={}))[Ws.center=1]="center",Ws[Ws.left=2]="left",Ws[Ws.right=3]="right",Ws[Ws.top=4]="top",Ws[Ws.bottom=5]="bottom",Ws[Ws["top-left"]=6]="top-left",Ws[Ws["top-right"]=7]="top-right",Ws[Ws["bottom-left"]=8]="bottom-left",Ws[Ws["bottom-right"]=9]="bottom-right";const Hh=7,X1=Number.POSITIVE_INFINITY;function vv(c,l){return l[1]!==X1?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-Hh;break;case"bottom-right":case"bottom-left":case"bottom":K=-w+Hh}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-Hh;break;case"bottom-right":case"bottom-left":T=-K+Hh;break;case"bottom":T=-y+Hh;break;case"top":T=y-Hh}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 J1(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,j=[];for(let Z=0;Z<D.length;Z+=2){const ne=j[Z]=D[Z],Ae=D[Z+1].map(_e=>_e*zt);ne.startsWith("top")?Ae[1]-=Hh:ne.startsWith("bottom")&&(Ae[1]+=Hh),j[Z+1]=Ae}return new qi(j)}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,X1]:w.get("text-offset").evaluate(l,{},d).map(Z=>Z*zt);const j=[];for(const Z of K)j.push(Z,vv(Z,D));return new qi(j)}return null}function eg(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 Jb(c,l,d,y,w,T,K,D,j,Z,ne){let Ae=T.textMaxSize.evaluate(l,{});Ae===void 0&&(Ae=K);const _e=c.layers[0].layout,Ee=_e.get("icon-offset").evaluate(l,{},ne),Ke=Cv(d.horizontal),We=K/24,qe=c.tilePixelRatio*We,st=c.tilePixelRatio*Ae/24,Ot=c.tilePixelRatio*D,ct=c.tilePixelRatio*_e.get("symbol-spacing"),_t=_e.get("text-padding")*c.tilePixelRatio,nn=function(On,Fr,wr,Fi=1){const da=On.get("icon-padding").evaluate(Fr,{},wr),ha=da&&da.values;return[ha[0]*Fi,ha[1]*Fi,ha[2]*Fi,ha[3]*Fi]}(_e,l,ne,c.tilePixelRatio),cn=_e.get("text-max-angle")/180*Math.PI,Un=_e.get("text-rotation-alignment")!=="viewport"&&_e.get("symbol-placement")!=="point",Cr=_e.get("icon-rotation-alignment")==="map"&&_e.get("symbol-placement")!=="point",qn=_e.get("symbol-placement"),wn=ct/2,gn=_e.get("icon-text-fit");let lr;y&&gn!=="none"&&(c.allowVerticalPlacement&&d.vertical&&(lr=Ob(y,d.vertical,gn,_e.get("icon-text-fit-padding"),Ee,We)),Ke&&(y=Ob(y,Ke,gn,_e.get("icon-text-fit-padding"),Ee,We)));const Rn=(On,Fr)=>{Fr.x<0||Fr.x>=_a||Fr.y<0||Fr.y>=_a||function(wr,Fi,da,ha,Ra,ou,au,ds,Ss,Vo,Ns,su,Gs,Qs,Wl,lu,Bl,hs,Xr,Es,ii,kl,Il,ci,YA){const qA=wr.addToLineVertexArray(Fi,da);let Ju,Xd,HA,CA,Bu=0,Jd=0,f0=0,tx=0,Ev=-1,Ov=-1;const eh={};let nx=Ui("");if(wr.allowVerticalPlacement&&ha.vertical){const Nl=ds.layout.get("text-rotate").evaluate(ii,{},ci)+90;HA=new Z1(Ss,Fi,Vo,Ns,su,ha.vertical,Gs,Qs,Wl,Nl),au&&(CA=new Z1(Ss,Fi,Vo,Ns,su,au,Bl,hs,Wl,Nl))}if(Ra){const Nl=ds.layout.get("icon-rotate").evaluate(ii,{}),bA=ds.layout.get("icon-text-fit")!=="none",Vh=Zb(Ra,Nl,Il,bA),Mc=au?Zb(au,Nl,Il,bA):void 0;Xd=new Z1(Ss,Fi,Vo,Ns,su,Ra,Bl,hs,!1,Nl),Bu=4*Vh.length;const Hf=wr.iconSizeData;let ud=null;Hf.kind==="source"?(ud=[ld*ds.layout.get("icon-size").evaluate(ii,{})],ud[0]>$h&&ke(`${wr.layerIds[0]}: Value for "icon-size" is >= ${qf}. Reduce your "icon-size".`)):Hf.kind==="composite"&&(ud=[ld*kl.compositeIconSizes[0].evaluate(ii,{},ci),ld*kl.compositeIconSizes[1].evaluate(ii,{},ci)],(ud[0]>$h||ud[1]>$h)&&ke(`${wr.layerIds[0]}: Value for "icon-size" is >= ${qf}. Reduce your "icon-size".`)),wr.addSymbols(wr.icon,Vh,ud,Es,Xr,ii,s.ah.none,Fi,qA.lineStartIndex,qA.lineLength,-1,ci),Ev=wr.icon.placedSymbolArray.length-1,Mc&&(Jd=4*Mc.length,wr.addSymbols(wr.icon,Mc,ud,Es,Xr,ii,s.ah.vertical,Fi,qA.lineStartIndex,qA.lineLength,-1,ci),Ov=wr.icon.placedSymbolArray.length-1)}const rx=Object.keys(ha.horizontal);for(const Nl of rx){const bA=ha.horizontal[Nl];if(!Ju){nx=Ui(bA.text);const Mc=ds.layout.get("text-rotate").evaluate(ii,{},ci);Ju=new Z1(Ss,Fi,Vo,Ns,su,bA,Gs,Qs,Wl,Mc)}const Vh=bA.positionedLines.length===1;if(f0+=_v(wr,Fi,bA,ou,ds,Wl,ii,lu,qA,ha.vertical?s.ah.horizontal:s.ah.horizontalOnly,Vh?rx:[Nl],eh,Ev,kl,ci),Vh)break}ha.vertical&&(tx+=_v(wr,Fi,ha.vertical,ou,ds,Wl,ii,lu,qA,s.ah.vertical,["vertical"],eh,Ov,kl,ci));const ww=Ju?Ju.boxStartIndex:wr.collisionBoxArray.length,Bv=Ju?Ju.boxEndIndex:wr.collisionBoxArray.length,Mw=HA?HA.boxStartIndex:wr.collisionBoxArray.length,kv=HA?HA.boxEndIndex:wr.collisionBoxArray.length,Sw=Xd?Xd.boxStartIndex:wr.collisionBoxArray.length,Ew=Xd?Xd.boxEndIndex:wr.collisionBoxArray.length,Ow=CA?CA.boxStartIndex:wr.collisionBoxArray.length,Tl=CA?CA.boxEndIndex:wr.collisionBoxArray.length;let Va=-1;const ig=(Nl,bA)=>Nl&&Nl.circleDiameter?Math.max(Nl.circleDiameter,bA):bA;Va=ig(Ju,Va),Va=ig(HA,Va),Va=ig(Xd,Va),Va=ig(CA,Va);const ix=Va>-1?1:0;ix&&(Va*=YA/zt),wr.glyphOffsetArray.length>=Yp.MAX_GLYPHS&&ke("Too many glyphs being rendered in a tile. See https://github.com/mapbox/mapbox-gl-js/issues/2907"),ii.sortKey!==void 0&&wr.addToSortKeyRanges(wr.symbolInstances.length,ii.sortKey);const Bw=J1(ds,ii,ci),[ox,kw]=function(Nl,bA){const Vh=Nl.length,Mc=bA==null?void 0:bA.values;if((Mc==null?void 0:Mc.length)>0)for(let Hf=0;Hf<Mc.length;Hf+=2){const ud=Mc[Hf+1];Nl.emplaceBack(s.ap[Mc[Hf]],ud[0],ud[1])}return[Vh,Nl.length]}(wr.textAnchorOffsets,Bw);wr.symbolInstances.emplaceBack(Fi.x,Fi.y,eh.right>=0?eh.right:-1,eh.center>=0?eh.center:-1,eh.left>=0?eh.left:-1,eh.vertical||-1,Ev,Ov,nx,ww,Bv,Mw,kv,Sw,Ew,Ow,Tl,Vo,f0,tx,Bu,Jd,ix,0,Gs,Va,ox,kw)}(c,Fr,On,d,y,w,lr,c.layers[0],c.collisionBoxArray,l.index,l.sourceLayerIndex,c.index,qe,[_t,_t,_t,_t],Un,j,Ot,nn,Cr,Ee,l,T,Z,ne,K)};if(qn==="line")for(const On of Yb(l.geometry,0,0,_a,_a)){const Fr=gw(On,ct,cn,d.vertical||Ke,y,24,st,c.overscaling,_a);for(const wr of Fr)Ke&&bw(c,Ke.text,wn,wr)||Rn(On,wr)}else if(qn==="line-center"){for(const On of l.geometry)if(On.length>1){const Fr=mw(On,cn,d.vertical||Ke,y,24,st);Fr&&Rn(On,Fr)}}else if(l.type==="Polygon")for(const On of Gd(l.geometry,0)){const Fr=_w(On,16);Rn(On[0],new qh(Fr.x,Fr.y,0))}else if(l.type==="LineString")for(const On of l.geometry)Rn(On,new qh(On[0].x,On[0].y,0));else if(l.type==="Point")for(const On of l.geometry)for(const Fr of On)Rn([Fr],new qh(Fr.x,Fr.y,0))}function _v(c,l,d,y,w,T,K,D,j,Z,ne,Ae,_e,Ee,Ke){const We=function(Ot,ct,_t,nn,cn,Un,Cr,qn){const wn=nn.layout.get("text-rotate").evaluate(Un,{})*Math.PI/180,gn=[];for(const lr of ct.positionedLines)for(const Rn of lr.positionedGlyphs){if(!Rn.rect)continue;const On=Rn.rect||{};let Fr=yA+1,wr=!0,Fi=1,da=0;const ha=(cn||qn)&&Rn.vertical,Ra=Rn.metrics.advance*Rn.scale/2;if(qn&&ct.verticalizable&&(da=lr.lineOffset/2-(Rn.imageName?-(zt-Rn.metrics.width*Rn.scale)/2:(Rn.scale-1)*zt)),Rn.imageName){const Es=Cr[Rn.imageName];wr=Es.sdf,Fi=Es.pixelRatio,Fr=Ha/Fi}const ou=cn?[Rn.x+Ra,Rn.y]:[0,0];let au=cn?[0,0]:[Rn.x+Ra+_t[0],Rn.y+_t[1]-da],ds=[0,0];ha&&(ds=au,au=[0,0]);const Ss=Rn.metrics.isDoubleResolution?2:1,Vo=(Rn.metrics.left-Fr)*Rn.scale-Ra+au[0],Ns=(-Rn.metrics.top-Fr)*Rn.scale+au[1],su=Vo+On.w/Ss*Rn.scale/Fi,Gs=Ns+On.h/Ss*Rn.scale/Fi,Qs=new B(Vo,Ns),Wl=new B(su,Ns),lu=new B(Vo,Gs),Bl=new B(su,Gs);if(ha){const Es=new B(-Ra,Ra-Qp),ii=-Math.PI/2,kl=zt/2-Ra,Il=new B(5-Qp-kl,-(Rn.imageName?kl:0)),ci=new B(...ds);Qs._rotateAround(ii,Es)._add(Il)._add(ci),Wl._rotateAround(ii,Es)._add(Il)._add(ci),lu._rotateAround(ii,Es)._add(Il)._add(ci),Bl._rotateAround(ii,Es)._add(Il)._add(ci)}if(wn){const Es=Math.sin(wn),ii=Math.cos(wn),kl=[ii,-Es,Es,ii];Qs._matMult(kl),Wl._matMult(kl),lu._matMult(kl),Bl._matMult(kl)}const hs=new B(0,0),Xr=new B(0,0);gn.push({tl:Qs,tr:Wl,bl:lu,br:Bl,tex:On,writingMode:ct.writingMode,glyphOffset:ou,sectionIndex:Rn.sectionIndex,isSDF:wr,pixelOffsetTL:hs,pixelOffsetBR:Xr,minFontScaleX:0,minFontScaleY:0})}return gn}(0,d,D,w,T,K,y,c.allowVerticalPlacement),qe=c.textSizeData;let st=null;qe.kind==="source"?(st=[ld*w.layout.get("text-size").evaluate(K,{})],st[0]>$h&&ke(`${c.layerIds[0]}: Value for "text-size" is >= ${qf}. Reduce your "text-size".`)):qe.kind==="composite"&&(st=[ld*Ee.compositeTextSizes[0].evaluate(K,{},Ke),ld*Ee.compositeTextSizes[1].evaluate(K,{},Ke)],(st[0]>$h||st[1]>$h)&&ke(`${c.layerIds[0]}: Value for "text-size" is >= ${qf}. Reduce your "text-size".`)),c.addSymbols(c.text,We,st,D,T,K,Z,l,j.lineStartIndex,j.lineLength,_e,Ke);for(const Ot of ne)Ae[Ot]=c.text.placedSymbolArray.length-1;return 4*We.length}function Cv(c){for(const l in c)return c[l];return null}function bw(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 ex=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array];class bv{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=ex[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 bv(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=ex.indexOf(this.ArrayType),K=2*l*this.ArrayType.BYTES_PER_ELEMENT,D=l*this.IndexArrayType.BYTES_PER_ELEMENT,j=(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+j,2*l),this._pos=2*l,this._finished=!0):(this.data=new ArrayBuffer(8+K+D+j),this.ids=new this.IndexArrayType(this.data,8,l),this.coords=new this.ArrayType(this.data,8+D+j,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 Vp(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,j=[0,T.length-1,0],Z=[];for(;j.length;){const ne=j.pop()||0,Ae=j.pop()||0,_e=j.pop()||0;if(Ae-_e<=D){for(let qe=_e;qe<=Ae;qe++){const st=K[2*qe],Ot=K[2*qe+1];st>=l&&st<=y&&Ot>=d&&Ot<=w&&Z.push(T[qe])}continue}const Ee=_e+Ae>>1,Ke=K[2*Ee],We=K[2*Ee+1];Ke>=l&&Ke<=y&&We>=d&&We<=w&&Z.push(T[Ee]),(ne===0?l<=Ke:d<=We)&&(j.push(_e),j.push(Ee-1),j.push(1-ne)),(ne===0?y>=Ke:w>=We)&&(j.push(Ee+1),j.push(Ae),j.push(1-ne))}return Z}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],j=[],Z=y*y;for(;D.length;){const ne=D.pop()||0,Ae=D.pop()||0,_e=D.pop()||0;if(Ae-_e<=K){for(let qe=_e;qe<=Ae;qe++)tg(T[2*qe],T[2*qe+1],l,d)<=Z&&j.push(w[qe]);continue}const Ee=_e+Ae>>1,Ke=T[2*Ee],We=T[2*Ee+1];tg(Ke,We,l,d)<=Z&&j.push(w[Ee]),(ne===0?l-y<=Ke:d-y<=We)&&(D.push(_e),D.push(Ee-1),D.push(1-ne)),(ne===0?l+y>=Ke:d+y>=We)&&(D.push(Ee+1),D.push(Ae),D.push(1-ne))}return j}}function Vp(c,l,d,y,w,T){if(w-y<=d)return;const K=y+w>>1;c0(c,l,K,y,w,T),Vp(c,l,d,y,K-1,1-T),Vp(c,l,d,K+1,w,1-T)}function c0(c,l,d,y,w,T){for(;w>y;){if(w-y>600){const Z=w-y+1,ne=d-y+1,Ae=Math.log(Z),_e=.5*Math.exp(2*Ae/3),Ee=.5*Math.sqrt(Ae*_e*(Z-_e)/Z)*(ne-Z/2<0?-1:1);c0(c,l,d,Math.max(y,Math.floor(d-ne*_e/Z+Ee)),Math.min(w,Math.floor(d+(Z-ne)*_e/Z+Ee)),T)}const K=l[2*d+T];let D=y,j=w;for(d0(c,l,y,d),l[2*w+T]>K&&d0(c,l,y,w);D<j;){for(d0(c,l,D,j),D++,j--;l[2*D+T]<K;)D++;for(;l[2*j+T]>K;)j--}l[2*y+T]===K?d0(c,l,y,j):(j++,d0(c,l,j,w)),j<=d&&(y=j+1),d<=j&&(w=j-1)}}function d0(c,l,d,y){xv(c,d,y),xv(l,2*d,2*y),xv(l,2*d+1,2*y+1)}function xv(c,l,d){const y=c[l];c[l]=c[d],c[d]=y}function tg(c,l,d,y){const w=c-d,T=l-y;return w*w+T*T}var ng;s.bc=void 0,(ng=s.bc||(s.bc={})).create="create",ng.load="load",ng.fullLoad="fullLoad";let rg=null,h0=[];const wv=1e3/60,Mv="loadTime",Sv="fullLoadTime",xw={mark(c){performance.mark(c)},frame(c){const l=c;rg!=null&&h0.push(l-rg),rg=l},clearMetrics(){rg=null,h0=[],performance.clearMeasures(Mv),performance.clearMeasures(Sv);for(const c in s.bc)performance.clearMarks(s.bc[c])},getPerformanceMetrics(){performance.measure(Mv,s.bc.create,s.bc.load),performance.measure(Sv,s.bc.create,s.bc.fullLoad);const c=performance.getEntriesByName(Mv)[0].duration,l=performance.getEntriesByName(Sv)[0].duration,d=h0.length,y=1/(h0.reduce((T,K)=>T+K,0)/d/1e3),w=h0.filter(T=>T>wv).reduce((T,K)=>T+(K-wv)/wv,0);return{loadTime:c,fullLoadTime:l,fps:y,percentDroppedFrames:w/(d+w)*100,totalFrames:d}}};s.$=Pr,s.A=zd,s.B=function(c){if(kt==null){const l=c.navigator?c.navigator.userAgent:null;kt=!!c.safari||!(!l||!(/\b(iPad|iPhone|iPod)\b/.test(l)||l.match("Safari")&&!l.match("Chrome")))}return kt},s.C=class{constructor(c,l){this.target=c,this.mapId=l,this.resolveRejects={},this.tasks={},this.taskQueue=[],this.abortControllers={},this.messageHandlers={},this.invoker=new fw(()=>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=Bt(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:hA(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(Bt(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 a(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(dc(l.error)):w.resolve(dc(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=dc(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?hA(l):null,data:hA(d,y)};this.target.postMessage(w,{transfer:y})}remove(){this.invoker.remove(),this.subscription.unsubscribe()}},s.D=vr,s.E=Rt,s.F=function(){var c=new zd(16);return zd!=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},s.G=Lt,s.H=function(c,l,d){var y,w,T,K,D,j,Z,ne,Ae,_e,Ee,Ke,We=d[0],qe=d[1],st=d[2];return l===c?(c[12]=l[0]*We+l[4]*qe+l[8]*st+l[12],c[13]=l[1]*We+l[5]*qe+l[9]*st+l[13],c[14]=l[2]*We+l[6]*qe+l[10]*st+l[14],c[15]=l[3]*We+l[7]*qe+l[11]*st+l[15]):(w=l[1],T=l[2],K=l[3],D=l[4],j=l[5],Z=l[6],ne=l[7],Ae=l[8],_e=l[9],Ee=l[10],Ke=l[11],c[0]=y=l[0],c[1]=w,c[2]=T,c[3]=K,c[4]=D,c[5]=j,c[6]=Z,c[7]=ne,c[8]=Ae,c[9]=_e,c[10]=Ee,c[11]=Ke,c[12]=y*We+D*qe+Ae*st+l[12],c[13]=w*We+j*qe+_e*st+l[13],c[14]=T*We+Z*qe+Ee*st+l[14],c[15]=K*We+ne*qe+Ke*st+l[15]),c},s.I=tl,s.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},s.K=Kp,s.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},s.M=Yh,s.N=Lb,s.O=pv,s.P=B,s.Q=_A,s.R=cl,s.S=$,s.T=Tp,s.U=q,s.V=Xe,s.W=_a,s.X=Qo,s.Y=Y1,s.Z=class extends mA{},s._=a,s.a=at,s.a$=function(c,l){return c[0]*l[0]+c[1]*l[1]+c[2]*l[2]+c[3]*l[3]},s.a0=mv,s.a1=H,s.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");Ue(y)||(l.crossOrigin="Anonymous"),w.src=y,l.appendChild(w)}})},s.a3=function(){return ae++},s.a4=u,s.a5=Yp,s.a6=kd,s.a7=WA,s.a8=So,s.a9=Nb,s.aA=De,s.aB=function(c,l){if(!c)return[{command:"setStyle",args:[l]}];let d=[];try{if(!vn(c.version,l.version))return[{command:"setStyle",args:[l]}];vn(c.center,l.center)||d.push({command:"setCenter",args:[l.center]}),vn(c.zoom,l.zoom)||d.push({command:"setZoom",args:[l.zoom]}),vn(c.bearing,l.bearing)||d.push({command:"setBearing",args:[l.bearing]}),vn(c.pitch,l.pitch)||d.push({command:"setPitch",args:[l.pitch]}),vn(c.sprite,l.sprite)||d.push({command:"setSprite",args:[l.sprite]}),vn(c.glyphs,l.glyphs)||d.push({command:"setGlyphs",args:[l.glyphs]}),vn(c.transition,l.transition)||d.push({command:"setTransition",args:[l.transition]}),vn(c.light,l.light)||d.push({command:"setLight",args:[l.light]}),vn(c.terrain,l.terrain)||d.push({command:"setTerrain",args:[l.terrain]});const y={},w=[];(function(K,D,j,Z){let ne;for(ne in D=D||{},K=K||{})Object.prototype.hasOwnProperty.call(K,ne)&&(Object.prototype.hasOwnProperty.call(D,ne)||Mr(ne,j,Z));for(ne in D)Object.prototype.hasOwnProperty.call(D,ne)&&(Object.prototype.hasOwnProperty.call(K,ne)?vn(K[ne],D[ne])||(K[ne].type==="geojson"&&D[ne].type==="geojson"&&gr(K,D,ne)?Xn(j,{command:"setGeoJSONSourceData",args:[ne,D[ne].data]}):Gr(ne,D,j,Z)):cr(ne,D,j))})(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,j){D=D||[];const Z=(K=K||[]).map(Se),ne=D.map(Se),Ae=K.reduce(X,{}),_e=D.reduce(X,{}),Ee=Z.slice(),Ke=Object.create(null);let We,qe,st,Ot,ct;for(let _t=0,nn=0;_t<Z.length;_t++)We=Z[_t],Object.prototype.hasOwnProperty.call(_e,We)?nn++:(Xn(j,{command:"removeLayer",args:[We]}),Ee.splice(Ee.indexOf(We,nn),1));for(let _t=0,nn=0;_t<ne.length;_t++)We=ne[ne.length-1-_t],Ee[Ee.length-1-_t]!==We&&(Object.prototype.hasOwnProperty.call(Ae,We)?(Xn(j,{command:"removeLayer",args:[We]}),Ee.splice(Ee.lastIndexOf(We,Ee.length-nn),1)):nn++,Ot=Ee[Ee.length-_t],Xn(j,{command:"addLayer",args:[_e[We],Ot]}),Ee.splice(Ee.length-_t,0,We),Ke[We]=!0);for(let _t=0;_t<ne.length;_t++)if(We=ne[_t],qe=Ae[We],st=_e[We],!Ke[We]&&!vn(qe,st))if(vn(qe.source,st.source)&&vn(qe["source-layer"],st["source-layer"])&&vn(qe.type,st.type)){for(ct in mi(qe.layout,st.layout,j,We,null,"setLayoutProperty"),mi(qe.paint,st.paint,j,We,null,"setPaintProperty"),vn(qe.filter,st.filter)||Xn(j,{command:"setFilter",args:[We,st.filter]}),vn(qe.minzoom,st.minzoom)&&vn(qe.maxzoom,st.maxzoom)||Xn(j,{command:"setLayerZoomRange",args:[We,st.minzoom,st.maxzoom]}),qe)Object.prototype.hasOwnProperty.call(qe,ct)&&ct!=="layout"&&ct!=="paint"&&ct!=="filter"&&ct!=="metadata"&&ct!=="minzoom"&&ct!=="maxzoom"&&(ct.indexOf("paint.")===0?mi(qe[ct],st[ct],j,We,ct.slice(6),"setPaintProperty"):vn(qe[ct],st[ct])||Xn(j,{command:"setLayerProperty",args:[We,ct,st[ct]]}));for(ct in st)Object.prototype.hasOwnProperty.call(st,ct)&&!Object.prototype.hasOwnProperty.call(qe,ct)&&ct!=="layout"&&ct!=="paint"&&ct!=="filter"&&ct!=="metadata"&&ct!=="minzoom"&&ct!=="maxzoom"&&(ct.indexOf("paint.")===0?mi(qe[ct],st[ct],j,We,ct.slice(6),"setPaintProperty"):vn(qe[ct],st[ct])||Xn(j,{command:"setLayerProperty",args:[We,ct,st[ct]]}))}else Xn(j,{command:"removeLayer",args:[We]}),Ot=Ee[Ee.lastIndexOf(We)+1],Xn(j,{command:"addLayer",args:[st,Ot]})}(T,l.layers,d)}catch(y){console.warn("Unable to compute style diff:",y),d=[{command:"setStyle",args:[l]}]}return d},s.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},s.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},s.aE=ye,s.aF=Oe,s.aG=class extends Ta{constructor(c,l){super(c,l),this.current=0}set(c){this.current!==c&&(this.current=c,this.gl.uniform1i(this.location,c))}},s.aH=Eo,s.aI=class extends Ta{constructor(c,l){super(c,l),this.current=Us}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}}},s.aJ=jl,s.aK=class extends Ta{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]))}},s.aL=class extends Ta{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]))}},s.aM=zA,s.aN=function(c,l,d,y,w,T,K){var D=1/(l-d),j=1/(y-w),Z=1/(T-K);return c[0]=-2*D,c[1]=0,c[2]=0,c[3]=0,c[4]=0,c[5]=-2*j,c[6]=0,c[7]=0,c[8]=0,c[9]=0,c[10]=2*Z,c[11]=0,c[12]=(l+d)*D,c[13]=(w+y)*j,c[14]=(K+T)*Z,c[15]=1,c},s.aO=bi,s.aP=Pp,s.aQ=class extends va{},s.aR=Je,s.aS=class extends gc{},s.aT=function(c){return c<=1?1:Math.pow(2,Math.ceil(Math.log(c)/Math.LN2))},s.aU=td,s.aV=Ie,s.aW=class extends El{},s.aX=dn,s.aY=function(c,l){var d=c[0],y=c[1],w=c[2],T=c[3],K=c[4],D=c[5],j=c[6],Z=c[7],ne=c[8],Ae=c[9],_e=c[10],Ee=c[11],Ke=c[12],We=c[13],qe=c[14],st=c[15],Ot=l[0],ct=l[1],_t=l[2],nn=l[3],cn=l[4],Un=l[5],Cr=l[6],qn=l[7],wn=l[8],gn=l[9],lr=l[10],Rn=l[11],On=l[12],Fr=l[13],wr=l[14],Fi=l[15];return Math.abs(d-Ot)<=Al*Math.max(1,Math.abs(d),Math.abs(Ot))&&Math.abs(y-ct)<=Al*Math.max(1,Math.abs(y),Math.abs(ct))&&Math.abs(w-_t)<=Al*Math.max(1,Math.abs(w),Math.abs(_t))&&Math.abs(T-nn)<=Al*Math.max(1,Math.abs(T),Math.abs(nn))&&Math.abs(K-cn)<=Al*Math.max(1,Math.abs(K),Math.abs(cn))&&Math.abs(D-Un)<=Al*Math.max(1,Math.abs(D),Math.abs(Un))&&Math.abs(j-Cr)<=Al*Math.max(1,Math.abs(j),Math.abs(Cr))&&Math.abs(Z-qn)<=Al*Math.max(1,Math.abs(Z),Math.abs(qn))&&Math.abs(ne-wn)<=Al*Math.max(1,Math.abs(ne),Math.abs(wn))&&Math.abs(Ae-gn)<=Al*Math.max(1,Math.abs(Ae),Math.abs(gn))&&Math.abs(_e-lr)<=Al*Math.max(1,Math.abs(_e),Math.abs(lr))&&Math.abs(Ee-Rn)<=Al*Math.max(1,Math.abs(Ee),Math.abs(Rn))&&Math.abs(Ke-On)<=Al*Math.max(1,Math.abs(Ke),Math.abs(On))&&Math.abs(We-Fr)<=Al*Math.max(1,Math.abs(We),Math.abs(Fr))&&Math.abs(qe-wr)<=Al*Math.max(1,Math.abs(qe),Math.abs(wr))&&Math.abs(st-Fi)<=Al*Math.max(1,Math.abs(st),Math.abs(Fi))},s.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},s.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},s.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},s.ab=function(c,l){const d=[];for(const y in c)y in l||d.push(y);return d},s.ac=me,s.ad=function(c,l,d){var y=Math.sin(d),w=Math.cos(d),T=l[0],K=l[1],D=l[2],j=l[3],Z=l[4],ne=l[5],Ae=l[6],_e=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+Z*y,c[1]=K*w+ne*y,c[2]=D*w+Ae*y,c[3]=j*w+_e*y,c[4]=Z*w-T*y,c[5]=ne*w-K*y,c[6]=Ae*w-D*y,c[7]=_e*w-j*y,c},s.ae=function(c){var l=new zd(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},s.af=Fp,s.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?me(Dn.interpolationFactor(w,l,T,K),0,1):0;c.kind==="camera"?y=mt.number(c.minSize,c.maxSize,D):d=D}return{uSizeT:d,uSize:y}},s.ai=function(c,{uSize:l,uSizeT:d},{lowerSize:y,upperSize:w}){return c.kind==="source"?y/ld:c.kind==="composite"?mt.number(y/ld,w/ld,d):l},s.aj=Av,s.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,j=K*T-D*w;if(j===0)return null;const Z=(D*(c.y-d.y)-K*(c.x-d.x))/j;return new B(c.x+Z*T,c.y+Z*w)},s.al=Yb,s.am=_c,s.an=Zm,s.ao=zt,s.aq=uv,s.ar=function(c,l){var d=l[0],y=l[1],w=l[2],T=l[3],K=l[4],D=l[5],j=l[6],Z=l[7],ne=l[8],Ae=l[9],_e=l[10],Ee=l[11],Ke=l[12],We=l[13],qe=l[14],st=l[15],Ot=d*D-y*K,ct=d*j-w*K,_t=d*Z-T*K,nn=y*j-w*D,cn=y*Z-T*D,Un=w*Z-T*j,Cr=ne*We-Ae*Ke,qn=ne*qe-_e*Ke,wn=ne*st-Ee*Ke,gn=Ae*qe-_e*We,lr=Ae*st-Ee*We,Rn=_e*st-Ee*qe,On=Ot*Rn-ct*lr+_t*gn+nn*wn-cn*qn+Un*Cr;return On?(c[0]=(D*Rn-j*lr+Z*gn)*(On=1/On),c[1]=(w*lr-y*Rn-T*gn)*On,c[2]=(We*Un-qe*cn+st*nn)*On,c[3]=(_e*cn-Ae*Un-Ee*nn)*On,c[4]=(j*wn-K*Rn-Z*qn)*On,c[5]=(d*Rn-w*wn+T*qn)*On,c[6]=(qe*_t-Ke*Un-st*ct)*On,c[7]=(ne*Un-_e*_t+Ee*ct)*On,c[8]=(K*lr-D*wn+Z*Cr)*On,c[9]=(y*wn-d*lr-T*Cr)*On,c[10]=(Ke*cn-We*_t+st*Ot)*On,c[11]=(Ae*_t-ne*cn-Ee*Ot)*On,c[12]=(D*qn-K*gn-j*Cr)*On,c[13]=(d*gn-y*qn+w*Cr)*On,c[14]=(We*ct-Ke*nn-qe*Ot)*On,c[15]=(ne*nn-Ae*ct+_e*Ot)*On,c):null},s.as=eg,s.at=lv,s.au=bv,s.av=function(){const c={},l=pt.$version;for(const d in pt.$root){const y=pt.$root[d];if(y.required){let w=null;w=d==="version"?l:y.type==="array"?[]:{},w!=null&&(c[d]=w)}}return c},s.aw=bu,s.ax=fe,s.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]=mn(c[d],l[c[d].ref]));return c},s.az=function(c){if(c.type==="custom")return new hw(c);switch(c.type){case"background":return new cw(c);case"circle":return new Xm(c);case"fill":return new jp(c);case"fill-extrusion":return new sd(c);case"heatmap":return new jd(c);case"hillshade":return new Su(c);case"line":return new U(c);case"raster":return new dw(c);case"symbol":return new Q1(c)}},s.b=Yt,s.b0=he,s.b1=zb,s.b2=Ub,s.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},s.b4=function(c,l,d){var y=Math.sin(d),w=Math.cos(d),T=l[4],K=l[5],D=l[6],j=l[7],Z=l[8],ne=l[9],Ae=l[10],_e=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+Z*y,c[5]=K*w+ne*y,c[6]=D*w+Ae*y,c[7]=j*w+_e*y,c[8]=Z*w-T*y,c[9]=ne*w-K*y,c[10]=Ae*w-D*y,c[11]=_e*w-j*y,c},s.b5=oe,s.b6=ce,s.b7=function(c){return c*Math.PI/180},s.b8=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},s.b9=class extends $u{},s.ba=fv,s.bb=xw,s.bd=Me,s.be=function(c,l){at.REGISTERED_PROTOCOLS[c]=l},s.bf=function(c){delete at.REGISTERED_PROTOCOLS[c]},s.bg=function(c,l){const d={};for(let w=0;w<c.length;w++){const T=l&&l[c[w].id]||Rl(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},s.bh=Nn,s.bi=Wb,s.bj=Gb,s.bk=Vd,s.bl=function(c){c.bucket.createArrays(),c.bucket.tilePixelRatio=_a/(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 So(c.bucket.zoom+1),c.canonical),layoutTextSize:y["text-size"].possiblyEvaluate(new So(c.bucket.zoom+1),c.canonical),textMaxSize:y["text-size"].possiblyEvaluate(new So(18))};if(c.bucket.textSizeData.kind==="composite"){const{minZoom:Z,maxZoom:ne}=c.bucket.textSizeData;w.compositeTextSizes=[y["text-size"].possiblyEvaluate(new So(Z),c.canonical),y["text-size"].possiblyEvaluate(new So(ne),c.canonical)]}if(c.bucket.iconSizeData.kind==="composite"){const{minZoom:Z,maxZoom:ne}=c.bucket.iconSizeData;w.compositeIconSizes=[y["icon-size"].possiblyEvaluate(new So(Z),c.canonical),y["icon-size"].possiblyEvaluate(new So(ne),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"),j=d.get("text-size");for(const Z of c.bucket.features){const ne=d.get("text-font").evaluate(Z,{},c.canonical).join(","),Ae=j.evaluate(Z,{},c.canonical),_e=w.layoutTextSize.evaluate(Z,{},c.canonical),Ee=w.layoutIconSize.evaluate(Z,{},c.canonical),Ke={horizontal:{},vertical:void 0},We=Z.text;let qe,st=[0,0];if(We){const _t=We.toString(),nn=d.get("text-letter-spacing").evaluate(Z,{},c.canonical)*zt,cn=LA(_t)?nn:0,Un=d.get("text-anchor").evaluate(Z,{},c.canonical),Cr=J1(l,Z,c.canonical);if(!Cr){const Rn=d.get("text-radial-offset").evaluate(Z,{},c.canonical);st=Rn?vv(Un,[Rn*zt,X1]):d.get("text-offset").evaluate(Z,{},c.canonical).map(On=>On*zt)}let qn=K?"center":d.get("text-justify").evaluate(Z,{},c.canonical);const wn=d.get("symbol-placement"),gn=wn==="point"?d.get("text-max-width").evaluate(Z,{},c.canonical)*zt:0,lr=()=>{c.bucket.allowVerticalPlacement&&hc(_t)&&(Ke.vertical=j1(We,c.glyphMap,c.glyphPositions,c.imagePositions,ne,gn,T,Un,"left",cn,st,s.ah.vertical,!0,wn,_e,Ae))};if(!K&&Cr){const Rn=new Set;if(qn==="auto")for(let Fr=0;Fr<Cr.values.length;Fr+=2)Rn.add(eg(Cr.values[Fr]));else Rn.add(qn);let On=!1;for(const Fr of Rn)if(!Ke.horizontal[Fr])if(On)Ke.horizontal[Fr]=Ke.horizontal[0];else{const wr=j1(We,c.glyphMap,c.glyphPositions,c.imagePositions,ne,gn,T,"center",Fr,cn,st,s.ah.horizontal,!1,wn,_e,Ae);wr&&(Ke.horizontal[Fr]=wr,On=wr.positionedLines.length===1)}lr()}else{qn==="auto"&&(qn=eg(Un));const Rn=j1(We,c.glyphMap,c.glyphPositions,c.imagePositions,ne,gn,T,Un,qn,cn,st,s.ah.horizontal,!1,wn,_e,Ae);Rn&&(Ke.horizontal[qn]=Rn),lr(),hc(_t)&&K&&D&&(Ke.vertical=j1(We,c.glyphMap,c.glyphPositions,c.imagePositions,ne,gn,T,Un,qn,cn,st,s.ah.vertical,!1,wn,_e,Ae))}}let Ot=!1;if(Z.icon&&Z.icon.name){const _t=c.imageMap[Z.icon.name];_t&&(qe=aw(c.imagePositions[Z.icon.name],d.get("icon-offset").evaluate(Z,{},c.canonical),d.get("icon-anchor").evaluate(Z,{},c.canonical)),Ot=!!_t.sdf,c.bucket.sdfIcons===void 0?c.bucket.sdfIcons=Ot:c.bucket.sdfIcons!==Ot&&ke("Style sheet warning: Cannot mix SDF and non-SDF icons in one buffer"),(_t.pixelRatio!==c.bucket.pixelRatio||d.get("icon-rotate").constantOr(1)!==0)&&(c.bucket.iconsNeedLinear=!0))}const ct=Cv(Ke.horizontal)||Ke.vertical;c.bucket.iconsInText=!!ct&&ct.iconsInText,(ct||qe)&&Jb(c.bucket,Z,Ke,qe,c.imageMap,w,_e,Ee,st,Ot,c.canonical)}c.showCollisionBoxes&&c.bucket.generateCollisionDebugBuffers()},s.bm=Qh,s.bn=zh,s.bo=qd,s.bp=Xu,s.bq=GA,s.br=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}},s.bs=function(c,l,d,y,w){return a(this,void 0,void 0,function*(){if(q())try{return yield Xe(c,l,d,y,w)}catch{}return function(T,K,D,j,Z){const ne=T.width,Ae=T.height;rt&&ot||(rt=new OffscreenCanvas(ne,Ae),ot=rt.getContext("2d",{willReadFrequently:!0})),rt.width=ne,rt.height=Ae,ot.drawImage(T,0,0,ne,Ae);const _e=ot.getImageData(K,D,j,Z);return ot.clearRect(0,0,ne,Ae),_e.data}(c,l,d,y,w)})},s.bt=jb,s.bu=h,s.bv=g,s.bw=hn,s.bx=uc,s.by=function(c){return c.message===on},s.bz=Gu,s.c=gt,s.d=c=>a(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.`)}}),s.e=V,s.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=jt})},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):jt}),s.g=It,s.h=(c,l)=>xe(V(c,{type:"json"}),l),s.i=Bt,s.j=Ut,s.k=bt,s.l=(c,l)=>xe(V(c,{type:"arrayBuffer"}),l),s.m=xe,s.n=function(c){return new GA(c).readFields(QA,[])},s.o=La,s.p=wc,s.q=Jo,s.r=xh,s.s=Ue,s.t=DA,s.u=$n,s.v=pt,s.w=ke,s.x=to,s.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)}},s.z=mt}),i("worker",["./shared"],function(s){class a{constructor(de){this.keyCache={},de&&this.replace(de)}replace(de){this._layerConfigs={},this._layers={},this.update(de,[])}update(de,Ce){for(const ze of de){this._layerConfigs[ze.id]=ze;const tt=this._layers[ze.id]=s.az(ze);tt._featureFilter=s.a6(tt.filter),this.keyCache[ze.id]&&delete this.keyCache[ze.id]}for(const ze of Ce)delete this.keyCache[ze],delete this._layerConfigs[ze],delete this._layers[ze];this.familiesBySource={};const Be=s.bg(Object.values(this._layerConfigs),this.keyCache);for(const ze of Be){const tt=ze.map(Vt=>this._layers[Vt.id]),lt=tt[0];if(lt.visibility==="none")continue;const ft=lt.source||"";let Ve=this.familiesBySource[ft];Ve||(Ve=this.familiesBySource[ft]={});const xt=lt.sourceLayer||"_geojsonTileLayer";let Xt=Ve[xt];Xt||(Xt=Ve[xt]=[]),Xt.push(tt)}}}class h{constructor(de){const Ce={},Be=[];for(const ft in de){const Ve=de[ft],xt=Ce[ft]={};for(const Xt in Ve){const Vt=Ve[+Xt];if(!Vt||Vt.bitmap.width===0||Vt.bitmap.height===0)continue;const Ht={x:0,y:0,w:Vt.bitmap.width+2,h:Vt.bitmap.height+2};Be.push(Ht),xt[Xt]={rect:Ht,metrics:Vt.metrics}}}const{w:ze,h:tt}=s.p(Be),lt=new s.o({width:ze||1,height:tt||1});for(const ft in de){const Ve=de[ft];for(const xt in Ve){const Xt=Ve[+xt];if(!Xt||Xt.bitmap.width===0||Xt.bitmap.height===0)continue;const Vt=Ce[ft][xt].rect;s.o.copy(Xt.bitmap,lt,{x:0,y:0},{x:Vt.x+1,y:Vt.y+1},Xt.bitmap)}}this.image=lt,this.positions=Ce}}s.bh("GlyphAtlas",h);class g{constructor(de){this.tileID=new s.Q(de.tileID.overscaledZ,de.tileID.wrap,de.tileID.canonical.z,de.tileID.canonical.x,de.tileID.canonical.y),this.uid=de.uid,this.zoom=de.zoom,this.pixelRatio=de.pixelRatio,this.tileSize=de.tileSize,this.source=de.source,this.overscaling=this.tileID.overscaleFactor(),this.showCollisionBoxes=de.showCollisionBoxes,this.collectResourceTiming=!!de.collectResourceTiming,this.returnDependencies=!!de.returnDependencies,this.promoteId=de.promoteId,this.inFlightDependencies=[]}parse(de,Ce,Be,ze){return s._(this,void 0,void 0,function*(){this.status="parsing",this.data=de,this.collisionBoxArray=new s.a4;const tt=new s.bi(Object.keys(de.layers).sort()),lt=new s.bj(this.tileID,this.promoteId);lt.bucketLayerIDs=[];const ft={},Ve={featureIndex:lt,iconDependencies:{},patternDependencies:{},glyphDependencies:{},availableImages:Be},xt=Ce.familiesBySource[this.source];for(const ir in xt){const ui=de.layers[ir];if(!ui)continue;ui.version===1&&s.w(`Vector tile source "${this.source}" layer "${ir}" does not use vector tile spec v2 and therefore may have some rendering errors.`);const Oi=tt.encode(ir),Yi=[];for(let _o=0;_o<ui.length;_o++){const Jr=ui.feature(_o),xo=lt.getId(Jr,ir);Yi.push({feature:Jr,id:xo,index:_o,sourceLayerIndex:Oi})}for(const _o of xt[ir]){const Jr=_o[0];Jr.source!==this.source&&s.w(`layer.source = ${Jr.source} does not equal this.source = ${this.source}`),Jr.minzoom&&this.zoom<Math.floor(Jr.minzoom)||Jr.maxzoom&&this.zoom>=Jr.maxzoom||Jr.visibility!=="none"&&(C(_o,this.zoom,Be),(ft[Jr.id]=Jr.createBucket({index:lt.bucketLayerIDs.length,layers:_o,zoom:this.zoom,pixelRatio:this.pixelRatio,overscaling:this.overscaling,collisionBoxArray:this.collisionBoxArray,sourceLayerIndex:Oi,sourceID:this.source})).populate(Yi,Ve,this.tileID.canonical),lt.bucketLayerIDs.push(_o.map(xo=>xo.id)))}}const Xt=s.aE(Ve.glyphDependencies,ir=>Object.keys(ir).map(Number));this.inFlightDependencies.forEach(ir=>ir==null?void 0:ir.abort()),this.inFlightDependencies=[];let Vt=Promise.resolve({});if(Object.keys(Xt).length){const ir=new AbortController;this.inFlightDependencies.push(ir),Vt=ze.sendAsync({type:"getGlyphs",data:{stacks:Xt,source:this.source,tileID:this.tileID,type:"glyphs"}},ir)}const Ht=Object.keys(Ve.iconDependencies);let Qn=Promise.resolve({});if(Ht.length){const ir=new AbortController;this.inFlightDependencies.push(ir),Qn=ze.sendAsync({type:"getImages",data:{icons:Ht,source:this.source,tileID:this.tileID,type:"icons"}},ir)}const Mn=Object.keys(Ve.patternDependencies);let or=Promise.resolve({});if(Mn.length){const ir=new AbortController;this.inFlightDependencies.push(ir),or=ze.sendAsync({type:"getImages",data:{icons:Mn,source:this.source,tileID:this.tileID,type:"patterns"}},ir)}const[ar,kr,jr]=yield Promise.all([Vt,Qn,or]),Lr=new h(ar),Wr=new s.bk(kr,jr);for(const ir in ft){const ui=ft[ir];ui instanceof s.a5?(C(ui.layers,this.zoom,Be),s.bl({bucket:ui,glyphMap:ar,glyphPositions:Lr.positions,imageMap:kr,imagePositions:Wr.iconPositions,showCollisionBoxes:this.showCollisionBoxes,canonical:this.tileID.canonical})):ui.hasPattern&&(ui instanceof s.bm||ui instanceof s.bn||ui instanceof s.bo)&&(C(ui.layers,this.zoom,Be),ui.addFeatures(Ve,this.tileID.canonical,Wr.patternPositions))}return this.status="done",{buckets:Object.values(ft).filter(ir=>!ir.isEmpty()),featureIndex:lt,collisionBoxArray:this.collisionBoxArray,glyphAtlasImage:Lr.image,imageAtlas:Wr,glyphMap:this.returnDependencies?ar:null,iconMap:this.returnDependencies?kr:null,glyphPositions:this.returnDependencies?Lr.positions:null}})}}function C(Fe,de,Ce){const Be=new s.a8(de);for(const ze of Fe)ze.recalculate(Be,Ce)}class B{constructor(de,Ce,Be){this.actor=de,this.layerIndex=Ce,this.availableImages=Be,this.fetching={},this.loading={},this.loaded={}}loadVectorTile(de,Ce){return s._(this,void 0,void 0,function*(){const Be=yield s.l(de.request,Ce);try{return{vectorTile:new s.bp.VectorTile(new s.bq(Be.data)),rawData:Be.data,cacheControl:Be.cacheControl,expires:Be.expires}}catch(ze){const tt=new Uint8Array(Be.data);let lt=`Unable to parse the tile at ${de.request.url}, `;throw lt+=tt[0]===31&&tt[1]===139?"please make sure the data is not gzipped and that you have configured the relevant header in the server":`got error: ${ze.messge}`,new Error(lt)}})}loadTile(de){return s._(this,void 0,void 0,function*(){const Ce=de.uid,Be=!!(de&&de.request&&de.request.collectResourceTiming)&&new s.br(de.request),ze=new g(de);this.loading[Ce]=ze;const tt=new AbortController;ze.abort=tt;try{const lt=yield this.loadVectorTile(de,tt);if(delete this.loading[Ce],!lt)return null;const ft=lt.rawData,Ve={};lt.expires&&(Ve.expires=lt.expires),lt.cacheControl&&(Ve.cacheControl=lt.cacheControl);const xt={};if(Be){const Vt=Be.finish();Vt&&(xt.resourceTiming=JSON.parse(JSON.stringify(Vt)))}ze.vectorTile=lt.vectorTile;const Xt=ze.parse(lt.vectorTile,this.layerIndex,this.availableImages,this.actor);this.loaded[Ce]=ze,this.fetching[Ce]={rawTileData:ft,cacheControl:Ve,resourceTiming:xt};try{const Vt=yield Xt;return s.e({rawTileData:ft.slice(0)},Vt,Ve,xt)}finally{delete this.fetching[Ce]}}catch(lt){throw delete this.loading[Ce],ze.status="done",this.loaded[Ce]=ze,lt}})}reloadTile(de){return s._(this,void 0,void 0,function*(){const Ce=de.uid;if(!this.loaded||!this.loaded[Ce])throw new Error("Should not be trying to reload a tile that was never loaded or has been removed");const Be=this.loaded[Ce];if(Be.showCollisionBoxes=de.showCollisionBoxes,Be.status==="parsing"){const ze=yield Be.parse(Be.vectorTile,this.layerIndex,this.availableImages,this.actor);let tt;if(this.fetching[Ce]){const{rawTileData:lt,cacheControl:ft,resourceTiming:Ve}=this.fetching[Ce];delete this.fetching[Ce],tt=s.e({rawTileData:lt.slice(0)},ze,ft,Ve)}else tt=ze;return tt}if(Be.status==="done"&&Be.vectorTile)return Be.parse(Be.vectorTile,this.layerIndex,this.availableImages,this.actor)})}abortTile(de){return s._(this,void 0,void 0,function*(){const Ce=this.loading,Be=de.uid;Ce&&Ce[Be]&&Ce[Be].abort&&(Ce[Be].abort.abort(),delete Ce[Be])})}removeTile(de){return s._(this,void 0,void 0,function*(){this.loaded&&this.loaded[de.uid]&&delete this.loaded[de.uid]})}}class k{constructor(){this.loaded={}}loadTile(de){return s._(this,void 0,void 0,function*(){const{uid:Ce,encoding:Be,rawImageData:ze,redFactor:tt,greenFactor:lt,blueFactor:ft,baseShift:Ve}=de,xt=ze.width+2,Xt=ze.height+2,Vt=s.b(ze)?new s.R({width:xt,height:Xt},yield s.bs(ze,-1,-1,xt,Xt)):ze,Ht=new s.bt(Ce,Vt,Be,tt,lt,ft,Ve);return this.loaded=this.loaded||{},this.loaded[Ce]=Ht,Ht})}removeTile(de){const Ce=this.loaded,Be=de.uid;Ce&&Ce[Be]&&delete Ce[Be]}}function P(Fe,de){if(Fe.length!==0){L(Fe[0],de);for(var Ce=1;Ce<Fe.length;Ce++)L(Fe[Ce],!de)}}function L(Fe,de){for(var Ce=0,Be=0,ze=0,tt=Fe.length,lt=tt-1;ze<tt;lt=ze++){var ft=(Fe[ze][0]-Fe[lt][0])*(Fe[lt][1]+Fe[ze][1]),Ve=Ce+ft;Be+=Math.abs(Ce)>=Math.abs(ft)?Ce-Ve+ft:ft-Ve+Ce,Ce=Ve}Ce+Be>=0!=!!de&&Fe.reverse()}var J=s.bu(function Fe(de,Ce){var Be,ze=de&&de.type;if(ze==="FeatureCollection")for(Be=0;Be<de.features.length;Be++)Fe(de.features[Be],Ce);else if(ze==="GeometryCollection")for(Be=0;Be<de.geometries.length;Be++)Fe(de.geometries[Be],Ce);else if(ze==="Feature")Fe(de.geometry,Ce);else if(ze==="Polygon")P(de.coordinates,Ce);else if(ze==="MultiPolygon")for(Be=0;Be<de.coordinates.length;Be++)P(de.coordinates[Be],Ce);return de});const N=s.bp.VectorTileFeature.prototype.toGeoJSON;var $={exports:{}},q=s.bv,oe=s.bp.VectorTileFeature,ce=me;function me(Fe,de){this.options=de||{},this.features=Fe,this.length=Fe.length}function he(Fe,de){this.id=typeof Fe.id=="number"?Fe.id:void 0,this.type=Fe.type,this.rawGeometry=Fe.type===1?[Fe.geometry]:Fe.geometry,this.properties=Fe.tags,this.extent=de||4096}me.prototype.feature=function(Fe){return new he(this.features[Fe],this.options.extent)},he.prototype.loadGeometry=function(){var Fe=this.rawGeometry;this.geometry=[];for(var de=0;de<Fe.length;de++){for(var Ce=Fe[de],Be=[],ze=0;ze<Ce.length;ze++)Be.push(new q(Ce[ze][0],Ce[ze][1]));this.geometry.push(Be)}return this.geometry},he.prototype.bbox=function(){this.geometry||this.loadGeometry();for(var Fe=this.geometry,de=1/0,Ce=-1/0,Be=1/0,ze=-1/0,tt=0;tt<Fe.length;tt++)for(var lt=Fe[tt],ft=0;ft<lt.length;ft++){var Ve=lt[ft];de=Math.min(de,Ve.x),Ce=Math.max(Ce,Ve.x),Be=Math.min(Be,Ve.y),ze=Math.max(ze,Ve.y)}return[de,Be,Ce,ze]},he.prototype.toGeoJSON=oe.prototype.toGeoJSON;var V=s.bw,ae=ce;function ye(Fe){var de=new V;return function(Ce,Be){for(var ze in Ce.layers)Be.writeMessage(3,Oe,Ce.layers[ze])}(Fe,de),de.finish()}function Oe(Fe,de){var Ce;de.writeVarintField(15,Fe.version||1),de.writeStringField(1,Fe.name||""),de.writeVarintField(5,Fe.extent||4096);var Be={keys:[],values:[],keycache:{},valuecache:{}};for(Ce=0;Ce<Fe.length;Ce++)Be.feature=Fe.feature(Ce),de.writeMessage(2,De,Be);var ze=Be.keys;for(Ce=0;Ce<ze.length;Ce++)de.writeStringField(3,ze[Ce]);var tt=Be.values;for(Ce=0;Ce<tt.length;Ce++)de.writeMessage(4,Bt,tt[Ce])}function De(Fe,de){var Ce=Fe.feature;Ce.id!==void 0&&de.writeVarintField(1,Ce.id),de.writeMessage(2,He,Fe),de.writeVarintField(3,Ce.type),de.writeMessage(4,be,Ce)}function He(Fe,de){var Ce=Fe.feature,Be=Fe.keys,ze=Fe.values,tt=Fe.keycache,lt=Fe.valuecache;for(var ft in Ce.properties){var Ve=Ce.properties[ft],xt=tt[ft];if(Ve!==null){xt===void 0&&(Be.push(ft),tt[ft]=xt=Be.length-1),de.writeVarint(xt);var Xt=typeof Ve;Xt!=="string"&&Xt!=="boolean"&&Xt!=="number"&&(Ve=JSON.stringify(Ve));var Vt=Xt+":"+Ve,Ht=lt[Vt];Ht===void 0&&(ze.push(Ve),lt[Vt]=Ht=ze.length-1),de.writeVarint(Ht)}}}function ke(Fe,de){return(de<<3)+(7&Fe)}function nt(Fe){return Fe<<1^Fe>>31}function be(Fe,de){for(var Ce=Fe.loadGeometry(),Be=Fe.type,ze=0,tt=0,lt=Ce.length,ft=0;ft<lt;ft++){var Ve=Ce[ft],xt=1;Be===1&&(xt=Ve.length),de.writeVarint(ke(1,xt));for(var Xt=Be===3?Ve.length-1:Ve.length,Vt=0;Vt<Xt;Vt++){Vt===1&&Be!==1&&de.writeVarint(ke(2,Xt-1));var Ht=Ve[Vt].x-ze,Qn=Ve[Vt].y-tt;de.writeVarint(nt(Ht)),de.writeVarint(nt(Qn)),ze+=Ht,tt+=Qn}Be===3&&de.writeVarint(ke(7,1))}}function Bt(Fe,de){var Ce=typeof Fe;Ce==="string"?de.writeStringField(1,Fe):Ce==="boolean"?de.writeBooleanField(7,Fe):Ce==="number"&&(Fe%1!=0?de.writeDoubleField(3,Fe):Fe<0?de.writeSVarintField(6,Fe):de.writeVarintField(5,Fe))}$.exports=ye,$.exports.fromVectorTileJs=ye,$.exports.fromGeojsonVt=function(Fe,de){de=de||{};var Ce={};for(var Be in Fe)Ce[Be]=new ae(Fe[Be].features,de),Ce[Be].name=Be,Ce[Be].version=de.version,Ce[Be].extent=de.extent;return ye({layers:Ce})},$.exports.GeoJSONWrapper=ae;var kt=s.bu($.exports);const Yt={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:Fe=>Fe},jt=Math.fround||(Xe=new Float32Array(1),Fe=>(Xe[0]=+Fe,Xe[0]));var Xe;const rt=3,ot=5,on=6;class gt{constructor(de){this.options=Object.assign(Object.create(Yt),de),this.trees=new Array(this.options.maxZoom+1),this.stride=this.options.reduce?7:6,this.clusterProps=[]}load(de){const{log:Ce,minZoom:Be,maxZoom:ze}=this.options;Ce&&console.time("total time");const tt=`prepare ${de.length} points`;Ce&&console.time(tt),this.points=de;const lt=[];for(let Ve=0;Ve<de.length;Ve++){const xt=de[Ve];if(!xt.geometry)continue;const[Xt,Vt]=xt.geometry.coordinates,Ht=jt(Lt(Xt)),Qn=jt(Me(Vt));lt.push(Ht,Qn,1/0,Ve,-1,1),this.options.reduce&&lt.push(0)}let ft=this.trees[ze+1]=this._createTree(lt);Ce&&console.timeEnd(tt);for(let Ve=ze;Ve>=Be;Ve--){const xt=+Date.now();ft=this.trees[Ve]=this._createTree(this._cluster(ft,Ve)),Ce&&console.log("z%d: %d clusters in %dms",Ve,ft.numItems,+Date.now()-xt)}return Ce&&console.timeEnd("total time"),this}getClusters(de,Ce){let Be=((de[0]+180)%360+360)%360-180;const ze=Math.max(-90,Math.min(90,de[1]));let tt=de[2]===180?180:((de[2]+180)%360+360)%360-180;const lt=Math.max(-90,Math.min(90,de[3]));if(de[2]-de[0]>=360)Be=-180,tt=180;else if(Be>tt){const Vt=this.getClusters([Be,ze,180,lt],Ce),Ht=this.getClusters([-180,ze,tt,lt],Ce);return Vt.concat(Ht)}const ft=this.trees[this._limitZoom(Ce)],Ve=ft.range(Lt(Be),Me(lt),Lt(tt),Me(ze)),xt=ft.data,Xt=[];for(const Vt of Ve){const Ht=this.stride*Vt;Xt.push(xt[Ht+ot]>1?at(xt,Ht,this.clusterProps):this.points[xt[Ht+rt]])}return Xt}getChildren(de){const Ce=this._getOriginId(de),Be=this._getOriginZoom(de),ze="No cluster with the specified id.",tt=this.trees[Be];if(!tt)throw new Error(ze);const lt=tt.data;if(Ce*this.stride>=lt.length)throw new Error(ze);const ft=this.options.radius/(this.options.extent*Math.pow(2,Be-1)),Ve=tt.within(lt[Ce*this.stride],lt[Ce*this.stride+1],ft),xt=[];for(const Xt of Ve){const Vt=Xt*this.stride;lt[Vt+4]===de&&xt.push(lt[Vt+ot]>1?at(lt,Vt,this.clusterProps):this.points[lt[Vt+rt]])}if(xt.length===0)throw new Error(ze);return xt}getLeaves(de,Ce,Be){const ze=[];return this._appendLeaves(ze,de,Ce=Ce||10,Be=Be||0,0),ze}getTile(de,Ce,Be){const ze=this.trees[this._limitZoom(de)],tt=Math.pow(2,de),{extent:lt,radius:ft}=this.options,Ve=ft/lt,xt=(Be-Ve)/tt,Xt=(Be+1+Ve)/tt,Vt={features:[]};return this._addTileFeatures(ze.range((Ce-Ve)/tt,xt,(Ce+1+Ve)/tt,Xt),ze.data,Ce,Be,tt,Vt),Ce===0&&this._addTileFeatures(ze.range(1-Ve/tt,xt,1,Xt),ze.data,tt,Be,tt,Vt),Ce===tt-1&&this._addTileFeatures(ze.range(0,xt,Ve/tt,Xt),ze.data,-1,Be,tt,Vt),Vt.features.length?Vt:null}getClusterExpansionZoom(de){let Ce=this._getOriginZoom(de)-1;for(;Ce<=this.options.maxZoom;){const Be=this.getChildren(de);if(Ce++,Be.length!==1)break;de=Be[0].properties.cluster_id}return Ce}_appendLeaves(de,Ce,Be,ze,tt){const lt=this.getChildren(Ce);for(const ft of lt){const Ve=ft.properties;if(Ve&&Ve.cluster?tt+Ve.point_count<=ze?tt+=Ve.point_count:tt=this._appendLeaves(de,Ve.cluster_id,Be,ze,tt):tt<ze?tt++:de.push(ft),de.length===Be)break}return tt}_createTree(de){const Ce=new s.au(de.length/this.stride|0,this.options.nodeSize,Float32Array);for(let Be=0;Be<de.length;Be+=this.stride)Ce.add(de[Be],de[Be+1]);return Ce.finish(),Ce.data=de,Ce}_addTileFeatures(de,Ce,Be,ze,tt,lt){for(const ft of de){const Ve=ft*this.stride,xt=Ce[Ve+ot]>1;let Xt,Vt,Ht;if(xt)Xt=It(Ce,Ve,this.clusterProps),Vt=Ce[Ve],Ht=Ce[Ve+1];else{const or=this.points[Ce[Ve+rt]];Xt=or.properties;const[ar,kr]=or.geometry.coordinates;Vt=Lt(ar),Ht=Me(kr)}const Qn={type:1,geometry:[[Math.round(this.options.extent*(Vt*tt-Be)),Math.round(this.options.extent*(Ht*tt-ze))]],tags:Xt};let Mn;Mn=xt||this.options.generateId?Ce[Ve+rt]:this.points[Ce[Ve+rt]].id,Mn!==void 0&&(Qn.id=Mn),lt.features.push(Qn)}}_limitZoom(de){return Math.max(this.options.minZoom,Math.min(Math.floor(+de),this.options.maxZoom+1))}_cluster(de,Ce){const{radius:Be,extent:ze,reduce:tt,minPoints:lt}=this.options,ft=Be/(ze*Math.pow(2,Ce)),Ve=de.data,xt=[],Xt=this.stride;for(let Vt=0;Vt<Ve.length;Vt+=Xt){if(Ve[Vt+2]<=Ce)continue;Ve[Vt+2]=Ce;const Ht=Ve[Vt],Qn=Ve[Vt+1],Mn=de.within(Ve[Vt],Ve[Vt+1],ft),or=Ve[Vt+ot];let ar=or;for(const kr of Mn){const jr=kr*Xt;Ve[jr+2]>Ce&&(ar+=Ve[jr+ot])}if(ar>or&&ar>=lt){let kr,jr=Ht*or,Lr=Qn*or,Wr=-1;const ir=((Vt/Xt|0)<<5)+(Ce+1)+this.points.length;for(const ui of Mn){const Oi=ui*Xt;if(Ve[Oi+2]<=Ce)continue;Ve[Oi+2]=Ce;const Yi=Ve[Oi+ot];jr+=Ve[Oi]*Yi,Lr+=Ve[Oi+1]*Yi,Ve[Oi+4]=ir,tt&&(kr||(kr=this._map(Ve,Vt,!0),Wr=this.clusterProps.length,this.clusterProps.push(kr)),tt(kr,this._map(Ve,Oi)))}Ve[Vt+4]=ir,xt.push(jr/ar,Lr/ar,1/0,ir,-1,ar),tt&&xt.push(Wr)}else{for(let kr=0;kr<Xt;kr++)xt.push(Ve[Vt+kr]);if(ar>1)for(const kr of Mn){const jr=kr*Xt;if(!(Ve[jr+2]<=Ce)){Ve[jr+2]=Ce;for(let Lr=0;Lr<Xt;Lr++)xt.push(Ve[jr+Lr])}}}}return xt}_getOriginId(de){return de-this.points.length>>5}_getOriginZoom(de){return(de-this.points.length)%32}_map(de,Ce,Be){if(de[Ce+ot]>1){const lt=this.clusterProps[de[Ce+on]];return Be?Object.assign({},lt):lt}const ze=this.points[de[Ce+rt]].properties,tt=this.options.map(ze);return Be&&tt===ze?Object.assign({},tt):tt}}function at(Fe,de,Ce){return{type:"Feature",id:Fe[de+rt],properties:It(Fe,de,Ce),geometry:{type:"Point",coordinates:[(Be=Fe[de],360*(Be-.5)),fe(Fe[de+1])]}};var Be}function It(Fe,de,Ce){const Be=Fe[de+ot],ze=Be>=1e4?`${Math.round(Be/1e3)}k`:Be>=1e3?Math.round(Be/100)/10+"k":Be,tt=Fe[de+on],lt=tt===-1?{}:Object.assign({},Ce[tt]);return Object.assign(lt,{cluster:!0,cluster_id:Fe[de+rt],point_count:Be,point_count_abbreviated:ze})}function Lt(Fe){return Fe/360+.5}function Me(Fe){const de=Math.sin(Fe*Math.PI/180),Ce=.5-.25*Math.log((1+de)/(1-de))/Math.PI;return Ce<0?0:Ce>1?1:Ce}function fe(Fe){const de=(180-360*Fe)*Math.PI/180;return 360*Math.atan(Math.exp(de))/Math.PI-90}function xe(Fe,de,Ce,Be){for(var ze,tt=Be,lt=Ce-de>>1,ft=Ce-de,Ve=Fe[de],xt=Fe[de+1],Xt=Fe[Ce],Vt=Fe[Ce+1],Ht=de+3;Ht<Ce;Ht+=3){var Qn=Ue(Fe[Ht],Fe[Ht+1],Ve,xt,Xt,Vt);if(Qn>tt)ze=Ht,tt=Qn;else if(Qn===tt){var Mn=Math.abs(Ht-lt);Mn<ft&&(ze=Ht,ft=Mn)}}tt>Be&&(ze-de>3&&xe(Fe,de,ze,Be),Fe[ze+2]=tt,Ce-ze>3&&xe(Fe,ze,Ce,Be))}function Ue(Fe,de,Ce,Be,ze,tt){var lt=ze-Ce,ft=tt-Be;if(lt!==0||ft!==0){var Ve=((Fe-Ce)*lt+(de-Be)*ft)/(lt*lt+ft*ft);Ve>1?(Ce=ze,Be=tt):Ve>0&&(Ce+=lt*Ve,Be+=ft*Ve)}return(lt=Fe-Ce)*lt+(ft=de-Be)*ft}function et(Fe,de,Ce,Be){var ze={id:Fe===void 0?null:Fe,type:de,geometry:Ce,tags:Be,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0};return function(tt){var lt=tt.geometry,ft=tt.type;if(ft==="Point"||ft==="MultiPoint"||ft==="LineString")it(tt,lt);else if(ft==="Polygon"||ft==="MultiLineString")for(var Ve=0;Ve<lt.length;Ve++)it(tt,lt[Ve]);else if(ft==="MultiPolygon")for(Ve=0;Ve<lt.length;Ve++)for(var xt=0;xt<lt[Ve].length;xt++)it(tt,lt[Ve][xt])}(ze),ze}function it(Fe,de){for(var Ce=0;Ce<de.length;Ce+=3)Fe.minX=Math.min(Fe.minX,de[Ce]),Fe.minY=Math.min(Fe.minY,de[Ce+1]),Fe.maxX=Math.max(Fe.maxX,de[Ce]),Fe.maxY=Math.max(Fe.maxY,de[Ce+1])}function bt(Fe,de,Ce,Be){if(de.geometry){var ze=de.geometry.coordinates,tt=de.geometry.type,lt=Math.pow(Ce.tolerance/((1<<Ce.maxZoom)*Ce.extent),2),ft=[],Ve=de.id;if(Ce.promoteId?Ve=de.properties[Ce.promoteId]:Ce.generateId&&(Ve=Be||0),tt==="Point")Ut(ze,ft);else if(tt==="MultiPoint")for(var xt=0;xt<ze.length;xt++)Ut(ze[xt],ft);else if(tt==="LineString")Rt(ze,ft,lt,!1);else if(tt==="MultiLineString"){if(Ce.lineMetrics){for(xt=0;xt<ze.length;xt++)Rt(ze[xt],ft=[],lt,!1),Fe.push(et(Ve,"LineString",ft,de.properties));return}pt(ze,ft,lt,!1)}else if(tt==="Polygon")pt(ze,ft,lt,!0);else{if(tt!=="MultiPolygon"){if(tt==="GeometryCollection"){for(xt=0;xt<de.geometry.geometries.length;xt++)bt(Fe,{id:Ve,geometry:de.geometry.geometries[xt],properties:de.properties},Ce,Be);return}throw new Error("Input data is not a valid GeoJSON object.")}for(xt=0;xt<ze.length;xt++){var Xt=[];pt(ze[xt],Xt,lt,!0),ft.push(Xt)}}Fe.push(et(Ve,tt,ft,de.properties))}}function Ut(Fe,de){de.push(rr(Fe[0])),de.push(mn(Fe[1])),de.push(0)}function Rt(Fe,de,Ce,Be){for(var ze,tt,lt=0,ft=0;ft<Fe.length;ft++){var Ve=rr(Fe[ft][0]),xt=mn(Fe[ft][1]);de.push(Ve),de.push(xt),de.push(0),ft>0&&(lt+=Be?(ze*xt-Ve*tt)/2:Math.sqrt(Math.pow(Ve-ze,2)+Math.pow(xt-tt,2))),ze=Ve,tt=xt}var Xt=de.length-3;de[2]=1,xe(de,0,Xt,Ce),de[Xt+2]=1,de.size=Math.abs(lt),de.start=0,de.end=de.size}function pt(Fe,de,Ce,Be){for(var ze=0;ze<Fe.length;ze++){var tt=[];Rt(Fe[ze],tt,Ce,Be),de.push(tt)}}function rr(Fe){return Fe/360+.5}function mn(Fe){var de=Math.sin(Fe*Math.PI/180),Ce=.5-.25*Math.log((1+de)/(1-de))/Math.PI;return Ce<0?0:Ce>1?1:Ce}function vn(Fe,de,Ce,Be,ze,tt,lt,ft){if(Be/=de,tt>=(Ce/=de)&&lt<Be)return Fe;if(lt<Ce||tt>=Be)return null;for(var Ve=[],xt=0;xt<Fe.length;xt++){var Xt=Fe[xt],Vt=Xt.geometry,Ht=Xt.type,Qn=ze===0?Xt.minX:Xt.minY,Mn=ze===0?Xt.maxX:Xt.maxY;if(Qn>=Ce&&Mn<Be)Ve.push(Xt);else if(!(Mn<Ce||Qn>=Be)){var or=[];if(Ht==="Point"||Ht==="MultiPoint")Xn(Vt,or,Ce,Be,ze);else if(Ht==="LineString")cr(Vt,or,Ce,Be,ze,!1,ft.lineMetrics);else if(Ht==="MultiLineString")Gr(Vt,or,Ce,Be,ze,!1);else if(Ht==="Polygon")Gr(Vt,or,Ce,Be,ze,!0);else if(Ht==="MultiPolygon")for(var ar=0;ar<Vt.length;ar++){var kr=[];Gr(Vt[ar],kr,Ce,Be,ze,!0),kr.length&&or.push(kr)}if(or.length){if(ft.lineMetrics&&Ht==="LineString"){for(ar=0;ar<or.length;ar++)Ve.push(et(Xt.id,Ht,or[ar],Xt.tags));continue}Ht!=="LineString"&&Ht!=="MultiLineString"||(or.length===1?(Ht="LineString",or=or[0]):Ht="MultiLineString"),Ht!=="Point"&&Ht!=="MultiPoint"||(Ht=or.length===3?"Point":"MultiPoint"),Ve.push(et(Xt.id,Ht,or,Xt.tags))}}}return Ve.length?Ve:null}function Xn(Fe,de,Ce,Be,ze){for(var tt=0;tt<Fe.length;tt+=3){var lt=Fe[tt+ze];lt>=Ce&&lt<=Be&&(de.push(Fe[tt]),de.push(Fe[tt+1]),de.push(Fe[tt+2]))}}function cr(Fe,de,Ce,Be,ze,tt,lt){for(var ft,Ve,xt=Mr(Fe),Xt=ze===0?mi:Se,Vt=Fe.start,Ht=0;Ht<Fe.length-3;Ht+=3){var Qn=Fe[Ht],Mn=Fe[Ht+1],or=Fe[Ht+2],ar=Fe[Ht+3],kr=Fe[Ht+4],jr=ze===0?Qn:Mn,Lr=ze===0?ar:kr,Wr=!1;lt&&(ft=Math.sqrt(Math.pow(Qn-ar,2)+Math.pow(Mn-kr,2))),jr<Ce?Lr>Ce&&(Ve=Xt(xt,Qn,Mn,ar,kr,Ce),lt&&(xt.start=Vt+ft*Ve)):jr>Be?Lr<Be&&(Ve=Xt(xt,Qn,Mn,ar,kr,Be),lt&&(xt.start=Vt+ft*Ve)):gr(xt,Qn,Mn,or),Lr<Ce&&jr>=Ce&&(Ve=Xt(xt,Qn,Mn,ar,kr,Ce),Wr=!0),Lr>Be&&jr<=Be&&(Ve=Xt(xt,Qn,Mn,ar,kr,Be),Wr=!0),!tt&&Wr&&(lt&&(xt.end=Vt+ft*Ve),de.push(xt),xt=Mr(Fe)),lt&&(Vt+=ft)}var ir=Fe.length-3;Qn=Fe[ir],Mn=Fe[ir+1],or=Fe[ir+2],(jr=ze===0?Qn:Mn)>=Ce&&jr<=Be&&gr(xt,Qn,Mn,or),ir=xt.length-3,tt&&ir>=3&&(xt[ir]!==xt[0]||xt[ir+1]!==xt[1])&&gr(xt,xt[0],xt[1],xt[2]),xt.length&&de.push(xt)}function Mr(Fe){var de=[];return de.size=Fe.size,de.start=Fe.start,de.end=Fe.end,de}function Gr(Fe,de,Ce,Be,ze,tt){for(var lt=0;lt<Fe.length;lt++)cr(Fe[lt],de,Ce,Be,ze,tt,!1)}function gr(Fe,de,Ce,Be){Fe.push(de),Fe.push(Ce),Fe.push(Be)}function mi(Fe,de,Ce,Be,ze,tt){var lt=(tt-de)/(Be-de);return Fe.push(tt),Fe.push(Ce+(ze-Ce)*lt),Fe.push(1),lt}function Se(Fe,de,Ce,Be,ze,tt){var lt=(tt-Ce)/(ze-Ce);return Fe.push(de+(Be-de)*lt),Fe.push(tt),Fe.push(1),lt}function X(Fe,de){for(var Ce=[],Be=0;Be<Fe.length;Be++){var ze,tt=Fe[Be],lt=tt.type;if(lt==="Point"||lt==="MultiPoint"||lt==="LineString")ze=H(tt.geometry,de);else if(lt==="MultiLineString"||lt==="Polygon"){ze=[];for(var ft=0;ft<tt.geometry.length;ft++)ze.push(H(tt.geometry[ft],de))}else if(lt==="MultiPolygon")for(ze=[],ft=0;ft<tt.geometry.length;ft++){for(var Ve=[],xt=0;xt<tt.geometry[ft].length;xt++)Ve.push(H(tt.geometry[ft][xt],de));ze.push(Ve)}Ce.push(et(tt.id,lt,ze,tt.tags))}return Ce}function H(Fe,de){var Ce=[];Ce.size=Fe.size,Fe.start!==void 0&&(Ce.start=Fe.start,Ce.end=Fe.end);for(var Be=0;Be<Fe.length;Be+=3)Ce.push(Fe[Be]+de,Fe[Be+1],Fe[Be+2]);return Ce}function Te(Fe,de){if(Fe.transformed)return Fe;var Ce,Be,ze,tt=1<<Fe.z,lt=Fe.x,ft=Fe.y;for(Ce=0;Ce<Fe.features.length;Ce++){var Ve=Fe.features[Ce],xt=Ve.geometry,Xt=Ve.type;if(Ve.geometry=[],Xt===1)for(Be=0;Be<xt.length;Be+=2)Ve.geometry.push(At(xt[Be],xt[Be+1],de,tt,lt,ft));else for(Be=0;Be<xt.length;Be++){var Vt=[];for(ze=0;ze<xt[Be].length;ze+=2)Vt.push(At(xt[Be][ze],xt[Be][ze+1],de,tt,lt,ft));Ve.geometry.push(Vt)}}return Fe.transformed=!0,Fe}function At(Fe,de,Ce,Be,ze,tt){return[Math.round(Ce*(Fe*Be-ze)),Math.round(Ce*(de*Be-tt))]}function St(Fe,de,Ce,Be,ze){for(var tt=de===ze.maxZoom?0:ze.tolerance/((1<<de)*ze.extent),lt={features:[],numPoints:0,numSimplified:0,numFeatures:0,source:null,x:Ce,y:Be,z:de,transformed:!1,minX:2,minY:1,maxX:-1,maxY:0},ft=0;ft<Fe.length;ft++){lt.numFeatures++,Et(lt,Fe[ft],tt,ze);var Ve=Fe[ft].minX,xt=Fe[ft].minY,Xt=Fe[ft].maxX,Vt=Fe[ft].maxY;Ve<lt.minX&&(lt.minX=Ve),xt<lt.minY&&(lt.minY=xt),Xt>lt.maxX&&(lt.maxX=Xt),Vt>lt.maxY&&(lt.maxY=Vt)}return lt}function Et(Fe,de,Ce,Be){var ze=de.geometry,tt=de.type,lt=[];if(tt==="Point"||tt==="MultiPoint")for(var ft=0;ft<ze.length;ft+=3)lt.push(ze[ft]),lt.push(ze[ft+1]),Fe.numPoints++,Fe.numSimplified++;else if(tt==="LineString")Nt(lt,ze,Fe,Ce,!1,!1);else if(tt==="MultiLineString"||tt==="Polygon")for(ft=0;ft<ze.length;ft++)Nt(lt,ze[ft],Fe,Ce,tt==="Polygon",ft===0);else if(tt==="MultiPolygon")for(var Ve=0;Ve<ze.length;Ve++){var xt=ze[Ve];for(ft=0;ft<xt.length;ft++)Nt(lt,xt[ft],Fe,Ce,!0,ft===0)}if(lt.length){var Xt=de.tags||null;if(tt==="LineString"&&Be.lineMetrics){for(var Vt in Xt={},de.tags)Xt[Vt]=de.tags[Vt];Xt.mapbox_clip_start=ze.start/ze.size,Xt.mapbox_clip_end=ze.end/ze.size}var Ht={geometry:lt,type:tt==="Polygon"||tt==="MultiPolygon"?3:tt==="LineString"||tt==="MultiLineString"?2:1,tags:Xt};de.id!==null&&(Ht.id=de.id),Fe.features.push(Ht)}}function Nt(Fe,de,Ce,Be,ze,tt){var lt=Be*Be;if(Be>0&&de.size<(ze?lt:Be))Ce.numPoints+=de.length/3;else{for(var ft=[],Ve=0;Ve<de.length;Ve+=3)(Be===0||de[Ve+2]>lt)&&(Ce.numSimplified++,ft.push(de[Ve]),ft.push(de[Ve+1])),Ce.numPoints++;ze&&function(xt,Xt){for(var Vt=0,Ht=0,Qn=xt.length,Mn=Qn-2;Ht<Qn;Mn=Ht,Ht+=2)Vt+=(xt[Ht]-xt[Mn])*(xt[Ht+1]+xt[Mn+1]);if(Vt>0===Xt)for(Ht=0,Qn=xt.length;Ht<Qn/2;Ht+=2){var or=xt[Ht],ar=xt[Ht+1];xt[Ht]=xt[Qn-2-Ht],xt[Ht+1]=xt[Qn-1-Ht],xt[Qn-2-Ht]=or,xt[Qn-1-Ht]=ar}}(ft,tt),Fe.push(ft)}}function pn(Fe,de){var Ce=(de=this.options=function(ze,tt){for(var lt in tt)ze[lt]=tt[lt];return ze}(Object.create(this.options),de)).debug;if(Ce&&console.time("preprocess data"),de.maxZoom<0||de.maxZoom>24)throw new Error("maxZoom should be in the 0-24 range");if(de.promoteId&&de.generateId)throw new Error("promoteId and generateId cannot be used together.");var Be=function(ze,tt){var lt=[];if(ze.type==="FeatureCollection")for(var ft=0;ft<ze.features.length;ft++)bt(lt,ze.features[ft],tt,ft);else bt(lt,ze.type==="Feature"?ze:{geometry:ze},tt);return lt}(Fe,de);this.tiles={},this.tileCoords=[],Ce&&(console.timeEnd("preprocess data"),console.log("index: maxZoom: %d, maxPoints: %d",de.indexMaxZoom,de.indexMaxPoints),console.time("generate tiles"),this.stats={},this.total=0),Be=function(ze,tt){var lt=tt.buffer/tt.extent,ft=ze,Ve=vn(ze,1,-1-lt,lt,0,-1,2,tt),xt=vn(ze,1,1-lt,2+lt,0,-1,2,tt);return(Ve||xt)&&(ft=vn(ze,1,-lt,1+lt,0,-1,2,tt)||[],Ve&&(ft=X(Ve,1).concat(ft)),xt&&(ft=ft.concat(X(xt,-1)))),ft}(Be,de),Be.length&&this.splitTile(Be,0,0,0),Ce&&(Be.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 Kn(Fe,de,Ce){return 32*((1<<Fe)*Ce+de)+Fe}function En(Fe,de){return de?Fe.properties[de]:Fe.id}function m(Fe,de){if(Fe==null)return!0;if(Fe.type==="Feature")return En(Fe,de)!=null;if(Fe.type==="FeatureCollection"){const Ce=new Set;for(const Be of Fe.features){const ze=En(Be,de);if(ze==null||Ce.has(ze))return!1;Ce.add(ze)}return!0}return!1}function Kt(Fe,de){const Ce=new Map;if(Fe!=null)if(Fe.type==="Feature")Ce.set(En(Fe,de),Fe);else for(const Be of Fe.features)Ce.set(En(Be,de),Be);return Ce}pn.prototype.options={maxZoom:14,indexMaxZoom:5,indexMaxPoints:1e5,tolerance:3,extent:4096,buffer:64,lineMetrics:!1,promoteId:null,generateId:!1,debug:0},pn.prototype.splitTile=function(Fe,de,Ce,Be,ze,tt,lt){for(var ft=[Fe,de,Ce,Be],Ve=this.options,xt=Ve.debug;ft.length;){Be=ft.pop(),Ce=ft.pop(),de=ft.pop(),Fe=ft.pop();var Xt=1<<de,Vt=Kn(de,Ce,Be),Ht=this.tiles[Vt];if(!Ht&&(xt>1&&console.time("creation"),Ht=this.tiles[Vt]=St(Fe,de,Ce,Be,Ve),this.tileCoords.push({z:de,x:Ce,y:Be}),xt)){xt>1&&(console.log("tile z%d-%d-%d (features: %d, points: %d, simplified: %d)",de,Ce,Be,Ht.numFeatures,Ht.numPoints,Ht.numSimplified),console.timeEnd("creation"));var Qn="z"+de;this.stats[Qn]=(this.stats[Qn]||0)+1,this.total++}if(Ht.source=Fe,ze){if(de===Ve.maxZoom||de===ze)continue;var Mn=1<<ze-de;if(Ce!==Math.floor(tt/Mn)||Be!==Math.floor(lt/Mn))continue}else if(de===Ve.indexMaxZoom||Ht.numPoints<=Ve.indexMaxPoints)continue;if(Ht.source=null,Fe.length!==0){xt>1&&console.time("clipping");var or,ar,kr,jr,Lr,Wr,ir=.5*Ve.buffer/Ve.extent,ui=.5-ir,Oi=.5+ir,Yi=1+ir;or=ar=kr=jr=null,Lr=vn(Fe,Xt,Ce-ir,Ce+Oi,0,Ht.minX,Ht.maxX,Ve),Wr=vn(Fe,Xt,Ce+ui,Ce+Yi,0,Ht.minX,Ht.maxX,Ve),Fe=null,Lr&&(or=vn(Lr,Xt,Be-ir,Be+Oi,1,Ht.minY,Ht.maxY,Ve),ar=vn(Lr,Xt,Be+ui,Be+Yi,1,Ht.minY,Ht.maxY,Ve),Lr=null),Wr&&(kr=vn(Wr,Xt,Be-ir,Be+Oi,1,Ht.minY,Ht.maxY,Ve),jr=vn(Wr,Xt,Be+ui,Be+Yi,1,Ht.minY,Ht.maxY,Ve),Wr=null),xt>1&&console.timeEnd("clipping"),ft.push(or||[],de+1,2*Ce,2*Be),ft.push(ar||[],de+1,2*Ce,2*Be+1),ft.push(kr||[],de+1,2*Ce+1,2*Be),ft.push(jr||[],de+1,2*Ce+1,2*Be+1)}}},pn.prototype.getTile=function(Fe,de,Ce){var Be=this.options,ze=Be.extent,tt=Be.debug;if(Fe<0||Fe>24)return null;var lt=1<<Fe,ft=Kn(Fe,de=(de%lt+lt)%lt,Ce);if(this.tiles[ft])return Te(this.tiles[ft],ze);tt>1&&console.log("drilling down to z%d-%d-%d",Fe,de,Ce);for(var Ve,xt=Fe,Xt=de,Vt=Ce;!Ve&&xt>0;)xt--,Xt=Math.floor(Xt/2),Vt=Math.floor(Vt/2),Ve=this.tiles[Kn(xt,Xt,Vt)];return Ve&&Ve.source?(tt>1&&console.log("found parent tile z%d-%d-%d",xt,Xt,Vt),tt>1&&console.time("drilling down"),this.splitTile(Ve.source,xt,Xt,Vt,Fe,de,Ce),tt>1&&console.timeEnd("drilling down"),this.tiles[ft]?Te(this.tiles[ft],ze):null):null};class Dr extends B{constructor(){super(...arguments),this._dataUpdateable=new Map}loadVectorTile(de,Ce){return s._(this,void 0,void 0,function*(){const Be=de.tileID.canonical;if(!this._geoJSONIndex)throw new Error("Unable to parse the data into a cluster or geojson");const ze=this._geoJSONIndex.getTile(Be.z,Be.x,Be.y);if(!ze)return null;const tt=new class{constructor(ft){this.layers={_geojsonTileLayer:this},this.name="_geojsonTileLayer",this.extent=s.W,this.length=ft.length,this._features=ft}feature(ft){return new class{constructor(Ve){this._feature=Ve,this.extent=s.W,this.type=Ve.type,this.properties=Ve.tags,"id"in Ve&&!isNaN(Ve.id)&&(this.id=parseInt(Ve.id,10))}loadGeometry(){if(this._feature.type===1){const Ve=[];for(const xt of this._feature.geometry)Ve.push([new s.P(xt[0],xt[1])]);return Ve}{const Ve=[];for(const xt of this._feature.geometry){const Xt=[];for(const Vt of xt)Xt.push(new s.P(Vt[0],Vt[1]));Ve.push(Xt)}return Ve}}toGeoJSON(Ve,xt,Xt){return N.call(this,Ve,xt,Xt)}}(this._features[ft])}}(ze.features);let lt=kt(tt);return lt.byteOffset===0&&lt.byteLength===lt.buffer.byteLength||(lt=new Uint8Array(lt)),{vectorTile:tt,rawData:lt.buffer}})}loadData(de){var Ce;return s._(this,void 0,void 0,function*(){(Ce=this._pendingRequest)===null||Ce===void 0||Ce.abort();const Be=!!(de&&de.request&&de.request.collectResourceTiming)&&new s.br(de.request);this._pendingRequest=new AbortController;try{let ze=yield this.loadGeoJSON(de,this._pendingRequest);if(delete this._pendingRequest,typeof ze!="object")throw new Error(`Input data given to '${de.source}' is not a valid GeoJSON object.`);if(J(ze,!0),de.filter){const lt=s.bx(de.filter,{type:"boolean","property-type":"data-driven",overridable:!1,transition:!1});if(lt.result==="error")throw new Error(lt.value.map(Ve=>`${Ve.key}: ${Ve.message}`).join(", "));ze={type:"FeatureCollection",features:ze.features.filter(Ve=>lt.value.evaluate({zoom:0},Ve))}}this._geoJSONIndex=de.cluster?new gt(function({superclusterOptions:lt,clusterProperties:ft}){if(!ft||!lt)return lt;const Ve={},xt={},Xt={accumulated:null,zoom:0},Vt={properties:null},Ht=Object.keys(ft);for(const Qn of Ht){const[Mn,or]=ft[Qn],ar=s.bx(or),kr=s.bx(typeof Mn=="string"?[Mn,["accumulated"],["get",Qn]]:Mn);Ve[Qn]=ar.value,xt[Qn]=kr.value}return lt.map=Qn=>{Vt.properties=Qn;const Mn={};for(const or of Ht)Mn[or]=Ve[or].evaluate(Xt,Vt);return Mn},lt.reduce=(Qn,Mn)=>{Vt.properties=Mn;for(const or of Ht)Xt.accumulated=Qn[or],Qn[or]=xt[or].evaluate(Xt,Vt)},lt}(de)).load(ze.features):function(lt,ft){return new pn(lt,ft)}(ze,de.geojsonVtOptions),this.loaded={};const tt={};if(Be){const lt=Be.finish();lt&&(tt.resourceTiming={},tt.resourceTiming[de.source]=JSON.parse(JSON.stringify(lt)))}return tt}catch(ze){if(delete this._pendingRequest,s.by(ze))return{abandoned:!0};throw ze}})}reloadTile(de){const Ce=this.loaded;return Ce&&Ce[de.uid]?super.reloadTile(de):this.loadTile(de)}loadGeoJSON(de,Ce){return s._(this,void 0,void 0,function*(){const{promoteId:Be}=de;if(de.request){const ze=yield s.h(de.request,Ce);return this._dataUpdateable=m(ze.data,Be)?Kt(ze.data,Be):void 0,ze.data}if(typeof de.data=="string")try{const ze=JSON.parse(de.data);return this._dataUpdateable=m(ze,Be)?Kt(ze,Be):void 0,ze}catch{throw new Error(`Input data given to '${de.source}' is not a valid GeoJSON object.`)}if(!de.dataDiff)throw new Error(`Input data given to '${de.source}' is not a valid GeoJSON object.`);if(!this._dataUpdateable)throw new Error(`Cannot update existing geojson data in ${de.source}`);return function(ze,tt,lt){var ft,Ve,xt,Xt;if(tt.removeAll&&ze.clear(),tt.remove)for(const Vt of tt.remove)ze.delete(Vt);if(tt.add)for(const Vt of tt.add){const Ht=En(Vt,lt);Ht!=null&&ze.set(Ht,Vt)}if(tt.update)for(const Vt of tt.update){let Ht=ze.get(Vt.id);if(Ht==null)continue;const Qn=!Vt.removeAllProperties&&(((ft=Vt.removeProperties)===null||ft===void 0?void 0:ft.length)>0||((Ve=Vt.addOrUpdateProperties)===null||Ve===void 0?void 0:Ve.length)>0);if((Vt.newGeometry||Vt.removeAllProperties||Qn)&&(Ht=Object.assign({},Ht),ze.set(Vt.id,Ht),Qn&&(Ht.properties=Object.assign({},Ht.properties))),Vt.newGeometry&&(Ht.geometry=Vt.newGeometry),Vt.removeAllProperties)Ht.properties={};else if(((xt=Vt.removeProperties)===null||xt===void 0?void 0:xt.length)>0)for(const Mn of Vt.removeProperties)Object.prototype.hasOwnProperty.call(Ht.properties,Mn)&&delete Ht.properties[Mn];if(((Xt=Vt.addOrUpdateProperties)===null||Xt===void 0?void 0:Xt.length)>0)for(const{key:Mn,value:or}of Vt.addOrUpdateProperties)Ht.properties[Mn]=or}}(this._dataUpdateable,de.dataDiff,Be),{type:"FeatureCollection",features:Array.from(this._dataUpdateable.values())}})}removeSource(de){return s._(this,void 0,void 0,function*(){this._pendingRequest&&this._pendingRequest.abort()})}getClusterExpansionZoom(de){return this._geoJSONIndex.getClusterExpansionZoom(de.clusterId)}getClusterChildren(de){return this._geoJSONIndex.getChildren(de.clusterId)}getClusterLeaves(de){return this._geoJSONIndex.getLeaves(de.clusterId,de.limit,de.offset)}}class Fn{constructor(de){this.self=de,this.actor=new s.C(de),this.layerIndexes={},this.availableImages={},this.workerSources={},this.demWorkerSources={},this.externalWorkerSourceTypes={},this.self.registerWorkerSource=(Ce,Be)=>{if(this.externalWorkerSourceTypes[Ce])throw new Error(`Worker source with name "${Ce}" already registered.`);this.externalWorkerSourceTypes[Ce]=Be},this.self.addProtocol=s.be,this.self.removeProtocol=s.bf,this.self.registerRTLTextPlugin=Ce=>{if(s.bz.isParsed())throw new Error("RTL text plugin already registered.");s.bz.setMethods(Ce)},this.actor.registerMessageHandler("loadDEMTile",(Ce,Be)=>this._getDEMWorkerSource(Ce,Be.source).loadTile(Be)),this.actor.registerMessageHandler("removeDEMTile",(Ce,Be)=>s._(this,void 0,void 0,function*(){this._getDEMWorkerSource(Ce,Be.source).removeTile(Be)})),this.actor.registerMessageHandler("getClusterExpansionZoom",(Ce,Be)=>s._(this,void 0,void 0,function*(){return this._getWorkerSource(Ce,Be.type,Be.source).getClusterExpansionZoom(Be)})),this.actor.registerMessageHandler("getClusterChildren",(Ce,Be)=>s._(this,void 0,void 0,function*(){return this._getWorkerSource(Ce,Be.type,Be.source).getClusterChildren(Be)})),this.actor.registerMessageHandler("getClusterLeaves",(Ce,Be)=>s._(this,void 0,void 0,function*(){return this._getWorkerSource(Ce,Be.type,Be.source).getClusterLeaves(Be)})),this.actor.registerMessageHandler("loadData",(Ce,Be)=>this._getWorkerSource(Ce,Be.type,Be.source).loadData(Be)),this.actor.registerMessageHandler("loadTile",(Ce,Be)=>this._getWorkerSource(Ce,Be.type,Be.source).loadTile(Be)),this.actor.registerMessageHandler("reloadTile",(Ce,Be)=>this._getWorkerSource(Ce,Be.type,Be.source).reloadTile(Be)),this.actor.registerMessageHandler("abortTile",(Ce,Be)=>this._getWorkerSource(Ce,Be.type,Be.source).abortTile(Be)),this.actor.registerMessageHandler("removeTile",(Ce,Be)=>this._getWorkerSource(Ce,Be.type,Be.source).removeTile(Be)),this.actor.registerMessageHandler("removeSource",(Ce,Be)=>s._(this,void 0,void 0,function*(){if(!this.workerSources[Ce]||!this.workerSources[Ce][Be.type]||!this.workerSources[Ce][Be.type][Be.source])return;const ze=this.workerSources[Ce][Be.type][Be.source];delete this.workerSources[Ce][Be.type][Be.source],ze.removeSource!==void 0&&ze.removeSource(Be)})),this.actor.registerMessageHandler("setReferrer",(Ce,Be)=>s._(this,void 0,void 0,function*(){this.referrer=Be})),this.actor.registerMessageHandler("syncRTLPluginState",(Ce,Be)=>this._syncRTLPluginState(Ce,Be)),this.actor.registerMessageHandler("importScript",(Ce,Be)=>s._(this,void 0,void 0,function*(){this.self.importScripts(Be)})),this.actor.registerMessageHandler("setImages",(Ce,Be)=>this._setImages(Ce,Be)),this.actor.registerMessageHandler("updateLayers",(Ce,Be)=>s._(this,void 0,void 0,function*(){this._getLayerIndex(Ce).update(Be.layers,Be.removedIds)})),this.actor.registerMessageHandler("setLayers",(Ce,Be)=>s._(this,void 0,void 0,function*(){this._getLayerIndex(Ce).replace(Be)}))}_setImages(de,Ce){return s._(this,void 0,void 0,function*(){this.availableImages[de]=Ce;for(const Be in this.workerSources[de]){const ze=this.workerSources[de][Be];for(const tt in ze)ze[tt].availableImages=Ce}})}_syncRTLPluginState(de,Ce){return s._(this,void 0,void 0,function*(){s.bz.setState(Ce);const Be=s.bz.getPluginURL();if(Ce.pluginStatus==="loaded"&&!s.bz.isParsed()&&Be!=null){this.self.importScripts(Be);const ze=s.bz.isParsed();if(ze)return ze;throw new Error(`RTL Text Plugin failed to import scripts from ${Be}`)}return!1})}_getAvailableImages(de){let Ce=this.availableImages[de];return Ce||(Ce=[]),Ce}_getLayerIndex(de){let Ce=this.layerIndexes[de];return Ce||(Ce=this.layerIndexes[de]=new a),Ce}_getWorkerSource(de,Ce,Be){if(this.workerSources[de]||(this.workerSources[de]={}),this.workerSources[de][Ce]||(this.workerSources[de][Ce]={}),!this.workerSources[de][Ce][Be]){const ze={sendAsync:(tt,lt)=>(tt.targetMapId=de,this.actor.sendAsync(tt,lt))};switch(Ce){case"vector":this.workerSources[de][Ce][Be]=new B(ze,this._getLayerIndex(de),this._getAvailableImages(de));break;case"geojson":this.workerSources[de][Ce][Be]=new Dr(ze,this._getLayerIndex(de),this._getAvailableImages(de));break;default:this.workerSources[de][Ce][Be]=new this.externalWorkerSourceTypes[Ce](ze,this._getLayerIndex(de),this._getAvailableImages(de))}}return this.workerSources[de][Ce][Be]}_getDEMWorkerSource(de,Ce){return this.demWorkerSources[de]||(this.demWorkerSources[de]={}),this.demWorkerSources[de][Ce]||(this.demWorkerSources[de][Ce]=new k),this.demWorkerSources[de][Ce]}}return s.i(self)&&(self.worker=new Fn(self)),Fn}),i("index",["exports","./shared"],function(s,a){var h="4.0.0";let g,C;const B={now:typeof performance<"u"&&performance&&performance.now?performance.now.bind(performance):Date.now.bind(Date),frameAsync:O=>new Promise((u,p)=>{const _=requestAnimationFrame(u);O.signal.addEventListener("abort",()=>{cancelAnimationFrame(_),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&&(C==null&&(C=matchMedia("(prefers-reduced-motion: reduce)")),C.matches)}};class k{static testProp(u){if(!k.docStyle)return u[0];for(let p=0;p<u.length;p++)if(u[p]in k.docStyle)return u[p];return u[0]}static create(u,p,_){const M=window.document.createElement(u);return p!==void 0&&(M.className=p),_&&_.appendChild(M),M}static createNS(u,p){return window.document.createElementNS(u,p)}static disableDrag(){k.docStyle&&k.selectProp&&(k.userSelect=k.docStyle[k.selectProp],k.docStyle[k.selectProp]="none")}static enableDrag(){k.docStyle&&k.selectProp&&(k.docStyle[k.selectProp]=k.userSelect)}static setTransform(u,p){u.style[k.transformProp]=p}static addEventListener(u,p,_,M={}){u.addEventListener(p,_,"passive"in M?M:M.capture)}static removeEventListener(u,p,_,M={}){u.removeEventListener(p,_,"passive"in M?M:M.capture)}static suppressClickInternal(u){u.preventDefault(),u.stopPropagation(),window.removeEventListener("click",k.suppressClickInternal,!0)}static suppressClick(){window.addEventListener("click",k.suppressClickInternal,!0),window.setTimeout(()=>{window.removeEventListener("click",k.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,_){const M=p.boundingClientRect;return new a.P((_.clientX-M.left)/p.x-u.clientLeft,(_.clientY-M.top)/p.y-u.clientTop)}static mousePos(u,p){const _=k.getScale(u);return k.getPoint(u,_,p)}static touchPos(u,p){const _=[],M=k.getScale(u);for(let I=0;I<p.length;I++)_.push(k.getPoint(u,M,p[I]));return _}static mouseButton(u){return u.button}static remove(u){u.parentNode&&u.parentNode.removeChild(u)}}k.docStyle=typeof window<"u"&&window.document&&window.document.documentElement.style,k.selectProp=k.testProp(["userSelect","MozUserSelect","WebkitUserSelect","msUserSelect"]),k.transformProp=k.testProp(["transform","WebkitTransform"]);const P={supported:!1,testSupport:function(O){!N&&J&&($?q(O):L=O)}};let L,J,N=!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,J),O.isContextLost())return;P.supported=!0}catch{}O.deleteTexture(u),N=!0}var oe,ce;typeof document<"u"&&(J=document.createElement("img"),J.onload=function(){L&&q(L),L=null,$=!0},J.onerror=function(){N=!0,L=null},J.src="data:image/webp;base64,UklGRh4AAABXRUJQVlA4TBEAAAAvAQAAAAfQ//73v/+BiOh/AAA="),function(O){let u,p,_,M;O.resetRequestQueue=()=>{u=[],p=0,_=0,M={}},O.addThrottleControl=Q=>{const re=_++;return M[re]=Q,re},O.removeThrottleControl=Q=>{delete M[Q],z()},O.getImage=(Q,re,ue=!0)=>new Promise((pe,Ie)=>{P.supported&&(Q.headers||(Q.headers={}),Q.headers.accept="image/webp,*/*"),a.e(Q,{type:"image"}),u.push({abortController:re,requestParameters:Q,supportImageRefresh:ue,state:"queued",onError:Ne=>{Ie(Ne)},onSuccess:Ne=>{pe(Ne)}}),z()});const I=Q=>a._(this,void 0,void 0,function*(){Q.state="running";const{requestParameters:re,supportImageRefresh:ue,onError:pe,onSuccess:Ie,abortController:Ne}=Q,Re=ue===!1&&!a.i(self)&&!a.g(re.url)&&(!re.headers||Object.keys(re.headers).reduce((ht,Tt)=>ht&&Tt==="accept",!0));p++;const $e=Re?W(re,Ne):a.m(re,Ne);try{const ht=yield $e;delete Q.abortController,Q.state="completed",ht.data instanceof HTMLImageElement||a.b(ht.data)?Ie(ht):ht.data&&Ie({data:yield(Ge=ht.data,typeof createImageBitmap=="function"?a.d(Ge):a.f(Ge)),cacheControl:ht.cacheControl,expires:ht.expires})}catch(ht){delete Q.abortController,pe(ht)}finally{p--,z()}var Ge}),z=()=>{const Q=(()=>{for(const re of Object.keys(M))if(M[re]())return!0;return!1})()?a.a.MAX_PARALLEL_IMAGE_REQUESTS_PER_FRAME:a.a.MAX_PARALLEL_IMAGE_REQUESTS;for(let re=p;re<Q&&u.length>0;re++){const ue=u.shift();ue.abortController.signal.aborted?re--:I(ue)}},W=(Q,re)=>new Promise((ue,pe)=>{const Ie=new Image,Ne=Q.url,Re=Q.credentials;Re&&Re==="include"?Ie.crossOrigin="use-credentials":(Re&&Re==="same-origin"||!a.s(Ne))&&(Ie.crossOrigin="anonymous"),re.signal.addEventListener("abort",()=>{Ie.src="",pe(a.c())}),Ie.fetchPriority="high",Ie.onload=()=>{Ie.onerror=Ie.onload=null,ue({data:Ie})},Ie.onerror=()=>{Ie.onerror=Ie.onload=null,re.signal.aborted||pe(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."))},Ie.src=Ne})}(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"}(ce||(ce={}));class me{constructor(u){this._transformRequestFn=u}transformRequest(u,p){return this._transformRequestFn&&this._transformRequestFn(u,p)||{url:u}}normalizeSpriteURL(u,p,_){const M=function(I){const z=I.match(he);if(!z)throw new Error(`Unable to parse URL "${I}"`);return{protocol:z[1],authority:z[2],path:z[3]||"/",params:z[4]?z[4].split("&"):[]}}(u);return M.path+=`${p}${_}`,function(I){const z=I.params.length?`?${I.params.join("&")}`:"";return`${I.protocol}://${I.authority}${I.path}${z}`}(M)}setTransformRequest(u){this._transformRequestFn=u}}const he=/^(\w+):\/\/([^/?]*)(\/[^?]+)?\??(.+)?/;function V(O){var u=new a.A(3);return u[0]=O[0],u[1]=O[1],u[2]=O[2],u}var ae,ye=function(O,u,p){return O[0]=u[0]-p[0],O[1]=u[1]-p[1],O[2]=u[2]-p[2],O};ae=new a.A(3),a.A!=Float32Array&&(ae[0]=0,ae[1]=0,ae[2]=0);var Oe=function(O){var u=O[0],p=O[1];return u*u+p*p};function De(O){const u=[];if(typeof O=="string")u.push({id:"default",url:O});else if(O&&O.length>0){const p=[];for(const{id:_,url:M}of O){const I=`${_}${M}`;p.indexOf(I)===-1&&(p.push(I),u.push({id:_,url:M}))}}return u}(function(){var O=new a.A(2);a.A!=Float32Array&&(O[0]=0,O[1]=0)})();class He{constructor(u,p,_,M){this.context=u,this.format=_,this.texture=u.gl.createTexture(),this.update(p,M)}update(u,p,_){const{width:M,height:I}=u,z=!(this.size&&this.size[0]===M&&this.size[1]===I||_),{context:W}=this,{gl:Q}=W;if(this.useMipmap=!!(p&&p.useMipmap),Q.bindTexture(Q.TEXTURE_2D,this.texture),W.pixelStoreUnpackFlipY.set(!1),W.pixelStoreUnpack.set(1),W.pixelStoreUnpackPremultiplyAlpha.set(this.format===Q.RGBA&&(!p||p.premultiply!==!1)),z)this.size=[M,I],u instanceof HTMLImageElement||u instanceof HTMLCanvasElement||u instanceof HTMLVideoElement||u instanceof ImageData||a.b(u)?Q.texImage2D(Q.TEXTURE_2D,0,this.format,this.format,Q.UNSIGNED_BYTE,u):Q.texImage2D(Q.TEXTURE_2D,0,this.format,M,I,0,this.format,Q.UNSIGNED_BYTE,u.data);else{const{x:re,y:ue}=_||{x:0,y:0};u instanceof HTMLImageElement||u instanceof HTMLCanvasElement||u instanceof HTMLVideoElement||u instanceof ImageData||a.b(u)?Q.texSubImage2D(Q.TEXTURE_2D,0,re,ue,Q.RGBA,Q.UNSIGNED_BYTE,u):Q.texSubImage2D(Q.TEXTURE_2D,0,re,ue,M,I,Q.RGBA,Q.UNSIGNED_BYTE,u.data)}this.useMipmap&&this.isSizePowerOfTwo()&&Q.generateMipmap(Q.TEXTURE_2D)}bind(u,p,_){const{context:M}=this,{gl:I}=M;I.bindTexture(I.TEXTURE_2D,this.texture),_!==I.LINEAR_MIPMAP_NEAREST||this.isSizePowerOfTwo()||(_=I.LINEAR),u!==this.filter&&(I.texParameteri(I.TEXTURE_2D,I.TEXTURE_MAG_FILTER,u),I.texParameteri(I.TEXTURE_2D,I.TEXTURE_MIN_FILTER,_||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 ke(O){const{userImage:u}=O;return!!(u&&u.render&&u.render())&&(O.data.replace(new Uint8Array(u.data.buffer)),!0)}class nt 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:_}of this.requestors)_(this._getImagesForIds(p));this.requestors=[]}}getImage(u){const p=this.images[u];if(p&&!p.data&&p.spriteData){const _=p.spriteData;p.data=new a.R({width:_.width,height:_.height},_.context.getImageData(_.x,_.y,_.width,_.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 _=!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`))),_=!1),this._validateStretch(p.stretchY,M&&M.height)||(this.fire(new a.j(new Error(`Image "${u}" has invalid "stretchY" value`))),_=!1),this._validateContent(p.content,p)||(this.fire(new a.j(new Error(`Image "${u}" has invalid "content" value`))),_=!1),_}_validateStretch(u,p){if(!u)return!0;let _=0;for(const M of u){if(M[0]<_||M[1]<M[0]||p<M[1])return!1;_=M[1]}return!0}_validateContent(u,p){if(!u)return!0;if(u.length!==4)return!1;const _=p.spriteData,M=_&&_.width||p.data.width,I=_&&_.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,_=!0){const M=this.getImage(u);if(_&&(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,_)=>{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 _ of u){let M=this.getImage(_);M||(this.fire(new a.k("styleimagemissing",{id:_})),M=this.getImage(_)),M?p[_]={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 "${_}" 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],_=this.getImage(u);if(!_)return null;if(p&&p.position.version===_.version)return p.position;if(p)p.position.version=_.version;else{const M={w:_.data.width+2,h:_.data.height+2,x:0,y:0},I=new a.I(M,_);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 He(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:_}=a.p(u),M=this.atlasImage;M.resize({width:p||1,height:_||1});for(const I in this.patterns){const{bin:z}=this.patterns[I],W=z.x+1,Q=z.y+1,re=this.getImage(I).data,ue=re.width,pe=re.height;a.R.copy(re,M,{x:0,y:0},{x:W,y:Q},{width:ue,height:pe}),a.R.copy(re,M,{x:0,y:pe-1},{x:W,y:Q-1},{width:ue,height:1}),a.R.copy(re,M,{x:0,y:0},{x:W,y:Q+pe},{width:ue,height:1}),a.R.copy(re,M,{x:ue-1,y:0},{x:W-1,y:Q},{width:1,height:pe}),a.R.copy(re,M,{x:0,y:0},{x:W+ue,y:Q},{width:1,height:pe})}this.dirty=!0}beginFrame(){this.callbackDispatchedThisFrame={}}dispatchRenderCallbacks(u){for(const p of u){if(this.callbackDispatchedThisFrame[p])continue;this.callbackDispatchedThisFrame[p]=!0;const _=this.getImage(p);_||a.w(`Image with ID: "${p}" was not found`),ke(_)&&this.updateImage(p,_)}}}const be=1e20;function Bt(O,u,p,_,M,I,z,W,Q){for(let re=u;re<u+_;re++)kt(O,p*I+re,I,M,z,W,Q);for(let re=p;re<p+M;re++)kt(O,re*I+u,1,_,z,W,Q)}function kt(O,u,p,_,M,I,z){I[0]=0,z[0]=-be,z[1]=be,M[0]=O[u];for(let W=1,Q=0,re=0;W<_;W++){M[W]=O[u+W*p];const ue=W*W;do{const pe=I[Q];re=(M[W]-M[pe]+ue-pe*pe)/(W-pe)/2}while(re<=z[Q]&&--Q>-1);Q++,I[Q]=W,z[Q]=re,z[Q+1]=be}for(let W=0,Q=0;W<_;W++){for(;z[Q+1]<W;)Q++;const re=I[Q],ue=W-re;O[u+W*p]=M[re]+ue*ue}}class Yt{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 z of u[I])p.push(this._getAndCacheGlyphsPromise(I,z));const _=yield Promise.all(p),M={};for(const{stack:I,id:z,glyph:W}of _)M[I]||(M[I]={}),M[I][z]=W&&{id:W.id,bitmap:W.bitmap.clone(),metrics:W.metrics};return M})}_getAndCacheGlyphsPromise(u,p){return a._(this,void 0,void 0,function*(){let _=this.entries[u];_||(_=this.entries[u]={glyphs:{},requests:{},ranges:{}});let M=_.glyphs[p];if(M!==void 0)return{stack:u,id:p,glyph:M};if(M=this._tinySDF(_,u,p),M)return _.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(_.ranges[I])return{stack:u,id:p,glyph:M};if(!this.url)throw new Error("glyphsUrl is not set");if(!_.requests[I]){const W=Yt.loadGlyphRange(u,I,this.url,this.requestManager);_.requests[I]=W}const z=yield _.requests[I];for(const W in z)this._doesCharSupportLocalGlyph(+W)||(_.glyphs[+W]=z[+W]);return _.ranges[I]=!0,{stack:u,id:p,glyph:z[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,_){const M=this.localIdeographFontFamily;if(!M||!this._doesCharSupportLocalGlyph(_))return;let I=u.tinySDF;if(!I){let W="400";/bold/i.test(p)?W="900":/medium/i.test(p)?W="500":/light/i.test(p)&&(W="200"),I=u.tinySDF=new Yt.TinySDF({fontSize:48,buffer:6,radius:16,cutoff:.25,fontFamily:M,fontWeight:W})}const z=I.draw(String.fromCharCode(_));return{id:_,bitmap:new a.o({width:z.width||60,height:z.height||60},z.data),metrics:{width:z.glyphWidth/2||24,height:z.glyphHeight/2||24,left:z.glyphLeft/2+.5||0,top:z.glyphTop/2-27.5||-8,advance:z.glyphAdvance/2||24,isDoubleResolution:!0}}}}Yt.loadGlyphRange=function(O,u,p,_){return a._(this,void 0,void 0,function*(){const M=256*u,I=M+255,z=_.transformRequest(p.replace("{fontstack}",O).replace("{range}",`${M}-${I}`),ce.Glyphs),W=yield a.l(z,new AbortController);if(!W||!W.data)throw new Error(`Could not load glyph range. range: ${u}, ${M}-${I}`);const Q={};for(const re of a.n(W.data))Q[re.id]=re;return Q})},Yt.TinySDF=class{constructor({fontSize:O=24,buffer:u=3,radius:p=8,cutoff:_=.25,fontFamily:M="sans-serif",fontWeight:I="normal",fontStyle:z="normal"}={}){this.buffer=u,this.cutoff=_,this.radius=p;const W=this.size=O+4*u,Q=this._createCanvas(W),re=this.ctx=Q.getContext("2d",{willReadFrequently:!0});re.font=`${z} ${I} ${O}px ${M}`,re.textBaseline="alphabetic",re.textAlign="left",re.fillStyle="black",this.gridOuter=new Float64Array(W*W),this.gridInner=new Float64Array(W*W),this.f=new Float64Array(W),this.z=new Float64Array(W+1),this.v=new Uint16Array(W)}_createCanvas(O){const u=document.createElement("canvas");return u.width=u.height=O,u}draw(O){const{width:u,actualBoundingBoxAscent:p,actualBoundingBoxDescent:_,actualBoundingBoxLeft:M,actualBoundingBoxRight:I}=this.ctx.measureText(O),z=Math.ceil(p),W=Math.max(0,Math.min(this.size-this.buffer,Math.ceil(I-M))),Q=Math.min(this.size-this.buffer,z+Math.ceil(_)),re=W+2*this.buffer,ue=Q+2*this.buffer,pe=Math.max(re*ue,0),Ie=new Uint8ClampedArray(pe),Ne={data:Ie,width:re,height:ue,glyphWidth:W,glyphHeight:Q,glyphTop:z,glyphLeft:0,glyphAdvance:u};if(W===0||Q===0)return Ne;const{ctx:Re,buffer:$e,gridInner:Ge,gridOuter:ht}=this;Re.clearRect($e,$e,W,Q),Re.fillText(O,$e,$e+z);const Tt=Re.getImageData($e,$e,W,Q);ht.fill(be,0,pe),Ge.fill(0,0,pe);for(let Ze=0;Ze<Q;Ze++)for(let Ct=0;Ct<W;Ct++){const $t=Tt.data[4*(Ze*W+Ct)+3]/255;if($t===0)continue;const Dt=(Ze+$e)*re+Ct+$e;if($t===1)ht[Dt]=0,Ge[Dt]=be;else{const tn=.5-$t;ht[Dt]=tn>0?tn*tn:0,Ge[Dt]=tn<0?tn*tn:0}}Bt(ht,0,0,re,ue,re,this.f,this.v,this.z),Bt(Ge,$e,$e,W,Q,re,this.f,this.v,this.z);for(let Ze=0;Ze<pe;Ze++){const Ct=Math.sqrt(ht[Ze])-Math.sqrt(Ge[Ze]);Ie[Ze]=Math.round(255-255*(Ct/this.radius+this.cutoff))}return Ne}};class jt{constructor(){this.specification=a.v.light.position}possiblyEvaluate(u,p){return a.y(u.expression.evaluate(p))}interpolate(u,p,_){return{x:a.z.number(u.x,p.x,_),y:a.z.number(u.y,p.y,_),z:a.z.number(u.z,p.z,_)}}}let Xe;class rt extends a.E{constructor(u){super(),Xe=Xe||new a.q({anchor:new a.D(a.v.light.anchor),position:new jt,color:new a.D(a.v.light.color),intensity:new a.D(a.v.light.intensity)}),this._transitionable=new a.T(Xe),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 _ in u){const M=u[_];_.endsWith("-transition")?this._transitionable.setTransition(_.slice(0,-11),M):this._transitionable.setValue(_,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,_){return(!_||_.validate!==!1)&&a.t(this,u.call(a.x,{value:p,style:{glyphs:!0,sprite:!0},styleSpec:a.v}))}}class ot{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 _=u.join(",")+String(p);return this.dashEntry[_]||(this.dashEntry[_]=this.addDash(u,p)),this.dashEntry[_]}getDashRanges(u,p,_){const M=[];let I=u.length%2==1?-u[u.length-1]*_:0,z=u[0]*_,W=!0;M.push({left:I,right:z,isDash:W,zeroLength:u[0]===0});let Q=u[0];for(let re=1;re<u.length;re++){W=!W;const ue=u[re];I=Q*_,Q+=ue,z=Q*_,M.push({left:I,right:z,isDash:W,zeroLength:ue===0})}return M}addRoundDash(u,p,_){const M=p/2;for(let I=-_;I<=_;I++){const z=this.width*(this.nextRow+_+I);let W=0,Q=u[W];for(let re=0;re<this.width;re++){re/Q.right>1&&(Q=u[++W]);const ue=Math.abs(re-Q.left),pe=Math.abs(re-Q.right),Ie=Math.min(ue,pe);let Ne;const Re=I/_*(M+1);if(Q.isDash){const $e=M-Math.abs(Re);Ne=Math.sqrt(Ie*Ie+$e*$e)}else Ne=M-Math.sqrt(Ie*Ie+Re*Re);this.data[z+re]=Math.max(0,Math.min(255,Ne+128))}}}addRegularDash(u){for(let W=u.length-1;W>=0;--W){const Q=u[W],re=u[W+1];Q.zeroLength?u.splice(W,1):re&&re.isDash===Q.isDash&&(re.left=Q.left,u.splice(W,1))}const p=u[0],_=u[u.length-1];p.isDash===_.isDash&&(p.left=_.left-this.width,_.right=p.right+this.width);const M=this.width*this.nextRow;let I=0,z=u[I];for(let W=0;W<this.width;W++){W/z.right>1&&(z=u[++I]);const Q=Math.abs(W-z.left),re=Math.abs(W-z.right),ue=Math.min(Q,re);this.data[M+W]=Math.max(0,Math.min(255,(z.isDash?ue:-ue)+128))}}addDash(u,p){const _=p?7:0,M=2*_+1;if(this.nextRow+M>this.height)return a.w("LineAtlas out of space"),null;let I=0;for(let W=0;W<u.length;W++)I+=u[W];if(I!==0){const W=this.width/I,Q=this.getDashRanges(u,this.width,W);p?this.addRoundDash(Q,W,_):this.addRegularDash(Q)}const z={y:(this.nextRow+_+.5)/this.height,height:2*_/this.height,width:I};return this.nextRow+=M,this.dirty=!0,z}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 on="maplibre_preloaded_worker_pool";class gt{constructor(){this.active={}}acquire(u){if(!this.workers)for(this.workers=[];this.workers.length<gt.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[on]}numActive(){return Object.keys(this.active).length}}const at=Math.floor(B.hardwareConcurrency/2);let It,Lt;function Me(){return It||(It=new gt),It}gt.workerCount=a.B(globalThis)?Math.max(Math.min(at,3),1):1;class fe{constructor(u,p){this.workerPool=u,this.actors=[],this.currentActor=0,this.id=p;const _=this.workerPool.acquire(p);for(let M=0;M<_.length;M++){const I=new a.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 _=[];for(const M of this.actors)_.push(M.sendAsync({type:u,data:p}));return Promise.all(_)}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 _ of this.actors)_.registerMessageHandler(u,p)}}function xe(){return Lt||(Lt=new fe(Me(),a.G),Lt.registerMessageHandler("getResource",(O,u,p)=>a.m(u,p))),Lt}function Ue(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 et(O,u,p,_,M,I){const z=function(pe,Ie,Ne){if(pe)for(const Re of pe){const $e=Ie[Re];if($e&&$e.source===Ne&&$e.type==="fill-extrusion")return!0}else for(const Re in Ie){const $e=Ie[Re];if($e.source===Ne&&$e.type==="fill-extrusion")return!0}return!1}(M&&M.layers,u,O.id),W=I.maxPitchScaleFactor(),Q=O.tilesIn(_,W,z);Q.sort(it);const re=[];for(const pe of Q)re.push({wrappedTileID:pe.tileID.wrapped().key,queryResults:pe.tile.queryRenderedFeatures(u,p,O._state,pe.queryGeometry,pe.cameraQueryGeometry,pe.scale,M,I,W,Ue(O.transform,pe.tileID))});const ue=function(pe){const Ie={},Ne={};for(const Re of pe){const $e=Re.queryResults,Ge=Re.wrappedTileID,ht=Ne[Ge]=Ne[Ge]||{};for(const Tt in $e){const Ze=$e[Tt],Ct=ht[Tt]=ht[Tt]||{},$t=Ie[Tt]=Ie[Tt]||[];for(const Dt of Ze)Ct[Dt.featureIndex]||(Ct[Dt.featureIndex]=!0,$t.push(Dt))}}return Ie}(re);for(const pe in ue)ue[pe].forEach(Ie=>{const Ne=Ie.feature,Re=O.getFeatureState(Ne.layer["source-layer"],Ne.id);Ne.source=Ne.layer.source,Ne.layer["source-layer"]&&(Ne.sourceLayer=Ne.layer["source-layer"]),Ne.state=Re});return ue}function it(O,u){const p=O.tileID,_=u.tileID;return p.overscaledZ-_.overscaledZ||p.canonical.y-_.canonical.y||p.wrap-_.wrap||p.canonical.x-_.canonical.x}function bt(O,u,p){return a._(this,void 0,void 0,function*(){let _=O;if(O.url?_=(yield a.h(u.transformRequest(O.url,ce.Source),p)).data:yield B.frameAsync(p),!_)return null;const M=a.L(a.e(_,O),["tiles","minzoom","maxzoom","attribution","bounds","scheme","tileSize","encoding"]);return"vector_layers"in _&&_.vector_layers&&(M.vectorLayerIds=_.vector_layers.map(I=>I.id)),M})}class Ut{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,_=this._ne;let M,I;if(u instanceof a.M)M=u,I=u;else{if(!(u instanceof Ut))return Array.isArray(u)?u.length===4||u.every(Array.isArray)?this.extend(Ut.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||_?(p.lng=Math.min(M.lng,p.lng),p.lat=Math.min(M.lat,p.lat),_.lng=Math.max(I.lng,_.lng),_.lat=Math.max(I.lat,_.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:_}=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<=_&&_<=this._ne.lat&&M}static convert(u){return u instanceof Ut?u:u&&new Ut(u)}static fromLngLat(u,p=0){const _=360*p/40075017,M=_/Math.cos(Math.PI/180*u.lat);return new Ut(new a.M(u.lng-M,u.lat-_),new a.M(u.lng+M,u.lat+_))}}class Rt{constructor(u,p,_){this.bounds=Ut.convert(this.validateBounds(u)),this.minzoom=p||0,this.maxzoom=_||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),_=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),z=Math.ceil(a.O(this.bounds.getSouth())*p);return u.x>=_&&u.x<I&&u.y>=M&&u.y<z}}class pt extends a.E{constructor(u,p,_,M){if(super(),this.id=u,this.dispatcher=_,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 bt(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 Rt(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),_={request:this.map._requestManager.transformRequest(p,ce.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};_.request.collectResourceTiming=this._collectResourceTiming;let M="reloadTile";if(u.actor&&u.state!=="expired"){if(u.state==="loading")return new Promise((I,z)=>{u.reloadPromise={resolve:I,reject:z}})}else u.actor=this.dispatcher.getActor(),M="loadTile";u.abortController=new AbortController;try{const I=yield u.actor.sendAsync({type:M,data:_},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 _=u.reloadPromise;u.reloadPromise=null,this.loadTile(u).then(_.resolve).catch(_.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 rr extends a.E{constructor(u,p,_,M){super(),this.id=u,this.dispatcher=_,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 bt(this._options,this.map._requestManager,this._tileJSONRequest);this._tileJSONRequest=null,this._loaded=!0,u&&(a.e(this,u),u.bounds&&(this.tileBounds=new Rt(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 _=yield oe.getImage(this.map._requestManager.transformRequest(p,ce.Tile),u.abortController,this.map._refreshExpiredTiles);if(delete u.abortController,u.aborted)return void(u.state="unloaded");if(_&&_.data){this.map._refreshExpiredTiles&&_.cacheControl&&_.expires&&u.setExpiryData({cacheControl:_.cacheControl,expires:_.expires});const M=this.map.painter.context,I=M.gl,z=_.data;u.texture=this.map.painter.getTileTexture(z.width),u.texture?u.texture.update(z,{useMipmap:!0}):(u.texture=new He(M,z,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(_){if(delete u.abortController,u.aborted)u.state="unloaded";else if(_)throw u.state="errored",_}})}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 mn extends rr{constructor(u,p,_,M){super(u,p,_,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),_=this.map._requestManager.transformRequest(p,ce.Tile);u.neighboringTiles=this._getNeighboringTiles(u.tileID),u.abortController=new AbortController;try{const M=yield oe.getImage(_,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 z=a.b(I)&&a.S()?I:yield this.readImageNow(I),W={type:this.type,uid:u.uid,source:this.id,rawImageData:z,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 Q=yield u.actor.sendAsync({type:"loadDEMTile",data:W});u.dem=Q,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,_=u.height+2;try{return new a.R({width:p,height:_},yield a.V(u,-1,-1,p,_))}catch{}}return B.getImageData(u,1)})}_getNeighboringTiles(u){const p=u.canonical,_=Math.pow(2,p.z),M=(p.x-1+_)%_,I=p.x===0?u.wrap-1:u.wrap,z=(p.x+1+_)%_,W=p.x+1===_?u.wrap+1:u.wrap,Q={};return Q[new a.Q(u.overscaledZ,I,p.z,M,p.y).key]={backfilled:!1},Q[new a.Q(u.overscaledZ,W,p.z,z,p.y).key]={backfilled:!1},p.y>0&&(Q[new a.Q(u.overscaledZ,I,p.z,M,p.y-1).key]={backfilled:!1},Q[new a.Q(u.overscaledZ,u.wrap,p.z,p.x,p.y-1).key]={backfilled:!1},Q[new a.Q(u.overscaledZ,W,p.z,z,p.y-1).key]={backfilled:!1}),p.y+1<_&&(Q[new a.Q(u.overscaledZ,I,p.z,M,p.y+1).key]={backfilled:!1},Q[new a.Q(u.overscaledZ,u.wrap,p.z,p.x,p.y+1).key]={backfilled:!1},Q[new a.Q(u.overscaledZ,W,p.z,z,p.y+1).key]={backfilled:!1}),Q}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 vn extends a.E{constructor(u,p,_,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=_.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,_){return this.actor.sendAsync({type:"getClusterLeaves",data:{type:this.type,source:this.id,clusterId:u,limit:p,offset:_}})}_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(B.resolveURL(this._data),ce.Source),p.request.collectResourceTiming=this._collectResourceTiming):p.data=JSON.stringify(this._data),this._pendingLoads++,this.fire(new a.k("dataloading",{dataType:"source"}));try{const _=yield this.actor.sendAsync({type:"loadData",data:p});if(this._pendingLoads--,this._removed||_.abandoned)return void this.fire(new a.k("dataabort",{dataType:"source"}));let M=null;_.resourceTiming&&_.resourceTiming[this.id]&&(M=_.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(_){if(this._pendingLoads--,this._removed)return void this.fire(new a.k("dataabort",{dataType:"source"}));this.fire(new a.j(_))}})}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 _={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:_},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 Xn=a.X([{name:"a_pos",type:"Int16",components:2},{name:"a_texture_pos",type:"Int16",components:2}]);class cr extends a.E{constructor(u,p,_,M){super(),this.id=u,this.dispatcher=_,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,ce.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,z=1/0,W=-1/0,Q=-1/0;for(const Ie of M)I=Math.min(I,Ie.x),z=Math.min(z,Ie.y),W=Math.max(W,Ie.x),Q=Math.max(Q,Ie.y);const re=Math.max(W-I,Q-z),ue=Math.max(0,Math.floor(-Math.log(re)/Math.LN2)),pe=Math.pow(2,ue);return new a.a0(ue,Math.floor((I+W)/2*pe),Math.floor((z+Q)/2*pe))}(p),this.minzoom=this.maxzoom=this.tileID.z;const _=p.map(M=>this.tileID.getTilePoint(M)._round());return this._boundsArray=new a.Z,this._boundsArray.emplaceBack(_[0].x,_[0].y,0,0),this._boundsArray.emplaceBack(_[1].x,_[1].y,a.W,0),this._boundsArray.emplaceBack(_[3].x,_[3].y,0,a.W),this._boundsArray.emplaceBack(_[2].x,_[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,Xn.members)),this.boundsSegments||(this.boundsSegments=a.$.simpleSegment(0,0,4,2)),this.texture||(this.texture=new He(u,this.image,p.RGBA),this.texture.bind(p.LINEAR,p.CLAMP_TO_EDGE));let _=!1;for(const M in this.tiles){const I=this.tiles[M];I.state!=="loaded"&&(I.state="loaded",I.texture=this.texture,_=!0)}_&&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 cr{constructor(u,p,_,M){super(u,p,_,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,ce.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,Xn.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 He(u,this.video,p.RGBA),this.texture.bind(p.LINEAR,p.CLAMP_TO_EDGE));let _=!1;for(const M in this.tiles){const I=this.tiles[M];I.state!=="loaded"&&(I.state="loaded",I.texture=this.texture,_=!0)}_&&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 Gr extends cr{constructor(u,p,_,M){super(u,p,_,M),p.coordinates?Array.isArray(p.coordinates)&&p.coordinates.length===4&&!p.coordinates.some(I=>!Array.isArray(I)||I.length!==2||I.some(z=>typeof z!="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,_=p.gl;this.boundsBuffer||(this.boundsBuffer=p.createVertexBuffer(this._boundsArray,Xn.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 He(p,this.canvas,_.RGBA,{premultiply:!0});let M=!1;for(const I in this.tiles){const z=this.tiles[I];z.state!=="loaded"&&(z.state="loaded",z.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 gr={},mi=O=>{switch(O){case"geojson":return vn;case"image":return cr;case"raster":return rr;case"raster-dem":return mn;case"vector":return pt;case"video":return Mr;case"canvas":return Gr}return gr[O]};class Se 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=B.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 X=null;function H(){return X||(X=new Se),X}class Te{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,_){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 z={};if(!I)return z;for(const W of M){const Q=W.layerIds.map(re=>I.getLayer(re)).filter(Boolean);if(Q.length!==0){W.layers=Q,W.stateDependentLayerIds&&(W.stateDependentLayers=W.stateDependentLayerIds.map(re=>Q.filter(ue=>ue.id===re)[0]));for(const re of Q)z[re.id]=W}}return z}(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,!_)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,H().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 _ in this.buckets){const M=this.buckets[_];M.uploadPending()&&M.upload(u)}const p=u.gl;this.imageAtlas&&!this.imageAtlas.uploaded&&(this.imageAtlasTexture=new He(u,this.imageAtlas.image,p.RGBA),this.imageAtlas.uploaded=!0),this.glyphAtlasImage&&(this.glyphAtlasTexture=new He(u,this.glyphAtlasImage,p.ALPHA),this.glyphAtlasImage=null)}prepare(u){this.imageAtlas&&this.imageAtlas.patchUpdatedImages(u,this.imageAtlasTexture)}queryRenderedFeatures(u,p,_,M,I,z,W,Q,re,ue){return this.latestFeatureIndex&&this.latestFeatureIndex.rawTileData?this.latestFeatureIndex.query({queryGeometry:M,cameraQueryGeometry:I,scale:z,tileSize:this.tileSize,pixelPosMatrix:ue,transform:Q,params:W,queryPadding:this.queryPadding*re},u,p,_):{}}querySourceFeatures(u,p){const _=this.latestFeatureIndex;if(!_||!_.rawTileData)return;const M=_.loadVTLayers(),I=p&&p.sourceLayer?p.sourceLayer:"",z=M._geojsonTileLayer||M[I];if(!z)return;const W=a.a6(p&&p.filter),{z:Q,x:re,y:ue}=this.tileID.canonical,pe={z:Q,x:re,y:ue};for(let Ie=0;Ie<z.length;Ie++){const Ne=z.feature(Ie);if(W.needGeometry){const Ge=a.a7(Ne,!0);if(!W.filter(new a.a8(this.tileID.overscaledZ),Ge,this.tileID.canonical))continue}else if(!W.filter(new a.a8(this.tileID.overscaledZ),Ne))continue;const Re=_.getId(Ne,I),$e=new a.a9(Ne,Q,re,ue,Re);$e.tile=pe,u.push($e)}}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 _=a.aa(u.cacheControl);_["max-age"]&&(this.expirationTime=Date.now()+1e3*_["max-age"])}else u.expires&&(this.expirationTime=new Date(u.expires).getTime());if(this.expirationTime){const _=Date.now();let M=!1;if(this.expirationTime>_)M=!1;else if(p)if(this.expirationTime<p)M=!0;else{const I=this.expirationTime-p;I?this.expirationTime=_+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 _=this.latestFeatureIndex.loadVTLayers();for(const M in this.buckets){if(!p.style.hasLayer(M))continue;const I=this.buckets[M],z=I.layers[0].sourceLayer||"_geojsonTileLayer",W=_[z],Q=u[z];if(!W||!Q||Object.keys(Q).length===0)continue;I.update(Q,W,this.imageAtlas&&this.imageAtlas.patternPositions||{});const re=p&&p.style&&p.style.getLayer(M);re&&(this.queryPadding=Math.max(this.queryPadding,re.queryRadius(I)))}}holdingForFade(){return this.symbolFadeHoldUntil!==void 0}symbolFadeFinished(){return!this.symbolFadeHoldUntil||this.symbolFadeHoldUntil<B.now()}clearFadeHold(){this.symbolFadeHoldUntil=void 0}setHoldDuration(u){this.symbolFadeHoldUntil=B.now()+u}setDependencies(u,p){const _={};for(const M of p)_[M]=!0;this.dependencies[u]=_}hasDependency(u,p){for(const _ of u){const M=this.dependencies[_];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,_){const M=u.wrapped().key;this.data[M]===void 0&&(this.data[M]=[]);const I={value:p,timeout:void 0};if(_!==void 0&&(I.timeout=setTimeout(()=>{this.remove(u,I)},_)),this.data[M].push(I),this.order.push(M),this.order.length>this.max){const z=this._getAndRemoveByKey(this.order[0]);z&&this.onRemove(z)}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 _=u.wrapped().key,M=p===void 0?0:this.data[_].indexOf(p),I=this.data[_][M];return this.data[_].splice(M,1),I.timeout&&clearTimeout(I.timeout),this.data[_].length===0&&delete this.data[_],this.onRemove(I.value),this.order.splice(this.order.indexOf(_),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 _ in this.data)for(const M of this.data[_])u(M.value)||p.push(M);for(const _ of p)this.remove(_.value.tileID,_)}}class St{constructor(){this.state={},this.stateChanges={},this.deletedStates={}}updateState(u,p,_){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],_),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])_[I]||(this.deletedStates[u][M][I]=null)}else for(const I in _)this.deletedStates[u]&&this.deletedStates[u][M]&&this.deletedStates[u][M][I]===null&&delete this.deletedStates[u][M][I]}removeFeatureState(u,p,_){if(this.deletedStates[u]===null)return;const M=String(p);if(this.deletedStates[u]=this.deletedStates[u]||{},_&&p!==void 0)this.deletedStates[u][M]!==null&&(this.deletedStates[u][M]=this.deletedStates[u][M]||{},this.deletedStates[u][M][_]=null);else if(p!==void 0)if(this.stateChanges[u]&&this.stateChanges[u][M])for(_ in this.deletedStates[u][M]={},this.stateChanges[u][M])this.deletedStates[u][M][_]=null;else this.deletedStates[u][M]=null;else this.deletedStates[u]=null}getState(u,p){const _=String(p),M=a.e({},(this.state[u]||{})[_],(this.stateChanges[u]||{})[_]);if(this.deletedStates[u]===null)return{};if(this.deletedStates[u]){const I=this.deletedStates[u][p];if(I===null)return{};for(const z in I)delete M[z]}return M}initializeTileState(u,p){u.setFeatureState(this.state,p)}coalesceChanges(u,p){const _={};for(const M in this.stateChanges){this.state[M]=this.state[M]||{};const I={};for(const z in this.stateChanges[M])this.state[M][z]||(this.state[M][z]={}),a.e(this.state[M][z],this.stateChanges[M][z]),I[z]=this.state[M][z];_[M]=I}for(const M in this.deletedStates){this.state[M]=this.state[M]||{};const I={};if(this.deletedStates[M]===null)for(const z in this.state[M])I[z]={},this.state[M][z]={};else for(const z in this.deletedStates[M]){if(this.deletedStates[M][z]===null)this.state[M][z]={};else for(const W of Object.keys(this.deletedStates[M][z]))delete this.state[M][z][W];I[z]=this.state[M][z]}_[M]=_[M]||{},a.e(_[M],I)}if(this.stateChanges={},this.deletedStates={},Object.keys(_).length!==0)for(const M in u)u[M].setFeatureState(_,p)}}class Et extends a.E{constructor(u,p,_){super(),this.id=u,this.dispatcher=_,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,z,W)=>{const Q=new(mi(I.type))(M,I,z,W);if(Q.id!==M)throw new Error(`Expected Source id to be ${M} instead of ${Q.id}`);return Q})(u,p,_,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 St,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,_){return a._(this,void 0,void 0,function*(){try{yield this._source.loadTile(u),this._tileLoaded(u,p,_)}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 _=this._tiles[p];_.upload(u),_.prepare(this.map.style.imageManager)}}getIds(){return Object.values(this._tiles).map(u=>u.tileID).sort(Nt).map(u=>u.key)}getRenderableIds(u){const p=[];for(const _ in this._tiles)this._isIdRenderable(_,u)&&p.push(this._tiles[_]);return u?p.sort((_,M)=>{const I=_.tileID,z=M.tileID,W=new a.P(I.canonical.x,I.canonical.y)._rotate(this.transform.angle),Q=new a.P(z.canonical.x,z.canonical.y)._rotate(this.transform.angle);return I.overscaledZ-z.overscaledZ||Q.y-W.y||Q.x-W.x}).map(_=>_.tileID.key):p.map(_=>_.tileID).sort(Nt).map(_=>_.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 _=this._tiles[u];_&&(_.state!=="loading"&&(_.state=p),yield this._loadTile(_,u,p))})}_tileLoaded(u,p,_){u.timeAdded=B.now(),_==="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 z=this.getTileByID(I);_(u,z),_(z,u)}}function _(M,I){M.needsHillshadePrepare=!0,M.needsTerrainPrepare=!0;let z=I.tileID.canonical.x-M.tileID.canonical.x;const W=I.tileID.canonical.y-M.tileID.canonical.y,Q=Math.pow(2,M.tileID.canonical.z),re=I.tileID.key;z===0&&W===0||Math.abs(W)>1||(Math.abs(z)>1&&(Math.abs(z+Q)===1?z+=Q:Math.abs(z-Q)===1&&(z-=Q)),I.dem&&M.dem&&(M.dem.backfillBorder(I.dem,z,W),M.neighboringTiles&&M.neighboringTiles[re]&&(M.neighboringTiles[re].backfilled=!0)))}}getTile(u){return this.getTileByID(u.key)}getTileByID(u){return this._tiles[u]}_retainLoadedChildren(u,p,_,M){for(const I in this._tiles){let z=this._tiles[I];if(M[I]||!z.hasData()||z.tileID.overscaledZ<=p||z.tileID.overscaledZ>_)continue;let W=z.tileID;for(;z&&z.tileID.overscaledZ>p+1;){const re=z.tileID.scaledTo(z.tileID.overscaledZ-1);z=this._tiles[re.key],z&&z.hasData()&&(W=re)}let Q=W;for(;Q.overscaledZ>p;)if(Q=Q.scaledTo(Q.overscaledZ-1),u[Q.key]){M[W.key]=W;break}}}findLoadedParent(u,p){if(u.key in this._loadedParentTiles){const _=this._loadedParentTiles[u.key];return _&&_.tileID.overscaledZ>=p?_:null}for(let _=u.overscaledZ-1;_>=p;_--){const M=u.scaledTo(_),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,_=Math.ceil(u.height/this._source.tileSize)+1,M=Math.floor(p*_*(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 _={};for(const M in this._tiles){const I=this._tiles[M];I.tileID=I.tileID.unwrapTo(I.tileID.wrap+p),_[I.tileID.key]=I}this._tiles=_;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 _;this.updateCacheSize(u),this.handleWrapJump(this.transform.center.lng),this._coveredTiles={},this.used||this.usedForTerrain?this._source.tileID?_=u.getVisibleUnwrappedCoordinates(this._source.tileID).map(ue=>new a.Q(ue.canonical.z,ue.wrap,ue.canonical.z,ue.canonical.x,ue.canonical.y)):(_=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&&(_=_.filter(ue=>this._source.hasTile(ue)))):_=[];const M=u.coveringZoomLevel(this._source),I=Math.max(M-Et.maxOverzooming,this._source.minzoom),z=Math.max(M+Et.maxUnderzooming,this._source.minzoom);if(this.usedForTerrain){const ue={};for(const pe of _)if(pe.canonical.z>this._source.minzoom){const Ie=pe.scaledTo(pe.canonical.z-1);ue[Ie.key]=Ie;const Ne=pe.scaledTo(Math.max(this._source.minzoom,Math.min(pe.canonical.z,5)));ue[Ne.key]=Ne}_=_.concat(Object.values(ue))}const W=_.length===0&&!this._updated&&this._didEmitContent;this._updated=!0,W&&this.fire(new a.k("data",{sourceDataType:"idle",dataType:"source",sourceId:this.id}));const Q=this._updateRetainedTiles(_,M);if(pn(this._source.type)){const ue={},pe={},Ie=Object.keys(Q),Ne=B.now();for(const Re of Ie){const $e=Q[Re],Ge=this._tiles[Re];if(!Ge||Ge.fadeEndTime!==0&&Ge.fadeEndTime<=Ne)continue;const ht=this.findLoadedParent($e,I);ht&&(this._addTile(ht.tileID),ue[ht.tileID.key]=ht.tileID),pe[Re]=$e}this._retainLoadedChildren(pe,M,z,Q);for(const Re in ue)Q[Re]||(this._coveredTiles[Re]=!0,Q[Re]=ue[Re]);if(p){const Re={},$e={};for(const Ge of _)this._tiles[Ge.key].hasData()?Re[Ge.key]=Ge:$e[Ge.key]=Ge;for(const Ge in $e){const ht=$e[Ge].children(this._source.maxzoom);this._tiles[ht[0].key]&&this._tiles[ht[1].key]&&this._tiles[ht[2].key]&&this._tiles[ht[3].key]&&(Re[ht[0].key]=Q[ht[0].key]=ht[0],Re[ht[1].key]=Q[ht[1].key]=ht[1],Re[ht[2].key]=Q[ht[2].key]=ht[2],Re[ht[3].key]=Q[ht[3].key]=ht[3],delete $e[Ge])}for(const Ge in $e){const ht=this.findLoadedParent($e[Ge],this._source.minzoom);if(ht){Re[ht.tileID.key]=Q[ht.tileID.key]=ht.tileID;for(const Tt in Re)Re[Tt].isChildOf(ht.tileID)&&delete Re[Tt]}}for(const Ge in this._tiles)Re[Ge]||(this._coveredTiles[Ge]=!0)}}for(const ue in Q)this._tiles[ue].clearFadeHold();const re=a.ab(this._tiles,Q);for(const ue of re){const pe=this._tiles[ue];pe.hasSymbolBuckets&&!pe.holdingForFade()?pe.setHoldDuration(this.map._fadeDuration):pe.hasSymbolBuckets&&!pe.symbolFadeFinished()||this._removeTile(ue)}this._updateLoadedParentTileCache()}releaseSymbolFadeTiles(){for(const u in this._tiles)this._tiles[u].holdingForFade()&&this._removeTile(u)}_updateRetainedTiles(u,p){const _={},M={},I=Math.max(p-Et.maxOverzooming,this._source.minzoom),z=Math.max(p+Et.maxUnderzooming,this._source.minzoom),W={};for(const Q of u){const re=this._addTile(Q);_[Q.key]=Q,re.hasData()||p<this._source.maxzoom&&(W[Q.key]=Q)}this._retainLoadedChildren(W,p,z,_);for(const Q of u){let re=this._tiles[Q.key];if(re.hasData())continue;if(p+1>this._source.maxzoom){const pe=Q.children(this._source.maxzoom)[0],Ie=this.getTile(pe);if(Ie&&Ie.hasData()){_[pe.key]=pe;continue}}else{const pe=Q.children(this._source.maxzoom);if(_[pe[0].key]&&_[pe[1].key]&&_[pe[2].key]&&_[pe[3].key])continue}let ue=re.wasRequested();for(let pe=Q.overscaledZ-1;pe>=I;--pe){const Ie=Q.scaledTo(pe);if(M[Ie.key])break;if(M[Ie.key]=!0,re=this.getTile(Ie),!re&&ue&&(re=this._addTile(Ie)),re){const Ne=re.hasData();if((ue||Ne)&&(_[Ie.key]=Ie),ue=re.wasRequested(),Ne)break}}}return _}_updateLoadedParentTileCache(){this._loadedParentTiles={};for(const u in this._tiles){const p=[];let _,M=this._tiles[u].tileID;for(;M.overscaledZ>0;){if(M.key in this._loadedParentTiles){_=this._loadedParentTiles[M.key];break}p.push(M.key);const I=M.scaledTo(M.overscaledZ-1);if(_=this._getLoadedTile(I),_)break;M=I}for(const I of p)this._loadedParentTiles[I]=_}}_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 _=p;return p||(p=new Te(u,this._source.tileSize*u.overscaleFactor()),this._loadTile(p,u.key,p.state)),p.uses++,this._tiles[u.key]=p,_||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 _=p.getExpiryTimeout();_&&(this._timers[u]=setTimeout(()=>{this._reloadTile(u,"expired"),delete this._timers[u]},_))}_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,_){const M=[],I=this.transform;if(!I)return M;const z=_?I.getCameraQueryGeometry(u):u,W=u.map(Re=>I.pointCoordinate(Re,this.terrain)),Q=z.map(Re=>I.pointCoordinate(Re,this.terrain)),re=this.getIds();let ue=1/0,pe=1/0,Ie=-1/0,Ne=-1/0;for(const Re of Q)ue=Math.min(ue,Re.x),pe=Math.min(pe,Re.y),Ie=Math.max(Ie,Re.x),Ne=Math.max(Ne,Re.y);for(let Re=0;Re<re.length;Re++){const $e=this._tiles[re[Re]];if($e.holdingForFade())continue;const Ge=$e.tileID,ht=Math.pow(2,I.zoom-$e.tileID.overscaledZ),Tt=p*$e.queryPadding*a.W/$e.tileSize/ht,Ze=[Ge.getTilePoint(new a.Y(ue,pe)),Ge.getTilePoint(new a.Y(Ie,Ne))];if(Ze[0].x-Tt<a.W&&Ze[0].y-Tt<a.W&&Ze[1].x+Tt>=0&&Ze[1].y+Tt>=0){const Ct=W.map(Dt=>Ge.getTilePoint(Dt)),$t=Q.map(Dt=>Ge.getTilePoint(Dt));M.push({tile:$e,tileID:Ge,queryGeometry:Ct,cameraQueryGeometry:$t,scale:ht})}}return M}getVisibleCoordinates(u){const p=this.getRenderableIds(u).map(_=>this._tiles[_].tileID);for(const _ of p)_.posMatrix=this.transform.calculatePosMatrix(_.toUnwrapped());return p}hasTransition(){if(this._source.hasTransition())return!0;if(pn(this._source.type)){const u=B.now();for(const p in this._tiles)if(this._tiles[p].fadeEndTime>=u)return!0}return!1}setFeatureState(u,p,_){this._state.updateState(u=u||"_geojsonTileLayer",p,_)}removeFeatureState(u,p,_){this._state.removeFeatureState(u=u||"_geojsonTileLayer",p,_)}getFeatureState(u,p){return this._state.getState(u=u||"_geojsonTileLayer",p)}setDependencies(u,p,_){const M=this._tiles[u];M&&M.setDependencies(p,_)}reloadTilesForDependencies(u,p){for(const _ in this._tiles)this._tiles[_].hasDependency(u,p)&&this._reloadTile(_,"reloading");this._cache.filter(_=>!_.hasDependency(u,p))}}function Nt(O,u){const p=Math.abs(2*O.wrap)-+(O.wrap<0),_=Math.abs(2*u.wrap)-+(u.wrap<0);return O.overscaledZ-u.overscaledZ||_-p||u.canonical.y-O.canonical.y||u.canonical.x-O.canonical.x}function pn(O){return O==="raster"||O==="image"||O==="video"}Et.maxOverzooming=10,Et.maxUnderzooming=3;class Kn{constructor(u,p){this.reset(u,p)}reset(u,p){this.points=u||[],this._distances=[0];for(let _=1;_<this.points.length;_++)this._distances[_]=this._distances[_-1]+this.points[_].dist(this.points[_-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,_=this._distances[p];const M=u*this.paddedLength+this.padding;for(;_<M&&p<this._distances.length;)_=this._distances[++p];const I=p-1,z=this._distances[I],W=_-z,Q=W>0?(M-z)/W:0;return this.points[I].mult(1-Q).add(this.points[p].mult(Q))}}function En(O,u){let p=!0;return O==="always"||O!=="never"&&u!=="never"||(p=!1),p}class m{constructor(u,p,_){const M=this.boxCells=[],I=this.circleCells=[];this.xCellCount=Math.ceil(u/_),this.yCellCount=Math.ceil(p/_);for(let z=0;z<this.xCellCount*this.yCellCount;z++)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,_,M,I){this._forEachCell(p,_,M,I,this._insertBoxCell,this.boxUid++),this.boxKeys.push(u),this.bboxes.push(p),this.bboxes.push(_),this.bboxes.push(M),this.bboxes.push(I)}insertCircle(u,p,_,M){this._forEachCell(p-M,_-M,p+M,_+M,this._insertCircleCell,this.circleUid++),this.circleKeys.push(u),this.circles.push(p),this.circles.push(_),this.circles.push(M)}_insertBoxCell(u,p,_,M,I,z){this.boxCells[I].push(z)}_insertCircleCell(u,p,_,M,I,z){this.circleCells[I].push(z)}_query(u,p,_,M,I,z,W){if(_<0||u>this.width||M<0||p>this.height)return[];const Q=[];if(u<=0&&p<=0&&this.width<=_&&this.height<=M){if(I)return[{key:null,x1:u,y1:p,x2:_,y2:M}];for(let re=0;re<this.boxKeys.length;re++)Q.push({key:this.boxKeys[re],x1:this.bboxes[4*re],y1:this.bboxes[4*re+1],x2:this.bboxes[4*re+2],y2:this.bboxes[4*re+3]});for(let re=0;re<this.circleKeys.length;re++){const ue=this.circles[3*re],pe=this.circles[3*re+1],Ie=this.circles[3*re+2];Q.push({key:this.circleKeys[re],x1:ue-Ie,y1:pe-Ie,x2:ue+Ie,y2:pe+Ie})}}else this._forEachCell(u,p,_,M,this._queryCell,Q,{hitTest:I,overlapMode:z,seenUids:{box:{},circle:{}}},W);return Q}query(u,p,_,M){return this._query(u,p,_,M,!1,null)}hitTest(u,p,_,M,I,z){return this._query(u,p,_,M,!0,I,z).length>0}hitTestCircle(u,p,_,M,I){const z=u-_,W=u+_,Q=p-_,re=p+_;if(W<0||z>this.width||re<0||Q>this.height)return!1;const ue=[];return this._forEachCell(z,Q,W,re,this._queryCellCircle,ue,{hitTest:!0,overlapMode:M,circle:{x:u,y:p,radius:_},seenUids:{box:{},circle:{}}},I),ue.length>0}_queryCell(u,p,_,M,I,z,W,Q){const{seenUids:re,hitTest:ue,overlapMode:pe}=W,Ie=this.boxCells[I];if(Ie!==null){const Re=this.bboxes;for(const $e of Ie)if(!re.box[$e]){re.box[$e]=!0;const Ge=4*$e,ht=this.boxKeys[$e];if(u<=Re[Ge+2]&&p<=Re[Ge+3]&&_>=Re[Ge+0]&&M>=Re[Ge+1]&&(!Q||Q(ht))&&(!ue||!En(pe,ht.overlapMode))&&(z.push({key:ht,x1:Re[Ge],y1:Re[Ge+1],x2:Re[Ge+2],y2:Re[Ge+3]}),ue))return!0}}const Ne=this.circleCells[I];if(Ne!==null){const Re=this.circles;for(const $e of Ne)if(!re.circle[$e]){re.circle[$e]=!0;const Ge=3*$e,ht=this.circleKeys[$e];if(this._circleAndRectCollide(Re[Ge],Re[Ge+1],Re[Ge+2],u,p,_,M)&&(!Q||Q(ht))&&(!ue||!En(pe,ht.overlapMode))){const Tt=Re[Ge],Ze=Re[Ge+1],Ct=Re[Ge+2];if(z.push({key:ht,x1:Tt-Ct,y1:Ze-Ct,x2:Tt+Ct,y2:Ze+Ct}),ue)return!0}}}return!1}_queryCellCircle(u,p,_,M,I,z,W,Q){const{circle:re,seenUids:ue,overlapMode:pe}=W,Ie=this.boxCells[I];if(Ie!==null){const Re=this.bboxes;for(const $e of Ie)if(!ue.box[$e]){ue.box[$e]=!0;const Ge=4*$e,ht=this.boxKeys[$e];if(this._circleAndRectCollide(re.x,re.y,re.radius,Re[Ge+0],Re[Ge+1],Re[Ge+2],Re[Ge+3])&&(!Q||Q(ht))&&!En(pe,ht.overlapMode))return z.push(!0),!0}}const Ne=this.circleCells[I];if(Ne!==null){const Re=this.circles;for(const $e of Ne)if(!ue.circle[$e]){ue.circle[$e]=!0;const Ge=3*$e,ht=this.circleKeys[$e];if(this._circlesCollide(Re[Ge],Re[Ge+1],Re[Ge+2],re.x,re.y,re.radius)&&(!Q||Q(ht))&&!En(pe,ht.overlapMode))return z.push(!0),!0}}}_forEachCell(u,p,_,M,I,z,W,Q){const re=this._convertToXCellCoord(u),ue=this._convertToYCellCoord(p),pe=this._convertToXCellCoord(_),Ie=this._convertToYCellCoord(M);for(let Ne=re;Ne<=pe;Ne++)for(let Re=ue;Re<=Ie;Re++)if(I.call(this,u,p,_,M,this.xCellCount*Re+Ne,z,W,Q))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,_,M,I,z){const W=M-u,Q=I-p,re=_+z;return re*re>W*W+Q*Q}_circleAndRectCollide(u,p,_,M,I,z,W){const Q=(z-M)/2,re=Math.abs(u-(M+Q));if(re>Q+_)return!1;const ue=(W-I)/2,pe=Math.abs(p-(I+ue));if(pe>ue+_)return!1;if(re<=Q||pe<=ue)return!0;const Ie=re-Q,Ne=pe-ue;return Ie*Ie+Ne*Ne<=_*_}}function Kt(O,u,p,_,M){const I=a.F();return u?(a.J(I,I,[1/M,1/M,1]),p||a.ad(I,I,_.angle)):a.K(I,_.labelPlaneMatrix,O),I}function Dr(O,u,p,_,M){if(u){const I=a.ae(O);return a.J(I,I,[M,M,1]),p||a.ad(I,I,-_.angle),I}return _.glCoordMatrix}function Fn(O,u,p){let _;p?(_=[O.x,O.y,p(O.x,O.y),1],a.af(_,_,u)):(_=[O.x,O.y,0,1],Qn(_,_,u));const M=_[3];return{point:new a.P(_[0]/M,_[1]/M),signedDistanceFromCamera:M}}function Fe(O,u){return .5+O/u*.5}function de(O,u){const p=O[0]/O[3],_=O[1]/O[3];return p>=-u[0]&&p<=u[0]&&_>=-u[1]&&_<=u[1]}function Ce(O,u,p,_,M,I,z,W,Q,re){const ue=_?O.textSizeData:O.iconSizeData,pe=a.ag(ue,p.transform.zoom),Ie=[256/p.width*2+1,256/p.height*2+1],Ne=_?O.text.dynamicLayoutVertexArray:O.icon.dynamicLayoutVertexArray;Ne.clear();const Re=O.lineVertexArray,$e=_?O.text.placedSymbolArray:O.icon.placedSymbolArray,Ge=p.transform.width/p.transform.height;let ht=!1;for(let Tt=0;Tt<$e.length;Tt++){const Ze=$e.get(Tt);if(Ze.hidden||Ze.writingMode===a.ah.vertical&&!ht){Ht(Ze.numGlyphs,Ne);continue}let Ct;if(ht=!1,re?(Ct=[Ze.anchorX,Ze.anchorY,re(Ze.anchorX,Ze.anchorY),1],a.af(Ct,Ct,u)):(Ct=[Ze.anchorX,Ze.anchorY,0,1],Qn(Ct,Ct,u)),!de(Ct,Ie)){Ht(Ze.numGlyphs,Ne);continue}const $t=Fe(p.transform.cameraToCenterDistance,Ct[3]),Dt=a.ai(ue,pe,Ze),tn=z?Dt/$t:Dt*$t,dn=new a.P(Ze.anchorX,Ze.anchorY),An=Fn(dn,M,re).point,bn={projections:{},offsets:{}},tr=tt(Ze,tn,!1,W,u,M,I,O.glyphOffsetArray,Re,Ne,An,dn,bn,Ge,Q,re);ht=tr.useVertical,(tr.notEnoughRoom||ht||tr.needsFlipping&&tt(Ze,tn,!0,W,u,M,I,O.glyphOffsetArray,Re,Ne,An,dn,bn,Ge,Q,re).notEnoughRoom)&&Ht(Ze.numGlyphs,Ne)}_?O.text.dynamicLayoutVertexBuffer.updateData(Ne):O.icon.dynamicLayoutVertexBuffer.updateData(Ne)}function Be(O,u,p,_,M,I,z,W,Q,re,ue,pe,Ie){const Ne=W.glyphStartIndex+W.numGlyphs,Re=W.lineStartIndex,$e=W.lineStartIndex+W.lineLength,Ge=u.getoffsetX(W.glyphStartIndex),ht=u.getoffsetX(Ne-1),Tt=Xt(O*Ge,p,_,M,I,z,W.segment,Re,$e,Q,re,ue,pe,Ie);if(!Tt)return null;const Ze=Xt(O*ht,p,_,M,I,z,W.segment,Re,$e,Q,re,ue,pe,Ie);return Ze?{first:Tt,last:Ze}:null}function ze(O,u,p,_){return O===a.ah.horizontal&&Math.abs(p.y-u.y)>Math.abs(p.x-u.x)*_?{useVertical:!0}:(O===a.ah.vertical?u.y<p.y:u.x>p.x)?{needsFlipping:!0}:null}function tt(O,u,p,_,M,I,z,W,Q,re,ue,pe,Ie,Ne,Re,$e){const Ge=u/24,ht=O.lineOffsetX*Ge,Tt=O.lineOffsetY*Ge;let Ze;if(O.numGlyphs>1){const Ct=O.glyphStartIndex+O.numGlyphs,$t=O.lineStartIndex,Dt=O.lineStartIndex+O.lineLength,tn=Be(Ge,W,ht,Tt,p,ue,pe,O,Q,I,Ie,Re,$e);if(!tn)return{notEnoughRoom:!0};const dn=Fn(tn.first.point,z,$e).point,An=Fn(tn.last.point,z,$e).point;if(_&&!p){const bn=ze(O.writingMode,dn,An,Ne);if(bn)return bn}Ze=[tn.first];for(let bn=O.glyphStartIndex+1;bn<Ct-1;bn++)Ze.push(Xt(Ge*W.getoffsetX(bn),ht,Tt,p,ue,pe,O.segment,$t,Dt,Q,I,Ie,Re,$e));Ze.push(tn.last)}else{if(_&&!p){const $t=Fn(pe,M,$e).point,Dt=O.lineStartIndex+O.segment+1,tn=new a.P(Q.getx(Dt),Q.gety(Dt)),dn=Fn(tn,M,$e),An=dn.signedDistanceFromCamera>0?dn.point:lt(pe,tn,$t,1,M,$e),bn=ze(O.writingMode,$t,An,Ne);if(bn)return bn}const Ct=Xt(Ge*W.getoffsetX(O.glyphStartIndex),ht,Tt,p,ue,pe,O.segment,O.lineStartIndex,O.lineStartIndex+O.lineLength,Q,I,Ie,Re,$e);if(!Ct)return{notEnoughRoom:!0};Ze=[Ct]}for(const Ct of Ze)a.aj(re,Ct.point,Ct.angle);return{}}function lt(O,u,p,_,M,I){const z=Fn(O.add(O.sub(u)._unit()),M,I).point,W=p.sub(z);return p.add(W._mult(_/W.mag()))}function ft(O,u){const{projectionCache:p,lineVertexArray:_,labelPlaneMatrix:M,tileAnchorPoint:I,distanceFromAnchor:z,getElevation:W,previousVertex:Q,direction:re,absOffsetX:ue}=u;if(p.projections[O])return p.projections[O];const pe=new a.P(_.getx(O),_.gety(O)),Ie=Fn(pe,M,W);if(Ie.signedDistanceFromCamera>0)return p.projections[O]=Ie.point,Ie.point;const Ne=O-re;return lt(z===0?I:new a.P(_.getx(Ne),_.gety(Ne)),pe,Q,ue-z+1,M,W)}function Ve(O,u,p){return O._unit()._perp()._mult(u*p)}function xt(O,u,p,_,M,I,z,W){const{projectionCache:Q,direction:re}=W;if(Q.offsets[O])return Q.offsets[O];const ue=p.add(u);if(O+re<_||O+re>=M)return Q.offsets[O]=ue,ue;const pe=ft(O+re,W),Ie=Ve(pe.sub(p),z,re),Ne=p.add(Ie),Re=pe.add(Ie);return Q.offsets[O]=a.ak(I,ue,Ne,Re)||ue,Q.offsets[O]}function Xt(O,u,p,_,M,I,z,W,Q,re,ue,pe,Ie,Ne){const Re=_?O-u:O+u;let $e=Re>0?1:-1,Ge=0;_&&($e*=-1,Ge=Math.PI),$e<0&&(Ge+=Math.PI);let ht,Tt,Ze=$e>0?W+z:W+z+1,Ct=M,$t=M,Dt=0,tn=0;const dn=Math.abs(Re),An=[];let bn;for(;Dt+tn<=dn;){if(Ze+=$e,Ze<W||Ze>=Q)return null;Dt+=tn,$t=Ct,Tt=ht;const Tn={projectionCache:pe,lineVertexArray:re,labelPlaneMatrix:ue,tileAnchorPoint:I,distanceFromAnchor:Dt,getElevation:Ne,previousVertex:$t,direction:$e,absOffsetX:dn};if(Ct=ft(Ze,Tn),p===0)An.push($t),bn=Ct.sub($t);else{let xr;const Jn=Ct.sub($t);xr=Jn.mag()===0?Ve(ft(Ze+$e,Tn).sub(Ct),p,$e):Ve(Jn,p,$e),Tt||(Tt=$t.add(xr)),ht=xt(Ze,xr,Ct,W,Q,Tt,p,Tn),An.push(Tt),bn=ht.sub(Tt)}tn=bn.mag()}const tr=bn._mult((dn-Dt)/tn)._add(Tt||$t),Pr=Ge+Math.atan2(Ct.y-$t.y,Ct.x-$t.x);return An.push(tr),{point:tr,angle:Ie?Pr:0,path:An}}const Vt=new Float32Array([-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0]);function Ht(O,u){for(let p=0;p<O;p++){const _=u.length;u.resize(_+4),u.float32.set(Vt,3*_)}}function Qn(O,u,p){const _=u[0],M=u[1];return O[0]=p[0]*_+p[4]*M+p[12],O[1]=p[1]*_+p[5]*M+p[13],O[3]=p[3]*_+p[7]*M+p[15],O}const Mn=100;class or{constructor(u,p=new m(u.width+200,u.height+200,25),_=new m(u.width+200,u.height+200,25)){this.transform=u,this.grid=p,this.ignoredGrid=_,this.pitchfactor=Math.cos(u._pitch)*u.cameraToCenterDistance,this.screenRightBoundary=u.width+Mn,this.screenBottomBoundary=u.height+Mn,this.gridRightBoundary=u.width+200,this.gridBottomBoundary=u.height+200,this.perspectiveRatioCutoff=.6}placeCollisionBox(u,p,_,M,I,z){const W=this.projectAndGetPerspectiveRatio(M,u.anchorPointX,u.anchorPointY,z),Q=_*W.perspectiveRatio,re=u.x1*Q+W.point.x,ue=u.y1*Q+W.point.y,pe=u.x2*Q+W.point.x,Ie=u.y2*Q+W.point.y;return!this.isInsideGrid(re,ue,pe,Ie)||p!=="always"&&this.grid.hitTest(re,ue,pe,Ie,p,I)||W.perspectiveRatio<this.perspectiveRatioCutoff?{box:[],offscreen:!1}:{box:[re,ue,pe,Ie],offscreen:this.isOffscreen(re,ue,pe,Ie)}}placeCollisionCircles(u,p,_,M,I,z,W,Q,re,ue,pe,Ie,Ne,Re){const $e=[],Ge=new a.P(p.anchorX,p.anchorY),ht=Fn(Ge,z,Re),Tt=Fe(this.transform.cameraToCenterDistance,ht.signedDistanceFromCamera),Ze=(ue?I/Tt:I*Tt)/a.ao,Ct=Fn(Ge,W,Re).point,$t=Be(Ze,M,p.lineOffsetX*Ze,p.lineOffsetY*Ze,!1,Ct,Ge,p,_,W,{projections:{},offsets:{}},!1,Re);let Dt=!1,tn=!1,dn=!0;if($t){const An=.5*Ie*Tt+Ne,bn=new a.P(-100,-100),tr=new a.P(this.screenRightBoundary,this.screenBottomBoundary),Pr=new Kn,Tn=$t.first,xr=$t.last;let Jn=[];for(let ri=Tn.path.length-1;ri>=1;ri--)Jn.push(Tn.path[ri]);for(let ri=1;ri<xr.path.length;ri++)Jn.push(xr.path[ri]);const Ni=2.5*An;if(Q){const ri=Jn.map(Mi=>Fn(Mi,Q,Re));Jn=ri.some(Mi=>Mi.signedDistanceFromCamera<=0)?[]:ri.map(Mi=>Mi.point)}let ki=[];if(Jn.length>0){const ri=Jn[0].clone(),Mi=Jn[0].clone();for(let ea=1;ea<Jn.length;ea++)ri.x=Math.min(ri.x,Jn[ea].x),ri.y=Math.min(ri.y,Jn[ea].y),Mi.x=Math.max(Mi.x,Jn[ea].x),Mi.y=Math.max(Mi.y,Jn[ea].y);ki=ri.x>=bn.x&&Mi.x<=tr.x&&ri.y>=bn.y&&Mi.y<=tr.y?[Jn]:Mi.x<bn.x||ri.x>tr.x||Mi.y<bn.y||ri.y>tr.y?[]:a.al([Jn],bn.x,bn.y,tr.x,tr.y)}for(const ri of ki){Pr.reset(ri,.25*An);let Mi=0;Mi=Pr.length<=.5*An?1:Math.ceil(Pr.paddedLength/Ni)+1;for(let ea=0;ea<Mi;ea++){const Ui=ea/Math.max(Mi-1,1),Ds=Pr.lerp(Ui),bs=Ds.x+Mn,Ho=Ds.y+Mn;$e.push(bs,Ho,An,0);const Ls=bs-An,Ta=Ho-An,Eo=bs+An,jl=Ho+An;if(dn=dn&&this.isOffscreen(Ls,Ta,Eo,jl),tn=tn||this.isInsideGrid(Ls,Ta,Eo,jl),u!=="always"&&this.grid.hitTestCircle(bs,Ho,An,u,pe)&&(Dt=!0,!re))return{circles:[],offscreen:!1,collisionDetected:Dt}}}}return{circles:!re&&Dt||!tn||Tt<this.perspectiveRatioCutoff?[]:$e,offscreen:dn,collisionDetected:Dt}}queryRenderedSymbols(u){if(u.length===0||this.grid.keysLength()===0&&this.ignoredGrid.keysLength()===0)return{};const p=[];let _=1/0,M=1/0,I=-1/0,z=-1/0;for(const ue of u){const pe=new a.P(ue.x+Mn,ue.y+Mn);_=Math.min(_,pe.x),M=Math.min(M,pe.y),I=Math.max(I,pe.x),z=Math.max(z,pe.y),p.push(pe)}const W=this.grid.query(_,M,I,z).concat(this.ignoredGrid.query(_,M,I,z)),Q={},re={};for(const ue of W){const pe=ue.key;if(Q[pe.bucketInstanceId]===void 0&&(Q[pe.bucketInstanceId]={}),Q[pe.bucketInstanceId][pe.featureIndex])continue;const Ie=[new a.P(ue.x1,ue.y1),new a.P(ue.x2,ue.y1),new a.P(ue.x2,ue.y2),new a.P(ue.x1,ue.y2)];a.am(p,Ie)&&(Q[pe.bucketInstanceId][pe.featureIndex]=!0,re[pe.bucketInstanceId]===void 0&&(re[pe.bucketInstanceId]=[]),re[pe.bucketInstanceId].push(pe.featureIndex))}return re}insertCollisionBox(u,p,_,M,I,z){(_?this.ignoredGrid:this.grid).insert({bucketInstanceId:M,featureIndex:I,collisionGroupID:z,overlapMode:p},u[0],u[1],u[2],u[3])}insertCollisionCircles(u,p,_,M,I,z){const W=_?this.ignoredGrid:this.grid,Q={bucketInstanceId:M,featureIndex:I,collisionGroupID:z,overlapMode:p};for(let re=0;re<u.length;re+=4)W.insertCircle(Q,u[re],u[re+1],u[re+2])}projectAndGetPerspectiveRatio(u,p,_,M){let I;return M?(I=[p,_,M(p,_),1],a.af(I,I,u)):(I=[p,_,0,1],Qn(I,I,u)),{point:new a.P((I[0]/I[3]+1)/2*this.transform.width+Mn,(-I[1]/I[3]+1)/2*this.transform.height+Mn),perspectiveRatio:.5+this.transform.cameraToCenterDistance/I[3]*.5}}isOffscreen(u,p,_,M){return _<Mn||u>=this.screenRightBoundary||M<Mn||p>this.screenBottomBoundary}isInsideGrid(u,p,_,M){return _>=0&&u<this.gridRightBoundary&&M>=0&&p<this.gridBottomBoundary}getViewportMatrix(){const u=a.an([]);return a.H(u,u,[-100,-100,0]),u}}function ar(O,u,p){return u*(a.W/(O.tileSize*Math.pow(2,p-O.tileID.overscaledZ)))}class kr{constructor(u,p,_,M){this.opacity=u?Math.max(0,Math.min(1,u.opacity+(u.placed?p:-p))):M&&_?1:0,this.placed=_}isHidden(){return this.opacity===0&&!this.placed}}class jr{constructor(u,p,_,M,I){this.text=new kr(u?u.text:null,p,_,I),this.icon=new kr(u?u.icon:null,p,M,I)}isHidden(){return this.text.isHidden()&&this.icon.isHidden()}}class Lr{constructor(u,p,_){this.text=u,this.icon=p,this.skipFade=_}}class Wr{constructor(){this.invProjMatrix=a.F(),this.viewportMatrix=a.F(),this.circles=[]}}class ir{constructor(u,p,_,M,I){this.bucketInstanceId=u,this.featureIndex=p,this.sourceLayerIndex=_,this.bucketIndex=M,this.tileID=I}}class ui{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:_=>_.collisionGroupID===p}}return this.collisionGroups[u]}}function Oi(O,u,p,_,M){const{horizontalAlign:I,verticalAlign:z}=a.at(O);return new a.P(-(I-.5)*u+_[0]*M,-(z-.5)*p+_[1]*M)}function Yi(O,u,p,_,M,I){const{x1:z,x2:W,y1:Q,y2:re,anchorPointX:ue,anchorPointY:pe}=O,Ie=new a.P(u,p);return _&&Ie._rotate(M?I:-I),{x1:z+Ie.x,y1:Q+Ie.y,x2:W+Ie.x,y2:re+Ie.y,anchorPointX:ue,anchorPointY:pe}}class _o{constructor(u,p,_,M,I){this.transform=u.clone(),this.terrain=p,this.collisionIndex=new or(this.transform),this.placements={},this.opacities={},this.variableOffsets={},this.stale=!1,this.commitTime=0,this.fadeDuration=_,this.retainedQueryData={},this.collisionGroups=new ui(M),this.collisionCircleArrays={},this.prevPlacement=I,I&&(I.prevPlacement=void 0),this.placedOrientations={}}getBucketParts(u,p,_,M){const I=_.getBucket(p),z=_.latestFeatureIndex;if(!I||!z||p.id!==I.layerIds[0])return;const W=_.collisionBoxArray,Q=I.layers[0].layout,re=Math.pow(2,this.transform.zoom-_.tileID.overscaledZ),ue=_.tileSize/a.W,pe=this.transform.calculatePosMatrix(_.tileID.toUnwrapped()),Ie=Q.get("text-pitch-alignment")==="map",Ne=Q.get("text-rotation-alignment")==="map",Re=ar(_,1,this.transform.zoom),$e=Kt(pe,Ie,Ne,this.transform,Re);let Ge=null;if(Ie){const Tt=Dr(pe,Ie,Ne,this.transform,Re);Ge=a.K([],this.transform.labelPlaneMatrix,Tt)}this.retainedQueryData[I.bucketInstanceId]=new ir(I.bucketInstanceId,z,I.sourceLayerIndex,I.index,_.tileID);const ht={bucket:I,layout:Q,posMatrix:pe,textLabelPlaneMatrix:$e,labelToScreenMatrix:Ge,scale:re,textPixelRatio:ue,holdingForFade:_.holdingForFade(),collisionBoxArray:W,partiallyEvaluatedTextSize:a.ag(I.textSizeData,this.transform.zoom),collisionGroup:this.collisionGroups.get(I.sourceID)};if(M)for(const Tt of I.sortKeyRanges){const{sortKey:Ze,symbolInstanceStart:Ct,symbolInstanceEnd:$t}=Tt;u.push({sortKey:Ze,symbolInstanceStart:Ct,symbolInstanceEnd:$t,parameters:ht})}else u.push({symbolInstanceStart:0,symbolInstanceEnd:I.symbolInstances.length,parameters:ht})}attemptAnchorPlacement(u,p,_,M,I,z,W,Q,re,ue,pe,Ie,Ne,Re,$e,Ge){const ht=a.ap[u.textAnchor],Tt=[u.textOffset0,u.textOffset1],Ze=Oi(ht,_,M,Tt,I),Ct=this.collisionIndex.placeCollisionBox(Yi(p,Ze.x,Ze.y,z,W,this.transform.angle),pe,Q,re,ue.predicate,Ge);if((!$e||this.collisionIndex.placeCollisionBox(Yi($e,Ze.x,Ze.y,z,W,this.transform.angle),pe,Q,re,ue.predicate,Ge).box.length!==0)&&Ct.box.length>0){let $t;if(this.prevPlacement&&this.prevPlacement.variableOffsets[Ie.crossTileID]&&this.prevPlacement.placements[Ie.crossTileID]&&this.prevPlacement.placements[Ie.crossTileID].text&&($t=this.prevPlacement.variableOffsets[Ie.crossTileID].anchor),Ie.crossTileID===0)throw new Error("symbolInstance.crossTileID can't be 0");return this.variableOffsets[Ie.crossTileID]={textOffset:Tt,width:_,height:M,anchor:ht,textBoxScale:I,prevAnchor:$t},this.markUsedJustification(Ne,ht,Ie,Re),Ne.allowVerticalPlacement&&(this.markUsedOrientation(Ne,Re,Ie),this.placedOrientations[Ie.crossTileID]=Re),{shift:Ze,placedGlyphBoxes:Ct}}}placeLayerBucketPart(u,p,_){const{bucket:M,layout:I,posMatrix:z,textLabelPlaneMatrix:W,labelToScreenMatrix:Q,textPixelRatio:re,holdingForFade:ue,collisionBoxArray:pe,partiallyEvaluatedTextSize:Ie,collisionGroup:Ne}=u.parameters,Re=I.get("text-optional"),$e=I.get("icon-optional"),Ge=a.aq(I,"text-overlap","text-allow-overlap"),ht=Ge==="always",Tt=a.aq(I,"icon-overlap","icon-allow-overlap"),Ze=Tt==="always",Ct=I.get("text-rotation-alignment")==="map",$t=I.get("text-pitch-alignment")==="map",Dt=I.get("icon-text-fit")!=="none",tn=I.get("symbol-z-order")==="viewport-y",dn=ht&&(Ze||!M.hasIconData()||$e),An=Ze&&(ht||!M.hasTextData()||Re);!M.collisionArrays&&pe&&M.deserializeCollisionBoxes(pe);const bn=this.retainedQueryData[M.bucketInstanceId].tileID,tr=this.terrain?(Tn,xr)=>this.terrain.getElevation(bn,Tn,xr):null,Pr=(Tn,xr)=>{var Jn,Ni;if(p[Tn.crossTileID])return;if(ue)return void(this.placements[Tn.crossTileID]=new Lr(!1,!1,!1));let ki=!1,ri=!1,Mi=!0,ea=null,Ui={box:null,offscreen:null},Ds={box:null,offscreen:null},bs=null,Ho=null,Ls=null,Ta=0,Eo=0,jl=0;xr.textFeatureIndex?Ta=xr.textFeatureIndex:Tn.useRuntimeCollisionCircles&&(Ta=Tn.featureIndex),xr.verticalTextFeatureIndex&&(Eo=xr.verticalTextFeatureIndex);const zA=xr.textBox;if(zA){const Ka=Ko=>{let $a=a.ah.horizontal;if(M.allowVerticalPlacement&&!Ko&&this.prevPlacement){const ls=this.prevPlacement.placedOrientations[Tn.crossTileID];ls&&(this.placedOrientations[Tn.crossTileID]=ls,$a=ls,this.markUsedOrientation(M,$a,Tn))}return $a},Lo=(Ko,$a)=>{if(M.allowVerticalPlacement&&Tn.numVerticalGlyphVertices>0&&xr.verticalTextBox){for(const ls of M.writingModes)if(ls===a.ah.vertical?(Ui=$a(),Ds=Ui):Ui=Ko(),Ui&&Ui.box&&Ui.box.length)break}else Ui=Ko()},Pi=Tn.textAnchorOffsetStartIndex,vo=Tn.textAnchorOffsetEndIndex;if(vo===Pi){const Ko=($a,ls)=>{const Aa=this.collisionIndex.placeCollisionBox($a,Ge,re,z,Ne.predicate,tr);return Aa&&Aa.box&&Aa.box.length&&(this.markUsedOrientation(M,ls,Tn),this.placedOrientations[Tn.crossTileID]=ls),Aa};Lo(()=>Ko(zA,a.ah.horizontal),()=>{const $a=xr.verticalTextBox;return M.allowVerticalPlacement&&Tn.numVerticalGlyphVertices>0&&$a?Ko($a,a.ah.vertical):{box:null,offscreen:null}}),Ka(Ui&&Ui.box&&Ui.box.length)}else{let Ko=a.ap[(Ni=(Jn=this.prevPlacement)===null||Jn===void 0?void 0:Jn.variableOffsets[Tn.crossTileID])===null||Ni===void 0?void 0:Ni.anchor];const $a=(Aa,vc,_a)=>{const jA=Aa.x2-Aa.x1,Oh=Aa.y2-Aa.y1,nu=Tn.textBoxScale,WA=Dt&&Tt==="never"?vc:null;let Xs={box:[],offscreen:!1},Ld=Ge==="never"?1:2,_c="never";Ko&&Ld++;for(let Bh=0;Bh<Ld;Bh++){for(let qu=Pi;qu<vo;qu++){const Uf=M.textAnchorOffsets.get(qu);if(Ko&&Uf.textAnchor!==Ko)continue;const Xc=this.attemptAnchorPlacement(Uf,Aa,jA,Oh,nu,Ct,$t,re,z,Ne,_c,Tn,M,_a,WA,tr);if(Xc&&(Xs=Xc.placedGlyphBoxes,Xs&&Xs.box&&Xs.box.length))return ki=!0,ea=Xc.shift,Xs}Ko?Ko=null:_c=Ge}return Xs};Lo(()=>$a(zA,xr.iconBox,a.ah.horizontal),()=>{const Aa=xr.verticalTextBox;return M.allowVerticalPlacement&&!(Ui&&Ui.box&&Ui.box.length)&&Tn.numVerticalGlyphVertices>0&&Aa?$a(Aa,xr.verticalIconBox,a.ah.vertical):{box:null,offscreen:null}}),Ui&&(ki=Ui.box,Mi=Ui.offscreen);const ls=Ka(Ui&&Ui.box);if(!ki&&this.prevPlacement){const Aa=this.prevPlacement.variableOffsets[Tn.crossTileID];Aa&&(this.variableOffsets[Tn.crossTileID]=Aa,this.markUsedJustification(M,Aa.anchor,Tn,ls))}}}if(bs=Ui,ki=bs&&bs.box&&bs.box.length>0,Mi=bs&&bs.offscreen,Tn.useRuntimeCollisionCircles){const Ka=M.text.placedSymbolArray.get(Tn.centerJustifiedTextSymbolIndex),Lo=a.ai(M.textSizeData,Ie,Ka),Pi=I.get("text-padding");Ho=this.collisionIndex.placeCollisionCircles(Ge,Ka,M.lineVertexArray,M.glyphOffsetArray,Lo,z,W,Q,_,$t,Ne.predicate,Tn.collisionCircleDiameter,Pi,tr),Ho.circles.length&&Ho.collisionDetected&&!_&&a.w("Collisions detected, but collision boxes are not shown"),ki=ht||Ho.circles.length>0&&!Ho.collisionDetected,Mi=Mi&&Ho.offscreen}if(xr.iconFeatureIndex&&(jl=xr.iconFeatureIndex),xr.iconBox){const Ka=Lo=>{const Pi=Dt&&ea?Yi(Lo,ea.x,ea.y,Ct,$t,this.transform.angle):Lo;return this.collisionIndex.placeCollisionBox(Pi,Tt,re,z,Ne.predicate,tr)};Ds&&Ds.box&&Ds.box.length&&xr.verticalIconBox?(Ls=Ka(xr.verticalIconBox),ri=Ls.box.length>0):(Ls=Ka(xr.iconBox),ri=Ls.box.length>0),Mi=Mi&&Ls.offscreen}const Us=Re||Tn.numHorizontalGlyphVertices===0&&Tn.numVerticalGlyphVertices===0,Mu=$e||Tn.numIconVertices===0;if(Us||Mu?Mu?Us||(ri=ri&&ki):ki=ri&&ki:ri=ki=ri&&ki,ki&&bs&&bs.box&&this.collisionIndex.insertCollisionBox(bs.box,Ge,I.get("text-ignore-placement"),M.bucketInstanceId,Ds&&Ds.box&&Eo?Eo:Ta,Ne.ID),ri&&Ls&&this.collisionIndex.insertCollisionBox(Ls.box,Tt,I.get("icon-ignore-placement"),M.bucketInstanceId,jl,Ne.ID),Ho&&(ki&&this.collisionIndex.insertCollisionCircles(Ho.circles,Ge,I.get("text-ignore-placement"),M.bucketInstanceId,Ta,Ne.ID),_)){const Ka=M.bucketInstanceId;let Lo=this.collisionCircleArrays[Ka];Lo===void 0&&(Lo=this.collisionCircleArrays[Ka]=new Wr);for(let Pi=0;Pi<Ho.circles.length;Pi+=4)Lo.circles.push(Ho.circles[Pi+0]),Lo.circles.push(Ho.circles[Pi+1]),Lo.circles.push(Ho.circles[Pi+2]),Lo.circles.push(Ho.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 Lr(ki||dn,ri||An,Mi||M.justReloaded),p[Tn.crossTileID]=!0};if(tn){if(u.symbolInstanceStart!==0)throw new Error("bucket.bucketInstanceId should be 0");const Tn=M.getSortedSymbolIndexes(this.transform.angle);for(let xr=Tn.length-1;xr>=0;--xr){const Jn=Tn[xr];Pr(M.symbolInstances.get(Jn),M.collisionArrays[Jn])}}else for(let Tn=u.symbolInstanceStart;Tn<u.symbolInstanceEnd;Tn++)Pr(M.symbolInstances.get(Tn),M.collisionArrays[Tn]);if(_&&M.bucketInstanceId in this.collisionCircleArrays){const Tn=this.collisionCircleArrays[M.bucketInstanceId];a.ar(Tn.invProjMatrix,z),Tn.viewportMatrix=this.collisionIndex.getViewportMatrix()}M.justReloaded=!1}markUsedJustification(u,p,_,M){let I;I=M===a.ah.vertical?_.verticalPlacedTextSymbolIndex:{left:_.leftJustifiedTextSymbolIndex,center:_.centerJustifiedTextSymbolIndex,right:_.rightJustifiedTextSymbolIndex}[a.as(p)];const z=[_.leftJustifiedTextSymbolIndex,_.centerJustifiedTextSymbolIndex,_.rightJustifiedTextSymbolIndex,_.verticalPlacedTextSymbolIndex];for(const W of z)W>=0&&(u.text.placedSymbolArray.get(W).crossTileID=I>=0&&W!==I?0:_.crossTileID)}markUsedOrientation(u,p,_){const M=p===a.ah.horizontal||p===a.ah.horizontalOnly?p:0,I=p===a.ah.vertical?p:0,z=[_.leftJustifiedTextSymbolIndex,_.centerJustifiedTextSymbolIndex,_.rightJustifiedTextSymbolIndex];for(const W of z)u.text.placedSymbolArray.get(W).placedOrientation=M;_.verticalPlacedTextSymbolIndex&&(u.text.placedSymbolArray.get(_.verticalPlacedTextSymbolIndex).placedOrientation=I)}commit(u){this.commitTime=u,this.zoomAtLastRecencyCheck=this.transform.zoom;const p=this.prevPlacement;let _=!1;this.prevZoomAdjustment=p?p.zoomAdjustment(this.transform.zoom):0;const M=p?p.symbolFadeChange(u):1,I=p?p.opacities:{},z=p?p.variableOffsets:{},W=p?p.placedOrientations:{};for(const Q in this.placements){const re=this.placements[Q],ue=I[Q];ue?(this.opacities[Q]=new jr(ue,M,re.text,re.icon),_=_||re.text!==ue.text.placed||re.icon!==ue.icon.placed):(this.opacities[Q]=new jr(null,M,re.text,re.icon,re.skipFade),_=_||re.text||re.icon)}for(const Q in I){const re=I[Q];if(!this.opacities[Q]){const ue=new jr(re,M,!1,!1);ue.isHidden()||(this.opacities[Q]=ue,_=_||re.text.placed||re.icon.placed)}}for(const Q in z)this.variableOffsets[Q]||!this.opacities[Q]||this.opacities[Q].isHidden()||(this.variableOffsets[Q]=z[Q]);for(const Q in W)this.placedOrientations[Q]||!this.opacities[Q]||this.opacities[Q].isHidden()||(this.placedOrientations[Q]=W[Q]);if(p&&p.lastPlacementChangeTime===void 0)throw new Error("Last placement time for previous placement is not defined");_?this.lastPlacementChangeTime=u:typeof this.lastPlacementChangeTime!="number"&&(this.lastPlacementChangeTime=p?p.lastPlacementChangeTime:u)}updateLayerOpacities(u,p){const _={};for(const M of p){const I=M.getBucket(u);I&&M.latestFeatureIndex&&u.id===I.layerIds[0]&&this.updateBucketOpacities(I,_,M.collisionBoxArray)}}updateBucketOpacities(u,p,_){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,z=new jr(null,0,!1,!1,!0),W=I.get("text-allow-overlap"),Q=I.get("icon-allow-overlap"),re=M._unevaluatedLayout.hasValue("text-variable-anchor")||M._unevaluatedLayout.hasValue("text-variable-anchor-offset"),ue=I.get("text-rotation-alignment")==="map",pe=I.get("text-pitch-alignment")==="map",Ie=I.get("icon-text-fit")!=="none",Ne=new jr(null,0,W&&(Q||!u.hasIconData()||I.get("icon-optional")),Q&&(W||!u.hasTextData()||I.get("text-optional")),!0);!u.collisionArrays&&_&&(u.hasIconCollisionBoxData()||u.hasTextCollisionBoxData())&&u.deserializeCollisionBoxes(_);const Re=($e,Ge,ht)=>{for(let Tt=0;Tt<Ge/4;Tt++)$e.opacityVertexArray.emplaceBack(ht);$e.hasVisibleVertices=$e.hasVisibleVertices||ht!==io};for(let $e=0;$e<u.symbolInstances.length;$e++){const Ge=u.symbolInstances.get($e),{numHorizontalGlyphVertices:ht,numVerticalGlyphVertices:Tt,crossTileID:Ze}=Ge;let Ct=this.opacities[Ze];p[Ze]?Ct=z:Ct||(Ct=Ne,this.opacities[Ze]=Ct),p[Ze]=!0;const $t=Ge.numIconVertices>0,Dt=this.placedOrientations[Ge.crossTileID],tn=Dt===a.ah.vertical,dn=Dt===a.ah.horizontal||Dt===a.ah.horizontalOnly;if(ht>0||Tt>0){const An=eo(Ct.text);Re(u.text,ht,tn?io:An),Re(u.text,Tt,dn?io:An);const bn=Ct.text.isHidden();[Ge.rightJustifiedTextSymbolIndex,Ge.centerJustifiedTextSymbolIndex,Ge.leftJustifiedTextSymbolIndex].forEach(Tn=>{Tn>=0&&(u.text.placedSymbolArray.get(Tn).hidden=bn||tn?1:0)}),Ge.verticalPlacedTextSymbolIndex>=0&&(u.text.placedSymbolArray.get(Ge.verticalPlacedTextSymbolIndex).hidden=bn||dn?1:0);const tr=this.variableOffsets[Ge.crossTileID];tr&&this.markUsedJustification(u,tr.anchor,Ge,Dt);const Pr=this.placedOrientations[Ge.crossTileID];Pr&&(this.markUsedJustification(u,"left",Ge,Pr),this.markUsedOrientation(u,Pr,Ge))}if($t){const An=eo(Ct.icon),bn=!(Ie&&Ge.verticalPlacedIconSymbolIndex&&tn);Ge.placedIconSymbolIndex>=0&&(Re(u.icon,Ge.numIconVertices,bn?An:io),u.icon.placedSymbolArray.get(Ge.placedIconSymbolIndex).hidden=Ct.icon.isHidden()),Ge.verticalPlacedIconSymbolIndex>=0&&(Re(u.icon,Ge.numVerticalIconVertices,bn?io:An),u.icon.placedSymbolArray.get(Ge.verticalPlacedIconSymbolIndex).hidden=Ct.icon.isHidden())}if(u.hasIconCollisionBoxData()||u.hasTextCollisionBoxData()){const An=u.collisionArrays[$e];if(An){let bn=new a.P(0,0);if(An.textBox||An.verticalTextBox){let Pr=!0;if(re){const Tn=this.variableOffsets[Ze];Tn?(bn=Oi(Tn.anchor,Tn.width,Tn.height,Tn.textOffset,Tn.textBoxScale),ue&&bn._rotate(pe?this.transform.angle:-this.transform.angle)):Pr=!1}An.textBox&&Jr(u.textCollisionBox.collisionVertexArray,Ct.text.placed,!Pr||tn,bn.x,bn.y),An.verticalTextBox&&Jr(u.textCollisionBox.collisionVertexArray,Ct.text.placed,!Pr||dn,bn.x,bn.y)}const tr=!!(!dn&&An.verticalIconBox);An.iconBox&&Jr(u.iconCollisionBox.collisionVertexArray,Ct.icon.placed,tr,Ie?bn.x:0,Ie?bn.y:0),An.verticalIconBox&&Jr(u.iconCollisionBox.collisionVertexArray,Ct.icon.placed,!tr,Ie?bn.x:0,Ie?bn.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 $e=this.collisionCircleArrays[u.bucketInstanceId];u.placementInvProjMatrix=$e.invProjMatrix,u.placementViewportMatrix=$e.viewportMatrix,u.collisionCircleArray=$e.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 _=this.zoomAtLastRecencyCheck===p?1-this.zoomAdjustment(p):1;return this.zoomAtLastRecencyCheck=p,this.commitTime+this.fadeDuration*_>u}setStale(){this.stale=!0}}function Jr(O,u,p,_,M){O.emplaceBack(u?1:0,p?1:0,_||0,M||0),O.emplaceBack(u?1:0,p?1:0,_||0,M||0),O.emplaceBack(u?1:0,p?1:0,_||0,M||0),O.emplaceBack(u?1:0,p?1:0,_||0,M||0)}const xo=Math.pow(2,25),Wa=Math.pow(2,24),Ba=Math.pow(2,17),bi=Math.pow(2,16),os=Math.pow(2,9),hi=Math.pow(2,8),Wn=Math.pow(2,1);function eo(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*xo+u*Wa+p*Ba+u*bi+p*os+u*hi+p*Wn+u}const io=0;class qi{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,_,M,I){const z=this._bucketParts;for(;this._currentTileIndex<u.length;)if(p.getBucketParts(z,M,u[this._currentTileIndex],this._sortAcrossTiles),this._currentTileIndex++,I())return!0;for(this._sortAcrossTiles&&(this._sortAcrossTiles=!1,z.sort((W,Q)=>W.sortKey-Q.sortKey));this._currentPartIndex<z.length;)if(p.placeLayerBucketPart(z[this._currentPartIndex],this._seenCrossTileIDs,_),this._currentPartIndex++,I())return!0;return!1}}class ve{constructor(u,p,_,M,I,z,W,Q){this.placement=new _o(u,p,z,W,Q),this._currentPlacementIndex=_.length-1,this._forceFullPlacement=M,this._showCollisionBoxes=I,this._done=!1}isDone(){return this._done}continuePlacement(u,p,_){const M=B.now(),I=()=>!this._forceFullPlacement&&B.now()-M>2;for(;this._currentPlacementIndex>=0;){const z=p[u[this._currentPlacementIndex]],W=this.placement.collisionIndex.transform.zoom;if(z.type==="symbol"&&(!z.minzoom||z.minzoom<=W)&&(!z.maxzoom||z.maxzoom>W)){if(this._inProgressLayer||(this._inProgressLayer=new qi(z)),this._inProgressLayer.continuePlacement(_[z.source],this.placement,this._showCollisionBoxes,z,I))return;delete this._inProgressLayer}this._currentPlacementIndex--}this._done=!0}commit(u){return this.placement.commit(u),this.placement}}const Ye=512/a.W/2;class Jt{constructor(u,p,_){this.tileID=u,this.bucketInstanceId=_,this._symbolsByKey={};const M=new Map;for(let I=0;I<p.length;I++){const z=p.get(I),W=z.key,Q=M.get(W);Q?Q.push(z):M.set(W,[z])}for(const[I,z]of M){const W={positions:z.map(Q=>({x:Math.floor(Q.anchorX*Ye),y:Math.floor(Q.anchorY*Ye)})),crossTileIDs:z.map(Q=>Q.crossTileID)};if(W.positions.length>128){const Q=new a.au(W.positions.length,16,Uint16Array);for(const{x:re,y:ue}of W.positions)Q.add(re,ue);Q.finish(),delete W.positions,W.index=Q}this._symbolsByKey[I]=W}}getScaledCoordinates(u,p){const{x:_,y:M,z:I}=this.tileID.canonical,{x:z,y:W,z:Q}=p.canonical,re=Ye/Math.pow(2,Q-I),ue=(W*a.W+u.anchorY)*re,pe=M*a.W*Ye;return{x:Math.floor((z*a.W+u.anchorX)*re-_*a.W*Ye),y:Math.floor(ue-pe)}}findMatches(u,p,_){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 z=u.get(I);if(z.crossTileID)continue;const W=this._symbolsByKey[z.key];if(!W)continue;const Q=this.getScaledCoordinates(z,p);if(W.index){const re=W.index.range(Q.x-M,Q.y-M,Q.x+M,Q.y+M).sort();for(const ue of re){const pe=W.crossTileIDs[ue];if(!_[pe]){_[pe]=!0,z.crossTileID=pe;break}}}else if(W.positions)for(let re=0;re<W.positions.length;re++){const ue=W.positions[re],pe=W.crossTileIDs[re];if(Math.abs(ue.x-Q.x)<=M&&Math.abs(ue.y-Q.y)<=M&&!_[pe]){_[pe]=!0,z.crossTileID=pe;break}}}}getCrossTileIDsLists(){return Object.values(this._symbolsByKey).map(({crossTileIDs:u})=>u)}}class sn{constructor(){this.maxCrossTileID=0}generate(){return++this.maxCrossTileID}}class Ft{constructor(){this.indexes={},this.usedCrossTileIDs={},this.lng=0}handleWrapJump(u){const p=Math.round((u-this.lng)/360);if(p!==0)for(const _ in this.indexes){const M=this.indexes[_],I={};for(const z in M){const W=M[z];W.tileID=W.tileID.unwrapTo(W.tileID.wrap+p),I[W.tileID.key]=W}this.indexes[_]=I}this.lng=u}addBucket(u,p,_){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 z=this.indexes[I];if(Number(I)>u.overscaledZ)for(const W in z){const Q=z[W];Q.tileID.isChildOf(u)&&Q.findMatches(p.symbolInstances,u,M)}else{const W=z[u.scaledTo(Number(I)).key];W&&W.findMatches(p.symbolInstances,u,M)}}for(let I=0;I<p.symbolInstances.length;I++){const z=p.symbolInstances.get(I);z.crossTileID||(z.crossTileID=_.generate(),M[z.crossTileID]=!0)}return this.indexes[u.overscaledZ]===void 0&&(this.indexes[u.overscaledZ]={}),this.indexes[u.overscaledZ][u.key]=new Jt(u,p.symbolInstances,p.bucketInstanceId),!0}removeBucketCrossTileIDs(u,p){for(const _ of p.getCrossTileIDsLists())for(const M of _)delete this.usedCrossTileIDs[u][M]}removeStaleBuckets(u){let p=!1;for(const _ in this.indexes){const M=this.indexes[_];for(const I in M)u[M[I].bucketInstanceId]||(this.removeBucketCrossTileIDs(_,M[I]),delete M[I],p=!0)}return p}}class Cn{constructor(){this.layerIndexes={},this.crossTileIDs=new sn,this.maxBucketInstanceId=0,this.bucketsInCurrentPlacement={}}addLayer(u,p,_){let M=this.layerIndexes[u.id];M===void 0&&(M=this.layerIndexes[u.id]=new Ft);let I=!1;const z={};M.handleWrapJump(_);for(const W of p){const Q=W.getBucket(u);Q&&u.id===Q.layerIds[0]&&(Q.bucketInstanceId||(Q.bucketInstanceId=++this.maxBucketInstanceId),M.addBucket(W.tileID,Q,this.crossTileIDs)&&(I=!0),z[Q.bucketInstanceId]=!0)}return M.removeStaleBuckets(z)&&(I=!0),I}pruneUnusedLayers(u){const p={};u.forEach(_=>{p[_]=!0});for(const _ in this.layerIndexes)p[_]||delete this.layerIndexes[_]}}const ur=(O,u)=>a.t(O,u&&u.filter(p=>p.identifier!=="source.canvas")),fi=a.av();class ei extends a.E{constructor(u,p={}){super(),this._rtlTextPluginStateChange=()=>{for(const _ in this.sourceCaches){const M=this.sourceCaches[_].getSource().type;M!=="vector"&&M!=="geojson"||this.sourceCaches[_].reload()}},this.map=u,this.dispatcher=new fe(Me(),u._getMapId()),this.dispatcher.registerMessageHandler("getGlyphs",(_,M)=>this.getGlyphs(_,M)),this.dispatcher.registerMessageHandler("getImages",(_,M)=>this.getImages(_,M)),this.imageManager=new nt,this.imageManager.setEventedParent(this),this.glyphManager=new Yt(u._requestManager,p.localIdeographFontFamily),this.lineAtlas=new ot(256,512),this.crossTileSymbolIndex=new Cn,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()),H().on("pluginStateChange",this._rtlTextPluginStateChange),this.on("data",_=>{if(_.dataType!=="source"||_.sourceDataType!=="metadata")return;const M=this.sourceCaches[_.sourceId];if(!M)return;const I=M.getSource();if(I&&I.vectorLayerIds)for(const z in this._layers){const W=this._layers[z];W.source===I.id&&this._validateLayer(W)}})}loadURL(u,p={},_){this.fire(new a.k("dataloading",{dataType:"style"})),p.validate=typeof p.validate!="boolean"||p.validate;const M=this.map._requestManager.transformRequest(u,ce.Style);this._loadStyleRequest=new AbortController,a.h(M,this._loadStyleRequest).then(I=>{this._loadStyleRequest=null,this._load(I.data,p,_)}).catch(I=>{this._loadStyleRequest=null,I&&this.fire(new a.j(I))})}loadJSON(u,p={},_){this.fire(new a.k("dataloading",{dataType:"style"})),this._frameRequest=new AbortController,B.frameAsync(this._frameRequest).then(()=>{this._frameRequest=null,p.validate=p.validate!==!1,this._load(u,p,_)}).catch(()=>{})}loadEmpty(){this.fire(new a.k("dataloading",{dataType:"style"})),this._load(fi,{validate:!1})}_load(u,p,_){var M;const I=p.transformStyle?p.transformStyle(_,u):u;if(!p.validate||!ur(this,a.x(I))){this._loaded=!0,this.stylesheet=I;for(const z in I.sources)this.addSource(z,I.sources[z],{validate:!1});I.sprite?this._loadSprite(I.sprite):this.imageManager.setLoaded(!0),this.glyphManager.setURL(I.glyphs),this._createLayers(),this.light=new rt(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 _=a.az(p);_.setEventedParent(this,{layer:{id:p.id}}),this._layers[p.id]=_}}_loadSprite(u,p=!1,_=void 0){let M;this.imageManager.setLoaded(!1),this._spriteRequest=new AbortController,function(I,z,W,Q){return a._(this,void 0,void 0,function*(){const re=De(I),ue=W>1?"@2x":"",pe={},Ie={};for(const{id:Ne,url:Re}of re){const $e=z.transformRequest(z.normalizeSpriteURL(Re,ue,".json"),ce.SpriteJSON);pe[Ne]=a.h($e,Q);const Ge=z.transformRequest(z.normalizeSpriteURL(Re,ue,".png"),ce.SpriteImage);Ie[Ne]=oe.getImage(Ge,Q)}return yield Promise.all([...Object.values(pe),...Object.values(Ie)]),function(Ne,Re){return a._(this,void 0,void 0,function*(){const $e={};for(const Ge in Ne){$e[Ge]={};const ht=B.getImageCanvasContext((yield Re[Ge]).data),Tt=(yield Ne[Ge]).data;for(const Ze in Tt){const{width:Ct,height:$t,x:Dt,y:tn,sdf:dn,pixelRatio:An,stretchX:bn,stretchY:tr,content:Pr}=Tt[Ze];$e[Ge][Ze]={data:null,pixelRatio:An,sdf:dn,stretchX:bn,stretchY:tr,content:Pr,spriteData:{width:Ct,height:$t,x:Dt,y:tn,context:ht}}}}return $e})}(pe,Ie)})}(u,this.map._requestManager,this.map.getPixelRatio(),this._spriteRequest).then(I=>{if(this._spriteRequest=null,I)for(const z in I){this._spritesImagesIds[z]=[];const W=this._spritesImagesIds[z]?this._spritesImagesIds[z].filter(Q=>!(Q in I)):[];for(const Q of W)this.imageManager.removeImage(Q),this._changedImages[Q]=!0;for(const Q in I[z]){const re=z==="default"?Q:`${z}:${Q}`;this._spritesImagesIds[z].push(re),re in this.imageManager.images?this.imageManager.updateImage(re,I[z][Q],!1):this.imageManager.addImage(re,I[z][Q]),p&&(this._changedImages[re]=!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"})),_&&_(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 _=u.sourceLayer;if(!_)return;const M=p.getSource();(M.type==="geojson"||M.vectorLayerIds&&M.vectorLayerIds.indexOf(_)===-1)&&this.fire(new a.j(new Error(`Source layer "${_}" 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 _=[];for(const M of u)p[M]&&_.push(p[M]);return _}_serializedAllLayers(){let u=this._serializedLayers;if(u)return u;u=this._serializedLayers={};const p=Object.keys(this._layers);for(const _ of p){const M=this._layers[_];M.type!=="custom"&&(u[_]=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 z in this._updatedSources){const W=this._updatedSources[z];if(W==="reload")this._reloadSource(z);else{if(W!=="clear")throw new Error(`Invalid action ${W}`);this._clearSource(z)}}this._updateTilesForChangedImages(),this._updateTilesForChangedGlyphs();for(const z in this._updatedPaintProps)this._layers[z].updateTransitions(u);this.light.updateTransitions(u),this._resetUpdates()}const _={};for(const M in this.sourceCaches){const I=this.sourceCaches[M];_[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 _){const I=this.sourceCaches[M];_[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 _=this.serialize();if(u=p.transformStyle?p.transformStyle(_,u):u,ur(this,a.x(u)))return!1;(u=a.aA(u)).layers=a.ay(u.layers);const M=a.aB(_,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 z of I.operations)z();return this.stylesheet=u,this._serializedLayers=null,!0}_getOperationsToPerform(u){const p=[],_=[];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:_.push(M.command)}return{operations:p,unimplemented:_}}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,_={}){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,_))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 _ in this._layers)if(this._layers[_].source===u)return this.fire(new a.j(new Error(`Source "${u}" cannot be removed while layer "${_}" 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 _=this.sourceCaches[u].getSource();if(_.type!=="geojson")throw new Error(`geojsonSource.type is ${_.type}, which is !== 'geojson`);_.setData(p),this._changed=!0}getSource(u){return this.sourceCaches[u]&&this.sourceCaches[u].getSource()}addLayer(u,p,_={}){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(ur(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},_))return;I=a.az(u),this._validateLayer(I),I.setEventedParent(this,{layer:{id:M}})}const z=p?this._order.indexOf(p):this._order.length;if(p&&z===-1)this.fire(new a.j(new Error(`Cannot add layer "${M}" before non-existing layer "${p}".`)));else{if(this._order.splice(z,0,M),this._layerOrderChanged=!0,this._layers[M]=I,this._removedLayers[M]&&I.source&&I.type!=="custom"){const W=this._removedLayers[M];delete this._removedLayers[M],W.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 _=this._order.indexOf(u);this._order.splice(_,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 _=this._order.indexOf(u);this._order.splice(_,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,_){this._checkLoaded();const M=this.getLayer(u);M?M.minzoom===p&&M.maxzoom===_||(p!=null&&(M.minzoom=p),_!=null&&(M.maxzoom=_),this._updateLayer(M)):this.fire(new a.j(new Error(`Cannot set the zoom range of non-existing layer "${u}".`)))}setFilter(u,p,_={}){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,_)||(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,_,M={}){this._checkLoaded();const I=this.getLayer(u);I?a.aD(I.getLayoutProperty(p),_)||(I.setLayoutProperty(p,_,M),this._updateLayer(I)):this.fire(new a.j(new Error(`Cannot style non-existing layer "${u}".`)))}getLayoutProperty(u,p){const _=this.getLayer(u);if(_)return _.getLayoutProperty(p);this.fire(new a.j(new Error(`Cannot get style of non-existing layer "${u}".`)))}setPaintProperty(u,p,_,M={}){this._checkLoaded();const I=this.getLayer(u);I?a.aD(I.getPaintProperty(p),_)||(I.setPaintProperty(p,_,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 _=u.source,M=u.sourceLayer,I=this.sourceCaches[_];if(I===void 0)return void this.fire(new a.j(new Error(`The source '${_}' does not exist in the map's style.`)));const z=I.getSource().type;z==="geojson"&&M?this.fire(new a.j(new Error("GeoJSON sources cannot have a sourceLayer parameter."))):z!=="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 _=u.source,M=this.sourceCaches[_];if(M===void 0)return void this.fire(new a.j(new Error(`The source '${_}' does not exist in the map's style.`)));const I=M.getSource().type,z=I==="vector"?u.sourceLayer:void 0;I!=="vector"||z?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(z,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,_=u.sourceLayer,M=this.sourceCaches[p];if(M!==void 0)return M.getSource().type!=="vector"||_?(u.id===void 0&&this.fire(new a.j(new Error("The feature id parameter must be provided."))),M.getFeatureState(_,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),_=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:_},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=z=>this._layers[z].type==="fill-extrusion",_={},M=[];for(let z=this._order.length-1;z>=0;z--){const W=this._order[z];if(p(W)){_[W]=z;for(const Q of u){const re=Q[W];if(re)for(const ue of re)M.push(ue)}}}M.sort((z,W)=>W.intersectionZ-z.intersectionZ);const I=[];for(let z=this._order.length-1;z>=0;z--){const W=this._order[z];if(p(W))for(let Q=M.length-1;Q>=0;Q--){const re=M[Q].feature;if(_[re.layer.id]<z)break;I.push(re),M.pop()}else for(const Q of u){const re=Q[W];if(re)for(const ue of re)I.push(ue.feature)}}return I}queryRenderedFeatures(u,p,_){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 W of p.layers){const Q=this._layers[W];if(!Q)return this.fire(new a.j(new Error(`The layer '${W}' does not exist in the map's style and cannot be queried for features.`))),[];M[Q.source]=!0}}const I=[];p.availableImages=this._availableImages;const z=this._serializedAllLayers();for(const W in this.sourceCaches)p.layers&&!M[W]||I.push(et(this.sourceCaches[W],this._layers,z,u,p,_));return this.placement&&I.push(function(W,Q,re,ue,pe,Ie,Ne){const Re={},$e=Ie.queryRenderedSymbols(ue),Ge=[];for(const ht of Object.keys($e).map(Number))Ge.push(Ne[ht]);Ge.sort(it);for(const ht of Ge){const Tt=ht.featureIndex.lookupSymbolFeatures($e[ht.bucketInstanceId],Q,ht.bucketIndex,ht.sourceLayerIndex,pe.filter,pe.layers,pe.availableImages,W);for(const Ze in Tt){const Ct=Re[Ze]=Re[Ze]||[],$t=Tt[Ze];$t.sort((Dt,tn)=>{const dn=ht.featureSortOrder;if(dn){const An=dn.indexOf(Dt.featureIndex);return dn.indexOf(tn.featureIndex)-An}return tn.featureIndex-Dt.featureIndex});for(const Dt of $t)Ct.push(Dt)}}for(const ht in Re)Re[ht].forEach(Tt=>{const Ze=Tt.feature,Ct=re[W[ht].source].getFeatureState(Ze.layer["source-layer"],Ze.id);Ze.source=Ze.layer.source,Ze.layer["source-layer"]&&(Ze.sourceLayer=Ze.layer["source-layer"]),Ze.state=Ct});return Re}(this._layers,z,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 _=this.sourceCaches[u];return _?function(M,I){const z=M.getRenderableIds().map(re=>M.getTileByID(re)),W=[],Q={};for(let re=0;re<z.length;re++){const ue=z[re],pe=ue.tileID.canonical.key;Q[pe]||(Q[pe]=!0,ue.querySourceFeatures(W,I))}return W}(_,p):[]}getLight(){return this.light.getLight()}setLight(u,p={}){this._checkLoaded();const _=this.light.getLight();let M=!1;for(const z in u)if(!a.aD(u[z],_[z])){M=!0;break}if(!M)return;const I={now:B.now(),transition:a.e({duration:300,delay:0},this.stylesheet.transition)};this.light.setLight(u,p),this.light.updateTransitions(I)}_validate(u,p,_,M,I={}){return(!I||I.validate!==!1)&&ur(this,u.call(a.x,a.e({key:p,style:this.serialize(),value:_,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),H().off("pluginStateChange",this._rtlTextPluginStateChange);for(const p in this._layers)this._layers[p].setEventedParent(null);for(const p in this.sourceCaches){const _=this.sourceCaches[p];_.setEventedParent(null),_.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,_,M,I=!1){let z=!1,W=!1;const Q={};for(const re of this._order){const ue=this._layers[re];if(ue.type!=="symbol")continue;if(!Q[ue.source]){const Ie=this.sourceCaches[ue.source];Q[ue.source]=Ie.getRenderableIds(!0).map(Ne=>Ie.getTileByID(Ne)).sort((Ne,Re)=>Re.tileID.overscaledZ-Ne.tileID.overscaledZ||(Ne.tileID.isLessThan(Re.tileID)?-1:1))}const pe=this.crossTileSymbolIndex.addLayer(ue,Q[ue.source],u.center.lng);z=z||pe}if(this.crossTileSymbolIndex.pruneUnusedLayers(this._order),((I=I||this._layerOrderChanged||_===0)||!this.pauseablePlacement||this.pauseablePlacement.isDone()&&!this.placement.stillRecent(B.now(),u.zoom))&&(this.pauseablePlacement=new ve(u,this.map.terrain,this._order,I,p,_,M,this.placement),this._layerOrderChanged=!1),this.pauseablePlacement.isDone()?this.placement.setStale():(this.pauseablePlacement.continuePlacement(this._order,this._layers,Q),this.pauseablePlacement.isDone()&&(this.placement=this.pauseablePlacement.commit(B.now()),W=!0),z&&this.pauseablePlacement.placement.setStale()),W||z)for(const re of this._order){const ue=this._layers[re];ue.type==="symbol"&&this.placement.updateLayerOpacities(ue,Q[ue.source])}return!this.pauseablePlacement.isDone()||this.placement.hasTransitions(B.now())}_releaseSymbolFadeTiles(){for(const u in this.sourceCaches)this.sourceCaches[u].releaseSymbolFadeTiles()}getImages(u,p){return a._(this,void 0,void 0,function*(){const _=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),_})}getGlyphs(u,p){return a._(this,void 0,void 0,function*(){const _=yield this.glyphManager.getGlyphs(p.stacks),M=this.sourceCaches[p.source];return M&&M.setDependencies(p.tileID.key,p.type,[""]),_})}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,_={},M){this._checkLoaded();const I=[{id:u,url:p}],z=[...De(this.stylesheet.sprite),...I];this._validate(a.x.sprite,"sprite",z,null,_)||(this.stylesheet.sprite=z,this._loadSprite(I,!0,M))}removeSprite(u){this._checkLoaded();const p=De(this.stylesheet.sprite);if(p.find(_=>_.id===u)){if(this._spritesImagesIds[u])for(const _ of this._spritesImagesIds[u])this.imageManager.removeImage(_),this._changedImages[_]=!0;p.splice(p.findIndex(_=>_.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 De(this.stylesheet.sprite)}setSprite(u,p={},_){this._checkLoaded(),u&&this._validate(a.x.sprite,"sprite",u,null,p)||(this.stylesheet.sprite=u,u?this._loadSprite(u,!0,_):(this._unloadSprite(),_&&_(null)))}}var Zo=a.X([{name:"a_pos",type:"Int16",components:2}]),Fa="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 Or={prelude:gi(`#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:gi(`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:gi(`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:gi(`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:gi("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:gi(`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:gi(`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:gi("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:gi("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:gi("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:gi(`#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:gi(`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:gi(`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:gi(`#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:gi(`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:gi(`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:gi(`#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:gi(`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:gi(`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:gi(`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:gi(`#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:gi(`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:gi(`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:gi(`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:gi(`#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:gi(`#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:gi("uniform sampler2D u_texture;varying vec2 v_texture_pos;void main() {gl_FragColor=texture2D(u_texture,v_texture_pos);}",Fa),terrainDepth:gi("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);}",Fa),terrainCoords:gi("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);}",Fa)};function gi(O,u){const p=/#pragma mapbox: ([\w]+) ([\w]+) ([\w]+) ([\w]+)/g,_=u.match(/attribute ([\w]+) ([\w]+)/g),M=O.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),I=u.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),z=I?I.concat(M):M,W={};return{fragmentSource:O=O.replace(p,(Q,re,ue,pe,Ie)=>(W[Ie]=!0,re==="define"?`
#ifndef HAS_UNIFORM_u_${Ie}
varying ${ue} ${pe} ${Ie};
#else
uniform ${ue} ${pe} u_${Ie};
#endif
`:`
#ifdef HAS_UNIFORM_u_${Ie}
${ue} ${pe} ${Ie} = u_${Ie};
#endif
`)),vertexSource:u=u.replace(p,(Q,re,ue,pe,Ie)=>{const Ne=pe==="float"?"vec2":"vec4",Re=Ie.match(/color/)?"color":Ne;return W[Ie]?re==="define"?`
#ifndef HAS_UNIFORM_u_${Ie}
uniform lowp float u_${Ie}_t;
attribute ${ue} ${Ne} a_${Ie};
varying ${ue} ${pe} ${Ie};
#else
uniform ${ue} ${pe} u_${Ie};
#endif
`:Re==="vec4"?`
#ifndef HAS_UNIFORM_u_${Ie}
${Ie} = a_${Ie};
#else
${ue} ${pe} ${Ie} = u_${Ie};
#endif
`:`
#ifndef HAS_UNIFORM_u_${Ie}
${Ie} = unpack_mix_${Re}(a_${Ie}, u_${Ie}_t);
#else
${ue} ${pe} ${Ie} = u_${Ie};
#endif
`:re==="define"?`
#ifndef HAS_UNIFORM_u_${Ie}
uniform lowp float u_${Ie}_t;
attribute ${ue} ${Ne} a_${Ie};
#else
uniform ${ue} ${pe} u_${Ie};
#endif
`:Re==="vec4"?`
#ifndef HAS_UNIFORM_u_${Ie}
${ue} ${pe} ${Ie} = a_${Ie};
#else
${ue} ${pe} ${Ie} = u_${Ie};
#endif
`:`
#ifndef HAS_UNIFORM_u_${Ie}
${ue} ${pe} ${Ie} = unpack_mix_${Re}(a_${Ie}, u_${Ie}_t);
#else
${ue} ${pe} ${Ie} = u_${Ie};
#endif
`}),staticAttributes:_,staticUniforms:z}}class Ks{constructor(){this.boundProgram=null,this.boundLayoutVertexBuffer=null,this.boundPaintVertexBuffers=[],this.boundIndexBuffer=null,this.boundVertexOffset=null,this.boundDynamicVertexBuffer=null,this.vao=null}bind(u,p,_,M,I,z,W,Q,re){this.context=u;let ue=this.boundPaintVertexBuffers.length!==M.length;for(let pe=0;!ue&&pe<M.length;pe++)this.boundPaintVertexBuffers[pe]!==M[pe]&&(ue=!0);!this.vao||this.boundProgram!==p||this.boundLayoutVertexBuffer!==_||ue||this.boundIndexBuffer!==I||this.boundVertexOffset!==z||this.boundDynamicVertexBuffer!==W||this.boundDynamicVertexBuffer2!==Q||this.boundDynamicVertexBuffer3!==re?this.freshBind(p,_,M,I,z,W,Q,re):(u.bindVertexArray.set(this.vao),W&&W.bind(),I&&I.dynamicDraw&&I.bind(),Q&&Q.bind(),re&&re.bind())}freshBind(u,p,_,M,I,z,W,Q){const re=u.numAttributes,ue=this.context,pe=ue.gl;this.vao&&this.destroy(),this.vao=ue.createVertexArray(),ue.bindVertexArray.set(this.vao),this.boundProgram=u,this.boundLayoutVertexBuffer=p,this.boundPaintVertexBuffers=_,this.boundIndexBuffer=M,this.boundVertexOffset=I,this.boundDynamicVertexBuffer=z,this.boundDynamicVertexBuffer2=W,this.boundDynamicVertexBuffer3=Q,p.enableAttributes(pe,u);for(const Ie of _)Ie.enableAttributes(pe,u);z&&z.enableAttributes(pe,u),W&&W.enableAttributes(pe,u),Q&&Q.enableAttributes(pe,u),p.bind(),p.setVertexAttribPointers(pe,u,I);for(const Ie of _)Ie.bind(),Ie.setVertexAttribPointers(pe,u,I);z&&(z.bind(),z.setVertexAttribPointers(pe,u,I)),M&&M.bind(),W&&(W.bind(),W.setVertexAttribPointers(pe,u,I)),Q&&(Q.bind(),Q.setVertexAttribPointers(pe,u,I)),ue.currentNumAttributes=re}destroy(){this.vao&&(this.context.deleteVertexArray(this.vao),this.vao=null)}}function ka(O){const u=[];for(let p=0;p<O.length;p++){if(O[p]===null)continue;const _=O[p].split(" ");u.push(_.pop())}return u}class pa{constructor(u,p,_,M,I,z){const W=u.gl;this.program=W.createProgram();const Q=ka(p.staticAttributes),re=_?_.getBinderAttributes():[],ue=Q.concat(re),pe=Or.prelude.staticUniforms?ka(Or.prelude.staticUniforms):[],Ie=p.staticUniforms?ka(p.staticUniforms):[],Ne=_?_.getBinderUniforms():[],Re=pe.concat(Ie).concat(Ne),$e=[];for(const Dt of Re)$e.indexOf(Dt)<0&&$e.push(Dt);const Ge=_?_.defines():[];I&&Ge.push("#define OVERDRAW_INSPECTOR;"),z&&Ge.push("#define TERRAIN3D;");const ht=Ge.concat(Or.prelude.fragmentSource,p.fragmentSource).join(`
`),Tt=Ge.concat(Or.prelude.vertexSource,p.vertexSource).join(`
`),Ze=W.createShader(W.FRAGMENT_SHADER);if(W.isContextLost())return void(this.failedToCreate=!0);if(W.shaderSource(Ze,ht),W.compileShader(Ze),!W.getShaderParameter(Ze,W.COMPILE_STATUS))throw new Error(`Could not compile fragment shader: ${W.getShaderInfoLog(Ze)}`);W.attachShader(this.program,Ze);const Ct=W.createShader(W.VERTEX_SHADER);if(W.isContextLost())return void(this.failedToCreate=!0);if(W.shaderSource(Ct,Tt),W.compileShader(Ct),!W.getShaderParameter(Ct,W.COMPILE_STATUS))throw new Error(`Could not compile vertex shader: ${W.getShaderInfoLog(Ct)}`);W.attachShader(this.program,Ct),this.attributes={};const $t={};this.numAttributes=ue.length;for(let Dt=0;Dt<this.numAttributes;Dt++)ue[Dt]&&(W.bindAttribLocation(this.program,Dt,ue[Dt]),this.attributes[ue[Dt]]=Dt);if(W.linkProgram(this.program),!W.getProgramParameter(this.program,W.LINK_STATUS))throw new Error(`Program failed to link: ${W.getProgramInfoLog(this.program)}`);W.deleteShader(Ct),W.deleteShader(Ze);for(let Dt=0;Dt<$e.length;Dt++){const tn=$e[Dt];if(tn&&!$t[tn]){const dn=W.getUniformLocation(this.program,tn);dn&&($t[tn]=dn)}}this.fixedUniforms=M(u,$t),this.terrainUniforms=((Dt,tn)=>({u_depth:new a.aG(Dt,tn.u_depth),u_terrain:new a.aG(Dt,tn.u_terrain),u_terrain_dim:new a.aH(Dt,tn.u_terrain_dim),u_terrain_matrix:new a.aI(Dt,tn.u_terrain_matrix),u_terrain_unpack:new a.aJ(Dt,tn.u_terrain_unpack),u_terrain_exaggeration:new a.aH(Dt,tn.u_terrain_exaggeration)}))(u,$t),this.binderUniforms=_?_.getUniforms(u,$t):[]}draw(u,p,_,M,I,z,W,Q,re,ue,pe,Ie,Ne,Re,$e,Ge,ht,Tt){const Ze=u.gl;if(this.failedToCreate)return;if(u.program.set(this.program),u.setDepthMode(_),u.setStencilMode(M),u.setColorMode(I),u.setCullFace(z),Q){u.activeTexture.set(Ze.TEXTURE2),Ze.bindTexture(Ze.TEXTURE_2D,Q.depthTexture),u.activeTexture.set(Ze.TEXTURE3),Ze.bindTexture(Ze.TEXTURE_2D,Q.texture);for(const $t in this.terrainUniforms)this.terrainUniforms[$t].set(Q[$t])}for(const $t in this.fixedUniforms)this.fixedUniforms[$t].set(W[$t]);$e&&$e.setUniforms(u,this.binderUniforms,Ne,{zoom:Re});let Ct=0;switch(p){case Ze.LINES:Ct=2;break;case Ze.TRIANGLES:Ct=3;break;case Ze.LINE_STRIP:Ct=1}for(const $t of Ie.get()){const Dt=$t.vaos||($t.vaos={});(Dt[re]||(Dt[re]=new Ks)).bind(u,this,ue,$e?$e.getPaintVertexBuffers():[],pe,$t.vertexOffset,Ge,ht,Tt),Ze.drawElements(p,$t.primitiveLength*Ct,Ze.UNSIGNED_SHORT,$t.primitiveOffset*Ct*2)}}}function Zl(O,u,p){const _=1/ar(p,1,u.transform.tileZoom),M=Math.pow(2,p.tileID.overscaledZ),I=p.tileSize*Math.pow(2,u.transform.tileZoom)/M,z=I*(p.tileID.canonical.x+p.tileID.wrap*M),W=I*p.tileID.canonical.y;return{u_image:0,u_texsize:p.imageAtlasTexture.size,u_scale:[_,O.fromScale,O.toScale],u_fade:O.t,u_pixel_coord_upper:[z>>16,W>>16],u_pixel_coord_lower:[65535&z,65535&W]}}const as=(O,u,p,_)=>{const M=u.style.light,I=M.properties.get("position"),z=[I.x,I.y,I.z],W=function(){var re=new a.A(9);return a.A!=Float32Array&&(re[1]=0,re[2]=0,re[3]=0,re[5]=0,re[6]=0,re[7]=0),re[0]=1,re[4]=1,re[8]=1,re}();M.properties.get("anchor")==="viewport"&&function(re,ue){var pe=Math.sin(ue),Ie=Math.cos(ue);re[0]=Ie,re[1]=pe,re[2]=0,re[3]=-pe,re[4]=Ie,re[5]=0,re[6]=0,re[7]=0,re[8]=1}(W,-u.transform.angle),function(re,ue,pe){var Ie=ue[0],Ne=ue[1],Re=ue[2];re[0]=Ie*pe[0]+Ne*pe[3]+Re*pe[6],re[1]=Ie*pe[1]+Ne*pe[4]+Re*pe[7],re[2]=Ie*pe[2]+Ne*pe[5]+Re*pe[8]}(z,z,W);const Q=M.properties.get("color");return{u_matrix:O,u_lightpos:z,u_lightintensity:M.properties.get("intensity"),u_lightcolor:[Q.r,Q.g,Q.b],u_vertical_gradient:+p,u_opacity:_}},ia=(O,u,p,_,M,I,z)=>a.e(as(O,u,p,_),Zl(I,u,z),{u_height_factor:-Math.pow(2,M.overscaledZ)/z.tileSize/8}),qo=O=>({u_matrix:O}),vs=(O,u,p,_)=>a.e(qo(O),Zl(p,u,_)),Fu=(O,u)=>({u_matrix:O,u_world:u}),ma=(O,u,p,_,M)=>a.e(vs(O,u,p,_),{u_world:M}),lA=(O,u,p,_)=>{const M=O.transform;let I,z;if(_.paint.get("circle-pitch-alignment")==="map"){const W=ar(p,1,M.zoom);I=!0,z=[W,W]}else I=!1,z=M.pixelsToGLUnits;return{u_camera_to_center_distance:M.cameraToCenterDistance,u_scale_with_map:+(_.paint.get("circle-pitch-scale")==="map"),u_matrix:O.translatePosMatrix(u.posMatrix,p,_.paint.get("circle-translate"),_.paint.get("circle-translate-anchor")),u_pitch_with_map:+I,u_device_pixel_ratio:O.pixelRatio,u_extrude_scale:z}},Du=(O,u,p)=>{const _=ar(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:_,u_extrude_scale:[u.pixelsToGLUnits[0]/(_*M),u.pixelsToGLUnits[1]/(_*M)],u_overscale_factor:I}},Lu=(O,u,p=1)=>({u_matrix:O,u_color:u,u_overlay:0,u_overlay_scale:p}),mu=O=>({u_matrix:O}),uA=(O,u,p,_)=>({u_matrix:O,u_extrude_scale:ar(u,1,p),u_intensity:_});function Wo(O,u){const p=Math.pow(2,u.canonical.z),_=u.canonical.y;return[new a.Y(0,_/p).toLngLat().lat,new a.Y(0,(_+1)/p).toLngLat().lat]}const Na=(O,u,p,_)=>{const M=O.transform;return{u_matrix:gu(O,u,p,_),u_ratio:1/ar(u,1,M.zoom),u_device_pixel_ratio:O.pixelRatio,u_units_to_pixels:[1/M.pixelsToGLUnits[0],1/M.pixelsToGLUnits[1]]}},Uu=(O,u,p,_,M)=>a.e(Na(O,u,p,M),{u_image:0,u_image_height:_}),ss=(O,u,p,_,M)=>{const I=O.transform,z=Do(u,I);return{u_matrix:gu(O,u,p,M),u_texsize:u.imageAtlasTexture.size,u_ratio:1/ar(u,1,I.zoom),u_device_pixel_ratio:O.pixelRatio,u_image:0,u_scale:[z,_.fromScale,_.toScale],u_fade:_.t,u_units_to_pixels:[1/I.pixelsToGLUnits[0],1/I.pixelsToGLUnits[1]]}},ll=(O,u,p,_,M,I)=>{const z=O.lineAtlas,W=Do(u,O.transform),Q=p.layout.get("line-cap")==="round",re=z.getDash(_.from,Q),ue=z.getDash(_.to,Q),pe=re.width*M.fromScale,Ie=ue.width*M.toScale;return a.e(Na(O,u,p,I),{u_patternscale_a:[W/pe,-re.height/2],u_patternscale_b:[W/Ie,-ue.height/2],u_sdfgamma:z.width/(256*Math.min(pe,Ie)*O.pixelRatio)/2,u_image:0,u_tex_y_a:re.y,u_tex_y_b:ue.y,u_mix:M.t})};function Do(O,u){return 1/ar(O,1,u.tileZoom)}function gu(O,u,p,_){return O.translatePosMatrix(_?_.posMatrix:u.tileID.posMatrix,u,p.paint.get("line-translate"),p.paint.get("line-translate-anchor"))}const vl=(O,u,p,_,M)=>{return{u_matrix:O,u_tl_parent:u,u_scale_parent:p,u_buffer_scale:1,u_fade_t:_.mix,u_opacity:_.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:(z=M.paint.get("raster-saturation"),z>0?1-1/(1.001-z):-z),u_contrast_factor:(I=M.paint.get("raster-contrast"),I>0?1/(1-I):1+I),u_spin_weights:_l(M.paint.get("raster-hue-rotate"))};var I,z};function _l(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 Dl=(O,u,p,_,M,I,z,W,Q,re)=>{const ue=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:ue.cameraToCenterDistance,u_pitch:ue.pitch/360*2*Math.PI,u_rotate_symbol:+p,u_aspect_ratio:ue.width/ue.height,u_fade_change:M.options.fadeDuration?M.symbolFadeChange:1,u_matrix:I,u_label_plane_matrix:z,u_coord_matrix:W,u_is_text:+Q,u_pitch_with_map:+_,u_texsize:re,u_texture:0}},oa=(O,u,p,_,M,I,z,W,Q,re,ue)=>{const pe=M.transform;return a.e(Dl(O,u,p,_,M,I,z,W,Q,re),{u_gamma_scale:_?Math.cos(pe._pitch)*pe.cameraToCenterDistance:1,u_device_pixel_ratio:M.pixelRatio,u_is_halo:+ue})},Cl=(O,u,p,_,M,I,z,W,Q,re)=>a.e(oa(O,u,p,_,M,I,z,W,!0,Q,!0),{u_texsize_icon:re,u_texture_icon:1}),AA=(O,u,p)=>({u_matrix:O,u_opacity:u,u_color:p}),go=(O,u,p,_,M,I)=>a.e(function(z,W,Q,re){const ue=Q.imageManager.getPattern(z.from.toString()),pe=Q.imageManager.getPattern(z.to.toString()),{width:Ie,height:Ne}=Q.imageManager.getPixelSize(),Re=Math.pow(2,re.tileID.overscaledZ),$e=re.tileSize*Math.pow(2,Q.transform.tileZoom)/Re,Ge=$e*(re.tileID.canonical.x+re.tileID.wrap*Re),ht=$e*re.tileID.canonical.y;return{u_image:0,u_pattern_tl_a:ue.tl,u_pattern_br_a:ue.br,u_pattern_tl_b:pe.tl,u_pattern_br_b:pe.br,u_texsize:[Ie,Ne],u_mix:W.t,u_pattern_size_a:ue.displaySize,u_pattern_size_b:pe.displaySize,u_scale_a:W.fromScale,u_scale_b:W.toScale,u_tile_units_to_pixels:1/ar(re,1,Q.transform.tileZoom),u_pixel_coord_upper:[Ge>>16,ht>>16],u_pixel_coord_lower:[65535&Ge,65535&ht]}}(_,I,p,M),{u_matrix:O,u_opacity:u}),oo={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 R{constructor(u,p,_){this.context=u;const M=u.gl;this.buffer=M.createBuffer(),this.dynamicDraw=!!_,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 se={Int8:"BYTE",Uint8:"UNSIGNED_BYTE",Int16:"SHORT",Uint16:"UNSIGNED_SHORT",Int32:"INT",Uint32:"UNSIGNED_INT",Float32:"FLOAT"};class Le{constructor(u,p,_,M){this.length=p.length,this.attributes=_,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 _=0;_<this.attributes.length;_++){const M=p.attributes[this.attributes[_].name];M!==void 0&&u.enableVertexAttribArray(M)}}setVertexAttribPointers(u,p,_){for(let M=0;M<this.attributes.length;M++){const I=this.attributes[M],z=p.attributes[I.name];z!==void 0&&u.vertexAttribPointer(z,I.components,u[se[I.type]],!1,this.itemSize,I.offset+this.itemSize*(_||0))}}destroy(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)}}const mt=new WeakMap;function Dn(O){var u;if(mt.has(O))return mt.get(O);{const p=(u=O.getParameter(O.VERSION))===null||u===void 0?void 0:u.startsWith("WebGL 2.0");return mt.set(O,p),p}}class en{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 Sr extends en{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 Ur extends en{getDefault(){return 1}set(u){(u!==this.current||this.dirty)&&(this.gl.clearDepth(u),this.current=u,this.dirty=!1)}}class yr extends en{getDefault(){return 0}set(u){(u!==this.current||this.dirty)&&(this.gl.clearStencil(u),this.current=u,this.dirty=!1)}}class Ir extends en{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 Bi extends en{getDefault(){return!0}set(u){(u!==this.current||this.dirty)&&(this.gl.depthMask(u),this.current=u,this.dirty=!1)}}class fo extends en{getDefault(){return 255}set(u){(u!==this.current||this.dirty)&&(this.gl.stencilMask(u),this.current=u,this.dirty=!1)}}class xi extends en{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 Hr extends en{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 Hi extends en{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 Io extends en{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 wo extends en{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 Ga extends en{getDefault(){return this.gl.LESS}set(u){(u!==this.current||this.dirty)&&(this.gl.depthFunc(u),this.current=u,this.dirty=!1)}}class Ll extends en{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 Xl extends en{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 ga extends en{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 qm extends en{getDefault(){return this.gl.FUNC_ADD}set(u){(u!==this.current||this.dirty)&&(this.gl.blendEquation(u),this.current=u,this.dirty=!1)}}class Jl extends en{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 mh extends en{getDefault(){return this.gl.BACK}set(u){(u!==this.current||this.dirty)&&(this.gl.cullFace(u),this.current=u,this.dirty=!1)}}class Wc extends en{getDefault(){return this.gl.CCW}set(u){(u!==this.current||this.dirty)&&(this.gl.frontFace(u),this.current=u,this.dirty=!1)}}class Ru extends en{getDefault(){return null}set(u){(u!==this.current||this.dirty)&&(this.gl.useProgram(u),this.current=u,this.dirty=!1)}}class Nc extends en{getDefault(){return this.gl.TEXTURE0}set(u){(u!==this.current||this.dirty)&&(this.gl.activeTexture(u),this.current=u,this.dirty=!1)}}class IA extends en{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 Xo extends en{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 zu extends en{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 Od extends en{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 TA extends en{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 lc extends en{getDefault(){return null}set(u){const p=this.gl;p.bindBuffer(p.ELEMENT_ARRAY_BUFFER,u),this.current=u,this.dirty=!1}}class yu extends en{getDefault(){return null}set(u){var p;if(u===this.current&&!this.dirty)return;const _=this.gl;Dn(_)?_.bindVertexArray(u):(p=_.getExtension("OES_vertex_array_object"))===null||p===void 0||p.bindVertexArrayOES(u),this.current=u,this.dirty=!1}}class Gc extends en{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 kp extends en{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 gh extends en{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 wi extends en{constructor(u,p){super(u),this.context=u,this.parent=p}getDefault(){return null}}class No extends wi{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 Hm extends wi{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 yh extends wi{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 ju{constructor(u,p,_,M,I){this.context=u,this.width=p,this.height=_;const z=u.gl,W=this.framebuffer=z.createFramebuffer();if(this.colorAttachment=new No(u,W),M)this.depthAttachment=I?new yh(u,W):new Hm(u,W);else if(I)throw new Error("Stencil cannot be set without depth");if(z.checkFramebufferStatus(z.FRAMEBUFFER)!==z.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 _=this.depthAttachment.get();_&&u.deleteRenderbuffer(_)}u.deleteFramebuffer(this.framebuffer)}}class ya{constructor(u,p,_){this.blendFunction=u,this.blendColor=p,this.mask=_}}ya.Replace=[1,0],ya.disabled=new ya(ya.Replace,a.aO.transparent,[!1,!1,!1,!1]),ya.unblended=new ya(ya.Replace,a.aO.transparent,[!0,!0,!0,!0]),ya.alphaBlended=new ya([1,771],a.aO.transparent,[!0,!0,!0,!0]);class vh{constructor(u){var p,_;if(this.gl=u,this.clearColor=new Sr(this),this.clearDepth=new Ur(this),this.clearStencil=new yr(this),this.colorMask=new Ir(this),this.depthMask=new Bi(this),this.stencilMask=new fo(this),this.stencilFunc=new xi(this),this.stencilOp=new Hr(this),this.stencilTest=new Hi(this),this.depthRange=new Io(this),this.depthTest=new wo(this),this.depthFunc=new Ga(this),this.blend=new Ll(this),this.blendFunc=new Xl(this),this.blendColor=new ga(this),this.blendEquation=new qm(this),this.cullFace=new Jl(this),this.cullFaceSide=new mh(this),this.frontFace=new Wc(this),this.program=new Ru(this),this.activeTexture=new Nc(this),this.viewport=new IA(this),this.bindFramebuffer=new Xo(this),this.bindRenderbuffer=new zu(this),this.bindTexture=new Od(this),this.bindVertexBuffer=new TA(this),this.bindElementBuffer=new lc(this),this.bindVertexArray=new yu(this),this.pixelStoreUnpack=new Gc(this),this.pixelStoreUnpackPremultiplyAlpha=new kp(this),this.pixelStoreUnpackFlipY=new gh(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),Dn(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=(_=u.RGB16F)!==null&&_!==void 0?_: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 R(this,u,p)}createVertexBuffer(u,p,_){return new Le(this,u,p,_)}createRenderbuffer(u,p,_){const M=this.gl,I=M.createRenderbuffer();return this.bindRenderbuffer.set(I),M.renderbufferStorage(M.RENDERBUFFER,u,p,_),this.bindRenderbuffer.set(null),I}createFramebuffer(u,p,_,M){return new ju(this,u,p,_,M)}clear({color:u,depth:p,stencil:_}){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)),_!==void 0&&(I|=M.STENCIL_BUFFER_BIT,this.clearStencil.set(_),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,ya.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 Dn(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 Dn(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 Li{constructor(u,p,_){this.func=u,this.mask=p,this.range=_}}Li.ReadOnly=!1,Li.ReadWrite=!0,Li.disabled=new Li(519,Li.ReadOnly,[0,1]);const Bd=7680;class To{constructor(u,p,_,M,I,z){this.test=u,this.ref=p,this.mask=_,this.fail=M,this.depthFail=I,this.pass=z}}To.disabled=new To({func:519,mask:0},0,0,Bd,Bd,Bd);class Mo{constructor(u,p,_){this.enable=u,this.mode=p,this.frontFace=_}}let uc;function Qc(O,u,p,_,M,I,z){const W=O.context,Q=W.gl,re=O.useProgram("collisionBox"),ue=[];let pe=0,Ie=0;for(let Ze=0;Ze<_.length;Ze++){const Ct=_[Ze],$t=u.getTile(Ct),Dt=$t.getBucket(p);if(!Dt)continue;let tn=Ct.posMatrix;M[0]===0&&M[1]===0||(tn=O.translatePosMatrix(Ct.posMatrix,$t,M,I));const dn=z?Dt.textCollisionBox:Dt.iconCollisionBox,An=Dt.collisionCircleArray;if(An.length>0){const bn=a.F(),tr=tn;a.aP(bn,Dt.placementInvProjMatrix,O.transform.glCoordMatrix),a.aP(bn,bn,Dt.placementViewportMatrix),ue.push({circleArray:An,circleOffset:Ie,transform:tr,invTransform:bn,coord:Ct}),pe+=An.length/4,Ie=pe}dn&&re.draw(W,Q.LINES,Li.disabled,To.disabled,O.colorModeForRenderPass(),Mo.disabled,Du(tn,O.transform,$t),O.style.map.terrain&&O.style.map.terrain.getTerrainData(Ct),p.id,dn.layoutVertexBuffer,dn.indexBuffer,dn.segments,null,O.transform.zoom,null,null,dn.collisionVertexBuffer)}if(!z||!ue.length)return;const Ne=O.useProgram("collisionCircle"),Re=new a.aQ;Re.resize(4*pe),Re._trim();let $e=0;for(const Ze of ue)for(let Ct=0;Ct<Ze.circleArray.length/4;Ct++){const $t=4*Ct,Dt=Ze.circleArray[$t+0],tn=Ze.circleArray[$t+1],dn=Ze.circleArray[$t+2],An=Ze.circleArray[$t+3];Re.emplace($e++,Dt,tn,dn,An,0),Re.emplace($e++,Dt,tn,dn,An,1),Re.emplace($e++,Dt,tn,dn,An,2),Re.emplace($e++,Dt,tn,dn,An,3)}(!uc||uc.length<2*pe)&&(uc=function(Ze){const Ct=2*Ze,$t=new a.aS;$t.resize(Ct),$t._trim();for(let Dt=0;Dt<Ct;Dt++){const tn=6*Dt;$t.uint16[tn+0]=4*Dt+0,$t.uint16[tn+1]=4*Dt+1,$t.uint16[tn+2]=4*Dt+2,$t.uint16[tn+3]=4*Dt+2,$t.uint16[tn+4]=4*Dt+3,$t.uint16[tn+5]=4*Dt+0}return $t}(pe));const Ge=W.createIndexBuffer(uc,!0),ht=W.createVertexBuffer(Re,a.aR.members,!0);for(const Ze of ue){const Ct={u_matrix:Ze.transform,u_inv_matrix:Ze.invTransform,u_camera_to_center_distance:(Tt=O.transform).cameraToCenterDistance,u_viewport_size:[Tt.width,Tt.height]};Ne.draw(W,Q.TRIANGLES,Li.disabled,To.disabled,O.colorModeForRenderPass(),Mo.disabled,Ct,O.style.map.terrain&&O.style.map.terrain.getTerrainData(Ze.coord),p.id,ht,Ge,a.$.simpleSegment(0,2*Ze.circleOffset,Ze.circleArray.length,Ze.circleArray.length/2),null,O.transform.zoom,null,null,null)}var Tt;ht.destroy(),Ge.destroy()}Mo.disabled=new Mo(!1,1029,2305),Mo.backCCW=new Mo(!0,1029,2305);const Hs=a.an(new Float32Array(16));function _h(O,u,p,_,M,I){const{horizontalAlign:z,verticalAlign:W}=a.at(O);return new a.P((-(z-.5)*u/M+_[0])*I,(-(W-.5)*p/M+_[1])*I)}function eu(O,u,p,_,M,I,z,W,Q,re,ue){const pe=O.text.placedSymbolArray,Ie=O.text.dynamicLayoutVertexArray,Ne=O.icon.dynamicLayoutVertexArray,Re={};Ie.clear();for(let $e=0;$e<pe.length;$e++){const Ge=pe.get($e),ht=Ge.hidden||!Ge.crossTileID||O.allowVerticalPlacement&&!Ge.placedOrientation?null:_[Ge.crossTileID];if(ht){const Tt=new a.P(Ge.anchorX,Ge.anchorY),Ze=Fn(Tt,p?z:I,ue),Ct=Fe(M.cameraToCenterDistance,Ze.signedDistanceFromCamera);let $t=a.ai(O.textSizeData,Q,Ge)*Ct/a.ao;p&&($t*=O.tilePixelRatio/W);const{width:Dt,height:tn,anchor:dn,textOffset:An,textBoxScale:bn}=ht,tr=_h(dn,Dt,tn,An,bn,$t),Pr=p?Fn(Tt.add(tr),I,ue).point:Ze.point.add(u?tr.rotate(-M.angle):tr),Tn=O.allowVerticalPlacement&&Ge.placedOrientation===a.ah.vertical?Math.PI/2:0;for(let xr=0;xr<Ge.numGlyphs;xr++)a.aj(Ie,Pr,Tn);re&&Ge.associatedIconIndex>=0&&(Re[Ge.associatedIconIndex]={shiftedAnchor:Pr,angle:Tn})}else Ht(Ge.numGlyphs,Ie)}if(re){Ne.clear();const $e=O.icon.placedSymbolArray;for(let Ge=0;Ge<$e.length;Ge++){const ht=$e.get(Ge);if(ht.hidden)Ht(ht.numGlyphs,Ne);else{const Tt=Re[Ge];if(Tt)for(let Ze=0;Ze<ht.numGlyphs;Ze++)a.aj(Ne,Tt.shiftedAnchor,Tt.angle);else Ht(ht.numGlyphs,Ne)}}O.icon.dynamicLayoutVertexBuffer.updateData(Ne)}O.text.dynamicLayoutVertexBuffer.updateData(Ie)}function Ul(O,u,p){return p.iconsInText&&u?"symbolTextAndIcon":O?"symbolSDF":"symbolIcon"}function KA(O,u,p,_,M,I,z,W,Q,re,ue,pe){const Ie=O.context,Ne=Ie.gl,Re=O.transform,$e=W==="map",Ge=Q==="map",ht=W!=="viewport"&&p.layout.get("symbol-placement")!=="point",Tt=$e&&!Ge&&!ht,Ze=!p.layout.get("symbol-sort-key").isConstant();let Ct=!1;const $t=O.depthModeForSublayer(0,Li.ReadOnly),Dt=p._unevaluatedLayout.hasValue("text-variable-anchor")||p._unevaluatedLayout.hasValue("text-variable-anchor-offset"),tn=[];for(const dn of _){const An=u.getTile(dn),bn=An.getBucket(p);if(!bn)continue;const tr=M?bn.text:bn.icon;if(!tr||!tr.segments.get().length||!tr.hasVisibleVertices)continue;const Pr=tr.programConfigurations.get(p.id),Tn=M||bn.sdfIcons,xr=M?bn.textSizeData:bn.iconSizeData,Jn=Ge||Re.pitch!==0,Ni=O.useProgram(Ul(Tn,M,bn),Pr),ki=a.ag(xr,Re.zoom),ri=O.style.map.terrain&&O.style.map.terrain.getTerrainData(dn);let Mi,ea,Ui,Ds,bs=[0,0],Ho=null;if(M)ea=An.glyphAtlasTexture,Ui=Ne.LINEAR,Mi=An.glyphAtlasTexture.size,bn.iconsInText&&(bs=An.imageAtlasTexture.size,Ho=An.imageAtlasTexture,Ds=Jn||O.options.rotating||O.options.zooming||xr.kind==="composite"||xr.kind==="camera"?Ne.LINEAR:Ne.NEAREST);else{const Ko=p.layout.get("icon-size").constantOr(0)!==1||bn.iconsNeedLinear;ea=An.imageAtlasTexture,Ui=Tn||O.options.rotating||O.options.zooming||Ko||Jn?Ne.LINEAR:Ne.NEAREST,Mi=An.imageAtlasTexture.size}const Ls=ar(An,1,O.transform.zoom),Ta=Kt(dn.posMatrix,Ge,$e,O.transform,Ls),Eo=Dr(dn.posMatrix,Ge,$e,O.transform,Ls),jl=Dt&&bn.hasTextData(),zA=p.layout.get("icon-text-fit")!=="none"&&jl&&bn.hasIconData();if(ht){const Ko=O.style.map.terrain?(ls,Aa)=>O.style.map.terrain.getElevation(dn,ls,Aa):null,$a=p.layout.get("text-rotation-alignment")==="map";Ce(bn,dn.posMatrix,O,M,Ta,Eo,Ge,re,$a,Ko)}const Us=O.translatePosMatrix(dn.posMatrix,An,I,z),Mu=ht||M&&Dt||zA?Hs:Ta,Ka=O.translatePosMatrix(Eo,An,I,z,!0),Lo=Tn&&p.paint.get(M?"text-halo-width":"icon-halo-width").constantOr(1)!==0;let Pi;Pi=Tn?bn.iconsInText?Cl(xr.kind,ki,Tt,Ge,O,Us,Mu,Ka,Mi,bs):oa(xr.kind,ki,Tt,Ge,O,Us,Mu,Ka,M,Mi,!0):Dl(xr.kind,ki,Tt,Ge,O,Us,Mu,Ka,M,Mi);const vo={program:Ni,buffers:tr,uniformValues:Pi,atlasTexture:ea,atlasTextureIcon:Ho,atlasInterpolation:Ui,atlasInterpolationIcon:Ds,isSDF:Tn,hasHalo:Lo};if(Ze&&bn.canOverlap){Ct=!0;const Ko=tr.segments.get();for(const $a of Ko)tn.push({segments:new a.$([$a]),sortKey:$a.sortKey,state:vo,terrainData:ri})}else tn.push({segments:tr.segments,sortKey:0,state:vo,terrainData:ri})}Ct&&tn.sort((dn,An)=>dn.sortKey-An.sortKey);for(const dn of tn){const An=dn.state;if(Ie.activeTexture.set(Ne.TEXTURE0),An.atlasTexture.bind(An.atlasInterpolation,Ne.CLAMP_TO_EDGE),An.atlasTextureIcon&&(Ie.activeTexture.set(Ne.TEXTURE1),An.atlasTextureIcon&&An.atlasTextureIcon.bind(An.atlasInterpolationIcon,Ne.CLAMP_TO_EDGE)),An.isSDF){const bn=An.uniformValues;An.hasHalo&&(bn.u_is_halo=1,Ch(An.buffers,dn.segments,p,O,An.program,$t,ue,pe,bn,dn.terrainData)),bn.u_is_halo=0}Ch(An.buffers,dn.segments,p,O,An.program,$t,ue,pe,An.uniformValues,dn.terrainData)}}function Ch(O,u,p,_,M,I,z,W,Q,re){const ue=_.context;M.draw(ue,ue.gl.TRIANGLES,I,z,W,Mo.disabled,Q,re,p.id,O.layoutVertexBuffer,O.indexBuffer,u,p.paint,_.transform.zoom,O.programConfigurations.get(p.id),O.dynamicLayoutVertexBuffer,O.opacityVertexBuffer)}function kd(O,u,p,_,M){if(!p||!_||!_.imageAtlas)return;const I=_.imageAtlas.patternPositions;let z=I[p.to.toString()],W=I[p.from.toString()];if(!z&&W&&(z=W),!W&&z&&(W=z),!z||!W){const Q=M.getPaintProperty(u);z=I[Q],W=I[Q]}z&&W&&O.setConstantPatternPositions(z,W)}function vu(O,u,p,_,M,I,z){const W=O.context.gl,Q="fill-pattern",re=p.paint.get(Q),ue=re&&re.constantOr(1),pe=p.getCrossfadeParameters();let Ie,Ne,Re,$e,Ge;z?(Ne=ue&&!p.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline",Ie=W.LINES):(Ne=ue?"fillPattern":"fill",Ie=W.TRIANGLES);const ht=re.constantOr(null);for(const Tt of _){const Ze=u.getTile(Tt);if(ue&&!Ze.patternsLoaded())continue;const Ct=Ze.getBucket(p);if(!Ct)continue;const $t=Ct.programConfigurations.get(p.id),Dt=O.useProgram(Ne,$t),tn=O.style.map.terrain&&O.style.map.terrain.getTerrainData(Tt);ue&&(O.context.activeTexture.set(W.TEXTURE0),Ze.imageAtlasTexture.bind(W.LINEAR,W.CLAMP_TO_EDGE),$t.updatePaintBuffers(pe)),kd($t,Q,ht,Ze,p);const dn=tn?Tt:null,An=O.translatePosMatrix(dn?dn.posMatrix:Tt.posMatrix,Ze,p.paint.get("fill-translate"),p.paint.get("fill-translate-anchor"));if(z){$e=Ct.indexBuffer2,Ge=Ct.segments2;const bn=[W.drawingBufferWidth,W.drawingBufferHeight];Re=Ne==="fillOutlinePattern"&&ue?ma(An,O,pe,Ze,bn):Fu(An,bn)}else $e=Ct.indexBuffer,Ge=Ct.segments,Re=ue?vs(An,O,pe,Ze):qo(An);Dt.draw(O.context,Ie,M,O.stencilModeForClipping(Tt),I,Mo.disabled,Re,tn,p.id,Ct.layoutVertexBuffer,$e,Ge,p.paint,O.transform.zoom,$t)}}function Wu(O,u,p,_,M,I,z){const W=O.context,Q=W.gl,re="fill-extrusion-pattern",ue=p.paint.get(re),pe=ue.constantOr(1),Ie=p.getCrossfadeParameters(),Ne=p.paint.get("fill-extrusion-opacity"),Re=ue.constantOr(null);for(const $e of _){const Ge=u.getTile($e),ht=Ge.getBucket(p);if(!ht)continue;const Tt=O.style.map.terrain&&O.style.map.terrain.getTerrainData($e),Ze=ht.programConfigurations.get(p.id),Ct=O.useProgram(pe?"fillExtrusionPattern":"fillExtrusion",Ze);pe&&(O.context.activeTexture.set(Q.TEXTURE0),Ge.imageAtlasTexture.bind(Q.LINEAR,Q.CLAMP_TO_EDGE),Ze.updatePaintBuffers(Ie)),kd(Ze,re,Re,Ge,p);const $t=O.translatePosMatrix($e.posMatrix,Ge,p.paint.get("fill-extrusion-translate"),p.paint.get("fill-extrusion-translate-anchor")),Dt=p.paint.get("fill-extrusion-vertical-gradient"),tn=pe?ia($t,O,Dt,Ne,$e,Ie,Ge):as($t,O,Dt,Ne);Ct.draw(W,W.gl.TRIANGLES,M,I,z,Mo.backCCW,tn,Tt,p.id,ht.layoutVertexBuffer,ht.indexBuffer,ht.segments,p.paint,O.transform.zoom,Ze,O.style.map.terrain&&ht.centroidVertexBuffer)}}function $c(O,u,p,_,M,I,z){const W=O.context,Q=W.gl,re=p.fbo;if(!re)return;const ue=O.useProgram("hillshade"),pe=O.style.map.terrain&&O.style.map.terrain.getTerrainData(u);W.activeTexture.set(Q.TEXTURE0),Q.bindTexture(Q.TEXTURE_2D,re.colorAttachment.get()),ue.draw(W,Q.TRIANGLES,M,I,z,Mo.disabled,((Ie,Ne,Re,$e)=>{const Ge=Re.paint.get("hillshade-shadow-color"),ht=Re.paint.get("hillshade-highlight-color"),Tt=Re.paint.get("hillshade-accent-color");let Ze=Re.paint.get("hillshade-illumination-direction")*(Math.PI/180);Re.paint.get("hillshade-illumination-anchor")==="viewport"&&(Ze-=Ie.transform.angle);const Ct=!Ie.options.moving;return{u_matrix:$e?$e.posMatrix:Ie.transform.calculatePosMatrix(Ne.tileID.toUnwrapped(),Ct),u_image:0,u_latrange:Wo(0,Ne.tileID),u_light:[Re.paint.get("hillshade-exaggeration"),Ze],u_shadow:Ge,u_highlight:ht,u_accent:Tt}})(O,p,_,pe?u:null),pe,_.id,O.rasterBoundsBuffer,O.quadTriangleIndexBuffer,O.rasterBoundsSegments)}function PA(O,u,p,_,M,I){const z=O.context,W=z.gl,Q=u.dem;if(Q&&Q.data){const re=Q.dim,ue=Q.stride,pe=Q.getPixels();if(z.activeTexture.set(W.TEXTURE1),z.pixelStoreUnpackPremultiplyAlpha.set(!1),u.demTexture=u.demTexture||O.getTileTexture(ue),u.demTexture){const Ne=u.demTexture;Ne.update(pe,{premultiply:!1}),Ne.bind(W.NEAREST,W.CLAMP_TO_EDGE)}else u.demTexture=new He(z,pe,W.RGBA,{premultiply:!1}),u.demTexture.bind(W.NEAREST,W.CLAMP_TO_EDGE);z.activeTexture.set(W.TEXTURE0);let Ie=u.fbo;if(!Ie){const Ne=new He(z,{width:re,height:re,data:null},W.RGBA);Ne.bind(W.LINEAR,W.CLAMP_TO_EDGE),Ie=u.fbo=z.createFramebuffer(re,re,!0,!1),Ie.colorAttachment.set(Ne.texture)}z.bindFramebuffer.set(Ie.framebuffer),z.viewport.set([0,0,re,re]),O.useProgram("hillshadePrepare").draw(z,W.TRIANGLES,_,M,I,Mo.disabled,((Ne,Re)=>{const $e=Re.stride,Ge=a.F();return a.aN(Ge,0,a.W,-a.W,0,0,1),a.H(Ge,Ge,[0,-a.W,0]),{u_matrix:Ge,u_image:1,u_dimension:[$e,$e],u_zoom:Ne.overscaledZ,u_unpack:Re.getUnpackVector()}})(u.tileID,Q),null,p.id,O.rasterBoundsBuffer,O.quadTriangleIndexBuffer,O.rasterBoundsSegments),u.needsHillshadePrepare=!1}}function kf(O,u,p,_,M,I){const z=_.paint.get("raster-fade-duration");if(!I&&z>0){const W=B.now(),Q=(W-O.timeAdded)/z,re=u?(W-u.timeAdded)/z:-1,ue=p.getSource(),pe=M.coveringZoomLevel({tileSize:ue.tileSize,roundZoom:ue.roundZoom}),Ie=!u||Math.abs(u.tileID.overscaledZ-pe)>Math.abs(O.tileID.overscaledZ-pe),Ne=Ie&&O.refreshedUponExpiration?1:a.ac(Ie?Q:1-re,0,1);return O.refreshedUponExpiration&&Q>=1&&(O.refreshedUponExpiration=!1),u?{opacity:1,mix:1-Ne}:{opacity:Ne,mix:0}}return{opacity:1,mix:0}}const Ip=new a.aO(1,0,0,1),Ac=new a.aO(0,1,0,1),Yc=new a.aO(0,0,1,1),Rl=new a.aO(1,0,1,1),bl=new a.aO(0,1,1,1);function aa(O,u,p,_){ul(O,0,u+p/2,O.transform.width,p,_)}function cA(O,u,p,_){ul(O,u-p/2,0,p,O.transform.height,_)}function ul(O,u,p,_,M,I){const z=O.context,W=z.gl;W.enable(W.SCISSOR_TEST),W.scissor(u*O.pixelRatio,p*O.pixelRatio,_*O.pixelRatio,M*O.pixelRatio),z.clear({color:I}),W.disable(W.SCISSOR_TEST)}function FA(O,u,p){const _=O.context,M=_.gl,I=p.posMatrix,z=O.useProgram("debug"),W=Li.disabled,Q=To.disabled,re=O.colorModeForRenderPass(),ue="$debug",pe=O.style.map.terrain&&O.style.map.terrain.getTerrainData(p);_.activeTexture.set(M.TEXTURE0);const Ie=u.getTileByID(p.key).latestRawTileData,Ne=Math.floor((Ie&&Ie.byteLength||0)/1024),Re=u.getTile(p).tileSize,$e=512/Math.min(Re,512)*(p.overscaledZ/O.transform.zoom)*.5;let Ge=p.canonical.toString();p.overscaledZ!==p.canonical.z&&(Ge+=` => ${p.overscaledZ}`),function(ht,Tt){ht.initDebugOverlayCanvas();const Ze=ht.debugOverlayCanvas,Ct=ht.context.gl,$t=ht.debugOverlayCanvas.getContext("2d");$t.clearRect(0,0,Ze.width,Ze.height),$t.shadowColor="white",$t.shadowBlur=2,$t.lineWidth=1.5,$t.strokeStyle="white",$t.textBaseline="top",$t.font="bold 36px Open Sans, sans-serif",$t.fillText(Tt,5,5),$t.strokeText(Tt,5,5),ht.debugOverlayTexture.update(Ze),ht.debugOverlayTexture.bind(Ct.LINEAR,Ct.CLAMP_TO_EDGE)}(O,`${Ge} ${Ne}kB`),z.draw(_,M.TRIANGLES,W,Q,ya.alphaBlended,Mo.disabled,Lu(I,a.aO.transparent,$e),null,ue,O.debugBuffer,O.quadTriangleIndexBuffer,O.debugSegments),z.draw(_,M.LINE_STRIP,W,Q,re,Mo.disabled,Lu(I,a.aO.red),pe,ue,O.debugBuffer,O.tileBorderIndexBuffer,O.debugSegments)}function xl(O,u,p){const _=O.context,M=_.gl,I=O.colorModeForRenderPass(),z=new Li(M.LEQUAL,Li.ReadWrite,O.depthRangeFor3D),W=O.useProgram("terrain"),Q=u.getTerrainMesh();_.bindFramebuffer.set(null),_.viewport.set([0,0,O.width,O.height]);for(const re of p){const ue=O.renderToTexture.getTexture(re),pe=u.getTerrainData(re.tileID);_.activeTexture.set(M.TEXTURE0),M.bindTexture(M.TEXTURE_2D,ue.texture);const Ie={u_matrix:O.transform.calculatePosMatrix(re.tileID.toUnwrapped()),u_texture:0,u_ele_delta:u.getMeshFrameDelta(O.transform.zoom)};W.draw(_,M.TRIANGLES,z,To.disabled,I,Mo.backCCW,Ie,pe,"terrain",Q.vertexBuffer,Q.indexBuffer,Q.segments)}}class bh{constructor(u,p){this.context=new vh(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 Cn}resize(u,p,_){if(this.width=Math.floor(u*_),this.height=Math.floor(p*_),this.pixelRatio=_,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,Zo.members),this.tileExtentSegments=a.$.simpleSegment(0,0,4,2);const _=new a.aV;_.emplaceBack(0,0),_.emplaceBack(a.W,0),_.emplaceBack(0,a.W),_.emplaceBack(a.W,a.W),this.debugBuffer=u.createVertexBuffer(_,Zo.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,Xn.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,Zo.members),this.viewportSegments=a.$.simpleSegment(0,0,4,2);const z=new a.aW;z.emplaceBack(0),z.emplaceBack(1),z.emplaceBack(3),z.emplaceBack(2),z.emplaceBack(0),this.tileBorderIndexBuffer=u.createIndexBuffer(z);const W=new a.aX;W.emplaceBack(0,1,2),W.emplaceBack(2,1,3),this.quadTriangleIndexBuffer=u.createIndexBuffer(W);const Q=this.context.gl;this.stencilClearMode=new To({func:Q.ALWAYS,mask:0},0,255,Q.ZERO,Q.ZERO,Q.ZERO)}clearStencil(){const u=this.context,p=u.gl;this.nextStencilID=1,this.currentStencilSource=void 0;const _=a.F();a.aN(_,0,this.width,this.height,0,0,1),a.J(_,_,[p.drawingBufferWidth,p.drawingBufferHeight,0]),this.useProgram("clippingMask").draw(u,p.TRIANGLES,Li.disabled,this.stencilClearMode,ya.disabled,Mo.disabled,mu(_),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 _=this.context,M=_.gl;this.nextStencilID+p.length>256&&this.clearStencil(),_.setColorMode(ya.disabled),_.setDepthMode(Li.disabled);const I=this.useProgram("clippingMask");this._tileClippingMaskIDs={};for(const z of p){const W=this._tileClippingMaskIDs[z.key]=this.nextStencilID++,Q=this.style.map.terrain&&this.style.map.terrain.getTerrainData(z);I.draw(_,M.TRIANGLES,Li.disabled,new To({func:M.ALWAYS,mask:0},W,255,M.KEEP,M.KEEP,M.REPLACE),ya.disabled,Mo.disabled,mu(z.posMatrix),Q,"$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 To({func:p.NOTEQUAL,mask:255},u,255,p.KEEP,p.KEEP,p.REPLACE)}stencilModeForClipping(u){const p=this.context.gl;return new To({func:p.EQUAL,mask:255},this._tileClippingMaskIDs[u.key],0,p.KEEP,p.KEEP,p.REPLACE)}stencilConfigForOverlap(u){const p=this.context.gl,_=u.sort((z,W)=>W.overscaledZ-z.overscaledZ),M=_[_.length-1].overscaledZ,I=_[0].overscaledZ-M+1;if(I>1){this.currentStencilSource=void 0,this.nextStencilID+I>256&&this.clearStencil();const z={};for(let W=0;W<I;W++)z[W+M]=new To({func:p.GEQUAL,mask:255},W+this.nextStencilID,255,p.KEEP,p.KEEP,p.REPLACE);return this.nextStencilID+=I,[z,_]}return[{[M]:To.disabled},_]}colorModeForRenderPass(){const u=this.context.gl;return this._showOverdrawInspector?new ya([u.CONSTANT_COLOR,u.ONE],new a.aO(.125,.125,.125,0),[!0,!0,!0,!0]):this.renderPass==="opaque"?ya.unblended:ya.alphaBlended}depthModeForSublayer(u,p,_){if(!this.opaquePassEnabledForLayer())return Li.disabled;const M=1-((1+this.currentLayer)*this.numSublayers+u)*this.depthEpsilon;return new Li(_||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(B.now()),this.imageManager.beginFrame();const _=this.style._order,M=this.style.sourceCaches,I={},z={},W={};for(const Q in M){const re=M[Q];re.used&&re.prepare(this.context),I[Q]=re.getVisibleCoordinates(),z[Q]=I[Q].slice().reverse(),W[Q]=re.getVisibleCoordinates(!0).reverse()}this.opaquePassCutoff=1/0;for(let Q=0;Q<_.length;Q++)if(this.style._layers[_[Q]].is3D()){this.opaquePassCutoff=Q;break}if(this.renderToTexture){this.renderToTexture.prepareForRender(this.style,this.transform.zoom),this.opaquePassCutoff=0;const Q=this.style.map.terrain.sourceCache.tilesAfterTime(this.terrainFacilitator.renderTime);(this.terrainFacilitator.dirty||!a.aY(this.terrainFacilitator.matrix,this.transform.projMatrix)||Q.length)&&(a.aZ(this.terrainFacilitator.matrix,this.transform.projMatrix),this.terrainFacilitator.renderTime=Date.now(),this.terrainFacilitator.dirty=!1,function(re,ue){const pe=re.context,Ie=pe.gl,Ne=ya.unblended,Re=new Li(Ie.LEQUAL,Li.ReadWrite,[0,1]),$e=ue.getTerrainMesh(),Ge=ue.sourceCache.getRenderableTiles(),ht=re.useProgram("terrainDepth");pe.bindFramebuffer.set(ue.getFramebuffer("depth").framebuffer),pe.viewport.set([0,0,re.width/devicePixelRatio,re.height/devicePixelRatio]),pe.clear({color:a.aO.transparent,depth:1});for(const Tt of Ge){const Ze=ue.getTerrainData(Tt.tileID),Ct={u_matrix:re.transform.calculatePosMatrix(Tt.tileID.toUnwrapped()),u_ele_delta:ue.getMeshFrameDelta(re.transform.zoom)};ht.draw(pe,Ie.TRIANGLES,Re,To.disabled,Ne,Mo.backCCW,Ct,Ze,"terrain",$e.vertexBuffer,$e.indexBuffer,$e.segments)}pe.bindFramebuffer.set(null),pe.viewport.set([0,0,re.width,re.height])}(this,this.style.map.terrain),function(re,ue){const pe=re.context,Ie=pe.gl,Ne=ya.unblended,Re=new Li(Ie.LEQUAL,Li.ReadWrite,[0,1]),$e=ue.getTerrainMesh(),Ge=ue.getCoordsTexture(),ht=ue.sourceCache.getRenderableTiles(),Tt=re.useProgram("terrainCoords");pe.bindFramebuffer.set(ue.getFramebuffer("coords").framebuffer),pe.viewport.set([0,0,re.width/devicePixelRatio,re.height/devicePixelRatio]),pe.clear({color:a.aO.transparent,depth:1}),ue.coordsIndex=[];for(const Ze of ht){const Ct=ue.getTerrainData(Ze.tileID);pe.activeTexture.set(Ie.TEXTURE0),Ie.bindTexture(Ie.TEXTURE_2D,Ge.texture);const $t={u_matrix:re.transform.calculatePosMatrix(Ze.tileID.toUnwrapped()),u_terrain_coords_id:(255-ue.coordsIndex.length)/255,u_texture:0,u_ele_delta:ue.getMeshFrameDelta(re.transform.zoom)};Tt.draw(pe,Ie.TRIANGLES,Re,To.disabled,Ne,Mo.backCCW,$t,Ct,"terrain",$e.vertexBuffer,$e.indexBuffer,$e.segments),ue.coordsIndex.push(Ze.tileID.key)}pe.bindFramebuffer.set(null),pe.viewport.set([0,0,re.width,re.height])}(this,this.style.map.terrain))}this.renderPass="offscreen";for(const Q of _){const re=this.style._layers[Q];if(!re.hasOffscreenPass()||re.isHidden(this.transform.zoom))continue;const ue=z[re.source];(re.type==="custom"||ue.length)&&this.renderLayer(this,M[re.source],re,ue)}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=_.length-1;this.currentLayer>=0;this.currentLayer--){const Q=this.style._layers[_[this.currentLayer]],re=M[Q.source],ue=I[Q.source];this._renderTileClippingMasks(Q,ue),this.renderLayer(this,re,Q,ue)}for(this.renderPass="translucent",this.currentLayer=0;this.currentLayer<_.length;this.currentLayer++){const Q=this.style._layers[_[this.currentLayer]],re=M[Q.source];if(this.renderToTexture&&this.renderToTexture.renderLayer(Q))continue;const ue=(Q.type==="symbol"?W:z)[Q.source];this._renderTileClippingMasks(Q,I[Q.source]),this.renderLayer(this,re,Q,ue)}if(this.options.showTileBoundaries){const Q=function(re,ue){let pe=null;const Ie=Object.values(re._layers).flatMap(Ge=>Ge.source&&!Ge.isHidden(ue)?[re.sourceCaches[Ge.source]]:[]),Ne=Ie.filter(Ge=>Ge.getSource().type==="vector"),Re=Ie.filter(Ge=>Ge.getSource().type!=="vector"),$e=Ge=>{(!pe||pe.getSource().maxzoom<Ge.getSource().maxzoom)&&(pe=Ge)};return Ne.forEach(Ge=>$e(Ge)),pe||Re.forEach(Ge=>$e(Ge)),pe}(this.style,this.transform.zoom);Q&&function(re,ue,pe){for(let Ie=0;Ie<pe.length;Ie++)FA(re,ue,pe[Ie])}(this,Q,Q.getVisibleCoordinates())}this.options.showPadding&&function(Q){const re=Q.transform.padding;aa(Q,Q.transform.height-(re.top||0),3,Ip),aa(Q,re.bottom||0,3,Ac),cA(Q,re.left||0,3,Yc),cA(Q,Q.transform.width-(re.right||0),3,Rl);const ue=Q.transform.centerPoint;(function(pe,Ie,Ne,Re){ul(pe,Ie-1,Ne-10,2,20,Re),ul(pe,Ie-10,Ne-1,20,2,Re)})(Q,ue.x,Q.transform.height-ue.y,bl)}(this),this.context.setDefault()}renderLayer(u,p,_,M){if(!_.isHidden(this.transform.zoom)&&(_.type==="background"||_.type==="custom"||(M||[]).length))switch(this.id=_.id,_.type){case"symbol":(function(I,z,W,Q,re){if(I.renderPass!=="translucent")return;const ue=To.disabled,pe=I.colorModeForRenderPass();(W._unevaluatedLayout.hasValue("text-variable-anchor")||W._unevaluatedLayout.hasValue("text-variable-anchor-offset"))&&function(Ie,Ne,Re,$e,Ge,ht,Tt){const Ze=Ne.transform,Ct=Ge==="map",$t=ht==="map";for(const Dt of Ie){const tn=$e.getTile(Dt),dn=tn.getBucket(Re);if(!dn||!dn.text||!dn.text.segments.get().length)continue;const An=a.ag(dn.textSizeData,Ze.zoom),bn=ar(tn,1,Ne.transform.zoom),tr=Kt(Dt.posMatrix,$t,Ct,Ne.transform,bn),Pr=Re.layout.get("icon-text-fit")!=="none"&&dn.hasIconData();if(An){const Tn=Math.pow(2,Ze.zoom-tn.tileID.overscaledZ);eu(dn,Ct,$t,Tt,Ze,tr,Dt.posMatrix,Tn,An,Pr,Ne.style.map.terrain?(xr,Jn)=>Ne.style.map.terrain.getElevation(Dt,xr,Jn):null)}}}(Q,I,W,z,W.layout.get("text-rotation-alignment"),W.layout.get("text-pitch-alignment"),re),W.paint.get("icon-opacity").constantOr(1)!==0&&KA(I,z,W,Q,!1,W.paint.get("icon-translate"),W.paint.get("icon-translate-anchor"),W.layout.get("icon-rotation-alignment"),W.layout.get("icon-pitch-alignment"),W.layout.get("icon-keep-upright"),ue,pe),W.paint.get("text-opacity").constantOr(1)!==0&&KA(I,z,W,Q,!0,W.paint.get("text-translate"),W.paint.get("text-translate-anchor"),W.layout.get("text-rotation-alignment"),W.layout.get("text-pitch-alignment"),W.layout.get("text-keep-upright"),ue,pe),z.map.showCollisionBoxes&&(Qc(I,z,W,Q,W.paint.get("text-translate"),W.paint.get("text-translate-anchor"),!0),Qc(I,z,W,Q,W.paint.get("icon-translate"),W.paint.get("icon-translate-anchor"),!1))})(u,p,_,M,this.style.placement.variableOffsets);break;case"circle":(function(I,z,W,Q){if(I.renderPass!=="translucent")return;const re=W.paint.get("circle-opacity"),ue=W.paint.get("circle-stroke-width"),pe=W.paint.get("circle-stroke-opacity"),Ie=!W.layout.get("circle-sort-key").isConstant();if(re.constantOr(1)===0&&(ue.constantOr(1)===0||pe.constantOr(1)===0))return;const Ne=I.context,Re=Ne.gl,$e=I.depthModeForSublayer(0,Li.ReadOnly),Ge=To.disabled,ht=I.colorModeForRenderPass(),Tt=[];for(let Ze=0;Ze<Q.length;Ze++){const Ct=Q[Ze],$t=z.getTile(Ct),Dt=$t.getBucket(W);if(!Dt)continue;const tn=Dt.programConfigurations.get(W.id),dn=I.useProgram("circle",tn),An=Dt.layoutVertexBuffer,bn=Dt.indexBuffer,tr=I.style.map.terrain&&I.style.map.terrain.getTerrainData(Ct),Pr={programConfiguration:tn,program:dn,layoutVertexBuffer:An,indexBuffer:bn,uniformValues:lA(I,Ct,$t,W),terrainData:tr};if(Ie){const Tn=Dt.segments.get();for(const xr of Tn)Tt.push({segments:new a.$([xr]),sortKey:xr.sortKey,state:Pr})}else Tt.push({segments:Dt.segments,sortKey:0,state:Pr})}Ie&&Tt.sort((Ze,Ct)=>Ze.sortKey-Ct.sortKey);for(const Ze of Tt){const{programConfiguration:Ct,program:$t,layoutVertexBuffer:Dt,indexBuffer:tn,uniformValues:dn,terrainData:An}=Ze.state;$t.draw(Ne,Re.TRIANGLES,$e,Ge,ht,Mo.disabled,dn,An,W.id,Dt,tn,Ze.segments,W.paint,I.transform.zoom,Ct)}})(u,p,_,M);break;case"heatmap":(function(I,z,W,Q){if(W.paint.get("heatmap-opacity")!==0)if(I.renderPass==="offscreen"){const re=I.context,ue=re.gl,pe=To.disabled,Ie=new ya([ue.ONE,ue.ONE],a.aO.transparent,[!0,!0,!0,!0]);(function(Ne,Re,$e){const Ge=Ne.gl;Ne.activeTexture.set(Ge.TEXTURE1),Ne.viewport.set([0,0,Re.width/4,Re.height/4]);let ht=$e.heatmapFbo;if(ht)Ge.bindTexture(Ge.TEXTURE_2D,ht.colorAttachment.get()),Ne.bindFramebuffer.set(ht.framebuffer);else{const Tt=Ge.createTexture();Ge.bindTexture(Ge.TEXTURE_2D,Tt),Ge.texParameteri(Ge.TEXTURE_2D,Ge.TEXTURE_WRAP_S,Ge.CLAMP_TO_EDGE),Ge.texParameteri(Ge.TEXTURE_2D,Ge.TEXTURE_WRAP_T,Ge.CLAMP_TO_EDGE),Ge.texParameteri(Ge.TEXTURE_2D,Ge.TEXTURE_MIN_FILTER,Ge.LINEAR),Ge.texParameteri(Ge.TEXTURE_2D,Ge.TEXTURE_MAG_FILTER,Ge.LINEAR),ht=$e.heatmapFbo=Ne.createFramebuffer(Re.width/4,Re.height/4,!1,!1),function(Ze,Ct,$t,Dt){var tn,dn;const An=Ze.gl,bn=(tn=Ze.HALF_FLOAT)!==null&&tn!==void 0?tn:An.UNSIGNED_BYTE,tr=(dn=Ze.RGBA16F)!==null&&dn!==void 0?dn:An.RGBA;An.texImage2D(An.TEXTURE_2D,0,tr,Ct.width/4,Ct.height/4,0,An.RGBA,bn,null),Dt.colorAttachment.set($t)}(Ne,Re,Tt,ht)}})(re,I,W),re.clear({color:a.aO.transparent});for(let Ne=0;Ne<Q.length;Ne++){const Re=Q[Ne];if(z.hasRenderableParent(Re))continue;const $e=z.getTile(Re),Ge=$e.getBucket(W);if(!Ge)continue;const ht=Ge.programConfigurations.get(W.id),Tt=I.useProgram("heatmap",ht),{zoom:Ze}=I.transform;Tt.draw(re,ue.TRIANGLES,Li.disabled,pe,Ie,Mo.disabled,uA(Re.posMatrix,$e,Ze,W.paint.get("heatmap-intensity")),null,W.id,Ge.layoutVertexBuffer,Ge.indexBuffer,Ge.segments,W.paint,I.transform.zoom,ht)}re.viewport.set([0,0,I.width,I.height])}else I.renderPass==="translucent"&&(I.context.setColorMode(I.colorModeForRenderPass()),function(re,ue){const pe=re.context,Ie=pe.gl,Ne=ue.heatmapFbo;if(!Ne)return;pe.activeTexture.set(Ie.TEXTURE0),Ie.bindTexture(Ie.TEXTURE_2D,Ne.colorAttachment.get()),pe.activeTexture.set(Ie.TEXTURE1);let Re=ue.colorRampTexture;Re||(Re=ue.colorRampTexture=new He(pe,ue.colorRamp,Ie.RGBA)),Re.bind(Ie.LINEAR,Ie.CLAMP_TO_EDGE),re.useProgram("heatmapTexture").draw(pe,Ie.TRIANGLES,Li.disabled,To.disabled,re.colorModeForRenderPass(),Mo.disabled,(($e,Ge,ht,Tt)=>{const Ze=a.F();a.aN(Ze,0,$e.width,$e.height,0,0,1);const Ct=$e.context.gl;return{u_matrix:Ze,u_world:[Ct.drawingBufferWidth,Ct.drawingBufferHeight],u_image:0,u_color_ramp:1,u_opacity:Ge.paint.get("heatmap-opacity")}})(re,ue),null,ue.id,re.viewportBuffer,re.quadTriangleIndexBuffer,re.viewportSegments,ue.paint,re.transform.zoom)}(I,W))})(u,p,_,M);break;case"line":(function(I,z,W,Q){if(I.renderPass!=="translucent")return;const re=W.paint.get("line-opacity"),ue=W.paint.get("line-width");if(re.constantOr(1)===0||ue.constantOr(1)===0)return;const pe=I.depthModeForSublayer(0,Li.ReadOnly),Ie=I.colorModeForRenderPass(),Ne=W.paint.get("line-dasharray"),Re=W.paint.get("line-pattern"),$e=Re.constantOr(1),Ge=W.paint.get("line-gradient"),ht=W.getCrossfadeParameters(),Tt=$e?"linePattern":Ne?"lineSDF":Ge?"lineGradient":"line",Ze=I.context,Ct=Ze.gl;let $t=!0;for(const Dt of Q){const tn=z.getTile(Dt);if($e&&!tn.patternsLoaded())continue;const dn=tn.getBucket(W);if(!dn)continue;const An=dn.programConfigurations.get(W.id),bn=I.context.program.get(),tr=I.useProgram(Tt,An),Pr=$t||tr.program!==bn,Tn=I.style.map.terrain&&I.style.map.terrain.getTerrainData(Dt),xr=Re.constantOr(null);if(xr&&tn.imageAtlas){const ki=tn.imageAtlas,ri=ki.patternPositions[xr.to.toString()],Mi=ki.patternPositions[xr.from.toString()];ri&&Mi&&An.setConstantPatternPositions(ri,Mi)}const Jn=Tn?Dt:null,Ni=$e?ss(I,tn,W,ht,Jn):Ne?ll(I,tn,W,Ne,ht,Jn):Ge?Uu(I,tn,W,dn.lineClipsArray.length,Jn):Na(I,tn,W,Jn);if($e)Ze.activeTexture.set(Ct.TEXTURE0),tn.imageAtlasTexture.bind(Ct.LINEAR,Ct.CLAMP_TO_EDGE),An.updatePaintBuffers(ht);else if(Ne&&(Pr||I.lineAtlas.dirty))Ze.activeTexture.set(Ct.TEXTURE0),I.lineAtlas.bind(Ze);else if(Ge){const ki=dn.gradients[W.id];let ri=ki.texture;if(W.gradientVersion!==ki.version){let Mi=256;if(W.stepInterpolant){const ea=z.getSource().maxzoom,Ui=Dt.canonical.z===ea?Math.ceil(1<<I.transform.maxZoom-Dt.canonical.z):1;Mi=a.ac(a.aT(dn.maxLineLength/a.W*1024*Ui),256,Ze.maxTextureSize)}ki.gradient=a.aU({expression:W.gradientExpression(),evaluationKey:"lineProgress",resolution:Mi,image:ki.gradient||void 0,clips:dn.lineClipsArray}),ki.texture?ki.texture.update(ki.gradient):ki.texture=new He(Ze,ki.gradient,Ct.RGBA),ki.version=W.gradientVersion,ri=ki.texture}Ze.activeTexture.set(Ct.TEXTURE0),ri.bind(W.stepInterpolant?Ct.NEAREST:Ct.LINEAR,Ct.CLAMP_TO_EDGE)}tr.draw(Ze,Ct.TRIANGLES,pe,I.stencilModeForClipping(Dt),Ie,Mo.disabled,Ni,Tn,W.id,dn.layoutVertexBuffer,dn.indexBuffer,dn.segments,W.paint,I.transform.zoom,An,dn.layoutVertexBuffer2),$t=!1}})(u,p,_,M);break;case"fill":(function(I,z,W,Q){const re=W.paint.get("fill-color"),ue=W.paint.get("fill-opacity");if(ue.constantOr(1)===0)return;const pe=I.colorModeForRenderPass(),Ie=W.paint.get("fill-pattern"),Ne=I.opaquePassEnabledForLayer()&&!Ie.constantOr(1)&&re.constantOr(a.aO.transparent).a===1&&ue.constantOr(0)===1?"opaque":"translucent";if(I.renderPass===Ne){const Re=I.depthModeForSublayer(1,I.renderPass==="opaque"?Li.ReadWrite:Li.ReadOnly);vu(I,z,W,Q,Re,pe,!1)}if(I.renderPass==="translucent"&&W.paint.get("fill-antialias")){const Re=I.depthModeForSublayer(W.getPaintProperty("fill-outline-color")?2:0,Li.ReadOnly);vu(I,z,W,Q,Re,pe,!0)}})(u,p,_,M);break;case"fill-extrusion":(function(I,z,W,Q){const re=W.paint.get("fill-extrusion-opacity");if(re!==0&&I.renderPass==="translucent"){const ue=new Li(I.context.gl.LEQUAL,Li.ReadWrite,I.depthRangeFor3D);if(re!==1||W.paint.get("fill-extrusion-pattern").constantOr(1))Wu(I,z,W,Q,ue,To.disabled,ya.disabled),Wu(I,z,W,Q,ue,I.stencilModeFor3D(),I.colorModeForRenderPass());else{const pe=I.colorModeForRenderPass();Wu(I,z,W,Q,ue,To.disabled,pe)}}})(u,p,_,M);break;case"hillshade":(function(I,z,W,Q){if(I.renderPass!=="offscreen"&&I.renderPass!=="translucent")return;const re=I.context,ue=I.depthModeForSublayer(0,Li.ReadOnly),pe=I.colorModeForRenderPass(),[Ie,Ne]=I.renderPass==="translucent"?I.stencilConfigForOverlap(Q):[{},Q];for(const Re of Ne){const $e=z.getTile(Re);$e.needsHillshadePrepare!==void 0&&$e.needsHillshadePrepare&&I.renderPass==="offscreen"?PA(I,$e,W,ue,To.disabled,pe):I.renderPass==="translucent"&&$c(I,Re,$e,W,ue,Ie[Re.overscaledZ],pe)}re.viewport.set([0,0,I.width,I.height])})(u,p,_,M);break;case"raster":(function(I,z,W,Q){if(I.renderPass!=="translucent"||W.paint.get("raster-opacity")===0||!Q.length)return;const re=I.context,ue=re.gl,pe=z.getSource(),Ie=I.useProgram("raster"),Ne=I.colorModeForRenderPass(),[Re,$e]=pe instanceof cr?[{},Q]:I.stencilConfigForOverlap(Q),Ge=$e[$e.length-1].overscaledZ,ht=!I.options.moving;for(const Tt of $e){const Ze=I.depthModeForSublayer(Tt.overscaledZ-Ge,W.paint.get("raster-opacity")===1?Li.ReadWrite:Li.ReadOnly,ue.LESS),Ct=z.getTile(Tt);Ct.registerFadeDuration(W.paint.get("raster-fade-duration"));const $t=z.findLoadedParent(Tt,0),Dt=kf(Ct,$t,z,W,I.transform,I.style.map.terrain);let tn,dn;const An=W.paint.get("raster-resampling")==="nearest"?ue.NEAREST:ue.LINEAR;re.activeTexture.set(ue.TEXTURE0),Ct.texture.bind(An,ue.CLAMP_TO_EDGE,ue.LINEAR_MIPMAP_NEAREST),re.activeTexture.set(ue.TEXTURE1),$t?($t.texture.bind(An,ue.CLAMP_TO_EDGE,ue.LINEAR_MIPMAP_NEAREST),tn=Math.pow(2,$t.tileID.overscaledZ-Ct.tileID.overscaledZ),dn=[Ct.tileID.canonical.x*tn%1,Ct.tileID.canonical.y*tn%1]):Ct.texture.bind(An,ue.CLAMP_TO_EDGE,ue.LINEAR_MIPMAP_NEAREST);const bn=I.style.map.terrain&&I.style.map.terrain.getTerrainData(Tt),tr=bn?Tt:null,Pr=tr?tr.posMatrix:I.transform.calculatePosMatrix(Tt.toUnwrapped(),ht),Tn=vl(Pr,dn||[0,0],tn||1,Dt,W);pe instanceof cr?Ie.draw(re,ue.TRIANGLES,Ze,To.disabled,Ne,Mo.disabled,Tn,bn,W.id,pe.boundsBuffer,I.quadTriangleIndexBuffer,pe.boundsSegments):Ie.draw(re,ue.TRIANGLES,Ze,Re[Tt.overscaledZ],Ne,Mo.disabled,Tn,bn,W.id,I.rasterBoundsBuffer,I.quadTriangleIndexBuffer,I.rasterBoundsSegments)}})(u,p,_,M);break;case"background":(function(I,z,W,Q){const re=W.paint.get("background-color"),ue=W.paint.get("background-opacity");if(ue===0)return;const pe=I.context,Ie=pe.gl,Ne=I.transform,Re=Ne.tileSize,$e=W.paint.get("background-pattern");if(I.isPatternMissing($e))return;const Ge=!$e&&re.a===1&&ue===1&&I.opaquePassEnabledForLayer()?"opaque":"translucent";if(I.renderPass!==Ge)return;const ht=To.disabled,Tt=I.depthModeForSublayer(0,Ge==="opaque"?Li.ReadWrite:Li.ReadOnly),Ze=I.colorModeForRenderPass(),Ct=I.useProgram($e?"backgroundPattern":"background"),$t=Q||Ne.coveringTiles({tileSize:Re,terrain:I.style.map.terrain});$e&&(pe.activeTexture.set(Ie.TEXTURE0),I.imageManager.bind(I.context));const Dt=W.getCrossfadeParameters();for(const tn of $t){const dn=Q?tn.posMatrix:I.transform.calculatePosMatrix(tn.toUnwrapped()),An=$e?go(dn,ue,I,$e,{tileID:tn,tileSize:Re},Dt):AA(dn,ue,re),bn=I.style.map.terrain&&I.style.map.terrain.getTerrainData(tn);Ct.draw(pe,Ie.TRIANGLES,Tt,ht,Ze,Mo.disabled,An,bn,W.id,I.tileExtentBuffer,I.quadTriangleIndexBuffer,I.tileExtentSegments)}})(u,0,_,M);break;case"custom":(function(I,z,W){const Q=I.context,re=W.implementation;if(I.renderPass==="offscreen"){const ue=re.prerender;ue&&(I.setCustomLayerDefaults(),Q.setColorMode(I.colorModeForRenderPass()),ue.call(re,Q.gl,I.transform.customLayerMatrix()),Q.setDirty(),I.setBaseState())}else if(I.renderPass==="translucent"){I.setCustomLayerDefaults(),Q.setColorMode(I.colorModeForRenderPass()),Q.setStencilMode(To.disabled);const ue=re.renderingMode==="3d"?new Li(I.context.gl.LEQUAL,Li.ReadWrite,I.depthRangeFor3D):I.depthModeForSublayer(0,Li.ReadOnly);Q.setDepthMode(ue),re.render(Q.gl,I.transform.customLayerMatrix()),Q.setDirty(),I.setBaseState(),Q.bindFramebuffer.set(null)}})(u,0,_)}}translatePosMatrix(u,p,_,M,I){if(!_[0]&&!_[1])return u;const z=I?M==="map"?this.transform.angle:0:M==="viewport"?-this.transform.angle:0;if(z){const re=Math.sin(z),ue=Math.cos(z);_=[_[0]*ue-_[1]*re,_[0]*re+_[1]*ue]}const W=[I?_[0]:ar(p,_[0],this.transform.zoom),I?_[1]:ar(p,_[1],this.transform.zoom),0],Q=new Float32Array(16);return a.H(Q,u,W),Q}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()),_=this.imageManager.getPattern(u.to.toString());return!p||!_}useProgram(u,p){this.cache=this.cache||{};const _=u+(p?p.cacheKey:"")+(this._showOverdrawInspector?"/overdraw":"")+(this.style.map.terrain?"/terrain":"");return this.cache[_]||(this.cache[_]=new pa(this.context,Or[u],p,oo[u],this._showOverdrawInspector,this.style.map.terrain)),this.cache[_]}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 He(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 dA{constructor(u,p){this.points=u,this.planes=p}static fromInvProjectionMatrix(u,p,_){const M=Math.pow(2,_),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(W=>{const Q=1/(W=a.af([],W,u))[3]/p*M;return a.a_(W,W,[Q,Q,1/W[3],Q])}),z=[[0,1,2],[6,5,4],[0,3,7],[2,1,5],[3,2,6],[0,4,5]].map(W=>{const Q=function(Ie,Ne){var Re=Ne[0],$e=Ne[1],Ge=Ne[2],ht=Re*Re+$e*$e+Ge*Ge;return ht>0&&(ht=1/Math.sqrt(ht)),Ie[0]=Ne[0]*ht,Ie[1]=Ne[1]*ht,Ie[2]=Ne[2]*ht,Ie}([],function(Ie,Ne,Re){var $e=Ne[0],Ge=Ne[1],ht=Ne[2],Tt=Re[0],Ze=Re[1],Ct=Re[2];return Ie[0]=Ge*Ct-ht*Ze,Ie[1]=ht*Tt-$e*Ct,Ie[2]=$e*Ze-Ge*Tt,Ie}([],ye([],I[W[0]],I[W[1]]),ye([],I[W[2]],I[W[1]]))),re=-((ue=Q)[0]*(pe=I[W[1]])[0]+ue[1]*pe[1]+ue[2]*pe[2]);var ue,pe;return Q.concat(re)});return new dA(I,z)}}class tu{constructor(u,p){this.min=u,this.max=p,this.center=function(_,M,I){return _[0]=.5*M[0],_[1]=.5*M[1],_[2]=.5*M[2],_}([],function(_,M,I){return _[0]=M[0]+I[0],_[1]=M[1]+I[1],_[2]=M[2]+I[2],_}([],this.min,this.max))}quadrant(u){const p=[u%2==0,u<2],_=V(this.min),M=V(this.max);for(let I=0;I<p.length;I++)_[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 tu(_,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 _=!0;for(let M=0;M<u.planes.length;M++){const I=u.planes[M];let z=0;for(let W=0;W<p.length;W++)a.a$(I,p[W])>=0&&z++;if(z===0)return 0;z!==p.length&&(_=!1)}if(_)return 2;for(let M=0;M<3;M++){let I=Number.MAX_VALUE,z=-Number.MAX_VALUE;for(let W=0;W<u.points.length;W++){const Q=u.points[W][M]-this.min[M];I=Math.min(I,Q),z=Math.max(z,Q)}if(z<0||I>this.max[M]-this.min[M])return 0}return 1}}class cc{constructor(u=0,p=0,_=0,M=0){if(isNaN(u)||u<0||isNaN(p)||p<0||isNaN(_)||_<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=_,this.right=M}interpolate(u,p,_){return p.top!=null&&u.top!=null&&(this.top=a.z.number(u.top,p.top,_)),p.bottom!=null&&u.bottom!=null&&(this.bottom=a.z.number(u.bottom,p.bottom,_)),p.left!=null&&u.left!=null&&(this.left=a.z.number(u.left,p.left,_)),p.right!=null&&u.right!=null&&(this.right=a.z.number(u.right,p.right,_)),this}getCenter(u,p){const _=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(_,M)}equals(u){return this.top===u.top&&this.bottom===u.bottom&&this.left===u.left&&this.right===u.right}clone(){return new cc(this.top,this.bottom,this.left,this.right)}toJSON(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}}}class Id{constructor(u,p,_,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=_??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 cc,this._posMatrixCache={},this._alignedPosMatrixCache={},this.minElevationForCurrentTile=0}clone(){const u=new Id(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 _=new a.A(4);return a.A!=Float32Array&&(_[1]=0,_[2]=0),_[0]=1,_[3]=1,_}(),function(_,M,I){var z=M[0],W=M[1],Q=M[2],re=M[3],ue=Math.sin(I),pe=Math.cos(I);_[0]=z*pe+Q*ue,_[1]=W*pe+re*ue,_[2]=z*-ue+Q*pe,_[3]=W*-ue+re*pe}(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,_){this._unmodified=!1,this._edgeInsets.interpolate(u,p,_),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 _=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)),z=this.pointCoordinate(new a.P(0,this.height)),W=Math.floor(Math.min(_.x,M.x,I.x,z.x)),Q=Math.floor(Math.max(_.x,M.x,I.x,z.x)),re=1;for(let ue=W-re;ue<=Q+re;ue++)ue!==0&&p.push(new a.b1(ue,u))}return p}coveringTiles(u){var p,_;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 z=this.pointCoordinate(this.getCameraPoint()),W=a.Y.fromLngLat(this.center),Q=Math.pow(2,M),re=[Q*z.x,Q*z.y,0],ue=[Q*W.x,Q*W.y,0],pe=dA.fromInvProjectionMatrix(this.invProjMatrix,this.worldSize,M);let Ie=u.minzoom||0;!u.terrain&&this.pitch<=60&&this._edgeInsets.top<.1&&(Ie=M);const Ne=u.terrain?2/Math.min(this.tileSize,u.tileSize)*this.tileSize:3,Re=Ze=>({aabb:new tu([Ze*Q,0,0],[(Ze+1)*Q,Q,0]),zoom:0,x:0,y:0,wrap:Ze,fullyVisible:!1}),$e=[],Ge=[],ht=M,Tt=u.reparseOverscaled?I:M;if(this._renderWorldCopies)for(let Ze=1;Ze<=3;Ze++)$e.push(Re(-Ze)),$e.push(Re(Ze));for($e.push(Re(0));$e.length>0;){const Ze=$e.pop(),Ct=Ze.x,$t=Ze.y;let Dt=Ze.fullyVisible;if(!Dt){const tr=Ze.aabb.intersects(pe);if(tr===0)continue;Dt=tr===2}const tn=u.terrain?re:ue,dn=Ze.aabb.distanceX(tn),An=Ze.aabb.distanceY(tn),bn=Math.max(Math.abs(dn),Math.abs(An));if(Ze.zoom===ht||bn>Ne+(1<<ht-Ze.zoom)-2&&Ze.zoom>=Ie){const tr=ht-Ze.zoom,Pr=re[0]-.5-(Ct<<tr),Tn=re[1]-.5-($t<<tr);Ge.push({tileID:new a.Q(Ze.zoom===ht?Tt:Ze.zoom,Ze.wrap,Ze.zoom,Ct,$t),distanceSq:Oe([ue[0]-.5-Ct,ue[1]-.5-$t]),tileDistanceToCamera:Math.sqrt(Pr*Pr+Tn*Tn)})}else for(let tr=0;tr<4;tr++){const Pr=(Ct<<1)+tr%2,Tn=($t<<1)+(tr>>1),xr=Ze.zoom+1;let Jn=Ze.aabb.quadrant(tr);if(u.terrain){const Ni=new a.Q(xr,Ze.wrap,xr,Pr,Tn),ki=u.terrain.getMinMaxElevation(Ni),ri=(p=ki.minElevation)!==null&&p!==void 0?p:this.elevation,Mi=(_=ki.maxElevation)!==null&&_!==void 0?_:this.elevation;Jn=new tu([Jn.min[0],Jn.min[1],ri],[Jn.max[0],Jn.max[1],Mi])}$e.push({aabb:Jn,zoom:xr,x:Pr,y:Tn,wrap:Ze.wrap,fullyVisible:Dt})}}return Ge.sort((Ze,Ct)=>Ze.distanceSq-Ct.distanceSq).map(Ze=>Ze.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),_=u.getElevationForLngLatZoom(p,this.tileZoom);if(!(this.elevation-_))return;const M=this.getCameraPosition(),I=a.Y.fromLngLat(M.lngLat,M.altitude),z=a.Y.fromLngLat(p,_),W=I.x-z.x,Q=I.y-z.y,re=I.z-z.z,ue=Math.sqrt(W*W+Q*Q+re*re),pe=this.scaleZoom(this.cameraToCenterDistance/ue/this.tileSize);this._elevation=_,this._center=p,this.zoom=pe}setLocationAtPoint(u,p){const _=this.pointCoordinate(p),M=this.pointCoordinate(this.centerPoint),I=this.locationCoordinate(u),z=new a.Y(I.x-(_.x-M.x),I.y-(_.y-M.y));this.center=this.coordinateLocation(z),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 Ie=p.pointCoordinate(u);if(Ie!=null)return Ie}const _=[u.x,u.y,0,1],M=[u.x,u.y,1,1];a.af(_,_,this.pixelMatrixInverse),a.af(M,M,this.pixelMatrixInverse);const I=_[3],z=M[3],W=_[1]/I,Q=M[1]/z,re=_[2]/I,ue=M[2]/z,pe=re===ue?0:(0-re)/(ue-re);return new a.Y(a.z.number(_[0]/I,M[0]/z,pe)/this.worldSize,a.z.number(W,Q,pe)/this.worldSize)}coordinatePoint(u,p=0,_=this.pixelMatrix){const M=[u.x*this.worldSize,u.y*this.worldSize,p,1];return a.af(M,M,_),new a.P(M[0]/M[3],M[1]/M[3])}getBounds(){const u=Math.max(0,this.height/2-this.getHorizon());return new Ut().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 Ut([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 _=u.key,M=p?this._alignedPosMatrixCache:this._posMatrixCache;if(M[_])return M[_];const I=u.canonical,z=this.worldSize/this.zoomScale(I.z),W=I.x+Math.pow(2,I.z)*u.wrap,Q=a.an(new Float64Array(16));return a.H(Q,Q,[W*z,I.y*z,0]),a.J(Q,Q,[z/a.W,z/a.W,1]),a.K(Q,p?this.alignedProjMatrix:this.projMatrix,Q),M[_]=new Float32Array(Q),M[_]}customLayerMatrix(){return this.mercatorMatrix.slice()}_constrain(){if(!this.center||!this.width||!this.height||this._constraining)return;this._constraining=!0;let u,p,_,M,I=-90,z=90,W=-180,Q=180;const re=this.size,ue=this._unmodified;if(this.latRange){const Ne=this.latRange;I=a.O(Ne[1])*this.worldSize,z=a.O(Ne[0])*this.worldSize,u=z-I<re.y?re.y/(z-I):0}if(this.lngRange){const Ne=this.lngRange;W=a.b0(a.N(Ne[0])*this.worldSize,0,this.worldSize),Q=a.b0(a.N(Ne[1])*this.worldSize,0,this.worldSize),Q<W&&(Q+=this.worldSize),p=Q-W<re.x?re.x/(Q-W):0}const pe=this.point,Ie=Math.max(p||0,u||0);if(Ie)return this.center=this.unproject(new a.P(p?(Q+W)/2:pe.x,u?(z+I)/2:pe.y)),this.zoom+=this.scaleZoom(Ie),this._unmodified=ue,void(this._constraining=!1);if(this.latRange){const Ne=pe.y,Re=re.y/2;Ne-Re<I&&(M=I+Re),Ne+Re>z&&(M=z-Re)}if(this.lngRange){const Ne=(W+Q)/2,Re=a.b0(pe.x,Ne-this.worldSize/2,Ne+this.worldSize/2),$e=re.x/2;Re-$e<W&&(_=W+$e),Re+$e>Q&&(_=Q-$e)}_===void 0&&M===void 0||(this.center=this.unproject(new a.P(_!==void 0?_:pe.x,M!==void 0?M:pe.y)).wrap()),this._unmodified=ue,this._constraining=!1}_calcMatrices(){if(!this.height)return;const u=this.centerOffset,p=this.point.x,_=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),z=Math.min(this.elevation,this.minElevationForCurrentTile),W=I-z*this._pixelPerMeter/Math.cos(this._pitch),Q=z<0?W:I,re=Math.PI/2+this._pitch,ue=this._fov*(.5+u.y/this.height),pe=Math.sin(ue)*Q/Math.sin(a.ac(Math.PI-re-ue,.01,Math.PI-.01)),Ie=this.getHorizon(),Ne=2*Math.atan(Ie/this.cameraToCenterDistance)*(.5+u.y/(2*Ie)),Re=Math.sin(Ne)*Q/Math.sin(a.ac(Math.PI-re-Ne,.01,Math.PI-.01)),$e=Math.min(pe,Re),Ge=1.01*(Math.cos(Math.PI/2-this._pitch)*$e+Q),ht=this.height/50;M=new Float64Array(16),a.b3(M,this._fov,this.width/this.height,ht,Ge),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,-_,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 Tt=this.width%2/2,Ze=this.height%2/2,Ct=Math.cos(this.angle),$t=Math.sin(this.angle),Dt=p-Math.round(p)+Ct*Tt+$t*Ze,tn=_-Math.round(_)+Ct*Ze+$t*Tt,dn=new Float64Array(M);if(a.H(dn,dn,[Dt>.5?Dt-1:Dt,tn>.5?tn-1:tn,0]),this.alignedProjMatrix=dn,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 _=p.x,M=p.y,I=p.x,z=p.y;for(const W of u)_=Math.min(_,W.x),M=Math.min(M,W.y),I=Math.max(I,W.x),z=Math.max(z,W.y);return[new a.P(_,M),new a.P(I,M),new a.P(I,z),new a.P(_,z),new a.P(_,M)]}}lngLatToCameraDepth(u,p){const _=this.locationCoordinate(u),M=[_.x*this.worldSize,_.y*this.worldSize,p,1];return a.af(M,M,this.projMatrix),M[2]/M[3]}}function Td(O,u){let p,_=!1,M=null,I=null;const z=()=>{M=null,_&&(O.apply(I,p),M=setTimeout(z,u),_=!1)};return(...W)=>(_=!0,I=this,p=W,M||z(),M)}class _u{constructor(u){this._getCurrentHash=()=>{const p=window.location.hash.replace("#","");if(this._hashName){let _;return p.split("&").map(M=>M.split("=")).forEach(M=>{M[0]===this._hashName&&(_=M)}),(_&&_[1]||"").split("/")}return p.split("/")},this._onHashChange=()=>{const p=this._getCurrentHash();if(p.length>=3&&!p.some(_=>isNaN(_))){const _=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:_,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=Td(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(),_=Math.round(100*this._map.getZoom())/100,M=Math.ceil((_*Math.LN2+Math.log(512/360/.5))/Math.LN10),I=Math.pow(10,M),z=Math.round(p.lng*I)/I,W=Math.round(p.lat*I)/I,Q=this._map.getBearing(),re=this._map.getPitch();let ue="";if(ue+=u?`/${z}/${W}/${_}`:`${_}/${W}/${z}`,(Q||re)&&(ue+="/"+Math.round(10*Q)/10),re&&(ue+=`/${Math.round(re)}`),this._hashName){const pe=this._hashName;let Ie=!1;const Ne=window.location.hash.slice(1).split("&").map(Re=>{const $e=Re.split("=")[0];return $e===pe?(Ie=!0,`${$e}=${ue}`):Re}).filter(Re=>Re);return Ie||Ne.push(`${pe}=${ue}`),`#${Ne.join("&")}`}return`#${ue}`}}const wt={linearity:.3,easing:a.b5(0,0,.3,1)},ln=a.e({deceleration:2500,maxSpeed:1400},wt),Wt=a.e({deceleration:20,maxSpeed:1400},wt),hr=a.e({deceleration:1e3,maxSpeed:360},wt),ai=a.e({deceleration:1e3,maxSpeed:90},wt);class ao{constructor(u){this._map=u,this.clear()}clear(){this._inertiaBuffer=[]}record(u){this._drainInertiaBuffer(),this._inertiaBuffer.push({time:B.now(),settings:u})}_drainInertiaBuffer(){const u=this._inertiaBuffer,p=B.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 _=this._inertiaBuffer[this._inertiaBuffer.length-1].time-this._inertiaBuffer[0].time,M={};if(p.pan.mag()){const I=yo(p.pan.mag(),_,a.e({},ln,u||{}));M.offset=p.pan.mult(I.amount/p.pan.mag()),M.center=this._map.transform.center,sa(M,I)}if(p.zoom){const I=yo(p.zoom,_,Wt);M.zoom=this._map.transform.zoom+I.amount,sa(M,I)}if(p.bearing){const I=yo(p.bearing,_,hr);M.bearing=this._map.transform.bearing+a.ac(I.amount,-179,179),sa(M,I)}if(p.pitch){const I=yo(p.pitch,_,ai);M.pitch=this._map.transform.pitch+I.amount,sa(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 sa(O,u){(!O.duration||O.duration<u.duration)&&(O.duration=u.duration,O.easing=u.easing)}function yo(O,u,p){const{maxSpeed:_,linearity:M,deceleration:I}=p,z=a.ac(O*M/(u/1e3),-_,_),W=Math.abs(z)/(I*M);return{easing:p.easing,duration:1e3*W,amount:z*(W/2)}}class _s extends a.k{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(u,p,_,M={}){const I=k.mousePos(p.getCanvas(),_),z=p.unproject(I);super(u,a.e({point:I,lngLat:z,originalEvent:_},M)),this._defaultPrevented=!1,this.target=p}}class qc extends a.k{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(u,p,_){const M=u==="touchend"?_.changedTouches:_.touches,I=k.touchPos(p.getCanvasContainer(),M),z=I.map(Q=>p.unproject(Q)),W=I.reduce((Q,re,ue,pe)=>Q.add(re.div(pe.length)),new a.P(0,0));super(u,{points:I,point:W,lngLats:z,lngLat:p.unproject(W),originalEvent:_}),this._defaultPrevented=!1}}class Cs extends a.k{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(u,p,_){super(u,{originalEvent:_}),this._defaultPrevented=!1}}class Kd{constructor(u,p){this._map=u,this._clickTolerance=p.clickTolerance}reset(){delete this._mousedownPos}wheel(u){return this._firePreventable(new Cs(u.type,this._map,u))}mousedown(u,p){return this._mousedownPos=p,this._firePreventable(new _s(u.type,this._map,u))}mouseup(u){this._map.fire(new _s(u.type,this._map,u))}click(u,p){this._mousedownPos&&this._mousedownPos.dist(p)>=this._clickTolerance||this._map.fire(new _s(u.type,this._map,u))}dblclick(u){return this._firePreventable(new _s(u.type,this._map,u))}mouseover(u){this._map.fire(new _s(u.type,this._map,u))}mouseout(u){this._map.fire(new _s(u.type,this._map,u))}touchstart(u){return this._firePreventable(new qc(u.type,this._map,u))}touchmove(u){this._map.fire(new qc(u.type,this._map,u))}touchend(u){this._map.fire(new qc(u.type,this._map,u))}touchcancel(u){this._map.fire(new qc(u.type,this._map,u))}_firePreventable(u){if(this._map.fire(u),u.defaultPrevented)return{}}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}}class Ps{constructor(u){this._map=u}reset(){this._delayContextMenu=!1,this._ignoreContextMenu=!0,delete this._contextMenuEvent}mousemove(u){this._map.fire(new _s(u.type,this._map,u))}mousedown(){this._delayContextMenu=!0,this._ignoreContextMenu=!1}mouseup(){this._delayContextMenu=!1,this._contextMenuEvent&&(this._map.fire(new _s("contextmenu",this._map,this._contextMenuEvent)),delete this._contextMenuEvent)}contextmenu(u){this._delayContextMenu?this._contextMenuEvent=u:this._ignoreContextMenu||this._map.fire(new _s(u.type,this._map,u)),this._map.listens("contextmenu")&&u.preventDefault()}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}}class la{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 Cu{constructor(u,p){this._map=u,this._tr=new la(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&&(k.disableDrag(),this._startPos=this._lastPos=p,this._active=!0)}mousemoveWindow(u,p){if(!this._active)return;const _=p;if(this._lastPos.equals(_)||!this._box&&_.dist(this._startPos)<this._clickTolerance)return;const M=this._startPos;this._lastPos=_,this._box||(this._box=k.create("div","maplibregl-boxzoom",this._container),this._container.classList.add("maplibregl-crosshair"),this._fireEvent("boxzoomstart",u));const I=Math.min(M.x,_.x),z=Math.max(M.x,_.x),W=Math.min(M.y,_.y),Q=Math.max(M.y,_.y);k.setTransform(this._box,`translate(${I}px,${W}px)`),this._box.style.width=z-I+"px",this._box.style.height=Q-W+"px"}mouseupWindow(u,p){if(!this._active||u.button!==0)return;const _=this._startPos,M=p;if(this.reset(),k.suppressClick(),_.x!==M.x||_.y!==M.y)return this._map.fire(new a.k("boxzoomend",{originalEvent:u})),{cameraAnimation:I=>I.fitScreenCoordinates(_,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&&(k.remove(this._box),this._box=null),k.enableDrag(),delete this._startPos,delete this._lastPos}_fireEvent(u,p){return this._map.fire(new a.k(u,{originalEvent:p}))}}function Fs(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 _=0;_<O.length;_++)p[O[_].identifier]=u[_];return p}class to{constructor(u){this.reset(),this.numTouches=u.numTouches}reset(){delete this.centroid,delete this.startTime,delete this.touches,this.aborted=!1}touchstart(u,p,_){(this.centroid||_.length>this.numTouches)&&(this.aborted=!0),this.aborted||(this.startTime===void 0&&(this.startTime=u.timeStamp),_.length===this.numTouches&&(this.centroid=function(M){const I=new a.P(0,0);for(const z of M)I._add(z);return I.div(M.length)}(p),this.touches=Fs(_,p)))}touchmove(u,p,_){if(this.aborted||!this.centroid)return;const M=Fs(_,p);for(const I in this.touches){const z=M[I];(!z||z.dist(this.touches[I])>30)&&(this.aborted=!0)}}touchend(u,p,_){if((!this.centroid||u.timeStamp-this.startTime>500)&&(this.aborted=!0),_.length===0){const M=!this.aborted&&this.centroid;if(this.reset(),M)return M}}}class xh{constructor(u){this.singleTap=new to(u),this.numTaps=u.numTaps,this.reset()}reset(){this.lastTime=1/0,delete this.lastTap,this.count=0,this.singleTap.reset()}touchstart(u,p,_){this.singleTap.touchstart(u,p,_)}touchmove(u,p,_){this.singleTap.touchmove(u,p,_)}touchend(u,p,_){const M=this.singleTap.touchend(u,p,_);if(M){const I=u.timeStamp-this.lastTime<500,z=!this.lastTap||this.lastTap.dist(M)<30;if(I&&z||this.reset(),this.count++,this.lastTime=u.timeStamp,this.lastTap=M,this.count===this.numTaps)return this.reset(),M}}}class wh{constructor(u){this._tr=new la(u),this._zoomIn=new xh({numTouches:1,numTaps:2}),this._zoomOut=new xh({numTouches:2,numTaps:1}),this.reset()}reset(){this._active=!1,this._zoomIn.reset(),this._zoomOut.reset()}touchstart(u,p,_){this._zoomIn.touchstart(u,p,_),this._zoomOut.touchstart(u,p,_)}touchmove(u,p,_){this._zoomIn.touchmove(u,p,_),this._zoomOut.touchmove(u,p,_)}touchend(u,p,_){const M=this._zoomIn.touchend(u,p,_),I=this._zoomOut.touchend(u,p,_),z=this._tr;return M?(this._active=!0,u.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:W=>W.easeTo({duration:300,zoom:z.zoom+1,around:z.unproject(M)},{originalEvent:u})}):I?(this._active=!0,u.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:W=>W.easeTo({duration:300,zoom:z.zoom-1,around:z.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 wl{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 _=this._lastPoint;if(!_)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(_)<this._clickTolerance?void 0:(this._moved=!0,this._lastPoint=M,this._move(_,M))}dragEnd(u){this.isEnabled()&&this._lastPoint&&this._moveStateManager.isValidEndEvent(u)&&(this._moved&&k.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 DA={0:1,2:2};class Da{constructor(u){this._correctEvent=u.checkCorrectEvent}startMove(u){const p=k.mouseButton(u);this._eventButton=p}endMove(u){delete this._eventButton}isValidStartEvent(u){return this._correctEvent(u)}isValidMoveEvent(u){return!function(p,_){const M=DA[_];return p.buttons===void 0||(p.buttons&M)!==M}(u,this._eventButton)}isValidEndEvent(u){return k.mouseButton(u)===this._eventButton}}class Vs{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 Nn=O=>{O.mousedown=O.dragStart,O.mousemoveWindow=O.dragMove,O.mouseup=O.dragEnd,O.contextmenu=function(u){u.preventDefault()}},zl=({enable:O,clickTolerance:u,bearingDegreesPerPixelMoved:p=.8})=>{const _=new Da({checkCorrectEvent:M=>k.mouseButton(M)===0&&M.ctrlKey||k.mouseButton(M)===2});return new wl({clickTolerance:u,move:(M,I)=>({bearingDelta:(I.x-M.x)*p}),moveStateManager:_,enable:O,assignEvents:Nn})},hA=({enable:O,clickTolerance:u,pitchDegreesPerPixelMoved:p=-.5})=>{const _=new Da({checkCorrectEvent:M=>k.mouseButton(M)===0&&M.ctrlKey||k.mouseButton(M)===2});return new wl({clickTolerance:u,move:(M,I)=>({pitchDelta:(I.y-M.y)*p}),moveStateManager:_,enable:O,assignEvents:Nn})};class dc{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,_){return this._calculateTransform(u,p,_)}touchmove(u,p,_){if(this._active&&!(_.length<this.minTouchs()))return u.preventDefault(),this._calculateTransform(u,p,_)}touchend(u,p,_){this._calculateTransform(u,p,_),this._active&&_.length<this.minTouchs()&&this.reset()}touchcancel(){this.reset()}_calculateTransform(u,p,_){_.length>0&&(this._active=!0);const M=Fs(_,p),I=new a.P(0,0),z=new a.P(0,0);let W=0;for(const re in M){const ue=M[re],pe=this._touches[re];pe&&(I._add(ue),z._add(ue.sub(pe)),W++,M[re]=ue)}if(this._touches=M,W<this.minTouchs()||!z.mag())return;const Q=z.div(W);return this._sum._add(Q),this._sum.mag()<this._clickTolerance?void 0:{around:I.div(W),panDelta:Q}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class bu{constructor(){this.reset()}reset(){this._active=!1,delete this._firstTwoTouches}touchstart(u,p,_){this._firstTwoTouches||_.length<2||(this._firstTwoTouches=[_[0].identifier,_[1].identifier],this._start([p[0],p[1]]))}touchmove(u,p,_){if(!this._firstTwoTouches)return;u.preventDefault();const[M,I]=this._firstTwoTouches,z=$n(_,p,M),W=$n(_,p,I);if(!z||!W)return;const Q=this._aroundCenter?null:z.add(W).div(2);return this._move([z,W],Q,u)}touchend(u,p,_){if(!this._firstTwoTouches)return;const[M,I]=this._firstTwoTouches,z=$n(_,p,M),W=$n(_,p,I);z&&W||(this._active&&k.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 $n(O,u,p){for(let _=0;_<O.length;_++)if(O[_].identifier===p)return u[_]}function hc(O,u){return Math.log(O/u)/Math.LN2}class LA extends bu{reset(){super.reset(),delete this._distance,delete this._startDistance}_start(u){this._startDistance=this._distance=u[0].dist(u[1])}_move(u,p){const _=this._distance;if(this._distance=u[0].dist(u[1]),this._active||!(Math.abs(hc(this._distance,this._startDistance))<.1))return this._active=!0,{zoomDelta:hc(this._distance,_),pinchAround:p}}}function If(O,u){return 180*O.angleWith(u)/Math.PI}class Nu extends bu{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,_){const M=this._vector;if(this._vector=u[0].sub(u[1]),this._active||!this._isBelowThreshold(this._vector))return this._active=!0,{bearingDelta:If(this._vector,M),pinchAround:p}}_isBelowThreshold(u){this._minDiameter=Math.min(this._minDiameter,u.mag());const p=25/(Math.PI*this._minDiameter)*360,_=If(u,this._startVector);return Math.abs(_)<p}}function xu(O){return Math.abs(O.y)>Math.abs(O.x)}class UA extends bu{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,_){super.touchstart(u,p,_),this._currentTouchCount=_.length}_start(u){this._lastPoints=u,xu(u[0].sub(u[1]))&&(this._valid=!1)}_move(u,p,_){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,_.timeStamp),this._valid?(this._lastPoints=u,this._active=!0,{pitchDelta:(M.y+I.y)/2*-.5}):void 0}gestureBeginsVertically(u,p,_){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=_),_-this._firstMove<100&&void 0;const z=u.y>0==p.y>0;return xu(u)&&xu(p)&&z}}const Tf={panStep:100,bearingStep:15,pitchStep:10};class fc{constructor(u){this._tr=new la(u);const p=Tf;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,_=0,M=0,I=0,z=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?_=-1:(u.preventDefault(),I=-1);break;case 39:u.shiftKey?_=1:(u.preventDefault(),I=1);break;case 38:u.shiftKey?M=1:(u.preventDefault(),z=-1);break;case 40:u.shiftKey?M=-1:(u.preventDefault(),z=1);break;default:return}return this._rotationDisabled&&(_=0,M=0),{cameraAnimation:W=>{const Q=this._tr;W.easeTo({duration:300,easeId:"keyboardHandler",easing:Gu,zoom:p?Math.round(Q.zoom)+p*(u.shiftKey?2:1):Q.zoom,bearing:Q.bearing+_*this._bearingStep,pitch:Q.pitch+M*this._pitchStep,offset:[-I*this._panStep,-z*this._panStep],center:Q.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 Gu(O){return O*(2-O)}const So=4.000244140625;class wu{constructor(u,p){this._onTimeout=_=>{this._type="wheel",this._delta-=this._lastValue,this._active||this._start(_)},this._map=u,this._tr=new la(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 _=B.now(),M=_-(this._lastWheelEventTime||0);this._lastWheelEventTime=_,p!==0&&p%So==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=k.mousePos(this._map.getCanvas(),u),_=this._tr;this._around=p.y>_.transform.height/2-_.transform.getHorizon()?a.M.convert(this._aroundCenter?_.center:_.unproject(p)):a.M.convert(_.center),this._aroundPoint=_.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 W=this._type==="wheel"&&Math.abs(this._delta)>So?this._wheelZoomRate:this._defaultZoomRate;let Q=2/(1+Math.exp(-Math.abs(this._delta*W)));this._delta<0&&Q!==0&&(Q=1/Q);const re=typeof this._targetZoom=="number"?u.zoomScale(this._targetZoom):u.scale;this._targetZoom=Math.min(u.maxZoom,Math.max(u.minZoom,u.scaleZoom(re*Q))),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,_=this._startZoom,M=this._easing;let I,z=!1;if(this._type==="wheel"&&_&&M){const W=Math.min((B.now()-this._lastWheelEventTime)/200,1),Q=M(W);I=a.z.number(_,p,Q),W<1?this._frameId||(this._frameId=!0):z=!0}else I=p,z=!0;return this._active=!0,z&&(this._active=!1,this._finishTimeout=setTimeout(()=>{this._zooming=!1,this._triggerRenderFrame(),delete this._targetZoom,delete this._finishTimeout},200)),{noInertia:!0,needsRenderFrame:!z,zoomDelta:I-u.zoom,around:this._aroundPoint,originalEvent:this._lastWheelEvent}}_smoothOutEasing(u){let p=a.b6;if(this._prevEase){const _=this._prevEase,M=(B.now()-_.start)/_.duration,I=_.easing(M+.01)-_.easing(M),z=.27/Math.sqrt(I*I+1e-4)*.01,W=Math.sqrt(.0729-z*z);p=a.b5(z,W,.25,1)}return this._prevEase={start:B.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 Hc{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 Tp{constructor(u){this._tr=new la(u),this.reset()}reset(){this._active=!1}dblclick(u,p){return u.preventDefault(),{cameraAnimation:_=>{_.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 Kf{constructor(){this._tap=new xh({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,_){if(!this._swipePoint)if(this._tapTime){const M=p[0],I=u.timeStamp-this._tapTime<500,z=this._tapPoint.dist(M)<30;I&&z?_.length>0&&(this._swipePoint=M,this._swipeTouch=_[0].identifier):this.reset()}else this._tap.touchstart(u,p,_)}touchmove(u,p,_){if(this._tapTime){if(this._swipePoint){if(_[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,_)}touchend(u,p,_){if(this._tapTime)this._swipePoint&&_.length===0&&this.reset();else{const M=this._tap.touchend(u,p,_);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 Pd{constructor(u,p,_){this._el=u,this._mousePan=p,this._touchPan=_}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 Mh{constructor(u,p,_){this._pitchWithRotate=u.pitchWithRotate,this._mouseRotate=p,this._mousePitch=_}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 so{constructor(u,p,_,M){this._el=u,this._touchZoom=p,this._touchRotate=_,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 ua{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=k.create("div","maplibregl-cooperative-gesture-screen",u);let p=this._map._getUIString("CooperativeGesturesHandler.WindowsHelpText");this._bypassKey==="metaKey"&&(p=this._map._getUIString("CooperativeGesturesHandler.MacHelpText"));const _=this._map._getUIString("CooperativeGesturesHandler.MobileHelpText"),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=_,this._container.appendChild(I),this._container.setAttribute("aria-hidden","true")}_destoryUI(){this._container&&(k.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 vr=O=>O.zoom||O.drag||O.pitch||O.rotate;class Tr extends a.k{}function RA(O){return O.panDelta&&O.panDelta.mag()||O.zoomDelta||O.bearingDelta||O.pitchDelta}class pc{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 z=M.type==="renderFrame"?void 0:M,W={needsRenderFrame:!1},Q={},re={},ue=M.touches,pe=ue?this._getMapTouches(ue):void 0,Ie=pe?k.touchPos(this._map.getCanvas(),pe):k.mousePos(this._map.getCanvas(),M);for(const{handlerName:$e,handler:Ge,allowed:ht}of this._handlers){if(!Ge.isEnabled())continue;let Tt;this._blockedByActive(re,ht,$e)?Ge.reset():Ge[I||M.type]&&(Tt=Ge[I||M.type](M,Ie,pe),this.mergeHandlerResult(W,Q,Tt,$e,z),Tt&&Tt.needsRenderFrame&&this._triggerRenderFrame()),(Tt||Ge.isActive())&&(re[$e]=Ge)}const Ne={};for(const $e in this._previousActiveHandlers)re[$e]||(Ne[$e]=z);this._previousActiveHandlers=re,(Object.keys(Ne).length||RA(W))&&(this._changes.push([W,Q,Ne]),this._triggerRenderFrame()),(Object.keys(re).length||RA(W))&&this._map._stop(!0),this._updatingCamera=!1;const{cameraAnimation:Re}=W;Re&&(this._inertia.clear(),this._fireEvents({},{},!0),this._changes=[],Re(this._map))},this._map=u,this._el=this._map.getCanvasContainer(),this._handlers=[],this._handlersById={},this._changes=[],this._inertia=new ao(u),this._bearingSnap=p.bearingSnap,this._previousActiveHandlers={},this._eventsInProgress={},this._addDefaultHandlers(p);const _=this._el;this._listeners=[[_,"touchstart",{passive:!0}],[_,"touchmove",{passive:!1}],[_,"touchend",void 0],[_,"touchcancel",void 0],[_,"mousedown",void 0],[_,"mousemove",void 0],[_,"mouseup",void 0],[document,"mousemove",{capture:!0}],[document,"mouseup",void 0],[_,"mouseover",void 0],[_,"mouseout",void 0],[_,"dblclick",void 0],[_,"click",void 0],[_,"keydown",{capture:!1}],[_,"keyup",void 0],[_,"wheel",{passive:!1}],[_,"contextmenu",void 0],[window,"blur",void 0]];for(const[M,I,z]of this._listeners)k.addEventListener(M,I,M===document?this.handleWindowEvent:this.handleEvent,z)}destroy(){for(const[u,p,_]of this._listeners)k.removeEventListener(u,p,u===document?this.handleWindowEvent:this.handleEvent,_)}_addDefaultHandlers(u){const p=this._map,_=p.getCanvasContainer();this._add("mapEvent",new Kd(p,u));const M=p.boxZoom=new Cu(p,u);this._add("boxZoom",M),u.interactive&&u.boxZoom&&M.enable();const I=p.cooperativeGestures=new ua(p,u.cooperativeGestures);this._add("cooperativeGestures",I),u.cooperativeGestures&&I.enable();const z=new wh(p),W=new Tp(p);p.doubleClickZoom=new Hc(W,z),this._add("tapZoom",z),this._add("clickZoom",W),u.interactive&&u.doubleClickZoom&&p.doubleClickZoom.enable();const Q=new Kf;this._add("tapDragZoom",Q);const re=p.touchPitch=new UA(p);this._add("touchPitch",re),u.interactive&&u.touchPitch&&p.touchPitch.enable(u.touchPitch);const ue=zl(u),pe=hA(u);p.dragRotate=new Mh(u,ue,pe),this._add("mouseRotate",ue,["mousePitch"]),this._add("mousePitch",pe,["mouseRotate"]),u.interactive&&u.dragRotate&&p.dragRotate.enable();const Ie=(({enable:Tt,clickTolerance:Ze})=>{const Ct=new Da({checkCorrectEvent:$t=>k.mouseButton($t)===0&&!$t.ctrlKey});return new wl({clickTolerance:Ze,move:($t,Dt)=>({around:Dt,panDelta:Dt.sub($t)}),activateOnStart:!0,moveStateManager:Ct,enable:Tt,assignEvents:Nn})})(u),Ne=new dc(u,p);p.dragPan=new Pd(_,Ie,Ne),this._add("mousePan",Ie),this._add("touchPan",Ne,["touchZoom","touchRotate"]),u.interactive&&u.dragPan&&p.dragPan.enable(u.dragPan);const Re=new Nu,$e=new LA;p.touchZoomRotate=new so(_,$e,Re,Q),this._add("touchRotate",Re,["touchPan","touchZoom"]),this._add("touchZoom",$e,["touchPan","touchRotate"]),u.interactive&&u.touchZoomRotate&&p.touchZoomRotate.enable(u.touchZoomRotate);const Ge=p.scrollZoom=new wu(p,()=>this._triggerRenderFrame());this._add("scrollZoom",Ge,["mousePan"]),u.interactive&&u.scrollZoom&&p.scrollZoom.enable(u.scrollZoom);const ht=p.keyboard=new fc(p);this._add("keyboard",ht),u.interactive&&u.keyboard&&p.keyboard.enable(),this._add("blockableMapEvent",new Ps(p))}_add(u,p,_){this._handlers.push({handlerName:u,handler:p,allowed:_}),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!!vr(this._eventsInProgress)||this.isZooming()}_blockedByActive(u,p,_){for(const M in u)if(M!==_&&(!p||p.indexOf(M)<0))return!0;return!1}_getMapTouches(u){const p=[];for(const _ of u)this._el.contains(_.target)&&p.push(_);return p}mergeHandlerResult(u,p,_,M,I){if(!_)return;a.e(u,_);const z={handlerName:M,originalEvent:_.originalEvent||I};_.zoomDelta!==void 0&&(p.zoom=z),_.panDelta!==void 0&&(p.drag=z),_.pitchDelta!==void 0&&(p.pitch=z),_.bearingDelta!==void 0&&(p.rotate=z)}_applyChanges(){const u={},p={},_={};for(const[M,I,z]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(_,z);this._updateMapTransform(u,p,_),this._changes=[]}_updateMapTransform(u,p,_){const M=this._map,I=M._getTransformForUpdate(),z=M.terrain;if(!(RA(u)||z&&this._terrainMovement))return this._fireEvents(p,_,!0);let{panDelta:W,zoomDelta:Q,bearingDelta:re,pitchDelta:ue,around:pe,pinchAround:Ie}=u;Ie!==void 0&&(pe=Ie),M._stop(!0),pe=pe||M.transform.centerPoint;const Ne=I.pointLocation(W?pe.sub(W):pe);re&&(I.bearing+=re),ue&&(I.pitch+=ue),Q&&(I.zoom+=Q),z?this._terrainMovement||!p.drag&&!p.zoom?p.drag&&this._terrainMovement?I.center=I.pointLocation(I.centerPoint.sub(W)):I.setLocationAtPoint(Ne,pe):(this._terrainMovement=!0,this._map._elevationFreeze=!0,I.setLocationAtPoint(Ne,pe),this._map.once("moveend",()=>{this._map._elevationFreeze=!1,this._terrainMovement=!1,I.recalculateZoom(M.terrain)})):I.setLocationAtPoint(Ne,pe),M._applyUpdatedTransform(I),this._map._update(),u.noInertia||this._inertia.record(u),this._fireEvents(p,_,!0)}_fireEvents(u,p,_){const M=vr(this._eventsInProgress),I=vr(u),z={};for(const ue in u){const{originalEvent:pe}=u[ue];this._eventsInProgress[ue]||(z[`${ue}start`]=pe),this._eventsInProgress[ue]=u[ue]}!M&&I&&this._fireEvent("movestart",I.originalEvent);for(const ue in z)this._fireEvent(ue,z[ue]);I&&this._fireEvent("move",I.originalEvent);for(const ue in u){const{originalEvent:pe}=u[ue];this._fireEvent(ue,pe)}const W={};let Q;for(const ue in this._eventsInProgress){const{handlerName:pe,originalEvent:Ie}=this._eventsInProgress[ue];this._handlersById[pe].isActive()||(delete this._eventsInProgress[ue],Q=p[pe]||Ie,W[`${ue}end`]=Q)}for(const ue in W)this._fireEvent(ue,W[ue]);const re=vr(this._eventsInProgress);if(_&&(M||I)&&!re){this._updatingCamera=!0;const ue=this._inertia._onMoveEnd(this._map.dragPan._inertiaOptions),pe=Ie=>Ie!==0&&-this._bearingSnap<Ie&&Ie<this._bearingSnap;!ue||!ue.essential&&B.prefersReducedMotion?(this._map.fire(new a.k("moveend",{originalEvent:Q})),pe(this._map.getBearing())&&this._map.resetNorth()):(pe(ue.bearing||this._map.getBearing())&&(ue.bearing=0),ue.freezeElevation=!0,this._map.easeTo(ue,{originalEvent:Q})),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 Tr("renderFrame",{timeStamp:u})),this._applyChanges()})}_triggerRenderFrame(){this._frameId===void 0&&(this._frameId=this._requestFrame())}}class Vc extends a.E{constructor(u,p){super(),this._renderFrameCallback=()=>{const _=Math.min((B.now()-this._easeStart)/this._easeOptions.duration,1);this._onEaseFrame(this._easeOptions.easing(_)),_<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,_){return u=a.P.convert(u).mult(-1),this.panTo(this.transform.center,a.e({offset:u},p),_)}panTo(u,p,_){return this.easeTo(a.e({center:u},p),_)}getZoom(){return this.transform.zoom}setZoom(u,p){return this.jumpTo({zoom:u},p),this}zoomTo(u,p,_){return this.easeTo(a.e({zoom:u},p),_)}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,_){return this.easeTo(a.e({bearing:u},p),_)}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=Ut.convert(u);const _=p&&p.bearing||0;return this._cameraForBoxAndBearing(u.getNorthWest(),u.getSouthEast(),_,p)}_cameraForBoxAndBearing(u,p,_,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 tr=M.padding;M.padding={top:tr,bottom:tr,right:tr,left:tr}}M.padding=a.e(I,M.padding);const z=this.transform,W=z.padding,Q=new Ut(u,p),re=z.project(Q.getNorthWest()),ue=z.project(Q.getNorthEast()),pe=z.project(Q.getSouthEast()),Ie=z.project(Q.getSouthWest()),Ne=a.b7(-_),Re=re.rotate(Ne),$e=ue.rotate(Ne),Ge=pe.rotate(Ne),ht=Ie.rotate(Ne),Tt=new a.P(Math.max(Re.x,$e.x,ht.x,Ge.x),Math.max(Re.y,$e.y,ht.y,Ge.y)),Ze=new a.P(Math.min(Re.x,$e.x,ht.x,Ge.x),Math.min(Re.y,$e.y,ht.y,Ge.y)),Ct=Tt.sub(Ze),$t=(z.width-(W.left+W.right+M.padding.left+M.padding.right))/Ct.x,Dt=(z.height-(W.top+W.bottom+M.padding.top+M.padding.bottom))/Ct.y;if(Dt<0||$t<0)return void a.w("Map cannot fit within canvas with the given bounds, padding, and/or offset.");const tn=Math.min(z.scaleZoom(z.scale*Math.min($t,Dt)),M.maxZoom),dn=a.P.convert(M.offset),An=new a.P((M.padding.left-M.padding.right)/2,(M.padding.top-M.padding.bottom)/2).rotate(a.b7(_)),bn=dn.add(An).mult(z.scale/z.zoomScale(tn));return{center:z.unproject(re.add(pe).div(2).sub(bn)),zoom:tn,bearing:_}}fitBounds(u,p,_){return this._fitInternal(this.cameraForBounds(u,p),p,_)}fitScreenCoordinates(u,p,_,M,I){return this._fitInternal(this._cameraForBoxAndBearing(this.transform.pointLocation(a.P.convert(u)),this.transform.pointLocation(a.P.convert(p)),_,M),M,I)}_fitInternal(u,p,_){return u?(delete(p=a.e(u,p)).padding,p.linear?this.easeTo(p,_):this.flyTo(p,_)):this}jumpTo(u,p){this.stop();const _=this._getTransformForUpdate();let M=!1,I=!1,z=!1;return"zoom"in u&&_.zoom!==+u.zoom&&(M=!0,_.zoom=+u.zoom),u.center!==void 0&&(_.center=a.M.convert(u.center)),"bearing"in u&&_.bearing!==+u.bearing&&(I=!0,_.bearing=+u.bearing),"pitch"in u&&_.pitch!==+u.pitch&&(z=!0,_.pitch=+u.pitch),u.padding==null||_.isPaddingEqual(u.padding)||(_.padding=u.padding),this._applyUpdatedTransform(_),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)),z&&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,_,M=0){const I=a.Y.fromLngLat(u,p),z=a.Y.fromLngLat(_,M),W=z.x-I.x,Q=z.y-I.y,re=z.z-I.z,ue=Math.hypot(W,Q,re);if(ue===0)throw new Error("Can't calculate camera options with same From and To");const pe=Math.hypot(W,Q),Ie=this.transform.scaleZoom(this.transform.cameraToCenterDistance/ue/this.transform.tileSize),Ne=180*Math.atan2(W,-Q)/Math.PI;let Re=180*Math.acos(pe/ue)/Math.PI;return Re=re<0?90-Re:90+Re,{center:z.toLngLat(),zoom:Ie,pitch:Re,bearing:Ne}}easeTo(u,p){this._stop(!1,u.easeId),((u=a.e({offset:[0,0],duration:500,easing:a.b6},u)).animate===!1||!u.essential&&B.prefersReducedMotion)&&(u.duration=0);const _=this._getTransformForUpdate(),M=this.getZoom(),I=this.getBearing(),z=this.getPitch(),W=this.getPadding(),Q="zoom"in u?+u.zoom:M,re="bearing"in u?this._normalizeBearing(u.bearing,I):I,ue="pitch"in u?+u.pitch:z,pe="padding"in u?u.padding:_.padding,Ie=a.P.convert(u.offset);let Ne=_.centerPoint.add(Ie);const Re=_.pointLocation(Ne),$e=a.M.convert(u.center||Re);this._normalizeCenter($e);const Ge=_.project(Re),ht=_.project($e).sub(Ge),Tt=_.zoomScale(Q-M);let Ze,Ct;u.around&&(Ze=a.M.convert(u.around),Ct=_.locationPoint(Ze));const $t={moving:this._moving,zooming:this._zooming,rotating:this._rotating,pitching:this._pitching};return this._zooming=this._zooming||Q!==M,this._rotating=this._rotating||I!==re,this._pitching=this._pitching||ue!==z,this._padding=!_.isPaddingEqual(pe),this._easeId=u.easeId,this._prepareEase(p,u.noMoveStart,$t),this.terrain&&this._prepareElevation($e),this._ease(Dt=>{if(this._zooming&&(_.zoom=a.z.number(M,Q,Dt)),this._rotating&&(_.bearing=a.z.number(I,re,Dt)),this._pitching&&(_.pitch=a.z.number(z,ue,Dt)),this._padding&&(_.interpolatePadding(W,pe,Dt),Ne=_.centerPoint.add(Ie)),this.terrain&&!u.freezeElevation&&this._updateElevation(Dt),Ze)_.setLocationAtPoint(Ze,Ct);else{const tn=_.zoomScale(_.zoom-M),dn=Q>M?Math.min(2,Tt):Math.max(.5,Tt),An=Math.pow(dn,1-Dt),bn=_.unproject(Ge.add(ht.mult(Dt*An)).mult(tn));_.setLocationAtPoint(_.renderWorldCopies?bn.wrap():bn,Ne)}this._applyUpdatedTransform(_),this._fireMoveEvents(p)},Dt=>{this.terrain&&this._finalizeElevation(),this._afterEase(p,Dt)},u),this}_prepareEase(u,p,_={}){this._moving=!0,p||_.moving||this.fire(new a.k("movestart",u)),this._zooming&&!_.zooming&&this.fire(new a.k("zoomstart",u)),this._rotating&&!_.rotating&&this.fire(new a.k("rotatestart",u)),this._pitching&&!_.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 _=this._elevationTarget-this._elevationStart;this._elevationStart+=u*(_-(p-(_*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:_,zoom:M,pitch:I,bearing:z,elevation:W}=this.transformCameraUpdate(p);_&&(p.center=_),M!==void 0&&(p.zoom=M),I!==void 0&&(p.pitch=I),z!==void 0&&(p.bearing=z),W!==void 0&&(p.elevation=W),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 _=this._zooming,M=this._rotating,I=this._pitching;this._moving=!1,this._zooming=!1,this._rotating=!1,this._pitching=!1,this._padding=!1,_&&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&&B.prefersReducedMotion){const Jn=a.L(u,["center","zoom","bearing","pitch","around"]);return this.jumpTo(Jn,p)}this.stop(),u=a.e({offset:[0,0],speed:1.2,curve:1.42,easing:a.b6},u);const _=this._getTransformForUpdate(),M=this.getZoom(),I=this.getBearing(),z=this.getPitch(),W=this.getPadding(),Q="zoom"in u?a.ac(+u.zoom,_.minZoom,_.maxZoom):M,re="bearing"in u?this._normalizeBearing(u.bearing,I):I,ue="pitch"in u?+u.pitch:z,pe="padding"in u?u.padding:_.padding,Ie=_.zoomScale(Q-M),Ne=a.P.convert(u.offset);let Re=_.centerPoint.add(Ne);const $e=_.pointLocation(Re),Ge=a.M.convert(u.center||$e);this._normalizeCenter(Ge);const ht=_.project($e),Tt=_.project(Ge).sub(ht);let Ze=u.curve;const Ct=Math.max(_.width,_.height),$t=Ct/Ie,Dt=Tt.mag();if("minZoom"in u){const Jn=a.ac(Math.min(u.minZoom,M,Q),_.minZoom,_.maxZoom),Ni=Ct/_.zoomScale(Jn-M);Ze=Math.sqrt(Ni/Dt*2)}const tn=Ze*Ze;function dn(Jn){const Ni=($t*$t-Ct*Ct+(Jn?-1:1)*tn*tn*Dt*Dt)/(2*(Jn?$t:Ct)*tn*Dt);return Math.log(Math.sqrt(Ni*Ni+1)-Ni)}function An(Jn){return(Math.exp(Jn)-Math.exp(-Jn))/2}function bn(Jn){return(Math.exp(Jn)+Math.exp(-Jn))/2}const tr=dn(!1);let Pr=function(Jn){return bn(tr)/bn(tr+Ze*Jn)},Tn=function(Jn){return Ct*((bn(tr)*(An(Ni=tr+Ze*Jn)/bn(Ni))-An(tr))/tn)/Dt;var Ni},xr=(dn(!0)-tr)/Ze;if(Math.abs(Dt)<1e-6||!isFinite(xr)){if(Math.abs(Ct-$t)<1e-6)return this.easeTo(u,p);const Jn=$t<Ct?-1:1;xr=Math.abs(Math.log($t/Ct))/Ze,Tn=function(){return 0},Pr=function(Ni){return Math.exp(Jn*Ze*Ni)}}return u.duration="duration"in u?+u.duration:1e3*xr/("screenSpeed"in u?+u.screenSpeed/Ze:+u.speed),u.maxDuration&&u.duration>u.maxDuration&&(u.duration=0),this._zooming=!0,this._rotating=I!==re,this._pitching=ue!==z,this._padding=!_.isPaddingEqual(pe),this._prepareEase(p,!1),this.terrain&&this._prepareElevation(Ge),this._ease(Jn=>{const Ni=Jn*xr,ki=1/Pr(Ni);_.zoom=Jn===1?Q:M+_.scaleZoom(ki),this._rotating&&(_.bearing=a.z.number(I,re,Jn)),this._pitching&&(_.pitch=a.z.number(z,ue,Jn)),this._padding&&(_.interpolatePadding(W,pe,Jn),Re=_.centerPoint.add(Ne)),this.terrain&&!u.freezeElevation&&this._updateElevation(Jn);const ri=Jn===1?Ge:_.unproject(ht.add(Tt.mult(Tn(Ni))).mult(ki));_.setLocationAtPoint(_.renderWorldCopies?ri.wrap():ri,Re),this._applyUpdatedTransform(_),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 _=this._onEaseEnd;delete this._onEaseEnd,_.call(this,p)}if(!u){const _=this.handlers;_&&_.stop(!1)}return this}_ease(u,p,_){_.animate===!1||_.duration===0?(u(1),p()):(this._easeStart=B.now(),this._easeOptions=_,this._onEaseFrame=u,this._onEaseEnd=p,this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback))}_normalizeBearing(u,p){u=a.b0(u,-180,180);const _=Math.abs(u-p);return Math.abs(u-360-p)<_&&(u-=360),Math.abs(u+360-p)<_&&(u+=360),u}_normalizeCenter(u){const p=this.transform;if(!p.renderWorldCopies||p.lngRange)return;const _=u.lng-p.center.lng;u.lng+=_>180?-360:_<-180?360:0}queryTerrainElevation(u){return this.terrain?this.terrain.getElevationForLngLatZoom(a.M.convert(u),this.transform.tileZoom)-this.transform.elevation:null}}const Jo={compact:!0,customAttribution:'<a href="https://maplibre.org/" target="_blank">MapLibre</a>'};class fA{constructor(u=Jo){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.compact,this._container=k.create("details","maplibregl-ctrl maplibregl-ctrl-attrib"),this._compactButton=k.create("summary","maplibregl-ctrl-attrib-button",this._container),this._compactButton.addEventListener("click",this._toggleAttribution),this._setElementTitle(this._compactButton,"ToggleAttribution"),this._innerContainer=k.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(){k.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 _=this._map._getUIString(`AttributionControl.${p}`);u.title=_,u.setAttribute("aria-label",_)}_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 z=I.getSource();z.attribution&&u.indexOf(z.attribution)<0&&u.push(z.attribution)}}u=u.filter(M=>String(M).trim()),u.sort((M,I)=>M.length-I.length),u=u.filter((M,I)=>{for(let z=I+1;z<u.length;z++)if(u[z].indexOf(M)>=0)return!1;return!0});const _=u.join(" | ");_!==this._attribHTML&&(this._attribHTML=_,u.length?(this._innerContainer.innerHTML=_,this._container.classList.remove("maplibregl-attrib-empty")):this._container.classList.add("maplibregl-attrib-empty"),this._updateCompact(),this._editLink=null)}}class Ia{constructor(u={}){this._updateCompact=()=>{const p=this._container.children;if(p.length){const _=p[0];this._map.getCanvasContainer().offsetWidth<=640||this._compact?this._compact!==!1&&_.classList.add("maplibregl-compact"):_.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=k.create("div","maplibregl-ctrl");const p=k.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(){k.remove(this._container),this._map.off("resize",this._updateCompact),this._map=void 0,this._compact=void 0}}class pA{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,_=p?this._queue.concat(p):this._queue;for(const M of _)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 _ of p)if(!_.cancelled&&(_.callback(u),this._cleared))break;this._cleared=!1,this._currentlyRunning=!1}clear(){this._currentlyRunning&&(this._cleared=!0),this._queue=[]}}var Ml=a.X([{name:"a_pos3d",type:"Int16",components:3}]);class Go 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 _={};for(const M of u.coveringTiles({tileSize:this.tileSize,minzoom:this.minzoom,maxzoom:this.maxzoom,reparseOverscaled:!1,terrain:p}))_[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 Te(M,this.tileSize));for(const M in this._tiles)_[M]||delete this._tiles[M]}freeRtt(u){for(const p in this._tiles){const _=this._tiles[p];(!u||_.tileID.equals(u)||_.tileID.isChildOf(u)||u.isChildOf(_.tileID))&&(_.rtt=[])}}getRenderableTiles(){return this._renderableTilesKeys.map(u=>this.getTileByID(u))}getTileByID(u){return this._tiles[u]}getTerrainCoords(u){const p={};for(const _ of this._renderableTilesKeys){const M=this._tiles[_].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[_]=I}else if(M.canonical.isChildOf(u.canonical)){const I=u.clone();I.posMatrix=new Float64Array(16);const z=M.canonical.z-u.canonical.z,W=M.canonical.x-(M.canonical.x>>z<<z),Q=M.canonical.y-(M.canonical.y>>z<<z),re=a.W>>z;a.aN(I.posMatrix,0,re,0,re,0,1),a.H(I.posMatrix,I.posMatrix,[-W*re,-Q*re,0]),p[_]=I}else if(u.canonical.isChildOf(M.canonical)){const I=u.clone();I.posMatrix=new Float64Array(16);const z=u.canonical.z-M.canonical.z,W=u.canonical.x-(u.canonical.x>>z<<z),Q=u.canonical.y-(u.canonical.y>>z<<z),re=a.W>>z;a.aN(I.posMatrix,0,a.W,0,a.W,0,1),a.H(I.posMatrix,I.posMatrix,[W*re,Q*re,0]),a.J(I.posMatrix,I.posMatrix,[1/2**z,1/2**z,0]),p[_]=I}}return p}getSourceTile(u,p){const _=this.sourceCache._source;let M=u.overscaledZ-this.deltaZoom;if(M>_.maxzoom&&(M=_.maxzoom),M<_.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>=_.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 Qo{constructor(u,p,_){this.painter=u,this.sourceCache=new Go(p),this.options=_,this.exaggeration=typeof _.exaggeration=="number"?_.exaggeration:1,this.qualityFactor=2,this.meshSize=128,this._demMatrixCache={},this.coordsIndex=[],this._coordsTextureSize=1024}getDEMElevation(u,p,_,M=a.W){var I;if(!(p>=0&&p<M&&_>=0&&_<M))return 0;const z=this.getTerrainData(u),W=(I=z.tile)===null||I===void 0?void 0:I.dem;if(!W)return 0;const Q=function(Re,$e,Ge){var ht=$e[0],Tt=$e[1];return Re[0]=Ge[0]*ht+Ge[4]*Tt+Ge[12],Re[1]=Ge[1]*ht+Ge[5]*Tt+Ge[13],Re}([],[p/M*a.W,_/M*a.W],z.u_terrain_matrix),re=[Q[0]*W.dim,Q[1]*W.dim],ue=Math.floor(re[0]),pe=Math.floor(re[1]),Ie=re[0]-ue,Ne=re[1]-pe;return W.get(ue,pe)*(1-Ie)*(1-Ne)+W.get(ue+1,pe)*Ie*(1-Ne)+W.get(ue,pe+1)*(1-Ie)*Ne+W.get(ue+1,pe+1)*Ie*Ne}getElevationForLngLatZoom(u,p){const{tileID:_,mercatorX:M,mercatorY:I}=this._getOverscaledTileIDFromLngLatZoom(u,p);return this.getElevation(_,M%a.W,I%a.W,a.W)}getElevation(u,p,_,M=a.W){return this.getDEMElevation(u,p,_,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 He(M,I,M.gl.RGBA,{premultiply:!1}),this._emptyDemUnpack=[0,0,0,0],this._emptyDemTexture=new He(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 He(M,p.dem.getPixels(),M.gl.RGBA,{premultiply:!1}),p.demTexture.bind(M.gl.NEAREST,M.gl.CLAMP_TO_EDGE),p.needsTerrainPrepare=!1}const _=p&&p+p.tileID.key+u.key;if(_&&!this._demMatrixCache[_]){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 z=u.canonical.x-(u.canonical.x>>I<<I),W=u.canonical.y-(u.canonical.y>>I<<I),Q=a.b8(new Float64Array(16),[1/(a.W<<I),1/(a.W<<I),0]);a.H(Q,Q,[z*a.W,W*a.W,0]),this._demMatrixCache[u.key]={matrix:Q,coord:u}}return{u_depth:2,u_terrain:3,u_terrain_dim:p&&p.dem&&p.dem.dim||1,u_terrain_matrix:_?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,_=p.width/devicePixelRatio,M=p.height/devicePixelRatio;return!this._fbo||this._fbo.width===_&&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 He(p.context,{width:_,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 He(p.context,{width:_,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(_,M,!0,!1),this._fbo.depthAttachment.set(p.context.createRenderbuffer(p.context.gl.DEPTH_COMPONENT16,_,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,z=0;I<this._coordsTextureSize;I++)for(let W=0;W<this._coordsTextureSize;W++,z+=4)p[z+0]=255&W,p[z+1]=255&I,p[z+2]=W>>8<<4|I>>8,p[z+3]=0;const _=new a.R({width:this._coordsTextureSize,height:this._coordsTextureSize},new Uint8Array(p.buffer)),M=new He(u,_,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),_=this.painter.context,M=_.gl;_.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),_.bindFramebuffer.set(null);const I=p[0]+(p[2]>>4<<8),z=p[1]+((15&p[2])<<8),W=this.coordsIndex[255-p[3]],Q=W&&this.sourceCache.getTileByID(W);if(!Q)return null;const re=this._coordsTextureSize,ue=(1<<Q.tileID.canonical.z)*re;return new a.Y((Q.tileID.canonical.x*re+I)/ue+Q.tileID.wrap,(Q.tileID.canonical.y*re+z)/ue,this.getElevation(Q.tileID,I,z,re))}depthAtPoint(u){const p=new Uint8Array(4),_=this.painter.context,M=_.gl;return _.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),_.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.b9,_=new a.aX,M=this.meshSize,I=a.W/M,z=M*M;for(let pe=0;pe<=M;pe++)for(let Ie=0;Ie<=M;Ie++)p.emplaceBack(Ie*I,pe*I,0);for(let pe=0;pe<z;pe+=M+1)for(let Ie=0;Ie<M;Ie++)_.emplaceBack(Ie+pe,M+Ie+pe+1,M+Ie+pe+2),_.emplaceBack(Ie+pe,M+Ie+pe+2,Ie+pe+1);const W=p.length,Q=W+2*(M+1);for(const pe of[0,1])for(let Ie=0;Ie<=M;Ie++)for(const Ne of[0,1])p.emplaceBack(Ie*I,pe*a.W,Ne);for(let pe=0;pe<2*M;pe+=2)_.emplaceBack(Q+pe,Q+pe+1,Q+pe+3),_.emplaceBack(Q+pe,Q+pe+3,Q+pe+2),_.emplaceBack(W+pe,W+pe+3,W+pe+1),_.emplaceBack(W+pe,W+pe+2,W+pe+3);const re=p.length,ue=re+2*(M+1);for(const pe of[0,1])for(let Ie=0;Ie<=M;Ie++)for(const Ne of[0,1])p.emplaceBack(pe*a.W,Ie*I,Ne);for(let pe=0;pe<2*M;pe+=2)_.emplaceBack(re+pe,re+pe+1,re+pe+3),_.emplaceBack(re+pe,re+pe+3,re+pe+2),_.emplaceBack(ue+pe,ue+pe+3,ue+pe+1),_.emplaceBack(ue+pe,ue+pe+2,ue+pe+3);return this._mesh={indexBuffer:u.createIndexBuffer(_),vertexBuffer:u.createVertexBuffer(p,Ml.members),segments:a.$.simpleSegment(0,0,p.length,_.length)},this._mesh}getMeshFrameDelta(u){return 2*Math.PI*a.ba/Math.pow(2,u)/5}getMinTileElevationForLngLatZoom(u,p){var _;const{tileID:M}=this._getOverscaledTileIDFromLngLatZoom(u,p);return(_=this.getMinMaxElevation(M).minElevation)!==null&&_!==void 0?_:0}getMinMaxElevation(u){const p=this.getTerrainData(u).tile,_={minElevation:null,maxElevation:null};return p&&p.dem&&(_.minElevation=p.dem.min*this.exaggeration,_.maxElevation=p.dem.max*this.exaggeration),_}_getOverscaledTileIDFromLngLatZoom(u,p){const _=a.Y.fromLngLat(u.wrap()),M=(1<<p)*a.W,I=_.x*M,z=_.y*M,W=Math.floor(I/a.W),Q=Math.floor(z/a.W);return{tileID:new a.Q(p,0,p,W,Q),mercatorX:I,mercatorY:z}}}class Pf{constructor(u,p,_){this._context=u,this._size=p,this._tileSize=_,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),_=new He(this._context,{width:this._tileSize,height:this._tileSize,data:null},this._context.gl.RGBA);return _.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(_.texture),{id:u,fbo:p,texture:_,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 Qu={background:!0,fill:!0,line:!0,raster:!0,hillshade:!0};class $u{constructor(u,p){this.painter=u,this.terrain=p,this.pool=new Pf(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(_=>!u._layers[_].isHidden(p)),this._coordsDescendingInv={};for(const _ in u.sourceCaches){this._coordsDescendingInv[_]={};const M=u.sourceCaches[_].getVisibleCoordinates();for(const I of M){const z=this.terrain.sourceCache.getTerrainCoords(I);for(const W in z)this._coordsDescendingInv[_][W]||(this._coordsDescendingInv[_][W]=[]),this._coordsDescendingInv[_][W].push(z[W])}}this._coordsDescendingInvStr={};for(const _ of u._order){const M=u._layers[_],I=M.source;if(Qu[M.type]&&!this._coordsDescendingInvStr[I]){this._coordsDescendingInvStr[I]={};for(const z in this._coordsDescendingInv[I])this._coordsDescendingInvStr[I][z]=this._coordsDescendingInv[I][z].map(W=>W.key).sort().join()}}for(const _ of this._renderableTiles)for(const M in this._coordsDescendingInvStr){const I=this._coordsDescendingInvStr[M][_.tileID.key];I&&I!==_.rttCoords[M]&&(_.rtt=[])}}renderLayer(u){if(u.isHidden(this.painter.transform.zoom))return!1;const p=u.type,_=this.painter,M=this._renderableLayerIds[this._renderableLayerIds.length-1]===u.id;if(Qu[p]&&(this._prevType&&Qu[this._prevType]||this._stacks.push([]),this._prevType=p,this._stacks[this._stacks.length-1].push(u.id),!M))return!0;if(Qu[this._prevType]||Qu[p]&&M){this._prevType=p;const I=this._stacks.length-1,z=this._stacks[I]||[];for(const W of this._renderableTiles){if(this.pool.isFull()&&(xl(this.painter,this.terrain,this._rttTiles),this._rttTiles=[],this.pool.freeAllObjects()),this._rttTiles.push(W),W.rtt[I]){const re=this.pool.getObjectForId(W.rtt[I].id);if(re.stamp===W.rtt[I].stamp){this.pool.useObject(re);continue}}const Q=this.pool.getOrCreateFreeObject();this.pool.useObject(Q),this.pool.stampObject(Q),W.rtt[I]={id:Q.id,stamp:Q.stamp},_.context.bindFramebuffer.set(Q.fbo.framebuffer),_.context.clear({color:a.aO.transparent,stencil:0}),_.currentStencilSource=void 0;for(let re=0;re<z.length;re++){const ue=_.style._layers[z[re]],pe=ue.source?this._coordsDescendingInv[ue.source][W.tileID.key]:[W.tileID];_.context.viewport.set([0,0,Q.fbo.width,Q.fbo.height]),_._renderTileClippingMasks(ue,pe),_.renderLayer(_,_.style.sourceCaches[ue.source],ue,pe),ue.source&&(W.rttCoords[ue.source]=this._coordsDescendingInvStr[ue.source][W.tileID.key])}}return xl(this.painter,this.terrain,this._rttTiles),this._rttTiles=[],this.pool.freeAllObjects(),Qu[p]}return!1}}const mA={"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":"MapLibre 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.Enable":"Enable terrain","TerrainControl.Disable":"Disable terrain","CooperativeGesturesHandler.WindowsHelpText":"Use Ctrl + scroll to zoom the map","CooperativeGesturesHandler.MacHelpText":"Use ⌘ + scroll to zoom the map","CooperativeGesturesHandler.MobileHelpText":"Use two fingers to move the map"},Ff=h,Zc={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:Jo,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]},Yu=O=>{O.touchstart=O.dragStart,O.touchmoveWindow=O.dragMove,O.touchend=O.dragEnd},Sh={showCompass:!0,showZoom:!0,visualizePitch:!1};class Pe{constructor(u,p,_=!1){this.mousedown=z=>{this.startMouse(a.e({},z,{ctrlKey:!0,preventDefault:()=>z.preventDefault()}),k.mousePos(this.element,z)),k.addEventListener(window,"mousemove",this.mousemove),k.addEventListener(window,"mouseup",this.mouseup)},this.mousemove=z=>{this.moveMouse(z,k.mousePos(this.element,z))},this.mouseup=z=>{this.mouseRotate.dragEnd(z),this.mousePitch&&this.mousePitch.dragEnd(z),this.offTemp()},this.touchstart=z=>{z.targetTouches.length!==1?this.reset():(this._startPos=this._lastPos=k.touchPos(this.element,z.targetTouches)[0],this.startTouch(z,this._startPos),k.addEventListener(window,"touchmove",this.touchmove,{passive:!1}),k.addEventListener(window,"touchend",this.touchend))},this.touchmove=z=>{z.targetTouches.length!==1?this.reset():(this._lastPos=k.touchPos(this.element,z.targetTouches)[0],this.moveTouch(z,this._lastPos))},this.touchend=z=>{z.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=zl({clickTolerance:M,enable:!0}),this.touchRotate=(({enable:z,clickTolerance:W,bearingDegreesPerPixelMoved:Q=.8})=>{const re=new Vs;return new wl({clickTolerance:W,move:(ue,pe)=>({bearingDelta:(pe.x-ue.x)*Q}),moveStateManager:re,enable:z,assignEvents:Yu})})({clickTolerance:M,enable:!0}),this.map=u,_&&(this.mousePitch=hA({clickTolerance:I,enable:!0}),this.touchPitch=(({enable:z,clickTolerance:W,pitchDegreesPerPixelMoved:Q=-.5})=>{const re=new Vs;return new wl({clickTolerance:W,move:(ue,pe)=>({pitchDelta:(pe.y-ue.y)*Q}),moveStateManager:re,enable:z,assignEvents:Yu})})({clickTolerance:I,enable:!0})),k.addEventListener(p,"mousedown",this.mousedown),k.addEventListener(p,"touchstart",this.touchstart,{passive:!1}),k.addEventListener(p,"touchcancel",this.reset)}startMouse(u,p){this.mouseRotate.dragStart(u,p),this.mousePitch&&this.mousePitch.dragStart(u,p),k.disableDrag()}startTouch(u,p){this.touchRotate.dragStart(u,p),this.touchPitch&&this.touchPitch.dragStart(u,p),k.disableDrag()}moveMouse(u,p){const _=this.map,{bearingDelta:M}=this.mouseRotate.dragMove(u,p)||{};if(M&&_.setBearing(_.getBearing()+M),this.mousePitch){const{pitchDelta:I}=this.mousePitch.dragMove(u,p)||{};I&&_.setPitch(_.getPitch()+I)}}moveTouch(u,p){const _=this.map,{bearingDelta:M}=this.touchRotate.dragMove(u,p)||{};if(M&&_.setBearing(_.getBearing()+M),this.touchPitch){const{pitchDelta:I}=this.touchPitch.dragMove(u,p)||{};I&&_.setPitch(_.getPitch()+I)}}off(){const u=this.element;k.removeEventListener(u,"mousedown",this.mousedown),k.removeEventListener(u,"touchstart",this.touchstart,{passive:!1}),k.removeEventListener(window,"touchmove",this.touchmove,{passive:!1}),k.removeEventListener(window,"touchend",this.touchend),k.removeEventListener(u,"touchcancel",this.reset),this.offTemp()}offTemp(){k.enableDrag(),k.removeEventListener(window,"mousemove",this.mousemove),k.removeEventListener(window,"mouseup",this.mouseup),k.removeEventListener(window,"touchmove",this.touchmove,{passive:!1}),k.removeEventListener(window,"touchend",this.touchend)}}let Sl;function Qa(O,u,p){if(O=new a.M(O.lng,O.lat),u){const _=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(_).distSqr(u)<I?O=_:p.locationPoint(M).distSqr(u)<I&&(O=M)}for(;Math.abs(O.lng-p.center.lng)>180;){const _=p.locationPoint(O);if(_.x>=0&&_.y>=0&&_.x<=p.width&&_.y<=p.height)break;O.lng>p.center.lng?O.lng-=360:O.lng+=360}return O}const lo={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 Yr(O,u,p){const _=O.classList;for(const M in lo)_.remove(`maplibregl-${p}-anchor-${M}`);_.add(`maplibregl-${p}-anchor-${u}`)}class va extends a.E{constructor(u){if(super(),this._onKeyPress=p=>{const _=p.code,M=p.charCode||p.keyCode;_!=="Space"&&_!=="Enter"&&M!==32&&M!==13||this.togglePopup()},this._onMapClick=p=>{const _=p.originalEvent.target,M=this._element;this._popup&&(_===M||M.contains(_))&&this.togglePopup()},this._update=p=>{if(!this._map)return;const _=this._map.loaded()&&!this._map.isMoving();((p==null?void 0:p.type)==="terrain"||(p==null?void 0:p.type)==="render"&&!_)&&this._map.once("render",this._update),this._map.transform.renderWorldCopies&&(this._lngLat=Qa(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()),k.setTransform(this._element,`${lo[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 _=this._clickTolerance||this._map._clickTolerance;this._isDragging=p.point.dist(this._pointerdownPos)>=_}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,this.setOpacity(),this.setOpacity(u==null?void 0:u.opacity,u==null?void 0:u.opacityWhenCovered),u&&u.element)this._element=u.element,this._offset=a.P.convert(u&&u.offset||[0,0]);else{this._defaultMarker=!0,this._element=k.create("div"),this._element.setAttribute("aria-label","Map marker");const p=k.createNS("http://www.w3.org/2000/svg","svg"),_=41,M=27;p.setAttributeNS(null,"display","block"),p.setAttributeNS(null,"height",`${_}px`),p.setAttributeNS(null,"width",`${M}px`),p.setAttributeNS(null,"viewBox",`0 0 ${M} ${_}`);const I=k.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 z=k.createNS("http://www.w3.org/2000/svg","g");z.setAttributeNS(null,"fill-rule","nonzero");const W=k.createNS("http://www.w3.org/2000/svg","g");W.setAttributeNS(null,"transform","translate(3.0, 29.0)"),W.setAttributeNS(null,"fill","#000000");const Q=[{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 ht of Q){const Tt=k.createNS("http://www.w3.org/2000/svg","ellipse");Tt.setAttributeNS(null,"opacity","0.04"),Tt.setAttributeNS(null,"cx","10.5"),Tt.setAttributeNS(null,"cy","5.80029008"),Tt.setAttributeNS(null,"rx",ht.rx),Tt.setAttributeNS(null,"ry",ht.ry),W.appendChild(Tt)}const re=k.createNS("http://www.w3.org/2000/svg","g");re.setAttributeNS(null,"fill",this._color);const ue=k.createNS("http://www.w3.org/2000/svg","path");ue.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"),re.appendChild(ue);const pe=k.createNS("http://www.w3.org/2000/svg","g");pe.setAttributeNS(null,"opacity","0.25"),pe.setAttributeNS(null,"fill","#000000");const Ie=k.createNS("http://www.w3.org/2000/svg","path");Ie.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"),pe.appendChild(Ie);const Ne=k.createNS("http://www.w3.org/2000/svg","g");Ne.setAttributeNS(null,"transform","translate(6.0, 7.0)"),Ne.setAttributeNS(null,"fill","#FFFFFF");const Re=k.createNS("http://www.w3.org/2000/svg","g");Re.setAttributeNS(null,"transform","translate(8.0, 8.0)");const $e=k.createNS("http://www.w3.org/2000/svg","circle");$e.setAttributeNS(null,"fill","#000000"),$e.setAttributeNS(null,"opacity","0.25"),$e.setAttributeNS(null,"cx","5.5"),$e.setAttributeNS(null,"cy","5.5"),$e.setAttributeNS(null,"r","5.4999962");const Ge=k.createNS("http://www.w3.org/2000/svg","circle");Ge.setAttributeNS(null,"fill","#FFFFFF"),Ge.setAttributeNS(null,"cx","5.5"),Ge.setAttributeNS(null,"cy","5.5"),Ge.setAttributeNS(null,"r","5.4999962"),Re.appendChild($e),Re.appendChild(Ge),z.appendChild(W),z.appendChild(re),z.appendChild(pe),z.appendChild(Ne),z.appendChild(Re),p.appendChild(z),p.setAttributeNS(null,"height",_*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()}),Yr(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),k.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!==this._opacity&&(this._element.style.opacity=this._opacity));if(u)this._opacityTimeout=null;else{if(this._opacityTimeout)return;this._opacityTimeout=setTimeout(()=>{this._opacityTimeout=null},100)}const p=this._map,_=p.terrain.depthAtPoint(this._pos),M=p.terrain.getElevationForLngLatZoom(this._lngLat,p.transform.tileZoom);if(p.transform.lngLatToCameraDepth(this._lngLat,M)-_<.006)return void(this._element.style.opacity=this._opacity);const I=-this._offset.y/p.transform._pixelPerMeter,z=Math.sin(p.getPitch()*Math.PI/180)*I,W=p.terrain.depthAtPoint(new a.P(this._pos.x,this._pos.y-this._offset.y)),Q=p.transform.lngLatToCameraDepth(this._lngLat,M+z);this._element.style.opacity=Q-W>.006?this._opacityWhenCovered:this._opacity}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}setOpacity(u,p){return u===void 0&&p===void 0&&(this._opacity="1",this._opacityWhenCovered="0.2"),u!==void 0&&(this._opacity=u),p!==void 0&&(this._opacityWhenCovered=p),this._map&&this._updateOpacity(!0),this}}const mc={positionOptions:{enableHighAccuracy:!1,maximumAge:0,timeout:6e3},fitBoundsOptions:{maxZoom:15},trackUserLocation:!1,showAccuracyCircle:!0,showUserLocation:!0};let gc=0,Zs=!1;const Df={maxWidth:100,unit:"metric"};function Fd(O,u,p){const _=p&&p.maxWidth||100,M=O._container.clientHeight/2,I=O.unproject([0,M]),z=O.unproject([_,M]),W=I.distanceTo(z);if(p&&p.unit==="imperial"){const Q=3.2808*W;Q>5280?yc(u,_,Q/5280,O._getUIString("ScaleControl.Miles")):yc(u,_,Q,O._getUIString("ScaleControl.Feet"))}else p&&p.unit==="nautical"?yc(u,_,W/1852,O._getUIString("ScaleControl.NauticalMiles")):W>=1e3?yc(u,_,W/1e3,O._getUIString("ScaleControl.Kilometers")):yc(u,_,W,O._getUIString("ScaleControl.Meters"))}function yc(O,u,p,_){const M=function(I){const z=Math.pow(10,`${Math.floor(I)}`.length-1);let W=I/z;return W=W>=10?10:W>=5?5:W>=3?3:W>=2?2:W>=1?1:function(Q){const re=Math.pow(10,Math.ceil(-Math.log(Q)/Math.LN10));return Math.round(Q*re)/re}(W),z*W}(p);O.style.width=u*(M/p)+"px",O.innerHTML=`${M}&nbsp;${_}`}const Dd={closeButton:!0,closeOnClick:!0,focusAfterOpen:!0,className:"",maxWidth:"240px"},Eh=["a[href]","[tabindex]:not([tabindex='-1'])","[contenteditable]:not([contenteditable='false'])","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].join(", ");function El(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 El(new a.P(0,0))}const Lf=h;s.AJAXError=a.bd,s.Evented=a.E,s.LngLat=a.M,s.MercatorCoordinate=a.Y,s.Point=a.P,s.addProtocol=a.be,s.config=a.a,s.removeProtocol=a.bf,s.AttributionControl=fA,s.BoxZoomHandler=Cu,s.CanvasSource=Gr,s.CooperativeGesturesHandler=ua,s.DoubleClickZoomHandler=Hc,s.DragPanHandler=Pd,s.DragRotateHandler=Mh,s.EdgeInsets=cc,s.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=k.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._setupUI(),this._controlContainer}onRemove(){k.remove(this._controlContainer),this._map=null,window.document.removeEventListener(this._fullscreenchange,this._onFullscreenChange)}_setupUI(){const O=this._fullscreenButton=k.create("button","maplibregl-ctrl-fullscreen",this._controlContainer);k.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()}},s.GeoJSONSource=vn,s.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),_=u.coords.accuracy,M=this._map.getBearing(),I=a.e({bearing:M},this.options.fitBoundsOptions),z=Ut.fromLngLat(p,_);this._map.fitBounds(z,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&&Zs)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=k.create("button","maplibregl-ctrl-geolocate",this._container),k.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=k.create("div","maplibregl-user-location-dot"),this._userLocationDotMarker=new va({element:this._dotElement}),this._circleElement=k.create("div","maplibregl-user-location-accuracy-circle"),this._accuracyCircleMarker=new va({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({},mc,O)}onAdd(O){return this._map=O,this._container=k.create("div","maplibregl-ctrl maplibregl-ctrl-group"),function(u=!1){return a._(this,void 0,void 0,function*(){if(Sl!==void 0&&!u)return Sl;if(window.navigator.permissions===void 0)return Sl=!!window.navigator.geolocation,Sl;try{Sl=(yield window.navigator.permissions.query({name:"geolocation"})).state!=="denied"}catch{Sl=!!window.navigator.geolocation}return Sl})}().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(),k.remove(this._container),this._map.off("zoom",this._onZoom),this._map=void 0,gc=0,Zs=!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(),_=u.distanceTo(p),M=Math.ceil(this._accuracy/(_/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":gc--,Zs=!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"),gc++,gc>1?(O={maximumAge:6e5,timeout:0},Zs=!0):(O=this.options.positionOptions,Zs=!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)}},s.Hash=_u,s.ImageSource=cr,s.KeyboardHandler=fc,s.LngLatBounds=Ut,s.LogoControl=Ia,s.Map=class extends Vc{constructor(O){if(a.bb.mark(a.bc.create),(O=a.e({},Zc,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 Id(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 pA,this._controls=[],this._mapId=a.a3(),this._locale=a.e({},mA,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 me(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=Td(_=>{this._trackResize&&!this._removed&&this.resize(_)._update()},50);this._resizeObserver=new ResizeObserver(_=>{u?p(_):u=!0}),this._resizeObserver.observe(this._container)}this.handlers=new pc(this,O),this._hash=O.hash&&new _u(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 fA(typeof O.attributionControl=="boolean"?void 0:O.attributionControl)),O.maplibreLogo&&this.addControl(new Ia,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 _=this._controlPositions[u];return u.indexOf("bottom")!==-1?_.insertBefore(p,_.firstChild):_.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,_){return _==null&&this.terrain&&(_=this.terrain.getElevationForLngLatZoom(p,this.transform.tileZoom)),super.calculateCameraOptionsFromTo(O,u,p,_)}resize(O){var u;const p=this._containerDimensions(),_=p[0],M=p[1],I=this._getClampedPixelRatio(_,M);if(this._resizeCanvas(_,M,I),this.painter.resize(_,M,I),this.painter.overLimit()){const W=this.painter.context.gl;this._maxCanvasSize=[W.drawingBufferWidth,W.drawingBufferHeight];const Q=this._getClampedPixelRatio(_,M);this._resizeCanvas(_,M,Q),this.painter.resize(_,M,Q)}this.transform.resize(_,M),(u=this._requestedCameraState)===null||u===void 0||u.resize(_,M);const z=!this._moving;return z&&(this.stop(),this.fire(new a.k("movestart",O)).fire(new a.k("move",O))),this.fire(new a.k("resize",O)),z&&this.fire(new a.k("moveend",O)),this}_getClampedPixelRatio(O,u){const{0:p,1:_}=this._maxCanvasSize,M=this.getPixelRatio(),I=O*M,z=u*M;return Math.min(I>p?p/I:1,z>_?_/z: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(Ut.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 _=!1;return{layer:u,listener:p,delegates:{mousemove:I=>{const z=this.getLayer(u)?this.queryRenderedFeatures(I.point,{layers:[u]}):[];z.length?_||(_=!0,p.call(this,new _s(O,this,I.originalEvent,{features:z}))):_=!1},mouseout:()=>{_=!1}}}}if(O==="mouseleave"||O==="mouseout"){let _=!1;return{layer:u,listener:p,delegates:{mousemove:z=>{(this.getLayer(u)?this.queryRenderedFeatures(z.point,{layers:[u]}):[]).length?_=!0:_&&(_=!1,p.call(this,new _s(O,this,z.originalEvent)))},mouseout:z=>{_&&(_=!1,p.call(this,new _s(O,this,z.originalEvent)))}}}}{const _=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]:_}}}}on(O,u,p){if(p===void 0)return super.on(O,u);const _=this._createDelegatedListener(O,u,p);this._delegatedListeners=this._delegatedListeners||{},this._delegatedListeners[O]=this._delegatedListeners[O]||[],this._delegatedListeners[O].push(_);for(const M in _.delegates)this.on(M,_.delegates[M]);return this}once(O,u,p){if(p===void 0)return super.once(O,u);const _=this._createDelegatedListener(O,u,p);for(const M in _.delegates)this.once(M,_.delegates[M]);return this}off(O,u,p){return p===void 0?super.off(O,u):(this._delegatedListeners&&this._delegatedListeners[O]&&(_=>{const M=this._delegatedListeners[O];for(let I=0;I<M.length;I++){const z=M[I];if(z.layer===u&&z.listener===p){for(const W in z.delegates)this.off(W,z.delegates[W]);return M.splice(I,1),this}}})(),this)}queryRenderedFeatures(O,u){if(!this.style)return[];let p;const _=O instanceof a.P||Array.isArray(O),M=_?O:[[0,0],[this.transform.width,this.transform.height]];if(u=u||(_?{}:O)||{},M instanceof a.P||typeof M[0]=="number")p=[a.P.convert(M)];else{const I=a.P.convert(M[0]),z=a.P.convert(M[1]);p=[I,new a.P(z.x,I.y),z,new a.P(I.x,z.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 ei(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 ei(this,{}),this.style.setEventedParent(this,{style:this.style}),this.style.loadEmpty())}_diffStyle(O,u){if(typeof O=="string"){const p=this._requestManager.transformRequest(O,ce.Style);a.h(p,new AbortController).then(_=>{this._updateDiff(_.data,u)}).catch(_=>{_&&this.fire(new a.j(_))})}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 _=this.style._layers[p];_.type==="hillshade"&&_.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 Qo(this.painter,u,O),this.painter.renderToTexture=new $u(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 _ in p){const M=p[_];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:_=1,sdf:M=!1,stretchX:I,stretchY:z,content:W}=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:Q,height:re,data:ue}=u,pe=u;return this.style.addImage(O,{data:new a.R({width:Q,height:re},new Uint8Array(ue)),pixelRatio:_,stretchX:I,stretchY:z,content:W,sdf:M,version:0,userImage:pe}),pe.onAdd&&pe.onAdd(this,O),this}}{const{width:Q,height:re,data:ue}=B.getImageData(u);this.style.addImage(O,{data:new a.R({width:Q,height:re},ue),pixelRatio:_,stretchX:I,stretchY:z,content:W,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 _=u instanceof HTMLImageElement||a.b(u)?B.getImageData(u):u,{width:M,height:I,data:z}=_;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 W=!(u instanceof HTMLImageElement||a.b(u));return p.data.replace(z,W),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,ce.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,_={}){return this.style.setPaintProperty(O,u,p,_),this._update(!0)}getPaintProperty(O,u){return this.style.getPaintProperty(O,u)}setLayoutProperty(O,u,p,_={}){return this.style.setLayoutProperty(O,u,p,_),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,_=>{_||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=k.create("div","maplibregl-canvas-container",O);this._interactive&&u.classList.add("maplibregl-interactive"),this._canvas=k.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(),_=this._getClampedPixelRatio(p[0],p[1]);this._resizeCanvas(p[0],p[1],_);const M=this._controlContainer=k.create("div","maplibregl-control-container",O),I=this._controlPositions={};["top-left","top-right","bottom-left","bottom-right"].forEach(z=>{I[z]=k.create("div",`maplibregl-ctrl-${z} `,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",_=>{u={requestedAttributes:O},_&&(u.statusMessage=_.statusMessage,u.type=_.type)},{once:!0});const p=this._canvas.getContext("webgl2",O)||this._canvas.getContext("webgl",O);if(!p){const _="Failed to initialize WebGL";throw u?(u.message=_,new Error(JSON.stringify(u))):new Error(_)}this.painter=new bh(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=B.now();this.style.zoomHistory.update(M,I);const z=new a.a8(M,{now:I,fadeDuration:u,zoomHistory:this.style.zoomHistory,transition:this.style.getTransition()}),W=z.crossFadingFactor();W===1&&W===this._crossFadingFactor||(p=!0,this._crossFadingFactor=W),this.style.update(z)}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.bb.mark(a.bc.load),this.fire(new a.k("load"))),this.style&&(this.style.hasTransitions()||p)&&(this._styleDirty=!0),this.style&&!this._placementDirty&&this.style._releaseSymbolFadeTiles();const _=this._sourcesDirty||this._styleDirty||this._placementDirty;return _||this._repaint?this.triggerRepaint():!this.isMoving()&&this.loaded()&&this.fire(new a.k("idle")),!this._loaded||this._fullyLoaded||_||(this._fullyLoaded=!0,a.bb.mark(a.bc.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),k.remove(this._canvasContainer),k.remove(this._controlContainer),this._container.classList.remove("maplibregl-map"),a.bb.clearMetrics(),this._removed=!0,this.fire(new a.k("remove"))}triggerRepaint(){this.style&&!this._frameRequest&&(this._frameRequest=new AbortController,B.frameAsync(this._frameRequest).then(O=>{a.bb.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 Ff}getCameraTargetElevation(){return this.transform.elevation}},s.MapMouseEvent=_s,s.MapTouchEvent=qc,s.MapWheelEvent=Cs,s.Marker=va,s.NavigationControl=class{constructor(O){this._updateZoomButtons=()=>{const u=this._map.getZoom(),p=u===this._map.getMaxZoom(),_=u===this._map.getMinZoom();this._zoomInButton.disabled=p,this._zoomOutButton.disabled=_,this._zoomInButton.setAttribute("aria-disabled",p.toString()),this._zoomOutButton.setAttribute("aria-disabled",_.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 _=this._map._getUIString(`NavigationControl.${p}`);u.title=_,u.setAttribute("aria-label",_)},this.options=a.e({},Sh,O),this._container=k.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})),k.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})),k.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=k.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 Pe(this._map,this._compass,this.options.visualizePitch)),this._container}onRemove(){k.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=k.create("button",O,this._container);return p.type="button",p.addEventListener("click",u),p}},s.Popup=class extends a.E{constructor(O){super(),this.remove=()=>(this._content&&k.remove(this._content),this._container&&(k.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=k.create("div","maplibregl-popup",this._map.getContainer()),this._tip=k.create("div","maplibregl-popup-tip",this._container),this._container.appendChild(this._content),this.options.className)for(const z of this.options.className.split(" "))this._container.classList.add(z);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=Qa(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 _=this.options.anchor;const M=El(this.options.offset);if(!_){const z=this._container.offsetWidth,W=this._container.offsetHeight;let Q;Q=p.y+M.bottom.y<W?["top"]:p.y>this._map.transform.height-W?["bottom"]:[],p.x<z/2?Q.push("left"):p.x>this._map.transform.width-z/2&&Q.push("right"),_=Q.length===0?"bottom":Q.join("-")}const I=p.add(M[_]).round();k.setTransform(this._container,`${lo[_]} translate(${I.x}px,${I.y}px)`),Yr(this._container,_,"popup")},this._onClose=()=>{this.remove()},this.options=a.e(Object.create(Dd),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 _;for(p.innerHTML=O;_=p.firstChild,_;)u.appendChild(_);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=k.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=k.create("button","maplibregl-popup-close-button",this._content),this._closeButton.type="button",this._closeButton.setAttribute("aria-label","Close popup"),this._closeButton.innerHTML="&#215;",this._closeButton.addEventListener("click",this._onClose))}_focusFirstElement(){if(!this.options.focusAfterOpen||!this._container)return;const O=this._container.querySelector(Eh);O&&O.focus()}},s.RasterDEMTileSource=mn,s.RasterTileSource=rr,s.ScaleControl=class{constructor(O){this._onMove=()=>{Fd(this._map,this._container,this.options)},this.setUnit=u=>{this.options.unit=u,Fd(this._map,this._container,this.options)},this.options=a.e({},Df,O)}getDefaultPosition(){return"bottom-left"}onAdd(O){return this._map=O,this._container=k.create("div","maplibregl-ctrl maplibregl-ctrl-scale",O.getContainer()),this._map.on("move",this._onMove),this._onMove(),this._container}onRemove(){k.remove(this._container),this._map.off("move",this._onMove),this._map=void 0}},s.ScrollZoomHandler=wu,s.Style=ei,s.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.Disable")):(this._terrainButton.classList.add("maplibregl-ctrl-terrain"),this._terrainButton.title=this._map._getUIString("TerrainControl.Enable"))},this.options=O}onAdd(O){return this._map=O,this._container=k.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._terrainButton=k.create("button","maplibregl-ctrl-terrain",this._container),k.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(){k.remove(this._container),this._map.off("terrain",this._updateTerrainIcon),this._map=void 0}},s.TwoFingersTouchPitchHandler=UA,s.TwoFingersTouchRotateHandler=Nu,s.TwoFingersTouchZoomHandler=LA,s.TwoFingersTouchZoomRotateHandler=so,s.VectorTileSource=pt,s.VideoSource=Mr,s.addSourceType=(O,u)=>a._(void 0,void 0,void 0,function*(){if(mi(O))throw new Error(`A source type called "${O}" already exists.`);((p,_)=>{gr[p]=_})(O,u)}),s.clearPrewarmedResources=function(){const O=It;O&&(O.isPreloaded()&&O.numActive()===1?(O.release(on),It=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()"))},s.getMaxParallelImageRequests=function(){return a.a.MAX_PARALLEL_IMAGE_REQUESTS},s.getRTLTextPluginStatus=function(){return H().getRTLTextPluginStatus()},s.getVersion=function(){return Lf},s.getWorkerCount=function(){return gt.workerCount},s.getWorkerUrl=function(){return a.a.WORKER_URL},s.importScriptInWorkers=function(O){return xe().broadcast("importScript",O)},s.prewarm=function(){Me().acquire(on)},s.setMaxParallelImageRequests=function(O){a.a.MAX_PARALLEL_IMAGE_REQUESTS=O},s.setRTLTextPlugin=function(O,u){return H().setRTLTextPlugin(O,u)},s.setWorkerCount=function(O){gt.workerCount=O},s.setWorkerUrl=function(O){a.a.WORKER_URL=O}});var o=t;return o})})(lR);var uJ=lR.exports;const i_=fa(uJ);var o_=typeof globalThis<"u"?globalThis:typeof window<"u"||typeof window<"u"?window:typeof self<"u"?self:{};function AR(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var d3={exports:{}};d3.exports;(function(e,n){var t=200,r="__lodash_hash_undefined__",i=1,o=2,s=9007199254740991,a="[object Arguments]",h="[object Array]",g="[object AsyncFunction]",C="[object Boolean]",B="[object Date]",k="[object Error]",P="[object Function]",L="[object GeneratorFunction]",J="[object Map]",N="[object Number]",$="[object Null]",q="[object Object]",oe="[object Promise]",ce="[object Proxy]",me="[object RegExp]",he="[object Set]",V="[object String]",ae="[object Symbol]",ye="[object Undefined]",Oe="[object WeakMap]",De="[object ArrayBuffer]",He="[object DataView]",ke="[object Float32Array]",nt="[object Float64Array]",be="[object Int8Array]",Bt="[object Int16Array]",kt="[object Int32Array]",Yt="[object Uint8Array]",jt="[object Uint8ClampedArray]",Xe="[object Uint16Array]",rt="[object Uint32Array]",ot=/[\\^$.*+?()[\]{}|]/g,on=/^\[object .+?Constructor\]$/,gt=/^(?:0|[1-9]\d*)$/,at={};at[ke]=at[nt]=at[be]=at[Bt]=at[kt]=at[Yt]=at[jt]=at[Xe]=at[rt]=!0,at[a]=at[h]=at[De]=at[C]=at[He]=at[B]=at[k]=at[P]=at[J]=at[N]=at[q]=at[me]=at[he]=at[V]=at[Oe]=!1;var It=typeof o_=="object"&&o_&&o_.Object===Object&&o_,Lt=typeof self=="object"&&self&&self.Object===Object&&self,Me=It||Lt||Function("return this")(),fe=n&&!n.nodeType&&n,xe=fe&&!0&&e&&!e.nodeType&&e,Ue=xe&&xe.exports===fe,et=Ue&&It.process,it=function(){try{return et&&et.binding&&et.binding("util")}catch{}}(),bt=it&&it.isTypedArray;function Ut(R,se){for(var Le=-1,mt=R==null?0:R.length,Dn=0,en=[];++Le<mt;){var Sr=R[Le];se(Sr,Le,R)&&(en[Dn++]=Sr)}return en}function Rt(R,se){for(var Le=-1,mt=se.length,Dn=R.length;++Le<mt;)R[Dn+Le]=se[Le];return R}function pt(R,se){for(var Le=-1,mt=R==null?0:R.length;++Le<mt;)if(se(R[Le],Le,R))return!0;return!1}function rr(R,se){for(var Le=-1,mt=Array(R);++Le<R;)mt[Le]=se(Le);return mt}function mn(R){return function(se){return R(se)}}function vn(R,se){return R.has(se)}function Xn(R,se){return R==null?void 0:R[se]}function cr(R){var se=-1,Le=Array(R.size);return R.forEach(function(mt,Dn){Le[++se]=[Dn,mt]}),Le}function Mr(R,se){return function(Le){return R(se(Le))}}function Gr(R){var se=-1,Le=Array(R.size);return R.forEach(function(mt){Le[++se]=mt}),Le}var gr=Array.prototype,mi=Function.prototype,Se=Object.prototype,X=Me["__core-js_shared__"],H=mi.toString,Te=Se.hasOwnProperty,At=function(){var R=/[^.]+$/.exec(X&&X.keys&&X.keys.IE_PROTO||"");return R?"Symbol(src)_1."+R:""}(),St=Se.toString,Et=RegExp("^"+H.call(Te).replace(ot,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Nt=Ue?Me.Buffer:void 0,pn=Me.Symbol,Kn=Me.Uint8Array,En=Se.propertyIsEnumerable,m=gr.splice,Kt=pn?pn.toStringTag:void 0,Dr=Object.getOwnPropertySymbols,Fn=Nt?Nt.isBuffer:void 0,Fe=Mr(Object.keys,Object),de=qo(Me,"DataView"),Ce=qo(Me,"Map"),Be=qo(Me,"Promise"),ze=qo(Me,"Set"),tt=qo(Me,"WeakMap"),lt=qo(Object,"create"),ft=Wo(de),Ve=Wo(Ce),xt=Wo(Be),Xt=Wo(ze),Vt=Wo(tt),Ht=pn?pn.prototype:void 0,Qn=Ht?Ht.valueOf:void 0;function Mn(R){var se=-1,Le=R==null?0:R.length;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function or(){this.__data__=lt?lt(null):{},this.size=0}function ar(R){var se=this.has(R)&&delete this.__data__[R];return this.size-=se?1:0,se}function kr(R){var se=this.__data__;if(lt){var Le=se[R];return Le===r?void 0:Le}return Te.call(se,R)?se[R]:void 0}function jr(R){var se=this.__data__;return lt?se[R]!==void 0:Te.call(se,R)}function Lr(R,se){var Le=this.__data__;return this.size+=this.has(R)?0:1,Le[R]=lt&&se===void 0?r:se,this}Mn.prototype.clear=or,Mn.prototype.delete=ar,Mn.prototype.get=kr,Mn.prototype.has=jr,Mn.prototype.set=Lr;function Wr(R){var se=-1,Le=R==null?0:R.length;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function ir(){this.__data__=[],this.size=0}function ui(R){var se=this.__data__,Le=Cn(se,R);if(Le<0)return!1;var mt=se.length-1;return Le==mt?se.pop():m.call(se,Le,1),--this.size,!0}function Oi(R){var se=this.__data__,Le=Cn(se,R);return Le<0?void 0:se[Le][1]}function Yi(R){return Cn(this.__data__,R)>-1}function _o(R,se){var Le=this.__data__,mt=Cn(Le,R);return mt<0?(++this.size,Le.push([R,se])):Le[mt][1]=se,this}Wr.prototype.clear=ir,Wr.prototype.delete=ui,Wr.prototype.get=Oi,Wr.prototype.has=Yi,Wr.prototype.set=_o;function Jr(R){var se=-1,Le=R==null?0:R.length;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function xo(){this.size=0,this.__data__={hash:new Mn,map:new(Ce||Wr),string:new Mn}}function Wa(R){var se=ia(this,R).delete(R);return this.size-=se?1:0,se}function Ba(R){return ia(this,R).get(R)}function bi(R){return ia(this,R).has(R)}function os(R,se){var Le=ia(this,R),mt=Le.size;return Le.set(R,se),this.size+=Le.size==mt?0:1,this}Jr.prototype.clear=xo,Jr.prototype.delete=Wa,Jr.prototype.get=Ba,Jr.prototype.has=bi,Jr.prototype.set=os;function hi(R){var se=-1,Le=R==null?0:R.length;for(this.__data__=new Jr;++se<Le;)this.add(R[se])}function Wn(R){return this.__data__.set(R,r),this}function eo(R){return this.__data__.has(R)}hi.prototype.add=hi.prototype.push=Wn,hi.prototype.has=eo;function io(R){var se=this.__data__=new Wr(R);this.size=se.size}function qi(){this.__data__=new Wr,this.size=0}function ve(R){var se=this.__data__,Le=se.delete(R);return this.size=se.size,Le}function Ye(R){return this.__data__.get(R)}function Jt(R){return this.__data__.has(R)}function sn(R,se){var Le=this.__data__;if(Le instanceof Wr){var mt=Le.__data__;if(!Ce||mt.length<t-1)return mt.push([R,se]),this.size=++Le.size,this;Le=this.__data__=new Jr(mt)}return Le.set(R,se),this.size=Le.size,this}io.prototype.clear=qi,io.prototype.delete=ve,io.prototype.get=Ye,io.prototype.has=Jt,io.prototype.set=sn;function Ft(R,se){var Le=ss(R),mt=!Le&&Uu(R),Dn=!Le&&!mt&&Do(R),en=!Le&&!mt&&!Dn&&Cl(R),Sr=Le||mt||Dn||en,Ur=Sr?rr(R.length,String):[],yr=Ur.length;for(var Ir in R)(se||Te.call(R,Ir))&&!(Sr&&(Ir=="length"||Dn&&(Ir=="offset"||Ir=="parent")||en&&(Ir=="buffer"||Ir=="byteLength"||Ir=="byteOffset")||lA(Ir,yr)))&&Ur.push(Ir);return Ur}function Cn(R,se){for(var Le=R.length;Le--;)if(Na(R[Le][0],se))return Le;return-1}function ur(R,se,Le){var mt=se(R);return ss(R)?mt:Rt(mt,Le(R))}function fi(R){return R==null?R===void 0?ye:$:Kt&&Kt in Object(R)?vs(R):uA(R)}function ei(R){return oa(R)&&fi(R)==a}function Zo(R,se,Le,mt,Dn){return R===se?!0:R==null||se==null||!oa(R)&&!oa(se)?R!==R&&se!==se:Fa(R,se,Le,mt,Zo,Dn)}function Fa(R,se,Le,mt,Dn,en){var Sr=ss(R),Ur=ss(se),yr=Sr?h:ma(R),Ir=Ur?h:ma(se);yr=yr==a?q:yr,Ir=Ir==a?q:Ir;var Bi=yr==q,fo=Ir==q,xi=yr==Ir;if(xi&&Do(R)){if(!Do(se))return!1;Sr=!0,Bi=!1}if(xi&&!Bi)return en||(en=new io),Sr||Cl(R)?ka(R,se,Le,mt,Dn,en):pa(R,se,yr,Le,mt,Dn,en);if(!(Le&i)){var Hr=Bi&&Te.call(R,"__wrapped__"),Hi=fo&&Te.call(se,"__wrapped__");if(Hr||Hi){var Io=Hr?R.value():R,wo=Hi?se.value():se;return en||(en=new io),Dn(Io,wo,Le,mt,en)}}return xi?(en||(en=new io),Zl(R,se,Le,mt,Dn,en)):!1}function Or(R){if(!Dl(R)||Lu(R))return!1;var se=vl(R)?Et:on;return se.test(Wo(R))}function gi(R){return oa(R)&&_l(R.length)&&!!at[fi(R)]}function Ks(R){if(!mu(R))return Fe(R);var se=[];for(var Le in Object(R))Te.call(R,Le)&&Le!="constructor"&&se.push(Le);return se}function ka(R,se,Le,mt,Dn,en){var Sr=Le&i,Ur=R.length,yr=se.length;if(Ur!=yr&&!(Sr&&yr>Ur))return!1;var Ir=en.get(R);if(Ir&&en.get(se))return Ir==se;var Bi=-1,fo=!0,xi=Le&o?new hi:void 0;for(en.set(R,se),en.set(se,R);++Bi<Ur;){var Hr=R[Bi],Hi=se[Bi];if(mt)var Io=Sr?mt(Hi,Hr,Bi,se,R,en):mt(Hr,Hi,Bi,R,se,en);if(Io!==void 0){if(Io)continue;fo=!1;break}if(xi){if(!pt(se,function(wo,Ga){if(!vn(xi,Ga)&&(Hr===wo||Dn(Hr,wo,Le,mt,en)))return xi.push(Ga)})){fo=!1;break}}else if(!(Hr===Hi||Dn(Hr,Hi,Le,mt,en))){fo=!1;break}}return en.delete(R),en.delete(se),fo}function pa(R,se,Le,mt,Dn,en,Sr){switch(Le){case He:if(R.byteLength!=se.byteLength||R.byteOffset!=se.byteOffset)return!1;R=R.buffer,se=se.buffer;case De:return!(R.byteLength!=se.byteLength||!en(new Kn(R),new Kn(se)));case C:case B:case N:return Na(+R,+se);case k:return R.name==se.name&&R.message==se.message;case me:case V:return R==se+"";case J:var Ur=cr;case he:var yr=mt&i;if(Ur||(Ur=Gr),R.size!=se.size&&!yr)return!1;var Ir=Sr.get(R);if(Ir)return Ir==se;mt|=o,Sr.set(R,se);var Bi=ka(Ur(R),Ur(se),mt,Dn,en,Sr);return Sr.delete(R),Bi;case ae:if(Qn)return Qn.call(R)==Qn.call(se)}return!1}function Zl(R,se,Le,mt,Dn,en){var Sr=Le&i,Ur=as(R),yr=Ur.length,Ir=as(se),Bi=Ir.length;if(yr!=Bi&&!Sr)return!1;for(var fo=yr;fo--;){var xi=Ur[fo];if(!(Sr?xi in se:Te.call(se,xi)))return!1}var Hr=en.get(R);if(Hr&&en.get(se))return Hr==se;var Hi=!0;en.set(R,se),en.set(se,R);for(var Io=Sr;++fo<yr;){xi=Ur[fo];var wo=R[xi],Ga=se[xi];if(mt)var Ll=Sr?mt(Ga,wo,xi,se,R,en):mt(wo,Ga,xi,R,se,en);if(!(Ll===void 0?wo===Ga||Dn(wo,Ga,Le,mt,en):Ll)){Hi=!1;break}Io||(Io=xi=="constructor")}if(Hi&&!Io){var Xl=R.constructor,ga=se.constructor;Xl!=ga&&"constructor"in R&&"constructor"in se&&!(typeof Xl=="function"&&Xl instanceof Xl&&typeof ga=="function"&&ga instanceof ga)&&(Hi=!1)}return en.delete(R),en.delete(se),Hi}function as(R){return ur(R,AA,Fu)}function ia(R,se){var Le=R.__data__;return Du(se)?Le[typeof se=="string"?"string":"hash"]:Le.map}function qo(R,se){var Le=Xn(R,se);return Or(Le)?Le:void 0}function vs(R){var se=Te.call(R,Kt),Le=R[Kt];try{R[Kt]=void 0;var mt=!0}catch{}var Dn=St.call(R);return mt&&(se?R[Kt]=Le:delete R[Kt]),Dn}var Fu=Dr?function(R){return R==null?[]:(R=Object(R),Ut(Dr(R),function(se){return En.call(R,se)}))}:go,ma=fi;(de&&ma(new de(new ArrayBuffer(1)))!=He||Ce&&ma(new Ce)!=J||Be&&ma(Be.resolve())!=oe||ze&&ma(new ze)!=he||tt&&ma(new tt)!=Oe)&&(ma=function(R){var se=fi(R),Le=se==q?R.constructor:void 0,mt=Le?Wo(Le):"";if(mt)switch(mt){case ft:return He;case Ve:return J;case xt:return oe;case Xt:return he;case Vt:return Oe}return se});function lA(R,se){return se=se??s,!!se&&(typeof R=="number"||gt.test(R))&&R>-1&&R%1==0&&R<se}function Du(R){var se=typeof R;return se=="string"||se=="number"||se=="symbol"||se=="boolean"?R!=="__proto__":R===null}function Lu(R){return!!At&&At in R}function mu(R){var se=R&&R.constructor,Le=typeof se=="function"&&se.prototype||Se;return R===Le}function uA(R){return St.call(R)}function Wo(R){if(R!=null){try{return H.call(R)}catch{}try{return R+""}catch{}}return""}function Na(R,se){return R===se||R!==R&&se!==se}var Uu=ei(function(){return arguments}())?ei:function(R){return oa(R)&&Te.call(R,"callee")&&!En.call(R,"callee")},ss=Array.isArray;function ll(R){return R!=null&&_l(R.length)&&!vl(R)}var Do=Fn||oo;function gu(R,se){return Zo(R,se)}function vl(R){if(!Dl(R))return!1;var se=fi(R);return se==P||se==L||se==g||se==ce}function _l(R){return typeof R=="number"&&R>-1&&R%1==0&&R<=s}function Dl(R){var se=typeof R;return R!=null&&(se=="object"||se=="function")}function oa(R){return R!=null&&typeof R=="object"}var Cl=bt?mn(bt):gi;function AA(R){return ll(R)?Ft(R):Ks(R)}function go(){return[]}function oo(){return!1}e.exports=gu})(d3,d3.exports);var AJ=d3.exports,cJ=AR(AJ);function F6(e,n,t){const 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 D6(e,n,t,r){const 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 L6(e,n,t){const 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 dJ(e,n){const t=[],r=[],i=[];function o(s){return{circle:n(s,.8),line:n(s,.6),polygon:n(s,.3),polygonOutline:n(s,.6),default:n(s,1)}}return Object.keys(e).forEach(s=>{const a=e[s];if(!a||a.length===0){const h=o(s);r.push(F6(h.circle,s)),i.push(L6(h.line,s)),t.push(D6(h.polygon,h.polygonOutline,s))}else a.forEach(h=>{const g=o(h);r.push(F6(g.circle,s,h)),i.push(L6(g.line,s,h)),t.push(D6(g.polygon,g.polygonOutline,s,h))})}),t.concat(i).concat(r)}function hJ(e,n,t){t=Object.assign({backgroundColor:"#fff"},t);const r={id:"background",type:"background",paint:{"background-color":t.backgroundColor}},i={};return Object.keys(e.sources).forEach(o=>{const s=e.sources[o];(s.type==="vector"||s.type==="geojson")&&(i[o]=s)}),Object.assign(e,{layers:[r].concat(n),sources:i})}var A9={polygonLayer:D6,lineLayer:L6,circleLayer:F6,generateInspectStyle:hJ,generateColoredLayers:dJ};class fJ{constructor(n){n=Object.assign({show:!0,onToggle(){}},n),this._btn=this.createButton(),this._btn.onclick=n.onToggle,this.elem=this.createContainer(this._btn,n.show)}createButton(){const n=document.createElement("button");return n.className="maplibregl-ctrl-icon maplibregl-ctrl-inspect",n.type="button",n.setAttribute("aria-label","Inspect"),n}createContainer(n,t){const r=document.createElement("div");return r.className="maplibregl-ctrl maplibregl-ctrl-group",r.appendChild(n),t||(r.style.display="none"),r}setInspectIcon(){this._btn.className="maplibregl-ctrl-icon maplibregl-ctrl-inspect"}setMapIcon(){this._btn.className="maplibregl-ctrl-icon maplibregl-ctrl-map"}}function pJ(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 c9(e,n){return`<div class="maplibregl-inspect_property"><div class="maplibregl-inspect_property-name">${e}</div><div class="maplibregl-inspect_property-value">${pJ(n)}</div></div>`}function mJ(e){return`<div class="maplibregl-inspect_layer">${e}</div>`}function gJ(e){const n=mJ(e.layer["source-layer"]||e.layer.source),t=c9("$type",e.geometry.type),r=Object.keys(e.properties).map(i=>c9(i,e.properties[i]));return[n,t].concat(r).join("")}function yJ(e){return e.map(n=>`<div class="maplibregl-inspect_feature">${gJ(n)}</div>`).join("")}function vJ(e){return`<div class="maplibregl-inspect_popup">${yJ(e)}</div>`}var U6={exports:{}};(function(e,n){(function(t,r){{var i=r();e&&e.exports&&(n=e.exports=i),n.randomColor=i}})(o_,function(){var t=null,r={};$();var i=[],o=function(V){if(V=V||{},V.seed!==void 0&&V.seed!==null&&V.seed===parseInt(V.seed,10))t=V.seed;else if(typeof V.seed=="string")t=me(V.seed);else{if(V.seed!==void 0&&V.seed!==null)throw new TypeError("The seed value must be an integer or string");t=null}var ae,ye,Oe;if(V.count!==null&&V.count!==void 0){for(var De=V.count,He=[],ke=0;ke<V.count;ke++)i.push(!1);for(V.count=null;De>He.length;){var nt=o(V);t!==null&&(V.seed=t),He.push(nt)}return V.count=De,He}return ae=s(V),ye=a(ae,V),Oe=h(ae,ye,V),g([ae,ye,Oe],V)};function s(V){if(i.length>0){var ae=he(V.hue),ye=L(ae),Oe=(ae[1]-ae[0])/i.length,De=parseInt((ye-ae[0])/Oe);i[De]===!0?De=(De+2)%i.length:i[De]=!0;var He=(ae[0]+De*Oe)%359,ke=(ae[0]+(De+1)*Oe)%359;return ae=[He,ke],ye=L(ae),ye<0&&(ye=360+ye),ye}else{var ae=B(V.hue);return ye=L(ae),ye<0&&(ye=360+ye),ye}}function a(V,ae){if(ae.hue==="monochrome")return 0;if(ae.luminosity==="random")return L([0,100]);var ye=k(V),Oe=ye[0],De=ye[1];switch(ae.luminosity){case"bright":Oe=55;break;case"dark":Oe=De-10;break;case"light":De=55;break}return L([Oe,De])}function h(V,ae,ye){var Oe=C(V,ae),De=100;switch(ye.luminosity){case"dark":De=Oe+20;break;case"light":Oe=(De+Oe)/2;break;case"random":Oe=0,De=100;break}return L([Oe,De])}function g(V,ae){switch(ae.format){case"hsvArray":return V;case"hslArray":return ce(V);case"hsl":var ye=ce(V);return"hsl("+ye[0]+", "+ye[1]+"%, "+ye[2]+"%)";case"hsla":var Oe=ce(V),ke=ae.alpha||Math.random();return"hsla("+Oe[0]+", "+Oe[1]+"%, "+Oe[2]+"%, "+ke+")";case"rgbArray":return q(V);case"rgb":var De=q(V);return"rgb("+De.join(", ")+")";case"rgba":var He=q(V),ke=ae.alpha||Math.random();return"rgba("+He.join(", ")+", "+ke+")";default:return J(V)}}function C(V,ae){for(var ye=P(V).lowerBounds,Oe=0;Oe<ye.length-1;Oe++){var De=ye[Oe][0],He=ye[Oe][1],ke=ye[Oe+1][0],nt=ye[Oe+1][1];if(ae>=De&&ae<=ke){var be=(nt-He)/(ke-De),Bt=He-be*De;return be*ae+Bt}}return 0}function B(V){if(typeof parseInt(V)=="number"){var ae=parseInt(V);if(ae<360&&ae>0)return[ae,ae]}if(typeof V=="string"){if(r[V]){var ye=r[V];if(ye.hueRange)return ye.hueRange}else if(V.match(/^#?([0-9A-F]{3}|[0-9A-F]{6})$/i)){var Oe=oe(V)[0];return[Oe,Oe]}}return[0,360]}function k(V){return P(V).saturationRange}function P(V){V>=334&&V<=360&&(V-=360);for(var ae in r){var ye=r[ae];if(ye.hueRange&&V>=ye.hueRange[0]&&V<=ye.hueRange[1])return r[ae]}return"Color not found"}function L(V){if(t===null){var ae=.618033988749895,ye=Math.random();return ye+=ae,ye%=1,Math.floor(V[0]+ye*(V[1]+1-V[0]))}else{var Oe=V[1]||1,De=V[0]||0;t=(t*9301+49297)%233280;var He=t/233280;return Math.floor(De+He*(Oe-De))}}function J(V){var ae=q(V);function ye(De){var He=De.toString(16);return He.length==1?"0"+He:He}var Oe="#"+ye(ae[0])+ye(ae[1])+ye(ae[2]);return Oe}function N(V,ae,ye){var Oe=ye[0][0],De=ye[ye.length-1][0],He=ye[ye.length-1][1],ke=ye[0][1];r[V]={hueRange:ae,lowerBounds:ye,saturationRange:[Oe,De],brightnessRange:[He,ke]}}function $(){N("monochrome",null,[[0,0],[100,0]]),N("red",[-26,18],[[20,100],[30,92],[40,89],[50,85],[60,78],[70,70],[80,60],[90,55],[100,50]]),N("orange",[18,46],[[20,100],[30,93],[40,88],[50,86],[60,85],[70,70],[100,70]]),N("yellow",[46,62],[[25,100],[40,94],[50,89],[60,86],[70,84],[80,82],[90,80],[100,75]]),N("green",[62,178],[[30,100],[40,90],[50,85],[60,81],[70,74],[80,64],[90,50],[100,40]]),N("blue",[178,257],[[20,100],[30,86],[40,80],[50,74],[60,60],[70,52],[80,44],[90,39],[100,35]]),N("purple",[257,282],[[20,100],[30,87],[40,79],[50,70],[60,65],[70,59],[80,52],[90,45],[100,42]]),N("pink",[282,334],[[20,100],[30,90],[40,86],[60,84],[80,80],[90,75],[100,73]])}function q(V){var ae=V[0];ae===0&&(ae=1),ae===360&&(ae=359),ae=ae/360;var ye=V[1]/100,Oe=V[2]/100,De=Math.floor(ae*6),He=ae*6-De,ke=Oe*(1-ye),nt=Oe*(1-He*ye),be=Oe*(1-(1-He)*ye),Bt=256,kt=256,Yt=256;switch(De){case 0:Bt=Oe,kt=be,Yt=ke;break;case 1:Bt=nt,kt=Oe,Yt=ke;break;case 2:Bt=ke,kt=Oe,Yt=be;break;case 3:Bt=ke,kt=nt,Yt=Oe;break;case 4:Bt=be,kt=ke,Yt=Oe;break;case 5:Bt=Oe,kt=ke,Yt=nt;break}var jt=[Math.floor(Bt*255),Math.floor(kt*255),Math.floor(Yt*255)];return jt}function oe(V){V=V.replace(/^#/,""),V=V.length===3?V.replace(/(.)/g,"$1$1"):V;var ae=parseInt(V.substr(0,2),16)/255,ye=parseInt(V.substr(2,2),16)/255,Oe=parseInt(V.substr(4,2),16)/255,De=Math.max(ae,ye,Oe),He=De-Math.min(ae,ye,Oe),ke=De?He/De:0;switch(De){case ae:return[60*((ye-Oe)/He%6)||0,ke,De];case ye:return[60*((Oe-ae)/He+2)||0,ke,De];case Oe:return[60*((ae-ye)/He+4)||0,ke,De]}}function ce(V){var ae=V[0],ye=V[1]/100,Oe=V[2]/100,De=(2-ye)*Oe;return[ae,Math.round(ye*Oe/(De<1?De:2-De)*1e4)/100,De/2*100]}function me(V){for(var ae=0,ye=0;ye!==V.length&&!(ae>=Number.MAX_SAFE_INTEGER);ye++)ae+=V.charCodeAt(ye);return ae}function he(V){if(isNaN(V)){if(typeof V=="string"){if(r[V]){var ye=r[V];if(ye.hueRange)return ye.hueRange}else if(V.match(/^#?([0-9A-F]{3}|[0-9A-F]{6})$/i)){var Oe=oe(V)[0];return P(Oe).hueRange}}}else{var ae=parseInt(V);if(ae<360&&ae>0)return P(V).hueRange}return[0,360]}return o})})(U6,U6.exports);var _J=U6.exports,CJ=AR(_J);function bJ(e,n){let t="bright",r;return/water|ocean|lake|sea|river/.test(e)&&(r="blue"),/state|country|place/.test(e)&&(r="pink"),/road|highway|transport|streets/.test(e)&&(r="orange"),/contour|building|earth/.test(e)&&(r="monochrome"),/building/.test(e)&&(t="dark"),/earth/.test(e)&&(t="light"),/contour|landuse/.test(e)&&(r="yellow"),/wood|forest|park|landcover|land|natural/.test(e)&&(r="green"),`rgba(${CJ({luminosity:t,hue:r,seed:e,format:"rgbArray"}).join(", ")}, ${n||"1"})`}var xJ={brightColor:bJ};function wJ(e){return e.metadata&&e.metadata["maplibregl-inspect:inspect"]}function MJ(e){return Object.assign(e,{metadata:Object.assign({},e.metadata,{"maplibregl-inspect:inspect":!0})})}class $B{constructor(n){if(this._onSourceChange=r=>{if(r.sourceDataType==="visibility"||!r.isSourceLoaded)return;const i=Object.assign({},this.sources);this._setSourcesFromMap(),!cJ(i,this.sources)&&Object.keys(this.sources).length>0&&setTimeout(()=>this.render(),1e3)},this._onStyleChange=()=>{const r=this._map.getStyle();wJ(r)||(this._originalStyle=r)},this._onRightClick=()=>{!this.options.showMapPopupOnHover&&!this.options.showInspectMapPopupOnHover&&!this.options.blockHoverPopupOnClick&&this._popup&&this._popup.remove()},this._onMousemove=r=>{if(this._showInspectMap){if(!this.options.showInspectMapPopup||r.type==="mousemove"&&!this.options.showInspectMapPopupOnHover)return;r.type==="click"&&this.options.showInspectMapPopupOnHover&&this.options.blockHoverPopupOnClick&&(this._popupBlocked=!this._popupBlocked)}else{if(!this.options.showMapPopup||r.type==="mousemove"&&!this.options.showMapPopupOnHover)return;r.type==="click"&&this.options.showMapPopupOnHover&&this.options.blockHoverPopupOnClick&&(this._popupBlocked=!this._popupBlocked)}if(!this._popupBlocked&&this._popup){let i;this.options.selectThreshold===0?i=r.point:i=[[r.point.x-this.options.selectThreshold,r.point.y+this.options.selectThreshold],[r.point.x+this.options.selectThreshold,r.point.y-this.options.selectThreshold]];const o=this._map.queryRenderedFeatures(i,this.options.queryParameters)||[];if(this._map.getCanvas().style.cursor=o.length?"pointer":"",!o.length)this._popup.remove();else{this._popup.setLngLat(r.lngLat);const s=this.options.renderPopup(o);typeof s=="string"?this._popup.setHTML(s):this._popup.setDOMContent(s),this._popup.addTo(this._map)}}},!(this instanceof $B))throw new Error("MaplibreInspect needs to be called with the new keyword");let t=null;window.maplibregl?t=new window.maplibregl.Popup({closeButton:!1,closeOnClick:!1}):n.popup||console.error("Maplibre GL JS can not be found. Make sure to include it or pass an initialized MaplibreGL Popup to MaplibreInspect 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:xJ.brightColor,buildInspectStyle:A9.generateInspectStyle,renderPopup:vJ,popup:t,selectThreshold:5,useInspectStyle:!0,queryParameters:{},sources:{},toggleCallback(){},manageStyleOutside:!1},n),this.sources=this.options.sources,this.assignLayerColor=this.options.assignLayerColor,this._popup=this.options.popup,this._popupBlocked=!1,this._showInspectMap=this.options.showInspectMap,this._toggle=new fJ({show:this.options.showInspectButton,onToggle:()=>this.toggleInspector()})}toggleInspector(){this._showInspectMap=!this._showInspectMap,this._popupBlocked=!1,this.options.toggleCallback(this._showInspectMap),this.render()}_inspectStyle(){const n=A9.generateColoredLayers(this.sources,this.assignLayerColor);return this.options.buildInspectStyle(this._map.getStyle(),n,{backgroundColor:this.options.backgroundColor})}render(){this._showInspectMap?(this.options.useInspectStyle&&this._map.setStyle(MJ(this._inspectStyle())),this._toggle.setMapIcon()):this._originalStyle&&(this._popup&&this._popup.remove(),this.options.useInspectStyle&&this._map.setStyle(this._originalStyle),this._toggle.setInspectIcon())}_setSourcesFromMap(){const n=Object.keys(this._map.getStyle().sources);Object.keys(this._map.style.sourceCaches).forEach(t=>{const r=this._map.style.sourceCaches[t]||{_source:{}},i=r._source.vectorLayerIds;i?this.sources[t]=i:r._source.type==="geojson"&&(this.sources[t]=[])}),Object.keys(this.sources).forEach(t=>{n.indexOf(t)===-1&&delete this.sources[t]})}setOriginalStyle(n){this._originalStyle=n,this._setSourcesFromMap()}onAdd(n){return this._map=n,Object.keys(this.sources).length===0&&(n.on("tiledata",this._onSourceChange),n.on("sourcedata",this._onSourceChange)),n.on("styledata",this._onStyleChange),n.on("load",this._onStyleChange),n.on("mousemove",this._onMousemove),n.on("click",this._onMousemove),n.on("contextmenu",this._onRightClick),this._toggle.elem}onRemove(){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),this._map.off("contextmenu",this._onRightClick);const n=this._toggle.elem;n.parentNode.removeChild(n),this._map=void 0}}var R6={exports:{}};(function(e,n){(function(t,r){{var i=r();e&&e.exports&&(n=e.exports=i),n.randomColor=i}})(ch,function(){var t=null,r={};$();var i=[],o=function(V){if(V=V||{},V.seed!==void 0&&V.seed!==null&&V.seed===parseInt(V.seed,10))t=V.seed;else if(typeof V.seed=="string")t=me(V.seed);else{if(V.seed!==void 0&&V.seed!==null)throw new TypeError("The seed value must be an integer or string");t=null}var ae,ye,Oe;if(V.count!==null&&V.count!==void 0){for(var De=V.count,He=[],ke=0;ke<V.count;ke++)i.push(!1);for(V.count=null;De>He.length;){var nt=o(V);t!==null&&(V.seed=t),He.push(nt)}return V.count=De,He}return ae=s(V),ye=a(ae,V),Oe=h(ae,ye,V),g([ae,ye,Oe],V)};function s(V){if(i.length>0){var ae=he(V.hue),ye=L(ae),Oe=(ae[1]-ae[0])/i.length,De=parseInt((ye-ae[0])/Oe);i[De]===!0?De=(De+2)%i.length:i[De]=!0;var He=(ae[0]+De*Oe)%359,ke=(ae[0]+(De+1)*Oe)%359;return ae=[He,ke],ye=L(ae),ye<0&&(ye=360+ye),ye}else{var ae=B(V.hue);return ye=L(ae),ye<0&&(ye=360+ye),ye}}function a(V,ae){if(ae.hue==="monochrome")return 0;if(ae.luminosity==="random")return L([0,100]);var ye=k(V),Oe=ye[0],De=ye[1];switch(ae.luminosity){case"bright":Oe=55;break;case"dark":Oe=De-10;break;case"light":De=55;break}return L([Oe,De])}function h(V,ae,ye){var Oe=C(V,ae),De=100;switch(ye.luminosity){case"dark":De=Oe+20;break;case"light":Oe=(De+Oe)/2;break;case"random":Oe=0,De=100;break}return L([Oe,De])}function g(V,ae){switch(ae.format){case"hsvArray":return V;case"hslArray":return ce(V);case"hsl":var ye=ce(V);return"hsl("+ye[0]+", "+ye[1]+"%, "+ye[2]+"%)";case"hsla":var Oe=ce(V),ke=ae.alpha||Math.random();return"hsla("+Oe[0]+", "+Oe[1]+"%, "+Oe[2]+"%, "+ke+")";case"rgbArray":return q(V);case"rgb":var De=q(V);return"rgb("+De.join(", ")+")";case"rgba":var He=q(V),ke=ae.alpha||Math.random();return"rgba("+He.join(", ")+", "+ke+")";default:return J(V)}}function C(V,ae){for(var ye=P(V).lowerBounds,Oe=0;Oe<ye.length-1;Oe++){var De=ye[Oe][0],He=ye[Oe][1],ke=ye[Oe+1][0],nt=ye[Oe+1][1];if(ae>=De&&ae<=ke){var be=(nt-He)/(ke-De),Bt=He-be*De;return be*ae+Bt}}return 0}function B(V){if(typeof parseInt(V)=="number"){var ae=parseInt(V);if(ae<360&&ae>0)return[ae,ae]}if(typeof V=="string"){if(r[V]){var ye=r[V];if(ye.hueRange)return ye.hueRange}else if(V.match(/^#?([0-9A-F]{3}|[0-9A-F]{6})$/i)){var Oe=oe(V)[0];return[Oe,Oe]}}return[0,360]}function k(V){return P(V).saturationRange}function P(V){V>=334&&V<=360&&(V-=360);for(var ae in r){var ye=r[ae];if(ye.hueRange&&V>=ye.hueRange[0]&&V<=ye.hueRange[1])return r[ae]}return"Color not found"}function L(V){if(t===null){var ae=.618033988749895,ye=Math.random();return ye+=ae,ye%=1,Math.floor(V[0]+ye*(V[1]+1-V[0]))}else{var Oe=V[1]||1,De=V[0]||0;t=(t*9301+49297)%233280;var He=t/233280;return Math.floor(De+He*(Oe-De))}}function J(V){var ae=q(V);function ye(De){var He=De.toString(16);return He.length==1?"0"+He:He}var Oe="#"+ye(ae[0])+ye(ae[1])+ye(ae[2]);return Oe}function N(V,ae,ye){var Oe=ye[0][0],De=ye[ye.length-1][0],He=ye[ye.length-1][1],ke=ye[0][1];r[V]={hueRange:ae,lowerBounds:ye,saturationRange:[Oe,De],brightnessRange:[He,ke]}}function $(){N("monochrome",null,[[0,0],[100,0]]),N("red",[-26,18],[[20,100],[30,92],[40,89],[50,85],[60,78],[70,70],[80,60],[90,55],[100,50]]),N("orange",[18,46],[[20,100],[30,93],[40,88],[50,86],[60,85],[70,70],[100,70]]),N("yellow",[46,62],[[25,100],[40,94],[50,89],[60,86],[70,84],[80,82],[90,80],[100,75]]),N("green",[62,178],[[30,100],[40,90],[50,85],[60,81],[70,74],[80,64],[90,50],[100,40]]),N("blue",[178,257],[[20,100],[30,86],[40,80],[50,74],[60,60],[70,52],[80,44],[90,39],[100,35]]),N("purple",[257,282],[[20,100],[30,87],[40,79],[50,70],[60,65],[70,59],[80,52],[90,45],[100,42]]),N("pink",[282,334],[[20,100],[30,90],[40,86],[60,84],[80,80],[90,75],[100,73]])}function q(V){var ae=V[0];ae===0&&(ae=1),ae===360&&(ae=359),ae=ae/360;var ye=V[1]/100,Oe=V[2]/100,De=Math.floor(ae*6),He=ae*6-De,ke=Oe*(1-ye),nt=Oe*(1-He*ye),be=Oe*(1-(1-He)*ye),Bt=256,kt=256,Yt=256;switch(De){case 0:Bt=Oe,kt=be,Yt=ke;break;case 1:Bt=nt,kt=Oe,Yt=ke;break;case 2:Bt=ke,kt=Oe,Yt=be;break;case 3:Bt=ke,kt=nt,Yt=Oe;break;case 4:Bt=be,kt=ke,Yt=Oe;break;case 5:Bt=Oe,kt=ke,Yt=nt;break}var jt=[Math.floor(Bt*255),Math.floor(kt*255),Math.floor(Yt*255)];return jt}function oe(V){V=V.replace(/^#/,""),V=V.length===3?V.replace(/(.)/g,"$1$1"):V;var ae=parseInt(V.substr(0,2),16)/255,ye=parseInt(V.substr(2,2),16)/255,Oe=parseInt(V.substr(4,2),16)/255,De=Math.max(ae,ye,Oe),He=De-Math.min(ae,ye,Oe),ke=De?He/De:0;switch(De){case ae:return[60*((ye-Oe)/He%6)||0,ke,De];case ye:return[60*((Oe-ae)/He+2)||0,ke,De];case Oe:return[60*((ae-ye)/He+4)||0,ke,De]}}function ce(V){var ae=V[0],ye=V[1]/100,Oe=V[2]/100,De=(2-ye)*Oe;return[ae,Math.round(ye*Oe/(De<1?De:2-De)*1e4)/100,De/2*100]}function me(V){for(var ae=0,ye=0;ye!==V.length&&!(ae>=Number.MAX_SAFE_INTEGER);ye++)ae+=V.charCodeAt(ye);return ae}function he(V){if(isNaN(V)){if(typeof V=="string"){if(r[V]){var ye=r[V];if(ye.hueRange)return ye.hueRange}else if(V.match(/^#?([0-9A-F]{3}|[0-9A-F]{6})$/i)){var Oe=oe(V)[0];return P(Oe).hueRange}}}else{var ae=parseInt(V);if(ae<360&&ae>0)return P(V).hueRange}return[0,360]}return o})})(R6,R6.exports);var SJ=R6.exports;const EJ=fa(SJ);function OJ(e,n){let t="bright",r;return/water|ocean|lake|sea|river/.test(e)&&(r="blue"),/state|country|place/.test(e)&&(r="pink"),/road|highway|transport|streets/.test(e)&&(r="orange"),/contour|building|earth/.test(e)&&(r="monochrome"),/building/.test(e)&&(t="dark"),/earth/.test(e)&&(t="light"),/contour|landuse/.test(e)&&(r="yellow"),/wood|forest|park|landcover|land|natural/.test(e)&&(r="green"),`rgba(${EJ({luminosity:t,hue:r,seed:e,format:"rgbArray"}).join(", ")}, ${n||"1"})`}const cR={brightColor:OJ};var dR={exports:{}},BJ="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",kJ=BJ,IJ=kJ;function hR(){}function fR(){}fR.resetWarningCache=hR;var TJ=function(){function e(r,i,o,s,a,h){if(h!==IJ){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:fR,resetWarningCache:hR};return t.PropTypes=t,t};dR.exports=TJ();var hh=dR.exports;const Rr=fa(hh);var d9=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 KJ(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 jm=function(n,t){var r=n.children,i=n.color,o=n.size,s=n.style,a=n.width,h=n.height,g=KJ(n,["children","color","size","style","width","height"]),C=t.reactIconBase,B=C===void 0?{}:C,k=o||B.size||"1em";return Sn.createElement("svg",d9({children:r,fill:"currentColor",preserveAspectRatio:"xMidYMid meet",height:h||k,width:a||k},B,g,{style:d9({verticalAlign:"middle",color:i||B.color},B.style||{},s)}))};jm.propTypes={color:Rr.string,size:Rr.oneOfType([Rr.string,Rr.number]),width:Rr.oneOfType([Rr.string,Rr.number]),height:Rr.oneOfType([Rr.string,Rr.number]),style:Rr.object};jm.contextTypes={reactIconBase:Rr.shape(jm.propTypes)};function h3(){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 h3=function(){return s},s}h3();class PJ extends Sn.Component{render(){return h3().f[0]++,h3().s[0]++,G.jsx(jm,{viewBox:"0 0 20 20",...this.props,children:G.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 f3(){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 f3=function(){return s},s}f3();class vx extends Sn.Component{render(){return f3().f[0]++,f3().s[0]++,G.jsx(jm,{viewBox:"0 0 20 20",...this.props,children:G.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 p3(){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 p3=function(){return s},s}p3();class FJ extends Sn.Component{render(){return p3().f[0]++,p3().s[0]++,G.jsx(jm,{viewBox:"0 0 20 20",...this.props,children:G.jsx("g",{transform:"matrix(1.2718518,0,0,1.2601269,16.559526,-7.4065264)",children:G.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 m3(){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 m3=function(){return s},s}m3();class h9 extends Sn.Component{render(){return m3().f[0]++,m3().s[0]++,G.jsx(jm,{viewBox:"0 0 20 20",...this.props,children:G.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 g3(){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 g3=function(){return s},s}g3();class DJ extends Sn.Component{render(){return g3().f[0]++,g3().s[0]++,G.jsx(jm,{viewBox:"0 0 20 20",...this.props,children:G.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 Ny(e){return sl({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 LJ(e){return sl({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 UJ(e){return sl({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 RJ(e){return sl({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 zJ(e){return sl({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 jJ(e){return sl({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 WJ(e){return sl({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 NJ(e){return sl({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 GJ(e){return sl({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 pR(e){return sl({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 QJ(e){return sl({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 $J(e){return sl({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 YJ(e){return sl({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 qJ(e){return sl({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 z6(e){return sl({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 HJ(e){return sl({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 VJ(e){return sl({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 ZJ(e){return sl({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 XJ(e){return sl({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 JJ(e){return sl({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 eee(e){return sl({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 tee(e){return sl({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 y3(){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 y3=function(){return s},s}y3();class nee extends Sn.Component{render(){return y3().f[0]++,y3().s[0]++,G.jsx(tee,{...this.props})}}function fs(){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 fs=function(){return s},s}fs();class mR extends Sn.Component{render(){fs().f[0]++;const n=(fs().s[0]++,{style:this.props.style});switch(fs().s[1]++,this.props.type){case"fill-extrusion":return fs().b[0][0]++,fs().s[2]++,G.jsx(h9,{...n});case"raster":return fs().b[0][1]++,fs().s[3]++,G.jsx(vx,{...n});case"hillshade":return fs().b[0][2]++,fs().s[4]++,G.jsx(vx,{...n});case"heatmap":return fs().b[0][3]++,fs().s[5]++,G.jsx(vx,{...n});case"fill":return fs().b[0][4]++,fs().s[6]++,G.jsx(vx,{...n});case"background":return fs().b[0][5]++,fs().s[7]++,G.jsx(h9,{...n});case"line":return fs().b[0][6]++,fs().s[8]++,G.jsx(PJ,{...n});case"symbol":return fs().b[0][7]++,fs().s[9]++,G.jsx(FJ,{...n});case"circle":return fs().b[0][8]++,fs().s[10]++,G.jsx(DJ,{...n});default:return fs().b[0][9]++,fs().s[11]++,G.jsx(nee,{...n})}}}function br(){var e="/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlLayerPopup.tsx",n="ea1e9940e142b9a2a1c672f6983f6f5748c841e6",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:18,column:5}},3:{start:{line:8,column:22},end:{line:8,column:51}},4:{start:{line:9,column:4},end:{line:17,column:5}},5:{start:{line:10,column:6},end:{line:10,column:43}},6:{start:{line:11,column:28},end:{line:11,column:91}},7:{start:{line:11,column:59},end:{line:11,column:90}},8:{start:{line:12,column:6},end:{line:12,column:65}},9:{start:{line:14,column:6},end:{line:14,column:52}},10:{start:{line:15,column:6},end:{line:15,column:39}},11:{start:{line:16,column:6},end:{line:16,column:45}},12:{start:{line:19,column:2},end:{line:19,column:17}},13:{start:{line:23,column:4},end:{line:25,column:5}},14:{start:{line:24,column:6},end:{line:24,column:13}},15:{start:{line:26,column:4},end:{line:44,column:5}},16:{start:{line:27,column:25},end:{line:27,column:44}},17:{start:{line:28,column:6},end:{line:30,column:7}},18:{start:{line:29,column:8},end:{line:29,column:48}},19:{start:{line:31,column:6},end:{line:33,column:7}},20:{start:{line:32,column:8},end:{line:32,column:48}},21:{start:{line:34,column:6},end:{line:36,column:7}},22:{start:{line:35,column:8},end:{line:35,column:48}},23:{start:{line:37,column:6},end:{line:39,column:7}},24:{start:{line:38,column:8},end:{line:38,column:58}},25:{start:{line:40,column:6},end:{line:40,column:21}},26:{start:{line:42,column:6},end:{line:42,column:63}},27:{start:{line:43,column:6},end:{line:43,column:21}},28:{start:{line:47,column:20},end:{line:47,column:67}},29:{start:{line:48,column:18},end:{line:93,column:6}},30:{start:{line:49,column:21},end:{line:88,column:8}},31:{start:{line:50,column:29},end:{line:50,column:76}},32:{start:{line:51,column:8},end:{line:87,column:10}},33:{start:{line:68,column:20},end:{line:68,column:63}},34:{start:{line:89,column:6},end:{line:92,column:26}},35:{start:{line:94,column:4},end:{line:94,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:20,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:18,column:3}},line:7},2:{name:"(anonymous_2)",decl:{start:{line:11,column:52},end:{line:11,column:53}},loc:{start:{line:11,column:59},end:{line:11,column:90}},line:11},3:{name:"(anonymous_3)",decl:{start:{line:22,column:2},end:{line:22,column:3}},loc:{start:{line:22,column:35},end:{line:45,column:3}},line:22},4:{name:"(anonymous_4)",decl:{start:{line:46,column:2},end:{line:46,column:3}},loc:{start:{line:46,column:11},end:{line:95,column:3}},line:46},5:{name:"(anonymous_5)",decl:{start:{line:48,column:43},end:{line:48,column:44}},loc:{start:{line:48,column:62},end:{line:93,column:5}},line:48},6:{name:"(anonymous_6)",decl:{start:{line:49,column:48},end:{line:49,column:49}},loc:{start:{line:49,column:66},end:{line:88,column:7}},line:49},7:{name:"(anonymous_7)",decl:{start:{line:67,column:27},end:{line:67,column:28}},loc:{start:{line:67,column:33},end:{line:69,column:19}},line:67}},branchMap:{0:{loc:{start:{line:9,column:4},end:{line:17,column:5}},type:"if",locations:[{start:{line:9,column:4},end:{line:17,column:5}},{start:{line:13,column:11},end:{line:17,column:5}}],line:9},1:{loc:{start:{line:14,column:27},end:{line:14,column:51}},type:"binary-expr",locations:[{start:{line:14,column:27},end:{line:14,column:45}},{start:{line:14,column:49},end:{line:14,column:51}}],line:14},2:{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},3:{loc:{start:{line:28,column:6},end:{line:30,column:7}},type:"if",locations:[{start:{line:28,column:6},end:{line:30,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:28},4:{loc:{start:{line:28,column:10},end:{line:28,column:64}},type:"binary-expr",locations:[{start:{line:28,column:10},end:{line:28,column:36}},{start:{line:28,column:40},end:{line:28,column:64}}],line:28},5:{loc:{start:{line:31,column:6},end:{line:33,column:7}},type:"if",locations:[{start:{line:31,column:6},end:{line:33,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:31},6:{loc:{start:{line:31,column:10},end:{line:31,column:64}},type:"binary-expr",locations:[{start:{line:31,column:10},end:{line:31,column:36}},{start:{line:31,column:40},end:{line:31,column:64}}],line:31},7:{loc:{start:{line:34,column:6},end:{line:36,column:7}},type:"if",locations:[{start:{line:34,column:6},end:{line:36,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:34},8:{loc:{start:{line:34,column:10},end:{line:34,column:64}},type:"binary-expr",locations:[{start:{line:34,column:10},end:{line:34,column:36}},{start:{line:34,column:40},end:{line:34,column:64}}],line:34},9:{loc:{start:{line:37,column:6},end:{line:39,column:7}},type:"if",locations:[{start:{line:37,column:6},end:{line:39,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:37},10:{loc:{start:{line:37,column:10},end:{line:37,column:84}},type:"binary-expr",locations:[{start:{line:37,column:10},end:{line:37,column:46}},{start:{line:37,column:50},end:{line:37,column:84}}],line:37},11:{loc:{start:{line:71,column:20},end:{line:75,column:24}},type:"binary-expr",locations:[{start:{line:71,column:20},end:{line:71,column:38}},{start:{line:71,column:58},end:{line:75,column:24}}],line:71},12:{loc:{start:{line:77,column:20},end:{line:80,column:24}},type:"binary-expr",locations:[{start:{line:77,column:20},end:{line:77,column:35}},{start:{line:77,column:55},end:{line:80,column:24}}],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},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/MapMaplibreGlLayerPopup.tsx"],names:[],mappings:"AA8EU,cAkBsB,YAlBtB;AA9EV,OAAO,WAAW;AAClB,OAAO,eAAe;AAGtB,SAAS,2BAA2B,UAA4B;AAC9D,QAAM,UAA6C,CAAC;AAEpD,QAAM,mBAA4C,CAAC;AAEnD,WAAS,QAAQ,aAAW;AAC1B,UAAM,YAAY,QAAQ,MAAM,cAAc;AAC9C,QAAG,OAAO,UAAU,eAAe,KAAK,kBAAkB,QAAQ,MAAM,EAAE,GAAG;AAC3E,uBAAiB,QAAQ,MAAM,EAAE;AAEjC,YAAM,gBAAgB,QAAQ,SAAS,EAAE,KAAK,CAAC,MAAsB,EAAE,MAAM,OAAO,QAAQ,MAAM,EAAE;AAEpG,oBAAe,UAAU,iBAAiB,QAAQ,MAAM,EAAE;AAAA,IAC5D,OAAO;AACL,cAAQ,SAAS,IAAI,QAAQ,SAAS,KAAK,CAAC;AAC5C,cAAQ,SAAS,EAAE,KAAK,OAAO;AAE/B,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;AAEjC,UAAG,gBAAgB,cAAc,WAAW,YAAY,GAAG;AACzD,eAAO,OAAO,WAAW,YAAY,CAAC;AAAA,MACxC;AACA,UAAI,gBAAgB,cAAc,WAAW,YAAY,GAAG;AAC1D,eAAO,OAAO,WAAW,YAAY,CAAC;AAAA,MACxC;AACA,UAAI,gBAAgB,cAAc,WAAW,YAAY,GAAG;AAC1D,eAAO,OAAO,WAAW,YAAY,CAAC;AAAA,MACxC;AACA,UAAI,0BAA0B,cAAc,WAAW,sBAAsB,GAAG;AAC9E,eAAO,OAAO,WAAW,sBAAsB,CAAC;AAAA,MAClD;AAEA,aAAO;AAAA,IACT,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:"ea1e9940e142b9a2a1c672f6983f6f5748c841e6"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return br=function(){return s},s}br();function ree(e){br().f[0]++;const n=(br().s[0]++,{}),t=(br().s[1]++,{});return br().s[2]++,e.forEach(r=>{br().f[1]++;const i=(br().s[3]++,r.layer["source-layer"]);if(br().s[4]++,Object.prototype.hasOwnProperty.call(t,r.layer.id)){br().b[0][0]++,br().s[5]++,t[r.layer.id]++;const o=(br().s[6]++,n[i].find(s=>(br().f[2]++,br().s[7]++,s.layer.id===r.layer.id)));br().s[8]++,o.counter=t[r.layer.id]}else br().b[0][1]++,br().s[9]++,n[i]=(br().b[1][0]++,n[i]||(br().b[1][1]++,[])),br().s[10]++,n[i].push(r),br().s[11]++,t[r.layer.id]=1}),br().s[12]++,n}class gR extends Sn.Component{_getFeatureColor(n,t){if(br().f[3]++,br().s[13]++,n.layer.paint)br().b[2][1]++;else{br().b[2][0]++,br().s[14]++;return}br().s[15]++;try{const r=(br().s[16]++,n.layer.paint);return br().s[17]++,br().b[4][0]++,"text-color"in r&&(br().b[4][1]++,r["text-color"])?(br().b[3][0]++,br().s[18]++,String(r["text-color"])):(br().b[3][1]++,br().s[19]++,br().b[6][0]++,"fill-color"in r&&(br().b[6][1]++,r["fill-color"])?(br().b[5][0]++,br().s[20]++,String(r["fill-color"])):(br().b[5][1]++,br().s[21]++,br().b[8][0]++,"line-color"in r&&(br().b[8][1]++,r["line-color"])?(br().b[7][0]++,br().s[22]++,String(r["line-color"])):(br().b[7][1]++,br().s[23]++,br().b[10][0]++,"fill-extrusion-color"in r&&(br().b[10][1]++,r["fill-extrusion-color"])?(br().b[9][0]++,br().s[24]++,String(r["fill-extrusion-color"])):(br().b[9][1]++,br().s[25]++,"black"))))}catch(r){return br().s[26]++,console.warn("Unable to get feature color, error:",r),br().s[27]++,"black"}}render(){br().f[4]++;const n=(br().s[28]++,ree(this.props.features)),t=(br().s[29]++,Object.keys(n).map(r=>{br().f[5]++;const i=(br().s[30]++,n[r].map((o,s)=>{br().f[6]++;const a=(br().s[31]++,this._getFeatureColor(o,this.props.zoom));return br().s[32]++,G.jsxs("div",{className:"maputnik-popup-layer",children:[G.jsx("div",{className:"maputnik-popup-layer__swatch",style:{background:a}}),G.jsxs("label",{className:"maputnik-popup-layer__label",onClick:()=>{br().f[7]++,br().s[33]++,this.props.onLayerSelect(o.layer.id)},children:[(br().b[11][0]++,o.layer.type&&(br().b[11][1]++,G.jsx(mR,{type:o.layer.type,style:{width:14,height:14,paddingRight:3}}))),o.layer.id,(br().b[12][0]++,o.counter&&(br().b[12][1]++,G.jsxs("span",{children:[" × ",o.counter]})))]})]},s)}));return br().s[34]++,G.jsxs("div",{children:[G.jsx("div",{className:"maputnik-popup-layer-id",children:r}),i]},r)}));return br().s[35]++,G.jsx("div",{className:"maputnik-feature-layer-popup",children:t})}}function di(){var e="/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlFeaturePropertyPopup.tsx",n="b2b277aba40a79a80b280d768bdec77ca8433f81",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlFeaturePropertyPopup.tsx",statementMap:{0:{start:{line:4,column:2},end:{line:5,column:17}},1:{start:{line:5,column:4},end:{line:5,column:17}},2:{start:{line:6,column:2},end:{line:7,column:34}},3:{start:{line:7,column:4},end:{line:7,column:34}},4:{start:{line:8,column:2},end:{line:9,column:28}},5:{start:{line:9,column:4},end:{line:9,column:28}},6:{start:{line:10,column:2},end:{line:10,column:15}},7:{start:{line:13,column:2},end:{line:16,column:12}},8:{start:{line:19,column:2},end:{line:35,column:12}},9:{start:{line:32,column:23},end:{line:32,column:55}},10:{start:{line:33,column:6},end:{line:33,column:74}},11:{start:{line:38,column:25},end:{line:38,column:27}},12:{start:{line:39,column:2},end:{line:52,column:5}},13:{start:{line:40,column:25},end:{line:42,column:6}},14:{start:{line:41,column:6},end:{line:41,column:156}},15:{start:{line:43,column:4},end:{line:51,column:5}},16:{start:{line:44,column:6},end:{line:44,column:35}},17:{start:{line:46,column:6},end:{line:50,column:7}},18:{start:{line:47,column:8},end:{line:47,column:58}},19:{start:{line:49,column:8},end:{line:49,column:60}},20:{start:{line:53,column:2},end:{line:53,column:24}},21:{start:{line:57,column:21},end:{line:57,column:66}},22:{start:{line:58,column:4},end:{line:58,column:250}}},fnMap:{0:{name:"displayValue",decl:{start:{line:3,column:9},end:{line:3,column:21}},loc:{start:{line:3,column:29},end:{line:11,column:1}},line:3},1:{name:"renderKeyValueTableRow",decl:{start:{line:12,column:9},end:{line:12,column:31}},loc:{start:{line:12,column:44},end:{line:17,column:1}},line:12},2:{name:"renderFeature",decl:{start:{line:18,column:9},end:{line:18,column:22}},loc:{start:{line:18,column:37},end:{line:36,column:1}},line:18},3:{name:"(anonymous_3)",decl:{start:{line:31,column:40},end:{line:31,column:41}},loc:{start:{line:31,column:58},end:{line:34,column:5}},line:31},4:{name:"removeDuplicatedFeatures",decl:{start:{line:37,column:9},end:{line:37,column:33}},loc:{start:{line:37,column:44},end:{line:54,column:1}},line:37},5:{name:"(anonymous_5)",decl:{start:{line:39,column:19},end:{line:39,column:20}},loc:{start:{line:39,column:32},end:{line:52,column:3}},line:39},6:{name:"(anonymous_6)",decl:{start:{line:40,column:50},end:{line:40,column:51}},loc:{start:{line:40,column:64},end:{line:42,column:5}},line:40},7:{name:"(anonymous_7)",decl:{start:{line:56,column:2},end:{line:56,column:3}},loc:{start:{line:56,column:11},end:{line:59,column:3}},line:56}},branchMap:{0:{loc:{start:{line:4,column:2},end:{line:5,column:17}},type:"if",locations:[{start:{line:4,column:2},end:{line:5,column:17}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:4},1:{loc:{start:{line:4,column:6},end:{line:4,column:52}},type:"binary-expr",locations:[{start:{line:4,column:6},end:{line:4,column:34}},{start:{line:4,column:38},end:{line:4,column:52}}],line:4},2:{loc:{start:{line:6,column:2},end:{line:7,column:34}},type:"if",locations:[{start:{line:6,column:2},end:{line:7,column:34}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:6},3:{loc:{start:{line:8,column:2},end:{line:9,column:28}},type:"if",locations:[{start:{line:8,column:2},end:{line:9,column:28}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:8},4:{loc:{start:{line:8,column:6},end:{line:8,column:89}},type:"binary-expr",locations:[{start:{line:8,column:6},end:{line:8,column:31}},{start:{line:8,column:35},end:{line:8,column:60}},{start:{line:8,column:64},end:{line:8,column:89}}],line:8},5:{loc:{start:{line:24,column:6},end:{line:27,column:10}},type:"binary-expr",locations:[{start:{line:24,column:6},end:{line:24,column:32}},{start:{line:24,column:52},end:{line:27,column:10}}],line:24},6:{loc:{start:{line:41,column:13},end:{line:41,column:155}},type:"binary-expr",locations:[{start:{line:41,column:13},end:{line:41,column:77}},{start:{line:41,column:81},end:{line:41,column:155}}],line:41},7:{loc:{start:{line:43,column:4},end:{line:51,column:5}},type:"if",locations:[{start:{line:43,column:4},end:{line:51,column:5}},{start:{line:45,column:11},end:{line:51,column:5}}],line:43},8:{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}},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,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:"AAkBS,SACL,KADK;AAlBT,OAAO,WAAW;AAQlB,SAAS,aAAa,OAAoD;AACxE,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,uBAAuB,KAAa,OAA2B;AACtE,SAAO,qBAAC,QACN;AAAA,wBAAC,QAAG,WAAU,6BAA6B,eAAI;AAAA,IAC/C,oBAAC,QAAG,WAAU,6BAA6B,iBAAM;AAAA,OAFnC,GAGhB;AACF;AAEA,SAAS,cAAc,SAAyB,KAAa;AAC3D,SAAO,qBAAC,MAAM,UAAN,EACN;AAAA,wBAAC,QACC,+BAAC,QAAG,SAAS,GAAG,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,GAC5L;AAAA,IACC,uBAAuB,SAAS,QAAQ,SAAS,IAAI;AAAA,IACrD,uBAAuB,cAAc,aAAa,QAAQ,EAAE,CAAC;AAAA,IAC7D,OAAO,KAAK,QAAQ,UAAU,EAAE,IAAI,kBAAgB;AACnD,YAAM,WAAW,QAAQ,WAAW,YAAY;AAChD,aAAO,uBAAuB,cAAc,aAAa,QAAQ,CAAC;AAAA,IACpE,CAAC;AAAA,OATyB,GAU5B;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,mCACpB,8BAAC,WAAM,WAAU,wBACf,8BAAC,WACE,mBAAS,IAAI,aAAa,GAC7B,GACF,GACF;AAAA,EACF;AACF;AAGA,eAAe;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"b2b277aba40a79a80b280d768bdec77ca8433f81"},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();function f9(e){return di().f[0]++,di().s[0]++,di().b[1][0]++,typeof e>"u"||(di().b[1][1]++,e===null)?(di().b[0][0]++,di().s[1]++,e):(di().b[0][1]++,di().s[2]++,e instanceof Date?(di().b[2][0]++,di().s[3]++,e.toLocaleString()):(di().b[2][1]++,di().s[4]++,di().b[4][0]++,typeof e=="object"||(di().b[4][1]++,typeof e=="number")||(di().b[4][2]++,typeof e=="string")?(di().b[3][0]++,di().s[5]++,e.toString()):(di().b[3][1]++,di().s[6]++,e)))}function AM(e,n){return di().f[1]++,di().s[7]++,G.jsxs("tr",{children:[G.jsx("td",{className:"maputnik-popup-table-cell",children:e}),G.jsx("td",{className:"maputnik-popup-table-cell",children:n})]},e)}function iee(e,n){return di().f[2]++,di().s[8]++,G.jsxs(Sn.Fragment,{children:[G.jsx("tr",{children:G.jsxs("td",{colSpan:2,className:"maputnik-popup-layer-id",children:[e.layer.source,": ",e.layer["source-layer"],(di().b[5][0]++,e.inspectModeCounter&&(di().b[5][1]++,G.jsxs("span",{children:[" × ",e.inspectModeCounter]})))]})}),AM("$type",e.geometry.type),AM("Feature ID",f9(e.id)),Object.keys(e.properties).map(t=>{di().f[3]++;const r=(di().s[9]++,e.properties[t]);return di().s[10]++,AM(t,f9(r))})]},n)}function oee(e){di().f[4]++;const n=(di().s[11]++,[]);return di().s[12]++,e.forEach(t=>{di().f[5]++;const r=(di().s[13]++,n.findIndex(i=>(di().f[6]++,di().s[14]++,di().b[6][0]++,t.layer["source-layer"]===i.layer["source-layer"]&&(di().b[6][1]++,JSON.stringify(t.properties)===JSON.stringify(i.properties)))));di().s[15]++,r===-1?(di().b[7][0]++,di().s[16]++,n.push(t)):(di().b[7][1]++,di().s[17]++,"inspectModeCounter"in n[r]?(di().b[8][0]++,di().s[18]++,n[r].inspectModeCounter++):(di().b[8][1]++,di().s[19]++,n[r].inspectModeCounter=2))}),di().s[20]++,n}class aee extends Sn.Component{render(){di().f[7]++;const n=(di().s[21]++,oee(this.props.features));return di().s[22]++,G.jsx("div",{className:"maputnik-feature-property-popup",children:G.jsx("table",{className:"maputnik-popup-table",children:G.jsx("tbody",{children:n.map(iee)})})})}}var yR={exports:{}},see={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]},vR={exports:{}},lee=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")},uee=lee,Aee=Array.prototype.concat,cee=Array.prototype.slice,p9=vR.exports=function(n){for(var t=[],r=0,i=n.length;r<i;r++){var o=n[r];uee(o)?t=Aee.call(t,cee.call(o)):t.push(o)}return t};p9.wrap=function(e){return function(){return e(p9(arguments))}};var dee=vR.exports,B_=see,GC=dee,_R=Object.hasOwnProperty,CR=Object.create(null);for(var cM in B_)_R.call(B_,cM)&&(CR[B_[cM]]=cM);var Fc=yR.exports={to:{},get:{}};Fc.get=function(e){var n=e.substring(0,3).toLowerCase(),t,r;switch(n){case"hsl":t=Fc.get.hsl(e),r="hsl";break;case"hwb":t=Fc.get.hwb(e),r="hwb";break;default:t=Fc.get.rgb(e),r="rgb";break}return t?{model:r,value:t}:null};Fc.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,h,g;if(a=e.match(t)){for(g=a[2],a=a[1],h=0;h<3;h++){var C=h*2;s[h]=parseInt(a.slice(C,C+2),16)}g&&(s[3]=parseInt(g,16)/255)}else if(a=e.match(n)){for(a=a[1],g=a[3],h=0;h<3;h++)s[h]=parseInt(a[h]+a[h],16);g&&(s[3]=parseInt(g+g,16)/255)}else if(a=e.match(r)){for(h=0;h<3;h++)s[h]=parseInt(a[h+1],0);a[4]&&(a[5]?s[3]=parseFloat(a[4])*.01:s[3]=parseFloat(a[4]))}else if(a=e.match(i)){for(h=0;h<3;h++)s[h]=Math.round(parseFloat(a[h+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]:_R.call(B_,a[1])?(s=B_[a[1]],s[3]=1,s):null:null;for(h=0;h<3;h++)s[h]=Km(s[h],0,255);return s[3]=Km(s[3],0,1),s};Fc.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=Km(parseFloat(t[2]),0,100),s=Km(parseFloat(t[3]),0,100),a=Km(isNaN(r)?1:r,0,1);return[i,o,s,a]}return null};Fc.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=Km(parseFloat(t[2]),0,100),s=Km(parseFloat(t[3]),0,100),a=Km(isNaN(r)?1:r,0,1);return[i,o,s,a]}return null};Fc.to.hex=function(){var e=GC(arguments);return"#"+_x(e[0])+_x(e[1])+_x(e[2])+(e[3]<1?_x(Math.round(e[3]*255)):"")};Fc.to.rgb=function(){var e=GC(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]+")"};Fc.to.rgb.percent=function(){var e=GC(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]+")"};Fc.to.hsl=function(){var e=GC(arguments);return e.length<4||e[3]===1?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"};Fc.to.hwb=function(){var e=GC(arguments),n="";return e.length>=4&&e[3]!==1&&(n=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+n+")"};Fc.to.keyword=function(e){return CR[e.slice(0,3)]};function Km(e,n,t){return Math.min(Math.max(n,e),t)}function _x(e){var n=Math.round(e).toString(16).toUpperCase();return n.length<2?"0"+n:n}var hee=yR.exports,fee={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 sC=fee,bR={};for(const e of Object.keys(sC))bR[sC[e]]=e;const $r={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 xR=$r;for(const e of Object.keys($r)){if(!("channels"in $r[e]))throw new Error("missing channels property: "+e);if(!("labels"in $r[e]))throw new Error("missing channel labels property: "+e);if($r[e].labels.length!==$r[e].channels)throw new Error("channel and label counts mismatch: "+e);const{channels:n,labels:t}=$r[e];delete $r[e].channels,delete $r[e].labels,Object.defineProperty($r[e],"channels",{value:n}),Object.defineProperty($r[e],"labels",{value:t})}$r.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,h;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?h=0:g<=.5?h=s/(o+i):h=s/(2-o-i),[a,h*100,g*100]};$r.rgb.hsv=function(e){let n,t,r,i,o;const s=e[0]/255,a=e[1]/255,h=e[2]/255,g=Math.max(s,a,h),C=g-Math.min(s,a,h),B=function(k){return(g-k)/6/C+1/2};return C===0?(i=0,o=0):(o=C/g,n=B(s),t=B(a),r=B(h),s===g?i=r-t:a===g?i=1/3+n-r:h===g&&(i=2/3+t-n),i<0?i+=1:i>1&&(i-=1)),[i*360,o*100,g*100]};$r.rgb.hwb=function(e){const n=e[0],t=e[1];let r=e[2];const i=$r.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]};$r.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 pee(e,n){return(e[0]-n[0])**2+(e[1]-n[1])**2+(e[2]-n[2])**2}$r.rgb.keyword=function(e){const n=bR[e];if(n)return n;let t=1/0,r;for(const i of Object.keys(sC)){const o=sC[i],s=pee(e,o);s<t&&(t=s,r=i)}return r};$r.keyword.rgb=function(e){return sC[e]};$r.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]};$r.rgb.lab=function(e){const n=$r.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]};$r.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,h=[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,h[g]=s*255;return h};$r.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]};$r.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),h=255*r*(1-t*(1-o));switch(r*=255,i){case 0:return[r,h,s];case 1:return[a,r,s];case 2:return[s,r,h];case 3:return[s,a,r];case 4:return[h,s,r];case 5:return[r,s,a]}};$r.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]};$r.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 h=t+o*(a-t);let g,C,B;switch(s){default:case 6:case 0:g=a,C=h,B=t;break;case 1:g=h,C=a,B=t;break;case 2:g=t,C=a,B=h;break;case 3:g=t,C=h,B=a;break;case 4:g=h,C=t,B=a;break;case 5:g=a,C=t,B=h;break}return[g*255,C*255,B*255]};$r.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]};$r.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]};$r.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]};$r.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,h=i**3,g=s**3;return o=a>.008856?a:(o-16/116)/7.787,i=h>.008856?h:(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]};$r.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]};$r.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]};$r.rgb.ansi16=function(e,n=null){const[t,r,i]=e;let o=n===null?$r.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};$r.hsv.ansi16=function(e){return $r.rgb.ansi16($r.hsv.rgb(e),e[2])};$r.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)};$r.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]};$r.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]};$r.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};$r.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]};$r.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,h;return s<1?a=o/(1-s):a=0,s<=0?h=0:i===n?h=(t-r)/s%6:i===t?h=2+(r-n)/s:h=4+(n-t)/s,h/=6,h%=1,[h*360,s*100,a*100]};$r.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]};$r.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]};$r.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 h=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 h=(1-t)*r,[(t*i[0]+h)*255,(t*i[1]+h)*255,(t*i[2]+h)*255]};$r.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]};$r.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]};$r.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]};$r.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]};$r.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};$r.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};$r.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};$r.gray.hsl=function(e){return[0,0,e[0]]};$r.gray.hsv=$r.gray.hsl;$r.gray.hwb=function(e){return[0,100,e[0]]};$r.gray.cmyk=function(e){return[0,0,0,e[0]]};$r.gray.lab=function(e){return[e[0],0,0]};$r.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};$r.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]};const v3=xR;function mee(){const e={},n=Object.keys(v3);for(let t=n.length,r=0;r<t;r++)e[n[r]]={distance:-1,parent:null};return e}function gee(e){const n=mee(),t=[e];for(n[e].distance=0;t.length;){const r=t.pop(),i=Object.keys(v3[r]);for(let o=i.length,s=0;s<o;s++){const a=i[s],h=n[a];h.distance===-1&&(h.distance=n[r].distance+1,h.parent=r,t.unshift(a))}}return n}function yee(e,n){return function(t){return n(e(t))}}function vee(e,n){const t=[n[e].parent,e];let r=v3[n[e].parent][e],i=n[e].parent;for(;n[i].parent;)t.unshift(n[i].parent),r=yee(v3[n[i].parent][i],r),i=n[i].parent;return r.conversion=t,r}var _ee=function(e){const n=gee(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]=vee(s,n))}return t};const j6=xR,Cee=_ee,bg={},bee=Object.keys(j6);function xee(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 wee(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}bee.forEach(e=>{bg[e]={},Object.defineProperty(bg[e],"channels",{value:j6[e].channels}),Object.defineProperty(bg[e],"labels",{value:j6[e].labels});const n=Cee(e);Object.keys(n).forEach(r=>{const i=n[r];bg[e][r]=wee(i),bg[e][r].raw=xee(i)})});var Mee=bg;const xg=hee,Kc=Mee,wR=["keyword","gray","hex"],W6={};for(const e of Object.keys(Kc))W6[[...Kc[e].labels].sort().join("")]=e;const _3={};function hu(e,n){if(!(this instanceof hu))return new hu(e,n);if(n&&n in wR&&(n=null),n&&!(n in Kc))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 hu)this.model=e.model,this.color=[...e.color],this.valpha=e.valpha;else if(typeof e=="string"){const i=xg.get(e);if(i===null)throw new Error("Unable to parse color from string: "+e);this.model=i.model,r=Kc[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=Kc[this.model].channels;const i=Array.prototype.slice.call(e,0,r);this.color=N6(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 W6))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=W6[o];const{labels:s}=Kc[this.model],a=[];for(t=0;t<s.length;t++)a.push(e[s[t]]);this.color=N6(a)}if(_3[this.model])for(r=Kc[this.model].channels,t=0;t<r;t++){const i=_3[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)}hu.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(e){let n=this.model in xg.to?this:this.rgb();n=n.round(typeof e=="number"?e:1);const t=n.valpha===1?n.color:[...n.color,this.valpha];return xg.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 xg.to.rgb.percent(t)},array(){return this.valpha===1?[...this.color]:[...this.color,this.valpha]},object(){const e={},{channels:n}=Kc[this.model],{labels:t}=Kc[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 hu([...this.color.map(Eee(e)),this.valpha],this.model)},alpha(e){return e!==void 0?new hu([...this.color,Math.max(0,Math.min(1,e))],this.model):this.valpha},red:nl("rgb",0,Gl(255)),green:nl("rgb",1,Gl(255)),blue:nl("rgb",2,Gl(255)),hue:nl(["hsl","hsv","hsl","hwb","hcg"],0,e=>(e%360+360)%360),saturationl:nl("hsl",1,Gl(100)),lightness:nl("hsl",2,Gl(100)),saturationv:nl("hsv",1,Gl(100)),value:nl("hsv",2,Gl(100)),chroma:nl("hcg",1,Gl(100)),gray:nl("hcg",2,Gl(100)),white:nl("hwb",1,Gl(100)),wblack:nl("hwb",2,Gl(100)),cyan:nl("cmyk",0,Gl(100)),magenta:nl("cmyk",1,Gl(100)),yellow:nl("cmyk",2,Gl(100)),black:nl("cmyk",3,Gl(100)),x:nl("xyz",0,Gl(95.047)),y:nl("xyz",1,Gl(100)),z:nl("xyz",2,Gl(108.833)),l:nl("lab",0,Gl(100)),a:nl("lab",1),b:nl("lab",2),keyword(e){return e!==void 0?new hu(e):Kc[this.model].keyword(this.color)},hex(e){return e!==void 0?new hu(e):xg.to.hex(this.rgb().round().color)},hexa(e){if(e!==void 0)return new hu(e);const n=this.rgb().round().color;let t=Math.round(this.valpha*255).toString(16).toUpperCase();return t.length===1&&(t="0"+t),xg.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 hu.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,h=1-a;return hu.rgb(a*t.red()+h*r.red(),a*t.green()+h*r.green(),a*t.blue()+h*r.blue(),t.alpha()*i+r.alpha()*(1-i))}};for(const e of Object.keys(Kc)){if(wR.includes(e))continue;const{channels:n}=Kc[e];hu.prototype[e]=function(...t){return this.model===e?new hu(this):t.length>0?new hu(t,e):new hu([...Oee(Kc[this.model][e].raw(this.color)),this.valpha],e)},hu[e]=function(...t){let r=t[0];return typeof r=="number"&&(r=N6(t,n)),new hu(r,e)}}function See(e,n){return Number(e.toFixed(n))}function Eee(e){return function(n){return See(n,e)}}function nl(e,n,t){e=Array.isArray(e)?e:[e];for(const r of e)(_3[r]||(_3[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 Gl(e){return function(n){return Math.max(0,Math.min(e,n))}}function Oee(e){return Array.isArray(e)?e:[e]}function N6(e,n){for(let t=0;t<n;t++)typeof e[t]!="number"&&(e[t]=0);return e}var Bee=hu;const G6=fa(Bee);function xa(){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 xa=function(){return s},s}xa();class kee{constructor(){an(this,"_map",(xa().s[0]++,void 0));an(this,"_container",(xa().s[1]++,void 0));an(this,"_textEl",(xa().s[2]++,null))}onAdd(n){return xa().f[0]++,xa().s[3]++,this._map=n,xa().s[4]++,this._container=document.createElement("div"),xa().s[5]++,this._container.className="maplibregl-ctrl maplibregl-ctrl-group maplibregl-ctrl-zoom",xa().s[6]++,this._container.setAttribute("data-wd-key","maplibre:ctrl-zoom"),xa().s[7]++,this._container.innerHTML=`
Zoom: <span></span>
`,xa().s[8]++,this._textEl=this._container.querySelector("span"),xa().s[9]++,this.addEventListeners(),xa().s[10]++,this._container}updateZoomLevel(){xa().f[1]++,xa().s[11]++,this._textEl.innerHTML=this._map.getZoom().toFixed(2)}addEventListeners(){xa().f[2]++,xa().s[12]++,this._map.on("render",()=>(xa().f[3]++,xa().s[13]++,this.updateZoomLevel())),xa().s[14]++,this._map.on("zoomIn",()=>(xa().f[4]++,xa().s[15]++,this.updateZoomLevel())),xa().s[16]++,this._map.on("zoomOut",()=>(xa().f[5]++,xa().s[17]++,this.updateZoomLevel()))}onRemove(){xa().f[6]++,xa().s[18]++,this._container.parentNode.removeChild(this._container),xa().s[19]++,this._map=void 0}}function Q6(e,n,t){const 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 $6(e,n,t,r){const 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 Y6(e,n,t){const 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 Iee(e,n){const t=[],r=[],i=[];function o(s){return{circle:n(s,.8),line:n(s,.6),polygon:n(s,.3),polygonOutline:n(s,.6),default:n(s,1)}}return Object.keys(e).forEach(s=>{const a=e[s];if(!a||a.length===0){const h=o(s);r.push(Q6(h.circle,s)),i.push(Y6(h.line,s)),t.push($6(h.polygon,h.polygonOutline,s))}else a.forEach(h=>{const g=o(h);r.push(Q6(g.circle,s,h)),i.push(Y6(g.line,s,h)),t.push($6(g.polygon,g.polygonOutline,s,h))})}),t.concat(i).concat(r)}function Tee(e,n,t){t=Object.assign({backgroundColor:"#fff"},t);const r={id:"background",type:"background",paint:{"background-color":t.backgroundColor}},i={};return Object.keys(e.sources).forEach(o=>{const s=e.sources[o];(s.type==="vector"||s.type==="geojson")&&(i[o]=s)}),Object.assign(e,{layers:[r].concat(n),sources:i})}const dM={polygonLayer:$6,lineLayer:Y6,circleLayer:Q6,generateInspectStyle:Tee,generateColoredLayers:Iee};function Ti(){var e="/home/runner/work/maputnik/maputnik/src/libs/highlight.ts",n="c6691b5ca8d2cfebe44cf9e3718b8a44b922cf42",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:"AAAA,OAAO,cAAc;AACrB,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:"c6691b5ca8d2cfebe44cf9e3718b8a44b922cf42"},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 hM(e,n){return Ti().f[0]++,Ti().s[0]++,e.type==="circle"?(Ti().b[0][0]++,Ti().s[1]++,e.paint["circle-radius"]=3):(Ti().b[0][1]++,Ti().s[2]++,e.type==="line"?(Ti().b[1][0]++,Ti().s[3]++,e.paint["line-width"]=2):Ti().b[1][1]++),Ti().s[4]++,"filter"in n?(Ti().b[2][0]++,Ti().s[5]++,e.filter=n.filter):(Ti().b[2][1]++,Ti().s[6]++,delete e.filter),Ti().s[7]++,e.id=e.id+"_highlight",Ti().s[8]++,e}function Kee(e){if(Ti().f[1]++,Ti().s[9]++,Ti().b[4][0]++,!e||(Ti().b[4][1]++,e.type==="background")||(Ti().b[4][2]++,e.type==="raster"))return Ti().b[3][0]++,Ti().s[10]++,null;Ti().b[3][1]++;const n=(Ti().s[11]++,Ti().b[5][0]++,e["source-layer"]||(Ti().b[5][1]++,"")),t=(Ti().s[12]++,cR.brightColor(n,1));return Ti().s[13]++,Ti().b[7][0]++,e.type==="fill"||(Ti().b[7][1]++,e.type==="fill-extrusion")?(Ti().b[6][0]++,Ti().s[14]++,hM(dM.polygonLayer(t,t,e.source,e["source-layer"]),e)):(Ti().b[6][1]++,Ti().s[15]++,Ti().b[9][0]++,e.type==="symbol"||(Ti().b[9][1]++,e.type==="circle")?(Ti().b[8][0]++,Ti().s[16]++,hM(dM.circleLayer(t,e.source,e["source-layer"]),e)):(Ti().b[8][1]++,Ti().s[17]++,e.type==="line"?(Ti().b[10][0]++,Ti().s[18]++,hM(dM.lineLayer(t,e.source,e["source-layer"]),e)):(Ti().b[10][1]++,Ti().s[19]++,null)))}function YB(){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 YB=function(){return s},s}YB();YB().s[0]++;i_.setRTLTextPlugin("https://unpkg.com/@mapbox/mapbox-gl-rtl-text@0.2.3/mapbox-gl-rtl-text.min.js",!1);var MR=Fee,Pee=Object.prototype.hasOwnProperty;function Fee(){for(var e={},n=0;n<arguments.length;n++){var t=arguments[n];for(var r in t)Pee.call(t,r)&&(e[r]=t[r])}return e}var SR={exports:{}};(function(e,n){(function(){var t={};e.exports=t,t.simpleFilter=function(r,i){return i.filter(function(o){return t.test(r,o)})},t.test=function(r,i){return t.match(r,i)!==null},t.match=function(r,i,o){o=o||{};var s=0,a=[],h=i.length,g=0,C=0,B=o.pre||"",k=o.post||"",P=o.caseSensitive&&i||i.toLowerCase(),L;r=o.caseSensitive&&r||r.toLowerCase();for(var J=0;J<h;J++)L=i[J],P[J]===r[s]?(L=B+L+k,s+=1,C+=1+C):C=0,g+=C,a[a.length]=L;return s===r.length?(g=P===r?1/0:g,{rendered:a.join(""),score:g}):null},t.filter=function(r,i,o){return!i||i.length===0?[]:typeof r!="string"?i:(o=o||{},i.reduce(function(s,a,h,g){var C=a;o.extract&&(C=o.extract(a));var B=t.match(r,C,o);return B!=null&&(s[s.length]={string:B.rendered,score:B.score,index:h,original:a}),s},[]).sort(function(s,a){var h=a.score-s.score;return h||s.index-a.index}))}})()})(SR);var Dee=SR.exports,sc=function(e){return this.component=e,this.items=[],this.active=e.options.noInitialSelection?-1:0,this.wrapper=document.createElement("div"),this.wrapper.className="suggestions-wrapper",this.element=document.createElement("ul"),this.element.className="suggestions",this.wrapper.appendChild(this.element),this.selectingListItem=!1,e.el.parentNode.insertBefore(this.wrapper,e.el.nextSibling),this};sc.prototype.show=function(){this.element.style.display="block"};sc.prototype.hide=function(){this.element.style.display="none"};sc.prototype.add=function(e){this.items.push(e)};sc.prototype.clear=function(){this.items=[],this.active=this.component.options.noInitialSelection?-1:0};sc.prototype.isEmpty=function(){return!this.items.length};sc.prototype.isVisible=function(){return this.element.style.display==="block"};sc.prototype.draw=function(){if(this.element.innerHTML="",this.items.length===0){this.hide();return}for(var e=0;e<this.items.length;e++)this.drawItem(this.items[e],this.active===e);this.show()};sc.prototype.drawItem=function(e,n){var t=document.createElement("li"),r=document.createElement("a");n&&(t.className+=" active"),r.innerHTML=e.string,t.appendChild(r),this.element.appendChild(t),t.addEventListener("mousedown",(function(){this.selectingListItem=!0}).bind(this)),t.addEventListener("mouseup",(function(){this.handleMouseUp.call(this,e)}).bind(this))};sc.prototype.handleMouseUp=function(e){this.selectingListItem=!1,this.component.value(e.original),this.clear(),this.draw()};sc.prototype.move=function(e){this.active=e,this.draw()};sc.prototype.previous=function(){this.move(this.active<=0?this.items.length-1:this.active-1)};sc.prototype.next=function(){this.move(this.active>=this.items.length-1?0:this.active+1)};sc.prototype.drawError=function(e){var n=document.createElement("li");n.innerHTML=e,this.element.appendChild(n),this.show()};var Lee=sc,Uee=MR,Ree=Dee,zee=Lee,sA=function(e,n,t){return t=t||{},this.options=Uee({minLength:2,limit:5,filter:!0,hideOnBlur:!0,noInitialSelection:!0},t),this.el=e,this.data=n||[],this.list=new zee(this),this.query="",this.selected=null,this.list.draw(),this.el.addEventListener("keyup",(function(r){this.handleKeyUp(r.keyCode,r)}).bind(this),!1),this.el.addEventListener("keydown",(function(r){this.handleKeyDown(r)}).bind(this)),this.el.addEventListener("focus",(function(){this.handleFocus()}).bind(this)),this.el.addEventListener("blur",(function(){this.handleBlur()}).bind(this)),this.el.addEventListener("paste",(function(r){this.handlePaste(r)}).bind(this)),this.render=this.options.render?this.options.render.bind(this):this.render.bind(this),this.getItemValue=this.options.getItemValue?this.options.getItemValue.bind(this):this.getItemValue.bind(this),this};sA.prototype.handleKeyUp=function(e,n){if(!(e===40||e===38||e===27||e===9)){if(e===13){this.list.items[this.list.active]&&(this.list.handleMouseUp(this.list.items[this.list.active]),n.stopPropagation());return}this.handleInputChange(this.el.value)}};sA.prototype.handleKeyDown=function(e){switch(e.keyCode){case 13:this.list.active>=0&&(this.list.selectingListItem=!0);break;case 9:this.list.isEmpty()||(this.list.isVisible()&&e.preventDefault(),this.value(this.list.active>=0?this.list.items[this.list.active].original:null),this.list.hide());break;case 27:this.list.isEmpty()||this.list.hide();break;case 38:this.list.previous();break;case 40:this.list.next();break}};sA.prototype.handleBlur=function(){!this.list.selectingListItem&&this.options.hideOnBlur&&this.list.hide()};sA.prototype.handlePaste=function(e){if(e.clipboardData)this.handleInputChange(e.clipboardData.getData("Text"));else{var n=this;setTimeout(function(){n.handleInputChange(e.target.value)},100)}};sA.prototype.handleInputChange=function(e){if(this.query=this.normalize(e),this.list.clear(),this.query.length<this.options.minLength){this.list.draw();return}this.getCandidates((function(n){for(var t=0;t<n.length&&(this.list.add(n[t]),t!==this.options.limit-1);t++);this.list.draw()}).bind(this))};sA.prototype.handleFocus=function(){this.list.isEmpty()||this.list.show(),this.list.selectingListItem=!1};sA.prototype.update=function(e){this.data=e,this.handleKeyUp()};sA.prototype.clear=function(){this.data=[],this.list.clear()};sA.prototype.normalize=function(e){return e=e.toLowerCase(),e};sA.prototype.match=function(e,n){return e.indexOf(n)>-1};sA.prototype.value=function(e){if(this.selected=e,this.el.value=this.getItemValue(e||{place_name:this.query}),document.createEvent){var n=document.createEvent("HTMLEvents");n.initEvent("change",!0,!1),this.el.dispatchEvent(n)}else this.el.fireEvent("onchange")};sA.prototype.getCandidates=function(e){var n={pre:"<strong>",post:"</strong>",extract:(function(r){return this.getItemValue(r)}).bind(this)},t;this.options.filter?(t=Ree.filter(this.query,this.data,n),t=t.map((function(r){return{original:r.original,string:this.render(r.original,r.string)}}).bind(this))):t=this.data.map((function(r){var i=this.render(r);return{original:r,string:i}}).bind(this)),e(t)};sA.prototype.getItemValue=function(e){return e};sA.prototype.render=function(e,n){if(n)return n;for(var t=e.original?this.getItemValue(e.original):this.getItemValue(e),r=this.normalize(t),i=r.lastIndexOf(this.query);i>-1;){var o=i+this.query.length;t=t.slice(0,i)+"<strong>"+t.slice(i,o)+"</strong>"+t.slice(o),i=r.slice(0,i).lastIndexOf(this.query)}return t};sA.prototype.renderError=function(e){this.list.drawError(e)};var jee=sA,ER=jee,Wee=ER;typeof window<"u"&&(window.Suggestions=ER);var Nee="Expected a function",m9=NaN,Gee="[object Symbol]",Qee=/^\s+|\s+$/g,$ee=/^[-+]0x[0-9a-f]+$/i,Yee=/^0b[01]+$/i,qee=/^0o[0-7]+$/i,Hee=parseInt,Vee=typeof window=="object"&&window&&window.Object===Object&&window,Zee=typeof self=="object"&&self&&self.Object===Object&&self,Xee=Vee||Zee||Function("return this")(),Jee=Object.prototype,ete=Jee.toString,tte=Math.max,nte=Math.min,fM=function(){return Xee.Date.now()};function rte(e,n,t){var r,i,o,s,a,h,g=0,C=!1,B=!1,k=!0;if(typeof e!="function")throw new TypeError(Nee);n=g9(n)||0,q6(t)&&(C=!!t.leading,B="maxWait"in t,o=B?tte(g9(t.maxWait)||0,n):o,k="trailing"in t?!!t.trailing:k);function P(he){var V=r,ae=i;return r=i=void 0,g=he,s=e.apply(ae,V),s}function L(he){return g=he,a=setTimeout($,n),C?P(he):s}function J(he){var V=he-h,ae=he-g,ye=n-V;return B?nte(ye,o-ae):ye}function N(he){var V=he-h,ae=he-g;return h===void 0||V>=n||V<0||B&&ae>=o}function $(){var he=fM();if(N(he))return q(he);a=setTimeout($,J(he))}function q(he){return a=void 0,k&&r?P(he):(r=i=void 0,s)}function oe(){a!==void 0&&clearTimeout(a),g=0,r=h=i=a=void 0}function ce(){return a===void 0?s:q(fM())}function me(){var he=fM(),V=N(he);if(r=arguments,i=this,h=he,V){if(a===void 0)return L(h);if(B)return a=setTimeout($,n),P(h)}return a===void 0&&(a=setTimeout($,n)),s}return me.cancel=oe,me.flush=ce,me}function q6(e){var n=typeof e;return!!e&&(n=="object"||n=="function")}function ite(e){return!!e&&typeof e=="object"}function ote(e){return typeof e=="symbol"||ite(e)&&ete.call(e)==Gee}function g9(e){if(typeof e=="number")return e;if(ote(e))return m9;if(q6(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=q6(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=e.replace(Qee,"");var t=Yee.test(e);return t||qee.test(e)?Hee(e.slice(2),t?2:8):$ee.test(e)?m9:+e}var ate=rte,qB={exports:{}},iy=typeof Reflect=="object"?Reflect:null,y9=iy&&typeof iy.apply=="function"?iy.apply:function(n,t,r){return Function.prototype.apply.call(n,t,r)},_2;iy&&typeof iy.ownKeys=="function"?_2=iy.ownKeys:Object.getOwnPropertySymbols?_2=function(n){return Object.getOwnPropertyNames(n).concat(Object.getOwnPropertySymbols(n))}:_2=function(n){return Object.getOwnPropertyNames(n)};function ste(e){console&&console.warn&&console.warn(e)}var OR=Number.isNaN||function(n){return n!==n};function Pa(){Pa.init.call(this)}qB.exports=Pa;qB.exports.once=cte;Pa.EventEmitter=Pa;Pa.prototype._events=void 0;Pa.prototype._eventsCount=0;Pa.prototype._maxListeners=void 0;var v9=10;function o5(e){if(typeof e!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}Object.defineProperty(Pa,"defaultMaxListeners",{enumerable:!0,get:function(){return v9},set:function(e){if(typeof e!="number"||e<0||OR(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");v9=e}});Pa.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0};Pa.prototype.setMaxListeners=function(n){if(typeof n!="number"||n<0||OR(n))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+n+".");return this._maxListeners=n,this};function BR(e){return e._maxListeners===void 0?Pa.defaultMaxListeners:e._maxListeners}Pa.prototype.getMaxListeners=function(){return BR(this)};Pa.prototype.emit=function(n){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var i=n==="error",o=this._events;if(o!==void 0)i=i&&o.error===void 0;else if(!i)return!1;if(i){var s;if(t.length>0&&(s=t[0]),s instanceof Error)throw s;var a=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw a.context=s,a}var h=o[n];if(h===void 0)return!1;if(typeof h=="function")y9(h,this,t);else for(var g=h.length,C=PR(h,g),r=0;r<g;++r)y9(C[r],this,t);return!0};function kR(e,n,t,r){var i,o,s;if(o5(t),o=e._events,o===void 0?(o=e._events=Object.create(null),e._eventsCount=0):(o.newListener!==void 0&&(e.emit("newListener",n,t.listener?t.listener:t),o=e._events),s=o[n]),s===void 0)s=o[n]=t,++e._eventsCount;else if(typeof s=="function"?s=o[n]=r?[t,s]:[s,t]:r?s.unshift(t):s.push(t),i=BR(e),i>0&&s.length>i&&!s.warned){s.warned=!0;var a=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(n)+" listeners added. Use emitter.setMaxListeners() to increase limit");a.name="MaxListenersExceededWarning",a.emitter=e,a.type=n,a.count=s.length,ste(a)}return e}Pa.prototype.addListener=function(n,t){return kR(this,n,t,!1)};Pa.prototype.on=Pa.prototype.addListener;Pa.prototype.prependListener=function(n,t){return kR(this,n,t,!0)};function lte(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function IR(e,n,t){var r={fired:!1,wrapFn:void 0,target:e,type:n,listener:t},i=lte.bind(r);return i.listener=t,r.wrapFn=i,i}Pa.prototype.once=function(n,t){return o5(t),this.on(n,IR(this,n,t)),this};Pa.prototype.prependOnceListener=function(n,t){return o5(t),this.prependListener(n,IR(this,n,t)),this};Pa.prototype.removeListener=function(n,t){var r,i,o,s,a;if(o5(t),i=this._events,i===void 0)return this;if(r=i[n],r===void 0)return this;if(r===t||r.listener===t)--this._eventsCount===0?this._events=Object.create(null):(delete i[n],i.removeListener&&this.emit("removeListener",n,r.listener||t));else if(typeof r!="function"){for(o=-1,s=r.length-1;s>=0;s--)if(r[s]===t||r[s].listener===t){a=r[s].listener,o=s;break}if(o<0)return this;o===0?r.shift():ute(r,o),r.length===1&&(i[n]=r[0]),i.removeListener!==void 0&&this.emit("removeListener",n,a||t)}return this};Pa.prototype.off=Pa.prototype.removeListener;Pa.prototype.removeAllListeners=function(n){var t,r,i;if(r=this._events,r===void 0)return this;if(r.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):r[n]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete r[n]),this;if(arguments.length===0){var o=Object.keys(r),s;for(i=0;i<o.length;++i)s=o[i],s!=="removeListener"&&this.removeAllListeners(s);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(t=r[n],typeof t=="function")this.removeListener(n,t);else if(t!==void 0)for(i=t.length-1;i>=0;i--)this.removeListener(n,t[i]);return this};function TR(e,n,t){var r=e._events;if(r===void 0)return[];var i=r[n];return i===void 0?[]:typeof i=="function"?t?[i.listener||i]:[i]:t?Ate(i):PR(i,i.length)}Pa.prototype.listeners=function(n){return TR(this,n,!0)};Pa.prototype.rawListeners=function(n){return TR(this,n,!1)};Pa.listenerCount=function(e,n){return typeof e.listenerCount=="function"?e.listenerCount(n):KR.call(e,n)};Pa.prototype.listenerCount=KR;function KR(e){var n=this._events;if(n!==void 0){var t=n[e];if(typeof t=="function")return 1;if(t!==void 0)return t.length}return 0}Pa.prototype.eventNames=function(){return this._eventsCount>0?_2(this._events):[]};function PR(e,n){for(var t=new Array(n),r=0;r<n;++r)t[r]=e[r];return t}function ute(e,n){for(;n+1<e.length;n++)e[n]=e[n+1];e.pop()}function Ate(e){for(var n=new Array(e.length),t=0;t<n.length;++t)n[t]=e[t].listener||e[t];return n}function cte(e,n){return new Promise(function(t,r){function i(s){e.removeListener(n,o),r(s)}function o(){typeof e.removeListener=="function"&&e.removeListener("error",i),t([].slice.call(arguments))}FR(e,n,o,{once:!0}),n!=="error"&&dte(e,i,{once:!0})})}function dte(e,n,t){typeof e.on=="function"&&FR(e,"error",n,t)}function FR(e,n,t,r){if(typeof e.on=="function")r.once?e.once(n,t):e.on(n,t);else if(typeof e.addEventListener=="function")e.addEventListener(n,function i(o){r.once&&e.removeEventListener(n,i),t(o)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e)}var hte=qB.exports,fte={fr:{name:"France",bbox:[[-4.59235,41.380007],[9.560016,51.148506]]},us:{name:"United States",bbox:[[-171.791111,18.91619],[-66.96466,71.357764]]},ru:{name:"Russia",bbox:[[19.66064,41.151416],[190.10042,81.2504]]},ca:{name:"Canada",bbox:[[-140.99778,41.675105],[-52.648099,83.23324]]}},pte={de:"Suche",it:"Ricerca",en:"Search",nl:"Zoeken",fr:"Chercher",ca:"Cerca",he:"לחפש",ja:"サーチ",lv:"Meklēt",pt:"Procurar",sr:"Претрага",zh:"搜索",cs:"Vyhledávání",hu:"Keresés",ka:"ძიება",nb:"Søke",sk:"Vyhľadávanie",th:"ค้นหา",fi:"Hae",is:"Leita",ko:"수색",pl:"Szukaj",sl:"Iskanje",fa:"جستجو",ru:"Поиск"},mte={placeholder:pte},DR={exports:{}};(function(e){(function(n,t,r){e.exports?e.exports=r():n[t]=r()})(ch,"subtag",function(){var n="",t=/^([a-zA-Z]{2,3})(?:[_-]+([a-zA-Z]{3})(?=$|[_-]+))?(?:[_-]+([a-zA-Z]{4})(?=$|[_-]+))?(?:[_-]+([a-zA-Z]{2}|[0-9]{3})(?=$|[_-]+))?/;function r(h){return h.match(t)||[]}function i(h){return r(h).filter(function(g,C){return g&&C})}function o(h){return h=r(h),{language:h[1]||n,extlang:h[2]||n,script:h[3]||n,region:h[4]||n}}function s(h,g,C){Object.defineProperty(h,g,{value:C,enumerable:!0})}function a(h,g,C){function B(k){return r(k)[h]||n}s(B,"pattern",g),s(o,C,B)}return a(1,/^[a-zA-Z]{2,3}$/,"language"),a(2,/^[a-zA-Z]{3}$/,"extlang"),a(3,/^[a-zA-Z]{4}$/,"script"),a(4,/^[a-zA-Z]{2}$|^[0-9]{3}$/,"region"),s(o,"split",i),o})})(DR);var gte=DR.exports,yte=Wee,vte=ate,Bc=MR,_te=hte.EventEmitter,_9=fte,Cte=mte,bte=gte;function LR(e,n){this._eventEmitter=new _te,this.options=Bc({},this.options,n),this.inputString="",this.fresh=!0,this.lastSelected=null,this.geocoderApi=e}LR.prototype={options:{zoom:16,flyTo:!0,trackProximity:!0,showResultsWhileTyping:!1,minLength:2,reverseGeocode:!1,limit:5,enableEventLogging:!0,marker:!0,popup:!1,maplibregl:null,collapsed:!1,clearAndBlurOnEsc:!1,clearOnBlur:!1,getItemValue:function(e){return e.text!==void 0?e.text:e.place_name},render:function(e){if(e.geometry){var a=e.place_name.split(",");return'<div class="mapboxgl-ctrl-geocoder--result maplibregl-ctrl-geocoder--result"><svg class="mapboxgl-ctrl-geocoder--result-icon maplibre-ctrl-geocoder--result-icon" viewBox="0 0 24 32" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M12 0C5.36571 0 0 5.38676 0 12.0471C0 21.0824 12 32 12 32C12 32 24 21.0824 24 12.0471C24 5.38676 18.6343 0 12 0ZM12 16.3496C9.63428 16.3496 7.71429 14.4221 7.71429 12.0471C7.71429 9.67207 9.63428 7.74454 12 7.74454C14.3657 7.74454 16.2857 9.67207 16.2857 12.0471C16.2857 14.4221 14.3657 16.3496 12 16.3496Z" fill="#687078"/></svg><div><div class="mapboxgl-ctrl-geocoder--result-title maplibregl-ctrl-geocoder--result-title">'+a[0]+'</div><div class="mapboxgl-ctrl-geocoder--result-address maplibregl-ctrl-geocoder--result-address">'+a.splice(1,a.length).join(",")+"</div></div></div>"}else{var n=e.text,t=n.toLowerCase().indexOf(this.query.toLowerCase()),r=this.query.length,i=n.substring(0,t),o=n.substring(t,t+r),s=n.substring(t+r);return'<div class="mapboxgl-ctrl-geocoder--suggestion maplibregl-ctrl-geocoder--suggestion"><svg class="mapboxgl-ctrl-geocoder--suggestion-icon maplibre-ctrl-geocoder--suggestion-icon" viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg"><path d="M22.8702 20.1258H21.4248L20.9125 19.6318C22.7055 17.546 23.785 14.8382 23.785 11.8925C23.785 5.32419 18.4608 0 11.8925 0C5.32419 0 0 5.32419 0 11.8925C0 18.4608 5.32419 23.785 11.8925 23.785C14.8382 23.785 17.546 22.7055 19.6318 20.9125L20.1258 21.4248V22.8702L29.2739 32L32 29.2739L22.8702 20.1258ZM11.8925 20.1258C7.33676 20.1258 3.65923 16.4483 3.65923 11.8925C3.65923 7.33676 7.33676 3.65923 11.8925 3.65923C16.4483 3.65923 20.1258 7.33676 20.1258 11.8925C20.1258 16.4483 16.4483 20.1258 11.8925 20.1258Z" fill="#687078"/></svg><div class="mapboxgl-ctrl-geocoder--suggestion-info maplibregl-ctrl-geocoder--suggestion-info"><div class="mapboxgl-ctrl-geocoder--suggestion-title maplibregl-ctrl-geocoder--suggestion-title">'+i+'<span class="mapboxgl-ctrl-geocoder--suggestion-match maplibregl-ctrl-geocoder--suggestion-match">'+o+"</span>"+s+"</div></div></div>"}},popupRender:function(e){var n=e.place_name.split(",");return'<div class="mapboxgl-ctrl-geocoder--suggestion maplibre-ctrl-geocoder--suggestion popup-suggestion"><div class="mapboxgl-ctrl-geocoder--suggestion-title maplibre-ctrl-geocoder--suggestion-title popup-suggestion-title">'+n[0]+'</div><div class="mapboxgl-ctrl-geocoder--suggestion-address maplibre-ctrl-geocoder--suggestion-address popup-suggestion-address">'+n.splice(1,n.length).join(",")+"</div></div>"},showResultMarkers:!0,debounceSearch:200},addTo:function(e){function n(r,i){if(!document.body.contains(i))throw new Error("Element provided to #addTo() exists, but is not in the DOM");var o=r.onAdd();i.appendChild(o)}if(e._controlContainer)e.addControl(this);else if(e instanceof HTMLElement)n(this,e);else if(typeof e=="string"){var t=document.querySelectorAll(e);if(t.length===0)throw new Error("Element ",e,"not found.");if(t.length>1)throw new Error("Geocoder can only be added to a single html element");n(this,t[0])}else throw new Error("Error: addTo must be a maplibre-gl-js map, an html element, or a CSS selector query for a single html element")},onAdd:function(e){if(e&&typeof e!="string"&&(this._map=e),this.setLanguage(),this.options.localGeocoderOnly&&!this.options.localGeocoder)throw new Error("A localGeocoder function must be specified to use localGeocoderOnly mode");this._onChange=this._onChange.bind(this),this._onKeyDown=this._onKeyDown.bind(this),this._onPaste=this._onPaste.bind(this),this._onBlur=this._onBlur.bind(this),this._showButton=this._showButton.bind(this),this._hideButton=this._hideButton.bind(this),this._onQueryResult=this._onQueryResult.bind(this),this.clear=this.clear.bind(this),this._updateProximity=this._updateProximity.bind(this),this._collapse=this._collapse.bind(this),this._unCollapse=this._unCollapse.bind(this),this._clear=this._clear.bind(this),this._clearOnBlur=this._clearOnBlur.bind(this);var n=this.container=document.createElement("div");n.className="mapboxgl-ctrl-geocoder mapboxgl-ctrl maplibregl-ctrl-geocoder maplibregl-ctrl";var t=this.createIcon("search",'<path d="M7.4 2.5c-2.7 0-4.9 2.2-4.9 4.9s2.2 4.9 4.9 4.9c1 0 1.8-.2 2.5-.8l3.7 3.7c.2.2.4.3.8.3.7 0 1.1-.4 1.1-1.1 0-.3-.1-.5-.3-.8L11.4 10c.4-.8.8-1.6.8-2.5.1-2.8-2.1-5-4.8-5zm0 1.6c1.8 0 3.2 1.4 3.2 3.2s-1.4 3.2-3.2 3.2-3.3-1.3-3.3-3.1 1.4-3.3 3.3-3.3z"/>');this._inputEl=document.createElement("input"),this._inputEl.type="text",this._inputEl.className="mapboxgl-ctrl-geocoder--input maplibregl-ctrl-geocoder--input",this.setPlaceholder(),this.options.collapsed&&(this._collapse(),this.container.addEventListener("mouseenter",this._unCollapse),this.container.addEventListener("mouseleave",this._collapse),this._inputEl.addEventListener("focus",this._unCollapse)),(this.options.collapsed||this.options.clearOnBlur)&&this._inputEl.addEventListener("blur",this._onBlur),this._inputEl.addEventListener("keydown",vte(this._onKeyDown,this.options.debounceSearch)),this._inputEl.addEventListener("paste",this._onPaste),this._inputEl.addEventListener("change",this._onChange),this.container.addEventListener("mouseenter",this._showButton),this.container.addEventListener("mouseleave",this._hideButton);var r=document.createElement("div");r.classList.add("mapboxgl-ctrl-geocoder--pin-right","maplibregl-ctrl-geocoder--pin-right"),this._clearEl=document.createElement("button"),this._clearEl.setAttribute("aria-label","Clear"),this._clearEl.addEventListener("click",this.clear),this._clearEl.className="mapboxgl-ctrl-geocoder--button maplibregl-ctrl-geocoder--button";var i=this.createIcon("close",'<path d="M3.8 2.5c-.6 0-1.3.7-1.3 1.3 0 .3.2.7.5.8L7.2 9 3 13.2c-.3.3-.5.7-.5 1 0 .6.7 1.3 1.3 1.3.3 0 .7-.2 1-.5L9 10.8l4.2 4.2c.2.3.7.3 1 .3.6 0 1.3-.7 1.3-1.3 0-.3-.2-.7-.3-1l-4.4-4L15 4.6c.3-.2.5-.5.5-.8 0-.7-.7-1.3-1.3-1.3-.3 0-.7.2-1 .3L9 7.1 4.8 2.8c-.3-.1-.7-.3-1-.3z"/>');return this._clearEl.appendChild(i),this._loadingEl=this.createIcon("loading",'<path fill="#333" d="M4.4 4.4l.8.8c2.1-2.1 5.5-2.1 7.6 0l.8-.8c-2.5-2.5-6.7-2.5-9.2 0z"/><path opacity=".1" d="M12.8 12.9c-2.1 2.1-5.5 2.1-7.6 0-2.1-2.1-2.1-5.5 0-7.7l-.8-.8c-2.5 2.5-2.5 6.7 0 9.2s6.6 2.5 9.2 0 2.5-6.6 0-9.2l-.8.8c2.2 2.1 2.2 5.6 0 7.7z"/>'),r.appendChild(this._clearEl),r.appendChild(this._loadingEl),n.appendChild(t),n.appendChild(this._inputEl),n.appendChild(r),this._typeahead=new yte(this._inputEl,[],{filter:!1,minLength:this.options.minLength,limit:this.options.limit,noInitialSelection:!0}),this.setRenderFunction(this.options.render),this._typeahead.getItemValue=this.options.getItemValue,this.mapMarker=null,this.resultMarkers=[],this._handleMarker=this._handleMarker.bind(this),this._handleResultMarkers=this._handleResultMarkers.bind(this),this._map&&(this.options.trackProximity&&(this._updateProximity(),this._map.on("moveend",this._updateProximity)),this._maplibregl=this.options.maplibregl,!this._maplibregl&&this.options.marker&&(console.error("No maplibregl detected in options. Map markers are disabled. Please set options.maplibregl."),this.options.marker=!1)),n},createIcon:function(e,n){var t=document.createElementNS("http://www.w3.org/2000/svg","svg");if(t.setAttribute("class","mapboxgl-ctrl-geocoder--icon mapboxgl-ctrl-geocoder--icon-"+e+" maplibregl-ctrl-geocoder--icon maplibregl-ctrl-geocoder--icon-"+e),t.setAttribute("viewBox","0 0 18 18"),t.setAttribute("xml:space","preserve"),t.setAttribute("width",18),t.setAttribute("height",18),"innerHTML"in t)t.innerHTML=n;else{var r=document.createElement("div");r.innerHTML="<svg>"+n.valueOf().toString()+"</svg>";var i=r.firstChild,o=i.firstChild;t.appendChild(o)}return t},onRemove:function(){return this.container.parentNode.removeChild(this.container),this.options.trackProximity&&this._map&&this._map.off("moveend",this._updateProximity),this._removeMarker(),this._map=null,this},_onPaste:function(e){var n=(e.clipboardData||window.clipboardData).getData("text");n.length>=this.options.minLength&&this.options.showResultsWhileTyping&&this._geocode(n)},_onKeyDown:function(e){var n=27,t=9;if(e.keyCode===n&&this.options.clearAndBlurOnEsc)return this._clear(e),this._inputEl.blur();var r=e.target&&e.target.shadowRoot?e.target.shadowRoot.activeElement:e.target,i=r?r.value:"";if(!i)return this.fresh=!0,e.keyCode!==t&&this.clear(e),this._clearEl.style.display="none";if(!(e.metaKey||[t,n,37,39,38,40].indexOf(e.keyCode)!==-1)){if(e.keyCode===13)if(!this.options.showResultsWhileTyping)this._typeahead.selected||this._geocode(r.value);else{this._typeahead.selected==null&&this.geocoderApi.getSuggestions?this._geocode(r.value,!0):this._typeahead.selected==null&&this.options.showResultMarkers&&this._fitBoundsForMarkers();return}r.value.length>=this.options.minLength&&this.options.showResultsWhileTyping&&this._geocode(r.value)}},_showButton:function(){this._inputEl.value.length>0&&(this._clearEl.style.display="block")},_hideButton:function(){this._typeahead.selected&&(this._clearEl.style.display="none")},_onBlur:function(e){this.options.clearOnBlur&&this._clearOnBlur(e),this.options.collapsed&&this._collapse()},_onChange:function(){var e=this._typeahead.selected;if(e&&!e.geometry)e.placeId?this._geocode(e.placeId,!0,!0):this._geocode(e.text,!0);else if(e&&JSON.stringify(e)!==this.lastSelected){if(this._clearEl.style.display="none",this.options.flyTo){var n;if(this._removeResultMarkers(),e.properties&&_9[e.properties.short_code])n=Bc({},this.options.flyTo),this._map&&this._map.fitBounds(_9[e.properties.short_code].bbox,n);else if(e.bbox){var t=e.bbox;n=Bc({},this.options.flyTo),this._map&&this._map.fitBounds([[t[0],t[1]],[t[2],t[3]]],n)}else{var r={zoom:this.options.zoom};n=Bc({},r,this.options.flyTo),e.center?n.center=e.center:e.geometry&&e.geometry.type&&e.geometry.type==="Point"&&e.geometry.coordinates&&(n.center=e.geometry.coordinates),this._map&&this._map.flyTo(n)}}this.options.marker&&this._maplibregl&&this._handleMarker(e),this._inputEl.focus(),this._inputEl.scrollLeft=0,this._inputEl.setSelectionRange(0,0),this.lastSelected=JSON.stringify(e),this._typeahead.selected=null,this._eventEmitter.emit("result",{result:e})}},_getConfigForRequest:function(){var e=["bbox","limit","proximity","countries","types","language","reverseMode"],n=this,t=e.reduce(function(r,i){return n.options[i]&&(["countries","types","language"].indexOf(i)>-1?r[i]=n.options[i].split(/[\s,]+/):r[i]=n.options[i],i==="proximity"&&n.options[i]&&typeof n.options[i].longitude=="number"&&typeof n.options[i].latitude=="number"&&(r[i]=[n.options[i].longitude,n.options[i].latitude])),r},{});return t},_geocode:function(e,n,t){this._loadingEl.style.display="block",this._eventEmitter.emit("loading",{query:e}),this.inputString=e;var r=null,i=this._getConfigForRequest(),o;if(this.options.localGeocoderOnly)o=Promise.resolve();else if(this.options.reverseGeocode&&/(-?\d+\.?\d*)[, ]+(-?\d+\.?\d*)[ ]*$/.test(e)){var s=e.split(/[\s(,)?]+/).map(function(g){return parseFloat(g,10)}).reverse();i.types&&i.types[0],i=Bc(i,{query:s,limit:1}),"proximity"in i&&delete i.proximity,o=this.geocoderApi.reverseGeocode(i)}else i=Bc(i,{query:e}),this.geocoderApi.getSuggestions?n?this.geocoderApi.searchByPlaceId&&t?o=this.geocoderApi.searchByPlaceId(i):o=this.geocoderApi.forwardGeocode(i):o=this.geocoderApi.getSuggestions(i):o=this.geocoderApi.forwardGeocode(i);var a=[];this.options.localGeocoder&&(a=this.options.localGeocoder(e),a||(a=[]));var h=[];return o.catch((function(g){r=g}).bind(this)).then((function(g){this._loadingEl.style.display="none";var C={};return g?C=g:C={type:"FeatureCollection",features:[]},C.config=i,this.fresh&&(this.fresh=!1),C.features=C.features?a.concat(C.features):a,this.options.externalGeocoder?(h=this.options.externalGeocoder(e,C.features,i)||[],h.then(function(B){return C.features=C.features?B.concat(C.features):B,C},function(){return C})):C}).bind(this)).then((function(g){if(r)throw r;this.options.filter&&g.features.length&&(g.features=g.features.filter(this.options.filter));var C=[];g.suggestions?C=g.suggestions:g.place?C=[g.place]:C=g.features,C.length?(this._clearEl.style.display="block",this._typeahead.update(C),(!this.options.showResultsWhileTyping||n)&&this.options.showResultMarkers&&(g.features.length>0||g.place)&&this._fitBoundsForMarkers(),this._eventEmitter.emit("results",g)):(this._clearEl.style.display="none",this._typeahead.selected=null,this._renderNoResults(),this._eventEmitter.emit("results",g))}).bind(this)).catch((function(g){this._loadingEl.style.display="none",a.length&&this.options.localGeocoder||h.length&&this.options.externalGeocoder?(this._clearEl.style.display="block",this._typeahead.update(a)):(this._clearEl.style.display="none",this._typeahead.selected=null,this._renderError()),this._eventEmitter.emit("results",{features:a}),this._eventEmitter.emit("error",{error:g})}).bind(this)),o},_clear:function(e){e&&e.preventDefault(),this._inputEl.value="",this._typeahead.selected=null,this._typeahead.clear(),this._onChange(),this._clearEl.style.display="none",this._removeMarker(),this._removeResultMarkers(),this.lastSelected=null,this._eventEmitter.emit("clear"),this.fresh=!0},clear:function(e){this._clear(e),this._inputEl.focus()},_clearOnBlur:function(e){var n=this;e.relatedTarget&&n._clear(e)},_onQueryResult:function(e){var n=e;if(n.features.length){var t=n.features[0];this._typeahead.selected=t,this._inputEl.value=t.place_name,this._onChange()}},_updateProximity:function(){if(this._map)if(this._map.getZoom()>9){var e=this._map.getCenter().wrap();this.setProximity({longitude:e.lng,latitude:e.lat})}else this.setProximity(null)},_collapse:function(){!this._inputEl.value&&this._inputEl!==document.activeElement&&this.container.classList.add("mapboxgl-ctrl-geocoder--collapsed","maplibregl-ctrl-geocoder--collapsed")},_unCollapse:function(){this.container.classList.remove("mapboxgl-ctrl-geocoder--collapsed","maplibregl-ctrl-geocoder--collapsed")},query:function(e){return this._geocode(e).then(this._onQueryResult),this},_renderError:function(){var e="<div class='mapbox-gl-geocoder--error maplibre-gl-geocoder--error'>There was an error reaching the server</div>";this._renderMessage(e)},_renderNoResults:function(){var e="<div class='mapbox-gl-geocoder--error mapbox-gl-geocoder--no-results maplibre-gl-geocoder--error maplibre-gl-geocoder--no-results'>No results found</div>";this._renderMessage(e)},_renderMessage:function(e){this._typeahead.update([]),this._typeahead.selected=null,this._typeahead.clear(),this._typeahead.renderError(e)},_getPlaceholderText:function(){if(this.options.placeholder)return this.options.placeholder;if(this.options.language){var e=this.options.language.split(",")[0],n=bte.language(e),t=Cte.placeholder[n];if(t)return t}return"Search"},_fitBoundsForMarkers:function(){if(!(this._typeahead.data.length<1)){var e=this._typeahead.data.filter(function(i){return typeof i!="string"}).slice(0,this.options.limit);if(this._clearEl.style.display="none",this.options.flyTo&&this._maplibregl&&this._map){var n={padding:100},t=Bc({},n,this.options.flyTo),r=new this._maplibregl.LngLatBounds;e.forEach(function(i){r.extend(i.geometry.coordinates)}),this._map.fitBounds(r.toArray(),t)}return e.length>0&&this._maplibregl&&this._handleResultMarkers(e),this}},setInput:function(e){return this._inputEl.value=e,this._typeahead.selected=null,this._typeahead.clear(),e.length>=this.options.minLength&&this.options.showResultsWhileTyping&&this._geocode(e),this},setProximity:function(e){return this.options.proximity=e,this},getProximity:function(){return this.options.proximity},setRenderFunction:function(e){return e&&typeof e=="function"&&(this._typeahead.render=e),this},getRenderFunction:function(){return this._typeahead.render},setLanguage:function(e){var n=navigator.language||navigator.userLanguage||navigator.browserLanguage;return this.options.language=e||this.options.language||n,this},getLanguage:function(){return this.options.language},getZoom:function(){return this.options.zoom},setZoom:function(e){return this.options.zoom=e,this},getFlyTo:function(){return this.options.flyTo},setFlyTo:function(e){return this.options.flyTo=e,this},getPlaceholder:function(){return this.options.placeholder},setPlaceholder:function(e){return this.placeholder=e||this._getPlaceholderText(),this._inputEl.placeholder=this.placeholder,this._inputEl.setAttribute("aria-label",this.placeholder),this},getBbox:function(){return this.options.bbox},setBbox:function(e){return this.options.bbox=e,this},getCountries:function(){return this.options.countries},setCountries:function(e){return this.options.countries=e,this},getTypes:function(){return this.options.types},setTypes:function(e){return this.options.types=e,this},getMinLength:function(){return this.options.minLength},setMinLength:function(e){return this.options.minLength=e,this._typeahead&&(this._typeahead.options.minLength=e),this},getLimit:function(){return this.options.limit},setLimit:function(e){return this.options.limit=e,this._typeahead&&(this._typeahead.options.limit=e),this},getFilter:function(){return this.options.filter},setFilter:function(e){return this.options.filter=e,this},setGeocoderApi:function(e){return this.geocoderApi=e,this},getGeocoderApi:function(){return this.geocoderApi},_handleMarker:function(e){if(this._map){this._removeMarker();var n={color:"#4668F2"},t=Bc({},n,this.options.marker);this.mapMarker=new this._maplibregl.Marker(t);var r;if(this.options.popup){var i={},o=Bc({},i,this.options.popup);r=new this._maplibregl.Popup(o).setHTML(this.options.popupRender(e))}return e.center?(this.mapMarker.setLngLat(e.center).addTo(this._map),this.options.popup&&this.mapMarker.setPopup(r)):e.geometry&&e.geometry.type&&e.geometry.type==="Point"&&e.geometry.coordinates&&(this.mapMarker.setLngLat(e.geometry.coordinates).addTo(this._map),this.options.popup&&this.mapMarker.setPopup(r)),this}},_removeMarker:function(){this.mapMarker&&(this.mapMarker.remove(),this.mapMarker=null)},_handleResultMarkers:function(e){if(this._map){this._removeResultMarkers();var n={color:"#4668F2"},t=Bc({},n,this.options.showResultMarkers);return e.forEach((function(r){if(this.options.showResultMarkers&&this.options.showResultMarkers.element){var i=this.options.showResultMarkers.element.cloneNode(!0);t=Bc(t,{element:i})}var o=new this._maplibregl.Marker(Bc({},t,{element:i})),s;if(this.options.popup){var a={},h=Bc({},a,this.options.popup);s=new this._maplibregl.Popup(h).setHTML(this.options.popupRender(r))}r.center?(o.setLngLat(r.center).addTo(this._map),this.options.popup&&o.setPopup(s)):r.geometry&&r.geometry.type&&r.geometry.type==="Point"&&r.geometry.coordinates&&(o.setLngLat(r.geometry.coordinates).addTo(this._map),this.options.popup&&o.setPopup(s)),this.resultMarkers.push(o)}).bind(this)),this}},_removeResultMarkers:function(){this.resultMarkers&&this.resultMarkers.length>0&&(this.resultMarkers.forEach(function(e){e.remove()}),this.resultMarkers=[])},on:function(e,n){return this._eventEmitter.on(e,n),this},off:function(e,n){return this._eventEmitter.removeListener(e,n),this}};var xte=LR;const wte=fa(xte);function rn(){var e="/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGl.tsx",n="5f82f1db20d50d10c048513b2ce08346d056029c",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGl.tsx",statementMap:{0:{start:{line:18,column:2},end:{line:18,column:36}},1:{start:{line:19,column:2},end:{line:19,column:19}},2:{start:{line:22,column:26},end:{line:28,column:3}},3:{start:{line:29,column:16},end:{line:29,column:55}},4:{start:{line:30,column:2},end:{line:32,column:3}},5:{start:{line:31,column:4},end:{line:31,column:30}},6:{start:{line:33,column:18},end:{line:33,column:20}},7:{start:{line:34,column:2},end:{line:39,column:5}},8:{start:{line:35,column:19},end:{line:35,column:53}},9:{start:{line:36,column:4},end:{line:38,column:5}},10:{start:{line:37,column:6},end:{line:37,column:33}},11:{start:{line:40,column:23},end:{line:44,column:3}},12:{start:{line:45,column:2},end:{line:45,column:22}},13:{start:{line:48,column:24},end:{line:58,column:3}},14:{start:{line:59,column:14},end:{line:59,column:18}},15:{start:{line:61,column:4},end:{line:61,column:17}},16:{start:{line:62,column:4},end:{line:65,column:6}},17:{start:{line:68,column:17},end:{line:68,column:22}},18:{start:{line:69,column:4},end:{line:72,column:5}},19:{start:{line:70,column:6},end:{line:70,column:132}},20:{start:{line:73,column:4},end:{line:73,column:18}},21:{start:{line:76,column:16},end:{line:76,column:30}},22:{start:{line:77,column:28},end:{line:77,column:79}},23:{start:{line:78,column:4},end:{line:83,column:5}},24:{start:{line:79,column:6},end:{line:79,column:52}},25:{start:{line:80,column:6},end:{line:80,column:70}},26:{start:{line:81,column:6},end:{line:81,column:70}},27:{start:{line:82,column:6},end:{line:82,column:76}},28:{start:{line:84,column:4},end:{line:86,column:5}},29:{start:{line:85,column:6},end:{line:85,column:43}},30:{start:{line:87,column:4},end:{line:92,column:5}},31:{start:{line:88,column:6},end:{line:88,column:59}},32:{start:{line:89,column:6},end:{line:91,column:14}},33:{start:{line:90,column:8},end:{line:90,column:36}},34:{start:{line:95,column:20},end:{line:101,column:5}},35:{start:{line:102,column:16},end:{line:102,column:43}},36:{start:{line:103,column:26},end:{line:107,column:5}},37:{start:{line:104,column:21},end:{line:104,column:36}},38:{start:{line:105,column:19},end:{line:105,column:32}},39:{start:{line:106,column:6},end:{line:106,column:44}},40:{start:{line:108,column:4},end:{line:108,column:20}},41:{start:{line:109,column:4},end:{line:109,column:56}},42:{start:{line:110,column:4},end:{line:110,column:56}},43:{start:{line:111,column:4},end:{line:111,column:62}},44:{start:{line:112,column:4},end:{line:112,column:27}},45:{start:{line:113,column:24},end:{line:113,column:41}},46:{start:{line:114,column:4},end:{line:114,column:45}},47:{start:{line:115,column:16},end:{line:115,column:74}},48:{start:{line:116,column:4},end:{line:116,column:37}},49:{start:{line:117,column:20},end:{line:117,column:49}},50:{start:{line:118,column:20},end:{line:138,column:6}},51:{start:{line:128,column:8},end:{line:128,column:82}},52:{start:{line:130,column:62},end:{line:130,column:141}},53:{start:{line:132,column:8},end:{line:136,column:9}},54:{start:{line:133,column:10},end:{line:133,column:108}},55:{start:{line:135,column:10},end:{line:135,column:160}},56:{start:{line:139,column:4},end:{line:139,column:28}},57:{start:{line:140,column:4},end:{line:146,column:7}},58:{start:{line:141,column:6},end:{line:145,column:9}},59:{start:{line:147,column:4},end:{line:153,column:7}},60:{start:{line:148,column:6},end:{line:149,column:15}},61:{start:{line:149,column:8},end:{line:149,column:15}},62:{start:{line:150,column:6},end:{line:152,column:9}},63:{start:{line:154,column:4},end:{line:156,column:7}},64:{start:{line:155,column:6},end:{line:155,column:30}},65:{start:{line:157,column:4},end:{line:161,column:7}},66:{start:{line:158,column:6},end:{line:160,column:9}},67:{start:{line:162,column:4},end:{line:162,column:37}},68:{start:{line:163,column:4},end:{line:163,column:37}},69:{start:{line:165,column:22},end:{line:168,column:3}},70:{start:{line:166,column:18},end:{line:166,column:82}},71:{start:{line:166,column:66},end:{line:166,column:81}},72:{start:{line:167,column:4},end:{line:167,column:36}},73:{start:{line:170,column:27},end:{line:203,column:5}},74:{start:{line:172,column:25},end:{line:172,column:27}},75:{start:{line:173,column:8},end:{line:198,column:9}},76:{start:{line:174,column:26},end:{line:174,column:138}},77:{start:{line:175,column:27},end:{line:175,column:47}},78:{start:{line:176,column:26},end:{line:176,column:47}},79:{start:{line:177,column:10},end:{line:195,column:11}},80:{start:{line:178,column:27},end:{line:181,column:13}},81:{start:{line:182,column:26},end:{line:193,column:13}},82:{start:{line:194,column:12},end:{line:194,column:33}},83:{start:{line:197,column:10},end:{line:197,column:69}},84:{start:{line:199,column:8},end:{line:201,column:10}},85:{start:{line:204,column:21},end:{line:204,column:85}},86:{start:{line:205,column:4},end:{line:205,column:41}},87:{start:{line:208,column:4},end:{line:217,column:6}},88:{start:{line:214,column:20},end:{line:214,column:38}}},fnMap:{0:{name:"renderPopup",decl:{start:{line:17,column:9},end:{line:17,column:20}},loc:{start:{line:17,column:39},end:{line:20,column:1}},line:17},1:{name:"buildInspectStyle",decl:{start:{line:21,column:9},end:{line:21,column:26}},loc:{start:{line:21,column:78},end:{line:46,column:1}},line:21},2:{name:"(anonymous_2)",decl:{start:{line:34,column:48},end:{line:34,column:49}},loc:{start:{line:34,column:62},end:{line:39,column:3}},line:34},3:{name:"(anonymous_3)",decl:{start:{line:49,column:17},end:{line:49,column:18}},loc:{start:{line:49,column:23},end:{line:50,column:5}},line:49},4:{name:"(anonymous_4)",decl:{start:{line:51,column:18},end:{line:51,column:19}},loc:{start:{line:51,column:24},end:{line:52,column:5}},line:51},5:{name:"(anonymous_5)",decl:{start:{line:53,column:19},end:{line:53,column:20}},loc:{start:{line:53,column:25},end:{line:54,column:5}},line:53},6:{name:"(anonymous_6)",decl:{start:{line:55,column:14},end:{line:55,column:15}},loc:{start:{line:55,column:20},end:{line:56,column:5}},line:55},7:{name:"(anonymous_7)",decl:{start:{line:60,column:2},end:{line:60,column:3}},loc:{start:{line:60,column:21},end:{line:66,column:3}},line:60},8:{name:"(anonymous_8)",decl:{start:{line:67,column:2},end:{line:67,column:3}},loc:{start:{line:67,column:46},end:{line:74,column:3}},line:67},9:{name:"(anonymous_9)",decl:{start:{line:75,column:2},end:{line:75,column:3}},loc:{start:{line:75,column:23},end:{line:93,column:3}},line:75},10:{name:"(anonymous_10)",decl:{start:{line:89,column:17},end:{line:89,column:18}},loc:{start:{line:89,column:23},end:{line:91,column:7}},line:89},11:{name:"(anonymous_11)",decl:{start:{line:94,column:2},end:{line:94,column:3}},loc:{start:{line:94,column:22},end:{line:164,column:3}},line:94},12:{name:"(anonymous_12)",decl:{start:{line:103,column:26},end:{line:103,column:27}},loc:{start:{line:103,column:32},end:{line:107,column:5}},line:103},13:{name:"(anonymous_13)",decl:{start:{line:127,column:24},end:{line:127,column:25}},loc:{start:{line:127,column:44},end:{line:129,column:7}},line:127},14:{name:"(anonymous_14)",decl:{start:{line:130,column:25},end:{line:130,column:26}},loc:{start:{line:130,column:62},end:{line:130,column:141}},line:130},15:{name:"(anonymous_15)",decl:{start:{line:131,column:19},end:{line:131,column:20}},loc:{start:{line:131,column:33},end:{line:137,column:7}},line:131},16:{name:"(anonymous_16)",decl:{start:{line:140,column:25},end:{line:140,column:26}},loc:{start:{line:140,column:31},end:{line:146,column:5}},line:140},17:{name:"(anonymous_17)",decl:{start:{line:147,column:19},end:{line:147,column:20}},loc:{start:{line:147,column:26},end:{line:153,column:5}},line:147},18:{name:"(anonymous_18)",decl:{start:{line:154,column:20},end:{line:154,column:21}},loc:{start:{line:154,column:27},end:{line:156,column:5}},line:154},19:{name:"(anonymous_19)",decl:{start:{line:157,column:19},end:{line:157,column:20}},loc:{start:{line:157,column:27},end:{line:161,column:5}},line:157},20:{name:"(anonymous_20)",decl:{start:{line:165,column:22},end:{line:165,column:23}},loc:{start:{line:165,column:30},end:{line:168,column:3}},line:165},21:{name:"(anonymous_21)",decl:{start:{line:166,column:55},end:{line:166,column:56}},loc:{start:{line:166,column:66},end:{line:166,column:81}},line:166},22:{name:"(anonymous_22)",decl:{start:{line:169,column:2},end:{line:169,column:3}},loc:{start:{line:169,column:20},end:{line:206,column:3}},line:169},23:{name:"(anonymous_23)",decl:{start:{line:171,column:22},end:{line:171,column:23}},loc:{start:{line:171,column:40},end:{line:202,column:7}},line:171},24:{name:"(anonymous_24)",decl:{start:{line:207,column:2},end:{line:207,column:3}},loc:{start:{line:207,column:11},end:{line:218,column:3}},line:207},25:{name:"(anonymous_25)",decl:{start:{line:214,column:13},end:{line:214,column:14}},loc:{start:{line:214,column:20},end:{line:214,column:38}},line:214}},branchMap:{0:{loc:{start:{line:30,column:2},end:{line:32,column:3}},type:"if",locations:[{start:{line:30,column:2},end:{line:32,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:30},1:{loc:{start:{line:36,column:4},end:{line:38,column:5}},type:"if",locations:[{start:{line:36,column:4},end:{line:38,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:36},2:{loc:{start:{line:36,column:8},end:{line:36,column:64}},type:"binary-expr",locations:[{start:{line:36,column:8},end:{line:36,column:32}},{start:{line:36,column:36},end:{line:36,column:64}}],line:36},3:{loc:{start:{line:70,column:15},end:{line:70,column:131}},type:"binary-expr",locations:[{start:{line:70,column:15},end:{line:70,column:71}},{start:{line:70,column:75},end:{line:70,column:131}}],line:70},4:{loc:{start:{line:78,column:4},end:{line:83,column:5}},type:"if",locations:[{start:{line:78,column:4},end:{line:83,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:78},5:{loc:{start:{line:84,column:4},end:{line:86,column:5}},type:"if",locations:[{start:{line:84,column:4},end:{line:86,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: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},8:{loc:{start:{line:87,column:8},end:{line:87,column:59}},type:"binary-expr",locations:[{start:{line:87,column:8},end:{line:87,column:26}},{start:{line:87,column:30},end:{line:87,column:59}}],line:87},9:{loc:{start:{line:132,column:8},end:{line:136,column:9}},type:"if",locations:[{start:{line:132,column:8},end:{line:136,column:9}},{start:{line:134,column:15},end:{line:136,column:9}}],line:132},10:{loc:{start:{line:148,column:6},end:{line:149,column:15}},type:"if",locations:[{start:{line:148,column:6},end:{line:149,column:15}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:148}},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},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},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:"AAgL6B;AAhL7B,OAAO,WAAuB;AAC9B,OAAO,cAAc;AACrB,OAAO,gBAAwG;AAC/G,OAAO,qBAAqB;AAC5B,OAAO,YAAY;AACnB,OAAO,6BAA6B;AACpC,OAAO,uCAA2D;AAClE,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,SAA2B,6BAA6B;AACxD,OAAO;AACP,OAAO;AACP,OAAO;AAEP,OAAO,sBAAsB;AAC7B,OAAO;AAEP,SAAS,YAAY,OAAoB,WAA4C;AACnF,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;AAEtD,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,EAGA,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,UAAM,kBAAkB,KAAK,MAAM,oBAAoB,KAAK,MAAM,QAAQ;AAC1E,QAAI,KAAK;AAIP,UAAI,SAAS,iBAAiB,EAAC,MAAM,KAAI,CAAC;AAC1C,UAAI,qBAAqB,KAAK,MAAM,SAAS;AAC7C,UAAI,qBAAqB,KAAK,MAAM,SAAS;AAC7C,UAAI,wBAAwB,KAAK,MAAM,SAAS;AAAA,IAClD;AAEA,QAAG,KAAK,MAAM,WAAW,KAAK,MAAM,uBAAuB,KAAK,MAAM,QAAQ,iBAAiB;AAC7F,WAAK,MAAM,QAAQ,gBAAgB;AAAA,IACrC;AACA,QAAI,KAAK,MAAM,WAAW,KAAK,MAAM,oBAAoB;AACvD,WAAK,MAAM,QAAQ,iBAAiB,eAAe;AAEnD,iBAAW,MAAM;AACf,aAAK,MAAM,QAAS,OAAO;AAAA,MAC7B,GAAG,GAAG;AAAA,IACR;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,SAAK,aAAa,GAAG;AAErB,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,gBAAgB;AAAA,MAClC,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,aAAa,KAAU;AACrB,UAAM,iBAAiB;AAAA,MACrB,gBAAgB,OAAO,WAA8D;AACnF,cAAM,WAAW,CAAC;AAClB,YAAI;AACF,gBAAM,UAAU,gDAAgD,OAAO,KAAK;AAC5E,gBAAM,WAAW,MAAM,MAAM,OAAO;AACpC,gBAAM,UAAU,MAAM,SAAS,KAAK;AACpC,qBAAW,WAAW,QAAQ,UAAU;AACtC,kBAAM,SAAS;AAAA,cACb,QAAQ,KAAK,CAAC,KACT,QAAQ,KAAK,CAAC,IAAI,QAAQ,KAAK,CAAC,KAAK;AAAA,cAC1C,QAAQ,KAAK,CAAC,KACT,QAAQ,KAAK,CAAC,IAAI,QAAQ,KAAK,CAAC,KAAK;AAAA,YAC5C;AACA,kBAAM,QAAQ;AAAA,cACZ,MAAM;AAAA,cACN,UAAU;AAAA,gBACR,MAAM;AAAA,gBACN,aAAa;AAAA,cACf;AAAA,cACA,YAAY,QAAQ,WAAW;AAAA,cAC/B,YAAY,QAAQ;AAAA,cACpB,MAAM,QAAQ,WAAW;AAAA,cACzB,YAAY,CAAC,OAAO;AAAA,cACpB;AAAA,YACF;AACA,qBAAS,KAAK,KAAK;AAAA,UACrB;AAAA,QACF,SAAS,GAAG;AACV,kBAAQ,MAAM,wCAAwC,CAAC,EAAE;AAAA,QAC3D;AACA,eAAO;AAAA,UACL;AAAA,QACF;AAAA,MACF;AAAA,IACF;AACA,UAAM,WAAW,IAAI,iBAAiB,gBAAgB,EAAC,YAAY,WAAU,CAAC;AAC9E,QAAI,WAAW,UAAU,UAAU;AAAA,EACrC;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:"5f82f1db20d50d10c048513b2ce08346d056029c"},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();function C9(e,n){return rn().f[0]++,rn().s[0]++,WL.render(e,n),rn().s[1]++,n}function Mte(e,n,t){rn().f[1]++;const r=(rn().s[2]++,{id:"background",type:"background",paint:{"background-color":"#1c1f24"}}),i=(rn().s[3]++,Kee(t));rn().s[4]++,i?(rn().b[0][0]++,rn().s[5]++,n.push(i)):rn().b[0][1]++;const o=(rn().s[6]++,{});rn().s[7]++,Object.keys(e.sources).forEach(a=>{rn().f[2]++;const h=(rn().s[8]++,e.sources[a]);rn().s[9]++,rn().b[2][0]++,h.type!=="raster"&&(rn().b[2][1]++,h.type!=="raster-dem")?(rn().b[1][0]++,rn().s[10]++,o[a]=h):rn().b[1][1]++});const s=(rn().s[11]++,{...e,sources:o,layers:[r].concat(n)});return rn().s[12]++,s}class UR extends Sn.Component{constructor(t){rn().f[7]++,rn().s[15]++;super(t);an(this,"container",(rn().s[14]++,null));an(this,"onLayerSelectById",(rn().s[69]++,t=>{rn().f[20]++;const r=(rn().s[70]++,this.props.mapStyle.layers.findIndex(i=>(rn().f[21]++,rn().s[71]++,i.id===t)));rn().s[72]++,this.props.onLayerSelect(r)}));rn().s[16]++,this.state={map:null,inspect:null}}shouldComponentUpdate(t,r){rn().f[8]++;let i=(rn().s[17]++,!1);rn().s[18]++;try{rn().s[19]++,i=(rn().b[3][0]++,JSON.stringify(this.props)!==JSON.stringify(t)||(rn().b[3][1]++,JSON.stringify(this.state)!==JSON.stringify(r)))}catch{}return rn().s[20]++,i}componentDidUpdate(){var i,o,s;rn().f[9]++;const t=(rn().s[21]++,this.state.map),r=(rn().s[22]++,this.props.replaceAccessTokens(this.props.mapStyle));rn().s[23]++,t?(rn().b[4][0]++,rn().s[24]++,t.setStyle(r,{diff:!0}),rn().s[25]++,t.showTileBoundaries=(i=this.props.options)==null?void 0:i.showTileBoundaries,rn().s[26]++,t.showCollisionBoxes=(o=this.props.options)==null?void 0:o.showCollisionBoxes,rn().s[27]++,t.showOverdrawInspector=(s=this.props.options)==null?void 0:s.showOverdrawInspector):rn().b[4][1]++,rn().s[28]++,rn().b[6][0]++,this.state.inspect&&(rn().b[6][1]++,this.props.inspectModeEnabled!==this.state.inspect._showInspectMap)?(rn().b[5][0]++,rn().s[29]++,this.state.inspect.toggleInspector()):rn().b[5][1]++,rn().s[30]++,rn().b[8][0]++,this.state.inspect&&(rn().b[8][1]++,this.props.inspectModeEnabled)?(rn().b[7][0]++,rn().s[31]++,this.state.inspect.setOriginalStyle(r),rn().s[32]++,setTimeout(()=>{rn().f[10]++,rn().s[33]++,this.state.inspect.render()},500)):rn().b[7][1]++}componentDidMount(){rn().f[11]++;const t=(rn().s[34]++,{...this.props.options,container:this.container,style:this.props.mapStyle,hash:!0,maxZoom:24}),r=(rn().s[35]++,new i_.Map(t));rn().s[36]++;const i=()=>{rn().f[12]++;const g=(rn().s[37]++,r.getCenter()),C=(rn().s[38]++,r.getZoom());rn().s[39]++,this.props.onChange({center:g,zoom:C})};rn().s[40]++,i(),rn().s[41]++,r.showTileBoundaries=t.showTileBoundaries,rn().s[42]++,r.showCollisionBoxes=t.showCollisionBoxes,rn().s[43]++,r.showOverdrawInspector=t.showOverdrawInspector,rn().s[44]++,this.initGeocoder(r);const o=(rn().s[45]++,new kee);rn().s[46]++,r.addControl(o,"top-right");const s=(rn().s[47]++,new i_.NavigationControl({visualizePitch:!0}));rn().s[48]++,r.addControl(s,"top-right");const a=(rn().s[49]++,document.createElement("div")),h=(rn().s[50]++,new $B({popup:new i_.Popup({closeOnClick:!1}),showMapPopup:!0,showMapPopupOnHover:!1,showInspectMapPopupOnHover:!0,showInspectButton:!1,blockHoverPopupOnClick:!0,assignLayerColor:(g,C)=>(rn().f[13]++,rn().s[51]++,G6(cR.brightColor(g,C)).desaturate(.5).string()),buildInspectStyle:(g,C)=>(rn().f[14]++,rn().s[52]++,Mte(g,C,this.props.highlightedLayer)),renderPopup:g=>(rn().f[15]++,rn().s[53]++,this.props.inspectModeEnabled?(rn().b[9][0]++,rn().s[54]++,C9(G.jsx(aee,{features:g}),a)):(rn().b[9][1]++,rn().s[55]++,C9(G.jsx(gR,{features:g,onLayerSelect:this.onLayerSelectById,zoom:this.state.zoom}),a)))}));rn().s[56]++,r.addControl(h),rn().s[57]++,r.on("style.load",()=>{rn().f[16]++,rn().s[58]++,this.setState({map:r,inspect:h,zoom:r.getZoom()})}),rn().s[59]++,r.on("data",g=>{if(rn().f[17]++,rn().s[60]++,g.dataType!=="tile"){rn().b[10][0]++,rn().s[61]++;return}else rn().b[10][1]++;rn().s[62]++,this.props.onDataChange({map:this.state.map})}),rn().s[63]++,r.on("error",g=>{rn().f[18]++,rn().s[64]++,console.log("ERROR",g)}),rn().s[65]++,r.on("zoom",g=>{rn().f[19]++,rn().s[66]++,this.setState({zoom:r.getZoom()})}),rn().s[67]++,r.on("dragend",i),rn().s[68]++,r.on("zoomend",i)}initGeocoder(t){rn().f[22]++;const r=(rn().s[73]++,{forwardGeocode:async o=>{rn().f[23]++;const s=(rn().s[74]++,[]);rn().s[75]++;try{const a=(rn().s[76]++,`https://nominatim.openstreetmap.org/search?q=${o.query}&format=geojson&polygon_geojson=1&addressdetails=1`),h=(rn().s[77]++,await fetch(a)),g=(rn().s[78]++,await h.json());rn().s[79]++;for(const C of g.features){const B=(rn().s[80]++,[C.bbox[0]+(C.bbox[2]-C.bbox[0])/2,C.bbox[1]+(C.bbox[3]-C.bbox[1])/2]),k=(rn().s[81]++,{type:"Feature",geometry:{type:"Point",coordinates:B},place_name:C.properties.display_name,properties:C.properties,text:C.properties.display_name,place_type:["place"],center:B});rn().s[82]++,s.push(k)}}catch(a){rn().s[83]++,console.error(`Failed to forwardGeocode with error: ${a}`)}return rn().s[84]++,{features:s}}}),i=(rn().s[85]++,new wte(r,{maplibregl:i_}));rn().s[86]++,t.addControl(i,"top-left")}render(){return rn().f[24]++,rn().s[87]++,G.jsx("div",{className:"maputnik-map__map",role:"region","aria-label":"Map view",ref:t=>(rn().f[25]++,rn().s[88]++,this.container=t),"data-wd-key":"maplibre:map"})}}an(UR,"defaultProps",(rn().s[13]++,{onMapLoaded:()=>{rn().f[3]++},onDataChange:()=>{rn().f[4]++},onLayerSelect:()=>{rn().f[5]++},onChange:()=>{rn().f[6]++},options:{}}));var Op=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 Ey={PROPERTYCHANGE:"propertychange"};var Ste=function(){function e(){this.disposed=!1}return e.prototype.dispose=function(){this.disposed||(this.disposed=!0,this.disposeInternal())},e.prototype.disposeInternal=function(){},e}();const HB=Ste;function Ete(e,n,t){for(var r,i,o=t||A1,s=0,a=e.length,h=!1;s<a;)r=s+(a-s>>1),i=+o(e[r],n),i<0?s=r+1:(a=r,h=!i);return h?s:~s}function A1(e,n){return e>n?1:e<n?-1:0}function VB(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 Ote(e,n,t){for(;n<t;){var r=e[n];e[n]=e[t],e[t]=r,++n,--t}}function mf(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 Bte(e,n,t){var r=n||A1;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 oy(){return!0}function a5(){return!1}function c1(){}function kte(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 gl=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 QC(e){for(var n in e)delete e[n]}var RR=typeof Object.values=="function"?Object.values:function(e){var n=[];for(var t in e)n.push(e[t]);return n};function d1(e){var n;for(n in e)return!1;return!n}var Ite=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)}}(),Tte=function(e){Ite(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 Op(t):t;s.target||(s.target=this.eventTarget_||this);var a=this.dispatching_||(this.dispatching_={}),h=this.pendingRemovals_||(this.pendingRemovals_={});i in a||(a[i]=0,h[i]=0),++a[i];for(var g,C=0,B=o.length;C<B;++C)if("handleEvent"in o[C]?g=o[C].handleEvent(s):g=o[C].call(this,s),g===!1||s.propagationStopped){g=!1;break}if(--a[i]===0){var k=h[i];for(delete h[i];k--;)this.removeEventListener(i,c1);delete a[i]}return g}},n.prototype.disposeInternal=function(){this.listeners_&&QC(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]=c1,++this.pendingRemovals_[t]):(i.splice(o,1),i.length===0&&delete this.listeners_[t]))}},n}(HB);const Gy=Tte,Di={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 ko(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 C3(e,n,t,r){return ko(e,n,t,r,!0)}function is(e){e&&e.target&&(e.target.removeEventListener(e.type,e.listener),QC(e))}var Kte=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)}}(),s5=function(e){Kte(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(Di.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]=ko(this,t[s],r);return o}else return ko(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]=C3(this,t[s],r)}else i=C3(this,t,r);return r.ol_key=i,i},n.prototype.unInternal=function(t,r){var i=r.ol_key;if(i)lC(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}(Gy);s5.prototype.on;s5.prototype.once;s5.prototype.un;function lC(e){if(Array.isArray(e))for(var n=0,t=e.length;n<t;++n)is(e[n]);else is(e)}const zR=s5;function pi(){return function(){throw new Error("Unimplemented abstract method.")}()}var Pte=0;function $i(e){return e.ol_uid||(e.ol_uid=String(++Pte))}var Fte="6.15.1",jR=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)}}(),b9=function(e){jR(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.key=r,o.oldValue=i,o}return n}(Op),fh=function(e){jR(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_&&gl({},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 b9(i,t,r)),i=Ey.PROPERTYCHANGE,this.hasListener(i)&&this.dispatchEvent(new b9(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_&&gl(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],d1(this.values_)&&(this.values_=null),r||this.notify(t,i)}},n}(zR),Dte=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)}}(),Lte=function(e){Dte(n,e);function n(t){var r=this,i="v"+Fte.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 WR=Lte;function ho(e,n){if(!e)throw new WR(n)}var Ute=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)}}(),Rte=function(e){Ute(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_&&(is(this.geometryChangeKey_),this.geometryChangeKey_=null);var t=this.getGeometry();t&&(this.geometryChangeKey_=ko(t,Di.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?zte(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}(fh);function zte(e){if(typeof e=="function")return e;var n;if(Array.isArray(e))n=e;else{ho(typeof e.getZIndex=="function",41);var t=e;n=[t]}return function(){return n}}var OA={RADIANS:"radians",DEGREES:"degrees",FEET:"ft",METERS:"m",PIXELS:"pixels",TILE_PIXELS:"tile-pixels",USFEET:"us-ft"},vf={};vf[OA.RADIANS]=6370997/(2*Math.PI);vf[OA.DEGREES]=2*Math.PI*6370997/360;vf[OA.FEET]=.3048;vf[OA.METERS]=1;vf[OA.USFEET]=1200/3937;var Wm=typeof navigator<"u"&&typeof navigator.userAgent<"u"?navigator.userAgent.toLowerCase():"",jte=Wm.indexOf("firefox")!==-1,Wte=Wm.indexOf("safari")!==-1&&Wm.indexOf("chrom")==-1;Wte&&(Wm.indexOf("version/15.4")>=0||Wm.match(/cpu (os|iphone os) 15_4 like mac os x/));var Nte=Wm.indexOf("webkit")!==-1&&Wm.indexOf("edge")==-1,Gte=Wm.indexOf("macintosh")!==-1,NR=typeof devicePixelRatio<"u"?devicePixelRatio:1,l5=typeof WorkerGlobalScope<"u"&&typeof OffscreenCanvas<"u"&&self instanceof WorkerGlobalScope,Qte=typeof Image<"u"&&Image.prototype.decode,GR=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}(),QR=new Array(6);function _d(){return[1,0,0,1,0,0]}function x9(e){return u5(e,1,0,0,1,0,0)}function ZB(e,n){var t=e[0],r=e[1],i=e[2],o=e[3],s=e[4],a=e[5],h=n[0],g=n[1],C=n[2],B=n[3],k=n[4],P=n[5];return e[0]=t*h+i*g,e[1]=r*h+o*g,e[2]=t*C+i*B,e[3]=r*C+o*B,e[4]=t*k+i*P+s,e[5]=r*k+o*P+a,e}function u5(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 $te(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 fl(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 pM(e,n,t){return ZB(e,u5(QR,n,0,0,t,0,0))}function Yte(e,n,t){return u5(e,n,0,0,t,0,0)}function qte(e,n,t){return ZB(e,u5(QR,1,0,0,1,n,t))}function _f(e,n,t,r,i,o,s,a){var h=Math.sin(o),g=Math.cos(o);return e[0]=r*g,e[1]=i*h,e[2]=-r*h,e[3]=i*g,e[4]=s*r*g-a*r*h+n,e[5]=s*i*h+a*i*g+t,e}function XB(e,n){var t=Hte(n);ho(t!==0,32);var r=n[0],i=n[1],o=n[2],s=n[3],a=n[4],h=n[5];return e[0]=s/t,e[1]=-i/t,e[2]=-o/t,e[3]=r/t,e[4]=(o*h-s*a)/t,e[5]=-(r*h-i*a)/t,e}function Hte(e){return e[0]*e[3]-e[1]*e[2]}var w9;function $R(e){var n="matrix("+e.join(", ")+")";if(l5)return n;var t=w9||(w9=document.createElement("div"));return t.style.transform=n,t.style.transform}const du={UNKNOWN:0,INTERSECTING:1,ABOVE:2,RIGHT:4,BELOW:8,LEFT:16};function H6(e){for(var n=xd(),t=0,r=e.length;t<r;++t)k_(n,e[t]);return n}function Vte(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 Cf(r,i,o,s,t)}function Pm(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 YR(e,n){return n?(n[0]=e[0],n[1]=e[1],n[2]=e[2],n[3]=e[3],n):e.slice()}function C1(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 $C(e,n){return JB(e,n[0],n[1])}function ym(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 V6(e,n){var t=e[0],r=e[1],i=e[2],o=e[3],s=n[0],a=n[1],h=du.UNKNOWN;return s<t?h=h|du.LEFT:s>i&&(h=h|du.RIGHT),a<r?h=h|du.BELOW:a>o&&(h=h|du.ABOVE),h===du.UNKNOWN&&(h=du.INTERSECTING),h}function xd(){return[1/0,1/0,-1/0,-1/0]}function Cf(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 YC(e){return Cf(1/0,1/0,-1/0,-1/0,e)}function qR(e,n){var t=e[0],r=e[1];return Cf(t,r,t,r,n)}function e7(e,n,t,r,i){var o=YC(i);return VR(o,e,n,t,r)}function Oy(e,n){return e[0]==n[0]&&e[2]==n[2]&&e[1]==n[1]&&e[3]==n[3]}function HR(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 k_(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 VR(e,n,t,r,i){for(;t<r;t+=i)Zte(e,n[t],n[t+1]);return e}function Zte(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 ZR(e,n){var t;return t=n(A5(e)),t||(t=n(c5(e)),t)||(t=n(d5(e)),t)||(t=n($m(e)),t)?t:!1}function Z6(e){var n=0;return t7(e)||(n=ys(e)*rc(e)),n}function A5(e){return[e[0],e[1]]}function c5(e){return[e[2],e[1]]}function Nm(e){return[(e[0]+e[2])/2,(e[1]+e[3])/2]}function Xte(e,n){var t;return n==="bottom-left"?t=A5(e):n==="bottom-right"?t=c5(e):n==="top-left"?t=$m(e):n==="top-right"?t=d5(e):ho(!1,13),t}function X6(e,n,t,r,i){var o=J6(e,n,t,r),s=o[0],a=o[1],h=o[2],g=o[3],C=o[4],B=o[5],k=o[6],P=o[7];return Cf(Math.min(s,h,C,k),Math.min(a,g,B,P),Math.max(s,h,C,k),Math.max(a,g,B,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),h=i*s,g=i*a,C=o*s,B=o*a,k=e[0],P=e[1];return[k-h+B,P-g-C,k-h-B,P-g+C,k+h-B,P+g+C,k+h+B,P+g-C,k-h+B,P-g-C]}function rc(e){return e[3]-e[1]}function Z0(e,n,t){var r=t||xd();return pl(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]):YC(r),r}function $m(e){return[e[0],e[3]]}function d5(e){return[e[2],e[3]]}function ys(e){return e[2]-e[0]}function pl(e,n){return e[0]<=n[2]&&e[2]>=n[0]&&e[1]<=n[3]&&e[3]>=n[1]}function t7(e){return e[2]<e[0]||e[3]<e[1]}function Jte(e,n){return n?(n[0]=e[0],n[1]=e[1],n[2]=e[2],n[3]=e[3],n):e}function ene(e,n,t){var r=!1,i=V6(e,n),o=V6(e,t);if(i===du.INTERSECTING||o===du.INTERSECTING)r=!0;else{var s=e[0],a=e[1],h=e[2],g=e[3],C=n[0],B=n[1],k=t[0],P=t[1],L=(P-B)/(k-C),J=void 0,N=void 0;o&du.ABOVE&&!(i&du.ABOVE)&&(J=k-(P-g)/L,r=J>=s&&J<=h),!r&&o&du.RIGHT&&!(i&du.RIGHT)&&(N=P-(k-h)*L,r=N>=a&&N<=g),!r&&o&du.BELOW&&!(i&du.BELOW)&&(J=k-(P-a)/L,r=J>=s&&J<=h),!r&&o&du.LEFT&&!(i&du.LEFT)&&(N=P-(k-s)*L,r=N>=a&&N<=g)}return r}function tne(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 h=[],g=[],a=0,C=i.length;a<C;a+=2)h.push(i[a]),g.push(i[a+1]);return Vte(h,g,t)}function XR(e,n){var t=n.getExtent(),r=Nm(e);if(n.canWrapX()&&(r[0]<t[0]||r[0]>=t[2])){var i=ys(t),o=Math.floor((r[0]-t[0])/i),s=o*i;e[0]-=s,e[2]-=s}return e}function nne(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]]];XR(e,n);var r=ys(t);if(ys(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 rne=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_||vf[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 n7=rne;function Fl(e,n,t){return Math.min(Math.max(e,n),t)}var ine=function(){var e;return"cosh"in Math?e=Math.cosh:e=function(n){var t=Math.exp(n);return(t+1/t)/2},e}(),one=function(){var e;return"log2"in Math?e=Math.log2:e=function(n){return Math.log(n)*Math.LOG2E},e}();function ane(e,n,t,r,i,o){var s=i-t,a=o-r;if(s!==0||a!==0){var h=((e-t)*s+(n-r)*a)/(s*s+a*a);h>1?(t=i,r=o):h>0&&(t+=s*h,r+=a*h)}return X0(e,n,t,r)}function X0(e,n,t,r){var i=t-e,o=r-n;return i*i+o*o}function sne(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 h=t+1;h<n;h++)for(var g=-e[h][t]/e[t][t],C=t;C<n+1;C++)t==C?e[h][C]=0:e[h][C]+=g*e[t][C]}for(var B=new Array(n),k=n-1;k>=0;k--){B[k]=e[k][n]/e[k][k];for(var P=k-1;P>=0;P--)e[P][n]-=e[P][k]*B[k]}return B}function C2(e){return e*Math.PI/180}function J0(e,n){var t=e%n;return t*n<0?t+n:t}function dp(e,n,t){return e+t*(n-e)}function JR(e,n){var t=Math.pow(10,n);return Math.round(e*t)/t}function Cx(e,n){return Math.floor(JR(e,n))}function bx(e,n){return Math.ceil(JR(e,n))}var lne=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)}}(),qC=6378137,Rg=Math.PI*qC,une=[-Rg,-Rg,Rg,Rg],Ane=[-180,-85,180,85],xx=qC*Math.log(Math.tan(Math.PI/2)),sg=function(e){lne(n,e);function n(t){return e.call(this,{code:t,units:OA.METERS,extent:une,global:!0,worldExtent:Ane,getPointResolution:function(r,i){return r/ine(i[1]/qC)}})||this}return n}(n7),M9=[new sg("EPSG:3857"),new sg("EPSG:102100"),new sg("EPSG:102113"),new sg("EPSG:900913"),new sg("http://www.opengis.net/def/crs/EPSG/0/3857"),new sg("http://www.opengis.net/gml/srs/epsg.xml#3857")];function cne(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]=Rg*e[s]/180;var a=qC*Math.log(Math.tan(Math.PI*(+e[s+1]+90)/360));a>xx?a=xx:a<-xx&&(a=-xx),o[s+1]=a}return o}function dne(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]/Rg,o[s+1]=360*Math.atan(Math.exp(e[s+1]/qC))/Math.PI-90;return o}var hne=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)}}(),fne=6378137,S9=[-180,-90,180,90],pne=Math.PI*fne/180,m0=function(e){hne(n,e);function n(t,r){return e.call(this,{code:t,units:OA.DEGREES,extent:S9,axisOrientation:r,global:!0,metersPerUnit:pne,worldExtent:S9})||this}return n}(n7),E9=[new m0("CRS:84"),new m0("EPSG:4326","neu"),new m0("urn:ogc:def:crs:OGC:1.3:CRS84"),new m0("urn:ogc:def:crs:OGC:2:84"),new m0("http://www.opengis.net/def/crs/OGC/1.3/CRS84"),new m0("http://www.opengis.net/gml/srs/epsg.xml#4326","neu"),new m0("http://www.opengis.net/def/crs/EPSG/0/4326","neu")],eE={};function mne(e){return eE[e]||eE[e.replace(/urn:(x-)?ogc:def:crs:EPSG:(.*:)?(\w+)$/,"EPSG:$3")]||null}function gne(e,n){eE[e]=n}var ay={};function b3(e,n,t){var r=e.getCode(),i=n.getCode();r in ay||(ay[r]={}),ay[r][i]=t}function yne(e,n){var t;return e in ay&&n in ay[e]&&(t=ay[e][n]),t}function vne(e,n){return e[0]+=+n[0],e[1]+=+n[1],e}function x3(e,n){for(var t=!0,r=e.length-1;r>=0;--r)if(e[r]!=n[r]){t=!1;break}return t}function r7(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 _ne(e,n){return e[0]*=n,e[1]*=n,e}function i7(e,n){if(n.canWrapX()){var t=ys(n.getExtent()),r=Cne(e,n,t);r&&(e[0]-=r*t)}return e}function Cne(e,n,t){var r=n.getExtent(),i=0;if(n.canWrapX()&&(e[0]<r[0]||e[0]>r[2])){var o=t||ys(r);i=Math.floor((e[0]-r[0])/o)}return i}var bne=63710088e-1;function O9(e,n,t){var r=t||bne,i=C2(e[1]),o=C2(n[1]),s=(o-i)/2,a=C2(n[0]-e[0])/2,h=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(h),Math.sqrt(1-h))}var tE=!0;function ez(e){var n=e===void 0?!0:e;tE=!n}function o7(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 tz(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 xne(e){gne(e.getCode(),e),b3(e,e,o7)}function wne(e){e.forEach(xne)}function qs(e){return typeof e=="string"?mne(e):e||null}function B9(e,n,t,r){e=qs(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/vf[r])}}else{var a=e.getUnits();if(a==OA.DEGREES&&!r||r==OA.DEGREES)i=n;else{var h=h5(e,qs("EPSG:4326"));if(h===tz&&a!==OA.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=h(g,g,2);var C=O9(g.slice(0,2),g.slice(2,4)),B=O9(g.slice(4,6),g.slice(6,8));i=(C+B)/2}var s=r?vf[r]:e.getMetersPerUnit();s!==void 0&&(i/=s)}}return i}function k9(e){wne(e),e.forEach(function(n){e.forEach(function(t){n!==t&&b3(n,t,o7)})})}function Mne(e,n,t,r){e.forEach(function(i){n.forEach(function(o){b3(i,o,t),b3(o,i,r)})})}function a7(e,n){return e?typeof e=="string"?qs(e):e:qs(n)}function nE(e,n){return ez(),s7(e,"EPSG:4326",n!==void 0?n:"EPSG:3857")}function mM(e,n){var t=s7(e,n!==void 0?n:"EPSG:3857","EPSG:4326"),r=t[0];return(r<-180||r>180)&&(t[0]=J0(r+180,360)-180),t}function k0(e,n){if(e===n)return!0;var t=e.getUnits()===n.getUnits();if(e.getCode()===n.getCode())return t;var r=h5(e,n);return r===o7&&t}function h5(e,n){var t=e.getCode(),r=n.getCode(),i=yne(t,r);return i||(i=tz),i}function w3(e,n){var t=qs(e),r=qs(n);return h5(t,r)}function s7(e,n,t){var r=w3(n,t);return r(e,void 0,e.length)}var Sne=null;function Ene(){return Sne}function rE(e,n){return e}function op(e,n){return tE&&!x3(e,[0,0])&&e[0]>=-180&&e[0]<=180&&e[1]>=-90&&e[1]<=90&&(tE=!1,console.warn("Call useGeographic() from ol/proj once to work with [longitude, latitude] coordinates.")),e}function nz(e,n){return e}function z0(e,n){return e}function One(){k9(M9),k9(E9),Mne(E9,M9,cne,dne)}One();function Fm(e,n,t,r,i,o){for(var s=o||[],a=0,h=n;h<t;h+=r){var g=e[h],C=e[h+1];s[a++]=i[0]*g+i[2]*C+i[4],s[a++]=i[1]*g+i[3]*C+i[5]}return o&&s.length!=a&&(s.length=a),s}function rz(e,n,t,r,i,o,s){for(var a=s||[],h=Math.cos(i),g=Math.sin(i),C=o[0],B=o[1],k=0,P=n;P<t;P+=r){var L=e[P]-C,J=e[P+1]-B;a[k++]=C+L*h-J*g,a[k++]=B+L*g+J*h;for(var N=P+2;N<P+r;++N)a[k++]=e[N]}return s&&a.length!=k&&(a.length=k),a}function Bne(e,n,t,r,i,o,s,a){for(var h=a||[],g=s[0],C=s[1],B=0,k=n;k<t;k+=r){var P=e[k]-g,L=e[k+1]-C;h[B++]=g+i*P,h[B++]=C+o*L;for(var J=k+2;J<k+r;++J)h[B++]=e[J]}return a&&h.length!=B&&(h.length=B),h}function kne(e,n,t,r,i,o,s){for(var a=s||[],h=0,g=n;g<t;g+=r){a[h++]=e[g]+i,a[h++]=e[g+1]+o;for(var C=g+2;C<g+r;++C)a[h++]=e[C]}return s&&a.length!=h&&(a.length=h),a}var Ine=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)}}(),I9=_d(),Tne=function(e){Ine(n,e);function n(){var t=e.call(this)||this;return t.extent_=xd(),t.extentRevision_=-1,t.simplifiedGeometryMaxMinSquaredTolerance=0,t.simplifiedGeometryRevision=0,t.simplifyTransformedInternal=kte(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 pi()},n.prototype.closestPointXY=function(t,r,i,o){return pi()},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 pi()},n.prototype.getExtent=function(t){if(this.extentRevision_!=this.getRevision()){var r=this.computeExtent(this.extent_);(isNaN(r[0])||isNaN(r[1]))&&YC(r),this.extentRevision_=this.getRevision()}return Jte(this.extent_,t)},n.prototype.rotate=function(t,r){pi()},n.prototype.scale=function(t,r,i){pi()},n.prototype.simplify=function(t){return this.getSimplifiedGeometry(t*t)},n.prototype.getSimplifiedGeometry=function(t){return pi()},n.prototype.getType=function(){return pi()},n.prototype.applyTransform=function(t){pi()},n.prototype.intersectsExtent=function(t){return pi()},n.prototype.translate=function(t,r){pi()},n.prototype.transform=function(t,r){var i=qs(t),o=i.getUnits()==OA.TILE_PIXELS?function(s,a,h){var g=i.getExtent(),C=i.getWorldExtent(),B=rc(C)/rc(g);return _f(I9,C[0],C[3],B,-B,0,0,0),Fm(s,0,s.length,h,I9,a),w3(i,r)(s,a,h)}:w3(i,r);return this.applyTransform(o),this},n}(fh);const iz=Tne;var Kne=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)}}(),Pne=function(e){Kne(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(is),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(ko(this.geometries_[t],Di.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<C1(this.getExtent(),t,r))return o;for(var s=this.geometries_,a=0,h=s.length;a<h;++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){YC(t);for(var r=this.geometries_,i=0,o=r.length;i<o;++i)HR(t,r[i].getExtent());return t},n.prototype.getGeometries=function(){return T9(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 h=i[s],g=h.getSimplifiedGeometry(t);r.push(g),g!==h&&(o=!0)}if(o){var C=new n(null);return C.setGeometriesArray(r),C}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=Nm(this.getExtent()));for(var s=this.geometries_,a=0,h=s.length;a<h;++a)s[a].scale(t,r,o);this.changed()},n.prototype.setGeometries=function(t){this.setGeometriesArray(T9(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}(iz);function T9(e){for(var n=[],t=0,r=e.length;t<r;++t)n.push(e[t].clone());return n}const Fne=Pne;var oz=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?qs(t.dataProjection):this.readProjection(n);t.extent&&i&&i.getUnits()===OA.TILE_PIXELS&&(i=qs(i),i.setWorldExtent(t.extent)),r={dataProjection:i,featureProjection:t.featureProjection}}return this.adaptOptions(r)},e.prototype.adaptOptions=function(n){return gl({dataProjection:this.dataProjection,featureProjection:this.defaultFeatureProjection},n)},e.prototype.getType=function(){return pi()},e.prototype.readFeature=function(n,t){return pi()},e.prototype.readFeatures=function(n,t){return pi()},e.prototype.readGeometry=function(n,t){return pi()},e.prototype.readProjection=function(n){return pi()},e.prototype.writeFeature=function(n,t){return pi()},e.prototype.writeFeatures=function(n,t){return pi()},e.prototype.writeGeometry=function(n,t){return pi()},e}();function l7(e,n,t){var r=t?qs(t.featureProjection):null,i=t?qs(t.dataProjection):null,o;if(r&&i&&!k0(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(h){for(var g=0,C=h.length;g<C;++g)h[g]=Math.round(h[g]*s)/s;return h};o===e&&(o=e.clone()),o.applyTransform(a)}return o}var Dne=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)}}(),Lne=function(e){Dne(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(wx(t),this.getReadOptions(t,r))},n.prototype.readFeatures=function(t,r){return this.readFeaturesFromObject(wx(t),this.getReadOptions(t,r))},n.prototype.readFeatureFromObject=function(t,r){return pi()},n.prototype.readFeaturesFromObject=function(t,r){return pi()},n.prototype.readGeometry=function(t,r){return this.readGeometryFromObject(wx(t),this.getReadOptions(t,r))},n.prototype.readGeometryFromObject=function(t,r){return pi()},n.prototype.readProjection=function(t){return this.readProjectionFromObject(wx(t))},n.prototype.readProjectionFromObject=function(t){return pi()},n.prototype.writeFeature=function(t,r){return JSON.stringify(this.writeFeatureObject(t,r))},n.prototype.writeFeatureObject=function(t,r){return pi()},n.prototype.writeFeatures=function(t,r){return JSON.stringify(this.writeFeaturesObject(t,r))},n.prototype.writeFeaturesObject=function(t,r){return pi()},n.prototype.writeGeometry=function(t,r){return JSON.stringify(this.writeGeometryObject(t,r))},n.prototype.writeGeometryObject=function(t,r){return pi()},n}(oz);function wx(e){if(typeof e=="string"){var n=JSON.parse(e);return n||null}else return e!==null?e:null}const Une=Lne,za={XY:"XY",XYZ:"XYZ",XYM:"XYM",XYZM:"XYZM"};var Rne=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)}}(),zne=function(e){Rne(n,e);function n(){var t=e.call(this)||this;return t.layout=za.XY,t.stride=2,t.flatCoordinates=null,t}return n.prototype.computeExtent=function(t){return e7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)},n.prototype.getCoordinates=function(){return pi()},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=K9(t),this.layout=t,this.flatCoordinates=r},n.prototype.setCoordinates=function(t,r){pi()},n.prototype.setLayout=function(t,r,i){var o;if(t)o=K9(t);else{for(var s=0;s<i;++s)if(r.length===0){this.layout=za.XY,this.stride=2;return}else r=r[0];o=r.length,t=jne(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();rz(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=Nm(this.getExtent()));var a=this.getFlatCoordinates();if(a){var h=this.getStride();Bne(a,0,a.length,h,t,o,s,a),this.changed()}},n.prototype.translate=function(t,r){var i=this.getFlatCoordinates();if(i){var o=this.getStride();kne(i,0,i.length,o,t,r,i),this.changed()}},n}(iz);function jne(e){var n;return e==2?n=za.XY:e==3?n=za.XYZ:e==4&&(n=za.XYZM),n}function K9(e){var n;return e==za.XY?n=2:e==za.XYZ||e==za.XYM?n=3:e==za.XYZM&&(n=4),n}function Wne(e,n,t){var r=e.getFlatCoordinates();if(r){var i=e.getStride();return Fm(r,0,r.length,i,n,t)}else return null}const b1=zne;function P9(e,n,t,r,i,o,s){var a=e[n],h=e[n+1],g=e[t]-a,C=e[t+1]-h,B;if(g===0&&C===0)B=n;else{var k=((i-a)*g+(o-h)*C)/(g*g+C*C);if(k>1)B=t;else if(k>0){for(var P=0;P<r;++P)s[P]=dp(e[n+P],e[t+P],k);s.length=r;return}else B=n}for(var P=0;P<r;++P)s[P]=e[B+P];s.length=r}function u7(e,n,t,r,i){var o=e[n],s=e[n+1];for(n+=r;n<t;n+=r){var a=e[n],h=e[n+1],g=X0(o,s,a,h);g>i&&(i=g),o=a,s=h}return i}function A7(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){var a=t[o];i=u7(e,n,a,r,i),n=a}return i}function Nne(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){var a=t[o];i=A7(e,n,a,r,i),n=a[a.length-1]}return i}function c7(e,n,t,r,i,o,s,a,h,g,C){if(n==t)return g;var B,k;if(i===0)if(k=X0(s,a,e[n],e[n+1]),k<g){for(B=0;B<r;++B)h[B]=e[n+B];return h.length=r,k}else return g;for(var P=C||[NaN,NaN],L=n+r;L<t;)if(P9(e,L-r,L,r,s,a,P),k=X0(s,a,P[0],P[1]),k<g){for(g=k,B=0;B<r;++B)h[B]=P[B];h.length=r,L+=r}else L+=r*Math.max((Math.sqrt(k)-Math.sqrt(g))/i|0,1);if(o&&(P9(e,t-r,n,r,s,a,P),k=X0(s,a,P[0],P[1]),k<g)){for(g=k,B=0;B<r;++B)h[B]=P[B];h.length=r}return g}function d7(e,n,t,r,i,o,s,a,h,g,C){for(var B=C||[NaN,NaN],k=0,P=t.length;k<P;++k){var L=t[k];g=c7(e,n,L,r,i,o,s,a,h,g,B),n=L}return g}function Gne(e,n,t,r,i,o,s,a,h,g,C){for(var B=C||[NaN,NaN],k=0,P=t.length;k<P;++k){var L=t[k];g=d7(e,n,L,r,i,o,s,a,h,g,B),n=L[L.length-1]}return g}function Qne(e,n,t,r){for(var i=0,o=t.length;i<o;++i)e[n++]=t[i];return n}function f5(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 h7(e,n,t,r,i){for(var o=i||[],s=0,a=0,h=t.length;a<h;++a){var g=f5(e,n,t[a],r);o[s++]=g,n=g}return o.length=s,o}function $ne(e,n,t,r,i){for(var o=i||[],s=0,a=0,h=t.length;a<h;++a){var g=h7(e,n,t[a],r,o[s]);o[s++]=g,n=g[g.length-1]}return o.length=s,o}function f7(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 h=new Array(a);h[0]=1,h[a-1]=1;for(var g=[n,t-r],C=0;g.length>0;){for(var B=g.pop(),k=g.pop(),P=0,L=e[k],J=e[k+1],N=e[B],$=e[B+1],q=k+r;q<B;q+=r){var oe=e[q],ce=e[q+1],me=ane(oe,ce,L,J,N,$);me>P&&(C=q,P=me)}P>i&&(h[(C-n)/r]=1,k+r<C&&g.push(k,C),C+r<B&&g.push(C,B))}for(var q=0;q<a;++q)h[q]&&(o[s++]=e[n+q*r],o[s++]=e[n+q*r+1]);return s}function Yne(e,n,t,r,i,o,s,a){for(var h=0,g=t.length;h<g;++h){var C=t[h];s=f7(e,n,C,r,i,o,s),a.push(s),n=C}return s}function M0(e,n){return n*Math.round(e/n)}function qne(e,n,t,r,i,o,s){if(n==t)return s;var a=M0(e[n],i),h=M0(e[n+1],i);n+=r,o[s++]=a,o[s++]=h;var g,C;do if(g=M0(e[n],i),C=M0(e[n+1],i),n+=r,n==t)return o[s++]=g,o[s++]=C,s;while(g==a&&C==h);for(;n<t;){var B=M0(e[n],i),k=M0(e[n+1],i);if(n+=r,!(B==g&&k==C)){var P=g-a,L=C-h,J=B-a,N=k-h;if(P*N==L*J&&(P<0&&J<P||P==J||P>0&&J>P)&&(L<0&&N<L||L==N||L>0&&N>L)){g=B,C=k;continue}o[s++]=g,o[s++]=C,a=g,h=C,g=B,C=k}}return o[s++]=g,o[s++]=C,s}function az(e,n,t,r,i,o,s,a){for(var h=0,g=t.length;h<g;++h){var C=t[h];s=qne(e,n,C,r,i,o,s),a.push(s),n=C}return s}function Hne(e,n,t,r,i,o,s,a){for(var h=0,g=t.length;h<g;++h){var C=t[h],B=[];s=az(e,n,C,r,i,o,s,B),a.push(B),n=C[C.length-1]}return s}function sz(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 vm(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 uC(e,n,t,r,i){for(var o=i!==void 0?i:[],s=0,a=0,h=t.length;a<h;++a){var g=t[a];o[s++]=vm(e,n,g,r,o[s]),n=g}return o.length=s,o}function iE(e,n,t,r,i){for(var o=i!==void 0?i:[],s=0,a=0,h=t.length;a<h;++a){var g=t[a];o[s++]=uC(e,n,g,r,o[s]),n=g[g.length-1]}return o.length=s,o}function M3(e,n,t,r,i,o,s){var a,h,g=(t-n)/r;if(g===1)a=n;else if(g===2)a=n,h=i;else if(g!==0){for(var C=e[n],B=e[n+1],k=0,P=[0],L=n+r;L<t;L+=r){var J=e[L],N=e[L+1];k+=Math.sqrt((J-C)*(J-C)+(N-B)*(N-B)),P.push(k),C=J,B=N}var $=i*k,q=Ete(P,$);q<0?(h=($-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,ce=o||new Array(oe),L=0;L<oe;++L)ce[L]=a===void 0?NaN:h===void 0?e[a+L]:dp(e[a+L],e[a+r+L],h);return ce}function oE(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,h=t/r;a<h;){var g=a+h>>1;i<e[(g+1)*r-1]?h=g:a=g+1}var C=e[a*r-1];if(i==C)return e.slice((a-1)*r,(a-1)*r+r);var B=e[(a+1)*r-1],k=(i-C)/(B-C);s=[];for(var P=0;P<r-1;++P)s.push(dp(e[(a-1)*r+P],e[a*r+P],k));return s.push(i),s}function Vne(e,n,t,r,i,o,s){if(s)return oE(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 h=0,g=t.length;h<g;++h){var C=t[h];if(n!=C){if(i<e[n+r-1])return null;if(i<=e[C-1])return oE(e,n,C,r,i,!1);n=C}}return null}function Zne(e,n,t,r,i){var o=ZR(i,function(s){return!j0(e,n,t,r,s[0],s[1])});return!o}function j0(e,n,t,r,i,o){for(var s=0,a=e[t-r],h=e[t-r+1];n<t;n+=r){var g=e[n],C=e[n+1];h<=o?C>o&&(g-a)*(o-h)-(i-a)*(C-h)>0&&s++:C<=o&&(g-a)*(o-h)-(i-a)*(C-h)<0&&s--,a=g,h=C}return s!==0}function p7(e,n,t,r,i,o){if(t.length===0||!j0(e,n,t[0],r,i,o))return!1;for(var s=1,a=t.length;s<a;++s)if(j0(e,t[s-1],t[s],r,i,o))return!1;return!0}function Xne(e,n,t,r,i,o){if(t.length===0)return!1;for(var s=0,a=t.length;s<a;++s){var h=t[s];if(p7(e,n,h,r,i,o))return!0;n=h[h.length-1]}return!1}function p5(e,n,t,r,i){var o=VR(xd(),e,n,t,r);return pl(i,o)?ym(i,o)||o[0]>=i[0]&&o[2]<=i[2]||o[1]>=i[1]&&o[3]<=i[3]?!0:sz(e,n,t,r,function(s,a){return ene(i,s,a)}):!1}function Jne(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){if(p5(e,n,t[o],r,i))return!0;n=t[o]}return!1}function lz(e,n,t,r,i){return!!(p5(e,n,t,r,i)||j0(e,n,t,r,i[0],i[1])||j0(e,n,t,r,i[0],i[3])||j0(e,n,t,r,i[2],i[1])||j0(e,n,t,r,i[2],i[3]))}function uz(e,n,t,r,i){if(!lz(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(Zne(e,t[o-1],t[o],r,i)&&!p5(e,t[o-1],t[o],r,i))return!1;return!0}function ere(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){var a=t[o];if(uz(e,n,a,r,i))return!0;n=a[a.length-1]}return!1}function Az(e,n,t,r){for(var i=e[n],o=e[n+1],s=0,a=n+r;a<t;a+=r){var h=e[a],g=e[a+1];s+=Math.sqrt((h-i)*(h-i)+(g-o)*(g-o)),i=h,o=g}return s}var tre=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)}}(),nre=function(e){tre(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?mf(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<C1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(u7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),c7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!1,t,r,i,o))},n.prototype.forEachSegment=function(t){return sz(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)},n.prototype.getCoordinateAtM=function(t,r){if(this.layout!=za.XYM&&this.layout!=za.XYZM)return null;var i=r!==void 0?r:!1;return oE(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,i)},n.prototype.getCoordinates=function(){return vm(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)},n.prototype.getCoordinateAt=function(t,r){return M3(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,r,this.stride)},n.prototype.getLength=function(){return Az(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=f7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,r,0),new n(r,za.XY)},n.prototype.getType=function(){return"LineString"},n.prototype.intersectsExtent=function(t){return p5(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=f5(this.flatCoordinates,0,t,this.stride),this.changed()},n}(b1);const S3=nre;var rre=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)}}(),ire=function(e){rre(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,h=[],g=[],C=0,B=a.length;C<B;++C){var k=a[C];C===0&&(s=k.getLayout()),mf(h,k.getFlatCoordinates()),g.push(h.length)}o.setFlatCoordinates(s,h),o.ends_=g}return o}return n.prototype.appendLineString=function(t){this.flatCoordinates?mf(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<C1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(A7(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),d7(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!1,t,r,i,o))},n.prototype.getCoordinateAtM=function(t,r,i){if(this.layout!=za.XYM&&this.layout!=za.XYZM||this.flatCoordinates.length===0)return null;var o=r!==void 0?r:!1,s=i!==void 0?i:!1;return Vne(this.flatCoordinates,0,this.ends_,this.stride,t,o,s)},n.prototype.getCoordinates=function(){return uC(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 S3(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,h=r.length;a<h;++a){var g=r[a],C=new S3(t.slice(s,g),i);o.push(C),s=g}return o},n.prototype.getFlatMidpoints=function(){for(var t=[],r=this.flatCoordinates,i=0,o=this.ends_,s=this.stride,a=0,h=o.length;a<h;++a){var g=o[a],C=M3(r,i,g,s,.5);mf(t,C),i=g}return t},n.prototype.getSimplifiedGeometryInternal=function(t){var r=[],i=[];return r.length=Yne(this.flatCoordinates,0,this.ends_,this.stride,t,r,0,i),new n(r,za.XY,i)},n.prototype.getType=function(){return"MultiLineString"},n.prototype.intersectsExtent=function(t){return Jne(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=h7(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=i.length===0?0:i[i.length-1],this.changed()},n}(b1);const cz=ire;var ore=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)}}(),are=function(e){ore(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=X0(t,r,s[0],s[1]);if(a<o){for(var h=this.stride,g=0;g<h;++g)i[g]=s[g];return i.length=h,a}else return o},n.prototype.getCoordinates=function(){return this.flatCoordinates?this.flatCoordinates.slice():[]},n.prototype.computeExtent=function(t){return qR(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=Qne(this.flatCoordinates,0,t,this.stride),this.changed()},n}(b1);const AC=are;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)}}(),lre=function(e){sre(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?mf(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<C1(this.getExtent(),t,r))return o;for(var s=this.flatCoordinates,a=this.stride,h=0,g=s.length;h<g;h+=a){var C=X0(t,r,s[h],s[h+1]);if(C<o){o=C;for(var B=0;B<a;++B)i[B]=s[h+B];i.length=a}}return o},n.prototype.getCoordinates=function(){return vm(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 AC(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 h=new AC(t.slice(s,s+i),r);o.push(h)}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],h=r[o+1];if(JB(t,a,h))return!0}return!1},n.prototype.setCoordinates=function(t,r){this.setLayout(r,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=f5(this.flatCoordinates,0,t,this.stride),this.changed()},n}(b1);const m7=lre;function dz(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],h=e[n+1];i+=s*a-o*h,o=a,s=h}return i/2}function hz(e,n,t,r){for(var i=0,o=0,s=t.length;o<s;++o){var a=t[o];i+=dz(e,n,a,r),n=a}return i}function ure(e,n,t,r){for(var i=0,o=0,s=t.length;o<s;++o){var a=t[o];i+=hz(e,n,a,r),n=a[a.length-1]}return i}var Are=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)}}(),cre=function(e){Are(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<C1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(u7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),c7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!0,t,r,i,o))},n.prototype.getArea=function(){return dz(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)},n.prototype.getCoordinates=function(){return vm(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)},n.prototype.getSimplifiedGeometryInternal=function(t){var r=[];return r.length=f7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,r,0),new n(r,za.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=f5(this.flatCoordinates,0,t,this.stride),this.changed()},n}(b1);const F9=cre;function g7(e,n,t,r,i,o,s){for(var a,h,g,C,B,k,P,L=i[o+1],J=[],N=0,$=t.length;N<$;++N){var q=t[N];for(C=e[q-r],k=e[q-r+1],a=n;a<q;a+=r)B=e[a],P=e[a+1],(L<=k&&P<=L||k<=L&&L<=P)&&(g=(L-k)/(P-k)*(B-C)+C,J.push(g)),C=B,k=P}var oe=NaN,ce=-1/0;for(J.sort(A1),C=J[0],a=1,h=J.length;a<h;++a){B=J[a];var me=Math.abs(B-C);me>ce&&(g=(C+B)/2,p7(e,n,t,r,g,L)&&(oe=g,ce=me)),C=B}return isNaN(oe)&&(oe=i[o]),s?(s.push(oe,L,ce),s):[oe,L,ce]}function fz(e,n,t,r,i){for(var o=[],s=0,a=t.length;s<a;++s){var h=t[s];o=g7(e,n,h,r,i,2*s,o),n=h[h.length-1]}return o}function dre(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 y7(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],h=e[n+1];i+=(a-o)*(h+s),o=a,s=h}return i===0?void 0:i>0}function pz(e,n,t,r,i){for(var o=i!==void 0?i:!1,s=0,a=t.length;s<a;++s){var h=t[s],g=y7(e,n,h,r);if(s===0){if(o&&g||!o&&!g)return!1}else if(o&&!g||!o&&g)return!1;n=h}return!0}function hre(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){var a=t[o];if(!pz(e,n,a,r,i))return!1;a.length&&(n=a[a.length-1])}return!0}function aE(e,n,t,r,i){for(var o=i!==void 0?i:!1,s=0,a=t.length;s<a;++s){var h=t[s],g=y7(e,n,h,r),C=s===0?o&&g||!o&&!g:o&&!g||!o&&g;C&&dre(e,n,h,r),n=h}return n}function D9(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o)n=aE(e,n,t[o],r,i);return n}function fre(e,n){for(var t=[],r=0,i=0,o=0,s=n.length;o<s;++o){var a=n[o];if(!y7(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 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)}}(),mz=function(e){pre(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?mf(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<C1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(A7(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),d7(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!0,t,r,i,o))},n.prototype.containsXY=function(t,r){return p7(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,r)},n.prototype.getArea=function(){return hz(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride)},n.prototype.getCoordinates=function(t){var r;return t!==void 0?(r=this.getOrientedFlatCoordinates().slice(),aE(r,0,this.ends_,this.stride,t)):r=this.flatCoordinates,uC(r,0,this.ends_,this.stride)},n.prototype.getEnds=function(){return this.ends_},n.prototype.getFlatInteriorPoint=function(){if(this.flatInteriorPointRevision_!=this.getRevision()){var t=Nm(this.getExtent());this.flatInteriorPoint_=g7(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,0),this.flatInteriorPointRevision_=this.getRevision()}return this.flatInteriorPoint_},n.prototype.getInteriorPoint=function(){return new AC(this.getFlatInteriorPoint(),za.XYM)},n.prototype.getLinearRingCount=function(){return this.ends_.length},n.prototype.getLinearRing=function(t){return t<0||this.ends_.length<=t?null:new F9(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,h=i.length;a<h;++a){var g=i[a],C=new F9(r.slice(s,g),t);o.push(C),s=g}return o},n.prototype.getOrientedFlatCoordinates=function(){if(this.orientedRevision_!=this.getRevision()){var t=this.flatCoordinates;pz(t,0,this.ends_,this.stride)?this.orientedFlatCoordinates_=t:(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=aE(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=az(this.flatCoordinates,0,this.ends_,this.stride,Math.sqrt(t),r,0,i),new n(r,za.XY,i)},n.prototype.getType=function(){return"Polygon"},n.prototype.intersectsExtent=function(t){return uz(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=h7(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=i.length===0?0:i[i.length-1],this.changed()},n}(b1);const cC=mz;function L9(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 mz(o,za.XY,[o.length])}function gz(e,n,t,r){for(var i=[],o=xd(),s=0,a=t.length;s<a;++s){var h=t[s];o=e7(e,n,h[0],r),i.push((o[0]+o[2])/2,(o[1]+o[3])/2),n=h[h.length-1]}return i}var mre=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)}}(),gre=function(e){mre(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,h=[],g=[],C=0,B=a.length;C<B;++C){var k=a[C];C===0&&(s=k.getLayout());for(var P=h.length,L=k.getEnds(),J=0,N=L.length;J<N;++J)L[J]+=P;mf(h,k.getFlatCoordinates()),g.push(L)}r=s,t=h,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;mf(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<C1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(Nne(this.flatCoordinates,0,this.endss_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),Gne(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,this.maxDelta_,!0,t,r,i,o))},n.prototype.containsXY=function(t,r){return Xne(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t,r)},n.prototype.getArea=function(){return ure(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride)},n.prototype.getCoordinates=function(t){var r;return t!==void 0?(r=this.getOrientedFlatCoordinates().slice(),D9(r,0,this.endss_,this.stride,t)):r=this.flatCoordinates,iE(r,0,this.endss_,this.stride)},n.prototype.getEndss=function(){return this.endss_},n.prototype.getFlatInteriorPoints=function(){if(this.flatInteriorPointsRevision_!=this.getRevision()){var t=gz(this.flatCoordinates,0,this.endss_,this.stride);this.flatInteriorPoints_=fz(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t),this.flatInteriorPointsRevision_=this.getRevision()}return this.flatInteriorPoints_},n.prototype.getInteriorPoints=function(){return new m7(this.getFlatInteriorPoints().slice(),za.XYM)},n.prototype.getOrientedFlatCoordinates=function(){if(this.orientedRevision_!=this.getRevision()){var t=this.flatCoordinates;hre(t,0,this.endss_,this.stride)?this.orientedFlatCoordinates_=t:(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=D9(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=Hne(this.flatCoordinates,0,this.endss_,this.stride,Math.sqrt(t),r,0,i),new n(r,za.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,h=o.length;a<h;++a)o[a]-=r;return new cC(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,h=i.length;a<h;++a){var g=i[a].slice(),C=g[g.length-1];if(s!==0)for(var B=0,k=g.length;B<k;++B)g[B]-=s;var P=new cC(r.slice(s,C),t,g);o.push(P),s=C}return o},n.prototype.getType=function(){return"MultiPolygon"},n.prototype.intersectsExtent=function(t){return ere(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=$ne(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}(b1);const yz=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)}}(),vre=function(e){yre(n,e);function n(t){var r=this,i=t||{};return r=e.call(this)||this,r.dataProjection=qs(i.dataProjection?i.dataProjection:"EPSG:4326"),i.featureProjection&&(r.defaultFeatureProjection=qs(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=sE(i.geometry,r),s=new Rte;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,h=0,g=a.length;h<g;++h)o.push(this.readFeatureFromObject(a[h],r))}else o=[this.readFeatureFromObject(t,r)];return o},n.prototype.readGeometryFromObject=function(t,r){return sE(t,r)},n.prototype.readProjectionFromObject=function(t){var r=t.crs,i;return r?r.type=="name"?i=qs(r.properties.name):r.type==="EPSG"?i=qs("EPSG:"+r.properties.code):ho(!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=lE(a,r),delete s[t.getGeometryName()]),d1(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 lE(t,this.adaptOptions(r))},n}(Une);function sE(e,n){if(!e)return null;var t;switch(e.type){case"Point":{t=Cre(e);break}case"LineString":{t=bre(e);break}case"Polygon":{t=Sre(e);break}case"MultiPoint":{t=wre(e);break}case"MultiLineString":{t=xre(e);break}case"MultiPolygon":{t=Mre(e);break}case"GeometryCollection":{t=_re(e);break}default:throw new Error("Unsupported GeoJSON type: "+e.type)}return l7(t,!1,n)}function _re(e,n){var t=e.geometries.map(function(r){return sE(r,n)});return new Fne(t)}function Cre(e){return new AC(e.coordinates)}function bre(e){return new S3(e.coordinates)}function xre(e){return new cz(e.coordinates)}function wre(e){return new m7(e.coordinates)}function Mre(e){return new yz(e.coordinates)}function Sre(e){return new cC(e.coordinates)}function lE(e,n){e=l7(e,!0,n);var t=e.getType(),r;switch(t){case"Point":{r=Tre(e);break}case"LineString":{r=Ore(e);break}case"Polygon":{r=Kre(e,n);break}case"MultiPoint":{r=kre(e);break}case"MultiLineString":{r=Bre(e);break}case"MultiPolygon":{r=Ire(e,n);break}case"GeometryCollection":{r=Ere(e,n);break}case"Circle":{r={type:"GeometryCollection",geometries:[]};break}default:throw new Error("Unsupported geometry type: "+t)}return r}function Ere(e,n){var t=e.getGeometriesArray().map(function(r){var i=gl({},n);return delete i.featureProjection,lE(r,i)});return{type:"GeometryCollection",geometries:t}}function Ore(e,n){return{type:"LineString",coordinates:e.getCoordinates()}}function Bre(e,n){return{type:"MultiLineString",coordinates:e.getCoordinates()}}function kre(e,n){return{type:"MultiPoint",coordinates:e.getCoordinates()}}function Ire(e,n){var t;return n&&(t=n.rightHanded),{type:"MultiPolygon",coordinates:e.getCoordinates(t)}}function Tre(e,n){return{type:"Point",coordinates:e.getCoordinates()}}function Kre(e,n){var t;return n&&(t=n.rightHanded),{type:"Polygon",coordinates:e.getCoordinates(t)}}var Pre=na,Mx=$4;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 uE=65536*65536,U9=1/uE,Fre=12,vz=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=Sx(this.buf,this.pos);return this.pos+=4,e},readSFixed32:function(){var e=z9(this.buf,this.pos);return this.pos+=4,e},readFixed64:function(){var e=Sx(this.buf,this.pos)+Sx(this.buf,this.pos+4)*uE;return this.pos+=8,e},readSFixed64:function(){var e=Sx(this.buf,this.pos)+z9(this.buf,this.pos+4)*uE;return this.pos+=8,e},readFloat:function(){var e=Mx.read(this.buf,this.pos,!0,23,4);return this.pos+=4,e},readDouble:function(){var e=Mx.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,Dre(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>=Fre&&vz?Vre(this.buf,n,e):Hre(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=Xf(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=Xf(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=Xf(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=Xf(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=Xf(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=Xf(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=Xf(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=Xf(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=Xf(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),ug(this.buf,e,this.pos),this.pos+=4},writeSFixed32:function(e){this.realloc(4),ug(this.buf,e,this.pos),this.pos+=4},writeFixed64:function(e){this.realloc(8),ug(this.buf,e&-1,this.pos),ug(this.buf,Math.floor(e*U9),this.pos+4),this.pos+=8},writeSFixed64:function(e){this.realloc(8),ug(this.buf,e&-1,this.pos),ug(this.buf,Math.floor(e*U9),this.pos+4),this.pos+=8},writeVarint:function(e){if(e=+e||0,e>268435455||e<0){Lre(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=Zre(this.buf,e,this.pos);var t=this.pos-n;t>=128&&R9(n,t,this),this.pos=n-1,this.writeVarint(t),this.pos+=t},writeFloat:function(e){this.realloc(4),Mx.write(this.buf,e,this.pos,!0,23,4),this.pos+=4},writeDouble:function(e){this.realloc(8),Mx.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&&R9(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,zre,n)},writePackedSVarint:function(e,n){n.length&&this.writeMessage(e,jre,n)},writePackedBoolean:function(e,n){n.length&&this.writeMessage(e,Gre,n)},writePackedFloat:function(e,n){n.length&&this.writeMessage(e,Wre,n)},writePackedDouble:function(e,n){n.length&&this.writeMessage(e,Nre,n)},writePackedFixed32:function(e,n){n.length&&this.writeMessage(e,Qre,n)},writePackedSFixed32:function(e,n){n.length&&this.writeMessage(e,$re,n)},writePackedFixed64:function(e,n){n.length&&this.writeMessage(e,Yre,n)},writePackedSFixed64:function(e,n){n.length&&this.writeMessage(e,qre,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 Dre(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 lg(e,i,n);throw new Error("Expected varint not more than 10 bytes")}function Xf(e){return e.type===na.Bytes?e.readVarint()+e.pos:e.pos+1}function lg(e,n,t){return t?n*4294967296+(e>>>0):(n>>>0)*4294967296+(e>>>0)}function Lre(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),Ure(t,r,n),Rre(r,n)}function Ure(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 Rre(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 R9(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 zre(e,n){for(var t=0;t<e.length;t++)n.writeVarint(e[t])}function jre(e,n){for(var t=0;t<e.length;t++)n.writeSVarint(e[t])}function Wre(e,n){for(var t=0;t<e.length;t++)n.writeFloat(e[t])}function Nre(e,n){for(var t=0;t<e.length;t++)n.writeDouble(e[t])}function Gre(e,n){for(var t=0;t<e.length;t++)n.writeBoolean(e[t])}function Qre(e,n){for(var t=0;t<e.length;t++)n.writeFixed32(e[t])}function $re(e,n){for(var t=0;t<e.length;t++)n.writeSFixed32(e[t])}function Yre(e,n){for(var t=0;t<e.length;t++)n.writeFixed64(e[t])}function qre(e,n){for(var t=0;t<e.length;t++)n.writeSFixed64(e[t])}function Sx(e,n){return(e[n]|e[n+1]<<8|e[n+2]<<16)+e[n+3]*16777216}function ug(e,n,t){e[t]=n,e[t+1]=n>>>8,e[t+2]=n>>>16,e[t+3]=n>>>24}function z9(e,n){return(e[n]|e[n+1]<<8|e[n+2]<<16)+(e[n+3]<<24)}function Hre(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 h,g,C;a===1?o<128&&(s=o):a===2?(h=e[i+1],(h&192)===128&&(s=(o&31)<<6|h&63,s<=127&&(s=null))):a===3?(h=e[i+1],g=e[i+2],(h&192)===128&&(g&192)===128&&(s=(o&15)<<12|(h&63)<<6|g&63,(s<=2047||s>=55296&&s<=57343)&&(s=null))):a===4&&(h=e[i+1],g=e[i+2],C=e[i+3],(h&192)===128&&(g&192)===128&&(C&192)===128&&(s=(o&15)<<18|(h&63)<<12|(g&63)<<6|C&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 Vre(e,n,t){return vz.decode(e.subarray(n,t))}function Zre(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 Xre=fa(Pre);var j9=_d(),dC=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"?qR(this.flatCoordinates_):e7(this.flatCoordinates_,0,this.flatCoordinates_.length,2)),this.extent_},e.prototype.getFlatInteriorPoint=function(){if(!this.flatInteriorPoints_){var n=Nm(this.getExtent());this.flatInteriorPoints_=g7(this.flatCoordinates_,0,this.ends_,2,n,0)}return this.flatInteriorPoints_},e.prototype.getFlatInteriorPoints=function(){if(!this.flatInteriorPoints_){var n=gz(this.flatCoordinates_,0,this.ends_,2);this.flatInteriorPoints_=fz(this.flatCoordinates_,0,this.ends_,2,n)}return this.flatInteriorPoints_},e.prototype.getFlatMidpoint=function(){return this.flatMidpoints_||(this.flatMidpoints_=M3(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=M3(n,t,s,2,.5);mf(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=qs(n);var t=n.getExtent(),r=n.getWorldExtent();if(t&&r){var i=rc(r)/rc(t);_f(j9,r[0],r[3],i,-i,0,0,0),Fm(this.flatCoordinates_,0,this.flatCoordinates_.length,2,j9,this.flatCoordinates_)}},e.prototype.getEnds=function(){return this.ends_},e}();dC.prototype.getEndss=dC.prototype.getEnds;dC.prototype.getFlatCoordinates=dC.prototype.getOrientedFlatCoordinates;const AE=dC;var Jre=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)}}(),eie=function(e){Jre(n,e);function n(t){var r=e.call(this)||this,i=t||{};return r.dataProjection=new n7({code:"",units:OA.TILE_PIXELS}),r.featureClass_=i.featureClass?i.featureClass:AE,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,h=0,g=0,C=0,B=0,k=0;t.pos<s;){if(!h){var P=t.readVarint();a=P&7,h=P>>3}h--,a===1||a===2?(g+=t.readSVarint(),C+=t.readSVarint(),a===1&&B>k&&(o.push(B),k=B),i.push(g,C),B+=2):a===7?B>k&&(i.push(i[k],i[k+1]),B+=2):ho(!1,59)}B>k&&(o.push(B),k=B)},n.prototype.createFeature_=function(t,r,i){var o=r.type;if(o===0)return null;var s,a=r.properties,h;this.idProperty_?(h=a[this.idProperty_],delete a[this.idProperty_]):h=r.id,a[this.layerName_]=r.layer.name;var g=[],C=[];this.readRawGeometry_(t,r,g,C);var B=oie(o,C.length);if(this.featureClass_===AE)s=new this.featureClass_(B,g,C,a,h),s.transform(i.dataProjection);else{var k=void 0;if(B=="Polygon"){var P=fre(g,C);k=P.length>1?new yz(g,za.XY,P):new cC(g,za.XY,C)}else k=B==="Point"?new AC(g,za.XY):B==="LineString"?new S3(g,za.XY):B==="MultiPoint"?new m7(g,za.XY):B==="MultiLineString"?new cz(g,za.XY,C):null;var L=this.featureClass_;s=new L,this.geometryName_&&s.setGeometryName(this.geometryName_);var J=l7(k,!1,i);s.setGeometry(J),h!==void 0&&s.setId(h),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=qs(o.dataProjection);s.setWorldExtent(o.extent),o.dataProjection=s;var a=new Xre(t),h=a.readFields(tie,{}),g=[];for(var C in h)if(!(i&&i.indexOf(C)==-1)){var B=h[C],k=B?[0,0,B.extent,B.extent]:null;s.setExtent(k);for(var P=0,L=B.length;P<L;++P){var J=iie(a,B,P),N=this.createFeature_(a,J,o);N!==null&&g.push(N)}}return g},n.prototype.readProjection=function(t){return this.dataProjection},n.prototype.setLayers=function(t){this.layers_=t},n}(oz);function tie(e,n,t){if(e===3){var r={keys:[],values:[],features:[]},i=t.readVarint()+t.pos;t.readFields(nie,r,i),r.length=r.features.length,r.length&&(n[r.name]=r)}}function nie(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 rie(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 iie(e,n,t){e.pos=n.features[t];var r=e.readVarint()+e.pos,i={layer:n,type:0,properties:{}};return e.readFields(rie,i,r),i}function oie(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 aie=eie;var sie=/^#([a-f0-9]{3}|[a-f0-9]{4}(?:[a-f0-9]{2}){0,2})$/i,lie=/^([a-z]*)$|^hsla?\(.*\)$/i;function _z(e){return typeof e=="string"?e:Cz(e)}function uie(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 Aie=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=cie(r),n[r]=i,++t}return i}}();function E3(e){return Array.isArray(e)?e:Aie(e)}function cie(e){var n,t,r,i,o;if(lie.exec(e)&&(e=uie(e)),sie.exec(e)){var s=e.length-1,a=void 0;s<=4?a=1:a=2;var h=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),h?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,h&&(i=(i<<4)+i)),o=[n,t,r,i/255]}else e.indexOf("rgba(")==0?(o=e.slice(5,-1).split(",").map(Number),W9(o)):e.indexOf("rgb(")==0?(o=e.slice(4,-1).split(",").map(Number),o.push(1),W9(o)):ho(!1,14);return o}function W9(e){return e[0]=Fl(e[0]+.5|0,0,255),e[1]=Fl(e[1]+.5|0,0,255),e[2]=Fl(e[2]+.5|0,0,255),e[3]=Fl(e[3],0,1),e}function Cz(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 die=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=N9(n,t,r);return i in this.cache_?this.cache_[i]:null},e.prototype.set=function(n,t,r,i){var o=N9(n,t,r);this.cache_[o]=i,++this.cacheSize_},e.prototype.setSize=function(n){this.maxCacheSize_=n,this.expire()},e}();function N9(e,n,t){var r=t?_z(t):"null";return n+":"+e+":"+r}var O3=new die;const Ma={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 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=e.call(this)||this;r.on,r.once,r.un,r.background_=t.background;var i=gl({},t);return typeof t.properties=="object"&&(delete i.properties,gl(i,t.properties)),i[Ma.OPACITY]=t.opacity!==void 0?t.opacity:1,ho(typeof i[Ma.OPACITY]=="number",64),i[Ma.VISIBLE]=t.visible!==void 0?t.visible:!0,i[Ma.Z_INDEX]=t.zIndex,i[Ma.MAX_RESOLUTION]=t.maxResolution!==void 0?t.maxResolution:1/0,i[Ma.MIN_RESOLUTION]=t.minResolution!==void 0?t.minResolution:0,i[Ma.MIN_ZOOM]=t.minZoom!==void 0?t.minZoom:-1/0,i[Ma.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=Fl(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 pi()},n.prototype.getLayerStatesArray=function(t){return pi()},n.prototype.getExtent=function(){return this.get(Ma.EXTENT)},n.prototype.getMaxResolution=function(){return this.get(Ma.MAX_RESOLUTION)},n.prototype.getMinResolution=function(){return this.get(Ma.MIN_RESOLUTION)},n.prototype.getMinZoom=function(){return this.get(Ma.MIN_ZOOM)},n.prototype.getMaxZoom=function(){return this.get(Ma.MAX_ZOOM)},n.prototype.getOpacity=function(){return this.get(Ma.OPACITY)},n.prototype.getSourceState=function(){return pi()},n.prototype.getVisible=function(){return this.get(Ma.VISIBLE)},n.prototype.getZIndex=function(){return this.get(Ma.Z_INDEX)},n.prototype.setBackground=function(t){this.background_=t,this.changed()},n.prototype.setExtent=function(t){this.set(Ma.EXTENT,t)},n.prototype.setMaxResolution=function(t){this.set(Ma.MAX_RESOLUTION,t)},n.prototype.setMinResolution=function(t){this.set(Ma.MIN_RESOLUTION,t)},n.prototype.setMaxZoom=function(t){this.set(Ma.MAX_ZOOM,t)},n.prototype.setMinZoom=function(t){this.set(Ma.MIN_ZOOM,t)},n.prototype.setOpacity=function(t){ho(typeof t=="number",64),this.set(Ma.OPACITY,t)},n.prototype.setVisible=function(t){this.set(Ma.VISIBLE,t)},n.prototype.setZIndex=function(t){this.set(Ma.Z_INDEX,t)},n.prototype.disposeInternal=function(){this.state_&&(this.state_.layer=null,this.state_=null),e.prototype.disposeInternal.call(this)},n}(fh);const bz=fie,Dm={PRERENDER:"prerender",POSTRENDER:"postrender",PRECOMPOSE:"precompose",POSTCOMPOSE:"postcompose",RENDERCOMPLETE:"rendercomplete"};var pie=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)}}(),m5=function(e){pie(n,e);function n(t){var r=this,i=gl({},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(Ma.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(Ma.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_&&(is(this.sourceChangeKey_),this.sourceChangeKey_=null);var t=this.getSource();t&&(this.sourceChangeKey_=ko(t,Di.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(Ma.MAP,t)},n.prototype.getMapInternal=function(){return this.get(Ma.MAP)},n.prototype.setMap=function(t){this.mapPrecomposeKey_&&(is(this.mapPrecomposeKey_),this.mapPrecomposeKey_=null),t||this.changed(),this.mapRenderKey_&&(is(this.mapRenderKey_),this.mapRenderKey_=null),t&&(this.mapPrecomposeKey_=ko(t,Dm.PRECOMPOSE,function(r){var i=r,o=i.frameState.layerStatesArray,s=this.getLayerState(!1);ho(!o.some(function(a){return a.layer===s.layer}),67),o.push(s)},this),this.mapRenderKey_=ko(this,Di.CHANGE,t.render,t),this.changed())},n.prototype.setSource=function(t){this.set(Ma.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}(bz);function B3(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 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)}}(),gie=function(e){mie(n,e);function n(t){var r=e.call(this)||this;return r.map_=t,r}return n.prototype.dispatchRenderEvent=function(t,r){pi()},n.prototype.calculateMatrices2D=function(t){var r=t.viewState,i=t.coordinateToPixelTransform,o=t.pixelToCoordinateTransform;_f(i,t.size[0]/2,t.size[1]/2,1/r.resolution,-1/r.resolution,-r.rotation,-r.center[0],-r.center[1]),XB(o,i)},n.prototype.forEachFeatureAtCoordinate=function(t,r,i,o,s,a,h,g){var C,B=r.viewState;function k(be,Bt,kt,Yt){return s.call(a,Bt,be?kt:null,Yt)}var P=B.projection,L=i7(t.slice(),P),J=[[0,0]];if(P.canWrapX()&&o){var N=P.getExtent(),$=ys(N);J.push([-$,0],[$,0])}for(var q=r.layerStatesArray,oe=q.length,ce=[],me=[],he=0;he<J.length;he++)for(var V=oe-1;V>=0;--V){var ae=q[V],ye=ae.layer;if(ye.hasRenderer()&&B3(ae,B)&&h.call(g,ye)){var Oe=ye.getRenderer(),De=ye.getSource();if(Oe&&De){var He=De.getWrapX()?L:t,ke=k.bind(null,ae.managed);me[0]=He[0]+J[he][0],me[1]=He[1]+J[he][1],C=Oe.forEachFeatureAtCoordinate(me,r,i,ke,ce)}if(C)return C}}if(ce.length!==0){var nt=1/ce.length;return ce.forEach(function(be,Bt){return be.distanceSq+=Bt*nt}),ce.sort(function(be,Bt){return be.distanceSq-Bt.distanceSq}),ce.some(function(be){return C=be.callback(be.feature,be.layer,be.geometry)}),C}},n.prototype.forEachLayerAtPixel=function(t,r,i,o,s){return pi()},n.prototype.hasFeatureAtCoordinate=function(t,r,i,o,s,a){var h=this.forEachFeatureAtCoordinate(t,r,i,o,oy,this,s,a);return h!==void 0},n.prototype.getMap=function(){return this.map_},n.prototype.renderFrame=function(t){pi()},n.prototype.scheduleExpireIconCache=function(t){O3.canExpireCache()&&t.postRenderFunctions.push(yie)},n}(HB);function yie(e,n){O3.expire()}const vie=gie;var _ie=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)}}(),xz=function(e){_ie(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}(Op),Ex="ol-hidden",Cie="ol-selectable",g5="ol-unselectable",v7="ol-control",G9="ol-collapsed",bie=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"),Q9=["style","variant","weight","size","lineHeight","family"],wz=function(e){var n=e.match(bie);if(!n)return null;for(var t={lineHeight:"normal",size:"1.2em",style:"normal",weight:"normal",variant:"normal"},r=0,i=Q9.length;r<i;++r){var o=n[r+1];o!==void 0&&(t[Q9[r]]=o)}return t.families=t.family.split(/,\s?/),t};function ic(e,n,t,r){var i;return t&&t.length?i=t.shift():l5?i=new OffscreenCanvas(e||300,n||300):i=document.createElement("canvas"),e&&(i.width=e),n&&(i.height=n),i.getContext("2d",r)}function _7(e){var n=e.canvas;n.width=1,n.height=1,e.clearRect(0,0,1,1)}function xie(e){var n=e.offsetWidth,t=getComputedStyle(e);return n+=parseInt(t.marginLeft,10)+parseInt(t.marginRight,10),n}function wie(e){var n=e.offsetHeight,t=getComputedStyle(e);return n+=parseInt(t.marginTop,10)+parseInt(t.marginBottom,10),n}function $9(e,n){var t=n.parentNode;t&&t.replaceChild(e,n)}function k3(e){return e&&e.parentNode?e.parentNode.removeChild(e):null}function Mz(e){for(;e.lastChild;)e.removeChild(e.lastChild)}function Mie(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 Sz="10px sans-serif",xp="#000",I3="round",hC=[],fC=0,By="round",pC=10,mC="#000",gC="center",T3="middle",W0=[0,0,0,0],yC=1,ap=new fh,cE=new Gy;cE.setSize=function(){console.warn("labelCache is deprecated.")};var wg=null,dE,hE={},Sie=function(){var e=100,n="32px ",t=["monospace","serif"],r=t.length,i="wmytzilWMYTZIL@#/&?$%10",o,s;function a(g,C,B){for(var k=!0,P=0;P<r;++P){var L=t[P];if(s=K3(g+" "+C+" "+n+L,i),B!=L){var J=K3(g+" "+C+" "+n+B+","+L,i);k=k&&J!=s}}return!!k}function h(){for(var g=!0,C=ap.getKeys(),B=0,k=C.length;B<k;++B){var P=C[B];ap.get(P)<e&&(a.apply(this,P.split(`
`))?(QC(hE),wg=null,dE=void 0,ap.set(P,e)):(ap.set(P,ap.get(P)+1,!0),g=!1))}g&&(clearInterval(o),o=void 0)}return function(g){var C=wz(g);if(C)for(var B=C.families,k=0,P=B.length;k<P;++k){var L=B[k],J=C.style+`
`+C.weight+`
`+L;ap.get(J)===void 0&&(ap.set(J,e,!0),a(C.style,C.weight,L)||(ap.set(J,0,!0),o===void 0&&(o=setInterval(h,32))))}}}(),Eie=function(){var e;return function(n){var t=hE[n];if(t==null){if(l5){var r=wz(n),i=Ez(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);hE[n]=t}return t}}();function Ez(e,n){return wg||(wg=ic(1,1)),e!=dE&&(wg.font=e,dE=wg.font),wg.measureText(n)}function K3(e,n){return Ez(e,n).width}function Y9(e,n,t){if(n in t)return t[n];var r=n.split(`
`).reduce(function(i,o){return Math.max(i,K3(e,o))},0);return t[n]=r,r}function Oie(e,n){for(var t=[],r=[],i=[],o=0,s=0,a=0,h=0,g=0,C=n.length;g<=C;g+=2){var B=n[g];if(B===`
`||g===C){o=Math.max(o,s),i.push(s),s=0,a+=h;continue}var k=n[g+1]||e.font,P=K3(k,B);t.push(P),s+=P;var L=Eie(k);r.push(L),h=Math.max(h,L)}return{width:o,height:a,widths:t,heights:r,lineWidths:i}}function Bie(e,n,t,r,i,o,s,a,h,g,C){e.save(),t!==1&&(e.globalAlpha*=t),n&&e.setTransform.apply(e,n),r.contextInstructions?(e.translate(h,g),e.scale(C[0],C[1]),kie(r,e)):C[0]<0||C[1]<0?(e.translate(h,g),e.scale(C[0],C[1]),e.drawImage(r,i,o,s,a,0,0,s,a)):e.drawImage(r,i,o,s,a,h,g,s*C[0],a*C[1]),e.restore()}function kie(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 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)}}(),Tie=function(e){Iie(n,e);function n(t){var r=e.call(this,t)||this;r.fontChangeListenerKey_=ko(ap,Ey.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=g5+" 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 xz(t,void 0,r);i.dispatchEvent(o)}},n.prototype.disposeInternal=function(){is(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(Dm.PRECOMPOSE,t);var r=t.layerStatesArray.sort(function(P,L){return P.zIndex-L.zIndex}),i=t.viewState;this.children_.length=0;for(var o=[],s=null,a=0,h=r.length;a<h;++a){var g=r[a];t.layerIndex=a;var C=g.layer,B=C.getSourceState();if(!B3(g,i)||B!="ready"&&B!="undefined"){C.unrender();continue}var k=C.render(t,s);k&&(k!==s&&(this.children_.push(k),s=k),"getDeclutter"in C&&o.push(C))}for(var a=o.length-1;a>=0;--a)o[a].renderDeclutter(t);Mie(this.element_,this.children_),this.dispatchRenderEvent(Dm.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,h=r.layerStatesArray,g=h.length,C=g-1;C>=0;--C){var B=h[C],k=B.layer;if(k.hasRenderer()&&B3(B,a)&&s(k)){var P=k.getRenderer(),L=P.getDataAtPixel(t,r,i);if(L){var J=o(k,L);if(J)return J}}}},n}(vie);const Kie=Tie,JA={ADD:"add",REMOVE:"remove"};var Oz=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)}}(),q9={LENGTH:"length"},Ox=function(e){Oz(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.element=r,o.index=i,o}return n}(Op),yd=function(e){Oz(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(q9.LENGTH)},n.prototype.insertAt=function(t,r){this.unique_&&this.assertUnique_(r),this.array_.splice(t,0,r),this.updateLength_(),this.dispatchEvent(new Ox(JA.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 Ox(JA.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 Ox(JA.REMOVE,o,t)),this.dispatchEvent(new Ox(JA.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(q9.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 WR(58)},n}(fh),Bz=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=function(e){Bz(n,e);function n(t,r){var i=e.call(this,t)||this;return i.layer=r,i}return n}(Op),gM={LAYERS:"layers"},Pie=function(e){Bz(n,e);function n(t){var r=this,i=t||{},o=gl({},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(gM.LAYERS,r.handleLayersChanged_),s?Array.isArray(s)?s=new yd(s.slice(),{unique:!0}):ho(typeof s.getArray=="function",43):s=new yd(void 0,{unique:!0}),r.setLayers(s),r}return n.prototype.handleLayerChange_=function(){this.changed()},n.prototype.handleLayersChanged_=function(){this.layersListenerKeys_.forEach(is),this.layersListenerKeys_.length=0;var t=this.getLayers();this.layersListenerKeys_.push(ko(t,JA.ADD,this.handleLayersAdd_,this),ko(t,JA.REMOVE,this.handleLayersRemove_,this));for(var r in this.listenerKeys_)this.listenerKeys_[r].forEach(is);QC(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 am("addlayer",a))}this.changed()},n.prototype.registerLayerListeners_=function(t){var r=[ko(t,Ey.PROPERTYCHANGE,this.handleLayerChange_,this),ko(t,Di.CHANGE,this.handleLayerChange_,this)];t instanceof n&&r.push(ko(t,"addlayer",this.handleLayerGroupAdd_,this),ko(t,"removelayer",this.handleLayerGroupRemove_,this)),this.listenerKeys_[$i(t)]=r},n.prototype.handleLayerGroupAdd_=function(t){this.dispatchEvent(new am("addlayer",t.layer))},n.prototype.handleLayerGroupRemove_=function(t){this.dispatchEvent(new am("removelayer",t.layer))},n.prototype.handleLayersAdd_=function(t){var r=t.element;this.registerLayerListeners_(r),this.dispatchEvent(new am("addlayer",r)),this.changed()},n.prototype.handleLayersRemove_=function(t){var r=t.element,i=$i(r);this.listenerKeys_[i].forEach(is),delete this.listenerKeys_[i],this.dispatchEvent(new am("removelayer",r)),this.changed()},n.prototype.getLayers=function(){return this.get(gM.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 am("removelayer",i[o]));this.set(gM.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(C){C.getLayerStatesArray(r)});var o=this.getLayerState(),s=o.zIndex;!t&&o.zIndex===void 0&&(s=0);for(var a=i,h=r.length;a<h;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=Z0(g.extent,o.extent):g.extent=o.extent),g.zIndex===void 0&&(g.zIndex=s)}return r},n.prototype.getSourceState=function(){return"ready"},n}(bz);const y5=Pie;var 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)}}(),Mg=function(e){Fie(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}(Op),Die=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)}}(),rm=function(e){Die(n,e);function n(t,r,i,o,s,a){var h=e.call(this,t,r,s)||this;return h.originalEvent=i,h.pixel_=null,h.coordinate_=null,h.dragging=o!==void 0?o:!1,h.activePointers=a,h}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}(Mg);const rl={SINGLECLICK:"singleclick",CLICK:Di.CLICK,DBLCLICK:Di.DBLCLICK,POINTERDRAG:"pointerdrag",POINTERMOVE:"pointermove",POINTERDOWN:"pointerdown",POINTERUP:"pointerup",POINTEROVER:"pointerover",POINTEROUT:"pointerout",POINTERENTER:"pointerenter",POINTERLEAVE:"pointerleave",POINTERCANCEL:"pointercancel"},fE={POINTERMOVE:"pointermove",POINTERDOWN:"pointerdown",POINTERUP:"pointerup",POINTEROVER:"pointerover",POINTEROUT:"pointerout",POINTERENTER:"pointerenter",POINTERLEAVE:"pointerleave",POINTERCANCEL:"pointercancel"};var 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)}}(),Uie=function(e){Lie(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_=ko(o,fE.POINTERDOWN,i.handlePointerDown_,i),i.originalPointerMoveEvent_,i.relayedListenerKey_=ko(o,fE.POINTERMOVE,i.relayMoveEvent_,i),i.boundHandleTouchMove_=i.handleTouchMove_.bind(i),i.element_.addEventListener(Di.TOUCHMOVE,i.boundHandleTouchMove_,GR?{passive:!1}:!1),i}return n.prototype.emulateClick_=function(t){var r=new rm(rl.CLICK,this.map_,t);this.dispatchEvent(r),this.clickTimeoutId_!==void 0?(clearTimeout(this.clickTimeoutId_),this.clickTimeoutId_=void 0,r=new rm(rl.DBLCLICK,this.map_,t),this.dispatchEvent(r)):this.clickTimeoutId_=setTimeout((function(){this.clickTimeoutId_=void 0;var i=new rm(rl.SINGLECLICK,this.map_,t);this.dispatchEvent(i)}).bind(this),250)},n.prototype.updateActivePointers_=function(t){var r=t,i=r.pointerId;if(r.type==rl.POINTERUP||r.type==rl.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==rl.POINTERDOWN||r.type==rl.POINTERMOVE)&&(this.trackedTouches_[i]=r);this.activePointers_=RR(this.trackedTouches_)},n.prototype.handlePointerUp_=function(t){this.updateActivePointers_(t);var r=new rm(rl.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(is),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 rm(rl.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"?c1:o}if(this.dragListenerKeys_.length===0){var s=this.map_.getOwnerDocument();this.dragListenerKeys_.push(ko(s,rl.POINTERMOVE,this.handlePointerMove_,this),ko(s,rl.POINTERUP,this.handlePointerUp_,this),ko(this.element_,rl.POINTERCANCEL,this.handlePointerUp_,this)),this.element_.getRootNode&&this.element_.getRootNode()!==s&&this.dragListenerKeys_.push(ko(this.element_.getRootNode(),rl.POINTERUP,this.handlePointerUp_,this))}},n.prototype.handlePointerMove_=function(t){if(this.isMoving_(t)){this.updateActivePointers_(t),this.dragging_=!0;var r=new rm(rl.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 rm(rl.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_&&(is(this.relayedListenerKey_),this.relayedListenerKey_=null),this.element_.removeEventListener(Di.TOUCHMOVE,this.boundHandleTouchMove_),this.pointerdownListenerKey_&&(is(this.pointerdownListenerKey_),this.pointerdownListenerKey_=null),this.dragListenerKeys_.forEach(is),this.dragListenerKeys_.length=0,this.element_=null,e.prototype.disposeInternal.call(this)},n}(Gy);const Rie=Uie,sp={POSTRENDER:"postrender",MOVESTART:"movestart",MOVEEND:"moveend",LOADSTART:"loadstart",LOADEND:"loadend"},tA={LAYERGROUP:"layergroup",SIZE:"size",TARGET:"target",VIEW:"view"};var P3=1/0,zie=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,QC(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){ho(!(this.keyFunction_(n)in this.queuedElements_),31);var t=this.priorityFunction_(n);return t!=P3?(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 h=this.getLeftChildIndex_(n),g=this.getRightChildIndex_(n),C=g<i&&r[g]<r[h]?g:h;t[n]=t[C],r[n]=r[C],n=C}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,h;for(a=0;a<o;++a)s=t[a],h=n(s),h==P3?delete this.queuedElements_[this.keyFunction_(s)]:(r[i]=h,t[i++]=s);t.length=i,r.length=i,this.heapify_()},e}();const jie=zie,mr={IDLE:0,LOADING:1,LOADED:2,ERROR:3,EMPTY:4};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,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(Di.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(Di.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}(jie);const Gie=Nie;function Qie(e,n,t,r,i){if(!e||!(t in e.wantedTiles)||!e.wantedTiles[t][n.getKey()])return P3;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 il={ANIMATING:0,INTERACTING:1},nh={CENTER:"center",RESOLUTION:"resolution",ROTATION:"rotation"};var kz=42,C7=256;function H9(e,n,t){return function(r,i,o,s,a){if(r){if(!i&&!n)return r;var h=n?0:o[0]*i,g=n?0:o[1]*i,C=a?a[0]:0,B=a?a[1]:0,k=e[0]+h/2+C,P=e[2]-h/2+C,L=e[1]+g/2+B,J=e[3]-g/2+B;k>P&&(k=(P+k)/2,P=k),L>J&&(L=(J+L)/2,J=L);var N=Fl(r[0],k,P),$=Fl(r[1],L,J);if(s&&t&&i){var q=30*i;N+=-q*Math.log(1+Math.max(0,k-r[0])/q)+q*Math.log(1+Math.max(0,r[0]-P)/q),$+=-q*Math.log(1+Math.max(0,L-r[1])/q)+q*Math.log(1+Math.max(0,r[1]-J)/q)}return[N,$]}}}function $ie(e){return e}function b7(e,n,t,r){var i=ys(n)/t[0],o=rc(n)/t[1];return r?Math.min(e,Math.max(i,o)):Math.min(e,Math.min(i,o))}function x7(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),Fl(r,t/2,n*2)}function Yie(e,n,t,r){return function(i,o,s,a){if(i!==void 0){var h=e[0],g=e[e.length-1],C=t?b7(h,t,s,r):h;if(a){var B=n!==void 0?n:!0;return B?x7(i,C,g):Fl(i,g,C)}var k=Math.min(C,i),P=Math.floor(VB(e,k,o));return e[P]>C&&P<e.length-1?e[P+1]:e[P]}else return}}function qie(e,n,t,r,i,o){return function(s,a,h,g){if(s!==void 0){var C=i?b7(n,i,h,o):n,B=t!==void 0?t:0;if(g){var k=r!==void 0?r:!0;return k?x7(s,C,B):Fl(s,B,C)}var P=1e-9,L=Math.ceil(Math.log(n/C)/Math.log(e)-P),J=-a*(.5-P)+.5,N=Math.min(C,s),$=Math.floor(Math.log(n/N)/Math.log(e)+J),q=Math.max(L,$),oe=n/Math.pow(e,q);return Fl(oe,B,C)}else return}}function V9(e,n,t,r,i){return function(o,s,a,h){if(o!==void 0){var g=r?b7(e,r,a,i):e,C=t!==void 0?t:!0;return!C||!h?Fl(o,n,g):x7(o,g,n)}else return}}function w7(e){if(e!==void 0)return 0}function Z9(e){if(e!==void 0)return e}function Hie(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 Vie(e){var n=e||C2(5);return function(t,r){if(r)return t;if(t!==void 0)return Math.abs(t)<=n?0:t}}function Iz(e){return Math.pow(e,3)}function Qy(e){return 1-Iz(1-e)}function Zie(e){return 3*e*e-2*e*e*e}function Xie(e){return e}var Jie=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)}}(),yM=0,gp=function(e){Jie(n,e);function n(t){var r=e.call(this)||this;r.on,r.once,r.un;var i=gl({},t);return r.hints_=[0,0],r.animations_=[],r.updateAnimationKey_,r.projection_=a7(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&&ez(),i.center&&(i.center=op(i.center,r.projection_)),i.extent&&(i.extent=z0(i.extent,r.projection_)),r.applyOptions_(i),r}return n.prototype.applyOptions_=function(t){var r=gl({},t);for(var i in nh)delete r[i];this.setProperties(r,!0);var o=toe(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=eoe(t),a=o.constraint,h=noe(t);this.constraints_={center:s,resolution:a,rotation:h},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]),h=s/2*(o[0]-r[0]+r[2]-o[2]);this.setCenterInternal([i[0]+a,i[1]-h])}},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(),gl({},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=gl({},o),o.center=op(o.center,this.getProjection())),o.anchor&&(o=gl({},o),o.anchor=op(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&&Bx(i,!0);return}for(var a=Date.now(),h=this.targetCenter_.slice(),g=this.targetResolution_,C=this.targetRotation_,B=[];o<r;++o){var k=arguments[o],P={start:a,complete:!1,anchor:k.anchor,duration:k.duration!==void 0?k.duration:1e3,easing:k.easing||Zie,callback:i};if(k.center&&(P.sourceCenter=h,P.targetCenter=k.center.slice(),h=P.targetCenter),k.zoom!==void 0?(P.sourceResolution=g,P.targetResolution=this.getResolutionForZoom(k.zoom),g=P.targetResolution):k.resolution&&(P.sourceResolution=g,P.targetResolution=k.resolution,g=P.targetResolution),k.rotation!==void 0){P.sourceRotation=C;var L=J0(k.rotation-C+Math.PI,2*Math.PI)-Math.PI;P.targetRotation=C+L,C=P.targetRotation}roe(P)?P.complete=!0:a+=P.duration,B.push(P)}this.animations_.push(B),this.setHint(il.ANIMATING,1),this.updateAnimations_()},n.prototype.getAnimating=function(){return this.hints_[il.ANIMATING]>0},n.prototype.getInteracting=function(){return this.hints_[il.INTERACTING]>0},n.prototype.cancelAnimations=function(){this.setHint(il.ANIMATING,-this.hints_[il.ANIMATING]);for(var t,r=0,i=this.animations_.length;r<i;++r){var o=this.animations_[r];if(o[0].callback&&Bx(o[0].callback,!1),!t)for(var s=0,a=o.length;s<a;++s){var h=o[s];if(!h.complete){t=h.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,h=o.length;a<h;++a){var g=o[a];if(!g.complete){var C=t-g.start,B=g.duration>0?C/g.duration:1;B>=1?(g.complete=!0,B=1):s=!1;var k=g.easing(B);if(g.sourceCenter){var P=g.sourceCenter[0],L=g.sourceCenter[1],J=g.targetCenter[0],N=g.targetCenter[1];this.nextCenter_=g.targetCenter;var $=P+k*(J-P),q=L+k*(N-L);this.targetCenter_=[$,q]}if(g.sourceResolution&&g.targetResolution){var oe=k===1?g.targetResolution:g.sourceResolution+k*(g.targetResolution-g.sourceResolution);if(g.anchor){var ce=this.getViewportSize_(this.getRotation()),me=this.constraints_.resolution(oe,0,ce,!0);this.targetCenter_=this.calculateCenterZoom(me,g.anchor)}this.nextResolution_=g.targetResolution,this.targetResolution_=oe,this.applyTargetState_(!0)}if(g.sourceRotation!==void 0&&g.targetRotation!==void 0){var he=k===1?J0(g.targetRotation+Math.PI,2*Math.PI)-Math.PI:g.sourceRotation+k*(g.targetRotation-g.sourceRotation);if(g.anchor){var V=this.constraints_.rotation(he,!0);this.targetCenter_=this.calculateCenterRotate(V,g.anchor)}this.nextRotation_=g.targetRotation,this.targetRotation_=he}if(this.applyTargetState_(!0),r=!0,!g.complete)break}}if(s){this.animations_[i]=null,this.setHint(il.ANIMATING,-1),this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN;var ae=o[0].callback;ae&&Bx(ae,!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]],r7(i,t-this.getRotation()),vne(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,h=r[1]-t*(r[1]-o[1])/s;i=[a,h]}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&&rE(t,this.getProjection())},n.prototype.getCenterInternal=function(){return this.get(nh.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 nz(r,this.getProjection())},n.prototype.calculateExtentInternal=function(t){var r=t||this.getViewportSizeMinusPadding_(),i=this.getCenterInternal();ho(i,1);var o=this.getResolution();ho(o!==void 0,2);var s=this.getRotation();return ho(s!==void 0,3),X6(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(nh.RESOLUTION)},n.prototype.getResolutions=function(){return this.resolutions_},n.prototype.getResolutionForExtent=function(t,r){return this.getResolutionForExtentInternal(z0(t,this.getProjection()),r)},n.prototype.getResolutionForExtentInternal=function(t,r){var i=r||this.getViewportSizeMinusPadding_(),o=ys(t)/i[0],s=rc(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 h=i/Math.pow(r,a*s);return h}},n.prototype.getRotation=function(){return this.get(nh.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 h=Math.log(i/a)/r/s;return h}},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=vM(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=VB(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=Fl(Math.floor(t),0,this.resolutions_.length-2),i=this.resolutions_[r]/this.resolutions_[r+1];return this.resolutions_[r]/Math.pow(i,Fl(t-r,0,1))}else return this.maxResolution_/Math.pow(this.zoomFactor_,t-this.minZoom_)},n.prototype.fit=function(t,r){var i;if(ho(Array.isArray(t)||typeof t.getSimplifiedGeometry=="function",24),Array.isArray(t)){ho(!t7(t),25);var o=z0(t,this.getProjection());i=L9(o)}else if(t.getType()==="Circle"){var o=z0(t.getExtent(),this.getProjection());i=L9(o),i.rotate(this.getRotation(),Nm(o))}else{var s=Ene();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(),h=1/0,g=1/0,C=-1/0,B=-1/0,k=0,P=s.length;k<P;k+=a){var L=s[k]*i-s[k+1]*o,J=s[k]*o+s[k+1]*i;h=Math.min(h,L),g=Math.min(g,J),C=Math.max(C,L),B=Math.max(B,J)}return[h,g,C,B]},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,h;i.minResolution!==void 0?h=i.minResolution:i.maxZoom!==void 0?h=this.getResolutionForZoom(i.maxZoom):h=0;var g=this.rotatedExtentForGeometry(t),C=this.getResolutionForExtentInternal(g,[o[0]-s[1]-s[3],o[1]-s[0]-s[2]]);C=isNaN(C)?h:Math.max(C,h),C=this.getConstrainedResolution(C,a?0:1);var B=this.getRotation(),k=Math.sin(B),P=Math.cos(B),L=Nm(g);L[0]+=(s[1]-s[3])/2*C,L[1]+=(s[0]-s[2])/2*C;var J=L[0]*P-L[1]*k,N=L[1]*P+L[0]*k,$=this.getConstrainedCenter([J,N],C),q=i.callback?i.callback:c1;i.duration!==void 0?this.animateInternal({resolution:C,center:$,duration:i.duration,easing:i.easing},q):(this.targetResolution_=C,this.targetCenter_=$,this.applyTargetState_(!1,!0),Bx(q,!0))},n.prototype.centerOn=function(t,r,i){this.centerOnInternal(op(t,this.getProjection()),r,i)},n.prototype.centerOnInternal=function(t,r,i){this.setCenterInternal(vM(t,r,i,this.getResolution(),this.getRotation()))},n.prototype.calculateCenterShift=function(t,r,i,o){var s,a=this.padding_;if(a&&t){var h=this.getViewportSizeMinusPadding_(-i),g=vM(t,o,[h[0]/2+a[3],h[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=rE(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&&op(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=op(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&&op(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),h=this.constraints_.center(this.targetCenter_,a,s,i,this.calculateCenterShift(this.targetCenter_,a,o,s));this.get(nh.ROTATION)!==o&&this.set(nh.ROTATION,o),this.get(nh.RESOLUTION)!==a&&(this.set(nh.RESOLUTION,a),this.set("zoom",this.getZoom(),!0)),(!h||!this.get(nh.CENTER)||!x3(this.get(nh.CENTER),h))&&this.set(nh.CENTER,h),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_),h=this.getViewportSize_(a),g=this.constraints_.resolution(this.targetResolution_,s,h),C=this.constraints_.center(this.targetCenter_,g,h,!1,this.calculateCenterShift(this.targetCenter_,g,a,h));if(o===0&&!this.cancelAnchor_){this.targetResolution_=g,this.targetRotation_=a,this.targetCenter_=C,this.applyTargetState_();return}var B=i||(o===0?this.cancelAnchor_:void 0);this.cancelAnchor_=void 0,(this.getResolution()!==g||this.getRotation()!==a||!this.getCenterInternal()||!x3(this.getCenterInternal(),C))&&(this.getAnimating()&&this.cancelAnimations(),this.animateInternal({rotation:a,center:C,resolution:g,duration:o,easing:Qy,anchor:B}))},n.prototype.beginInteraction=function(){this.resolveConstraints(0),this.setHint(il.INTERACTING,1)},n.prototype.endInteraction=function(t,r,i){var o=i&&op(i,this.getProjection());this.endInteractionInternal(t,r,o)},n.prototype.endInteractionInternal=function(t,r,i){this.setHint(il.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}(fh);function Bx(e,n){setTimeout(function(){e(n)},0)}function eoe(e){if(e.extent!==void 0){var n=e.smoothExtentConstraint!==void 0?e.smoothExtentConstraint:!0;return H9(e.extent,e.constrainOnlyCenter,n)}var t=a7(e.projection,"EPSG:3857");if(e.multiWorld!==!0&&t.isGlobal()){var r=t.getExtent().slice();return r[0]=-1/0,r[2]=1/0,H9(r,!1,!1)}return $ie}function toe(e){var n,t,r,i=28,o=2,s=e.minZoom!==void 0?e.minZoom:yM,a=e.maxZoom!==void 0?e.maxZoom:i,h=e.zoomFactor!==void 0?e.zoomFactor:o,g=e.multiWorld!==void 0?e.multiWorld:!1,C=e.smoothResolutionConstraint!==void 0?e.smoothResolutionConstraint:!0,B=e.showFullExtent!==void 0?e.showFullExtent:!1,k=a7(e.projection,"EPSG:3857"),P=k.getExtent(),L=e.constrainOnlyCenter,J=e.extent;if(!g&&!J&&k.isGlobal()&&(L=!1,J=P),e.resolutions!==void 0){var N=e.resolutions;t=N[s],r=N[a]!==void 0?N[a]:N[N.length-1],e.constrainResolution?n=Yie(N,C,!L&&J,B):n=V9(t,r,C,!L&&J,B)}else{var $=P?Math.max(ys(P),rc(P)):360*vf[OA.DEGREES]/k.getMetersPerUnit(),q=$/C7/Math.pow(o,yM),oe=q/Math.pow(o,i-yM);t=e.maxResolution,t!==void 0?s=0:t=q/Math.pow(h,s),r=e.minResolution,r===void 0&&(e.maxZoom!==void 0?e.maxResolution!==void 0?r=t/Math.pow(h,a):r=q/Math.pow(h,a):r=oe),a=s+Math.floor(Math.log(t/r)/Math.log(h)),r=t/Math.pow(h,a-s),e.constrainResolution?n=qie(h,t,r,C,!L&&J,B):n=V9(t,r,C,!L&&J,B)}return{constraint:n,maxResolution:t,minResolution:r,minZoom:s,zoomFactor:h}}function noe(e){var n=e.enableRotation!==void 0?e.enableRotation:!0;if(n){var t=e.constrainRotation;return t===void 0||t===!0?Vie():t===!1?Z9:typeof t=="number"?Hie(t):Z9}else return w7}function roe(e){return!(e.sourceCenter&&e.targetCenter&&!x3(e.sourceCenter,e.targetCenter)||e.sourceResolution!==e.targetResolution||e.sourceRotation!==e.targetRotation)}function vM(e,n,t,r,i){var o=Math.cos(-i),s=Math.sin(-i),a=e[0]*o-e[1]*s,h=e[1]*o+e[0]*s;a+=(n[0]/2-t[0])*r,h+=(t[1]-n[1]/2)*r,s=-s;var g=a*o-h*s,C=h*o+a*s;return[g,C]}function X9(e){return e[0]>0&&e[1]>0}function ioe(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 SA(e,n){return Array.isArray(e)?e:(n===void 0?n=[e,e]:(n[0]=e,n[1]=e),n)}var ooe=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 Tz(e){if(e instanceof m5){e.setMapInternal(null);return}e instanceof y5&&e.getLayers().forEach(Tz)}function Kz(e,n){if(e instanceof m5){e.setMapInternal(n);return}if(e instanceof y5)for(var t=e.getLayers().getArray(),r=0,i=t.length;r<i;++r)Kz(t[r],n)}var aoe=function(e){ooe(n,e);function n(t){var r=e.call(this)||this;r.on,r.once,r.un;var i=soe(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:NR,r.postRenderTimeoutHandle_,r.animationDelayKey_,r.animationDelay_=(function(){this.animationDelayKey_=void 0,this.renderFrame_(Date.now())}).bind(r),r.coordinateToPixelTransform_=_d(),r.pixelToCoordinateTransform_=_d(),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 yd,r.interactions=i.interactions||new yd,r.overlays_=i.overlays,r.overlayIdIndex_={},r.renderer_=null,r.postRenderFunctions_=[],r.tileQueue_=new Gie(r.getTilePriority.bind(r),r.handleTileChange_.bind(r)),r.addChangeListener(tA.LAYERGROUP,r.handleLayerGroupChanged_),r.addChangeListener(tA.VIEW,r.handleViewChanged_),r.addChangeListener(tA.SIZE,r.handleSizeChanged_),r.addChangeListener(tA.TARGET,r.handleTargetChanged_),r.setProperties(i.values);var o=r;return t.view&&!(t.view instanceof gp)&&t.view.then(function(s){o.setView(new gp(s))}),r.controls.addEventListener(JA.ADD,(function(s){s.element.setMap(this)}).bind(r)),r.controls.addEventListener(JA.REMOVE,(function(s){s.element.setMap(null)}).bind(r)),r.interactions.addEventListener(JA.ADD,(function(s){s.element.setMap(this)}).bind(r)),r.interactions.addEventListener(JA.REMOVE,(function(s){s.element.setMap(null)}).bind(r)),r.overlays_.addEventListener(JA.ADD,(function(s){this.addOverlayInternal_(s.element)}).bind(r)),r.overlays_.addEventListener(JA.REMOVE,(function(s){var a=s.element,h=a.getId();h!==void 0&&delete this.overlayIdIndex_[h.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){Kz(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:oy,h=i.checkWrapped!==!1;return this.renderer_.forEachFeatureAtCoordinate(o,this.frameState_,s,h,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 y5?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||oy;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:oy,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(tA.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 rE(this.getCoordinateFromPixelInternal(t),this.getView().getProjection())},n.prototype.getCoordinateFromPixelInternal=function(t){var r=this.frameState_;return r?fl(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(tA.LAYERGROUP)},n.prototype.setLayers=function(t){var r=this.getLayerGroup();if(t instanceof yd){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=op(t,this.getView().getProjection());return this.getPixelFromCoordinateInternal(r)},n.prototype.getPixelFromCoordinateInternal=function(t){var r=this.frameState_;return r?fl(r.coordinateToPixelTransform,t.slice(0,2)):null},n.prototype.getRenderer=function(){return this.renderer_},n.prototype.getSize=function(){return this.get(tA.SIZE)},n.prototype.getView=function(){return this.get(tA.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 Qie(this.frameState_,t,r,i,o)},n.prototype.handleBrowserEvent=function(t,r){var i=r||t.type,o=new rm(i,this,t);this.handleMapBrowserEvent(o)},n.prototype.handleMapBrowserEvent=function(t){if(this.frameState_){var r=t.originalEvent,i=r.type;if(i===fE.POINTERDOWN||i===Di.WHEEL||i===Di.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 h=this.getInteractions().getArray().slice(),g=h.length-1;g>=0;g--){var C=h[g];if(!(C.getMap()!==this||!C.getActive()||!this.getTargetElement())){var B=C.handleEvent(t);if(!B||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[il.ANIMATING]||s[il.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(Dm.RENDERCOMPLETE)&&this.renderer_.dispatchRenderEvent(Dm.RENDERCOMPLETE,t),this.loaded_===!1&&(this.loaded_=!0,this.dispatchEvent(new Mg(sp.LOADEND,this,t)))):this.loaded_===!0&&(this.loaded_=!1,this.dispatchEvent(new Mg(sp.LOADSTART,this,t))));for(var h=this.postRenderFunctions_,g=0,C=h.length;g<C;++g)h[g](this,t);h.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)is(this.targetChangeHandlerKeys_[t]);this.targetChangeHandlerKeys_=null,this.viewport_.removeEventListener(Di.CONTEXTMENU,this.boundHandleBrowserEvent_),this.viewport_.removeEventListener(Di.WHEEL,this.boundHandleBrowserEvent_),this.mapBrowserEventHandler_.dispose(),this.mapBrowserEventHandler_=null,k3(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 Rie(this,this.moveTolerance_);for(var o in rl)this.mapBrowserEventHandler_.addEventListener(rl[o],this.handleMapBrowserEvent.bind(this));this.viewport_.addEventListener(Di.CONTEXTMENU,this.boundHandleBrowserEvent_,!1),this.viewport_.addEventListener(Di.WHEEL,this.boundHandleBrowserEvent_,GR?{passive:!1}:!1);var s=this.getOwnerDocument().defaultView,a=this.keyboardEventTarget_?this.keyboardEventTarget_:i;this.targetChangeHandlerKeys_=[ko(a,Di.KEYDOWN,this.handleBrowserEvent,this),ko(a,Di.KEYPRESS,this.handleBrowserEvent,this),ko(s,Di.RESIZE,this.updateSize,this)]}this.updateSize()},n.prototype.handleTileChange_=function(){this.render()},n.prototype.handleViewPropertyChanged_=function(){this.render()},n.prototype.handleViewChanged_=function(){this.viewPropertyListenerKey_&&(is(this.viewPropertyListenerKey_),this.viewPropertyListenerKey_=null),this.viewChangeListenerKey_&&(is(this.viewChangeListenerKey_),this.viewChangeListenerKey_=null);var t=this.getView();t&&(this.updateViewportSize_(),this.viewPropertyListenerKey_=ko(t,Ey.PROPERTYCHANGE,this.handleViewPropertyChanged_,this),this.viewChangeListenerKey_=ko(t,Di.CHANGE,this.handleViewPropertyChanged_,this),t.resolveConstraints(0)),this.render()},n.prototype.handleLayerGroupChanged_=function(){this.layerGroupPropertyListenerKeys_&&(this.layerGroupPropertyListenerKeys_.forEach(is),this.layerGroupPropertyListenerKeys_=null);var t=this.getLayerGroup();t&&(this.handleLayerAdd_(new am("addlayer",t)),this.layerGroupPropertyListenerKeys_=[ko(t,Ey.PROPERTYCHANGE,this.render,this),ko(t,Di.CHANGE,this.render,this),ko(t,"addlayer",this.handleLayerAdd_,this),ko(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){Tz(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&&X9(i)&&o&&o.isDef()){var h=o.getHints(this.frameState_?this.frameState_.viewHints:void 0),g=o.getState();if(a={animate:!1,coordinateToPixelTransform:this.coordinateToPixelTransform_,declutterTree:null,extent:X6(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:h,wantedTiles:{},mapId:$i(this),renderTargets:{}},g.nextCenter&&g.nextResolution){var C=isNaN(g.nextRotation)?g.rotation:g.nextRotation;a.nextExtent=X6(g.nextCenter,g.nextResolution,C,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 B=!this.previousExtent_||!t7(this.previousExtent_)&&!Oy(a.extent,this.previousExtent_);B&&(this.dispatchEvent(new Mg(sp.MOVESTART,this,s)),this.previousExtent_=YC(this.previousExtent_))}var k=this.previousExtent_&&!a.viewHints[il.ANIMATING]&&!a.viewHints[il.INTERACTING]&&!Oy(a.extent,this.previousExtent_);k&&(this.dispatchEvent(new Mg(sp.MOVEEND,this,a)),YR(a.extent,this.previousExtent_))}this.dispatchEvent(new Mg(sp.POSTRENDER,this,a)),this.renderComplete_=this.hasListener(sp.LOADSTART)||this.hasListener(sp.LOADEND)||this.hasListener(Dm.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 am("removelayer",r)),this.set(tA.LAYERGROUP,t)},n.prototype.setSize=function(t){this.set(tA.SIZE,t)},n.prototype.setTarget=function(t){this.set(tA.TARGET,t)},n.prototype.setView=function(t){if(!t||t instanceof gp){this.set(tA.VIEW,t);return}this.set(tA.VIEW,new gp);var r=this;t.then(function(i){r.setView(new gp(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],!X9(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}(fh);function soe(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 y5({layers:e.layers});t[tA.LAYERGROUP]=r,t[tA.TARGET]=e.target,t[tA.VIEW]=e.view instanceof gp?e.view:new gp;var i;e.controls!==void 0&&(Array.isArray(e.controls)?i=new yd(e.controls.slice()):(ho(typeof e.controls.getArray=="function",47),i=e.controls));var o;e.interactions!==void 0&&(Array.isArray(e.interactions)?o=new yd(e.interactions.slice()):(ho(typeof e.interactions.getArray=="function",48),o=e.interactions));var s;return e.overlays!==void 0?Array.isArray(e.overlays)?s=new yd(e.overlays.slice()):(ho(typeof e.overlays.getArray=="function",49),s=e.overlays):s=new yd,{controls:i,interactions:o,keyboardEventTarget:n,overlays:s,values:t}}const loe=aoe;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)}}(),Aoe=function(e){uoe(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(){k3(this.element),e.prototype.disposeInternal.call(this)},n.prototype.getMap=function(){return this.map_},n.prototype.setMap=function(t){this.map_&&k3(this.element);for(var r=0,i=this.listenerKeys.length;r<i;++r)is(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!==c1&&this.listenerKeys.push(ko(t,sp.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}(fh);const M7=Aoe;var coe=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)}}(),doe=function(e){coe(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",h=i.collapseLabel!==void 0?i.collapseLabel:"",g=i.collapseClassName!==void 0?i.collapseClassName:o+"-collapse";typeof h=="string"?(r.collapseLabel_=document.createElement("span"),r.collapseLabel_.textContent=h,r.collapseLabel_.className=g):r.collapseLabel_=h;var C=i.label!==void 0?i.label:"i";typeof C=="string"?(r.label_=document.createElement("span"),r.label_.textContent=C,r.label_.className=a):r.label_=C;var B=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(B),r.toggleButton_.addEventListener(Di.CLICK,r.handleClick_.bind(r),!1);var k=o+" "+g5+" "+v7+(r.collapsed_&&r.collapsible_?" "+G9:"")+(r.collapsible_?"":" ol-uncollapsible"),P=r.element;return P.className=k,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,h=s.length;a<h;++a){var g=s[a];if(B3(g,t.viewState)){var C=g.layer.getSource();if(C){var B=C.getAttributions();if(B){var k=B(t);if(k)if(o=o&&C.getAttributionsCollapsible()!==!1,Array.isArray(k))for(var P=0,L=k.length;P<L;++P)k[P]in r||(i.push(k[P]),r[k[P]]=!0);else k in r||(i.push(k),r[k]=!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_)){Mz(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(G9),this.collapsed_?$9(this.collapseLabel_,this.label_):$9(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}(M7);const hoe=doe;var foe=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)}}(),poe=function(e){foe(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 h=i.tipLabel?i.tipLabel:"Reset rotation",g=document.createElement("button");g.className=o+"-reset",g.setAttribute("type","button"),g.title=h,g.appendChild(r.label_),g.addEventListener(Di.CLICK,r.handleClick_.bind(r),!1);var C=o+" "+g5+" "+v7,B=r.element;return B.className=C,B.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(Ex),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:Qy}):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(Ex);!s&&i===0?this.element.classList.add(Ex):s&&i!==0&&this.element.classList.remove(Ex)}this.label_.style.transform=o}this.rotation_=i}},n}(M7);const moe=poe;var goe=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){goe(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",h=i.zoomOutClassName!==void 0?i.zoomOutClassName:o+"-out",g=i.zoomInLabel!==void 0?i.zoomInLabel:"+",C=i.zoomOutLabel!==void 0?i.zoomOutLabel:"",B=i.zoomInTipLabel!==void 0?i.zoomInTipLabel:"Zoom in",k=i.zoomOutTipLabel!==void 0?i.zoomOutTipLabel:"Zoom out",P=document.createElement("button");P.className=a,P.setAttribute("type","button"),P.title=B,P.appendChild(typeof g=="string"?document.createTextNode(g):g),P.addEventListener(Di.CLICK,r.handleClick_.bind(r,s),!1);var L=document.createElement("button");L.className=h,L.setAttribute("type","button"),L.title=k,L.appendChild(typeof C=="string"?document.createTextNode(C):C),L.addEventListener(Di.CLICK,r.handleClick_.bind(r,-s),!1);var J=o+" "+g5+" "+v7,N=r.element;return N.className=J,N.appendChild(P),N.appendChild(L),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:Qy})):i.setZoom(s)}}},n}(M7);const voe=yoe;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)}}(),eA={ELEMENT:"element",MAP:"map",OFFSET:"offset",POSITION:"position",POSITIONING:"positioning"},Coe=function(e){_oe(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 "+Cie,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(eA.ELEMENT,r.handleElementChanged),r.addChangeListener(eA.MAP,r.handleMapChanged),r.addChangeListener(eA.OFFSET,r.handleOffsetChanged),r.addChangeListener(eA.POSITION,r.handlePositionChanged),r.addChangeListener(eA.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(eA.ELEMENT)},n.prototype.getId=function(){return this.id},n.prototype.getMap=function(){return this.get(eA.MAP)||null},n.prototype.getOffset=function(){return this.get(eA.OFFSET)},n.prototype.getPosition=function(){return this.get(eA.POSITION)},n.prototype.getPositioning=function(){return this.get(eA.POSITIONING)},n.prototype.handleElementChanged=function(){Mz(this.element);var t=this.getElement();t&&this.element.appendChild(t)},n.prototype.handleMapChanged=function(){this.mapPostrenderListenerKey&&(k3(this.element),is(this.mapPostrenderListenerKey),this.mapPostrenderListenerKey=null);var t=this.getMap();if(t){this.mapPostrenderListenerKey=ko(t,sp.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(eA.ELEMENT,t)},n.prototype.setMap=function(t){this.set(eA.MAP,t)},n.prototype.setOffset=function(t){this.set(eA.OFFSET,t)},n.prototype.setPosition=function(t){this.set(eA.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(eA.POSITION))){var i=this.getRect(r.getTargetElement(),r.getSize()),o=this.getElement(),s=this.getRect(o,[xie(o),wie(o)]),a=t||{},h=a.margin===void 0?20:a.margin;if(!ym(i,s)){var g=s[0]-i[0],C=i[2]-s[2],B=s[1]-i[1],k=i[3]-s[3],P=[0,0];if(g<0?P[0]=g-h:C<0&&(P[0]=Math.abs(C)+h),B<0?P[1]=B-h:k<0&&(P[1]=Math.abs(k)+h),P[0]!==0||P[1]!==0){var L=r.getView().getCenterInternal(),J=r.getPixelFromCoordinateInternal(L);if(!J)return;var N=[J[0]+P[0],J[1]+P[1]],$=a.animation||{};r.getView().animateInternal({center:r.getCoordinateFromPixelInternal(N),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(eA.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",h=Math.round(t[1]+o[1])+"px",g="0%",C="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"?C="-100%":(s=="center-left"||s=="center-center"||s=="center-right")&&(C="-50%");var B="translate(".concat(g,", ").concat(C,") translate(").concat(a,", ").concat(h,")");this.rendered.transform_!=B&&(this.rendered.transform_=B,i.transform=B,i.msTransform=B)},n.prototype.getOptions=function(){return this.options},n}(fh);function boe(e){var n=e||{},t=new yd,r=n.zoom!==void 0?n.zoom:!0;r&&t.push(new voe(n.zoomOptions));var i=n.rotate!==void 0?n.rotate:!0;i&&t.push(new moe(n.rotateOptions));var o=n.attribution!==void 0?n.attribution:!0;return o&&t.push(new hoe(n.attributionOptions)),t}const J9={ACTIVE:"active"};var xoe=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)}}(),woe=function(e){xoe(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(J9.ACTIVE)},n.prototype.getMap=function(){return this.map_},n.prototype.handleEvent=function(t){return!0},n.prototype.setActive=function(t){this.set(J9.ACTIVE,t)},n.prototype.setMap=function(t){this.map_=t},n}(fh);function Moe(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:Xie,center:e.getConstrainedCenter(i)})}}function S7(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:Qy})}}const HC=woe;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)}}(),Eoe=function(e){Soe(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==rl.DBLCLICK){var i=t.originalEvent,o=t.map,s=t.coordinate,a=i.shiftKey?-this.delta_:this.delta_,h=o.getView();S7(h,a,s,this.duration_),i.preventDefault(),r=!0}return!r},n}(HC);const Ooe=Eoe;var Boe=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)}}(),koe=function(e){Boe(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==rl.POINTERDRAG)this.handleDragEvent(t),t.originalEvent.preventDefault();else if(t.type==rl.POINTERUP){var i=this.handleUpEvent(t);this.handlingDownUpSequence=i&&this.targetPointers.length>0}}else if(t.type==rl.POINTERDOWN){var o=this.handleDownEvent(t);this.handlingDownUpSequence=o,r=this.stopDown(o)}else t.type==rl.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}(HC);function E7(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 VC=koe;function pE(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 Ioe=function(e){var n=e.originalEvent;return n.altKey&&!(n.metaKey||n.ctrlKey)&&n.shiftKey},Toe=function(e){var n=e.map.getTargetElement(),t=e.map.getOwnerDocument().activeElement;return n.contains(t)},Pz=function(e){return e.map.getTargetElement().hasAttribute("tabindex")?Toe(e):!0},Koe=oy,Fz=function(e){var n=e.originalEvent;return n.button==0&&!(Nte&&Gte&&n.ctrlKey)},Dz=function(e){var n=e.originalEvent;return!n.altKey&&!(n.metaKey||n.ctrlKey)&&!n.shiftKey},Poe=function(e){var n=e.originalEvent;return!n.altKey&&!(n.metaKey||n.ctrlKey)&&n.shiftKey},Lz=function(e){var n=e.originalEvent,t=n.target.tagName;return t!=="INPUT"&&t!=="SELECT"&&t!=="TEXTAREA"&&!n.target.isContentEditable},_M=function(e){var n=e.originalEvent;return ho(n!==void 0,56),n.pointerType=="mouse"},Foe=function(e){var n=e.originalEvent;return ho(n!==void 0,56),n.isPrimary&&n.button===0},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)}}(),Loe=function(e){Doe(n,e);function n(t){var r=e.call(this,{stopDown:a5})||this,i=t||{};r.kinetic_=i.kinetic,r.lastCentroid=null,r.lastPointersCount_,r.panning_=!1;var o=i.condition?i.condition:pE(Dz,Foe);return r.condition_=i.onFocusOnly?pE(Pz,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=E7(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();_ne(o,a.getResolution()),r7(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(),h=r.getPixelFromCoordinateInternal(a),g=r.getCoordinateFromPixelInternal([h[0]-o*Math.cos(s),h[1]-o*Math.sin(s)]);i.animateInternal({center:i.getConstrainedCenter(g),duration:500,easing:Qy})}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}(VC);const Uoe=Loe;var Roe=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){Roe(n,e);function n(t){var r=this,i=t||{};return r=e.call(this,{stopDown:a5})||this,r.condition_=i.condition?i.condition:Ioe,r.lastAngle_=void 0,r.duration_=i.duration!==void 0?i.duration:250,r}return n.prototype.handleDragEvent=function(t){if(_M(t)){var r=t.map,i=r.getView();if(i.getConstraints().rotation!==w7){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 h=a-this.lastAngle_;i.adjustRotationInternal(-h)}this.lastAngle_=a}}},n.prototype.handleUpEvent=function(t){if(!_M(t))return!0;var r=t.map,i=r.getView();return i.endInteraction(this.duration_),!1},n.prototype.handleDownEvent=function(t){if(!_M(t))return!1;if(Fz(t)&&this.condition_(t)){var r=t.map;return r.getView().beginInteraction(),this.lastAngle_=void 0,!0}else return!1},n}(VC),joe=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)}}(),Woe=function(e){joe(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 cC([o])},n.prototype.getGeometry=function(){return this.geometry_},n}(HB);const Noe=Woe;var Uz=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)}}(),kx={BOXSTART:"boxstart",BOXDRAG:"boxdrag",BOXEND:"boxend",BOXCANCEL:"boxcancel"},CM=function(e){Uz(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.coordinate=r,o.mapBrowserEvent=i,o}return n}(Op),Goe=function(e){Uz(n,e);function n(t){var r=e.call(this)||this;r.on,r.once,r.un;var i=t||{};return r.box_=new Noe(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:Fz,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 CM(kx.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 CM(r?kx.BOXEND:kx.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 CM(kx.BOXSTART,t.coordinate,t)),!0):!1},n.prototype.onBoxEnd=function(t){},n}(VC);const Qoe=Goe;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.condition?i.condition:Poe;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),h=i.getResolution()/a;o=o.clone(),o.scale(h*h)}i.fitInternal(o,{duration:this.duration_,easing:Qy})},n}(Qoe);const qoe=Yoe,g0={LEFT:37,UP:38,RIGHT:39,DOWN:40};var Hoe=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){Hoe(n,e);function n(t){var r=e.call(this)||this,i=t||{};return r.defaultCondition_=function(o){return Dz(o)&&Lz(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==Di.KEYDOWN){var i=t.originalEvent,o=i.keyCode;if(this.condition_(t)&&(o==g0.DOWN||o==g0.LEFT||o==g0.RIGHT||o==g0.UP)){var s=t.map,a=s.getView(),h=a.getResolution()*this.pixelDelta_,g=0,C=0;o==g0.DOWN?C=-h:o==g0.LEFT?g=-h:o==g0.RIGHT?g=h:C=h;var B=[g,C];r7(B,a.getRotation()),Moe(a,B,this.duration_),i.preventDefault(),r=!0}}return!r},n}(HC),Zoe=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)}}(),Xoe=function(e){Zoe(n,e);function n(t){var r=e.call(this)||this,i=t||{};return r.condition_=i.condition?i.condition:Lz,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==Di.KEYDOWN||t.type==Di.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_,h=s.getView();S7(h,a,void 0,this.duration_),i.preventDefault(),r=!0}}return!r},n}(HC);const Joe=Xoe;var eae=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}(),tae=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)}}(),bM={TRACKPAD:"trackpad",WHEEL:"wheel"},nae=function(e){tae(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:Koe;return r.condition_=i.onFocusOnly?pE(Pz,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!==Di.WHEEL)return!0;var i=t.map,o=t.originalEvent;o.preventDefault(),this.useAnchor_&&(this.lastAnchor_=t.coordinate);var s;if(t.type==Di.WHEEL&&(s=o.deltaY,jte&&o.deltaMode===WheelEvent.DOM_DELTA_PIXEL&&(s/=NR),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?bM.TRACKPAD:bM.WHEEL);var h=i.getView();if(this.mode_===bM.TRACKPAD&&!(h.getConstrainResolution()||this.constrainResolution_))return this.trackpadTimeoutId_?clearTimeout(this.trackpadTimeoutId_):(h.getAnimating()&&h.cancelAnimations(),h.beginInteraction()),this.trackpadTimeoutId_=setTimeout(this.endInteraction_.bind(this),this.timeout_),h.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=-Fl(this.totalDelta_,-this.maxDelta_*this.deltaPerZoom_,this.maxDelta_*this.deltaPerZoom_)/this.deltaPerZoom_;(r.getConstrainResolution()||this.constrainResolution_)&&(i=i?i>0?1:-1:0),S7(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}(HC);const rae=nae;var iae=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)}}(),oae=function(e){iae(n,e);function n(t){var r=this,i=t||{},o=i;return o.stopDown||(o.stopDown=a5),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 h=t.map,g=h.getView();if(g.getConstraints().rotation!==w7){var C=h.getViewport().getBoundingClientRect(),B=E7(this.targetPointers);B[0]-=C.left,B[1]-=C.top,this.anchor_=h.getCoordinateFromPixelInternal(B),this.rotating_&&(h.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}(VC),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)}}(),sae=function(e){aae(n,e);function n(t){var r=this,i=t||{},o=i;return o.stopDown||(o.stopDown=a5),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,h=Math.sqrt(s*s+a*a);this.lastDistance_!==void 0&&(r=this.lastDistance_/h),this.lastDistance_=h;var g=t.map,C=g.getView();r!=1&&(this.lastScaleDelta_=r);var B=g.getViewport().getBoundingClientRect(),k=E7(this.targetPointers);k[0]-=B.left,k[1]-=B.top,this.anchor_=g.getCoordinateFromPixelInternal(k),g.render(),C.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}(VC);const lae=sae;function uae(e,n,t,r,i){Rz(e,n,t||0,r||e.length-1,i||Aae)}function Rz(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),h=.5*Math.exp(2*a/3),g=.5*Math.sqrt(a*h*(o-h)/o)*(s-o/2<0?-1:1),C=Math.max(t,Math.floor(n-s*h/o+g)),B=Math.min(r,Math.floor(n+(o-s)*h/o+g));Rz(e,n,C,B,i)}var k=e[n],P=t,L=r;for(zv(e,t,n),i(e[r],k)>0&&zv(e,t,r);P<L;){for(zv(e,P,L),P++,L--;i(e[P],k)<0;)P++;for(;i(e[L],k)>0;)L--}i(e[t],k)===0?zv(e,t,L):(L++,zv(e,L,r)),L<=n&&(t=L+1),n<=L&&(r=L-1)}}function zv(e,n,t){var r=e[n];e[n]=e[t],e[t]=r}function Aae(e,n){return e<n?-1:e>n?1:0}let zz=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(!Tx(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],h=t.leaf?i(a):a;Tx(n,h)&&(t.leaf?r.push(a):wM(n,h)?this._all(a,r):o.push(a))}t=o.pop()}return r}collides(n){let t=this.data;if(!Tx(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(Tx(n,s)){if(t.leaf||wM(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=Sg([]),this}remove(n,t){if(!n)return this;let r=this.data;const i=this.toBBox(n),o=[],s=[];let a,h,g;for(;r||o.length;){if(r||(r=o.pop(),h=o[o.length-1],a=s.pop(),g=!0),r.leaf){const C=cae(n,r.children,t);if(C!==-1)return r.children.splice(C,1),o.push(r),this._condense(o),this}!g&&!r.leaf&&wM(r,i)?(o.push(r),s.push(a),a=0,h=r,r=r.children[0]):h?(a++,r=h.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=Sg(n.slice(t,r+1)),Ag(a,this.toBBox),a;i||(i=Math.ceil(Math.log(o)/Math.log(s)),s=Math.ceil(o/Math.pow(s,i-1))),a=Sg([]),a.leaf=!1,a.height=i;const h=Math.ceil(o/s),g=h*Math.ceil(Math.sqrt(s));eT(n,t,r,g,this.compareMinX);for(let C=t;C<=r;C+=g){const B=Math.min(C+g-1,r);eT(n,C,B,h,this.compareMinY);for(let k=C;k<=B;k+=h){const P=Math.min(k+h-1,B);a.children.push(this._build(n,k,P,i-1))}}return Ag(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 h=0;h<t.children.length;h++){const g=t.children[h],C=xM(g),B=fae(n,g)-C;B<s?(s=B,o=C<o?C:o,a=g):B===s&&C<o&&(o=C,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),s_(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=Sg(r.children.splice(s,r.children.length-s));a.height=r.height,a.leaf=r.leaf,Ag(r,this.toBBox),Ag(a,this.toBBox),t?n[t-1].children.push(a):this._splitRoot(r,a)}_splitRoot(n,t){this.data=Sg([n,t]),this.data.height=n.height+1,this.data.leaf=!1,Ag(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 h=a_(n,0,a,this.toBBox),g=a_(n,a,r,this.toBBox),C=pae(h,g),B=xM(h)+xM(g);C<o?(o=C,i=a,s=B<s?B:s):C===o&&B<s&&(s=B,i=a)}return i||r-t}_chooseSplitAxis(n,t,r){const i=n.leaf?this.compareMinX:dae,o=n.leaf?this.compareMinY:hae,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=a_(n,0,t,o),a=a_(n,r-t,r,o);let h=Ix(s)+Ix(a);for(let g=t;g<r-t;g++){const C=n.children[g];s_(s,n.leaf?o(C):C),h+=Ix(s)}for(let g=r-t-1;g>=t;g--){const C=n.children[g];s_(a,n.leaf?o(C):C),h+=Ix(a)}return h}_adjustParentBBoxes(n,t,r){for(let i=r;i>=0;i--)s_(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():Ag(n[t],this.toBBox)}};function cae(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 Ag(e,n){a_(e,0,e.children.length,n,e)}function a_(e,n,t,r,i){i||(i=Sg(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];s_(i,e.leaf?r(s):s)}return i}function s_(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 dae(e,n){return e.minX-n.minX}function hae(e,n){return e.minY-n.minY}function xM(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function Ix(e){return e.maxX-e.minX+(e.maxY-e.minY)}function fae(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 pae(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 wM(e,n){return e.minX<=n.minX&&e.minY<=n.minY&&n.maxX<=e.maxX&&n.maxY<=e.maxY}function Tx(e,n){return n.minX<=e.maxX&&n.minY<=e.maxY&&n.maxX>=e.minX&&n.maxY>=e.minY}function Sg(e){return{children:e,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function eT(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;uae(e,s,n,t,i),o.push(n,s,s,t)}}const rs={IDLE:0,LOADING:1,LOADED:2,ERROR:3,EMPTY:4};var mae=function(){function e(n){this.opacity_=n.opacity,this.rotateWithView_=n.rotateWithView,this.rotation_=n.rotation,this.scale_=n.scale,this.scaleArray_=SA(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 pi()},e.prototype.getImage=function(n){return pi()},e.prototype.getHitDetectionImage=function(){return pi()},e.prototype.getPixelRatio=function(n){return 1},e.prototype.getImageState=function(){return pi()},e.prototype.getImageSize=function(){return pi()},e.prototype.getOrigin=function(){return pi()},e.prototype.getSize=function(){return pi()},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_=SA(n)},e.prototype.listenImageChange=function(n){pi()},e.prototype.load=function(){pi()},e.prototype.unlistenImageChange=function(n){pi()},e}();const jz=mae;function cf(e){return Array.isArray(e)?Cz(e):e}var gae=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)}}(),yae=function(e){gae(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=ic(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 rs.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 h=this.radius2_===void 0?this.points_:this.points_*2,g=2*Math.PI/h,C=s*Math.sin(g),B=Math.sqrt(s*s-C*C),k=o-B,P=Math.sqrt(C*C+k*k),L=P/C;if(t==="miter"&&L<=i)return L*r;var J=r/2/L,N=r/2*(k/P),$=Math.sqrt((o+J)*(o+J)+N*N),q=$-o;if(this.radius2_===void 0||t==="bevel")return q*2;var oe=o*Math.sin(g),ce=Math.sqrt(o*o-oe*oe),me=s-ce,he=Math.sqrt(oe*oe+me*me),V=he/oe;if(V<=i){var ae=V*r/2-s-o;return 2*Math.max(q,ae)}return q*2},n.prototype.createRenderOptions=function(){var t=By,r=0,i=null,o=0,s,a=0;this.stroke_&&(s=this.stroke_.getColor(),s===null&&(s=mC),s=cf(s),a=this.stroke_.getWidth(),a===void 0&&(a=yC),i=this.stroke_.getLineDash(),o=this.stroke_.getLineDashOffset(),t=this.stroke_.getLineJoin(),t===void 0&&(t=By),r=this.stroke_.getMiterLimit(),r===void 0&&(r=pC));var h=this.calculateLineJoinSize_(t,a,r),g=Math.max(this.radius_,this.radius2_||0),C=Math.ceil(2*g+h);return{strokeStyle:s,strokeWidth:a,size:C,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=xp),r.fillStyle=cf(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=E3(r)),r===null?i=1:Array.isArray(r)&&(i=r.length===4?r[3]:1),i===0){var o=ic(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,h=0;h<r;h++){var g=s+h*a,C=h%2===0?i:o;t.lineTo(C*Math.cos(g),C*Math.sin(g))}t.closePath()}},n.prototype.drawHitDetectionCanvas_=function(t,r){r.translate(t.size/2,t.size/2),this.createPath_(r),r.fillStyle=xp,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}(jz);const vae=yae;var _ae=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)}}(),Wz=function(e){_ae(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}(vae),zg=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}(),l_=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}(),S0=function(){function e(n){var t=n||{};this.geometry_=null,this.geometryFunction_=tT,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_=tT,this.geometry_=n},e.prototype.setZIndex=function(n){this.zIndex_=n},e}();function Cae(e){var n;if(typeof e=="function")n=e;else{var t;if(Array.isArray(e))t=e;else{ho(typeof e.getZIndex=="function",41);var r=e;t=[r]}n=function(){return t}}return n}var MM=null;function bae(e,n){if(!MM){var t=new zg({color:"rgba(255,255,255,0.4)"}),r=new l_({color:"#3399CC",width:1.25});MM=[new S0({image:new Wz({fill:t,stroke:r,radius:5}),fill:t,stroke:r})]}return MM}function tT(e){return e.getGeometry()}var xae=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)}}(),nT={RENDER_ORDER:"renderOrder"},wae=function(e){xae(n,e);function n(t){var r=this,i=t||{},o=gl({},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(nT.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 zz(9)),this.getRenderer().renderDeclutter(t)},n.prototype.setRenderOrder=function(t){this.set(nT.RENDER_ORDER,t)},n.prototype.setStyle=function(t){this.style_=t!==void 0?t:bae,this.styleFunction_=t===null?void 0:Cae(this.style_),this.changed()},n}(m5);const Nz=wae;var li={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=[li.FILL],_m=[li.STROKE],N0=[li.BEGIN_PATH],rT=[li.CLOSE_PATH],Mae=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 Gz=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){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,h=0,g=t.length;h<g;h+=r)o[0]=t[h],o[1]=t[h+1],$C(i,o)&&(s[a++]=o[0],s[a++]=o[1]);return a},n.prototype.appendFlatLineCoordinates=function(t,r,i,o,s,a){var h=this.coordinates,g=h.length,C=this.getBufferedMaxExtent();a&&(r+=o);var B=t[r],k=t[r+1],P=this.tmpCoordinate_,L=!0,J,N,$;for(J=r+o;J<i;J+=o)P[0]=t[J],P[1]=t[J+1],$=V6(C,P),$!==N?(L&&(h[g++]=B,h[g++]=k,L=!1),h[g++]=P[0],h[g++]=P[1]):$===du.INTERSECTING?(h[g++]=P[0],h[g++]=P[1],L=!1):L=!0,B=P[0],k=P[1],N=$;return(s&&L||J===r+o)&&(h[g++]=B,h[g++]=k),g},n.prototype.drawCustomCoordinates_=function(t,r,i,o,s){for(var a=0,h=i.length;a<h;++a){var g=i[a],C=this.appendFlatLineCoordinates(t,r,g,o,!1,!1);s.push(C),r=g}return r},n.prototype.drawCustom=function(t,r,i,o){this.beginGeometry(t,r);var s=t.getType(),a=t.getStride(),h=this.coordinates.length,g,C,B,k,P;switch(s){case"MultiPolygon":g=t.getOrientedFlatCoordinates(),k=[];var L=t.getEndss();P=0;for(var J=0,N=L.length;J<N;++J){var $=[];P=this.drawCustomCoordinates_(g,P,L[J],a,$),k.push($)}this.instructions.push([li.CUSTOM,h,k,t,i,iE]),this.hitDetectionInstructions.push([li.CUSTOM,h,k,t,o||i,iE]);break;case"Polygon":case"MultiLineString":B=[],g=s=="Polygon"?t.getOrientedFlatCoordinates():t.getFlatCoordinates(),P=this.drawCustomCoordinates_(g,0,t.getEnds(),a,B),this.instructions.push([li.CUSTOM,h,B,t,i,uC]),this.hitDetectionInstructions.push([li.CUSTOM,h,B,t,o||i,uC]);break;case"LineString":case"Circle":g=t.getFlatCoordinates(),C=this.appendFlatLineCoordinates(g,0,g.length,a,!1,!1),this.instructions.push([li.CUSTOM,h,C,t,i,vm]),this.hitDetectionInstructions.push([li.CUSTOM,h,C,t,o||i,vm]);break;case"MultiPoint":g=t.getFlatCoordinates(),C=this.appendFlatPointCoordinates(g,a),C>h&&(this.instructions.push([li.CUSTOM,h,C,t,i,vm]),this.hitDetectionInstructions.push([li.CUSTOM,h,C,t,o||i,vm]));break;case"Point":g=t.getFlatCoordinates(),this.coordinates.push(g[0],g[1]),C=this.coordinates.length,this.instructions.push([li.CUSTOM,h,C,t,i]),this.hitDetectionInstructions.push([li.CUSTOM,h,C,t,o||i]);break}this.endGeometry(r)},n.prototype.beginGeometry=function(t,r){this.beginGeometryInstruction1_=[li.BEGIN_GEOMETRY,r,0,t],this.instructions.push(this.beginGeometryInstruction1_),this.beginGeometryInstruction2_=[li.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==li.END_GEOMETRY?a=r:s==li.BEGIN_GEOMETRY&&(o[2]=r,Ote(this.hitDetectionInstructions,a,r),a=-1)},n.prototype.setFillStrokeStyle=function(t,r){var i=this.state;if(t){var o=t.getColor();i.fillStyle=cf(o||xp)}else i.fillStyle=void 0;if(r){var s=r.getColor();i.strokeStyle=cf(s||mC);var a=r.getLineCap();i.lineCap=a!==void 0?a:I3;var h=r.getLineDash();i.lineDash=h?h.slice():hC;var g=r.getLineDashOffset();i.lineDashOffset=g||fC;var C=r.getLineJoin();i.lineJoin=C!==void 0?C:By;var B=r.getWidth();i.lineWidth=B!==void 0?B:yC;var k=r.getMiterLimit();i.miterLimit=k!==void 0?k:pC,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=[li.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[li.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,h=t.lineJoin,g=t.lineWidth,C=t.miterLimit;(t.currentStrokeStyle!=i||t.currentLineCap!=o||s!=t.currentLineDash&&!_1(t.currentLineDash,s)||t.currentLineDashOffset!=a||t.currentLineJoin!=h||t.currentLineWidth!=g||t.currentMiterLimit!=C)&&(i!==void 0&&r.call(this,t),t.currentStrokeStyle=i,t.currentLineCap=o,t.currentLineDash=s,t.currentLineDashOffset=a,t.currentLineJoin=h,t.currentLineWidth=g,t.currentMiterLimit=C)},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=[li.END_GEOMETRY,t];this.instructions.push(r),this.hitDetectionInstructions.push(r)},n.prototype.getBufferedMaxExtent=function(){if(!this.bufferedMaxExtent_&&(this.bufferedMaxExtent_=YR(this.maxExtent),this.maxLineWidth>0)){var t=this.resolution*(this.maxLineWidth+1)/2;Pm(this.bufferedMaxExtent_,t,this.bufferedMaxExtent_)}return this.bufferedMaxExtent_},n}(Gz);const ZC=Eae;var Oae=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)}}(),Bae=function(e){Oae(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([li.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([li.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([li.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([li.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}(ZC);const kae=Bae;var Iae=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)}}(),Tae=function(e){Iae(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),h=[li.MOVE_TO_LINE_TO,s,a];return this.instructions.push(h),this.hitDetectionInstructions.push(h),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([li.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,hC,fC],N0);var a=t.getFlatCoordinates(),h=t.getStride();this.drawFlatCoordinates_(a,0,a.length,h),this.hitDetectionInstructions.push(_m),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([li.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,i.lineDash,i.lineDashOffset],N0);for(var a=t.getEnds(),h=t.getFlatCoordinates(),g=t.getStride(),C=0,B=0,k=a.length;B<k;++B)C=this.drawFlatCoordinates_(h,C,a[B],g);this.hitDetectionInstructions.push(_m),this.endGeometry(r)}},n.prototype.finish=function(){var t=this.state;return t.lastStroke!=null&&t.lastStroke!=this.coordinates.length&&this.instructions.push(_m),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(_m),t.lastStroke=this.coordinates.length),t.lastStroke=0,e.prototype.applyStroke.call(this,t),this.instructions.push(N0)},n}(ZC);const Kae=Tae;var Pae=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)}}(),Fae=function(e){Pae(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,h=s.strokeStyle!==void 0,g=i.length;this.instructions.push(N0),this.hitDetectionInstructions.push(N0);for(var C=0;C<g;++C){var B=i[C],k=this.coordinates.length,P=this.appendFlatLineCoordinates(t,r,B,o,!0,!h),L=[li.MOVE_TO_LINE_TO,k,P];this.instructions.push(L),this.hitDetectionInstructions.push(L),h&&(this.instructions.push(rT),this.hitDetectionInstructions.push(rT)),r=B}return a&&(this.instructions.push(Kx),this.hitDetectionInstructions.push(Kx)),h&&(this.instructions.push(_m),this.hitDetectionInstructions.push(_m)),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([li.SET_FILL_STYLE,xp]),i.strokeStyle!==void 0&&this.hitDetectionInstructions.push([li.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,i.lineDash,i.lineDashOffset]);var a=t.getFlatCoordinates(),h=t.getStride(),g=this.coordinates.length;this.appendFlatLineCoordinates(a,0,a.length,h,!1,!1);var C=[li.CIRCLE,g];this.instructions.push(N0,C),this.hitDetectionInstructions.push(N0,C),i.fillStyle!==void 0&&(this.instructions.push(Kx),this.hitDetectionInstructions.push(Kx)),i.strokeStyle!==void 0&&(this.instructions.push(_m),this.hitDetectionInstructions.push(_m)),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([li.SET_FILL_STYLE,xp]),i.strokeStyle!==void 0&&this.hitDetectionInstructions.push([li.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,i.lineDash,i.lineDashOffset]);var a=t.getEnds(),h=t.getOrientedFlatCoordinates(),g=t.getStride();this.drawFlatCoordinatess_(h,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([li.SET_FILL_STYLE,xp]),i.strokeStyle!==void 0&&this.hitDetectionInstructions.push([li.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,i.lineDash,i.lineDashOffset]);for(var a=t.getEndss(),h=t.getOrientedFlatCoordinates(),g=t.getStride(),C=0,B=0,k=a.length;B<k;++B)C=this.drawFlatCoordinatess_(h,C,a[B],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]=M0(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}(ZC);const iT=Fae,Qz={POINT:"point",LINE:"line"};function Dae(e,n,t,r,i){var o=t,s=t,a=0,h=0,g=t,C,B,k,P,L,J,N,$,q,oe;for(B=t;B<r;B+=i){var ce=n[B],me=n[B+1];L!==void 0&&(q=ce-L,oe=me-J,P=Math.sqrt(q*q+oe*oe),N!==void 0&&(h+=k,C=Math.acos((N*q+$*oe)/(k*P)),C>e&&(h>a&&(a=h,o=g,s=B),h=0,g=B-i)),k=P,N=q,$=oe),L=ce,J=me}return h+=P,h>a?[g,B]:[o,s]}var Lae=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)}}(),I_={left:0,end:0,center:.5,right:1,start:1,top:0,middle:.5,hanging:.2,alphabetic:.8,ideographic:.8,bottom:1},Uae=function(e){Lae(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,h=a.length,g=t.getType(),C=null,B=t.getStride();if(s.placement===Qz.LINE&&(g=="LineString"||g=="MultiLineString"||g=="Polygon"||g=="MultiPolygon")){if(!pl(this.getBufferedMaxExtent(),t.getExtent()))return;var k=void 0;if(C=t.getFlatCoordinates(),g=="LineString")k=[C.length];else if(g=="MultiLineString")k=t.getEnds();else if(g=="Polygon")k=t.getEnds().slice(0,1);else if(g=="MultiPolygon"){var P=t.getEndss();k=[];for(var L=0,J=P.length;L<J;++L)k.push(P[L][0])}this.beginGeometry(t,r);for(var N=s.textAlign,$=0,q=void 0,oe=0,ce=k.length;oe<ce;++oe){if(N==null){var me=Dae(s.maxAngle,C,$,k[oe],B);$=me[0],q=me[1]}else q=k[oe];for(var L=$;L<q;L+=B)a.push(C[L],C[L+1]);var he=a.length;$=k[oe],this.drawChars_(h,he),h=he}this.endGeometry(r)}else{var V=s.overflow?null:[];switch(g){case"Point":case"MultiPoint":C=t.getFlatCoordinates();break;case"LineString":C=t.getFlatMidpoint();break;case"Circle":C=t.getCenter();break;case"MultiLineString":C=t.getFlatMidpoints(),B=2;break;case"Polygon":C=t.getFlatInteriorPoint(),s.overflow||V.push(C[2]/this.resolution),B=3;break;case"MultiPolygon":var ae=t.getFlatInteriorPoints();C=[];for(var L=0,J=ae.length;L<J;L+=3)s.overflow||V.push(ae[L+2]/this.resolution),C.push(ae[L],ae[L+1]);if(C.length===0)return;B=2;break}var he=this.appendFlatPointCoordinates(C,B);if(he===h)return;if(V&&(he-h)/2!==C.length/B){var ye=h/2;V=V.filter(function(Yt,jt){var Xe=a[(ye+jt)*2]===C[jt*B]&&a[(ye+jt)*2+1]===C[jt*B+1];return Xe||--ye,Xe})}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 Oe=s.padding;if(Oe!=W0&&(s.scale[0]<0||s.scale[1]<0)){var De=s.padding[0],He=s.padding[1],ke=s.padding[2],nt=s.padding[3];s.scale[0]<0&&(He=-He,nt=-nt),s.scale[1]<0&&(De=-De,ke=-ke),Oe=[De,He,ke,nt]}var be=this.pixelRatio;this.instructions.push([li.DRAW_IMAGE,h,he,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[1,1],NaN,void 0,this.declutterImageWithText_,Oe==W0?W0:Oe.map(function(Yt){return Yt*be}),!!s.backgroundFill,!!s.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_,this.textOffsetX_,this.textOffsetY_,V]);var Bt=1/be;this.hitDetectionInstructions.push([li.DRAW_IMAGE,h,he,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[Bt,Bt],NaN,void 0,this.declutterImageWithText_,Oe,!!s.backgroundFill,!!s.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_,this.textOffsetX_,this.textOffsetY_,V]),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||gC,justify:r.justify,textBaseline:r.textBaseline||T3,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_,h=this.fillKey_;this.saveTextStates_();var g=this.pixelRatio,C=I_[o.textBaseline],B=this.textOffsetY_*g,k=this.text_,P=i?i.lineWidth*Math.abs(o.scale[0])/2:0;this.instructions.push([li.DRAW_CHARS,t,r,C,o.overflow,h,o.maxAngle,g,B,s,P*g,k,a,1]),this.hitDetectionInstructions.push([li.DRAW_CHARS,t,r,C,o.overflow,h,o.maxAngle,1,B,s,P,k,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=cf(a.getColor()||xp)):(o=null,this.textFillState_=o);var h=t.getStroke();if(!h)s=null,this.textStrokeState_=s;else{s=this.textStrokeState_,s||(s={},this.textStrokeState_=s);var g=h.getLineDash(),C=h.getLineDashOffset(),B=h.getWidth(),k=h.getMiterLimit();s.lineCap=h.getLineCap()||I3,s.lineDash=g?g.slice():hC,s.lineDashOffset=C===void 0?fC:C,s.lineJoin=h.getLineJoin()||By,s.lineWidth=B===void 0?yC:B,s.miterLimit=k===void 0?pC:k,s.strokeStyle=cf(h.getColor()||mC)}i=this.textState_;var P=t.getFont()||Sz;Sie(P);var L=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()||T3,i.backgroundFill=t.getBackgroundFill(),i.backgroundStroke=t.getBackgroundStroke(),i.padding=t.getPadding()||W0,i.scale=L===void 0?[1,1]:L;var J=t.getOffsetX(),N=t.getOffsetY(),$=t.getRotateWithView(),q=t.getRotation();this.text_=t.getText()||"",this.textOffsetX_=J===void 0?0:J,this.textOffsetY_=N===void 0?0:N,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}(ZC),Rae={Circle:iT,Default:ZC,Image:kae,LineString:Kae,Polygon:iT,Text:Uae},F3=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=Rae[t];o=new s(this.tolerance_,this.maxExtent_,this.resolution_,this.pixelRatio_),i[t]=o}return o},e}(),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(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 pi()},n.prototype.getData=function(t){return null},n.prototype.prepareFrame=function(t){return pi()},n.prototype.renderFrame=function(t,r){return pi()},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()===rs.LOADED&&this.renderIfReadyAndVisible()},n.prototype.loadImage=function(t){var r=t.getState();return r!=rs.LOADED&&r!=rs.ERROR&&t.addEventListener(Di.CHANGE,this.boundHandleImageChange_),r==rs.IDLE&&(t.load(),r=t.getState()),r==rs.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}(zR);const Wae=jae;var Nae=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)}}(),oT=[],Eg=null;function Gae(){var e=document.createElement("canvas");e.width=1,e.height=1,Eg=e.getContext("2d")}var Qae=function(e){Nae(n,e);function n(t){var r=e.call(this,t)||this;return r.container=null,r.renderedResolution,r.tempTransform=_d(),r.pixelTransform=_d(),r.inversePixelTransform=_d(),r.context=null,r.containerReused=!1,r.pixelContext_=null,r.frameState=null,r}return n.prototype.getImageData=function(t,r,i){Eg||Gae(),Eg.clearRect(0,0,1,1);var o;try{Eg.drawImage(t,r,i,1,1,0,0,1,1),o=Eg.getImageData(0,0,1,1).data}catch{return Eg=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(E3(t.style.backgroundColor),E3(i)))){var h=t.firstElementChild;h instanceof HTMLCanvasElement&&(a=h.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=ic();var h=a.canvas;s.appendChild(h),g=h.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=$m(i),s=d5(i),a=c5(i),h=A5(i);fl(r.coordinateToPixelTransform,o),fl(r.coordinateToPixelTransform,s),fl(r.coordinateToPixelTransform,a),fl(r.coordinateToPixelTransform,h);var g=this.inversePixelTransform;fl(g,o),fl(g,s),fl(g,a),fl(g,h),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(h[0]),Math.round(h[1])),t.clip()},n.prototype.dispatchRenderEvent_=function(t,r,i){var o=this.getLayer();if(o.hasListener(t)){var s=new xz(t,this.inversePixelTransform,i,r);o.dispatchEvent(s)}},n.prototype.preRender=function(t,r){this.frameState=r,this.dispatchRenderEvent_(Dm.PRERENDER,t,r)},n.prototype.postRender=function(t,r){this.dispatchRenderEvent_(Dm.POSTRENDER,t,r)},n.prototype.getRenderTransform=function(t,r,i,o,s,a,h){var g=s/2,C=a/2,B=o/r,k=-B,P=-t[0]+h,L=-t[1];return _f(this.tempTransform,g,C,B,k,-i,P,L)},n.prototype.getDataAtPixel=function(t,r,i){var o=fl(this.inversePixelTransform,t.slice()),s=this.context,a=this.getLayer(),h=a.getExtent();if(h){var g=fl(r.pixelToCoordinateTransform,t.slice());if(!$C(h,g))return null}var C=Math.round(o[0]),B=Math.round(o[1]),k=this.pixelContext_;if(!k){var P=document.createElement("canvas");P.width=1,P.height=1,k=P.getContext("2d"),this.pixelContext_=k}k.clearRect(0,0,1,1);var L;try{k.drawImage(s.canvas,C,B,1,1,0,0,1,1),L=k.getImageData(0,0,1,1).data}catch(J){return J.name==="SecurityError"?(this.pixelContext_=null,new Uint8Array):L}return L[3]===0?null:L},n.prototype.disposeInternal=function(){delete this.frameState,e.prototype.disposeInternal.call(this)},n}(Wae);const $z=Qae;function $ae(e,n,t,r,i,o,s,a,h,g,C,B){var k=e[n],P=e[n+1],L=0,J=0,N=0,$=0;function q(){L=k,J=P,n+=r,k=e[n],P=e[n+1],$+=N,N=Math.sqrt((k-L)*(k-L)+(P-J)*(P-J))}do q();while(n<t-r&&$+N<o);for(var oe=N===0?0:(o-$)/N,ce=dp(L,k,oe),me=dp(J,P,oe),he=n-r,V=$,ae=o+a*h(g,i,C);n<t-r&&$+N<ae;)q();oe=N===0?0:(ae-$)/N;var ye=dp(L,k,oe),Oe=dp(J,P,oe),De;if(B){var He=[ce,me,ye,Oe];rz(He,0,4,2,B,He,He),De=He[0]>He[2]}else De=ce>ye;var ke=Math.PI,nt=[],be=he+r===n;n=he,N=0,$=V,k=e[n],P=e[n+1];var Bt;if(be){q(),Bt=Math.atan2(P-J,k-L),De&&(Bt+=Bt>0?-ke:ke);var kt=(ye+ce)/2,Yt=(Oe+me)/2;return nt[0]=[kt,Yt,(ae-o)/2,Bt,i],nt}i=i.replace(/\n/g," ");for(var jt=0,Xe=i.length;jt<Xe;){q();var rt=Math.atan2(P-J,k-L);if(De&&(rt+=rt>0?-ke:ke),Bt!==void 0){var ot=rt-Bt;if(ot+=ot>ke?-2*ke:ot<-ke?2*ke:0,Math.abs(ot)>s)return null}Bt=rt;for(var on=jt,gt=0;jt<Xe;++jt){var at=De?Xe-jt-1:jt,It=a*h(g,i[at],C);if(n+r<t&&$+N<o+gt+It/2)break;gt+=It}if(jt!==on){var Lt=De?i.substring(Xe-on,Xe-jt):i.substring(on,jt);oe=N===0?0:(o+gt/2-$)/N;var kt=dp(L,k,oe),Yt=dp(J,P,oe);nt.push([kt,Yt,gt/2,rt,Lt]),o+=gt}}return nt}var cg=xd(),Zp=[],Jf=[],ep=[],Xp=[];function aT(e){return e[3].declutterBox}var Yae=new RegExp("[֑-ࣿיִ-﷿ﹰ-ﻼࠀ-࿿-]");function sT(e,n){return(n==="start"||n==="end")&&!Yae.test(e)&&(n=n==="start"?"left":"right"),I_[n]}function qae(e,n,t){return t>0&&e.push(`
`,""),e.push(n,""),e}var Hae=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_=_d(),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,h=this.textStates[t],g=this.pixelRatio,C=[h.scale[0]*g,h.scale[1]*g],B=Array.isArray(n),k=h.justify?I_[h.justify]:sT(Array.isArray(n)?n[0]:n,h.textAlign||gC),P=i&&s.lineWidth?s.lineWidth:0,L=B?n:n.split(`
`).reduce(qae,[]),J=Oie(h,L),N=J.width,$=J.height,q=J.widths,oe=J.heights,ce=J.lineWidths,me=N+P,he=[],V=(me+2)*C[0],ae=($+P)*C[1],ye={width:V<0?Math.floor(V):Math.ceil(V),height:ae<0?Math.floor(ae):Math.ceil(ae),contextInstructions:he};if((C[0]!=1||C[1]!=1)&&he.push("scale",C),i){he.push("strokeStyle",s.strokeStyle),he.push("lineWidth",P),he.push("lineCap",s.lineCap),he.push("lineJoin",s.lineJoin),he.push("miterLimit",s.miterLimit);var Oe=l5?OffscreenCanvasRenderingContext2D:CanvasRenderingContext2D;Oe.prototype.setLineDash&&(he.push("setLineDash",[s.lineDash]),he.push("lineDashOffset",s.lineDashOffset))}r&&he.push("fillStyle",a.fillStyle),he.push("textBaseline","middle"),he.push("textAlign","center");for(var De=.5-k,He=k*me+De*P,ke=[],nt=[],be=0,Bt=0,kt=0,Yt=0,jt,Xe=0,rt=L.length;Xe<rt;Xe+=2){var ot=L[Xe];if(ot===`
`){Bt+=be,be=0,He=k*me+De*P,++Yt;continue}var on=L[Xe+1]||h.font;on!==jt&&(i&&ke.push("font",on),r&&nt.push("font",on),jt=on),be=Math.max(be,oe[kt]);var gt=[ot,He+De*q[kt]+k*(q[kt]-ce[Yt]),.5*(P+be)+Bt];He+=q[kt],i&&ke.push("strokeText",gt),r&&nt.push("fillText",gt),++kt}return Array.prototype.push.apply(he,ke),Array.prototype.push.apply(he,nt),this.labels_[o]=ye,ye},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,h,g,C,B,k,P,L,J,N){a*=k[0],h*=k[1];var $=r-a,q=i-h,oe=o+g>n?n-g:o,ce=s+C>t?t-C:s,me=L[3]+oe*k[0]+L[1],he=L[0]+ce*k[1]+L[2],V=$-L[3],ae=q-L[0];(J||B!==0)&&(Zp[0]=V,Xp[0]=V,Zp[1]=ae,Jf[1]=ae,Jf[0]=V+me,ep[0]=Jf[0],ep[1]=ae+he,Xp[1]=ep[1]);var ye;return B!==0?(ye=_f(_d(),r,i,1,1,B,-r,-i),fl(ye,Zp),fl(ye,Jf),fl(ye,ep),fl(ye,Xp),Cf(Math.min(Zp[0],Jf[0],ep[0],Xp[0]),Math.min(Zp[1],Jf[1],ep[1],Xp[1]),Math.max(Zp[0],Jf[0],ep[0],Xp[0]),Math.max(Zp[1],Jf[1],ep[1],Xp[1]),cg)):Cf(Math.min(V,V+me),Math.min(ae,ae+he),Math.max(V,V+me),Math.max(ae,ae+he),cg),P&&($=Math.round($),q=Math.round(q)),{drawImageX:$,drawImageY:q,drawImageW:oe,drawImageH:ce,originX:g,originY:C,declutterBox:{minX:cg[0],minY:cg[1],maxX:cg[2],maxY:cg[3],value:N},canvasTransform:ye,scale:k}},e.prototype.replayImageOrLabel_=function(n,t,r,i,o,s,a){var h=!!(s||a),g=i.declutterBox,C=n.canvas,B=a?a[2]*i.scale[0]/2:0,k=g.minX-B<=C.width/t&&g.maxX+B>=0&&g.minY-B<=C.height/t&&g.maxY+B>=0;return k&&(h&&this.replayTextBackground_(n,Zp,Jf,ep,Xp,s,a),Bie(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=fl(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],h=this.pixelRatio,g=sT(Array.isArray(n)?n[0]:n,o.textAlign||gC),C=I_[o.textBaseline||T3],B=a&&a.lineWidth?a.lineWidth:0,k=s.width/h-2*o.scale[0],P=g*k+2*(.5-g)*B,L=C*s.height/h+2*(.5-C)*B;return{label:s,anchorX:P,anchorY:L}},e.prototype.execute_=function(n,t,r,i,o,s,a,h){var g;this.pixelCoordinates_&&_1(r,this.renderedTransform_)?g=this.pixelCoordinates_:(this.pixelCoordinates_||(this.pixelCoordinates_=[]),g=Fm(this.coordinates,0,this.coordinates.length,2,r,this.pixelCoordinates_),$te(this.renderedTransform_,r));for(var C=0,B=i.length,k=0,P,L,J,N,$,q,oe,ce,me,he,V,ae,ye=0,Oe=0,De=null,He=null,ke=this.coordinateCache_,nt=this.viewRotation_,be=Math.round(Math.atan2(-r[1],r[0])*1e12)/1e12,Bt={context:n,pixelRatio:this.pixelRatio,resolution:this.resolution,rotation:nt},kt=this.instructions!=i||this.overlaps?0:200,Yt,jt,Xe,rt;C<B;){var ot=i[C],on=ot[0];switch(on){case li.BEGIN_GEOMETRY:Yt=ot[1],rt=ot[3],Yt.getGeometry()?a!==void 0&&!pl(a,rt.getExtent())?C=ot[2]+1:++C:C=ot[2];break;case li.BEGIN_PATH:ye>kt&&(this.fill_(n),ye=0),Oe>kt&&(n.stroke(),Oe=0),!ye&&!Oe&&(n.beginPath(),N=NaN,$=NaN),++C;break;case li.CIRCLE:k=ot[1];var gt=g[k],at=g[k+1],It=g[k+2],Lt=g[k+3],Me=It-gt,fe=Lt-at,xe=Math.sqrt(Me*Me+fe*fe);n.moveTo(gt+xe,at),n.arc(gt,at,xe,0,2*Math.PI,!0),++C;break;case li.CLOSE_PATH:n.closePath(),++C;break;case li.CUSTOM:k=ot[1],P=ot[2];var Ue=ot[3],et=ot[4],it=ot.length==6?ot[5]:void 0;Bt.geometry=Ue,Bt.feature=Yt,C in ke||(ke[C]=[]);var bt=ke[C];it?it(g,k,P,2,bt):(bt[0]=g[k],bt[1]=g[k+1],bt.length=2),et(bt,Bt),++C;break;case li.DRAW_IMAGE:k=ot[1],P=ot[2],ce=ot[3],L=ot[4],J=ot[5];var Ut=ot[6],Rt=ot[7],pt=ot[8],rr=ot[9],mn=ot[10],vn=ot[11],Xn=ot[12],cr=ot[13],Mr=ot[14],Gr=ot[15];if(!ce&&ot.length>=20){me=ot[19],he=ot[20],V=ot[21],ae=ot[22];var gr=this.drawLabelWithPointPlacement_(me,he,V,ae);ce=gr.label,ot[3]=ce;var mi=ot[23];L=(gr.anchorX-mi)*this.pixelRatio,ot[4]=L;var Se=ot[24];J=(gr.anchorY-Se)*this.pixelRatio,ot[5]=J,Ut=ce.height,ot[6]=Ut,cr=ce.width,ot[13]=cr}var X=void 0;ot.length>25&&(X=ot[25]);var H=void 0,Te=void 0,At=void 0;ot.length>17?(H=ot[16],Te=ot[17],At=ot[18]):(H=W0,Te=!1,At=!1),mn&&be?vn+=nt:!mn&&!be&&(vn-=nt);for(var St=0;k<P;k+=2)if(!(X&&X[St++]<cr/this.pixelRatio)){var Et=this.calculateImageOrLabelDimensions_(ce.width,ce.height,g[k],g[k+1],cr,Ut,L,J,pt,rr,vn,Xn,o,H,Te||At,Yt),Nt=[n,t,ce,Et,Rt,Te?De:null,At?He:null];if(h){if(Mr==="none")continue;if(Mr==="obstacle"){h.insert(Et.declutterBox);continue}else{var pn=void 0,Kn=void 0;if(Gr){var En=P-k;if(!Gr[En]){Gr[En]=Nt;continue}if(pn=Gr[En],delete Gr[En],Kn=aT(pn),h.collides(Kn))continue}if(h.collides(Et.declutterBox))continue;pn&&(h.insert(Kn),this.replayImageOrLabel_.apply(this,pn)),h.insert(Et.declutterBox)}}this.replayImageOrLabel_.apply(this,Nt)}++C;break;case li.DRAW_CHARS:var m=ot[1],Kt=ot[2],Dr=ot[3],Fn=ot[4];ae=ot[5];var Fe=ot[6],de=ot[7],Ce=ot[8];V=ot[9];var Be=ot[10];me=ot[11],he=ot[12];var ze=[ot[13],ot[13]],tt=this.textStates[he],lt=tt.font,ft=[tt.scale[0]*de,tt.scale[1]*de],Ve=void 0;lt in this.widths_?Ve=this.widths_[lt]:(Ve={},this.widths_[lt]=Ve);var xt=Az(g,m,Kt,2),Xt=Math.abs(ft[0])*Y9(lt,me,Ve);if(Fn||Xt<=xt){var Vt=this.textStates[he].textAlign,Ht=(xt-Xt)*I_[Vt],Qn=$ae(g,m,Kt,2,me,Ht,Fe,Math.abs(ft[0]),Y9,lt,Ve,be?0:this.viewRotation_);e:if(Qn){var Mn=[],or=void 0,ar=void 0,kr=void 0,jr=void 0,Lr=void 0;if(V)for(or=0,ar=Qn.length;or<ar;++or){Lr=Qn[or],kr=Lr[4],jr=this.createLabel(kr,he,"",V),L=Lr[2]+(ft[0]<0?-Be:Be),J=Dr*jr.height+(.5-Dr)*2*Be*ft[1]/ft[0]-Ce;var Et=this.calculateImageOrLabelDimensions_(jr.width,jr.height,Lr[0],Lr[1],jr.width,jr.height,L,J,0,0,Lr[3],ze,!1,W0,!1,Yt);if(h&&h.collides(Et.declutterBox))break e;Mn.push([n,t,jr,Et,1,null,null])}if(ae)for(or=0,ar=Qn.length;or<ar;++or){Lr=Qn[or],kr=Lr[4],jr=this.createLabel(kr,he,ae,""),L=Lr[2],J=Dr*jr.height-Ce;var Et=this.calculateImageOrLabelDimensions_(jr.width,jr.height,Lr[0],Lr[1],jr.width,jr.height,L,J,0,0,Lr[3],ze,!1,W0,!1,Yt);if(h&&h.collides(Et.declutterBox))break e;Mn.push([n,t,jr,Et,1,null,null])}h&&h.load(Mn.map(aT));for(var Wr=0,ir=Mn.length;Wr<ir;++Wr)this.replayImageOrLabel_.apply(this,Mn[Wr])}}++C;break;case li.END_GEOMETRY:if(s!==void 0){Yt=ot[1];var ui=s(Yt,rt);if(ui)return ui}++C;break;case li.FILL:kt?ye++:this.fill_(n),++C;break;case li.MOVE_TO_LINE_TO:for(k=ot[1],P=ot[2],jt=g[k],Xe=g[k+1],q=jt+.5|0,oe=Xe+.5|0,(q!==N||oe!==$)&&(n.moveTo(jt,Xe),N=q,$=oe),k+=2;k<P;k+=2)jt=g[k],Xe=g[k+1],q=jt+.5|0,oe=Xe+.5|0,(k==P-2||q!==N||oe!==$)&&(n.lineTo(jt,Xe),N=q,$=oe);++C;break;case li.SET_FILL_STYLE:De=ot,this.alignFill_=ot[2],ye&&(this.fill_(n),ye=0,Oe&&(n.stroke(),Oe=0)),n.fillStyle=ot[1],++C;break;case li.SET_STROKE_STYLE:He=ot,Oe&&(n.stroke(),Oe=0),this.setStrokeStyle_(n,ot),++C;break;case li.STROKE:kt?Oe++:n.stroke(),++C;break;default:++C;break}}ye&&this.fill_(n),Oe&&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 Vae=Hae;var SM=["Polygon","Circle","LineString","Image","Text","Default"],Zae=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_=_d(),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 Vae(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,h=_f(this.hitDetectionTransform_,i+.5,i+.5,1/t,-1/t,-r,-n[0],-n[1]),g=!this.hitDetectionContext_;g&&(this.hitDetectionContext_=ic(a,a));var C=this.hitDetectionContext_;C.canvas.width!==a||C.canvas.height!==a?(C.canvas.width=a,C.canvas.height=a):g||C.clearRect(0,0,a,a);var B;this.renderBuffer_!==void 0&&(B=xd(),k_(B,n),Pm(B,t*(this.renderBuffer_+i),B));var k=Xae(i),P;function L(he,V){for(var ae=C.getImageData(0,0,a,a).data,ye=0,Oe=k.length;ye<Oe;ye++)if(ae[k[ye]]>0){if(!s||P!=="Image"&&P!=="Text"||s.indexOf(he)!==-1){var De=(k[ye]-3)/4,He=i-De%a,ke=i-(De/a|0),nt=o(he,V,He*He+ke*ke);if(nt)return nt}C.clearRect(0,0,a,a);break}}var J=Object.keys(this.executorsByZIndex_).map(Number);J.sort(A1);var N,$,q,oe,ce;for(N=J.length-1;N>=0;--N){var me=J[N].toString();for(q=this.executorsByZIndex_[me],$=SM.length-1;$>=0;--$)if(P=SM[$],oe=q[P],oe!==void 0&&(ce=oe.executeHitDetection(C,h,r,L,B),ce))return ce}},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 Fm(a,0,8,2,n,a),a},e.prototype.isEmpty=function(){return d1(this.executorsByZIndex_)},e.prototype.execute=function(n,t,r,i,o,s,a){var h=Object.keys(this.executorsByZIndex_).map(Number);h.sort(A1),this.maxExtent_&&(n.save(),this.clip(n,r));var g=s||SM,C,B,k,P,L,J;for(a&&h.reverse(),C=0,B=h.length;C<B;++C){var N=h[C].toString();for(L=this.executorsByZIndex_[N],k=0,P=g.length;k<P;++k){var $=g[k];J=L[$],J!==void 0&&J.execute(n,t,r,i,o,a)}}this.maxExtent_&&n.restore()},e}(),EM={};function Xae(e){if(EM[e]!==void 0)return EM[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 h=[],i=0,g=r.length;i<g;++i)r[i]&&h.push.apply(h,r[i]);return EM[e]=h,h}const D3=Zae;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,r,i,o,s,a,h){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_=h,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_=_d(),g}return n.prototype.drawImages_=function(t,r,i,o){if(this.image_){var s=Fm(t,r,i,o,this.transform_,this.pixelCoordinates_),a=this.context_,h=this.tmpLocalTransform_,g=a.globalAlpha;this.imageOpacity_!=1&&(a.globalAlpha=g*this.imageOpacity_);var C=this.imageRotation_;this.imageRotateWithView_&&(C+=this.viewRotation_);for(var B=0,k=s.length;B<k;B+=2){var P=s[B]-this.imageAnchorX_,L=s[B+1]-this.imageAnchorY_;if(C!==0||this.imageScale_[0]!=1||this.imageScale_[1]!=1){var J=P+this.imageAnchorX_,N=L+this.imageAnchorY_;_f(h,J,N,1,1,C,-J,-N),a.setTransform.apply(a,h),a.translate(J,N),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,L,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=Fm(t,r,i,o,this.transform_,this.pixelCoordinates_),a=this.context_,h=this.textRotation_;for(this.textRotateWithView_&&(h+=this.viewRotation_);r<i;r+=o){var g=s[r]+this.textOffsetX_,C=s[r+1]+this.textOffsetY_;if(h!==0||this.textScale_[0]!=1||this.textScale_[1]!=1){var B=_f(this.tmpLocalTransform_,g,C,1,1,h,-g,-C);a.setTransform.apply(a,B),a.translate(g,C),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,C),this.textFillState_&&a.fillText(this.text_,g,C)}}},n.prototype.moveToLineTo_=function(t,r,i,o,s){var a=this.context_,h=Fm(t,r,i,o,this.transform_,this.pixelCoordinates_);a.moveTo(h[0],h[1]);var g=h.length;s&&(g-=2);for(var C=2;C<g;C+=2)a.lineTo(h[C],h[C+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(pl(this.extent_,t.getExtent())){if(this.fillState_||this.strokeState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);var r=Wne(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||!pl(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_)),!!pl(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(pl(this.extent_,r)){if(this.strokeState_){this.setContextStrokeState_(this.strokeState_);var i=this.context_,o=t.getFlatCoordinates(),s=0,a=t.getEnds(),h=t.getStride();i.beginPath();for(var g=0,C=a.length;g<C;++g)s=this.moveToLineTo_(o,s,a[g],h,!1);i.stroke()}if(this.text_!==""){var B=t.getFlatMidpoints();this.drawText_(B,0,B.length,2)}}},n.prototype.drawPolygon=function(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),!!pl(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_)),!!pl(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 h=0,g=s.length;h<g;++h){var C=s[h];o=this.drawRings_(i,o,C,a)}this.fillState_&&r.fill(),this.strokeState_&&r.stroke()}if(this.text_!==""){var B=t.getFlatInteriorPoints();this.drawText_(B,0,B.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:gC;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:cf(o||xp)}}if(!r)this.strokeState_=null;else{var s=r.getColor(),a=r.getLineCap(),h=r.getLineDash(),g=r.getLineDashOffset(),C=r.getLineJoin(),B=r.getWidth(),k=r.getMiterLimit(),P=h||hC;this.strokeState_={lineCap:a!==void 0?a:I3,lineDash:this.pixelRatio_===1?P:P.map(function(L){return L*i.pixelRatio_}),lineDashOffset:(g||fC)*this.pixelRatio_,lineJoin:C!==void 0?C:By,lineWidth:(B!==void 0?B:yC)*this.pixelRatio_,miterLimit:k!==void 0?k:pC,strokeStyle:cf(s||mC)}}},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:cf(i||xp)}}var o=t.getStroke();if(!o)this.textStrokeState_=null;else{var s=o.getColor(),a=o.getLineCap(),h=o.getLineDash(),g=o.getLineDashOffset(),C=o.getLineJoin(),B=o.getWidth(),k=o.getMiterLimit();this.textStrokeState_={lineCap:a!==void 0?a:I3,lineDash:h||hC,lineDashOffset:g||fC,lineJoin:C!==void 0?C:By,lineWidth:B!==void 0?B:yC,miterLimit:k!==void 0?k:pC,strokeStyle:cf(s||mC)}}var P=t.getFont(),L=t.getOffsetX(),J=t.getOffsetY(),N=t.getRotateWithView(),$=t.getRotation(),q=t.getScaleArray(),oe=t.getText(),ce=t.getTextAlign(),me=t.getTextBaseline();this.textState_={font:P!==void 0?P:Sz,textAlign:ce!==void 0?ce:gC,textBaseline:me!==void 0?me:T3},this.text_=oe!==void 0?Array.isArray(oe)?oe.reduce(function(he,V,ae){return he+=ae%2?" ":V},""):oe:"",this.textOffsetX_=L!==void 0?this.pixelRatio_*L:0,this.textOffsetY_=J!==void 0?this.pixelRatio_*J:0,this.textRotateWithView_=N!==void 0?N:!1,this.textRotation_=$!==void 0?$:0,this.textScale_=[this.pixelRatio_*q[0],this.pixelRatio_*q[1]]}},n}(Gz);const sm={FRACTION:"fraction",PIXELS:"pixels"},Ad={BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",TOP_LEFT:"top-left",TOP_RIGHT:"top-right"};var tse=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)}}(),nse=function(e){tse(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(Di.CHANGE)},n.prototype.getExtent=function(){return this.extent},n.prototype.getImage=function(){return pi()},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(){pi()},n}(Gy);const rse=nse;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)}}();(function(e){ise(n,e);function n(t,r,i,o,s,a){var h=e.call(this,t,r,i,rs.IDLE)||this;return h.src_=o,h.image_=new Image,s!==null&&(h.image_.crossOrigin=s),h.unlisten_=null,h.state=rs.IDLE,h.imageLoadFunction_=a,h}return n.prototype.getImage=function(){return this.image_},n.prototype.handleImageError_=function(){this.state=rs.ERROR,this.unlistenImage_(),this.changed()},n.prototype.handleImageLoad_=function(){this.resolution===void 0&&(this.resolution=rc(this.extent)/this.image_.height),this.state=rs.LOADED,this.unlistenImage_(),this.changed()},n.prototype.load=function(){(this.state==rs.IDLE||this.state==rs.ERROR)&&(this.state=rs.LOADING,this.changed(),this.imageLoadFunction_(this,this.src_),this.unlisten_=O7(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))},n.prototype.setImage=function(t){this.image_=t,this.resolution=rc(this.extent)/this.image_.height},n.prototype.unlistenImage_=function(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)},n})(rse);function O7(e,n,t){var r=e,i=!0,o=!1,s=!1,a=[C3(r,Di.LOAD,function(){s=!0,o||n()})];return r.src&&Qte?(o=!0,r.decode().then(function(){i&&n()}).catch(function(h){i&&(s?n():t())})):a.push(C3(r,Di.ERROR,t)),function(){i=!1,a.forEach(is)}}var ose=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)}}(),jv=null,ase=function(e){ose(n,e);function n(t,r,i,o,s,a){var h=e.call(this)||this;return h.hitDetectionImage_=null,h.image_=t||new Image,o!==null&&(h.image_.crossOrigin=o),h.canvas_={},h.color_=a,h.unlisten_=null,h.imageState_=s,h.size_=i,h.src_=r,h.tainted_,h}return n.prototype.isTainted_=function(){if(this.tainted_===void 0&&this.imageState_===rs.LOADED){jv||(jv=ic(1,1)),jv.drawImage(this.image_,0,0);try{jv.getImageData(0,0,1,1),this.tainted_=!1}catch{jv=null,this.tainted_=!0}}return this.tainted_===!0},n.prototype.dispatchChangeEvent_=function(){this.dispatchEvent(Di.CHANGE)},n.prototype.handleImageError_=function(){this.imageState_=rs.ERROR,this.unlistenImage_(),this.dispatchChangeEvent_()},n.prototype.handleImageLoad_=function(){this.imageState_=rs.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=ic(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_==rs.IDLE){this.imageState_=rs.LOADING;try{this.image_.src=this.src_}catch{this.handleImageError_()}this.unlisten_=O7(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this))}},n.prototype.replaceColor_=function(t){if(!(!this.color_||this.canvas_[t]||this.imageState_!==rs.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=_z(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,h=this.color_[1]/255,g=this.color_[2]/255,C=this.color_[3],B=0,k=s.length;B<k;B+=4)s[B]*=a,s[B+1]*=h,s[B+2]*=g,s[B+3]*=C;i.putImageData(o,0,0)}}},n.prototype.unlistenImage_=function(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)},n}(Gy);function sse(e,n,t,r,i,o){var s=O3.get(n,r,o);return s||(s=new ase(e,n,t,r,i,o),O3.set(n,r,o,s)),s}var lse=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)}}(),use=function(e){lse(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,h=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:h,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:Ad.TOP_LEFT,r.anchorXUnits_=i.anchorXUnits!==void 0?i.anchorXUnits:sm.FRACTION,r.anchorYUnits_=i.anchorYUnits!==void 0?i.anchorYUnits:sm.FRACTION,r.crossOrigin_=i.crossOrigin!==void 0?i.crossOrigin:null;var g=i.img!==void 0?i.img:null;r.imgSize_=i.imgSize;var C=i.src;ho(!(C!==void 0&&g),4),ho(!g||g&&r.imgSize_,5),(C===void 0||C.length===0)&&g&&(C=g.src||$i(g)),ho(C!==void 0&&C.length>0,6);var B=i.src!==void 0?rs.IDLE:rs.LOADED;return r.color_=i.color!==void 0?E3(i.color):null,r.iconImage_=sse(g,C,r.imgSize_!==void 0?r.imgSize_:null,r.crossOrigin_,B,r.color_),r.offset_=i.offset!==void 0?i.offset:[0,0],r.offsetOrigin_=i.offsetOrigin!==void 0?i.offsetOrigin:Ad.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_==sm.FRACTION||this.anchorYUnits_==sm.FRACTION){if(!r)return null;t=this.anchor_.slice(),this.anchorXUnits_==sm.FRACTION&&(t[0]*=r[0]),this.anchorYUnits_==sm.FRACTION&&(t[1]*=r[1])}if(this.anchorOrigin_!=Ad.TOP_LEFT){if(!r)return null;t===this.anchor_&&(t=this.anchor_.slice()),(this.anchorOrigin_==Ad.TOP_RIGHT||this.anchorOrigin_==Ad.BOTTOM_RIGHT)&&(t[0]=-t[0]+r[0]),(this.anchorOrigin_==Ad.BOTTOM_LEFT||this.anchorOrigin_==Ad.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_!=Ad.TOP_LEFT){var r=this.getSize(),i=this.iconImage_.getSize();if(!r||!i)return null;t=t.slice(),(this.offsetOrigin_==Ad.TOP_RIGHT||this.offsetOrigin_==Ad.BOTTOM_RIGHT)&&(t[0]=i[0]-r[0]-t[0]),(this.offsetOrigin_==Ad.BOTTOM_LEFT||this.offsetOrigin_==Ad.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(Di.CHANGE,t)},n.prototype.load=function(){this.iconImage_.load()},n.prototype.unlistenImageChange=function(t){this.iconImage_.removeEventListener(Di.CHANGE,t)},n}(jz);const Yz=use;var Ase="#333",cse=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_=SA(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 zg({color:Ase}),this.maxAngle_=t.maxAngle!==void 0?t.maxAngle:Math.PI/4,this.placement_=t.placement!==void 0?t.placement:Qz.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_=SA(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}(),Pc=.5;function qz(e,n,t,r,i,o,s){var a=e[0]*Pc,h=e[1]*Pc,g=ic(a,h);g.imageSmoothingEnabled=!1;for(var C=g.canvas,B=new ese(g,Pc,i,null,s),k=t.length,P=Math.floor((256*256*256-1)/k),L={},J=1;J<=k;++J){var N=t[J-1],$=N.getStyleFunction()||r;if(r){var q=$(N,o);if(q){Array.isArray(q)||(q=[q]);for(var oe=J*P,ce="#"+("000000"+oe.toString(16)).slice(-6),me=0,he=q.length;me<he;++me){var V=q[me],ae=V.getGeometryFunction()(N);if(!(!ae||!pl(i,ae.getExtent()))){var ye=V.clone(),Oe=ye.getFill();Oe&&Oe.setColor(ce);var De=ye.getStroke();De&&(De.setColor(ce),De.setLineDash(null)),ye.setText(void 0);var He=V.getImage();if(He&&He.getOpacity()!==0){var ke=He.getImageSize();if(!ke)continue;var nt=ic(ke[0],ke[1],void 0,{alpha:!1}),be=nt.canvas;nt.fillStyle=ce,nt.fillRect(0,0,be.width,be.height),ye.setImage(new Yz({img:be,imgSize:ke,anchor:He.getAnchor(),anchorXUnits:sm.PIXELS,anchorYUnits:sm.PIXELS,offset:He.getOrigin(),opacity:1,size:He.getSize(),scale:He.getScale(),rotation:He.getRotation(),rotateWithView:He.getRotateWithView()}))}var Bt=ye.getZIndex()||0,kt=L[Bt];kt||(kt={},L[Bt]=kt,kt.Polygon=[],kt.Circle=[],kt.LineString=[],kt.Point=[]),kt[ae.getType().replace("Multi","")].push(ae,ye)}}}}}for(var Yt=Object.keys(L).map(Number).sort(A1),J=0,jt=Yt.length;J<jt;++J){var kt=L[Yt[J]];for(var Xe in kt)for(var rt=kt[Xe],me=0,he=rt.length;me<he;me+=2){B.setStyle(rt[me+1]);for(var ot=0,on=n.length;ot<on;++ot)B.setTransform(n[ot]),B.drawGeometry(rt[me])}}return g.getImageData(0,0,C.width,C.height)}function Hz(e,n,t){var r=[];if(t){var i=Math.floor(Math.round(e[0])*Pc),o=Math.floor(Math.round(e[1])*Pc),s=(Fl(i,0,t.width-1)+Fl(o,0,t.height-1)*t.width)*4,a=t.data[s],h=t.data[s+1],g=t.data[s+2],C=g+256*(h+256*a),B=Math.floor((256*256*256-1)/n.length);C&&C%B===0&&r.push(n[C/B-1])}return r}var dse=.5,Vz={Point:_se,LineString:gse,Polygon:bse,MultiPoint:Cse,MultiLineString:yse,MultiPolygon:vse,GeometryCollection:mse,Circle:fse};function hse(e,n){return parseInt($i(e),10)-parseInt($i(n),10)}function Zz(e,n){var t=mE(e,n);return t*t}function mE(e,n){return dse*e/n}function fse(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 h=t.getText();if(h&&h.getText()){var g=(i||e).getBuilder(t.getZIndex(),"Text");g.setTextStyle(h),g.drawText(n,r)}}function L3(e,n,t,r,i,o,s){var a=!1,h=t.getImage();if(h){var g=h.getImageState();g==rs.LOADED||g==rs.ERROR?h.unlistenImageChange(i):(g==rs.IDLE&&h.load(),h.listenImageChange(i),a=!0)}return pse(e,n,t,r,o,s),a}function pse(e,n,t,r,i,o){var s=t.getGeometryFunction()(n);if(s){var a=s.simplifyTransformed(r,i),h=t.getRenderer();if(h)Xz(e,a,t,n);else{var g=Vz[a.getType()];g(e,a,t,n,o)}}}function Xz(e,n,t,r){if(n.getType()=="GeometryCollection"){for(var i=n.getGeometries(),o=0,s=i.length;o<s;++o)Xz(e,i[o],t,r);return}var a=e.getBuilder(t.getZIndex(),"Default");a.drawCustom(n,r,t.getRenderer(),t.getHitDetectionRenderer())}function mse(e,n,t,r,i){var o=n.getGeometriesArray(),s,a;for(s=0,a=o.length;s<a;++s){var h=Vz[o[s].getType()];h(e,o[s],t,r,i)}}function gse(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 h=(i||e).getBuilder(t.getZIndex(),"Text");h.setTextStyle(a),h.drawText(n,r)}}function yse(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 h=(i||e).getBuilder(t.getZIndex(),"Text");h.setTextStyle(a),h.drawText(n,r)}}function vse(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 h=t.getText();if(h&&h.getText()){var g=(i||e).getBuilder(t.getZIndex(),"Text");g.setTextStyle(h),g.drawText(n,r)}}function _se(e,n,t,r,i){var o=t.getImage(),s=t.getText(),a;if(o){if(o.getImageState()!=rs.LOADED)return;var h=e;if(i){var g=o.getDeclutterMode();if(g!=="none")if(h=i,g==="obstacle"){var C=e.getBuilder(t.getZIndex(),"Image");C.setImageStyle(o,a),C.drawPoint(n,r)}else s&&s.getText()&&(a={})}var B=h.getBuilder(t.getZIndex(),"Image");B.setImageStyle(o,a),B.drawPoint(n,r)}if(s&&s.getText()){var k=e;i&&(k=i);var P=k.getBuilder(t.getZIndex(),"Text");P.setTextStyle(s,a),P.drawText(n,r)}}function Cse(e,n,t,r,i){var o=t.getImage(),s=t.getText(),a;if(o){if(o.getImageState()!=rs.LOADED)return;var h=e;if(i){var g=o.getDeclutterMode();if(g!=="none")if(h=i,g==="obstacle"){var C=e.getBuilder(t.getZIndex(),"Image");C.setImageStyle(o,a),C.drawMultiPoint(n,r)}else s&&s.getText()&&(a={})}var B=h.getBuilder(t.getZIndex(),"Image");B.setImageStyle(o,a),B.drawMultiPoint(n,r)}if(s&&s.getText()){var k=e;i&&(k=i);var P=k.getBuilder(t.getZIndex(),"Text");P.setTextStyle(s,a),P.drawText(n,r)}}function bse(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 h=t.getText();if(h&&h.getText()){var g=(i||e).getBuilder(t.getZIndex(),"Text");g.setTextStyle(h),g.drawText(n,r)}}var xse=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)}}(),wse=function(e){xse(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_=xd(),r.wrappedRenderedExtent_=xd(),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,h=s.resolution,g=s.projection,C=s.rotation,B=g.getExtent(),k=this.getLayer().getSource(),P=r.pixelRatio,L=r.viewHints,J=!(L[il.ANIMATING]||L[il.INTERACTING]),N=this.compositionContext_,$=Math.round(r.size[0]*P),q=Math.round(r.size[1]*P),oe=k.getWrapX()&&g.canWrapX(),ce=oe?ys(B):null,me=oe?Math.ceil((o[2]-B[2])/ce)+1:1,he=oe?Math.floor((o[0]-B[0])/ce):0;do{var V=this.getRenderTransform(a,h,C,P,$,q,he*ce);t.execute(N,1,V,C,J,void 0,i)}while(++he<me)},n.prototype.setupCompositionContext_=function(){if(this.opacity_!==1){var t=ic(this.context.canvas.width,this.context.canvas.height,oT);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,_7(this.compositionContext_),oT.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];Yte(this.pixelTransform,1/i,1/i),XB(this.inversePixelTransform,this.pixelTransform);var s=$R(this.pixelTransform);this.useContainer(r,s,this.getBackground(t));var a=this.context,h=a.canvas,g=this.replayGroup_,C=this.declutterExecutorGroup;if((!g||g.isEmpty())&&(!C||C.isEmpty()))return null;var B=Math.round(t.size[0]*i),k=Math.round(t.size[1]*i);h.width!=B||h.height!=k?(h.width=B,h.height=k,h.style.transform!==s&&(h.style.transform=s)):this.containerReused||a.clearRect(0,0,B,k),this.preRender(a,t);var P=t.viewState;P.projection,this.opacity_=o.opacity,this.setupCompositionContext_();var L=!1,J=!0;if(o.extent&&this.clipping){var N=z0(o.extent);J=pl(N,t.extent),L=J&&!ym(N,t.extent),L&&this.clipUnrotated(this.compositionContext_,t,N)}return J&&this.renderWorlds(g,t),L&&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];fl(this.pixelTransform,i);var o=this.renderedCenter_,s=this.renderedResolution_,a=this.renderedRotation_,h=this.renderedProjection_,g=this.wrappedRenderedExtent_,C=this.getLayer(),B=[],k=i[0]*Pc,P=i[1]*Pc;B.push(this.getRenderTransform(o,s,a,Pc,k,P,0).slice());var L=C.getSource(),J=h.getExtent();if(L.getWrapX()&&h.canWrapX()&&!ym(J,g)){for(var N=g[0],$=ys(J),q=0,oe=void 0;N<J[0];)--q,oe=$*q,B.push(this.getRenderTransform(o,s,a,Pc,k,P,oe).slice()),N+=$;for(q=0,N=g[2];N>J[2];)++q,oe=$*q,B.push(this.getRenderTransform(o,s,a,Pc,k,P,oe).slice()),N-=$}this.hitDetectionImageData_=qz(i,B,this.renderedFeatures_,C.getStyleFunction(),g,s,a)}r(Hz(t,this.renderedFeatures_,this.hitDetectionImageData_))}).bind(this))},n.prototype.forEachFeatureAtCoordinate=function(t,r,i,o,s){var a=this;if(this.replayGroup_){var h=r.viewState.resolution,g=r.viewState.rotation,C=this.getLayer(),B={},k=function(J,N,$){var q=$i(J),oe=B[q];if(oe){if(oe!==!0&&$<oe.distanceSq){if($===0)return B[q]=!0,s.splice(s.lastIndexOf(oe),1),o(J,C,N);oe.geometry=N,oe.distanceSq=$}}else{if($===0)return B[q]=!0,o(J,C,N);s.push(B[q]={feature:J,layer:C,geometry:N,distanceSq:$,callback:o})}},P,L=[this.replayGroup_];return this.declutterExecutorGroup&&L.push(this.declutterExecutorGroup),L.some(function(J){return P=J.forEachFeatureAtCoordinate(t,h,g,i,k,J===a.declutterExecutorGroup&&r.declutterTree?r.declutterTree.all().map(function(N){return N.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[il.ANIMATING],s=t.viewHints[il.INTERACTING],a=r.getUpdateWhileAnimating(),h=r.getUpdateWhileInteracting();if(this.ready&&!a&&o||!h&&s)return this.animatingOrInteracting_=!0,!0;this.animatingOrInteracting_=!1;var g=t.extent,C=t.viewState,B=C.projection,k=C.resolution,P=t.pixelRatio,L=r.getRevision(),J=r.getRenderBuffer(),N=r.getRenderOrder();N===void 0&&(N=hse);var $=C.center.slice(),q=Pm(g,J*k),oe=q.slice(),ce=[q.slice()],me=B.getExtent();if(i.getWrapX()&&B.canWrapX()&&!ym(me,t.extent)){var he=ys(me),V=Math.max(ys(q)/2,he);q[0]=me[0]-V,q[2]=me[2]+V,i7($,B);var ae=XR(ce[0],B);ae[0]<me[0]&&ae[2]<me[2]?ce.push([ae[0]+he,ae[1],ae[2]+he,ae[3]]):ae[0]>me[0]&&ae[2]>me[2]&&ce.push([ae[0]-he,ae[1],ae[2]-he,ae[3]])}if(this.ready&&this.renderedResolution_==k&&this.renderedRevision_==L&&this.renderedRenderOrder_==N&&ym(this.wrappedRenderedExtent_,q))return _1(this.renderedExtent_,oe)||(this.hitDetectionImageData_=null,this.renderedExtent_=oe),this.renderedCenter_=$,this.replayGroupChanged=!1,!0;this.replayGroup_=null;var ye=new F3(mE(k,P),q,k,P),Oe;this.getLayer().getDeclutter()&&(Oe=new F3(mE(k,P),q,k,P));for(var De,He,ke,He=0,ke=ce.length;He<ke;++He)i.loadFeatures(ce[He],k,B);var nt=Zz(k,P),be=!0,Bt=(function(rt){var ot,on=rt.getStyleFunction()||r.getStyleFunction();if(on&&(ot=on(rt,k)),ot){var gt=this.renderFeature(rt,nt,ot,ye,De,Oe);be=be&&!gt}}).bind(this),kt=nz(q),Yt=i.getFeaturesInExtent(kt);N&&Yt.sort(N);for(var He=0,ke=Yt.length;He<ke;++He)Bt(Yt[He]);this.renderedFeatures_=Yt,this.ready=be;var jt=ye.finish(),Xe=new D3(q,k,P,i.getOverlaps(),jt,r.getRenderBuffer());return Oe&&(this.declutterExecutorGroup=new D3(q,k,P,i.getOverlaps(),Oe.finish(),r.getRenderBuffer())),this.renderedResolution_=k,this.renderedRevision_=L,this.renderedRenderOrder_=N,this.renderedExtent_=oe,this.wrappedRenderedExtent_=q,this.renderedCenter_=$,this.renderedProjection_=B,this.replayGroup_=Xe,this.hitDetectionImageData_=null,this.replayGroupChanged=!0,!0},n.prototype.renderFeature=function(t,r,i,o,s,a){if(!i)return!1;var h=!1;if(Array.isArray(i))for(var g=0,C=i.length;g<C;++g)h=L3(o,t,i[g],r,this.boundHandleStyleImageChange_,s,a)||h;else h=L3(o,t,i,r,this.boundHandleStyleImageChange_,s,a);return h},n}($z);const Mse=wse;var Sse=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){Sse(n,e);function n(t){return e.call(this,t)||this}return n.prototype.createRenderer=function(){return new Mse(this)},n}(Nz);const Jz=Ese;var lT=function(){function e(n){this.rbush_=new zz(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],h={minX:s[0],minY:s[1],maxX:s[2],maxY:s[3],value:a};r[i]=h,this.items_[$i(a)]=h}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];Oy(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 d1(this.items_)},e.prototype.clear=function(){this.rbush_.clear(),this.items_={}},e.prototype.getExtent=function(n){var t=this.rbush_.toJSON();return Cf(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}(),Ose=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)}}(),Bse=function(e){Ose(n,e);function n(t){var r=e.call(this)||this;r.projection=qs(t.projection),r.attributions_=uT(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 pi()},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_=uT(t),this.changed()},n.prototype.setState=function(t){this.state_=t,this.changed()},n}(fh);function uT(e){return e?Array.isArray(e)?function(n){return e}:typeof e=="function"?e:function(n){return[e]}:null}const ej=Bse,rh={ADDFEATURE:"addfeature",CHANGEFEATURE:"changefeature",CLEAR:"clear",REMOVEFEATURE:"removefeature",FEATURESLOADSTART:"featuresloadstart",FEATURESLOADEND:"featuresloadend",FEATURESLOADERROR:"featuresloaderror"};function kse(e,n){return[[-1/0,-1/0,1/0,1/0]]}var Ise=!1;function tj(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=Ise,a.onload=function(h){if(!a.status||a.status>=200&&a.status<300){var g=n.getType(),C=void 0;g=="json"||g=="text"?C=a.responseText:g=="xml"?(C=a.responseXML,C||(C=new DOMParser().parseFromString(a.responseText,"application/xml"))):g=="arraybuffer"&&(C=a.response),C?o(n.readFeatures(C,{extent:t,featureProjection:i}),n.readProjection(C)):s()}else s()},a.onerror=s,a.send()}function AT(e,n){return function(t,r,i,o,s){var a=this;tj(e,n,t,r,i,function(h,g){a.addFeatures(h),o!==void 0&&o(h)},s||c1)}}var nj=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)}}(),Jp=function(e){nj(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.feature=r,o.features=i,o}return n}(Op),Tse=function(e){nj(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_=c1,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&&(ho(r.format_,7),r.loader_=AT(r.url_,r.format_)),r.strategy_=i.strategy!==void 0?i.strategy:kse;var o=i.useSpatialIndex!==void 0?i.useSpatialIndex:!0;r.featuresRtree_=o?new lT:null,r.loadedExtentsRtree_=new lT,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 yd(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 Jp(rh.ADDFEATURE,t))},n.prototype.setupChangeEvents_=function(t,r){this.featureChangeKeys_[t]=[ko(r,Di.CHANGE,this.handleFeatureChange_,this),ko(r,Ey.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&&(ho(!(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 h=t[s],g=$i(h);this.addToIndex_(g,h)&&i.push(h)}for(var s=0,C=i.length;s<C;s++){var h=i[s],g=$i(h);this.setupChangeEvents_(g,h);var B=h.getGeometry();if(B){var k=B.getExtent();r.push(k),o.push(h)}else this.nullGeometryFeatures_[g]=h}if(this.featuresRtree_&&this.featuresRtree_.load(r,o),this.hasListener(rh.ADDFEATURE))for(var s=0,P=i.length;s<P;s++)this.dispatchEvent(new Jp(rh.ADDFEATURE,i[s]))},n.prototype.bindFeaturesCollection_=function(t){var r=!1;this.addEventListener(rh.ADDFEATURE,function(i){r||(r=!0,t.push(i.feature),r=!1)}),this.addEventListener(rh.REMOVEFEATURE,function(i){r||(r=!0,t.remove(i.feature),r=!1)}),t.addEventListener(JA.ADD,(function(i){r||(r=!0,this.addFeature(i.element),r=!1)}).bind(this)),t.addEventListener(JA.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(is)}this.featuresCollection_||(this.featureChangeKeys_={},this.idIndex_={},this.uidIndex_={})}else if(this.featuresRtree_){var o=(function(h){this.removeFeatureInternal(h)}).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 Jp(rh.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(),d1(this.nullGeometryFeatures_)||mf(t,RR(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=nne(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],h=1/0,g=[-1/0,-1/0,1/0,1/0],C=r||oy;return this.featuresRtree_.forEachInExtent(g,function(B){if(C(B)){var k=B.getGeometry(),P=h;if(h=k.closestPointXY(i,o,a,h),h<P){s=B;var L=Math.sqrt(h);g[0]=i-L,g[1]=o-L,g[2]=i+L,g[3]=o+L}}}),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 h=a.toString();this.idIndex_[h]!==r&&(this.removeFromIdIndex_(r),this.idIndex_[h]=r)}else this.removeFromIdIndex_(r),this.uidIndex_[i]=r;this.changed(),this.dispatchEvent(new Jp(rh.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()&&d1(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(B,k){var P=s[B],L=o.forEachInExtent(P,function(J){return ym(J.extent,P)});L||(++h.loadingExtentsCount_,h.dispatchEvent(new Jp(rh.FEATURESLOADSTART)),h.loader_.call(h,P,r,i,(function(J){--this.loadingExtentsCount_,this.dispatchEvent(new Jp(rh.FEATURESLOADEND,void 0,J))}).bind(h),(function(){--this.loadingExtentsCount_,this.dispatchEvent(new Jp(rh.FEATURESLOADERROR))}).bind(h)),o.insert(P,{extent:P.slice()}))},h=this,g=0,C=s.length;g<C;++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(Oy(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(is),delete this.featureChangeKeys_[r];var o=t.getId();return o!==void 0&&delete this.idIndex_[o.toString()],delete this.uidIndex_[r],this.dispatchEvent(new Jp(rh.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){ho(this.format_,7),this.url_=t,this.setLoader(AT(t,this.format_))},n}(ej);const rj=Tse;function Kse(e){var n=e||{},t=new yd,r=new eae(-.005,.05,100),i=n.altShiftDragRotate!==void 0?n.altShiftDragRotate:!0;i&&t.push(new zoe);var o=n.doubleClickZoom!==void 0?n.doubleClickZoom:!0;o&&t.push(new Ooe({delta:n.zoomDelta,duration:n.zoomDuration}));var s=n.dragPan!==void 0?n.dragPan:!0;s&&t.push(new Uoe({onFocusOnly:n.onFocusOnly,kinetic:r}));var a=n.pinchRotate!==void 0?n.pinchRotate:!0;a&&t.push(new oae);var h=n.pinchZoom!==void 0?n.pinchZoom:!0;h&&t.push(new lae({duration:n.zoomDuration}));var g=n.keyboard!==void 0?n.keyboard:!0;g&&(t.push(new Voe),t.push(new Joe({delta:n.zoomDelta,duration:n.zoomDuration})));var C=n.mouseWheelZoom!==void 0?n.mouseWheelZoom:!0;C&&t.push(new rae({onFocusOnly:n.onFocusOnly,duration:n.zoomDuration}));var B=n.shiftDragZoom!==void 0?n.shiftDragZoom:!0;return B&&t.push(new qoe({duration:n.zoomDuration})),t}var Pse=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)}}(),B7=function(e){Pse(n,e);function n(t){return t=gl({},t),t.controls||(t.controls=boe()),t.interactions||(t.interactions=Kse({onFocusOnly:!0})),e.call(this,t)||this}return n.prototype.createRenderer=function(){return new Kie(this)},n}(loe),ij=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 dg(e,n,t,r,i){return i!==void 0?(i.minX=e,i.maxX=n,i.minY=t,i.maxY=r,i):new ij(e,n,t,r)}const oj=ij;function cT(e,n,t,r){return r!==void 0?(r[0]=e,r[1]=n,r[2]=t,r):[e,n,t]}function $y(e,n,t){return e+"/"+n+"/"+t}function aj(e){return $y(e[0],e[1],e[2])}function Fse(e){var n=e.substring(e.lastIndexOf("/")+1,e.length).split(",").map(Number),t=n[0],r=n[1],i=n[2];return $y(t,r,i)}function sj(e){return e.split("/").map(Number)}function Dse(e){return(e[1]<<e[0])+e[2]}function Lse(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 Use=[0,0,0],em=5,Rse=function(){function e(n){this.minZoom=n.minZoom!==void 0?n.minZoom:0,this.resolutions_=n.resolutions,ho(Bte(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,ho(this.origins_.length==this.resolutions_.length,20));var o=n.extent;o!==void 0&&!this.origin_&&!this.origins_&&(this.origin_=$m(o)),ho(!this.origin_&&this.origins_||this.origin_&&!this.origins_,18),this.tileSizes_=null,n.tileSizes!==void 0&&(this.tileSizes_=n.tileSizes,ho(this.tileSizes_.length==this.resolutions_.length,19)),this.tileSize_=n.tileSize!==void 0?n.tileSize:this.tileSizes_?null:C7,ho(!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 h=new oj(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);h.minX=Math.max(g.minX,h.minX),h.maxX=Math.min(g.maxX,h.maxX),h.minY=Math.max(g.minY,h.minY),h.maxY=Math.min(g.maxY,h.maxY)}return h},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,h=i.maxY;a<=h;++a)r([t,o,a])},e.prototype.forEachTileCoordParentTileRange=function(n,t,r,i){var o,s,a,h=null,g=n[0]-1;for(this.zoomFactor_===2?(s=n[1],a=n[2]):h=this.getTileCoordExtent(n,i);g>=this.minZoom;){if(this.zoomFactor_===2?(s=Math.floor(s/2),a=Math.floor(a/2),o=dg(s,s,a,a,r)):o=this.getTileRangeForExtentAndZ(h,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 dg(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 dg(o,s,o,s,r);if(this.zoomFactor_){var a=Math.pow(this.zoomFactor_,t-i),h=Math.floor(o*a),g=Math.floor(s*a);if(t<i)return dg(h,h,g,g,r);var C=Math.floor(a*(o+1))-1,B=Math.floor(a*(s+1))-1;return dg(h,C,g,B,r)}var k=this.getTileCoordExtent(n,this.tmpExtent_);return this.getTileRangeForExtentAndZ(k,t,r)},e.prototype.getTileRangeExtent=function(n,t,r){var i=this.getOrigin(n),o=this.getResolution(n),s=SA(this.getTileSize(n),this.tmpSize_),a=i[0]+t.minX*s[0]*o,h=i[0]+(t.maxX+1)*s[0]*o,g=i[1]+t.minY*s[1]*o,C=i[1]+(t.maxY+1)*s[1]*o;return Cf(a,g,h,C,r)},e.prototype.getTileRangeForExtentAndZ=function(n,t,r){var i=Use;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),dg(o,i[1],s,i[2],r)},e.prototype.getTileCoordCenter=function(n){var t=this.getOrigin(n[0]),r=this.getResolution(n[0]),i=SA(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=SA(this.getTileSize(n[0]),this.tmpSize_),s=r[0]+n[1]*o[0]*i,a=r[1]-(n[2]+1)*o[1]*i,h=s+o[0]*i,g=a+o[1]*i;return Cf(s,a,h,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),h=this.getOrigin(s),g=SA(this.getTileSize(s),this.tmpSize_),C=a*(n-h[0])/r/g[0],B=a*(h[1]-t)/r/g[1];return i?(C=bx(C,em)-1,B=bx(B,em)-1):(C=Cx(C,em),B=Cx(B,em)),cT(s,C,B,o)},e.prototype.getTileCoordForXYAndZ_=function(n,t,r,i,o){var s=this.getOrigin(r),a=this.getResolution(r),h=SA(this.getTileSize(r),this.tmpSize_),g=(n-s[0])/a/h[0],C=(s[1]-t)/a/h[1];return i?(g=bx(g,em)-1,C=bx(C,em)-1):(g=Cx(g,em),C=Cx(C,em)),cT(r,g,C,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=VB(this.resolutions_,n,t||0);return Fl(r,this.minZoom,this.maxZoom)},e.prototype.tileCoordIntersectsViewport=function(n,t){return lz(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 XC=Rse;var zse=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)}}(),jse=function(e){zse(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(Di.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(){pi()},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:Iz(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}(Gy);const v5=jse;var Wse=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)}}(),Nse=function(e){Wse(n,e);function n(t,r,i,o,s,a){var h=e.call(this,t,r,a)||this;return h.crossOrigin_=o,h.src_=i,h.key=i,h.image_=new Image,o!==null&&(h.image_.crossOrigin=o),h.unlisten_=null,h.tileLoadFunction_=s,h}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_=Gse(),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_=O7(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))},n.prototype.unlistenImage_=function(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)},n}(v5);function Gse(){var e=ic(1,1);return e.fillStyle="rgba(0,0,0,0)",e.fillRect(0,0,1,1),e.canvas}const lj=Nse;var Qse=.5,$se=10,dT=.25,Yse=function(){function e(n,t,r,i,o,s){this.sourceProj_=n,this.targetProj_=t;var a={},h=w3(this.targetProj_,this.sourceProj_);this.transformInv_=function(oe){var ce=oe[0]+"/"+oe[1];return a[ce]||(a[ce]=h(oe)),a[ce]},this.maxSourceExtent_=i,this.errorThresholdSquared_=o*o,this.triangles_=[],this.wrapsXInSource_=!1,this.canWrapXInSource_=this.sourceProj_.canWrapX()&&!!i&&!!this.sourceProj_.getExtent()&&ys(i)==ys(this.sourceProj_.getExtent()),this.sourceWorldWidth_=this.sourceProj_.getExtent()?ys(this.sourceProj_.getExtent()):null,this.targetWorldWidth_=this.targetProj_.getExtent()?ys(this.targetProj_.getExtent()):null;var g=$m(r),C=d5(r),B=c5(r),k=A5(r),P=this.transformInv_(g),L=this.transformInv_(C),J=this.transformInv_(B),N=this.transformInv_(k),$=$se+(s?Math.max(0,Math.ceil(one(Z6(r)/(s*s*256*256)))):0);if(this.addQuad_(g,C,B,k,P,L,J,N,$),this.wrapsXInSource_){var q=1/0;this.triangles_.forEach(function(oe,ce,me){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 ce=[[oe.source[0][0],oe.source[0][1]],[oe.source[1][0],oe.source[1][1]],[oe.source[2][0],oe.source[2][1]]];ce[0][0]-q>this.sourceWorldWidth_/2&&(ce[0][0]-=this.sourceWorldWidth_),ce[1][0]-q>this.sourceWorldWidth_/2&&(ce[1][0]-=this.sourceWorldWidth_),ce[2][0]-q>this.sourceWorldWidth_/2&&(ce[2][0]-=this.sourceWorldWidth_);var me=Math.min(ce[0][0],ce[1][0],ce[2][0]),he=Math.max(ce[0][0],ce[1][0],ce[2][0]);he-me<this.sourceWorldWidth_/2&&(oe.source=ce)}}).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,h,g){var C=H6([o,s,a,h]),B=this.sourceWorldWidth_?ys(C)/this.sourceWorldWidth_:null,k=this.sourceWorldWidth_,P=this.sourceProj_.canWrapX()&&B>.5&&B<1,L=!1;if(g>0){if(this.targetProj_.isGlobal()&&this.targetWorldWidth_){var J=H6([n,t,r,i]),N=ys(J)/this.targetWorldWidth_;L=N>dT||L}!P&&this.sourceProj_.isGlobal()&&B&&(L=B>dT||L)}if(!(!L&&this.maxSourceExtent_&&isFinite(C[0])&&isFinite(C[1])&&isFinite(C[2])&&isFinite(C[3])&&!pl(C,this.maxSourceExtent_))){var $=0;if(!L&&(!isFinite(o[0])||!isFinite(o[1])||!isFinite(s[0])||!isFinite(s[1])||!isFinite(a[0])||!isFinite(a[1])||!isFinite(h[0])||!isFinite(h[1]))){if(g>0)L=!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(h[0])||!isFinite(h[1])?1:0),$!=1&&$!=2&&$!=4&&$!=8)return}if(g>0){if(!L){var q=[(n[0]+r[0])/2,(n[1]+r[1])/2],oe=this.transformInv_(q),ce=void 0;if(P){var me=(J0(o[0],k)+J0(a[0],k))/2;ce=me-J0(oe[0],k)}else ce=(o[0]+a[0])/2-oe[0];var he=(o[1]+a[1])/2-oe[1],V=ce*ce+he*he;L=V>this.errorThresholdSquared_}if(L){if(Math.abs(n[0]-r[0])<=Math.abs(n[1]-r[1])){var ae=[(t[0]+r[0])/2,(t[1]+r[1])/2],ye=this.transformInv_(ae),Oe=[(i[0]+n[0])/2,(i[1]+n[1])/2],De=this.transformInv_(Oe);this.addQuad_(n,t,ae,Oe,o,s,ye,De,g-1),this.addQuad_(Oe,ae,r,i,De,ye,a,h,g-1)}else{var He=[(n[0]+t[0])/2,(n[1]+t[1])/2],ke=this.transformInv_(He),nt=[(r[0]+i[0])/2,(r[1]+i[1])/2],be=this.transformInv_(nt);this.addQuad_(n,He,nt,i,o,ke,be,h,g-1),this.addQuad_(He,t,r,nt,ke,s,a,be,g-1)}return}}if(P){if(!this.canWrapXInSource_)return;this.wrapsXInSource_=!0}$&11||this.addTriangle_(n,r,i,o,a,h),$&14||this.addTriangle_(n,r,t,o,a,s),$&&($&13||this.addTriangle_(t,i,n,s,h,o),$&7||this.addTriangle_(t,i,r,s,h,a))}},e.prototype.calculateSourceExtent=function(){var n=xd();return this.triangles_.forEach(function(t,r,i){var o=t.source;k_(n,o[0]),k_(n,o[1]),k_(n,o[2])}),n},e.prototype.getTriangles=function(){return this.triangles_},e}(),gE={imageSmoothingEnabled:!1,msImageSmoothingEnabled:!1},qse={imageSmoothingEnabled:!0,msImageSmoothingEnabled:!0},OM,uj=[];function hT(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 BM(e,n){return Math.abs(e[n*4]-210)>2||Math.abs(e[n*4+3]-.75*255)>2}function Hse(){if(OM===void 0){var e=document.createElement("canvas").getContext("2d");e.globalCompositeOperation="lighter",e.fillStyle="rgba(210, 0, 0, 0.75)",hT(e,4,5,4,0),hT(e,4,5,0,5);var n=e.getImageData(0,0,3,3).data;OM=BM(n,0)||BM(n,4)||BM(n,8)}return OM}function fT(e,n,t,r){var i=s7(t,n,e),o=B9(n,r,t),s=n.getMetersPerUnit();s!==void 0&&(o*=s);var a=e.getMetersPerUnit();a!==void 0&&(o/=a);var h=e.getExtent();if(!h||$C(h,i)){var g=B9(e,o,i)/o;isFinite(g)&&g>0&&(o/=g)}return o}function Vse(e,n,t,r){var i=Nm(t),o=fT(e,n,i,r);return(!isFinite(o)||o<=0)&&ZR(t,function(s){return o=fT(e,n,s,r),isFinite(o)&&o>0}),o}function Zse(e,n,t,r,i,o,s,a,h,g,C,B){var k=ic(Math.round(t*e),Math.round(t*n),uj);if(B||gl(k,gE),h.length===0)return k.canvas;k.scale(t,t);function P(ce){return Math.round(ce*t)/t}k.globalCompositeOperation="lighter";var L=xd();h.forEach(function(ce,me,he){HR(L,ce.extent)});var J=ys(L),N=rc(L),$=ic(Math.round(t*J/r),Math.round(t*N/r));B||gl($,gE);var q=t/r;h.forEach(function(ce,me,he){var V=ce.extent[0]-L[0],ae=-(ce.extent[3]-L[3]),ye=ys(ce.extent),Oe=rc(ce.extent);ce.image.width>0&&ce.image.height>0&&$.drawImage(ce.image,g,g,ce.image.width-2*g,ce.image.height-2*g,V*q,ae*q,ye*q,Oe*q)});var oe=$m(s);return a.getTriangles().forEach(function(ce,me,he){var V=ce.source,ae=ce.target,ye=V[0][0],Oe=V[0][1],De=V[1][0],He=V[1][1],ke=V[2][0],nt=V[2][1],be=P((ae[0][0]-oe[0])/o),Bt=P(-(ae[0][1]-oe[1])/o),kt=P((ae[1][0]-oe[0])/o),Yt=P(-(ae[1][1]-oe[1])/o),jt=P((ae[2][0]-oe[0])/o),Xe=P(-(ae[2][1]-oe[1])/o),rt=ye,ot=Oe;ye=0,Oe=0,De-=rt,He-=ot,ke-=rt,nt-=ot;var on=[[De,He,0,0,kt-be],[ke,nt,0,0,jt-be],[0,0,De,He,Yt-Bt],[0,0,ke,nt,Xe-Bt]],gt=sne(on);if(gt){if(k.save(),k.beginPath(),Hse()||!B){k.moveTo(kt,Yt);for(var at=4,It=be-kt,Lt=Bt-Yt,Me=0;Me<at;Me++)k.lineTo(kt+P((Me+1)*It/at),Yt+P(Me*Lt/(at-1))),Me!=at-1&&k.lineTo(kt+P((Me+1)*It/at),Yt+P((Me+1)*Lt/(at-1)));k.lineTo(jt,Xe)}else k.moveTo(kt,Yt),k.lineTo(be,Bt),k.lineTo(jt,Xe);k.clip(),k.transform(gt[0],gt[2],gt[1],gt[3],be,Bt),k.translate(L[0]-rt,L[3]-ot),k.scale(r/t,-r/t),k.drawImage($.canvas,0,0),k.restore()}}),C&&(k.save(),k.globalCompositeOperation="source-over",k.strokeStyle="black",k.lineWidth=1,a.getTriangles().forEach(function(ce,me,he){var V=ce.target,ae=(V[0][0]-oe[0])/o,ye=-(V[0][1]-oe[1])/o,Oe=(V[1][0]-oe[0])/o,De=-(V[1][1]-oe[1])/o,He=(V[2][0]-oe[0])/o,ke=-(V[2][1]-oe[1])/o;k.beginPath(),k.moveTo(Oe,De),k.lineTo(ae,ye),k.lineTo(He,ke),k.closePath(),k.stroke()}),k.restore()),k.canvas}var Xse=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)}}(),Jse=function(e){Xse(n,e);function n(t,r,i,o,s,a,h,g,C,B,k,P){var L=e.call(this,s,mr.IDLE,{interpolate:!!P})||this;L.renderEdges_=k!==void 0?k:!1,L.pixelRatio_=h,L.gutter_=g,L.canvas_=null,L.sourceTileGrid_=r,L.targetTileGrid_=o,L.wrappedTileCoord_=a||s,L.sourceTiles_=[],L.sourcesListenerKeys_=null,L.sourceZ_=0;var J=o.getTileCoordExtent(L.wrappedTileCoord_),N=L.targetTileGrid_.getExtent(),$=L.sourceTileGrid_.getExtent(),q=N?Z0(J,N):J;if(Z6(q)===0)return L.state=mr.EMPTY,L;var oe=t.getExtent();oe&&($?$=Z0($,oe):$=oe);var ce=o.getResolution(L.wrappedTileCoord_[0]),me=Vse(t,i,q,ce);if(!isFinite(me)||me<=0)return L.state=mr.EMPTY,L;var he=B!==void 0?B:Qse;if(L.triangulation_=new Yse(t,i,q,$,me*he,ce),L.triangulation_.getTriangles().length===0)return L.state=mr.EMPTY,L;L.sourceZ_=r.getZForResolution(me);var V=L.triangulation_.calculateSourceExtent();if($&&(t.canWrapX()?(V[1]=Fl(V[1],$[1],$[3]),V[3]=Fl(V[3],$[1],$[3])):V=Z0(V,$)),!Z6(V))L.state=mr.EMPTY;else{for(var ae=r.getTileRangeForExtentAndZ(V,L.sourceZ_),ye=ae.minX;ye<=ae.maxX;ye++)for(var Oe=ae.minY;Oe<=ae.maxY;Oe++){var De=C(L.sourceZ_,ye,Oe,h);De&&L.sourceTiles_.push(De)}L.sourceTiles_.length===0&&(L.state=mr.EMPTY)}return L}return n.prototype.getImage=function(){return this.canvas_},n.prototype.reproject_=function(){var t=[];if(this.sourceTiles_.forEach((function(C,B,k){C&&C.getState()==mr.LOADED&&t.push({extent:this.sourceTileGrid_.getTileCoordExtent(C.tileCoord),image:C.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),h=this.sourceTileGrid_.getResolution(this.sourceZ_),g=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);this.canvas_=Zse(o,s,this.pixelRatio_,h,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=ko(r,Di.CHANGE,function(h){var g=r.getState();(g==mr.LOADED||g==mr.ERROR||g==mr.EMPTY)&&(is(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(is),this.sourcesListenerKeys_=null},n.prototype.release=function(){this.canvas_&&(_7(this.canvas_.getContext("2d")),uj.push(this.canvas_),this.canvas_=null),e.prototype.release.call(this)},n}(v5);const Aj=Jse;var ele=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 ho(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 ho(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){ho(!(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 tle=ele;var nle=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)}}(),rle=function(e){nle(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=sj(t),i=r[0];this.forEach((function(o){o.tileCoord[0]!==i&&(this.remove(aj(o.tileCoord)),o.release())}).bind(this))}},n}(tle);const k7=rle,kM={TILELOADSTART:"tileloadstart",TILELOADEND:"tileloadend",TILELOADERROR:"tileloaderror"};function cj(e){var n=e.getDefaultTileGrid();return n||(n=ale(e),e.setDefaultTileGrid(n)),n}function ile(e,n,t){var r=n[0],i=e.getTileCoordCenter(n),o=_5(t);if($C(o,i))return n;var s=ys(o),a=Math.ceil((o[0]-i[0])/s);return i[0]+=s*a,e.getTileCoordForCoordAndZ(i,r)}function ole(e,n,t,r){var i=r!==void 0?r:"top-left",o=dj(e,n,t);return new XC({extent:e,origin:Xte(e,i),resolutions:o,tileSize:t})}function I7(e){var n=e||{},t=n.extent||qs("EPSG:3857").getExtent(),r={extent:t,minZoom:n.minZoom,tileSize:n.tileSize,resolutions:dj(t,n.maxZoom,n.tileSize,n.maxResolution)};return new XC(r)}function dj(e,n,t,r){for(var i=n!==void 0?n:kz,o=rc(e),s=ys(e),a=SA(t!==void 0?t:C7),h=r>0?r:Math.max(s/a[0],o/a[1]),g=i+1,C=new Array(g),B=0;B<g;++B)C[B]=h/Math.pow(2,B);return C}function ale(e,n,t,r){var i=_5(e);return ole(i,n,t,r)}function _5(e){e=qs(e);var n=e.getExtent();if(!n){var t=180*vf[OA.DEGREES]/e.getMetersPerUnit();n=Cf(-t,-t,t,t)}return n}var hj=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)}}(),sle=function(e){hj(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&&SA(r.tileGrid.getTileSize(r.tileGrid.getMinZoom()),i),r.tileCache=new k7(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,h,g,C,B=i.minX;B<=i.maxX;++B)for(var k=i.minY;k<=i.maxY;++k)g=$y(r,B,k),C=!1,s.containsKey(g)&&(h=s.get(g),C=h.getState()===mr.LOADED,C&&(C=o(h)!==!1)),C||(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 pi()},n.prototype.getTileGrid=function(){return this.tileGrid},n.prototype.getTileGridForProjection=function(t){return this.tileGrid?this.tileGrid:cj(t)},n.prototype.getTileCacheForProjection=function(t){var r=this.getProjection();return ho(r===null||k0(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=SA(o.getTileSize(t),this.tmpSize);return s==1?a:ioe(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=ile(o,t,i)),Lse(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}(ej),lle=function(e){hj(n,e);function n(t,r){var i=e.call(this,t)||this;return i.tile=r,i}return n}(Op);const ule=sle;function Ale(e,n){var t=/\{z\}/g,r=/\{x\}/g,i=/\{y\}/g,o=/\{-y\}/g;return function(s,a,h){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],C=n.getFullTileRange(g);ho(C,55);var B=C.getHeight()-s[2]-1;return B.toString()})}}function fj(e,n){for(var t=e.length,r=new Array(t),i=0;i<t;++i)r[i]=Ale(e[i],n);return cle(r)}function cle(e){return e.length===1?e[0]:function(n,t,r){if(n){var i=Dse(n),o=J0(i,e.length);return e[o](n,t,r)}else return}}function dle(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 hle=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)}}(),fle=function(e){hle(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=kM.TILELOADSTART):i in this.tileLoadingKeys_&&(delete this.tileLoadingKeys_[i],s=o==mr.ERROR?kM.TILELOADERROR:o==mr.LOADED?kM.TILELOADEND:void 0),s!=null&&this.dispatchEvent(new lle(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=dle(t);this.urls=r,this.setUrls(r)},n.prototype.setUrls=function(t){this.urls=t;var r=t.join(`
`);this.generateTileUrlFunction_?this.setTileUrlFunction(fj(t,this.tileGrid),r):this.setKey(r)},n.prototype.tileUrlFunction=function(t,r,i){},n.prototype.useTile=function(t,r,i){var o=$y(t,r,i);this.tileCache.containsKey(o)&&this.tileCache.get(o)},n}(ule);const pj=fle;var ple=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)}}(),mle=function(e){ple(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:gle,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:lj,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&&!k0(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&&!k0(this.getProjection(),t)?!1:e.prototype.getOpaque.call(this,t)},n.prototype.getTileGridForProjection=function(t){var r=this.getProjection();if(this.tileGrid&&(!r||k0(r,t)))return this.tileGrid;var i=$i(t);return i in this.tileGridForProjection||(this.tileGridForProjection[i]=cj(t)),this.tileGridForProjection[i]},n.prototype.getTileCacheForProjection=function(t){var r=this.getProjection();if(!r||k0(r,t))return this.tileCache;var i=$i(t);return i in this.tileCacheForProjection||(this.tileCacheForProjection[i]=new k7(this.tileCache.highWaterMark)),this.tileCacheForProjection[i]},n.prototype.createTile_=function(t,r,i,o,s,a){var h=[t,r,i],g=this.getTileCoordForTileUrlFunction(h,s),C=g?this.tileUrlFunction(g,o,s):void 0,B=new this.tileClass(h,C!==void 0?mr.IDLE:mr.EMPTY,C!==void 0?C:"",this.crossOrigin,this.tileLoadFunction,this.tileOptions);return B.key=a,B.addEventListener(Di.CHANGE,this.handleTileChange.bind(this)),B},n.prototype.getTile=function(t,r,i,o,s){var a=this.getProjection();if(!a||!s||k0(a,s))return this.getTileInternal(t,r,i,o,a||s);var h=this.getTileCacheForProjection(s),g=[t,r,i],C=void 0,B=aj(g);h.containsKey(B)&&(C=h.get(B));var k=this.getKey();if(C&&C.key==k)return C;var P=this.getTileGridForProjection(a),L=this.getTileGridForProjection(s),J=this.getTileCoordForTileUrlFunction(g,s),N=new Aj(a,P,s,L,g,J,this.getTilePixelRatio(o),this.getGutter(),(function($,q,oe,ce){return this.getTileInternal($,q,oe,ce,a)}).bind(this),this.reprojectionErrorThreshold_,this.renderReprojectionEdges_,this.getInterpolate());return N.key=k,C?(N.interimTile=C,N.refreshInterimChain(),h.replace(B,N)):h.set(B,N),N},n.prototype.getTileInternal=function(t,r,i,o,s){var a=null,h=$y(t,r,i),g=this.getKey();if(!this.tileCache.containsKey(h))a=this.createTile_(t,r,i,o,s,g),this.tileCache.set(h,a);else if(a=this.tileCache.get(h),a.key!=g){var C=a;a=this.createTile_(t,r,i,o,s,g),C.getState()==mr.IDLE?a.interimTile=C.interimTile:a.interimTile=C,a.refreshInterimChain(),this.tileCache.replace(h,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=qs(t);if(i){var o=$i(i);o in this.tileGridForProjection||(this.tileGridForProjection[o]=r)}}},n}(pj);function gle(e,n){e.getImage().src=n}const yle=mle;var mj=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 vle(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(h){clearTimeout(a),s(),n(h)},document.head.appendChild(i)}(function(e){mj(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){mj(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 _le=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)}}(),Cle=function(e){_le(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:qs("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)vle(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):ho(!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=qs("EPSG:4326"),i=this.getProjection(),o;if(t.bounds!==void 0){var s=h5(r,i);o=tne(t.bounds,s)}var a=_5(i),h=t.minzoom||0,g=t.maxzoom||22,C=I7({extent:a,maxZoom:g,minZoom:h,tileSize:this.tileSize_});if(this.tileGrid=C,this.tileUrlFunction=fj(t.tiles,C),t.attribution!==void 0&&!this.getAttributions()){var B=o!==void 0?o:a;this.setAttributions(function(k){return pl(B,k.extent)?[t.attribution]:null})}this.tileJSON_=t,this.setState("ready")},n.prototype.handleTileJSONError=function(){this.setState("error")},n}(yle);const gj=Cle,Cm={PRELOAD:"preload",USE_INTERIM_TILES_ON_ERROR:"useInterimTilesOnError"};var ble=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)}}(),xle=function(e){ble(n,e);function n(t){var r=this,i=t||{},o=gl({},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(Cm.PRELOAD)},n.prototype.setPreload=function(t){this.set(Cm.PRELOAD,t)},n.prototype.getUseInterimTilesOnError=function(){return this.get(Cm.USE_INTERIM_TILES_ON_ERROR)},n.prototype.setUseInterimTilesOnError=function(t){this.set(Cm.USE_INTERIM_TILES_ON_ERROR,t)},n.prototype.getData=function(t){return e.prototype.getData.call(this,t)},n}(m5);const wle=xle;var Mle=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)}}(),Sle=function(e){Mle(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=xd(),r.tmpTileRange_=new oj(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,h=this.getLayer(),g=h.getSource(),C=g.getTile(t,r,i,s,a);return C.getState()==mr.ERROR&&(h.getUseInterimTilesOnError()?h.getPreload()>0&&(this.newTiles_=!0):C.setState(mr.LOADED)),this.isDrawableTile(C)||(C=C.getInterimTile()),C},n.prototype.getData=function(t){var r=this.frameState;if(!r)return null;var i=this.getLayer(),o=fl(r.pixelToCoordinateTransform,t.slice()),s=i.getExtent();if(s&&!$C(s,o))return null;for(var a=r.pixelRatio,h=r.viewState.projection,g=r.viewState,C=i.getRenderSource(),B=C.getTileGridForProjection(g.projection),k=C.getTilePixelRatio(r.pixelRatio),P=B.getZForResolution(g.resolution);P>=B.getMinZoom();--P){var L=B.getTileCoordForCoordAndZ(o,P),J=C.getTile(P,L[1],L[2],a,h);if(!(J instanceof lj||J instanceof Aj))return null;if(J.getState()===mr.LOADED){var N=B.getOrigin(P),$=SA(B.getTileSize(P)),q=B.getResolution(P),oe=Math.floor(k*((o[0]-N[0])/q-L[1]*$[0])),ce=Math.floor(k*((N[1]-o[1])/q-L[2]*$[1])),me=Math.round(k*C.getGutterForProjection(g.projection));return this.getImageData(J.getImage(),oe+me,ce+me)}}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,h=o.center,g=o.rotation,C=t.pixelRatio,B=this.getLayer(),k=B.getSource(),P=k.getRevision(),L=k.getTileGridForProjection(s),J=L.getZForResolution(a,k.zDirection),N=L.getResolution(J),$=t.extent,q=t.viewState.resolution,oe=k.getTilePixelRatio(C),ce=Math.round(ys($)/q*C),me=Math.round(rc($)/q*C),he=i.extent&&z0(i.extent);he&&($=Z0($,z0(i.extent)));var V=N*ce/2/oe,ae=N*me/2/oe,ye=[h[0]-V,h[1]-ae,h[0]+V,h[1]+ae],Oe=L.getTileRangeForExtentAndZ($,J),De={};De[J]={};var He=this.createLoadedTileFinder(k,s,De),ke=this.tmpExtent,nt=this.tmpTileRange_;this.newTiles_=!1;for(var be=g?J6(o.center,q,g,t.size):void 0,Bt=Oe.minX;Bt<=Oe.maxX;++Bt)for(var kt=Oe.minY;kt<=Oe.maxY;++kt)if(!(g&&!L.tileCoordIntersectsViewport([J,Bt,kt],be))){var Yt=this.getTile(J,Bt,kt,t);if(this.isDrawableTile(Yt)){var jt=$i(this);if(Yt.getState()==mr.LOADED){De[J][Yt.tileCoord.toString()]=Yt;var Xe=Yt.inTransition(jt);Xe&&i.opacity!==1&&(Yt.endTransition(jt),Xe=!1),!this.newTiles_&&(Xe||this.renderedTiles.indexOf(Yt)===-1)&&(this.newTiles_=!0)}if(Yt.getAlpha(jt,t.time)===1)continue}var rt=L.getTileCoordChildTileRange(Yt.tileCoord,nt,ke),ot=!1;rt&&(ot=He(J+1,rt)),ot||L.forEachTileCoordParentTileRange(Yt.tileCoord,He,nt,ke)}var on=N/a*C/oe;_f(this.pixelTransform,t.size[0]/2,t.size[1]/2,1/C,1/C,g,-ce/2,-me/2);var gt=$R(this.pixelTransform);this.useContainer(r,gt,this.getBackground(t));var at=this.context,It=at.canvas;XB(this.inversePixelTransform,this.pixelTransform),_f(this.tempTransform,ce/2,me/2,on,on,0,-ce/2,-me/2),It.width!=ce||It.height!=me?(It.width=ce,It.height=me):this.containerReused||at.clearRect(0,0,ce,me),he&&this.clipUnrotated(at,t,he),k.getInterpolate()||gl(at,gE),this.preRender(at,t),this.renderedTiles.length=0;var Lt=Object.keys(De).map(Number);Lt.sort(A1);var Me,fe,xe;i.opacity===1&&(!this.containerReused||k.getOpaque(t.viewState.projection))?Lt=Lt.reverse():(Me=[],fe=[]);for(var Ue=Lt.length-1;Ue>=0;--Ue){var et=Lt[Ue],it=k.getTilePixelSize(et,C,s),bt=L.getResolution(et),Ut=bt/N,Rt=it[0]*Ut*on,pt=it[1]*Ut*on,rr=L.getTileCoordForCoordAndZ($m(ye),et),mn=L.getTileCoordExtent(rr),vn=fl(this.tempTransform,[oe*(mn[0]-ye[0])/N,oe*(ye[3]-mn[3])/N]),Xn=oe*k.getGutterForProjection(s),cr=De[et];for(var Mr in cr){var Yt=cr[Mr],Gr=Yt.tileCoord,gr=rr[1]-Gr[1],mi=Math.round(vn[0]-(gr-1)*Rt),Se=rr[2]-Gr[2],X=Math.round(vn[1]-(Se-1)*pt),Bt=Math.round(vn[0]-gr*Rt),kt=Math.round(vn[1]-Se*pt),H=mi-Bt,Te=X-kt,At=J===et,Xe=At&&Yt.getAlpha($i(this),t.time)!==1,St=!1;if(!Xe)if(Me){xe=[Bt,kt,Bt+H,kt,Bt+H,kt+Te,Bt,kt+Te];for(var Et=0,Nt=Me.length;Et<Nt;++Et)if(J!==et&&et<fe[Et]){var pn=Me[Et];pl([Bt,kt,Bt+H,kt+Te],[pn[0],pn[3],pn[4],pn[7]])&&(St||(at.save(),St=!0),at.beginPath(),at.moveTo(xe[0],xe[1]),at.lineTo(xe[2],xe[3]),at.lineTo(xe[4],xe[5]),at.lineTo(xe[6],xe[7]),at.moveTo(pn[6],pn[7]),at.lineTo(pn[4],pn[5]),at.lineTo(pn[2],pn[3]),at.lineTo(pn[0],pn[1]),at.clip())}Me.push(xe),fe.push(et)}else at.clearRect(Bt,kt,H,Te);this.drawTileImage(Yt,t,Bt,kt,H,Te,Xn,At),Me&&!Xe?(St&&at.restore(),this.renderedTiles.unshift(Yt)):this.renderedTiles.push(Yt),this.updateUsedTiles(t.usedTiles,k,Yt)}}return this.renderedRevision=P,this.renderedResolution=N,this.extentChanged=!this.renderedExtent_||!Oy(this.renderedExtent_,ye),this.renderedExtent_=ye,this.renderedPixelRatio=C,this.renderedProjection=s,this.manageTilePyramid(t,k,L,C,s,$,J,B.getPreload()),this.scheduleExpireCache(t,k),this.postRender(at,t),i.extent&&at.restore(),gl(at,qse),gt!==It.style.transform&&(It.style.transform=gt),this.container},n.prototype.drawTileImage=function(t,r,i,o,s,a,h,g){var C=this.getTileImage(t);if(C){var B=$i(this),k=r.layerStatesArray[r.layerIndex],P=k.opacity*(g?t.getAlpha(B,r.time):1),L=P!==this.context.globalAlpha;L&&(this.context.save(),this.context.globalAlpha=P),this.context.drawImage(C,h,h,C.width-2*h,C.height-2*h,i,o,s,a),L&&this.context.restore(),P!==k.opacity?r.animate=!0:g&&t.endTransition(B)}},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 h=$i(o);h in a.usedTiles&&o.expireCache(a.viewState.projection,a.usedTiles[h])}).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,h,g,C){var B=$i(r);B in t.wantedTiles||(t.wantedTiles[B]={});var k=t.wantedTiles[B],P=t.tileQueue,L=i.getMinZoom(),J=t.viewState.rotation,N=J?J6(t.viewState.center,t.viewState.resolution,J,t.size):void 0,$=0,q,oe,ce,me,he,V;for(V=L;V<=h;++V)for(oe=i.getTileRangeForExtentAndZ(a,V,oe),ce=i.getResolution(V),me=oe.minX;me<=oe.maxX;++me)for(he=oe.minY;he<=oe.maxY;++he)J&&!i.tileCoordIntersectsViewport([V,me,he],N)||(h-V<=g?(++$,q=r.getTile(V,me,he,o,s),q.getState()==mr.IDLE&&(k[q.getKey()]=!0,P.isKeyQueued(q.getKey())||P.enqueue([q,B,i.getTileCoordCenter(q.tileCoord),ce])),C!==void 0&&C(q)):r.useTile(V,me,he,s));r.updateCacheSize($,s)},n}($z);const yj=Sle;var Ele=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)}}(),Ole=function(e){Ele(n,e);function n(t){return e.call(this,t)||this}return n.prototype.createRenderer=function(){return new yj(this)},n}(wle);const bm={IMAGE:"image",HYBRID:"hybrid",VECTOR:"vector"};var Ble=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)}}(),kle={image:["Polygon","Circle","LineString","Image","Text"],hybrid:["Polygon","LineString"],vector:[]},Ile={hybrid:["Image","Text","Default"],vector:["Polygon","Circle","LineString","Image","Text","Default"]},Tle=function(e){Ble(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_=_d(),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,h=a.resolution,g=a.projection,C=this.getLayer(),B=C.getSource().getTile(t,r,i,s,g),k=o.viewHints,P=!(k[il.ANIMATING]||k[il.INTERACTING]);(P||!B.wantedResolution)&&(B.wantedResolution=h);var L=this.prepareTile(B,s,g);return L&&(P||Date.now()-o.time<8)&&C.getRenderMode()!==bm.VECTOR&&this.renderTileImage_(B,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()===bm.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,h=t.wantedResolution,g=t.getReplayState(o);if(!(!g.dirty&&g.renderedResolution===h&&g.renderedRevision==s&&g.renderedRenderOrder==a)){var C=o.getSource(),B=o.getDeclutter(),k=C.getTileGrid(),P=C.getTileGridForProjection(i),L=P.getTileCoordExtent(t.wrappedTileCoord),J=C.getSourceTiles(r,i,t),N=$i(o);delete t.hitDetectionImageData[N],t.executorGroups[N]=[],B&&(t.declutterExecutorGroups[N]=[]),g.dirty=!1;for(var $=function(me,he){var V=J[me];if(V.getState()!=mr.LOADED)return"continue";var ae=V.tileCoord,ye=k.getTileCoordExtent(ae),Oe=Z0(L,ye),De=Pm(Oe,o.getRenderBuffer()*h,q.tmpExtent),He=Oy(ye,Oe)?null:De,ke=new F3(0,De,h,r),nt=B?new F3(0,Oe,h,r):void 0,be=Zz(h,r),Bt=function(at){var It,Lt=at.getStyleFunction()||o.getStyleFunction();if(Lt&&(It=Lt(at,h)),It){var Me=this.renderFeature(at,be,It,ke,nt);g.dirty=g.dirty||Me}},kt=V.getFeatures();a&&a!==g.renderedRenderOrder&&kt.sort(a);for(var Yt=0,jt=kt.length;Yt<jt;++Yt){var Xe=kt[Yt];(!He||pl(He,Xe.getGeometry().getExtent()))&&Bt.call(q,Xe)}var rt=ke.finish(),ot=o.getRenderMode()!==bm.VECTOR&&B&&J.length===1?null:Oe,on=new D3(ot,h,r,C.getOverlaps(),rt,o.getRenderBuffer());if(t.executorGroups[N].push(on),nt){var gt=new D3(null,h,r,C.getOverlaps(),nt.finish(),o.getRenderBuffer());t.declutterExecutorGroups[N].push(gt)}},q=this,oe=0,ce=J.length;oe<ce;++oe)$(oe);g.renderedRevision=s,g.renderedRenderOrder=a,g.renderedResolution=h}},n.prototype.forEachFeatureAtCoordinate=function(t,r,i,o,s){var a=r.viewState.resolution,h=r.viewState.rotation;i=i??0;var g=this.getLayer(),C=g.getSource(),B=C.getTileGridForProjection(r.viewState.projection),k=H6([t]);Pm(k,a*i,k);for(var P={},L=function(ce,me,he){var V=ce.getId();V===void 0&&(V=$i(ce));var ae=P[V];if(ae){if(ae!==!0&&he<ae.distanceSq){if(he===0)return P[V]=!0,s.splice(s.lastIndexOf(ae),1),o(ce,g,me);ae.geometry=me,ae.distanceSq=he}}else{if(he===0)return P[V]=!0,o(ce,g,me);s.push(P[V]={feature:ce,layer:g,geometry:me,distanceSq:he,callback:o})}},J=this.renderedTiles,N,$=function(ce,me){var he=J[ce],V=B.getTileCoordExtent(he.wrappedTileCoord);if(!pl(V,k))return"continue";var ae=$i(g),ye=[he.executorGroups[ae]],Oe=he.declutterExecutorGroups[ae];Oe&&ye.push(Oe),ye.some(function(De){for(var He=De===Oe?r.declutterTree.all().map(function(Bt){return Bt.value}):null,ke=0,nt=De.length;ke<nt;++ke){var be=De[ke];if(N=be.forEachFeatureAtCoordinate(t,a,h,i,L,He),N)return!0}})},q=0,oe=J.length;!N&&q<oe;++q)$(q);return N},n.prototype.getFeatures=function(t){return new Promise((function(r,i){for(var o=this.getLayer(),s=$i(o),a=o.getSource(),h=this.renderedProjection,g=h.getExtent(),C=this.renderedResolution,B=a.getTileGridForProjection(h),k=fl(this.renderedPixelToCoordinateTransform_,t.slice()),P=B.getTileCoordForCoordAndResolution(k,C),L,J=0,N=this.renderedTiles.length;J<N;++J)if(P.toString()===this.renderedTiles[J].tileCoord.toString()){if(L=this.renderedTiles[J],L.getState()===mr.LOADED){var $=B.getTileCoordExtent(L.tileCoord);a.getWrapX()&&h.canWrapX()&&!ym(g,$)&&i7(k,h);break}L=void 0}if(!L||L.loadingSourceTiles>0){r([]);return}var q=B.getTileCoordExtent(L.wrappedTileCoord),oe=$m(q),ce=[(k[0]-oe[0])/C,(oe[1]-k[1])/C],me=L.getSourceTiles().reduce(function(Oe,De){return Oe.concat(De.getFeatures())},[]),he=L.hitDetectionImageData[s];if(!he&&!this.animatingOrInteracting_){var V=SA(B.getTileSize(B.getZForResolution(C,a.zDirection))),ae=this.renderedRotation_,ye=[this.getRenderTransform(B.getTileCoordCenter(L.wrappedTileCoord),C,0,Pc,V[0]*Pc,V[1]*Pc,0)];he=qz(V,ye,me,o.getStyleFunction(),B.getTileCoordExtent(L.wrappedTileCoord),L.getReplayState(o).renderedResolution,ae),L.hitDetectionImageData[s]=he}r(Hz(ce,me,he))}).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[il.ANIMATING]||o[il.INTERACTING]),a=this.renderedTiles,h=0,g=a.length;h<g;++h){var C=a[h],B=C.declutterExecutorGroups[$i(this.getLayer())];if(B)for(var k=B.length-1;k>=0;--k)B[k].execute(this.context,1,this.getTileRenderTransform(C,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,h=o.rotation,g=r.size,C=Math.round(g[0]*i),B=Math.round(g[1]*i),k=this.getLayer().getSource(),P=k.getTileGridForProjection(r.viewState.projection),L=t.tileCoord,J=P.getTileCoordExtent(t.wrappedTileCoord),N=P.getTileCoordExtent(L,this.tmpExtent)[0]-J[0],$=ZB(pM(this.inversePixelTransform.slice(),1/i,1/i),this.getRenderTransform(s,a,h,i,C,B,N));return $},n.prototype.renderFrame=function(t,r){var i=t.viewHints,o=!(i[il.ANIMATING]||i[il.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(),h=this.context,g=h.globalAlpha;h.globalAlpha=s.getOpacity();for(var C=Ile[a],B=t.viewState,k=B.rotation,P=s.getSource(),L=P.getTileGridForProjection(B.projection),J=L.getZForResolution(B.resolution,P.zDirection),N=this.renderedTiles,$=[],q=[],oe=!0,ce=N.length-1;ce>=0;--ce){var me=N[ce];oe=oe&&!me.getReplayState(s).dirty;var he=me.executorGroups[$i(s)].filter(function(kt){return kt.hasExecutors(C)});if(he.length!==0){var V=this.getTileRenderTransform(me,t),ae=me.tileCoord[0],ye=!1,Oe=he[0].getClipCoords(V);if(Oe){for(var De=0,He=$.length;De<He;++De)if(J!==ae&&ae<q[De]){var ke=$[De];pl([Oe[0],Oe[3],Oe[4],Oe[7]],[ke[0],ke[3],ke[4],ke[7]])&&(ye||(h.save(),ye=!0),h.beginPath(),h.moveTo(Oe[0],Oe[1]),h.lineTo(Oe[2],Oe[3]),h.lineTo(Oe[4],Oe[5]),h.lineTo(Oe[6],Oe[7]),h.moveTo(ke[6],ke[7]),h.lineTo(ke[4],ke[5]),h.lineTo(ke[2],ke[3]),h.lineTo(ke[0],ke[1]),h.clip())}$.push(Oe),q.push(ae)}for(var nt=0,be=he.length;nt<be;++nt){var Bt=he[nt];Bt.execute(h,1,V,k,o,C)}ye&&h.restore()}}return h.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 h=0,g=i.length;h<g;++h)a=L3(o,t,i[h],r,this.boundHandleStyleImageChange_,void 0,s)||a;else a=L3(o,t,i,r,this.boundHandleStyleImageChange_,void 0,s);return a},n.prototype.tileImageNeedsRender_=function(t){var r=this.getLayer();if(r.getRenderMode()===bm.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 h=t.wrappedTileCoord,g=h[0],C=i.getSource(),B=r.pixelRatio,k=r.viewState,P=k.projection,L=C.getTileGridForProjection(P),J=L.getResolution(t.tileCoord[0]),N=r.pixelRatio/t.wantedResolution*J,$=L.getResolution(g),q=t.getContext(i);B=Math.round(Math.max(B,N/B));var oe=C.getTilePixelSize(g,B,P);q.canvas.width=oe[0],q.canvas.height=oe[1];var ce=B/N;if(ce!==1){var me=x9(this.tmpTransform_);pM(me,ce,ce),q.setTransform.apply(q,me)}var he=L.getTileCoordExtent(h,this.tmpExtent),V=N/$,ae=x9(this.tmpTransform_);pM(ae,V,-V),qte(ae,-he[0],-he[3]);for(var ye=0,Oe=a.length;ye<Oe;++ye){var De=a[ye];De.execute(q,ce,ae,0,!0,kle[i.getRenderMode()])}o.renderedTileResolution=t.wantedResolution},n}(yj);const Kle=Tle;var Ple=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)}}(),vj=function(e){Ple(n,e);function n(t){var r=this,i=t||{},o=gl({},i);delete o.preload,delete o.useInterimTilesOnError,r=e.call(this,o)||this,r.on,r.once,r.un,i.renderMode===bm.IMAGE&&(console.warn('renderMode: "image" is deprecated. Option ignored.'),i.renderMode=void 0);var s=i.renderMode||bm.HYBRID;return ho(s==bm.HYBRID||s==bm.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 Kle(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(Cm.PRELOAD)},n.prototype.getUseInterimTilesOnError=function(){return this.get(Cm.USE_INTERIM_TILES_ON_ERROR)},n.prototype.setPreload=function(t){this.set(Cm.PRELOAD,t)},n.prototype.setUseInterimTilesOnError=function(t){this.set(Cm.USE_INTERIM_TILES_ON_ERROR,t)},n}(Nz),Fle=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)}}(),Dle=function(e){Fle(n,e);function n(t,r,i,o,s,a){var h=e.call(this,t,r,a)||this;return h.extent=null,h.format_=o,h.features_=null,h.loader_,h.projection=null,h.resolution,h.tileLoadFunction_=s,h.url_=i,h.key=i,h}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}(v5);const Lle=Dle;var Ule=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)}}(),pT=[],Rle=function(e){Ule(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]=ic(1,1,pT)),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];_7(r),pT.push(r.canvas),delete this.context_[t]}e.prototype.release.call(this)},n}(v5);const zle=Rle;var jle=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)}}(),Wle=function(e){jle(n,e);function n(t){var r=this,i=t.projection||"EPSG:3857",o=t.extent||_5(i),s=t.tileGrid||I7({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:Nle,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 k7(r.tileCache.highWaterMark),r.overlaps_=t.overlaps==null?!0:t.overlaps,r.tileClass=t.tileClass?t.tileClass:Lle,r.tileGrids_={},r}return n.prototype.getFeaturesInExtent=function(t){var r=[],i=this.tileCache;if(i.getCount()===0)return r;var o=sj(i.peekFirstKey())[0],s=this.tileGrid;return i.forEach(function(a){if(!(a.tileCoord[0]!==o||a.getState()!==mr.LOADED))for(var h=a.getSourceTiles(),g=0,C=h.length;g<C;++g){var B=h[g],k=B.tileCoord;if(pl(t,s.getTileCoordExtent(k))){var P=B.getFeatures();if(P)for(var L=0,J=P.length;L<J;++L){var N=P[L],$=N.getGeometry();pl(t,$.getExtent())&&r.push(N)}}}}),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 h=Fse(a),g=i.peek(h);if(g)for(var C=g.sourceTiles,B=0,k=C.length;B<k;++B)s[C[B].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),h=a.getTileCoordExtent(s),g=s[0],C=a.getResolution(g);Pm(h,-C,h);var B=this.tileGrid,k=B.getExtent();k&&Z0(h,k,h);var P=B.getZForResolution(C,this.zDirection);B.forEachTileCoord(h,P,function(L){var J=o.tileUrlFunction(L,t,r),N=o.sourceTileCache.containsKey(J)?o.sourceTileCache.get(J):new o.tileClass(L,J?mr.IDLE:mr.EMPTY,J,o.format_,o.tileLoadFunction);i.sourceTiles.push(N);var $=N.getState();if($<mr.LOADED){var q=function(oe){o.handleTileChange(oe);var ce=N.getState();if(ce===mr.LOADED||ce===mr.ERROR){var me=N.getKey();me in i.errorTileKeys?N.getState()===mr.LOADED&&delete i.errorTileKeys[me]:i.loadingSourceTiles--,ce===mr.ERROR?i.errorTileKeys[me]=!0:N.removeEventListener(Di.CHANGE,q),i.loadingSourceTiles===0&&i.setState(d1(i.errorTileKeys)?mr.LOADED:mr.ERROR)}};N.addEventListener(Di.CHANGE,q),i.loadingSourceTiles++}$===mr.IDLE&&(N.extent=B.getTileCoordExtent(L),N.projection=r,N.resolution=B.getResolution(L[0]),o.sourceTileCache.set(J,N),N.load())}),i.loadingSourceTiles||i.setState(i.sourceTiles.some(function(L){return L.getState()===mr.ERROR})?mr.ERROR:mr.LOADED)}return i.sourceTiles},n.prototype.getTile=function(t,r,i,o,s){var a=$y(t,r,i),h=this.getKey(),g;if(this.tileCache.containsKey(a)&&(g=this.tileCache.get(a),g.key===h))return g;var C=[t,r,i],B=this.getTileCoordForTileUrlFunction(C,s),k=this.getTileGrid().getExtent(),P=this.getTileGridForProjection(s);if(B&&k){var L=P.getTileCoordExtent(B);Pm(L,-P.getResolution(t),L),pl(k,L)||(B=null)}var J=!0;if(B!==null){var N=this.tileGrid,$=P.getResolution(t),q=N.getZForResolution($,1),oe=P.getTileCoordExtent(B);Pm(oe,-$,oe),N.forEachTileCoord(oe,q,(function(me){J=J&&!this.tileUrlFunction(me,o,s)}).bind(this))}var ce=new zle(C,J?mr.EMPTY:mr.IDLE,B,this.getSourceTiles.bind(this,o,s));return ce.key=h,g?(ce.interimTile=g,ce.refreshInterimChain(),this.tileCache.replace(a,ce)):this.tileCache.set(a,ce),ce},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(B,k){return o.getOrigin(k)}),h=s.map(function(B,k){return o.getTileSize(k)}),g=kz+1,C=s.length;C<g;++C)s.push(s[C-1]/2),a.push(a[C-1]),h.push(h[C-1]);i=new XC({extent:o.getExtent(),origins:a,resolutions:s,tileSizes:h}),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=SA(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}(pj);const _j=Wle;function Nle(e,n){e.setLoader(function(t,r,i){tj(n,e.getFormat(),t,r,i,e.onLoad.bind(e),e.onError.bind(e))})}var mT={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},Wv=" ",gT=/(italic|oblique)$/i,yT={},Gle=function(e,n,t){var r=yT[e];if(!r){Array.isArray(e)||(e=[e]);for(var i=400,o="normal",s=[],a,h,g=0,C=e.length;g<C;++g){var B=e[g],k=B.split(" "),P=k[k.length-1].toLowerCase();P=="normal"||P=="italic"||P=="oblique"?(o=h?o:P,k.pop(),P=k[k.length-1].toLowerCase()):gT.test(P)&&(P=P.replace(gT,""),o=h?o:k[k.length-1].replace(P,""));for(var L in mT){var J=k.length>1?k[k.length-2].toLowerCase():"";if(P==L||P==L.replace("-","")||J+"-"+P==L){i=a?i:mT[L],k.pop(),J&&L.startsWith(J)&&k.pop();break}}!a&&typeof P=="number"&&(i=P);var N=k.join(Wv).replace("Klokantech Noto Sans","Noto Sans");N.indexOf(Wv)!==-1&&(N='"'+N+'"'),s.push(N)}r=yT[e]=[o,i,s]}return r[0]+Wv+r[1]+Wv+n+"px"+(t?"/"+t:"")+Wv+r[2]};const yE=fa(Gle);var Qle=8,$le={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"}}]}},Yle={"*":{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."}},qle=["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],Hle={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."}},Vle={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."}},Zle={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."}},Xle={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>}`."}},Jle={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."}}},eue={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."}}},tue={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."}},nue=["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background","layout_sky"],rue={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"}},iue={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"}},oue={"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"}},aue={"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"}},sue={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"}},lue={"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"}},uue={"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 doesnt 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"}},Aue={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"}},cue={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"}},due={type:"array",value:"*",doc:"A filter selects specific features from a layer."},hue={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"]}},fue={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"]}},pue={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"]}},mue={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"]}},gue={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"]}},yue={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."},vue={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."},_ue={type:"array",minimum:0,maximum:24,value:["number","color"],length:2,doc:"Zoom level and value pair."},Cue={type:"array",value:"*",minimum:1,doc:"An expression defines a function that can be used for data-driven style properties or feature filters."},bue={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"}}}}},xue={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"}}}},wue={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"}}}},Mue={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"}}}},Sue={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"}}}},Eue=["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background","paint_sky"],Oue={"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"}},Bue={"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"}},kue={"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"}},Iue={"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"}},Tue={"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"}},Kue={"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"}},Pue={"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"}},Fue={"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"}},Due={"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"}},Lue={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."}},Uue={"*":{type:"string",doc:"A name of a feature property to use as ID for feature state."}},Cj={$version:Qle,$root:$le,sources:Yle,source:qle,source_vector:Hle,source_raster:Vle,source_raster_dem:Zle,source_geojson:Xle,source_video:Jle,source_image:eue,layer:tue,layout:nue,layout_background:rue,layout_sky:iue,layout_fill:oue,layout_circle:aue,layout_heatmap:sue,"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:lue,layout_symbol:uue,layout_raster:Aue,layout_hillshade:cue,filter:due,filter_symbol:hue,filter_fill:fue,filter_line:pue,filter_circle:mue,"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:gue,filter_operator:yue,geometry_type:vue,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:_ue,expression:Cue,expression_name:bue,fog:xue,light:wue,projection:Mue,terrain:Sue,paint:Eue,paint_fill:Oue,"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:Bue,paint_circle:kue,paint_heatmap:Iue,paint_symbol:Tue,paint_raster:Kue,paint_hillshade:Pue,paint_background:Fue,paint_sky:Due,transition:Lue,"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:Uue},IM=typeof globalThis<"u"?globalThis:typeof window<"u"||typeof window<"u"?window:typeof self<"u"?self:{},vE={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 IM=="object"&&IM;(o.global===o||o.window===o||o.self===o)&&(t=o);var s,a=2147483647,h=36,g=1,C=26,B=38,k=700,P=72,L=128,J="-",N=/^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"},ce=h-g,me=Math.floor,he=String.fromCharCode,V;function ae(Xe){throw RangeError(oe[Xe])}function ye(Xe,rt){for(var ot=Xe.length,on=[];ot--;)on[ot]=rt(Xe[ot]);return on}function Oe(Xe,rt){var ot=Xe.split("@"),on="";ot.length>1&&(on=ot[0]+"@",Xe=ot[1]),Xe=Xe.replace(q,".");var gt=Xe.split("."),at=ye(gt,rt).join(".");return on+at}function De(Xe){for(var rt=[],ot=0,on=Xe.length,gt,at;ot<on;)gt=Xe.charCodeAt(ot++),gt>=55296&&gt<=56319&&ot<on?(at=Xe.charCodeAt(ot++),(at&64512)==56320?rt.push(((gt&1023)<<10)+(at&1023)+65536):(rt.push(gt),ot--)):rt.push(gt);return rt}function He(Xe){return ye(Xe,function(rt){var ot="";return rt>65535&&(rt-=65536,ot+=he(rt>>>10&1023|55296),rt=56320|rt&1023),ot+=he(rt),ot}).join("")}function ke(Xe){return Xe-48<10?Xe-22:Xe-65<26?Xe-65:Xe-97<26?Xe-97:h}function nt(Xe,rt){return Xe+22+75*(Xe<26)-((rt!=0)<<5)}function be(Xe,rt,ot){var on=0;for(Xe=ot?me(Xe/k):Xe>>1,Xe+=me(Xe/rt);Xe>ce*C>>1;on+=h)Xe=me(Xe/ce);return me(on+(ce+1)*Xe/(Xe+B))}function Bt(Xe){var rt=[],ot=Xe.length,on,gt=0,at=L,It=P,Lt,Me,fe,xe,Ue,et,it,bt,Ut;for(Lt=Xe.lastIndexOf(J),Lt<0&&(Lt=0),Me=0;Me<Lt;++Me)Xe.charCodeAt(Me)>=128&&ae("not-basic"),rt.push(Xe.charCodeAt(Me));for(fe=Lt>0?Lt+1:0;fe<ot;){for(xe=gt,Ue=1,et=h;fe>=ot&&ae("invalid-input"),it=ke(Xe.charCodeAt(fe++)),(it>=h||it>me((a-gt)/Ue))&&ae("overflow"),gt+=it*Ue,bt=et<=It?g:et>=It+C?C:et-It,!(it<bt);et+=h)Ut=h-bt,Ue>me(a/Ut)&&ae("overflow"),Ue*=Ut;on=rt.length+1,It=be(gt-xe,on,xe==0),me(gt/on)>a-at&&ae("overflow"),at+=me(gt/on),gt%=on,rt.splice(gt++,0,at)}return He(rt)}function kt(Xe){var rt,ot,on,gt,at,It,Lt,Me,fe,xe,Ue,et=[],it,bt,Ut,Rt;for(Xe=De(Xe),it=Xe.length,rt=L,ot=0,at=P,It=0;It<it;++It)Ue=Xe[It],Ue<128&&et.push(he(Ue));for(on=gt=et.length,gt&&et.push(J);on<it;){for(Lt=a,It=0;It<it;++It)Ue=Xe[It],Ue>=rt&&Ue<Lt&&(Lt=Ue);for(bt=on+1,Lt-rt>me((a-ot)/bt)&&ae("overflow"),ot+=(Lt-rt)*bt,rt=Lt,It=0;It<it;++It)if(Ue=Xe[It],Ue<rt&&++ot>a&&ae("overflow"),Ue==rt){for(Me=ot,fe=h;xe=fe<=at?g:fe>=at+C?C:fe-at,!(Me<xe);fe+=h)Rt=Me-xe,Ut=h-xe,et.push(he(nt(xe+Rt%Ut,0))),Me=me(Rt/Ut);et.push(he(nt(Me,0))),at=be(ot,bt,on==gt),ot=0,++on}++ot,++rt}return et.join("")}function Yt(Xe){return Oe(Xe,function(rt){return N.test(rt)?Bt(rt.slice(4).toLowerCase()):rt})}function jt(Xe){return Oe(Xe,function(rt){return $.test(rt)?"xn--"+kt(rt):rt})}if(s={version:"1.3.2",ucs2:{decode:De,encode:He},decode:Bt,encode:kt,toASCII:jt,toUnicode:Yt},r&&i)if(e.exports==r)i.exports=s;else for(V in s)s.hasOwnProperty(V)&&(r[V]=s[V]);else t.punycode=s})(IM)})(vE,vE.exports);var Rue={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}},vC={};function zue(e,n){return Object.prototype.hasOwnProperty.call(e,n)}var jue=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 h=0;h<a;++h){var g=e[h].replace(o,"%20"),C=g.indexOf(t),B,k,P,L;C>=0?(B=g.substr(0,C),k=g.substr(C+1)):(B=g,k=""),P=decodeURIComponent(B),L=decodeURIComponent(k),zue(i,P)?Array.isArray(i[P])?i[P].push(L):i[P]=[i[P],L]:i[P]=L}return i},Nv=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}},Wue=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(Nv(i))+t;return Array.isArray(e[i])?e[i].map(function(s){return o+encodeURIComponent(Nv(s))}).join(n):o+encodeURIComponent(Nv(e[i]))}).join(n):r?encodeURIComponent(Nv(r))+t+encodeURIComponent(Nv(e)):""};vC.decode=vC.parse=jue;vC.encode=vC.stringify=Wue;var Nue=vE.exports,hp=Rue;function wp(){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 Gue=/^([a-z0-9.+-]+:)/i,Que=/:[0-9]*$/,$ue=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,Yue=["<",">",'"',"`"," ","\r",`
`," "],que=["{","}","|","\\","^","`"].concat(Yue),_E=["'"].concat(que),vT=["%","/","?",";","#"].concat(_E),_T=["/","?","#"],Hue=255,CT=/^[+a-z0-9A-Z_-]{0,63}$/,Vue=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,Zue={javascript:!0,"javascript:":!0},CE={javascript:!0,"javascript:":!0},sy={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},bE=vC;function Xue(e,n,t){if(e&&hp.isObject(e)&&e instanceof wp)return e;var r=new wp;return r.parse(e,n,t),r}wp.prototype.parse=function(e,n,t){if(!hp.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 h=$ue.exec(a);if(h)return this.path=a,this.href=a,this.pathname=h[1],h[2]?(this.search=h[2],n?this.query=bE.parse(this.search.substr(1)):this.query=this.search.substr(1)):n&&(this.search="",this.query={}),this}var g=Gue.exec(a);if(g){g=g[0];var C=g.toLowerCase();this.protocol=C,a=a.substr(g.length)}if(t||g||a.match(/^\/\/[^@\/]+@[^@\/]+/)){var B=a.substr(0,2)==="//";B&&!(g&&CE[g])&&(a=a.substr(2),this.slashes=!0)}if(!CE[g]&&(B||g&&!sy[g])){for(var k=-1,P=0;P<_T.length;P++){var L=a.indexOf(_T[P]);L!==-1&&(k===-1||L<k)&&(k=L)}var J,N;k===-1?N=a.lastIndexOf("@"):N=a.lastIndexOf("@",k),N!==-1&&(J=a.slice(0,N),a=a.slice(N+1),this.auth=decodeURIComponent(J)),k=-1;for(var P=0;P<vT.length;P++){var L=a.indexOf(vT[P]);L!==-1&&(k===-1||L<k)&&(k=L)}k===-1&&(k=a.length),this.host=a.slice(0,k),a=a.slice(k),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 ce=q[P];if(ce&&!ce.match(CT)){for(var me="",he=0,V=ce.length;he<V;he++)ce.charCodeAt(he)>127?me+="x":me+=ce[he];if(!me.match(CT)){var ae=q.slice(0,P),ye=q.slice(P+1),Oe=ce.match(Vue);Oe&&(ae.push(Oe[1]),ye.unshift(Oe[2])),ye.length&&(a="/"+ye.join(".")+a),this.hostname=ae.join(".");break}}}this.hostname.length>Hue?this.hostname="":this.hostname=this.hostname.toLowerCase(),$||(this.hostname=Nue.toASCII(this.hostname));var De=this.port?":"+this.port:"",He=this.hostname||"";this.host=He+De,this.href+=this.host,$&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),a[0]!=="/"&&(a="/"+a))}if(!Zue[C])for(var P=0,oe=_E.length;P<oe;P++){var ke=_E[P];if(a.indexOf(ke)!==-1){var nt=encodeURIComponent(ke);nt===ke&&(nt=escape(ke)),a=a.split(ke).join(nt)}}var be=a.indexOf("#");be!==-1&&(this.hash=a.substr(be),a=a.slice(0,be));var Bt=a.indexOf("?");if(Bt!==-1?(this.search=a.substr(Bt),this.query=a.substr(Bt+1),n&&(this.query=bE.parse(this.query)),a=a.slice(0,Bt)):n&&(this.search="",this.query={}),a&&(this.pathname=a),sy[C]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var De=this.pathname||"",kt=this.search||"";this.path=De+kt}return this.href=this.format(),this};wp.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&&hp.isObject(this.query)&&Object.keys(this.query).length&&(o=bE.stringify(this.query));var s=this.search||o&&"?"+o||"";return n&&n.substr(-1)!==":"&&(n+=":"),this.slashes||(!n||sy[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};wp.prototype.resolve=function(e){return this.resolveObject(Xue(e,!1,!0)).format()};wp.prototype.resolveObject=function(e){if(hp.isString(e)){var n=new wp;n.parse(e,!1,!0),e=n}for(var t=new wp,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 h=s[a];h!=="protocol"&&(t[h]=e[h])}return sy[t.protocol]&&t.hostname&&!t.pathname&&(t.path=t.pathname="/"),t.href=t.format(),t}if(e.protocol&&e.protocol!==t.protocol){if(!sy[e.protocol]){for(var g=Object.keys(e),C=0;C<g.length;C++){var B=g[C];t[B]=e[B]}return t.href=t.format(),t}if(t.protocol=e.protocol,!e.host&&!CE[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 k=t.pathname||"",P=t.search||"";t.path=k+P}return t.slashes=t.slashes||e.slashes,t.href=t.format(),t}var L=t.pathname&&t.pathname.charAt(0)==="/",J=e.host||e.pathname&&e.pathname.charAt(0)==="/",N=J||L||t.host&&e.pathname,$=N,q=t.pathname&&t.pathname.split("/")||[],oe=e.pathname&&e.pathname.split("/")||[],ce=t.protocol&&!sy[t.protocol];if(ce&&(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),N=N&&(oe[0]===""||q[0]==="")),J)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(!hp.isNullOrUndefined(e.search)){if(ce){t.hostname=t.host=q.shift();var me=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;me&&(t.auth=me.shift(),t.host=t.hostname=me.shift())}return t.search=e.search,t.query=e.query,(!hp.isNull(t.pathname)||!hp.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 he=q.slice(-1)[0],V=(t.host||e.host||q.length>1)&&(he==="."||he==="..")||he==="",ae=0,ye=q.length;ye>=0;ye--)he=q[ye],he==="."?q.splice(ye,1):he===".."?(q.splice(ye,1),ae++):ae&&(q.splice(ye,1),ae--);if(!N&&!$)for(;ae--;ae)q.unshift("..");N&&q[0]!==""&&(!q[0]||q[0].charAt(0)!=="/")&&q.unshift(""),V&&q.join("/").substr(-1)!=="/"&&q.push("");var Oe=q[0]===""||q[0]&&q[0].charAt(0)==="/";if(ce){t.hostname=t.host=Oe?"":q.length?q.shift():"";var me=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;me&&(t.auth=me.shift(),t.host=t.hostname=me.shift())}return N=N||t.host&&q.length,N&&!Oe&&q.unshift(""),q.length?t.pathname=q.join("/"):(t.pathname=null,t.path=null),(!hp.isNull(t.pathname)||!hp.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};wp.prototype.parseHost=function(){var e=this.host,n=Que.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 bj(e,...n){for(const t of n)for(const r in t)e[r]=t[r];return e}class Jue extends Error{constructor(n,t){super(t),this.message=t,this.key=n}}var sf=Jue;class T7{constructor(n,t=[]){this.parent=n,this.bindings={};for(const[r,i]of t)this.bindings[r]=i}concat(n){return new T7(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 eAe=T7;const C5={kind:"null"},er={kind:"number"},co={kind:"string"},Zi={kind:"boolean"},Mp={kind:"color"},ly={kind:"object"},Ji={kind:"value"},tAe={kind:"error"},b5={kind:"collator"},x5={kind:"formatted"},JC={kind:"resolvedImage"};function pd(e,n){return{kind:"array",itemType:e,N:n}}function ks(e){if(e.kind==="array"){const n=ks(e.itemType);return typeof e.N=="number"?`array<${n}, ${e.N}>`:e.itemType.kind==="value"?"array":`array<${n}>`}else return e.kind}const nAe=[C5,er,co,Zi,Mp,x5,ly,pd(Ji),JC];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 nAe)if(!_C(t,n))return null}}return`Expected ${ks(e)} but found ${ks(n)} instead.`}function K7(e,n){return n.some(t=>t.kind===e.kind)}function CC(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 rAe={},xj,bT={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 T_(e){return e=Math.round(e),e<0?0:e>255?255:e}function xT(e){return e<0?0:e>1?1:e}function TM(e){return e[e.length-1]==="%"?T_(parseFloat(e)/100*255):T_(parseInt(e))}function Px(e){return e[e.length-1]==="%"?xT(parseFloat(e)/100):xT(parseFloat(e))}function KM(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 iAe(e){var n=e.replace(/ /g,"").toLowerCase();if(n in bT)return bT[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=Px(s.pop());case"rgb":return s.length!==3?null:[TM(s[0]),TM(s[1]),TM(s[2]),a];case"hsla":if(s.length!==4)return null;a=Px(s.pop());case"hsl":if(s.length!==3)return null;var h=(parseFloat(s[0])%360+360)%360/360,g=Px(s[1]),C=Px(s[2]),B=C<=.5?C*(g+1):C+g-C*g,k=C*2-B;return[T_(KM(k,B,h+1/3)*255),T_(KM(k,B,h)*255),T_(KM(k,B,h-1/3)*255),a];default:return null}}return null}try{xj=rAe.parseCSSColor=iAe}catch{}class oc{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 oc)return n;if(typeof n!="string")return;const t=xj(n);if(t)return new oc(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]}}oc.black=new oc(0,0,0,1);oc.white=new oc(1,1,1,1);oc.transparent=new oc(0,0,0,0);oc.red=new oc(1,0,0,1);oc.blue=new oc(0,0,1,1);var Vl=oc;class P7{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 xE{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 lh{constructor(n){this.sections=n}static fromString(n){return new lh([new xE(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 lh?n:lh.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 Bp{constructor(n){this.name=n.name,this.available=n.available}toString(){return this.name}static fromString(n){return n?new Bp({name:n,available:!1}):null}serialize(){return["image",this.name]}}function wj(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 U3(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 Vl)return!0;if(e instanceof P7)return!0;if(e instanceof lh)return!0;if(e instanceof Bp)return!0;if(Array.isArray(e)){for(const n of e)if(!U3(n))return!1;return!0}else if(typeof e=="object"){for(const n in e)if(!U3(e[n]))return!1;return!0}else return!1}function ql(e){if(e===null)return C5;if(typeof e=="string")return co;if(typeof e=="boolean")return Zi;if(typeof e=="number")return er;if(e instanceof Vl)return Mp;if(e instanceof P7)return b5;if(e instanceof lh)return x5;if(e instanceof Bp)return JC;if(Array.isArray(e)){const n=e.length;let t;for(const r of e){const i=ql(r);if(!t)t=i;else{if(t===i)continue;t=Ji;break}}return pd(t||Ji,n)}else return ly}function K_(e){const n=typeof e;return e===null?"":n==="string"||n==="number"||n==="boolean"?String(e):e instanceof Vl||e instanceof lh||e instanceof Bp?e.toString():JSON.stringify(e)}class F7{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(!U3(n[1]))return t.error("invalid value");const r=n[1];let i=ql(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 F7(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 Vl?["rgba"].concat(this.value.toArray()):this.value instanceof lh?this.value.serialize():this.value}}var R3=F7;class oAe{constructor(n){this.name="ExpressionEvaluationError",this.message=n}toJSON(){return this.message}}var Tu=oAe;const PM={string:co,number:er,boolean:Zi,object:ly};class D7{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 PM)||g==="object")return t.error('The item type argument of "array" must be one of string, number, boolean',1);a=PM[g],r++}else a=Ji;let h;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);h=n[2],r++}i=pd(a,h)}else i=PM[o];const s=[];for(;r<n.length;r++){const a=t.parse(n[r],r,Ji);if(!a)return null;s.push(a)}return new D7(i,s)}evaluate(n){for(let t=0;t<this.args.length;t++){const r=this.args[t].evaluate(n);if(_C(this.type,ql(r))){if(t===this.args.length-1)throw new Tu(`Expected value to be of type ${ks(this.type)}, but found ${ks(ql(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 yp=D7;class w5{constructor(n){this.type=x5,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 h=null;if(a["font-scale"]&&(h=t.parse(a["font-scale"],1,er),!h))return null;let g=null;if(a["text-font"]&&(g=t.parse(a["text-font"],1,pd(co)),!g))return null;let C=null;if(a["text-color"]&&(C=t.parse(a["text-color"],1,Mp),!C))return null;const B=i[i.length-1];B.scale=h,B.font=g,B.textColor=C}else{const h=t.parse(n[s],1,Ji);if(!h)return null;const g=h.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:h,scale:null,font:null,textColor:null})}}return new w5(i)}evaluate(n){const t=r=>{const i=r.content.evaluate(n);return ql(i)===JC?new xE("",i,null,null,null):new xE(K_(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 lh(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 M5{constructor(n){this.type=JC,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 M5(r):t.error("No image name provided.")}evaluate(n){const t=this.input.evaluate(n),r=Bp.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 aAe={"to-boolean":Zi,"to-color":Mp,"to-number":er,"to-string":co};class L7{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=aAe[r],o=[];for(let s=1;s<n.length;s++){const a=t.parse(n[s],s,Ji);if(!a)return null;o.push(a)}return new L7(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 Vl)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=wj(t[0],t[1],t[2],t[3]),!r))return new Vl(t[0]/255,t[1]/255,t[2]/255,t[3])}throw new Tu(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 Tu(`Could not convert ${JSON.stringify(t)} to number.`)}else return this.type.kind==="formatted"?lh.fromString(K_(this.args[0].evaluate(n))):this.type.kind==="resolvedImage"?Bp.fromString(K_(this.args[0].evaluate(n))):K_(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 w5([{content:this.args[0],scale:null,font:null,textColor:null}]).serialize();if(this.type.kind==="resolvedImage")return new M5(this.args[0]).serialize();const n=[`to-${this.type.kind}`];return this.eachChild(t=>{n.push(t.serialize())}),n}}var jg=L7;const sAe=["Unknown","Point","LineString","Polygon"];class lAe{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"?sAe[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],h=this.featureDistanceData.bearing[1];return a*o+h*s}return 0}parseColor(n){let t=this._parseColorCache[n];return t||(t=this._parseColorCache[n]=Vl.parse(n)),t}}var Mj=lAe;class Wg{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=Wg.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 h=null;for(const[g,C]of a){h=new kj(t.registry,t.path,null,t.scope);const B=[];let k=!1;for(let P=1;P<n.length;P++){const L=n[P],J=Array.isArray(g)?g[P-1]:g.type,N=h.parse(L,1+B.length,J);if(!N){k=!0;break}B.push(N)}if(!k){if(Array.isArray(g)&&g.length!==B.length){h.error(`Expected ${g.length} arguments, but found ${B.length} instead.`);continue}for(let P=0;P<B.length;P++){const L=Array.isArray(g)?g[P]:g.type,J=B[P];h.concat(P+1).checkSubtype(L,J.type)}if(h.errors.length===0)return new Wg(r,o,C,B)}}if(a.length===1)t.errors.push(...h.errors);else{const C=(a.length?a:s).map(([k])=>uAe(k)).join(" | "),B=[];for(let k=1;k<n.length;k++){const P=t.parse(n[k],1+B.length);if(!P)return null;B.push(ks(P.type))}t.error(`Expected arguments of type ${C}, but found (${B.join(", ")}) instead.`)}return null}static register(n,t){Wg.definitions=t;for(const r in t)n[r]=Wg}}function uAe(e){return Array.isArray(e)?`(${e.map(ks).join(", ")})`:`(${ks(e.type)}...)`}var Yy=Wg;class S5{constructor(n,t,r){this.type=b5,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,Zi);if(!i)return null;const o=t.parse(r["diacritic-sensitive"]===void 0?!1:r["diacritic-sensitive"],1,Zi);if(!o)return null;let s=null;return r.locale&&(s=t.parse(r.locale,1,co),!s)?null:new S5(i,o,s)}evaluate(n){return new P7(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 Lm=8192;function U7(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 AAe(e){return(180+e)/360}function cAe(e){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+e*Math.PI/360)))/360}function z3(e,n){return!(e[0]<=n[0]||e[2]>=n[2]||e[1]<=n[1]||e[3]>=n[3])}function dAe(e,n){const t=AAe(e[0]),r=cAe(e[1]),i=Math.pow(2,n.z);return[Math.round(t*i*Lm),Math.round(r*i*Lm)]}function hAe(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 fAe(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 R7(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(hAe(e,o[s],o[s+1]))return!1;fAe(e,o[s],o[s+1])&&(t=!t)}}return t}function pAe(e,n){for(let t=0;t<n.length;t++)if(R7(e,n[t]))return!0;return!1}function mAe(e,n){return e[0]*n[1]-e[1]*n[0]}function wT(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],h=r[0]-t[0],g=r[1]-t[1],C=i*g-h*o,B=s*g-h*a;return C>0&&B<0||C<0&&B>0}function gAe(e,n,t,r){const i=[n[0]-e[0],n[1]-e[1]],o=[r[0]-t[0],r[1]-t[1]];return mAe(o,i)===0?!1:!!(wT(e,n,t,r)&&wT(t,r,e,n))}function yAe(e,n,t){for(const r of t)for(let i=0;i<r.length-1;++i)if(gAe(e,n,r[i],r[i+1]))return!0;return!1}function Sj(e,n){for(let t=0;t<e.length;++t)if(!R7(e[t],n))return!1;for(let t=0;t<e.length-1;++t)if(yAe(e[t],e[t+1],n))return!1;return!0}function vAe(e,n){for(let t=0;t<n.length;t++)if(Sj(e,n[t]))return!0;return!1}function z7(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=dAe(e[i][s],t);U7(n,a),o.push(a)}r.push(o)}return r}function Ej(e,n,t){const r=[];for(let i=0;i<e.length;i++){const o=z7(e[i],n,t);r.push(o)}return r}function Oj(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}U7(n,e)}function _Ae(e){e[0]=e[1]=1/0,e[2]=e[3]=-1/0}function MT(e,n,t,r){const i=Math.pow(2,r.z)*Lm,o=[r.x*Lm,r.y*Lm],s=[];if(!e)return s;for(const a of e)for(const h of a){const g=[h.x+o[0],h.y+o[1]];Oj(g,n,t,i),s.push(g)}return s}function ST(e,n,t,r){const i=Math.pow(2,r.z)*Lm,o=[r.x*Lm,r.y*Lm],s=[];if(!e)return s;for(const a of e){const h=[];for(const g of a){const C=[g.x+o[0],g.y+o[1]];U7(n,C),h.push(C)}s.push(h)}if(n[2]-n[0]<=i/2){_Ae(n);for(const a of s)for(const h of a)Oj(h,n,t,i)}return s}function CAe(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=z7(n.coordinates,r,i),s=MT(e.geometry(),t,r,i);if(!z3(t,r))return!1;for(const a of s)if(!R7(a,o))return!1}if(n.type==="MultiPolygon"){const o=Ej(n.coordinates,r,i),s=MT(e.geometry(),t,r,i);if(!z3(t,r))return!1;for(const a of s)if(!pAe(a,o))return!1}return!0}function bAe(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=z7(n.coordinates,r,i),s=ST(e.geometry(),t,r,i);if(!z3(t,r))return!1;for(const a of s)if(!Sj(a,o))return!1}if(n.type==="MultiPolygon"){const o=Ej(n.coordinates,r,i),s=ST(e.geometry(),t,r,i);if(!z3(t,r))return!1;for(const a of s)if(!vAe(a,o))return!1}return!0}class P_{constructor(n,t){this.type=Zi,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(U3(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 P_(r,r.features[i].geometry)}else if(r.type==="Feature"){const i=r.geometry.type;if(i==="Polygon"||i==="MultiPolygon")return new P_(r,r.geometry)}else if(r.type==="Polygon"||r.type==="MultiPolygon")return new P_(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 CAe(n,this.geometries);if(n.geometryType()==="LineString")return bAe(n,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}serialize(){return["within",this.geojson]}}var j7=P_;function E5(e){if(e instanceof Yy){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 j7)return!1;let n=!0;return e.eachChild(t=>{n&&!E5(t)&&(n=!1)}),n}function W7(e){if(e instanceof Yy&&e.name==="feature-state")return!1;let n=!0;return e.eachChild(t=>{n&&!W7(t)&&(n=!1)}),n}function N7(e,n){if(e instanceof Yy&&n.indexOf(e.name)>=0)return!1;let t=!0;return e.eachChild(r=>{t&&!N7(r,n)&&(t=!1)}),t}class G7{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 G7(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 Bj=G7;class Q7{constructor(n,t=[],r,i=new eAe,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 yp(o,[i]):s==="coerce"?new jg(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,h=s.type;if((a.kind==="string"||a.kind==="number"||a.kind==="boolean"||a.kind==="object"||a.kind==="array")&&h.kind==="value")s=r(s,a,t.typeAnnotation||"assert");else if((a.kind==="color"||a.kind==="formatted"||a.kind==="resolvedImage")&&(h.kind==="value"||h.kind==="string"))s=r(s,a,t.typeAnnotation||"coerce");else if(this.checkSubtype(a,h))return null}if(!(s instanceof R3)&&s.type.kind!=="resolvedImage"&&wE(s)){const a=new Mj;try{s=new R3(s.type,s.evaluate(a))}catch(h){return this.error(h.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 Q7(this.registry,i,t||null,o,this.errors)}error(n,...t){const r=`${this.key}${t.map(i=>`[${i}]`).join("")}`;this.errors.push(new sf(r,n))}checkSubtype(n,t){const r=_C(n,t);return r&&this.error(r),r}}var kj=Q7;function wE(e){if(e instanceof Bj)return wE(e.boundExpression);if(e instanceof Yy&&e.name==="error")return!1;if(e instanceof S5)return!1;if(e instanceof j7)return!1;const n=e instanceof jg||e instanceof yp;let t=!0;return e.eachChild(r=>{n?t=t&&wE(r):t=t&&r instanceof R3}),t?E5(e)&&N7(e,["zoom","heatmap-density","line-progress","sky-radial-progress","accumulated","is-supported-script","pitch","distance-from-center"]):!1}function O5(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 Tu("Input is not a number.");return 0}class $7{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,er);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],h=n[s+1],g=s,C=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 B=t.parse(h,C,o);if(!B)return null;o=o||B.type,i.push([a,B])}return new $7(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=O5(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 Ij=$7,xAe=Tj;function Tj(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}Tj.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 Dc(e,n,t){return e*(1-t)+n*t}function wAe(e,n,t){return new Vl(Dc(e.r,n.r,t),Dc(e.g,n.g,t),Dc(e.b,n.b,t),Dc(e.a,n.a,t))}function MAe(e,n,t){return e.map((r,i)=>Dc(r,n[i],t))}var Kj=Object.freeze({__proto__:null,number:Dc,color:wAe,array:MAe});const Pj=.95047,Fj=1,Dj=1.08883,Lj=4/29,uy=6/29,Uj=3*uy*uy,SAe=uy*uy*uy,EAe=Math.PI/180,OAe=180/Math.PI;function FM(e){return e>SAe?Math.pow(e,1/3):e/Uj+Lj}function DM(e){return e>uy?e*e*e:Uj*(e-Lj)}function LM(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function UM(e){return e/=255,e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function Rj(e){const n=UM(e.r),t=UM(e.g),r=UM(e.b),i=FM((.4124564*n+.3575761*t+.1804375*r)/Pj),o=FM((.2126729*n+.7151522*t+.072175*r)/Fj),s=FM((.0193339*n+.119192*t+.9503041*r)/Dj);return{l:116*o-16,a:500*(i-o),b:200*(o-s),alpha:e.a}}function zj(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=Fj*DM(n),t=Pj*DM(t),r=Dj*DM(r),new Vl(LM(3.2404542*t-1.5371385*n-.4985314*r),LM(-.969266*t+1.8760108*n+.041556*r),LM(.0556434*t-.2040259*n+1.0572252*r),e.alpha)}function BAe(e,n,t){return{l:Dc(e.l,n.l,t),a:Dc(e.a,n.a,t),b:Dc(e.b,n.b,t),alpha:Dc(e.alpha,n.alpha,t)}}function kAe(e){const{l:n,a:t,b:r}=Rj(e),i=Math.atan2(r,t)*OAe;return{h:i<0?i+360:i,c:Math.sqrt(t*t+r*r),l:n,alpha:e.a}}function IAe(e){const n=e.h*EAe,t=e.c,r=e.l;return zj({l:r,a:Math.cos(n)*t,b:Math.sin(n)*t,alpha:e.alpha})}function TAe(e,n,t){const r=n-e;return e+t*(r>180||r<-180?r-360*Math.round(r/360):r)}function KAe(e,n,t){return{h:TAe(e.h,n.h,t),c:Dc(e.c,n.c,t),l:Dc(e.l,n.l,t),alpha:Dc(e.alpha,n.alpha,t)}}const u_={forward:Rj,reverse:zj,interpolate:BAe},A_={forward:kAe,reverse:IAe,interpolate:KAe};var jj=Object.freeze({__proto__:null,lab:u_,hcl:A_});class j3{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=RM(t,n.base,r,i);else if(n.name==="linear")o=RM(t,1,r,i);else if(n.name==="cubic-bezier"){const s=n.controlPoints;o=new xAe(s[0],s[1],s[2],s[3]).solve(RM(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(C=>typeof C!="number"||C<0||C>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,er),!o)return null;const a=[];let h=null;r==="interpolate-hcl"||r==="interpolate-lab"?h=Mp:t.expectedType&&t.expectedType.kind!=="value"&&(h=t.expectedType);for(let g=0;g<s.length;g+=2){const C=s[g],B=s[g+1],k=g+3,P=g+4;if(typeof C!="number")return t.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',k);if(a.length&&a[a.length-1][0]>=C)return t.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',k);const L=t.parse(B,P,h);if(!L)return null;h=h||L.type,a.push([C,L])}return h.kind!=="number"&&h.kind!=="color"&&!(h.kind==="array"&&h.itemType.kind==="number"&&typeof h.N=="number")?t.error(`Type ${ks(h)} is not interpolatable.`):new j3(h,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=O5(t,i),a=t[s],h=t[s+1],g=j3.interpolationFactor(this.interpolation,i,a,h),C=r[s].evaluate(n),B=r[s+1].evaluate(n);return this.operator==="interpolate"?Kj[this.type.kind.toLowerCase()](C,B,g):this.operator==="interpolate-hcl"?A_.reverse(A_.interpolate(A_.forward(C),A_.forward(B),g)):u_.reverse(u_.interpolate(u_.forward(C),u_.forward(B),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 RM(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 Sp=j3;class W3{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 h=t.parse(a,1+o.length,r,void 0,{typeAnnotation:"omit"});if(!h)return null;r=r||h.type,o.push(h)}return i&&o.some(a=>_C(i,a.type))?new W3(Ji,o):new W3(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 Bp&&!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 Wj=W3;class Y7{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 Y7(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 Nj=Y7;class q7{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,er),i=t.parse(n[2],2,pd(t.expectedType||Ji));if(!r||!i)return null;const o=i.type;return new q7(o.itemType,r,i)}evaluate(n){const t=this.index.evaluate(n),r=this.input.evaluate(n);if(t<0)throw new Tu(`Array index out of bounds: ${t} < 0.`);if(t>=r.length)throw new Tu(`Array index out of bounds: ${t} > ${r.length-1}.`);if(t!==Math.floor(t))throw new Tu(`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 PAe=q7;class H7{constructor(n,t){this.type=Zi,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,Ji),i=t.parse(n[2],2,Ji);return!r||!i?null:K7(r.type,[Zi,co,er,C5,Ji])?new H7(r,i):t.error(`Expected first argument to be of type boolean, string, number or null, but found ${ks(r.type)} instead`)}evaluate(n){const t=this.needle.evaluate(n),r=this.haystack.evaluate(n);if(r==null)return!1;if(!CC(t,["boolean","string","number","null"]))throw new Tu(`Expected first argument to be of type boolean, string, number or null, but found ${ks(ql(t))} instead.`);if(!CC(r,["string","array"]))throw new Tu(`Expected second argument to be of type array or string, but found ${ks(ql(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 FAe=H7;class N3{constructor(n,t,r){this.type=er,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,Ji),i=t.parse(n[2],2,Ji);if(!r||!i)return null;if(!K7(r.type,[Zi,co,er,C5,Ji]))return t.error(`Expected first argument to be of type boolean, string, number or null, but found ${ks(r.type)} instead`);if(n.length===4){const o=t.parse(n[3],3,er);return o?new N3(r,i,o):null}else return new N3(r,i)}evaluate(n){const t=this.needle.evaluate(n),r=this.haystack.evaluate(n);if(!CC(t,["boolean","string","number","null"]))throw new Tu(`Expected first argument to be of type boolean, string, number or null, but found ${ks(ql(t))} instead.`);if(!CC(r,["string","array"]))throw new Tu(`Expected second argument to be of type array or string, but found ${ks(ql(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 DAe=N3;class V7{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 C=n[g];const B=n[g+1];Array.isArray(C)||(C=[C]);const k=t.concat(g);if(C.length===0)return k.error("Expected at least one branch label.");for(const L of C){if(typeof L!="number"&&typeof L!="string")return k.error("Branch labels must be numbers or strings.");if(typeof L=="number"&&Math.abs(L)>Number.MAX_SAFE_INTEGER)return k.error(`Branch labels must be integers no larger than ${Number.MAX_SAFE_INTEGER}.`);if(typeof L=="number"&&Math.floor(L)!==L)return k.error("Numeric branch labels must be integer values.");if(!r)r=ql(L);else if(k.checkSubtype(r,ql(L)))return null;if(typeof o[String(L)]<"u")return k.error("Branch labels must be unique.");o[String(L)]=s.length}const P=t.parse(B,g,i);if(!P)return null;i=i||P.type,s.push(P)}const a=t.parse(n[1],1,Ji);if(!a)return null;const h=t.parse(n[n.length-1],n.length-1,i);return!h||a.type.kind!=="value"&&t.concat(1).checkSubtype(r,a.type)?null:new V7(r,i,a,o,s,h)}evaluate(n){const t=this.input.evaluate(n);return(ql(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 LAe=V7;class Z7{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,Zi);if(!a)return null;const h=t.parse(n[s+1],s+1,r);if(!h)return null;i.push([a,h]),r=r||h.type}const o=t.parse(n[n.length-1],n.length-1,r);return o?new Z7(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 UAe=Z7;class G3{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,Ji),i=t.parse(n[2],2,er);if(!r||!i)return null;if(!K7(r.type,[pd(Ji),co,Ji]))return t.error(`Expected first argument to be of type array or string, but found ${ks(r.type)} instead`);if(n.length===4){const o=t.parse(n[3],3,er);return o?new G3(r.type,r,i,o):null}else return new G3(r.type,r,i)}evaluate(n){const t=this.input.evaluate(n),r=this.beginIndex.evaluate(n);if(!CC(t,["string","array"]))throw new Tu(`Expected first argument to be of type array or string, but found ${ks(ql(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 RAe=G3;function ET(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 zAe(e,n,t){return n===t}function jAe(e,n,t){return n!==t}function WAe(e,n,t){return n<t}function NAe(e,n,t){return n>t}function GAe(e,n,t){return n<=t}function QAe(e,n,t){return n>=t}function Gj(e,n,t,r){return r.compare(n,t)===0}function $Ae(e,n,t,r){return!Gj(e,n,t,r)}function YAe(e,n,t,r){return r.compare(n,t)<0}function qAe(e,n,t,r){return r.compare(n,t)>0}function HAe(e,n,t,r){return r.compare(n,t)<=0}function VAe(e,n,t,r){return r.compare(n,t)>=0}function qy(e,n,t){const r=e!=="=="&&e!=="!=";return class Qj{constructor(o,s,a){this.type=Zi,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 h=s.parse(o[1],1,Ji);if(!h)return null;if(!ET(a,h.type))return s.concat(1).error(`"${a}" comparisons are not supported for type '${ks(h.type)}'.`);let g=s.parse(o[2],2,Ji);if(!g)return null;if(!ET(a,g.type))return s.concat(2).error(`"${a}" comparisons are not supported for type '${ks(g.type)}'.`);if(h.type.kind!==g.type.kind&&h.type.kind!=="value"&&g.type.kind!=="value")return s.error(`Cannot compare types '${ks(h.type)}' and '${ks(g.type)}'.`);r&&(h.type.kind==="value"&&g.type.kind!=="value"?h=new yp(g.type,[h]):h.type.kind!=="value"&&g.type.kind==="value"&&(g=new yp(h.type,[g])));let C=null;if(o.length===4){if(h.type.kind!=="string"&&g.type.kind!=="string"&&h.type.kind!=="value"&&g.type.kind!=="value")return s.error("Cannot use collator to compare non-string types.");if(C=s.parse(o[3],3,b5),!C)return null}return new Qj(h,g,C)}evaluate(o){const s=this.lhs.evaluate(o),a=this.rhs.evaluate(o);if(r&&this.hasUntypedArgument){const h=ql(s),g=ql(a);if(h.kind!==g.kind||!(h.kind==="string"||h.kind==="number"))throw new Tu(`Expected arguments for "${e}" to be (string, string) or (number, number), but found (${h.kind}, ${g.kind}) instead.`)}if(this.collator&&!r&&this.hasUntypedArgument){const h=ql(s),g=ql(a);if(h.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 ZAe=qy("==",zAe,Gj),XAe=qy("!=",jAe,$Ae),JAe=qy("<",WAe,YAe),ece=qy(">",NAe,qAe),tce=qy("<=",GAe,HAe),nce=qy(">=",QAe,VAe);class X7{constructor(n,t,r,i,o,s){this.type=co,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,er);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.unit&&(a=t.parse(i.unit,1,co),!a))return null;let h=null;if(i["min-fraction-digits"]&&(h=t.parse(i["min-fraction-digits"],1,er),!h))return null;let g=null;return i["max-fraction-digits"]&&(g=t.parse(i["max-fraction-digits"],1,er),!g)?null:new X7(r,o,s,a,h,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=er,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 ${ks(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 Tu(`Expected value to be of type string or array, but found ${ks(ql(t))} instead.`)}eachChild(n){n(this.input)}outputDefined(){return!1}serialize(){const n=["length"];return this.eachChild(t=>{n.push(t.serialize())}),n}}var rce=J7;const $j={"==":ZAe,"!=":XAe,">":ece,"<":JAe,">=":nce,"<=":tce,array:yp,at:PAe,boolean:yp,case:UAe,coalesce:Wj,collator:S5,format:w5,image:M5,in:FAe,"index-of":DAe,interpolate:Sp,"interpolate-hcl":Sp,"interpolate-lab":Sp,length:rce,let:Nj,literal:R3,match:LAe,number:yp,"number-format":X7,object:yp,slice:RAe,step:Ij,string:yp,"to-boolean":jg,"to-color":jg,"to-number":jg,"to-string":jg,var:Bj,within:j7};function OT(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=wj(n,t,r,o);if(s)throw new Tu(s);return new Vl(n/255*o,t/255*o,r/255*o,o)}function BT(e,n){return e in n}function zM(e,n){const t=n[e];return typeof t>"u"?null:t}function ice(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 y0(e){return{type:e}}Yy.register($j,{error:[tAe,[co],(e,[n])=>{throw new Tu(n.evaluate(e))}],typeof:[co,[Ji],(e,[n])=>ks(ql(n.evaluate(e)))],"to-rgba":[pd(er,4),[Mp],(e,[n])=>n.evaluate(e).toArray()],rgb:[Mp,[er,er,er],OT],rgba:[Mp,[er,er,er,er],OT],has:{type:Zi,overloads:[[[co],(e,[n])=>BT(n.evaluate(e),e.properties())],[[co,ly],(e,[n,t])=>BT(n.evaluate(e),t.evaluate(e))]]},get:{type:Ji,overloads:[[[co],(e,[n])=>zM(n.evaluate(e),e.properties())],[[co,ly],(e,[n,t])=>zM(n.evaluate(e),t.evaluate(e))]]},"feature-state":[Ji,[co],(e,[n])=>zM(n.evaluate(e),e.featureState||{})],properties:[ly,[],e=>e.properties()],"geometry-type":[co,[],e=>e.geometryType()],id:[Ji,[],e=>e.id()],zoom:[er,[],e=>e.globals.zoom],pitch:[er,[],e=>e.globals.pitch||0],"distance-from-center":[er,[],e=>e.distanceFromCenter()],"heatmap-density":[er,[],e=>e.globals.heatmapDensity||0],"line-progress":[er,[],e=>e.globals.lineProgress||0],"sky-radial-progress":[er,[],e=>e.globals.skyRadialProgress||0],accumulated:[Ji,[],e=>e.globals.accumulated===void 0?null:e.globals.accumulated],"+":[er,y0(er),(e,n)=>{let t=0;for(const r of n)t+=r.evaluate(e);return t}],"*":[er,y0(er),(e,n)=>{let t=1;for(const r of n)t*=r.evaluate(e);return t}],"-":{type:er,overloads:[[[er,er],(e,[n,t])=>n.evaluate(e)-t.evaluate(e)],[[er],(e,[n])=>-n.evaluate(e)]]},"/":[er,[er,er],(e,[n,t])=>n.evaluate(e)/t.evaluate(e)],"%":[er,[er,er],(e,[n,t])=>n.evaluate(e)%t.evaluate(e)],ln2:[er,[],()=>Math.LN2],pi:[er,[],()=>Math.PI],e:[er,[],()=>Math.E],"^":[er,[er,er],(e,[n,t])=>Math.pow(n.evaluate(e),t.evaluate(e))],sqrt:[er,[er],(e,[n])=>Math.sqrt(n.evaluate(e))],log10:[er,[er],(e,[n])=>Math.log(n.evaluate(e))/Math.LN10],ln:[er,[er],(e,[n])=>Math.log(n.evaluate(e))],log2:[er,[er],(e,[n])=>Math.log(n.evaluate(e))/Math.LN2],sin:[er,[er],(e,[n])=>Math.sin(n.evaluate(e))],cos:[er,[er],(e,[n])=>Math.cos(n.evaluate(e))],tan:[er,[er],(e,[n])=>Math.tan(n.evaluate(e))],asin:[er,[er],(e,[n])=>Math.asin(n.evaluate(e))],acos:[er,[er],(e,[n])=>Math.acos(n.evaluate(e))],atan:[er,[er],(e,[n])=>Math.atan(n.evaluate(e))],min:[er,y0(er),(e,n)=>Math.min(...n.map(t=>t.evaluate(e)))],max:[er,y0(er),(e,n)=>Math.max(...n.map(t=>t.evaluate(e)))],abs:[er,[er],(e,[n])=>Math.abs(n.evaluate(e))],round:[er,[er],(e,[n])=>{const t=n.evaluate(e);return t<0?-Math.round(-t):Math.round(t)}],floor:[er,[er],(e,[n])=>Math.floor(n.evaluate(e))],ceil:[er,[er],(e,[n])=>Math.ceil(n.evaluate(e))],"filter-==":[Zi,[co,Ji],(e,[n,t])=>e.properties()[n.value]===t.value],"filter-id-==":[Zi,[Ji],(e,[n])=>e.id()===n.value],"filter-type-==":[Zi,[co],(e,[n])=>e.geometryType()===n.value],"filter-<":[Zi,[co,Ji],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r<i}],"filter-id-<":[Zi,[Ji],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t<r}],"filter->":[Zi,[co,Ji],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r>i}],"filter-id->":[Zi,[Ji],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t>r}],"filter-<=":[Zi,[co,Ji],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r<=i}],"filter-id-<=":[Zi,[Ji],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t<=r}],"filter->=":[Zi,[co,Ji],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r>=i}],"filter-id->=":[Zi,[Ji],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t>=r}],"filter-has":[Zi,[Ji],(e,[n])=>n.value in e.properties()],"filter-has-id":[Zi,[],e=>e.id()!==null&&e.id()!==void 0],"filter-type-in":[Zi,[pd(co)],(e,[n])=>n.value.indexOf(e.geometryType())>=0],"filter-id-in":[Zi,[pd(Ji)],(e,[n])=>n.value.indexOf(e.id())>=0],"filter-in-small":[Zi,[co,pd(Ji)],(e,[n,t])=>t.value.indexOf(e.properties()[n.value])>=0],"filter-in-large":[Zi,[co,pd(Ji)],(e,[n,t])=>ice(e.properties()[n.value],t.value,0,t.value.length-1)],all:{type:Zi,overloads:[[[Zi,Zi],(e,[n,t])=>n.evaluate(e)&&t.evaluate(e)],[y0(Zi),(e,n)=>{for(const t of n)if(!t.evaluate(e))return!1;return!0}]]},any:{type:Zi,overloads:[[[Zi,Zi],(e,[n,t])=>n.evaluate(e)||t.evaluate(e)],[y0(Zi),(e,n)=>{for(const t of n)if(t.evaluate(e))return!0;return!1}]]},"!":[Zi,[Zi],(e,[n])=>!n.evaluate(e)],"is-supported-script":[Zi,[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,y0(Ji),(e,n)=>n.map(t=>K_(t.evaluate(e))).join("")],"resolved-locale":[co,[b5],(e,[n])=>n.evaluate(e).resolvedLocale()]});var Yj=$j;function ME(e){return{result:"success",value:e}}function Og(e){return{result:"error",value:e}}function oce(e){return e["property-type"]==="data-driven"}function ace(e){return!!e.expression&&e.expression.parameters.indexOf("zoom")>-1}function qj(e){return!!e.expression&&e.expression.interpolated}function e8(e){return e instanceof Number?"number":e instanceof String?"string":e instanceof Boolean?"boolean":Array.isArray(e)?"array":e===null?"null":typeof e}function t8(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function sce(e){return e}function n8(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||(qj(n)?"exponential":"interval");if(t&&(e=bj({},e),e.stops&&(e.stops=e.stops.map(C=>[C[0],Vl.parse(C[1])])),e.default?e.default=Vl.parse(e.default):e.default=Vl.parse(n.default)),e.colorSpace&&e.colorSpace!=="rgb"&&!jj[e.colorSpace])throw new Error(`Unknown color space: ${e.colorSpace}`);let a,h,g;if(s==="exponential")a=kT;else if(s==="interval")a=uce;else if(s==="categorical"){a=lce,h=Object.create(null);for(const C of e.stops)h[C[0]]=C[1];g=typeof e.stops[0][0]}else if(s==="identity")a=Ace;else throw new Error(`Unknown function type "${s}"`);if(r){const C={},B=[];for(let L=0;L<e.stops.length;L++){const J=e.stops[L],N=J[0].zoom;C[N]===void 0&&(C[N]={zoom:N,type:e.type,property:e.property,default:e.default,stops:[]},B.push(N)),C[N].stops.push([J[0].value,J[1]])}const k=[];for(const L of B)k.push([C[L].zoom,n8(C[L],n)]);const P={name:"linear"};return{kind:"composite",interpolationType:P,interpolationFactor:Sp.interpolationFactor.bind(void 0,P),zoomStops:k.map(L=>L[0]),evaluate({zoom:L},J){return kT({stops:k,base:e.base},n,L).evaluate(L,J)}}}else if(o){const C=s==="exponential"?{name:"exponential",base:e.base!==void 0?e.base:1}:null;return{kind:"camera",interpolationType:C,interpolationFactor:Sp.interpolationFactor.bind(void 0,C),zoomStops:e.stops.map(B=>B[0]),evaluate:({zoom:B})=>a(e,n,B,h,g)}}else return{kind:"source",evaluate(C,B){const k=B&&B.properties?B.properties[e.property]:void 0;return k===void 0?eb(e.default,n.default):a(e,n,k,h,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 lce(e,n,t,r,i){const o=typeof t===i?r[t]:void 0;return eb(o,e.default,n.default)}function uce(e,n,t){if(e8(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=O5(e.stops.map(o=>o[0]),t);return e.stops[i][1]}function kT(e,n,t){const r=e.base!==void 0?e.base:1;if(e8(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=O5(e.stops.map(C=>C[0]),t),s=cce(t,r,e.stops[o][0],e.stops[o+1][0]),a=e.stops[o][1],h=e.stops[o+1][1];let g=Kj[n.type]||sce;if(e.colorSpace&&e.colorSpace!=="rgb"){const C=jj[e.colorSpace];g=(B,k)=>C.reverse(C.interpolate(C.forward(B),C.forward(k),s))}return typeof a.evaluate=="function"?{evaluate(...C){const B=a.evaluate.apply(void 0,C),k=h.evaluate.apply(void 0,C);if(!(B===void 0||k===void 0))return g(B,k,s)}}:g(a,h,s)}function Ace(e,n,t){return n.type==="color"?t=Vl.parse(t):n.type==="formatted"?t=lh.fromString(t.toString()):n.type==="resolvedImage"?t=Bp.fromString(t.toString()):e8(t)!==n.type&&(n.type!=="enum"||!n.values[t])&&(t=void 0),eb(t,e.default,n.default)}function cce(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 Hj{constructor(n,t){this.expression=n,this._warningHistory={},this._evaluator=new Mj,this._defaultValue=t?fce(t):null,this._enumValues=t&&t.type==="enum"?t.values:null}evaluateWithoutErrorHandling(n,t,r,i,o,s,a,h){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=h||null,this.expression.evaluate(this._evaluator)}evaluate(n,t,r,i,o,s,a,h){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=h||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 Tu(`Expected value to be one of ${Object.keys(this._enumValues).map(C=>JSON.stringify(C)).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 Vj(e){return Array.isArray(e)&&e.length>0&&typeof e[0]=="string"&&e[0]in Yj}function Q3(e,n){const t=new kj(Yj,[],n?hce(n):void 0),r=t.parse(e,void 0,void 0,void 0,n&&n.type==="string"?{typeAnnotation:"coerce"}:void 0);return r?ME(new Hj(r,n)):Og(t.errors)}class SE{constructor(n,t){this.kind=n,this._styleExpression=t,this.isStateDependent=n!=="constant"&&!W7(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 EE{constructor(n,t,r,i){this.kind=n,this.zoomStops=r,this._styleExpression=t,this.isStateDependent=n!=="camera"&&!W7(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?Sp.interpolationFactor(this.interpolationType,n,t,r):0}}function Zj(e,n){if(e=Q3(e,n),e.result==="error")return e;const t=e.value.expression,r=E5(t);if(!r&&!oce(n))return Og([new sf("","data expressions not supported")]);const i=N7(t,["zoom","pitch","distance-from-center"]);if(!i&&!ace(n))return Og([new sf("","zoom expressions not supported")]);const o=b2(t);if(!o&&!i)return Og([new sf("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')]);if(o instanceof sf)return Og([o]);if(o instanceof Sp&&!qj(n))return Og([new sf("",'"interpolate" expressions cannot be used with this property')]);if(!o)return ME(r?new SE("constant",e.value):new SE("source",e.value));const s=o instanceof Sp?o.interpolation:void 0;return ME(r?new EE("camera",e.value,o.labels,s):new EE("composite",e.value,o.labels,s))}class B5{constructor(n,t){this._parameters=n,this._specification=t,bj(this,n8(this._parameters,this._specification))}static deserialize(n){return new B5(n._parameters,n._specification)}static serialize(n){return{_parameters:n._parameters,_specification:n._specification}}}function dce(e,n){if(t8(e))return new B5(e,n);if(Vj(e)){const t=Zj(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=Vl.parse(e)),{kind:"constant",evaluate:()=>t}}}function b2(e){let n=null;if(e instanceof Nj)n=b2(e.result);else if(e instanceof Wj){for(const t of e.args)if(n=b2(t),n)break}else(e instanceof Ij||e instanceof Sp)&&e.input instanceof Yy&&e.input.name==="zoom"&&(n=e);return n instanceof sf||e.eachChild(t=>{const r=b2(t);r instanceof sf?n=r:!n&&r?n=new sf("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):n&&r&&n!==r&&(n=new sf("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),n}function hce(e){const n={color:Mp,string:co,number:er,enum:co,boolean:Zi,formatted:x5,resolvedImage:JC};return e.type==="array"?pd(n[e.value]||Ji,e.length):n[e.type]}function fce(e){return e.type==="color"&&(t8(e.default)||Array.isArray(e.default))?new Vl(0,0,0,0):e.type==="color"?Vl.parse(e.default)||null:e.default===void 0?null:e.default}function bC(e){return typeof e=="object"?["literal",e]:e}function pce(e,n){let t=e.stops;if(!t)return mce(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],_ce(s[1])]:[s[0],bC(s[1])]),r?gce(e,n,t):o?vce(e,n,t):OE(e,n,t)}function mce(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,bC(e.default)];return n.type==="array"&&r.splice(1,0,n.value,n.length||null),r}}function r8(e){switch(e.colorSpace){case"hcl":return"interpolate-hcl";case"lab":return"interpolate-lab";default:return"interpolate"}}function gce(e,n,t){const r={},i={},o=[];for(let a=0;a<t.length;a++){const h=t[a],g=h[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([h[0].value,h[1]])}if(o8({},n)==="exponential"){const a=[r8(e),["linear"],["zoom"]];for(const h of o){const g=OE(r[h],n,i[h]);Ay(a,h,g,!1)}return a}else{const a=["step",["zoom"]];for(const h of o){const g=OE(r[h],n,i[h]);Ay(a,h,g,!0)}return i8(a),a}}function yce(e,n){if(e!==void 0)return e;if(n!==void 0)return n}function IT(e,n){const t=bC(yce(e.default,n.default));return t===void 0&&n.type==="resolvedImage"?"":t}function OE(e,n,t){const r=o8(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(IT(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(IT(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 i8(o),e.default===void 0?o:["case",["==",["typeof",i],"number"],o,bC(e.default)]}else if(r==="exponential"){const o=e.base!==void 0?e.base:1,s=[r8(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,bC(e.default)]}else throw new Error(`Unknown property function type ${r}`)}function vce(e,n,t,r=["zoom"]){const i=o8(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=[r8(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 i8(o),o}function i8(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 o8(e,n){return e.type?e.type:n.expression.interpolated?"exponential":"interval"}function _ce(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 Cce(e){return e instanceof Number||e instanceof String||e instanceof Boolean?e.valueOf():e}function BE(e){if(Array.isArray(e))return e.map(BE);if(e instanceof Object&&!(e instanceof Number||e instanceof String||e instanceof Boolean)){const n={};for(const t in e)n[t]=BE(e[t]);return n}return Cce(e)}function a8(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(!a8(n)&&typeof n!="boolean")return!1;return!0;default:return!0}}function bce(e,n="fill"){if(e==null)return{filter:()=>!0,needGeometry:!1,needFeature:!1};a8(e)||(e=$3(e));const t=e;let r=!0;try{r=xce(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=Cj[`filter_${n}`],o=Q3(r,i);let s=null;if(o.result==="error")throw new Error(o.value.map(C=>`${C.key}: ${C.message}`).join(", "));s=(C,B,k)=>o.value.evaluate(C,B,{},k);let a=null,h=null;if(r!==t){const C=Q3(t,i);if(C.result==="error")throw new Error(C.value.map(B=>`${B.key}: ${B.message}`).join(", "));a=(B,k,P,L,J)=>C.value.evaluate(B,k,{},P,void 0,void 0,L,J),h=!E5(C.value.expression)}s=s;const g=eW(r);return{filter:s,dynamicFilter:a||void 0,needGeometry:g,needFeature:!!h}}function xce(e){if(!cy(e))return e;let n=BE(e);return Jj(n),n=Xj(n),n}function Xj(e){if(!Array.isArray(e))return e;const n=Sce(e);return n===!0?n:n.map(t=>Xj(t))}function Jj(e){let n=!1;const t=[];if(e[0]==="case"){for(let r=1;r<e.length-1;r+=2)n=n||cy(e[r]),t.push(e[r+1]);t.push(e[e.length-1])}else if(e[0]==="match"){n=n||cy(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||cy(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++)Jj(e[r])}function cy(e){if(!Array.isArray(e))return!1;if(wce(e[0]))return!0;for(let n=1;n<e.length;n++){const t=e[n];if(cy(t))return!0}return!1}function wce(e){return e==="pitch"||e==="distance-from-center"}const Mce=new Set(["in","==","!=",">",">=","<","<=","to-boolean"]);function Sce(e){if(Mce.has(e[0]))for(let n=1;n<e.length;n++){const t=e[n];if(cy(t))return!0}return e}function Ece(e,n){return e<n?-1:e>n?1:0}function eW(e){if(!Array.isArray(e))return!1;if(e[0]==="within")return!0;for(let n=1;n<e.length;n++)if(eW(e[n]))return!0;return!1}function $3(e){if(!e)return!0;const n=e[0];return e.length<=1?n!=="any":n==="=="?jM(e[1],e[2],"=="):n==="!="?Fx(jM(e[1],e[2],"==")):n==="<"||n===">"||n==="<="||n===">="?jM(e[1],e[2],n):n==="any"?Oce(e.slice(1)):n==="all"?["all"].concat(e.slice(1).map($3)):n==="none"?["all"].concat(e.slice(1).map($3).map(Fx)):n==="in"?TT(e[1],e.slice(2)):n==="!in"?Fx(TT(e[1],e.slice(2))):n==="has"?KT(e[1]):n==="!has"?Fx(KT(e[1])):n==="within"?e:!0}function jM(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 Oce(e){return["any"].concat(e.map($3))}function TT(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(Ece)]]:["filter-in-small",e,["literal",n]]}}function KT(e){switch(e){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",e]}}function Fx(e){return["!",e]}var Bce=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function kce(e,n){const t={};for(const r in e)r!=="ref"&&(t[r]=e[r]);return Bce.forEach(r=>{r in n&&(t[r]=n[r])}),t}function Ice(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]=kce(e[t],n[e[t].ref]));return e}function Tce(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 Kce={};(function(e){var n=function(){var t=function(N,$,q,oe){for(q=q||{},oe=N.length;oe--;q[N[oe]]=$);return q},r=[1,12],i=[1,13],o=[1,9],s=[1,10],a=[1,11],h=[1,14],g=[1,15],C=[14,18,22,24],B=[18,22],k=[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,ce,me,he,V){var ae=he.length-1;switch(me){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.$=he[ae-1];case 13:this.$={},Object.defineProperty(this.$,"__line__",{value:this._$.first_line,enumerable:!1});break;case 14:case 19:this.$=he[ae-1],Object.defineProperty(this.$,"__line__",{value:this._$.first_line,enumerable:!1});break;case 15:this.$=[he[ae-2],he[ae]];break;case 16:this.$={},this.$[he[ae][0]]=he[ae][1];break;case 17:this.$=he[ae-2],he[ae-2][he[ae][0]]=he[ae][1];break;case 18:this.$=[],Object.defineProperty(this.$,"__line__",{value:this._$.first_line,enumerable:!1});break;case 20:this.$=[he[ae]];break;case 21:this.$=he[ae-2],he[ae-2].push(he[ae]);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:h,23:g},{1:[3]},{14:[1,16]},t(C,[2,7]),t(C,[2,8]),t(C,[2,9]),t(C,[2,10]),t(C,[2,11]),t(C,[2,12]),t(C,[2,3]),t(C,[2,4]),t(C,[2,5]),t([14,18,21,22,24],[2,1]),t(C,[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:h,23:g,24:[1,21],25:22},{1:[2,6]},t(C,[2,13]),{18:[1,24],22:[1,25]},t(B,[2,16]),{21:[1,26]},t(C,[2,18]),{22:[1,28],24:[1,27]},t(k,[2,20]),t(C,[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:h,23:g},t(C,[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:h,23:g},t(B,[2,17]),t(B,[2,15]),t(k,[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],ce=[null],me=[],he=this.table,V="",ae=0,ye=0,Oe=2,De=1,He=me.slice.call(arguments,1),ke=Object.create(this.lexer),nt={yy:{}};for(var be in this.yy)Object.prototype.hasOwnProperty.call(this.yy,be)&&(nt.yy[be]=this.yy[be]);ke.setInput($,nt.yy),nt.yy.lexer=ke,nt.yy.parser=this,typeof ke.yylloc>"u"&&(ke.yylloc={});var Bt=ke.yylloc;me.push(Bt);var kt=ke.options&&ke.options.ranges;typeof nt.yy.parseError=="function"?this.parseError=nt.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Yt(){var fe;return fe=ke.lex()||De,typeof fe!="number"&&(fe=q.symbols_[fe]||fe),fe}for(var jt,Xe,rt,ot,on={},gt,at,It,Lt;;){if(Xe=oe[oe.length-1],this.defaultActions[Xe]?rt=this.defaultActions[Xe]:((jt===null||typeof jt>"u")&&(jt=Yt()),rt=he[Xe]&&he[Xe][jt]),typeof rt>"u"||!rt.length||!rt[0]){var Me="";Lt=[];for(gt in he[Xe])this.terminals_[gt]&&gt>Oe&&Lt.push("'"+this.terminals_[gt]+"'");ke.showPosition?Me="Parse error on line "+(ae+1)+`:
`+ke.showPosition()+`
Expecting `+Lt.join(", ")+", got '"+(this.terminals_[jt]||jt)+"'":Me="Parse error on line "+(ae+1)+": Unexpected "+(jt==De?"end of input":"'"+(this.terminals_[jt]||jt)+"'"),this.parseError(Me,{text:ke.match,token:this.terminals_[jt]||jt,line:ke.yylineno,loc:Bt,expected:Lt})}if(rt[0]instanceof Array&&rt.length>1)throw new Error("Parse Error: multiple actions possible at state: "+Xe+", token: "+jt);switch(rt[0]){case 1:oe.push(jt),ce.push(ke.yytext),me.push(ke.yylloc),oe.push(rt[1]),jt=null,ye=ke.yyleng,V=ke.yytext,ae=ke.yylineno,Bt=ke.yylloc;break;case 2:if(at=this.productions_[rt[1]][1],on.$=ce[ce.length-at],on._$={first_line:me[me.length-(at||1)].first_line,last_line:me[me.length-1].last_line,first_column:me[me.length-(at||1)].first_column,last_column:me[me.length-1].last_column},kt&&(on._$.range=[me[me.length-(at||1)].range[0],me[me.length-1].range[1]]),ot=this.performAction.apply(on,[V,ye,ae,nt.yy,rt[1],ce,me].concat(He)),typeof ot<"u")return ot;at&&(oe=oe.slice(0,-1*at*2),ce=ce.slice(0,-1*at),me=me.slice(0,-1*at)),oe.push(this.productions_[rt[1]][0]),ce.push(on.$),me.push(on._$),It=he[oe[oe.length-2]][oe[oe.length-1]],oe.push(It);break;case 3:return!0}}return!0}},L=function(){var N={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 ce=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 me=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===ce.length?this.yylloc.first_column:0)+ce[ce.length-oe.length].length-oe[0].length:this.yylloc.first_column-q},this.options.ranges&&(this.yylloc.range=[me[0],me[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,ce,me;if(this.options.backtrack_lexer&&(me={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&&(me.yylloc.range=this.yylloc.range.slice(0))),ce=$[0].match(/(?:\r\n?|\n).*/g),ce&&(this.yylineno+=ce.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:ce?ce[ce.length-1].length-ce[ce.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 he in me)this[he]=me[he];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var $,q,oe,ce;this._more||(this.yytext="",this.match="");for(var me=this._currentRules(),he=0;he<me.length;he++)if(oe=this._input.match(this.rules[me[he]]),oe&&(!q||oe[0].length>q[0].length)){if(q=oe,ce=he,this.options.backtrack_lexer){if($=this.test_match(oe,me[he]),$!==!1)return $;if(this._backtrack){q=!1;continue}else return!1}else if(!this.options.flex)break}return q?($=this.test_match(q,me[ce]),$!==!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,ce,me){switch(ce){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 N}();P.lexer=L;function J(){this.yy={}}return J.prototype=P,P.Parser=J,new J}();typeof Tce<"u"&&(e.parser=n,e.Parser=n.Parser,e.parse=function(){return n.parse.apply(n,arguments)})})(Kce);const tW={StyleExpression:Hj,isExpression:Vj,isExpressionFilter:a8,createExpression:Q3,createPropertyExpression:Zj,normalizePropertyExpression:dce,ZoomConstantExpression:SE,ZoomDependentExpression:EE,StylePropertyFunction:B5},nW={convertFunction:pce,createFunction:n8,isFunction:t8};var rW=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 WM(e){return e*Math.PI/180}var ky=function(){for(var e=[],n=78271.51696402048;e.length<=24;n/=2)e.push(n);return e}();function iW(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 Pce(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 Fce=Array(256).join("");function kE(e,n){if(n>=.05){for(var t="",r=e.split(`
`),i=Fce.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 NM;function oW(){return NM||(NM=iW(1,1).getContext("2d")),NM}function v0(e,n){return oW().measureText(e).width+(e.length-1)*n}var IE={};cE&&ko(cE,Di.CLEAR,function(){IE={}});function TE(e,n,t,r){if(e.indexOf(`
`)!==-1){for(var i=e.split(`
`),o=[],s=0,a=i.length;s<a;++s)o.push(TE(i[s],n,t,r));return o.join(`
`)}var h=t+","+n+","+e+","+r,g=IE[h];if(!g){var C=e.split(" ");if(C.length>1){var B=oW();B.font=n;for(var k=B.measureText("M").width,P=k*t,L="",o=[],s=0,a=C.length;s<a;++s){var J=C[s],N=L+(L?" ":"")+J;v0(N,r)<=P?L=N:(L&&o.push(L),L=J)}L&&o.push(L);for(var s=0,a=o.length;s<a&&a>1;++s){var $=o[s];if(v0($,r)<P*.35){var q=s>0?v0(o[s-1],r):1/0,oe=s<a-1?v0(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 ce=o[s],me=o[s+1];if(v0(ce,r)>P*.7&&v0(me,r)<P*.6){var he=ce.split(" "),V=he.pop();v0(V,r)<P*.2&&(o[s]=he.join(" "),o[s+1]=V+" "+me),a-=1}}g=o.join(`
`)}else g=e;g=kE(g,r),IE[h]=g}return g}var Dce=nW.isFunction,Lce=nW.convertFunction,Uce=tW.isExpression,Rce=tW.createPropertyExpression,zce={Point:1,MultiPoint:1,LineString:2,MultiLineString:2,Polygon:3,MultiPolygon:3},jce={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]},Wce=function(e,n){var t=Rce(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},KE={},Y3={zoom:0},Dx,GM;function Ii(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 h=(e[n]||KE)[t],g=Cj["".concat(n,"_").concat(e.type)][t];h===void 0&&(h=g.default);var C=Uce(h);if(!C&&Dce(h)&&(h=Lce(h,g),C=!0),C){var B=Wce(h,g);a[t]=B.evaluate.bind(B)}else g.type=="color"&&(h=Vl.parse(h)),a[t]=function(){return h}}return Y3.zoom=r,a[t](Y3,i)}function Nce(e,n,t,r,i){return i||console.warn("No filterCache provided to evaluateFilter()"),e in i||(i[e]=bce(n).filter),Y3.zoom=r,i[e](Y3,t)}function im(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 Gce=/^([^]*)\{(.*)\}([^]*)$/;function QM(e,n){var t;do if(t=e.match(Gce),t){var r=n[t[2]]||"";e=t[1]+r+t[3]}while(t);return e}function Qce(e,n,t,r,i,o,s){if(r===void 0&&(r=ky),typeof n=="string"&&(n=JSON.parse(n)),n.version!=8)throw new Error("glStyle version 8 required.");var a,h;if(o){if(typeof Image<"u"){var g=new Image;g.crossOrigin="anonymous",g.onload=function(){a=g,h=[g.width,g.height],e.changed(),g.onload=null},g.src=o}else if(typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope){var C=self;C.postMessage({action:"loadImage",src:o}),C.addEventListener("message",function(Bt){Bt.data.action==="imageLoaded"&&Bt.data.src===o&&(a=Bt.data.image,h=[a.width,a.height])})}}for(var B=Ice(n.layers),k={},P=[],L={},J={},N={},$={},q,oe=0,ce=B.length;oe<ce;++oe){var me=B[oe],he=me.id;if(typeof t=="string"&&me.source==t||t.indexOf(he)!==-1){var V=me["source-layer"];if(!q){q=me.source;var ae=n.sources[q];if(!ae)throw new Error('Source "'.concat(q,'" is not defined'));var ye=ae.type;if(ye!=="vector"&&ye!=="geojson")throw new Error('Source "'.concat(q,'" is not of type "vector" or "geojson", but "').concat(ye,'"'))}var Oe=k[V];Oe||(Oe=[],k[V]=Oe),Oe.push({layer:me,index:oe}),P.push(he)}}var De=new l_,He=new zg,ke=[],nt=function(be,Bt){var kt=be.getProperties(),Yt=k[kt.layer];if(Yt){var jt=r.indexOf(Bt);jt==-1&&(jt=Pce(Bt,r));for(var Xe=zce[be.getGeometry().getType()],rt={properties:kt,type:Xe},ot=-1,on=function(It,Lt){var Me=Yt[It],fe=Me.layer,xe=fe.id,Ue=fe.layout||KE,et=fe.paint||KE;if(Ue.visibility==="none"||"minzoom"in fe&&jt<fe.minzoom||"maxzoom"in fe&&jt>=fe.maxzoom)return"continue";var it=fe.filter;if(!it||Nce(xe,it,rt,jt,$)){var bt=void 0,Ut=void 0,Rt=void 0,pt=void 0,rr=void 0,mn=void 0,vn=Me.index;if(Xe==3&&(fe.type=="fill"||fe.type=="fill-extrusion"))if(Ut=Ii(fe,"paint",fe.type+"-opacity",jt,rt,N),fe.type+"-pattern"in et){var Xn=Ii(fe,"paint",fe.type+"-pattern",jt,rt,N);if(Xn){var cr=typeof Xn=="string"?QM(Xn,kt):Xn.toString();if(a&&i&&i[cr]){++ot,mn=ke[ot],(!mn||!mn.getFill()||mn.getStroke()||mn.getText())&&(mn=new S0({fill:new zg}),ke[ot]=mn),Rt=mn.getFill(),mn.setZIndex(vn);var Mr=cr+"."+Ut,Gr=J[Mr];if(!Gr){var gr=i[cr],mi=iW(gr.width,gr.height),Se=mi.getContext("2d");Se.globalAlpha=Ut,Se.drawImage(a,gr.x,gr.y,gr.width,gr.height,0,0,gr.width,gr.height),Gr=Se.createPattern(mi,"repeat"),J[Mr]=Gr}Rt.setColor(Gr)}}}else bt=im(Ii(fe,"paint",fe.type+"-color",jt,rt,N),Ut),fe.type+"-outline-color"in et&&(rr=im(Ii(fe,"paint",fe.type+"-outline-color",jt,rt,N),Ut)),rr||(rr=bt),(bt||rr)&&(++ot,mn=ke[ot],(!mn||bt&&!mn.getFill()||!bt&&mn.getFill()||rr&&!mn.getStroke()||!rr&&mn.getStroke()||mn.getText())&&(mn=new S0({fill:bt?new zg:void 0,stroke:rr?new l_:void 0}),ke[ot]=mn),bt&&(Rt=mn.getFill(),Rt.setColor(bt)),rr&&(pt=mn.getStroke(),pt.setColor(rr),pt.setWidth(.5)),mn.setZIndex(vn));if(Xe!=1&&fe.type=="line"){bt=!("line-pattern"in et)&&"line-color"in et?im(Ii(fe,"paint","line-color",jt,rt,N),Ii(fe,"paint","line-opacity",jt,rt,N)):void 0;var X=Ii(fe,"paint","line-width",jt,rt,N);bt&&X>0&&(++ot,mn=ke[ot],(!mn||!mn.getStroke()||mn.getFill()||mn.getText())&&(mn=new S0({stroke:new l_}),ke[ot]=mn),pt=mn.getStroke(),pt.setLineCap(Ii(fe,"layout","line-cap",jt,rt,N)),pt.setLineJoin(Ii(fe,"layout","line-join",jt,rt,N)),pt.setMiterLimit(Ii(fe,"layout","line-miter-limit",jt,rt,N)),pt.setColor(bt),pt.setWidth(X),pt.setLineDash(et["line-dasharray"]?Ii(fe,"paint","line-dasharray",jt,rt,N).map(function(fi){return fi*X}):null),mn.setZIndex(vn))}var H=!1,Te=null,At=0,St=void 0,Et=void 0,Nt=void 0;if((Xe==1||Xe==2)&&"icon-image"in Ue){var pn=Ii(fe,"layout","icon-image",jt,rt,N);if(pn){St=typeof pn=="string"?QM(pn,kt):pn.toString();var Kn=void 0;if(a&&i&&i[St]){var En=Ii(fe,"layout","icon-rotation-alignment",jt,rt,N);if(Xe==2){var m=be.getGeometry();if(m.getFlatMidpoint||m.getFlatMidpoints){var Kt=m.getExtent(),Dr=Math.sqrt(Math.max(Math.pow((Kt[2]-Kt[0])/Bt,2),Math.pow((Kt[3]-Kt[1])/Bt,2)));if(Dr>150){var Fn=m.getType()==="MultiLineString"?m.getFlatMidpoints():m.getFlatMidpoint();GM||(Dx=[NaN,NaN],GM=new AE("Point",Dx,[],{},null)),Kn=GM,Dx[0]=Fn[0],Dx[1]=Fn[1];var Fe=Ii(fe,"layout","symbol-placement",jt,rt,N);if(Fe==="line"&&En==="map")for(var de=m.getStride(),Ce=m.getFlatCoordinates(),Be=0,ze=Ce.length-de;Be<ze;Be+=de){var tt=Ce[Be],lt=Ce[Be+1],ft=Ce[Be+de],Ve=Ce[Be+de+1],xt=Math.min(tt,ft),Xt=Math.min(lt,Ve),Vt=Math.max(tt,ft),Ht=Math.max(lt,Ve);if(Fn[0]>=xt&&Fn[0]<=Vt&&Fn[1]>=Xt&&Fn[1]<=Ht){At=Math.atan2(lt-Ve,ft-tt);break}}}}}if(Xe!==2||Kn){var Qn=Ii(fe,"layout","icon-size",jt,rt,N),Mn=et["icon-color"]!==void 0?Ii(fe,"paint","icon-color",jt,rt,N):null;if(!Mn||Mn.a!==0){var Mr=St+"."+Qn;if(Mn!==null&&(Mr+="."+Mn),Et=L[Mr],!Et){var or=i[St];Et=new Yz({color:Mn?[Mn.r*255,Mn.g*255,Mn.b*255,Mn.a]:void 0,img:a,imgSize:h,size:[or.width,or.height],offset:[or.x,or.y],rotateWithView:En==="map",scale:Qn/or.pixelRatio,displacement:"icon-offset"in Ue?Ii(fe,"layout","icon-offset",jt,rt,N).map(function(ei){return-ei*or.pixelRatio}):void 0}),L[Mr]=Et}}Et&&(++ot,mn=ke[ot],(!mn||!mn.getImage()||mn.getFill()||mn.getStroke())&&(mn=new S0,ke[ot]=mn),mn.setGeometry(Kn),Et.setRotation(At+WM(Ii(fe,"layout","icon-rotate",jt,rt,N))),Et.setOpacity(Ii(fe,"paint","icon-opacity",jt,rt,N)),Et.setAnchor(jce[Ii(fe,"layout","icon-anchor",jt,rt,N)]),mn.setImage(Et),Te=mn.getText(),mn.setText(void 0),mn.setZIndex(vn),H=!0,Nt=!1)}else Nt=!0}}}if(Xe==1&&fe.type==="circle"){++ot,mn=ke[ot],(!mn||!mn.getImage()||mn.getFill()||mn.getStroke())&&(mn=new S0,ke[ot]=mn);var ar="circle-radius"in et?Ii(fe,"paint","circle-radius",jt,rt,N):5,kr=im(Ii(fe,"paint","circle-stroke-color",jt,rt,N),Ii(fe,"paint","circle-stroke-opacity",jt,rt,N)),jr=im(Ii(fe,"paint","circle-color",jt,rt,N),Ii(fe,"paint","circle-opacity",jt,rt,N)),Lr=Ii(fe,"paint","circle-stroke-width",jt,rt,N),Wr=ar+"."+kr+"."+jr+"."+Lr;Et=L[Wr],Et||(Et=new Wz({radius:ar,stroke:kr&&Lr>0?new l_({width:Lr,color:kr}):void 0,fill:jr?new zg({color:jr}):void 0}),L[Wr]=Et),mn.setImage(Et),Te=mn.getText(),mn.setText(void 0),mn.setGeometry(void 0),mn.setZIndex(vn),H=!0}var ir=void 0,ui=void 0,Oi,Yi,_o,Jr;if("text-field"in Ue){Yi=Math.round(Ii(fe,"layout","text-size",jt,rt,N));var xo=Ii(fe,"layout","text-font",jt,rt,N);Oi=Ii(fe,"layout","text-line-height",jt,rt,N),ui=yE(s?s(xo):xo,Yi,Oi),_o=Ii(fe,"layout","text-letter-spacing",jt,rt,N),Jr=Ii(fe,"layout","text-max-width",jt,rt,N);var Wa=Ii(fe,"layout","text-field",jt,rt,N);typeof Wa=="object"&&Wa.sections?Wa.sections.length===1?ir=Wa.toString():ir=Wa.sections.reduce(function(fi,ei,Zo){var Fa=ei.fontStack?ei.fontStack.split(","):xo,Or=yE(s?s(Fa):Fa,Yi*(ei.scale||1),Oi),gi=ei.text;if(gi===`
`)return fi.push(`
`,""),fi;if(Xe==2){fi.push(kE(gi,_o),Or);return}gi=TE(gi,Or,Jr,_o).split(`
`);for(var Ks=0,ka=gi.length;Ks<ka;++Ks)Ks>0&&fi.push(`
`,""),fi.push(gi[Ks],Or);return fi},[]):ir=QM(Wa,kt).trim(),Ut=Ii(fe,"paint","text-opacity",jt,rt,N)}if(ir&&Ut&&!Nt){H||(++ot,mn=ke[ot],(!mn||!mn.getText()||mn.getFill()||mn.getStroke())&&(mn=new S0,ke[ot]=mn),mn.setImage(void 0),mn.setGeometry(void 0)),mn.getText()||mn.setText(Te||new cse({padding:[2,2,2,2]})),Te=mn.getText();var Ba=Ue["text-transform"];Ba=="uppercase"?ir=Array.isArray(ir)?ir.map(function(ei,Zo){return Zo%2?ei:ei.toUpperCase()}):ir.toUpperCase():Ba=="lowercase"&&(ir=Array.isArray(ir)?ir.map(function(ei,Zo){return Zo%2?ei:ei.toLowerCase()}):ir.toLowerCase());var bi=Array.isArray(ir)?ir:Xe==2?kE(ir,_o):TE(ir,ui,Jr,_o);Te.setText(bi),Te.setFont(ui),Te.setRotation(WM(Ii(fe,"layout","text-rotate",jt,rt,N)));var os=Ii(fe,"layout","text-anchor",jt,rt,N),Fe=H||Xe==1?"point":Ii(fe,"layout","symbol-placement",jt,rt,N);Te.setPlacement(Fe),Te.setOverflow(Fe==="point");var hi=Ii(fe,"paint","text-halo-width",jt,rt,N),Wn=Ii(fe,"layout","text-offset",jt,rt,N),eo=Ii(fe,"paint","text-translate",jt,rt,N),io=0,qi=0;if(Fe=="point"){var ve="center";os.indexOf("left")!==-1?(ve="left",qi=hi):os.indexOf("right")!==-1&&(ve="right",qi=-hi),Te.setTextAlign(ve);var Ye=Ii(fe,"layout","text-rotation-alignment",jt,rt,N);Te.setRotateWithView(Ye=="map")}else Te.setMaxAngle(WM(Ii(fe,"layout","text-max-angle",jt,rt,N))*ir.length/bi.length),Te.setTextAlign(),Te.setRotateWithView(!1);var Jt="middle";os.indexOf("bottom")==0?(Jt="bottom",io=-hi-.5*(Oi-1)*Yi):os.indexOf("top")==0&&(Jt="top",io=hi+.5*(Oi-1)*Yi),Te.setTextBaseline(Jt),Te.setOffsetX(Wn[0]*Yi+qi+eo[0]),Te.setOffsetY(Wn[1]*Yi+io+eo[1]),He.setColor(im(Ii(fe,"paint","text-color",jt,rt,N),Ut)),Te.setFill(He);var sn=im(Ii(fe,"paint","text-halo-color",jt,rt,N),Ut);if(sn){De.setColor(sn),hi*=2;var Ft=.5*Yi;De.setWidth(hi<=Ft?hi:Ft),Te.setStroke(De)}else Te.setStroke(void 0);var Cn=Ii(fe,"layout","text-padding",jt,rt,N),ur=Te.getPadding();Cn!==ur[0]&&(ur[0]=Cn,ur[1]=Cn,ur[2]=Cn,ur[3]=Cn),mn.setZIndex(vn)}}},gt=0,at=Yt.length;gt<at;++gt)on(gt);if(ot>-1)return ke.length=ot+1,ke}};return e.setStyle(nt),e.set("mapbox-source",q),e.set("mapbox-layers",P),nt}var aW={exports:{}};(function(){var e;aW.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(ch);var $ce=aW.exports;const Yce=fa($ce);var PT={},qce=/font-family: ?([^;]*);/,Hce=/("|')/g,Lx;function Vce(e){if(!Lx){Lx={};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 h=o[s];if(h.type==5){var g=h.cssText.match(qce);Lx[g[1].replace(Hce,"")]=!0}}}catch{}}}return e in Lx}var FT={},Zce=Yce.getNames();function Xce(e){var n=e.toString();if(n in FT)return e;for(var t=e.map(function(g){var C=yE(g,1).split(" ");return[C.slice(3).join(" ").replace(/"/g,""),C[1]+C[0]]}),r=0,i=t.length;r<i;++r){var o=t[r],s=o[0];if(!Vce(s)&&Zce.indexOf(s)!==-1){var a="https://fonts.googleapis.com/css?family="+s.replace(/ /g,"+")+":"+o[1];if(!document.querySelector('link[href="'+a+'"]')){var h=document.createElement("link");h.href=a,h.rel="stylesheet",document.head.appendChild(h)}}}return FT[n]=!0,e}var sW=/^(.*)(\?.*)$/;function q3(e,n){return n&&e.indexOf(".")===0&&(e=n+e),e}function $M(e,n,t){e=q3(e,n);var r=e.match(sW);return r?r[1]+t+(r.length>2?r[2]:""):e+t}function Jce(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 Jz||e instanceof vj))return s(new Error("Can only apply to VectorLayer or VectorTileLayer"));var a,h,g,C;function B(){!C&&(!n.sprite||h)?(C=Qce(e,n,t,i,h,g,Xce),e.getStyle()?o():s(new Error("Nothing to show for source [".concat(t,"]")))):C?(e.setStyle(C),o()):s(new Error("Something went wrong trying to apply style."))}if(n.sprite){a=window.devicePixelRatio>=1.5?.5:1;var k=a==.5?"@2x":"",P=$M(n.sprite,r,k+".json");fetch(P,{credentials:"same-origin"}).then(function(L){return!L.ok&&k!==""?(P=$M(n.sprite,r,".json"),fetch(P,{credentials:"same-origin"})):L}).then(function(L){if(L.ok)return L.json();s(new Error("Problem fetching sprite from ".concat(P,": ").concat(L.statusText)))}).then(function(L){if(L===void 0)return s(new Error("No sprites found."));h=L,g=$M(n.sprite,r,k+".png"),B()}).catch(function(L){s(new Error("Sprites cannot be loaded: ".concat(P,": ").concat(L.message)))})}else B()})}var PE={};function ede(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 h=typeof e.getSource=="function"?e.getSource().getTileGrid().getZForResolution(o):e.getView().getZoom(),g=typeof e.getTargetElement=="function"?e.getTargetElement():void 0,C,B;if(a["background-color"]!==void 0&&(C=Ii(t,"paint","background-color",h,PE,r),g&&(g.style.background=Vl.parse(C).toString())),a["background-opacity"]!==void 0&&(B=Ii(t,"paint","background-opacity",h,PE,r),g&&(g.style.opacity=B)),s.visibility=="none"){g&&(g.style.backgroundColor="",g.style.opacity="");return}return im(C,B)}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 tde(e,n){var t;return e.some(function(r){if(r.id==n)return t=r.source,!0}),t}function lW(e){var n=e.bounds;if(n){var t=nE([n[0],n[1]]),r=nE([n[2],n[3]]);return[t[0],t[1],r[0],r[1]]}}function nde(e,n){e=rW({},e);var t=[n,JSON.stringify(e)].toString(),r=PT[t];return r||(r=new gj({url:e.tiles?void 0:n,tileJSON:e.tiles?e:void 0}),PT[t]=r),new Promise(function(i){var o=r.on("change",function(){var s=r.getState();if(s==="ready"){var a=r.getTileJSON(),h=Array.isArray(a.tiles)?a.tiles:[a.tiles];if(n)for(var g=0,C=h.length;g<C;++g)h[g]=decodeURI(new URL(h[g],n).href);var B=r.getTileGrid(),k=lW(a),P=a.minzoom||0,L=a.maxzoom||22,J=r.get("ol-source");J===void 0&&(J=new _j({attributions:r.getAttributions(),format:new aie,tileGrid:new XC({origin:B.getOrigin(0),extent:k||B.getExtent(),minZoom:P,resolutions:ky.slice(0,L+1),tileSize:512}),urls:h}),r.set("ol-source",J)),lC(o),i(J)}else s==="error"&&(r.set("ol-source",null),lC(o),i(void 0))});r.getState()==="ready"&&r.changed()})}function rde(e,n){var t=new vj({declutter:!0,visible:!1});return nde(e,n).then(function(r){t.setSource(r)}),t}function ide(e,n){var t=new Ole,r=new gj({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"){lC(i);var s=r.getTileJSON(),a=lW(s),h=r.getTileGrid(),g=e.tileSize||s.tileSize||512,C=s.minzoom||0,B=s.maxzoom||22;r.tileGrid=new XC({origin:h.getOrigin(0),extent:a||h.getExtent(),minZoom:C,resolutions:I7({maxZoom:B,tileSize:g}).getResolutions(),tileSize:g}),t.setSource(r)}else o==="error"&&(lC(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 h=o.getImage();h.src=s}),t}var DT=new vre;function ode(e,n){var t=e.data,r,i;return typeof t=="string"?i=q3(t,n):r=DT.readFeatures(t,{featureProjection:"EPSG:3857"}),new Jz({declutter:!0,source:new rj({attributions:e.attribution,features:r,format:DT,url:i}),visible:!1})}function LT(e,n,t,r){var i=t.getZoom(),o=Ii(e,"paint","raster-opacity",i,PE,r);n.setOpacity(o)}function UT(e,n,t,r,i,o){o===void 0&&(o="");var s=[],a=n.getView();!a.isDef()&&!a.getRotation()&&!a.getResolutions()&&(a=new gp(rW(a.getProperties(),{maxResolution:ky[0]})),n.setView(a)),"center"in e&&!a.getCenter()&&a.setCenter(nE(e.center)),"zoom"in e&&a.getZoom()===void 0&&a.setResolution(ky[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 h=e.layers,g=[],C,B,k,P,L,J,N=function(ce,me){C=h[ce];var he=C.type;if(!(he=="heatmap"||he=="hillshade"))if(he=="background")ede(n,C);else{if(P=C.source||tde(h,C.ref),P!=k){if(g.length&&(s.push(RT(L,g,e,i,n)),g=[]),B=e.sources[P],J=B.url,J)if(J=q3(J,i),J.indexOf("mapbox://")==0){var V=J.replace("mapbox://","");B.tiles=["a","b","c","d"].map(function(ye){return"https://"+ye+".tiles.mapbox.com/v4/"+V+"/{z}/{x}/{y}."+(B.type=="vector"?"vector.pbf":"png")+o})}else J.indexOf("/")===0&&r.indexOf("http")===0&&(J=r+J);if(B.tiles&&(B.tiles=B.tiles.map(function(ye){return q3(ye,i)})),B.type=="vector")L=rde(B,J);else if(B.type=="raster"){L=ide(B,J),L.setVisible(C.layout?C.layout.visibility!=="none":!0);var ae={};a.on("change:resolution",LT.bind($,C,L,a,ae)),LT(C,L,a,ae)}else B.type=="geojson"&&(L=ode(B,i));k=P,L&&L.set("mapbox-source",k)}g.push(C.id)}},$=this,q=0,oe=h.length;q<oe;++q)N(q);return s.push(RT(L,g,e,i,n)),n.set("mapbox-style",e),Promise.all(s)}function ade(e,n){var t,r="",i="",o="",s="";if((typeof e=="string"||e instanceof HTMLElement)&&(e=new B7({target:e})),typeof n=="string"){var a=n.match(sW);a&&(i=a[1],r=a.length>2?a[2]:""),t=new Promise(function(h,g){fetch(n,{credentials:"same-origin"}).then(function(C){return C.json()}).then(function(C){var B=document.createElement("A");B.href=n;var k=B.href;s=B.pathname.split("/").slice(0,-1).join("/")+"/",o=k.substr(0,k.indexOf(s)),UT(C,e,i,o,s,r).then(function(){h(e)}).catch(g)}).catch(function(C){g(new Error("Could not load ".concat(n,": ").concat(C.message)))})})}else t=new Promise(function(h,g){UT(n,e).then(function(){h(e)}).catch(g)});return t}function sde(e,n){return(typeof e=="string"||e instanceof HTMLElement)&&(e=new B7({target:e})),setTimeout(function(){ade(e,n)},0),e}function RT(e,n,t,r,i){for(var o=24,s=0,a=t.layers,h=0,g=a.length;h<g;++h){var C=a[h];n.indexOf(C.id)!==-1&&(o=Math.min("minzoom"in C?C.minzoom:0,o),s=Math.max("maxzoom"in C?C.maxzoom:24,s))}return new Promise(function(B,k){var P=function(){var L=e.getSource();if(!L||L.getState()==="error"){k(new Error("Error accessing data for source "+e.get("mapbox-source")));return}if("getTileGrid"in L){var J=L.getTileGrid();if(J){var N=J.getMinZoom();(o>0||N>0)&&e.setMaxResolution(Math.min(ky[o],J.getResolution(N))+1e-9),s<24&&e.setMinResolution(ky[s]+1e-9)}}L instanceof rj||L instanceof _j?Jce(e,t,n,r).then(function(){e.setVisible(!0),B()},function($){k($)}):B()};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 zT(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]++,G.jsx("span",{className:"maputnik-coords",children:e.map(n=>(Er().f[1]++,Er().s[3]++,String(n).padStart(7," "))).join(", ")}))}class uW extends Sn.Component{constructor(t){Er().f[5]++,Er().s[7]++;super(t);an(this,"updateStyle");an(this,"map");an(this,"container",(Er().s[5]++,null));an(this,"overlay");an(this,"popupContainer",(Er().s[6]++,null));an(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=H4.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]++,sde(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 Coe({element:this.popupContainer,autoPan:!0,autoPanAnimation:{duration:250}});const t=(Er().s[17]++,new B7({target:this.container,overlays:[this.overlay],view:new gp({zoom:1,center:[180,-90]})}));Er().s[18]++,t.on("pointermove",i=>{Er().f[9]++;const o=(Er().s[19]++,mM(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]++,mM(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]++,mM(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]++,G.jsxs("div",{className:"maputnik-ol-container",children:[G.jsxs("div",{ref:t=>(Er().f[14]++,Er().s[36]++,this.popupContainer=t),style:{background:"black"},className:"maputnik-popup",children:[G.jsx("button",{className:"maplibregl-popup-close-button",onClick:this.closeOverlay,"aria-label":"Close popup",children:"×"}),G.jsx(gR,{features:(Er().b[4][0]++,this.state.selectedFeatures||(Er().b[4][1]++,[])),onLayerSelect:this.props.onLayerSelect})]}),G.jsxs("div",{className:"maputnik-ol-zoom",children:["Zoom: ",this.state.zoom]}),(Er().b[5][0]++,this.props.debugToolbox&&(Er().b[5][1]++,G.jsxs("div",{className:"maputnik-ol-debug",children:[G.jsxs("div",{children:[G.jsx("label",{children:"cursor: "}),G.jsx("span",{children:zT(this.state.cursor)})]}),G.jsxs("div",{children:[G.jsx("label",{children:"center: "}),G.jsx("span",{children:zT(this.state.center)})]}),G.jsxs("div",{children:[G.jsx("label",{children:"rotation: "}),G.jsx("span",{children:this.state.rotation})]})]}))),G.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}})]})}}an(uW,"defaultProps",(Er().s[4]++,{onMapLoaded:()=>{Er().f[2]++},onDataChange:()=>{Er().f[3]++},onLayerSelect:()=>{Er().f[4]++}}));var AW={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})()})(AW);var lde=AW.exports;const bf=fa(lde);function I0(){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 I0=function(){return s},s}I0();class ude extends Sn.Component{render(){I0().f[0]++;const n=(I0().s[0]++,{width:20,height:20,...this.props.style});return I0().s[1]++,this.props.isCollapsed?(I0().b[0][0]++,G.jsx(XJ,{style:n})):(I0().b[0][1]++,G.jsx(ZJ,{style:n}))}}function Ng(){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 Ng=function(){return s},s}Ng();class Ade extends Sn.Component{render(){return Ng().f[0]++,Ng().s[0]++,G.jsx("li",{className:"maputnik-layer-list-group",children:G.jsxs("div",{className:"maputnik-layer-list-group-header","data-wd-key":"layer-list-group:"+this.props["data-wd-key"],onClick:n=>(Ng().f[1]++,Ng().s[1]++,this.props.onActiveToggle(!this.props.isActive)),children:[G.jsx("button",{className:"maputnik-layer-list-group-title","aria-controls":this.props["aria-controls"],"aria-expanded":this.props.isActive,children:this.props.title}),G.jsx("span",{className:"maputnik-space"}),G.jsx(ude,{style:{height:14,width:14},isCollapsed:this.props.isActive})]})})}}function xC(){return xC=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},xC.apply(this,arguments)}function cde(e){if(Array.isArray(e))return e}function dde(e,n){var t=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(t!=null){var r,i,o,s,a=[],h=!0,g=!1;try{if(o=(t=t.call(e)).next,n===0){if(Object(t)!==t)return;h=!1}else for(;!(h=(r=o.call(t)).done)&&(a.push(r.value),a.length!==n);h=!0);}catch(C){g=!0,i=C}finally{try{if(!h&&t.return!=null&&(s=t.return(),Object(s)!==s))return}finally{if(g)throw i}}return a}}function FE(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 cW(e,n){if(e){if(typeof e=="string")return FE(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 FE(e,n)}}function hde(){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 dW(e,n){return cde(e)||dde(e,n)||cW(e,n)||hde()}function Iy(e){"@babel/helpers - typeof";return Iy=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},Iy(e)}function fde(e,n){if(Iy(e)!="object"||!e)return e;var t=e[Symbol.toPrimitive];if(t!==void 0){var r=t.call(e,n||"default");if(Iy(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(n==="string"?String:Number)(e)}function hW(e){var n=fde(e,"string");return Iy(n)=="symbol"?n:String(n)}function Sa(e,n,t){return n=hW(n),n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function YM(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){Sa(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 jT(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,hW(r.key),r)}}function nb(e,n,t){return n&&jT(e.prototype,n),t&&jT(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function po(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function s8(e,n){if(n&&(Iy(n)==="object"||typeof n=="function"))return n;if(n!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return po(e)}function wC(e){return wC=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},wC(e)}function DE(e,n){return DE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},DE(e,n)}function l8(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&&DE(e,n)}var pde=function(e,n,t,r,i,o,s,a){if(!e){var h;if(n===void 0)h=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],C=0;h=new Error(n.replace(/%s/g,function(){return g[C++]})),h.name="Invariant Violation"}throw h.framesToPop=1,h}},mde=pde;const h1=fa(mde);function gde(e){if(Array.isArray(e))return FE(e)}function yde(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function vde(){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 _de(e){return gde(e)||yde(e)||cW(e)||vde()}var Cde=function(){function e(){tb(this,e),Sa(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(bde)}}]),e}();function bde(e,n){var t=e.node.sortableInfo.index,r=n.node.sortableInfo.index;return t-r}function fW(e,n){return Object.keys(e).reduce(function(t,r){return n.indexOf(r)===-1&&(t[r]=e[r]),t},{})}var hg={end:["touchend","touchcancel","mouseup"],move:["touchmove","mousemove"],start:["touchstart","mousedown"]},pW=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 Ux(e,n){Object.keys(n).forEach(function(t){e.style[t]=n[t]})}function Rx(e,n){e.style["".concat(pW,"Transform")]=n==null?"":"translate3d(".concat(n.x,"px,").concat(n.y,"px,0)")}function qM(e,n){e.style["".concat(pW,"TransitionDuration")]=n==null?"":"".concat(n,"ms")}function c_(e,n){for(;e;){if(n(e))return e;e=e.parentNode}return null}function WT(e,n,t){return Math.max(e,Math.min(t,n))}function Gg(e){return e.substr(-2)==="px"?parseFloat(e):0}function xde(e){var n=window.getComputedStyle(e);return{bottom:Gg(n.marginBottom),left:Gg(n.marginLeft),right:Gg(n.marginRight),top:Gg(n.marginTop)}}function u8(e,n){var t=n.displayName||n.name;return t?"".concat(e,"(").concat(t,")"):e}function HM(e,n){var t=e.getBoundingClientRect();return{top:t.top+n.top,left:t.left+n.left}}function Gv(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 wde(e){return e.touches&&e.touches.length||e.changedTouches&&e.changedTouches.length}function x2(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:x2(e.parentNode,n,r)}}function Mde(e,n,t){return e<t&&e>n?e-1:e>t&&e<n?e+1:e}function NT(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);h1(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 h1(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 Sde(e){var n=e.height,t=e.width,r=e.lockOffset,i=Array.isArray(r)?r:[r,r];h1(i.length===2,"lockOffset prop of SortableContainer should be a single value or an array of exactly two values. Given %s",r);var o=dW(i,2),s=o[0],a=o[1];return[NT({height:n,lockOffset:s,width:t}),NT({height:n,lockOffset:a,width:t})]}function Ede(e){var n=window.getComputedStyle(e),t=/(auto|scroll)/,r=["overflow","overflowX","overflowY"];return r.find(function(i){return t.test(n[i])})}function mW(e){return e instanceof HTMLElement?Ede(e)?e:mW(e.parentNode):null}function Ode(e){var n=window.getComputedStyle(e);return n.display==="grid"?{x:Gg(n.gridColumnGap),y:Gg(n.gridRowGap)}:{x:0,y:0}}var _0={TAB:9,ESC:27,SPACE:32,LEFT:37,UP:38,RIGHT:39,DOWN:40},T0={Anchor:"A",Button:"BUTTON",Canvas:"CANVAS",Input:"INPUT",Option:"OPTION",Textarea:"TEXTAREA",Select:"SELECT"};function Bde(e){var n="input, textarea, select, canvas, [contenteditable]",t=e.querySelectorAll(n),r=e.cloneNode(!0),i=_de(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===T0.Canvas&&t[s].width>0&&t[s].height>0){var a=o.getContext("2d");a.drawImage(t[s],0,0)}}),r}function kde(e){var n,t,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{withRef:!1};return t=n=function(i){l8(o,i);function o(){var s,a;tb(this,o);for(var h=arguments.length,g=new Array(h),C=0;C<h;C++)g[C]=arguments[C];return a=s8(this,(s=wC(o)).call.apply(s,[this].concat(g))),Sa(po(po(a)),"wrappedInstance",Br.createRef()),a}return nb(o,[{key:"componentDidMount",value:function(){var a=Qm.findDOMNode(this);a.sortableHandle=!0}},{key:"getWrappedInstance",value:function(){return h1(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 Br.createElement(e,xC({ref:a},this.props))}}]),o}(Br.Component),Sa(n,"displayName",u8("sortableHandle",e)),t}function GT(e){return e.sortableHandle!=null}var Ide=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,h=t.height,g={x:0,y:0},C={x:1,y:1},B={x:10,y:10},k=this.container,P=k.scrollTop,L=k.scrollLeft,J=k.scrollHeight,N=k.scrollWidth,$=k.clientHeight,q=k.clientWidth,oe=P===0,ce=J-P-$===0,me=L===0,he=N-L-q===0;i.y>=s.y-h/2&&!ce?(g.y=1,C.y=B.y*Math.abs((s.y-h/2-i.y)/h)):i.x>=s.x-a/2&&!he?(g.x=1,C.x=B.x*Math.abs((s.x-a/2-i.x)/a)):i.y<=o.y+h/2&&!oe?(g.y=-1,C.y=B.y*Math.abs((i.y-h/2-o.y)/h)):i.x<=o.x+a/2&&!me&&(g.x=-1,C.x=B.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 V={left:C.x*g.x,top:C.y*g.y};r.container.scrollTop+=V.top,r.container.scrollLeft+=V.left,r.onScrollCallback(V)},5))}}]),e}();function Tde(e){var n=e.node;return{height:n.offsetHeight,width:n.offsetWidth}}function Kde(e){var n=[T0.Input,T0.Textarea,T0.Select,T0.Option,T0.Button];return!!(n.indexOf(e.target.tagName)!==-1||c_(e.target,function(t){return t.contentEditable==="true"}))}var gW={axis:Rr.oneOf(["x","y","xy"]),contentWindow:Rr.any,disableAutoscroll:Rr.bool,distance:Rr.number,getContainer:Rr.func,getHelperDimensions:Rr.func,helperClass:Rr.string,helperContainer:Rr.oneOfType([Rr.func,typeof HTMLElement>"u"?Rr.any:Rr.instanceOf(HTMLElement)]),hideSortableGhost:Rr.bool,keyboardSortingTransitionDuration:Rr.number,lockAxis:Rr.string,lockOffset:Rr.oneOfType([Rr.number,Rr.string,Rr.arrayOf(Rr.oneOfType([Rr.number,Rr.string]))]),lockToContainerEdges:Rr.bool,onSortEnd:Rr.func,onSortMove:Rr.func,onSortOver:Rr.func,onSortStart:Rr.func,pressDelay:Rr.number,pressThreshold:Rr.number,keyCodes:Rr.shape({lift:Rr.arrayOf(Rr.number),drop:Rr.arrayOf(Rr.number),cancel:Rr.arrayOf(Rr.number),up:Rr.arrayOf(Rr.number),down:Rr.arrayOf(Rr.number)}),shouldCancelStart:Rr.func,transitionDuration:Rr.number,updateBeforeSortStart:Rr.func,useDragHandle:Rr.bool,useWindowAsScrollContainer:Rr.bool},yW={lift:[_0.SPACE],drop:[_0.SPACE],cancel:[_0.ESC],up:[_0.UP,_0.LEFT],down:[_0.DOWN,_0.RIGHT]},Pde={axis:"y",disableAutoscroll:!1,distance:0,getHelperDimensions:Tde,hideSortableGhost:!0,lockOffset:"50%",lockToContainerEdges:!1,pressDelay:0,pressThreshold:5,keyCodes:yW,shouldCancelStart:Kde,transitionDuration:300,useWindowAsScrollContainer:!1},Fde=Object.keys(gW);function Dde(e){h1(!(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 Lde(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 vW=Br.createContext({manager:{}});function Ude(e){var n,t,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{withRef:!1};return t=n=function(i){l8(o,i);function o(s){var a;tb(this,o),a=s8(this,wC(o).call(this,s)),Sa(po(po(a)),"state",{}),Sa(po(po(a)),"handleStart",function(g){var C=a.props,B=C.distance,k=C.shouldCancelStart;if(!(g.button===2||k(g))){a.touched=!0,a.position=Gv(g);var P=c_(g.target,function(oe){return oe.sortableInfo!=null});if(P&&P.sortableInfo&&a.nodeIsChild(P)&&!a.state.sorting){var L=a.props.useDragHandle,J=P.sortableInfo,N=J.index,$=J.collection,q=J.disabled;if(q||L&&!c_(g.target,GT))return;a.manager.active={collection:$,index:N},!wde(g)&&g.target.tagName===T0.Anchor&&g.preventDefault(),B||(a.props.pressDelay===0?a.handlePress(g):a.pressTimer=setTimeout(function(){return a.handlePress(g)},a.props.pressDelay))}}}),Sa(po(po(a)),"nodeIsChild",function(g){return g.sortableInfo.manager===a.manager}),Sa(po(po(a)),"handleMove",function(g){var C=a.props,B=C.distance,k=C.pressThreshold;if(!a.state.sorting&&a.touched&&!a._awaitingUpdateBeforeSortStart){var P=Gv(g),L={x:a.position.x-P.x,y:a.position.y-P.y},J=Math.abs(L.x)+Math.abs(L.y);a.delta=L,!B&&(!k||J>=k)?(clearTimeout(a.cancelTimer),a.cancelTimer=setTimeout(a.cancel,0)):B&&J>=B&&a.manager.isActive()&&a.handlePress(g)}}),Sa(po(po(a)),"handleEnd",function(){a.touched=!1,a.cancel()}),Sa(po(po(a)),"cancel",function(){var g=a.props.distance,C=a.state.sorting;C||(g||clearTimeout(a.pressTimer),a.manager.active=null)}),Sa(po(po(a)),"handlePress",function(g){try{var C=a.manager.getActive(),B=function(){if(C){var k=function(){var Oe=me.sortableInfo.index,De=xde(me),He=Ode(a.container),ke=a.scrollContainer.getBoundingClientRect(),nt=J({index:Oe,node:me,collection:he});if(a.node=me,a.margin=De,a.gridGap=He,a.width=nt.width,a.height=nt.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=me.getBoundingClientRect(),a.containerBoundingRect=ke,a.index=Oe,a.newIndex=Oe,a.axis={x:L.indexOf("x")>=0,y:L.indexOf("y")>=0},a.offsetEdge=x2(me,a.container),V?a.initialOffset=Gv(YM({},g,{pageX:a.boundingClientRect.left,pageY:a.boundingClientRect.top})):a.initialOffset=Gv(g),a.initialScroll={left:a.scrollContainer.scrollLeft,top:a.scrollContainer.scrollTop},a.initialWindowScroll={left:window.pageXOffset,top:window.pageYOffset},a.helper=a.helperContainer.appendChild(Bde(me)),Ux(a.helper,{boxSizing:"border-box",height:"".concat(a.height,"px"),left:"".concat(a.boundingClientRect.left-De.left,"px"),pointerEvents:"none",position:"fixed",top:"".concat(a.boundingClientRect.top-De.top,"px"),width:"".concat(a.width,"px")}),V&&a.helper.focus(),$&&(a.sortableGhost=me,Ux(me,{opacity:0,visibility:"hidden"})),a.minTranslate={},a.maxTranslate={},V){var be=ce?{top:0,left:0,width:a.contentWindow.innerWidth,height:a.contentWindow.innerHeight}:a.containerBoundingRect,Bt=be.top,kt=be.left,Yt=be.width,jt=be.height,Xe=Bt+jt,rt=kt+Yt;a.axis.x&&(a.minTranslate.x=kt-a.boundingClientRect.left,a.maxTranslate.x=rt-(a.boundingClientRect.left+a.width)),a.axis.y&&(a.minTranslate.y=Bt-a.boundingClientRect.top,a.maxTranslate.y=Xe-(a.boundingClientRect.top+a.height))}else a.axis.x&&(a.minTranslate.x=(ce?0:ke.left)-a.boundingClientRect.left-a.width/2,a.maxTranslate.x=(ce?a.contentWindow.innerWidth:ke.left+ke.width)-a.boundingClientRect.left-a.width/2),a.axis.y&&(a.minTranslate.y=(ce?0:ke.top)-a.boundingClientRect.top-a.height/2,a.maxTranslate.y=(ce?a.contentWindow.innerHeight:ke.top+ke.height)-a.boundingClientRect.top-a.height/2);N&&N.split(" ").forEach(function(ot){return a.helper.classList.add(ot)}),a.listenerNode=g.touches?g.target:a.contentWindow,V?(a.listenerNode.addEventListener("wheel",a.handleKeyEnd,!0),a.listenerNode.addEventListener("mousedown",a.handleKeyEnd,!0),a.listenerNode.addEventListener("keydown",a.handleKeyDown)):(hg.move.forEach(function(ot){return a.listenerNode.addEventListener(ot,a.handleSortMove,!1)}),hg.end.forEach(function(ot){return a.listenerNode.addEventListener(ot,a.handleSortEnd,!1)})),a.setState({sorting:!0,sortingIndex:Oe}),oe&&oe({node:me,index:Oe,collection:he,isKeySorting:V,nodes:a.manager.getOrderedRefs(),helper:a.helper},g),V&&a.keyMove(0)},P=a.props,L=P.axis,J=P.getHelperDimensions,N=P.helperClass,$=P.hideSortableGhost,q=P.updateBeforeSortStart,oe=P.onSortStart,ce=P.useWindowAsScrollContainer,me=C.node,he=C.collection,V=a.manager.isKeySorting,ae=function(){if(typeof q=="function"){a._awaitingUpdateBeforeSortStart=!0;var ye=Lde(function(){var Oe=me.sortableInfo.index;return Promise.resolve(q({collection:he,index:Oe,node:me,isKeySorting:V},g)).then(function(){})},function(Oe,De){if(a._awaitingUpdateBeforeSortStart=!1,Oe)throw De;return De});if(ye&&ye.then)return ye.then(function(){})}}();return ae&&ae.then?ae.then(k):k(ae)}}();return Promise.resolve(B&&B.then?B.then(function(){}):void 0)}catch(k){return Promise.reject(k)}}),Sa(po(po(a)),"handleSortMove",function(g){var C=a.props.onSortMove;typeof g.preventDefault=="function"&&g.cancelable&&g.preventDefault(),a.updateHelperPosition(g),a.animateNodes(),a.autoscroll(),C&&C(g)}),Sa(po(po(a)),"handleSortEnd",function(g){var C=a.props,B=C.hideSortableGhost,k=C.onSortEnd,P=a.manager,L=P.active.collection,J=P.isKeySorting,N=a.manager.getOrderedRefs();a.listenerNode&&(J?(a.listenerNode.removeEventListener("wheel",a.handleKeyEnd,!0),a.listenerNode.removeEventListener("mousedown",a.handleKeyEnd,!0),a.listenerNode.removeEventListener("keydown",a.handleKeyDown)):(hg.move.forEach(function(me){return a.listenerNode.removeEventListener(me,a.handleSortMove)}),hg.end.forEach(function(me){return a.listenerNode.removeEventListener(me,a.handleSortEnd)}))),a.helper.parentNode.removeChild(a.helper),B&&a.sortableGhost&&Ux(a.sortableGhost,{opacity:"",visibility:""});for(var $=0,q=N.length;$<q;$++){var oe=N[$],ce=oe.node;oe.edgeOffset=null,oe.boundingClientRect=null,Rx(ce,null),qM(ce,null),oe.translate=null}a.autoScroller.clear(),a.manager.active=null,a.manager.isKeySorting=!1,a.setState({sorting:!1,sortingIndex:null}),typeof k=="function"&&k({collection:L,newIndex:a.newIndex,oldIndex:a.index,isKeySorting:J,nodes:N},g),a.touched=!1}),Sa(po(po(a)),"autoscroll",function(){var g=a.props.disableAutoscroll,C=a.manager.isKeySorting;if(g){a.autoScroller.clear();return}if(C){var B=YM({},a.translate),k=0,P=0;a.axis.x&&(B.x=Math.min(a.maxTranslate.x,Math.max(a.minTranslate.x,a.translate.x)),k=a.translate.x-B.x),a.axis.y&&(B.y=Math.min(a.maxTranslate.y,Math.max(a.minTranslate.y,a.translate.y)),P=a.translate.y-B.y),a.translate=B,Rx(a.helper,a.translate),a.scrollContainer.scrollLeft+=k,a.scrollContainer.scrollTop+=P;return}a.autoScroller.update({height:a.height,maxTranslate:a.maxTranslate,minTranslate:a.minTranslate,translate:a.translate,width:a.width})}),Sa(po(po(a)),"onAutoScroll",function(g){a.translate.x+=g.left,a.translate.y+=g.top,a.animateNodes()}),Sa(po(po(a)),"handleKeyDown",function(g){var C=g.keyCode,B=a.props,k=B.shouldCancelStart,P=B.keyCodes,L=P===void 0?{}:P,J=YM({},yW,L);a.manager.active&&!a.manager.isKeySorting||!a.manager.active&&(!J.lift.includes(C)||k(g)||!a.isValidSortingTarget(g))||(g.stopPropagation(),g.preventDefault(),J.lift.includes(C)&&!a.manager.active?a.keyLift(g):J.drop.includes(C)&&a.manager.active?a.keyDrop(g):J.cancel.includes(C)?(a.newIndex=a.manager.active.index,a.keyDrop(g)):J.up.includes(C)?a.keyMove(-1):J.down.includes(C)&&a.keyMove(1))}),Sa(po(po(a)),"keyLift",function(g){var C=g.target,B=c_(C,function(J){return J.sortableInfo!=null}),k=B.sortableInfo,P=k.index,L=k.collection;a.initialFocusedNode=C,a.manager.isKeySorting=!0,a.manager.active={index:P,collection:L},a.handlePress(g)}),Sa(po(po(a)),"keyMove",function(g){var C=a.manager.getOrderedRefs(),B=C[C.length-1].node.sortableInfo.index,k=a.newIndex+g,P=a.newIndex;if(!(k<0||k>B)){a.prevIndex=P,a.newIndex=k;var L=Mde(a.newIndex,a.prevIndex,a.index),J=C.find(function(V){var ae=V.node;return ae.sortableInfo.index===L}),N=J.node,$=a.containerScrollDelta,q=J.boundingClientRect||HM(N,$),oe=J.translate||{x:0,y:0},ce={top:q.top+oe.y-$.top,left:q.left+oe.x-$.left},me=P<k,he={x:me&&a.axis.x?N.offsetWidth-a.width:0,y:me&&a.axis.y?N.offsetHeight-a.height:0};a.handleSortMove({pageX:ce.left+he.x,pageY:ce.top+he.y,ignoreTransition:g===0})}}),Sa(po(po(a)),"keyDrop",function(g){a.handleSortEnd(g),a.initialFocusedNode&&a.initialFocusedNode.focus()}),Sa(po(po(a)),"handleKeyEnd",function(g){a.manager.active&&a.keyDrop(g)}),Sa(po(po(a)),"isValidSortingTarget",function(g){var C=a.props.useDragHandle,B=g.target,k=c_(B,function(P){return P.sortableInfo!=null});return k&&k.sortableInfo&&!k.sortableInfo.disabled&&(C?GT(B):B.sortableInfo)});var h=new Cde;return Dde(s),a.manager=h,a.wrappedInstance=Br.createRef(),a.sortableContextValue={manager:h},a.events={end:a.handleEnd,move:a.handleMove,start:a.handleStart},a}return nb(o,[{key:"componentDidMount",value:function(){var a=this,h=this.props.useWindowAsScrollContainer,g=this.getContainer();Promise.resolve(g).then(function(C){a.container=C,a.document=a.container.ownerDocument||document;var B=a.props.contentWindow||a.document.defaultView||window;a.contentWindow=typeof B=="function"?B():B,a.scrollContainer=h?a.document.scrollingElement||a.document.documentElement:mW(a.container)||a.container,a.autoScroller=new Ide(a.scrollContainer,a.onAutoScroll),Object.keys(a.events).forEach(function(k){return hg[k].forEach(function(P){return a.container.addEventListener(P,a.events[k],!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(h){return hg[h].forEach(function(g){return a.container.removeEventListener(g,a.events[h])})}),this.container.removeEventListener("keydown",this.handleKeyDown))}},{key:"updateHelperPosition",value:function(a){var h=this.props,g=h.lockAxis,C=h.lockOffset,B=h.lockToContainerEdges,k=h.transitionDuration,P=h.keyboardSortingTransitionDuration,L=P===void 0?k:P,J=this.manager.isKeySorting,N=a.ignoreTransition,$=Gv(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,B){var oe=Sde({height:this.height,lockOffset:C,width:this.width}),ce=dW(oe,2),me=ce[0],he=ce[1],V={x:this.width/2-me.x,y:this.height/2-me.y},ae={x:this.width/2-he.x,y:this.height/2-he.y};q.x=WT(this.minTranslate.x+V.x,this.maxTranslate.x-ae.x,q.x),q.y=WT(this.minTranslate.y+V.y,this.maxTranslate.y-ae.y,q.y)}g==="x"?q.y=0:g==="y"&&(q.x=0),J&&L&&!N&&qM(this.helper,L),Rx(this.helper,q)}},{key:"animateNodes",value:function(){var a=this.props,h=a.transitionDuration,g=a.hideSortableGhost,C=a.onSortOver,B=this.containerScrollDelta,k=this.windowScrollDelta,P=this.manager.getOrderedRefs(),L={left:this.offsetEdge.left+this.translate.x+B.left,top:this.offsetEdge.top+this.translate.y+B.top},J=this.manager.isKeySorting,N=this.newIndex;this.newIndex=null;for(var $=0,q=P.length;$<q;$++){var oe=P[$].node,ce=oe.sortableInfo.index,me=oe.offsetWidth,he=oe.offsetHeight,V={height:this.height>he?he/2:this.height/2,width:this.width>me?me/2:this.width/2},ae=J&&ce>this.index&&ce<=N,ye=J&&ce<this.index&&ce>=N,Oe={x:0,y:0},De=P[$].edgeOffset;De||(De=x2(oe,this.container),P[$].edgeOffset=De,J&&(P[$].boundingClientRect=HM(oe,B)));var He=$<P.length-1&&P[$+1],ke=$>0&&P[$-1];if(He&&!He.edgeOffset&&(He.edgeOffset=x2(He.node,this.container),J&&(He.boundingClientRect=HM(He.node,B))),ce===this.index){g&&(this.sortableGhost=oe,Ux(oe,{opacity:0,visibility:"hidden"}));continue}h&&qM(oe,h),this.axis.x?this.axis.y?ye||ce<this.index&&(L.left+k.left-V.width<=De.left&&L.top+k.top<=De.top+V.height||L.top+k.top+V.height<=De.top)?(Oe.x=this.width+this.marginOffset.x,De.left+Oe.x>this.containerBoundingRect.width-V.width&&He&&(Oe.x=He.edgeOffset.left-De.left,Oe.y=He.edgeOffset.top-De.top),this.newIndex===null&&(this.newIndex=ce)):(ae||ce>this.index&&(L.left+k.left+V.width>=De.left&&L.top+k.top+V.height>=De.top||L.top+k.top+V.height>=De.top+he))&&(Oe.x=-(this.width+this.marginOffset.x),De.left+Oe.x<this.containerBoundingRect.left+V.width&&ke&&(Oe.x=ke.edgeOffset.left-De.left,Oe.y=ke.edgeOffset.top-De.top),this.newIndex=ce):ae||ce>this.index&&L.left+k.left+V.width>=De.left?(Oe.x=-(this.width+this.marginOffset.x),this.newIndex=ce):(ye||ce<this.index&&L.left+k.left<=De.left+V.width)&&(Oe.x=this.width+this.marginOffset.x,this.newIndex==null&&(this.newIndex=ce)):this.axis.y&&(ae||ce>this.index&&L.top+k.top+V.height>=De.top?(Oe.y=-(this.height+this.marginOffset.y),this.newIndex=ce):(ye||ce<this.index&&L.top+k.top<=De.top+V.height)&&(Oe.y=this.height+this.marginOffset.y,this.newIndex==null&&(this.newIndex=ce))),Rx(oe,Oe),P[$].translate=Oe}this.newIndex==null&&(this.newIndex=this.index),J&&(this.newIndex=N);var nt=J?this.prevIndex:N;C&&this.newIndex!==nt&&C({collection:this.manager.active.collection,index:this.index,newIndex:this.newIndex,oldIndex:nt,isKeySorting:J,nodes:P,helper:this.helper})}},{key:"getWrappedInstance",value:function(){return h1(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"?Qm.findDOMNode(this):a(r.withRef?this.getWrappedInstance():void 0)}},{key:"render",value:function(){var a=r.withRef?this.wrappedInstance:null;return Br.createElement(vW.Provider,{value:this.sortableContextValue},Br.createElement(e,xC({ref:a},fW(this.props,Fde))))}},{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}(Br.Component),Sa(n,"displayName",u8("sortableList",e)),Sa(n,"defaultProps",Pde),Sa(n,"propTypes",gW),t}var _W={index:Rr.number.isRequired,collection:Rr.oneOfType([Rr.number,Rr.string]),disabled:Rr.bool},Rde=Object.keys(_W);function zde(e){var n,t,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{withRef:!1};return t=n=function(i){l8(o,i);function o(){var s,a;tb(this,o);for(var h=arguments.length,g=new Array(h),C=0;C<h;C++)g[C]=arguments[C];return a=s8(this,(s=wC(o)).call.apply(s,[this].concat(g))),Sa(po(po(a)),"wrappedInstance",Br.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,h=a.collection,g=a.disabled,C=a.index,B=Qm.findDOMNode(this);B.sortableInfo={collection:h,disabled:g,index:C,manager:this.context.manager},this.node=B,this.ref={node:B},this.context.manager.add(h,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 h1(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 Br.createElement(e,xC({ref:a},fW(this.props,Rde)))}}]),o}(Br.Component),Sa(n,"displayName",u8("sortableElement",e)),Sa(n,"contextType",vW),Sa(n,"propTypes",_W),Sa(n,"defaultProps",{collection:0}),t}function Ci(){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 Ci=function(){return s},s}Ci();const jde=(Ci().s[0]++,kde(e=>(Ci().f[0]++,Ci().s[1]++,G.jsxs("div",{className:"maputnik-layer-list-item-handle",children:[G.jsx(mR,{className:"layer-handle__icon",type:e.layerType}),G.jsx("button",{className:"maputnik-layer-list-item-id",children:e.layerId})]}))));class VM extends Sn.Component{renderIcon(){switch(Ci().f[1]++,Ci().s[2]++,this.props.action){case"duplicate":return Ci().b[0][0]++,Ci().s[3]++,G.jsx(QJ,{});case"show":return Ci().b[0][1]++,Ci().s[4]++,G.jsx(GJ,{});case"hide":return Ci().b[0][2]++,Ci().s[5]++,G.jsx(NJ,{});case"delete":return Ci().b[0][3]++,Ci().s[6]++,G.jsx(Ny,{})}}render(){Ci().f[2]++;const{classBlockName:n,classBlockModifier:t}=(Ci().s[7]++,this.props);let r=(Ci().s[8]++,"");return Ci().s[9]++,n?(Ci().b[1][0]++,Ci().s[10]++,r=`maputnik-layer-list-icon-action__${n}`,Ci().s[11]++,t?(Ci().b[2][0]++,Ci().s[12]++,r+=` maputnik-layer-list-icon-action__${n}--${t}`):Ci().b[2][1]++):Ci().b[1][1]++,Ci().s[13]++,G.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 LE extends Sn.Component{getChildContext(){return Ci().f[6]++,Ci().s[16]++,{reactIconBase:{size:14}}}render(){Ci().f[7]++;const n=(Ci().s[17]++,this.props.visibility==="visible"?(Ci().b[3][0]++,"show"):(Ci().b[3][1]++,"hide"));return Ci().s[18]++,G.jsxs("li",{id:this.props.id,onClick:t=>(Ci().f[8]++,Ci().s[19]++,this.props.onLayerSelect(this.props.layerIndex)),"data-wd-key":"layer-list-item:"+this.props.layerId,className:bf({"maputnik-layer-list-item":!0,"maputnik-layer-list-item-selected":this.props.isSelected,[this.props.className]:!0}),children:[G.jsx(jde,{...this.props}),G.jsx("span",{style:{flexGrow:1}}),G.jsx(VM,{wdKey:"layer-list-item:"+this.props.layerId+":delete",action:"delete",classBlockName:"delete",onClick:t=>(Ci().f[9]++,Ci().s[20]++,this.props.onLayerDestroy(this.props.layerIndex))}),G.jsx(VM,{wdKey:"layer-list-item:"+this.props.layerId+":copy",action:"duplicate",classBlockName:"duplicate",onClick:t=>(Ci().f[10]++,Ci().s[21]++,this.props.onLayerCopy(this.props.layerIndex))}),G.jsx(VM,{wdKey:"layer-list-item:"+this.props.layerId+":toggle-visibility",action:n,classBlockName:"visibility",classBlockModifier:n,onClick:t=>(Ci().f[11]++,Ci().s[22]++,this.props.onLayerVisibilityToggle(this.props.layerIndex))})]},this.props.layerId)}}an(LE,"defaultProps",(Ci().s[14]++,{isSelected:!1,visibility:"visible",onLayerCopy:()=>{Ci().f[3]++},onLayerDestroy:()=>{Ci().f[4]++},onLayerVisibilityToggle:()=>{Ci().f[5]++}})),an(LE,"childContextTypes",(Ci().s[15]++,{reactIconBase:Rr.object}));const Wde=(Ci().s[23]++,zde(e=>(Ci().f[12]++,Ci().s[24]++,G.jsx(LE,{...e}))));function H3(){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 H3=function(){return s},s}H3();class ja extends Sn.Component{render(){return H3().f[0]++,H3().s[0]++,G.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:bf("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 CW=["input","select","textarea","a[href]","button","[tabindex]:not(slot)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])',"details>summary:first-of-type","details"],V3=CW.join(","),bW=typeof Element>"u",f1=bW?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,UE=!bW&&Element.prototype.getRootNode?function(e){return e.getRootNode()}:function(e){return e.ownerDocument},xW=function(n,t,r){var i=Array.prototype.slice.apply(n.querySelectorAll(V3));return t&&f1.call(n,V3)&&i.unshift(n),i=i.filter(r),i},wW=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(),h=a.length?a:s.children,g=e(h,!0,r);r.flatten?i.push.apply(i,g):i.push({scope:s,candidates:g})}else{var C=f1.call(s,V3);C&&r.filter(s)&&(t||!n.includes(s))&&i.push(s);var B=s.shadowRoot||typeof r.getShadowRoot=="function"&&r.getShadowRoot(s),k=!r.shadowRootFilter||r.shadowRootFilter(s);if(B&&k){var P=e(B===!0?s.children:B.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},MW=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},Nde=function(n,t){return n.tabIndex===t.tabIndex?n.documentOrder-t.documentOrder:n.tabIndex-t.tabIndex},SW=function(n){return n.tagName==="INPUT"},Gde=function(n){return SW(n)&&n.type==="hidden"},Qde=function(n){var t=n.tagName==="DETAILS"&&Array.prototype.slice.apply(n.children).some(function(r){return r.tagName==="SUMMARY"});return t},$de=function(n,t){for(var r=0;r<n.length;r++)if(n[r].checked&&n[r].form===t)return n[r]},Yde=function(n){if(!n.name)return!0;var t=n.form||UE(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=$de(i,n.form);return!o||o===n},qde=function(n){return SW(n)&&n.type==="radio"},Hde=function(n){return qde(n)&&!Yde(n)},QT=function(n){var t=n.getBoundingClientRect(),r=t.width,i=t.height;return r===0&&i===0},Vde=function(n,t){var r=t.displayCheck,i=t.getShadowRoot;if(getComputedStyle(n).visibility==="hidden")return!0;var o=f1.call(n,"details>summary:first-of-type"),s=o?n.parentElement:n;if(f1.call(s,"details:not([open]) *"))return!0;var a=UE(n).host,h=(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 C=n.parentElement,B=UE(n);if(C&&!C.shadowRoot&&i(C)===!0)return QT(n);n.assignedSlot?n=n.assignedSlot:!C&&B!==n.ownerDocument?n=B.host:n=C}n=g}if(h)return!n.getClientRects().length}else if(r==="non-zero-area")return QT(n);return!1},Zde=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 f1.call(t,"fieldset[disabled] *")?!0:!i.contains(n)}return!0}t=t.parentElement}return!1},Z3=function(n,t){return!(t.disabled||Gde(t)||Vde(t,n)||Qde(t)||Zde(t))},RE=function(n,t){return!(Hde(t)||MW(t)<0||!Z3(n,t))},Xde=function(n){var t=parseInt(n.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},Jde=function e(n){var t=[],r=[];return n.forEach(function(i,o){var s=!!i.scope,a=s?i.scope:i,h=MW(a,s),g=s?e(i.candidates):a;h===0?s?t.push.apply(t,g):t.push(a):r.push({documentOrder:o,tabIndex:h,item:i,isScope:s,content:g})}),r.sort(Nde).reduce(function(i,o){return o.isScope?i.push.apply(i,o.content):i.push(o.content),i},[]).concat(t)},EW=function(n,t){t=t||{};var r;return t.getShadowRoot?r=wW([n],t.includeContainer,{filter:RE.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:Xde}):r=xW(n,t.includeContainer,RE.bind(null,t)),Jde(r)},OW=function(n,t){t=t||{};var r;return t.getShadowRoot?r=wW([n],t.includeContainer,{filter:Z3.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):r=xW(n,t.includeContainer,Z3.bind(null,t)),r},d_=function(n,t){if(t=t||{},!n)throw new Error("No node provided");return f1.call(n,V3)===!1?!1:RE(t,n)},ehe=CW.concat("iframe").join(","),w2=function(n,t){if(t=t||{},!n)throw new Error("No node provided");return f1.call(n,ehe)===!1?!1:Z3(t,n)};const the=Object.freeze(Object.defineProperty({__proto__:null,focusable:OW,isFocusable:w2,isTabbable:d_,tabbable:EW},Symbol.toStringTag,{value:"Module"}));/*!
* focus-trap 6.9.4
* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
*/function $T(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 YT(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?arguments[n]:{};n%2?$T(Object(t),!0).forEach(function(r){nhe(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):$T(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function nhe(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var qT=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()}}}(),rhe=function(n){return n.tagName&&n.tagName.toLowerCase()==="input"&&typeof n.select=="function"},ihe=function(n){return n.key==="Escape"||n.key==="Esc"||n.keyCode===27},ohe=function(n){return n.key==="Tab"||n.keyCode===9},HT=function(n){return setTimeout(n,0)},VT=function(n,t){var r=-1;return n.every(function(i,o){return t(i)?(r=o,!1):!0}),r},Qv=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},zx=function(n){return n.target.shadowRoot&&typeof n.composedPath=="function"?n.composedPath()[0]:n.target},ahe=function(n,t){var r=(t==null?void 0:t.document)||document,i=YT({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(he,V,ae){return he&&he[V]!==void 0?he[V]:i[ae||V]},h=function(he){return o.containerGroups.findIndex(function(V){var ae=V.container,ye=V.tabbableNodes;return ae.contains(he)||ye.find(function(Oe){return Oe===he})})},g=function(he){var V=i[he];if(typeof V=="function"){for(var ae=arguments.length,ye=new Array(ae>1?ae-1:0),Oe=1;Oe<ae;Oe++)ye[Oe-1]=arguments[Oe];V=V.apply(void 0,ye)}if(V===!0&&(V=void 0),!V){if(V===void 0||V===!1)return V;throw new Error("`".concat(he,"` was specified but was not a node, or did not return a node"))}var De=V;if(typeof V=="string"&&(De=r.querySelector(V),!De))throw new Error("`".concat(he,"` as selector refers to no known node"));return De},C=function(){var he=g("initialFocus");if(he===!1)return!1;if(he===void 0)if(h(r.activeElement)>=0)he=r.activeElement;else{var V=o.tabbableGroups[0],ae=V&&V.firstTabbableNode;he=ae||g("fallbackFocus")}if(!he)throw new Error("Your focus-trap needs to have at least one focusable element");return he},B=function(){if(o.containerGroups=o.containers.map(function(he){var V=EW(he,i.tabbableOptions),ae=OW(he,i.tabbableOptions);return{container:he,tabbableNodes:V,focusableNodes:ae,firstTabbableNode:V.length>0?V[0]:null,lastTabbableNode:V.length>0?V[V.length-1]:null,nextTabbableNode:function(Oe){var De=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,He=ae.findIndex(function(ke){return ke===Oe});if(!(He<0))return De?ae.slice(He+1).find(function(ke){return d_(ke,i.tabbableOptions)}):ae.slice(0,He).reverse().find(function(ke){return d_(ke,i.tabbableOptions)})}}}),o.tabbableGroups=o.containerGroups.filter(function(he){return he.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")},k=function me(he){if(he!==!1&&he!==r.activeElement){if(!he||!he.focus){me(C());return}he.focus({preventScroll:!!i.preventScroll}),o.mostRecentlyFocusedNode=he,rhe(he)&&he.select()}},P=function(he){var V=g("setReturnFocus",he);return V||(V===!1?!1:he)},L=function(he){var V=zx(he);if(!(h(V)>=0)){if(Qv(i.clickOutsideDeactivates,he)){s.deactivate({returnFocus:i.returnFocusOnDeactivate&&!w2(V,i.tabbableOptions)});return}Qv(i.allowOutsideClick,he)||he.preventDefault()}},J=function(he){var V=zx(he),ae=h(V)>=0;ae||V instanceof Document?ae&&(o.mostRecentlyFocusedNode=V):(he.stopImmediatePropagation(),k(o.mostRecentlyFocusedNode||C()))},N=function(he){var V=zx(he);B();var ae=null;if(o.tabbableGroups.length>0){var ye=h(V),Oe=ye>=0?o.containerGroups[ye]:void 0;if(ye<0)he.shiftKey?ae=o.tabbableGroups[o.tabbableGroups.length-1].lastTabbableNode:ae=o.tabbableGroups[0].firstTabbableNode;else if(he.shiftKey){var De=VT(o.tabbableGroups,function(kt){var Yt=kt.firstTabbableNode;return V===Yt});if(De<0&&(Oe.container===V||w2(V,i.tabbableOptions)&&!d_(V,i.tabbableOptions)&&!Oe.nextTabbableNode(V,!1))&&(De=ye),De>=0){var He=De===0?o.tabbableGroups.length-1:De-1,ke=o.tabbableGroups[He];ae=ke.lastTabbableNode}}else{var nt=VT(o.tabbableGroups,function(kt){var Yt=kt.lastTabbableNode;return V===Yt});if(nt<0&&(Oe.container===V||w2(V,i.tabbableOptions)&&!d_(V,i.tabbableOptions)&&!Oe.nextTabbableNode(V))&&(nt=ye),nt>=0){var be=nt===o.tabbableGroups.length-1?0:nt+1,Bt=o.tabbableGroups[be];ae=Bt.firstTabbableNode}}}else ae=g("fallbackFocus");ae&&(he.preventDefault(),k(ae))},$=function(he){if(ihe(he)&&Qv(i.escapeDeactivates,he)!==!1){he.preventDefault(),s.deactivate();return}if(ohe(he)){N(he);return}},q=function(he){var V=zx(he);h(V)>=0||Qv(i.clickOutsideDeactivates,he)||Qv(i.allowOutsideClick,he)||(he.preventDefault(),he.stopImmediatePropagation())},oe=function(){if(o.active)return qT.activateTrap(s),o.delayInitialFocusTimer=i.delayInitialFocus?HT(function(){k(C())}):k(C()),r.addEventListener("focusin",J,!0),r.addEventListener("mousedown",L,{capture:!0,passive:!1}),r.addEventListener("touchstart",L,{capture:!0,passive:!1}),r.addEventListener("click",q,{capture:!0,passive:!1}),r.addEventListener("keydown",$,{capture:!0,passive:!1}),s},ce=function(){if(o.active)return r.removeEventListener("focusin",J,!0),r.removeEventListener("mousedown",L,!0),r.removeEventListener("touchstart",L,!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(he){if(o.active)return this;var V=a(he,"onActivate"),ae=a(he,"onPostActivate"),ye=a(he,"checkCanFocusTrap");ye||B(),o.active=!0,o.paused=!1,o.nodeFocusedBeforeActivation=r.activeElement,V&&V();var Oe=function(){ye&&B(),oe(),ae&&ae()};return ye?(ye(o.containers.concat()).then(Oe,Oe),this):(Oe(),this)},deactivate:function(he){if(!o.active)return this;var V=YT({onDeactivate:i.onDeactivate,onPostDeactivate:i.onPostDeactivate,checkCanReturnFocus:i.checkCanReturnFocus},he);clearTimeout(o.delayInitialFocusTimer),o.delayInitialFocusTimer=void 0,ce(),o.active=!1,o.paused=!1,qT.deactivateTrap(s);var ae=a(V,"onDeactivate"),ye=a(V,"onPostDeactivate"),Oe=a(V,"checkCanReturnFocus"),De=a(V,"returnFocus","returnFocusOnDeactivate");ae&&ae();var He=function(){HT(function(){De&&k(P(o.nodeFocusedBeforeActivation)),ye&&ye()})};return De&&Oe?(Oe(P(o.nodeFocusedBeforeActivation)).then(He,He),this):(He(),this)},pause:function(){return o.paused||!o.active?this:(o.paused=!0,ce(),this)},unpause:function(){return!o.paused||!o.active?this:(o.paused=!1,B(),oe(),this)},updateContainerElements:function(he){var V=[].concat(he).filter(Boolean);return o.containers=V.map(function(ae){return typeof ae=="string"?r.querySelector(ae):ae}),o.active&&B(),this}},s.updateContainerElements(n),s};const she=Object.freeze(Object.defineProperty({__proto__:null,createFocusTrap:ahe},Symbol.toStringTag,{value:"Module"})),lhe=EO(she),uhe=EO(the);function zE(e){"@babel/helpers - typeof";return zE=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},zE(e)}function Ahe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function ZT(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 che(e,n,t){return n&&ZT(e.prototype,n),t&&ZT(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function dhe(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&&jE(e,n)}function jE(e,n){return jE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},jE(e,n)}function hhe(e){var n=phe();return function(){var r=X3(e),i;if(n){var o=X3(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return fhe(this,i)}}function fhe(e,n){if(n&&(zE(n)==="object"||typeof n=="function"))return n;if(n!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return h_(e)}function h_(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function phe(){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 X3(e){return X3=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},X3(e)}function mhe(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var jx=Br,ghe=Qm,Ri=hh,yhe=lhe,vhe=yhe.createFocusTrap,_he=uhe,Che=_he.isFocusable,A8=function(e){dhe(t,e);var n=hhe(t);function t(r){var i;Ahe(this,t),i=n.call(this,r),mhe(h_(i),"getNodeForOption",function(a){var h,g=(h=this.internalOptions[a])!==null&&h!==void 0?h:this.originalOptions[a];if(typeof g=="function"){for(var C=arguments.length,B=new Array(C>1?C-1:0),k=1;k<C;k++)B[k-1]=arguments[k];g=g.apply(void 0,B)}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 L;if(P=(L=this.getDocument())===null||L===void 0?void 0:L.querySelector(g),!P)throw new Error("`".concat(a,"` as selector refers to no known node"))}return P}),i.handleDeactivate=i.handleDeactivate.bind(h_(i)),i.handlePostDeactivate=i.handlePostDeactivate.bind(h_(i)),i.handleClickOutsideDeactivates=i.handleClickOutsideDeactivates.bind(h_(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 che(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(),h=!!(i.originalOptions.returnFocusOnDeactivate&&a!==null&&a!==void 0&&a.focus&&(!i.outsideClick||i.outsideClick.allowDeactivation&&!Che(i.outsideClick.target,i.internalOptions.tabbableOptions))),g=i.internalOptions.preventScroll,C=g===void 0?!1:g;h&&a.focus({preventScroll:C}),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(ghe.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,h=i.paused&&!this.props.paused;if(o&&(this.updatePreviousElement(),this.focusTrap.activate()),s){this.deactivateTrap();return}a&&this.focusTrap.pause(),h&&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?jx.Children.only(this.props.children):void 0;if(o){if(o.type&&o.type===jx.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 C=i.props.containerElements;o&&(typeof o.ref=="function"?o.ref(g):o.ref&&(o.ref.current=g)),i.focusTrapElements=C||[g]},a=jx.cloneElement(o,{ref:s});return a}return null}}]),t}(jx.Component),$v=typeof Element>"u"?Function:Element;A8.propTypes={active:Ri.bool,paused:Ri.bool,focusTrapOptions:Ri.shape({document:Ri.object,onActivate:Ri.func,onPostActivate:Ri.func,checkCanFocusTrap:Ri.func,onDeactivate:Ri.func,onPostDeactivate:Ri.func,checkCanReturnFocus:Ri.func,initialFocus:Ri.oneOfType([Ri.instanceOf($v),Ri.string,Ri.bool,Ri.func]),fallbackFocus:Ri.oneOfType([Ri.instanceOf($v),Ri.string,Ri.func]),escapeDeactivates:Ri.oneOfType([Ri.bool,Ri.func]),clickOutsideDeactivates:Ri.oneOfType([Ri.bool,Ri.func]),returnFocusOnDeactivate:Ri.bool,setReturnFocus:Ri.oneOfType([Ri.instanceOf($v),Ri.string,Ri.bool,Ri.func]),allowOutsideClick:Ri.oneOfType([Ri.bool,Ri.func]),preventScroll:Ri.bool,tabbableOptions:Ri.shape({displayCheck:Ri.oneOf(["full","non-zero-area","none"]),getShadowRoot:Ri.oneOfType([Ri.bool,Ri.func])})}),containerElements:Ri.arrayOf(Ri.instanceOf($v)),children:Ri.oneOfType([Ri.element,Ri.instanceOf($v)])};A8.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:vhe};var bhe=A8,XT=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 JT(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function ZM(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 eK(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 Wx=Br,Bg=Qm,Nx=!!Bg.createPortal;function xhe(e,n){if(!window.document)return function(r){eK(i,r);function i(){return JT(this,i),ZM(this,(i.__proto__||Object.getPrototypeOf(i)).apply(this,arguments))}return XT(i,[{key:"render",value:function(){return!1}}]),i}(Wx.Component);n=n||{};var t=function(r){eK(i,r);function i(){var o,s,a,h;JT(this,i);for(var g=arguments.length,C=Array(g),B=0;B<g;B++)C[B]=arguments[B];return h=(s=(a=ZM(this,(o=i.__proto__||Object.getPrototypeOf(i)).call.apply(o,[this].concat(C))),a),a.renderDisplaced=function(){Bg.unstable_renderSubtreeIntoContainer(a,Wx.createElement(e,a.props,a.props.children),a.container)},a.removeDisplaced=function(){Bg.unmountComponentAtNode(a.container)},s),ZM(a,h)}return XT(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(){Nx||this.props.mounted&&this.renderDisplaced()}},{key:"componentDidUpdate",value:function(s){Nx||(s.mounted&&!this.props.mounted?Bg.unmountComponentAtNode(this.container):this.props.mounted&&this.renderDisplaced())}},{key:"componentWillUnmount",value:function(){Nx||Bg.unmountComponentAtNode(this.container),n.renderTo||this.container.parentNode.removeChild(this.container)}},{key:"render",value:function(){return!Nx||this.props.mounted===!1?null:Bg.createPortal(Wx.createElement(e,this.props,this.props.children),this.container)}}]),i}(Wx.Component);return t.defaultProps={mounted:!0},t.WrappedComponent=e,t}var whe=xhe,BW={exports:{}};(function(e){(function(n){var t=!1,r,i;function o(){if(typeof r<"u")return r;var B=document.documentElement,k=document.createElement("div");return k.setAttribute("style","width:99px;height:99px;position:absolute;top:-9999px;overflow:scroll;"),B.appendChild(k),r=k.offsetWidth-k.clientWidth,B.removeChild(k),r}function s(){return document.documentElement.scrollHeight>window.innerHeight}function a(B){if(!(typeof document>"u"||t)){var k=document.documentElement;i=window.pageYOffset,s()?k.style.width="calc(100% - "+o()+"px)":k.style.width="100%",k.style.position="fixed",k.style.top=-i+"px",k.style.overflow="hidden",t=!0}}function h(){if(!(typeof document>"u"||!t)){var B=document.documentElement;B.style.width="",B.style.position="",B.style.top="",B.style.overflow="",window.scroll(0,i),t=!1}}function g(){if(t){h();return}a()}var C={on:a,off:h,toggle:g};e.exports=C})()})(BW);var Mhe=BW.exports;function WE(e){"@babel/helpers - typeof";return WE=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},WE(e)}function She(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function tK(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 Ehe(e,n,t){return n&&tK(e.prototype,n),t&&tK(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ohe(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&&NE(e,n)}function NE(e,n){return NE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},NE(e,n)}function Bhe(e){var n=Ihe();return function(){var r=J3(e),i;if(n){var o=J3(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return khe(this,i)}}function khe(e,n){if(n&&(WE(n)==="object"||typeof n=="function"))return n;if(n!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return f_(e)}function f_(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ihe(){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 J3(e){return J3=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},J3(e)}function p_(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var Yv=Br,The=bhe,kW=whe,Gx=Mhe,c8=function(e){Ohe(t,e);var n=Bhe(t);function t(r){var i;if(She(this,t),i=n.call(this,r),p_(f_(i),"getApplicationNode",function(){return i.props.getApplicationNode?i.props.getApplicationNode():i.props.applicationNode}),p_(f_(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)}),p_(f_(i),"checkDocumentKeyDown",function(o){i.props.escapeExits&&(o.key==="Escape"||o.key==="Esc"||o.keyCode===27)&&i.exit(o)}),p_(f_(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 Ehe(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&&Gx.on()}},{key:"componentDidUpdate",value:function(i){i.scrollDisabled&&!this.props.scrollDisabled?Gx.off():!i.scrollDisabled&&this.props.scrollDisabled&&Gx.on(),this.props.escapeExits&&!i.escapeExits?this.addKeyDownListener():!this.props.escapeExits&&i.escapeExits&&this.removeKeyDownListener()}},{key:"componentWillUnmount",value:function(){this.props.scrollDisabled&&Gx.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 h in this.props.underlayProps)a[h]=this.props.underlayProps[h];var g={};i.includeDefaultStyles&&(g={display:"inline-block",height:"100%",verticalAlign:"middle"});var C={key:"a",style:g},B={};if(i.includeDefaultStyles&&(B={display:"inline-block",textAlign:"left",top:0,maxWidth:"100%",cursor:"auto",outline:i.focusDialog?0:null},i.verticallyCenter&&(B.verticalAlign="middle",B.top=0)),i.dialogStyle)for(var k in i.dialogStyle)i.dialogStyle.hasOwnProperty(k)&&(B[k]=i.dialogStyle[k]);var P={key:"b",ref:(function($){this.dialogNode=$}).bind(this),role:i.alert?"alertdialog":"dialog",id:i.dialogId,className:i.dialogClass,style:B};i.titleId?P["aria-labelledby"]=i.titleId:i.titleText&&(P["aria-label"]=i.titleText),i.focusDialog&&(P.tabIndex="-1");for(var L in i)/^(data-|aria-)/.test(L)&&(P[L]=i[L]);var J=[Yv.createElement("div",P,i.children)];i.verticallyCenter&&J.unshift(Yv.createElement("div",C));var N=i.focusTrapOptions||{};return(i.focusDialog||i.initialFocus)&&(N.initialFocus=i.focusDialog?"#".concat(this.props.dialogId):i.initialFocus),N.escapeDeactivates=i.escapeExits,Yv.createElement(The,{focusTrapOptions:N,paused:i.focusTrapPaused},Yv.createElement("div",a,J))}}]),t}(Yv.Component);p_(c8,"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 IW=kW(c8);IW.renderTo=function(e){return kW(c8,{renderTo:e})};var Khe=IW;const Phe=fa(Khe);function uu(){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 uu=function(){return s},s}uu();class Of extends Sn.Component{constructor(){super(...arguments);an(this,"onClose",(uu().s[1]++,()=>{uu().f[0]++,uu().s[2]++,document.activeElement?(uu().b[0][0]++,uu().s[3]++,document.activeElement.blur()):uu().b[0][1]++,uu().s[4]++,setTimeout(()=>{uu().f[1]++,uu().s[5]++,this.props.onOpenToggle(!1)},0)}))}render(){return uu().f[2]++,uu().s[6]++,this.props.isOpen?(uu().b[1][0]++,uu().s[7]++,G.jsx(Phe,{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:G.jsxs("div",{className:bf("maputnik-modal",this.props.className),"data-wd-key":this.props["data-wd-key"],children:[G.jsxs("header",{className:"maputnik-modal-header",children:[G.jsx("h1",{className:"maputnik-modal-header-title",children:this.props.title}),G.jsx("span",{className:"maputnik-modal-header-space"}),G.jsx("button",{className:"maputnik-modal-header-toggle",title:"Close modal",onClick:this.onClose,"data-wd-key":this.props["data-wd-key"]+".close-modal",children:G.jsx(JJ,{})})]}),G.jsx("div",{className:"maputnik-modal-scroller",children:G.jsx("div",{className:"maputnik-modal-content",children:this.props.children})})]})})):(uu().b[1][1]++,uu().s[8]++,!1)}}an(Of,"defaultProps",(uu().s[0]++,{underlayClickExits:!0}));const Fhe=8,Dhe={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"}}]}},Lhe={"*":{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."}},Uhe=["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],Rhe={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."}},zhe={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."}},jhe={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."}},Whe={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>}`."}},Nhe={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."}}},Ghe={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."}}},Qhe={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."}},$he=["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background"],Yhe={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"}},qhe={"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"}},Hhe={"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"}},Vhe={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"}},Zhe={"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"}},Xhe={"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 doesnt 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"}},Jhe={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"}},efe={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"}},tfe={type:"array",value:"*",doc:"A filter selects specific features from a layer."},nfe={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."},rfe={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."},ife={type:"array",minimum:0,maximum:24,value:["number","color"],length:2,doc:"Zoom level and value pair."},ofe={type:"array",value:"*",minimum:1,doc:"An expression defines a function that can be used for data-driven style properties or feature filters."},afe={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"}}}}},sfe={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"}}}},lfe={"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"}},ufe={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"}}}},Afe=["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background"],cfe={"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"}},dfe={"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"}},hfe={"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"}},ffe={"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"}},pfe={"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"}},mfe={"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"}},gfe={"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"}},yfe={"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"}},vfe={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."}},_fe={"*":{type:"string",doc:"A name of a feature property to use as ID for feature state."}},no={$version:Fhe,$root:Dhe,sources:Lhe,source:Uhe,source_vector:Rhe,source_raster:zhe,source_raster_dem:jhe,source_geojson:Whe,source_video:Nhe,source_image:Ghe,layer:Qhe,layout:$he,layout_background:Yhe,layout_fill:qhe,layout_circle:Hhe,layout_heatmap:Vhe,"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:Zhe,layout_symbol:Xhe,layout_raster:Jhe,layout_hillshade:efe,filter:tfe,filter_operator:nfe,geometry_type:rfe,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:ife,expression:ofe,expression_name:afe,light:sfe,sky:lfe,terrain:ufe,paint:Afe,paint_fill:cfe,"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:dfe,paint_circle:hfe,paint_heatmap:ffe,paint_symbol:pfe,paint_raster:mfe,paint_hillshade:gfe,paint_background:yfe,transition:vfe,"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:_fe};function Fo(){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 Fo=function(){return s},s}Fo();class d8 extends Sn.Component{constructor(t){Fo().f[0]++,Fo().s[0]++;super(t);an(this,"onToggleDoc",(Fo().s[2]++,t=>{Fo().f[1]++,Fo().s[3]++,this.setState({open:t},()=>{Fo().f[2]++,Fo().s[4]++,this.props.onToggleDoc?(Fo().b[0][0]++,Fo().s[5]++,this.props.onToggleDoc(this.state.open)):Fo().b[0][1]++})}));Fo().s[1]++,this.state={open:!1}}render(){Fo().f[3]++;const{label:t,fieldSpec:r}=(Fo().s[6]++,this.props),{doc:i}=(Fo().s[7]++,Fo().b[1][0]++,r||(Fo().b[1][1]++,{}));if(Fo().s[8]++,i)return Fo().b[2][0]++,Fo().s[9]++,G.jsx("label",{className:"maputnik-doc-wrapper",children:G.jsxs("div",{className:"maputnik-doc-target",children:[t," ",G.jsx("button",{"aria-label":this.state.open?(Fo().b[3][0]++,"close property documentation"):(Fo().b[3][1]++,"open property documentation"),className:`maputnik-doc-button maputnik-doc-button--${this.state.open?(Fo().b[4][0]++,"open"):(Fo().b[4][1]++,"closed")}`,onClick:()=>(Fo().f[4]++,Fo().s[10]++,this.onToggleDoc(!this.state.open)),"data-wd-key":"field-doc-button-"+t,children:this.state.open?(Fo().b[5][0]++,G.jsx(RJ,{})):(Fo().b[5][1]++,G.jsx(zJ,{}))})]})});if(Fo().b[2][1]++,Fo().s[11]++,t)return Fo().b[6][0]++,Fo().s[12]++,G.jsx("label",{className:"maputnik-doc-wrapper",children:G.jsx("div",{className:"maputnik-doc-target",children:t})});Fo().b[6][1]++,Fo().s[13]++}}function wa(){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 wa=function(){return s},s}wa();const nK=(wa().s[0]++,{js:"JS",android:"Android",ios:"iOS",macos:"macOS"});class h8 extends Sn.Component{render(){wa().f[0]++;const{fieldSpec:n}=(wa().s[1]++,this.props),{doc:t,values:r}=(wa().s[2]++,n),i=(wa().s[3]++,n["sdk-support"]),o=(wa().s[4]++,wa().b[0][0]++,!!r&&(wa().b[0][1]++,!Array.isArray(r)));return wa().s[5]++,G.jsxs(G.Fragment,{children:[(wa().b[1][0]++,t&&(wa().b[1][1]++,G.jsxs("div",{className:"SpecDoc",children:[G.jsx("div",{className:"SpecDoc__doc","data-wd-key":"spec-field-doc",children:t}),(wa().b[2][0]++,o&&(wa().b[2][1]++,G.jsx("ul",{className:"SpecDoc__values",children:Object.entries(r).map(([s,a])=>(wa().f[1]++,wa().s[6]++,G.jsxs("li",{children:[G.jsx("code",{children:JSON.stringify(s)}),G.jsx("div",{children:a.doc})]},s)))})))]}))),(wa().b[3][0]++,i&&(wa().b[3][1]++,G.jsx("div",{className:"SpecDoc__sdk-support",children:G.jsxs("table",{className:"SpecDoc__sdk-support__table",children:[G.jsx("thead",{children:G.jsxs("tr",{children:[G.jsx("th",{}),Object.values(nK).map(s=>(wa().f[2]++,wa().s[7]++,G.jsx("th",{children:s},s)))]})}),G.jsx("tbody",{children:Object.entries(i).map(([s,a])=>(wa().f[3]++,wa().s[8]++,G.jsxs("tr",{children:[G.jsx("td",{children:s}),Object.keys(nK).map(h=>(wa().f[4]++,wa().s[9]++,Object.prototype.hasOwnProperty.call(a,h)?(wa().b[4][0]++,wa().s[10]++,G.jsx("td",{children:a[h]},h)):(wa().b[4][1]++,wa().s[11]++,G.jsx("td",{children:"no"},h))))]},s)))})]})})))]})}}function Ao(){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 Ao=function(){return s},s}Ao();class ra extends Sn.Component{constructor(t){Ao().f[0]++,Ao().s[1]++;super(t);an(this,"_blockEl",(Ao().s[0]++,null));an(this,"onToggleDoc",(Ao().s[6]++,t=>{Ao().f[2]++,Ao().s[7]++,this.setState({showDoc:t})}));an(this,"onLabelClick",(Ao().s[8]++,t=>{var o;Ao().f[3]++;const r=(Ao().s[9]++,t.nativeEvent.target),i=(Ao().s[10]++,(o=this._blockEl)==null?void 0:o.contains(r));Ao().s[11]++,Ao().b[3][0]++,t.nativeEvent.target.nodeName!=="INPUT"&&(Ao().b[3][1]++,!i)?(Ao().b[2][0]++,Ao().s[12]++,t.stopPropagation()):Ao().b[2][1]++,Ao().s[13]++,t.preventDefault()}));Ao().s[2]++,this.state={showDoc:!1}}onChange(t){Ao().f[1]++;const r=(Ao().s[3]++,t.target.value);if(Ao().s[4]++,this.props.onChange)return Ao().b[0][0]++,Ao().s[5]++,this.props.onChange(r===""?(Ao().b[1][0]++,void 0):(Ao().b[1][1]++,r));Ao().b[0][1]++}render(){return Ao().f[4]++,Ao().s[14]++,G.jsxs("label",{style:this.props.style,"data-wd-key":this.props["data-wd-key"],className:bf({"maputnik-input-block":!0,"maputnik-input-block--wide":this.props.wideMode,"maputnik-action-block":this.props.action}),onClick:this.onLabelClick,children:[(Ao().b[4][0]++,this.props.fieldSpec&&(Ao().b[4][1]++,G.jsx("div",{className:"maputnik-input-block-label",children:G.jsx(d8,{label:this.props.label,onToggleDoc:this.onToggleDoc,fieldSpec:this.props.fieldSpec})}))),(Ao().b[5][0]++,!this.props.fieldSpec&&(Ao().b[5][1]++,G.jsx("div",{className:"maputnik-input-block-label",children:this.props.label}))),G.jsx("div",{className:"maputnik-input-block-action",children:this.props.action}),G.jsx("div",{className:"maputnik-input-block-content",ref:t=>(Ao().f[5]++,Ao().s[15]++,this._blockEl=t),children:this.props.children}),(Ao().b[6][0]++,this.props.fieldSpec&&(Ao().b[6][1]++,G.jsx("div",{className:"maputnik-doc-inline",style:{display:this.state.showDoc?(Ao().b[7][0]++,""):(Ao().b[7][1]++,"none")},children:G.jsx(h8,{fieldSpec:this.props.fieldSpec})})))]})}}function ku(){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 ku=function(){return s},s}ku();class x1 extends Sn.Component{render(){ku().f[0]++;let n=(ku().s[0]++,this.props.options);return ku().s[1]++,ku().b[1][0]++,n.length>0&&(ku().b[1][1]++,!Array.isArray(n[0]))?(ku().b[0][0]++,ku().s[2]++,n=n.map(t=>(ku().f[1]++,ku().s[3]++,[t,t]))):ku().b[0][1]++,ku().s[4]++,G.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=>(ku().f[2]++,ku().s[5]++,this.props.onChange(t.target.value)),"aria-label":this.props["aria-label"],children:n.map(([t,r])=>(ku().f[3]++,ku().s[6]++,G.jsx("option",{value:t,children:r},t)))})}}function ti(){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 ti=function(){return s},s}ti();class wd extends Sn.Component{constructor(n){ti().f[1]++,ti().s[1]++,super(n),ti().s[2]++,this.state={editing:!1,value:(ti().b[0][0]++,n.value||(ti().b[0][1]++,""))}}static getDerivedStateFromProps(n,t){if(ti().f[2]++,ti().s[3]++,t.editing)ti().b[1][1]++;else return ti().b[1][0]++,ti().s[4]++,{value:n.value};return ti().s[5]++,{}}render(){ti().f[3]++;let n,t;return ti().s[6]++,this.props.multi?(ti().b[2][0]++,ti().s[7]++,n="textarea",ti().s[8]++,t=["maputnik-string","maputnik-string--multi"]):(ti().b[2][1]++,ti().s[9]++,n="input",ti().s[10]++,t=["maputnik-string"]),ti().s[11]++,this.props.disabled?(ti().b[3][0]++,ti().s[12]++,t.push("maputnik-string--disabled")):ti().b[3][1]++,ti().s[13]++,Sn.createElement(n,{"aria-label":this.props["aria-label"],"data-wd-key":this.props["data-wd-key"],spellCheck:Object.prototype.hasOwnProperty.call(this.props,"spellCheck")?(ti().b[4][0]++,this.props.spellCheck):(ti().b[4][1]++,n!=="input"),disabled:this.props.disabled,className:t.join(" "),style:this.props.style,value:this.state.value===void 0?(ti().b[5][0]++,""):(ti().b[5][1]++,this.state.value),placeholder:this.props.default,title:this.props.title,onChange:r=>{ti().f[4]++,ti().s[14]++,this.setState({editing:!0,value:r.target.value},()=>{ti().f[5]++,ti().s[15]++,this.props.onInput?(ti().b[6][0]++,ti().s[16]++,this.props.onInput(this.state.value)):ti().b[6][1]++})},onBlur:()=>{ti().f[6]++,ti().s[17]++,this.state.value!==this.props.value?(ti().b[7][0]++,ti().s[18]++,this.setState({editing:!1}),ti().s[19]++,this.props.onChange?(ti().b[8][0]++,ti().s[20]++,this.props.onChange(this.state.value)):ti().b[8][1]++):ti().b[7][1]++},onKeyDown:r=>{ti().f[7]++,ti().s[21]++,ti().b[10][0]++,r.keyCode===13&&(ti().b[10][1]++,this.props.onChange)?(ti().b[9][0]++,ti().s[22]++,this.props.onChange(this.state.value)):ti().b[9][1]++},required:this.props.required})}}an(wd,"defaultProps",(ti().s[0]++,{onInput:()=>{ti().f[0]++}}));function lp(){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 lp=function(){return s},s}lp();class f8 extends Sn.Component{render(){return lp().f[0]++,lp().s[1]++,G.jsxs(ra,{label:"Type",fieldSpec:no.layer.type,"data-wd-key":this.props.wdKey,error:this.props.error,children:[(lp().b[0][0]++,this.props.disabled&&(lp().b[0][1]++,G.jsx(wd,{value:this.props.value,disabled:!0}))),(lp().b[1][0]++,!this.props.disabled&&(lp().b[1][1]++,G.jsx(x1,{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"})))]})}}an(f8,"defaultProps",(lp().s[0]++,{disabled:!1}));function e4(){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 e4=function(){return s},s}e4();class TW extends Sn.Component{render(){return e4().f[0]++,e4().s[0]++,G.jsx(ra,{label:"ID",fieldSpec:no.layer.id,"data-wd-key":this.props.wdKey,error:this.props.error,children:G.jsx(wd,{value:this.props.value,onInput:this.props.onChange,"data-wd-key":this.props.wdKey+".input"})})}}var KW={exports:{}},Cfe=/[\-+]?(?:\d*\.|)\d+(?:[eE][\-+]?\d+|)/.source;function bfe(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 PW(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 GE(e){return PW(e)}function QE(e){return PW(e,!0)}function FW(e){var n=bfe(e),t=e.ownerDocument,r=t.defaultView||t.parentWindow;return n.left+=GE(r),n.top+=QE(r),n}function xfe(e,n,t){var r="",i=e.ownerDocument;return(t=t||i.defaultView.getComputedStyle(e,null))&&(r=t.getPropertyValue(n)||t[n]),r}var wfe=new RegExp("^("+Cfe+")(?!px)[a-z%]+$","i"),Mfe=/^(top|right|bottom|left)$/,XM="currentStyle",JM="runtimeStyle",C0="left",Sfe="px";function Efe(e,n){var t=e[XM]&&e[XM][n];if(wfe.test(t)&&!Mfe.test(n)){var r=e.style,i=r[C0],o=e[JM][C0];e[JM][C0]=e[XM][C0],r[C0]=n==="fontSize"?"1em":t||0,t=r.pixelLeft+Sfe,r[C0]=i,e[JM][C0]=o}return t===""?"auto":t}var p1;typeof window<"u"&&(p1=window.getComputedStyle?xfe:Efe);function Ofe(e,n){dy(e,"position")==="static"&&(e.style.position="relative");var t=FW(e),r={},i,o;for(o in n)i=parseFloat(dy(e,o))||0,r[o]=i+n[o]-t[o];dy(e,r)}function p8(e,n){for(var t=0;t<e.length;t++)n(e[t])}function DW(e){return p1(e,"boxSizing")==="border-box"}var Bfe=["margin","border","padding"],$E=-1,kfe=2,YE=1,Ife=0;function Tfe(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 m_(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(p1(e,a))||0}return r}function M2(e){return e!=null&&e==e.window}var df={};p8(["Width","Height"],function(e){df["doc"+e]=function(n){var t=n.document;return Math.max(t.documentElement["scroll"+e],t.body["scroll"+e],df["viewport"+e](t))},df["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 rK(e,n,t){if(M2(e))return n==="width"?df.viewportWidth(e):df.viewportHeight(e);if(e.nodeType===9)return n==="width"?df.docWidth(e):df.docHeight(e);var r=n==="width"?["Left","Right"]:["Top","Bottom"],i=n==="width"?e.offsetWidth:e.offsetHeight;p1(e);var o=DW(e),s=0;(i==null||i<=0)&&(i=void 0,s=p1(e,n),(s==null||Number(s)<0)&&(s=e.style[n]||0),s=parseFloat(s)||0),t===void 0&&(t=o?YE:$E);var a=i!==void 0||o,h=i||s;return t===$E?a?h-m_(e,["border","padding"],r):s:a?h+(t===YE?0:t===kfe?-m_(e,["border"],r):m_(e,["margin"],r)):s+m_(e,Bfe.slice(t),r)}var Kfe={position:"absolute",visibility:"hidden",display:"block"};function iK(e){var n,t=arguments;return e.offsetWidth!==0?n=rK.apply(void 0,t):Tfe(e,Kfe,function(){n=rK.apply(void 0,t)}),n}p8(["width","height"],function(e){var n=e.charAt(0).toUpperCase()+e.slice(1);df["outer"+n]=function(r,i){return r&&iK(r,e,i?Ife:YE)};var t=e==="width"?["Left","Right"]:["Top","Bottom"];df[e]=function(r,i){if(i!==void 0){if(r){p1(r);var o=DW(r);return o&&(i+=m_(r,["padding","border"],t)),dy(r,e,i)}return}return r&&iK(r,e,$E)}});function dy(e,n,t){if(typeof n=="object"){for(var r in n)dy(e,r,n[r]);return}if(typeof t<"u")typeof t=="number"&&(t=t+"px"),e.style[n]=t;else return p1(e,n)}function LW(e,n){for(var t in n)e[t]=n[t];return e}var UW=KW.exports={getWindow:function(e){var n=e.ownerDocument||e;return n.defaultView||n.parentWindow},offset:function(e,n){if(typeof n<"u")Ofe(e,n);else return FW(e)},isWindow:M2,each:p8,css:dy,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:LW,scrollLeft:function(e,n){if(M2(e)){if(n===void 0)return GE(e);window.scrollTo(n,QE(e))}else{if(n===void 0)return e.scrollLeft;e.scrollLeft=n}},scrollTop:function(e,n){if(M2(e)){if(n===void 0)return QE(e);window.scrollTo(GE(e),n)}else{if(n===void 0)return e.scrollTop;e.scrollTop=n}},merge:function(){for(var e={},n=0;n<arguments.length;n++)UW.mix(e,arguments[n]);return e},viewportWidth:0,viewportHeight:0};LW(UW,df);var Pfe=KW.exports,Za=Pfe;function Ffe(e,n,t){t=t||{},n.nodeType===9&&(n=Za.getWindow(n));var r=t.allowHorizontalScroll,i=t.onlyScrollIfNeeded,o=t.alignWithTop,s=t.alignWithLeft;r=r===void 0?!0:r;var a=Za.isWindow(n),h=Za.offset(e),g=Za.outerHeight(e),C=Za.outerWidth(e),B,k,P,L,J,N,$,q,oe,ce;a?($=n,ce=Za.height($),oe=Za.width($),q={left:Za.scrollLeft($),top:Za.scrollTop($)},J={left:h.left-q.left,top:h.top-q.top},N={left:h.left+C-(q.left+oe),top:h.top+g-(q.top+ce)},L=q):(B=Za.offset(n),k=n.clientHeight,P=n.clientWidth,L={left:n.scrollLeft,top:n.scrollTop},J={left:h.left-(B.left+(parseFloat(Za.css(n,"borderLeftWidth"))||0)),top:h.top-(B.top+(parseFloat(Za.css(n,"borderTopWidth"))||0))},N={left:h.left+C-(B.left+P+(parseFloat(Za.css(n,"borderRightWidth"))||0)),top:h.top+g-(B.top+k+(parseFloat(Za.css(n,"borderBottomWidth"))||0))}),J.top<0||N.top>0?o===!0?Za.scrollTop(n,L.top+J.top):o===!1?Za.scrollTop(n,L.top+N.top):J.top<0?Za.scrollTop(n,L.top+J.top):Za.scrollTop(n,L.top+N.top):i||(o=o===void 0?!0:!!o,o?Za.scrollTop(n,L.top+J.top):Za.scrollTop(n,L.top+N.top)),r&&(J.left<0||N.left>0?s===!0?Za.scrollLeft(n,L.left+J.left):s===!1?Za.scrollLeft(n,L.left+N.left):J.left<0?Za.scrollLeft(n,L.left+J.left):Za.scrollLeft(n,L.left+N.left):i||(s=s===void 0?!0:!!s,s?Za.scrollLeft(n,L.left+J.left):Za.scrollLeft(n,L.left+N.left)))}var Dfe=Ffe,Lfe=Dfe,S2=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},Ufe=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 Rfe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function zfe(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 jfe(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 K0=Br,Kl=hh,Wfe=Qm,oK=Wfe.findDOMNode,Nfe=Lfe,Gfe=["blur","checkValidity","click","focus","select","setCustomValidity","setSelectionRange","setRangeText"];function Qfe(){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 k5=function(e){jfe(n,e);function n(t){Rfe(this,n);var r=zfe(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 Ufe(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,Gfe.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;Nfe(oK(r),oK(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,h=o===null?0:o,g=this.getFilteredItems(i),C=0;C<g.length&&!i.isItemSelectable(g[h]);C++)h=(h+1)%g.length;var B=g[h]&&i.isItemSelectable(g[h])?g[h]:null;if(s!==""&&B){var k=a(B),P=k.toLowerCase().indexOf(s.toLowerCase())===0;if(P)return{highlightedIndex:h}}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,h=parseInt(o.marginRight,10)||0;this.setState({menuTop:i.bottom+s,menuLeft:i.left+a,menuWidth:i.width+a+h})}},{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,h){var g=r.props.renderItem(a,r.state.highlightedIndex===h,{cursor:"default"});return K0.cloneElement(g,{onMouseEnter:r.props.isItemSelectable(a)?function(){return r.highlightItemFromMouse(h)}:null,onClick:r.props.isItemSelectable(a)?function(){return r.selectItemFromMouse(a)}:null,ref:function(B){return r.refs["item-"+h]=B}})}),o={left:this.state.menuLeft,top:this.state.menuTop,minWidth:this.state.menuWidth},s=this.props.renderMenu(i,this.props.value,o);return K0.cloneElement(s,{ref:function(h){return r.refs.menu=h},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=Qfe(),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),h=a[s],g=this.props.getItemValue(h);o=function(){return i.props.onSelect(g,h)}}this.setState({isOpen:!1,highlightedIndex:null},o);var C=this.props.inputProps.onBlur;C&&C(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 h=this.props.inputProps.onFocus;h&&h(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 K0.createElement("div",S2({style:S2({},this.props.wrapperStyle)},this.props.wrapperProps),this.props.renderInput(S2({},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&&K0.createElement("pre",{style:{marginLeft:300}},JSON.stringify(this._debugStates.slice(Math.max(0,this._debugStates.length-5),this._debugStates.length),null,2)))}}]),n}(K0.Component);k5.propTypes={items:Kl.array.isRequired,value:Kl.any,onChange:Kl.func,onSelect:Kl.func,shouldItemRender:Kl.func,isItemSelectable:Kl.func,sortItems:Kl.func,getItemValue:Kl.func.isRequired,renderItem:Kl.func.isRequired,renderMenu:Kl.func,menuStyle:Kl.object,renderInput:Kl.func,inputProps:Kl.object,wrapperProps:Kl.object,wrapperStyle:Kl.object,autoHighlight:Kl.bool,selectOnBlur:Kl.bool,onMenuVisibilityChange:Kl.func,open:Kl.bool,debug:Kl.bool};k5.defaultProps={value:"",wrapperProps:{},wrapperStyle:{display:"inline-block"},inputProps:{},renderInput:function(n){return K0.createElement("input",n)},onChange:function(){},onSelect:function(){},isItemSelectable:function(){return!0},renderMenu:function(n,t,r){return K0.createElement("div",{style:S2({},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(){}};k5.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 $fe=k5;const Yfe=fa($fe);function Qi(){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 Qi=function(){return s},s}Qi();const aK=(Qi().s[0]++,140);class Hy extends Sn.Component{constructor(){super(...arguments);an(this,"state",(Qi().s[1]++,{maxHeight:aK}));an(this,"autocompleteMenuEl",(Qi().s[2]++,null))}calcMaxHeight(){if(Qi().f[1]++,Qi().s[4]++,this.props.keepMenuWithinWindowBounds){Qi().b[0][0]++;const t=(Qi().s[5]++,window.innerHeight-this.autocompleteMenuEl.getBoundingClientRect().top),r=(Qi().s[6]++,Math.min(t,aK));Qi().s[7]++,r!=this.state.maxHeight?(Qi().b[1][0]++,Qi().s[8]++,this.setState({maxHeight:r})):Qi().b[1][1]++}else Qi().b[0][1]++}componentDidMount(){Qi().f[2]++,Qi().s[9]++,this.calcMaxHeight()}componentDidUpdate(){Qi().f[3]++,Qi().s[10]++,this.calcMaxHeight()}onChange(t){Qi().f[4]++,Qi().s[11]++,this.props.onChange(t===""?(Qi().b[2][0]++,void 0):(Qi().b[2][1]++,t))}render(){return Qi().f[5]++,Qi().s[12]++,G.jsx("div",{ref:t=>{Qi().f[6]++,Qi().s[13]++,this.autocompleteMenuEl=t},children:G.jsx(Yfe,{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=>(Qi().f[7]++,Qi().s[14]++,t[0]),onSelect:t=>(Qi().f[8]++,Qi().s[15]++,this.onChange(t)),onChange:(t,r)=>(Qi().f[9]++,Qi().s[16]++,this.onChange(r)),shouldItemRender:(t,r=(Qi().b[3][0]++,""))=>(Qi().f[10]++,Qi().s[17]++,typeof r=="string"?(Qi().b[4][0]++,Qi().s[18]++,t[0].toLowerCase().indexOf(r.toLowerCase())>-1):(Qi().b[4][1]++,Qi().s[19]++,!1)),renderItem:(t,r)=>(Qi().f[11]++,Qi().s[20]++,G.jsx("div",{className:bf({"maputnik-autocomplete-menu-item":!0,"maputnik-autocomplete-menu-item-selected":r}),children:t[1]},t[0]))})})}}an(Hy,"defaultProps",(Qi().s[3]++,{onChange:()=>{Qi().f[0]++},options:[]}));function lm(){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 lm=function(){return s},s}lm();class m8 extends Sn.Component{render(){var n;return lm().f[1]++,lm().s[1]++,G.jsx(ra,{label:"Source",fieldSpec:no.layer.source,error:this.props.error,"data-wd-key":this.props.wdKey,children:G.jsx(Hy,{value:this.props.value,onChange:this.props.onChange,options:(n=this.props.sourceIds)==null?void 0:n.map(t=>(lm().f[2]++,lm().s[2]++,[t,t]))})})}}an(m8,"defaultProps",(lm().s[0]++,{onChange:()=>{lm().f[0]++},sourceIds:[]}));function um(){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 um=function(){return s},s}um();class g8 extends Sn.Component{render(){var n;return um().f[1]++,um().s[1]++,G.jsx(ra,{label:"Source Layer",fieldSpec:Ea.layer["source-layer"],"data-wd-key":"layer-source-layer",error:this.props.error,children:G.jsx(Hy,{keepMenuWithinWindowBounds:!!this.props.isFixed,value:this.props.value,onChange:this.props.onChange,options:(n=this.props.sourceLayerIds)==null?void 0:n.map(t=>(um().f[2]++,um().s[2]++,[t,t]))})})}}an(g8,"defaultProps",(um().s[0]++,{onChange:()=>{um().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 qfe extends Sn.Component{constructor(t){dr().f[1]++,dr().s[10]++;super(t);an(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]++,G.jsx(Of,{isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Add Layer","data-wd-key":"modal:add-layer",className:"maputnik-add-modal",children:G.jsxs("div",{className:"maputnik-add-layer",children:[G.jsx(TW,{value:this.state.id,wdKey:"add-layer.layer-id",onChange:i=>{dr().f[6]++,dr().s[34]++,this.setState({id:i})}}),G.jsx(f8,{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]++,G.jsx(m8,{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]++,G.jsx(g8,{isFixed:!0,sourceLayerIds:r,value:this.state["source-layer"],onChange:i=>(dr().f[9]++,dr().s[37]++,this.setState({"source-layer":i}))}))),G.jsx(ja,{className:"maputnik-add-layer-button",onClick:this.addLayer,"data-wd-key":"add-layer",children:"Add Layer"})]})})}}function G0(){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 G0=function(){return s},s}G0();let sK=(G0().s[0]++,0);function Ty(e=(G0().b[0][0]++,"")){return G0().f[0]++,G0().s[1]++,sK++,G0().s[2]++,e+sK}function oi(){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 oi=function(){return s},s}oi();function Hfe(e,n){oi().f[0]++;const t=(oi().s[0]++,{...e.paint});oi().s[1]++,Object.keys(t).forEach(i=>{oi().f[1]++,oi().s[2]++,i in Ea["paint_"+n]?oi().b[0][1]++:(oi().b[0][0]++,oi().s[3]++,delete t[i])});const r=(oi().s[4]++,{...e.layout});return oi().s[5]++,Object.keys(r).forEach(i=>{oi().f[2]++,oi().s[6]++,i in Ea["layout_"+n]?oi().b[1][1]++:(oi().b[1][0]++,oi().s[7]++,delete r[i])}),oi().s[8]++,{...e,paint:t,layout:r,type:n}}function Vfe(e,n,t,r){if(oi().f[3]++,oi().s[9]++,r===void 0)if(oi().b[2][0]++,oi().s[10]++,n){oi().b[3][0]++;const i=(oi().s[11]++,{...e,[n]:{...e[n]}});return oi().s[12]++,delete i[n][t],oi().s[13]++,Object.keys(i[n]).length<1?(oi().b[4][0]++,oi().s[14]++,delete i[n]):oi().b[4][1]++,oi().s[15]++,i}else{oi().b[3][1]++;const i=(oi().s[16]++,{...e});return oi().s[17]++,delete i[t],oi().s[18]++,i}else return oi().b[2][1]++,oi().s[19]++,n?(oi().b[5][0]++,oi().s[20]++,{...e,[n]:{...e[n],[t]:r}}):(oi().b[5][1]++,oi().s[21]++,{...e,[t]:r})}function Qg(e){return oi().f[4]++,oi().s[22]++,e.replace(" ","-").replace("_","-").split("-")[0]}function Zfe(e,n){oi().f[5]++;const t=(oi().s[23]++,Qg(e[n].id));let r=(oi().s[24]++,n);oi().s[25]++;for(let i=(oi().s[26]++,n);i>0;i--){const o=(oi().s[27]++,Qg(e[i-1].id));if(oi().s[28]++,o===t)oi().b[6][0]++,oi().s[29]++,r=i-1;else return oi().b[6][1]++,oi().s[30]++,r}return oi().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 RW extends Sn.Component{constructor(t){qt().f[1]++,qt().s[1]++;super(t);an(this,"selectedItemRef");an(this,"scrollContainerRef");an(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]++,Qg(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=Sn.createRef(),qt().s[3]++,this.scrollContainerRef=Sn.createRef(),qt().s[4]++,this.state={collapsedGroups:{},areAllGroupsExpanded:!1,keys:{add:+Ty()},isOpen:{add:!1}}}toggleModal(t){qt().f[2]++,qt().s[5]++,this.setState({keys:{...this.state.keys,[t]:+Ty()},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]++,Qg(s.id)==Qg(a.id))){qt().b[2][0]++;const h=(qt().s[26]++,t[t.length-1]);qt().s[27]++,h.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 C=(qt().s[40]++,{id:g.id});return qt().s[41]++,g.layout?(qt().b[7][0]++,qt().s[42]++,C.layout={visibility:g.layout.visibility}):qt().b[7][1]++,qt().s[43]++,C}const o=(qt().s[44]++,x6.isEqual(t.layers.map(i),this.props.layers.map(i)));function s(g){qt().f[11]++;const C=(qt().s[45]++,{...g});return qt().s[46]++,delete C.layers,qt().s[47]++,C}const a=(qt().s[48]++,x6.isEqual(s(this.props),s(t))),h=(qt().s[49]++,qt().b[8][0]++,!(o&&(qt().b[8][1]++,a)));return qt().s[50]++,h}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]++,Qg(o[0].id));if(qt().s[66]++,o.length>1){qt().b[14][0]++;const a=(qt().s[67]++,G.jsx(Ade,{"data-wd-key":[s,r].join("-"),"aria-controls":o.map(h=>(qt().f[16]++,qt().s[68]++,h.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,h)=>{var P;qt().f[17]++;const g=(qt().s[71]++,Zfe(this.props.layers,r)),C=(qt().s[72]++,this.props.errors.find(L=>(qt().f[18]++,qt().s[73]++,qt().b[16][0]++,L.parsed&&(qt().b[16][1]++,L.parsed.type==="layer")&&(qt().b[16][2]++,L.parsed.data.index==r)))),B=(qt().s[74]++,{});qt().s[75]++,r===this.props.selectedLayerIndex?(qt().b[17][0]++,qt().s[76]++,B.ref=this.selectedItemRef):qt().b[17][1]++;const k=(qt().s[77]++,G.jsx(Wde,{className:bf({"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]++,h==o.length-1&&(qt().b[19][1]++,o.length>1)),"maputnik-layer-list-item--error":!!C}),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),...B},a.key));qt().s[78]++,t.push(k),qt().s[79]++,r+=1})}),qt().s[80]++,G.jsxs("section",{className:"maputnik-layer-list",role:"complementary","aria-label":"Layers list",ref:this.scrollContainerRef,children:[G.jsx(qfe,{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),G.jsxs("header",{className:"maputnik-layer-list-header",children:[G.jsx("span",{className:"maputnik-layer-list-header-title",children:"Layers"}),G.jsx("span",{className:"maputnik-space"}),G.jsx("div",{className:"maputnik-default-property",children:G.jsx("div",{className:"maputnik-multibutton",children:G.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")})})}),G.jsx("div",{className:"maputnik-default-property",children:G.jsx("div",{className:"maputnik-multibutton",children:G.jsx("button",{onClick:this.toggleModal.bind(this,"add"),"data-wd-key":"layer-list:add-layer",className:"maputnik-button maputnik-button-selected",children:"Add Layer"})})})]}),G.jsx("div",{role:"navigation","aria-label":"Layers list",children:G.jsx("ul",{className:"maputnik-layer-list-container",children:t})})]})}}an(RW,"defaultProps",(qt().s[0]++,{onLayerSelect:()=>{qt().f[0]++}}));const Xfe=(qt().s[81]++,Ude(e=>(qt().f[19]++,qt().s[82]++,G.jsx(RW,{...e}))));class Jfe extends Sn.Component{render(){return qt().f[20]++,qt().s[83]++,G.jsx(Xfe,{...this.props,helperClass:"sortableHelper",onSortEnd:this.props.onMoveLayer.bind(this),useDragHandle:!0,shouldCancelStart:()=>(qt().f[21]++,qt().s[84]++,!1)})}}var I5={},zW="a menu outside a mounted Wrapper with an id, or a menu that does not exist";function epe(e,n){I5[e]=n}function tpe(e){delete I5[e]}function npe(e,n){var t=I5[e];if(!t)throw new Error("Cannot open "+zW);t.openMenu(n)}function rpe(e,n){var t=I5[e];if(!t)throw new Error("Cannot close "+zW);t.closeMenu(n)}var jW={registerManager:epe,unregisterManager:tpe,openMenu:npe,closeMenu:rpe};function Ts(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)}Ts.prototype.activate=function(){return document.addEventListener("keydown",this._boundHandleKeydownEvent,!0),this};Ts.prototype.deactivate=function(){return document.removeEventListener("keydown",this._boundHandleKeydownEvent,!0),this._clearSearchStringRefreshTimer(),this};Ts.prototype._handleKeydownEvent=function(e){var n=this._getActiveElementIndex();if(n!==-1){var t=!1;this._keybindingsLookup.forEach((function(r){if(ipe(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)}};Ts.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};Ts.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};Ts.prototype.moveFocusToFirst=function(){this.focusNodeAtIndex(0)};Ts.prototype.moveFocusToLast=function(){this.focusNodeAtIndex(this._members.length-1)};Ts.prototype._handleUnboundKey=function(e){if(this._settings.stringSearch){if(this._searchString!==""&&(e.key===" "||e.keyCode===32))return e.preventDefault(),-1;if(!ope(e.keyCode)||e.ctrlKey||e.metaKey||e.altKey)return-1;e.preventDefault(),this._addToSearchString(String.fromCharCode(e.keyCode)),this._runStringSearch()}};Ts.prototype._clearSearchString=function(){this._searchString=""};Ts.prototype._addToSearchString=function(e){this._searchString+=e.toLowerCase()};Ts.prototype._startSearchStringRefreshTimer=function(){var e=this;this._clearSearchStringRefreshTimer(),this._stringSearchTimer=setTimeout(function(){e._clearSearchString()},this._settings.stringSearchDelay)};Ts.prototype._clearSearchStringRefreshTimer=function(){clearTimeout(this._stringSearchTimer)};Ts.prototype._runStringSearch=function(){this._startSearchStringRefreshTimer(),this.moveFocusByString(this._searchString)};Ts.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 WW(n.node)};Ts.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};Ts.prototype._getActiveElementIndex=function(){return this._findIndexOfNode(document.activeElement)};Ts.prototype.focusNodeAtIndex=function(e){var n=this._members[e];return n&&WW(n.node),this};Ts.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};Ts.prototype.removeMember=function(e){var n=typeof e=="number"?e:this._findIndexOfNode(e);if(n!==-1)return this._members.splice(n,1),this};Ts.prototype.clearMembers=function(){return this._members=[],this};Ts.prototype.setMembers=function(e){this.clearMembers();for(var n=0,t=e.length;n<t;n++)this.addMember(e[n]);return this};Ts.prototype.getMembers=function(){return this._members};Ts.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 ipe(e,n){for(var t in e)if(n[t]!==void 0&&e[t]!==n[t])return!1;return!0}function ope(e){return e>=65&&e<=90}function WW(e){!e||!e.focus||(e.focus(),e.tagName.toLowerCase()==="input"&&e.select())}var ape=function(n){return new Ts(n)},spe=ape,lK=jW,lpe={wrap:!0,stringSearch:!0},upe={init:function(n){this.updateOptions(n),this.handleBlur=Ape.bind(this),this.handleSelection=cpe.bind(this),this.handleMenuKey=dpe.bind(this),this.focusGroup=spe(lpe),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&&lK.registerManager(this.options.id,this),t&&t.id&&t.id!==this.options.id&&lK.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 Ape(){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 cpe(e,n){this.options.closeOnSelection&&this.closeMenu({focusButton:!0}),this.options.onSelection&&this.options.onSelection(e,n)}function dpe(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 hpe=function(e){var n=Object.create(upe);return n.init(e),n},fpe=Br,ppe=fpe.createContext(),T5=ppe,Qx=hh,K5={refType:Qx.oneOfType([Qx.func,Qx.shape({current:Qx.elementType})])},P5=function(e,n,t){t=t||{};for(var r in n)n.hasOwnProperty(r)&&(t[r]||(e[r]=n[r]))};function mpe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function gpe(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 ype(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 F_=Br,fg=hh,vpe=hpe,_pe=T5,Cpe=K5,bpe=Cpe.refType,qE=P5,t4={children:fg.node.isRequired,forwardedRef:bpe,onMenuToggle:fg.func,onSelection:fg.func,closeOnSelection:fg.bool,closeOnBlur:fg.bool,tag:fg.string},uK=function(n){return{onMenuToggle:n.onMenuToggle,onSelection:n.onSelection,closeOnSelection:n.closeOnSelection,closeOnBlur:n.closeOnBlur,id:n.id}},y8=function(e){ype(n,e);function n(t){mpe(this,n);var r=gpe(this,e.call(this,t));return r.manager=vpe(uK(t)),r}return n.prototype.componentDidUpdate=function(){this.manager.updateOptions(uK(this.props))},n.prototype.render=function(){var r={};return qE(r,this.props,t4),F_.createElement(_pe.Provider,{value:this.manager},F_.createElement(this.props.tag,r,this.props.children))},n}(F_.Component);y8.propTypes=t4;y8.defaultProps={tag:"div"};var xpe=F_.forwardRef(function(e,n){var t={forwardedRef:n};return qE(t,e,{children:t4.children,forwardedRef:t4.forwardedRef}),qE(t,{forwardedRef:n}),F_.createElement(y8,t,e.children)});function wpe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function AK(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 Mpe(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 hy=Br,$x=hh,Spe=T5,Epe=K5,Ope=Epe.refType,E2=P5,D_={ambManager:$x.object.isRequired,children:$x.node.isRequired,disabled:$x.bool,forwardedRef:Ope,tag:$x.string},Bpe=function(){return["button","fieldset","input","optgroup","option","select","textarea"]},v8=function(e){Mpe(n,e);function n(){var t,r,i;wpe(this,n);for(var o=arguments.length,s=Array(o),a=0;a<o;a++)s[a]=arguments[a];return i=(t=(r=AK(this,e.call.apply(e,[this].concat(s))),r),r.ref=hy.createRef(),r.handleKeyDown=function(h){if(!r.props.disabled){var g=r.props.ambManager;switch(h.key){case"ArrowDown":h.preventDefault(),g.isOpen?g.focusItem(0):g.openMenu();break;case"Enter":case" ":h.preventDefault(),g.toggleMenu();break;case"Escape":g.handleMenuKey(h);break;default:g.handleButtonNonArrowKey(h)}}},r.handleClick=function(){r.props.disabled||r.props.ambManager.toggleMenu({},{focusMenu:!1})},r.setRef=function(h){r.ref.current=h,typeof r.props.forwardedRef=="function"?r.props.forwardedRef(h):r.props.forwardedRef&&(r.props.forwardedRef.current=h)},t),AK(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 E2(s,D_),Bpe().indexOf(r.tag)>=0&&delete s.disabled,i.options.closeOnBlur&&(o.onBlur=i.handleBlur),E2(o,r,s),E2(o,{ref:this.setRef}),hy.createElement(r.tag,o,r.children)},n}(hy.Component);v8.propTypes=D_;v8.defaultProps={tag:"span"};var kpe=hy.forwardRef(function(e,n){return hy.createElement(Spe.Consumer,null,function(t){var r={ambManager:t,forwardedRef:n};return E2(r,e,{ambManager:D_.ambManager,children:D_.children,forwardedRef:D_.forwardedRef}),hy.createElement(v8,r,e.children)})}),Ipe=function(n,t,r){var i=0,o=0,s=!1,a=!1,h=!1;n.addEventListener("click",g,r),n.addEventListener("touchstart",C,r);function g(N){h||t(N)}function C(N){h=!0,!s&&(s=!0,n.addEventListener("touchmove",B,r),n.addEventListener("touchend",k,r),n.addEventListener("touchcancel",P,r),a=!1,i=N.touches[0].clientX,o=N.touches[0].clientY)}function B(N){a||Math.abs(N.touches[0].clientX-i)<=10&&Math.abs(N.touches[0].clientY-o)<=10||(a=!0)}function k(N){s=!1,L(),a||t(N)}function P(){s=!1,a=!1,i=0,o=0}function L(){n.removeEventListener("touchmove",B,r),n.removeEventListener("touchend",k,r),n.removeEventListener("touchcancel",P,r)}function J(){n.removeEventListener("click",g,r),n.removeEventListener("touchstart",C,r),L()}return{remove:J}};function Tpe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function cK(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 Kpe(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 fy=Br,qv=hh,Ppe=Ipe,Fpe=T5,Dpe=K5,Lpe=Dpe.refType,HE=P5,L_={ambManager:qv.object.isRequired,children:qv.oneOfType([qv.func,qv.node]).isRequired,forwardedRef:Lpe,tag:qv.string},_8=function(e){Kpe(n,e);function n(){var t,r,i;Tpe(this,n);for(var o=arguments.length,s=Array(o),a=0;a<o;a++)s[a]=arguments[a];return i=(t=(r=cK(this,e.call.apply(e,[this].concat(s))),r),r.ref=fy.createRef(),r.addTapListener=function(){var h=r.ref.current;if(h){var g=h.ownerDocument;g&&(r.tapListener=Ppe(g.documentElement,r.handleTap))}},r.handleTap=function(h){r.ref.current.contains(h.target)||r.props.ambManager.button.ref.current.contains(h.target)||r.props.ambManager.closeMenu()},r.setRef=function(h){r.ref.current=h,typeof r.props.forwardedRef=="function"?r.props.forwardedRef(h):r.props.forwardedRef&&(r.props.forwardedRef.current=h)},t),cK(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),HE(s,r,L_),HE(s,{ref:this.setRef}),fy.createElement(r.tag,s,o)},n}(fy.Component);_8.propTypes=L_;_8.defaultProps={tag:"div"};var Upe=fy.forwardRef(function(e,n){return fy.createElement(Fpe.Consumer,null,function(t){var r={ambManager:t,forwardedRef:n};return HE(r,e,{ambManager:L_.ambManager,children:L_.children,forwardedRef:L_.forwardedRef}),fy.createElement(_8,r,e.children)})});function Rpe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function dK(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 zpe(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 py=Br,Hv=hh,jpe=T5,Wpe=K5,Npe=Wpe.refType,NW=P5,U_={ambManager:Hv.object.isRequired,children:Hv.node.isRequired,forwardedRef:Npe,tag:Hv.string,text:Hv.string,value:Hv.any},C8=function(e){zpe(n,e);function n(){var t,r,i;Rpe(this,n);for(var o=arguments.length,s=Array(o),a=0;a<o;a++)s[a]=arguments[a];return i=(t=(r=dK(this,e.call.apply(e,[this].concat(s))),r),r.ref=py.createRef(),r.handleKeyDown=function(h){h.key!=="Enter"&&h.key!==" "||r.props.tag==="a"&&r.props.href||(h.preventDefault(),r.selectItem(h))},r.selectItem=function(h){var g=typeof r.props.value<"u"?r.props.value:r.props.children;r.props.ambManager.handleSelection(g,h)},r.setRef=function(h){r.ref.current=h,typeof r.props.forwardedRef=="function"?r.props.forwardedRef(h):r.props.forwardedRef&&(r.props.forwardedRef.current=h)},t),dK(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 NW(r,this.props,U_),py.createElement(this.props.tag,r,this.props.children)},n}(py.Component);C8.propTypes=U_;C8.defaultProps={tag:"div"};var Gpe=py.forwardRef(function(e,n){return py.createElement(jpe.Consumer,null,function(t){var r={ambManager:t,forwardedRef:n};return NW(r,e,{ambManager:U_.ambManager,children:U_.children,forwardedRef:U_.forwardedRef}),py.createElement(C8,r,e.children)})}),hK=jW,Yx={Wrapper:xpe,Button:kpe,Menu:Upe,MenuItem:Gpe,openMenu:hK.openMenu,closeMenu:hK.closeMenu};function F5(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function fK(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 b8(e,n,t){return n&&fK(e.prototype,n),t&&fK(e,t),e}function gs(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function xf(){return xf=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},xf.apply(this,arguments)}function pK(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 VE(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?arguments[n]:{};n%2?pK(Object(t),!0).forEach(function(r){gs(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):pK(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function x8(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&&ZE(e,n)}function n4(e){return n4=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},n4(e)}function ZE(e,n){return ZE=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},ZE(e,n)}function Qpe(){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 $pe(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 D5(e,n){if(e==null)return{};var t=$pe(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 ah(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ype(e,n){return n&&(typeof n=="object"||typeof n=="function")?n:ah(e)}function w8(e){var n=Qpe();return function(){var r=n4(e),i;if(n){var o=n4(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Ype(this,i)}}function qpe(e,n){return Zpe(e)||Jpe(e,n)||GW(e,n)||tme()}function Hpe(e){return Vpe(e)||Xpe(e)||GW(e)||eme()}function Vpe(e){if(Array.isArray(e))return XE(e)}function Zpe(e){if(Array.isArray(e))return e}function Xpe(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function Jpe(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(h){i=!0,o=h}finally{try{!r&&s.return!=null&&s.return()}finally{if(i)throw o}}return t}}function GW(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 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 eme(){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 tme(){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 nme=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,h=a===void 0?!1:a;F5(this,e),gs(this,"expanded",void 0),gs(this,"allowMultipleExpanded",void 0),gs(this,"allowZeroExpanded",void 0),gs(this,"toggleExpanded",function(g){if(t.isItemDisabled(g))return t;var C=t.isItemExpanded(g);return C?t.augment({expanded:t.expanded.filter(function(B){return B!==g})}):t.augment({expanded:t.allowMultipleExpanded?[].concat(Hpe(t.expanded),[g]):[g]})}),gs(this,"isItemDisabled",function(g){var C=t.isItemExpanded(g),B=t.expanded.length===1;return!!(C&&!t.allowZeroExpanded&&B)}),gs(this,"isItemExpanded",function(g){return t.expanded.indexOf(g)!==-1}),gs(this,"getPanelAttributes",function(g,C){var B=C??t.isItemExpanded(g);return{role:t.allowMultipleExpanded?void 0:"region","aria-hidden":t.allowMultipleExpanded?!B:void 0,"aria-labelledby":t.getButtonId(g),id:t.getPanelId(g),hidden:B?void 0:!0}}),gs(this,"getHeadingAttributes",function(){return{role:"heading"}}),gs(this,"getButtonAttributes",function(g,C){var B=C??t.isItemExpanded(g),k=t.isItemDisabled(g);return{id:t.getButtonId(g),"aria-disabled":k,"aria-expanded":B,"aria-controls":t.getPanelId(g),role:"button",tabIndex:0}}),gs(this,"getPanelId",function(g){return"accordion__panel-".concat(g)}),gs(this,"getButtonId",function(g){return"accordion__heading-".concat(g)}),gs(this,"augment",function(g){return new e(VE({expanded:t.expanded,allowMultipleExpanded:t.allowMultipleExpanded,allowZeroExpanded:t.allowZeroExpanded},g))}),this.expanded=i,this.allowMultipleExpanded=s,this.allowZeroExpanded=h},QW=Br.createContext(null),$W=function(e){x8(t,e);var n=w8(t);function t(){var r;F5(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)),gs(ah(r),"state",new nme({expanded:r.props.preExpanded,allowMultipleExpanded:r.props.allowMultipleExpanded,allowZeroExpanded:r.props.allowZeroExpanded})),gs(ah(r),"toggleExpanded",function(a){r.setState(function(h){return h.toggleExpanded(a)},function(){r.props.onChange&&r.props.onChange(r.state.expanded)})}),gs(ah(r),"isItemDisabled",function(a){return r.state.isItemDisabled(a)}),gs(ah(r),"isItemExpanded",function(a){return r.state.isItemExpanded(a)}),gs(ah(r),"getPanelAttributes",function(a,h){return r.state.getPanelAttributes(a,h)}),gs(ah(r),"getHeadingAttributes",function(){return r.state.getHeadingAttributes()}),gs(ah(r),"getButtonAttributes",function(a,h){return r.state.getButtonAttributes(a,h)}),r}return b8(t,[{key:"render",value:function(){var i=this.state,o=i.allowZeroExpanded,s=i.allowMultipleExpanded;return Br.createElement(QW.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}(Br.PureComponent);gs($W,"defaultProps",{allowMultipleExpanded:!1,allowZeroExpanded:!1});var YW=function(e){x8(t,e);var n=w8(t);function t(){var r;F5(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)),gs(ah(r),"renderChildren",function(a){return a?r.props.children(a):null}),r}return b8(t,[{key:"render",value:function(){return Br.createElement(QW.Consumer,null,this.renderChildren)}}]),t}(Br.PureComponent),rme=function(n){var t=n.className,r=t===void 0?"accordion":t,i=n.allowMultipleExpanded,o=n.allowZeroExpanded,s=n.onChange,a=n.preExpanded,h=D5(n,["className","allowMultipleExpanded","allowZeroExpanded","onChange","preExpanded"]);return Br.createElement($W,{preExpanded:a,allowMultipleExpanded:i,allowZeroExpanded:o,onChange:s},Br.createElement("div",xf({"data-accordion-component":"Accordion",className:r},h)))},JE;(function(e){e.Accordion="Accordion",e.AccordionItem="AccordionItem",e.AccordionItemButton="AccordionItemButton",e.AccordionItemHeading="AccordionItemHeading",e.AccordionItemPanel="AccordionItemPanel"})(JE||(JE={}));var qW=JE,ime=0,eS=ime;function ome(){var e=eS;return eS=eS+1,"raa-".concat(e)}var ame=/[\u0009\u000a\u000c\u000d\u0020]/g;function MC(e){return e===""||ame.test(e)?(console.error('uuid must be a valid HTML5 id but was given "'.concat(e,'", ASCII whitespaces are forbidden')),!1):!0}var HW=Br.createContext(null),sme=function(n){var t=n.children,r=n.uuid,i=n.accordionContext,o=n.dangerouslySetExpanded,s=function(){i.toggleExpanded(r)},a=function(g){var C=o??g.isItemExpanded(r),B=g.isItemDisabled(r),k=g.getPanelAttributes(r,o),P=g.getHeadingAttributes(r),L=g.getButtonAttributes(r,o);return Br.createElement(HW.Provider,{value:{uuid:r,expanded:C,disabled:B,toggleExpanded:s,panelAttributes:k,headingAttributes:P,buttonAttributes:L}},t)};return Br.createElement(YW,null,a)},lme=function(n){return Br.createElement(YW,null,function(t){return Br.createElement(sme,xf({},n,{accordionContext:t}))})},L5=function(n){var t=n.children,r=function(o){return o?t(o):null};return Br.createElement(HW.Consumer,null,r)},VW=function(n){var t=n.uuid,r=n.dangerouslySetExpanded,i=n.className,o=i===void 0?"accordion__item":i,s=n.activeClassName,a=D5(n,["uuid","dangerouslySetExpanded","className","activeClassName"]),h=Br.useState(ome()),g=qpe(h,1),C=g[0],B=t??C,k=function(L){var J=L.expanded,N=J&&s?s:o;return Br.createElement("div",xf({"data-accordion-component":"AccordionItem",className:N},a))};return MC(B.toString()),a.id&&MC(a.id),Br.createElement(lme,{uuid:B,dangerouslySetExpanded:r},Br.createElement(L5,null,k))};VW.displayName=qW.AccordionItem;function ZW(e){return e&&(e.matches('[data-accordion-component="Accordion"]')?e:ZW(e.parentElement))}function U5(e){var n=ZW(e);return n&&Array.from(n.querySelectorAll('[data-accordion-component="AccordionItemButton"]'))}function ume(e){var n=U5(e)||[],t=n[0];t&&t.focus()}function Ame(e){var n=U5(e)||[],t=n[n.length-1];t&&t.focus()}function cme(e){var n=U5(e)||[],t=n.indexOf(e);if(t!==-1){var r=n[t+1];r&&r.focus()}}function dme(e){var n=U5(e)||[],t=n.indexOf(e);if(t!==-1){var r=n[t-1];r&&r.focus()}}var tp={END:"End",ENTER:"Enter",HOME:"Home",SPACE:" ",SPACE_DEPRECATED:"Spacebar",UP:"ArrowUp",DOWN:"ArrowDown",LEFT:"ArrowLeft",RIGHT:"ArrowRight"},hme=function(n){var t=n.toggleExpanded,r=n.className,i=r===void 0?"accordion__button":r,o=D5(n,["toggleExpanded","className"]),s=function(h){var g=h.key;if((g===tp.ENTER||g===tp.SPACE||g===tp.SPACE_DEPRECATED)&&(h.preventDefault(),t()),h.target instanceof HTMLElement)switch(g){case tp.HOME:{h.preventDefault(),ume(h.target);break}case tp.END:{h.preventDefault(),Ame(h.target);break}case tp.LEFT:case tp.UP:{h.preventDefault(),dme(h.target);break}case tp.RIGHT:case tp.DOWN:{h.preventDefault(),cme(h.target);break}}};return o.id&&MC(o.id),Br.createElement("div",xf({className:i},o,{role:"button",tabIndex:0,onClick:t,onKeyDown:s,"data-accordion-component":"AccordionItemButton"}))},fme=function(n){return Br.createElement(L5,null,function(t){var r=t.toggleExpanded,i=t.buttonAttributes;return Br.createElement(hme,xf({toggleExpanded:r},n,i))})},pme={className:"accordion__heading","aria-level":3},mme=`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.”
`,XW=function(e){x8(t,e);var n=w8(t);function t(){var r;F5(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)),gs(ah(r),"ref",void 0),gs(ah(r),"setRef",function(a){r.ref=a}),r}return b8(t,[{key:"componentDidUpdate",value:function(){t.VALIDATE(this.ref)}},{key:"componentDidMount",value:function(){t.VALIDATE(this.ref)}},{key:"render",value:function(){return Br.createElement("div",xf({"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(mme)}}]),t}(Br.PureComponent);gs(XW,"defaultProps",pme);var JW=function(n){return Br.createElement(L5,null,function(t){var r=t.headingAttributes;return n.id&&MC(n.id),Br.createElement(XW,xf({},n,r))})};JW.displayName=qW.AccordionItemHeading;var gme=function(n){var t=n.className,r=t===void 0?"accordion__panel":t,i=n.region,o=n.id,s=D5(n,["className","region","id"]),a=function(g){var C=g.panelAttributes;o&&MC(o);var B=VE(VE({},C),{},{"aria-labelledby":i?C["aria-labelledby"]:void 0});return Br.createElement("div",xf({"data-accordion-component":"AccordionItemPanel",className:r},s,B,{role:i?"region":void 0}))};return Br.createElement(L5,null,a)},tS={exports:{}},mK;function R5(){return mK||(mK=1,function(e,n){(function(t,r){e.exports=r()})(ch,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),h=o||s||a,g=h&&(o?document.documentMode||6:+(a||s)[1]),C=!a&&/WebKit\//.test(t),B=C&&/Qt\/\d+\.\d+/.test(t),k=!a&&/Chrome\/(\d+)/.exec(t),P=k&&+k[1],L=/Opera\//.test(t),J=/Apple Computer/.test(navigator.vendor),N=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(t),$=/PhantomJS/.test(t),q=J&&(/Mobile\/\w+/.test(t)||navigator.maxTouchPoints>2),oe=/Android/.test(t),ce=q||oe||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(t),me=q||/Mac/.test(r),he=/\bCrOS\b/.test(t),V=/win/i.test(r),ae=L&&t.match(/Version\/(\d*\.\d*)/);ae&&(ae=Number(ae[1])),ae&&ae>=15&&(L=!1,C=!0);var ye=me&&(B||L&&(ae==null||ae<12.11)),Oe=i||h&&g>=9;function De(A){return new RegExp("(^|\\s)"+A+"(?:$|\\s)\\s*")}var He=function(A,f){var x=A.className,b=De(f).exec(x);if(b){var E=x.slice(b.index+b[0].length);A.className=x.slice(0,b.index)+(E?b[1]+E:"")}};function ke(A){for(var f=A.childNodes.length;f>0;--f)A.removeChild(A.firstChild);return A}function nt(A,f){return ke(A).appendChild(f)}function be(A,f,x,b){var E=document.createElement(A);if(x&&(E.className=x),b&&(E.style.cssText=b),typeof f=="string")E.appendChild(document.createTextNode(f));else if(f)for(var U=0;U<f.length;++U)E.appendChild(f[U]);return E}function Bt(A,f,x,b){var E=be(A,f,x,b);return E.setAttribute("role","presentation"),E}var kt;document.createRange?kt=function(A,f,x,b){var E=document.createRange();return E.setEnd(b||A,x),E.setStart(A,f),E}:kt=function(A,f,x){var b=document.body.createTextRange();try{b.moveToElementText(A.parentNode)}catch{return b}return b.collapse(!0),b.moveEnd("character",x),b.moveStart("character",f),b};function Yt(A,f){if(f.nodeType==3&&(f=f.parentNode),A.contains)return A.contains(f);do if(f.nodeType==11&&(f=f.host),f==A)return!0;while(f=f.parentNode)}function jt(A){var f=A.ownerDocument||A,x;try{x=A.activeElement}catch{x=f.body||null}for(;x&&x.shadowRoot&&x.shadowRoot.activeElement;)x=x.shadowRoot.activeElement;return x}function Xe(A,f){var x=A.className;De(f).test(x)||(A.className+=(x?" ":"")+f)}function rt(A,f){for(var x=A.split(" "),b=0;b<x.length;b++)x[b]&&!De(x[b]).test(f)&&(f+=" "+x[b]);return f}var ot=function(A){A.select()};q?ot=function(A){A.selectionStart=0,A.selectionEnd=A.value.length}:h&&(ot=function(A){try{A.select()}catch{}});function on(A){return A.display.wrapper.ownerDocument}function gt(A){return at(A.display.wrapper)}function at(A){return A.getRootNode?A.getRootNode():A.ownerDocument}function It(A){return on(A).defaultView}function Lt(A){var f=Array.prototype.slice.call(arguments,1);return function(){return A.apply(null,f)}}function Me(A,f,x){f||(f={});for(var b in A)A.hasOwnProperty(b)&&(x!==!1||!f.hasOwnProperty(b))&&(f[b]=A[b]);return f}function fe(A,f,x,b,E){f==null&&(f=A.search(/[^\s\u00a0]/),f==-1&&(f=A.length));for(var U=b||0,Y=E||0;;){var te=A.indexOf(" ",U);if(te<0||te>=f)return Y+(f-U);Y+=te-U,Y+=x-Y%x,U=te+1}}var xe=function(){this.id=null,this.f=null,this.time=0,this.handler=Lt(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,f){this.f=f;var x=+new Date+A;(!this.id||x<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,A),this.time=x)};function Ue(A,f){for(var x=0;x<A.length;++x)if(A[x]==f)return x;return-1}var et=50,it={toString:function(){return"CodeMirror.Pass"}},bt={scroll:!1},Ut={origin:"*mouse"},Rt={origin:"+move"};function pt(A,f,x){for(var b=0,E=0;;){var U=A.indexOf(" ",b);U==-1&&(U=A.length);var Y=U-b;if(U==A.length||E+Y>=f)return b+Math.min(Y,f-E);if(E+=U-b,E+=x-E%x,b=U+1,E>=f)return b}}var rr=[""];function mn(A){for(;rr.length<=A;)rr.push(vn(rr)+" ");return rr[A]}function vn(A){return A[A.length-1]}function Xn(A,f){for(var x=[],b=0;b<A.length;b++)x[b]=f(A[b],b);return x}function cr(A,f,x){for(var b=0,E=x(f);b<A.length&&x(A[b])<=E;)b++;A.splice(b,0,f)}function Mr(){}function Gr(A,f){var x;return Object.create?x=Object.create(A):(Mr.prototype=A,x=new Mr),f&&Me(f,x),x}var gr=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function mi(A){return/\w/.test(A)||A>"€"&&(A.toUpperCase()!=A.toLowerCase()||gr.test(A))}function Se(A,f){return f?f.source.indexOf("\\w")>-1&&mi(A)?!0:f.test(A):mi(A)}function X(A){for(var f in A)if(A.hasOwnProperty(f)&&A[f])return!1;return!0}var H=/[\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 Te(A){return A.charCodeAt(0)>=768&&H.test(A)}function At(A,f,x){for(;(x<0?f>0:f<A.length)&&Te(A.charAt(f));)f+=x;return f}function St(A,f,x){for(var b=f>x?-1:1;;){if(f==x)return f;var E=(f+x)/2,U=b<0?Math.ceil(E):Math.floor(E);if(U==f)return A(U)?f:x;A(U)?x=U:f=U+b}}function Et(A,f,x,b){if(!A)return b(f,x,"ltr",0);for(var E=!1,U=0;U<A.length;++U){var Y=A[U];(Y.from<x&&Y.to>f||f==x&&Y.to==f)&&(b(Math.max(Y.from,f),Math.min(Y.to,x),Y.level==1?"rtl":"ltr",U),E=!0)}E||b(f,x,"ltr")}var Nt=null;function pn(A,f,x){var b;Nt=null;for(var E=0;E<A.length;++E){var U=A[E];if(U.from<f&&U.to>f)return E;U.to==f&&(U.from!=U.to&&x=="before"?b=E:Nt=E),U.from==f&&(U.from!=U.to&&x!="before"?b=E:Nt=E)}return b??Nt}var Kn=function(){var A="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",f="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function x(ge){return ge<=247?A.charAt(ge):1424<=ge&&ge<=1524?"R":1536<=ge&&ge<=1785?f.charAt(ge-1536):1774<=ge&&ge<=2220?"r":8192<=ge&&ge<=8203?"w":ge==8204?"b":"L"}var b=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,E=/[stwN]/,U=/[LRr]/,Y=/[Lb1n]/,te=/[1n]/;function le(ge,Qe,Je){this.level=ge,this.from=Qe,this.to=Je}return function(ge,Qe){var Je=Qe=="ltr"?"L":"R";if(ge.length==0||Qe=="ltr"&&!b.test(ge))return!1;for(var Mt=ge.length,yt=[],zt=0;zt<Mt;++zt)yt.push(x(ge.charCodeAt(zt)));for(var hn=0,kn=Je;hn<Mt;++hn){var Yn=yt[hn];Yn=="m"?yt[hn]=kn:kn=Yn}for(var xn=0,Ln=Je;xn<Mt;++xn){var sr=yt[xn];sr=="1"&&Ln=="r"?yt[xn]="n":U.test(sr)&&(Ln=sr,sr=="r"&&(yt[xn]="R"))}for(var Kr=1,_r=yt[0];Kr<Mt-1;++Kr){var Ai=yt[Kr];Ai=="+"&&_r=="1"&&yt[Kr+1]=="1"?yt[Kr]="1":Ai==","&&_r==yt[Kr+1]&&(_r=="1"||_r=="n")&&(yt[Kr]=_r),_r=Ai}for(var Uo=0;Uo<Mt;++Uo){var qa=yt[Uo];if(qa==",")yt[Uo]="N";else if(qa=="%"){var ba=void 0;for(ba=Uo+1;ba<Mt&&yt[ba]=="%";++ba);for(var Ua=Uo&&yt[Uo-1]=="!"||ba<Mt&&yt[ba]=="1"?"1":"N",us=Uo;us<ba;++us)yt[us]=Ua;Uo=ba-1}}for(var As=0,Ol=Je;As<Mt;++As){var el=yt[As];Ol=="L"&&el=="1"?yt[As]="L":U.test(el)&&(Ol=el)}for(var ws=0;ws<Mt;++ws)if(E.test(yt[ws])){var cs=void 0;for(cs=ws+1;cs<Mt&&E.test(yt[cs]);++cs);for(var ca=(ws?yt[ws-1]:Je)=="L",Ms=(cs<Mt?yt[cs]:Je)=="L",Hd=ca==Ms?ca?"L":"R":Je,GA=ws;GA<cs;++GA)yt[GA]=Hd;ws=cs-1}for(var zs=[],QA,js=0;js<Mt;)if(Y.test(yt[js])){var l0=js;for(++js;js<Mt&&Y.test(yt[js]);++js);zs.push(new le(0,l0,js))}else{var yA=js,wc=zs.length,Ha=Qe=="rtl"?1:0;for(++js;js<Mt&&yt[js]!="L";++js);for(var tl=yA;tl<js;)if(te.test(yt[tl])){yA<tl&&(zs.splice(wc,0,new le(1,yA,tl)),wc+=Ha);var Vd=tl;for(++tl;tl<js&&te.test(yt[tl]);++tl);zs.splice(wc,0,new le(2,Vd,tl)),wc+=Ha,yA=tl}else++tl;yA<js&&zs.splice(wc,0,new le(1,yA,js))}return Qe=="ltr"&&(zs[0].level==1&&(QA=ge.match(/^\s+/))&&(zs[0].from=QA[0].length,zs.unshift(new le(0,0,QA[0].length))),vn(zs).level==1&&(QA=ge.match(/\s+$/))&&(vn(zs).to-=QA[0].length,zs.push(new le(0,Mt-QA[0].length,Mt)))),Qe=="rtl"?zs.reverse():zs}}();function En(A,f){var x=A.order;return x==null&&(x=A.order=Kn(A.text,f)),x}var m=[],Kt=function(A,f,x){if(A.addEventListener)A.addEventListener(f,x,!1);else if(A.attachEvent)A.attachEvent("on"+f,x);else{var b=A._handlers||(A._handlers={});b[f]=(b[f]||m).concat(x)}};function Dr(A,f){return A._handlers&&A._handlers[f]||m}function Fn(A,f,x){if(A.removeEventListener)A.removeEventListener(f,x,!1);else if(A.detachEvent)A.detachEvent("on"+f,x);else{var b=A._handlers,E=b&&b[f];if(E){var U=Ue(E,x);U>-1&&(b[f]=E.slice(0,U).concat(E.slice(U+1)))}}}function Fe(A,f){var x=Dr(A,f);if(x.length)for(var b=Array.prototype.slice.call(arguments,2),E=0;E<x.length;++E)x[E].apply(null,b)}function de(A,f,x){return typeof f=="string"&&(f={type:f,preventDefault:function(){this.defaultPrevented=!0}}),Fe(A,x||f.type,A,f),ft(f)||f.codemirrorIgnore}function Ce(A){var f=A._handlers&&A._handlers.cursorActivity;if(f)for(var x=A.curOp.cursorActivityHandlers||(A.curOp.cursorActivityHandlers=[]),b=0;b<f.length;++b)Ue(x,f[b])==-1&&x.push(f[b])}function Be(A,f){return Dr(A,f).length>0}function ze(A){A.prototype.on=function(f,x){Kt(this,f,x)},A.prototype.off=function(f,x){Fn(this,f,x)}}function tt(A){A.preventDefault?A.preventDefault():A.returnValue=!1}function lt(A){A.stopPropagation?A.stopPropagation():A.cancelBubble=!0}function ft(A){return A.defaultPrevented!=null?A.defaultPrevented:A.returnValue==!1}function Ve(A){tt(A),lt(A)}function xt(A){return A.target||A.srcElement}function Xt(A){var f=A.which;return f==null&&(A.button&1?f=1:A.button&2?f=3:A.button&4&&(f=2)),me&&A.ctrlKey&&f==1&&(f=3),f}var Vt=function(){if(h&&g<9)return!1;var A=be("div");return"draggable"in A||"dragDrop"in A}(),Ht;function Qn(A){if(Ht==null){var f=be("span","");nt(A,be("span",[f,document.createTextNode("x")])),A.firstChild.offsetHeight!=0&&(Ht=f.offsetWidth<=1&&f.offsetHeight>2&&!(h&&g<8))}var x=Ht?be("span",""):be("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return x.setAttribute("cm-text",""),x}var Mn;function or(A){if(Mn!=null)return Mn;var f=nt(A,document.createTextNode("AخA")),x=kt(f,0,1).getBoundingClientRect(),b=kt(f,1,2).getBoundingClientRect();return ke(A),!x||x.left==x.right?!1:Mn=b.right-x.right<3}var ar=`
b`.split(/\n/).length!=3?function(A){for(var f=0,x=[],b=A.length;f<=b;){var E=A.indexOf(`
`,f);E==-1&&(E=A.length);var U=A.slice(f,A.charAt(E-1)=="\r"?E-1:E),Y=U.indexOf("\r");Y!=-1?(x.push(U.slice(0,Y)),f+=Y+1):(x.push(U),f=E+1)}return x}:function(A){return A.split(/\r\n?|\n/)},kr=window.getSelection?function(A){try{return A.selectionStart!=A.selectionEnd}catch{return!1}}:function(A){var f;try{f=A.ownerDocument.selection.createRange()}catch{}return!f||f.parentElement()!=A?!1:f.compareEndPoints("StartToEnd",f)!=0},jr=function(){var A=be("div");return"oncopy"in A?!0:(A.setAttribute("oncopy","return;"),typeof A.oncopy=="function")}(),Lr=null;function Wr(A){if(Lr!=null)return Lr;var f=nt(A,be("span","x")),x=f.getBoundingClientRect(),b=kt(f,0,1).getBoundingClientRect();return Lr=Math.abs(x.left-b.left)>1}var ir={},ui={};function Oi(A,f){arguments.length>2&&(f.dependencies=Array.prototype.slice.call(arguments,2)),ir[A]=f}function Yi(A,f){ui[A]=f}function _o(A){if(typeof A=="string"&&ui.hasOwnProperty(A))A=ui[A];else if(A&&typeof A.name=="string"&&ui.hasOwnProperty(A.name)){var f=ui[A.name];typeof f=="string"&&(f={name:f}),A=Gr(f,A),A.name=f.name}else{if(typeof A=="string"&&/^[\w\-]+\/[\w\-]+\+xml$/.test(A))return _o("application/xml");if(typeof A=="string"&&/^[\w\-]+\/[\w\-]+\+json$/.test(A))return _o("application/json")}return typeof A=="string"?{name:A}:A||{name:"null"}}function Jr(A,f){f=_o(f);var x=ir[f.name];if(!x)return Jr(A,"text/plain");var b=x(A,f);if(xo.hasOwnProperty(f.name)){var E=xo[f.name];for(var U in E)E.hasOwnProperty(U)&&(b.hasOwnProperty(U)&&(b["_"+U]=b[U]),b[U]=E[U])}if(b.name=f.name,f.helperType&&(b.helperType=f.helperType),f.modeProps)for(var Y in f.modeProps)b[Y]=f.modeProps[Y];return b}var xo={};function Wa(A,f){var x=xo.hasOwnProperty(A)?xo[A]:xo[A]={};Me(f,x)}function Ba(A,f){if(f===!0)return f;if(A.copyState)return A.copyState(f);var x={};for(var b in f){var E=f[b];E instanceof Array&&(E=E.concat([])),x[b]=E}return x}function bi(A,f){for(var x;A.innerMode&&(x=A.innerMode(f),!(!x||x.mode==A));)f=x.state,A=x.mode;return x||{mode:A,state:f}}function os(A,f,x){return A.startState?A.startState(f,x):!0}var hi=function(A,f,x){this.pos=this.start=0,this.string=A,this.tabSize=f||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=x};hi.prototype.eol=function(){return this.pos>=this.string.length},hi.prototype.sol=function(){return this.pos==this.lineStart},hi.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},hi.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},hi.prototype.eat=function(A){var f=this.string.charAt(this.pos),x;if(typeof A=="string"?x=f==A:x=f&&(A.test?A.test(f):A(f)),x)return++this.pos,f},hi.prototype.eatWhile=function(A){for(var f=this.pos;this.eat(A););return this.pos>f},hi.prototype.eatSpace=function(){for(var A=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>A},hi.prototype.skipToEnd=function(){this.pos=this.string.length},hi.prototype.skipTo=function(A){var f=this.string.indexOf(A,this.pos);if(f>-1)return this.pos=f,!0},hi.prototype.backUp=function(A){this.pos-=A},hi.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=fe(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?fe(this.string,this.lineStart,this.tabSize):0)},hi.prototype.indentation=function(){return fe(this.string,null,this.tabSize)-(this.lineStart?fe(this.string,this.lineStart,this.tabSize):0)},hi.prototype.match=function(A,f,x){if(typeof A=="string"){var b=function(Y){return x?Y.toLowerCase():Y},E=this.string.substr(this.pos,A.length);if(b(E)==b(A))return f!==!1&&(this.pos+=A.length),!0}else{var U=this.string.slice(this.pos).match(A);return U&&U.index>0?null:(U&&f!==!1&&(this.pos+=U[0].length),U)}},hi.prototype.current=function(){return this.string.slice(this.start,this.pos)},hi.prototype.hideFirstChars=function(A,f){this.lineStart+=A;try{return f()}finally{this.lineStart-=A}},hi.prototype.lookAhead=function(A){var f=this.lineOracle;return f&&f.lookAhead(A)},hi.prototype.baseToken=function(){var A=this.lineOracle;return A&&A.baseToken(this.pos)};function Wn(A,f){if(f-=A.first,f<0||f>=A.size)throw new Error("There is no line "+(f+A.first)+" in the document.");for(var x=A;!x.lines;)for(var b=0;;++b){var E=x.children[b],U=E.chunkSize();if(f<U){x=E;break}f-=U}return x.lines[f]}function eo(A,f,x){var b=[],E=f.line;return A.iter(f.line,x.line+1,function(U){var Y=U.text;E==x.line&&(Y=Y.slice(0,x.ch)),E==f.line&&(Y=Y.slice(f.ch)),b.push(Y),++E}),b}function io(A,f,x){var b=[];return A.iter(f,x,function(E){b.push(E.text)}),b}function qi(A,f){var x=f-A.height;if(x)for(var b=A;b;b=b.parent)b.height+=x}function ve(A){if(A.parent==null)return null;for(var f=A.parent,x=Ue(f.lines,A),b=f.parent;b;f=b,b=b.parent)for(var E=0;b.children[E]!=f;++E)x+=b.children[E].chunkSize();return x+f.first}function Ye(A,f){var x=A.first;e:do{for(var b=0;b<A.children.length;++b){var E=A.children[b],U=E.height;if(f<U){A=E;continue e}f-=U,x+=E.chunkSize()}return x}while(!A.lines);for(var Y=0;Y<A.lines.length;++Y){var te=A.lines[Y],le=te.height;if(f<le)break;f-=le}return x+Y}function Jt(A,f){return f>=A.first&&f<A.first+A.size}function sn(A,f){return String(A.lineNumberFormatter(f+A.firstLineNumber))}function Ft(A,f,x){if(x===void 0&&(x=null),!(this instanceof Ft))return new Ft(A,f,x);this.line=A,this.ch=f,this.sticky=x}function Cn(A,f){return A.line-f.line||A.ch-f.ch}function ur(A,f){return A.sticky==f.sticky&&Cn(A,f)==0}function fi(A){return Ft(A.line,A.ch)}function ei(A,f){return Cn(A,f)<0?f:A}function Zo(A,f){return Cn(A,f)<0?A:f}function Fa(A,f){return Math.max(A.first,Math.min(f,A.first+A.size-1))}function Or(A,f){if(f.line<A.first)return Ft(A.first,0);var x=A.first+A.size-1;return f.line>x?Ft(x,Wn(A,x).text.length):gi(f,Wn(A,f.line).text.length)}function gi(A,f){var x=A.ch;return x==null||x>f?Ft(A.line,f):x<0?Ft(A.line,0):A}function Ks(A,f){for(var x=[],b=0;b<f.length;b++)x[b]=Or(A,f[b]);return x}var ka=function(A,f){this.state=A,this.lookAhead=f},pa=function(A,f,x,b){this.state=f,this.doc=A,this.line=x,this.maxLookAhead=b||0,this.baseTokens=null,this.baseTokenPos=1};pa.prototype.lookAhead=function(A){var f=this.doc.getLine(this.line+A);return f!=null&&A>this.maxLookAhead&&(this.maxLookAhead=A),f},pa.prototype.baseToken=function(A){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=A;)this.baseTokenPos+=2;var f=this.baseTokens[this.baseTokenPos+1];return{type:f&&f.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-A}},pa.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},pa.fromSaved=function(A,f,x){return f instanceof ka?new pa(A,Ba(A.mode,f.state),x,f.lookAhead):new pa(A,Ba(A.mode,f),x)},pa.prototype.save=function(A){var f=A!==!1?Ba(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new ka(f,this.maxLookAhead):f};function Zl(A,f,x,b){var E=[A.state.modeGen],U={};Lu(A,f.text,A.doc.mode,x,function(ge,Qe){return E.push(ge,Qe)},U,b);for(var Y=x.state,te=function(ge){x.baseTokens=E;var Qe=A.state.overlays[ge],Je=1,Mt=0;x.state=!0,Lu(A,f.text,Qe.mode,x,function(yt,zt){for(var hn=Je;Mt<yt;){var kn=E[Je];kn>yt&&E.splice(Je,1,yt,E[Je+1],kn),Je+=2,Mt=Math.min(yt,kn)}if(zt)if(Qe.opaque)E.splice(hn,Je-hn,yt,"overlay "+zt),Je=hn+2;else for(;hn<Je;hn+=2){var Yn=E[hn+1];E[hn+1]=(Yn?Yn+" ":"")+"overlay "+zt}},U),x.state=Y,x.baseTokens=null,x.baseTokenPos=1},le=0;le<A.state.overlays.length;++le)te(le);return{styles:E,classes:U.bgClass||U.textClass?U:null}}function as(A,f,x){if(!f.styles||f.styles[0]!=A.state.modeGen){var b=ia(A,ve(f)),E=f.text.length>A.options.maxHighlightLength&&Ba(A.doc.mode,b.state),U=Zl(A,f,b);E&&(b.state=E),f.stateAfter=b.save(!E),f.styles=U.styles,U.classes?f.styleClasses=U.classes:f.styleClasses&&(f.styleClasses=null),x===A.doc.highlightFrontier&&(A.doc.modeFrontier=Math.max(A.doc.modeFrontier,++A.doc.highlightFrontier))}return f.styles}function ia(A,f,x){var b=A.doc,E=A.display;if(!b.mode.startState)return new pa(b,!0,f);var U=mu(A,f,x),Y=U>b.first&&Wn(b,U-1).stateAfter,te=Y?pa.fromSaved(b,Y,U):new pa(b,os(b.mode),U);return b.iter(U,f,function(le){qo(A,le.text,te);var ge=te.line;le.stateAfter=ge==f-1||ge%5==0||ge>=E.viewFrom&&ge<E.viewTo?te.save():null,te.nextLine()}),x&&(b.modeFrontier=te.line),te}function qo(A,f,x,b){var E=A.doc.mode,U=new hi(f,A.options.tabSize,x);for(U.start=U.pos=b||0,f==""&&vs(E,x.state);!U.eol();)Fu(E,U,x.state),U.start=U.pos}function vs(A,f){if(A.blankLine)return A.blankLine(f);if(A.innerMode){var x=bi(A,f);if(x.mode.blankLine)return x.mode.blankLine(x.state)}}function Fu(A,f,x,b){for(var E=0;E<10;E++){b&&(b[0]=bi(A,x).mode);var U=A.token(f,x);if(f.pos>f.start)return U}throw new Error("Mode "+A.name+" failed to advance stream.")}var ma=function(A,f,x){this.start=A.start,this.end=A.pos,this.string=A.current(),this.type=f||null,this.state=x};function lA(A,f,x,b){var E=A.doc,U=E.mode,Y;f=Or(E,f);var te=Wn(E,f.line),le=ia(A,f.line,x),ge=new hi(te.text,A.options.tabSize,le),Qe;for(b&&(Qe=[]);(b||ge.pos<f.ch)&&!ge.eol();)ge.start=ge.pos,Y=Fu(U,ge,le.state),b&&Qe.push(new ma(ge,Y,Ba(E.mode,le.state)));return b?Qe:new ma(ge,Y,le.state)}function Du(A,f){if(A)for(;;){var x=A.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!x)break;A=A.slice(0,x.index)+A.slice(x.index+x[0].length);var b=x[1]?"bgClass":"textClass";f[b]==null?f[b]=x[2]:new RegExp("(?:^|\\s)"+x[2]+"(?:$|\\s)").test(f[b])||(f[b]+=" "+x[2])}return A}function Lu(A,f,x,b,E,U,Y){var te=x.flattenSpans;te==null&&(te=A.options.flattenSpans);var le=0,ge=null,Qe=new hi(f,A.options.tabSize,b),Je,Mt=A.options.addModeClass&&[null];for(f==""&&Du(vs(x,b.state),U);!Qe.eol();){if(Qe.pos>A.options.maxHighlightLength?(te=!1,Y&&qo(A,f,b,Qe.pos),Qe.pos=f.length,Je=null):Je=Du(Fu(x,Qe,b.state,Mt),U),Mt){var yt=Mt[0].name;yt&&(Je="m-"+(Je?yt+" "+Je:yt))}if(!te||ge!=Je){for(;le<Qe.start;)le=Math.min(Qe.start,le+5e3),E(le,ge);ge=Je}Qe.start=Qe.pos}for(;le<Qe.pos;){var zt=Math.min(Qe.pos,le+5e3);E(zt,ge),le=zt}}function mu(A,f,x){for(var b,E,U=A.doc,Y=x?-1:f-(A.doc.mode.innerMode?1e3:100),te=f;te>Y;--te){if(te<=U.first)return U.first;var le=Wn(U,te-1),ge=le.stateAfter;if(ge&&(!x||te+(ge instanceof ka?ge.lookAhead:0)<=U.modeFrontier))return te;var Qe=fe(le.text,null,A.options.tabSize);(E==null||b>Qe)&&(E=te-1,b=Qe)}return E}function uA(A,f){if(A.modeFrontier=Math.min(A.modeFrontier,f),!(A.highlightFrontier<f-10)){for(var x=A.first,b=f-1;b>x;b--){var E=Wn(A,b).stateAfter;if(E&&(!(E instanceof ka)||b+E.lookAhead<f)){x=b+1;break}}A.highlightFrontier=Math.min(A.highlightFrontier,x)}}var Wo=!1,Na=!1;function Uu(){Wo=!0}function ss(){Na=!0}function ll(A,f,x){this.marker=A,this.from=f,this.to=x}function Do(A,f){if(A)for(var x=0;x<A.length;++x){var b=A[x];if(b.marker==f)return b}}function gu(A,f){for(var x,b=0;b<A.length;++b)A[b]!=f&&(x||(x=[])).push(A[b]);return x}function vl(A,f,x){var b=x&&window.WeakSet&&(x.markedSpans||(x.markedSpans=new WeakSet));b&&A.markedSpans&&b.has(A.markedSpans)?A.markedSpans.push(f):(A.markedSpans=A.markedSpans?A.markedSpans.concat([f]):[f],b&&b.add(A.markedSpans)),f.marker.attachLine(A)}function _l(A,f,x){var b;if(A)for(var E=0;E<A.length;++E){var U=A[E],Y=U.marker,te=U.from==null||(Y.inclusiveLeft?U.from<=f:U.from<f);if(te||U.from==f&&Y.type=="bookmark"&&(!x||!U.marker.insertLeft)){var le=U.to==null||(Y.inclusiveRight?U.to>=f:U.to>f);(b||(b=[])).push(new ll(Y,U.from,le?null:U.to))}}return b}function Dl(A,f,x){var b;if(A)for(var E=0;E<A.length;++E){var U=A[E],Y=U.marker,te=U.to==null||(Y.inclusiveRight?U.to>=f:U.to>f);if(te||U.from==f&&Y.type=="bookmark"&&(!x||U.marker.insertLeft)){var le=U.from==null||(Y.inclusiveLeft?U.from<=f:U.from<f);(b||(b=[])).push(new ll(Y,le?null:U.from-f,U.to==null?null:U.to-f))}}return b}function oa(A,f){if(f.full)return null;var x=Jt(A,f.from.line)&&Wn(A,f.from.line).markedSpans,b=Jt(A,f.to.line)&&Wn(A,f.to.line).markedSpans;if(!x&&!b)return null;var E=f.from.ch,U=f.to.ch,Y=Cn(f.from,f.to)==0,te=_l(x,E,Y),le=Dl(b,U,Y),ge=f.text.length==1,Qe=vn(f.text).length+(ge?E:0);if(te)for(var Je=0;Je<te.length;++Je){var Mt=te[Je];if(Mt.to==null){var yt=Do(le,Mt.marker);yt?ge&&(Mt.to=yt.to==null?null:yt.to+Qe):Mt.to=E}}if(le)for(var zt=0;zt<le.length;++zt){var hn=le[zt];if(hn.to!=null&&(hn.to+=Qe),hn.from==null){var kn=Do(te,hn.marker);kn||(hn.from=Qe,ge&&(te||(te=[])).push(hn))}else hn.from+=Qe,ge&&(te||(te=[])).push(hn)}te&&(te=Cl(te)),le&&le!=te&&(le=Cl(le));var Yn=[te];if(!ge){var xn=f.text.length-2,Ln;if(xn>0&&te)for(var sr=0;sr<te.length;++sr)te[sr].to==null&&(Ln||(Ln=[])).push(new ll(te[sr].marker,null,null));for(var Kr=0;Kr<xn;++Kr)Yn.push(Ln);Yn.push(le)}return Yn}function Cl(A){for(var f=0;f<A.length;++f){var x=A[f];x.from!=null&&x.from==x.to&&x.marker.clearWhenEmpty!==!1&&A.splice(f--,1)}return A.length?A:null}function AA(A,f,x){var b=null;if(A.iter(f.line,x.line+1,function(yt){if(yt.markedSpans)for(var zt=0;zt<yt.markedSpans.length;++zt){var hn=yt.markedSpans[zt].marker;hn.readOnly&&(!b||Ue(b,hn)==-1)&&(b||(b=[])).push(hn)}}),!b)return null;for(var E=[{from:f,to:x}],U=0;U<b.length;++U)for(var Y=b[U],te=Y.find(0),le=0;le<E.length;++le){var ge=E[le];if(!(Cn(ge.to,te.from)<0||Cn(ge.from,te.to)>0)){var Qe=[le,1],Je=Cn(ge.from,te.from),Mt=Cn(ge.to,te.to);(Je<0||!Y.inclusiveLeft&&!Je)&&Qe.push({from:ge.from,to:te.from}),(Mt>0||!Y.inclusiveRight&&!Mt)&&Qe.push({from:te.to,to:ge.to}),E.splice.apply(E,Qe),le+=Qe.length-3}}return E}function go(A){var f=A.markedSpans;if(f){for(var x=0;x<f.length;++x)f[x].marker.detachLine(A);A.markedSpans=null}}function oo(A,f){if(f){for(var x=0;x<f.length;++x)f[x].marker.attachLine(A);A.markedSpans=f}}function R(A){return A.inclusiveLeft?-1:0}function se(A){return A.inclusiveRight?1:0}function Le(A,f){var x=A.lines.length-f.lines.length;if(x!=0)return x;var b=A.find(),E=f.find(),U=Cn(b.from,E.from)||R(A)-R(f);if(U)return-U;var Y=Cn(b.to,E.to)||se(A)-se(f);return Y||f.id-A.id}function mt(A,f){var x=Na&&A.markedSpans,b;if(x)for(var E=void 0,U=0;U<x.length;++U)E=x[U],E.marker.collapsed&&(f?E.from:E.to)==null&&(!b||Le(b,E.marker)<0)&&(b=E.marker);return b}function Dn(A){return mt(A,!0)}function en(A){return mt(A,!1)}function Sr(A,f){var x=Na&&A.markedSpans,b;if(x)for(var E=0;E<x.length;++E){var U=x[E];U.marker.collapsed&&(U.from==null||U.from<f)&&(U.to==null||U.to>f)&&(!b||Le(b,U.marker)<0)&&(b=U.marker)}return b}function Ur(A,f,x,b,E){var U=Wn(A,f),Y=Na&&U.markedSpans;if(Y)for(var te=0;te<Y.length;++te){var le=Y[te];if(le.marker.collapsed){var ge=le.marker.find(0),Qe=Cn(ge.from,x)||R(le.marker)-R(E),Je=Cn(ge.to,b)||se(le.marker)-se(E);if(!(Qe>=0&&Je<=0||Qe<=0&&Je>=0)&&(Qe<=0&&(le.marker.inclusiveRight&&E.inclusiveLeft?Cn(ge.to,x)>=0:Cn(ge.to,x)>0)||Qe>=0&&(le.marker.inclusiveRight&&E.inclusiveLeft?Cn(ge.from,b)<=0:Cn(ge.from,b)<0)))return!0}}}function yr(A){for(var f;f=Dn(A);)A=f.find(-1,!0).line;return A}function Ir(A){for(var f;f=en(A);)A=f.find(1,!0).line;return A}function Bi(A){for(var f,x;f=en(A);)A=f.find(1,!0).line,(x||(x=[])).push(A);return x}function fo(A,f){var x=Wn(A,f),b=yr(x);return x==b?f:ve(b)}function xi(A,f){if(f>A.lastLine())return f;var x=Wn(A,f),b;if(!Hr(A,x))return f;for(;b=en(x);)x=b.find(1,!0).line;return ve(x)+1}function Hr(A,f){var x=Na&&f.markedSpans;if(x){for(var b=void 0,E=0;E<x.length;++E)if(b=x[E],!!b.marker.collapsed){if(b.from==null)return!0;if(!b.marker.widgetNode&&b.from==0&&b.marker.inclusiveLeft&&Hi(A,f,b))return!0}}}function Hi(A,f,x){if(x.to==null){var b=x.marker.find(1,!0);return Hi(A,b.line,Do(b.line.markedSpans,x.marker))}if(x.marker.inclusiveRight&&x.to==f.text.length)return!0;for(var E=void 0,U=0;U<f.markedSpans.length;++U)if(E=f.markedSpans[U],E.marker.collapsed&&!E.marker.widgetNode&&E.from==x.to&&(E.to==null||E.to!=x.from)&&(E.marker.inclusiveLeft||x.marker.inclusiveRight)&&Hi(A,f,E))return!0}function Io(A){A=yr(A);for(var f=0,x=A.parent,b=0;b<x.lines.length;++b){var E=x.lines[b];if(E==A)break;f+=E.height}for(var U=x.parent;U;x=U,U=x.parent)for(var Y=0;Y<U.children.length;++Y){var te=U.children[Y];if(te==x)break;f+=te.height}return f}function wo(A){if(A.height==0)return 0;for(var f=A.text.length,x,b=A;x=Dn(b);){var E=x.find(0,!0);b=E.from.line,f+=E.from.ch-E.to.ch}for(b=A;x=en(b);){var U=x.find(0,!0);f-=b.text.length-U.from.ch,b=U.to.line,f+=b.text.length-U.to.ch}return f}function Ga(A){var f=A.display,x=A.doc;f.maxLine=Wn(x,x.first),f.maxLineLength=wo(f.maxLine),f.maxLineChanged=!0,x.iter(function(b){var E=wo(b);E>f.maxLineLength&&(f.maxLineLength=E,f.maxLine=b)})}var Ll=function(A,f,x){this.text=A,oo(this,f),this.height=x?x(this):1};Ll.prototype.lineNo=function(){return ve(this)},ze(Ll);function Xl(A,f,x,b){A.text=f,A.stateAfter&&(A.stateAfter=null),A.styles&&(A.styles=null),A.order!=null&&(A.order=null),go(A),oo(A,x);var E=b?b(A):1;E!=A.height&&qi(A,E)}function ga(A){A.parent=null,go(A)}var qm={},Jl={};function mh(A,f){if(!A||/^\s*$/.test(A))return null;var x=f.addModeClass?Jl:qm;return x[A]||(x[A]=A.replace(/\S+/g,"cm-$&"))}function Wc(A,f){var x=Bt("span",null,null,C?"padding-right: .1px":null),b={pre:Bt("pre",[x],"CodeMirror-line"),content:x,col:0,pos:0,cm:A,trailingSpace:!1,splitSpaces:A.getOption("lineWrapping")};f.measure={};for(var E=0;E<=(f.rest?f.rest.length:0);E++){var U=E?f.rest[E-1]:f.line,Y=void 0;b.pos=0,b.addToken=Nc,or(A.display.measure)&&(Y=En(U,A.doc.direction))&&(b.addToken=Xo(b.addToken,Y)),b.map=[];var te=f!=A.display.externalMeasured&&ve(U);Od(U,b,as(A,U,te)),U.styleClasses&&(U.styleClasses.bgClass&&(b.bgClass=rt(U.styleClasses.bgClass,b.bgClass||"")),U.styleClasses.textClass&&(b.textClass=rt(U.styleClasses.textClass,b.textClass||""))),b.map.length==0&&b.map.push(0,0,b.content.appendChild(Qn(A.display.measure))),E==0?(f.measure.map=b.map,f.measure.cache={}):((f.measure.maps||(f.measure.maps=[])).push(b.map),(f.measure.caches||(f.measure.caches=[])).push({}))}if(C){var le=b.content.lastChild;(/\bcm-tab\b/.test(le.className)||le.querySelector&&le.querySelector(".cm-tab"))&&(b.content.className="cm-tab-wrap-hack")}return Fe(A,"renderLine",A,f.line,b.pre),b.pre.className&&(b.textClass=rt(b.pre.className,b.textClass||"")),b}function Ru(A){var f=be("span","•","cm-invalidchar");return f.title="\\u"+A.charCodeAt(0).toString(16),f.setAttribute("aria-label",f.title),f}function Nc(A,f,x,b,E,U,Y){if(f){var te=A.splitSpaces?IA(f,A.trailingSpace):f,le=A.cm.state.specialChars,ge=!1,Qe;if(!le.test(f))A.col+=f.length,Qe=document.createTextNode(te),A.map.push(A.pos,A.pos+f.length,Qe),h&&g<9&&(ge=!0),A.pos+=f.length;else{Qe=document.createDocumentFragment();for(var Je=0;;){le.lastIndex=Je;var Mt=le.exec(f),yt=Mt?Mt.index-Je:f.length-Je;if(yt){var zt=document.createTextNode(te.slice(Je,Je+yt));h&&g<9?Qe.appendChild(be("span",[zt])):Qe.appendChild(zt),A.map.push(A.pos,A.pos+yt,zt),A.col+=yt,A.pos+=yt}if(!Mt)break;Je+=yt+1;var hn=void 0;if(Mt[0]==" "){var kn=A.cm.options.tabSize,Yn=kn-A.col%kn;hn=Qe.appendChild(be("span",mn(Yn),"cm-tab")),hn.setAttribute("role","presentation"),hn.setAttribute("cm-text"," "),A.col+=Yn}else Mt[0]=="\r"||Mt[0]==`
`?(hn=Qe.appendChild(be("span",Mt[0]=="\r"?"␍":"␤","cm-invalidchar")),hn.setAttribute("cm-text",Mt[0]),A.col+=1):(hn=A.cm.options.specialCharPlaceholder(Mt[0]),hn.setAttribute("cm-text",Mt[0]),h&&g<9?Qe.appendChild(be("span",[hn])):Qe.appendChild(hn),A.col+=1);A.map.push(A.pos,A.pos+1,hn),A.pos++}}if(A.trailingSpace=te.charCodeAt(f.length-1)==32,x||b||E||ge||U||Y){var xn=x||"";b&&(xn+=b),E&&(xn+=E);var Ln=be("span",[Qe],xn,U);if(Y)for(var sr in Y)Y.hasOwnProperty(sr)&&sr!="style"&&sr!="class"&&Ln.setAttribute(sr,Y[sr]);return A.content.appendChild(Ln)}A.content.appendChild(Qe)}}function IA(A,f){if(A.length>1&&!/ /.test(A))return A;for(var x=f,b="",E=0;E<A.length;E++){var U=A.charAt(E);U==" "&&x&&(E==A.length-1||A.charCodeAt(E+1)==32)&&(U=" "),b+=U,x=U==" "}return b}function Xo(A,f){return function(x,b,E,U,Y,te,le){E=E?E+" cm-force-border":"cm-force-border";for(var ge=x.pos,Qe=ge+b.length;;){for(var Je=void 0,Mt=0;Mt<f.length&&(Je=f[Mt],!(Je.to>ge&&Je.from<=ge));Mt++);if(Je.to>=Qe)return A(x,b,E,U,Y,te,le);A(x,b.slice(0,Je.to-ge),E,U,null,te,le),U=null,b=b.slice(Je.to-ge),ge=Je.to}}}function zu(A,f,x,b){var E=!b&&x.widgetNode;E&&A.map.push(A.pos,A.pos+f,E),!b&&A.cm.display.input.needsContentAttribute&&(E||(E=A.content.appendChild(document.createElement("span"))),E.setAttribute("cm-marker",x.id)),E&&(A.cm.display.input.setUneditable(E),A.content.appendChild(E)),A.pos+=f,A.trailingSpace=!1}function Od(A,f,x){var b=A.markedSpans,E=A.text,U=0;if(!b){for(var Y=1;Y<x.length;Y+=2)f.addToken(f,E.slice(U,U=x[Y]),mh(x[Y+1],f.cm.options));return}for(var te=E.length,le=0,ge=1,Qe="",Je,Mt,yt=0,zt,hn,kn,Yn,xn;;){if(yt==le){zt=hn=kn=Mt="",xn=null,Yn=null,yt=1/0;for(var Ln=[],sr=void 0,Kr=0;Kr<b.length;++Kr){var _r=b[Kr],Ai=_r.marker;if(Ai.type=="bookmark"&&_r.from==le&&Ai.widgetNode)Ln.push(Ai);else if(_r.from<=le&&(_r.to==null||_r.to>le||Ai.collapsed&&_r.to==le&&_r.from==le)){if(_r.to!=null&&_r.to!=le&&yt>_r.to&&(yt=_r.to,hn=""),Ai.className&&(zt+=" "+Ai.className),Ai.css&&(Mt=(Mt?Mt+";":"")+Ai.css),Ai.startStyle&&_r.from==le&&(kn+=" "+Ai.startStyle),Ai.endStyle&&_r.to==yt&&(sr||(sr=[])).push(Ai.endStyle,_r.to),Ai.title&&((xn||(xn={})).title=Ai.title),Ai.attributes)for(var Uo in Ai.attributes)(xn||(xn={}))[Uo]=Ai.attributes[Uo];Ai.collapsed&&(!Yn||Le(Yn.marker,Ai)<0)&&(Yn=_r)}else _r.from>le&&yt>_r.from&&(yt=_r.from)}if(sr)for(var qa=0;qa<sr.length;qa+=2)sr[qa+1]==yt&&(hn+=" "+sr[qa]);if(!Yn||Yn.from==le)for(var ba=0;ba<Ln.length;++ba)zu(f,0,Ln[ba]);if(Yn&&(Yn.from||0)==le){if(zu(f,(Yn.to==null?te+1:Yn.to)-le,Yn.marker,Yn.from==null),Yn.to==null)return;Yn.to==le&&(Yn=!1)}}if(le>=te)break;for(var Ua=Math.min(te,yt);;){if(Qe){var us=le+Qe.length;if(!Yn){var As=us>Ua?Qe.slice(0,Ua-le):Qe;f.addToken(f,As,Je?Je+zt:zt,kn,le+As.length==yt?hn:"",Mt,xn)}if(us>=Ua){Qe=Qe.slice(Ua-le),le=Ua;break}le=us,kn=""}Qe=E.slice(U,U=x[ge++]),Je=mh(x[ge++],f.cm.options)}}}function TA(A,f,x){this.line=f,this.rest=Bi(f),this.size=this.rest?ve(vn(this.rest))-x+1:1,this.node=this.text=null,this.hidden=Hr(A,f)}function lc(A,f,x){for(var b=[],E,U=f;U<x;U=E){var Y=new TA(A.doc,Wn(A.doc,U),U);E=U+Y.size,b.push(Y)}return b}var yu=null;function Gc(A){yu?yu.ops.push(A):A.ownsGroup=yu={ops:[A],delayedCallbacks:[]}}function kp(A){var f=A.delayedCallbacks,x=0;do{for(;x<f.length;x++)f[x].call(null);for(var b=0;b<A.ops.length;b++){var E=A.ops[b];if(E.cursorActivityHandlers)for(;E.cursorActivityCalled<E.cursorActivityHandlers.length;)E.cursorActivityHandlers[E.cursorActivityCalled++].call(null,E.cm)}}while(x<f.length)}function gh(A,f){var x=A.ownsGroup;if(x)try{kp(x)}finally{yu=null,f(x)}}var wi=null;function No(A,f){var x=Dr(A,f);if(x.length){var b=Array.prototype.slice.call(arguments,2),E;yu?E=yu.delayedCallbacks:wi?E=wi:(E=wi=[],setTimeout(Hm,0));for(var U=function(te){E.push(function(){return x[te].apply(null,b)})},Y=0;Y<x.length;++Y)U(Y)}}function Hm(){var A=wi;wi=null;for(var f=0;f<A.length;++f)A[f]()}function yh(A,f,x,b){for(var E=0;E<f.changes.length;E++){var U=f.changes[E];U=="text"?Li(A,f):U=="gutter"?To(A,f,x,b):U=="class"?Bd(A,f):U=="widget"&&Mo(A,f,b)}f.changes=null}function ju(A){return A.node==A.text&&(A.node=be("div",null,null,"position: relative"),A.text.parentNode&&A.text.parentNode.replaceChild(A.node,A.text),A.node.appendChild(A.text),h&&g<8&&(A.node.style.zIndex=2)),A.node}function ya(A,f){var x=f.bgClass?f.bgClass+" "+(f.line.bgClass||""):f.line.bgClass;if(x&&(x+=" CodeMirror-linebackground"),f.background)x?f.background.className=x:(f.background.parentNode.removeChild(f.background),f.background=null);else if(x){var b=ju(f);f.background=b.insertBefore(be("div",null,x),b.firstChild),A.display.input.setUneditable(f.background)}}function vh(A,f){var x=A.display.externalMeasured;return x&&x.line==f.line?(A.display.externalMeasured=null,f.measure=x.measure,x.built):Wc(A,f)}function Li(A,f){var x=f.text.className,b=vh(A,f);f.text==f.node&&(f.node=b.pre),f.text.parentNode.replaceChild(b.pre,f.text),f.text=b.pre,b.bgClass!=f.bgClass||b.textClass!=f.textClass?(f.bgClass=b.bgClass,f.textClass=b.textClass,Bd(A,f)):x&&(f.text.className=x)}function Bd(A,f){ya(A,f),f.line.wrapClass?ju(f).className=f.line.wrapClass:f.node!=f.text&&(f.node.className="");var x=f.textClass?f.textClass+" "+(f.line.textClass||""):f.line.textClass;f.text.className=x||""}function To(A,f,x,b){if(f.gutter&&(f.node.removeChild(f.gutter),f.gutter=null),f.gutterBackground&&(f.node.removeChild(f.gutterBackground),f.gutterBackground=null),f.line.gutterClass){var E=ju(f);f.gutterBackground=be("div",null,"CodeMirror-gutter-background "+f.line.gutterClass,"left: "+(A.options.fixedGutter?b.fixedPos:-b.gutterTotalWidth)+"px; width: "+b.gutterTotalWidth+"px"),A.display.input.setUneditable(f.gutterBackground),E.insertBefore(f.gutterBackground,f.text)}var U=f.line.gutterMarkers;if(A.options.lineNumbers||U){var Y=ju(f),te=f.gutter=be("div",null,"CodeMirror-gutter-wrapper","left: "+(A.options.fixedGutter?b.fixedPos:-b.gutterTotalWidth)+"px");if(te.setAttribute("aria-hidden","true"),A.display.input.setUneditable(te),Y.insertBefore(te,f.text),f.line.gutterClass&&(te.className+=" "+f.line.gutterClass),A.options.lineNumbers&&(!U||!U["CodeMirror-linenumbers"])&&(f.lineNumber=te.appendChild(be("div",sn(A.options,x),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+b.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+A.display.lineNumInnerWidth+"px"))),U)for(var le=0;le<A.display.gutterSpecs.length;++le){var ge=A.display.gutterSpecs[le].className,Qe=U.hasOwnProperty(ge)&&U[ge];Qe&&te.appendChild(be("div",[Qe],"CodeMirror-gutter-elt","left: "+b.gutterLeft[ge]+"px; width: "+b.gutterWidth[ge]+"px"))}}}function Mo(A,f,x){f.alignable&&(f.alignable=null);for(var b=De("CodeMirror-linewidget"),E=f.node.firstChild,U=void 0;E;E=U)U=E.nextSibling,b.test(E.className)&&f.node.removeChild(E);Qc(A,f,x)}function uc(A,f,x,b){var E=vh(A,f);return f.text=f.node=E.pre,E.bgClass&&(f.bgClass=E.bgClass),E.textClass&&(f.textClass=E.textClass),Bd(A,f),To(A,f,x,b),Qc(A,f,b),f.node}function Qc(A,f,x){if(Hs(A,f.line,f,x,!0),f.rest)for(var b=0;b<f.rest.length;b++)Hs(A,f.rest[b],f,x,!1)}function Hs(A,f,x,b,E){if(f.widgets)for(var U=ju(x),Y=0,te=f.widgets;Y<te.length;++Y){var le=te[Y],ge=be("div",[le.node],"CodeMirror-linewidget"+(le.className?" "+le.className:""));le.handleMouseEvents||ge.setAttribute("cm-ignore-events","true"),_h(le,ge,x,b),A.display.input.setUneditable(ge),E&&le.above?U.insertBefore(ge,x.gutter||x.text):U.appendChild(ge),No(le,"redraw")}}function _h(A,f,x,b){if(A.noHScroll){(x.alignable||(x.alignable=[])).push(f);var E=b.wrapperWidth;f.style.left=b.fixedPos+"px",A.coverGutter||(E-=b.gutterTotalWidth,f.style.paddingLeft=b.gutterTotalWidth+"px"),f.style.width=E+"px"}A.coverGutter&&(f.style.zIndex=5,f.style.position="relative",A.noHScroll||(f.style.marginLeft=-b.gutterTotalWidth+"px"))}function eu(A){if(A.height!=null)return A.height;var f=A.doc.cm;if(!f)return 0;if(!Yt(document.body,A.node)){var x="position: relative;";A.coverGutter&&(x+="margin-left: -"+f.display.gutters.offsetWidth+"px;"),A.noHScroll&&(x+="width: "+f.display.wrapper.clientWidth+"px;"),nt(f.display.measure,be("div",[A.node],null,x))}return A.height=A.node.parentNode.offsetHeight}function Ul(A,f){for(var x=xt(f);x!=A.wrapper;x=x.parentNode)if(!x||x.nodeType==1&&x.getAttribute("cm-ignore-events")=="true"||x.parentNode==A.sizer&&x!=A.mover)return!0}function KA(A){return A.lineSpace.offsetTop}function Ch(A){return A.mover.offsetHeight-A.lineSpace.offsetHeight}function kd(A){if(A.cachedPaddingH)return A.cachedPaddingH;var f=nt(A.measure,be("pre","x","CodeMirror-line-like")),x=window.getComputedStyle?window.getComputedStyle(f):f.currentStyle,b={left:parseInt(x.paddingLeft),right:parseInt(x.paddingRight)};return!isNaN(b.left)&&!isNaN(b.right)&&(A.cachedPaddingH=b),b}function vu(A){return et-A.display.nativeBarWidth}function Wu(A){return A.display.scroller.clientWidth-vu(A)-A.display.barWidth}function $c(A){return A.display.scroller.clientHeight-vu(A)-A.display.barHeight}function PA(A,f,x){var b=A.options.lineWrapping,E=b&&Wu(A);if(!f.measure.heights||b&&f.measure.width!=E){var U=f.measure.heights=[];if(b){f.measure.width=E;for(var Y=f.text.firstChild.getClientRects(),te=0;te<Y.length-1;te++){var le=Y[te],ge=Y[te+1];Math.abs(le.bottom-ge.bottom)>2&&U.push((le.bottom+ge.top)/2-x.top)}}U.push(x.bottom-x.top)}}function kf(A,f,x){if(A.line==f)return{map:A.measure.map,cache:A.measure.cache};if(A.rest){for(var b=0;b<A.rest.length;b++)if(A.rest[b]==f)return{map:A.measure.maps[b],cache:A.measure.caches[b]};for(var E=0;E<A.rest.length;E++)if(ve(A.rest[E])>x)return{map:A.measure.maps[E],cache:A.measure.caches[E],before:!0}}}function Ip(A,f){f=yr(f);var x=ve(f),b=A.display.externalMeasured=new TA(A.doc,f,x);b.lineN=x;var E=b.built=Wc(A,b);return b.text=E.pre,nt(A.display.lineMeasure,E.pre),b}function Ac(A,f,x,b){return bl(A,Rl(A,f),x,b)}function Yc(A,f){if(f>=A.display.viewFrom&&f<A.display.viewTo)return A.display.view[DA(A,f)];var x=A.display.externalMeasured;if(x&&f>=x.lineN&&f<x.lineN+x.size)return x}function Rl(A,f){var x=ve(f),b=Yc(A,x);b&&!b.text?b=null:b&&b.changes&&(yh(A,b,x,Fs(A)),A.curOp.forceUpdate=!0),b||(b=Ip(A,f));var E=kf(b,f,x);return{line:f,view:b,rect:null,map:E.map,cache:E.cache,before:E.before,hasHeights:!1}}function bl(A,f,x,b,E){f.before&&(x=-1);var U=x+(b||""),Y;return f.cache.hasOwnProperty(U)?Y=f.cache[U]:(f.rect||(f.rect=f.view.text.getBoundingClientRect()),f.hasHeights||(PA(A,f.view,f.rect),f.hasHeights=!0),Y=FA(A,f,x,b),Y.bogus||(f.cache[U]=Y)),{left:Y.left,right:Y.right,top:E?Y.rtop:Y.top,bottom:E?Y.rbottom:Y.bottom}}var aa={left:0,right:0,top:0,bottom:0};function cA(A,f,x){for(var b,E,U,Y,te,le,ge=0;ge<A.length;ge+=3)if(te=A[ge],le=A[ge+1],f<te?(E=0,U=1,Y="left"):f<le?(E=f-te,U=E+1):(ge==A.length-3||f==le&&A[ge+3]>f)&&(U=le-te,E=U-1,f>=le&&(Y="right")),E!=null){if(b=A[ge+2],te==le&&x==(b.insertLeft?"left":"right")&&(Y=x),x=="left"&&E==0)for(;ge&&A[ge-2]==A[ge-3]&&A[ge-1].insertLeft;)b=A[(ge-=3)+2],Y="left";if(x=="right"&&E==le-te)for(;ge<A.length-3&&A[ge+3]==A[ge+4]&&!A[ge+5].insertLeft;)b=A[(ge+=3)+2],Y="right";break}return{node:b,start:E,end:U,collapse:Y,coverStart:te,coverEnd:le}}function ul(A,f){var x=aa;if(f=="left")for(var b=0;b<A.length&&(x=A[b]).left==x.right;b++);else for(var E=A.length-1;E>=0&&(x=A[E]).left==x.right;E--);return x}function FA(A,f,x,b){var E=cA(f.map,x,b),U=E.node,Y=E.start,te=E.end,le=E.collapse,ge;if(U.nodeType==3){for(var Qe=0;Qe<4;Qe++){for(;Y&&Te(f.line.text.charAt(E.coverStart+Y));)--Y;for(;E.coverStart+te<E.coverEnd&&Te(f.line.text.charAt(E.coverStart+te));)++te;if(h&&g<9&&Y==0&&te==E.coverEnd-E.coverStart?ge=U.parentNode.getBoundingClientRect():ge=ul(kt(U,Y,te).getClientRects(),b),ge.left||ge.right||Y==0)break;te=Y,Y=Y-1,le="right"}h&&g<11&&(ge=xl(A.display.measure,ge))}else{Y>0&&(le=b="right");var Je;A.options.lineWrapping&&(Je=U.getClientRects()).length>1?ge=Je[b=="right"?Je.length-1:0]:ge=U.getBoundingClientRect()}if(h&&g<9&&!Y&&(!ge||!ge.left&&!ge.right)){var Mt=U.parentNode.getClientRects()[0];Mt?ge={left:Mt.left,right:Mt.left+Cu(A.display),top:Mt.top,bottom:Mt.bottom}:ge=aa}for(var yt=ge.top-f.rect.top,zt=ge.bottom-f.rect.top,hn=(yt+zt)/2,kn=f.view.measure.heights,Yn=0;Yn<kn.length-1&&!(hn<kn[Yn]);Yn++);var xn=Yn?kn[Yn-1]:0,Ln=kn[Yn],sr={left:(le=="right"?ge.right:ge.left)-f.rect.left,right:(le=="left"?ge.left:ge.right)-f.rect.left,top:xn,bottom:Ln};return!ge.left&&!ge.right&&(sr.bogus=!0),A.options.singleCursorHeightPerLine||(sr.rtop=yt,sr.rbottom=zt),sr}function xl(A,f){if(!window.screen||screen.logicalXDPI==null||screen.logicalXDPI==screen.deviceXDPI||!Wr(A))return f;var x=screen.logicalXDPI/screen.deviceXDPI,b=screen.logicalYDPI/screen.deviceYDPI;return{left:f.left*x,right:f.right*x,top:f.top*b,bottom:f.bottom*b}}function bh(A){if(A.measure&&(A.measure.cache={},A.measure.heights=null,A.rest))for(var f=0;f<A.rest.length;f++)A.measure.caches[f]={}}function dA(A){A.display.externalMeasure=null,ke(A.display.lineMeasure);for(var f=0;f<A.display.view.length;f++)bh(A.display.view[f])}function tu(A){dA(A),A.display.cachedCharWidth=A.display.cachedTextHeight=A.display.cachedPaddingH=null,A.options.lineWrapping||(A.display.maxLineChanged=!0),A.display.lineNumChars=null}function cc(A){return k&&oe?-(A.body.getBoundingClientRect().left-parseInt(getComputedStyle(A.body).marginLeft)):A.defaultView.pageXOffset||(A.documentElement||A.body).scrollLeft}function Id(A){return k&&oe?-(A.body.getBoundingClientRect().top-parseInt(getComputedStyle(A.body).marginTop)):A.defaultView.pageYOffset||(A.documentElement||A.body).scrollTop}function Td(A){var f=yr(A),x=f.widgets,b=0;if(x)for(var E=0;E<x.length;++E)x[E].above&&(b+=eu(x[E]));return b}function _u(A,f,x,b,E){if(!E){var U=Td(f);x.top+=U,x.bottom+=U}if(b=="line")return x;b||(b="local");var Y=Io(f);if(b=="local"?Y+=KA(A.display):Y-=A.display.viewOffset,b=="page"||b=="window"){var te=A.display.lineSpace.getBoundingClientRect();Y+=te.top+(b=="window"?0:Id(on(A)));var le=te.left+(b=="window"?0:cc(on(A)));x.left+=le,x.right+=le}return x.top+=Y,x.bottom+=Y,x}function wt(A,f,x){if(x=="div")return f;var b=f.left,E=f.top;if(x=="page")b-=cc(on(A)),E-=Id(on(A));else if(x=="local"||!x){var U=A.display.sizer.getBoundingClientRect();b+=U.left,E+=U.top}var Y=A.display.lineSpace.getBoundingClientRect();return{left:b-Y.left,top:E-Y.top}}function ln(A,f,x,b,E){return b||(b=Wn(A.doc,f.line)),_u(A,b,Ac(A,b,f.ch,E),x)}function Wt(A,f,x,b,E,U){b=b||Wn(A.doc,f.line),E||(E=Rl(A,b));function Y(zt,hn){var kn=bl(A,E,zt,hn?"right":"left",U);return hn?kn.left=kn.right:kn.right=kn.left,_u(A,b,kn,x)}var te=En(b,A.doc.direction),le=f.ch,ge=f.sticky;if(le>=b.text.length?(le=b.text.length,ge="before"):le<=0&&(le=0,ge="after"),!te)return Y(ge=="before"?le-1:le,ge=="before");function Qe(zt,hn,kn){var Yn=te[hn],xn=Yn.level==1;return Y(kn?zt-1:zt,xn!=kn)}var Je=pn(te,le,ge),Mt=Nt,yt=Qe(le,Je,ge=="before");return Mt!=null&&(yt.other=Qe(le,Mt,ge!="before")),yt}function hr(A,f){var x=0;f=Or(A.doc,f),A.options.lineWrapping||(x=Cu(A.display)*f.ch);var b=Wn(A.doc,f.line),E=Io(b)+KA(A.display);return{left:x,right:x,top:E,bottom:E+b.height}}function ai(A,f,x,b,E){var U=Ft(A,f,x);return U.xRel=E,b&&(U.outside=b),U}function ao(A,f,x){var b=A.doc;if(x+=A.display.viewOffset,x<0)return ai(b.first,0,null,-1,-1);var E=Ye(b,x),U=b.first+b.size-1;if(E>U)return ai(b.first+b.size-1,Wn(b,U).text.length,null,1,1);f<0&&(f=0);for(var Y=Wn(b,E);;){var te=qc(A,Y,E,f,x),le=Sr(Y,te.ch+(te.xRel>0||te.outside>0?1:0));if(!le)return te;var ge=le.find(1);if(ge.line==E)return ge;Y=Wn(b,E=ge.line)}}function sa(A,f,x,b){b-=Td(f);var E=f.text.length,U=St(function(Y){return bl(A,x,Y-1).bottom<=b},E,0);return E=St(function(Y){return bl(A,x,Y).top>b},U,E),{begin:U,end:E}}function yo(A,f,x,b){x||(x=Rl(A,f));var E=_u(A,f,bl(A,x,b),"line").top;return sa(A,f,x,E)}function _s(A,f,x,b){return A.bottom<=x?!1:A.top>x?!0:(b?A.left:A.right)>f}function qc(A,f,x,b,E){E-=Io(f);var U=Rl(A,f),Y=Td(f),te=0,le=f.text.length,ge=!0,Qe=En(f,A.doc.direction);if(Qe){var Je=(A.options.lineWrapping?Kd:Cs)(A,f,x,U,Qe,b,E);ge=Je.level!=1,te=ge?Je.from:Je.to-1,le=ge?Je.to:Je.from-1}var Mt=null,yt=null,zt=St(function(Kr){var _r=bl(A,U,Kr);return _r.top+=Y,_r.bottom+=Y,_s(_r,b,E,!1)?(_r.top<=E&&_r.left<=b&&(Mt=Kr,yt=_r),!0):!1},te,le),hn,kn,Yn=!1;if(yt){var xn=b-yt.left<yt.right-b,Ln=xn==ge;zt=Mt+(Ln?0:1),kn=Ln?"after":"before",hn=xn?yt.left:yt.right}else{!ge&&(zt==le||zt==te)&&zt++,kn=zt==0?"after":zt==f.text.length?"before":bl(A,U,zt-(ge?1:0)).bottom+Y<=E==ge?"after":"before";var sr=Wt(A,Ft(x,zt,kn),"line",f,U);hn=sr.left,Yn=E<sr.top?-1:E>=sr.bottom?1:0}return zt=At(f.text,zt,1),ai(x,zt,kn,Yn,b-hn)}function Cs(A,f,x,b,E,U,Y){var te=St(function(Je){var Mt=E[Je],yt=Mt.level!=1;return _s(Wt(A,Ft(x,yt?Mt.to:Mt.from,yt?"before":"after"),"line",f,b),U,Y,!0)},0,E.length-1),le=E[te];if(te>0){var ge=le.level!=1,Qe=Wt(A,Ft(x,ge?le.from:le.to,ge?"after":"before"),"line",f,b);_s(Qe,U,Y,!0)&&Qe.top>Y&&(le=E[te-1])}return le}function Kd(A,f,x,b,E,U,Y){var te=sa(A,f,b,Y),le=te.begin,ge=te.end;/\s/.test(f.text.charAt(ge-1))&&ge--;for(var Qe=null,Je=null,Mt=0;Mt<E.length;Mt++){var yt=E[Mt];if(!(yt.from>=ge||yt.to<=le)){var zt=yt.level!=1,hn=bl(A,b,zt?Math.min(ge,yt.to)-1:Math.max(le,yt.from)).right,kn=hn<U?U-hn+1e9:hn-U;(!Qe||Je>kn)&&(Qe=yt,Je=kn)}}return Qe||(Qe=E[E.length-1]),Qe.from<le&&(Qe={from:le,to:Qe.to,level:Qe.level}),Qe.to>ge&&(Qe={from:Qe.from,to:ge,level:Qe.level}),Qe}var Ps;function la(A){if(A.cachedTextHeight!=null)return A.cachedTextHeight;if(Ps==null){Ps=be("pre",null,"CodeMirror-line-like");for(var f=0;f<49;++f)Ps.appendChild(document.createTextNode("x")),Ps.appendChild(be("br"));Ps.appendChild(document.createTextNode("x"))}nt(A.measure,Ps);var x=Ps.offsetHeight/50;return x>3&&(A.cachedTextHeight=x),ke(A.measure),x||1}function Cu(A){if(A.cachedCharWidth!=null)return A.cachedCharWidth;var f=be("span","xxxxxxxxxx"),x=be("pre",[f],"CodeMirror-line-like");nt(A.measure,x);var b=f.getBoundingClientRect(),E=(b.right-b.left)/10;return E>2&&(A.cachedCharWidth=E),E||10}function Fs(A){for(var f=A.display,x={},b={},E=f.gutters.clientLeft,U=f.gutters.firstChild,Y=0;U;U=U.nextSibling,++Y){var te=A.display.gutterSpecs[Y].className;x[te]=U.offsetLeft+U.clientLeft+E,b[te]=U.clientWidth}return{fixedPos:to(f),gutterTotalWidth:f.gutters.offsetWidth,gutterLeft:x,gutterWidth:b,wrapperWidth:f.wrapper.clientWidth}}function to(A){return A.scroller.getBoundingClientRect().left-A.sizer.getBoundingClientRect().left}function xh(A){var f=la(A.display),x=A.options.lineWrapping,b=x&&Math.max(5,A.display.scroller.clientWidth/Cu(A.display)-3);return function(E){if(Hr(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 x?U+(Math.ceil(E.text.length/b)||1)*f:U+f}}function wh(A){var f=A.doc,x=xh(A);f.iter(function(b){var E=x(b);E!=b.height&&qi(b,E)})}function wl(A,f,x,b){var E=A.display;if(!x&&xt(f).getAttribute("cm-not-content")=="true")return null;var U,Y,te=E.lineSpace.getBoundingClientRect();try{U=f.clientX-te.left,Y=f.clientY-te.top}catch{return null}var le=ao(A,U,Y),ge;if(b&&le.xRel>0&&(ge=Wn(A.doc,le.line).text).length==le.ch){var Qe=fe(ge,ge.length,A.options.tabSize)-ge.length;le=Ft(le.line,Math.max(0,Math.round((U-kd(A.display).left)/Cu(A.display))-Qe))}return le}function DA(A,f){if(f>=A.display.viewTo||(f-=A.display.viewFrom,f<0))return null;for(var x=A.display.view,b=0;b<x.length;b++)if(f-=x[b].size,f<0)return b}function Da(A,f,x,b){f==null&&(f=A.doc.first),x==null&&(x=A.doc.first+A.doc.size),b||(b=0);var E=A.display;if(b&&x<E.viewTo&&(E.updateLineNumbers==null||E.updateLineNumbers>f)&&(E.updateLineNumbers=f),A.curOp.viewChanged=!0,f>=E.viewTo)Na&&fo(A.doc,f)<E.viewTo&&Nn(A);else if(x<=E.viewFrom)Na&&xi(A.doc,x+b)>E.viewFrom?Nn(A):(E.viewFrom+=b,E.viewTo+=b);else if(f<=E.viewFrom&&x>=E.viewTo)Nn(A);else if(f<=E.viewFrom){var U=zl(A,x,x+b,1);U?(E.view=E.view.slice(U.index),E.viewFrom=U.lineN,E.viewTo+=b):Nn(A)}else if(x>=E.viewTo){var Y=zl(A,f,f,-1);Y?(E.view=E.view.slice(0,Y.index),E.viewTo=Y.lineN):Nn(A)}else{var te=zl(A,f,f,-1),le=zl(A,x,x+b,1);te&&le?(E.view=E.view.slice(0,te.index).concat(lc(A,te.lineN,le.lineN)).concat(E.view.slice(le.index)),E.viewTo+=b):Nn(A)}var ge=E.externalMeasured;ge&&(x<ge.lineN?ge.lineN+=b:f<ge.lineN+ge.size&&(E.externalMeasured=null))}function Vs(A,f,x){A.curOp.viewChanged=!0;var b=A.display,E=A.display.externalMeasured;if(E&&f>=E.lineN&&f<E.lineN+E.size&&(b.externalMeasured=null),!(f<b.viewFrom||f>=b.viewTo)){var U=b.view[DA(A,f)];if(U.node!=null){var Y=U.changes||(U.changes=[]);Ue(Y,x)==-1&&Y.push(x)}}}function Nn(A){A.display.viewFrom=A.display.viewTo=A.doc.first,A.display.view=[],A.display.viewOffset=0}function zl(A,f,x,b){var E=DA(A,f),U,Y=A.display.view;if(!Na||x==A.doc.first+A.doc.size)return{index:E,lineN:x};for(var te=A.display.viewFrom,le=0;le<E;le++)te+=Y[le].size;if(te!=f){if(b>0){if(E==Y.length-1)return null;U=te+Y[E].size-f,E++}else U=te-f;f+=U,x+=U}for(;fo(A.doc,x)!=x;){if(E==(b<0?0:Y.length-1))return null;x+=b*Y[E-(b<0?1:0)].size,E+=b}return{index:E,lineN:x}}function hA(A,f,x){var b=A.display,E=b.view;E.length==0||f>=b.viewTo||x<=b.viewFrom?(b.view=lc(A,f,x),b.viewFrom=f):(b.viewFrom>f?b.view=lc(A,f,b.viewFrom).concat(b.view):b.viewFrom<f&&(b.view=b.view.slice(DA(A,f))),b.viewFrom=f,b.viewTo<x?b.view=b.view.concat(lc(A,b.viewTo,x)):b.viewTo>x&&(b.view=b.view.slice(0,DA(A,x)))),b.viewTo=x}function dc(A){for(var f=A.display.view,x=0,b=0;b<f.length;b++){var E=f[b];!E.hidden&&(!E.node||E.changes)&&++x}return x}function bu(A){A.display.input.showSelection(A.display.input.prepareSelection())}function $n(A,f){f===void 0&&(f=!0);var x=A.doc,b={},E=b.cursors=document.createDocumentFragment(),U=b.selection=document.createDocumentFragment(),Y=A.options.$customCursor;Y&&(f=!0);for(var te=0;te<x.sel.ranges.length;te++)if(!(!f&&te==x.sel.primIndex)){var le=x.sel.ranges[te];if(!(le.from().line>=A.display.viewTo||le.to().line<A.display.viewFrom)){var ge=le.empty();if(Y){var Qe=Y(A,le);Qe&&hc(A,Qe,E)}else(ge||A.options.showCursorWhenSelecting)&&hc(A,le.head,E);ge||If(A,le,U)}}return b}function hc(A,f,x){var b=Wt(A,f,"div",null,null,!A.options.singleCursorHeightPerLine),E=x.appendChild(be("div"," ","CodeMirror-cursor"));if(E.style.left=b.left+"px",E.style.top=b.top+"px",E.style.height=Math.max(0,b.bottom-b.top)*A.options.cursorHeight+"px",/\bcm-fat-cursor\b/.test(A.getWrapperElement().className)){var U=ln(A,f,"div",null,null),Y=U.right-U.left;E.style.width=(Y>0?Y:A.defaultCharWidth())+"px"}if(b.other){var te=x.appendChild(be("div"," ","CodeMirror-cursor CodeMirror-secondarycursor"));te.style.display="",te.style.left=b.other.left+"px",te.style.top=b.other.top+"px",te.style.height=(b.other.bottom-b.other.top)*.85+"px"}}function LA(A,f){return A.top-f.top||A.left-f.left}function If(A,f,x){var b=A.display,E=A.doc,U=document.createDocumentFragment(),Y=kd(A.display),te=Y.left,le=Math.max(b.sizerWidth,Wu(A)-b.sizer.offsetLeft)-Y.right,ge=E.direction=="ltr";function Qe(Ln,sr,Kr,_r){sr<0&&(sr=0),sr=Math.round(sr),_r=Math.round(_r),U.appendChild(be("div",null,"CodeMirror-selected","position: absolute; left: "+Ln+`px;
top: `+sr+"px; width: "+(Kr??le-Ln)+`px;
height: `+(_r-sr)+"px"))}function Je(Ln,sr,Kr){var _r=Wn(E,Ln),Ai=_r.text.length,Uo,qa;function ba(As,Ol){return ln(A,Ft(Ln,As),"div",_r,Ol)}function Ua(As,Ol,el){var ws=yo(A,_r,null,As),cs=Ol=="ltr"==(el=="after")?"left":"right",ca=el=="after"?ws.begin:ws.end-(/\s/.test(_r.text.charAt(ws.end-1))?2:1);return ba(ca,cs)[cs]}var us=En(_r,E.direction);return Et(us,sr||0,Kr??Ai,function(As,Ol,el,ws){var cs=el=="ltr",ca=ba(As,cs?"left":"right"),Ms=ba(Ol-1,cs?"right":"left"),Hd=sr==null&&As==0,GA=Kr==null&&Ol==Ai,zs=ws==0,QA=!us||ws==us.length-1;if(Ms.top-ca.top<=3){var js=(ge?Hd:GA)&&zs,l0=(ge?GA:Hd)&&QA,yA=js?te:(cs?ca:Ms).left,wc=l0?le:(cs?Ms:ca).right;Qe(yA,ca.top,wc-yA,ca.bottom)}else{var Ha,tl,Vd,$A;cs?(Ha=ge&&Hd&&zs?te:ca.left,tl=ge?le:Ua(As,el,"before"),Vd=ge?te:Ua(Ol,el,"after"),$A=ge&&GA&&QA?le:Ms.right):(Ha=ge?Ua(As,el,"before"):te,tl=!ge&&Hd&&zs?le:ca.right,Vd=!ge&&GA&&QA?te:Ms.left,$A=ge?Ua(Ol,el,"after"):le),Qe(Ha,ca.top,tl-Ha,ca.bottom),ca.bottom<Ms.top&&Qe(te,ca.bottom,null,Ms.top),Qe(Vd,Ms.top,$A-Vd,Ms.bottom)}(!Uo||LA(ca,Uo)<0)&&(Uo=ca),LA(Ms,Uo)<0&&(Uo=Ms),(!qa||LA(ca,qa)<0)&&(qa=ca),LA(Ms,qa)<0&&(qa=Ms)}),{start:Uo,end:qa}}var Mt=f.from(),yt=f.to();if(Mt.line==yt.line)Je(Mt.line,Mt.ch,yt.ch);else{var zt=Wn(E,Mt.line),hn=Wn(E,yt.line),kn=yr(zt)==yr(hn),Yn=Je(Mt.line,Mt.ch,kn?zt.text.length+1:null).end,xn=Je(yt.line,kn?0:null,yt.ch).start;kn&&(Yn.top<xn.top-2?(Qe(Yn.right,Yn.top,null,Yn.bottom),Qe(te,xn.top,xn.left,xn.bottom)):Qe(Yn.right,Yn.top,xn.left-Yn.right,Yn.bottom)),Yn.bottom<xn.top&&Qe(te,Yn.bottom,null,xn.top)}x.appendChild(U)}function Nu(A){if(A.state.focused){var f=A.display;clearInterval(f.blinker);var x=!0;f.cursorDiv.style.visibility="",A.options.cursorBlinkRate>0?f.blinker=setInterval(function(){A.hasFocus()||fc(A),f.cursorDiv.style.visibility=(x=!x)?"":"hidden"},A.options.cursorBlinkRate):A.options.cursorBlinkRate<0&&(f.cursorDiv.style.visibility="hidden")}}function xu(A){A.hasFocus()||(A.display.input.focus(),A.state.focused||Tf(A))}function UA(A){A.state.delayingBlurEvent=!0,setTimeout(function(){A.state.delayingBlurEvent&&(A.state.delayingBlurEvent=!1,A.state.focused&&fc(A))},100)}function Tf(A,f){A.state.delayingBlurEvent&&!A.state.draggingText&&(A.state.delayingBlurEvent=!1),A.options.readOnly!="nocursor"&&(A.state.focused||(Fe(A,"focus",A,f),A.state.focused=!0,Xe(A.display.wrapper,"CodeMirror-focused"),!A.curOp&&A.display.selForContextMenu!=A.doc.sel&&(A.display.input.reset(),C&&setTimeout(function(){return A.display.input.reset(!0)},20)),A.display.input.receivedFocus()),Nu(A))}function fc(A,f){A.state.delayingBlurEvent||(A.state.focused&&(Fe(A,"blur",A,f),A.state.focused=!1,He(A.display.wrapper,"CodeMirror-focused")),clearInterval(A.display.blinker),setTimeout(function(){A.state.focused||(A.display.shift=!1)},150))}function Gu(A){for(var f=A.display,x=f.lineDiv.offsetTop,b=Math.max(0,f.scroller.getBoundingClientRect().top),E=f.lineDiv.getBoundingClientRect().top,U=0,Y=0;Y<f.view.length;Y++){var te=f.view[Y],le=A.options.lineWrapping,ge=void 0,Qe=0;if(!te.hidden){if(E+=te.line.height,h&&g<8){var Je=te.node.offsetTop+te.node.offsetHeight;ge=Je-x,x=Je}else{var Mt=te.node.getBoundingClientRect();ge=Mt.bottom-Mt.top,!le&&te.text.firstChild&&(Qe=te.text.firstChild.getBoundingClientRect().right-Mt.left-1)}var yt=te.line.height-ge;if((yt>.005||yt<-.005)&&(E<b&&(U-=yt),qi(te.line,ge),So(te.line),te.rest))for(var zt=0;zt<te.rest.length;zt++)So(te.rest[zt]);if(Qe>A.display.sizerWidth){var hn=Math.ceil(Qe/Cu(A.display));hn>A.display.maxLineLength&&(A.display.maxLineLength=hn,A.display.maxLine=te.line,A.display.maxLineChanged=!0)}}}Math.abs(U)>2&&(f.scroller.scrollTop+=U)}function So(A){if(A.widgets)for(var f=0;f<A.widgets.length;++f){var x=A.widgets[f],b=x.node.parentNode;b&&(x.height=b.offsetHeight)}}function wu(A,f,x){var b=x&&x.top!=null?Math.max(0,x.top):A.scroller.scrollTop;b=Math.floor(b-KA(A));var E=x&&x.bottom!=null?x.bottom:b+A.wrapper.clientHeight,U=Ye(f,b),Y=Ye(f,E);if(x&&x.ensure){var te=x.ensure.from.line,le=x.ensure.to.line;te<U?(U=te,Y=Ye(f,Io(Wn(f,te))+A.wrapper.clientHeight)):Math.min(le,f.lastLine())>=Y&&(U=Ye(f,Io(Wn(f,le))-A.wrapper.clientHeight),Y=le)}return{from:U,to:Math.max(Y,U+1)}}function Hc(A,f){if(!de(A,"scrollCursorIntoView")){var x=A.display,b=x.sizer.getBoundingClientRect(),E=null,U=x.wrapper.ownerDocument;if(f.top+b.top<0?E=!0:f.bottom+b.top>(U.defaultView.innerHeight||U.documentElement.clientHeight)&&(E=!1),E!=null&&!$){var Y=be("div","",null,`position: absolute;
top: `+(f.top-x.viewOffset-KA(A.display))+`px;
height: `+(f.bottom-f.top+vu(A)+x.barHeight)+`px;
left: `+f.left+"px; width: "+Math.max(2,f.right-f.left)+"px;");A.display.lineSpace.appendChild(Y),Y.scrollIntoView(E),A.display.lineSpace.removeChild(Y)}}}function Tp(A,f,x,b){b==null&&(b=0);var E;!A.options.lineWrapping&&f==x&&(x=f.sticky=="before"?Ft(f.line,f.ch+1,"before"):f,f=f.ch?Ft(f.line,f.sticky=="before"?f.ch-1:f.ch,"after"):f);for(var U=0;U<5;U++){var Y=!1,te=Wt(A,f),le=!x||x==f?te:Wt(A,x);E={left:Math.min(te.left,le.left),top:Math.min(te.top,le.top)-b,right:Math.max(te.left,le.left),bottom:Math.max(te.bottom,le.bottom)+b};var ge=Pd(A,E),Qe=A.doc.scrollTop,Je=A.doc.scrollLeft;if(ge.scrollTop!=null&&(pc(A,ge.scrollTop),Math.abs(A.doc.scrollTop-Qe)>1&&(Y=!0)),ge.scrollLeft!=null&&(Jo(A,ge.scrollLeft),Math.abs(A.doc.scrollLeft-Je)>1&&(Y=!0)),!Y)break}return E}function Kf(A,f){var x=Pd(A,f);x.scrollTop!=null&&pc(A,x.scrollTop),x.scrollLeft!=null&&Jo(A,x.scrollLeft)}function Pd(A,f){var x=A.display,b=la(A.display);f.top<0&&(f.top=0);var E=A.curOp&&A.curOp.scrollTop!=null?A.curOp.scrollTop:x.scroller.scrollTop,U=$c(A),Y={};f.bottom-f.top>U&&(f.bottom=f.top+U);var te=A.doc.height+Ch(x),le=f.top<b,ge=f.bottom>te-b;if(f.top<E)Y.scrollTop=le?0:f.top;else if(f.bottom>E+U){var Qe=Math.min(f.top,(ge?te:f.bottom)-U);Qe!=E&&(Y.scrollTop=Qe)}var Je=A.options.fixedGutter?0:x.gutters.offsetWidth,Mt=A.curOp&&A.curOp.scrollLeft!=null?A.curOp.scrollLeft:x.scroller.scrollLeft-Je,yt=Wu(A)-x.gutters.offsetWidth,zt=f.right-f.left>yt;return zt&&(f.right=f.left+yt),f.left<10?Y.scrollLeft=0:f.left<Mt?Y.scrollLeft=Math.max(0,f.left+Je-(zt?0:10)):f.right>yt+Mt-3&&(Y.scrollLeft=f.right+(zt?0:10)-yt),Y}function Mh(A,f){f!=null&&(Tr(A),A.curOp.scrollTop=(A.curOp.scrollTop==null?A.doc.scrollTop:A.curOp.scrollTop)+f)}function so(A){Tr(A);var f=A.getCursor();A.curOp.scrollToPos={from:f,to:f,margin:A.options.cursorScrollMargin}}function ua(A,f,x){(f!=null||x!=null)&&Tr(A),f!=null&&(A.curOp.scrollLeft=f),x!=null&&(A.curOp.scrollTop=x)}function vr(A,f){Tr(A),A.curOp.scrollToPos=f}function Tr(A){var f=A.curOp.scrollToPos;if(f){A.curOp.scrollToPos=null;var x=hr(A,f.from),b=hr(A,f.to);RA(A,x,b,f.margin)}}function RA(A,f,x,b){var E=Pd(A,{left:Math.min(f.left,x.left),top:Math.min(f.top,x.top)-b,right:Math.max(f.right,x.right),bottom:Math.max(f.bottom,x.bottom)+b});ua(A,E.scrollLeft,E.scrollTop)}function pc(A,f){Math.abs(A.doc.scrollTop-f)<2||(i||El(A,{top:f}),Vc(A,f,!0),i&&El(A),mc(A,100))}function Vc(A,f,x){f=Math.max(0,Math.min(A.display.scroller.scrollHeight-A.display.scroller.clientHeight,f)),!(A.display.scroller.scrollTop==f&&!x)&&(A.doc.scrollTop=f,A.display.scrollbars.setScrollTop(f),A.display.scroller.scrollTop!=f&&(A.display.scroller.scrollTop=f))}function Jo(A,f,x,b){f=Math.max(0,Math.min(f,A.display.scroller.scrollWidth-A.display.scroller.clientWidth)),!((x?f==A.doc.scrollLeft:Math.abs(A.doc.scrollLeft-f)<2)&&!b)&&(A.doc.scrollLeft=f,p(A),A.display.scroller.scrollLeft!=f&&(A.display.scroller.scrollLeft=f),A.display.scrollbars.setScrollLeft(f))}function fA(A){var f=A.display,x=f.gutters.offsetWidth,b=Math.round(A.doc.height+Ch(A.display));return{clientHeight:f.scroller.clientHeight,viewHeight:f.wrapper.clientHeight,scrollWidth:f.scroller.scrollWidth,clientWidth:f.scroller.clientWidth,viewWidth:f.wrapper.clientWidth,barLeft:A.options.fixedGutter?x:0,docHeight:b,scrollHeight:b+vu(A)+f.barHeight,nativeBarWidth:f.nativeBarWidth,gutterWidth:x}}var Ia=function(A,f,x){this.cm=x;var b=this.vert=be("div",[be("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),E=this.horiz=be("div",[be("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");b.tabIndex=E.tabIndex=-1,A(b),A(E),Kt(b,"scroll",function(){b.clientHeight&&f(b.scrollTop,"vertical")}),Kt(E,"scroll",function(){E.clientWidth&&f(E.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,h&&g<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Ia.prototype.update=function(A){var f=A.scrollWidth>A.clientWidth+1,x=A.scrollHeight>A.clientHeight+1,b=A.nativeBarWidth;if(x){this.vert.style.display="block",this.vert.style.bottom=f?b+"px":"0";var E=A.viewHeight-(f?b: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(f){this.horiz.style.display="block",this.horiz.style.right=x?b+"px":"0",this.horiz.style.left=A.barLeft+"px";var U=A.viewWidth-A.barLeft-(x?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&&(b==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:x?b:0,bottom:f?b:0}},Ia.prototype.setScrollLeft=function(A){this.horiz.scrollLeft!=A&&(this.horiz.scrollLeft=A),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Ia.prototype.setScrollTop=function(A){this.vert.scrollTop!=A&&(this.vert.scrollTop=A),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Ia.prototype.zeroWidthHack=function(){var A=me&&!N?"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},Ia.prototype.enableZeroWidthBar=function(A,f,x){A.style.visibility="";function b(){var E=A.getBoundingClientRect(),U=x=="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":f.set(1e3,b)}f.set(1e3,b)},Ia.prototype.clear=function(){var A=this.horiz.parentNode;A.removeChild(this.horiz),A.removeChild(this.vert)};var pA=function(){};pA.prototype.update=function(){return{bottom:0,right:0}},pA.prototype.setScrollLeft=function(){},pA.prototype.setScrollTop=function(){},pA.prototype.clear=function(){};function Ml(A,f){f||(f=fA(A));var x=A.display.barWidth,b=A.display.barHeight;Go(A,f);for(var E=0;E<4&&x!=A.display.barWidth||b!=A.display.barHeight;E++)x!=A.display.barWidth&&A.options.lineWrapping&&Gu(A),Go(A,fA(A)),x=A.display.barWidth,b=A.display.barHeight}function Go(A,f){var x=A.display,b=x.scrollbars.update(f);x.sizer.style.paddingRight=(x.barWidth=b.right)+"px",x.sizer.style.paddingBottom=(x.barHeight=b.bottom)+"px",x.heightForcer.style.borderBottom=b.bottom+"px solid transparent",b.right&&b.bottom?(x.scrollbarFiller.style.display="block",x.scrollbarFiller.style.height=b.bottom+"px",x.scrollbarFiller.style.width=b.right+"px"):x.scrollbarFiller.style.display="",b.bottom&&A.options.coverGutterNextToScrollbar&&A.options.fixedGutter?(x.gutterFiller.style.display="block",x.gutterFiller.style.height=b.bottom+"px",x.gutterFiller.style.width=f.gutterWidth+"px"):x.gutterFiller.style.display=""}var Qo={native:Ia,null:pA};function Pf(A){A.display.scrollbars&&(A.display.scrollbars.clear(),A.display.scrollbars.addClass&&He(A.display.wrapper,A.display.scrollbars.addClass)),A.display.scrollbars=new Qo[A.options.scrollbarStyle](function(f){A.display.wrapper.insertBefore(f,A.display.scrollbarFiller),Kt(f,"mousedown",function(){A.state.focused&&setTimeout(function(){return A.display.input.focus()},0)}),f.setAttribute("cm-not-content","true")},function(f,x){x=="horizontal"?Jo(A,f):pc(A,f)},A),A.display.scrollbars.addClass&&Xe(A.display.wrapper,A.display.scrollbars.addClass)}var Qu=0;function $u(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:++Qu,markArrays:null},Gc(A.curOp)}function mA(A){var f=A.curOp;f&&gh(f,function(x){for(var b=0;b<x.ops.length;b++)x.ops[b].cm.curOp=null;Ff(x)})}function Ff(A){for(var f=A.ops,x=0;x<f.length;x++)Zc(f[x]);for(var b=0;b<f.length;b++)Yu(f[b]);for(var E=0;E<f.length;E++)Sh(f[E]);for(var U=0;U<f.length;U++)Pe(f[U]);for(var Y=0;Y<f.length;Y++)Sl(f[Y])}function Zc(A){var f=A.cm,x=f.display;Df(f),A.updateMaxLine&&Ga(f),A.mustUpdate=A.viewChanged||A.forceUpdate||A.scrollTop!=null||A.scrollToPos&&(A.scrollToPos.from.line<x.viewFrom||A.scrollToPos.to.line>=x.viewTo)||x.maxLineChanged&&f.options.lineWrapping,A.update=A.mustUpdate&&new Zs(f,A.mustUpdate&&{top:A.scrollTop,ensure:A.scrollToPos},A.forceUpdate)}function Yu(A){A.updatedDisplay=A.mustUpdate&&Dd(A.cm,A.update)}function Sh(A){var f=A.cm,x=f.display;A.updatedDisplay&&Gu(f),A.barMeasure=fA(f),x.maxLineChanged&&!f.options.lineWrapping&&(A.adjustWidthTo=Ac(f,x.maxLine,x.maxLine.text.length).left+3,f.display.sizerWidth=A.adjustWidthTo,A.barMeasure.scrollWidth=Math.max(x.scroller.clientWidth,x.sizer.offsetLeft+A.adjustWidthTo+vu(f)+f.display.barWidth),A.maxScrollLeft=Math.max(0,x.sizer.offsetLeft+A.adjustWidthTo-Wu(f))),(A.updatedDisplay||A.selectionChanged)&&(A.preparedSelection=x.input.prepareSelection())}function Pe(A){var f=A.cm;A.adjustWidthTo!=null&&(f.display.sizer.style.minWidth=A.adjustWidthTo+"px",A.maxScrollLeft<f.doc.scrollLeft&&Jo(f,Math.min(f.display.scroller.scrollLeft,A.maxScrollLeft),!0),f.display.maxLineChanged=!1);var x=A.focus&&A.focus==jt(gt(f));A.preparedSelection&&f.display.input.showSelection(A.preparedSelection,x),(A.updatedDisplay||A.startHeight!=f.doc.height)&&Ml(f,A.barMeasure),A.updatedDisplay&&u(f,A.barMeasure),A.selectionChanged&&Nu(f),f.state.focused&&A.updateInput&&f.display.input.reset(A.typing),x&&xu(A.cm)}function Sl(A){var f=A.cm,x=f.display,b=f.doc;if(A.updatedDisplay&&Eh(f,A.update),x.wheelStartX!=null&&(A.scrollTop!=null||A.scrollLeft!=null||A.scrollToPos)&&(x.wheelStartX=x.wheelStartY=null),A.scrollTop!=null&&Vc(f,A.scrollTop,A.forceScroll),A.scrollLeft!=null&&Jo(f,A.scrollLeft,!0,!0),A.scrollToPos){var E=Tp(f,Or(b,A.scrollToPos.from),Or(b,A.scrollToPos.to),A.scrollToPos.margin);Hc(f,E)}var U=A.maybeHiddenMarkers,Y=A.maybeUnhiddenMarkers;if(U)for(var te=0;te<U.length;++te)U[te].lines.length||Fe(U[te],"hide");if(Y)for(var le=0;le<Y.length;++le)Y[le].lines.length&&Fe(Y[le],"unhide");x.wrapper.offsetHeight&&(b.scrollTop=f.display.scroller.scrollTop),A.changeObjs&&Fe(f,"changes",f,A.changeObjs),A.update&&A.update.finish()}function Qa(A,f){if(A.curOp)return f();$u(A);try{return f()}finally{mA(A)}}function lo(A,f){return function(){if(A.curOp)return f.apply(A,arguments);$u(A);try{return f.apply(A,arguments)}finally{mA(A)}}}function Yr(A){return function(){if(this.curOp)return A.apply(this,arguments);$u(this);try{return A.apply(this,arguments)}finally{mA(this)}}}function va(A){return function(){var f=this.cm;if(!f||f.curOp)return A.apply(this,arguments);$u(f);try{return A.apply(this,arguments)}finally{mA(f)}}}function mc(A,f){A.doc.highlightFrontier<A.display.viewTo&&A.state.highlight.set(f,Lt(gc,A))}function gc(A){var f=A.doc;if(!(f.highlightFrontier>=A.display.viewTo)){var x=+new Date+A.options.workTime,b=ia(A,f.highlightFrontier),E=[];f.iter(b.line,Math.min(f.first+f.size,A.display.viewTo+500),function(U){if(b.line>=A.display.viewFrom){var Y=U.styles,te=U.text.length>A.options.maxHighlightLength?Ba(f.mode,b.state):null,le=Zl(A,U,b,!0);te&&(b.state=te),U.styles=le.styles;var ge=U.styleClasses,Qe=le.classes;Qe?U.styleClasses=Qe:ge&&(U.styleClasses=null);for(var Je=!Y||Y.length!=U.styles.length||ge!=Qe&&(!ge||!Qe||ge.bgClass!=Qe.bgClass||ge.textClass!=Qe.textClass),Mt=0;!Je&&Mt<Y.length;++Mt)Je=Y[Mt]!=U.styles[Mt];Je&&E.push(b.line),U.stateAfter=b.save(),b.nextLine()}else U.text.length<=A.options.maxHighlightLength&&qo(A,U.text,b),U.stateAfter=b.line%5==0?b.save():null,b.nextLine();if(+new Date>x)return mc(A,A.options.workDelay),!0}),f.highlightFrontier=b.line,f.modeFrontier=Math.max(f.modeFrontier,b.line),E.length&&Qa(A,function(){for(var U=0;U<E.length;U++)Vs(A,E[U],"text")})}}var Zs=function(A,f,x){var b=A.display;this.viewport=f,this.visible=wu(b,A.doc,f),this.editorIsHidden=!b.wrapper.offsetWidth,this.wrapperHeight=b.wrapper.clientHeight,this.wrapperWidth=b.wrapper.clientWidth,this.oldDisplayWidth=Wu(A),this.force=x,this.dims=Fs(A),this.events=[]};Zs.prototype.signal=function(A,f){Be(A,f)&&this.events.push(arguments)},Zs.prototype.finish=function(){for(var A=0;A<this.events.length;A++)Fe.apply(null,this.events[A])};function Df(A){var f=A.display;!f.scrollbarsClipped&&f.scroller.offsetWidth&&(f.nativeBarWidth=f.scroller.offsetWidth-f.scroller.clientWidth,f.heightForcer.style.height=vu(A)+"px",f.sizer.style.marginBottom=-f.nativeBarWidth+"px",f.sizer.style.borderRightWidth=vu(A)+"px",f.scrollbarsClipped=!0)}function Fd(A){if(A.hasFocus())return null;var f=jt(gt(A));if(!f||!Yt(A.display.lineDiv,f))return null;var x={activeElt:f};if(window.getSelection){var b=It(A).getSelection();b.anchorNode&&b.extend&&Yt(A.display.lineDiv,b.anchorNode)&&(x.anchorNode=b.anchorNode,x.anchorOffset=b.anchorOffset,x.focusNode=b.focusNode,x.focusOffset=b.focusOffset)}return x}function yc(A){if(!(!A||!A.activeElt||A.activeElt==jt(at(A.activeElt)))&&(A.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(A.activeElt.nodeName)&&A.anchorNode&&Yt(document.body,A.anchorNode)&&Yt(document.body,A.focusNode))){var f=A.activeElt.ownerDocument,x=f.defaultView.getSelection(),b=f.createRange();b.setEnd(A.anchorNode,A.anchorOffset),b.collapse(!1),x.removeAllRanges(),x.addRange(b),x.extend(A.focusNode,A.focusOffset)}}function Dd(A,f){var x=A.display,b=A.doc;if(f.editorIsHidden)return Nn(A),!1;if(!f.force&&f.visible.from>=x.viewFrom&&f.visible.to<=x.viewTo&&(x.updateLineNumbers==null||x.updateLineNumbers>=x.viewTo)&&x.renderedView==x.view&&dc(A)==0)return!1;_(A)&&(Nn(A),f.dims=Fs(A));var E=b.first+b.size,U=Math.max(f.visible.from-A.options.viewportMargin,b.first),Y=Math.min(E,f.visible.to+A.options.viewportMargin);x.viewFrom<U&&U-x.viewFrom<20&&(U=Math.max(b.first,x.viewFrom)),x.viewTo>Y&&x.viewTo-Y<20&&(Y=Math.min(E,x.viewTo)),Na&&(U=fo(A.doc,U),Y=xi(A.doc,Y));var te=U!=x.viewFrom||Y!=x.viewTo||x.lastWrapHeight!=f.wrapperHeight||x.lastWrapWidth!=f.wrapperWidth;hA(A,U,Y),x.viewOffset=Io(Wn(A.doc,x.viewFrom)),A.display.mover.style.top=x.viewOffset+"px";var le=dc(A);if(!te&&le==0&&!f.force&&x.renderedView==x.view&&(x.updateLineNumbers==null||x.updateLineNumbers>=x.viewTo))return!1;var ge=Fd(A);return le>4&&(x.lineDiv.style.display="none"),Lf(A,x.updateLineNumbers,f.dims),le>4&&(x.lineDiv.style.display=""),x.renderedView=x.view,yc(ge),ke(x.cursorDiv),ke(x.selectionDiv),x.gutters.style.height=x.sizer.style.minHeight=0,te&&(x.lastWrapHeight=f.wrapperHeight,x.lastWrapWidth=f.wrapperWidth,mc(A,400)),x.updateLineNumbers=null,!0}function Eh(A,f){for(var x=f.viewport,b=!0;;b=!1){if(!b||!A.options.lineWrapping||f.oldDisplayWidth==Wu(A)){if(x&&x.top!=null&&(x={top:Math.min(A.doc.height+Ch(A.display)-$c(A),x.top)}),f.visible=wu(A.display,A.doc,x),f.visible.from>=A.display.viewFrom&&f.visible.to<=A.display.viewTo)break}else b&&(f.visible=wu(A.display,A.doc,x));if(!Dd(A,f))break;Gu(A);var E=fA(A);bu(A),Ml(A,E),u(A,E),f.force=!1}f.signal(A,"update",A),(A.display.viewFrom!=A.display.reportedViewFrom||A.display.viewTo!=A.display.reportedViewTo)&&(f.signal(A,"viewportChange",A,A.display.viewFrom,A.display.viewTo),A.display.reportedViewFrom=A.display.viewFrom,A.display.reportedViewTo=A.display.viewTo)}function El(A,f){var x=new Zs(A,f);if(Dd(A,x)){Gu(A),Eh(A,x);var b=fA(A);bu(A),Ml(A,b),u(A,b),x.finish()}}function Lf(A,f,x){var b=A.display,E=A.options.lineNumbers,U=b.lineDiv,Y=U.firstChild;function te(zt){var hn=zt.nextSibling;return C&&me&&A.display.currentWheelTarget==zt?zt.style.display="none":zt.parentNode.removeChild(zt),hn}for(var le=b.view,ge=b.viewFrom,Qe=0;Qe<le.length;Qe++){var Je=le[Qe];if(!Je.hidden)if(!Je.node||Je.node.parentNode!=U){var Mt=uc(A,Je,ge,x);U.insertBefore(Mt,Y)}else{for(;Y!=Je.node;)Y=te(Y);var yt=E&&f!=null&&f<=ge&&Je.lineNumber;Je.changes&&(Ue(Je.changes,"gutter")>-1&&(yt=!1),yh(A,Je,ge,x)),yt&&(ke(Je.lineNumber),Je.lineNumber.appendChild(document.createTextNode(sn(A.options,ge)))),Y=Je.node.nextSibling}ge+=Je.size}for(;Y;)Y=te(Y)}function O(A){var f=A.gutters.offsetWidth;A.sizer.style.marginLeft=f+"px",No(A,"gutterChanged",A)}function u(A,f){A.display.sizer.style.minHeight=f.docHeight+"px",A.display.heightForcer.style.top=f.docHeight+"px",A.display.gutters.style.height=f.docHeight+A.display.barHeight+vu(A)+"px"}function p(A){var f=A.display,x=f.view;if(!(!f.alignWidgets&&(!f.gutters.firstChild||!A.options.fixedGutter))){for(var b=to(f)-f.scroller.scrollLeft+A.doc.scrollLeft,E=f.gutters.offsetWidth,U=b+"px",Y=0;Y<x.length;Y++)if(!x[Y].hidden){A.options.fixedGutter&&(x[Y].gutter&&(x[Y].gutter.style.left=U),x[Y].gutterBackground&&(x[Y].gutterBackground.style.left=U));var te=x[Y].alignable;if(te)for(var le=0;le<te.length;le++)te[le].style.left=U}A.options.fixedGutter&&(f.gutters.style.left=b+E+"px")}}function _(A){if(!A.options.lineNumbers)return!1;var f=A.doc,x=sn(A.options,f.first+f.size-1),b=A.display;if(x.length!=b.lineNumChars){var E=b.measure.appendChild(be("div",[be("div",x)],"CodeMirror-linenumber CodeMirror-gutter-elt")),U=E.firstChild.offsetWidth,Y=E.offsetWidth-U;return b.lineGutter.style.width="",b.lineNumInnerWidth=Math.max(U,b.lineGutter.offsetWidth-Y)+1,b.lineNumWidth=b.lineNumInnerWidth+Y,b.lineNumChars=b.lineNumInnerWidth?x.length:-1,b.lineGutter.style.width=b.lineNumWidth+"px",O(A.display),!0}return!1}function M(A,f){for(var x=[],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(f)b=!0;else continue;x.push({className:U,style:Y})}return f&&!b&&x.push({className:"CodeMirror-linenumbers",style:null}),x}function I(A){var f=A.gutters,x=A.gutterSpecs;ke(f),A.lineGutter=null;for(var b=0;b<x.length;++b){var E=x[b],U=E.className,Y=E.style,te=f.appendChild(be("div",null,"CodeMirror-gutter "+U));Y&&(te.style.cssText=Y),U=="CodeMirror-linenumbers"&&(A.lineGutter=te,te.style.width=(A.lineNumWidth||1)+"px")}f.style.display=x.length?"":"none",O(A)}function z(A){I(A.display),Da(A),p(A)}function W(A,f,x,b){var E=this;this.input=x,E.scrollbarFiller=be("div",null,"CodeMirror-scrollbar-filler"),E.scrollbarFiller.setAttribute("cm-not-content","true"),E.gutterFiller=be("div",null,"CodeMirror-gutter-filler"),E.gutterFiller.setAttribute("cm-not-content","true"),E.lineDiv=Bt("div",null,"CodeMirror-code"),E.selectionDiv=be("div",null,null,"position: relative; z-index: 1"),E.cursorDiv=be("div",null,"CodeMirror-cursors"),E.measure=be("div",null,"CodeMirror-measure"),E.lineMeasure=be("div",null,"CodeMirror-measure"),E.lineSpace=Bt("div",[E.measure,E.lineMeasure,E.selectionDiv,E.cursorDiv,E.lineDiv],null,"position: relative; outline: none");var U=Bt("div",[E.lineSpace],"CodeMirror-lines");E.mover=be("div",[U],null,"position: relative"),E.sizer=be("div",[E.mover],"CodeMirror-sizer"),E.sizerWidth=null,E.heightForcer=be("div",null,null,"position: absolute; height: "+et+"px; width: 1px;"),E.gutters=be("div",null,"CodeMirror-gutters"),E.lineGutter=null,E.scroller=be("div",[E.sizer,E.heightForcer,E.gutters],"CodeMirror-scroll"),E.scroller.setAttribute("tabIndex","-1"),E.wrapper=be("div",[E.scrollbarFiller,E.gutterFiller,E.scroller],"CodeMirror"),k&&P>=105&&(E.wrapper.style.clipPath="inset(0px)"),E.wrapper.setAttribute("translate","no"),h&&g<8&&(E.gutters.style.zIndex=-1,E.scroller.style.paddingRight=0),!C&&!(i&&ce)&&(E.scroller.draggable=!0),A&&(A.appendChild?A.appendChild(E.wrapper):A(E.wrapper)),E.viewFrom=E.viewTo=f.first,E.reportedViewFrom=E.reportedViewTo=f.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=M(b.gutters,b.lineNumbers),I(E),x.init(E)}var Q=0,re=null;h?re=-.53:i?re=15:k?re=-.7:J&&(re=-1/3);function ue(A){var f=A.wheelDeltaX,x=A.wheelDeltaY;return f==null&&A.detail&&A.axis==A.HORIZONTAL_AXIS&&(f=A.detail),x==null&&A.detail&&A.axis==A.VERTICAL_AXIS?x=A.detail:x==null&&(x=A.wheelDelta),{x:f,y:x}}function pe(A){var f=ue(A);return f.x*=re,f.y*=re,f}function Ie(A,f){k&&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 x=ue(f),b=x.x,E=x.y,U=re;f.deltaMode===0&&(b=f.deltaX,E=f.deltaY,U=1);var Y=A.display,te=Y.scroller,le=te.scrollWidth>te.clientWidth,ge=te.scrollHeight>te.clientHeight;if(b&&le||E&&ge){if(E&&me&&C){e:for(var Qe=f.target,Je=Y.view;Qe!=te;Qe=Qe.parentNode)for(var Mt=0;Mt<Je.length;Mt++)if(Je[Mt].node==Qe){A.display.currentWheelTarget=Qe;break e}}if(b&&!i&&!L&&U!=null){E&&ge&&pc(A,Math.max(0,te.scrollTop+E*U)),Jo(A,Math.max(0,te.scrollLeft+b*U)),(!E||E&&ge)&&tt(f),Y.wheelStartX=null;return}if(E&&U!=null){var yt=E*U,zt=A.doc.scrollTop,hn=zt+Y.wrapper.clientHeight;yt<0?zt=Math.max(0,zt+yt-50):hn=Math.min(A.doc.height,hn+yt+50),El(A,{top:zt,bottom:hn})}Q<20&&f.deltaMode!==0&&(Y.wheelStartX==null?(Y.wheelStartX=te.scrollLeft,Y.wheelStartY=te.scrollTop,Y.wheelDX=b,Y.wheelDY=E,setTimeout(function(){if(Y.wheelStartX!=null){var kn=te.scrollLeft-Y.wheelStartX,Yn=te.scrollTop-Y.wheelStartY,xn=Yn&&Y.wheelDY&&Yn/Y.wheelDY||kn&&Y.wheelDX&&kn/Y.wheelDX;Y.wheelStartX=Y.wheelStartY=null,xn&&(re=(re*Q+xn)/(Q+1),++Q)}},200)):(Y.wheelDX+=b,Y.wheelDY+=E))}}var Ne=function(A,f){this.ranges=A,this.primIndex=f};Ne.prototype.primary=function(){return this.ranges[this.primIndex]},Ne.prototype.equals=function(A){if(A==this)return!0;if(A.primIndex!=this.primIndex||A.ranges.length!=this.ranges.length)return!1;for(var f=0;f<this.ranges.length;f++){var x=this.ranges[f],b=A.ranges[f];if(!ur(x.anchor,b.anchor)||!ur(x.head,b.head))return!1}return!0},Ne.prototype.deepCopy=function(){for(var A=[],f=0;f<this.ranges.length;f++)A[f]=new Re(fi(this.ranges[f].anchor),fi(this.ranges[f].head));return new Ne(A,this.primIndex)},Ne.prototype.somethingSelected=function(){for(var A=0;A<this.ranges.length;A++)if(!this.ranges[A].empty())return!0;return!1},Ne.prototype.contains=function(A,f){f||(f=A);for(var x=0;x<this.ranges.length;x++){var b=this.ranges[x];if(Cn(f,b.from())>=0&&Cn(A,b.to())<=0)return x}return-1};var Re=function(A,f){this.anchor=A,this.head=f};Re.prototype.from=function(){return Zo(this.anchor,this.head)},Re.prototype.to=function(){return ei(this.anchor,this.head)},Re.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function $e(A,f,x){var b=A&&A.options.selectionsMayTouch,E=f[x];f.sort(function(Mt,yt){return Cn(Mt.from(),yt.from())}),x=Ue(f,E);for(var U=1;U<f.length;U++){var Y=f[U],te=f[U-1],le=Cn(te.to(),Y.from());if(b&&!Y.empty()?le>0:le>=0){var ge=Zo(te.from(),Y.from()),Qe=ei(te.to(),Y.to()),Je=te.empty()?Y.from()==Y.head:te.from()==te.head;U<=x&&--x,f.splice(--U,2,new Re(Je?Qe:ge,Je?ge:Qe))}}return new Ne(f,x)}function Ge(A,f){return new Ne([new Re(A,f||A)],0)}function ht(A){return A.text?Ft(A.from.line+A.text.length-1,vn(A.text).length+(A.text.length==1?A.from.ch:0)):A.to}function Tt(A,f){if(Cn(A,f.from)<0)return A;if(Cn(A,f.to)<=0)return ht(f);var x=A.line+f.text.length-(f.to.line-f.from.line)-1,b=A.ch;return A.line==f.to.line&&(b+=ht(f).ch-f.to.ch),Ft(x,b)}function Ze(A,f){for(var x=[],b=0;b<A.sel.ranges.length;b++){var E=A.sel.ranges[b];x.push(new Re(Tt(E.anchor,f),Tt(E.head,f)))}return $e(A.cm,x,A.sel.primIndex)}function Ct(A,f,x){return A.line==f.line?Ft(x.line,A.ch-f.ch+x.ch):Ft(x.line+(A.line-f.line),A.ch)}function $t(A,f,x){for(var b=[],E=Ft(A.first,0),U=E,Y=0;Y<f.length;Y++){var te=f[Y],le=Ct(te.from,E,U),ge=Ct(ht(te),E,U);if(E=te.to,U=ge,x=="around"){var Qe=A.sel.ranges[Y],Je=Cn(Qe.head,Qe.anchor)<0;b[Y]=new Re(Je?ge:le,Je?le:ge)}else b[Y]=new Re(le,le)}return new Ne(b,A.sel.primIndex)}function Dt(A){A.doc.mode=Jr(A.options,A.doc.modeOption),tn(A)}function tn(A){A.doc.iter(function(f){f.stateAfter&&(f.stateAfter=null),f.styles&&(f.styles=null)}),A.doc.modeFrontier=A.doc.highlightFrontier=A.doc.first,mc(A,100),A.state.modeGen++,A.curOp&&Da(A)}function dn(A,f){return f.from.ch==0&&f.to.ch==0&&vn(f.text)==""&&(!A.cm||A.cm.options.wholeLineUpdateBefore)}function An(A,f,x,b){function E(xn){return x?x[xn]:null}function U(xn,Ln,sr){Xl(xn,Ln,sr,b),No(xn,"change",xn,f)}function Y(xn,Ln){for(var sr=[],Kr=xn;Kr<Ln;++Kr)sr.push(new Ll(ge[Kr],E(Kr),b));return sr}var te=f.from,le=f.to,ge=f.text,Qe=Wn(A,te.line),Je=Wn(A,le.line),Mt=vn(ge),yt=E(ge.length-1),zt=le.line-te.line;if(f.full)A.insert(0,Y(0,ge.length)),A.remove(ge.length,A.size-ge.length);else if(dn(A,f)){var hn=Y(0,ge.length-1);U(Je,Je.text,yt),zt&&A.remove(te.line,zt),hn.length&&A.insert(te.line,hn)}else if(Qe==Je)if(ge.length==1)U(Qe,Qe.text.slice(0,te.ch)+Mt+Qe.text.slice(le.ch),yt);else{var kn=Y(1,ge.length-1);kn.push(new Ll(Mt+Qe.text.slice(le.ch),yt,b)),U(Qe,Qe.text.slice(0,te.ch)+ge[0],E(0)),A.insert(te.line+1,kn)}else if(ge.length==1)U(Qe,Qe.text.slice(0,te.ch)+ge[0]+Je.text.slice(le.ch),E(0)),A.remove(te.line+1,zt);else{U(Qe,Qe.text.slice(0,te.ch)+ge[0],E(0)),U(Je,Mt+Je.text.slice(le.ch),yt);var Yn=Y(1,ge.length-1);zt>1&&A.remove(te.line+1,zt-1),A.insert(te.line+1,Yn)}No(A,"change",A,f)}function bn(A,f,x){function b(E,U,Y){if(E.linked)for(var te=0;te<E.linked.length;++te){var le=E.linked[te];if(le.doc!=U){var ge=Y&&le.sharedHist;x&&!ge||(f(le.doc,ge),b(le.doc,E,ge))}}}b(A,null,!0)}function tr(A,f){if(f.cm)throw new Error("This document is already in use.");A.doc=f,f.cm=A,wh(A),Dt(A),Pr(A),A.options.direction=f.direction,A.options.lineWrapping||Ga(A),A.options.mode=f.modeOption,Da(A)}function Pr(A){(A.doc.direction=="rtl"?Xe:He)(A.display.lineDiv,"CodeMirror-rtl")}function Tn(A){Qa(A,function(){Pr(A),Da(A)})}function xr(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 Jn(A,f){var x={from:fi(f.from),to:ht(f),text:eo(A,f.from,f.to)};return Ds(A,x,f.from.line,f.to.line+1),bn(A,function(b){return Ds(b,x,f.from.line,f.to.line+1)},!0),x}function Ni(A){for(;A.length;){var f=vn(A);if(f.ranges)A.pop();else break}}function ki(A,f){if(f)return Ni(A.done),vn(A.done);if(A.done.length&&!vn(A.done).ranges)return vn(A.done);if(A.done.length>1&&!A.done[A.done.length-2].ranges)return A.done.pop(),vn(A.done)}function ri(A,f,x,b){var E=A.history;E.undone.length=0;var U=+new Date,Y,te;if((E.lastOp==b||E.lastOrigin==f.origin&&f.origin&&(f.origin.charAt(0)=="+"&&E.lastModTime>U-(A.cm?A.cm.options.historyEventDelay:500)||f.origin.charAt(0)=="*"))&&(Y=ki(E,E.lastOp==b)))te=vn(Y.changes),Cn(f.from,f.to)==0&&Cn(f.from,te.to)==0?te.to=ht(f):Y.changes.push(Jn(A,f));else{var le=vn(E.done);for((!le||!le.ranges)&&Ui(A.sel,E.done),Y={changes:[Jn(A,f)],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(x),E.generation=++E.maxGeneration,E.lastModTime=E.lastSelTime=U,E.lastOp=E.lastSelOp=b,E.lastOrigin=E.lastSelOrigin=f.origin,te||Fe(A,"historyAdded")}function Mi(A,f,x,b){var E=f.charAt(0);return E=="*"||E=="+"&&x.ranges.length==b.ranges.length&&x.somethingSelected()==b.somethingSelected()&&new Date-A.history.lastSelTime<=(A.cm?A.cm.options.historyEventDelay:500)}function ea(A,f,x,b){var E=A.history,U=b&&b.origin;x==E.lastSelOp||U&&E.lastSelOrigin==U&&(E.lastModTime==E.lastSelTime&&E.lastOrigin==U||Mi(A,U,vn(E.done),f))?E.done[E.done.length-1]=f:Ui(f,E.done),E.lastSelTime=+new Date,E.lastSelOrigin=U,E.lastSelOp=x,b&&b.clearRedo!==!1&&Ni(E.undone)}function Ui(A,f){var x=vn(f);x&&x.ranges&&x.equals(A)||f.push(A)}function Ds(A,f,x,b){var E=f["spans_"+A.id],U=0;A.iter(Math.max(A.first,x),Math.min(A.first+A.size,b),function(Y){Y.markedSpans&&((E||(E=f["spans_"+A.id]={}))[U]=Y.markedSpans),++U})}function bs(A){if(!A)return null;for(var f,x=0;x<A.length;++x)A[x].marker.explicitlyCleared?f||(f=A.slice(0,x)):f&&f.push(A[x]);return f?f.length?f:null:A}function Ho(A,f){var x=f["spans_"+A.id];if(!x)return null;for(var b=[],E=0;E<f.text.length;++E)b.push(bs(x[E]));return b}function Ls(A,f){var x=Ho(A,f),b=oa(A,f);if(!x)return b;if(!b)return x;for(var E=0;E<x.length;++E){var U=x[E],Y=b[E];if(U&&Y)e:for(var te=0;te<Y.length;++te){for(var le=Y[te],ge=0;ge<U.length;++ge)if(U[ge].marker==le.marker)continue e;U.push(le)}else Y&&(x[E]=Y)}return x}function Ta(A,f,x){for(var b=[],E=0;E<A.length;++E){var U=A[E];if(U.ranges){b.push(x?Ne.prototype.deepCopy.call(U):U);continue}var Y=U.changes,te=[];b.push({changes:te});for(var le=0;le<Y.length;++le){var ge=Y[le],Qe=void 0;if(te.push({from:ge.from,to:ge.to,text:ge.text}),f)for(var Je in ge)(Qe=Je.match(/^spans_(\d+)$/))&&Ue(f,Number(Qe[1]))>-1&&(vn(te)[Je]=ge[Je],delete ge[Je])}}return b}function Eo(A,f,x,b){if(b){var E=A.anchor;if(x){var U=Cn(f,E)<0;U!=Cn(x,E)<0?(E=f,f=x):U!=Cn(f,x)<0&&(f=x)}return new Re(E,f)}else return new Re(x||f,f)}function jl(A,f,x,b,E){E==null&&(E=A.cm&&(A.cm.display.shift||A.extend)),Pi(A,new Ne([Eo(A.sel.primary(),f,x,E)],0),b)}function zA(A,f,x){for(var b=[],E=A.cm&&(A.cm.display.shift||A.extend),U=0;U<A.sel.ranges.length;U++)b[U]=Eo(A.sel.ranges[U],f[U],null,E);var Y=$e(A.cm,b,A.sel.primIndex);Pi(A,Y,x)}function Us(A,f,x,b){var E=A.sel.ranges.slice(0);E[f]=x,Pi(A,$e(A.cm,E,A.sel.primIndex),b)}function Mu(A,f,x,b){Pi(A,Ge(f,x),b)}function Ka(A,f,x){var b={ranges:f.ranges,update:function(E){this.ranges=[];for(var U=0;U<E.length;U++)this.ranges[U]=new Re(Or(A,E[U].anchor),Or(A,E[U].head))},origin:x&&x.origin};return Fe(A,"beforeSelectionChange",A,b),A.cm&&Fe(A.cm,"beforeSelectionChange",A.cm,b),b.ranges!=f.ranges?$e(A.cm,b.ranges,b.ranges.length-1):f}function Lo(A,f,x){var b=A.history.done,E=vn(b);E&&E.ranges?(b[b.length-1]=f,vo(A,f,x)):Pi(A,f,x)}function Pi(A,f,x){vo(A,f,x),ea(A,A.sel,A.cm?A.cm.curOp.id:NaN,x)}function vo(A,f,x){(Be(A,"beforeSelectionChange")||A.cm&&Be(A.cm,"beforeSelectionChange"))&&(f=Ka(A,f,x));var b=x&&x.bias||(Cn(f.primary().head,A.sel.primary().head)<0?-1:1);Ko(A,ls(A,f,b,!0)),!(x&&x.scroll===!1)&&A.cm&&A.cm.getOption("readOnly")!="nocursor"&&so(A.cm)}function Ko(A,f){f.equals(A.sel)||(A.sel=f,A.cm&&(A.cm.curOp.updateInput=1,A.cm.curOp.selectionChanged=!0,Ce(A.cm)),No(A,"cursorActivity",A))}function $a(A){Ko(A,ls(A,A.sel,null,!1))}function ls(A,f,x,b){for(var E,U=0;U<f.ranges.length;U++){var Y=f.ranges[U],te=f.ranges.length==A.sel.ranges.length&&A.sel.ranges[U],le=vc(A,Y.anchor,te&&te.anchor,x,b),ge=Y.head==Y.anchor?le:vc(A,Y.head,te&&te.head,x,b);(E||le!=Y.anchor||ge!=Y.head)&&(E||(E=f.ranges.slice(0,U)),E[U]=new Re(le,ge))}return E?$e(A.cm,E,f.primIndex):f}function Aa(A,f,x,b,E){var U=Wn(A,f.line);if(U.markedSpans)for(var Y=0;Y<U.markedSpans.length;++Y){var te=U.markedSpans[Y],le=te.marker,ge="selectLeft"in le?!le.selectLeft:le.inclusiveLeft,Qe="selectRight"in le?!le.selectRight:le.inclusiveRight;if((te.from==null||(ge?te.from<=f.ch:te.from<f.ch))&&(te.to==null||(Qe?te.to>=f.ch:te.to>f.ch))){if(E&&(Fe(le,"beforeCursorEnter"),le.explicitlyCleared))if(U.markedSpans){--Y;continue}else break;if(!le.atomic)continue;if(x){var Je=le.find(b<0?1:-1),Mt=void 0;if((b<0?Qe:ge)&&(Je=_a(A,Je,-b,Je&&Je.line==f.line?U:null)),Je&&Je.line==f.line&&(Mt=Cn(Je,x))&&(b<0?Mt<0:Mt>0))return Aa(A,Je,f,b,E)}var yt=le.find(b<0?-1:1);return(b<0?ge:Qe)&&(yt=_a(A,yt,b,yt.line==f.line?U:null)),yt?Aa(A,yt,f,b,E):null}}return f}function vc(A,f,x,b,E){var U=b||1,Y=Aa(A,f,x,U,E)||!E&&Aa(A,f,x,U,!0)||Aa(A,f,x,-U,E)||!E&&Aa(A,f,x,-U,!0);return Y||(A.cantEdit=!0,Ft(A.first,0))}function _a(A,f,x,b){return x<0&&f.ch==0?f.line>A.first?Or(A,Ft(f.line-1)):null:x>0&&f.ch==(b||Wn(A,f.line)).text.length?f.line<A.first+A.size-1?Ft(f.line+1,0):null:new Ft(f.line,f.ch+x)}function jA(A){A.setSelection(Ft(A.firstLine(),0),Ft(A.lastLine()),bt)}function Oh(A,f,x){var b={canceled:!1,from:f.from,to:f.to,text:f.text,origin:f.origin,cancel:function(){return b.canceled=!0}};return x&&(b.update=function(E,U,Y,te){E&&(b.from=Or(A,E)),U&&(b.to=Or(A,U)),Y&&(b.text=Y),te!==void 0&&(b.origin=te)}),Fe(A,"beforeChange",A,b),A.cm&&Fe(A.cm,"beforeChange",A.cm,b),b.canceled?(A.cm&&(A.cm.curOp.updateInput=2),null):{from:b.from,to:b.to,text:b.text,origin:b.origin}}function nu(A,f,x){if(A.cm){if(!A.cm.curOp)return lo(A.cm,nu)(A,f,x);if(A.cm.state.suppressEdits)return}if(!((Be(A,"beforeChange")||A.cm&&Be(A.cm,"beforeChange"))&&(f=Oh(A,f,!0),!f))){var b=Wo&&!x&&AA(A,f.from,f.to);if(b)for(var E=b.length-1;E>=0;--E)WA(A,{from:b[E].from,to:b[E].to,text:E?[""]:f.text,origin:f.origin});else WA(A,f)}}function WA(A,f){if(!(f.text.length==1&&f.text[0]==""&&Cn(f.from,f.to)==0)){var x=Ze(A,f);ri(A,f,x,A.cm?A.cm.curOp.id:NaN),_c(A,f,x,oa(A,f));var b=[];bn(A,function(E,U){!U&&Ue(b,E.history)==-1&&(B1(E.history,f),b.push(E.history)),_c(E,f,null,oa(E,f))})}}function Xs(A,f,x){var b=A.cm&&A.cm.state.suppressEdits;if(!(b&&!x)){for(var E=A.history,U,Y=A.sel,te=f=="undo"?E.done:E.undone,le=f=="undo"?E.undone:E.done,ge=0;ge<te.length&&(U=te[ge],!(x?U.ranges&&!U.equals(A.sel):!U.ranges));ge++);if(ge!=te.length){for(E.lastOrigin=E.lastSelOrigin=null;;)if(U=te.pop(),U.ranges){if(Ui(U,le),x&&!U.equals(A.sel)){Pi(A,U,{clearRedo:!1});return}Y=U}else if(b){te.push(U);return}else break;var Qe=[];Ui(Y,le),le.push({changes:Qe,generation:E.generation}),E.generation=U.generation||++E.maxGeneration;for(var Je=Be(A,"beforeChange")||A.cm&&Be(A.cm,"beforeChange"),Mt=function(hn){var kn=U.changes[hn];if(kn.origin=f,Je&&!Oh(A,kn,!1))return te.length=0,{};Qe.push(Jn(A,kn));var Yn=hn?Ze(A,kn):vn(te);_c(A,kn,Yn,Ls(A,kn)),!hn&&A.cm&&A.cm.scrollIntoView({from:kn.from,to:ht(kn)});var xn=[];bn(A,function(Ln,sr){!sr&&Ue(xn,Ln.history)==-1&&(B1(Ln.history,kn),xn.push(Ln.history)),_c(Ln,kn,null,Ls(Ln,kn))})},yt=U.changes.length-1;yt>=0;--yt){var zt=Mt(yt);if(zt)return zt.v}}}}function Ld(A,f){if(f!=0&&(A.first+=f,A.sel=new Ne(Xn(A.sel.ranges,function(E){return new Re(Ft(E.anchor.line+f,E.anchor.ch),Ft(E.head.line+f,E.head.ch))}),A.sel.primIndex),A.cm)){Da(A.cm,A.first,A.first-f,f);for(var x=A.cm.display,b=x.viewFrom;b<x.viewTo;b++)Vs(A.cm,b,"gutter")}}function _c(A,f,x,b){if(A.cm&&!A.cm.curOp)return lo(A.cm,_c)(A,f,x,b);if(f.to.line<A.first){Ld(A,f.text.length-1-(f.to.line-f.from.line));return}if(!(f.from.line>A.lastLine())){if(f.from.line<A.first){var E=f.text.length-1-(A.first-f.from.line);Ld(A,E),f={from:Ft(A.first,0),to:Ft(f.to.line+E,f.to.ch),text:[vn(f.text)],origin:f.origin}}var U=A.lastLine();f.to.line>U&&(f={from:f.from,to:Ft(U,Wn(A,U).text.length),text:[f.text[0]],origin:f.origin}),f.removed=eo(A,f.from,f.to),x||(x=Ze(A,f)),A.cm?Bh(A.cm,f,b):An(A,f,b),vo(A,x,bt),A.cantEdit&&vc(A,Ft(A.firstLine(),0))&&(A.cantEdit=!1)}}function Bh(A,f,x){var b=A.doc,E=A.display,U=f.from,Y=f.to,te=!1,le=U.line;A.options.lineWrapping||(le=ve(yr(Wn(b,U.line))),b.iter(le,Y.line+1,function(yt){if(yt==E.maxLine)return te=!0,!0})),b.sel.contains(f.from,f.to)>-1&&Ce(A),An(b,f,x,xh(A)),A.options.lineWrapping||(b.iter(le,U.line+f.text.length,function(yt){var zt=wo(yt);zt>E.maxLineLength&&(E.maxLine=yt,E.maxLineLength=zt,E.maxLineChanged=!0,te=!1)}),te&&(A.curOp.updateMaxLine=!0)),uA(b,U.line),mc(A,400);var ge=f.text.length-(Y.line-U.line)-1;f.full?Da(A):U.line==Y.line&&f.text.length==1&&!dn(A.doc,f)?Vs(A,U.line,"text"):Da(A,U.line,Y.line+1,ge);var Qe=Be(A,"changes"),Je=Be(A,"change");if(Je||Qe){var Mt={from:U,to:Y,text:f.text,removed:f.removed,origin:f.origin};Je&&No(A,"change",A,Mt),Qe&&(A.curOp.changeObjs||(A.curOp.changeObjs=[])).push(Mt)}A.display.selForContextMenu=null}function qu(A,f,x,b,E){var U;b||(b=x),Cn(b,x)<0&&(U=[b,x],x=U[0],b=U[1]),typeof f=="string"&&(f=A.splitLines(f)),nu(A,{from:x,to:b,text:f,origin:E})}function Uf(A,f,x,b){x<A.line?A.line+=b:f<A.line&&(A.line=f,A.ch=0)}function Xc(A,f,x,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 te=0;te<U.ranges.length;te++)Uf(U.ranges[te].anchor,f,x,b),Uf(U.ranges[te].head,f,x,b);continue}for(var le=0;le<U.changes.length;++le){var ge=U.changes[le];if(x<ge.from.line)ge.from=Ft(ge.from.line+b,ge.from.ch),ge.to=Ft(ge.to.line+b,ge.to.ch);else if(f<=ge.to.line){Y=!1;break}}Y||(A.splice(0,E+1),E=0)}}function B1(A,f){var x=f.from.line,b=f.to.line,E=f.text.length-(b-x)-1;Xc(A.done,x,b,E),Xc(A.undone,x,b,E)}function Jc(A,f,x,b){var E=f,U=f;return typeof f=="number"?U=Wn(A,Fa(A,f)):E=ve(f),E==null?null:(b(U,E)&&A.cm&&Vs(A.cm,E,x),U)}function ed(A){this.lines=A,this.parent=null;for(var f=0,x=0;x<A.length;++x)A[x].parent=this,f+=A[x].height;this.height=f}ed.prototype={chunkSize:function(){return this.lines.length},removeInner:function(A,f){for(var x=A,b=A+f;x<b;++x){var E=this.lines[x];this.height-=E.height,ga(E),No(E,"delete")}this.lines.splice(A,f)},collapse:function(A){A.push.apply(A,this.lines)},insertInner:function(A,f,x){this.height+=x,this.lines=this.lines.slice(0,A).concat(f).concat(this.lines.slice(A));for(var b=0;b<f.length;++b)f[b].parent=this},iterN:function(A,f,x){for(var b=A+f;A<b;++A)if(x(this.lines[A]))return!0}};function kh(A){this.children=A;for(var f=0,x=0,b=0;b<A.length;++b){var E=A[b];f+=E.chunkSize(),x+=E.height,E.parent=this}this.size=f,this.height=x,this.parent=null}kh.prototype={chunkSize:function(){return this.size},removeInner:function(A,f){this.size-=f;for(var x=0;x<this.children.length;++x){var b=this.children[x],E=b.chunkSize();if(A<E){var U=Math.min(f,E-A),Y=b.height;if(b.removeInner(A,U),this.height-=Y-b.height,E==U&&(this.children.splice(x--,1),b.parent=null),(f-=U)==0)break;A=0}else A-=E}if(this.size-f<25&&(this.children.length>1||!(this.children[0]instanceof ed))){var te=[];this.collapse(te),this.children=[new ed(te)],this.children[0].parent=this}},collapse:function(A){for(var f=0;f<this.children.length;++f)this.children[f].collapse(A)},insertInner:function(A,f,x){this.size+=f.length,this.height+=x;for(var b=0;b<this.children.length;++b){var E=this.children[b],U=E.chunkSize();if(A<=U){if(E.insertInner(A,f,x),E.lines&&E.lines.length>50){for(var Y=E.lines.length%25+25,te=Y;te<E.lines.length;){var le=new ed(E.lines.slice(te,te+=25));E.height-=le.height,this.children.splice(++b,0,le),le.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 f=A.children.splice(A.children.length-5,5),x=new kh(f);if(A.parent){A.size-=x.size,A.height-=x.height;var E=Ue(A.parent.children,A);A.parent.children.splice(E+1,0,x)}else{var b=new kh(A.children);b.parent=A,A.children=[b,x],A=b}x.parent=A.parent}while(A.children.length>10);A.parent.maybeSpill()}},iterN:function(A,f,x){for(var b=0;b<this.children.length;++b){var E=this.children[b],U=E.chunkSize();if(A<U){var Y=Math.min(f,U-A);if(E.iterN(A,Y,x))return!0;if((f-=Y)==0)break;A=0}else A-=U}}};var Hu=function(A,f,x){if(x)for(var b in x)x.hasOwnProperty(b)&&(this[b]=x[b]);this.doc=A,this.node=f};Hu.prototype.clear=function(){var A=this.doc.cm,f=this.line.widgets,x=this.line,b=ve(x);if(!(b==null||!f)){for(var E=0;E<f.length;++E)f[E]==this&&f.splice(E--,1);f.length||(x.widgets=null);var U=eu(this);qi(x,Math.max(0,x.height-U)),A&&(Qa(A,function(){Vm(A,x,-U),Vs(A,b,"widget")}),No(A,"lineWidgetCleared",A,this,b))}},Hu.prototype.changed=function(){var A=this,f=this.height,x=this.doc.cm,b=this.line;this.height=null;var E=eu(this)-f;E&&(Hr(this.doc,b)||qi(b,b.height+E),x&&Qa(x,function(){x.curOp.forceUpdate=!0,Vm(x,b,E),No(x,"lineWidgetChanged",x,A,ve(b))}))},ze(Hu);function Vm(A,f,x){Io(f)<(A.curOp&&A.curOp.scrollTop||A.doc.scrollTop)&&Mh(A,x)}function Ih(A,f,x,b){var E=new Hu(A,x,b),U=A.cm;return U&&E.noHScroll&&(U.display.alignWidgets=!0),Jc(A,f,"widget",function(Y){var te=Y.widgets||(Y.widgets=[]);if(E.insertAt==null?te.push(E):te.splice(Math.min(te.length,Math.max(0,E.insertAt)),0,E),E.line=Y,U&&!Hr(A,Y)){var le=Io(Y)<A.scrollTop;qi(Y,Y.height+eu(E)),le&&Mh(U,E.height),U.curOp.forceUpdate=!0}return!0}),U&&No(U,"lineWidgetAdded",U,E,typeof f=="number"?f:ve(f)),E}var Th=0,ru=function(A,f){this.lines=[],this.type=f,this.doc=A,this.id=++Th};ru.prototype.clear=function(){if(!this.explicitlyCleared){var A=this.doc.cm,f=A&&!A.curOp;if(f&&$u(A),Be(this,"clear")){var x=this.find();x&&No(this,"clear",x.from,x.to)}for(var b=null,E=null,U=0;U<this.lines.length;++U){var Y=this.lines[U],te=Do(Y.markedSpans,this);A&&!this.collapsed?Vs(A,ve(Y),"text"):A&&(te.to!=null&&(E=ve(Y)),te.from!=null&&(b=ve(Y))),Y.markedSpans=gu(Y.markedSpans,te),te.from==null&&this.collapsed&&!Hr(this.doc,Y)&&A&&qi(Y,la(A.display))}if(A&&this.collapsed&&!A.options.lineWrapping)for(var le=0;le<this.lines.length;++le){var ge=yr(this.lines[le]),Qe=wo(ge);Qe>A.display.maxLineLength&&(A.display.maxLine=ge,A.display.maxLineLength=Qe,A.display.maxLineChanged=!0)}b!=null&&A&&this.collapsed&&Da(A,b,E+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,A&&$a(A.doc)),A&&No(A,"markerCleared",A,this,b,E),f&&mA(A),this.parent&&this.parent.clear()}},ru.prototype.find=function(A,f){A==null&&this.type=="bookmark"&&(A=1);for(var x,b,E=0;E<this.lines.length;++E){var U=this.lines[E],Y=Do(U.markedSpans,this);if(Y.from!=null&&(x=Ft(f?U:ve(U),Y.from),A==-1))return x;if(Y.to!=null&&(b=Ft(f?U:ve(U),Y.to),A==1))return b}return x&&{from:x,to:b}},ru.prototype.changed=function(){var A=this,f=this.find(-1,!0),x=this,b=this.doc.cm;!f||!b||Qa(b,function(){var E=f.line,U=ve(f.line),Y=Yc(b,U);if(Y&&(bh(Y),b.curOp.selectionChanged=b.curOp.forceUpdate=!0),b.curOp.updateMaxLine=!0,!Hr(x.doc,E)&&x.height!=null){var te=x.height;x.height=null;var le=eu(x)-te;le&&qi(E,E.height+le)}No(b,"markerChanged",b,A)})},ru.prototype.attachLine=function(A){if(!this.lines.length&&this.doc.cm){var f=this.doc.cm.curOp;(!f.maybeHiddenMarkers||Ue(f.maybeHiddenMarkers,this)==-1)&&(f.maybeUnhiddenMarkers||(f.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(A)},ru.prototype.detachLine=function(A){if(this.lines.splice(Ue(this.lines,A),1),!this.lines.length&&this.doc.cm){var f=this.doc.cm.curOp;(f.maybeHiddenMarkers||(f.maybeHiddenMarkers=[])).push(this)}},ze(ru);function Ud(A,f,x,b,E){if(b&&b.shared)return k1(A,f,x,b,E);if(A.cm&&!A.cm.curOp)return lo(A.cm,Ud)(A,f,x,b,E);var U=new ru(A,E),Y=Cn(f,x);if(b&&Me(b,U,!1),Y>0||Y==0&&U.clearWhenEmpty!==!1)return U;if(U.replacedWith&&(U.collapsed=!0,U.widgetNode=Bt("span",[U.replacedWith],"CodeMirror-widget"),b.handleMouseEvents||U.widgetNode.setAttribute("cm-ignore-events","true"),b.insertLeft&&(U.widgetNode.insertLeft=!0)),U.collapsed){if(Ur(A,f.line,f,x,U)||f.line!=x.line&&Ur(A,x.line,f,x,U))throw new Error("Inserting collapsed marker partially overlapping an existing one");ss()}U.addToHistory&&ri(A,{from:f,to:x,origin:"markText"},A.sel,NaN);var te=f.line,le=A.cm,ge;if(A.iter(te,x.line+1,function(Je){le&&U.collapsed&&!le.options.lineWrapping&&yr(Je)==le.display.maxLine&&(ge=!0),U.collapsed&&te!=f.line&&qi(Je,0),vl(Je,new ll(U,te==f.line?f.ch:null,te==x.line?x.ch:null),A.cm&&A.cm.curOp),++te}),U.collapsed&&A.iter(f.line,x.line+1,function(Je){Hr(A,Je)&&qi(Je,0)}),U.clearOnEnter&&Kt(U,"beforeCursorEnter",function(){return U.clear()}),U.readOnly&&(Uu(),(A.history.done.length||A.history.undone.length)&&A.clearHistory()),U.collapsed&&(U.id=++Th,U.atomic=!0),le){if(ge&&(le.curOp.updateMaxLine=!0),U.collapsed)Da(le,f.line,x.line+1);else if(U.className||U.startStyle||U.endStyle||U.css||U.attributes||U.title)for(var Qe=f.line;Qe<=x.line;Qe++)Vs(le,Qe,"text");U.atomic&&$a(le.doc),No(le,"markerAdded",le,U)}return U}var Rd=function(A,f){this.markers=A,this.primary=f;for(var x=0;x<A.length;++x)A[x].parent=this};Rd.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var A=0;A<this.markers.length;++A)this.markers[A].clear();No(this,"clear")}},Rd.prototype.find=function(A,f){return this.primary.find(A,f)},ze(Rd);function k1(A,f,x,b,E){b=Me(b),b.shared=!1;var U=[Ud(A,f,x,b,E)],Y=U[0],te=b.widgetNode;return bn(A,function(le){te&&(b.widgetNode=te.cloneNode(!0)),U.push(Ud(le,Or(le,f),Or(le,x),b,E));for(var ge=0;ge<le.linked.length;++ge)if(le.linked[ge].isParent)return;Y=vn(U)}),new Rd(U,Y)}function Al(A){return A.findMarks(Ft(A.first,0),A.clipPos(Ft(A.lastLine())),function(f){return f.parent})}function zd(A,f){for(var x=0;x<f.length;x++){var b=f[x],E=b.find(),U=A.clipPos(E.from),Y=A.clipPos(E.to);if(Cn(U,Y)){var te=Ud(A,U,Y,b.primary,b.primary.type);b.markers.push(te),te.parent=b}}}function Zm(A){for(var f=function(b){var E=A[b],U=[E.primary.doc];bn(E.primary.doc,function(le){return U.push(le)});for(var Y=0;Y<E.markers.length;Y++){var te=E.markers[Y];Ue(U,te.doc)==-1&&(te.parent=null,E.markers.splice(Y--,1))}},x=0;x<A.length;x++)f(x)}var Kp=0,xs=function(A,f,x,b,E){if(!(this instanceof xs))return new xs(A,f,x,b,E);x==null&&(x=0),kh.call(this,[new ed([new Ll("",null)])]),this.first=x,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=x;var U=Ft(x,0);this.sel=Ge(U),this.history=new xr(null),this.id=++Kp,this.modeOption=f,this.lineSep=b,this.direction=E=="rtl"?"rtl":"ltr",this.extend=!1,typeof A=="string"&&(A=this.splitLines(A)),An(this,{from:U,to:U,text:A}),Pi(this,Ge(U),bt)};xs.prototype=Gr(kh.prototype,{constructor:xs,iter:function(A,f,x){x?this.iterN(A-this.first,f-A,x):this.iterN(this.first,this.first+this.size,A)},insert:function(A,f){for(var x=0,b=0;b<f.length;++b)x+=f[b].height;this.insertInner(A-this.first,f,x)},remove:function(A,f){this.removeInner(A-this.first,f)},getValue:function(A){var f=io(this,this.first,this.first+this.size);return A===!1?f:f.join(A||this.lineSeparator())},setValue:va(function(A){var f=Ft(this.first,0),x=this.first+this.size-1;nu(this,{from:f,to:Ft(x,Wn(this,x).text.length),text:this.splitLines(A),origin:"setValue",full:!0},!0),this.cm&&ua(this.cm,0,0),Pi(this,Ge(f),bt)}),replaceRange:function(A,f,x,b){f=Or(this,f),x=x?Or(this,x):f,qu(this,A,f,x,b)},getRange:function(A,f,x){var b=eo(this,Or(this,A),Or(this,f));return x===!1?b:x===""?b.join(""):b.join(x||this.lineSeparator())},getLine:function(A){var f=this.getLineHandle(A);return f&&f.text},getLineHandle:function(A){if(Jt(this,A))return Wn(this,A)},getLineNumber:function(A){return ve(A)},getLineHandleVisualStart:function(A){return typeof A=="number"&&(A=Wn(this,A)),yr(A)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(A){return Or(this,A)},getCursor:function(A){var f=this.sel.primary(),x;return A==null||A=="head"?x=f.head:A=="anchor"?x=f.anchor:A=="end"||A=="to"||A===!1?x=f.to():x=f.from(),x},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:va(function(A,f,x){Mu(this,Or(this,typeof A=="number"?Ft(A,f||0):A),null,x)}),setSelection:va(function(A,f,x){Mu(this,Or(this,A),Or(this,f||A),x)}),extendSelection:va(function(A,f,x){jl(this,Or(this,A),f&&Or(this,f),x)}),extendSelections:va(function(A,f){zA(this,Ks(this,A),f)}),extendSelectionsBy:va(function(A,f){var x=Xn(this.sel.ranges,A);zA(this,Ks(this,x),f)}),setSelections:va(function(A,f,x){if(A.length){for(var b=[],E=0;E<A.length;E++)b[E]=new Re(Or(this,A[E].anchor),Or(this,A[E].head||A[E].anchor));f==null&&(f=Math.min(A.length-1,this.sel.primIndex)),Pi(this,$e(this.cm,b,f),x)}}),addSelection:va(function(A,f,x){var b=this.sel.ranges.slice(0);b.push(new Re(Or(this,A),Or(this,f||A))),Pi(this,$e(this.cm,b,b.length-1),x)}),getSelection:function(A){for(var f=this.sel.ranges,x,b=0;b<f.length;b++){var E=eo(this,f[b].from(),f[b].to());x=x?x.concat(E):E}return A===!1?x:x.join(A||this.lineSeparator())},getSelections:function(A){for(var f=[],x=this.sel.ranges,b=0;b<x.length;b++){var E=eo(this,x[b].from(),x[b].to());A!==!1&&(E=E.join(A||this.lineSeparator())),f[b]=E}return f},replaceSelection:function(A,f,x){for(var b=[],E=0;E<this.sel.ranges.length;E++)b[E]=A;this.replaceSelections(b,f,x||"+input")},replaceSelections:va(function(A,f,x){for(var b=[],E=this.sel,U=0;U<E.ranges.length;U++){var Y=E.ranges[U];b[U]={from:Y.from(),to:Y.to(),text:this.splitLines(A[U]),origin:x}}for(var te=f&&f!="end"&&$t(this,b,f),le=b.length-1;le>=0;le--)nu(this,b[le]);te?Lo(this,te):this.cm&&so(this.cm)}),undo:va(function(){Xs(this,"undo")}),redo:va(function(){Xs(this,"redo")}),undoSelection:va(function(){Xs(this,"undo",!0)}),redoSelection:va(function(){Xs(this,"redo",!0)}),setExtending:function(A){this.extend=A},getExtending:function(){return this.extend},historySize:function(){for(var A=this.history,f=0,x=0,b=0;b<A.done.length;b++)A.done[b].ranges||++f;for(var E=0;E<A.undone.length;E++)A.undone[E].ranges||++x;return{undo:f,redo:x}},clearHistory:function(){var A=this;this.history=new xr(this.history),bn(this,function(f){return f.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:Ta(this.history.done),undone:Ta(this.history.undone)}},setHistory:function(A){var f=this.history=new xr(this.history);f.done=Ta(A.done.slice(0),null,!0),f.undone=Ta(A.undone.slice(0),null,!0)},setGutterMarker:va(function(A,f,x){return Jc(this,A,"gutter",function(b){var E=b.gutterMarkers||(b.gutterMarkers={});return E[f]=x,!x&&X(E)&&(b.gutterMarkers=null),!0})}),clearGutter:va(function(A){var f=this;this.iter(function(x){x.gutterMarkers&&x.gutterMarkers[A]&&Jc(f,x,"gutter",function(){return x.gutterMarkers[A]=null,X(x.gutterMarkers)&&(x.gutterMarkers=null),!0})})}),lineInfo:function(A){var f;if(typeof A=="number"){if(!Jt(this,A)||(f=A,A=Wn(this,A),!A))return null}else if(f=ve(A),f==null)return null;return{line:f,handle:A,text:A.text,gutterMarkers:A.gutterMarkers,textClass:A.textClass,bgClass:A.bgClass,wrapClass:A.wrapClass,widgets:A.widgets}},addLineClass:va(function(A,f,x){return Jc(this,A,f=="gutter"?"gutter":"class",function(b){var E=f=="text"?"textClass":f=="background"?"bgClass":f=="gutter"?"gutterClass":"wrapClass";if(!b[E])b[E]=x;else{if(De(x).test(b[E]))return!1;b[E]+=" "+x}return!0})}),removeLineClass:va(function(A,f,x){return Jc(this,A,f=="gutter"?"gutter":"class",function(b){var E=f=="text"?"textClass":f=="background"?"bgClass":f=="gutter"?"gutterClass":"wrapClass",U=b[E];if(U)if(x==null)b[E]=null;else{var Y=U.match(De(x));if(!Y)return!1;var te=Y.index+Y[0].length;b[E]=U.slice(0,Y.index)+(!Y.index||te==U.length?"":" ")+U.slice(te)||null}else return!1;return!0})}),addLineWidget:va(function(A,f,x){return Ih(this,A,f,x)}),removeLineWidget:function(A){A.clear()},markText:function(A,f,x){return Ud(this,Or(this,A),Or(this,f),x,x&&x.type||"range")},setBookmark:function(A,f){var x={replacedWith:f&&(f.nodeType==null?f.widget:f),insertLeft:f&&f.insertLeft,clearWhenEmpty:!1,shared:f&&f.shared,handleMouseEvents:f&&f.handleMouseEvents};return A=Or(this,A),Ud(this,A,A,x,"bookmark")},findMarksAt:function(A){A=Or(this,A);var f=[],x=Wn(this,A.line).markedSpans;if(x)for(var b=0;b<x.length;++b){var E=x[b];(E.from==null||E.from<=A.ch)&&(E.to==null||E.to>=A.ch)&&f.push(E.marker.parent||E.marker)}return f},findMarks:function(A,f,x){A=Or(this,A),f=Or(this,f);var b=[],E=A.line;return this.iter(A.line,f.line+1,function(U){var Y=U.markedSpans;if(Y)for(var te=0;te<Y.length;te++){var le=Y[te];!(le.to!=null&&E==A.line&&A.ch>=le.to||le.from==null&&E!=A.line||le.from!=null&&E==f.line&&le.from>=f.ch)&&(!x||x(le.marker))&&b.push(le.marker.parent||le.marker)}++E}),b},getAllMarks:function(){var A=[];return this.iter(function(f){var x=f.markedSpans;if(x)for(var b=0;b<x.length;++b)x[b].from!=null&&A.push(x[b].marker)}),A},posFromIndex:function(A){var f,x=this.first,b=this.lineSeparator().length;return this.iter(function(E){var U=E.text.length+b;if(U>A)return f=A,!0;A-=U,++x}),Or(this,Ft(x,f))},indexFromPos:function(A){A=Or(this,A);var f=A.ch;if(A.line<this.first||A.ch<0)return 0;var x=this.lineSeparator().length;return this.iter(this.first,A.line,function(b){f+=b.text.length+x}),f},copy:function(A){var f=new xs(io(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return f.scrollTop=this.scrollTop,f.scrollLeft=this.scrollLeft,f.sel=this.sel,f.extend=!1,A&&(f.history.undoDepth=this.history.undoDepth,f.setHistory(this.getHistory())),f},linkedDoc:function(A){A||(A={});var f=this.first,x=this.first+this.size;A.from!=null&&A.from>f&&(f=A.from),A.to!=null&&A.to<x&&(x=A.to);var b=new xs(io(this,f,x),A.mode||this.modeOption,f,this.lineSep,this.direction);return A.sharedHist&&(b.history=this.history),(this.linked||(this.linked=[])).push({doc:b,sharedHist:A.sharedHist}),b.linked=[{doc:this,isParent:!0,sharedHist:A.sharedHist}],zd(b,Al(this)),b},unlinkDoc:function(A){if(A instanceof Co&&(A=A.doc),this.linked)for(var f=0;f<this.linked.length;++f){var x=this.linked[f];if(x.doc==A){this.linked.splice(f,1),A.unlinkDoc(this),Zm(Al(this));break}}if(A.history==this.history){var b=[A.id];bn(A,function(E){return b.push(E.id)},!0),A.history=new xr(null),A.history.done=Ta(this.history.done,b),A.history.undone=Ta(this.history.undone,b)}},iterLinkedDocs:function(A){bn(this,A)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(A){return this.lineSep?A.split(this.lineSep):ar(A)},lineSeparator:function(){return this.lineSep||`
`},setDirection:va(function(A){A!="rtl"&&(A="ltr"),A!=this.direction&&(this.direction=A,this.iter(function(f){return f.order=null}),this.cm&&Tn(this.cm))})}),xs.prototype.eachLine=xs.prototype.iter;var Pp=0;function Fp(A){var f=this;if(Jm(f),!(de(f,A)||Ul(f.display,A))){tt(A),h&&(Pp=+new Date);var x=wl(f,A,!0),b=A.dataTransfer.files;if(!(!x||f.isReadOnly()))if(b&&b.length&&window.FileReader&&window.File)for(var E=b.length,U=Array(E),Y=0,te=function(){++Y==E&&lo(f,function(){x=Or(f.doc,x);var yt={from:x,to:x,text:f.doc.splitLines(U.filter(function(zt){return zt!=null}).join(f.doc.lineSeparator())),origin:"paste"};nu(f.doc,yt),Lo(f.doc,Ge(Or(f.doc,x),Or(f.doc,ht(yt))))})()},le=function(yt,zt){if(f.options.allowDropFileTypes&&Ue(f.options.allowDropFileTypes,yt.type)==-1){te();return}var hn=new FileReader;hn.onerror=function(){return te()},hn.onload=function(){var kn=hn.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(kn)){te();return}U[zt]=kn,te()},hn.readAsText(yt)},ge=0;ge<b.length;ge++)le(b[ge],ge);else{if(f.state.draggingText&&f.doc.sel.contains(x)>-1){f.state.draggingText(A),setTimeout(function(){return f.display.input.focus()},20);return}try{var Qe=A.dataTransfer.getData("Text");if(Qe){var Je;if(f.state.draggingText&&!f.state.draggingText.copy&&(Je=f.listSelections()),vo(f.doc,Ge(x,x)),Je)for(var Mt=0;Mt<Je.length;++Mt)qu(f.doc,"",Je[Mt].anchor,Je[Mt].head,"drag");f.replaceSelection(Qe,"around","paste"),f.display.input.focus()}}catch{}}}}function Xm(A,f){if(h&&(!A.state.draggingText||+new Date-Pp<100)){Ve(f);return}if(!(de(A,f)||Ul(A.display,f))&&(f.dataTransfer.setData("Text",A.getSelection()),f.dataTransfer.effectAllowed="copyMove",f.dataTransfer.setDragImage&&!J)){var x=be("img",null,null,"position: fixed; left: 0; top: 0;");x.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",L&&(x.width=x.height=1,A.display.wrapper.appendChild(x),x._top=x.offsetTop),f.dataTransfer.setDragImage(x,0,0),L&&x.parentNode.removeChild(x)}}function Gi(A,f){var x=wl(A,f);if(x){var b=document.createDocumentFragment();hc(A,x,b),A.display.dragCursor||(A.display.dragCursor=be("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),A.display.lineSpace.insertBefore(A.display.dragCursor,A.display.cursorDiv)),nt(A.display.dragCursor,b)}}function Jm(A){A.display.dragCursor&&(A.display.lineSpace.removeChild(A.display.dragCursor),A.display.dragCursor=null)}function e0(A){if(document.getElementsByClassName){for(var f=document.getElementsByClassName("CodeMirror"),x=[],b=0;b<f.length;b++){var E=f[b].CodeMirror;E&&x.push(E)}x.length&&x[0].operation(function(){for(var U=0;U<x.length;U++)A(x[U])})}}var Kh=!1;function Dp(){Kh||(I1(),Kh=!0)}function I1(){var A;Kt(window,"resize",function(){A==null&&(A=setTimeout(function(){A=null,e0(t0)},100))}),Kt(window,"blur",function(){return e0(fc)})}function t0(A){var f=A.display;f.cachedCharWidth=f.cachedTextHeight=f.cachedPaddingH=null,f.scrollbarsClipped=!1,A.setSize()}for(var La={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"},cl=0;cl<10;cl++)La[cl+48]=La[cl+96]=String(cl);for(var td=65;td<=90;td++)La[td]=String.fromCharCode(td);for(var jd=1;jd<=12;jd++)La[jd+111]=La[jd+63235]="F"+jd;var gA={};gA.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"},gA.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"},gA.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"},gA.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"]},gA.default=me?gA.macDefault:gA.pcDefault;function T1(A){var f=A.split(/-(?!$)/);A=f[f.length-1];for(var x,b,E,U,Y=0;Y<f.length-1;Y++){var te=f[Y];if(/^(cmd|meta|m)$/i.test(te))U=!0;else if(/^a(lt)?$/i.test(te))x=!0;else if(/^(c|ctrl|control)$/i.test(te))b=!0;else if(/^s(hift)?$/i.test(te))E=!0;else throw new Error("Unrecognized modifier name: "+te)}return x&&(A="Alt-"+A),b&&(A="Ctrl-"+A),U&&(A="Cmd-"+A),E&&(A="Shift-"+A),A}function Su(A){var f={};for(var x in A)if(A.hasOwnProperty(x)){var b=A[x];if(/^(name|fallthrough|(de|at)tach)$/.test(x))continue;if(b=="..."){delete A[x];continue}for(var E=Xn(x.split(" "),T1),U=0;U<E.length;U++){var Y=void 0,te=void 0;U==E.length-1?(te=E.join(" "),Y=b):(te=E.slice(0,U+1).join(" "),Y="...");var le=f[te];if(!le)f[te]=Y;else if(le!=Y)throw new Error("Inconsistent bindings for "+te)}delete A[x]}for(var ge in f)A[ge]=f[ge];return A}function Eu(A,f,x,b){f=Ph(f);var E=f.call?f.call(A,b):f[A];if(E===!1)return"nothing";if(E==="...")return"multi";if(E!=null&&x(E))return"handled";if(f.fallthrough){if(Object.prototype.toString.call(f.fallthrough)!="[object Array]")return Eu(A,f.fallthrough,x,b);for(var U=0;U<f.fallthrough.length;U++){var Y=Eu(A,f.fallthrough[U],x,b);if(Y)return Y}}}function Lp(A){var f=typeof A=="string"?A:La[A.keyCode];return f=="Ctrl"||f=="Alt"||f=="Shift"||f=="Mod"}function Rf(A,f,x){var b=A;return f.altKey&&b!="Alt"&&(A="Alt-"+A),(ye?f.metaKey:f.ctrlKey)&&b!="Ctrl"&&(A="Ctrl-"+A),(ye?f.ctrlKey:f.metaKey)&&b!="Mod"&&(A="Cmd-"+A),!x&&f.shiftKey&&b!="Shift"&&(A="Shift-"+A),A}function nd(A,f){if(L&&A.keyCode==34&&A.char)return!1;var x=La[A.keyCode];return x==null||A.altGraphKey?!1:(A.keyCode==3&&A.code&&(x=A.code),Rf(x,A,f))}function Ph(A){return typeof A=="string"?gA[A]:A}function iu(A,f){for(var x=A.doc.sel.ranges,b=[],E=0;E<x.length;E++){for(var U=f(x[E]);b.length&&Cn(U.from,vn(b).to)<=0;){var Y=b.pop();if(Cn(Y.from,U.from)<0){U.from=Y.from;break}}b.push(U)}Qa(A,function(){for(var te=b.length-1;te>=0;te--)qu(A.doc,"",b[te].from,b[te].to,"+delete");so(A)})}function rd(A,f,x){var b=At(A.text,f+x,x);return b<0||b>A.text.length?null:b}function zf(A,f,x){var b=rd(A,f.ch,x);return b==null?null:new Ft(f.line,b,x<0?"after":"before")}function jf(A,f,x,b,E){if(A){f.doc.direction=="rtl"&&(E=-E);var U=En(x,f.doc.direction);if(U){var Y=E<0?vn(U):U[0],te=E<0==(Y.level==1),le=te?"after":"before",ge;if(Y.level>0||f.doc.direction=="rtl"){var Qe=Rl(f,x);ge=E<0?x.text.length-1:0;var Je=bl(f,Qe,ge).top;ge=St(function(Mt){return bl(f,Qe,Mt).top==Je},E<0==(Y.level==1)?Y.from:Y.to-1,ge),le=="before"&&(ge=rd(x,ge,1))}else ge=E<0?Y.to:Y.from;return new Ft(b,ge,le)}}return new Ft(b,E<0?x.text.length:0,E<0?"before":"after")}function id(A,f,x,b){var E=En(f,A.doc.direction);if(!E)return zf(f,x,b);x.ch>=f.text.length?(x.ch=f.text.length,x.sticky="before"):x.ch<=0&&(x.ch=0,x.sticky="after");var U=pn(E,x.ch,x.sticky),Y=E[U];if(A.doc.direction=="ltr"&&Y.level%2==0&&(b>0?Y.to>x.ch:Y.from<x.ch))return zf(f,x,b);var te=function(Yn,xn){return rd(f,Yn instanceof Ft?Yn.ch:Yn,xn)},le,ge=function(Yn){return A.options.lineWrapping?(le=le||Rl(A,f),yo(A,f,le,Yn)):{begin:0,end:f.text.length}},Qe=ge(x.sticky=="before"?te(x,-1):x.ch);if(A.doc.direction=="rtl"||Y.level==1){var Je=Y.level==1==b<0,Mt=te(x,Je?1:-1);if(Mt!=null&&(Je?Mt<=Y.to&&Mt<=Qe.end:Mt>=Y.from&&Mt>=Qe.begin)){var yt=Je?"before":"after";return new Ft(x.line,Mt,yt)}}var zt=function(Yn,xn,Ln){for(var sr=function(Uo,qa){return qa?new Ft(x.line,te(Uo,1),"before"):new Ft(x.line,Uo,"after")};Yn>=0&&Yn<E.length;Yn+=xn){var Kr=E[Yn],_r=xn>0==(Kr.level!=1),Ai=_r?Ln.begin:te(Ln.end,-1);if(Kr.from<=Ai&&Ai<Kr.to||(Ai=_r?Kr.from:te(Kr.to,-1),Ln.begin<=Ai&&Ai<Ln.end))return sr(Ai,_r)}},hn=zt(U+b,b,Qe);if(hn)return hn;var kn=b>0?Qe.end:te(Qe.begin,-1);return kn!=null&&!(b>0&&kn==f.text.length)&&(hn=zt(b>0?0:E.length-1,b,ge(kn)),hn)?hn:null}var Wf={selectAll:jA,singleSelection:function(A){return A.setSelection(A.getCursor("anchor"),A.getCursor("head"),bt)},killLine:function(A){return iu(A,function(f){if(f.empty()){var x=Wn(A.doc,f.head.line).text.length;return f.head.ch==x&&f.head.line<A.lastLine()?{from:f.head,to:Ft(f.head.line+1,0)}:{from:f.head,to:Ft(f.head.line,x)}}else return{from:f.from(),to:f.to()}})},deleteLine:function(A){return iu(A,function(f){return{from:Ft(f.from().line,0),to:Or(A.doc,Ft(f.to().line+1,0))}})},delLineLeft:function(A){return iu(A,function(f){return{from:Ft(f.from().line,0),to:f.from()}})},delWrappedLineLeft:function(A){return iu(A,function(f){var x=A.charCoords(f.head,"div").top+5,b=A.coordsChar({left:0,top:x},"div");return{from:b,to:f.from()}})},delWrappedLineRight:function(A){return iu(A,function(f){var x=A.charCoords(f.head,"div").top+5,b=A.coordsChar({left:A.display.lineDiv.offsetWidth+100,top:x},"div");return{from:f.from(),to:b}})},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(Ft(A.firstLine(),0))},goDocEnd:function(A){return A.extendSelection(Ft(A.lastLine()))},goLineStart:function(A){return A.extendSelectionsBy(function(f){return Cc(A,f.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(A){return A.extendSelectionsBy(function(f){return n0(A,f.head)},{origin:"+move",bias:1})},goLineEnd:function(A){return A.extendSelectionsBy(function(f){return K1(A,f.head.line)},{origin:"+move",bias:-1})},goLineRight:function(A){return A.extendSelectionsBy(function(f){var x=A.cursorCoords(f.head,"div").top+5;return A.coordsChar({left:A.display.lineDiv.offsetWidth+100,top:x},"div")},Rt)},goLineLeft:function(A){return A.extendSelectionsBy(function(f){var x=A.cursorCoords(f.head,"div").top+5;return A.coordsChar({left:0,top:x},"div")},Rt)},goLineLeftSmart:function(A){return A.extendSelectionsBy(function(f){var x=A.cursorCoords(f.head,"div").top+5,b=A.coordsChar({left:0,top:x},"div");return b.ch<A.getLine(b.line).search(/\S/)?n0(A,f.head):b},Rt)},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 f=[],x=A.listSelections(),b=A.options.tabSize,E=0;E<x.length;E++){var U=x[E].from(),Y=fe(A.getLine(U.line),U.ch,b);f.push(mn(b-Y%b))}A.replaceSelections(f)},defaultTab:function(A){A.somethingSelected()?A.indentSelection("add"):A.execCommand("insertTab")},transposeChars:function(A){return Qa(A,function(){for(var f=A.listSelections(),x=[],b=0;b<f.length;b++)if(f[b].empty()){var E=f[b].head,U=Wn(A.doc,E.line).text;if(U){if(E.ch==U.length&&(E=new Ft(E.line,E.ch-1)),E.ch>0)E=new Ft(E.line,E.ch+1),A.replaceRange(U.charAt(E.ch-1)+U.charAt(E.ch-2),Ft(E.line,E.ch-2),E,"+transpose");else if(E.line>A.doc.first){var Y=Wn(A.doc,E.line-1).text;Y&&(E=new Ft(E.line,1),A.replaceRange(U.charAt(0)+A.doc.lineSeparator()+Y.charAt(Y.length-1),Ft(E.line-1,Y.length-1),E,"+transpose"))}}x.push(new Re(E,E))}A.setSelections(x)})},newlineAndIndent:function(A){return Qa(A,function(){for(var f=A.listSelections(),x=f.length-1;x>=0;x--)A.replaceRange(A.doc.lineSeparator(),f[x].anchor,f[x].head,"+input");f=A.listSelections();for(var b=0;b<f.length;b++)A.indentLine(f[b].from().line,null,!0);so(A)})},openLine:function(A){return A.replaceSelection(`
`,"start")},toggleOverwrite:function(A){return A.toggleOverwrite()}};function Cc(A,f){var x=Wn(A.doc,f),b=yr(x);return b!=x&&(f=ve(b)),jf(!0,A,b,f,1)}function K1(A,f){var x=Wn(A.doc,f),b=Ir(x);return b!=x&&(f=ve(b)),jf(!0,A,x,f,-1)}function n0(A,f){var x=Cc(A,f.line),b=Wn(A.doc,x.line),E=En(b,A.doc.direction);if(!E||E[0].level==0){var U=Math.max(x.ch,b.text.search(/\S/)),Y=f.line==x.line&&f.ch<=U&&f.ch;return Ft(x.line,Y?0:U,x.sticky)}return x}function od(A,f,x){if(typeof f=="string"&&(f=Wf[f],!f))return!1;A.display.input.ensurePolled();var b=A.display.shift,E=!1;try{A.isReadOnly()&&(A.state.suppressEdits=!0),x&&(A.display.shift=!1),E=f(A)!=it}finally{A.display.shift=b,A.state.suppressEdits=!1}return E}function iv(A,f,x){for(var b=0;b<A.state.keyMaps.length;b++){var E=Eu(f,A.state.keyMaps[b],x,A);if(E)return E}return A.options.extraKeys&&Eu(f,A.options.extraKeys,x,A)||Eu(f,A.options.keyMap,x,A)}var Fh=new xe;function Nf(A,f,x,b){var E=A.state.keySeq;if(E){if(Lp(f))return"handled";if(/\'$/.test(f)?A.state.keySeq=null:Fh.set(50,function(){A.state.keySeq==E&&(A.state.keySeq=null,A.display.input.reset())}),Ca(A,E+" "+f,x,b))return!0}return Ca(A,f,x,b)}function Ca(A,f,x,b){var E=iv(A,f,b);return E=="multi"&&(A.state.keySeq=f),E=="handled"&&No(A,"keyHandled",A,f,x),(E=="handled"||E=="multi")&&(tt(x),Nu(A)),!!E}function Dh(A,f){var x=nd(f,!0);return x?f.shiftKey&&!A.state.keySeq?Nf(A,"Shift-"+x,f,function(b){return od(A,b,!0)})||Nf(A,x,f,function(b){if(typeof b=="string"?/^go[A-Z]/.test(b):b.motion)return od(A,b)}):Nf(A,x,f,function(b){return od(A,b)}):!1}function P1(A,f,x){return Nf(A,"'"+x+"'",f,function(b){return od(A,b,!0)})}var Wd=null;function Lh(A){var f=this;if(!(A.target&&A.target!=f.display.input.getField())&&(f.curOp.focus=jt(gt(f)),!de(f,A))){h&&g<11&&A.keyCode==27&&(A.returnValue=!1);var x=A.keyCode;f.display.shift=x==16||A.shiftKey;var b=Dh(f,A);L&&(Wd=b?x:null,!b&&x==88&&!jr&&(me?A.metaKey:A.ctrlKey)&&f.replaceSelection("",null,"cut")),i&&!me&&!b&&x==46&&A.shiftKey&&!A.ctrlKey&&document.execCommand&&document.execCommand("cut"),x==18&&!/\bCodeMirror-crosshair\b/.test(f.display.lineDiv.className)&&Js(f)}}function Js(A){var f=A.display.lineDiv;Xe(f,"CodeMirror-crosshair");function x(b){(b.keyCode==18||!b.altKey)&&(He(f,"CodeMirror-crosshair"),Fn(document,"keyup",x),Fn(document,"mouseover",x))}Kt(document,"keyup",x),Kt(document,"mouseover",x)}function Vu(A){A.keyCode==16&&(this.doc.sel.shift=!1),de(this,A)}function r0(A){var f=this;if(!(A.target&&A.target!=f.display.input.getField())&&!(Ul(f.display,A)||de(f,A)||A.ctrlKey&&!A.altKey||me&&A.metaKey)){var x=A.keyCode,b=A.charCode;if(L&&x==Wd){Wd=null,tt(A);return}if(!(L&&(!A.which||A.which<10)&&Dh(f,A))){var E=String.fromCharCode(b??x);E!="\b"&&(P1(f,A,E)||f.display.input.onKeyPress(A))}}}var Gf=400,ad=function(A,f,x){this.time=A,this.pos=f,this.button=x};ad.prototype.compare=function(A,f,x){return this.time+Gf>A&&Cn(f,this.pos)==0&&x==this.button};var Zu,Nd;function F1(A,f){var x=+new Date;return Nd&&Nd.compare(x,A,f)?(Zu=Nd=null,"triple"):Zu&&Zu.compare(x,A,f)?(Nd=new ad(x,A,f),Zu=null,"double"):(Zu=new ad(x,A,f),Nd=null,"single")}function i0(A){var f=this,x=f.display;if(!(de(f,A)||x.activeTouch&&x.input.supportsTouch())){if(x.input.ensurePolled(),x.shift=A.shiftKey,Ul(x,A)){C||(x.scroller.draggable=!1,setTimeout(function(){return x.scroller.draggable=!0},100));return}if(!Qd(f,A)){var b=wl(f,A),E=Xt(A),U=b?F1(b,E):"single";It(f).focus(),E==1&&f.state.selectingText&&f.state.selectingText(A),!(b&&Uh(f,E,b,U,A))&&(E==1?b?Gd(f,b,U,A):xt(A)==x.scroller&&tt(A):E==2?(b&&jl(f.doc,b),setTimeout(function(){return x.input.focus()},20)):E==3&&(Oe?f.display.input.onContextMenu(A):UA(f)))}}}function Uh(A,f,x,b,E){var U="Click";return b=="double"?U="Double"+U:b=="triple"&&(U="Triple"+U),U=(f==1?"Left":f==2?"Middle":"Right")+U,Nf(A,Rf(U,E),E,function(Y){if(typeof Y=="string"&&(Y=Wf[Y]),!Y)return!1;var te=!1;try{A.isReadOnly()&&(A.state.suppressEdits=!0),te=Y(A,x)!=it}finally{A.state.suppressEdits=!1}return te})}function Rh(A,f,x){var b=A.getOption("configureMouse"),E=b?b(A,f,x):{};if(E.unit==null){var U=he?x.shiftKey&&x.metaKey:x.altKey;E.unit=U?"rectangle":f=="single"?"char":f=="double"?"word":"line"}return(E.extend==null||A.doc.extend)&&(E.extend=A.doc.extend||x.shiftKey),E.addNew==null&&(E.addNew=me?x.metaKey:x.ctrlKey),E.moveOnDrag==null&&(E.moveOnDrag=!(me?x.altKey:x.ctrlKey)),E}function Gd(A,f,x,b){h?setTimeout(Lt(xu,A),0):A.curOp.focus=jt(gt(A));var E=Rh(A,x,b),U=A.doc.sel,Y;A.options.dragDrop&&Vt&&!A.isReadOnly()&&x=="single"&&(Y=U.contains(f))>-1&&(Cn((Y=U.ranges[Y]).from(),f)<0||f.xRel>0)&&(Cn(Y.to(),f)>0||f.xRel<0)?ov(A,b,f,E):Up(A,b,f,E)}function ov(A,f,x,b){var E=A.display,U=!1,Y=lo(A,function(ge){C&&(E.scroller.draggable=!1),A.state.draggingText=!1,A.state.delayingBlurEvent&&(A.hasFocus()?A.state.delayingBlurEvent=!1:UA(A)),Fn(E.wrapper.ownerDocument,"mouseup",Y),Fn(E.wrapper.ownerDocument,"mousemove",te),Fn(E.scroller,"dragstart",le),Fn(E.scroller,"drop",Y),U||(tt(ge),b.addNew||jl(A.doc,x,null,null,b.extend),C&&!J||h&&g==9?setTimeout(function(){E.wrapper.ownerDocument.body.focus({preventScroll:!0}),E.input.focus()},20):E.input.focus())}),te=function(ge){U=U||Math.abs(f.clientX-ge.clientX)+Math.abs(f.clientY-ge.clientY)>=10},le=function(){return U=!0};C&&(E.scroller.draggable=!0),A.state.draggingText=Y,Y.copy=!b.moveOnDrag,Kt(E.wrapper.ownerDocument,"mouseup",Y),Kt(E.wrapper.ownerDocument,"mousemove",te),Kt(E.scroller,"dragstart",le),Kt(E.scroller,"drop",Y),A.state.delayingBlurEvent=!0,setTimeout(function(){return E.input.focus()},20),E.scroller.dragDrop&&E.scroller.dragDrop()}function Qf(A,f,x){if(x=="char")return new Re(f,f);if(x=="word")return A.findWordAt(f);if(x=="line")return new Re(Ft(f.line,0),Or(A.doc,Ft(f.line+1,0)));var b=x(A,f);return new Re(b.from,b.to)}function Up(A,f,x,b){h&&UA(A);var E=A.display,U=A.doc;tt(f);var Y,te,le=U.sel,ge=le.ranges;if(b.addNew&&!b.extend?(te=U.sel.contains(x),te>-1?Y=ge[te]:Y=new Re(x,x)):(Y=U.sel.primary(),te=U.sel.primIndex),b.unit=="rectangle")b.addNew||(Y=new Re(x,x)),x=wl(A,f,!0,!0),te=-1;else{var Qe=Qf(A,x,b.unit);b.extend?Y=Eo(Y,Qe.anchor,Qe.head,b.extend):Y=Qe}b.addNew?te==-1?(te=ge.length,Pi(U,$e(A,ge.concat([Y]),te),{scroll:!1,origin:"*mouse"})):ge.length>1&&ge[te].empty()&&b.unit=="char"&&!b.extend?(Pi(U,$e(A,ge.slice(0,te).concat(ge.slice(te+1)),0),{scroll:!1,origin:"*mouse"}),le=U.sel):Us(U,te,Y,Ut):(te=0,Pi(U,new Ne([Y],0),Ut),le=U.sel);var Je=x;function Mt(Ln){if(Cn(Je,Ln)!=0)if(Je=Ln,b.unit=="rectangle"){for(var sr=[],Kr=A.options.tabSize,_r=fe(Wn(U,x.line).text,x.ch,Kr),Ai=fe(Wn(U,Ln.line).text,Ln.ch,Kr),Uo=Math.min(_r,Ai),qa=Math.max(_r,Ai),ba=Math.min(x.line,Ln.line),Ua=Math.min(A.lastLine(),Math.max(x.line,Ln.line));ba<=Ua;ba++){var us=Wn(U,ba).text,As=pt(us,Uo,Kr);Uo==qa?sr.push(new Re(Ft(ba,As),Ft(ba,As))):us.length>As&&sr.push(new Re(Ft(ba,As),Ft(ba,pt(us,qa,Kr))))}sr.length||sr.push(new Re(x,x)),Pi(U,$e(A,le.ranges.slice(0,te).concat(sr),te),{origin:"*mouse",scroll:!1}),A.scrollIntoView(Ln)}else{var Ol=Y,el=Qf(A,Ln,b.unit),ws=Ol.anchor,cs;Cn(el.anchor,ws)>0?(cs=el.head,ws=Zo(Ol.from(),el.anchor)):(cs=el.anchor,ws=ei(Ol.to(),el.head));var ca=le.ranges.slice(0);ca[te]=zh(A,new Re(Or(U,ws),cs)),Pi(U,$e(A,ca,te),Ut)}}var yt=E.wrapper.getBoundingClientRect(),zt=0;function hn(Ln){var sr=++zt,Kr=wl(A,Ln,!0,b.unit=="rectangle");if(Kr)if(Cn(Kr,Je)!=0){A.curOp.focus=jt(gt(A)),Mt(Kr);var _r=wu(E,U);(Kr.line>=_r.to||Kr.line<_r.from)&&setTimeout(lo(A,function(){zt==sr&&hn(Ln)}),150)}else{var Ai=Ln.clientY<yt.top?-20:Ln.clientY>yt.bottom?20:0;Ai&&setTimeout(lo(A,function(){zt==sr&&(E.scroller.scrollTop+=Ai,hn(Ln))}),50)}}function kn(Ln){A.state.selectingText=!1,zt=1/0,Ln&&(tt(Ln),E.input.focus()),Fn(E.wrapper.ownerDocument,"mousemove",Yn),Fn(E.wrapper.ownerDocument,"mouseup",xn),U.history.lastSelOrigin=null}var Yn=lo(A,function(Ln){Ln.buttons===0||!Xt(Ln)?kn(Ln):hn(Ln)}),xn=lo(A,kn);A.state.selectingText=xn,Kt(E.wrapper.ownerDocument,"mousemove",Yn),Kt(E.wrapper.ownerDocument,"mouseup",xn)}function zh(A,f){var x=f.anchor,b=f.head,E=Wn(A.doc,x.line);if(Cn(x,b)==0&&x.sticky==b.sticky)return f;var U=En(E);if(!U)return f;var Y=pn(U,x.ch,x.sticky),te=U[Y];if(te.from!=x.ch&&te.to!=x.ch)return f;var le=Y+(te.from==x.ch==(te.level!=1)?0:1);if(le==0||le==U.length)return f;var ge;if(b.line!=x.line)ge=(b.line-x.line)*(A.doc.direction=="ltr"?1:-1)>0;else{var Qe=pn(U,b.ch,b.sticky),Je=Qe-Y||(b.ch-x.ch)*(te.level==1?-1:1);Qe==le-1||Qe==le?ge=Je<0:ge=Je>0}var Mt=U[le+(ge?-1:0)],yt=ge==(Mt.level==1),zt=yt?Mt.from:Mt.to,hn=yt?"after":"before";return x.ch==zt&&x.sticky==hn?f:new Re(new Ft(x.line,zt,hn),b)}function Rp(A,f,x,b){var E,U;if(f.touches)E=f.touches[0].clientX,U=f.touches[0].clientY;else try{E=f.clientX,U=f.clientY}catch{return!1}if(E>=Math.floor(A.display.gutters.getBoundingClientRect().right))return!1;b&&tt(f);var Y=A.display,te=Y.lineDiv.getBoundingClientRect();if(U>te.bottom||!Be(A,x))return ft(f);U-=te.top-Y.viewOffset;for(var le=0;le<A.display.gutterSpecs.length;++le){var ge=Y.gutters.childNodes[le];if(ge&&ge.getBoundingClientRect().right>=E){var Qe=Ye(A.doc,U),Je=A.display.gutterSpecs[le];return Fe(A,x,A,Qe,Je.className,f),ft(f)}}}function Qd(A,f){return Rp(A,f,"gutterClick",!0)}function zp(A,f){Ul(A.display,f)||jp(A,f)||de(A,f,"contextmenu")||Oe||A.display.input.onContextMenu(f)}function jp(A,f){return Be(A,"gutterContextMenu")?Rp(A,f,"gutterContextMenu",!1):!1}function D1(A){A.display.wrapper.className=A.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+A.options.theme.replace(/(^|\s)\s*/g," cm-s-"),tu(A)}var $d={toString:function(){return"CodeMirror.Init"}},$f={},Xu={};function o0(A){var f=A.optionHandlers;function x(b,E,U,Y){A.defaults[b]=E,U&&(f[b]=Y?function(te,le,ge){ge!=$d&&U(te,le,ge)}:U)}A.defineOption=x,A.Init=$d,x("value","",function(b,E){return b.setValue(E)},!0),x("mode",null,function(b,E){b.doc.modeOption=E,Dt(b)},!0),x("indentUnit",2,Dt,!0),x("indentWithTabs",!1),x("smartIndent",!0),x("tabSize",4,function(b){tn(b),tu(b),Da(b)},!0),x("lineSeparator",null,function(b,E){if(b.doc.lineSep=E,!!E){var U=[],Y=b.doc.first;b.doc.iter(function(le){for(var ge=0;;){var Qe=le.text.indexOf(E,ge);if(Qe==-1)break;ge=Qe+E.length,U.push(Ft(Y,Qe))}Y++});for(var te=U.length-1;te>=0;te--)qu(b.doc,E,U[te],Ft(U[te].line,U[te].ch+E.length))}}),x("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b\u200e\u200f\u2028\u2029\u202d\u202e\u2066\u2067\u2069\ufeff\ufff9-\ufffc]/g,function(b,E,U){b.state.specialChars=new RegExp(E.source+(E.test(" ")?"":"| "),"g"),U!=$d&&b.refresh()}),x("specialCharPlaceholder",Ru,function(b){return b.refresh()},!0),x("electricChars",!0),x("inputStyle",ce?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),x("spellcheck",!1,function(b,E){return b.getInputField().spellcheck=E},!0),x("autocorrect",!1,function(b,E){return b.getInputField().autocorrect=E},!0),x("autocapitalize",!1,function(b,E){return b.getInputField().autocapitalize=E},!0),x("rtlMoveVisually",!V),x("wholeLineUpdateBefore",!0),x("theme","default",function(b){D1(b),z(b)},!0),x("keyMap","default",function(b,E,U){var Y=Ph(E),te=U!=$d&&Ph(U);te&&te.detach&&te.detach(b,Y),Y.attach&&Y.attach(b,te||null)}),x("extraKeys",null),x("configureMouse",null),x("lineWrapping",!1,Yd,!0),x("gutters",[],function(b,E){b.display.gutterSpecs=M(E,b.options.lineNumbers),z(b)},!0),x("fixedGutter",!0,function(b,E){b.display.gutters.style.left=E?to(b.display)+"px":"0",b.refresh()},!0),x("coverGutterNextToScrollbar",!1,function(b){return Ml(b)},!0),x("scrollbarStyle","native",function(b){Pf(b),Ml(b),b.display.scrollbars.setScrollTop(b.doc.scrollTop),b.display.scrollbars.setScrollLeft(b.doc.scrollLeft)},!0),x("lineNumbers",!1,function(b,E){b.display.gutterSpecs=M(b.options.gutters,E),z(b)},!0),x("firstLineNumber",1,z,!0),x("lineNumberFormatter",function(b){return b},z,!0),x("showCursorWhenSelecting",!1,bu,!0),x("resetSelectionOnContextMenu",!0),x("lineWiseCopyCut",!0),x("pasteLinesPerSelection",!0),x("selectionsMayTouch",!1),x("readOnly",!1,function(b,E){E=="nocursor"&&(fc(b),b.display.input.blur()),b.display.input.readOnlyChanged(E)}),x("screenReaderLabel",null,function(b,E){E=E===""?null:E,b.display.input.screenReaderLabelChanged(E)}),x("disableInput",!1,function(b,E){E||b.display.input.reset()},!0),x("dragDrop",!0,L1),x("allowDropFileTypes",null),x("cursorBlinkRate",530),x("cursorScrollMargin",0),x("cursorHeight",1,bu,!0),x("singleCursorHeightPerLine",!0,bu,!0),x("workTime",100),x("workDelay",100),x("flattenSpans",!0,tn,!0),x("addModeClass",!1,tn,!0),x("pollInterval",100),x("undoDepth",200,function(b,E){return b.doc.history.undoDepth=E}),x("historyEventDelay",1250),x("viewportMargin",10,function(b){return b.refresh()},!0),x("maxHighlightLength",1e4,tn,!0),x("moveInputWithCursor",!0,function(b,E){E||b.display.input.resetPosition()}),x("tabindex",null,function(b,E){return b.display.input.getField().tabIndex=E||""}),x("autofocus",null),x("direction","ltr",function(b,E){return b.doc.setDirection(E)},!0),x("phrases",null)}function L1(A,f,x){var b=x&&x!=$d;if(!f!=!b){var E=A.display.dragFunctions,U=f?Kt:Fn;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 Yd(A){A.options.lineWrapping?(Xe(A.display.wrapper,"CodeMirror-wrap"),A.display.sizer.style.minWidth="",A.display.sizerWidth=null):(He(A.display.wrapper,"CodeMirror-wrap"),Ga(A)),wh(A),Da(A),tu(A),setTimeout(function(){return Ml(A)},100)}function Co(A,f){var x=this;if(!(this instanceof Co))return new Co(A,f);this.options=f=f?Me(f):{},Me($f,f,!1);var b=f.value;typeof b=="string"?b=new xs(b,f.mode,null,f.lineSeparator,f.direction):f.mode&&(b.modeOption=f.mode),this.doc=b;var E=new Co.inputStyles[f.inputStyle](this),U=this.display=new W(A,b,E,f);U.wrapper.CodeMirror=this,D1(this),f.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),Pf(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},f.autofocus&&!ce&&U.input.focus(),h&&g<11&&setTimeout(function(){return x.display.input.reset(!0)},20),U1(this),Dp(),$u(this),this.curOp.forceUpdate=!0,tr(this,b),f.autofocus&&!ce||this.hasFocus()?setTimeout(function(){x.hasFocus()&&!x.state.focused&&Tf(x)},20):fc(this);for(var Y in Xu)Xu.hasOwnProperty(Y)&&Xu[Y](this,f[Y],$d);_(this),f.finishInit&&f.finishInit(this);for(var te=0;te<Wp.length;++te)Wp[te](this);mA(this),C&&f.lineWrapping&&getComputedStyle(U.lineDiv).textRendering=="optimizelegibility"&&(U.lineDiv.style.textRendering="auto")}Co.defaults=$f,Co.optionHandlers=Xu;function U1(A){var f=A.display;Kt(f.scroller,"mousedown",lo(A,i0)),h&&g<11?Kt(f.scroller,"dblclick",lo(A,function(le){if(!de(A,le)){var ge=wl(A,le);if(!(!ge||Qd(A,le)||Ul(A.display,le))){tt(le);var Qe=A.findWordAt(ge);jl(A.doc,Qe.anchor,Qe.head)}}})):Kt(f.scroller,"dblclick",function(le){return de(A,le)||tt(le)}),Kt(f.scroller,"contextmenu",function(le){return zp(A,le)}),Kt(f.input.getField(),"contextmenu",function(le){f.scroller.contains(le.target)||zp(A,le)});var x,b={end:0};function E(){f.activeTouch&&(x=setTimeout(function(){return f.activeTouch=null},1e3),b=f.activeTouch,b.end=+new Date)}function U(le){if(le.touches.length!=1)return!1;var ge=le.touches[0];return ge.radiusX<=1&&ge.radiusY<=1}function Y(le,ge){if(ge.left==null)return!0;var Qe=ge.left-le.left,Je=ge.top-le.top;return Qe*Qe+Je*Je>20*20}Kt(f.scroller,"touchstart",function(le){if(!de(A,le)&&!U(le)&&!Qd(A,le)){f.input.ensurePolled(),clearTimeout(x);var ge=+new Date;f.activeTouch={start:ge,moved:!1,prev:ge-b.end<=300?b:null},le.touches.length==1&&(f.activeTouch.left=le.touches[0].pageX,f.activeTouch.top=le.touches[0].pageY)}}),Kt(f.scroller,"touchmove",function(){f.activeTouch&&(f.activeTouch.moved=!0)}),Kt(f.scroller,"touchend",function(le){var ge=f.activeTouch;if(ge&&!Ul(f,le)&&ge.left!=null&&!ge.moved&&new Date-ge.start<300){var Qe=A.coordsChar(f.activeTouch,"page"),Je;!ge.prev||Y(ge,ge.prev)?Je=new Re(Qe,Qe):!ge.prev.prev||Y(ge,ge.prev.prev)?Je=A.findWordAt(Qe):Je=new Re(Ft(Qe.line,0),Or(A.doc,Ft(Qe.line+1,0))),A.setSelection(Je.anchor,Je.head),A.focus(),tt(le)}E()}),Kt(f.scroller,"touchcancel",E),Kt(f.scroller,"scroll",function(){f.scroller.clientHeight&&(pc(A,f.scroller.scrollTop),Jo(A,f.scroller.scrollLeft,!0),Fe(A,"scroll",A))}),Kt(f.scroller,"mousewheel",function(le){return Ie(A,le)}),Kt(f.scroller,"DOMMouseScroll",function(le){return Ie(A,le)}),Kt(f.wrapper,"scroll",function(){return f.wrapper.scrollTop=f.wrapper.scrollLeft=0}),f.dragFunctions={enter:function(le){de(A,le)||Ve(le)},over:function(le){de(A,le)||(Gi(A,le),Ve(le))},start:function(le){return Xm(A,le)},drop:lo(A,Fp),leave:function(le){de(A,le)||Jm(A)}};var te=f.input.getField();Kt(te,"keyup",function(le){return Vu.call(A,le)}),Kt(te,"keydown",lo(A,Lh)),Kt(te,"keypress",lo(A,r0)),Kt(te,"focus",function(le){return Tf(A,le)}),Kt(te,"blur",function(le){return fc(A,le)})}var Wp=[];Co.defineInitHook=function(A){return Wp.push(A)};function jh(A,f,x,b){var E=A.doc,U;x==null&&(x="add"),x=="smart"&&(E.mode.indent?U=ia(A,f).state:x="prev");var Y=A.options.tabSize,te=Wn(E,f),le=fe(te.text,null,Y);te.stateAfter&&(te.stateAfter=null);var ge=te.text.match(/^\s*/)[0],Qe;if(!b&&!/\S/.test(te.text))Qe=0,x="not";else if(x=="smart"&&(Qe=E.mode.indent(U,te.text.slice(ge.length),te.text),Qe==it||Qe>150)){if(!b)return;x="prev"}x=="prev"?f>E.first?Qe=fe(Wn(E,f-1).text,null,Y):Qe=0:x=="add"?Qe=le+A.options.indentUnit:x=="subtract"?Qe=le-A.options.indentUnit:typeof x=="number"&&(Qe=le+x),Qe=Math.max(0,Qe);var Je="",Mt=0;if(A.options.indentWithTabs)for(var yt=Math.floor(Qe/Y);yt;--yt)Mt+=Y,Je+=" ";if(Mt<Qe&&(Je+=mn(Qe-Mt)),Je!=ge)return qu(E,Je,Ft(f,0),Ft(f,ge.length),"+input"),te.stateAfter=null,!0;for(var zt=0;zt<E.sel.ranges.length;zt++){var hn=E.sel.ranges[zt];if(hn.head.line==f&&hn.head.ch<ge.length){var kn=Ft(f,ge.length);Us(E,zt,new Re(kn,kn));break}}}var Ou=null;function Np(A){Ou=A}function a0(A,f,x,b,E){var U=A.doc;A.display.shift=!1,b||(b=U.sel);var Y=+new Date-200,te=E=="paste"||A.state.pasteIncoming>Y,le=ar(f),ge=null;if(te&&b.ranges.length>1)if(Ou&&Ou.text.join(`
`)==f){if(b.ranges.length%Ou.text.length==0){ge=[];for(var Qe=0;Qe<Ou.text.length;Qe++)ge.push(U.splitLines(Ou.text[Qe]))}}else le.length==b.ranges.length&&A.options.pasteLinesPerSelection&&(ge=Xn(le,function(Yn){return[Yn]}));for(var Je=A.curOp.updateInput,Mt=b.ranges.length-1;Mt>=0;Mt--){var yt=b.ranges[Mt],zt=yt.from(),hn=yt.to();yt.empty()&&(x&&x>0?zt=Ft(zt.line,zt.ch-x):A.state.overwrite&&!te?hn=Ft(hn.line,Math.min(Wn(U,hn.line).text.length,hn.ch+vn(le).length)):te&&Ou&&Ou.lineWise&&Ou.text.join(`
`)==le.join(`
`)&&(zt=hn=Ft(zt.line,0)));var kn={from:zt,to:hn,text:ge?ge[Mt%ge.length]:le,origin:E||(te?"paste":A.state.cutIncoming>Y?"cut":"+input")};nu(A.doc,kn),No(A,"inputRead",A,kn)}f&&!te&&Gp(A,f),so(A),A.curOp.updateInput<2&&(A.curOp.updateInput=Je),A.curOp.typing=!0,A.state.pasteIncoming=A.state.cutIncoming=-1}function NA(A,f){var x=A.clipboardData&&A.clipboardData.getData("Text");if(x)return A.preventDefault(),!f.isReadOnly()&&!f.options.disableInput&&f.hasFocus()&&Qa(f,function(){return a0(f,x,0,null,"paste")}),!0}function Gp(A,f){if(!(!A.options.electricChars||!A.options.smartIndent))for(var x=A.doc.sel,b=x.ranges.length-1;b>=0;b--){var E=x.ranges[b];if(!(E.head.ch>100||b&&x.ranges[b-1].head.line==E.head.line)){var U=A.getModeAt(E.head),Y=!1;if(U.electricChars){for(var te=0;te<U.electricChars.length;te++)if(f.indexOf(U.electricChars.charAt(te))>-1){Y=jh(A,E.head.line,"smart");break}}else U.electricInput&&U.electricInput.test(Wn(A.doc,E.head.line).text.slice(0,E.head.ch))&&(Y=jh(A,E.head.line,"smart"));Y&&No(A,"electricInput",A,E.head.line)}}}function Wh(A){for(var f=[],x=[],b=0;b<A.doc.sel.ranges.length;b++){var E=A.doc.sel.ranges[b].head.line,U={anchor:Ft(E,0),head:Ft(E+1,0)};x.push(U),f.push(A.getRange(U.anchor,U.head))}return{text:f,ranges:x}}function bc(A,f,x,b){A.setAttribute("autocorrect",x?"on":"off"),A.setAttribute("autocapitalize",b?"on":"off"),A.setAttribute("spellcheck",!!f)}function qd(){var A=be("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; min-height: 1em; outline: none"),f=be("div",[A],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return C?A.style.width="1000px":A.setAttribute("wrap","off"),q&&(A.style.border="1px solid black"),f}function Nh(A){var f=A.optionHandlers,x=A.helpers={};A.prototype={constructor:A,focus:function(){It(this).focus(),this.display.input.focus()},setOption:function(b,E){var U=this.options,Y=U[b];U[b]==E&&b!="mode"||(U[b]=E,f.hasOwnProperty(b)&&lo(this,f[b])(this,E,Y),Fe(this,"optionChange",this,b))},getOption:function(b){return this.options[b]},getDoc:function(){return this.doc},addKeyMap:function(b,E){this.state.keyMaps[E?"push":"unshift"](Ph(b))},removeKeyMap:function(b){for(var E=this.state.keyMaps,U=0;U<E.length;++U)if(E[U]==b||E[U].name==b)return E.splice(U,1),!0},addOverlay:Yr(function(b,E){var U=b.token?b:A.getMode(this.options,b);if(U.startState)throw new Error("Overlays may not be stateful.");cr(this.state.overlays,{mode:U,modeSpec:b,opaque:E&&E.opaque,priority:E&&E.priority||0},function(Y){return Y.priority}),this.state.modeGen++,Da(this)}),removeOverlay:Yr(function(b){for(var E=this.state.overlays,U=0;U<E.length;++U){var Y=E[U].modeSpec;if(Y==b||typeof b=="string"&&Y.name==b){E.splice(U,1),this.state.modeGen++,Da(this);return}}}),indentLine:Yr(function(b,E,U){typeof E!="string"&&typeof E!="number"&&(E==null?E=this.options.smartIndent?"smart":"prev":E=E?"add":"subtract"),Jt(this.doc,b)&&jh(this,b,E,U)}),indentSelection:Yr(function(b){for(var E=this.doc.sel.ranges,U=-1,Y=0;Y<E.length;Y++){var te=E[Y];if(te.empty())te.head.line>U&&(jh(this,te.head.line,b,!0),U=te.head.line,Y==this.doc.sel.primIndex&&so(this));else{var le=te.from(),ge=te.to(),Qe=Math.max(U,le.line);U=Math.min(this.lastLine(),ge.line-(ge.ch?0:1))+1;for(var Je=Qe;Je<U;++Je)jh(this,Je,b);var Mt=this.doc.sel.ranges;le.ch==0&&E.length==Mt.length&&Mt[Y].from().ch>0&&Us(this.doc,Y,new Re(le,Mt[Y].to()),bt)}}}),getTokenAt:function(b,E){return lA(this,b,E)},getLineTokens:function(b,E){return lA(this,Ft(b),E,!0)},getTokenTypeAt:function(b){b=Or(this.doc,b);var E=as(this,Wn(this.doc,b.line)),U=0,Y=(E.length-1)/2,te=b.ch,le;if(te==0)le=E[2];else for(;;){var ge=U+Y>>1;if((ge?E[ge*2-1]:0)>=te)Y=ge;else if(E[ge*2+1]<te)U=ge+1;else{le=E[ge*2+2];break}}var Qe=le?le.indexOf("overlay "):-1;return Qe<0?le:Qe==0?null:le.slice(0,Qe-1)},getModeAt:function(b){var E=this.doc.mode;return E.innerMode?A.innerMode(E,this.getTokenAt(b).state).mode:E},getHelper:function(b,E){return this.getHelpers(b,E)[0]},getHelpers:function(b,E){var U=[];if(!x.hasOwnProperty(E))return U;var Y=x[E],te=this.getModeAt(b);if(typeof te[E]=="string")Y[te[E]]&&U.push(Y[te[E]]);else if(te[E])for(var le=0;le<te[E].length;le++){var ge=Y[te[E][le]];ge&&U.push(ge)}else te.helperType&&Y[te.helperType]?U.push(Y[te.helperType]):Y[te.name]&&U.push(Y[te.name]);for(var Qe=0;Qe<Y._global.length;Qe++){var Je=Y._global[Qe];Je.pred(te,this)&&Ue(U,Je.val)==-1&&U.push(Je.val)}return U},getStateAfter:function(b,E){var U=this.doc;return b=Fa(U,b??U.first+U.size-1),ia(this,b+1,E).state},cursorCoords:function(b,E){var U,Y=this.doc.sel.primary();return b==null?U=Y.head:typeof b=="object"?U=Or(this.doc,b):U=b?Y.from():Y.to(),Wt(this,U,E||"page")},charCoords:function(b,E){return ln(this,Or(this.doc,b),E||"page")},coordsChar:function(b,E){return b=wt(this,b,E||"page"),ao(this,b.left,b.top)},lineAtHeight:function(b,E){return b=wt(this,{top:b,left:0},E||"page").top,Ye(this.doc,b+this.display.viewOffset)},heightAtLine:function(b,E,U){var Y=!1,te;if(typeof b=="number"){var le=this.doc.first+this.doc.size-1;b<this.doc.first?b=this.doc.first:b>le&&(b=le,Y=!0),te=Wn(this.doc,b)}else te=b;return _u(this,te,{top:0,left:0},E||"page",U||Y).top+(Y?this.doc.height-Io(te):0)},defaultTextHeight:function(){return la(this.display)},defaultCharWidth:function(){return Cu(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(b,E,U,Y,te){var le=this.display;b=Wt(this,Or(this.doc,b));var ge=b.bottom,Qe=b.left;if(E.style.position="absolute",E.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(E),le.sizer.appendChild(E),Y=="over")ge=b.top;else if(Y=="above"||Y=="near"){var Je=Math.max(le.wrapper.clientHeight,this.doc.height),Mt=Math.max(le.sizer.clientWidth,le.lineSpace.clientWidth);(Y=="above"||b.bottom+E.offsetHeight>Je)&&b.top>E.offsetHeight?ge=b.top-E.offsetHeight:b.bottom+E.offsetHeight<=Je&&(ge=b.bottom),Qe+E.offsetWidth>Mt&&(Qe=Mt-E.offsetWidth)}E.style.top=ge+"px",E.style.left=E.style.right="",te=="right"?(Qe=le.sizer.clientWidth-E.offsetWidth,E.style.right="0px"):(te=="left"?Qe=0:te=="middle"&&(Qe=(le.sizer.clientWidth-E.offsetWidth)/2),E.style.left=Qe+"px"),U&&Kf(this,{left:Qe,top:ge,right:Qe+E.offsetWidth,bottom:ge+E.offsetHeight})},triggerOnKeyDown:Yr(Lh),triggerOnKeyPress:Yr(r0),triggerOnKeyUp:Vu,triggerOnMouseDown:Yr(i0),execCommand:function(b){if(Wf.hasOwnProperty(b))return Wf[b].call(null,this)},triggerElectric:Yr(function(b){Gp(this,b)}),findPosH:function(b,E,U,Y){var te=1;E<0&&(te=-1,E=-E);for(var le=Or(this.doc,b),ge=0;ge<E&&(le=Zr(this.doc,le,te,U,Y),!le.hitSide);++ge);return le},moveH:Yr(function(b,E){var U=this;this.extendSelectionsBy(function(Y){return U.display.shift||U.doc.extend||Y.empty()?Zr(U.doc,Y.head,b,E,U.options.rtlMoveVisually):b<0?Y.from():Y.to()},Rt)}),deleteH:Yr(function(b,E){var U=this.doc.sel,Y=this.doc;U.somethingSelected()?Y.replaceSelection("",null,"+delete"):iu(this,function(te){var le=Zr(Y,te.head,b,E,!1);return b<0?{from:le,to:te.head}:{from:te.head,to:le}})}),findPosV:function(b,E,U,Y){var te=1,le=Y;E<0&&(te=-1,E=-E);for(var ge=Or(this.doc,b),Qe=0;Qe<E;++Qe){var Je=Wt(this,ge,"div");if(le==null?le=Je.left:Je.left=le,ge=Gh(this,Je,te,U),ge.hitSide)break}return ge},moveV:Yr(function(b,E){var U=this,Y=this.doc,te=[],le=!this.display.shift&&!Y.extend&&Y.sel.somethingSelected();if(Y.extendSelectionsBy(function(Qe){if(le)return b<0?Qe.from():Qe.to();var Je=Wt(U,Qe.head,"div");Qe.goalColumn!=null&&(Je.left=Qe.goalColumn),te.push(Je.left);var Mt=Gh(U,Je,b,E);return E=="page"&&Qe==Y.sel.primary()&&Mh(U,ln(U,Mt,"div").top-Je.top),Mt},Rt),te.length)for(var ge=0;ge<Y.sel.ranges.length;ge++)Y.sel.ranges[ge].goalColumn=te[ge]}),findWordAt:function(b){var E=this.doc,U=Wn(E,b.line).text,Y=b.ch,te=b.ch;if(U){var le=this.getHelper(b,"wordChars");(b.sticky=="before"||te==U.length)&&Y?--Y:++te;for(var ge=U.charAt(Y),Qe=Se(ge,le)?function(Je){return Se(Je,le)}:/\s/.test(ge)?function(Je){return/\s/.test(Je)}:function(Je){return!/\s/.test(Je)&&!Se(Je)};Y>0&&Qe(U.charAt(Y-1));)--Y;for(;te<U.length&&Qe(U.charAt(te));)++te}return new Re(Ft(b.line,Y),Ft(b.line,te))},toggleOverwrite:function(b){b!=null&&b==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?Xe(this.display.cursorDiv,"CodeMirror-overwrite"):He(this.display.cursorDiv,"CodeMirror-overwrite"),Fe(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==jt(gt(this))},isReadOnly:function(){return!!(this.options.readOnly||this.doc.cantEdit)},scrollTo:Yr(function(b,E){ua(this,b,E)}),getScrollInfo:function(){var b=this.display.scroller;return{left:b.scrollLeft,top:b.scrollTop,height:b.scrollHeight-vu(this)-this.display.barHeight,width:b.scrollWidth-vu(this)-this.display.barWidth,clientHeight:$c(this),clientWidth:Wu(this)}},scrollIntoView:Yr(function(b,E){b==null?(b={from:this.doc.sel.primary().head,to:null},E==null&&(E=this.options.cursorScrollMargin)):typeof b=="number"?b={from:Ft(b,0),to:null}:b.from==null&&(b={from:b,to:null}),b.to||(b.to=b.from),b.margin=E||0,b.from.line!=null?vr(this,b):RA(this,b.from,b.to,b.margin)}),setSize:Yr(function(b,E){var U=this,Y=function(le){return typeof le=="number"||/^\d+$/.test(String(le))?le+"px":le};b!=null&&(this.display.wrapper.style.width=Y(b)),E!=null&&(this.display.wrapper.style.height=Y(E)),this.options.lineWrapping&&dA(this);var te=this.display.viewFrom;this.doc.iter(te,this.display.viewTo,function(le){if(le.widgets){for(var ge=0;ge<le.widgets.length;ge++)if(le.widgets[ge].noHScroll){Vs(U,te,"widget");break}}++te}),this.curOp.forceUpdate=!0,Fe(this,"refresh",this)}),operation:function(b){return Qa(this,b)},startOperation:function(){return $u(this)},endOperation:function(){return mA(this)},refresh:Yr(function(){var b=this.display.cachedTextHeight;Da(this),this.curOp.forceUpdate=!0,tu(this),ua(this,this.doc.scrollLeft,this.doc.scrollTop),O(this.display),(b==null||Math.abs(b-la(this.display))>.5||this.options.lineWrapping)&&wh(this),Fe(this,"refresh",this)}),swapDoc:Yr(function(b){var E=this.doc;return E.cm=null,this.state.selectingText&&this.state.selectingText(),tr(this,b),tu(this),this.display.input.reset(),ua(this,b.scrollLeft,b.scrollTop),this.curOp.forceScroll=!0,No(this,"swapDoc",this,E),E}),phrase:function(b){var E=this.options.phrases;return E&&Object.prototype.hasOwnProperty.call(E,b)?E[b]:b},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}},ze(A),A.registerHelper=function(b,E,U){x.hasOwnProperty(b)||(x[b]=A[b]={_global:[]}),x[b][E]=U},A.registerGlobalHelper=function(b,E,U,Y){A.registerHelper(b,E,Y),x[b]._global.push({pred:U,val:Y})}}function Zr(A,f,x,b,E){var U=f,Y=x,te=Wn(A,f.line),le=E&&A.direction=="rtl"?-x:x;function ge(){var xn=f.line+le;return xn<A.first||xn>=A.first+A.size?!1:(f=new Ft(xn,f.ch,f.sticky),te=Wn(A,xn))}function Qe(xn){var Ln;if(b=="codepoint"){var sr=te.text.charCodeAt(f.ch+(x>0?0:-1));if(isNaN(sr))Ln=null;else{var Kr=x>0?sr>=55296&&sr<56320:sr>=56320&&sr<57343;Ln=new Ft(f.line,Math.max(0,Math.min(te.text.length,f.ch+x*(Kr?2:1))),-x)}}else E?Ln=id(A.cm,te,f,x):Ln=zf(te,f,x);if(Ln==null)if(!xn&&ge())f=jf(E,A.cm,te,f.line,le);else return!1;else f=Ln;return!0}if(b=="char"||b=="codepoint")Qe();else if(b=="column")Qe(!0);else if(b=="word"||b=="group")for(var Je=null,Mt=b=="group",yt=A.cm&&A.cm.getHelper(f,"wordChars"),zt=!0;!(x<0&&!Qe(!zt));zt=!1){var hn=te.text.charAt(f.ch)||`
`,kn=Se(hn,yt)?"w":Mt&&hn==`
`?"n":!Mt||/\s/.test(hn)?null:"p";if(Mt&&!zt&&!kn&&(kn="s"),Je&&Je!=kn){x<0&&(x=1,Qe(),f.sticky="after");break}if(kn&&(Je=kn),x>0&&!Qe(!zt))break}var Yn=vc(A,f,U,Y,!0);return ur(U,Yn)&&(Yn.hitSide=!0),Yn}function Gh(A,f,x,b){var E=A.doc,U=f.left,Y;if(b=="page"){var te=Math.min(A.display.wrapper.clientHeight,It(A).innerHeight||E(A).documentElement.clientHeight),le=Math.max(te-.5*la(A.display),3);Y=(x>0?f.bottom:f.top)+x*le}else b=="line"&&(Y=x>0?f.bottom+3:f.top-3);for(var ge;ge=ao(A,U,Y),!!ge.outside;){if(x<0?Y<=0:Y>=E.height){ge.hitSide=!0;break}Y+=x*5}return ge}var Oo=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};Oo.prototype.init=function(A){var f=this,x=this,b=x.cm,E=x.div=A.lineDiv;E.contentEditable=!0,bc(E,b.options.spellcheck,b.options.autocorrect,b.options.autocapitalize);function U(te){for(var le=te.target;le;le=le.parentNode){if(le==E)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(le.className))break}return!1}Kt(E,"paste",function(te){!U(te)||de(b,te)||NA(te,b)||g<=11&&setTimeout(lo(b,function(){return f.updateFromDOM()}),20)}),Kt(E,"compositionstart",function(te){f.composing={data:te.data,done:!1}}),Kt(E,"compositionupdate",function(te){f.composing||(f.composing={data:te.data,done:!1})}),Kt(E,"compositionend",function(te){f.composing&&(te.data!=f.composing.data&&f.readFromDOMSoon(),f.composing.done=!0)}),Kt(E,"touchstart",function(){return x.forceCompositionEnd()}),Kt(E,"input",function(){f.composing||f.readFromDOMSoon()});function Y(te){if(!(!U(te)||de(b,te))){if(b.somethingSelected())Np({lineWise:!1,text:b.getSelections()}),te.type=="cut"&&b.replaceSelection("",null,"cut");else if(b.options.lineWiseCopyCut){var le=Wh(b);Np({lineWise:!0,text:le.text}),te.type=="cut"&&b.operation(function(){b.setSelections(le.ranges,0,bt),b.replaceSelection("",null,"cut")})}else return;if(te.clipboardData){te.clipboardData.clearData();var ge=Ou.text.join(`
`);if(te.clipboardData.setData("Text",ge),te.clipboardData.getData("Text")==ge){te.preventDefault();return}}var Qe=qd(),Je=Qe.firstChild;bc(Je),b.display.lineSpace.insertBefore(Qe,b.display.lineSpace.firstChild),Je.value=Ou.text.join(`
`);var Mt=jt(at(E));ot(Je),setTimeout(function(){b.display.lineSpace.removeChild(Qe),Mt.focus(),Mt==E&&x.showPrimarySelection()},50)}}Kt(E,"copy",Y),Kt(E,"cut",Y)},Oo.prototype.screenReaderLabelChanged=function(A){A?this.div.setAttribute("aria-label",A):this.div.removeAttribute("aria-label")},Oo.prototype.prepareSelection=function(){var A=$n(this.cm,!1);return A.focus=jt(at(this.div))==this.div,A},Oo.prototype.showSelection=function(A,f){!A||!this.cm.display.view.length||((A.focus||f)&&this.showPrimarySelection(),this.showMultipleSelections(A))},Oo.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},Oo.prototype.showPrimarySelection=function(){var A=this.getSelection(),f=this.cm,x=f.doc.sel.primary(),b=x.from(),E=x.to();if(f.display.viewTo==f.display.viewFrom||b.line>=f.display.viewTo||E.line<f.display.viewFrom){A.removeAllRanges();return}var U=Rs(f,A.anchorNode,A.anchorOffset),Y=Rs(f,A.focusNode,A.focusOffset);if(!(U&&!U.bad&&Y&&!Y.bad&&Cn(Zo(U,Y),b)==0&&Cn(ei(U,Y),E)==0)){var te=f.display.view,le=b.line>=f.display.viewFrom&&sd(f,b)||{node:te[0].measure.map[2],offset:0},ge=E.line<f.display.viewTo&&sd(f,E);if(!ge){var Qe=te[te.length-1].measure,Je=Qe.maps?Qe.maps[Qe.maps.length-1]:Qe.map;ge={node:Je[Je.length-1],offset:Je[Je.length-2]-Je[Je.length-3]}}if(!le||!ge){A.removeAllRanges();return}var Mt=A.rangeCount&&A.getRangeAt(0),yt;try{yt=kt(le.node,le.offset,ge.offset,ge.node)}catch{}yt&&(!i&&f.state.focused?(A.collapse(le.node,le.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()}},Oo.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)},Oo.prototype.showMultipleSelections=function(A){nt(this.cm.display.cursorDiv,A.cursors),nt(this.cm.display.selectionDiv,A.selection)},Oo.prototype.rememberSelection=function(){var A=this.getSelection();this.lastAnchorNode=A.anchorNode,this.lastAnchorOffset=A.anchorOffset,this.lastFocusNode=A.focusNode,this.lastFocusOffset=A.focusOffset},Oo.prototype.selectionInEditor=function(){var A=this.getSelection();if(!A.rangeCount)return!1;var f=A.getRangeAt(0).commonAncestorContainer;return Yt(this.div,f)},Oo.prototype.focus=function(){this.cm.options.readOnly!="nocursor"&&((!this.selectionInEditor()||jt(at(this.div))!=this.div)&&this.showSelection(this.prepareSelection(),!0),this.div.focus())},Oo.prototype.blur=function(){this.div.blur()},Oo.prototype.getField=function(){return this.div},Oo.prototype.supportsTouch=function(){return!0},Oo.prototype.receivedFocus=function(){var A=this,f=this;this.selectionInEditor()?setTimeout(function(){return A.pollSelection()},20):Qa(this.cm,function(){return f.cm.curOp.selectionChanged=!0});function x(){f.cm.state.focused&&(f.pollSelection(),f.polling.set(f.cm.options.pollInterval,x))}this.polling.set(this.cm.options.pollInterval,x)},Oo.prototype.selectionChanged=function(){var A=this.getSelection();return A.anchorNode!=this.lastAnchorNode||A.anchorOffset!=this.lastAnchorOffset||A.focusNode!=this.lastFocusNode||A.focusOffset!=this.lastFocusOffset},Oo.prototype.pollSelection=function(){if(!(this.readDOMTimeout!=null||this.gracePeriod||!this.selectionChanged())){var A=this.getSelection(),f=this.cm;if(oe&&k&&this.cm.display.gutterSpecs.length&&Yf(A.anchorNode)){this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),this.focus();return}if(!this.composing){this.rememberSelection();var x=Rs(f,A.anchorNode,A.anchorOffset),b=Rs(f,A.focusNode,A.focusOffset);x&&b&&Qa(f,function(){Pi(f.doc,Ge(x,b),bt),(x.bad||b.bad)&&(f.curOp.selectionChanged=!0)})}}},Oo.prototype.pollContent=function(){this.readDOMTimeout!=null&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var A=this.cm,f=A.display,x=A.doc.sel.primary(),b=x.from(),E=x.to();if(b.ch==0&&b.line>A.firstLine()&&(b=Ft(b.line-1,Wn(A.doc,b.line-1).length)),E.ch==Wn(A.doc,E.line).text.length&&E.line<A.lastLine()&&(E=Ft(E.line+1,0)),b.line<f.viewFrom||E.line>f.viewTo-1)return!1;var U,Y,te;b.line==f.viewFrom||(U=DA(A,b.line))==0?(Y=ve(f.view[0].line),te=f.view[0].node):(Y=ve(f.view[U].line),te=f.view[U-1].node.nextSibling);var le=DA(A,E.line),ge,Qe;if(le==f.view.length-1?(ge=f.viewTo-1,Qe=f.lineDiv.lastChild):(ge=ve(f.view[le+1].line)-1,Qe=f.view[le+1].node.previousSibling),!te)return!1;for(var Je=A.doc.splitLines(R1(A,te,Qe,Y,ge)),Mt=eo(A.doc,Ft(Y,0),Ft(ge,Wn(A.doc,ge).text.length));Je.length>1&&Mt.length>1;)if(vn(Je)==vn(Mt))Je.pop(),Mt.pop(),ge--;else if(Je[0]==Mt[0])Je.shift(),Mt.shift(),Y++;else break;for(var yt=0,zt=0,hn=Je[0],kn=Mt[0],Yn=Math.min(hn.length,kn.length);yt<Yn&&hn.charCodeAt(yt)==kn.charCodeAt(yt);)++yt;for(var xn=vn(Je),Ln=vn(Mt),sr=Math.min(xn.length-(Je.length==1?yt:0),Ln.length-(Mt.length==1?yt:0));zt<sr&&xn.charCodeAt(xn.length-zt-1)==Ln.charCodeAt(Ln.length-zt-1);)++zt;if(Je.length==1&&Mt.length==1&&Y==b.line)for(;yt&&yt>b.ch&&xn.charCodeAt(xn.length-zt-1)==Ln.charCodeAt(Ln.length-zt-1);)yt--,zt++;Je[Je.length-1]=xn.slice(0,xn.length-zt).replace(/^\u200b+/,""),Je[0]=Je[0].slice(yt).replace(/\u200b+$/,"");var Kr=Ft(Y,yt),_r=Ft(ge,Mt.length?vn(Mt).length-zt:0);if(Je.length>1||Je[0]||Cn(Kr,_r))return qu(A.doc,Je,Kr,_r,"+input"),!0},Oo.prototype.ensurePolled=function(){this.forceCompositionEnd()},Oo.prototype.reset=function(){this.forceCompositionEnd()},Oo.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Oo.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))},Oo.prototype.updateFromDOM=function(){var A=this;(this.cm.isReadOnly()||!this.pollContent())&&Qa(this.cm,function(){return Da(A.cm)})},Oo.prototype.setUneditable=function(A){A.contentEditable="false"},Oo.prototype.onKeyPress=function(A){A.charCode==0||this.composing||(A.preventDefault(),this.cm.isReadOnly()||lo(this.cm,a0)(this.cm,String.fromCharCode(A.charCode==null?A.keyCode:A.charCode),0))},Oo.prototype.readOnlyChanged=function(A){this.div.contentEditable=String(A!="nocursor")},Oo.prototype.onContextMenu=function(){},Oo.prototype.resetPosition=function(){},Oo.prototype.needsContentAttribute=!0;function sd(A,f){var x=Yc(A,f.line);if(!x||x.hidden)return null;var b=Wn(A.doc,f.line),E=kf(x,b,f.line),U=En(b,A.doc.direction),Y="left";if(U){var te=pn(U,f.ch);Y=te%2?"right":"left"}var le=cA(E.map,f.ch,Y);return le.offset=le.collapse=="right"?le.end:le.start,le}function Yf(A){for(var f=A;f;f=f.parentNode)if(/CodeMirror-gutter-wrapper/.test(f.className))return!0;return!1}function xc(A,f){return f&&(A.bad=!0),A}function R1(A,f,x,b,E){var U="",Y=!1,te=A.doc.lineSeparator(),le=!1;function ge(yt){return function(zt){return zt.id==yt}}function Qe(){Y&&(U+=te,le&&(U+=te),Y=le=!1)}function Je(yt){yt&&(Qe(),U+=yt)}function Mt(yt){if(yt.nodeType==1){var zt=yt.getAttribute("cm-text");if(zt){Je(zt);return}var hn=yt.getAttribute("cm-marker"),kn;if(hn){var Yn=A.findMarks(Ft(b,0),Ft(E+1,0),ge(+hn));Yn.length&&(kn=Yn[0].find(0))&&Je(eo(A.doc,kn.from,kn.to).join(te));return}if(yt.getAttribute("contenteditable")=="false")return;var xn=/^(pre|div|p|li|table|br)$/i.test(yt.nodeName);if(!/^br$/i.test(yt.nodeName)&&yt.textContent.length==0)return;xn&&Qe();for(var Ln=0;Ln<yt.childNodes.length;Ln++)Mt(yt.childNodes[Ln]);/^(pre|p)$/i.test(yt.nodeName)&&(le=!0),xn&&(Y=!0)}else yt.nodeType==3&&Je(yt.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "))}for(;Mt(f),f!=x;)f=f.nextSibling,le=!1;return U}function Rs(A,f,x){var b;if(f==A.display.lineDiv){if(b=A.display.lineDiv.childNodes[x],!b)return xc(A.clipPos(Ft(A.display.viewTo-1)),!0);f=null,x=0}else for(b=f;;b=b.parentNode){if(!b||b==A.display.lineDiv)return null;if(b.parentNode&&b.parentNode==A.display.lineDiv)break}for(var E=0;E<A.display.view.length;E++){var U=A.display.view[E];if(U.node==b)return av(U,f,x)}}function av(A,f,x){var b=A.text.firstChild,E=!1;if(!f||!Yt(b,f))return xc(Ft(ve(A.line),0),!0);if(f==b&&(E=!0,f=b.childNodes[x],x=0,!f)){var U=A.rest?vn(A.rest):A.line;return xc(Ft(ve(U),U.text.length),E)}var Y=f.nodeType==3?f:null,te=f;for(!Y&&f.childNodes.length==1&&f.firstChild.nodeType==3&&(Y=f.firstChild,x&&(x=Y.nodeValue.length));te.parentNode!=b;)te=te.parentNode;var le=A.measure,ge=le.maps;function Qe(kn,Yn,xn){for(var Ln=-1;Ln<(ge?ge.length:0);Ln++)for(var sr=Ln<0?le.map:ge[Ln],Kr=0;Kr<sr.length;Kr+=3){var _r=sr[Kr+2];if(_r==kn||_r==Yn){var Ai=ve(Ln<0?A.line:A.rest[Ln]),Uo=sr[Kr]+xn;return(xn<0||_r!=kn)&&(Uo=sr[Kr+(xn?1:0)]),Ft(Ai,Uo)}}}var Je=Qe(Y,te,x);if(Je)return xc(Je,E);for(var Mt=te.nextSibling,yt=Y?Y.nodeValue.length-x:0;Mt;Mt=Mt.nextSibling){if(Je=Qe(Mt,Mt.firstChild,0),Je)return xc(Ft(Je.line,Je.ch-yt),E);yt+=Mt.textContent.length}for(var zt=te.previousSibling,hn=x;zt;zt=zt.previousSibling){if(Je=Qe(zt,zt.firstChild,-1),Je)return xc(Ft(Je.line,Je.ch+hn),E);hn+=zt.textContent.length}}var Ya=function(A){this.cm=A,this.prevInput="",this.pollingFast=!1,this.polling=new xe,this.hasSelection=!1,this.composing=null,this.resetting=!1};Ya.prototype.init=function(A){var f=this,x=this,b=this.cm;this.createField(A);var E=this.textarea;A.wrapper.insertBefore(this.wrapper,A.wrapper.firstChild),q&&(E.style.width="0px"),Kt(E,"input",function(){h&&g>=9&&f.hasSelection&&(f.hasSelection=null),x.poll()}),Kt(E,"paste",function(Y){de(b,Y)||NA(Y,b)||(b.state.pasteIncoming=+new Date,x.fastPoll())});function U(Y){if(!de(b,Y)){if(b.somethingSelected())Np({lineWise:!1,text:b.getSelections()});else if(b.options.lineWiseCopyCut){var te=Wh(b);Np({lineWise:!0,text:te.text}),Y.type=="cut"?b.setSelections(te.ranges,null,bt):(x.prevInput="",E.value=te.text.join(`
`),ot(E))}else return;Y.type=="cut"&&(b.state.cutIncoming=+new Date)}}Kt(E,"cut",U),Kt(E,"copy",U),Kt(A.scroller,"paste",function(Y){if(!(Ul(A,Y)||de(b,Y))){if(!E.dispatchEvent){b.state.pasteIncoming=+new Date,x.focus();return}var te=new Event("paste");te.clipboardData=Y.clipboardData,E.dispatchEvent(te)}}),Kt(A.lineSpace,"selectstart",function(Y){Ul(A,Y)||tt(Y)}),Kt(E,"compositionstart",function(){var Y=b.getCursor("from");x.composing&&x.composing.range.clear(),x.composing={start:Y,range:b.markText(Y,b.getCursor("to"),{className:"CodeMirror-composing"})}}),Kt(E,"compositionend",function(){x.composing&&(x.poll(),x.composing.range.clear(),x.composing=null)})},Ya.prototype.createField=function(A){this.wrapper=qd(),this.textarea=this.wrapper.firstChild;var f=this.cm.options;bc(this.textarea,f.spellcheck,f.autocorrect,f.autocapitalize)},Ya.prototype.screenReaderLabelChanged=function(A){A?this.textarea.setAttribute("aria-label",A):this.textarea.removeAttribute("aria-label")},Ya.prototype.prepareSelection=function(){var A=this.cm,f=A.display,x=A.doc,b=$n(A);if(A.options.moveInputWithCursor){var E=Wt(A,x.sel.primary().head,"div"),U=f.wrapper.getBoundingClientRect(),Y=f.lineDiv.getBoundingClientRect();b.teTop=Math.max(0,Math.min(f.wrapper.clientHeight-10,E.top+Y.top-U.top)),b.teLeft=Math.max(0,Math.min(f.wrapper.clientWidth-10,E.left+Y.left-U.left))}return b},Ya.prototype.showSelection=function(A){var f=this.cm,x=f.display;nt(x.cursorDiv,A.cursors),nt(x.selectionDiv,A.selection),A.teTop!=null&&(this.wrapper.style.top=A.teTop+"px",this.wrapper.style.left=A.teLeft+"px")},Ya.prototype.reset=function(A){if(!(this.contextMenuPending||this.composing&&A)){var f=this.cm;if(this.resetting=!0,f.somethingSelected()){this.prevInput="";var x=f.getSelection();this.textarea.value=x,f.state.focused&&ot(this.textarea),h&&g>=9&&(this.hasSelection=x)}else A||(this.prevInput=this.textarea.value="",h&&g>=9&&(this.hasSelection=null));this.resetting=!1}},Ya.prototype.getField=function(){return this.textarea},Ya.prototype.supportsTouch=function(){return!1},Ya.prototype.focus=function(){if(this.cm.options.readOnly!="nocursor"&&(!ce||jt(at(this.textarea))!=this.textarea))try{this.textarea.focus()}catch{}},Ya.prototype.blur=function(){this.textarea.blur()},Ya.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Ya.prototype.receivedFocus=function(){this.slowPoll()},Ya.prototype.slowPoll=function(){var A=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){A.poll(),A.cm.state.focused&&A.slowPoll()})},Ya.prototype.fastPoll=function(){var A=!1,f=this;f.pollingFast=!0;function x(){var b=f.poll();!b&&!A?(A=!0,f.polling.set(60,x)):(f.pollingFast=!1,f.slowPoll())}f.polling.set(20,x)},Ya.prototype.poll=function(){var A=this,f=this.cm,x=this.textarea,b=this.prevInput;if(this.contextMenuPending||this.resetting||!f.state.focused||kr(x)&&!b&&!this.composing||f.isReadOnly()||f.options.disableInput||f.state.keySeq)return!1;var E=x.value;if(E==b&&!f.somethingSelected())return!1;if(h&&g>=9&&this.hasSelection===E||me&&/[\uf700-\uf7ff]/.test(E))return f.display.input.reset(),!1;if(f.doc.sel==f.display.selForContextMenu){var U=E.charCodeAt(0);if(U==8203&&!b&&(b=""),U==8666)return this.reset(),this.cm.execCommand("undo")}for(var Y=0,te=Math.min(b.length,E.length);Y<te&&b.charCodeAt(Y)==E.charCodeAt(Y);)++Y;return Qa(f,function(){a0(f,E.slice(Y),b.length-Y,null,A.composing?"*compose":null),E.length>1e3||E.indexOf(`
`)>-1?x.value=A.prevInput="":A.prevInput=E,A.composing&&(A.composing.range.clear(),A.composing.range=f.markText(A.composing.start,f.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},Ya.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Ya.prototype.onKeyPress=function(){h&&g>=9&&(this.hasSelection=null),this.fastPoll()},Ya.prototype.onContextMenu=function(A){var f=this,x=f.cm,b=x.display,E=f.textarea;f.contextMenuPending&&f.contextMenuPending();var U=wl(x,A),Y=b.scroller.scrollTop;if(!U||L)return;var te=x.options.resetSelectionOnContextMenu;te&&x.doc.sel.contains(U)==-1&&lo(x,Pi)(x.doc,Ge(U),bt);var le=E.style.cssText,ge=f.wrapper.style.cssText,Qe=f.wrapper.offsetParent.getBoundingClientRect();f.wrapper.style.cssText="position: static",E.style.cssText=`position: absolute; width: 30px; height: 30px;
top: `+(A.clientY-Qe.top-5)+"px; left: "+(A.clientX-Qe.left-5)+`px;
z-index: 1000; background: `+(h?"rgba(255, 255, 255, .05)":"transparent")+`;
outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);`;var Je;C&&(Je=E.ownerDocument.defaultView.scrollY),b.input.focus(),C&&E.ownerDocument.defaultView.scrollTo(null,Je),b.input.reset(),x.somethingSelected()||(E.value=f.prevInput=" "),f.contextMenuPending=yt,b.selForContextMenu=x.doc.sel,clearTimeout(b.detectingSelectAll);function Mt(){if(E.selectionStart!=null){var hn=x.somethingSelected(),kn=""+(hn?E.value:"");E.value="⇚",E.value=kn,f.prevInput=hn?"":"",E.selectionStart=1,E.selectionEnd=kn.length,b.selForContextMenu=x.doc.sel}}function yt(){if(f.contextMenuPending==yt&&(f.contextMenuPending=!1,f.wrapper.style.cssText=ge,E.style.cssText=le,h&&g<9&&b.scrollbars.setScrollTop(b.scroller.scrollTop=Y),E.selectionStart!=null)){(!h||h&&g<9)&&Mt();var hn=0,kn=function(){b.selForContextMenu==x.doc.sel&&E.selectionStart==0&&E.selectionEnd>0&&f.prevInput==""?lo(x,jA)(x):hn++<10?b.detectingSelectAll=setTimeout(kn,500):(b.selForContextMenu=null,b.input.reset())};b.detectingSelectAll=setTimeout(kn,200)}}if(h&&g>=9&&Mt(),Oe){Ve(A);var zt=function(){Fn(window,"mouseup",zt),setTimeout(yt,20)};Kt(window,"mouseup",zt)}else setTimeout(yt,50)},Ya.prototype.readOnlyChanged=function(A){A||this.reset(),this.textarea.disabled=A=="nocursor",this.textarea.readOnly=!!A},Ya.prototype.setUneditable=function(){},Ya.prototype.needsContentAttribute=!1;function z1(A,f){if(f=f?Me(f):{},f.value=A.value,!f.tabindex&&A.tabIndex&&(f.tabindex=A.tabIndex),!f.placeholder&&A.placeholder&&(f.placeholder=A.placeholder),f.autofocus==null){var x=jt(at(A));f.autofocus=x==A||A.getAttribute("autofocus")!=null&&x==document.body}function b(){A.value=te.getValue()}var E;if(A.form&&(Kt(A.form,"submit",b),!f.leaveSubmitMethodAlone)){var U=A.form;E=U.submit;try{var Y=U.submit=function(){b(),U.submit=E,U.submit(),U.submit=Y}}catch{}}f.finishInit=function(le){le.save=b,le.getTextArea=function(){return A},le.toTextArea=function(){le.toTextArea=isNaN,b(),A.parentNode.removeChild(le.getWrapperElement()),A.style.display="",A.form&&(Fn(A.form,"submit",b),!f.leaveSubmitMethodAlone&&typeof A.form.submit=="function"&&(A.form.submit=E))}},A.style.display="none";var te=Co(function(le){return A.parentNode.insertBefore(le,A.nextSibling)},f);return te}function sv(A){A.off=Fn,A.on=Kt,A.wheelEventPixels=pe,A.Doc=xs,A.splitLines=ar,A.countColumn=fe,A.findColumn=pt,A.isWordChar=mi,A.Pass=it,A.signal=Fe,A.Line=Ll,A.changeEnd=ht,A.scrollbarModel=Qo,A.Pos=Ft,A.cmpPos=Cn,A.modes=ir,A.mimeModes=ui,A.resolveMode=_o,A.getMode=Jr,A.modeExtensions=xo,A.extendMode=Wa,A.copyState=Ba,A.startState=os,A.innerMode=bi,A.commands=Wf,A.keyMap=gA,A.keyName=nd,A.isModifierKey=Lp,A.lookupKey=Eu,A.normalizeKeyMap=Su,A.StringStream=hi,A.SharedTextMarker=Rd,A.TextMarker=ru,A.LineWidget=Hu,A.e_preventDefault=tt,A.e_stopPropagation=lt,A.e_stop=Ve,A.addClass=Xe,A.contains=Yt,A.rmClass=He,A.keyNames=La}o0(Co),Nh(Co);var s0="iter insert remove copy getEditor constructor".split(" ");for(var Qh in xs.prototype)xs.prototype.hasOwnProperty(Qh)&&Ue(s0,Qh)<0&&(Co.prototype[Qh]=function(A){return function(){return A.apply(this.doc,arguments)}}(xs.prototype[Qh]));return ze(xs),Co.inputStyles={textarea:Ya,contenteditable:Oo},Co.defineMode=function(A){!Co.defaults.mode&&A!="null"&&(Co.defaults.mode=A),Oi.apply(this,arguments)},Co.defineMIME=Yi,Co.defineMode("null",function(){return{token:function(A){return A.skipToEnd()}}}),Co.defineMIME("text/plain","null"),Co.defineExtension=function(A,f){Co.prototype[A]=f},Co.defineDocExtension=function(A,f){xs.prototype[A]=f},Co.fromTextArea=z1,sv(Co),Co.version="5.65.16",Co})}(tS)),tS.exports}var yme=R5();const Ic=fa(yme);(function(e,n){(function(t){t(R5())})(function(t){t.defineMode("javascript",function(r,i){var o=r.indentUnit,s=i.statementIndent,a=i.jsonld,h=i.json||a,g=i.trackScope!==!1,C=i.typescript,B=i.wordCharacters||/[\w$\xa1-\uffff]/,k=function(){function ve(fi){return{type:fi,style:"keyword"}}var Ye=ve("keyword a"),Jt=ve("keyword b"),sn=ve("keyword c"),Ft=ve("keyword d"),Cn=ve("operator"),ur={type:"atom",style:"atom"};return{if:ve("if"),while:Ye,with:Ye,else:Jt,do:Jt,try:Jt,finally:Jt,return:Ft,break:Ft,continue:Ft,new:ve("new"),delete:sn,void:sn,throw:sn,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:Cn,typeof:Cn,instanceof:Cn,true:ur,false:ur,null:ur,undefined:ur,NaN:ur,Infinity:ur,this:ve("this"),class:ve("class"),super:ve("atom"),yield:sn,export:ve("export"),import:ve("import"),extends:sn,await:sn}}(),P=/[+\-*&%=<>!?|~^@]/,L=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function J(ve){for(var Ye=!1,Jt,sn=!1;(Jt=ve.next())!=null;){if(!Ye){if(Jt=="/"&&!sn)return;Jt=="["?sn=!0:sn&&Jt=="]"&&(sn=!1)}Ye=!Ye&&Jt=="\\"}}var N,$;function q(ve,Ye,Jt){return N=ve,$=Jt,Ye}function oe(ve,Ye){var Jt=ve.next();if(Jt=='"'||Jt=="'")return Ye.tokenize=ce(Jt),Ye.tokenize(ve,Ye);if(Jt=="."&&ve.match(/^\d[\d_]*(?:[eE][+\-]?[\d_]+)?/))return q("number","number");if(Jt=="."&&ve.match(".."))return q("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(Jt))return q(Jt);if(Jt=="="&&ve.eat(">"))return q("=>","operator");if(Jt=="0"&&ve.match(/^(?:x[\dA-Fa-f_]+|o[0-7_]+|b[01_]+)n?/))return q("number","number");if(/\d/.test(Jt))return ve.match(/^[\d_]*(?:n|(?:\.[\d_]*)?(?:[eE][+\-]?[\d_]+)?)?/),q("number","number");if(Jt=="/")return ve.eat("*")?(Ye.tokenize=me,me(ve,Ye)):ve.eat("/")?(ve.skipToEnd(),q("comment","comment")):qi(ve,Ye,1)?(J(ve),ve.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),q("regexp","string-2")):(ve.eat("="),q("operator","operator",ve.current()));if(Jt=="`")return Ye.tokenize=he,he(ve,Ye);if(Jt=="#"&&ve.peek()=="!")return ve.skipToEnd(),q("meta","meta");if(Jt=="#"&&ve.eatWhile(B))return q("variable","property");if(Jt=="<"&&ve.match("!--")||Jt=="-"&&ve.match("->")&&!/\S/.test(ve.string.slice(0,ve.start)))return ve.skipToEnd(),q("comment","comment");if(P.test(Jt))return(Jt!=">"||!Ye.lexical||Ye.lexical.type!=">")&&(ve.eat("=")?(Jt=="!"||Jt=="=")&&ve.eat("="):/[<>*+\-|&?]/.test(Jt)&&(ve.eat(Jt),Jt==">"&&ve.eat(Jt))),Jt=="?"&&ve.eat(".")?q("."):q("operator","operator",ve.current());if(B.test(Jt)){ve.eatWhile(B);var sn=ve.current();if(Ye.lastType!="."){if(k.propertyIsEnumerable(sn)){var Ft=k[sn];return q(Ft.type,Ft.style,sn)}if(sn=="async"&&ve.match(/^(\s|\/\*([^*]|\*(?!\/))*?\*\/)*[\[\(\w]/,!1))return q("async","keyword",sn)}return q("variable","variable",sn)}}function ce(ve){return function(Ye,Jt){var sn=!1,Ft;if(a&&Ye.peek()=="@"&&Ye.match(L))return Jt.tokenize=oe,q("jsonld-keyword","meta");for(;(Ft=Ye.next())!=null&&!(Ft==ve&&!sn);)sn=!sn&&Ft=="\\";return sn||(Jt.tokenize=oe),q("string","string")}}function me(ve,Ye){for(var Jt=!1,sn;sn=ve.next();){if(sn=="/"&&Jt){Ye.tokenize=oe;break}Jt=sn=="*"}return q("comment","comment")}function he(ve,Ye){for(var Jt=!1,sn;(sn=ve.next())!=null;){if(!Jt&&(sn=="`"||sn=="$"&&ve.eat("{"))){Ye.tokenize=oe;break}Jt=!Jt&&sn=="\\"}return q("quasi","string-2",ve.current())}var V="([{}])";function ae(ve,Ye){Ye.fatArrowAt&&(Ye.fatArrowAt=null);var Jt=ve.string.indexOf("=>",ve.start);if(!(Jt<0)){if(C){var sn=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(ve.string.slice(ve.start,Jt));sn&&(Jt=sn.index)}for(var Ft=0,Cn=!1,ur=Jt-1;ur>=0;--ur){var fi=ve.string.charAt(ur),ei=V.indexOf(fi);if(ei>=0&&ei<3){if(!Ft){++ur;break}if(--Ft==0){fi=="("&&(Cn=!0);break}}else if(ei>=3&&ei<6)++Ft;else if(B.test(fi))Cn=!0;else if(/["'\/`]/.test(fi))for(;;--ur){if(ur==0)return;var Zo=ve.string.charAt(ur-1);if(Zo==fi&&ve.string.charAt(ur-2)!="\\"){ur--;break}}else if(Cn&&!Ft){++ur;break}}Cn&&!Ft&&(Ye.fatArrowAt=ur)}}var ye={atom:!0,number:!0,variable:!0,string:!0,regexp:!0,this:!0,import:!0,"jsonld-keyword":!0};function Oe(ve,Ye,Jt,sn,Ft,Cn){this.indented=ve,this.column=Ye,this.type=Jt,this.prev=Ft,this.info=Cn,sn!=null&&(this.align=sn)}function De(ve,Ye){if(!g)return!1;for(var Jt=ve.localVars;Jt;Jt=Jt.next)if(Jt.name==Ye)return!0;for(var sn=ve.context;sn;sn=sn.prev)for(var Jt=sn.vars;Jt;Jt=Jt.next)if(Jt.name==Ye)return!0}function He(ve,Ye,Jt,sn,Ft){var Cn=ve.cc;for(ke.state=ve,ke.stream=Ft,ke.marked=null,ke.cc=Cn,ke.style=Ye,ve.lexical.hasOwnProperty("align")||(ve.lexical.align=!0);;){var ur=Cn.length?Cn.pop():h?Ue:fe;if(ur(Jt,sn)){for(;Cn.length&&Cn[Cn.length-1].lex;)Cn.pop()();return ke.marked?ke.marked:Jt=="variable"&&De(ve,sn)?"variable-2":Ye}}}var ke={state:null,column:null,marked:null,cc:null};function nt(){for(var ve=arguments.length-1;ve>=0;ve--)ke.cc.push(arguments[ve])}function be(){return nt.apply(null,arguments),!0}function Bt(ve,Ye){for(var Jt=Ye;Jt;Jt=Jt.next)if(Jt.name==ve)return!0;return!1}function kt(ve){var Ye=ke.state;if(ke.marked="def",!!g){if(Ye.context){if(Ye.lexical.info=="var"&&Ye.context&&Ye.context.block){var Jt=Yt(ve,Ye.context);if(Jt!=null){Ye.context=Jt;return}}else if(!Bt(ve,Ye.localVars)){Ye.localVars=new rt(ve,Ye.localVars);return}}i.globalVars&&!Bt(ve,Ye.globalVars)&&(Ye.globalVars=new rt(ve,Ye.globalVars))}}function Yt(ve,Ye){if(Ye)if(Ye.block){var Jt=Yt(ve,Ye.prev);return Jt?Jt==Ye.prev?Ye:new Xe(Jt,Ye.vars,!0):null}else return Bt(ve,Ye.vars)?Ye:new Xe(Ye.prev,new rt(ve,Ye.vars),!1);else return null}function jt(ve){return ve=="public"||ve=="private"||ve=="protected"||ve=="abstract"||ve=="readonly"}function Xe(ve,Ye,Jt){this.prev=ve,this.vars=Ye,this.block=Jt}function rt(ve,Ye){this.name=ve,this.next=Ye}var ot=new rt("this",new rt("arguments",null));function on(){ke.state.context=new Xe(ke.state.context,ke.state.localVars,!1),ke.state.localVars=ot}function gt(){ke.state.context=new Xe(ke.state.context,ke.state.localVars,!0),ke.state.localVars=null}on.lex=gt.lex=!0;function at(){ke.state.localVars=ke.state.context.vars,ke.state.context=ke.state.context.prev}at.lex=!0;function It(ve,Ye){var Jt=function(){var sn=ke.state,Ft=sn.indented;if(sn.lexical.type=="stat")Ft=sn.lexical.indented;else for(var Cn=sn.lexical;Cn&&Cn.type==")"&&Cn.align;Cn=Cn.prev)Ft=Cn.indented;sn.lexical=new Oe(Ft,ke.stream.column(),ve,null,sn.lexical,Ye)};return Jt.lex=!0,Jt}function Lt(){var ve=ke.state;ve.lexical.prev&&(ve.lexical.type==")"&&(ve.indented=ve.lexical.indented),ve.lexical=ve.lexical.prev)}Lt.lex=!0;function Me(ve){function Ye(Jt){return Jt==ve?be():ve==";"||Jt=="}"||Jt==")"||Jt=="]"?nt():be(Ye)}return Ye}function fe(ve,Ye){return ve=="var"?be(It("vardef",Ye),lt,Me(";"),Lt):ve=="keyword a"?be(It("form"),it,fe,Lt):ve=="keyword b"?be(It("form"),fe,Lt):ve=="keyword d"?ke.stream.match(/^\s*$/,!1)?be():be(It("stat"),Ut,Me(";"),Lt):ve=="debugger"?be(Me(";")):ve=="{"?be(It("}"),gt,St,Lt,at):ve==";"?be():ve=="if"?(ke.state.lexical.info=="else"&&ke.state.cc[ke.state.cc.length-1]==Lt&&ke.state.cc.pop()(),be(It("form"),it,fe,Lt,Ht)):ve=="function"?be(ar):ve=="for"?be(It("form"),gt,Qn,fe,at,Lt):ve=="class"||C&&Ye=="interface"?(ke.marked="keyword",be(It("form",ve=="class"?ve:Ye),ir,Lt)):ve=="variable"?C&&Ye=="declare"?(ke.marked="keyword",be(fe)):C&&(Ye=="module"||Ye=="enum"||Ye=="type")&&ke.stream.match(/^\s*\w/,!1)?(ke.marked="keyword",Ye=="enum"?be(Wn):Ye=="type"?be(jr,Me("operator"),En,Me(";")):be(It("form"),ft,Me("{"),It("}"),St,Lt,Lt)):C&&Ye=="namespace"?(ke.marked="keyword",be(It("form"),Ue,fe,Lt)):C&&Ye=="abstract"?(ke.marked="keyword",be(fe)):be(It("stat"),gr):ve=="switch"?be(It("form"),it,Me("{"),It("}","switch"),gt,St,Lt,Lt,at):ve=="case"?be(Ue,Me(":")):ve=="default"?be(Me(":")):ve=="catch"?be(It("form"),on,xe,fe,Lt,at):ve=="export"?be(It("stat"),_o,Lt):ve=="import"?be(It("stat"),xo,Lt):ve=="async"?be(fe):Ye=="@"?be(Ue,fe):nt(It("stat"),Ue,Me(";"),Lt)}function xe(ve){if(ve=="(")return be(Lr,Me(")"))}function Ue(ve,Ye){return bt(ve,Ye,!1)}function et(ve,Ye){return bt(ve,Ye,!0)}function it(ve){return ve!="("?nt():be(It(")"),Ut,Me(")"),Lt)}function bt(ve,Ye,Jt){if(ke.state.fatArrowAt==ke.stream.start){var sn=Jt?Xn:vn;if(ve=="(")return be(on,It(")"),Te(Lr,")"),Lt,Me("=>"),sn,at);if(ve=="variable")return nt(on,ft,Me("=>"),sn,at)}var Ft=Jt?pt:Rt;return ye.hasOwnProperty(ve)?be(Ft):ve=="function"?be(ar,Ft):ve=="class"||C&&Ye=="interface"?(ke.marked="keyword",be(It("form"),Wr,Lt)):ve=="keyword c"||ve=="async"?be(Jt?et:Ue):ve=="("?be(It(")"),Ut,Me(")"),Lt,Ft):ve=="operator"||ve=="spread"?be(Jt?et:Ue):ve=="["?be(It("]"),hi,Lt,Ft):ve=="{"?At(Se,"}",null,Ft):ve=="quasi"?nt(rr,Ft):ve=="new"?be(cr(Jt)):be()}function Ut(ve){return ve.match(/[;\}\)\],]/)?nt():nt(Ue)}function Rt(ve,Ye){return ve==","?be(Ut):pt(ve,Ye,!1)}function pt(ve,Ye,Jt){var sn=Jt==!1?Rt:pt,Ft=Jt==!1?Ue:et;if(ve=="=>")return be(on,Jt?Xn:vn,at);if(ve=="operator")return/\+\+|--/.test(Ye)||C&&Ye=="!"?be(sn):C&&Ye=="<"&&ke.stream.match(/^([^<>]|<[^<>]*>)*>\s*\(/,!1)?be(It(">"),Te(En,">"),Lt,sn):Ye=="?"?be(Ue,Me(":"),Ft):be(Ft);if(ve=="quasi")return nt(rr,sn);if(ve!=";"){if(ve=="(")return At(et,")","call",sn);if(ve==".")return be(mi,sn);if(ve=="[")return be(It("]"),Ut,Me("]"),Lt,sn);if(C&&Ye=="as")return ke.marked="keyword",be(En,sn);if(ve=="regexp")return ke.state.lastType=ke.marked="operator",ke.stream.backUp(ke.stream.pos-ke.stream.start-1),be(Ft)}}function rr(ve,Ye){return ve!="quasi"?nt():Ye.slice(Ye.length-2)!="${"?be(rr):be(Ut,mn)}function mn(ve){if(ve=="}")return ke.marked="string-2",ke.state.tokenize=he,be(rr)}function vn(ve){return ae(ke.stream,ke.state),nt(ve=="{"?fe:Ue)}function Xn(ve){return ae(ke.stream,ke.state),nt(ve=="{"?fe:et)}function cr(ve){return function(Ye){return Ye=="."?be(ve?Gr:Mr):Ye=="variable"&&C?be(Be,ve?pt:Rt):nt(ve?et:Ue)}}function Mr(ve,Ye){if(Ye=="target")return ke.marked="keyword",be(Rt)}function Gr(ve,Ye){if(Ye=="target")return ke.marked="keyword",be(pt)}function gr(ve){return ve==":"?be(Lt,fe):nt(Rt,Me(";"),Lt)}function mi(ve){if(ve=="variable")return ke.marked="property",be()}function Se(ve,Ye){if(ve=="async")return ke.marked="property",be(Se);if(ve=="variable"||ke.style=="keyword"){if(ke.marked="property",Ye=="get"||Ye=="set")return be(X);var Jt;return C&&ke.state.fatArrowAt==ke.stream.start&&(Jt=ke.stream.match(/^\s*:\s*/,!1))&&(ke.state.fatArrowAt=ke.stream.pos+Jt[0].length),be(H)}else{if(ve=="number"||ve=="string")return ke.marked=a?"property":ke.style+" property",be(H);if(ve=="jsonld-keyword")return be(H);if(C&&jt(Ye))return ke.marked="keyword",be(Se);if(ve=="[")return be(Ue,Et,Me("]"),H);if(ve=="spread")return be(et,H);if(Ye=="*")return ke.marked="keyword",be(Se);if(ve==":")return nt(H)}}function X(ve){return ve!="variable"?nt(H):(ke.marked="property",be(ar))}function H(ve){if(ve==":")return be(et);if(ve=="(")return nt(ar)}function Te(ve,Ye,Jt){function sn(Ft,Cn){if(Jt?Jt.indexOf(Ft)>-1:Ft==","){var ur=ke.state.lexical;return ur.info=="call"&&(ur.pos=(ur.pos||0)+1),be(function(fi,ei){return fi==Ye||ei==Ye?nt():nt(ve)},sn)}return Ft==Ye||Cn==Ye?be():Jt&&Jt.indexOf(";")>-1?nt(ve):be(Me(Ye))}return function(Ft,Cn){return Ft==Ye||Cn==Ye?be():nt(ve,sn)}}function At(ve,Ye,Jt){for(var sn=3;sn<arguments.length;sn++)ke.cc.push(arguments[sn]);return be(It(Ye,Jt),Te(ve,Ye),Lt)}function St(ve){return ve=="}"?be():nt(fe,St)}function Et(ve,Ye){if(C){if(ve==":")return be(En);if(Ye=="?")return be(Et)}}function Nt(ve,Ye){if(C&&(ve==":"||Ye=="in"))return be(En)}function pn(ve){if(C&&ve==":")return ke.stream.match(/^\s*\w+\s+is\b/,!1)?be(Ue,Kn,En):be(En)}function Kn(ve,Ye){if(Ye=="is")return ke.marked="keyword",be()}function En(ve,Ye){if(Ye=="keyof"||Ye=="typeof"||Ye=="infer"||Ye=="readonly")return ke.marked="keyword",be(Ye=="typeof"?et:En);if(ve=="variable"||Ye=="void")return ke.marked="type",be(Ce);if(Ye=="|"||Ye=="&")return be(En);if(ve=="string"||ve=="number"||ve=="atom")return be(Ce);if(ve=="[")return be(It("]"),Te(En,"]",","),Lt,Ce);if(ve=="{")return be(It("}"),Kt,Lt,Ce);if(ve=="(")return be(Te(de,")"),m,Ce);if(ve=="<")return be(Te(En,">"),En);if(ve=="quasi")return nt(Fn,Ce)}function m(ve){if(ve=="=>")return be(En)}function Kt(ve){return ve.match(/[\}\)\]]/)?be():ve==","||ve==";"?be(Kt):nt(Dr,Kt)}function Dr(ve,Ye){if(ve=="variable"||ke.style=="keyword")return ke.marked="property",be(Dr);if(Ye=="?"||ve=="number"||ve=="string")return be(Dr);if(ve==":")return be(En);if(ve=="[")return be(Me("variable"),Nt,Me("]"),Dr);if(ve=="(")return nt(kr,Dr);if(!ve.match(/[;\}\)\],]/))return be()}function Fn(ve,Ye){return ve!="quasi"?nt():Ye.slice(Ye.length-2)!="${"?be(Fn):be(En,Fe)}function Fe(ve){if(ve=="}")return ke.marked="string-2",ke.state.tokenize=he,be(Fn)}function de(ve,Ye){return ve=="variable"&&ke.stream.match(/^\s*[?:]/,!1)||Ye=="?"?be(de):ve==":"?be(En):ve=="spread"?be(de):nt(En)}function Ce(ve,Ye){if(Ye=="<")return be(It(">"),Te(En,">"),Lt,Ce);if(Ye=="|"||ve=="."||Ye=="&")return be(En);if(ve=="[")return be(En,Me("]"),Ce);if(Ye=="extends"||Ye=="implements")return ke.marked="keyword",be(En);if(Ye=="?")return be(En,Me(":"),En)}function Be(ve,Ye){if(Ye=="<")return be(It(">"),Te(En,">"),Lt,Ce)}function ze(){return nt(En,tt)}function tt(ve,Ye){if(Ye=="=")return be(En)}function lt(ve,Ye){return Ye=="enum"?(ke.marked="keyword",be(Wn)):nt(ft,Et,Xt,Vt)}function ft(ve,Ye){if(C&&jt(Ye))return ke.marked="keyword",be(ft);if(ve=="variable")return kt(Ye),be();if(ve=="spread")return be(ft);if(ve=="[")return At(xt,"]");if(ve=="{")return At(Ve,"}")}function Ve(ve,Ye){return ve=="variable"&&!ke.stream.match(/^\s*:/,!1)?(kt(Ye),be(Xt)):(ve=="variable"&&(ke.marked="property"),ve=="spread"?be(ft):ve=="}"?nt():ve=="["?be(Ue,Me("]"),Me(":"),Ve):be(Me(":"),ft,Xt))}function xt(){return nt(ft,Xt)}function Xt(ve,Ye){if(Ye=="=")return be(et)}function Vt(ve){if(ve==",")return be(lt)}function Ht(ve,Ye){if(ve=="keyword b"&&Ye=="else")return be(It("form","else"),fe,Lt)}function Qn(ve,Ye){if(Ye=="await")return be(Qn);if(ve=="(")return be(It(")"),Mn,Lt)}function Mn(ve){return ve=="var"?be(lt,or):ve=="variable"?be(or):nt(or)}function or(ve,Ye){return ve==")"?be():ve==";"?be(or):Ye=="in"||Ye=="of"?(ke.marked="keyword",be(Ue,or)):nt(Ue,or)}function ar(ve,Ye){if(Ye=="*")return ke.marked="keyword",be(ar);if(ve=="variable")return kt(Ye),be(ar);if(ve=="(")return be(on,It(")"),Te(Lr,")"),Lt,pn,fe,at);if(C&&Ye=="<")return be(It(">"),Te(ze,">"),Lt,ar)}function kr(ve,Ye){if(Ye=="*")return ke.marked="keyword",be(kr);if(ve=="variable")return kt(Ye),be(kr);if(ve=="(")return be(on,It(")"),Te(Lr,")"),Lt,pn,at);if(C&&Ye=="<")return be(It(">"),Te(ze,">"),Lt,kr)}function jr(ve,Ye){if(ve=="keyword"||ve=="variable")return ke.marked="type",be(jr);if(Ye=="<")return be(It(">"),Te(ze,">"),Lt)}function Lr(ve,Ye){return Ye=="@"&&be(Ue,Lr),ve=="spread"?be(Lr):C&&jt(Ye)?(ke.marked="keyword",be(Lr)):C&&ve=="this"?be(Et,Xt):nt(ft,Et,Xt)}function Wr(ve,Ye){return ve=="variable"?ir(ve,Ye):ui(ve,Ye)}function ir(ve,Ye){if(ve=="variable")return kt(Ye),be(ui)}function ui(ve,Ye){if(Ye=="<")return be(It(">"),Te(ze,">"),Lt,ui);if(Ye=="extends"||Ye=="implements"||C&&ve==",")return Ye=="implements"&&(ke.marked="keyword"),be(C?En:Ue,ui);if(ve=="{")return be(It("}"),Oi,Lt)}function Oi(ve,Ye){if(ve=="async"||ve=="variable"&&(Ye=="static"||Ye=="get"||Ye=="set"||C&&jt(Ye))&&ke.stream.match(/^\s+#?[\w$\xa1-\uffff]/,!1))return ke.marked="keyword",be(Oi);if(ve=="variable"||ke.style=="keyword")return ke.marked="property",be(Yi,Oi);if(ve=="number"||ve=="string")return be(Yi,Oi);if(ve=="[")return be(Ue,Et,Me("]"),Yi,Oi);if(Ye=="*")return ke.marked="keyword",be(Oi);if(C&&ve=="(")return nt(kr,Oi);if(ve==";"||ve==",")return be(Oi);if(ve=="}")return be();if(Ye=="@")return be(Ue,Oi)}function Yi(ve,Ye){if(Ye=="!"||Ye=="?")return be(Yi);if(ve==":")return be(En,Xt);if(Ye=="=")return be(et);var Jt=ke.state.lexical.prev,sn=Jt&&Jt.info=="interface";return nt(sn?kr:ar)}function _o(ve,Ye){return Ye=="*"?(ke.marked="keyword",be(os,Me(";"))):Ye=="default"?(ke.marked="keyword",be(Ue,Me(";"))):ve=="{"?be(Te(Jr,"}"),os,Me(";")):nt(fe)}function Jr(ve,Ye){if(Ye=="as")return ke.marked="keyword",be(Me("variable"));if(ve=="variable")return nt(et,Jr)}function xo(ve){return ve=="string"?be():ve=="("?nt(Ue):ve=="."?nt(Rt):nt(Wa,Ba,os)}function Wa(ve,Ye){return ve=="{"?At(Wa,"}"):(ve=="variable"&&kt(Ye),Ye=="*"&&(ke.marked="keyword"),be(bi))}function Ba(ve){if(ve==",")return be(Wa,Ba)}function bi(ve,Ye){if(Ye=="as")return ke.marked="keyword",be(Wa)}function os(ve,Ye){if(Ye=="from")return ke.marked="keyword",be(Ue)}function hi(ve){return ve=="]"?be():nt(Te(et,"]"))}function Wn(){return nt(It("form"),ft,Me("{"),It("}"),Te(eo,"}"),Lt,Lt)}function eo(){return nt(ft,Xt)}function io(ve,Ye){return ve.lastType=="operator"||ve.lastType==","||P.test(Ye.charAt(0))||/[,.]/.test(Ye.charAt(0))}function qi(ve,Ye,Jt){return Ye.tokenize==oe&&/^(?:operator|sof|keyword [bcd]|case|new|export|default|spread|[\[{}\(,;:]|=>)$/.test(Ye.lastType)||Ye.lastType=="quasi"&&/\{\s*$/.test(ve.string.slice(0,ve.pos-(Jt||0)))}return{startState:function(ve){var Ye={tokenize:oe,lastType:"sof",cc:[],lexical:new Oe((ve||0)-o,0,"block",!1),localVars:i.localVars,context:i.localVars&&new Xe(null,null,!1),indented:ve||0};return i.globalVars&&typeof i.globalVars=="object"&&(Ye.globalVars=i.globalVars),Ye},token:function(ve,Ye){if(ve.sol()&&(Ye.lexical.hasOwnProperty("align")||(Ye.lexical.align=!1),Ye.indented=ve.indentation(),ae(ve,Ye)),Ye.tokenize!=me&&ve.eatSpace())return null;var Jt=Ye.tokenize(ve,Ye);return N=="comment"?Jt:(Ye.lastType=N=="operator"&&($=="++"||$=="--")?"incdec":N,He(Ye,Jt,N,$,ve))},indent:function(ve,Ye){if(ve.tokenize==me||ve.tokenize==he)return t.Pass;if(ve.tokenize!=oe)return 0;var Jt=Ye&&Ye.charAt(0),sn=ve.lexical,Ft;if(!/^\s*else\b/.test(Ye))for(var Cn=ve.cc.length-1;Cn>=0;--Cn){var ur=ve.cc[Cn];if(ur==Lt)sn=sn.prev;else if(ur!=Ht&&ur!=at)break}for(;(sn.type=="stat"||sn.type=="form")&&(Jt=="}"||(Ft=ve.cc[ve.cc.length-1])&&(Ft==Rt||Ft==pt)&&!/^[,\.=+\-*:?[\(]/.test(Ye));)sn=sn.prev;s&&sn.type==")"&&sn.prev.type=="stat"&&(sn=sn.prev);var fi=sn.type,ei=Jt==fi;return fi=="vardef"?sn.indented+(ve.lastType=="operator"||ve.lastType==","?sn.info.length+1:0):fi=="form"&&Jt=="{"?sn.indented:fi=="form"?sn.indented+o:fi=="stat"?sn.indented+(io(ve,Ye)?s||o:0):sn.info=="switch"&&!ei&&i.doubleIndentSwitch!=!1?sn.indented+(/^(?:case|default)\b/.test(Ye)?o:2*o):sn.align?sn.column+(ei?0:1):sn.indented+(ei?0:o)},electricInput:/^\s*(?:case .*?:|default:|\{|\})$/,blockCommentStart:h?null:"/*",blockCommentEnd:h?null:"*/",blockCommentContinue:h?null:" * ",lineComment:h?null:"//",fold:"brace",closeBrackets:"()[]{}''\"\"``",helperType:h?"json":"javascript",jsonldMode:a,jsonMode:h,expressionAllowed:qi,skipExpression:function(ve){He(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(R5())})(function(t){var r="CodeMirror-lint-markers",i="CodeMirror-lint-line-";function o(V,ae,ye){var Oe=document.createElement("div");Oe.className="CodeMirror-lint-tooltip cm-s-"+V.options.theme,Oe.appendChild(ye.cloneNode(!0)),V.state.lint.options.selfContain?V.getWrapperElement().appendChild(Oe):document.body.appendChild(Oe);function De(He){if(!Oe.parentNode)return t.off(document,"mousemove",De);var ke=Math.max(0,He.clientY-Oe.offsetHeight-5),nt=Math.max(0,Math.min(He.clientX+5,Oe.ownerDocument.defaultView.innerWidth-Oe.offsetWidth));Oe.style.top=ke+"px",Oe.style.left=nt+"px"}return t.on(document,"mousemove",De),De(ae),Oe.style.opacity!=null&&(Oe.style.opacity=1),Oe}function s(V){V.parentNode&&V.parentNode.removeChild(V)}function a(V){V.parentNode&&(V.style.opacity==null&&s(V),V.style.opacity=0,setTimeout(function(){s(V)},600))}function h(V,ae,ye,Oe){var De=o(V,ae,ye);function He(){t.off(Oe,"mouseout",He),De&&(a(De),De=null)}var ke=setInterval(function(){if(De)for(var nt=Oe;;nt=nt.parentNode){if(nt&&nt.nodeType==11&&(nt=nt.host),nt==document.body)return;if(!nt){He();break}}if(!De)return clearInterval(ke)},400);t.on(Oe,"mouseout",He)}function g(V,ae,ye){this.marked=[],ae instanceof Function&&(ae={getAnnotations:ae}),(!ae||ae===!0)&&(ae={}),this.options={},this.linterOptions=ae.options||{};for(var Oe in C)this.options[Oe]=C[Oe];for(var Oe in ae)C.hasOwnProperty(Oe)?ae[Oe]!=null&&(this.options[Oe]=ae[Oe]):ae.options||(this.linterOptions[Oe]=ae[Oe]);this.timeout=null,this.hasGutter=ye,this.onMouseOver=function(De){he(V,De)},this.waitingFor=0}var C={highlightLines:!1,tooltips:!0,delay:500,lintOnChange:!0,getAnnotations:null,async:!1,selfContain:null,formatAnnotation:null,onUpdateLinting:null};function B(V){var ae=V.state.lint;ae.hasGutter&&V.clearGutter(r),ae.options.highlightLines&&k(V);for(var ye=0;ye<ae.marked.length;++ye)ae.marked[ye].clear();ae.marked.length=0}function k(V){V.eachLine(function(ae){var ye=ae.wrapClass&&/\bCodeMirror-lint-line-\w+\b/.exec(ae.wrapClass);ye&&V.removeLineClass(ae,"wrap",ye[0])})}function P(V,ae,ye,Oe,De){var He=document.createElement("div"),ke=He;return He.className="CodeMirror-lint-marker CodeMirror-lint-marker-"+ye,Oe&&(ke=He.appendChild(document.createElement("div")),ke.className="CodeMirror-lint-marker CodeMirror-lint-marker-multiple"),De!=!1&&t.on(ke,"mouseover",function(nt){h(V,nt,ae,ke)}),He}function L(V,ae){return V=="error"?V:ae}function J(V){for(var ae=[],ye=0;ye<V.length;++ye){var Oe=V[ye],De=Oe.from.line;(ae[De]||(ae[De]=[])).push(Oe)}return ae}function N(V){var ae=V.severity;ae||(ae="error");var ye=document.createElement("div");return ye.className="CodeMirror-lint-message CodeMirror-lint-message-"+ae,typeof V.messageHTML<"u"?ye.innerHTML=V.messageHTML:ye.appendChild(document.createTextNode(V.message)),ye}function $(V,ae){var ye=V.state.lint,Oe=++ye.waitingFor;function De(){Oe=-1,V.off("change",De)}V.on("change",De),ae(V.getValue(),function(He,ke){V.off("change",De),ye.waitingFor==Oe&&(ke&&He instanceof t&&(He=ke),V.operation(function(){oe(V,He)}))},ye.linterOptions,V)}function q(V){var ae=V.state.lint;if(ae){var ye=ae.options,Oe=ye.getAnnotations||V.getHelper(t.Pos(0,0),"lint");if(Oe)if(ye.async||Oe.async)$(V,Oe);else{var De=Oe(V.getValue(),ae.linterOptions,V);if(!De)return;De.then?De.then(function(He){V.operation(function(){oe(V,He)})}):V.operation(function(){oe(V,De)})}}}function oe(V,ae){var ye=V.state.lint;if(ye){var Oe=ye.options;B(V);for(var De=J(ae),He=0;He<De.length;++He){var ke=De[He];if(ke){for(var nt=null,be=ye.hasGutter&&document.createDocumentFragment(),Bt=0;Bt<ke.length;++Bt){var kt=ke[Bt],Yt=kt.severity;Yt||(Yt="error"),nt=L(nt,Yt),Oe.formatAnnotation&&(kt=Oe.formatAnnotation(kt)),ye.hasGutter&&be.appendChild(N(kt)),kt.to&&ye.marked.push(V.markText(kt.from,kt.to,{className:"CodeMirror-lint-mark CodeMirror-lint-mark-"+Yt,__annotation:kt}))}ye.hasGutter&&V.setGutterMarker(He,r,P(V,be,nt,ke.length>1,Oe.tooltips)),Oe.highlightLines&&V.addLineClass(He,"wrap",i+nt)}}Oe.onUpdateLinting&&Oe.onUpdateLinting(ae,De,V)}}function ce(V){var ae=V.state.lint;ae&&(clearTimeout(ae.timeout),ae.timeout=setTimeout(function(){q(V)},ae.options.delay))}function me(V,ae,ye){for(var Oe=ye.target||ye.srcElement,De=document.createDocumentFragment(),He=0;He<ae.length;He++){var ke=ae[He];De.appendChild(N(ke))}h(V,ye,De,Oe)}function he(V,ae){var ye=ae.target||ae.srcElement;if(/\bCodeMirror-lint-mark-/.test(ye.className)){for(var Oe=ye.getBoundingClientRect(),De=(Oe.left+Oe.right)/2,He=(Oe.top+Oe.bottom)/2,ke=V.findMarksAt(V.coordsChar({left:De,top:He},"client")),nt=[],be=0;be<ke.length;++be){var Bt=ke[be].__annotation;Bt&&nt.push(Bt)}nt.length&&me(V,nt,ae)}}t.defineOption("lint",!1,function(V,ae,ye){if(ye&&ye!=t.Init&&(B(V),V.state.lint.options.lintOnChange!==!1&&V.off("change",ce),t.off(V.getWrapperElement(),"mouseover",V.state.lint.onMouseOver),clearTimeout(V.state.lint.timeout),delete V.state.lint),ae){for(var Oe=V.getOption("gutters"),De=!1,He=0;He<Oe.length;++He)Oe[He]==r&&(De=!0);var ke=V.state.lint=new g(V,ae,De);ke.options.lintOnChange&&V.on("change",ce),ke.options.tooltips!=!1&&ke.options.tooltips!="gutter"&&t.on(V.getWrapperElement(),"mouseover",ke.onMouseOver),q(V)}}),t.defineExtension("performLint",function(){q(this)})})})();(function(e,n){(function(t){t(R5())})(function(t){var r=/MSIE \d/.test(navigator.userAgent)&&(document.documentMode==null||document.documentMode<8),i=t.Pos,o={"(":")>",")":"(<","[":"]>","]":"[<","{":"}>","}":"{<","<":">>",">":"<<"};function s(k){return k&&k.bracketRegex||/[(){}[\]]/}function a(k,P,L){var J=k.getLineHandle(P.line),N=P.ch-1,$=L&&L.afterCursor;$==null&&($=/(^| )cm-fat-cursor($| )/.test(k.getWrapperElement().className));var q=s(L),oe=!$&&N>=0&&q.test(J.text.charAt(N))&&o[J.text.charAt(N)]||q.test(J.text.charAt(N+1))&&o[J.text.charAt(++N)];if(!oe)return null;var ce=oe.charAt(1)==">"?1:-1;if(L&&L.strict&&ce>0!=(N==P.ch))return null;var me=k.getTokenTypeAt(i(P.line,N+1)),he=h(k,i(P.line,N+(ce>0?1:0)),ce,me,L);return he==null?null:{from:i(P.line,N),to:he&&he.pos,match:he&&he.ch==oe.charAt(0),forward:ce>0}}function h(k,P,L,J,N){for(var $=N&&N.maxScanLineLength||1e4,q=N&&N.maxScanLines||1e3,oe=[],ce=s(N),me=L>0?Math.min(P.line+q,k.lastLine()+1):Math.max(k.firstLine()-1,P.line-q),he=P.line;he!=me;he+=L){var V=k.getLine(he);if(V){var ae=L>0?0:V.length-1,ye=L>0?V.length:-1;if(!(V.length>$))for(he==P.line&&(ae=P.ch-(L<0?1:0));ae!=ye;ae+=L){var Oe=V.charAt(ae);if(ce.test(Oe)&&(J===void 0||(k.getTokenTypeAt(i(he,ae+1))||"")==(J||""))){var De=o[Oe];if(De&&De.charAt(1)==">"==L>0)oe.push(Oe);else if(oe.length)oe.pop();else return{pos:i(he,ae),ch:Oe}}}}}return he-L==(L>0?k.lastLine():k.firstLine())?!1:null}function g(k,P,L){for(var J=k.state.matchBrackets.maxHighlightLineLength||1e3,N=L&&L.highlightNonMatching,$=[],q=k.listSelections(),oe=0;oe<q.length;oe++){var ce=q[oe].empty()&&a(k,q[oe].head,L);if(ce&&(ce.match||N!==!1)&&k.getLine(ce.from.line).length<=J){var me=ce.match?"CodeMirror-matchingbracket":"CodeMirror-nonmatchingbracket";$.push(k.markText(ce.from,i(ce.from.line,ce.from.ch+1),{className:me})),ce.to&&k.getLine(ce.to.line).length<=J&&$.push(k.markText(ce.to,i(ce.to.line,ce.to.ch+1),{className:me}))}}if($.length){r&&k.state.focused&&k.focus();var he=function(){k.operation(function(){for(var V=0;V<$.length;V++)$[V].clear()})};if(P)setTimeout(he,800);else return he}}function C(k){k.operation(function(){k.state.matchBrackets.currentlyHighlighted&&(k.state.matchBrackets.currentlyHighlighted(),k.state.matchBrackets.currentlyHighlighted=null),k.state.matchBrackets.currentlyHighlighted=g(k,!1,k.state.matchBrackets)})}function B(k){k.state.matchBrackets&&k.state.matchBrackets.currentlyHighlighted&&(k.state.matchBrackets.currentlyHighlighted(),k.state.matchBrackets.currentlyHighlighted=null)}t.defineOption("matchBrackets",!1,function(k,P,L){L&&L!=t.Init&&(k.off("cursorActivity",C),k.off("focus",C),k.off("blur",B),B(k)),P&&(k.state.matchBrackets=typeof P=="object"?P:{},k.on("cursorActivity",C),k.on("focus",C),k.on("blur",B))}),t.defineExtension("matchBrackets",function(){g(this,!0)}),t.defineExtension("findMatchingBracket",function(k,P,L){return(L||typeof P=="boolean")&&(L?(L.strict=P,P=L):P=P?{strict:!0}:null),a(this,k,P)}),t.defineExtension("scanForBracket",function(k,P,L,J){return h(this,k,P,L,J)})})})();var vme=/("(?:[^\\"]|\\.)*")|[:,]/g,_me=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,h,g){var C,B,k,P,L,J,N,$,q,oe,ce,me;if(a&&typeof a.toJSON=="function"&&(a=a.toJSON()),ce=JSON.stringify(a,o),ce===void 0)return ce;if(N=i-h.length-g,ce.length<=N&&(q=ce.replace(vme,function(he,V){return V||he+" "}),q.length<=N))return q;if(o!=null&&(a=JSON.parse(ce),o=void 0),typeof a=="object"&&a!==null){if($=h+r,k=[],B=0,Array.isArray(a))for(oe="[",C="]",N=a.length;B<N;B++)k.push(s(a[B],$,B===N-1?0:1)||"null");else for(oe="{",C="}",J=Object.keys(a),N=J.length;B<N;B++)P=J[B],L=JSON.stringify(P)+": ",me=s(a[P],$,L.length+(B===N-1?0:1)),me!==void 0&&k.push(L+me);if(k.length>0)return[oe,r+k.join(`,
`+$),C].join(`
`+h)}return ce}(n,"",0)};const eN=fa(_me);function Cme(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 tN={};(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,h,g,C,B){var k=C.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.$=C[k-1];case 13:this.$={};break;case 14:this.$=C[k-1];break;case 15:this.$=[C[k-2],C[k]];break;case 16:this.$={},this.$[C[k][0]]=C[k][1];break;case 17:this.$=C[k-2],C[k-2][C[k][0]]=C[k][1];break;case 18:this.$=[];break;case 19:this.$=C[k-1];break;case 20:this.$=[C[k]];break;case 21:this.$=C[k-2],C[k-2].push(C[k]);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],h=[null],g=[],C=this.table,B="",k=0,P=0,L=0,J=2,N=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(be){a.length=a.length-2*be,h.length=h.length-be,g.length=g.length-be}function oe(){var be;return be=s.lexer.lex()||1,typeof be!="number"&&(be=s.symbols_[be]||be),be}for(var ce,me,he,V,ae,ye={},Oe,De,He,ke;;){if(he=a[a.length-1],this.defaultActions[he]?V=this.defaultActions[he]:(ce==null&&(ce=oe()),V=C[he]&&C[he][ce]),typeof V>"u"||!V.length||!V[0]){if(!L){ke=[];for(Oe in C[he])this.terminals_[Oe]&&Oe>2&&ke.push("'"+this.terminals_[Oe]+"'");var nt="";this.lexer.showPosition?nt="Parse error on line "+(k+1)+`:
`+this.lexer.showPosition()+`
Expecting `+ke.join(", ")+", got '"+this.terminals_[ce]+"'":nt="Parse error on line "+(k+1)+": Unexpected "+(ce==1?"end of input":"'"+(this.terminals_[ce]||ce)+"'"),this.parseError(nt,{text:this.lexer.match,token:this.terminals_[ce]||ce,line:this.lexer.yylineno,loc:$,expected:ke})}if(L==3){if(ce==N)throw new Error(nt||"Parsing halted.");P=this.lexer.yyleng,B=this.lexer.yytext,k=this.lexer.yylineno,$=this.lexer.yylloc,ce=oe()}for(;!(J.toString()in C[he]);){if(he==0)throw new Error(nt||"Parsing halted.");q(1),he=a[a.length-1]}me=ce,ce=J,he=a[a.length-1],V=C[he]&&C[he][J],L=3}if(V[0]instanceof Array&&V.length>1)throw new Error("Parse Error: multiple actions possible at state: "+he+", token: "+ce);switch(V[0]){case 1:a.push(ce),h.push(this.lexer.yytext),g.push(this.lexer.yylloc),a.push(V[1]),ce=null,me?(ce=me,me=null):(P=this.lexer.yyleng,B=this.lexer.yytext,k=this.lexer.yylineno,$=this.lexer.yylloc,L>0&&L--);break;case 2:if(De=this.productions_[V[1]][1],ye.$=h[h.length-De],ye._$={first_line:g[g.length-(De||1)].first_line,last_line:g[g.length-1].last_line,first_column:g[g.length-(De||1)].first_column,last_column:g[g.length-1].last_column},ae=this.performAction.call(ye,B,P,k,this.yy,V[1],h,g),typeof ae<"u")return ae;De&&(a=a.slice(0,-1*De*2),h=h.slice(0,-1*De),g=g.slice(0,-1*De)),a.push(this.productions_[V[1]][0]),h.push(ye.$),g.push(ye._$),He=C[a[a.length-2]][a[a.length-1]],a.push(He);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,h,g;this._more||(this.yytext="",this.match="");for(var C=this._currentRules(),B=0;B<C.length&&(a=this._input.match(this.rules[C[B]]),!(a&&(!s||a[0].length>s[0].length)&&(s=a,h=B,!this.options.flex)));B++);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,C[h],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,h,g){switch(h){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 Cme<"u"&&(e.parser=n,e.parse=n.parse.bind(n))})(tN);const eO=fa(tN);var nN={exports:{}};(function(e,n){(function(t,r){e.exports=r()})(ch,function(){var t=typeof window<"u"||typeof window<"u"?window:typeof self<"u"?self:{};function r(fe,xe){return xe={exports:{}},fe(xe,xe.exports),xe.exports}var i=r(function(fe){function xe(){var Ue=0,et=1,it=2,bt=3,Ut=4,Rt=5,pt=6,rr=7,mn=8,vn=9,Xn=10,cr=11,Mr=12,Gr=13,gr=14,mi=15,Se=16,X=17,H=0,Te=1,At=2,St=3,Et=4;function Nt(m,Kt){return 55296<=m.charCodeAt(Kt)&&m.charCodeAt(Kt)<=56319&&56320<=m.charCodeAt(Kt+1)&&m.charCodeAt(Kt+1)<=57343}function pn(m,Kt){Kt===void 0&&(Kt=0);var Dr=m.charCodeAt(Kt);if(55296<=Dr&&Dr<=56319&&Kt<m.length-1){var Fn=Dr,Fe=m.charCodeAt(Kt+1);return 56320<=Fe&&Fe<=57343?(Fn-55296)*1024+(Fe-56320)+65536:Fn}if(56320<=Dr&&Dr<=57343&&Kt>=1){var Fn=m.charCodeAt(Kt-1),Fe=Dr;return 55296<=Fn&&Fn<=56319?(Fn-55296)*1024+(Fe-56320)+65536:Fe}return Dr}function Kn(m,Kt,Dr){var Fn=[m].concat(Kt).concat([Dr]),Fe=Fn[Fn.length-2],de=Dr,Ce=Fn.lastIndexOf(gr);if(Ce>1&&Fn.slice(1,Ce).every(function(tt){return tt==bt})&&[bt,Gr,X].indexOf(m)==-1)return At;var Be=Fn.lastIndexOf(Ut);if(Be>0&&Fn.slice(1,Be).every(function(tt){return tt==Ut})&&[Mr,Ut].indexOf(Fe)==-1)return Fn.filter(function(tt){return tt==Ut}).length%2==1?St:Et;if(Fe==Ue&&de==et)return H;if(Fe==it||Fe==Ue||Fe==et)return de==gr&&Kt.every(function(tt){return tt==bt})?At:Te;if(de==it||de==Ue||de==et)return Te;if(Fe==pt&&(de==pt||de==rr||de==vn||de==Xn))return H;if((Fe==vn||Fe==rr)&&(de==rr||de==mn))return H;if((Fe==Xn||Fe==mn)&&de==mn)return H;if(de==bt||de==mi)return H;if(de==Rt)return H;if(Fe==Mr)return H;var ze=Fn.indexOf(bt)!=-1?Fn.lastIndexOf(bt)-1:Fn.length-2;return[Gr,X].indexOf(Fn[ze])!=-1&&Fn.slice(ze+1,-1).every(function(tt){return tt==bt})&&de==gr||Fe==mi&&[Se,X].indexOf(de)!=-1?H:Kt.indexOf(Ut)!=-1?At:Fe==Ut&&de==Ut?H:Te}this.nextBreak=function(m,Kt){if(Kt===void 0&&(Kt=0),Kt<0)return 0;if(Kt>=m.length-1)return m.length;for(var Dr=En(pn(m,Kt)),Fn=[],Fe=Kt+1;Fe<m.length;Fe++)if(!Nt(m,Fe-1)){var de=En(pn(m,Fe));if(Kn(Dr,Fn,de))return Fe;Fn.push(de)}return m.length},this.splitGraphemes=function(m){for(var Kt=[],Dr=0,Fn;(Fn=this.nextBreak(m,Dr))<m.length;)Kt.push(m.slice(Dr,Fn)),Dr=Fn;return Dr<m.length&&Kt.push(m.slice(Dr)),Kt},this.iterateGraphemes=function(m){var Kt=0,Dr={next:(function(){var Fn,Fe;return(Fe=this.nextBreak(m,Kt))<m.length?(Fn=m.slice(Kt,Fe),Kt=Fe,{value:Fn,done:!1}):Kt<m.length?(Fn=m.slice(Kt),Kt=m.length,{value:Fn,done:!1}):{value:void 0,done:!0}}).bind(this)};return typeof Symbol<"u"&&Symbol.iterator&&(Dr[Symbol.iterator]=function(){return Dr}),Dr},this.countGraphemes=function(m){for(var Kt=0,Dr=0,Fn;(Fn=this.nextBreak(m,Dr))<m.length;)Dr=Fn,Kt++;return Dr<m.length&&Kt++,Kt};function En(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?Ue:m==10?et: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?it: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?bt:127462<=m&&m<=127487?Ut: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?Rt:4352<=m&&m<=4447||43360<=m&&m<=43388?pt:4448<=m&&m<=4519||55216<=m&&m<=55238?rr:4520<=m&&m<=4607||55243<=m&&m<=55291?mn: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?vn: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?Xn: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?Gr:127995<=m&&m<=127999?gr:m==8205?mi: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?Se:128102<=m&&m<=128105?X:cr}return this}fe.exports&&(fe.exports=xe)}),o=new i,s=function(xe,Ue,et){for(var it=o.iterateGraphemes(xe.substring(Ue)),bt="",Ut=0;Ut<et-Ue;Ut++){var Rt=it.next();if(bt+=Rt.value,Rt.done)break}return bt},a=function(fe,xe,Ue,et,it,bt,Ut){return{start:{line:fe,column:xe,offset:Ue},end:{line:et,column:it,offset:bt},source:Ut||null}},h=r(function(fe,xe){(function(Ue,et){fe.exports=et()})(t,function(){var Ue="",et,it=bt;function bt(Xn,cr){if(typeof Xn!="string")throw new TypeError("expected a string");if(cr===1)return Xn;if(cr===2)return Xn+Xn;var Mr=Xn.length*cr;if(et!==Xn||typeof et>"u")et=Xn,Ue="";else if(Ue.length>=Mr)return Ue.substr(0,Mr);for(;Mr>Ue.length&&cr>1;)cr&1&&(Ue+=Xn),cr>>=1,Xn+=Xn;return Ue+=Xn,Ue=Ue.substr(0,Mr),Ue}var Ut=function(cr,Mr,Gr){if(cr==null||Mr==null)return cr;var gr=String(cr),mi=typeof Mr=="number"?Mr:parseInt(Mr,10);if(isNaN(mi)||!isFinite(mi))return gr;var Se=gr.length;if(Se>=mi)return gr;var X=Gr==null?"":String(Gr);X===""&&(X=" ");for(var H=mi-Se;X.length<H;)X+=X;var Te=X.length>H?X.substr(0,H):X;return Te+gr},Rt=Object.assign||function(Xn){for(var cr=1;cr<arguments.length;cr++){var Mr=arguments[cr];for(var Gr in Mr)Object.prototype.hasOwnProperty.call(Mr,Gr)&&(Xn[Gr]=Mr[Gr])}return Xn};function pt(Xn,cr,Mr,Gr){var gr=String(cr),mi=Ut(gr,Mr," "),Se=it(" ",Gr.tabSize);return mi+" | "+Xn.replace(/\t/g,Se)}function rr(Xn,cr,Mr,Gr,gr){return Xn.slice(cr,Mr).map(function(mi,Se){return pt(mi,cr+Se+1,Gr,gr)}).join(`
`)}var mn={extraLines:2,tabSize:4},vn=function(cr,Mr,Gr,gr){gr=Rt({},mn,gr);var mi=cr.split(/\r\n?|\n|\f/),Se=Math.max(1,Mr-gr.extraLines)-1,X=Math.min(Mr+gr.extraLines,mi.length),H=String(X).length,Te=rr(mi,Se,Mr,H,gr),At=pt(mi[Mr-1].substring(0,Gr-1),Mr,H,gr),St=it(" ",At.length)+"^",Et=rr(mi,Mr,X,H,gr);return[Te,St,Et].filter(Boolean).join(`
`)};return vn})}),g=new Error().stack,C=function(fe){var xe=Object.create(SyntaxError.prototype);return Object.assign(xe,fe,{name:"SyntaxError"}),Object.defineProperty(xe,"stack",{get:function(){return g?g.replace(/^(.+\n){1,3}/,String(xe)+`
`):""}}),xe},B=function(fe,xe,Ue,et,it){throw C({message:et?fe+`
`+h(xe,et,it):fe,rawMessage:fe,source:Ue,line:et,column:it})},k={unexpectedEnd:function(){return"Unexpected end of input"},unexpectedToken:function(xe){for(var Ue=arguments.length,et=Array(Ue>1?Ue-1:0),it=1;it<Ue;it++)et[it-1]=arguments[it];return"Unexpected token <"+xe+"> at "+et.filter(Boolean).join(":")}},P={unexpectedSymbol:function(xe){for(var Ue=arguments.length,et=Array(Ue>1?Ue-1:0),it=1;it<Ue;it++)et[it-1]=arguments[it];return"Unexpected symbol <"+xe+"> at "+et.filter(Boolean).join(":")}},L={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},J={"{":L.LEFT_BRACE,"}":L.RIGHT_BRACE,"[":L.LEFT_BRACKET,"]":L.RIGHT_BRACKET,":":L.COLON,",":L.COMMA},N={true:L.TRUE,false:L.FALSE,null:L.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 ce(fe){return fe>="1"&&fe<="9"}function me(fe){return fe>="0"&&fe<="9"}function he(fe){return me(fe)||fe>="a"&&fe<="f"||fe>="A"&&fe<="F"}function V(fe){return fe==="e"||fe==="E"}function ae(fe,xe,Ue,et){var it=fe.charAt(xe);if(it==="\r")xe++,Ue++,et=1,fe.charAt(xe)===`
`&&xe++;else if(it===`
`)xe++,Ue++,et=1;else if(it===" "||it===" ")xe++,et++;else return null;return{index:xe,line:Ue,column:et}}function ye(fe,xe,Ue,et){var it=fe.charAt(xe);return it in J?{type:J[it],line:Ue,column:et+1,index:xe+1,value:null}:null}function Oe(fe,xe,Ue,et){for(var it in N)if(N.hasOwnProperty(it)&&fe.substr(xe,it.length)===it)return{type:N[it],line:Ue,column:et+it.length,index:xe+it.length,value:it};return null}function De(fe,xe,Ue,et){for(var it=xe,bt=$._START_;xe<fe.length;){var Ut=fe.charAt(xe);switch(bt){case $._START_:{if(Ut==='"')xe++,bt=$.START_QUOTE_OR_CHAR;else return null;break}case $.START_QUOTE_OR_CHAR:{if(Ut==="\\")xe++,bt=$.ESCAPE;else{if(Ut==='"')return xe++,{type:L.STRING,line:Ue,column:et+xe-it,index:xe,value:fe.slice(it,xe)};xe++}break}case $.ESCAPE:{if(Ut in q){if(xe++,Ut==="u")for(var Rt=0;Rt<4;Rt++){var pt=fe.charAt(xe);if(pt&&he(pt))xe++;else return null}bt=$.START_QUOTE_OR_CHAR}else return null;break}}}}function He(fe,xe,Ue,et){var it=xe,bt=xe,Ut=oe._START_;e:for(;xe<fe.length;){var Rt=fe.charAt(xe);switch(Ut){case oe._START_:{if(Rt==="-")Ut=oe.MINUS;else if(Rt==="0")bt=xe+1,Ut=oe.ZERO;else if(ce(Rt))bt=xe+1,Ut=oe.DIGIT;else return null;break}case oe.MINUS:{if(Rt==="0")bt=xe+1,Ut=oe.ZERO;else if(ce(Rt))bt=xe+1,Ut=oe.DIGIT;else return null;break}case oe.ZERO:{if(Rt===".")Ut=oe.POINT;else if(V(Rt))Ut=oe.EXP;else break e;break}case oe.DIGIT:{if(me(Rt))bt=xe+1;else if(Rt===".")Ut=oe.POINT;else if(V(Rt))Ut=oe.EXP;else break e;break}case oe.POINT:{if(me(Rt))bt=xe+1,Ut=oe.DIGIT_FRACTION;else break e;break}case oe.DIGIT_FRACTION:{if(me(Rt))bt=xe+1;else if(V(Rt))Ut=oe.EXP;else break e;break}case oe.EXP:{if(Rt==="+"||Rt==="-")Ut=oe.EXP_DIGIT_OR_SIGN;else if(me(Rt))bt=xe+1,Ut=oe.EXP_DIGIT_OR_SIGN;else break e;break}case oe.EXP_DIGIT_OR_SIGN:{if(me(Rt))bt=xe+1;else break e;break}}xe++}return bt>0?{type:L.NUMBER,line:Ue,column:et+bt-it,index:bt,value:fe.slice(it,bt)}:null}var ke=function(xe,Ue){for(var et=1,it=1,bt=0,Ut=[];bt<xe.length;){var Rt=[xe,bt,et,it],pt=ae.apply(void 0,Rt);if(pt){bt=pt.index,et=pt.line,it=pt.column;continue}var rr=ye.apply(void 0,Rt)||Oe.apply(void 0,Rt)||De.apply(void 0,Rt)||He.apply(void 0,Rt);if(rr){var mn={type:rr.type,value:rr.value,loc:a(et,it,bt,rr.line,rr.column,rr.index,Ue.source)};Ut.push(mn),bt=rr.index,et=rr.line,it=rr.column}else B(P.unexpectedSymbol(s(xe,bt,bt+1),Ue.source,et,it),xe,Ue.source,et,it)}return Ut},nt={_START_:0,OPEN_OBJECT:1,PROPERTY:2,COMMA:3},be={_START_:0,KEY:1,COLON:2},Bt={_START_:0,OPEN_ARRAY:1,VALUE:2,COMMA:3},kt={loc:!0,source:null};function Yt(fe,xe,Ue){var et=xe.length>0?xe[xe.length-1].loc.end:{line:1,column:1};B(k.unexpectedEnd(),fe,Ue.source,et.line,et.column)}function jt(fe){for(var xe=0,Ue=0;Ue<4;Ue++)xe=xe*16+parseInt(fe[Ue],16);return String.fromCharCode(xe)}var Xe={b:"\b",f:"\f",n:`
`,r:"\r",t:" "},rt=['"',"\\","/"];function ot(fe){for(var xe="",Ue=0;Ue<fe.length;Ue++){var et=fe.charAt(Ue);if(et==="\\"){Ue++;var it=fe.charAt(Ue);if(it==="u")xe+=jt(fe.substr(Ue+1,4)),Ue+=4;else if(rt.indexOf(it)!==-1)xe+=it;else if(it in Xe)xe+=Xe[it];else break}else xe+=et}return xe}function on(fe,xe,Ue,et){for(var it=void 0,bt={type:"Object",children:[]},Ut=nt._START_;Ue<xe.length;){var Rt=xe[Ue];switch(Ut){case nt._START_:{if(Rt.type===L.LEFT_BRACE)it=Rt,Ut=nt.OPEN_OBJECT,Ue++;else return null;break}case nt.OPEN_OBJECT:{if(Rt.type===L.RIGHT_BRACE)return et.loc&&(bt.loc=a(it.loc.start.line,it.loc.start.column,it.loc.start.offset,Rt.loc.end.line,Rt.loc.end.column,Rt.loc.end.offset,et.source)),{value:bt,index:Ue+1};var pt=gt(fe,xe,Ue,et);bt.children.push(pt.value),Ut=nt.PROPERTY,Ue=pt.index;break}case nt.PROPERTY:{if(Rt.type===L.RIGHT_BRACE)return et.loc&&(bt.loc=a(it.loc.start.line,it.loc.start.column,it.loc.start.offset,Rt.loc.end.line,Rt.loc.end.column,Rt.loc.end.offset,et.source)),{value:bt,index:Ue+1};Rt.type===L.COMMA?(Ut=nt.COMMA,Ue++):B(k.unexpectedToken(s(fe,Rt.loc.start.offset,Rt.loc.end.offset),et.source,Rt.loc.start.line,Rt.loc.start.column),fe,et.source,Rt.loc.start.line,Rt.loc.start.column);break}case nt.COMMA:{var rr=gt(fe,xe,Ue,et);rr?(Ue=rr.index,bt.children.push(rr.value),Ut=nt.PROPERTY):B(k.unexpectedToken(s(fe,Rt.loc.start.offset,Rt.loc.end.offset),et.source,Rt.loc.start.line,Rt.loc.start.column),fe,et.source,Rt.loc.start.line,Rt.loc.start.column);break}}}Yt(fe,xe,et)}function gt(fe,xe,Ue,et){for(var it=void 0,bt={type:"Property",key:null,value:null},Ut=be._START_;Ue<xe.length;){var Rt=xe[Ue];switch(Ut){case be._START_:{if(Rt.type===L.STRING){var pt={type:"Identifier",value:ot(fe.slice(Rt.loc.start.offset+1,Rt.loc.end.offset-1)),raw:Rt.value};et.loc&&(pt.loc=Rt.loc),it=Rt,bt.key=pt,Ut=be.KEY,Ue++}else return null;break}case be.KEY:{Rt.type===L.COLON?(Ut=be.COLON,Ue++):B(k.unexpectedToken(s(fe,Rt.loc.start.offset,Rt.loc.end.offset),et.source,Rt.loc.start.line,Rt.loc.start.column),fe,et.source,Rt.loc.start.line,Rt.loc.start.column);break}case be.COLON:{var rr=Lt(fe,xe,Ue,et);return bt.value=rr.value,et.loc&&(bt.loc=a(it.loc.start.line,it.loc.start.column,it.loc.start.offset,rr.value.loc.end.line,rr.value.loc.end.column,rr.value.loc.end.offset,et.source)),{value:bt,index:rr.index}}}}}function at(fe,xe,Ue,et){for(var it=void 0,bt={type:"Array",children:[]},Ut=Bt._START_,Rt=void 0;Ue<xe.length;)switch(Rt=xe[Ue],Ut){case Bt._START_:{if(Rt.type===L.LEFT_BRACKET)it=Rt,Ut=Bt.OPEN_ARRAY,Ue++;else return null;break}case Bt.OPEN_ARRAY:{if(Rt.type===L.RIGHT_BRACKET)return et.loc&&(bt.loc=a(it.loc.start.line,it.loc.start.column,it.loc.start.offset,Rt.loc.end.line,Rt.loc.end.column,Rt.loc.end.offset,et.source)),{value:bt,index:Ue+1};var pt=Lt(fe,xe,Ue,et);Ue=pt.index,bt.children.push(pt.value),Ut=Bt.VALUE;break}case Bt.VALUE:{if(Rt.type===L.RIGHT_BRACKET)return et.loc&&(bt.loc=a(it.loc.start.line,it.loc.start.column,it.loc.start.offset,Rt.loc.end.line,Rt.loc.end.column,Rt.loc.end.offset,et.source)),{value:bt,index:Ue+1};Rt.type===L.COMMA?(Ut=Bt.COMMA,Ue++):B(k.unexpectedToken(s(fe,Rt.loc.start.offset,Rt.loc.end.offset),et.source,Rt.loc.start.line,Rt.loc.start.column),fe,et.source,Rt.loc.start.line,Rt.loc.start.column);break}case Bt.COMMA:{var rr=Lt(fe,xe,Ue,et);Ue=rr.index,bt.children.push(rr.value),Ut=Bt.VALUE;break}}Yt(fe,xe,et)}function It(fe,xe,Ue,et){var it=xe[Ue],bt=null;switch(it.type){case L.STRING:{bt=ot(fe.slice(it.loc.start.offset+1,it.loc.end.offset-1));break}case L.NUMBER:{bt=Number(it.value);break}case L.TRUE:{bt=!0;break}case L.FALSE:{bt=!1;break}case L.NULL:{bt=null;break}default:return null}var Ut={type:"Literal",value:bt,raw:it.value};return et.loc&&(Ut.loc=it.loc),{value:Ut,index:Ue+1}}function Lt(fe,xe,Ue,et){var it=xe[Ue],bt=It.apply(void 0,arguments)||on.apply(void 0,arguments)||at.apply(void 0,arguments);if(bt)return bt;B(k.unexpectedToken(s(fe,it.loc.start.offset,it.loc.end.offset),et.source,it.loc.start.line,it.loc.start.column),fe,et.source,it.loc.start.line,it.loc.start.column)}var Me=function(fe,xe){xe=Object.assign({},kt,xe);var Ue=ke(fe,xe);Ue.length===0&&Yt(fe,Ue,xe);var et=Lt(fe,Ue,0,xe);if(et.index===Ue.length)return et.value;var it=Ue[et.index];B(k.unexpectedToken(s(fe,it.loc.start.offset,it.loc.end.offset),xe.source,it.loc.start.line,it.loc.start.column),fe,xe.source,it.loc.start.line,it.loc.start.column)};return Me})})(nN);var bme=nN.exports;const xme=fa(bme);function Bn(){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 Bn=function(){return s},s}Bn();Bn().s[0]++;Ic.defineMode("mgl",(e,n)=>(Bn().f[0]++,Bn().s[1]++,Ic.modes.javascript({...e,json:!0},n)));Bn().s[2]++;Ic.registerHelper("lint","json",e=>{Bn().f[1]++;const n=(Bn().s[3]++,[]);Bn().s[4]++,eO.parser.parseError=(t,r)=>{Bn().f[2]++;const i=(Bn().s[5]++,r.loc);Bn().s[6]++,n.push({from:Ic.Pos(i.first_line-1,i.first_column),to:Ic.Pos(i.last_line-1,i.last_column),message:t})},Bn().s[7]++;try{Bn().s[8]++,eO.parse(e)}catch{}return Bn().s[9]++,n});Bn().s[10]++;Ic.registerHelper("lint","mgl",(e,n,t)=>{Bn().f[3]++;const r=(Bn().s[11]++,[]),{parser:i}=(Bn().s[12]++,eO),{context:o}=(Bn().s[13]++,n);Bn().s[14]++,i.parseError=(C,B)=>{Bn().f[4]++;const k=(Bn().s[15]++,B.loc);Bn().s[16]++,r.push({from:Ic.Pos(k.first_line-1,k.first_column),to:Ic.Pos(k.last_line-1,k.last_column),message:C})},Bn().s[17]++;try{Bn().s[18]++,i.parse(e)}catch{}if(Bn().s[19]++,r.length>0)return Bn().b[0][0]++,Bn().s[20]++,r;Bn().b[0][1]++;const s=(Bn().s[21]++,xme(e)),a=(Bn().s[22]++,JSON.parse(e));function h(C,B){if(Bn().f[5]++,Bn().s[23]++,C){if(Bn().b[1][1]++,Bn().s[25]++,B.length<1)return Bn().b[2][0]++,Bn().s[26]++,C;if(Bn().b[2][1]++,Bn().s[27]++,C.children){Bn().b[3][1]++;const k=(Bn().s[29]++,B[0]);let P;return Bn().s[30]++,k.match(/^[0-9]+$/)?(Bn().b[4][0]++,Bn().s[31]++,P=C.children[B[0]]):(Bn().b[4][1]++,Bn().s[32]++,P=C.children.find(L=>(Bn().f[6]++,Bn().s[33]++,Bn().b[5][0]++,L.key&&(Bn().b[5][1]++,L.key.type==="Identifier")&&(Bn().b[5][2]++,L.key.value===k))),Bn().s[34]++,P?(Bn().b[6][0]++,Bn().s[35]++,P=P.value):Bn().b[6][1]++),Bn().s[36]++,h(P,B.slice(1))}else{Bn().b[3][0]++,Bn().s[28]++;return}}else{Bn().b[1][0]++,Bn().s[24]++;return}}let g=(Bn().s[37]++,null);if(Bn().s[38]++,o==="layer"){Bn().b[7][0]++;const C=(Bn().s[39]++,Sd({version:8,name:"Empty Style",metadata:{},sources:{},sprite:"",glyphs:"https://example.com/glyphs/{fontstack}/{range}.pbf",layers:[a]}));Bn().s[40]++,C?(Bn().b[8][0]++,Bn().s[41]++,g={result:"error",value:C.filter(B=>(Bn().f[7]++,Bn().s[42]++,!B.message.match(/^layers\[0\]: source ".*" not found$/))).map(B=>{Bn().f[8]++;const k=(Bn().s[43]++,B.message.replace(/^layers\[0\]./,"").split(":"));return Bn().s[44]++,{name:"",key:k[0],message:k[1]}})}):Bn().b[8][1]++}else if(Bn().b[7][1]++,Bn().s[45]++,o==="expression")Bn().b[9][0]++,Bn().s[46]++,g=sJ.createExpression(a,n.spec);else throw Bn().b[9][1]++,Bn().s[47]++,new Error(`Invalid context ${o}`);if(Bn().s[48]++,(g==null?void 0:g.result)==="error"){Bn().b[10][0]++;const C=(Bn().s[49]++,g.value);Bn().s[50]++,C.forEach(B=>{Bn().f[9]++;const{key:k,message:P}=(Bn().s[51]++,B);if(Bn().s[52]++,k)if(Bn().b[11][1]++,Bn().s[56]++,k){Bn().b[12][0]++;const L=(Bn().s[57]++,k.replace(/^\[|\]$/g,"").split(/\.|[[\]]+/).filter(Boolean)),J=(Bn().s[58]++,h(s,L));if(Bn().s[59]++,J)Bn().b[13][1]++;else{Bn().b[13][0]++,Bn().s[60]++,console.warn("Something went wrong parsing error:",B),Bn().s[61]++;return}const{loc:N}=(Bn().s[62]++,J),{start:$,end:q}=(Bn().s[63]++,N);Bn().s[64]++,r.push({from:Ic.Pos($.line-1,$.column),to:Ic.Pos(q.line-1,q.column),message:P})}else Bn().b[12][1]++;else{Bn().b[11][0]++;const L=(Bn().s[53]++,t.getLineHandle(t.lastLine())),J=(Bn().s[54]++,{from:Ic.Pos(t.firstLine(),0),to:Ic.Pos(t.lastLine(),L.text.length),message:P});Bn().s[55]++,r.push(J)}})}else Bn().b[10][1]++;return Bn().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 rN extends Sn.Component{constructor(t){Pn().f[5]++,Pn().s[4]++;super(t);an(this,"_keyEvent");an(this,"_doc");an(this,"_el",(Pn().s[2]++,null));an(this,"_cancelNextChange",(Pn().s[3]++,!1));an(this,"onPointerDown",(Pn().s[11]++,()=>{Pn().f[7]++,Pn().s[12]++,this._keyEvent="pointer"}));an(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"})}));an(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})}));an(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=Ic(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]++,G.jsxs("div",{className:"JSONEditor",onPointerDown:this.onPointerDown,"aria-hidden":"true",children:[G.jsxs("div",{className:bf("JSONEditor__message",{"JSONEditor__message--on":t}),children:["Press ",G.jsx("kbd",{children:"ESC"})," to lose focus"]}),G.jsx("div",{className:bf("codemirror-container",this.props.className),ref:i=>(Pn().f[14]++,Pn().s[51]++,this._el=i),style:r})]})}}an(rN,"defaultProps",(Pn().s[0]++,{lineNumbers:!0,lineWrapping:!1,gutters:["CodeMirror-lint-markers"],getValue:t=>(Pn().f[0]++,Pn().s[1]++,eN(t,{indent:2,maxLength:40})),onFocus:()=>{Pn().f[1]++},onBlur:()=>{Pn().f[2]++},onJSONInvalid:()=>{Pn().f[3]++},onJSONValid:()=>{Pn().f[4]++}}));function r4(){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 r4=function(){return s},s}r4();class M8 extends Sn.Component{render(){return r4().f[0]++,r4().s[0]++,G.jsx(rN,{...this.props})}}var SC="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",wme="M7,10L12,15L17,10H7Z",Mme="M7,15L12,10L17,15H7Z",S8="M22,10A2,2 0 0,1 20,12H4A2,2 0 0,1 2,10V3H4V5H8V3H10V5H14V3H16V5H20V3H22V10M4,10H8V7H4V10M10,10H14V7H10V10M20,10V7H16V10H20M11,14H13V17H16V19H13V22H11V19H8V17H11V14Z";function e1(){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 e1=function(){return s},s}e1();const E8=(e1().s[0]++,["all","any","none"]);e1().s[1]++;const Sme=(e1().s[2]++,Object.keys(no.filter_operator.values).filter(e=>(e1().f[0]++,e1().s[3]++,E8.indexOf(e)<0)));function Qr(){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 Qr=function(){return s},s}Qr();function Eme(e){return Qr().f[0]++,Qr().s[0]++,e===""?(Qr().b[0][0]++,Qr().s[1]++,e):(Qr().b[0][1]++,Qr().s[2]++,isNaN(e)?(Qr().b[1][0]++,Qr().s[3]++,e):(Qr().b[1][1]++,Qr().s[4]++,parseFloat(e)))}function Ome(e){Qr().f[1]++;const n=(Qr().s[5]++,typeof e=="string");if(Qr().s[6]++,n)Qr().b[2][1]++;else return Qr().b[2][0]++,Qr().s[7]++,e;return Qr().s[8]++,e.match(/^\s*true\s*$/)?(Qr().b[3][0]++,Qr().s[9]++,!0):(Qr().b[3][1]++,Qr().s[10]++,e.match(/^\s*false\s*$/)?(Qr().b[4][0]++,Qr().s[11]++,!1):(Qr().b[4][1]++,Qr().s[12]++,e))}function Bme(e){return Qr().f[2]++,Qr().s[13]++,e=Eme(e),Qr().s[14]++,e=Ome(e),Qr().s[15]++,e}class iN extends Sn.Component{onFilterPartChanged(n,t,r){Qr().f[3]++;let i=(Qr().s[17]++,[n,t,...r.map(Bme)]);Qr().s[18]++,Qr().b[6][0]++,n==="has"||(Qr().b[6][1]++,n==="!has")?(Qr().b[5][0]++,Qr().s[19]++,i=[n,t]):(Qr().b[5][1]++,Qr().s[20]++,r.length===0?(Qr().b[7][0]++,Qr().s[21]++,i=[n,t,""]):Qr().b[7][1]++),Qr().s[22]++,this.props.onChange(i)}render(){Qr().f[4]++;const n=(Qr().s[23]++,this.props.filter),t=(Qr().s[24]++,n[0]),r=(Qr().s[25]++,n[1]),i=(Qr().s[26]++,n.slice(2));return Qr().s[27]++,G.jsxs("div",{className:"maputnik-filter-editor-single",children:[G.jsx("div",{className:"maputnik-filter-editor-property",children:G.jsx(Hy,{"aria-label":"key",value:r,options:Object.keys(this.props.properties).map(o=>(Qr().f[5]++,Qr().s[28]++,[o,o])),onChange:o=>(Qr().f[6]++,Qr().s[29]++,this.onFilterPartChanged(t,o,i))})}),G.jsx("div",{className:"maputnik-filter-editor-operator",children:G.jsx(x1,{"aria-label":"function",value:t,onChange:o=>(Qr().f[7]++,Qr().s[30]++,this.onFilterPartChanged(o,r,i)),options:Sme})}),(Qr().b[8][0]++,i.length>0&&(Qr().b[8][1]++,G.jsx("div",{className:"maputnik-filter-editor-args",children:G.jsx(wd,{"aria-label":"value",value:i.join(","),onChange:o=>(Qr().f[8]++,Qr().s[31]++,this.onFilterPartChanged(t,r,o.split(",")))})})))]})}}an(iN,"defaultProps",(Qr().s[16]++,{properties:{}}));function i4(){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 i4=function(){return s},s}i4();class kme extends Sn.Component{render(){return i4().f[0]++,i4().s[0]++,G.jsxs("div",{className:"maputnik-filter-editor-block",children:[G.jsx("div",{className:"maputnik-filter-editor-block-action",children:G.jsx(ja,{className:"maputnik-delete-filter",onClick:this.props.onDelete,title:"Delete filter block",children:G.jsx(Ny,{})})}),G.jsx("div",{className:"maputnik-filter-editor-block-content",children:this.props.children})]})}}var Ime=1/0,Tme="[object Symbol]",O8="\\ud800-\\udfff",oN="\\u0300-\\u036f\\ufe20-\\ufe23",aN="\\u20d0-\\u20f0",sN="\\ufe0e\\ufe0f",Kme="["+O8+"]",tO="["+oN+aN+"]",nO="\\ud83c[\\udffb-\\udfff]",Pme="(?:"+tO+"|"+nO+")",lN="[^"+O8+"]",uN="(?:\\ud83c[\\udde6-\\uddff]){2}",AN="[\\ud800-\\udbff][\\udc00-\\udfff]",cN="\\u200d",dN=Pme+"?",hN="["+sN+"]?",Fme="(?:"+cN+"(?:"+[lN,uN,AN].join("|")+")"+hN+dN+")*",Dme=hN+dN+Fme,Lme="(?:"+[lN+tO+"?",tO,uN,AN,Kme].join("|")+")",Ume=RegExp(nO+"(?="+nO+")|"+Lme+Dme,"g"),Rme=RegExp("["+cN+O8+oN+aN+sN+"]"),zme=typeof window=="object"&&window&&window.Object===Object&&window,jme=typeof self=="object"&&self&&self.Object===Object&&self,Wme=zme||jme||Function("return this")();function Nme(e){return e.split("")}function fN(e){return Rme.test(e)}function Gme(e){return fN(e)?Qme(e):Nme(e)}function Qme(e){return e.match(Ume)||[]}var $me=Object.prototype,Yme=$me.toString,gK=Wme.Symbol,yK=gK?gK.prototype:void 0,vK=yK?yK.toString:void 0;function qme(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 Hme(e){if(typeof e=="string")return e;if(Jme(e))return vK?vK.call(e):"";var n=e+"";return n=="0"&&1/e==-Ime?"-0":n}function Vme(e,n,t){var r=e.length;return t=t===void 0?r:t,!n&&t>=r?e:qme(e,n,t)}function Zme(e){return function(n){n=pN(n);var t=fN(n)?Gme(n):void 0,r=t?t[0]:n.charAt(0),i=t?Vme(t,1).join(""):n.slice(1);return r[e]()+i}}function Xme(e){return!!e&&typeof e=="object"}function Jme(e){return typeof e=="symbol"||Xme(e)&&Yme.call(e)==Tme}function pN(e){return e==null?"":Hme(e)}function e0e(e){return t0e(pN(e).toLowerCase())}var t0e=Zme("toUpperCase"),n0e=e0e;const B8=fa(n0e);function Xh(){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 Xh=function(){return s},s}Xh();function z5(e){Xh().f[0]++;let n;const t=(Xh().s[0]++,e.split("-"));return Xh().s[1]++,t.length>1?(Xh().b[0][0]++,Xh().s[2]++,n=e.split("-").slice(1).join(" ")):(Xh().b[0][1]++,Xh().s[3]++,n=e),Xh().s[4]++,B8(n)}function zi(){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 zi=function(){return s},s}zi();class k8 extends Sn.Component{constructor(t){zi().f[2]++,zi().s[1]++;super(t);an(this,"onJSONInvalid",(zi().s[3]++,t=>{zi().f[3]++,zi().s[4]++,this.setState({jsonError:!0})}));an(this,"onJSONValid",(zi().s[5]++,()=>{zi().f[4]++,zi().s[6]++,this.setState({jsonError:!1})}));zi().s[2]++,this.state={jsonError:!1}}render(){zi().f[5]++;const{errors:t,fieldName:r,fieldType:i,value:o,canUndo:s}=(zi().s[7]++,this.props),{jsonError:a}=(zi().s[8]++,this.state),h=(zi().s[9]++,s?(zi().b[0][0]++,!s()):(zi().b[0][1]++,!0)),g=(zi().s[10]++,G.jsxs(G.Fragment,{children:[(zi().b[1][0]++,this.props.onUndo&&(zi().b[1][1]++,G.jsx(ja,{onClick:this.props.onUndo,disabled:h,className:"maputnik-delete-stop",title:"Revert from expression",children:G.jsx($J,{})},"undo_action"))),G.jsx(ja,{onClick:this.props.onDelete,className:"maputnik-delete-stop",title:"Delete expression",children:G.jsx(Ny,{})},"delete_action")]})),C=(zi().s[11]++,i===void 0?(zi().b[2][0]++,r):(zi().b[2][1]++,`${i}.${r}`)),B=(zi().s[12]++,t[C]),k=(zi().s[13]++,`${C}[`),P=(zi().s[14]++,[]);function L(J){return zi().f[6]++,zi().s[15]++,eN(J,{indent:2,maxLength:38})}return zi().s[16]++,a?(zi().b[3][0]++,zi().s[17]++,P.push({message:"Invalid JSON"})):(zi().b[3][1]++,zi().s[18]++,Object.entries(t).filter(([J,N])=>(zi().f[7]++,zi().s[19]++,J.startsWith(k))).forEach(([J,N])=>(zi().f[8]++,zi().s[20]++,P.push(N))),zi().s[21]++,B?(zi().b[4][0]++,zi().s[22]++,P.push(B)):zi().b[4][1]++),zi().s[23]++,G.jsx(ra,{error:P,fieldSpec:this.props.fieldSpec,label:z5(this.props.fieldName),action:g,wideMode:!0,children:G.jsx(M8,{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:L,onChange:this.props.onChange})})}}an(k8,"defaultProps",(zi().s[0]++,{errors:{},onFocus:()=>{zi().f[0]++},onBlur:()=>{zi().f[1]++}}));function fn(){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 fn=function(){return s},s}fn();function tm(e){fn().f[0]++;const n=(fn().s[0]++,fn().b[0][0]++,e.filter||(fn().b[0][1]++,["all"]));if(fn().s[1]++,Array.isArray(n))fn().b[1][1]++;else return fn().b[1][0]++,fn().s[2]++,n;let t=(fn().s[3]++,n[0]),r=(fn().s[4]++,n.slice(1));return fn().s[5]++,E8.indexOf(t)<0?(fn().b[2][0]++,fn().s[6]++,t="all",fn().s[7]++,r=[n.slice(0)]):fn().b[2][1]++,fn().s[8]++,[t,...r]}function r0e(e){return fn().f[1]++,fn().s[9]++,aJ(i0e(e)).layers[0].filter}function i0e(e){return fn().f[2]++,fn().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 o0e=(fn().s[11]++,["all","any","none"]);function _K(e){if(fn().f[3]++,fn().s[12]++,fn().b[4][0]++,e.length===1&&(fn().b[4][1]++,o0e.includes(e[0])))return fn().b[3][0]++,fn().s[13]++,!0;fn().b[3][1]++;const n=(fn().s[14]++,E_(e));return fn().s[15]++,!H4.isEqual(n,e)}function CK(e){return fn().f[4]++,fn().s[16]++,E8.indexOf(e[0])>=0}function a0e(e){return fn().f[5]++,fn().s[17]++,CK(e)?(fn().b[5][0]++,fn().s[18]++,e.slice(1).map(n=>(fn().f[6]++,fn().s[19]++,CK(n))).filter(n=>(fn().f[7]++,fn().s[20]++,n==!0)).length>0):(fn().b[5][1]++,fn().s[21]++,!1)}class mN extends Sn.Component{constructor(t){fn().f[8]++,fn().s[23]++;super(t);an(this,"addFilterItem",(fn().s[31]++,()=>{fn().f[11]++;const t=(fn().s[32]++,tm(this.props).slice(0));fn().s[33]++,t.push(["==","name",""]),fn().s[34]++,this.props.onChange(t)}));an(this,"onToggleDoc",(fn().s[35]++,t=>{fn().f[12]++,fn().s[36]++,this.setState({showDoc:t})}));an(this,"makeFilter",(fn().s[37]++,()=>{fn().f[13]++,fn().s[38]++,this.setState({displaySimpleFilter:!0})}));an(this,"makeExpression",(fn().s[39]++,()=>{fn().f[14]++;const t=(fn().s[40]++,tm(this.props));fn().s[41]++,this.props.onChange(r0e(t)),fn().s[42]++,this.setState({displaySimpleFilter:!1})}));fn().s[24]++,this.state={showDoc:!1,displaySimpleFilter:_K(tm(t))}}onFilterPartChanged(t,r){fn().f[9]++;const i=(fn().s[25]++,tm(this.props).slice(0));fn().s[26]++,i[t]=r,fn().s[27]++,this.props.onChange(i)}deleteFilterItem(t){fn().f[10]++;const r=(fn().s[28]++,tm(this.props).slice(0));fn().s[29]++,r.splice(t+1,1),fn().s[30]++,this.props.onChange(r)}static getDerivedStateFromProps(t,r){fn().f[15]++;const i=(fn().s[43]++,_K(tm(t)));return fn().s[44]++,fn().b[7][0]++,!i&&(fn().b[7][1]++,r.displaySimpleFilter===!0)?(fn().b[6][0]++,fn().s[45]++,{displaySimpleFilter:!1,valueIsSimpleFilter:!1}):(fn().b[6][1]++,fn().s[46]++,fn().b[9][0]++,i&&(fn().b[9][1]++,r.displaySimpleFilter===!1)?(fn().b[8][0]++,fn().s[47]++,{valueIsSimpleFilter:!0}):(fn().b[8][1]++,fn().s[48]++,{valueIsSimpleFilter:!1}))}render(){fn().f[16]++;const{errors:t}=(fn().s[49]++,this.props),{displaySimpleFilter:r}=(fn().s[50]++,this.state),i=(fn().s[51]++,{doc:Ea.layer.filter.doc+" Combine multiple filters together by using a compound filter."}),o=(fn().s[52]++,["all"]),s=(fn().s[53]++,fn().b[10][0]++,r&&(fn().b[10][1]++,a0e(tm(this.props))));if(fn().s[54]++,s)return fn().b[11][0]++,fn().s[55]++,G.jsxs("div",{className:"maputnik-filter-editor-unsupported",children:[G.jsx("p",{children:"Nested filters are not supported."}),G.jsxs(ja,{onClick:this.makeExpression,title:"Convert to expression",children:[G.jsx("svg",{style:{marginRight:"0.2em",width:"14px",height:"14px",verticalAlign:"middle"},viewBox:"0 0 24 24",children:G.jsx("path",{fill:"currentColor",d:SC})}),"Upgrade to expression"]})]});if(fn().b[11][1]++,fn().s[56]++,r){fn().b[12][0]++;const a=(fn().s[57]++,tm(this.props)),h=(fn().s[58]++,a[0]),g=(fn().s[59]++,a.slice(1)),C=(fn().s[60]++,G.jsx("div",{children:G.jsx(ja,{onClick:this.makeExpression,title:"Convert to expression",className:"maputnik-make-zoom-function",children:G.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"middle"},viewBox:"0 0 24 24",children:G.jsx("path",{fill:"currentColor",d:SC})})})})),B=(fn().s[61]++,g.map((k,P)=>{fn().f[17]++;const L=(fn().s[62]++,t[`filter[${P+1}]`]);return fn().s[63]++,G.jsxs("div",{children:[G.jsx(kme,{onDelete:this.deleteFilterItem.bind(this,P),children:G.jsx(iN,{properties:this.props.properties,filter:k,onChange:this.onFilterPartChanged.bind(this,P+1)})},P),(fn().b[13][0]++,L&&(fn().b[13][1]++,G.jsx("div",{className:"maputnik-inline-error",children:L.message},"error")))]},`block-${P}`)}));return fn().s[64]++,G.jsxs(G.Fragment,{children:[G.jsx(ra,{fieldSpec:i,label:"Filter",action:C,children:G.jsx(x1,{value:h,onChange:k=>(fn().f[18]++,fn().s[65]++,this.onFilterPartChanged(0,k)),options:[["all","every filter matches"],["none","no filter matches"],["any","any filter matches"]]})},"top"),B,G.jsx("div",{className:"maputnik-filter-editor-add-wrapper",children:G.jsxs(ja,{"data-wd-key":"layer-filter-button",className:"maputnik-add-filter",onClick:this.addFilterItem,children:[G.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:G.jsx("path",{fill:"currentColor",d:S8})})," Add filter"]})},"buttons"),G.jsx("div",{className:"maputnik-doc-inline",style:{display:this.state.showDoc?(fn().b[14][0]++,""):(fn().b[14][1]++,"none")},children:G.jsx(h8,{fieldSpec:i})},"doc")]})}else{fn().b[12][1]++;const{filter:a}=(fn().s[66]++,this.props);return fn().s[67]++,G.jsxs(G.Fragment,{children:[G.jsx(k8,{onDelete:()=>{fn().f[19]++,fn().s[68]++,this.setState({displaySimpleFilter:!0}),fn().s[69]++,this.props.onChange(o)},fieldName:"filter",fieldSpec:i,value:a,errors:t,onChange:this.props.onChange}),(fn().b[15][0]++,this.state.valueIsSimpleFilter&&(fn().b[15][1]++,G.jsxs("div",{className:"maputnik-expr-infobox",children:["You've entered a old style filter,"," ",G.jsx("button",{onClick:this.makeFilter,className:"maputnik-expr-infobox__button",children:"switch to filter editor"})]})))]})}}}an(mN,"defaultProps",(fn().s[22]++,{filter:["all"]}));var j5={},Ys={},rb={},s0e=typeof window=="object"&&window&&window.Object===Object&&window,gN=s0e,l0e=gN,u0e=typeof self=="object"&&self&&self.Object===Object&&self,A0e=l0e||u0e||Function("return this")(),ph=A0e,c0e=ph,d0e=c0e.Symbol,ib=d0e,bK=ib,yN=Object.prototype,h0e=yN.hasOwnProperty,f0e=yN.toString,Vv=bK?bK.toStringTag:void 0;function p0e(e){var n=h0e.call(e,Vv),t=e[Vv];try{e[Vv]=void 0;var r=!0}catch{}var i=f0e.call(e);return r&&(n?e[Vv]=t:delete e[Vv]),i}var m0e=p0e,g0e=Object.prototype,y0e=g0e.toString;function v0e(e){return y0e.call(e)}var _0e=v0e,xK=ib,C0e=m0e,b0e=_0e,x0e="[object Null]",w0e="[object Undefined]",wK=xK?xK.toStringTag:void 0;function M0e(e){return e==null?e===void 0?w0e:x0e:wK&&wK in Object(e)?C0e(e):b0e(e)}var w1=M0e,S0e=Array.isArray,jc=S0e;function E0e(e){return e!=null&&typeof e=="object"}var Bf=E0e,O0e=w1,B0e=jc,k0e=Bf,I0e="[object String]";function T0e(e){return typeof e=="string"||!B0e(e)&&k0e(e)&&O0e(e)==I0e}var K0e=T0e;function P0e(e){return function(n,t,r){for(var i=-1,o=Object(n),s=r(n),a=s.length;a--;){var h=s[e?a:++i];if(t(o[h],h,o)===!1)break}return n}}var F0e=P0e,D0e=F0e,L0e=D0e(),vN=L0e;function U0e(e,n){for(var t=-1,r=Array(e);++t<e;)r[t]=n(t);return r}var R0e=U0e,z0e=w1,j0e=Bf,W0e="[object Arguments]";function N0e(e){return j0e(e)&&z0e(e)==W0e}var G0e=N0e,MK=G0e,Q0e=Bf,_N=Object.prototype,$0e=_N.hasOwnProperty,Y0e=_N.propertyIsEnumerable,q0e=MK(function(){return arguments}())?MK:function(e){return Q0e(e)&&$0e.call(e,"callee")&&!Y0e.call(e,"callee")},I8=q0e,o4={exports:{}};function H0e(){return!1}var V0e=H0e;o4.exports;(function(e,n){var t=ph,r=V0e,i=n&&!n.nodeType&&n,o=i&&!0&&e&&!e.nodeType&&e,s=o&&o.exports===i,a=s?t.Buffer:void 0,h=a?a.isBuffer:void 0,g=h||r;e.exports=g})(o4,o4.exports);var W5=o4.exports,Z0e=9007199254740991,X0e=/^(?:0|[1-9]\d*)$/;function J0e(e,n){var t=typeof e;return n=n??Z0e,!!n&&(t=="number"||t!="symbol"&&X0e.test(e))&&e>-1&&e%1==0&&e<n}var T8=J0e,e1e=9007199254740991;function t1e(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=e1e}var K8=t1e,n1e=w1,r1e=K8,i1e=Bf,o1e="[object Arguments]",a1e="[object Array]",s1e="[object Boolean]",l1e="[object Date]",u1e="[object Error]",A1e="[object Function]",c1e="[object Map]",d1e="[object Number]",h1e="[object Object]",f1e="[object RegExp]",p1e="[object Set]",m1e="[object String]",g1e="[object WeakMap]",y1e="[object ArrayBuffer]",v1e="[object DataView]",_1e="[object Float32Array]",C1e="[object Float64Array]",b1e="[object Int8Array]",x1e="[object Int16Array]",w1e="[object Int32Array]",M1e="[object Uint8Array]",S1e="[object Uint8ClampedArray]",E1e="[object Uint16Array]",O1e="[object Uint32Array]",ms={};ms[_1e]=ms[C1e]=ms[b1e]=ms[x1e]=ms[w1e]=ms[M1e]=ms[S1e]=ms[E1e]=ms[O1e]=!0;ms[o1e]=ms[a1e]=ms[y1e]=ms[s1e]=ms[v1e]=ms[l1e]=ms[u1e]=ms[A1e]=ms[c1e]=ms[d1e]=ms[h1e]=ms[f1e]=ms[p1e]=ms[m1e]=ms[g1e]=!1;function B1e(e){return i1e(e)&&r1e(e.length)&&!!ms[n1e(e)]}var k1e=B1e;function I1e(e){return function(n){return e(n)}}var P8=I1e,a4={exports:{}};a4.exports;(function(e,n){var t=gN,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 h=i&&i.require&&i.require("util").types;return h||s&&s.binding&&s.binding("util")}catch{}}();e.exports=a})(a4,a4.exports);var F8=a4.exports,T1e=k1e,K1e=P8,SK=F8,EK=SK&&SK.isTypedArray,P1e=EK?K1e(EK):T1e,D8=P1e,F1e=R0e,D1e=I8,L1e=jc,U1e=W5,R1e=T8,z1e=D8,j1e=Object.prototype,W1e=j1e.hasOwnProperty;function N1e(e,n){var t=L1e(e),r=!t&&D1e(e),i=!t&&!r&&U1e(e),o=!t&&!r&&!i&&z1e(e),s=t||r||i||o,a=s?F1e(e.length,String):[],h=a.length;for(var g in e)(n||W1e.call(e,g))&&!(s&&(g=="length"||i&&(g=="offset"||g=="parent")||o&&(g=="buffer"||g=="byteLength"||g=="byteOffset")||R1e(g,h)))&&a.push(g);return a}var CN=N1e,G1e=Object.prototype;function Q1e(e){var n=e&&e.constructor,t=typeof n=="function"&&n.prototype||G1e;return e===t}var L8=Q1e;function $1e(e,n){return function(t){return e(n(t))}}var bN=$1e,Y1e=bN,q1e=Y1e(Object.keys,Object),H1e=q1e,V1e=L8,Z1e=H1e,X1e=Object.prototype,J1e=X1e.hasOwnProperty;function ege(e){if(!V1e(e))return Z1e(e);var n=[];for(var t in Object(e))J1e.call(e,t)&&t!="constructor"&&n.push(t);return n}var tge=ege;function nge(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")}var Ed=nge,rge=w1,ige=Ed,oge="[object AsyncFunction]",age="[object Function]",sge="[object GeneratorFunction]",lge="[object Proxy]";function uge(e){if(!ige(e))return!1;var n=rge(e);return n==age||n==sge||n==oge||n==lge}var U8=uge,Age=U8,cge=K8;function dge(e){return e!=null&&cge(e.length)&&!Age(e)}var Vy=dge,hge=CN,fge=tge,pge=Vy;function mge(e){return pge(e)?hge(e):fge(e)}var ob=mge,gge=vN,yge=ob;function vge(e,n){return e&&gge(e,n,yge)}var xN=vge;function _ge(e){return e}var N5=_ge,Cge=N5;function bge(e){return typeof e=="function"?e:Cge}var wN=bge,xge=xN,wge=wN;function Mge(e,n){return e&&xge(e,wge(n))}var R8=Mge,Sge=bN,Ege=Sge(Object.getPrototypeOf,Object),z8=Ege,Oge=w1,Bge=z8,kge=Bf,Ige="[object Object]",Tge=Function.prototype,Kge=Object.prototype,MN=Tge.toString,Pge=Kge.hasOwnProperty,Fge=MN.call(Object);function Dge(e){if(!kge(e)||Oge(e)!=Ige)return!1;var n=Bge(e);if(n===null)return!0;var t=Pge.call(n,"constructor")&&n.constructor;return typeof t=="function"&&t instanceof t&&MN.call(t)==Fge}var SN=Dge;function Lge(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 EN=Lge;function Uge(){this.__data__=[],this.size=0}var Rge=Uge;function zge(e,n){return e===n||e!==e&&n!==n}var ab=zge,jge=ab;function Wge(e,n){for(var t=e.length;t--;)if(jge(e[t][0],n))return t;return-1}var G5=Wge,Nge=G5,Gge=Array.prototype,Qge=Gge.splice;function $ge(e){var n=this.__data__,t=Nge(n,e);if(t<0)return!1;var r=n.length-1;return t==r?n.pop():Qge.call(n,t,1),--this.size,!0}var Yge=$ge,qge=G5;function Hge(e){var n=this.__data__,t=qge(n,e);return t<0?void 0:n[t][1]}var Vge=Hge,Zge=G5;function Xge(e){return Zge(this.__data__,e)>-1}var Jge=Xge,eye=G5;function tye(e,n){var t=this.__data__,r=eye(t,e);return r<0?(++this.size,t.push([e,n])):t[r][1]=n,this}var nye=tye,rye=Rge,iye=Yge,oye=Vge,aye=Jge,sye=nye;function Zy(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])}}Zy.prototype.clear=rye;Zy.prototype.delete=iye;Zy.prototype.get=oye;Zy.prototype.has=aye;Zy.prototype.set=sye;var Q5=Zy,lye=Q5;function uye(){this.__data__=new lye,this.size=0}var Aye=uye;function cye(e){var n=this.__data__,t=n.delete(e);return this.size=n.size,t}var dye=cye;function hye(e){return this.__data__.get(e)}var fye=hye;function pye(e){return this.__data__.has(e)}var mye=pye,gye=ph,yye=gye["__core-js_shared__"],vye=yye,nS=vye,OK=function(){var e=/[^.]+$/.exec(nS&&nS.keys&&nS.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function _ye(e){return!!OK&&OK in e}var Cye=_ye,bye=Function.prototype,xye=bye.toString;function wye(e){if(e!=null){try{return xye.call(e)}catch{}try{return e+""}catch{}}return""}var ON=wye,Mye=U8,Sye=Cye,Eye=Ed,Oye=ON,Bye=/[\\^$.*+?()[\]{}|]/g,kye=/^\[object .+?Constructor\]$/,Iye=Function.prototype,Tye=Object.prototype,Kye=Iye.toString,Pye=Tye.hasOwnProperty,Fye=RegExp("^"+Kye.call(Pye).replace(Bye,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Dye(e){if(!Eye(e)||Sye(e))return!1;var n=Mye(e)?Fye:kye;return n.test(Oye(e))}var Lye=Dye;function Uye(e,n){return e==null?void 0:e[n]}var Rye=Uye,zye=Lye,jye=Rye;function Wye(e,n){var t=jye(e,n);return zye(t)?t:void 0}var M1=Wye,Nye=M1,Gye=ph,Qye=Nye(Gye,"Map"),j8=Qye,$ye=M1,Yye=$ye(Object,"create"),$5=Yye,BK=$5;function qye(){this.__data__=BK?BK(null):{},this.size=0}var Hye=qye;function Vye(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n}var Zye=Vye,Xye=$5,Jye="__lodash_hash_undefined__",eve=Object.prototype,tve=eve.hasOwnProperty;function nve(e){var n=this.__data__;if(Xye){var t=n[e];return t===Jye?void 0:t}return tve.call(n,e)?n[e]:void 0}var rve=nve,ive=$5,ove=Object.prototype,ave=ove.hasOwnProperty;function sve(e){var n=this.__data__;return ive?n[e]!==void 0:ave.call(n,e)}var lve=sve,uve=$5,Ave="__lodash_hash_undefined__";function cve(e,n){var t=this.__data__;return this.size+=this.has(e)?0:1,t[e]=uve&&n===void 0?Ave:n,this}var dve=cve,hve=Hye,fve=Zye,pve=rve,mve=lve,gve=dve;function Xy(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])}}Xy.prototype.clear=hve;Xy.prototype.delete=fve;Xy.prototype.get=pve;Xy.prototype.has=mve;Xy.prototype.set=gve;var yve=Xy,kK=yve,vve=Q5,_ve=j8;function Cve(){this.size=0,this.__data__={hash:new kK,map:new(_ve||vve),string:new kK}}var bve=Cve;function xve(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null}var wve=xve,Mve=wve;function Sve(e,n){var t=e.__data__;return Mve(n)?t[typeof n=="string"?"string":"hash"]:t.map}var Y5=Sve,Eve=Y5;function Ove(e){var n=Eve(this,e).delete(e);return this.size-=n?1:0,n}var Bve=Ove,kve=Y5;function Ive(e){return kve(this,e).get(e)}var Tve=Ive,Kve=Y5;function Pve(e){return Kve(this,e).has(e)}var Fve=Pve,Dve=Y5;function Lve(e,n){var t=Dve(this,e),r=t.size;return t.set(e,n),this.size+=t.size==r?0:1,this}var Uve=Lve,Rve=bve,zve=Bve,jve=Tve,Wve=Fve,Nve=Uve;function Jy(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])}}Jy.prototype.clear=Rve;Jy.prototype.delete=zve;Jy.prototype.get=jve;Jy.prototype.has=Wve;Jy.prototype.set=Nve;var W8=Jy,Gve=Q5,Qve=j8,$ve=W8,Yve=200;function qve(e,n){var t=this.__data__;if(t instanceof Gve){var r=t.__data__;if(!Qve||r.length<Yve-1)return r.push([e,n]),this.size=++t.size,this;t=this.__data__=new $ve(r)}return t.set(e,n),this.size=t.size,this}var Hve=qve,Vve=Q5,Zve=Aye,Xve=dye,Jve=fye,e_e=mye,t_e=Hve;function ev(e){var n=this.__data__=new Vve(e);this.size=n.size}ev.prototype.clear=Zve;ev.prototype.delete=Xve;ev.prototype.get=Jve;ev.prototype.has=e_e;ev.prototype.set=t_e;var q5=ev,n_e="__lodash_hash_undefined__";function r_e(e){return this.__data__.set(e,n_e),this}var i_e=r_e;function o_e(e){return this.__data__.has(e)}var a_e=o_e,s_e=W8,l_e=i_e,u_e=a_e;function s4(e){var n=-1,t=e==null?0:e.length;for(this.__data__=new s_e;++n<t;)this.add(e[n])}s4.prototype.add=s4.prototype.push=l_e;s4.prototype.has=u_e;var A_e=s4;function c_e(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 d_e=c_e;function h_e(e,n){return e.has(n)}var f_e=h_e,p_e=A_e,m_e=d_e,g_e=f_e,y_e=1,v_e=2;function __e(e,n,t,r,i,o){var s=t&y_e,a=e.length,h=n.length;if(a!=h&&!(s&&h>a))return!1;var g=o.get(e),C=o.get(n);if(g&&C)return g==n&&C==e;var B=-1,k=!0,P=t&v_e?new p_e:void 0;for(o.set(e,n),o.set(n,e);++B<a;){var L=e[B],J=n[B];if(r)var N=s?r(J,L,B,n,e,o):r(L,J,B,e,n,o);if(N!==void 0){if(N)continue;k=!1;break}if(P){if(!m_e(n,function($,q){if(!g_e(P,q)&&(L===$||i(L,$,t,r,o)))return P.push(q)})){k=!1;break}}else if(!(L===J||i(L,J,t,r,o))){k=!1;break}}return o.delete(e),o.delete(n),k}var BN=__e,C_e=ph,b_e=C_e.Uint8Array,kN=b_e;function x_e(e){var n=-1,t=Array(e.size);return e.forEach(function(r,i){t[++n]=[i,r]}),t}var w_e=x_e;function M_e(e){var n=-1,t=Array(e.size);return e.forEach(function(r){t[++n]=r}),t}var S_e=M_e,IK=ib,TK=kN,E_e=ab,O_e=BN,B_e=w_e,k_e=S_e,I_e=1,T_e=2,K_e="[object Boolean]",P_e="[object Date]",F_e="[object Error]",D_e="[object Map]",L_e="[object Number]",U_e="[object RegExp]",R_e="[object Set]",z_e="[object String]",j_e="[object Symbol]",W_e="[object ArrayBuffer]",N_e="[object DataView]",KK=IK?IK.prototype:void 0,rS=KK?KK.valueOf:void 0;function G_e(e,n,t,r,i,o,s){switch(t){case N_e:if(e.byteLength!=n.byteLength||e.byteOffset!=n.byteOffset)return!1;e=e.buffer,n=n.buffer;case W_e:return!(e.byteLength!=n.byteLength||!o(new TK(e),new TK(n)));case K_e:case P_e:case L_e:return E_e(+e,+n);case F_e:return e.name==n.name&&e.message==n.message;case U_e:case z_e:return e==n+"";case D_e:var a=B_e;case R_e:var h=r&I_e;if(a||(a=k_e),e.size!=n.size&&!h)return!1;var g=s.get(e);if(g)return g==n;r|=T_e,s.set(e,n);var C=O_e(a(e),a(n),r,i,o,s);return s.delete(e),C;case j_e:if(rS)return rS.call(e)==rS.call(n)}return!1}var Q_e=G_e;function $_e(e,n){for(var t=-1,r=n.length,i=e.length;++t<r;)e[i+t]=n[t];return e}var IN=$_e,Y_e=IN,q_e=jc;function H_e(e,n,t){var r=n(e);return q_e(e)?r:Y_e(r,t(e))}var TN=H_e;function V_e(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 Z_e=V_e;function X_e(){return[]}var KN=X_e,J_e=Z_e,eCe=KN,tCe=Object.prototype,nCe=tCe.propertyIsEnumerable,PK=Object.getOwnPropertySymbols,rCe=PK?function(e){return e==null?[]:(e=Object(e),J_e(PK(e),function(n){return nCe.call(e,n)}))}:eCe,N8=rCe,iCe=TN,oCe=N8,aCe=ob;function sCe(e){return iCe(e,aCe,oCe)}var PN=sCe,FK=PN,lCe=1,uCe=Object.prototype,ACe=uCe.hasOwnProperty;function cCe(e,n,t,r,i,o){var s=t&lCe,a=FK(e),h=a.length,g=FK(n),C=g.length;if(h!=C&&!s)return!1;for(var B=h;B--;){var k=a[B];if(!(s?k in n:ACe.call(n,k)))return!1}var P=o.get(e),L=o.get(n);if(P&&L)return P==n&&L==e;var J=!0;o.set(e,n),o.set(n,e);for(var N=s;++B<h;){k=a[B];var $=e[k],q=n[k];if(r)var oe=s?r(q,$,k,n,e,o):r($,q,k,e,n,o);if(!(oe===void 0?$===q||i($,q,t,r,o):oe)){J=!1;break}N||(N=k=="constructor")}if(J&&!N){var ce=e.constructor,me=n.constructor;ce!=me&&"constructor"in e&&"constructor"in n&&!(typeof ce=="function"&&ce instanceof ce&&typeof me=="function"&&me instanceof me)&&(J=!1)}return o.delete(e),o.delete(n),J}var dCe=cCe,hCe=M1,fCe=ph,pCe=hCe(fCe,"DataView"),mCe=pCe,gCe=M1,yCe=ph,vCe=gCe(yCe,"Promise"),_Ce=vCe,CCe=M1,bCe=ph,xCe=CCe(bCe,"Set"),wCe=xCe,MCe=M1,SCe=ph,ECe=MCe(SCe,"WeakMap"),OCe=ECe,rO=mCe,iO=j8,oO=_Ce,aO=wCe,sO=OCe,FN=w1,tv=ON,DK="[object Map]",BCe="[object Object]",LK="[object Promise]",UK="[object Set]",RK="[object WeakMap]",zK="[object DataView]",kCe=tv(rO),ICe=tv(iO),TCe=tv(oO),KCe=tv(aO),PCe=tv(sO),E0=FN;(rO&&E0(new rO(new ArrayBuffer(1)))!=zK||iO&&E0(new iO)!=DK||oO&&E0(oO.resolve())!=LK||aO&&E0(new aO)!=UK||sO&&E0(new sO)!=RK)&&(E0=function(e){var n=FN(e),t=n==BCe?e.constructor:void 0,r=t?tv(t):"";if(r)switch(r){case kCe:return zK;case ICe:return DK;case TCe:return LK;case KCe:return UK;case PCe:return RK}return n});var H5=E0,iS=q5,FCe=BN,DCe=Q_e,LCe=dCe,jK=H5,WK=jc,NK=W5,UCe=D8,RCe=1,GK="[object Arguments]",QK="[object Array]",qx="[object Object]",zCe=Object.prototype,$K=zCe.hasOwnProperty;function jCe(e,n,t,r,i,o){var s=WK(e),a=WK(n),h=s?QK:jK(e),g=a?QK:jK(n);h=h==GK?qx:h,g=g==GK?qx:g;var C=h==qx,B=g==qx,k=h==g;if(k&&NK(e)){if(!NK(n))return!1;s=!0,C=!1}if(k&&!C)return o||(o=new iS),s||UCe(e)?FCe(e,n,t,r,i,o):DCe(e,n,h,t,r,i,o);if(!(t&RCe)){var P=C&&$K.call(e,"__wrapped__"),L=B&&$K.call(n,"__wrapped__");if(P||L){var J=P?e.value():e,N=L?n.value():n;return o||(o=new iS),i(J,N,t,r,o)}}return k?(o||(o=new iS),LCe(e,n,t,r,i,o)):!1}var WCe=jCe,NCe=WCe,YK=Bf;function DN(e,n,t,r,i){return e===n?!0:e==null||n==null||!YK(e)&&!YK(n)?e!==e&&n!==n:NCe(e,n,t,r,DN,i)}var LN=DN,GCe=q5,QCe=LN,$Ce=1,YCe=2;function qCe(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 h=a[0],g=e[h],C=a[1];if(s&&a[2]){if(g===void 0&&!(h in e))return!1}else{var B=new GCe;if(r)var k=r(g,C,h,e,n,B);if(!(k===void 0?QCe(C,g,$Ce|YCe,r,B):k))return!1}}return!0}var HCe=qCe,VCe=Ed;function ZCe(e){return e===e&&!VCe(e)}var UN=ZCe,XCe=UN,JCe=ob;function ebe(e){for(var n=JCe(e),t=n.length;t--;){var r=n[t],i=e[r];n[t]=[r,i,XCe(i)]}return n}var tbe=ebe;function nbe(e,n){return function(t){return t==null?!1:t[e]===n&&(n!==void 0||e in Object(t))}}var RN=nbe,rbe=HCe,ibe=tbe,obe=RN;function abe(e){var n=ibe(e);return n.length==1&&n[0][2]?obe(n[0][0],n[0][1]):function(t){return t===e||rbe(t,e,n)}}var sbe=abe,lbe=w1,ube=Bf,Abe="[object Symbol]";function cbe(e){return typeof e=="symbol"||ube(e)&&lbe(e)==Abe}var V5=cbe,dbe=jc,hbe=V5,fbe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,pbe=/^\w*$/;function mbe(e,n){if(dbe(e))return!1;var t=typeof e;return t=="number"||t=="symbol"||t=="boolean"||e==null||hbe(e)?!0:pbe.test(e)||!fbe.test(e)||n!=null&&e in Object(n)}var G8=mbe,zN=W8,gbe="Expected a function";function Q8(e,n){if(typeof e!="function"||n!=null&&typeof n!="function")throw new TypeError(gbe);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(Q8.Cache||zN),t}Q8.Cache=zN;var ybe=Q8,vbe=ybe,_be=500;function Cbe(e){var n=vbe(e,function(r){return t.size===_be&&t.clear(),r}),t=n.cache;return n}var bbe=Cbe,xbe=bbe,wbe=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Mbe=/\\(\\)?/g,Sbe=xbe(function(e){var n=[];return e.charCodeAt(0)===46&&n.push(""),e.replace(wbe,function(t,r,i,o){n.push(i?o.replace(Mbe,"$1"):r||t)}),n}),Ebe=Sbe,qK=ib,Obe=EN,Bbe=jc,kbe=V5,Ibe=1/0,HK=qK?qK.prototype:void 0,VK=HK?HK.toString:void 0;function jN(e){if(typeof e=="string")return e;if(Bbe(e))return Obe(e,jN)+"";if(kbe(e))return VK?VK.call(e):"";var n=e+"";return n=="0"&&1/e==-Ibe?"-0":n}var Tbe=jN,Kbe=Tbe;function Pbe(e){return e==null?"":Kbe(e)}var Fbe=Pbe,Dbe=jc,Lbe=G8,Ube=Ebe,Rbe=Fbe;function zbe(e,n){return Dbe(e)?e:Lbe(e,n)?[e]:Ube(Rbe(e))}var WN=zbe,jbe=V5,Wbe=1/0;function Nbe(e){if(typeof e=="string"||jbe(e))return e;var n=e+"";return n=="0"&&1/e==-Wbe?"-0":n}var Z5=Nbe,Gbe=WN,Qbe=Z5;function $be(e,n){n=Gbe(n,e);for(var t=0,r=n.length;e!=null&&t<r;)e=e[Qbe(n[t++])];return t&&t==r?e:void 0}var NN=$be,Ybe=NN;function qbe(e,n,t){var r=e==null?void 0:Ybe(e,n);return r===void 0?t:r}var Hbe=qbe;function Vbe(e,n){return e!=null&&n in Object(e)}var Zbe=Vbe,Xbe=WN,Jbe=I8,exe=jc,txe=T8,nxe=K8,rxe=Z5;function ixe(e,n,t){n=Xbe(n,e);for(var r=-1,i=n.length,o=!1;++r<i;){var s=rxe(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&&nxe(i)&&txe(s,i)&&(exe(e)||Jbe(e)))}var oxe=ixe,axe=Zbe,sxe=oxe;function lxe(e,n){return e!=null&&sxe(e,n,axe)}var uxe=lxe,Axe=LN,cxe=Hbe,dxe=uxe,hxe=G8,fxe=UN,pxe=RN,mxe=Z5,gxe=1,yxe=2;function vxe(e,n){return hxe(e)&&fxe(n)?pxe(mxe(e),n):function(t){var r=cxe(t,e);return r===void 0&&r===n?dxe(t,e):Axe(n,r,gxe|yxe)}}var _xe=vxe;function Cxe(e){return function(n){return n==null?void 0:n[e]}}var bxe=Cxe,xxe=NN;function wxe(e){return function(n){return xxe(n,e)}}var Mxe=wxe,Sxe=bxe,Exe=Mxe,Oxe=G8,Bxe=Z5;function kxe(e){return Oxe(e)?Sxe(Bxe(e)):Exe(e)}var Ixe=kxe,Txe=sbe,Kxe=_xe,Pxe=N5,Fxe=jc,Dxe=Ixe;function Lxe(e){return typeof e=="function"?e:e==null?Pxe:typeof e=="object"?Fxe(e)?Kxe(e[0],e[1]):Txe(e):Dxe(e)}var Uxe=Lxe,Rxe=Vy;function zxe(e,n){return function(t,r){if(t==null)return t;if(!Rxe(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 jxe=zxe,Wxe=xN,Nxe=jxe,Gxe=Nxe(Wxe),GN=Gxe,Qxe=GN,$xe=Vy;function Yxe(e,n){var t=-1,r=$xe(e)?Array(e.length):[];return Qxe(e,function(i,o,s){r[++t]=n(i,o,s)}),r}var qxe=Yxe,Hxe=EN,Vxe=Uxe,Zxe=qxe,Xxe=jc;function Jxe(e,n){var t=Xxe(e)?Hxe:Zxe;return t(e,Vxe(n))}var e2e=Jxe;Object.defineProperty(rb,"__esModule",{value:!0});rb.flattenNames=void 0;var t2e=K0e,n2e=X5(t2e),r2e=R8,i2e=X5(r2e),o2e=SN,a2e=X5(o2e),s2e=e2e,l2e=X5(s2e);function X5(e){return e&&e.__esModule?e:{default:e}}var u2e=rb.flattenNames=function e(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=[];return(0,l2e.default)(n,function(r){Array.isArray(r)?e(r).map(function(i){return t.push(i)}):(0,a2e.default)(r)?(0,i2e.default)(r,function(i,o){i===!0&&t.push(o),t.push(o+"-"+i)}):(0,n2e.default)(r)&&t.push(r)}),t};rb.default=u2e;var sb={};function A2e(e,n){for(var t=-1,r=e==null?0:e.length;++t<r&&n(e[t],t,e)!==!1;);return e}var QN=A2e,c2e=M1,d2e=function(){try{var e=c2e(Object,"defineProperty");return e({},"",{}),e}catch{}}(),$N=d2e,ZK=$N;function h2e(e,n,t){n=="__proto__"&&ZK?ZK(e,n,{configurable:!0,enumerable:!0,value:t,writable:!0}):e[n]=t}var $8=h2e,f2e=$8,p2e=ab,m2e=Object.prototype,g2e=m2e.hasOwnProperty;function y2e(e,n,t){var r=e[n];(!(g2e.call(e,n)&&p2e(r,t))||t===void 0&&!(n in e))&&f2e(e,n,t)}var YN=y2e,v2e=YN,_2e=$8;function C2e(e,n,t,r){var i=!t;t||(t={});for(var o=-1,s=n.length;++o<s;){var a=n[o],h=r?r(t[a],e[a],a,t,e):void 0;h===void 0&&(h=e[a]),i?_2e(t,a,h):v2e(t,a,h)}return t}var lb=C2e,b2e=lb,x2e=ob;function w2e(e,n){return e&&b2e(n,x2e(n),e)}var M2e=w2e;function S2e(e){var n=[];if(e!=null)for(var t in Object(e))n.push(t);return n}var E2e=S2e,O2e=Ed,B2e=L8,k2e=E2e,I2e=Object.prototype,T2e=I2e.hasOwnProperty;function K2e(e){if(!O2e(e))return k2e(e);var n=B2e(e),t=[];for(var r in e)r=="constructor"&&(n||!T2e.call(e,r))||t.push(r);return t}var P2e=K2e,F2e=CN,D2e=P2e,L2e=Vy;function U2e(e){return L2e(e)?F2e(e,!0):D2e(e)}var ub=U2e,R2e=lb,z2e=ub;function j2e(e,n){return e&&R2e(n,z2e(n),e)}var W2e=j2e,l4={exports:{}};l4.exports;(function(e,n){var t=ph,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 h(g,C){if(C)return g.slice();var B=g.length,k=a?a(B):new g.constructor(B);return g.copy(k),k}e.exports=h})(l4,l4.exports);var qN=l4.exports;function N2e(e,n){var t=-1,r=e.length;for(n||(n=Array(r));++t<r;)n[t]=e[t];return n}var HN=N2e,G2e=lb,Q2e=N8;function $2e(e,n){return G2e(e,Q2e(e),n)}var Y2e=$2e,q2e=IN,H2e=z8,V2e=N8,Z2e=KN,X2e=Object.getOwnPropertySymbols,J2e=X2e?function(e){for(var n=[];e;)q2e(n,V2e(e)),e=H2e(e);return n}:Z2e,VN=J2e,e3e=lb,t3e=VN;function n3e(e,n){return e3e(e,t3e(e),n)}var r3e=n3e,i3e=TN,o3e=VN,a3e=ub;function s3e(e){return i3e(e,a3e,o3e)}var l3e=s3e,u3e=Object.prototype,A3e=u3e.hasOwnProperty;function c3e(e){var n=e.length,t=new e.constructor(n);return n&&typeof e[0]=="string"&&A3e.call(e,"index")&&(t.index=e.index,t.input=e.input),t}var d3e=c3e,XK=kN;function h3e(e){var n=new e.constructor(e.byteLength);return new XK(n).set(new XK(e)),n}var Y8=h3e,f3e=Y8;function p3e(e,n){var t=n?f3e(e.buffer):e.buffer;return new e.constructor(t,e.byteOffset,e.byteLength)}var m3e=p3e,g3e=/\w*$/;function y3e(e){var n=new e.constructor(e.source,g3e.exec(e));return n.lastIndex=e.lastIndex,n}var v3e=y3e,JK=ib,eP=JK?JK.prototype:void 0,tP=eP?eP.valueOf:void 0;function _3e(e){return tP?Object(tP.call(e)):{}}var C3e=_3e,b3e=Y8;function x3e(e,n){var t=n?b3e(e.buffer):e.buffer;return new e.constructor(t,e.byteOffset,e.length)}var ZN=x3e,w3e=Y8,M3e=m3e,S3e=v3e,E3e=C3e,O3e=ZN,B3e="[object Boolean]",k3e="[object Date]",I3e="[object Map]",T3e="[object Number]",K3e="[object RegExp]",P3e="[object Set]",F3e="[object String]",D3e="[object Symbol]",L3e="[object ArrayBuffer]",U3e="[object DataView]",R3e="[object Float32Array]",z3e="[object Float64Array]",j3e="[object Int8Array]",W3e="[object Int16Array]",N3e="[object Int32Array]",G3e="[object Uint8Array]",Q3e="[object Uint8ClampedArray]",$3e="[object Uint16Array]",Y3e="[object Uint32Array]";function q3e(e,n,t){var r=e.constructor;switch(n){case L3e:return w3e(e);case B3e:case k3e:return new r(+e);case U3e:return M3e(e,t);case R3e:case z3e:case j3e:case W3e:case N3e:case G3e:case Q3e:case $3e:case Y3e:return O3e(e,t);case I3e:return new r;case T3e:case F3e:return new r(e);case K3e:return S3e(e);case P3e:return new r;case D3e:return E3e(e)}}var H3e=q3e,V3e=Ed,nP=Object.create,Z3e=function(){function e(){}return function(n){if(!V3e(n))return{};if(nP)return nP(n);e.prototype=n;var t=new e;return e.prototype=void 0,t}}(),X3e=Z3e,J3e=X3e,e4e=z8,t4e=L8;function n4e(e){return typeof e.constructor=="function"&&!t4e(e)?J3e(e4e(e)):{}}var XN=n4e,r4e=H5,i4e=Bf,o4e="[object Map]";function a4e(e){return i4e(e)&&r4e(e)==o4e}var s4e=a4e,l4e=s4e,u4e=P8,rP=F8,iP=rP&&rP.isMap,A4e=iP?u4e(iP):l4e,c4e=A4e,d4e=H5,h4e=Bf,f4e="[object Set]";function p4e(e){return h4e(e)&&d4e(e)==f4e}var m4e=p4e,g4e=m4e,y4e=P8,oP=F8,aP=oP&&oP.isSet,v4e=aP?y4e(aP):g4e,_4e=v4e,C4e=q5,b4e=QN,x4e=YN,w4e=M2e,M4e=W2e,S4e=qN,E4e=HN,O4e=Y2e,B4e=r3e,k4e=PN,I4e=l3e,T4e=H5,K4e=d3e,P4e=H3e,F4e=XN,D4e=jc,L4e=W5,U4e=c4e,R4e=Ed,z4e=_4e,j4e=ob,W4e=ub,N4e=1,G4e=2,Q4e=4,JN="[object Arguments]",$4e="[object Array]",Y4e="[object Boolean]",q4e="[object Date]",H4e="[object Error]",eG="[object Function]",V4e="[object GeneratorFunction]",Z4e="[object Map]",X4e="[object Number]",tG="[object Object]",J4e="[object RegExp]",e5e="[object Set]",t5e="[object String]",n5e="[object Symbol]",r5e="[object WeakMap]",i5e="[object ArrayBuffer]",o5e="[object DataView]",a5e="[object Float32Array]",s5e="[object Float64Array]",l5e="[object Int8Array]",u5e="[object Int16Array]",A5e="[object Int32Array]",c5e="[object Uint8Array]",d5e="[object Uint8ClampedArray]",h5e="[object Uint16Array]",f5e="[object Uint32Array]",ts={};ts[JN]=ts[$4e]=ts[i5e]=ts[o5e]=ts[Y4e]=ts[q4e]=ts[a5e]=ts[s5e]=ts[l5e]=ts[u5e]=ts[A5e]=ts[Z4e]=ts[X4e]=ts[tG]=ts[J4e]=ts[e5e]=ts[t5e]=ts[n5e]=ts[c5e]=ts[d5e]=ts[h5e]=ts[f5e]=!0;ts[H4e]=ts[eG]=ts[r5e]=!1;function O2(e,n,t,r,i,o){var s,a=n&N4e,h=n&G4e,g=n&Q4e;if(t&&(s=i?t(e,r,i,o):t(e)),s!==void 0)return s;if(!R4e(e))return e;var C=D4e(e);if(C){if(s=K4e(e),!a)return E4e(e,s)}else{var B=T4e(e),k=B==eG||B==V4e;if(L4e(e))return S4e(e,a);if(B==tG||B==JN||k&&!i){if(s=h||k?{}:F4e(e),!a)return h?B4e(e,M4e(s,e)):O4e(e,w4e(s,e))}else{if(!ts[B])return i?e:{};s=P4e(e,B,a)}}o||(o=new C4e);var P=o.get(e);if(P)return P;o.set(e,s),z4e(e)?e.forEach(function(N){s.add(O2(N,n,t,N,e,o))}):U4e(e)&&e.forEach(function(N,$){s.set($,O2(N,n,t,$,e,o))});var L=g?h?I4e:k4e:h?W4e:j4e,J=C?void 0:L(e);return b4e(J||e,function(N,$){J&&($=N,N=e[$]),x4e(s,$,O2(N,n,t,$,e,o))}),s}var p5e=O2,m5e=p5e,g5e=1,y5e=4;function v5e(e){return m5e(e,g5e|y5e)}var _5e=v5e;Object.defineProperty(sb,"__esModule",{value:!0});sb.mergeClasses=void 0;var C5e=R8,b5e=nG(C5e),x5e=_5e,w5e=nG(x5e),M5e=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 nG(e){return e&&e.__esModule?e:{default:e}}var S5e=sb.mergeClasses=function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=n.default&&(0,w5e.default)(n.default)||{};return t.map(function(i){var o=n[i];return o&&(0,b5e.default)(o,function(s,a){r[a]||(r[a]={}),r[a]=M5e({},r[a],o[a])}),i}),r};sb.default=S5e;var Ab={};Object.defineProperty(Ab,"__esModule",{value:!0});Ab.autoprefix=void 0;var E5e=R8,sP=B5e(E5e),O5e=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 B5e(e){return e&&e.__esModule?e:{default:e}}var k5e={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}}},I5e=Ab.autoprefix=function(n){var t={};return(0,sP.default)(n,function(r,i){var o={};(0,sP.default)(r,function(s,a){var h=k5e[a];h?o=O5e({},o,h(s)):o[a]=s}),t[i]=o}),t};Ab.default=I5e;var cb={};Object.defineProperty(cb,"__esModule",{value:!0});cb.hover=void 0;var T5e=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},K5e=Br,oS=P5e(K5e);function P5e(e){return e&&e.__esModule?e:{default:e}}function F5e(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function lP(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 D5e(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 L5e=cb.hover=function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"span";return function(r){D5e(i,r);function i(){var o,s,a,h;F5e(this,i);for(var g=arguments.length,C=Array(g),B=0;B<g;B++)C[B]=arguments[B];return h=(s=(a=lP(this,(o=i.__proto__||Object.getPrototypeOf(i)).call.apply(o,[this].concat(C))),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 oS.default.createElement(t,{onMouseOver:a.handleMouseOver,onMouseOut:a.handleMouseOut},oS.default.createElement(n,T5e({},a.props,a.state)))},s),lP(a,h)}return i}(oS.default.Component)};cb.default=L5e;var db={};Object.defineProperty(db,"__esModule",{value:!0});db.active=void 0;var U5e=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},R5e=Br,aS=z5e(R5e);function z5e(e){return e&&e.__esModule?e:{default:e}}function j5e(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function uP(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 W5e(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 N5e=db.active=function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"span";return function(r){W5e(i,r);function i(){var o,s,a,h;j5e(this,i);for(var g=arguments.length,C=Array(g),B=0;B<g;B++)C[B]=arguments[B];return h=(s=(a=uP(this,(o=i.__proto__||Object.getPrototypeOf(i)).call.apply(o,[this].concat(C))),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 aS.default.createElement(t,{onMouseDown:a.handleMouseDown,onMouseUp:a.handleMouseUp},aS.default.createElement(n,U5e({},a.props,a.state)))},s),uP(a,h)}return i}(aS.default.Component)};db.default=N5e;var q8={};Object.defineProperty(q8,"__esModule",{value:!0});var G5e=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};q8.default=G5e;Object.defineProperty(Ys,"__esModule",{value:!0});Ys.ReactCSS=Ys.loop=Ys.handleActive=Ys.handleHover=Ys.hover=void 0;var Q5e=rb,$5e=nv(Q5e),Y5e=sb,q5e=nv(Y5e),H5e=Ab,V5e=nv(H5e),Z5e=cb,rG=nv(Z5e),X5e=db,J5e=nv(X5e),ewe=q8,twe=nv(ewe);function nv(e){return e&&e.__esModule?e:{default:e}}Ys.hover=rG.default;Ys.handleHover=rG.default;Ys.handleActive=J5e.default;Ys.loop=twe.default;var nwe=Ys.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,$5e.default)(r),s=(0,q5e.default)(n,o);return(0,V5e.default)(s)};Ys.default=nwe;var rwe=$8,iwe=ab;function owe(e,n,t){(t!==void 0&&!iwe(e[n],t)||t===void 0&&!(n in e))&&rwe(e,n,t)}var iG=owe,awe=Vy,swe=Bf;function lwe(e){return swe(e)&&awe(e)}var uwe=lwe;function Awe(e,n){if(!(n==="constructor"&&typeof e[n]=="function")&&n!="__proto__")return e[n]}var oG=Awe,cwe=lb,dwe=ub;function hwe(e){return cwe(e,dwe(e))}var fwe=hwe,AP=iG,pwe=qN,mwe=ZN,gwe=HN,ywe=XN,cP=I8,dP=jc,vwe=uwe,_we=W5,Cwe=U8,bwe=Ed,xwe=SN,wwe=D8,hP=oG,Mwe=fwe;function Swe(e,n,t,r,i,o,s){var a=hP(e,t),h=hP(n,t),g=s.get(h);if(g){AP(e,t,g);return}var C=o?o(a,h,t+"",e,n,s):void 0,B=C===void 0;if(B){var k=dP(h),P=!k&&_we(h),L=!k&&!P&&wwe(h);C=h,k||P||L?dP(a)?C=a:vwe(a)?C=gwe(a):P?(B=!1,C=pwe(h,!0)):L?(B=!1,C=mwe(h,!0)):C=[]:xwe(h)||cP(h)?(C=a,cP(a)?C=Mwe(a):(!bwe(a)||Cwe(a))&&(C=ywe(h))):B=!1}B&&(s.set(h,C),i(C,h,r,o,s),s.delete(h)),AP(e,t,C)}var Ewe=Swe,Owe=q5,Bwe=iG,kwe=vN,Iwe=Ewe,Twe=Ed,Kwe=ub,Pwe=oG;function aG(e,n,t,r,i){e!==n&&kwe(n,function(o,s){if(i||(i=new Owe),Twe(o))Iwe(e,n,s,t,aG,r,i);else{var a=r?r(Pwe(e,s),o,s+"",e,n,i):void 0;a===void 0&&(a=o),Bwe(e,s,a)}},Kwe)}var Fwe=aG;function Dwe(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 Lwe=Dwe,Uwe=Lwe,fP=Math.max;function Rwe(e,n,t){return n=fP(n===void 0?e.length-1:n,0),function(){for(var r=arguments,i=-1,o=fP(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),Uwe(e,this,a)}}var zwe=Rwe;function jwe(e){return function(){return e}}var Wwe=jwe,Nwe=Wwe,pP=$N,Gwe=N5,Qwe=pP?function(e,n){return pP(e,"toString",{configurable:!0,enumerable:!1,value:Nwe(n),writable:!0})}:Gwe,$we=Qwe,Ywe=800,qwe=16,Hwe=Date.now;function Vwe(e){var n=0,t=0;return function(){var r=Hwe(),i=qwe-(r-t);if(t=r,i>0){if(++n>=Ywe)return arguments[0]}else n=0;return e.apply(void 0,arguments)}}var Zwe=Vwe,Xwe=$we,Jwe=Zwe,eMe=Jwe(Xwe),tMe=eMe,nMe=N5,rMe=zwe,iMe=tMe;function oMe(e,n){return iMe(rMe(e,n,nMe),e+"")}var aMe=oMe,sMe=ab,lMe=Vy,uMe=T8,AMe=Ed;function cMe(e,n,t){if(!AMe(t))return!1;var r=typeof n;return(r=="number"?lMe(t)&&uMe(n,t.length):r=="string"&&n in t)?sMe(t[n],e):!1}var dMe=cMe,hMe=aMe,fMe=dMe;function pMe(e){return hMe(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&&fMe(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 mMe=pMe,gMe=Fwe,yMe=mMe,vMe=yMe(function(e,n,t){gMe(e,n,t)}),sG=vMe,H8={},hb={},V8={};Object.defineProperty(V8,"__esModule",{value:!0});V8.calculateChange=function(n,t,r,i,o){var s=o.clientWidth,a=o.clientHeight,h=typeof n.pageX=="number"?n.pageX:n.touches[0].pageX,g=typeof n.pageY=="number"?n.pageY:n.touches[0].pageY,C=h-(o.getBoundingClientRect().left+window.pageXOffset),B=g-(o.getBoundingClientRect().top+window.pageYOffset);if(r==="vertical"){var k=void 0;if(B<0?k=0:B>a?k=1:k=Math.round(B*100/a)/100,t.a!==k)return{h:t.h,s:t.s,l:t.l,a:k,source:"rgb"}}else{var P=void 0;if(C<0?P=0:C>s?P=1:P=Math.round(C*100/s)/100,i!==P)return{h:t.h,s:t.s,l:t.l,a:P,source:"rgb"}}return null};var S1={},J5={};Object.defineProperty(J5,"__esModule",{value:!0});var sS={},_Me=J5.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};J5.get=function(n,t,r,i){var o=n+"-"+t+"-"+r+(i?"-server":"");if(sS[o])return sS[o];var s=_Me(n,t,r,i);return sS[o]=s,s};Object.defineProperty(S1,"__esModule",{value:!0});S1.Checkboard=void 0;var mP=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},lG=Br,gP=uG(lG),CMe=Ys,bMe=uG(CMe),xMe=J5,wMe=MMe(xMe);function MMe(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 uG(e){return e&&e.__esModule?e:{default:e}}var AG=S1.Checkboard=function(n){var t=n.white,r=n.grey,i=n.size,o=n.renderers,s=n.borderRadius,a=n.boxShadow,h=n.children,g=(0,bMe.default)({default:{grid:{borderRadius:s,boxShadow:a,absolute:"0px 0px 0px 0px",background:"url("+wMe.get(t,r,i,o.canvas)+") center left"}}});return(0,lG.isValidElement)(h)?gP.default.cloneElement(h,mP({},h.props,{style:mP({},h.props.style,g.grid)})):gP.default.createElement("div",{style:g.grid})};AG.defaultProps={size:8,white:"transparent",grey:"rgba(0,0,0,.08)",renderers:{}};S1.default=AG;Object.defineProperty(hb,"__esModule",{value:!0});hb.Alpha=void 0;var SMe=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},EMe=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}}(),lO=Br,nm=Z8(lO),OMe=Ys,BMe=Z8(OMe),kMe=V8,IMe=PMe(kMe),TMe=S1,KMe=Z8(TMe);function PMe(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 Z8(e){return e&&e.__esModule?e:{default:e}}function FMe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function yP(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 DMe(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 LMe=hb.Alpha=function(e){DMe(n,e);function n(){var t,r,i,o;FMe(this,n);for(var s=arguments.length,a=Array(s),h=0;h<s;h++)a[h]=arguments[h];return o=(r=(i=yP(this,(t=n.__proto__||Object.getPrototypeOf(n)).call.apply(t,[this].concat(a))),i),i.handleChange=function(g){var C=IMe.calculateChange(g,i.props.hsl,i.props.direction,i.props.a,i.container);C&&typeof i.props.onChange=="function"&&i.props.onChange(C,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),yP(i,o)}return EMe(n,[{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"render",value:function(){var r=this,i=this.props.rgb,o=(0,BMe.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:SMe({},this.props.style)},{vertical:this.props.direction==="vertical",overwrite:!0});return nm.default.createElement("div",{style:o.alpha},nm.default.createElement("div",{style:o.checkboard},nm.default.createElement(KMe.default,{renderers:this.props.renderers})),nm.default.createElement("div",{style:o.gradient}),nm.default.createElement("div",{style:o.container,ref:function(a){return r.container=a},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},nm.default.createElement("div",{style:o.pointer},this.props.pointer?nm.default.createElement(this.props.pointer,this.props):nm.default.createElement("div",{style:o.slider}))))}}]),n}(lO.PureComponent||lO.Component);hb.default=LMe;var fb={};Object.defineProperty(fb,"__esModule",{value:!0});fb.EditableInput=void 0;var UMe=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}}(),uO=Br,lS=cG(uO),RMe=Ys,zMe=cG(RMe);function cG(e){return e&&e.__esModule?e:{default:e}}function jMe(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function WMe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function NMe(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 GMe(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 QMe=1,dG=38,$Me=40,YMe=[dG,$Me],qMe=function(n){return YMe.indexOf(n)>-1},HMe=function(n){return Number(String(n).replace(/%/g,""))},VMe=1,ZMe=fb.EditableInput=function(e){GMe(n,e);function n(t){WMe(this,n);var r=NMe(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=HMe(i.target.value);if(!isNaN(o)&&qMe(i.keyCode)){var s=r.getArrowOffset(),a=i.keyCode===dG?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-"+VMe++,r}return UMe(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 jMe({},this.props.label,r)}},{key:"getArrowOffset",value:function(){return this.props.arrowOffset||QMe}},{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,zMe.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 lS.default.createElement("div",{style:i.wrap},lS.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?lS.default.createElement("label",{htmlFor:this.inputId,style:i.label,onMouseDown:this.handleMouseDown},this.props.label):null)}}]),n}(uO.PureComponent||uO.Component);fb.default=ZMe;var pb={},X8={};Object.defineProperty(X8,"__esModule",{value:!0});X8.calculateChange=function(n,t,r,i){var o=i.clientWidth,s=i.clientHeight,a=typeof n.pageX=="number"?n.pageX:n.touches[0].pageX,h=typeof n.pageY=="number"?n.pageY:n.touches[0].pageY,g=a-(i.getBoundingClientRect().left+window.pageXOffset),C=h-(i.getBoundingClientRect().top+window.pageYOffset);if(t==="vertical"){var B=void 0;if(C<0)B=359;else if(C>s)B=0;else{var k=-(C*100/s)+100;B=360*k/100}if(r.h!==B)return{h:B,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 L=g*100/o;P=360*L/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 XMe=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}}(),AO=Br,pg=hG(AO),JMe=Ys,eSe=hG(JMe),tSe=X8,nSe=rSe(tSe);function rSe(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 hG(e){return e&&e.__esModule?e:{default:e}}function iSe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function vP(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 oSe(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 aSe=pb.Hue=function(e){oSe(n,e);function n(){var t,r,i,o;iSe(this,n);for(var s=arguments.length,a=Array(s),h=0;h<s;h++)a[h]=arguments[h];return o=(r=(i=vP(this,(t=n.__proto__||Object.getPrototypeOf(n)).call.apply(t,[this].concat(a))),i),i.handleChange=function(g){var C=nSe.calculateChange(g,i.props.direction,i.props.hsl,i.container);C&&typeof i.props.onChange=="function"&&i.props.onChange(C,g)},i.handleMouseDown=function(g){i.handleChange(g),window.addEventListener("mousemove",i.handleChange),window.addEventListener("mouseup",i.handleMouseUp)},i.handleMouseUp=function(){i.unbindEventListeners()},r),vP(i,o)}return XMe(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,eSe.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 pg.default.createElement("div",{style:s.hue},pg.default.createElement("div",{className:"hue-"+o,style:s.container,ref:function(h){return r.container=h},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},pg.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%);
}
`),pg.default.createElement("div",{style:s.pointer},this.props.pointer?pg.default.createElement(this.props.pointer,this.props):pg.default.createElement("div",{style:s.slider}))))}}]),n}(AO.PureComponent||AO.Component);pb.default=aSe;var mb={};Object.defineProperty(mb,"__esModule",{value:!0});mb.Raised=void 0;var sSe=Br,uS=ew(sSe),lSe=hh,Hx=ew(lSe),uSe=Ys,ASe=ew(uSe),cSe=sG,dSe=ew(cSe);function ew(e){return e&&e.__esModule?e:{default:e}}var J8=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,h=(0,ASe.default)((0,dSe.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 uS.default.createElement("div",{style:h.wrap},uS.default.createElement("div",{style:h.bg}),uS.default.createElement("div",{style:h.content},o))};J8.propTypes={background:Hx.default.string,zDepth:Hx.default.oneOf([0,1,2,3,4,5]),radius:Hx.default.number,styles:Hx.default.object};J8.defaultProps={background:"#fff",zDepth:1,radius:2,styles:{}};mb.default=J8;var gb={},hSe=ph,fSe=function(){return hSe.Date.now()},pSe=fSe,mSe=/\s/;function gSe(e){for(var n=e.length;n--&&mSe.test(e.charAt(n)););return n}var ySe=gSe,vSe=ySe,_Se=/^\s+/;function CSe(e){return e&&e.slice(0,vSe(e)+1).replace(_Se,"")}var bSe=CSe,xSe=bSe,_P=Ed,wSe=V5,CP=NaN,MSe=/^[-+]0x[0-9a-f]+$/i,SSe=/^0b[01]+$/i,ESe=/^0o[0-7]+$/i,OSe=parseInt;function BSe(e){if(typeof e=="number")return e;if(wSe(e))return CP;if(_P(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=_P(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=xSe(e);var t=SSe.test(e);return t||ESe.test(e)?OSe(e.slice(2),t?2:8):MSe.test(e)?CP:+e}var kSe=BSe,ISe=Ed,AS=pSe,bP=kSe,TSe="Expected a function",KSe=Math.max,PSe=Math.min;function FSe(e,n,t){var r,i,o,s,a,h,g=0,C=!1,B=!1,k=!0;if(typeof e!="function")throw new TypeError(TSe);n=bP(n)||0,ISe(t)&&(C=!!t.leading,B="maxWait"in t,o=B?KSe(bP(t.maxWait)||0,n):o,k="trailing"in t?!!t.trailing:k);function P(he){var V=r,ae=i;return r=i=void 0,g=he,s=e.apply(ae,V),s}function L(he){return g=he,a=setTimeout($,n),C?P(he):s}function J(he){var V=he-h,ae=he-g,ye=n-V;return B?PSe(ye,o-ae):ye}function N(he){var V=he-h,ae=he-g;return h===void 0||V>=n||V<0||B&&ae>=o}function $(){var he=AS();if(N(he))return q(he);a=setTimeout($,J(he))}function q(he){return a=void 0,k&&r?P(he):(r=i=void 0,s)}function oe(){a!==void 0&&clearTimeout(a),g=0,r=h=i=a=void 0}function ce(){return a===void 0?s:q(AS())}function me(){var he=AS(),V=N(he);if(r=arguments,i=this,h=he,V){if(a===void 0)return L(h);if(B)return clearTimeout(a),a=setTimeout($,n),P(h)}return a===void 0&&(a=setTimeout($,n)),s}return me.cancel=oe,me.flush=ce,me}var fG=FSe,DSe=fG,LSe=Ed,USe="Expected a function";function RSe(e,n,t){var r=!0,i=!0;if(typeof e!="function")throw new TypeError(USe);return LSe(t)&&(r="leading"in t?!!t.leading:r,i="trailing"in t?!!t.trailing:i),DSe(e,n,{leading:r,maxWait:n,trailing:i})}var zSe=RSe,ek={};Object.defineProperty(ek,"__esModule",{value:!0});ek.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,h=typeof n.pageY=="number"?n.pageY:n.touches[0].pageY,g=a-(r.getBoundingClientRect().left+window.pageXOffset),C=h-(r.getBoundingClientRect().top+window.pageYOffset);g<0?g=0:g>o&&(g=o),C<0?C=0:C>s&&(C=s);var B=g/o,k=1-C/s;return{h:t.h,s:B,v:k,a:t.a,source:"hsv"}};Object.defineProperty(gb,"__esModule",{value:!0});gb.Saturation=void 0;var jSe=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}}(),cO=Br,b0=tk(cO),WSe=Ys,NSe=tk(WSe),GSe=zSe,QSe=tk(GSe),$Se=ek,YSe=qSe($Se);function qSe(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 tk(e){return e&&e.__esModule?e:{default:e}}function HSe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function VSe(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 ZSe(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 XSe=gb.Saturation=function(e){ZSe(n,e);function n(t){HSe(this,n);var r=VSe(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,t));return r.handleChange=function(i){typeof r.props.onChange=="function"&&r.throttle(r.props.onChange,YSe.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,QSe.default)(function(i,o,s){i(o,s)},50),r}return jSe(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,h=i.pointer,g=i.circle,C=(0,NSe.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:h,circle:g}},{custom:!!this.props.style});return b0.default.createElement("div",{style:C.color,ref:function(k){return r.container=k},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},b0.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));
}
`),b0.default.createElement("div",{style:C.white,className:"saturation-white"},b0.default.createElement("div",{style:C.black,className:"saturation-black"}),b0.default.createElement("div",{style:C.pointer},this.props.pointer?b0.default.createElement(this.props.pointer,this.props):b0.default.createElement("div",{style:C.circle}))))}}]),n}(cO.PureComponent||cO.Component);gb.default=XSe;var yb={},MA={},JSe=QN,e6e=GN,t6e=wN,n6e=jc;function r6e(e,n){var t=n6e(e)?JSe:e6e;return t(e,t6e(n))}var i6e=r6e,o6e=i6e,pG={exports:{}};(function(e,n){(function(t,r){e.exports=r()})(ch,function(){function t(Me){"@babel/helpers - typeof";return t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(fe){return typeof fe}:function(fe){return fe&&typeof Symbol=="function"&&fe.constructor===Symbol&&fe!==Symbol.prototype?"symbol":typeof fe},t(Me)}var r=/^\s+/,i=/\s+$/;function o(Me,fe){if(Me=Me||"",fe=fe||{},Me instanceof o)return Me;if(!(this instanceof o))return new o(Me,fe);var xe=s(Me);this._originalInput=Me,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=fe.format||xe.format,this._gradientType=fe.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 fe=this.toRgb();return(fe.r*299+fe.g*587+fe.b*114)/1e3},getLuminance:function(){var fe=this.toRgb(),xe,Ue,et,it,bt,Ut;return xe=fe.r/255,Ue=fe.g/255,et=fe.b/255,xe<=.03928?it=xe/12.92:it=Math.pow((xe+.055)/1.055,2.4),Ue<=.03928?bt=Ue/12.92:bt=Math.pow((Ue+.055)/1.055,2.4),et<=.03928?Ut=et/12.92:Ut=Math.pow((et+.055)/1.055,2.4),.2126*it+.7152*bt+.0722*Ut},setAlpha:function(fe){return this._a=nt(fe),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var fe=C(this._r,this._g,this._b);return{h:fe.h*360,s:fe.s,v:fe.v,a:this._a}},toHsvString:function(){var fe=C(this._r,this._g,this._b),xe=Math.round(fe.h*360),Ue=Math.round(fe.s*100),et=Math.round(fe.v*100);return this._a==1?"hsv("+xe+", "+Ue+"%, "+et+"%)":"hsva("+xe+", "+Ue+"%, "+et+"%, "+this._roundA+")"},toHsl:function(){var fe=h(this._r,this._g,this._b);return{h:fe.h*360,s:fe.s,l:fe.l,a:this._a}},toHslString:function(){var fe=h(this._r,this._g,this._b),xe=Math.round(fe.h*360),Ue=Math.round(fe.s*100),et=Math.round(fe.l*100);return this._a==1?"hsl("+xe+", "+Ue+"%, "+et+"%)":"hsla("+xe+", "+Ue+"%, "+et+"%, "+this._roundA+")"},toHex:function(fe){return k(this._r,this._g,this._b,fe)},toHexString:function(fe){return"#"+this.toHex(fe)},toHex8:function(fe){return P(this._r,this._g,this._b,this._a,fe)},toHex8String:function(fe){return"#"+this.toHex8(fe)},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(be(this._r,255)*100)+"%",g:Math.round(be(this._g,255)*100)+"%",b:Math.round(be(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(be(this._r,255)*100)+"%, "+Math.round(be(this._g,255)*100)+"%, "+Math.round(be(this._b,255)*100)+"%)":"rgba("+Math.round(be(this._r,255)*100)+"%, "+Math.round(be(this._g,255)*100)+"%, "+Math.round(be(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:He[k(this._r,this._g,this._b,!0)]||!1},toFilter:function(fe){var xe="#"+L(this._r,this._g,this._b,this._a),Ue=xe,et=this._gradientType?"GradientType = 1, ":"";if(fe){var it=o(fe);Ue="#"+L(it._r,it._g,it._b,it._a)}return"progid:DXImageTransform.Microsoft.gradient("+et+"startColorstr="+xe+",endColorstr="+Ue+")"},toString:function(fe){var xe=!!fe;fe=fe||this._format;var Ue=!1,et=this._a<1&&this._a>=0,it=!xe&&et&&(fe==="hex"||fe==="hex6"||fe==="hex3"||fe==="hex4"||fe==="hex8"||fe==="name");return it?fe==="name"&&this._a===0?this.toName():this.toRgbString():(fe==="rgb"&&(Ue=this.toRgbString()),fe==="prgb"&&(Ue=this.toPercentageRgbString()),(fe==="hex"||fe==="hex6")&&(Ue=this.toHexString()),fe==="hex3"&&(Ue=this.toHexString(!0)),fe==="hex4"&&(Ue=this.toHex8String(!0)),fe==="hex8"&&(Ue=this.toHex8String()),fe==="name"&&(Ue=this.toName()),fe==="hsl"&&(Ue=this.toHslString()),fe==="hsv"&&(Ue=this.toHsvString()),Ue||this.toHexString())},clone:function(){return o(this.toString())},_applyModification:function(fe,xe){var Ue=fe.apply(null,[this].concat([].slice.call(xe)));return this._r=Ue._r,this._g=Ue._g,this._b=Ue._b,this.setAlpha(Ue._a),this},lighten:function(){return this._applyModification(q,arguments)},brighten:function(){return this._applyModification(oe,arguments)},darken:function(){return this._applyModification(ce,arguments)},desaturate:function(){return this._applyModification(J,arguments)},saturate:function(){return this._applyModification(N,arguments)},greyscale:function(){return this._applyModification($,arguments)},spin:function(){return this._applyModification(me,arguments)},_applyCombination:function(fe,xe){return fe.apply(null,[this].concat([].slice.call(xe)))},analogous:function(){return this._applyCombination(ye,arguments)},complement:function(){return this._applyCombination(he,arguments)},monochromatic:function(){return this._applyCombination(Oe,arguments)},splitcomplement:function(){return this._applyCombination(ae,arguments)},triad:function(){return this._applyCombination(V,[3])},tetrad:function(){return this._applyCombination(V,[4])}},o.fromRatio=function(Me,fe){if(t(Me)=="object"){var xe={};for(var Ue in Me)Me.hasOwnProperty(Ue)&&(Ue==="a"?xe[Ue]=Me[Ue]:xe[Ue]=rt(Me[Ue]));Me=xe}return o(Me,fe)};function s(Me){var fe={r:0,g:0,b:0},xe=1,Ue=null,et=null,it=null,bt=!1,Ut=!1;return typeof Me=="string"&&(Me=It(Me)),t(Me)=="object"&&(at(Me.r)&&at(Me.g)&&at(Me.b)?(fe=a(Me.r,Me.g,Me.b),bt=!0,Ut=String(Me.r).substr(-1)==="%"?"prgb":"rgb"):at(Me.h)&&at(Me.s)&&at(Me.v)?(Ue=rt(Me.s),et=rt(Me.v),fe=B(Me.h,Ue,et),bt=!0,Ut="hsv"):at(Me.h)&&at(Me.s)&&at(Me.l)&&(Ue=rt(Me.s),it=rt(Me.l),fe=g(Me.h,Ue,it),bt=!0,Ut="hsl"),Me.hasOwnProperty("a")&&(xe=Me.a)),xe=nt(xe),{ok:bt,format:Me.format||Ut,r:Math.min(255,Math.max(fe.r,0)),g:Math.min(255,Math.max(fe.g,0)),b:Math.min(255,Math.max(fe.b,0)),a:xe}}function a(Me,fe,xe){return{r:be(Me,255)*255,g:be(fe,255)*255,b:be(xe,255)*255}}function h(Me,fe,xe){Me=be(Me,255),fe=be(fe,255),xe=be(xe,255);var Ue=Math.max(Me,fe,xe),et=Math.min(Me,fe,xe),it,bt,Ut=(Ue+et)/2;if(Ue==et)it=bt=0;else{var Rt=Ue-et;switch(bt=Ut>.5?Rt/(2-Ue-et):Rt/(Ue+et),Ue){case Me:it=(fe-xe)/Rt+(fe<xe?6:0);break;case fe:it=(xe-Me)/Rt+2;break;case xe:it=(Me-fe)/Rt+4;break}it/=6}return{h:it,s:bt,l:Ut}}function g(Me,fe,xe){var Ue,et,it;Me=be(Me,360),fe=be(fe,100),xe=be(xe,100);function bt(pt,rr,mn){return mn<0&&(mn+=1),mn>1&&(mn-=1),mn<1/6?pt+(rr-pt)*6*mn:mn<1/2?rr:mn<2/3?pt+(rr-pt)*(2/3-mn)*6:pt}if(fe===0)Ue=et=it=xe;else{var Ut=xe<.5?xe*(1+fe):xe+fe-xe*fe,Rt=2*xe-Ut;Ue=bt(Rt,Ut,Me+1/3),et=bt(Rt,Ut,Me),it=bt(Rt,Ut,Me-1/3)}return{r:Ue*255,g:et*255,b:it*255}}function C(Me,fe,xe){Me=be(Me,255),fe=be(fe,255),xe=be(xe,255);var Ue=Math.max(Me,fe,xe),et=Math.min(Me,fe,xe),it,bt,Ut=Ue,Rt=Ue-et;if(bt=Ue===0?0:Rt/Ue,Ue==et)it=0;else{switch(Ue){case Me:it=(fe-xe)/Rt+(fe<xe?6:0);break;case fe:it=(xe-Me)/Rt+2;break;case xe:it=(Me-fe)/Rt+4;break}it/=6}return{h:it,s:bt,v:Ut}}function B(Me,fe,xe){Me=be(Me,360)*6,fe=be(fe,100),xe=be(xe,100);var Ue=Math.floor(Me),et=Me-Ue,it=xe*(1-fe),bt=xe*(1-et*fe),Ut=xe*(1-(1-et)*fe),Rt=Ue%6,pt=[xe,bt,it,it,Ut,xe][Rt],rr=[Ut,xe,xe,bt,it,it][Rt],mn=[it,it,Ut,xe,xe,bt][Rt];return{r:pt*255,g:rr*255,b:mn*255}}function k(Me,fe,xe,Ue){var et=[Xe(Math.round(Me).toString(16)),Xe(Math.round(fe).toString(16)),Xe(Math.round(xe).toString(16))];return Ue&&et[0].charAt(0)==et[0].charAt(1)&&et[1].charAt(0)==et[1].charAt(1)&&et[2].charAt(0)==et[2].charAt(1)?et[0].charAt(0)+et[1].charAt(0)+et[2].charAt(0):et.join("")}function P(Me,fe,xe,Ue,et){var it=[Xe(Math.round(Me).toString(16)),Xe(Math.round(fe).toString(16)),Xe(Math.round(xe).toString(16)),Xe(ot(Ue))];return et&&it[0].charAt(0)==it[0].charAt(1)&&it[1].charAt(0)==it[1].charAt(1)&&it[2].charAt(0)==it[2].charAt(1)&&it[3].charAt(0)==it[3].charAt(1)?it[0].charAt(0)+it[1].charAt(0)+it[2].charAt(0)+it[3].charAt(0):it.join("")}function L(Me,fe,xe,Ue){var et=[Xe(ot(Ue)),Xe(Math.round(Me).toString(16)),Xe(Math.round(fe).toString(16)),Xe(Math.round(xe).toString(16))];return et.join("")}o.equals=function(Me,fe){return!Me||!fe?!1:o(Me).toRgbString()==o(fe).toRgbString()},o.random=function(){return o.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function J(Me,fe){fe=fe===0?0:fe||10;var xe=o(Me).toHsl();return xe.s-=fe/100,xe.s=Bt(xe.s),o(xe)}function N(Me,fe){fe=fe===0?0:fe||10;var xe=o(Me).toHsl();return xe.s+=fe/100,xe.s=Bt(xe.s),o(xe)}function $(Me){return o(Me).desaturate(100)}function q(Me,fe){fe=fe===0?0:fe||10;var xe=o(Me).toHsl();return xe.l+=fe/100,xe.l=Bt(xe.l),o(xe)}function oe(Me,fe){fe=fe===0?0:fe||10;var xe=o(Me).toRgb();return xe.r=Math.max(0,Math.min(255,xe.r-Math.round(255*-(fe/100)))),xe.g=Math.max(0,Math.min(255,xe.g-Math.round(255*-(fe/100)))),xe.b=Math.max(0,Math.min(255,xe.b-Math.round(255*-(fe/100)))),o(xe)}function ce(Me,fe){fe=fe===0?0:fe||10;var xe=o(Me).toHsl();return xe.l-=fe/100,xe.l=Bt(xe.l),o(xe)}function me(Me,fe){var xe=o(Me).toHsl(),Ue=(xe.h+fe)%360;return xe.h=Ue<0?360+Ue:Ue,o(xe)}function he(Me){var fe=o(Me).toHsl();return fe.h=(fe.h+180)%360,o(fe)}function V(Me,fe){if(isNaN(fe)||fe<=0)throw new Error("Argument to polyad must be a positive number");for(var xe=o(Me).toHsl(),Ue=[o(Me)],et=360/fe,it=1;it<fe;it++)Ue.push(o({h:(xe.h+it*et)%360,s:xe.s,l:xe.l}));return Ue}function ae(Me){var fe=o(Me).toHsl(),xe=fe.h;return[o(Me),o({h:(xe+72)%360,s:fe.s,l:fe.l}),o({h:(xe+216)%360,s:fe.s,l:fe.l})]}function ye(Me,fe,xe){fe=fe||6,xe=xe||30;var Ue=o(Me).toHsl(),et=360/xe,it=[o(Me)];for(Ue.h=(Ue.h-(et*fe>>1)+720)%360;--fe;)Ue.h=(Ue.h+et)%360,it.push(o(Ue));return it}function Oe(Me,fe){fe=fe||6;for(var xe=o(Me).toHsv(),Ue=xe.h,et=xe.s,it=xe.v,bt=[],Ut=1/fe;fe--;)bt.push(o({h:Ue,s:et,v:it})),it=(it+Ut)%1;return bt}o.mix=function(Me,fe,xe){xe=xe===0?0:xe||50;var Ue=o(Me).toRgb(),et=o(fe).toRgb(),it=xe/100,bt={r:(et.r-Ue.r)*it+Ue.r,g:(et.g-Ue.g)*it+Ue.g,b:(et.b-Ue.b)*it+Ue.b,a:(et.a-Ue.a)*it+Ue.a};return o(bt)},o.readability=function(Me,fe){var xe=o(Me),Ue=o(fe);return(Math.max(xe.getLuminance(),Ue.getLuminance())+.05)/(Math.min(xe.getLuminance(),Ue.getLuminance())+.05)},o.isReadable=function(Me,fe,xe){var Ue=o.readability(Me,fe),et,it;switch(it=!1,et=Lt(xe),et.level+et.size){case"AAsmall":case"AAAlarge":it=Ue>=4.5;break;case"AAlarge":it=Ue>=3;break;case"AAAsmall":it=Ue>=7;break}return it},o.mostReadable=function(Me,fe,xe){var Ue=null,et=0,it,bt,Ut,Rt;xe=xe||{},bt=xe.includeFallbackColors,Ut=xe.level,Rt=xe.size;for(var pt=0;pt<fe.length;pt++)it=o.readability(Me,fe[pt]),it>et&&(et=it,Ue=o(fe[pt]));return o.isReadable(Me,Ue,{level:Ut,size:Rt})||!bt?Ue:(xe.includeFallbackColors=!1,o.mostReadable(Me,["#fff","#000"],xe))};var De=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"},He=o.hexNames=ke(De);function ke(Me){var fe={};for(var xe in Me)Me.hasOwnProperty(xe)&&(fe[Me[xe]]=xe);return fe}function nt(Me){return Me=parseFloat(Me),(isNaN(Me)||Me<0||Me>1)&&(Me=1),Me}function be(Me,fe){Yt(Me)&&(Me="100%");var xe=jt(Me);return Me=Math.min(fe,Math.max(0,parseFloat(Me))),xe&&(Me=parseInt(Me*fe,10)/100),Math.abs(Me-fe)<1e-6?1:Me%fe/parseFloat(fe)}function Bt(Me){return Math.min(1,Math.max(0,Me))}function kt(Me){return parseInt(Me,16)}function Yt(Me){return typeof Me=="string"&&Me.indexOf(".")!=-1&&parseFloat(Me)===1}function jt(Me){return typeof Me=="string"&&Me.indexOf("%")!=-1}function Xe(Me){return Me.length==1?"0"+Me:""+Me}function rt(Me){return Me<=1&&(Me=Me*100+"%"),Me}function ot(Me){return Math.round(parseFloat(Me)*255).toString(16)}function on(Me){return kt(Me)/255}var gt=function(){var Me="[-\\+]?\\d+%?",fe="[-\\+]?\\d*\\.\\d+%?",xe="(?:"+fe+")|(?:"+Me+")",Ue="[\\s|\\(]+("+xe+")[,|\\s]+("+xe+")[,|\\s]+("+xe+")\\s*\\)?",et="[\\s|\\(]+("+xe+")[,|\\s]+("+xe+")[,|\\s]+("+xe+")[,|\\s]+("+xe+")\\s*\\)?";return{CSS_UNIT:new RegExp(xe),rgb:new RegExp("rgb"+Ue),rgba:new RegExp("rgba"+et),hsl:new RegExp("hsl"+Ue),hsla:new RegExp("hsla"+et),hsv:new RegExp("hsv"+Ue),hsva:new RegExp("hsva"+et),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 at(Me){return!!gt.CSS_UNIT.exec(Me)}function It(Me){Me=Me.replace(r,"").replace(i,"").toLowerCase();var fe=!1;if(De[Me])Me=De[Me],fe=!0;else if(Me=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var xe;return(xe=gt.rgb.exec(Me))?{r:xe[1],g:xe[2],b:xe[3]}:(xe=gt.rgba.exec(Me))?{r:xe[1],g:xe[2],b:xe[3],a:xe[4]}:(xe=gt.hsl.exec(Me))?{h:xe[1],s:xe[2],l:xe[3]}:(xe=gt.hsla.exec(Me))?{h:xe[1],s:xe[2],l:xe[3],a:xe[4]}:(xe=gt.hsv.exec(Me))?{h:xe[1],s:xe[2],v:xe[3]}:(xe=gt.hsva.exec(Me))?{h:xe[1],s:xe[2],v:xe[3],a:xe[4]}:(xe=gt.hex8.exec(Me))?{r:kt(xe[1]),g:kt(xe[2]),b:kt(xe[3]),a:on(xe[4]),format:fe?"name":"hex8"}:(xe=gt.hex6.exec(Me))?{r:kt(xe[1]),g:kt(xe[2]),b:kt(xe[3]),format:fe?"name":"hex"}:(xe=gt.hex4.exec(Me))?{r:kt(xe[1]+""+xe[1]),g:kt(xe[2]+""+xe[2]),b:kt(xe[3]+""+xe[3]),a:on(xe[4]+""+xe[4]),format:fe?"name":"hex8"}:(xe=gt.hex3.exec(Me))?{r:kt(xe[1]+""+xe[1]),g:kt(xe[2]+""+xe[2]),b:kt(xe[3]+""+xe[3]),format:fe?"name":"hex"}:!1}function Lt(Me){var fe,xe;return Me=Me||{level:"AA",size:"small"},fe=(Me.level||"AA").toUpperCase(),xe=(Me.size||"small").toLowerCase(),fe!=="AA"&&fe!=="AAA"&&(fe="AA"),xe!=="small"&&xe!=="large"&&(xe="small"),{level:fe,size:xe}}return o})})(pG);var a6e=pG.exports;Object.defineProperty(MA,"__esModule",{value:!0});MA.isvalidColorString=MA.red=MA.getContrastingColor=MA.isValidHex=MA.toState=MA.simpleCheckForValidColor=void 0;var s6e=o6e,l6e=mG(s6e),u6e=a6e,u4=mG(u6e);function mG(e){return e&&e.__esModule?e:{default:e}}MA.simpleCheckForValidColor=function(n){var t=["r","g","b","a","h","s","l","v"],r=0,i=0;return(0,l6e.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 A6e=MA.toState=function(n,t){var r=n.hex?(0,u4.default)(n.hex):(0,u4.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 h=a==="000000"&&s.a===0;return{hsl:i,hex:h?"transparent":"#"+a,rgb:s,hsv:o,oldHue:n.h||t||i.h,source:n.source}};MA.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,u4.default)(n).isValid()};MA.getContrastingColor=function(n){if(!n)return"#fff";var t=A6e(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"};MA.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}};MA.isvalidColorString=function(n,t){var r=n.replace("°","");return(0,u4.default)(t+" ("+r+")")._ok};Object.defineProperty(yb,"__esModule",{value:!0});yb.ColorWrap=void 0;var Zv=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},c6e=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}}(),dO=Br,d6e=gG(dO),h6e=fG,f6e=gG(h6e),p6e=MA,mg=m6e(p6e);function m6e(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 gG(e){return e&&e.__esModule?e:{default:e}}function g6e(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function y6e(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 v6e(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 _6e=yb.ColorWrap=function(n){var t=function(r){v6e(i,r);function i(o){g6e(this,i);var s=y6e(this,(i.__proto__||Object.getPrototypeOf(i)).call(this));return s.handleChange=function(a,h){var g=mg.simpleCheckForValidColor(a);if(g){var C=mg.toState(a,a.h||s.state.oldHue);s.setState(C),s.props.onChangeComplete&&s.debounce(s.props.onChangeComplete,C,h),s.props.onChange&&s.props.onChange(C,h)}},s.handleSwatchHover=function(a,h){var g=mg.simpleCheckForValidColor(a);if(g){var C=mg.toState(a,a.h||s.state.oldHue);s.props.onSwatchHover&&s.props.onSwatchHover(C,h)}},s.state=Zv({},mg.toState(o.color,0)),s.debounce=(0,f6e.default)(function(a,h,g){a(h,g)},100),s}return c6e(i,[{key:"render",value:function(){var s={};return this.props.onSwatchHover&&(s.onSwatchHover=this.handleSwatchHover),d6e.default.createElement(n,Zv({},this.props,this.state,{onChange:this.handleChange},s))}}],[{key:"getDerivedStateFromProps",value:function(s,a){return Zv({},mg.toState(s.color,a.oldHue))}}]),i}(dO.PureComponent||dO.Component);return t.propTypes=Zv({},n.propTypes),t.defaultProps=Zv({},n.defaultProps,{color:{h:250,s:.5,l:.2,a:1}}),t};yb.default=_6e;var vb={},tw={};Object.defineProperty(tw,"__esModule",{value:!0});tw.handleFocus=void 0;var C6e=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},b6e=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}}(),x6e=Br,cS=w6e(x6e);function w6e(e){return e&&e.__esModule?e:{default:e}}function M6e(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function xP(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 S6e(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)}tw.handleFocus=function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"span";return function(r){S6e(i,r);function i(){var o,s,a,h;M6e(this,i);for(var g=arguments.length,C=Array(g),B=0;B<g;B++)C[B]=arguments[B];return h=(s=(a=xP(this,(o=i.__proto__||Object.getPrototypeOf(i)).call.apply(o,[this].concat(C))),a),a.state={focus:!1},a.handleFocus=function(){return a.setState({focus:!0})},a.handleBlur=function(){return a.setState({focus:!1})},s),xP(a,h)}return b6e(i,[{key:"render",value:function(){return cS.default.createElement(t,{onFocus:this.handleFocus,onBlur:this.handleBlur},cS.default.createElement(n,C6e({},this.props,this.state)))}}]),i}(cS.default.Component)};Object.defineProperty(vb,"__esModule",{value:!0});vb.Swatch=void 0;var wP=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},E6e=Br,MP=nk(E6e),O6e=Ys,B6e=nk(O6e),k6e=tw,I6e=S1,T6e=nk(I6e);function nk(e){return e&&e.__esModule?e:{default:e}}var K6e=13,P6e=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,h=a===void 0?t:a,g=n.children,C=n.focus,B=n.focusStyle,k=B===void 0?{}:B,P=t==="transparent",L=(0,B6e.default)({default:{swatch:wP({background:t,height:"100%",width:"100%",cursor:"pointer",position:"relative",outline:"none"},r,C?k:{})}}),J=function(ce){return o(t,ce)},N=function(ce){return ce.keyCode===K6e&&o(t,ce)},$=function(ce){return s(t,ce)},q={};return s&&(q.onMouseOver=$),MP.default.createElement("div",wP({style:L.swatch,onClick:J,title:h,tabIndex:0,onKeyDown:N},q),g,P&&MP.default.createElement(T6e.default,{borderRadius:L.swatch.borderRadius,boxShadow:"inset 0 0 0 1px rgba(0,0,0,0.1)"}))};vb.default=(0,k6e.handleFocus)(P6e);(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=S1;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 h=vb;Object.defineProperty(e,"Swatch",{enumerable:!0,get:function(){return g(h).default}});function g(C){return C&&C.__esModule?C:{default:C}}})(H8);var _b={};function F6e(e){return e===void 0}var D6e=F6e,rk={};Object.defineProperty(rk,"__esModule",{value:!0});var SP=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},L6e=Br,EP=U6e(L6e);function U6e(e){return e&&e.__esModule?e:{default:e}}function R6e(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 Vx=24;rk.default=function(e){var n=e.fill,t=n===void 0?"currentColor":n,r=e.width,i=r===void 0?Vx:r,o=e.height,s=o===void 0?Vx:o,a=e.style,h=a===void 0?{}:a,g=R6e(e,["fill","width","height","style"]);return EP.default.createElement("svg",SP({viewBox:"0 0 "+Vx+" "+Vx,style:SP({fill:t,width:i,height:s},h)},g),EP.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(_b,"__esModule",{value:!0});_b.ChromeFields=void 0;var z6e=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}}(),j6e=Br,Xa=nw(j6e),W6e=Ys,N6e=nw(W6e),G6e=MA,Q6e=H6e(G6e),$6e=D6e,OP=nw($6e),np=H8,Y6e=rk,q6e=nw(Y6e);function H6e(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 nw(e){return e&&e.__esModule?e:{default:e}}function V6e(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function Z6e(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 X6e(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 yG=_b.ChromeFields=function(e){X6e(n,e);function n(t){V6e(this,n);var r=Z6e(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?Q6e.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,OP.default)(i.s)?r.props.hsl.s:i.s),l:Number((0,OP.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 z6e(n,[{key:"render",value:function(){var r=this,i=(0,N6e.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=Xa.default.createElement("div",{style:i.fields,className:"flexbox-fix"},Xa.default.createElement("div",{style:i.field},Xa.default.createElement(np.EditableInput,{style:{input:i.input,label:i.label},label:"hex",value:this.props.hex,onChange:this.handleChange}))):this.state.view==="rgb"?o=Xa.default.createElement("div",{style:i.fields,className:"flexbox-fix"},Xa.default.createElement("div",{style:i.field},Xa.default.createElement(np.EditableInput,{style:{input:i.input,label:i.label},label:"r",value:this.props.rgb.r,onChange:this.handleChange})),Xa.default.createElement("div",{style:i.field},Xa.default.createElement(np.EditableInput,{style:{input:i.input,label:i.label},label:"g",value:this.props.rgb.g,onChange:this.handleChange})),Xa.default.createElement("div",{style:i.field},Xa.default.createElement(np.EditableInput,{style:{input:i.input,label:i.label},label:"b",value:this.props.rgb.b,onChange:this.handleChange})),Xa.default.createElement("div",{style:i.alpha},Xa.default.createElement(np.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=Xa.default.createElement("div",{style:i.fields,className:"flexbox-fix"},Xa.default.createElement("div",{style:i.field},Xa.default.createElement(np.EditableInput,{style:{input:i.input,label:i.label},label:"h",value:Math.round(this.props.hsl.h),onChange:this.handleChange})),Xa.default.createElement("div",{style:i.field},Xa.default.createElement(np.EditableInput,{style:{input:i.input,label:i.label},label:"s",value:Math.round(this.props.hsl.s*100)+"%",onChange:this.handleChange})),Xa.default.createElement("div",{style:i.field},Xa.default.createElement(np.EditableInput,{style:{input:i.input,label:i.label},label:"l",value:Math.round(this.props.hsl.l*100)+"%",onChange:this.handleChange})),Xa.default.createElement("div",{style:i.alpha},Xa.default.createElement(np.EditableInput,{style:{input:i.input,label:i.label},label:"a",value:this.props.hsl.a,arrowOffset:.01,onChange:this.handleChange})))),Xa.default.createElement("div",{style:i.wrap,className:"flexbox-fix"},o,Xa.default.createElement("div",{style:i.toggle},Xa.default.createElement("div",{style:i.icon,onClick:this.toggleViews,ref:function(a){return r.icon=a}},Xa.default.createElement(q6e.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}(Xa.default.Component);yG.defaultProps={view:"hex"};_b.default=yG;var Cb={};Object.defineProperty(Cb,"__esModule",{value:!0});Cb.ChromePointer=void 0;var J6e=Br,eEe=vG(J6e),tEe=Ys,nEe=vG(tEe);function vG(e){return e&&e.__esModule?e:{default:e}}var rEe=Cb.ChromePointer=function(){var n=(0,nEe.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 eEe.default.createElement("div",{style:n.picker})};Cb.default=rEe;var bb={};Object.defineProperty(bb,"__esModule",{value:!0});bb.ChromePointerCircle=void 0;var iEe=Br,oEe=_G(iEe),aEe=Ys,sEe=_G(aEe);function _G(e){return e&&e.__esModule?e:{default:e}}var lEe=bb.ChromePointerCircle=function(){var n=(0,sEe.default)({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",boxShadow:"inset 0 0 0 1px #fff",transform:"translate(-6px, -6px)"}}});return oEe.default.createElement("div",{style:n.picker})};bb.default=lEe;Object.defineProperty(j5,"__esModule",{value:!0});j5.Chrome=void 0;var uEe=Br,wA=E1(uEe),AEe=hh,gg=E1(AEe),cEe=Ys,dEe=E1(cEe),hEe=sG,fEe=E1(hEe),g_=H8,pEe=_b,mEe=E1(pEe),gEe=Cb,BP=E1(gEe),yEe=bb,vEe=E1(yEe);function E1(e){return e&&e.__esModule?e:{default:e}}var ik=j5.Chrome=function(n){var t=n.width,r=n.onChange,i=n.disableAlpha,o=n.rgb,s=n.hsl,a=n.hsv,h=n.hex,g=n.renderers,C=n.styles,B=C===void 0?{}:C,k=n.className,P=k===void 0?"":k,L=n.defaultView,J=(0,dEe.default)((0,fEe.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"}}},B),{disableAlpha:i});return wA.default.createElement("div",{style:J.picker,className:"chrome-picker "+P},wA.default.createElement("div",{style:J.saturation},wA.default.createElement(g_.Saturation,{style:J.Saturation,hsl:s,hsv:a,pointer:vEe.default,onChange:r})),wA.default.createElement("div",{style:J.body},wA.default.createElement("div",{style:J.controls,className:"flexbox-fix"},wA.default.createElement("div",{style:J.color},wA.default.createElement("div",{style:J.swatch},wA.default.createElement("div",{style:J.active}),wA.default.createElement(g_.Checkboard,{renderers:g}))),wA.default.createElement("div",{style:J.toggles},wA.default.createElement("div",{style:J.hue},wA.default.createElement(g_.Hue,{style:J.Hue,hsl:s,pointer:BP.default,onChange:r})),wA.default.createElement("div",{style:J.alpha},wA.default.createElement(g_.Alpha,{style:J.Alpha,rgb:o,hsl:s,pointer:BP.default,renderers:g,onChange:r})))),wA.default.createElement(mEe.default,{rgb:o,hsl:s,hex:h,view:L,onChange:r,disableAlpha:i})))};ik.propTypes={width:gg.default.oneOfType([gg.default.string,gg.default.number]),disableAlpha:gg.default.bool,styles:gg.default.object,defaultView:gg.default.oneOf(["hex","rgb","hsl"])};ik.defaultProps={width:225,disableAlpha:!1,styles:{}};var _Ee=j5.default=(0,g_.ColorWrap)(ik);function _i(){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 _i=function(){return s},s}_i();function CEe(e){_i().f[0]++;const n=(_i().s[0]++,e.rgb);return _i().s[1]++,`rgba(${n.r}, ${n.g}, ${n.b}, ${n.a})`}class CG extends Sn.Component{constructor(t){_i().f[1]++,_i().s[4]++;super(t);an(this,"state",(_i().s[2]++,{pickerOpened:!1}));an(this,"colorInput",(_i().s[3]++,null));an(this,"calcPickerOffset",(_i().s[7]++,()=>{_i().f[3]++;const t=(_i().s[8]++,this.colorInput);if(_i().s[9]++,t){_i().b[0][0]++;const r=(_i().s[10]++,t.getBoundingClientRect());return _i().s[11]++,{top:r.top,left:r.left+196}}else return _i().b[0][1]++,_i().s[12]++,{top:160,left:555}}));an(this,"togglePicker",(_i().s[13]++,()=>{_i().f[4]++,_i().s[14]++,this.setState({pickerOpened:!this.state.pickerOpened})}));_i().s[5]++,this.onChangeNoCheck=x6.throttle(this.onChangeNoCheck,1e3/30)}onChangeNoCheck(t){_i().f[2]++,_i().s[6]++,this.props.onChange(t)}get color(){_i().f[5]++,_i().s[15]++;try{return _i().s[16]++,G6(this.props.value).rgb()}catch(t){return _i().s[17]++,console.warn("Error parsing color: ",t),_i().s[18]++,G6("rgb(255,255,255)")}}onChange(t){_i().f[6]++,_i().s[19]++,this.props.onChange(t===""?(_i().b[1][0]++,void 0):(_i().b[1][1]++,t))}render(){_i().f[7]++;const t=(_i().s[20]++,this.calcPickerOffset()),r=(_i().s[21]++,this.color.object()),i=(_i().s[22]++,{r:r.r,g:r.g,b:r.b,a:r.alpha}),o=(_i().s[23]++,G.jsxs("div",{className:"maputnik-color-picker-offset",style:{position:"fixed",zIndex:1,left:t.left,top:t.top},children:[G.jsx(_Ee,{color:i,onChange:a=>(_i().f[8]++,_i().s[24]++,this.onChangeNoCheck(CEe(a)))}),G.jsx("div",{className:"maputnik-color-picker-offset",onClick:this.togglePicker,style:{zIndex:-1,position:"fixed",top:"0px",right:"0px",bottom:"0px",left:"0px"}})]})),s=(_i().s[25]++,{backgroundColor:this.props.value});return _i().s[26]++,G.jsxs("div",{className:"maputnik-color-wrapper",children:[(_i().b[2][0]++,this.state.pickerOpened&&(_i().b[2][1]++,o)),G.jsx("div",{className:"maputnik-color-swatch",style:s}),G.jsx("input",{"aria-label":this.props["aria-label"],spellCheck:"false",autoComplete:"off",className:"maputnik-color",ref:a=>(_i().f[9]++,_i().s[27]++,this.colorInput=a),onClick:this.togglePicker,style:this.props.style,name:this.props.name,placeholder:this.props.default,value:this.props.value?(_i().b[3][0]++,this.props.value):(_i().b[3][1]++,""),onChange:a=>(_i().f[10]++,_i().s[28]++,this.onChange(a.target.value))})]})}}function Gt(){var e="/home/runner/work/maputnik/maputnik/src/components/InputNumber.tsx",n="055427b59351edaed6ac0381ee689923477adaa1",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:53}},type:"cond-expr",locations:[{start:{line:42,column:36},end:{line:42,column:42}},{start:{line:42,column:45},end:{line:42,column:53}}],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:"AA8Ka,SACL,KADK;AA9Kb,OAAO,WAAmC;AAC1C,OAAO,sBAAsB;AA0B7B,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,CAAC,KAAK,MAAM,YAAa;AACnC,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:"055427b59351edaed6ac0381ee689923477adaa1"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Gt=function(){return s},s}Gt();class wf extends Sn.Component{constructor(t){Gt().f[0]++,Gt().s[2]++;super(t);an(this,"_keyboardEvent",(Gt().s[1]++,!1));an(this,"resetValue",(Gt().s[26]++,()=>{if(Gt().f[4]++,Gt().s[27]++,this.setState({editing:!1}),Gt().s[28]++,this.state.value)Gt().b[16][1]++;else{Gt().b[16][0]++,Gt().s[29]++;return}Gt().s[30]++,this.isValid(this.state.value)?Gt().b[17][1]++:(Gt().b[17][0]++,Gt().s[31]++,this.isValid(this.props.value)?(Gt().b[18][0]++,Gt().s[32]++,this.changeValue(this.props.value),Gt().s[33]++,this.setState({dirtyValue:this.props.value})):(Gt().b[18][1]++,Gt().s[34]++,this.changeValue(void 0),Gt().s[35]++,this.setState({dirtyValue:void 0})))}));an(this,"onChangeRange",(Gt().s[36]++,t=>{Gt().f[5]++;let r=(Gt().s[37]++,parseFloat(t.target.value));const i=(Gt().s[38]++,this.props.rangeStep);let o=(Gt().s[39]++,r);if(Gt().s[40]++,i){Gt().b[19][0]++;const s=(Gt().s[41]++,r%i);Gt().s[42]++,this._keyboardEvent?(Gt().b[20][0]++,Gt().s[43]++,r<+this.state.dirtyValue?(Gt().b[21][0]++,Gt().s[44]++,r=this.state.value-i):(Gt().b[21][1]++,Gt().s[45]++,r=this.state.value+i),Gt().s[46]++,o=r):(Gt().b[20][1]++,Gt().s[47]++,s<i/2?(Gt().b[22][0]++,Gt().s[48]++,r=r-s):(Gt().b[22][1]++,Gt().s[49]++,r=r+(i-s)))}else Gt().b[19][1]++;Gt().s[50]++,this._keyboardEvent=!1,Gt().s[51]++,r=Math.max(this.props.min,Math.min(this.props.max,r)),Gt().s[52]++,this.setState({value:r,dirtyValue:o}),Gt().s[53]++,this.props.onChange?(Gt().b[23][0]++,Gt().s[54]++,this.props.onChange(r)):Gt().b[23][1]++}));Gt().s[3]++,this.state={uuid:+Ty(),editing:!1,value:t.value,dirtyValue:t.value}}static getDerivedStateFromProps(t,r){return Gt().f[1]++,Gt().s[4]++,Gt().b[1][0]++,!r.editing&&(Gt().b[1][1]++,t.value!==r.value)?(Gt().b[0][0]++,Gt().s[5]++,{value:t.value,dirtyValue:t.value}):(Gt().b[0][1]++,Gt().s[6]++,null)}changeValue(t){Gt().f[2]++;const r=(Gt().s[7]++,Gt().b[3][0]++,t===""||(Gt().b[3][1]++,t===void 0)?(Gt().b[2][0]++,void 0):(Gt().b[2][1]++,+t)),i=(Gt().s[8]++,this.props.value!==r);Gt().s[9]++,Gt().b[5][0]++,this.isValid(r)&&(Gt().b[5][1]++,i)?(Gt().b[4][0]++,Gt().s[10]++,this.props.onChange?(Gt().b[6][0]++,Gt().s[11]++,this.props.onChange(r)):Gt().b[6][1]++,Gt().s[12]++,this.setState({value:r})):(Gt().b[4][1]++,Gt().s[13]++,Gt().b[8][0]++,!this.isValid(r)&&(Gt().b[8][1]++,i)?(Gt().b[7][0]++,Gt().s[14]++,this.setState({value:void 0})):Gt().b[7][1]++),Gt().s[15]++,this.setState({dirtyValue:t===""?(Gt().b[9][0]++,void 0):(Gt().b[9][1]++,t)})}isValid(t){if(Gt().f[3]++,Gt().s[16]++,t===void 0)return Gt().b[10][0]++,Gt().s[17]++,!0;Gt().b[10][1]++;const r=(Gt().s[18]++,+t);return Gt().s[19]++,isNaN(r)?(Gt().b[11][0]++,Gt().s[20]++,!1):(Gt().b[11][1]++,Gt().s[21]++,Gt().b[13][0]++,!isNaN(this.props.min)&&(Gt().b[13][1]++,r<this.props.min)?(Gt().b[12][0]++,Gt().s[22]++,!1):(Gt().b[12][1]++,Gt().s[23]++,Gt().b[15][0]++,!isNaN(this.props.max)&&(Gt().b[15][1]++,r>this.props.max)?(Gt().b[14][0]++,Gt().s[24]++,!1):(Gt().b[14][1]++,Gt().s[25]++,!0)))}render(){var t,r;if(Gt().f[6]++,Gt().s[55]++,Gt().b[25][0]++,Object.prototype.hasOwnProperty.call(this.props,"min")&&(Gt().b[25][1]++,Object.prototype.hasOwnProperty.call(this.props,"max"))&&(Gt().b[25][2]++,this.props.min!==void 0)&&(Gt().b[25][3]++,this.props.max!==void 0)&&(Gt().b[25][4]++,this.props.allowRange)){Gt().b[24][0]++;const i=(Gt().s[56]++,this.state.editing?(Gt().b[26][0]++,this.state.dirtyValue):(Gt().b[26][1]++,this.state.value)),o=(Gt().s[57]++,this.props.default===void 0?(Gt().b[27][0]++,""):(Gt().b[27][1]++,this.props.default));let s;return Gt().s[58]++,this.state.editingRange?(Gt().b[28][0]++,Gt().s[59]++,s=this.state.value):(Gt().b[28][1]++,Gt().s[60]++,s=i),Gt().s[61]++,G.jsxs("div",{className:"maputnik-number-container",children:[G.jsx("input",{className:"maputnik-number-range",type:"range",max:this.props.max,min:this.props.min,step:"any",spellCheck:"false",value:i===void 0?(Gt().b[29][0]++,o):(Gt().b[29][1]++,i),onChange:this.onChangeRange,onKeyDown:()=>{Gt().f[7]++,Gt().s[62]++,this._keyboardEvent=!0},onPointerDown:()=>{Gt().f[8]++,Gt().s[63]++,this.setState({editing:!0,editingRange:!0})},onPointerUp:()=>{Gt().f[9]++,Gt().s[64]++,this.setState({editing:!1,editingRange:!1})},onBlur:()=>{Gt().f[10]++,Gt().s[65]++,this.setState({editing:!1,editingRange:!1,dirtyValue:this.state.value})},"data-wd-key":this.props["data-wd-key"]+"-range"},"range"),G.jsx("input",{type:"text",spellCheck:"false",className:"maputnik-number",placeholder:(t=this.props.default)==null?void 0:t.toString(),value:s===void 0?(Gt().b[30][0]++,""):(Gt().b[30][1]++,s),onFocus:a=>{Gt().f[11]++,Gt().s[66]++,this.setState({editing:!0})},onChange:a=>{Gt().f[12]++,Gt().s[67]++,this.changeValue(a.target.value)},onBlur:a=>{Gt().f[13]++,Gt().s[68]++,this.setState({editing:!1}),Gt().s[69]++,this.resetValue()},"data-wd-key":this.props["data-wd-key"]+"-text"},"text")]})}else{Gt().b[24][1]++;const i=(Gt().s[70]++,this.state.editing?(Gt().b[31][0]++,this.state.dirtyValue):(Gt().b[31][1]++,this.state.value));return Gt().s[71]++,G.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?(Gt().b[32][0]++,""):(Gt().b[32][1]++,i),onChange:o=>(Gt().f[14]++,Gt().s[72]++,this.changeValue(o.target.value)),onFocus:()=>{Gt().f[15]++,Gt().s[73]++,this.setState({editing:!0})},onBlur:this.resetValue,required:this.props.required,"data-wd-key":this.props["data-wd-key"]})}}}an(wf,"defaultProps",(Gt().s[0]++,{rangeStep:1}));function Jh(){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 Jh=function(){return s},s}Jh();class ok extends Sn.Component{constructor(){super(...arguments);an(this,"onChange",(Jh().s[1]++,()=>{Jh().f[0]++,Jh().s[2]++,this.props.onChange(!this.props.value)}))}render(){return Jh().f[1]++,Jh().s[3]++,G.jsxs("div",{className:"maputnik-checkbox-wrapper",children:[G.jsx("input",{className:"maputnik-checkbox",type:"checkbox",style:this.props.style,onChange:this.onChange,onClick:this.onChange,checked:this.props.value}),G.jsx("div",{className:"maputnik-checkbox-box",children:G.jsx("svg",{style:{display:this.props.value?(Jh().b[0][0]++,"inline"):(Jh().b[0][1]++,"none")},className:"maputnik-checkbox-icon",viewBox:"0 0 32 32",children:G.jsx("path",{d:"M1 14 L5 10 L13 18 L27 4 L31 8 L13 26 z"})})})]})}}an(ok,"defaultProps",(Jh().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 ES;let bG=(ES=class extends Sn.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]++,G.jsx(wf,{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]++,G.jsx(wd,{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]++,G.jsx("div",{className:"maputnik-array",children:r})}},an(ES,"defaultProps",(pr().s[0]++,{value:[],default:[]})),ES);function hl(){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 hl=function(){return s},s}hl();class bEe extends Sn.Component{render(){hl().f[0]++;let n=(hl().s[0]++,this.props.options);hl().s[1]++,hl().b[1][0]++,n.length>0&&(hl().b[1][1]++,!Array.isArray(n[0]))?(hl().b[0][0]++,hl().s[2]++,n=n.map(i=>(hl().f[1]++,hl().s[3]++,[i,i]))):hl().b[0][1]++;const t=(hl().s[4]++,hl().b[2][0]++,this.props.value||(hl().b[2][1]++,n[0][0])),r=(hl().s[5]++,n.map(([i,o])=>(hl().f[2]++,hl().s[6]++,G.jsxs("label",{className:bf("maputnik-radio-as-button",{"maputnik-button-selected":i===t}),children:[G.jsx("input",{type:"radio",name:this.props.name,onChange:s=>(hl().f[3]++,hl().s[7]++,this.props.onChange(i)),value:i,checked:i===t}),o]},i))));return hl().s[8]++,G.jsx("fieldset",{className:"maputnik-multibutton","aria-label":this.props["aria-label"],children:r})}}function ps(){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 ps=function(){return s},s}ps();function xEe(e){ps().f[0]++;let n=(ps().s[0]++,0);return ps().s[1]++,e.forEach(([t,r])=>{ps().f[1]++,ps().s[2]++,n+=r.length}),ps().s[3]++,n}class ak extends Sn.Component{render(){ps().f[2]++;const{options:n,value:t,onChange:r,name:i,label:o}=(ps().s[4]++,this.props);return ps().s[5]++,ps().b[1][0]++,n.length<=3&&(ps().b[1][1]++,xEe(n)<=20)?(ps().b[0][0]++,ps().s[6]++,G.jsx(bEe,{name:i,options:n,value:(ps().b[2][0]++,t||(ps().b[2][1]++,this.props.default)),onChange:r,"aria-label":(ps().b[3][0]++,this.props["aria-label"]||(ps().b[3][1]++,o))})):(ps().b[0][1]++,ps().s[7]++,G.jsx(x1,{options:n,value:(ps().b[4][0]++,t||(ps().b[4][1]++,this.props.default)),onChange:r,"aria-label":(ps().b[5][0]++,this.props["aria-label"]||(ps().b[5][1]++,o))}))}}function A4(){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 A4=function(){return s},s}A4();class kP extends Sn.Component{render(){return A4().f[0]++,A4().s[0]++,G.jsxs("div",{className:"SmallError",children:["Error: ",this.props.children]})}}function Ki(){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 Ki=function(){return s},s}Ki();function dS(e){if(Ki().f[0]++,Ki().s[0]++,e===""){Ki().b[0][0]++,Ki().s[1]++;return}else Ki().b[0][1]++;let n;Ki().s[2]++;const t=o=>{Ki().f[1]++,Ki().s[3]++;try{const s=(Ki().s[4]++,new URL(o));return Ki().s[5]++,s.protocol}catch{Ki().s[6]++;return}},r=(Ki().s[7]++,t(e)),i=(Ki().s[8]++,window.location.protocol==="https:");return Ki().s[9]++,r?(Ki().b[1][1]++,Ki().s[11]++,Ki().b[4][0]++,r&&(Ki().b[4][1]++,r==="http:")&&(Ki().b[4][2]++,window.location.protocol==="https:")?(Ki().b[3][0]++,Ki().s[12]++,n=G.jsxs(kP,{children:["CORS policy won't allow fetching resources served over http from https, use a ",G.jsx("code",{children:"https://"})," domain"]})):Ki().b[3][1]++):(Ki().b[1][0]++,Ki().s[10]++,n=G.jsxs(kP,{children:["Must provide protocol ",i?(Ki().b[2][0]++,G.jsx("code",{children:"https://"})):(Ki().b[2][1]++,G.jsxs(G.Fragment,{children:[G.jsx("code",{children:"http://"})," or ",G.jsx("code",{children:"https://"})]}))]})),Ki().s[13]++,n}var OS;let sk=(OS=class extends Sn.Component{constructor(t){Ki().f[3]++,Ki().s[15]++;super(t);an(this,"onInput",(Ki().s[17]++,t=>{Ki().f[4]++,Ki().s[18]++,this.setState({error:dS(t)}),Ki().s[19]++,this.props.onInput?(Ki().b[5][0]++,Ki().s[20]++,this.props.onInput(t)):Ki().b[5][1]++}));an(this,"onChange",(Ki().s[21]++,t=>{Ki().f[5]++,Ki().s[22]++,this.setState({error:dS(t)}),Ki().s[23]++,this.props.onChange(t)}));Ki().s[16]++,this.state={error:dS(t.value)}}render(){return Ki().f[6]++,Ki().s[24]++,G.jsxs("div",{children:[G.jsx(wd,{...this.props,onInput:this.onInput,onChange:this.onChange,"aria-label":this.props["aria-label"]}),this.state.error]})}},an(OS,"defaultProps",(Ki().s[14]++,{onInput:()=>{Ki().f[2]++}})),OS);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 xG=class extends Sn.Component{constructor(){super(...arguments);an(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]++,G.jsx(wEe,{onClick:this.deleteValue.bind(this,i)}));let s;if(Ar().s[24]++,this.props.type==="url")Ar().b[8][0]++,Ar().s[25]++,s=G.jsx(sk,{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=G.jsx(wf,{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 h=(Ar().s[29]++,Object.keys((a=this.props.fieldSpec)==null?void 0:a.values).map(g=>(Ar().f[6]++,Ar().s[30]++,[g,B8(g)])));Ar().s[31]++,s=G.jsx(ak,{options:h,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=G.jsx(wd,{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]++,G.jsxs("div",{style:this.props.style,className:"maputnik-array-block",children:[G.jsx("div",{className:"maputnik-array-block-action",children:o}),G.jsx("div",{className:"maputnik-array-block-content",children:s})]},i)}));return Ar().s[34]++,G.jsxs("div",{className:"maputnik-array",children:[t,G.jsx(ja,{className:"maputnik-array-add-value",onClick:this.addValue,children:"Add value"})]})}};class wEe extends Sn.Component{render(){return Ar().f[7]++,Ar().s[35]++,G.jsx(ja,{className:"maputnik-delete-stop",onClick:this.props.onClick,title:"Remove array item",children:G.jsx(d8,{label:G.jsx(Ny,{})})})}}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 wG extends Sn.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]++,G.jsx("li",{children:G.jsx(Hy,{"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]++,G.jsx("ul",{className:"maputnik-font",children:n})}}an(wG,"defaultProps",(ta().s[0]++,{fonts:[]}));function Si(){var e="/home/runner/work/maputnik/maputnik/src/components/InputSpec.tsx",n="8a7e9c26497bbcdc9141a7bf10d3ed50f729d679",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:28,column:5}},2:{start:{line:26,column:30},end:{line:26,column:81}},3:{start:{line:29,column:4},end:{line:115,column:5}},4:{start:{line:31,column:8},end:{line:38,column:10}},5:{start:{line:40,column:24},end:{line:40,column:101}},6:{start:{line:40,column:82},end:{line:40,column:100}},7:{start:{line:41,column:8},end:{line:47,column:10}},8:{start:{line:52,column:8},end:{line:68,column:9}},9:{start:{line:53,column:26},end:{line:53,column:59}},10:{start:{line:54,column:10},end:{line:60,column:12}},11:{start:{line:58,column:42},end:{line:58,column:48}},12:{start:{line:62,column:10},end:{line:67,column:12}},13:{start:{line:70,column:8},end:{line:75,column:10}},14:{start:{line:77,column:8},end:{line:82,column:10}},15:{start:{line:84,column:8},end:{line:112,column:9}},16:{start:{line:85,column:10},end:{line:91,column:12}},17:{start:{line:93,column:10},end:{line:111,column:11}},18:{start:{line:94,column:12},end:{line:101,column:14}},19:{start:{line:103,column:12},end:{line:110,column:14}},20:{start:{line:114,column:8},end:{line:114,column:20}},21:{start:{line:118,column:4},end:{line:118,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:116,column:3}},line:15},1:{name:"(anonymous_1)",decl:{start:{line:26,column:16},end:{line:26,column:17}},loc:{start:{line:26,column:30},end:{line:26,column:81}},line:26},2:{name:"(anonymous_2)",decl:{start:{line:40,column:75},end:{line:40,column:76}},loc:{start:{line:40,column:82},end:{line:40,column:100}},line:40},3:{name:"(anonymous_3)",decl:{start:{line:58,column:35},end:{line:58,column:36}},loc:{start:{line:58,column:42},end:{line:58,column:48}},line:58},4:{name:"(anonymous_4)",decl:{start:{line:117,column:2},end:{line:117,column:3}},loc:{start:{line:117,column:11},end:{line:119,column:3}},line:117}},branchMap:{0:{loc:{start:{line:29,column:4},end:{line:115,column:5}},type:"switch",locations:[{start:{line:30,column:6},end:{line:38,column:10}},{start:{line:39,column:6},end:{line:48,column:7}},{start:{line:49,column:6},end:{line:49,column:27}},{start:{line:50,column:6},end:{line:50,column:23}},{start:{line:51,column:6},end:{line:68,column:9}},{start:{line:69,column:6},end:{line:75,column:10}},{start:{line:76,column:6},end:{line:82,column:10}},{start:{line:83,column:6},end:{line:112,column:9}},{start:{line:113,column:6},end:{line:114,column:20}}],line:29},1:{loc:{start:{line:40,column:36},end:{line:40,column:69}},type:"binary-expr",locations:[{start:{line:40,column:36},end:{line:40,column:63}},{start:{line:40,column:67},end:{line:40,column:69}}],line:40},2:{loc:{start:{line:52,column:8},end:{line:68,column:9}},type:"if",locations:[{start:{line:52,column:8},end:{line:68,column:9}},{start:{line:61,column:15},end:{line:68,column:9}}],line:52},3:{loc:{start:{line:53,column:26},end:{line:53,column:59}},type:"binary-expr",locations:[{start:{line:53,column:26},end:{line:53,column:53}},{start:{line:53,column:57},end:{line:53,column:59}}],line:53},4:{loc:{start:{line:84,column:8},end:{line:112,column:9}},type:"if",locations:[{start:{line:84,column:8},end:{line:112,column:9}},{start:{line:92,column:15},end:{line:112,column:9}}],line:84},5:{loc:{start:{line:93,column:10},end:{line:111,column:11}},type:"if",locations:[{start:{line:93,column:10},end:{line:111,column:11}},{start:{line:102,column:17},end:{line:111,column:11}}],line:93}},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:"AAyDM;AAzDN,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,eAAe,sBAAsB,KAAK,MAAM;AAAA,MAChD,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:"8a7e9c26497bbcdc9141a7bf10d3ed50f729d679"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Si=function(){return s},s}Si();const MEe=(Si().s[0]++,["background-pattern","fill-pattern","line-pattern","fill-extrusion-pattern","icon-image"]);let my=class extends Sn.Component{childNodes(){var t,r;Si().f[0]++;const n=(Si().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,"data-wd-key":"spec-field-input:"+this.props.fieldName,onChange:i=>(Si().f[1]++,Si().s[2]++,this.props.onChange(this.props.fieldName,i)),"aria-label":this.props["aria-label"]});switch(Si().s[3]++,(r=this.props.fieldSpec)==null?void 0:r.type){case"number":return Si().b[0][0]++,Si().s[4]++,G.jsx(wf,{...n,min:this.props.fieldSpec.minimum,max:this.props.fieldSpec.maximum});case"enum":Si().b[0][1]++;{const i=(Si().s[5]++,Object.keys((Si().b[1][0]++,this.props.fieldSpec.values||(Si().b[1][1]++,[]))).map(o=>(Si().f[2]++,Si().s[6]++,[o,B8(o)])));return Si().s[7]++,G.jsx(ak,{...n,options:i})}case"resolvedImage":Si().b[0][2]++;case"formatted":Si().b[0][3]++;case"string":if(Si().b[0][4]++,Si().s[8]++,MEe.indexOf(this.props.fieldName)>=0){Si().b[2][0]++;const i=(Si().s[9]++,Si().b[3][0]++,this.props.fieldSpec.values||(Si().b[3][1]++,[]));return Si().s[10]++,G.jsx(Hy,{...n,options:i.map(o=>(Si().f[3]++,Si().s[11]++,[o,o]))})}else return Si().b[2][1]++,Si().s[12]++,G.jsx(wd,{...n});case"color":return Si().b[0][5]++,Si().s[13]++,G.jsx(CG,{...n});case"boolean":return Si().b[0][6]++,Si().s[14]++,G.jsx(ok,{...n});case"array":return Si().b[0][7]++,Si().s[15]++,this.props.fieldName==="text-font"?(Si().b[4][0]++,Si().s[16]++,G.jsx(wG,{...n,fonts:this.props.fieldSpec.values})):(Si().b[4][1]++,Si().s[17]++,this.props.fieldSpec.length?(Si().b[5][0]++,Si().s[18]++,G.jsx(bG,{...n,type:this.props.fieldSpec.value,length:this.props.fieldSpec.length})):(Si().b[5][1]++,Si().s[19]++,G.jsx(xG,{...n,fieldSpec:this.props.fieldSpec,type:this.props.fieldSpec.value})));default:return Si().b[0][8]++,Si().s[20]++,null}}render(){return Si().f[4]++,Si().s[21]++,G.jsx("div",{"data-wd-key":"spec-field:"+this.props.fieldName,children:this.childNodes()})}};function Ql(){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 Ql=function(){return s},s}Ql();class EC extends Sn.Component{constructor(t){Ql().f[0]++,Ql().s[0]++;super(t);an(this,"_labelId");an(this,"onToggleDoc",(Ql().s[3]++,t=>{Ql().f[1]++,Ql().s[4]++,this.setState({showDoc:t})}));Ql().s[1]++,this._labelId=Ty("fieldset_label_"),Ql().s[2]++,this.state={showDoc:!1}}render(){return Ql().f[2]++,Ql().s[5]++,G.jsxs("div",{className:"maputnik-input-block",role:"group","aria-labelledby":this._labelId,children:[(Ql().b[0][0]++,this.props.fieldSpec&&(Ql().b[0][1]++,G.jsx("div",{className:"maputnik-input-block-label",children:G.jsx(d8,{label:this.props.label,onToggleDoc:this.onToggleDoc,fieldSpec:this.props.fieldSpec})}))),(Ql().b[1][0]++,!this.props.fieldSpec&&(Ql().b[1][1]++,G.jsx("div",{className:"maputnik-input-block-label",children:this.props.label}))),G.jsx("div",{className:"maputnik-input-block-action",children:this.props.action}),G.jsx("div",{className:"maputnik-input-block-content",children:this.props.children}),(Ql().b[2][0]++,this.props.fieldSpec&&(Ql().b[2][1]++,G.jsx("div",{className:"maputnik-doc-inline",style:{display:this.state.showDoc?(Ql().b[3][0]++,""):(Ql().b[3][1]++,"none")},children:G.jsx(h8,{fieldSpec:this.props.fieldSpec})})))]})}}function $o(){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 $o=function(){return s},s}$o();const SEe=($o().s[0]++,{color:()=>($o().f[0]++,$o().s[1]++,ra),enum:({fieldSpec:e})=>($o().f[1]++,$o().s[2]++,Object.keys(e.values).length<=3?($o().b[0][0]++,EC):($o().b[0][1]++,ra)),boolean:()=>($o().f[2]++,$o().s[3]++,ra),array:()=>($o().f[3]++,$o().s[4]++,EC),resolvedImage:()=>($o().f[4]++,$o().s[5]++,ra),number:()=>($o().f[5]++,$o().s[6]++,ra),string:()=>($o().f[6]++,$o().s[7]++,ra),formatted:()=>($o().f[7]++,$o().s[8]++,ra),padding:()=>($o().f[8]++,$o().s[9]++,ra)});class EEe extends Sn.Component{render(){var i;$o().f[9]++;const n=($o().s[10]++,(i=this.props.fieldSpec)==null?void 0:i.type),t=($o().s[11]++,SEe[n]);let r;return $o().s[12]++,t?($o().b[1][0]++,$o().s[13]++,r=t(this.props)):($o().b[1][1]++,$o().s[14]++,console.warn("No such type for '%s'",n),$o().s[15]++,r=ra),$o().s[16]++,G.jsx(r,{label:this.props.label,action:this.props.action,fieldSpec:this.props.fieldSpec,children:G.jsx(my,{...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 OEe extends Sn.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=G.jsx(ja,{className:"maputnik-make-zoom-function",onClick:this.props.onExpressionClick,title:"Convert to expression",children:G.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"middle"},viewBox:"0 0 24 24",children:G.jsx("path",{fill:"currentColor",d:SC})})}),ZA().s[2]++,n=G.jsx(ja,{className:"maputnik-make-zoom-function",onClick:this.props.onZoomClick,title:"Convert property into a zoom function",children:G.jsx(YJ,{})}),ZA().s[3]++,this.props.fieldSpec["property-type"]==="data-driven"?(ZA().b[1][0]++,ZA().s[4]++,t=G.jsx(ja,{className:"maputnik-make-data-function",onClick:this.props.onDataClick,title:"Convert property to data function",children:G.jsx(qJ,{})})):ZA().b[1][1]++,ZA().s[5]++,G.jsxs("div",{children:[r,t,n]})):(ZA().b[0][1]++,ZA().s[6]++,G.jsx("div",{children:r}))}}function ef(){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 ef=function(){return s},s}ef();class MG extends Sn.Component{render(){ef().f[0]++;const{errors:n,fieldName:t,fieldType:r}=(ef().s[1]++,this.props),i=(ef().s[2]++,G.jsx(OEe,{fieldSpec:this.props.fieldSpec,onZoomClick:this.props.onZoomClick,onDataClick:this.props.onDataClick,onExpressionClick:this.props.onExpressionClick})),o=(ef().s[3]++,n[r+"."+t]);return ef().s[4]++,G.jsx(EEe,{...this.props,error:o,fieldSpec:this.props.fieldSpec,label:z5((ef().b[0][0]++,this.props.fieldName||(ef().b[0][1]++,""))),action:i})}}an(MG,"defaultProps",(ef().s[0]++,{errors:{}}));function XA(){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 XA=function(){return s},s}XA();function SG(e,n){XA().f[0]++;const t=(XA().s[0]++,+e),r=(XA().s[1]++,+n);return XA().s[2]++,t<r?(XA().b[0][0]++,XA().s[3]++,-1):(XA().b[0][1]++,XA().s[4]++,t>r?(XA().b[1][0]++,XA().s[5]++,1):(XA().b[1][1]++,XA().s[6]++,0))}function ih(){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 ih=function(){return s},s}ih();function cd(e){if(ih().f[0]++,ih().s[0]++,Object.prototype.hasOwnProperty.call(e,"default"))return ih().b[0][0]++,ih().s[1]++,e.default;ih().b[0][1]++;const n=(ih().s[2]++,{color:"#000000",string:"",boolean:!1,number:0,array:[]});return ih().s[3]++,ih().b[1][0]++,n[e.type]||(ih().b[1][1]++,"")}function c4(){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 c4=function(){return s},s}c4();class EG extends Sn.Component{render(){return c4().f[0]++,c4().s[0]++,G.jsx(ja,{className:"maputnik-delete-stop",onClick:this.props.onClick,title:"Remove zoom level from stop",children:G.jsx(Ny,{})})}}function Qt(){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 Qt=function(){return s},s}Qt();function IP(e,n){Qt().f[0]++;let t;return Qt().s[0]++,Qt().b[1][0]++,e.value&&(Qt().b[1][1]++,e.value.stops)?(Qt().b[0][0]++,Qt().s[1]++,e.value.stops.forEach((r,i)=>{Qt().f[1]++,Qt().s[2]++,Object.prototype.hasOwnProperty.call(n.refs,i)?Qt().b[2][1]++:(Qt().b[2][0]++,Qt().s[3]++,t?Qt().b[3][1]++:(Qt().b[3][0]++,Qt().s[4]++,t={...n}),Qt().s[5]++,t[i]=Ty("stop-"))})):Qt().b[0][1]++,Qt().s[6]++,t}class BEe extends Sn.Component{constructor(){super(...arguments);an(this,"state",(Qt().s[7]++,{refs:{}}));an(this,"onChange",(Qt().s[32]++,(t,r)=>{if(Qt().f[11]++,Qt().s[33]++,r.type==="identity")Qt().b[9][0]++,Qt().s[34]++,r={type:r.type,property:r.property};else{Qt().b[9][1]++;const i=(Qt().s[35]++,r.type==="categorical"?(Qt().b[10][0]++,""):(Qt().b[10][1]++,0));Qt().s[36]++,r={property:"",type:r.type,stops:[[{zoom:6,value:i},cd(this.props.fieldSpec)],[{zoom:10,value:i},cd(this.props.fieldSpec)]],...r}}Qt().s[37]++,this.props.onChange(t,r)}))}componentDidMount(){Qt().f[2]++;const t=(Qt().s[8]++,IP(this.props,this.state));Qt().s[9]++,t?(Qt().b[4][0]++,Qt().s[10]++,this.setState({refs:t})):Qt().b[4][1]++}static getDerivedStateFromProps(t,r){Qt().f[3]++;const i=(Qt().s[11]++,IP(t,r));return Qt().s[12]++,i?(Qt().b[5][0]++,Qt().s[13]++,{refs:i}):(Qt().b[5][1]++,Qt().s[14]++,null)}getFieldFunctionType(t){return Qt().f[4]++,Qt().s[15]++,t.expression.interpolated?(Qt().b[6][0]++,Qt().s[16]++,"exponential"):(Qt().b[6][1]++,Qt().s[17]++,t.type==="number"?(Qt().b[7][0]++,Qt().s[18]++,"interval"):(Qt().b[7][1]++,Qt().s[19]++,"categorical"))}getDataFunctionTypes(t){return Qt().f[5]++,Qt().s[20]++,t.expression.interpolated?(Qt().b[8][0]++,Qt().s[21]++,["interpolate","categorical","interval","exponential","identity"]):(Qt().b[8][1]++,Qt().s[22]++,["categorical","interval","identity"])}orderStopsByZoom(t){Qt().f[6]++;const r=(Qt().s[23]++,t.map((o,s)=>(Qt().f[7]++,Qt().s[24]++,{ref:this.state.refs[s],data:o})).sort((o,s)=>(Qt().f[8]++,Qt().s[25]++,SG(o.data[0].zoom,s.data[0].zoom)))),i=(Qt().s[26]++,{});return Qt().s[27]++,r.forEach((o,s)=>{Qt().f[9]++,Qt().s[28]++,i[s]=o.ref}),Qt().s[29]++,this.setState({refs:i}),Qt().s[30]++,r.map(o=>(Qt().f[10]++,Qt().s[31]++,o.data))}changeStop(t,r,i){var h;Qt().f[12]++;const o=(Qt().s[38]++,Qt().b[11][0]++,((h=this.props.value)==null?void 0:h.stops.slice(0))||(Qt().b[11][1]++,[]));Qt().s[39]++,o[t]=[{value:r.value,zoom:r.zoom===void 0?(Qt().b[12][0]++,0):(Qt().b[12][1]++,r.zoom)},i];const s=(Qt().s[40]++,this.orderStopsByZoom(o)),a=(Qt().s[41]++,{...this.props.value,stops:s});Qt().s[42]++,this.onChange(this.props.fieldName,a)}changeBase(t){Qt().f[13]++;const r=(Qt().s[43]++,{...this.props.value,base:t});Qt().s[44]++,r.base===void 0?(Qt().b[13][0]++,Qt().s[45]++,delete r.base):Qt().b[13][1]++,Qt().s[46]++,this.props.onChange(this.props.fieldName,r)}changeDataType(t){Qt().f[14]++,Qt().s[47]++,Qt().b[15][0]++,t==="interpolate"&&(Qt().b[15][1]++,this.props.onChangeToZoomFunction)?(Qt().b[14][0]++,Qt().s[48]++,this.props.onChangeToZoomFunction()):(Qt().b[14][1]++,Qt().s[49]++,this.onChange(this.props.fieldName,{...this.props.value,type:t}))}changeDataProperty(t,r){Qt().f[15]++,Qt().s[50]++,r?(Qt().b[16][0]++,Qt().s[51]++,this.props.value[t]=r):(Qt().b[16][1]++,Qt().s[52]++,delete this.props.value[t]),Qt().s[53]++,this.onChange(this.props.fieldName,this.props.value)}render(){var r,i,o,s,a,h,g,C;Qt().f[16]++,Qt().s[54]++,typeof((r=this.props.value)==null?void 0:r.type)>"u"?(Qt().b[17][0]++,Qt().s[55]++,this.props.value.type=this.getFieldFunctionType(this.props.fieldSpec)):Qt().b[17][1]++;let t;return Qt().s[56]++,(i=this.props.value)!=null&&i.stops?(Qt().b[18][0]++,Qt().s[57]++,t=this.props.value.stops.map((B,k)=>{var me,he;Qt().f[17]++;const P=(Qt().s[58]++,typeof B[0]=="object"?(Qt().b[19][0]++,B[0].zoom):(Qt().b[19][1]++,void 0)),L=(Qt().s[59]++,this.state.refs[k]),J=(Qt().s[60]++,typeof B[0]=="object"?(Qt().b[20][0]++,B[0].value):(Qt().b[20][1]++,B[0])),N=(Qt().s[61]++,B[1]),$=(Qt().s[62]++,G.jsx(EG,{onClick:(me=this.props.onDeleteStop)==null?void 0:me.bind(this,k)})),q=(Qt().s[63]++,{"aria-label":"Input value",label:"Data value",value:J,onChange:V=>(Qt().f[18]++,Qt().s[64]++,this.changeStop(k,{zoom:P,value:V},N))});let oe;Qt().s[65]++,((he=this.props.value)==null?void 0:he.type)==="categorical"?(Qt().b[21][0]++,Qt().s[66]++,oe=G.jsx(wd,{...q})):(Qt().b[21][1]++,Qt().s[67]++,oe=G.jsx(wf,{...q}));let ce=(Qt().s[68]++,null);return Qt().s[69]++,P!==void 0?(Qt().b[22][0]++,Qt().s[70]++,ce=G.jsx("div",{children:G.jsx(wf,{"aria-label":"Zoom",value:P,onChange:V=>(Qt().f[19]++,Qt().s[71]++,this.changeStop(k,{zoom:V,value:J},N)),min:0,max:22})})):Qt().b[22][1]++,Qt().s[72]++,G.jsxs("tr",{children:[G.jsx("td",{children:ce}),G.jsx("td",{children:oe}),G.jsx("td",{children:G.jsx(my,{"aria-label":"Output value",fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:N,onChange:(V,ae)=>(Qt().f[20]++,Qt().s[73]++,this.changeStop(k,{zoom:P,value:J},ae))})}),G.jsx("td",{children:$})]},L)})):Qt().b[18][1]++,Qt().s[74]++,G.jsx("div",{className:"maputnik-data-spec-block",children:G.jsxs("fieldset",{className:"maputnik-data-spec-property",children:[G.jsx("legend",{children:z5(this.props.fieldName)}),G.jsxs("div",{className:"maputnik-data-fieldset-inner",children:[G.jsx(ra,{label:"Function",children:G.jsx("div",{className:"maputnik-data-spec-property-input",children:G.jsx(x1,{value:this.props.value.type,onChange:B=>(Qt().f[21]++,Qt().s[75]++,this.changeDataType(B)),title:"Select a type of data scale (default is 'categorical').",options:this.getDataFunctionTypes(this.props.fieldSpec)})})},"function"),(Qt().b[23][0]++,((o=this.props.value)==null?void 0:o.type)!=="identity"&&(Qt().b[23][1]++,G.jsx(ra,{label:"Base",children:G.jsx("div",{className:"maputnik-data-spec-property-input",children:G.jsx(my,{fieldName:"base",fieldSpec:no.function.base,value:(s=this.props.value)==null?void 0:s.base,onChange:(B,k)=>(Qt().f[22]++,Qt().s[76]++,this.changeBase(k))})})},"base"))),G.jsx(ra,{label:"Property",children:G.jsx("div",{className:"maputnik-data-spec-property-input",children:G.jsx(wd,{value:(a=this.props.value)==null?void 0:a.property,title:"Input a data property to base styles off of.",onChange:B=>(Qt().f[23]++,Qt().s[77]++,this.changeDataProperty("property",B))})})},"property"),(Qt().b[24][0]++,t&&(Qt().b[24][1]++,G.jsx(ra,{label:"Default",children:G.jsx(my,{fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:(h=this.props.value)==null?void 0:h.default,onChange:(B,k)=>(Qt().f[24]++,Qt().s[78]++,this.changeDataProperty("default",k))})},"default"))),(Qt().b[25][0]++,t&&(Qt().b[25][1]++,G.jsx("div",{className:"maputnik-function-stop",children:G.jsxs("table",{className:"maputnik-function-stop-table",children:[G.jsx("caption",{children:"Stops"}),G.jsx("thead",{children:G.jsxs("tr",{children:[G.jsx("th",{children:"Zoom"}),G.jsx("th",{children:"Input value"}),G.jsx("th",{rowSpan:2,children:"Output value"})]})}),G.jsx("tbody",{children:t})]})}))),G.jsxs("div",{className:"maputnik-toolbox",children:[(Qt().b[26][0]++,t&&(Qt().b[26][1]++,G.jsxs(ja,{className:"maputnik-add-stop",onClick:(g=this.props.onAddStop)==null?void 0:g.bind(this),children:[G.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:G.jsx("path",{fill:"currentColor",d:S8})})," Add stop"]}))),G.jsxs(ja,{className:"maputnik-add-stop",onClick:(C=this.props.onExpressionClick)==null?void 0:C.bind(this),children:[G.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:G.jsx("path",{fill:"currentColor",d:SC})})," Convert to expression"]})]})]})]})})}}function zn(){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 zn=function(){return s},s}zn();function TP(e,n){zn().f[0]++;let t=(zn().s[0]++,{});return zn().s[1]++,zn().b[1][0]++,e.value&&(zn().b[1][1]++,e.value.stops)?(zn().b[0][0]++,zn().s[2]++,e.value.stops.forEach((r,i)=>{zn().f[1]++,zn().s[3]++,Object.prototype.hasOwnProperty.call(!n.refs,i)?(zn().b[2][0]++,zn().s[4]++,t?zn().b[3][1]++:(zn().b[3][0]++,zn().s[5]++,t={...n}),zn().s[6]++,t[i]=Ty("stop-")):(zn().b[2][1]++,zn().s[7]++,t[i]=n.refs[i])})):zn().b[0][1]++,zn().s[8]++,t}class OG extends Sn.Component{constructor(){super(...arguments);an(this,"state",(zn().s[10]++,{refs:{}}));an(this,"changeDataType",(zn().s[36]++,t=>{zn().f[11]++,zn().s[37]++,zn().b[8][0]++,t!=="interpolate"&&(zn().b[8][1]++,this.props.onChangeToDataFunction)?(zn().b[7][0]++,zn().s[38]++,this.props.onChangeToDataFunction(t)):zn().b[7][1]++}))}componentDidMount(){zn().f[2]++;const t=(zn().s[11]++,TP(this.props,this.state));zn().s[12]++,t?(zn().b[4][0]++,zn().s[13]++,this.setState({refs:t})):zn().b[4][1]++}static getDerivedStateFromProps(t,r){zn().f[3]++;const i=(zn().s[14]++,TP(t,r));return zn().s[15]++,i?(zn().b[5][0]++,zn().s[16]++,{refs:i}):(zn().b[5][1]++,zn().s[17]++,null)}orderStopsByZoom(t){zn().f[4]++;const r=(zn().s[18]++,t.map((o,s)=>(zn().f[5]++,zn().s[19]++,{ref:this.state.refs[s],data:o})).sort((o,s)=>(zn().f[6]++,zn().s[20]++,SG(o.data[0],s.data[0])))),i=(zn().s[21]++,{});return zn().s[22]++,r.forEach((o,s)=>{zn().f[7]++,zn().s[23]++,i[s]=o.ref}),zn().s[24]++,this.setState({refs:i}),zn().s[25]++,r.map(o=>(zn().f[8]++,zn().s[26]++,o.data))}changeZoomStop(t,r,i){zn().f[9]++;const o=(zn().s[27]++,this.props.value.stops.slice(0));zn().s[28]++,o[t]=[r,i];const s=(zn().s[29]++,this.orderStopsByZoom(o)),a=(zn().s[30]++,{...this.props.value,stops:s});zn().s[31]++,this.props.onChange(this.props.fieldName,a)}changeBase(t){zn().f[10]++;const r=(zn().s[32]++,{...this.props.value,base:t});zn().s[33]++,r.base===void 0?(zn().b[6][0]++,zn().s[34]++,delete r.base):zn().b[6][1]++,zn().s[35]++,this.props.onChange(this.props.fieldName,r)}render(){var r,i,o,s;zn().f[12]++;const t=(zn().s[39]++,(r=this.props.value)==null?void 0:r.stops.map((a,h)=>{var P;zn().f[13]++;const g=(zn().s[40]++,a[0]),C=(zn().s[41]++,this.state.refs[h]),B=(zn().s[42]++,a[1]),k=(zn().s[43]++,G.jsx(EG,{onClick:(P=this.props.onDeleteStop)==null?void 0:P.bind(this,h)}));return zn().s[44]++,G.jsxs("tr",{children:[G.jsx("td",{children:G.jsx(wf,{"aria-label":"Zoom",value:g,onChange:L=>(zn().f[14]++,zn().s[45]++,this.changeZoomStop(h,L,B)),min:0,max:22})}),G.jsx("td",{children:G.jsx(my,{"aria-label":"Output value",fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:B,onChange:(L,J)=>(zn().f[15]++,zn().s[46]++,this.changeZoomStop(h,g,J))})}),G.jsx("td",{children:k})]},C)}));return zn().s[47]++,G.jsx("div",{className:"maputnik-data-spec-block",children:G.jsxs("fieldset",{className:"maputnik-data-spec-property",children:[G.jsx("legend",{children:z5(this.props.fieldName)}),G.jsxs("div",{className:"maputnik-data-fieldset-inner",children:[G.jsx(ra,{label:"Function",children:G.jsx("div",{className:"maputnik-data-spec-property-input",children:G.jsx(x1,{value:"interpolate",onChange:a=>(zn().f[16]++,zn().s[48]++,this.changeDataType(a)),title:"Select a type of data scale (default is 'categorical').",options:this.getDataFunctionTypes(this.props.fieldSpec)})})}),G.jsx(ra,{label:"Base",children:G.jsx("div",{className:"maputnik-data-spec-property-input",children:G.jsx(my,{fieldName:"base",fieldSpec:no.function.base,value:(i=this.props.value)==null?void 0:i.base,onChange:(a,h)=>(zn().f[17]++,zn().s[49]++,this.changeBase(h))})})}),G.jsx("div",{className:"maputnik-function-stop",children:G.jsxs("table",{className:"maputnik-function-stop-table maputnik-function-stop-table--zoom",children:[G.jsx("caption",{children:"Stops"}),G.jsx("thead",{children:G.jsxs("tr",{children:[G.jsx("th",{children:"Zoom"}),G.jsx("th",{rowSpan:2,children:"Output value"})]})}),G.jsx("tbody",{children:t})]})}),G.jsxs("div",{className:"maputnik-toolbox",children:[G.jsxs(ja,{className:"maputnik-add-stop",onClick:(o=this.props.onAddStop)==null?void 0:o.bind(this),children:[G.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:G.jsx("path",{fill:"currentColor",d:S8})})," Add stop"]}),G.jsxs(ja,{className:"maputnik-add-stop",onClick:(s=this.props.onExpressionClick)==null?void 0:s.bind(this),children:[G.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:G.jsx("path",{fill:"currentColor",d:SC})})," Convert to expression"]})]})]})]})})}getDataFunctionTypes(t){return zn().f[18]++,zn().s[50]++,t["property-type"]==="data-driven"?(zn().b[9][0]++,zn().s[51]++,["interpolate","categorical","interval","exponential","identity"]):(zn().b[9][1]++,zn().s[52]++,["interpolate"])}}an(OG,"defaultProps",(zn().s[9]++,{errors:{}}));function dt(){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 dt=function(){return s},s}dt();function KP(e){return dt().f[0]++,dt().s[0]++,dt().b[0][0]++,Array.isArray(e)&&(dt().b[0][1]++,e.length===2)&&(dt().b[0][2]++,e[0]==="literal")}function PP(e){return dt().f[1]++,dt().s[1]++,dt().b[1][0]++,Array.isArray(e)&&(dt().b[1][1]++,e.length===2)&&(dt().b[1][2]++,e[0]==="get")}function kEe(e){return dt().f[2]++,dt().s[2]++,dt().b[2][0]++,typeof e=="object"&&(dt().b[2][1]++,e.stops)&&(dt().b[2][2]++,typeof e.property>"u")&&(dt().b[2][3]++,Array.isArray(e.stops))&&(dt().b[2][4]++,e.stops.length>1)&&(dt().b[2][5]++,e.stops.every(n=>(dt().f[3]++,dt().s[3]++,dt().b[3][0]++,Array.isArray(n)&&(dt().b[3][1]++,n.length===2))))}function BG(e){return dt().f[4]++,dt().s[4]++,dt().b[4][0]++,typeof e=="object"&&(dt().b[4][1]++,e.type==="identity")&&(dt().b[4][2]++,Object.prototype.hasOwnProperty.call(e,"property"))}function IEe(e){return dt().f[5]++,dt().s[5]++,dt().b[5][0]++,typeof e=="object"&&(dt().b[5][1]++,e.stops)&&(dt().b[5][2]++,typeof e.property<"u")&&(dt().b[5][3]++,e.stops.length>1)&&(dt().b[5][4]++,Array.isArray(e.stops))&&(dt().b[5][5]++,e.stops.every(n=>(dt().f[6]++,dt().s[6]++,dt().b[6][0]++,Array.isArray(n)&&(dt().b[6][1]++,n.length===2)&&(dt().b[6][2]++,typeof n[0]=="object"))))}function TEe(e){return dt().f[7]++,dt().s[7]++,dt().b[7][0]++,BG(e)||(dt().b[7][1]++,IEe(e))}function lk(e){dt().f[8]++;const n=(dt().s[8]++,["string","boolean","number"]);return dt().s[9]++,n.includes(typeof e)}function KEe(e){return dt().f[9]++,dt().s[10]++,Array.isArray(e)?(dt().b[8][0]++,dt().s[11]++,e.every(lk)):(dt().b[8][1]++,dt().s[12]++,!1)}function FP(e,n=(dt().b[9][0]++,{})){return dt().f[10]++,dt().s[13]++,e===void 0?(dt().b[10][0]++,dt().s[14]++,"value"):(dt().b[10][1]++,dt().s[15]++,lk(e)?(dt().b[11][0]++,dt().s[16]++,"value"):(dt().b[11][1]++,dt().s[17]++,dt().b[13][0]++,n.type==="array"&&(dt().b[13][1]++,KEe(e))?(dt().b[12][0]++,dt().s[18]++,"value"):(dt().b[12][1]++,dt().s[19]++,kEe(e)?(dt().b[14][0]++,dt().s[20]++,"zoom_function"):(dt().b[14][1]++,dt().s[21]++,TEe(e)?(dt().b[15][0]++,dt().s[22]++,"data_function"):(dt().b[15][1]++,dt().s[23]++,"expression")))))}class PEe extends Sn.Component{constructor(t){dt().f[11]++,dt().s[24]++;super(t);an(this,"addStop",(dt().s[34]++,()=>{dt().f[14]++;const t=(dt().s[35]++,this.props.value.stops.slice(0)),r=(dt().s[36]++,t[t.length-1]);dt().s[37]++,typeof r[0]=="object"?(dt().b[19][0]++,dt().s[38]++,t.push([{zoom:r[0].zoom+1,value:r[0].value},r[1]])):(dt().b[19][1]++,dt().s[39]++,t.push([r[0]+1,r[1]]));const i=(dt().s[40]++,{...this.props.value,stops:t});dt().s[41]++,this.props.onChange(this.props.fieldName,i)}));an(this,"deleteExpression",(dt().s[42]++,()=>{dt().f[15]++;const{fieldSpec:t,fieldName:r}=(dt().s[43]++,this.props);dt().s[44]++,this.props.onChange(r,t.default),dt().s[45]++,this.setState({dataType:"value"})}));an(this,"deleteStop",(dt().s[46]++,t=>{dt().f[16]++;const r=(dt().s[47]++,this.props.value.stops.slice(0));dt().s[48]++,r.splice(t,1);let i=(dt().s[49]++,{...this.props.value,stops:r});dt().s[50]++,r.length===1?(dt().b[20][0]++,dt().s[51]++,i=r[0][1]):dt().b[20][1]++,dt().s[52]++,this.props.onChange(this.props.fieldName,i)}));an(this,"makeZoomFunction",(dt().s[53]++,()=>{dt().f[17]++;const{value:t}=(dt().s[54]++,this.props);let r;dt().s[55]++,typeof t=="object"?(dt().b[21][0]++,dt().s[56]++,t.stops?(dt().b[22][0]++,dt().s[57]++,r={base:t.base,stops:t.stops.map(i=>(dt().f[18]++,dt().s[58]++,[i[0].zoom,(dt().b[23][0]++,i[1]||(dt().b[23][1]++,cd(this.props.fieldSpec)))]))}):(dt().b[22][1]++,dt().s[59]++,r={base:t.base,stops:[[6,cd(this.props.fieldSpec)],[10,cd(this.props.fieldSpec)]]})):(dt().b[21][1]++,dt().s[60]++,r={stops:[[6,(dt().b[24][0]++,t||(dt().b[24][1]++,cd(this.props.fieldSpec)))],[10,(dt().b[25][0]++,t||(dt().b[25][1]++,cd(this.props.fieldSpec)))]]}),dt().s[61]++,this.props.onChange(this.props.fieldName,r)}));an(this,"undoExpression",(dt().s[62]++,()=>{dt().f[19]++;const{value:t,fieldName:r}=(dt().s[63]++,this.props);dt().s[64]++,PP(t)?(dt().b[26][0]++,dt().s[65]++,this.props.onChange(r,{type:"identity",property:t[1]}),dt().s[66]++,this.setState({dataType:"value"})):(dt().b[26][1]++,dt().s[67]++,KP(t)?(dt().b[27][0]++,dt().s[68]++,this.props.onChange(r,t[1]),dt().s[69]++,this.setState({dataType:"value"})):dt().b[27][1]++)}));an(this,"canUndo",(dt().s[70]++,()=>{dt().f[20]++;const{value:t,fieldSpec:r}=(dt().s[71]++,this.props);return dt().s[72]++,dt().b[28][0]++,PP(t)||(dt().b[28][1]++,KP(t))||(dt().b[28][2]++,lk(t))||(dt().b[28][3]++,Array.isArray(t)&&(dt().b[28][4]++,r.type==="array"))}));an(this,"makeExpression",(dt().s[73]++,()=>{dt().f[21]++;const{value:t,fieldSpec:r}=(dt().s[74]++,this.props);let i;dt().s[75]++,dt().b[30][0]++,typeof t=="object"&&(dt().b[30][1]++,"stops"in t)?(dt().b[29][0]++,dt().s[76]++,i=lJ.convertFunction(t,r)):(dt().b[29][1]++,dt().s[77]++,BG(t)?(dt().b[31][0]++,dt().s[78]++,i=["get",t.property]):(dt().b[31][1]++,dt().s[79]++,i=["literal",(dt().b[32][0]++,t||(dt().b[32][1]++,this.props.fieldSpec.default))])),dt().s[80]++,this.props.onChange(this.props.fieldName,i)}));an(this,"makeDataFunction",(dt().s[81]++,()=>{dt().f[22]++;const t=(dt().s[82]++,this.getFieldFunctionType(this.props.fieldSpec)),r=(dt().s[83]++,t==="categorical"?(dt().b[33][0]++,""):(dt().b[33][1]++,0)),{value:i}=(dt().s[84]++,this.props);let o;dt().s[85]++,typeof i=="object"?(dt().b[34][0]++,dt().s[86]++,i.stops?(dt().b[35][0]++,dt().s[87]++,o={property:"",type:t,base:i.base,stops:i.stops.map(s=>(dt().f[23]++,dt().s[88]++,[{zoom:s[0],value:r},(dt().b[36][0]++,s[1]||(dt().b[36][1]++,cd(this.props.fieldSpec)))]))}):(dt().b[35][1]++,dt().s[89]++,o={property:"",type:t,base:i.base,stops:[[{zoom:6,value:r},cd(this.props.fieldSpec)],[{zoom:10,value:r},cd(this.props.fieldSpec)]]})):(dt().b[34][1]++,dt().s[90]++,o={property:"",type:t,base:i.base,stops:[[{zoom:6,value:r},(dt().b[37][0]++,this.props.value||(dt().b[37][1]++,cd(this.props.fieldSpec)))],[{zoom:10,value:r},(dt().b[38][0]++,this.props.value||(dt().b[38][1]++,cd(this.props.fieldSpec)))]]}),dt().s[91]++,this.props.onChange(this.props.fieldName,o)}));an(this,"onMarkEditing",(dt().s[92]++,()=>{dt().f[24]++,dt().s[93]++,this.setState({isEditing:!0})}));an(this,"onUnmarkEditing",(dt().s[94]++,()=>{dt().f[25]++,dt().s[95]++,this.setState({isEditing:!1})}));dt().s[25]++,this.state={dataType:FP(t.value,t.fieldSpec),isEditing:!1}}static getDerivedStateFromProps(t,r){return dt().f[12]++,dt().s[26]++,r.isEditing?(dt().b[16][0]++,dt().s[27]++,{}):(dt().b[16][1]++,dt().s[28]++,{isEditing:!1,dataType:FP(t.value,t.fieldSpec)})}getFieldFunctionType(t){return dt().f[13]++,dt().s[29]++,t.expression.interpolated?(dt().b[17][0]++,dt().s[30]++,"exponential"):(dt().b[17][1]++,dt().s[31]++,t.type==="number"?(dt().b[18][0]++,dt().s[32]++,"interval"):(dt().b[18][1]++,dt().s[33]++,"categorical"))}render(){dt().f[26]++;const{dataType:t}=(dt().s[96]++,this.state),r=(dt().s[97]++,this.props.fieldSpec.default===this.props.value?(dt().b[39][0]++,"maputnik-default-property"):(dt().b[39][1]++,"maputnik-modified-property"));let i;return dt().s[98]++,t==="expression"?(dt().b[40][0]++,dt().s[99]++,i=G.jsx(k8,{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})):(dt().b[40][1]++,dt().s[100]++,t==="zoom_function"?(dt().b[41][0]++,dt().s[101]++,i=G.jsx(OG,{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})):(dt().b[41][1]++,dt().s[102]++,t==="data_function"?(dt().b[42][0]++,dt().s[103]++,i=G.jsx(BEe,{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})):(dt().b[42][1]++,dt().s[104]++,i=G.jsx(MG,{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})))),dt().s[105]++,G.jsx("div",{className:r,"data-wd-key":"spec-field-container:"+this.props.fieldName,children:i})}}function Ei(){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 Ei=function(){return s},s}Ei();const FEe=(Ei().s[0]++,["background-pattern","fill-pattern","line-pattern","fill-extrusion-pattern","icon-image"]);function DEe(e,n,t){Ei().f[0]++;const r=(Ei().s[1]++,kG(e,n,t)),i=(Ei().s[2]++,e[r+"_"+n]),o=(Ei().s[3]++,i[t]);return Ei().s[4]++,FEe.indexOf(t)>=0?(Ei().b[0][0]++,Ei().s[5]++,{...o,values:e.$root.sprite.values}):(Ei().b[0][1]++,Ei().s[6]++,t==="text-font"?(Ei().b[1][0]++,Ei().s[7]++,{...o,values:e.$root.glyphs.values}):(Ei().b[1][1]++,Ei().s[8]++,o))}function kG(e,n,t){Ei().f[1]++;const r=(Ei().s[9]++,Ei().b[2][0]++,e["paint_"+n]||(Ei().b[2][1]++,{}));return Ei().s[10]++,t in r?(Ei().b[3][0]++,Ei().s[11]++,"paint"):(Ei().b[3][1]++,Ei().s[12]++,"layout")}class LEe extends Sn.Component{constructor(){super(...arguments);an(this,"onPropertyChange",(Ei().s[13]++,(t,r)=>{Ei().f[2]++;const i=(Ei().s[14]++,kG(this.props.spec,this.props.layer.type,t));Ei().s[15]++,this.props.onChange(i,t,r)}))}render(){Ei().f[3]++;const{errors:t}=(Ei().s[16]++,this.props),r=(Ei().s[17]++,this.props.groupFields.map(i=>{Ei().f[4]++;const o=(Ei().s[18]++,DEe(this.props.spec,this.props.layer.type,i)),s=(Ei().s[19]++,Ei().b[4][0]++,this.props.layer.paint||(Ei().b[4][1]++,{})),a=(Ei().s[20]++,Ei().b[5][0]++,this.props.layer.layout||(Ei().b[5][1]++,{})),h=(Ei().s[21]++,i in s?(Ei().b[6][0]++,s[i]):(Ei().b[6][1]++,a[i])),g=(Ei().s[22]++,i in s?(Ei().b[7][0]++,"paint"):(Ei().b[7][1]++,"layout"));return Ei().s[23]++,G.jsx(PEe,{errors:t,onChange:this.onPropertyChange,fieldName:i,value:h,fieldType:g,fieldSpec:o},i)}));return Ei().s[24]++,G.jsx("div",{className:"maputnik-property-group",children:r})}}var UEe=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=hh},function(e,n){e.exports=Br},function(e,n,t){t.r(n);var r=t(1),i=t(0),o=function(){return(o=Object.assign||function(L){for(var J,N=1,$=arguments.length;N<$;N++)for(var q in J=arguments[N])Object.prototype.hasOwnProperty.call(J,q)&&(L[q]=J[q]);return L}).apply(this,arguments)},s=function(L,J){var N={};for(var $ in L)Object.prototype.hasOwnProperty.call(L,$)&&J.indexOf($)<0&&(N[$]=L[$]);if(L!=null&&typeof Object.getOwnPropertySymbols=="function"){var q=0;for($=Object.getOwnPropertySymbols(L);q<$.length;q++)J.indexOf($[q])<0&&Object.prototype.propertyIsEnumerable.call(L,$[q])&&(N[$[q]]=L[$[q]])}return N},a=0,h=r.forwardRef(function(L,J){var N=L.title,$=N===void 0?null:N,q=L.description,oe=q===void 0?null:q,ce=L.size,me=ce===void 0?null:ce,he=L.color,V=he===void 0?"currentColor":he,ae=L.horizontal,ye=ae===void 0?null:ae,Oe=L.vertical,De=Oe===void 0?null:Oe,He=L.rotate,ke=He===void 0?null:He,nt=L.spin,be=nt===void 0?null:nt,Bt=L.style,kt=Bt===void 0?{}:Bt,Yt=L.children,jt=s(L,["title","description","size","color","horizontal","vertical","rotate","spin","style","children"]);a++;var Xe,rt=be!==null&&be,ot=r.Children.map(Yt,function(It){var Lt=It;rt!==!0&&(rt=(be===null?Lt.props.spin:be)===!0);var Me=Lt.props.size;typeof me=="number"&&typeof Lt.props.size=="number"&&(Me=Lt.props.size/me);var fe={size:Me,color:V===null?Lt.props.color:V,horizontal:ye===null?Lt.props.horizontal:ye,vertical:De===null?Lt.props.vertical:De,rotate:ke===null?Lt.props.rotate:ke,spin:be===null?Lt.props.spin:be,inStack:!0};return r.cloneElement(Lt,fe)});me!==null&&(kt.width=typeof me=="string"?me:1.5*me+"rem");var on,gt="stack_labelledby_"+a,at="stack_describedby_"+a;if($)Xe=oe?gt+" "+at:gt;else if(on="presentation",oe)throw new Error("title attribute required when description is set");return r.createElement("svg",o({ref:J,viewBox:"0 0 24 24",style:kt,role:on,"aria-labelledby":Xe},jt),$&&r.createElement("title",{id:gt},$),oe&&r.createElement("desc",{id:at},oe),rt&&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) } }"),ot)});h.displayName="Stack",h.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},h.defaultProps={size:null,color:null,horizontal:null,vertical:null,rotate:null,spin:null};var g=h;t.d(n,"Icon",function(){return P}),t.d(n,"Stack",function(){return g});var C=function(){return(C=Object.assign||function(L){for(var J,N=1,$=arguments.length;N<$;N++)for(var q in J=arguments[N])Object.prototype.hasOwnProperty.call(J,q)&&(L[q]=J[q]);return L}).apply(this,arguments)},B=function(L,J){var N={};for(var $ in L)Object.prototype.hasOwnProperty.call(L,$)&&J.indexOf($)<0&&(N[$]=L[$]);if(L!=null&&typeof Object.getOwnPropertySymbols=="function"){var q=0;for($=Object.getOwnPropertySymbols(L);q<$.length;q++)J.indexOf($[q])<0&&Object.prototype.propertyIsEnumerable.call(L,$[q])&&(N[$[q]]=L[$[q]])}return N},k=0,P=r.forwardRef(function(L,J){var N=L.path,$=L.id,q=$===void 0?++k:$,oe=L.title,ce=oe===void 0?null:oe,me=L.description,he=me===void 0?null:me,V=L.size,ae=V===void 0?null:V,ye=L.color,Oe=ye===void 0?"currentColor":ye,De=L.horizontal,He=De!==void 0&&De,ke=L.vertical,nt=ke!==void 0&&ke,be=L.rotate,Bt=be===void 0?0:be,kt=L.spin,Yt=kt!==void 0&&kt,jt=L.style,Xe=jt===void 0?{}:jt,rt=L.inStack,ot=rt!==void 0&&rt,on=B(L,["path","id","title","description","size","color","horizontal","vertical","rotate","spin","style","inStack"]),gt={},at=[];ae!==null&&(ot?at.push("scale("+ae+")"):(Xe.width=typeof ae=="string"?ae:1.5*ae+"rem",Xe.height=Xe.width)),He&&at.push("scaleX(-1)"),nt&&at.push("scaleY(-1)"),Bt!==0&&at.push("rotate("+Bt+"deg)"),Oe!==null&&(gt.fill=Oe);var It=r.createElement("path",C({d:N,style:gt},ot?on:{})),Lt=It;at.length>0&&(Xe.transform=at.join(" "),Xe.transformOrigin="center",ot&&(Lt=r.createElement("g",{style:Xe},It,r.createElement("rect",{width:"24",height:"24",fill:"transparent"}))));var Me,fe=Lt,xe=Yt===!0||typeof Yt!="number"?2:Yt,Ue=!ot&&(He||nt);if(xe<0&&(Ue=!Ue),Yt&&(fe=r.createElement("g",{style:{animation:"spin"+(Ue?"-inverse":"")+" linear "+Math.abs(xe)+"s infinite",transformOrigin:"center"}},Lt,!(He||nt||Bt!==0)&&r.createElement("rect",{width:"24",height:"24",fill:"transparent"}))),ot)return fe;var et,it="icon_labelledby_"+q,bt="icon_describedby_"+q;if(ce)Me=he?it+" "+bt:it;else if(et="presentation",he)throw new Error("title attribute required when description is set");return r.createElement("svg",C({ref:J,viewBox:"0 0 24 24",style:Xe,role:et,"aria-labelledby":Me},on),ce&&r.createElement("title",{id:it},ce),he&&r.createElement("desc",{id:bt},he),!ot&&Yt&&(Ue?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) } }")),fe)});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 DP=fa(UEe);function $g(){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 $g=function(){return s},s}$g();class REe extends Sn.Component{render(){return $g().f[0]++,$g().s[0]++,G.jsxs(VW,{uuid:this.props.id,children:[G.jsx(JW,{className:"maputnik-layer-editor-group","data-wd-key":"layer-editor-group:"+this.props["data-wd-key"],onClick:n=>($g().f[1]++,$g().s[1]++,this.props.onActiveToggle(!this.props.isActive)),children:G.jsxs(fme,{className:"maputnik-layer-editor-group__button",children:[G.jsx("span",{style:{flexGrow:1},children:this.props.title}),G.jsx(DP,{path:Mme,size:1,className:"maputnik-layer-editor-group__button__icon maputnik-layer-editor-group__button__icon--up"}),G.jsx(DP,{path:wme,size:1,className:"maputnik-layer-editor-group__button__icon maputnik-layer-editor-group__button__icon--down"})]})}),G.jsx(gme,{children:this.props.children})]})}}function d4(){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 d4=function(){return s},s}d4();class zEe extends Sn.Component{render(){return d4().f[0]++,d4().s[0]++,G.jsx(ra,{label:"Min Zoom",fieldSpec:no.layer.minzoom,error:this.props.error,"data-wd-key":"min-zoom",children:G.jsx(wf,{allowRange:!0,value:this.props.value,onChange:this.props.onChange,min:no.layer.minzoom.minimum,max:no.layer.minzoom.maximum,default:no.layer.minzoom.minimum,"data-wd-key":"min-zoom.input"})})}}function h4(){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 h4=function(){return s},s}h4();class jEe extends Sn.Component{render(){return h4().f[0]++,h4().s[0]++,G.jsx(ra,{label:"Max Zoom",fieldSpec:no.layer.maxzoom,error:this.props.error,"data-wd-key":"max-zoom",children:G.jsx(wf,{allowRange:!0,value:this.props.value,onChange:this.props.onChange,min:no.layer.maxzoom.minimum,max:no.layer.maxzoom.maximum,default:no.layer.maxzoom.maximum,"data-wd-key":"max-zoom.input"})})}}function R_(){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 R_=function(){return s},s}R_();class WEe extends Sn.Component{render(){R_().f[0]++;const n=(R_().s[0]++,{doc:"Comments for the current layer. This is non-standard and not in the spec."});return R_().s[1]++,G.jsx(ra,{label:"Comments",fieldSpec:n,"data-wd-key":"layer-comment",error:this.props.error,children:G.jsx(wd,{multi:!0,value:this.props.value,onChange:this.props.onChange,default:"Comment...","data-wd-key":"layer-comment.input"})})}}const NEe={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"]}]},GEe={groups:[{title:"Paint properties",type:"properties",fields:["background-color","background-pattern","background-opacity"]}]},QEe={groups:[{title:"Paint properties",type:"properties",fields:["fill-opacity","fill-color","fill-antialias","fill-outline-color","fill-pattern","fill-translate","fill-translate-anchor"]}]},$Ee={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"]}]},YEe={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"]}]},qEe={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"]}]},HEe={groups:[{title:"Paint properties",type:"properties",fields:["hillshade-illumination-direction","hillshade-illumination-anchor","hillshade-exaggeration","hillshade-shadow-color","hillshade-highlight-color","hillshade-accent-color"]}]},VEe={groups:[{title:"Paint properties",type:"properties",fields:["heatmap-radius","heatmap-weight","heatmap-intensity","heatmap-opacity"]}]},ZEe={groups:[]},hS={line:NEe,background:GEe,fill:QEe,"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:$Ee,symbol:YEe,raster:qEe,hillshade:HEe,heatmap:VEe,invalid:ZEe};function Yg(){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 Yg=function(){return s},s}Yg();function IG(e){return Yg().f[0]++,Yg().s[0]++,e===""?(Yg().b[0][0]++,"[empty_string]"):(Yg().b[0][1]++,`'${e}'`)}function un(){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 un=function(){return s},s}un();function TG(e){return un().f[0]++,un().s[0]++,hS[e]?(un().b[0][0]++,hS[e]):(un().b[0][1]++,hS.invalid)}function LP(e){un().f[1]++;const n=(un().s[1]++,{title:"Layer",type:"layer"}),t=(un().s[2]++,{title:"Filter",type:"filter"}),r=(un().s[3]++,{title:"JSON Editor",type:"jsoneditor"});return un().s[4]++,[n,t].concat(TG(e).groups).concat([r])}class hO extends Sn.Component{constructor(n){un().f[5]++,un().s[7]++,super(n);const t=(un().s[8]++,{});un().s[9]++,LP(this.props.layer.type).forEach(r=>{un().f[6]++,un().s[10]++,t[r.title]=!0}),un().s[11]++,this.state={editorGroups:t}}static getDerivedStateFromProps(n,t){un().f[7]++;const r=(un().s[12]++,{...t.editorGroups});return un().s[13]++,TG(n.layer.type).groups.forEach(i=>{un().f[8]++,un().s[14]++,i.title in r?un().b[1][1]++:(un().b[1][0]++,un().s[15]++,r[i.title]=!0)}),un().s[16]++,{editorGroups:r}}getChildContext(){return un().f[9]++,un().s[17]++,{reactIconBase:{size:14,color:"#8e8e8e"}}}changeProperty(n,t,r){un().f[10]++,un().s[18]++,this.props.onLayerChanged(this.props.layerIndex,Vfe(this.props.layer,n,t,r))}onGroupToggle(n,t){un().f[11]++;const r=(un().s[19]++,{...this.state.editorGroups,[n]:t});un().s[20]++,this.setState({editorGroups:r})}renderGroupType(n,t){un().f[12]++;let r=(un().s[21]++,"");un().s[22]++,this.props.layer.metadata?(un().b[2][0]++,un().s[23]++,r=this.props.layer.metadata["maputnik:comment"]):un().b[2][1]++;const{errors:i,layerIndex:o}=(un().s[24]++,this.props),s=(un().s[25]++,{});un().s[26]++,i.forEach(g=>{un().f[13]++,un().s[27]++,un().b[4][0]++,g.parsed&&(un().b[4][1]++,g.parsed.type==="layer")&&(un().b[4][2]++,g.parsed.data.index==o)?(un().b[3][0]++,un().s[28]++,s[g.parsed.data.key]={message:g.parsed.data.message}):un().b[3][1]++});let a;const h=(un().s[29]++,this.props.layer);switch(un().s[30]++,Object.prototype.hasOwnProperty.call(this.props.sources,h.source)?(un().b[5][0]++,un().s[31]++,a=this.props.sources[h.source].layers):un().b[5][1]++,un().s[32]++,n){case"layer":return un().b[6][0]++,un().s[33]++,G.jsxs("div",{children:[G.jsx(TW,{value:this.props.layer.id,wdKey:"layer-editor.layer-id",error:s.id,onChange:g=>(un().f[14]++,un().s[34]++,this.props.onLayerIdChange(this.props.layerIndex,this.props.layer.id,g))}),G.jsx(f8,{disabled:!0,error:s.type,value:this.props.layer.type,onChange:g=>(un().f[15]++,un().s[35]++,this.props.onLayerChanged(this.props.layerIndex,Hfe(this.props.layer,g)))}),(un().b[7][0]++,this.props.layer.type!=="background"&&(un().b[7][1]++,G.jsx(m8,{error:s.source,sourceIds:Object.keys(this.props.sources),value:this.props.layer.source,onChange:g=>(un().f[16]++,un().s[36]++,this.changeProperty(null,"source",g))}))),(un().b[8][0]++,["background","raster","hillshade","heatmap"].indexOf(this.props.layer.type)<0&&(un().b[8][1]++,G.jsx(g8,{error:s["source-layer"],sourceLayerIds:a,value:this.props.layer["source-layer"],onChange:g=>(un().f[17]++,un().s[37]++,this.changeProperty(null,"source-layer",g))}))),G.jsx(zEe,{error:s.minzoom,value:this.props.layer.minzoom,onChange:g=>(un().f[18]++,un().s[38]++,this.changeProperty(null,"minzoom",g))}),G.jsx(jEe,{error:s.maxzoom,value:this.props.layer.maxzoom,onChange:g=>(un().f[19]++,un().s[39]++,this.changeProperty(null,"maxzoom",g))}),G.jsx(WEe,{error:s.comment,value:r,onChange:g=>(un().f[20]++,un().s[40]++,this.changeProperty("metadata","maputnik:comment",g==""?(un().b[9][0]++,void 0):(un().b[9][1]++,g)))})]});case"filter":return un().b[6][1]++,un().s[41]++,G.jsx("div",{children:G.jsx("div",{className:"maputnik-filter-editor-wrapper",children:G.jsx(mN,{errors:s,filter:this.props.layer.filter,properties:this.props.vectorLayers[this.props.layer["source-layer"]],onChange:g=>(un().f[21]++,un().s[42]++,this.changeProperty(null,"filter",g))})})});case"properties":return un().b[6][2]++,un().s[43]++,G.jsx(LEe,{errors:s,layer:this.props.layer,groupFields:t,spec:this.props.spec,onChange:this.changeProperty.bind(this)});case"jsoneditor":return un().b[6][3]++,un().s[44]++,G.jsx(M8,{layer:this.props.layer,onChange:g=>{un().f[22]++,un().s[45]++,this.props.onLayerChanged(this.props.layerIndex,g)}});default:return un().b[6][4]++,un().s[46]++,G.jsx(G.Fragment,{})}}moveLayer(n){un().f[23]++,un().s[47]++,this.props.onMoveLayer({oldIndex:this.props.layerIndex,newIndex:this.props.layerIndex+n})}render(){un().f[24]++;const n=(un().s[48]++,[]),t=(un().s[49]++,this.props.layer.type),r=(un().s[50]++,LP(t).filter(a=>(un().f[25]++,un().s[51]++,un().b[10][0]++,!(t==="background"&&(un().b[10][1]++,a.type==="source")))).map(a=>{un().f[26]++;const h=(un().s[52]++,a.title.replace(/ /g,"_"));return un().s[53]++,n.push(h),un().s[54]++,G.jsx(REe,{"data-wd-key":a.title,id:h,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=(un().s[55]++,un().b[11][0]++,this.props.layer.layout||(un().b[11][1]++,{})),o=(un().s[56]++,{delete:{text:"Delete",handler:()=>(un().f[27]++,un().s[57]++,this.props.onLayerDestroy(this.props.layerIndex))},duplicate:{text:"Duplicate",handler:()=>(un().f[28]++,un().s[58]++,this.props.onLayerCopy(this.props.layerIndex))},hide:{text:i.visibility==="none"?(un().b[12][0]++,"Show"):(un().b[12][1]++,"Hide"),handler:()=>(un().f[29]++,un().s[59]++,this.props.onLayerVisibilityToggle(this.props.layerIndex))},moveLayerUp:{text:"Move layer up",disabled:this.props.isFirstLayer,handler:()=>(un().f[30]++,un().s[60]++,this.moveLayer(-1))},moveLayerDown:{text:"Move layer down",disabled:this.props.isLastLayer,handler:()=>(un().f[31]++,un().s[61]++,this.moveLayer(1))}});function s(a,h){un().f[32]++,un().s[62]++,h.stopPropagation(),un().s[63]++,o[a].handler()}return un().s[64]++,G.jsxs("section",{className:"maputnik-layer-editor",role:"main","aria-label":"Layer editor",children:[G.jsx("header",{children:G.jsxs("div",{className:"layer-header",children:[G.jsxs("h2",{className:"layer-header__title",children:["Layer: ",IG(this.props.layer.id)]}),G.jsx("div",{className:"layer-header__info",children:G.jsxs(Yx.Wrapper,{className:"more-menu",onSelection:s,closeOnSelection:!1,children:[G.jsx(Yx.Button,{id:"skip-target-layer-editor","data-wd-key":"skip-target-layer-editor",className:"more-menu__button",title:"Layer options",children:G.jsx(eee,{className:"more-menu__button__svg"})}),G.jsx(Yx.Menu,{children:G.jsx("ul",{className:"more-menu__menu",children:Object.keys(o).map(a=>{un().f[33]++;const h=(un().s[65]++,o[a]);return un().s[66]++,G.jsx("li",{children:G.jsx(Yx.MenuItem,{value:a,className:"more-menu__menu__item",children:h.text})},a)})})})]})})]})}),G.jsx(rme,{allowMultipleExpanded:!0,allowZeroExpanded:!0,preExpanded:n,children:r})]})}}an(hO,"defaultProps",(un().s[5]++,{onLayerChanged:()=>{un().f[2]++},onLayerIdChange:()=>{un().f[3]++},onLayerDestroyed:()=>{un().f[4]++}})),an(hO,"childContextTypes",(un().s[6]++,{reactIconBase:Rr.object}));var UP=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))},XEe=function(){function e(n,t,r){this.name=n,this.version=t,this.os=r,this.type="browser"}return e}(),JEe=function(){function e(n){this.version=n,this.type="node",this.name="node",this.os=process.platform}return e}(),eOe=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}(),tOe=function(){function e(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null}return e}(),nOe=function(){function e(){this.type="react-native",this.name="react-native",this.version=null,this.os=null}return e}(),rOe=/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/,iOe=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,RP=3,oOe=[["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",rOe]],zP=[["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 aOe(e){return e?jP(e):typeof document>"u"&&typeof navigator<"u"&&navigator.product==="ReactNative"?new nOe:typeof navigator<"u"?jP(navigator.userAgent):uOe()}function sOe(e){return e!==""&&oOe.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 jP(e){var n=sOe(e);if(!n)return null;var t=n[0],r=n[1];if(t==="searchbot")return new tOe;var i=r[1]&&r[1].split(".").join("_").split("_").slice(0,3);i?i.length<RP&&(i=UP(UP([],i,!0),AOe(RP-i.length),!0)):i=[];var o=i.join("."),s=lOe(e),a=iOe.exec(e);return a&&a[1]?new eOe(t,o,s,a[1]):new XEe(t,o,s)}function lOe(e){for(var n=0,t=zP.length;n<t;n++){var r=zP[n],i=r[0],o=r[1],s=o.exec(e);if(s)return i}return null}function uOe(){var e=typeof process<"u"&&process.version;return e?new JEe(process.version.slice(1)):null}function AOe(e){for(var n=[],t=0;t<e;t++)n.push("0");return n}const cOe="maputnik",dOe="2.0.0",hOe="A MapLibre GL visual style editor",fOe="module",pOe="''",mOe={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"'},gOe={type:"git",url:"https://github.com/maplibre/maputnik"},yOe="Lukas Martinelli",vOe="MIT",_Oe="https://github.com/maplibre/maputnik#readme",COe={"@mapbox/mapbox-gl-rtl-text":"^0.2.3","@maplibre/maplibre-gl-geocoder":"^1.5.0","@maplibre/maplibre-gl-inspect":"^1.6.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","maplibre-gl":"^4.0.0","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"},bOe={esversion:6},xOe={extends:"stylelint-config-recommended-scss",rules:{"no-descending-specificity":null,"media-feature-name-no-unknown":[!0,{ignoreMediaFeatureNames:["prefers-reduced-motion"]}]}},wOe={"@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/randomcolor":"^0.5.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"},WP={name:cOe,version:dOe,description:hOe,type:fOe,main:pOe,scripts:mOe,repository:gOe,author:yOe,license:vOe,homepage:_Oe,dependencies:COe,jshintConfig:bOe,stylelint:xOe,devDependencies:wOe},MOe="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 ji(){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 ji=function(){return s},s}ji();const SOe=(ji().s[0]++,aOe()),Zx=(ji().s[1]++,["chrome","firefox"].indexOf(SOe.name)>-1);class Xv extends Sn.Component{render(){return ji().f[0]++,ji().s[2]++,G.jsx("span",{className:"maputnik-icon-text",children:this.props.children})}}class EOe extends Sn.Component{render(){return ji().f[1]++,ji().s[3]++,G.jsx("a",{className:bf("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 OOe extends Sn.Component{render(){return ji().f[2]++,ji().s[4]++,G.jsx("div",{className:"maputnik-toolbar-select","data-wd-key":this.props.wdKey,children:this.props.children})}}class Xx extends Sn.Component{render(){return ji().f[3]++,ji().s[5]++,G.jsx("button",{className:"maputnik-toolbar-action","data-wd-key":this.props.wdKey,onClick:this.props.onClick,children:this.props.children})}}class BOe extends Sn.Component{constructor(){super(...arguments);an(this,"state",(ji().s[6]++,{isOpen:{settings:!1,sources:!1,open:!1,add:!1,export:!1}}));an(this,"onSkip",(ji().s[8]++,t=>{if(ji().f[5]++,ji().s[9]++,t==="map")ji().b[0][0]++,ji().s[10]++,document.querySelector(".maplibregl-canvas").focus();else{ji().b[0][1]++;const r=(ji().s[11]++,document.querySelector("#skip-target-"+t));ji().s[12]++,r.focus()}}))}handleSelection(t){ji().f[4]++,ji().s[7]++,this.props.onSetMapState(t)}render(){ji().f[6]++;const t=(ji().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:!Zx},{id:"filter-protanopia",group:"color-accessibility",title:"Protanopia filter",disabled:!Zx},{id:"filter-tritanopia",group:"color-accessibility",title:"Tritanopia filter",disabled:!Zx},{id:"filter-achromatopsia",group:"color-accessibility",title:"Achromatopsia filter",disabled:!Zx}]),r=(ji().s[14]++,t.find(i=>(ji().f[7]++,ji().s[15]++,i.id===this.props.mapState)));return ji().s[16]++,G.jsx("nav",{className:"maputnik-toolbar",children:G.jsxs("div",{className:"maputnik-toolbar__inner",children:[G.jsxs("div",{className:"maputnik-toolbar-logo-container",children:[G.jsx("button",{"data-wd-key":"root:skip:layer-list",className:"maputnik-toolbar-skip",onClick:i=>(ji().f[8]++,ji().s[17]++,this.onSkip("layer-list")),children:"Layers list"}),G.jsx("button",{"data-wd-key":"root:skip:layer-editor",className:"maputnik-toolbar-skip",onClick:i=>(ji().f[9]++,ji().s[18]++,this.onSkip("layer-editor")),children:"Layer editor"}),G.jsx("button",{"data-wd-key":"root:skip:map-view",className:"maputnik-toolbar-skip",onClick:i=>(ji().f[10]++,ji().s[19]++,this.onSkip("map")),children:"Map view"}),G.jsxs("a",{className:"maputnik-toolbar-logo",target:"blank",rel:"noreferrer noopener",href:"https://github.com/maplibre/maputnik",children:[G.jsx("img",{src:MOe,alt:"Maputnik on GitHub"}),G.jsxs("h1",{children:[G.jsx("span",{className:"maputnik-toolbar-name",children:WP.name}),G.jsxs("span",{className:"maputnik-toolbar-version",children:["v",WP.version]})]})]})]}),G.jsxs("div",{className:"maputnik-toolbar__actions",role:"navigation","aria-label":"Toolbar",children:[G.jsxs(Xx,{wdKey:"nav:open",onClick:this.props.onToggleModal.bind(this,"open"),children:[G.jsx(jJ,{}),G.jsx(Xv,{children:"Open"})]}),G.jsxs(Xx,{wdKey:"nav:export",onClick:this.props.onToggleModal.bind(this,"export"),children:[G.jsx(z6,{}),G.jsx(Xv,{children:"Export"})]}),G.jsxs(Xx,{wdKey:"nav:sources",onClick:this.props.onToggleModal.bind(this,"sources"),children:[G.jsx(VJ,{}),G.jsx(Xv,{children:"Data Sources"})]}),G.jsxs(Xx,{wdKey:"nav:settings",onClick:this.props.onToggleModal.bind(this,"settings"),children:[G.jsx(WJ,{}),G.jsx(Xv,{children:"Style Settings"})]}),G.jsxs(OOe,{wdKey:"nav:inspect",children:[G.jsx(LJ,{}),G.jsxs("label",{children:["View",G.jsxs("select",{className:"maputnik-select","data-wd-key":"maputnik-select",onChange:i=>(ji().f[11]++,ji().s[20]++,this.handleSelection(i.target.value)),value:r==null?void 0:r.id,children:[t.filter(i=>(ji().f[12]++,ji().s[21]++,i.group==="general")).map(i=>(ji().f[13]++,ji().s[22]++,G.jsx("option",{value:i.id,disabled:i.disabled,"data-wd-key":i.id,children:i.title},i.id))),G.jsx("optgroup",{label:"Color accessibility",children:t.filter(i=>(ji().f[14]++,ji().s[23]++,i.group==="color-accessibility")).map(i=>(ji().f[15]++,ji().s[24]++,G.jsx("option",{value:i.id,disabled:i.disabled,children:i.title},i.id)))})]})]})]}),G.jsxs(EOe,{href:"https://github.com/maplibre/maputnik/wiki",children:[G.jsx(UJ,{}),G.jsx(Xv,{children:"Help"})]})]})]})})}}function f4(){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 f4=function(){return s},s}f4();class kOe extends Sn.Component{render(){return f4().f[0]++,f4().s[0]++,G.jsx("div",{className:"maputnik-scroll-container",children:this.props.children})}}function up(){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 up=function(){return s},s}up();class KG extends Sn.Component{getChildContext(){return up().f[0]++,up().s[1]++,{reactIconBase:{size:14}}}render(){return up().f[1]++,up().s[2]++,G.jsxs("div",{className:"maputnik-layout",children:[this.props.toolbar,G.jsx("div",{className:"maputnik-layout-list",children:this.props.layerList}),G.jsx("div",{className:"maputnik-layout-drawer",children:G.jsx(kOe,{children:this.props.layerEditor})}),this.props.map,(up().b[0][0]++,this.props.bottom&&(up().b[0][1]++,G.jsx("div",{className:"maputnik-layout-bottom",children:this.props.bottom}))),this.props.modals]})}}an(KG,"childContextTypes",(up().s[0]++,{reactIconBase:Rr.object}));function Ja(){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 Ja=function(){return s},s}Ja();class PG extends Sn.Component{render(){var i,o;Ja().f[1]++;const{selectedLayerIndex:n}=(Ja().s[1]++,this.props),t=(Ja().s[2]++,(i=this.props.errors)==null?void 0:i.map((s,a)=>{var g;Ja().f[2]++;let h;if(Ja().s[3]++,Ja().b[1][0]++,s.parsed&&(Ja().b[1][1]++,s.parsed.type==="layer")){Ja().b[0][0]++;const{parsed:C}=(Ja().s[4]++,s),B=(Ja().s[5]++,(g=this.props.mapStyle)==null?void 0:g.layers[C.data.index].id);Ja().s[6]++,h=G.jsxs(G.Fragment,{children:["Layer ",G.jsx("span",{children:IG(B)}),": ",C.data.message,(Ja().b[2][0]++,n!==C.data.index&&(Ja().b[2][1]++,G.jsxs(G.Fragment,{children:[" — ",G.jsx("button",{className:"maputnik-message-panel__switch-button",onClick:()=>(Ja().f[3]++,Ja().s[7]++,this.props.onLayerSelect(C.data.index)),children:"switch to layer"})]})))]})}else Ja().b[0][1]++,Ja().s[8]++,h=s.message;return Ja().s[9]++,G.jsx("p",{className:"maputnik-message-panel-error",children:h},"error-"+a)})),r=(Ja().s[10]++,(o=this.props.infos)==null?void 0:o.map((s,a)=>(Ja().f[4]++,Ja().s[11]++,G.jsx("p",{children:s},"info-"+a))));return Ja().s[12]++,G.jsxs("div",{className:"maputnik-message-panel",children:[t,r]})}}an(PG,"defaultProps",(Ja().s[0]++,{onLayerSelect:()=>{Ja().f[0]++}}));function p4(){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 p4=function(){return s},s}p4();class m4 extends Sn.Component{render(){return p4().f[0]++,p4().s[0]++,G.jsx(EC,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:G.jsx(bG,{...this.props})})}}function g4(){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 g4=function(){return s},s}g4();class Ap extends Sn.Component{render(){return g4().f[0]++,g4().s[0]++,G.jsx(ra,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:G.jsx(wf,{...this.props})})}}function y4(){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 y4=function(){return s},s}y4();class dm extends Sn.Component{render(){return y4().f[0]++,y4().s[0]++,G.jsx(ra,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:G.jsx(wd,{...this.props})})}}function v4(){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 v4=function(){return s},s}v4();class OC extends Sn.Component{render(){return v4().f[0]++,v4().s[0]++,G.jsx(ra,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:G.jsx(sk,{...this.props})})}}function _4(){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 _4=function(){return s},s}_4();class uk extends Sn.Component{render(){return _4().f[0]++,_4().s[0]++,G.jsx(ra,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:G.jsx(x1,{...this.props})})}}function C4(){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 C4=function(){return s},s}C4();class IOe extends Sn.Component{render(){return C4().f[0]++,C4().s[0]++,G.jsx(EC,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:G.jsx(ak,{...this.props})})}}function b4(){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 b4=function(){return s},s}b4();class TOe extends Sn.Component{render(){return b4().f[0]++,b4().s[0]++,G.jsx(ra,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:G.jsx(CG,{...this.props})})}}function Ak(){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 Ak=function(){return s},s}Ak();const nf=(Ak().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 si(){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 si=function(){return s},s}si();class KOe extends Sn.Component{changeTransitionProperty(n,t){si().f[0]++;const r=(si().s[0]++,{...this.props.mapStyle.transition});si().s[1]++,t===void 0?(si().b[0][0]++,si().s[2]++,delete r[n]):(si().b[0][1]++,si().s[3]++,r[n]=t),si().s[4]++,this.props.onStyleChanged({...this.props.mapStyle,transition:r})}changeLightProperty(n,t){si().f[1]++;const r=(si().s[5]++,{...this.props.mapStyle.light});si().s[6]++,t===void 0?(si().b[1][0]++,si().s[7]++,delete r[n]):(si().b[1][1]++,si().s[8]++,r[n]=t),si().s[9]++,this.props.onStyleChanged({...this.props.mapStyle,light:r})}changeTerrainProperty(n,t){si().f[2]++;const r=(si().s[10]++,{...this.props.mapStyle.terrain});si().s[11]++,t===void 0?(si().b[2][0]++,si().s[12]++,delete r[n]):(si().b[2][1]++,si().s[13]++,r[n]=t),si().s[14]++,this.props.onStyleChanged({...this.props.mapStyle,terrain:r})}changeStyleProperty(n,t){si().f[3]++;const r=(si().s[15]++,{...this.props.mapStyle});si().s[16]++,t===void 0?(si().b[3][0]++,si().s[17]++,delete r[n]):(si().b[3][1]++,si().s[18]++,r[n]=t),si().s[19]++,this.props.onStyleChanged(r)}render(){si().f[4]++;const n=(si().s[20]++,si().b[4][0]++,this.props.mapStyle.metadata||(si().b[4][1]++,{})),{onChangeMetadataProperty:t,mapStyle:r}=(si().s[21]++,this.props),i=(si().s[22]++,si().b[5][0]++,this.props.mapStyle.light||(si().b[5][1]++,{})),o=(si().s[23]++,si().b[6][0]++,this.props.mapStyle.transition||(si().b[6][1]++,{})),s=(si().s[24]++,si().b[7][0]++,this.props.mapStyle.terrain||(si().b[7][1]++,{}));return si().s[25]++,G.jsx(Of,{"data-wd-key":"modal:settings",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Style Settings",children:G.jsxs("div",{className:"modal:settings",children:[G.jsx(dm,{label:"Name",fieldSpec:no.$root.name,"data-wd-key":"modal:settings.name",value:this.props.mapStyle.name,onChange:this.changeStyleProperty.bind(this,"name")}),G.jsx(dm,{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")}),G.jsx(OC,{fieldSpec:no.$root.sprite,label:"Sprite URL","data-wd-key":"modal:settings.sprite",value:this.props.mapStyle.sprite,onChange:this.changeStyleProperty.bind(this,"sprite")}),G.jsx(OC,{label:"Glyphs URL",fieldSpec:no.$root.glyphs,"data-wd-key":"modal:settings.glyphs",value:this.props.mapStyle.glyphs,onChange:this.changeStyleProperty.bind(this,"glyphs")}),G.jsx(dm,{label:nf.maputnik.maptiler_access_token.label,fieldSpec:nf.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")}),G.jsx(dm,{label:nf.maputnik.thunderforest_access_token.label,fieldSpec:nf.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")}),G.jsx(m4,{label:"Center",fieldSpec:no.$root.center,length:2,type:"number",value:(si().b[8][0]++,r.center||(si().b[8][1]++,[])),default:[0,0],onChange:this.changeStyleProperty.bind(this,"center")}),G.jsx(Ap,{label:"Zoom",fieldSpec:no.$root.zoom,value:r.zoom,default:0,onChange:this.changeStyleProperty.bind(this,"zoom")}),G.jsx(Ap,{label:"Bearing",fieldSpec:no.$root.bearing,value:r.bearing,default:no.$root.bearing.default,onChange:this.changeStyleProperty.bind(this,"bearing")}),G.jsx(Ap,{label:"Pitch",fieldSpec:no.$root.pitch,value:r.pitch,default:no.$root.pitch.default,onChange:this.changeStyleProperty.bind(this,"pitch")}),G.jsx(IOe,{label:"Light anchor",fieldSpec:no.light.anchor,name:"light-anchor",value:i.anchor,options:Object.keys(no.light.anchor.values),default:no.light.anchor.default,onChange:this.changeLightProperty.bind(this,"anchor")}),G.jsx(TOe,{label:"Light color",fieldSpec:no.light.color,value:i.color,default:no.light.color.default,onChange:this.changeLightProperty.bind(this,"color")}),G.jsx(Ap,{label:"Light intensity",fieldSpec:no.light.intensity,value:i.intensity,default:no.light.intensity.default,onChange:this.changeLightProperty.bind(this,"intensity")}),G.jsx(m4,{label:"Light position",fieldSpec:no.light.position,type:"number",length:no.light.position.length,value:i.position,default:no.light.position.default,onChange:this.changeLightProperty.bind(this,"position")}),G.jsx(dm,{label:"Terrain source",fieldSpec:no.terrain.source,"data-wd-key":"modal:settings.maputnik:terrain_source",value:s.source,onChange:this.changeTerrainProperty.bind(this,"source")}),G.jsx(Ap,{label:"Terrain exaggeration",fieldSpec:no.terrain.exaggeration,value:s.exaggeration,default:no.terrain.exaggeration.default,onChange:this.changeTerrainProperty.bind(this,"exaggeration")}),G.jsx(Ap,{label:"Transition delay",fieldSpec:no.transition.delay,value:o.delay,default:no.transition.delay.default,onChange:this.changeTransitionProperty.bind(this,"delay")}),G.jsx(Ap,{label:"Transition duration",fieldSpec:no.transition.duration,value:o.duration,default:no.transition.duration.default,onChange:this.changeTransitionProperty.bind(this,"duration")}),G.jsx(uk,{label:nf.maputnik.style_renderer.label,fieldSpec:nf.maputnik.style_renderer,"data-wd-key":"modal:settings.maputnik:renderer",options:[["mlgljs","MapLibreGL JS"],["ol","Open Layers (experimental)"]],value:(si().b[9][0]++,n["maputnik:renderer"]||(si().b[9][1]++,"mlgljs")),onChange:t.bind(this,"maputnik:renderer")})]})})}}var FG={exports:{}};(function(e,n){(function(t,r,i){e.exports=i(),e.exports.default=i()})("slugify",ch,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]||{},h=s.replacement===void 0?"-":s.replacement,g=s.trim===void 0?!0:s.trim,C=o.normalize().split("").reduce(function(B,k){var P=a[k];return P===void 0&&(P=t[k]),P===void 0&&(P=k),P===h&&(P=" "),B+P.replace(s.remove||/[^\w\s$*_+~.()'"!\-:@]+/g,"")},"");return s.strict&&(C=C.replace(/[^A-Za-z0-9\s]/g,"")),g&&(C=C.trim()),C=C.replace(/\s+/g,h),s.lower&&(C=C.toLowerCase()),C}return i.extend=function(o){Object.assign(t,o)},i})})(FG);var POe=FG.exports;const FOe=fa(POe);var DG={exports:{}};(function(e,n){(function(t,r){r()})(ch,function(){function t(g,C){return typeof C>"u"?C={autoBom:!1}:typeof C!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),C={autoBom:!C}),C.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,C,B){var k=new XMLHttpRequest;k.open("GET",g),k.responseType="blob",k.onload=function(){h(k.response,C,B)},k.onerror=function(){console.error("could not download file")},k.send()}function i(g){var C=new XMLHttpRequest;C.open("HEAD",g,!1);try{C.send()}catch{}return 200<=C.status&&299>=C.status}function o(g){try{g.dispatchEvent(new MouseEvent("click"))}catch{var C=document.createEvent("MouseEvents");C.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),g.dispatchEvent(C)}}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),h=s.saveAs||(typeof window!="object"||window!==s?function(){}:"download"in HTMLAnchorElement.prototype&&!a?function(g,C,B){var k=s.URL||s.webkitURL,P=document.createElement("a");C=C||g.name||"download",P.download=C,P.rel="noopener",typeof g=="string"?(P.href=g,P.origin===location.origin?o(P):i(P.href)?r(g,C,B):o(P,P.target="_blank")):(P.href=k.createObjectURL(g),setTimeout(function(){k.revokeObjectURL(P.href)},4e4),setTimeout(function(){o(P)},0))}:"msSaveOrOpenBlob"in navigator?function(g,C,B){if(C=C||g.name||"download",typeof g!="string")navigator.msSaveOrOpenBlob(t(g,B),C);else if(i(g))r(g,C,B);else{var k=document.createElement("a");k.href=g,k.target="_blank",setTimeout(function(){o(k)})}}:function(g,C,B,k){if(k=k||open("","_blank"),k&&(k.document.title=k.document.body.innerText="downloading..."),typeof g=="string")return r(g,C,B);var P=g.type==="application/octet-stream",L=/constructor/i.test(s.HTMLElement)||s.safari,J=/CriOS\/[\d]+/.test(navigator.userAgent);if((J||P&&L||a)&&typeof FileReader<"u"){var N=new FileReader;N.onloadend=function(){var oe=N.result;oe=J?oe:oe.replace(/^data:[^;]*;/,"data:attachment/file;"),k?k.location.href=oe:location=oe,k=null},N.readAsDataURL(g)}else{var $=s.URL||s.webkitURL,q=$.createObjectURL(g);k?k.location=q:location.href=q,k=null,setTimeout(function(){$.revokeObjectURL(q)},4e4)}});s.saveAs=h.saveAs=h,e.exports=h})})(DG);var NP=DG.exports;const DOe="4.0.0",LOe="get_your_own_OpIi9ZULNHzrESv6T2vL",UOe="b71f7f0ba4064f5eb9e903859a9cf5c6",LG={openmaptiles:LOe,thunderforest:UOe};function jn(){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 jn=function(){return s},s}jn();const ROe=(jn().s[0]++,RG({version:8,sources:{},layers:[]}));function UG(){return jn().f[0]++,jn().s[1]++,Math.random().toString(36).substring(2,9)}function zOe(e){return jn().f[1]++,jn().s[2]++,jn().b[1][0]++,!("id"in e)||(jn().b[1][1]++,!e.id)?(jn().b[0][0]++,jn().s[3]++,e.id=UG(),jn().s[4]++,e):(jn().b[0][1]++,jn().s[5]++,e)}function jOe(e){jn().f[2]++;const n=(jn().s[6]++,e.layers.map(t=>{jn().f[3]++;const r=(jn().s[7]++,{...t});return jn().s[8]++,delete r.interactive,jn().s[9]++,r}));return jn().s[10]++,{...e,layers:n}}function WOe(e){return jn().f[4]++,jn().s[11]++,{...e,layers:fZ(e.layers)}}function RG(e){return jn().f[5]++,jn().s[12]++,jOe(WOe(zOe(e)))}function NOe(e,n){jn().f[6]++,jn().s[13]++;for(let t=(jn().s[14]++,0);t<e.length;t++){if(jn().s[15]++,e[t].id===n)return jn().b[2][0]++,jn().s[16]++,t;jn().b[2][1]++}return jn().s[17]++,null}function ck(e,n,t){jn().f[7]++,jn().s[18]++,jn().b[4][0]++,e==="thunderforest_transport"||(jn().b[4][1]++,e==="thunderforest_outdoors")?(jn().b[3][0]++,jn().s[19]++,e="thunderforest"):jn().b[3][1]++;const r=(jn().s[20]++,jn().b[5][0]++,n.metadata||(jn().b[5][1]++,{}));let i=(jn().s[21]++,r[`maputnik:${e}_access_token`]);return jn().s[22]++,jn().b[7][0]++,t.allowFallback&&(jn().b[7][1]++,!i)?(jn().b[6][0]++,jn().s[23]++,i=LG[e]):jn().b[6][1]++,jn().s[24]++,i}function GOe(e,n,t=(jn().b[8][0]++,{})){jn().f[8]++;const r=(jn().s[25]++,e.sources[n]);if(jn().s[26]++,r)jn().b[9][1]++;else return jn().b[9][0]++,jn().s[27]++,e;if(jn().s[28]++,jn().b[11][0]++,!("url"in r)||(jn().b[11][1]++,!r.url))return jn().b[10][0]++,jn().s[29]++,e;jn().b[10][1]++;const i=(jn().s[30]++,ck(n,e,t));if(jn().s[31]++,i)jn().b[12][1]++;else return jn().b[12][0]++,jn().s[32]++,e;const o=(jn().s[33]++,{...e.sources,[n]:{...r,url:r.url.replace("{key}",i)}}),s=(jn().s[34]++,{...e,sources:o});return jn().s[35]++,s}function QOe(e,n=(jn().b[13][0]++,{})){jn().f[9]++;let t=(jn().s[36]++,e);if(jn().s[37]++,Object.keys(e.sources).forEach(r=>{jn().f[10]++,jn().s[38]++,t=GOe(t,r,n)}),jn().s[39]++,jn().b[15][0]++,e.glyphs&&(jn().b[15][1]++,e.glyphs.match(/\.tilehosting\.com/)||(jn().b[15][2]++,e.glyphs.match(/\.maptiler\.com/)))){jn().b[14][0]++;const r=(jn().s[40]++,ck("openmaptiles",e,n));jn().s[41]++,r?(jn().b[16][0]++,jn().s[42]++,t={...t,glyphs:e.glyphs.replace("{key}",r)}):jn().b[16][1]++}else jn().b[14][1]++;return jn().s[43]++,t}function $Oe(e){jn().f[11]++;const n=(jn().s[44]++,{...e.metadata});return jn().s[45]++,delete n["maputnik:openmaptiles_access_token"],jn().s[46]++,{...e,metadata:n}}const Iu={ensureStyleValidity:RG,emptyStyle:ROe,indexOfLayer:NOe,generateId:UG,getAccessToken:ck,replaceAccessTokens:QOe,stripAccessTokens:$Oe};function Ro(){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 Ro=function(){return s},s}Ro();const GP=(Ro().s[0]++,DOe);class YOe extends Sn.Component{tokenizedStyle(){return Ro().f[0]++,Ro().s[1]++,sR(Iu.stripAccessTokens(Iu.replaceAccessTokens(this.props.mapStyle)))}exportName(){return Ro().f[1]++,Ro().s[2]++,this.props.mapStyle.name?(Ro().b[0][0]++,Ro().s[3]++,FOe(this.props.mapStyle.name,{replacement:"_",remove:/[*\-+~.()'"!:]/g,lower:!0})):(Ro().b[0][1]++,Ro().s[4]++,this.props.mapStyle.id)}downloadHtml(){Ro().f[2]++;const n=(Ro().s[5]++,this.tokenizedStyle()),t=(Ro().s[6]++,Ro().b[1][0]++,this.props.mapStyle.name||(Ro().b[1][1]++,"Map")),r=(Ro().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@${GP}/dist/maplibre-gl.js"><\/script>
<link href="https://unpkg.com/maplibre-gl@${GP}/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=(Ro().s[8]++,new Blob([r],{type:"text/html;charset=utf-8"})),o=(Ro().s[9]++,this.exportName());Ro().s[10]++,NP.saveAs(i,o+".html")}downloadStyle(){Ro().f[3]++;const n=(Ro().s[11]++,this.tokenizedStyle()),t=(Ro().s[12]++,new Blob([n],{type:"application/json;charset=utf-8"})),r=(Ro().s[13]++,this.exportName());Ro().s[14]++,NP.saveAs(t,r+".json")}changeMetadataProperty(n,t){Ro().f[4]++;const r=(Ro().s[15]++,{...this.props.mapStyle,metadata:{...this.props.mapStyle.metadata,[n]:t}});Ro().s[16]++,this.props.onStyleChanged(r)}render(){return Ro().f[5]++,Ro().s[17]++,G.jsx(Of,{"data-wd-key":"modal:export",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Export Style",className:"maputnik-export-modal",children:G.jsxs("section",{className:"maputnik-modal-section",children:[G.jsx("h1",{children:"Download Style"}),G.jsx("p",{children:"Download a JSON style to your computer."}),G.jsxs("div",{children:[G.jsx(dm,{label:nf.maputnik.maptiler_access_token.label,fieldSpec:nf.maputnik.maptiler_access_token,value:(Ro().b[2][0]++,this.props.mapStyle.metadata||(Ro().b[2][1]++,{}))["maputnik:openmaptiles_access_token"],onChange:this.changeMetadataProperty.bind(this,"maputnik:openmaptiles_access_token")}),G.jsx(dm,{label:nf.maputnik.thunderforest_access_token.label,fieldSpec:nf.maputnik.thunderforest_access_token,value:(Ro().b[3][0]++,this.props.mapStyle.metadata||(Ro().b[3][1]++,{}))["maputnik:thunderforest_access_token"],onChange:this.changeMetadataProperty.bind(this,"maputnik:thunderforest_access_token")})]}),G.jsxs("div",{className:"maputnik-modal-export-buttons",children:[G.jsxs(ja,{onClick:this.downloadStyle.bind(this),children:[G.jsx(z6,{}),"Download Style"]}),G.jsxs(ja,{onClick:this.downloadHtml.bind(this),children:[G.jsx(z6,{}),"Download HTML"]})]})]})})}}function x4(){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 x4=function(){return s},s}x4();class zG extends Sn.Component{render(){return x4().f[0]++,x4().s[0]++,G.jsx(EC,{label:this.props.label,children:G.jsx(xG,{...this.props})})}}function w4(){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 w4=function(){return s},s}w4();class qOe extends Sn.Component{render(){return w4().f[0]++,w4().s[0]++,G.jsx(ra,{label:this.props.label,children:G.jsx(ok,{...this.props})})}}function Vn(){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 Vn=function(){return s},s}Vn();class fS extends Sn.Component{render(){return Vn().f[0]++,Vn().s[0]++,G.jsxs("div",{children:[G.jsx(OC,{label:"TileJSON URL",fieldSpec:Ea.source_vector.url,value:this.props.source.url,onChange:n=>(Vn().f[1]++,Vn().s[1]++,this.props.onChange({...this.props.source,url:n}))}),this.props.children]})}}class pS extends Sn.Component{changeTileUrls(n){Vn().f[2]++,Vn().s[2]++,this.props.onChange({...this.props.source,tiles:n})}renderTileUrls(){Vn().f[3]++;const n=(Vn().s[3]++,Vn().b[0][0]++,this.props.source.tiles||(Vn().b[0][1]++,[]));return Vn().s[4]++,G.jsx(zG,{label:"Tile URL",fieldSpec:Ea.source_vector.tiles,type:"url",value:n,onChange:this.changeTileUrls.bind(this)})}render(){return Vn().f[4]++,Vn().s[5]++,G.jsxs("div",{children:[this.renderTileUrls(),G.jsx(Ap,{label:"Min Zoom",fieldSpec:Ea.source_vector.minzoom,value:(Vn().b[1][0]++,this.props.source.minzoom||(Vn().b[1][1]++,0)),onChange:n=>(Vn().f[5]++,Vn().s[6]++,this.props.onChange({...this.props.source,minzoom:n}))}),G.jsx(Ap,{label:"Max Zoom",fieldSpec:Ea.source_vector.maxzoom,value:(Vn().b[2][0]++,this.props.source.maxzoom||(Vn().b[2][1]++,22)),onChange:n=>(Vn().f[6]++,Vn().s[7]++,this.props.onChange({...this.props.source,maxzoom:n}))}),this.props.children]})}}class HOe extends Sn.Component{render(){Vn().f[7]++,Vn().s[8]++;const n=(t,r)=>{Vn().f[8]++;const i=(Vn().s[9]++,this.props.source.coordinates.slice(0));Vn().s[10]++,i[t]=r,Vn().s[11]++,this.props.onChange({...this.props.source,coordinates:i})};return Vn().s[12]++,G.jsxs("div",{children:[G.jsx(OC,{label:"Image URL",fieldSpec:Ea.source_image.url,value:this.props.source.url,onChange:t=>(Vn().f[9]++,Vn().s[13]++,this.props.onChange({...this.props.source,url:t}))}),["top left","top right","bottom right","bottom left"].map((t,r)=>(Vn().f[10]++,Vn().s[14]++,G.jsx(m4,{label:`Coord ${t}`,length:2,type:"number",value:this.props.source.coordinates[r],default:[0,0],onChange:i=>(Vn().f[11]++,Vn().s[15]++,n(r,i))},t)))]})}}class VOe extends Sn.Component{render(){Vn().f[12]++,Vn().s[16]++;const n=(r,i)=>{Vn().f[13]++;const o=(Vn().s[17]++,this.props.source.coordinates.slice(0));Vn().s[18]++,o[r]=i,Vn().s[19]++,this.props.onChange({...this.props.source,coordinates:o})};Vn().s[20]++;const t=r=>{Vn().f[14]++,Vn().s[21]++,this.props.onChange({...this.props.source,urls:r})};return Vn().s[22]++,G.jsxs("div",{children:[G.jsx(zG,{label:"Video URL",fieldSpec:Ea.source_video.urls,type:"string",value:this.props.source.urls,default:[],onChange:t}),["top left","top right","bottom right","bottom left"].map((r,i)=>(Vn().f[15]++,Vn().s[23]++,G.jsx(m4,{label:`Coord ${r}`,length:2,type:"number",value:this.props.source.coordinates[i],default:[0,0],onChange:o=>(Vn().f[16]++,Vn().s[24]++,n(i,o))},r)))]})}}class ZOe extends Sn.Component{render(){return Vn().f[17]++,Vn().s[25]++,G.jsx(OC,{label:"GeoJSON URL",fieldSpec:Ea.source_geojson.data,value:this.props.source.data,onChange:n=>(Vn().f[18]++,Vn().s[26]++,this.props.onChange({...this.props.source,data:n}))})}}class XOe extends Sn.Component{render(){return Vn().f[19]++,Vn().s[27]++,G.jsxs("div",{children:[G.jsx(ra,{label:"GeoJSON",fieldSpec:Ea.source_geojson.data,children:G.jsx(M8,{layer:this.props.source.data,maxHeight:200,mode:{name:"javascript",json:!0},lint:!0,onChange:n=>{Vn().f[20]++,Vn().s[28]++,this.props.onChange({...this.props.source,data:n})}})}),G.jsx(qOe,{label:"Cluster",value:this.props.source.cluster,onChange:n=>{Vn().f[21]++,Vn().s[29]++,this.props.onChange({...this.props.source,cluster:n})}})]})}}class jG extends Sn.Component{render(){Vn().f[22]++;const n=(Vn().s[30]++,{source:this.props.source,onChange:this.props.onChange});switch(Vn().s[31]++,this.props.mode){case"geojson_url":return Vn().b[3][0]++,Vn().s[32]++,G.jsx(ZOe,{...n});case"geojson_json":return Vn().b[3][1]++,Vn().s[33]++,G.jsx(XOe,{...n});case"tilejson_vector":return Vn().b[3][2]++,Vn().s[34]++,G.jsx(fS,{...n});case"tilexyz_vector":return Vn().b[3][3]++,Vn().s[35]++,G.jsx(pS,{...n});case"tilejson_raster":return Vn().b[3][4]++,Vn().s[36]++,G.jsx(fS,{...n});case"tilexyz_raster":return Vn().b[3][5]++,Vn().s[37]++,G.jsx(pS,{...n});case"tilejson_raster-dem":return Vn().b[3][6]++,Vn().s[38]++,G.jsx(fS,{...n});case"tilexyz_raster-dem":return Vn().b[3][7]++,Vn().s[39]++,G.jsx(pS,{...n,children:G.jsx(uk,{label:"Encoding",fieldSpec:Ea.source_raster_dem.encoding,options:Object.keys(Ea.source_raster_dem.encoding.values),onChange:t=>(Vn().f[23]++,Vn().s[40]++,this.props.onChange({...this.props.source,encoding:t})),value:(Vn().b[4][0]++,this.props.source.encoding||(Vn().b[4][1]++,Ea.source_raster_dem.encoding.default))})});case"image":return Vn().b[3][8]++,Vn().s[41]++,G.jsx(HOe,{...n});case"video":return Vn().b[3][9]++,Vn().s[42]++,G.jsx(VOe,{...n});default:return Vn().b[3][10]++,Vn().s[43]++,null}}}function sh(){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 sh=function(){return s},s}sh();function JOe(e,n){sh().f[0]++;const t=(sh().s[0]++,{...e.sources});return sh().s[1]++,delete t[n],sh().s[2]++,{...e,sources:t}}function QP(e,n,t){return sh().f[1]++,sh().s[3]++,WG(e,n,t)}function WG(e,n,t){sh().f[2]++;const r=(sh().s[4]++,{...e.sources,[n]:t});return sh().s[5]++,{...e,sources:r}}const eBe={type:"vector",url:"https://api.maptiler.com/tiles/v3/tiles.json?key={key}",title:"OpenMapTiles v3"},tBe={type:"vector",url:"https://tile.thunderforest.com/thunderforest.transport-v2.json?apikey={key}",title:"Thunderforest Transport v2"},nBe={type:"vector",url:"https://tile.thunderforest.com/thunderforest.outdoors-v2.json?apikey={key}",title:"Thunderforest Outdoors v2"},rBe={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"},$P={openmaptiles:eBe,thunderforest_transport:tBe,thunderforest_outdoors:nBe,open_zoomstack:rBe};function Zt(){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 Zt=function(){return s},s}Zt();class iBe extends Sn.Component{render(){return Zt().f[0]++,Zt().s[0]++,G.jsx("div",{className:"maputnik-public-source",children:G.jsxs(ja,{className:"maputnik-public-source-select",onClick:()=>(Zt().f[1]++,Zt().s[1]++,this.props.onSelect(this.props.id)),children:[G.jsxs("div",{className:"maputnik-public-source-info",children:[G.jsx("p",{className:"maputnik-public-source-name",children:this.props.title}),G.jsxs("p",{className:"maputnik-public-source-id",children:["#",this.props.id]})]}),G.jsx("span",{className:"maputnik-space"}),G.jsx(pR,{})]})})}}function oBe(e){return Zt().f[2]++,Zt().s[2]++,e.type==="raster"?(Zt().b[0][0]++,Zt().s[3]++,e.tiles?(Zt().b[1][0]++,Zt().s[4]++,"tilexyz_raster"):(Zt().b[1][1]++,Zt().s[5]++,"tilejson_raster")):(Zt().b[0][1]++,Zt().s[6]++,e.type==="raster-dem"?(Zt().b[2][0]++,Zt().s[7]++,e.tiles?(Zt().b[3][0]++,Zt().s[8]++,"tilexyz_raster-dem"):(Zt().b[3][1]++,Zt().s[9]++,"tilejson_raster-dem")):(Zt().b[2][1]++,Zt().s[10]++,e.type==="vector"?(Zt().b[4][0]++,Zt().s[11]++,e.tiles?(Zt().b[5][0]++,Zt().s[12]++,"tilexyz_vector"):(Zt().b[5][1]++,Zt().s[13]++,"tilejson_vector")):(Zt().b[4][1]++,Zt().s[14]++,e.type==="geojson"?(Zt().b[6][0]++,Zt().s[15]++,typeof e.data=="string"?(Zt().b[7][0]++,Zt().s[16]++,"geojson_url"):(Zt().b[7][1]++,Zt().s[17]++,"geojson_json")):(Zt().b[6][1]++,Zt().s[18]++,e.type==="image"?(Zt().b[8][0]++,Zt().s[19]++,"image"):(Zt().b[8][1]++,Zt().s[20]++,e.type==="video"?(Zt().b[9][0]++,Zt().s[21]++,"video"):(Zt().b[9][1]++,Zt().s[22]++,null))))))}class aBe extends Sn.Component{render(){return Zt().f[3]++,Zt().s[23]++,G.jsxs("div",{className:"maputnik-active-source-type-editor",children:[G.jsxs("div",{className:"maputnik-active-source-type-editor-header",children:[G.jsxs("span",{className:"maputnik-active-source-type-editor-header-id",children:["#",this.props.sourceId]}),G.jsx("span",{className:"maputnik-space"}),G.jsx(ja,{"aria-label":`Remove '${this.props.sourceId}' source`,className:"maputnik-active-source-type-editor-header-delete",onClick:()=>(Zt().f[4]++,Zt().s[24]++,this.props.onDelete(this.props.sourceId)),style:{backgroundColor:"transparent"},children:G.jsx(Ny,{})})]}),G.jsx("div",{className:"maputnik-active-source-type-editor-content",children:G.jsx(jG,{onChange:this.props.onChange,mode:oBe(this.props.source),source:this.props.source})})]})}}class sBe extends Sn.Component{constructor(t){Zt().f[5]++,Zt().s[25]++;super(t);an(this,"onAdd",(Zt().s[41]++,()=>{Zt().f[7]++;const{source:t,sourceId:r}=(Zt().s[42]++,this.state);Zt().s[43]++,this.props.onAdd(r,t)}));an(this,"onChangeSource",(Zt().s[44]++,t=>{Zt().f[8]++,Zt().s[45]++,this.setState({source:t})}));Zt().s[26]++,this.state={mode:"tilejson_vector",sourceId:Iu.generateId(),source:this.defaultSource("tilejson_vector")}}defaultSource(t){Zt().f[6]++;const r=(Zt().s[27]++,Zt().b[10][0]++,(Zt().b[11][0]++,this.state||(Zt().b[11][1]++,{})).source||(Zt().b[10][1]++,{})),{protocol:i}=(Zt().s[28]++,window.location);switch(Zt().s[29]++,t){case"geojson_url":return Zt().b[12][0]++,Zt().s[30]++,{type:"geojson",data:`${i}//localhost:3000/geojson.json`};case"geojson_json":return Zt().b[12][1]++,Zt().s[31]++,{type:"geojson",cluster:(Zt().b[13][0]++,r.cluster||(Zt().b[13][1]++,!1)),data:""};case"tilejson_vector":return Zt().b[12][2]++,Zt().s[32]++,{type:"vector",url:(Zt().b[14][0]++,r.url||(Zt().b[14][1]++,`${i}//localhost:3000/tilejson.json`))};case"tilexyz_vector":return Zt().b[12][3]++,Zt().s[33]++,{type:"vector",tiles:(Zt().b[15][0]++,r.tiles||(Zt().b[15][1]++,[`${i}//localhost:3000/{x}/{y}/{z}.pbf`])),minzoom:(Zt().b[16][0]++,r.minzoom||(Zt().b[16][1]++,0)),maxzoom:(Zt().b[17][0]++,r.maxzoom||(Zt().b[17][1]++,14))};case"tilejson_raster":return Zt().b[12][4]++,Zt().s[34]++,{type:"raster",url:(Zt().b[18][0]++,r.url||(Zt().b[18][1]++,`${i}//localhost:3000/tilejson.json`))};case"tilexyz_raster":return Zt().b[12][5]++,Zt().s[35]++,{type:"raster",tiles:(Zt().b[19][0]++,r.tiles||(Zt().b[19][1]++,[`${i}//localhost:3000/{x}/{y}/{z}.pbf`])),minzoom:(Zt().b[20][0]++,r.minzoom||(Zt().b[20][1]++,0)),maxzoom:(Zt().b[21][0]++,r.maxzoom||(Zt().b[21][1]++,14))};case"tilejson_raster-dem":return Zt().b[12][6]++,Zt().s[36]++,{type:"raster-dem",url:(Zt().b[22][0]++,r.url||(Zt().b[22][1]++,`${i}//localhost:3000/tilejson.json`))};case"tilexyz_raster-dem":return Zt().b[12][7]++,Zt().s[37]++,{type:"raster-dem",tiles:(Zt().b[23][0]++,r.tiles||(Zt().b[23][1]++,[`${i}//localhost:3000/{x}/{y}/{z}.pbf`])),minzoom:(Zt().b[24][0]++,r.minzoom||(Zt().b[24][1]++,0)),maxzoom:(Zt().b[25][0]++,r.maxzoom||(Zt().b[25][1]++,14))};case"image":return Zt().b[12][8]++,Zt().s[38]++,{type:"image",url:`${i}//localhost:3000/image.png`,coordinates:[[0,0],[0,0],[0,0],[0,0]]};case"video":return Zt().b[12][9]++,Zt().s[39]++,{type:"video",urls:[`${i}//localhost:3000/movie.mp4`],coordinates:[[0,0],[0,0],[0,0],[0,0]]};default:return Zt().b[12][10]++,Zt().s[40]++,{}}}render(){Zt().f[9]++;const t=(Zt().s[46]++,{doc:no.source_vector.type.doc});return Zt().s[47]++,G.jsxs("div",{className:"maputnik-add-source",children:[G.jsx(dm,{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=>(Zt().f[10]++,Zt().s[48]++,this.setState({sourceId:r}))}),G.jsx(uk,{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=>(Zt().f[11]++,Zt().s[49]++,this.setState({mode:r,source:this.defaultSource(r)})),value:this.state.mode}),G.jsx(jG,{onChange:this.onChangeSource,mode:this.state.mode,source:this.state.source}),G.jsx(ja,{className:"maputnik-add-source-button",onClick:this.onAdd,children:"Add Source"})]})}}class lBe extends Sn.Component{stripTitle(n){Zt().f[12]++;const t=(Zt().s[50]++,{...n});return Zt().s[51]++,delete t.title,Zt().s[52]++,t}render(){Zt().f[13]++;const n=(Zt().s[53]++,this.props.mapStyle),t=(Zt().s[54]++,Object.keys(n.sources).map(i=>{Zt().f[14]++;const o=(Zt().s[55]++,n.sources[i]);return Zt().s[56]++,G.jsx(aBe,{sourceId:i,source:o,onChange:s=>(Zt().f[15]++,Zt().s[57]++,this.props.onStyleChanged(WG(n,i,s))),onDelete:()=>(Zt().f[16]++,Zt().s[58]++,this.props.onStyleChanged(JOe(n,i)))},i)})),r=(Zt().s[59]++,Object.keys($P).filter(i=>(Zt().f[17]++,Zt().s[60]++,!(i in n.sources))).map(i=>{Zt().f[18]++;const o=(Zt().s[61]++,$P[i]);return Zt().s[62]++,G.jsx(iBe,{id:i,type:o.type,title:o.title,onSelect:()=>(Zt().f[19]++,Zt().s[63]++,this.props.onStyleChanged(QP(n,i,this.stripTitle(o))))},i)}));return Zt().s[64]++,G.jsxs(Of,{"data-wd-key":"modal:sources",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Sources",children:[G.jsxs("section",{className:"maputnik-modal-section",children:[G.jsx("h1",{children:"Active Sources"}),t]}),G.jsxs("section",{className:"maputnik-modal-section",children:[G.jsx("h1",{children:"Choose Public Source"}),G.jsx("p",{children:"Add one of the publicly available sources to your style."}),G.jsx("div",{className:"maputnik-public-sources",style:{maxWidth:500},children:r})]}),G.jsxs("section",{className:"maputnik-modal-section",children:[G.jsx("h1",{children:"Add New Source"}),G.jsx("p",{children:"Add a new source to your style. You can only choose the source type and id at creation time!"}),G.jsx(sBe,{onAdd:(i,o)=>(Zt().f[20]++,Zt().s[65]++,this.props.onStyleChanged(QP(n,i,o)))})]})]})}}var NG={};Object.defineProperty(NG,"__esModule",{value:!0});var uBe=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},ABe=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},cBe=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}}(),dBe=Br,mS=mBe(dBe),hBe=Qm,fBe=pBe(hBe);function pBe(e){return e&&e.__esModule?e:{default:e}}function mBe(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 gBe(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 yBe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function vBe(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 _Be(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 CBe=function(e){_Be(n,e);function n(t){yBe(this,n);var r=vBe(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(h){return new Promise(function(g,C){var B=new FileReader;switch(B.onload=function(k){g([k,h])},a){case"binary":{B.readAsBinaryString(h);break}case"buffer":{B.readAsArrayBuffer(h);break}case"text":{B.readAsText(h);break}case"url":{B.readAsDataURL(h);break}}})})).then(function(h){r.props.onChange(o,h)})},r.triggerInput=function(){var o=fBe.default.findDOMNode(r._reactFileReaderInput);o&&o.click()};var i=(typeof window>"u"?"undefined":ABe(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 cBe(n,[{key:"render",value:function(){var r=this,i=this.props;i.as;var o=i.children,s=i.style,a=gBe(i,["as","children","style"]),h=o?{position:"absolute",top:"-9999px"}:{};return mS.createElement("div",{className:"_react-file-reader-input",onClick:this.triggerInput,style:s},mS.createElement("input",uBe({},a,{type:"file",ref:function(C){r._reactFileReaderInput=C},onChange:this.handleChange,onClick:function(){r._reactFileReaderInput.value=null},style:h})),o)}}]),n}(mS.Component),bBe=NG.default=CBe;function dd(){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 dd=function(){return s},s}dd();class xBe extends Sn.Component{underlayOnClick(n){dd().f[0]++,dd().s[0]++,n.stopPropagation()}render(){return dd().f[1]++,dd().s[1]++,G.jsxs(Of,{"data-wd-key":"modal:loading",isOpen:this.props.isOpen,underlayClickExits:!1,underlayProps:{onClick:n=>(dd().f[2]++,dd().s[2]++,underlayProps(n))},title:this.props.title,onOpenToggle:()=>(dd().f[3]++,dd().s[3]++,this.props.onCancel()),children:[G.jsx("p",{children:this.props.message}),G.jsx("p",{className:"maputnik-dialog__buttons",children:G.jsx(ja,{onClick:n=>(dd().f[4]++,dd().s[4]++,this.props.onCancel(n)),children:"Cancel"})})]})}}const GG=[{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 Hn(){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 Hn=function(){return s},s}Hn();class wBe extends Sn.Component{render(){return Hn().f[0]++,Hn().s[0]++,G.jsx("div",{className:"maputnik-public-style",children:G.jsxs(ja,{className:"maputnik-public-style-button","aria-label":this.props.title,onClick:()=>(Hn().f[1]++,Hn().s[1]++,this.props.onSelect(this.props.url)),children:[G.jsxs("div",{className:"maputnik-public-style-header",children:[G.jsx("div",{children:this.props.title}),G.jsx("span",{className:"maputnik-space"}),G.jsx(pR,{})]}),G.jsx("div",{className:"maputnik-public-style-thumbnail",style:{backgroundImage:`url(${this.props.thumbnailUrl})`}})]})})}}class MBe extends Sn.Component{constructor(t){Hn().f[2]++,Hn().s[2]++;super(t);an(this,"onStyleSelect",(Hn().s[10]++,t=>{Hn().f[5]++,Hn().s[11]++,this.clearError();let r=(Hn().s[12]++,!1);Hn().s[13]++,fetch(t,{mode:"cors",credentials:"same-origin"}).then(function(i){return Hn().f[6]++,Hn().s[14]++,i.json()}).then(i=>{if(Hn().f[7]++,Hn().s[15]++,r){Hn().b[2][0]++,Hn().s[16]++;return}else Hn().b[2][1]++;Hn().s[17]++,this.setState({activeRequest:null,activeRequestUrl:null});const o=(Hn().s[18]++,Iu.ensureStyleValidity(i));Hn().s[19]++,console.log("Loaded style ",o.id),Hn().s[20]++,this.props.onStyleOpen(o),Hn().s[21]++,this.onOpenToggle()}).catch(i=>{Hn().f[8]++,Hn().s[22]++,this.setState({error:`Failed to load: '${t}'`,activeRequest:null,activeRequestUrl:null}),Hn().s[23]++,console.error(i),Hn().s[24]++,console.warn("Could not open the style URL",t)}),Hn().s[25]++,this.setState({activeRequest:{abort:function(){Hn().f[9]++,Hn().s[26]++,r=!0}},activeRequestUrl:t})}));an(this,"onSubmitUrl",(Hn().s[27]++,t=>{Hn().f[10]++,Hn().s[28]++,t.preventDefault(),Hn().s[29]++,this.onStyleSelect(this.state.styleUrl)}));an(this,"onUpload",(Hn().s[30]++,(t,r)=>{Hn().f[11]++;const[,i]=(Hn().s[31]++,r[0]),o=(Hn().s[32]++,new FileReader);Hn().s[33]++,this.clearError(),Hn().s[34]++,o.readAsText(i,"UTF-8"),Hn().s[35]++,o.onload=s=>{var h;Hn().f[12]++;let a;Hn().s[36]++;try{Hn().s[37]++,a=JSON.parse((h=s.target)==null?void 0:h.result)}catch(g){Hn().s[38]++,this.setState({error:g.toString()}),Hn().s[39]++;return}Hn().s[40]++,a=Iu.ensureStyleValidity(a),Hn().s[41]++,this.props.onStyleOpen(a),Hn().s[42]++,this.onOpenToggle()},Hn().s[43]++,o.onerror=s=>(Hn().f[13]++,Hn().s[44]++,console.log(s.target))}));an(this,"onChangeUrl",(Hn().s[48]++,t=>{Hn().f[15]++,Hn().s[49]++,this.setState({styleUrl:t})}));Hn().s[3]++,this.state={styleUrl:""}}clearError(){Hn().f[3]++,Hn().s[4]++,this.setState({error:null})}onCancelActiveRequest(t){Hn().f[4]++,Hn().s[5]++,t?(Hn().b[0][0]++,Hn().s[6]++,t.stopPropagation()):Hn().b[0][1]++,Hn().s[7]++,this.state.activeRequest?(Hn().b[1][0]++,Hn().s[8]++,this.state.activeRequest.abort(),Hn().s[9]++,this.setState({activeRequest:null,activeRequestUrl:null})):Hn().b[1][1]++}onOpenToggle(){Hn().f[14]++,Hn().s[45]++,this.setState({styleUrl:""}),Hn().s[46]++,this.clearError(),Hn().s[47]++,this.props.onOpenToggle()}render(){Hn().f[16]++;const t=(Hn().s[50]++,GG.map(i=>(Hn().f[17]++,Hn().s[51]++,G.jsx(wBe,{url:i.url,title:i.title,thumbnailUrl:i.thumbnail,onSelect:this.onStyleSelect},i.id))));let r;return Hn().s[52]++,this.state.error?(Hn().b[3][0]++,Hn().s[53]++,r=G.jsxs("div",{className:"maputnik-modal-error",children:[this.state.error,G.jsx("a",{href:"#",onClick:()=>(Hn().f[18]++,Hn().s[54]++,this.clearError()),className:"maputnik-modal-error-close",children:"×"})]})):Hn().b[3][1]++,Hn().s[55]++,G.jsxs("div",{children:[G.jsxs(Of,{"data-wd-key":"modal:open",isOpen:this.props.isOpen,onOpenToggle:()=>(Hn().f[19]++,Hn().s[56]++,this.onOpenToggle()),title:"Open Style",children:[r,G.jsxs("section",{className:"maputnik-modal-section",children:[G.jsx("h1",{children:"Upload Style"}),G.jsx("p",{children:"Upload a JSON style from your computer."}),G.jsx(bBe,{onChange:this.onUpload,tabIndex:-1,"aria-label":"Style file",children:G.jsxs(ja,{className:"maputnik-upload-button",children:[G.jsx(HJ,{})," Upload"]})})]}),G.jsx("section",{className:"maputnik-modal-section",children:G.jsxs("form",{onSubmit:this.onSubmitUrl,children:[G.jsx("h1",{children:"Load from URL"}),G.jsxs("p",{children:["Load from a URL. Note that the URL must have ",G.jsx("a",{href:"https://enable-cors.org",target:"_blank",rel:"noopener noreferrer",children:"CORS enabled"}),"."]}),G.jsx(sk,{"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}),G.jsx("div",{children:G.jsx(ja,{"data-wd-key":"modal:open.url.button",type:"submit",className:"maputnik-big-button",disabled:this.state.styleUrl.length<1,children:"Load from URL"})})]})}),G.jsxs("section",{className:"maputnik-modal-section maputnik-modal-section--shrink",children:[G.jsx("h1",{children:"Gallery Styles"}),G.jsx("p",{children:"Open one of the publicly available styles to start from."}),G.jsx("div",{className:"maputnik-style-gallery-container",children:t})]})]}),G.jsx(xBe,{isOpen:!!this.state.activeRequest,title:"Loading style",onCancel:i=>(Hn().f[20]++,Hn().s[57]++,this.onCancelActiveRequest(i)),message:"Loading: "+this.state.activeRequestUrl})]})}}function tf(){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 tf=function(){return s},s}tf();class SBe extends Sn.Component{render(){tf().f[0]++;const n=(tf().s[0]++,[{key:G.jsx("kbd",{children:"?"}),text:"Shortcuts menu"},{key:G.jsx("kbd",{children:"o"}),text:"Open modal"},{key:G.jsx("kbd",{children:"e"}),text:"Export modal"},{key:G.jsx("kbd",{children:"d"}),text:"Data Sources modal"},{key:G.jsx("kbd",{children:"s"}),text:"Style Settings modal"},{key:G.jsx("kbd",{children:"i"}),text:"Toggle inspect"},{key:G.jsx("kbd",{children:"m"}),text:"Focus map"},{key:G.jsx("kbd",{children:"!"}),text:"Debug modal"}]),t=(tf().s[1]++,[{key:G.jsx("kbd",{children:"+"}),text:"Increase the zoom level by 1."},{key:G.jsxs(G.Fragment,{children:[G.jsx("kbd",{children:"Shift"})," + ",G.jsx("kbd",{children:"+"})]}),text:"Increase the zoom level by 2."},{key:G.jsx("kbd",{children:"-"}),text:"Decrease the zoom level by 1."},{key:G.jsxs(G.Fragment,{children:[G.jsx("kbd",{children:"Shift"})," + ",G.jsx("kbd",{children:"-"})]}),text:"Decrease the zoom level by 2."},{key:G.jsx("kbd",{children:"Up"}),text:"Pan up by 100 pixels."},{key:G.jsx("kbd",{children:"Down"}),text:"Pan down by 100 pixels."},{key:G.jsx("kbd",{children:"Left"}),text:"Pan left by 100 pixels."},{key:G.jsx("kbd",{children:"Right"}),text:"Pan right by 100 pixels."},{key:G.jsxs(G.Fragment,{children:[G.jsx("kbd",{children:"Shift"})," + ",G.jsx("kbd",{children:"Right"})]}),text:"Increase the rotation by 15 degrees."},{key:G.jsxs(G.Fragment,{children:[G.jsx("kbd",{children:"Shift"})," + ",G.jsx("kbd",{children:"Left"})]}),text:"Decrease the rotation by 15 degrees."},{key:G.jsxs(G.Fragment,{children:[G.jsx("kbd",{children:"Shift"})," + ",G.jsx("kbd",{children:"Up"})]}),text:"Increase the pitch by 10 degrees."},{key:G.jsxs(G.Fragment,{children:[G.jsx("kbd",{children:"Shift"})," + ",G.jsx("kbd",{children:"Down"})]}),text:"Decrease the pitch by 10 degrees."}]);return tf().s[2]++,G.jsx(Of,{"data-wd-key":"modal:shortcuts",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Shortcuts",children:G.jsxs("section",{className:"maputnik-modal-section maputnik-modal-shortcuts",children:[G.jsxs("p",{children:["Press ",G.jsx("code",{children:"ESC"})," to lose focus of any active elements, then press one of:"]}),G.jsx("dl",{children:n.map((r,i)=>(tf().f[1]++,tf().s[3]++,G.jsxs("div",{className:"maputnik-modal-shortcuts__shortcut",children:[G.jsx("dt",{children:r.key},"dt"+i),G.jsx("dd",{children:r.text},"dd"+i)]},i)))}),G.jsx("p",{children:"If the Map is in focused you can use the following shortcuts"}),G.jsx("ul",{children:t.map((r,i)=>(tf().f[2]++,tf().s[4]++,G.jsxs("li",{children:[G.jsx("span",{children:r.key})," ",r.text]},i)))})]})})}}const EBe="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 Am(){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 Am=function(){return s},s}Am();class OBe extends Sn.Component{constructor(){super(...arguments);an(this,"onClick",(Am().s[0]++,()=>{Am().f[0]++,Am().s[1]++,window.open("https://gregorywolanski.typeform.com/to/cPgaSY","_blank"),Am().s[2]++,this.props.onOpenToggle()}))}render(){return Am().f[1]++,Am().s[3]++,G.jsx(Of,{"data-wd-key":"modal:survey",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Maputnik Survey",children:G.jsxs("div",{className:"maputnik-modal-survey",children:[G.jsx("img",{src:EBe,className:"maputnik-modal-survey__logo"}),G.jsx("h1",{children:"You + Maputnik = Maputnik better for you"}),G.jsx("p",{className:"maputnik-modal-survey__description",children:"We dont track you, so we dont know how you use Maputnik. Help us make Maputnik better for you by completing a 7minute survey carried out by our contributing designer."}),G.jsx(ja,{onClick:this.onClick,className:"maputnik-big-button maputnik-white-button maputnik-wide-button",children:"Take the Maputnik Survey"}),G.jsx("p",{className:"maputnik-modal-survey__footnote",children:"It takes 7 minutes, tops! Every question is optional."})]})})}}function Pl(){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 Pl=function(){return s},s}Pl();class BBe extends Sn.Component{render(){Pl().f[0]++;const{mapView:n}=(Pl().s[0]++,this.props),t=(Pl().s[1]++,Math.round(n.zoom)+1),r=(Pl().s[2]++,+n.center.lng.toFixed(5)),i=(Pl().s[3]++,+n.center.lat.toFixed(5));return Pl().s[4]++,G.jsxs(Of,{"data-wd-key":"modal:debug",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Debug",children:[G.jsxs("section",{className:"maputnik-modal-section maputnik-modal-shortcuts",children:[G.jsx("h1",{children:"Options"}),(Pl().b[0][0]++,this.props.renderer==="mlgljs"&&(Pl().b[0][1]++,G.jsx("ul",{children:Object.entries(this.props.maplibreGlDebugOptions).map(([o,s])=>(Pl().f[1]++,Pl().s[5]++,G.jsx("li",{children:G.jsxs("label",{children:[G.jsx("input",{type:"checkbox",checked:s,onChange:a=>(Pl().f[2]++,Pl().s[6]++,this.props.onChangeMaplibreGlDebug(o,a.target.checked))})," ",o]})},o)))}))),(Pl().b[1][0]++,this.props.renderer==="ol"&&(Pl().b[1][1]++,G.jsx("ul",{children:Object.entries(this.props.openlayersDebugOptions).map(([o,s])=>(Pl().f[3]++,Pl().s[7]++,G.jsx("li",{children:G.jsxs("label",{children:[G.jsx("input",{type:"checkbox",checked:s,onChange:a=>(Pl().f[4]++,Pl().s[8]++,this.props.onChangeOpenlayersDebug(o,a.target.checked))})," ",o]})},o)))})))]}),G.jsxs("section",{className:"maputnik-modal-section",children:[G.jsx("h1",{children:"Links"}),G.jsxs("p",{children:[G.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 m1={},M4={exports:{}};/*! https://mths.be/punycode v1.4.1 by @mathias */M4.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,h=36,g=1,C=26,B=38,k=700,P=72,L=128,J="-",N=/^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"},ce=h-g,me=Math.floor,he=String.fromCharCode,V;function ae(Xe){throw new RangeError(oe[Xe])}function ye(Xe,rt){for(var ot=Xe.length,on=[];ot--;)on[ot]=rt(Xe[ot]);return on}function Oe(Xe,rt){var ot=Xe.split("@"),on="";ot.length>1&&(on=ot[0]+"@",Xe=ot[1]),Xe=Xe.replace(q,".");var gt=Xe.split("."),at=ye(gt,rt).join(".");return on+at}function De(Xe){for(var rt=[],ot=0,on=Xe.length,gt,at;ot<on;)gt=Xe.charCodeAt(ot++),gt>=55296&&gt<=56319&&ot<on?(at=Xe.charCodeAt(ot++),(at&64512)==56320?rt.push(((gt&1023)<<10)+(at&1023)+65536):(rt.push(gt),ot--)):rt.push(gt);return rt}function He(Xe){return ye(Xe,function(rt){var ot="";return rt>65535&&(rt-=65536,ot+=he(rt>>>10&1023|55296),rt=56320|rt&1023),ot+=he(rt),ot}).join("")}function ke(Xe){return Xe-48<10?Xe-22:Xe-65<26?Xe-65:Xe-97<26?Xe-97:h}function nt(Xe,rt){return Xe+22+75*(Xe<26)-((rt!=0)<<5)}function be(Xe,rt,ot){var on=0;for(Xe=ot?me(Xe/k):Xe>>1,Xe+=me(Xe/rt);Xe>ce*C>>1;on+=h)Xe=me(Xe/ce);return me(on+(ce+1)*Xe/(Xe+B))}function Bt(Xe){var rt=[],ot=Xe.length,on,gt=0,at=L,It=P,Lt,Me,fe,xe,Ue,et,it,bt,Ut;for(Lt=Xe.lastIndexOf(J),Lt<0&&(Lt=0),Me=0;Me<Lt;++Me)Xe.charCodeAt(Me)>=128&&ae("not-basic"),rt.push(Xe.charCodeAt(Me));for(fe=Lt>0?Lt+1:0;fe<ot;){for(xe=gt,Ue=1,et=h;fe>=ot&&ae("invalid-input"),it=ke(Xe.charCodeAt(fe++)),(it>=h||it>me((a-gt)/Ue))&&ae("overflow"),gt+=it*Ue,bt=et<=It?g:et>=It+C?C:et-It,!(it<bt);et+=h)Ut=h-bt,Ue>me(a/Ut)&&ae("overflow"),Ue*=Ut;on=rt.length+1,It=be(gt-xe,on,xe==0),me(gt/on)>a-at&&ae("overflow"),at+=me(gt/on),gt%=on,rt.splice(gt++,0,at)}return He(rt)}function kt(Xe){var rt,ot,on,gt,at,It,Lt,Me,fe,xe,Ue,et=[],it,bt,Ut,Rt;for(Xe=De(Xe),it=Xe.length,rt=L,ot=0,at=P,It=0;It<it;++It)Ue=Xe[It],Ue<128&&et.push(he(Ue));for(on=gt=et.length,gt&&et.push(J);on<it;){for(Lt=a,It=0;It<it;++It)Ue=Xe[It],Ue>=rt&&Ue<Lt&&(Lt=Ue);for(bt=on+1,Lt-rt>me((a-ot)/bt)&&ae("overflow"),ot+=(Lt-rt)*bt,rt=Lt,It=0;It<it;++It)if(Ue=Xe[It],Ue<rt&&++ot>a&&ae("overflow"),Ue==rt){for(Me=ot,fe=h;xe=fe<=at?g:fe>=at+C?C:fe-at,!(Me<xe);fe+=h)Rt=Me-xe,Ut=h-xe,et.push(he(nt(xe+Rt%Ut,0))),Me=me(Rt/Ut);et.push(he(nt(Me,0))),at=be(ot,bt,on==gt),ot=0,++on}++ot,++rt}return et.join("")}function Yt(Xe){return Oe(Xe,function(rt){return N.test(rt)?Bt(rt.slice(4).toLowerCase()):rt})}function jt(Xe){return Oe(Xe,function(rt){return $.test(rt)?"xn--"+kt(rt):rt})}if(s={version:"1.4.1",ucs2:{decode:De,encode:He},decode:Bt,encode:kt,toASCII:jt,toUnicode:Yt},r&&i)if(e.exports==r)i.exports=s;else for(V in s)s.hasOwnProperty(V)&&(r[V]=s[V]);else t.punycode=s})(ch)})(M4,M4.exports);var kBe=M4.exports,IBe=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},YP=typeof Symbol<"u"&&Symbol,TBe=IBe,KBe=function(){return typeof YP!="function"||typeof Symbol!="function"||typeof YP("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:TBe()},qP={foo:{}},PBe=Object,FBe=function(){return{__proto__:qP}.foo===qP.foo&&!({__proto__:null}instanceof PBe)},DBe="Function.prototype.bind called on incompatible ",LBe=Object.prototype.toString,UBe=Math.max,RBe="[object Function]",HP=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},zBe=function(n,t){for(var r=[],i=t||0,o=0;i<n.length;i+=1,o+=1)r[o]=n[i];return r},jBe=function(e,n){for(var t="",r=0;r<e.length;r+=1)t+=e[r],r+1<e.length&&(t+=n);return t},WBe=function(n){var t=this;if(typeof t!="function"||LBe.apply(t)!==RBe)throw new TypeError(DBe+t);for(var r=zBe(arguments,1),i,o=function(){if(this instanceof i){var C=t.apply(this,HP(r,arguments));return Object(C)===C?C:this}return t.apply(n,HP(r,arguments))},s=UBe(0,t.length-r.length),a=[],h=0;h<s;h++)a[h]="$"+h;if(i=Function("binder","return function ("+jBe(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},NBe=WBe,dk=Function.prototype.bind||NBe,GBe=Function.prototype.call,QBe=Object.prototype.hasOwnProperty,$Be=dk,YBe=$Be.call(GBe,QBe),Bo,Ky=SyntaxError,QG=Function,gy=TypeError,gS=function(e){try{return QG('"use strict"; return ('+e+").constructor;")()}catch{}},t1=Object.getOwnPropertyDescriptor;if(t1)try{t1({},"")}catch{t1=null}var yS=function(){throw new gy},qBe=t1?function(){try{return arguments.callee,yS}catch{try{return t1(arguments,"callee").get}catch{return yS}}}():yS,yg=KBe(),HBe=FBe(),cu=Object.getPrototypeOf||(HBe?function(e){return e.__proto__}:null),kg={},VBe=typeof Uint8Array>"u"||!cu?Bo:cu(Uint8Array),n1={"%AggregateError%":typeof AggregateError>"u"?Bo:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?Bo:ArrayBuffer,"%ArrayIteratorPrototype%":yg&&cu?cu([][Symbol.iterator]()):Bo,"%AsyncFromSyncIteratorPrototype%":Bo,"%AsyncFunction%":kg,"%AsyncGenerator%":kg,"%AsyncGeneratorFunction%":kg,"%AsyncIteratorPrototype%":kg,"%Atomics%":typeof Atomics>"u"?Bo:Atomics,"%BigInt%":typeof BigInt>"u"?Bo:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?Bo:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?Bo:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?Bo:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array>"u"?Bo:Float32Array,"%Float64Array%":typeof Float64Array>"u"?Bo:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?Bo:FinalizationRegistry,"%Function%":QG,"%GeneratorFunction%":kg,"%Int8Array%":typeof Int8Array>"u"?Bo:Int8Array,"%Int16Array%":typeof Int16Array>"u"?Bo:Int16Array,"%Int32Array%":typeof Int32Array>"u"?Bo:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":yg&&cu?cu(cu([][Symbol.iterator]())):Bo,"%JSON%":typeof JSON=="object"?JSON:Bo,"%Map%":typeof Map>"u"?Bo:Map,"%MapIteratorPrototype%":typeof Map>"u"||!yg||!cu?Bo:cu(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?Bo:Promise,"%Proxy%":typeof Proxy>"u"?Bo:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect>"u"?Bo:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?Bo:Set,"%SetIteratorPrototype%":typeof Set>"u"||!yg||!cu?Bo:cu(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?Bo:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":yg&&cu?cu(""[Symbol.iterator]()):Bo,"%Symbol%":yg?Symbol:Bo,"%SyntaxError%":Ky,"%ThrowTypeError%":qBe,"%TypedArray%":VBe,"%TypeError%":gy,"%Uint8Array%":typeof Uint8Array>"u"?Bo:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?Bo:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?Bo:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?Bo:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap>"u"?Bo:WeakMap,"%WeakRef%":typeof WeakRef>"u"?Bo:WeakRef,"%WeakSet%":typeof WeakSet>"u"?Bo:WeakSet};if(cu)try{null.error}catch(e){var ZBe=cu(cu(e));n1["%Error.prototype%"]=ZBe}var XBe=function e(n){var t;if(n==="%AsyncFunction%")t=gS("async function () {}");else if(n==="%GeneratorFunction%")t=gS("function* () {}");else if(n==="%AsyncGeneratorFunction%")t=gS("async function* () {}");else if(n==="%AsyncGenerator%"){var r=e("%AsyncGeneratorFunction%");r&&(t=r.prototype)}else if(n==="%AsyncIteratorPrototype%"){var i=e("%AsyncGenerator%");i&&cu&&(t=cu(i.prototype))}return n1[n]=t,t},VP={"%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=dk,S4=YBe,JBe=xb.call(Function.call,Array.prototype.concat),e7e=xb.call(Function.apply,Array.prototype.splice),ZP=xb.call(Function.call,String.prototype.replace),E4=xb.call(Function.call,String.prototype.slice),t7e=xb.call(Function.call,RegExp.prototype.exec),n7e=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,r7e=/\\(\\)?/g,i7e=function(n){var t=E4(n,0,1),r=E4(n,-1);if(t==="%"&&r!=="%")throw new Ky("invalid intrinsic syntax, expected closing `%`");if(r==="%"&&t!=="%")throw new Ky("invalid intrinsic syntax, expected opening `%`");var i=[];return ZP(n,n7e,function(o,s,a,h){i[i.length]=a?ZP(h,r7e,"$1"):s||o}),i},o7e=function(n,t){var r=n,i;if(S4(VP,r)&&(i=VP[r],r="%"+i[0]+"%"),S4(n1,r)){var o=n1[r];if(o===kg&&(o=XBe(r)),typeof o>"u"&&!t)throw new gy("intrinsic "+n+" exists, but is not available. Please file an issue!");return{alias:i,name:r,value:o}}throw new Ky("intrinsic "+n+" does not exist!")},O1=function(n,t){if(typeof n!="string"||n.length===0)throw new gy("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof t!="boolean")throw new gy('"allowMissing" argument must be a boolean');if(t7e(/^%?[^%]*%?$/,n)===null)throw new Ky("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=i7e(n),i=r.length>0?r[0]:"",o=o7e("%"+i+"%",t),s=o.name,a=o.value,h=!1,g=o.alias;g&&(i=g[0],e7e(r,JBe([0,1],g)));for(var C=1,B=!0;C<r.length;C+=1){var k=r[C],P=E4(k,0,1),L=E4(k,-1);if((P==='"'||P==="'"||P==="`"||L==='"'||L==="'"||L==="`")&&P!==L)throw new Ky("property names with quotes must have matching quotes");if((k==="constructor"||!B)&&(h=!0),i+="."+k,s="%"+i+"%",S4(n1,s))a=n1[s];else if(a!=null){if(!(k in a)){if(!t)throw new gy("base intrinsic for "+n+" exists, but the property is not available.");return}if(t1&&C+1>=r.length){var J=t1(a,k);B=!!J,B&&"get"in J&&!("originalValue"in J.get)?a=J.get:a=a[k]}else B=S4(a,k),a=a[k];B&&!h&&(n1[s]=a)}}return a},$G={exports:{}},a7e=O1,fO=a7e("%Object.defineProperty%",!0),pO=function(){if(fO)try{return fO({},"a",{value:1}),!0}catch{return!1}return!1};pO.hasArrayLengthDefineBug=function(){if(!pO())return null;try{return fO([],"length",{value:1}).length!==1}catch{return!0}};var YG=pO,s7e=O1,B2=s7e("%Object.getOwnPropertyDescriptor%",!0);if(B2)try{B2([],"length")}catch{B2=null}var qG=B2,l7e=YG(),hk=O1,z_=l7e&&hk("%Object.defineProperty%",!0);if(z_)try{z_({},"a",{value:1})}catch{z_=!1}var u7e=hk("%SyntaxError%"),vg=hk("%TypeError%"),XP=qG,A7e=function(n,t,r){if(!n||typeof n!="object"&&typeof n!="function")throw new vg("`obj` must be an object or a function`");if(typeof t!="string"&&typeof t!="symbol")throw new vg("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new vg("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new vg("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new vg("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new vg("`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,h=!!XP&&XP(n,t);if(z_)z_(n,t,{configurable:s===null&&h?h.configurable:!s,enumerable:i===null&&h?h.enumerable:!i,value:r,writable:o===null&&h?h.writable:!o});else if(a||!i&&!o&&!s)n[t]=r;else throw new u7e("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},HG=O1,JP=A7e,c7e=YG(),eF=qG,tF=HG("%TypeError%"),d7e=HG("%Math.floor%"),h7e=function(n,t){if(typeof n!="function")throw new tF("`fn` is not a function");if(typeof t!="number"||t<0||t>4294967295||d7e(t)!==t)throw new tF("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],i=!0,o=!0;if("length"in n&&eF){var s=eF(n,"length");s&&!s.configurable&&(i=!1),s&&!s.writable&&(o=!1)}return(i||o||!r)&&(c7e?JP(n,"length",t,!0,!0):JP(n,"length",t)),n};(function(e){var n=dk,t=O1,r=h7e,i=t("%TypeError%"),o=t("%Function.prototype.apply%"),s=t("%Function.prototype.call%"),a=t("%Reflect.apply%",!0)||n.call(s,o),h=t("%Object.defineProperty%",!0),g=t("%Math.max%");if(h)try{h({},"a",{value:1})}catch{h=null}e.exports=function(k){if(typeof k!="function")throw new i("a function is required");var P=a(n,s,arguments);return r(P,1+g(0,k.length-(arguments.length-1)),!0)};var C=function(){return a(n,o,arguments)};h?h(e.exports,"apply",{value:C}):e.exports.apply=C})($G);var f7e=$G.exports,VG=O1,ZG=f7e,p7e=ZG(VG("String.prototype.indexOf")),m7e=function(n,t){var r=VG(n,!!t);return typeof r=="function"&&p7e(n,".prototype.")>-1?ZG(r):r};const g7e={},y7e=Object.freeze(Object.defineProperty({__proto__:null,default:g7e},Symbol.toStringTag,{value:"Module"})),v7e=EO(y7e);var fk=typeof Map=="function"&&Map.prototype,vS=Object.getOwnPropertyDescriptor&&fk?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,O4=fk&&vS&&typeof vS.get=="function"?vS.get:null,nF=fk&&Map.prototype.forEach,pk=typeof Set=="function"&&Set.prototype,_S=Object.getOwnPropertyDescriptor&&pk?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,B4=pk&&_S&&typeof _S.get=="function"?_S.get:null,rF=pk&&Set.prototype.forEach,_7e=typeof WeakMap=="function"&&WeakMap.prototype,j_=_7e?WeakMap.prototype.has:null,C7e=typeof WeakSet=="function"&&WeakSet.prototype,W_=C7e?WeakSet.prototype.has:null,b7e=typeof WeakRef=="function"&&WeakRef.prototype,iF=b7e?WeakRef.prototype.deref:null,x7e=Boolean.prototype.valueOf,w7e=Object.prototype.toString,M7e=Function.prototype.toString,S7e=String.prototype.match,mk=String.prototype.slice,xm=String.prototype.replace,E7e=String.prototype.toUpperCase,oF=String.prototype.toLowerCase,XG=RegExp.prototype.test,aF=Array.prototype.concat,rf=Array.prototype.join,O7e=Array.prototype.slice,sF=Math.floor,mO=typeof BigInt=="function"?BigInt.prototype.valueOf:null,CS=Object.getOwnPropertySymbols,gO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,Py=typeof Symbol=="function"&&typeof Symbol.iterator=="object",aA=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===Py||!0)?Symbol.toStringTag:null,JG=Object.prototype.propertyIsEnumerable,lF=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function uF(e,n){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||XG.call(/e/,n))return n;var t=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var r=e<0?-sF(-e):sF(e);if(r!==e){var i=String(r),o=mk.call(n,i.length+1);return xm.call(i,t,"$&_")+"."+xm.call(xm.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return xm.call(n,t,"$&_")}var yO=v7e,AF=yO.custom,cF=tQ(AF)?AF:null,B7e=function e(n,t,r,i){var o=t||{};if(cm(o,"quoteStyle")&&o.quoteStyle!=="single"&&o.quoteStyle!=="double")throw new TypeError('option "quoteStyle" must be "single" or "double"');if(cm(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=cm(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(cm(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(cm(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 rQ(n,o);if(typeof n=="number"){if(n===0)return 1/0/n>0?"0":"-0";var h=String(n);return a?uF(n,h):h}if(typeof n=="bigint"){var g=String(n)+"n";return a?uF(n,g):g}var C=typeof o.depth>"u"?5:o.depth;if(typeof r>"u"&&(r=0),r>=C&&C>0&&typeof n=="object")return vO(n)?"[Array]":"[Object]";var B=Y7e(o,r);if(typeof i>"u")i=[];else if(nQ(i,n)>=0)return"[Circular]";function k(ke,nt,be){if(nt&&(i=O7e.call(i),i.push(nt)),be){var Bt={depth:o.depth};return cm(o,"quoteStyle")&&(Bt.quoteStyle=o.quoteStyle),e(ke,Bt,r+1,i)}return e(ke,o,r+1,i)}if(typeof n=="function"&&!dF(n)){var P=U7e(n),L=Jx(n,k);return"[Function"+(P?": "+P:" (anonymous)")+"]"+(L.length>0?" { "+rf.call(L,", ")+" }":"")}if(tQ(n)){var J=Py?xm.call(String(n),/^(Symbol\(.*\))_[^)]*$/,"$1"):gO.call(n);return typeof n=="object"&&!Py?Jv(J):J}if(G7e(n)){for(var N="<"+oF.call(String(n.nodeName)),$=n.attributes||[],q=0;q<$.length;q++)N+=" "+$[q].name+"="+eQ(k7e($[q].value),"double",o);return N+=">",n.childNodes&&n.childNodes.length&&(N+="..."),N+="</"+oF.call(String(n.nodeName))+">",N}if(vO(n)){if(n.length===0)return"[]";var oe=Jx(n,k);return B&&!$7e(oe)?"["+_O(oe,B)+"]":"[ "+rf.call(oe,", ")+" ]"}if(T7e(n)){var ce=Jx(n,k);return!("cause"in Error.prototype)&&"cause"in n&&!JG.call(n,"cause")?"{ ["+String(n)+"] "+rf.call(aF.call("[cause]: "+k(n.cause),ce),", ")+" }":ce.length===0?"["+String(n)+"]":"{ ["+String(n)+"] "+rf.call(ce,", ")+" }"}if(typeof n=="object"&&s){if(cF&&typeof n[cF]=="function"&&yO)return yO(n,{depth:C-r});if(s!=="symbol"&&typeof n.inspect=="function")return n.inspect()}if(R7e(n)){var me=[];return nF&&nF.call(n,function(ke,nt){me.push(k(nt,n,!0)+" => "+k(ke,n))}),hF("Map",O4.call(n),me,B)}if(W7e(n)){var he=[];return rF&&rF.call(n,function(ke){he.push(k(ke,n))}),hF("Set",B4.call(n),he,B)}if(z7e(n))return bS("WeakMap");if(N7e(n))return bS("WeakSet");if(j7e(n))return bS("WeakRef");if(P7e(n))return Jv(k(Number(n)));if(D7e(n))return Jv(k(mO.call(n)));if(F7e(n))return Jv(x7e.call(n));if(K7e(n))return Jv(k(String(n)));if(typeof window<"u"&&n===window)return"{ [object Window] }";if(n===window)return"{ [object globalThis] }";if(!I7e(n)&&!dF(n)){var V=Jx(n,k),ae=lF?lF(n)===Object.prototype:n instanceof Object||n.constructor===Object,ye=n instanceof Object?"":"null prototype",Oe=!ae&&aA&&Object(n)===n&&aA in n?mk.call(Ym(n),8,-1):ye?"Object":"",De=ae||typeof n.constructor!="function"?"":n.constructor.name?n.constructor.name+" ":"",He=De+(Oe||ye?"["+rf.call(aF.call([],Oe||[],ye||[]),": ")+"] ":"");return V.length===0?He+"{}":B?He+"{"+_O(V,B)+"}":He+"{ "+rf.call(V,", ")+" }"}return String(n)};function eQ(e,n,t){var r=(t.quoteStyle||n)==="double"?'"':"'";return r+e+r}function k7e(e){return xm.call(String(e),/"/g,"&quot;")}function vO(e){return Ym(e)==="[object Array]"&&(!aA||!(typeof e=="object"&&aA in e))}function I7e(e){return Ym(e)==="[object Date]"&&(!aA||!(typeof e=="object"&&aA in e))}function dF(e){return Ym(e)==="[object RegExp]"&&(!aA||!(typeof e=="object"&&aA in e))}function T7e(e){return Ym(e)==="[object Error]"&&(!aA||!(typeof e=="object"&&aA in e))}function K7e(e){return Ym(e)==="[object String]"&&(!aA||!(typeof e=="object"&&aA in e))}function P7e(e){return Ym(e)==="[object Number]"&&(!aA||!(typeof e=="object"&&aA in e))}function F7e(e){return Ym(e)==="[object Boolean]"&&(!aA||!(typeof e=="object"&&aA in e))}function tQ(e){if(Py)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!gO)return!1;try{return gO.call(e),!0}catch{}return!1}function D7e(e){if(!e||typeof e!="object"||!mO)return!1;try{return mO.call(e),!0}catch{}return!1}var L7e=Object.prototype.hasOwnProperty||function(e){return e in this};function cm(e,n){return L7e.call(e,n)}function Ym(e){return w7e.call(e)}function U7e(e){if(e.name)return e.name;var n=S7e.call(M7e.call(e),/^function\s*([\w$]+)/);return n?n[1]:null}function nQ(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 R7e(e){if(!O4||!e||typeof e!="object")return!1;try{O4.call(e);try{B4.call(e)}catch{return!0}return e instanceof Map}catch{}return!1}function z7e(e){if(!j_||!e||typeof e!="object")return!1;try{j_.call(e,j_);try{W_.call(e,W_)}catch{return!0}return e instanceof WeakMap}catch{}return!1}function j7e(e){if(!iF||!e||typeof e!="object")return!1;try{return iF.call(e),!0}catch{}return!1}function W7e(e){if(!B4||!e||typeof e!="object")return!1;try{B4.call(e);try{O4.call(e)}catch{return!0}return e instanceof Set}catch{}return!1}function N7e(e){if(!W_||!e||typeof e!="object")return!1;try{W_.call(e,W_);try{j_.call(e,j_)}catch{return!0}return e instanceof WeakSet}catch{}return!1}function G7e(e){return!e||typeof e!="object"?!1:typeof HTMLElement<"u"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}function rQ(e,n){if(e.length>n.maxStringLength){var t=e.length-n.maxStringLength,r="... "+t+" more character"+(t>1?"s":"");return rQ(mk.call(e,0,n.maxStringLength),n)+r}var i=xm.call(xm.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,Q7e);return eQ(i,"single",n)}function Q7e(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":"")+E7e.call(n.toString(16))}function Jv(e){return"Object("+e+")"}function bS(e){return e+" { ? }"}function hF(e,n,t,r){var i=r?_O(t,r):rf.call(t,", ");return e+" ("+n+") {"+i+"}"}function $7e(e){for(var n=0;n<e.length;n++)if(nQ(e[n],`
`)>=0)return!1;return!0}function Y7e(e,n){var t;if(e.indent===" ")t=" ";else if(typeof e.indent=="number"&&e.indent>0)t=rf.call(Array(e.indent+1)," ");else return null;return{base:t,prev:rf.call(Array(n+1),t)}}function _O(e,n){if(e.length===0)return"";var t=`
`+n.prev+n.base;return t+rf.call(e,","+t)+`
`+n.prev}function Jx(e,n){var t=vO(e),r=[];if(t){r.length=e.length;for(var i=0;i<e.length;i++)r[i]=cm(e,i)?n(e[i],e):""}var o=typeof CS=="function"?CS(e):[],s;if(Py){s={};for(var a=0;a<o.length;a++)s["$"+o[a]]=o[a]}for(var h in e)cm(e,h)&&(t&&String(Number(h))===h&&h<e.length||Py&&s["$"+h]instanceof Symbol||(XG.call(/[^\w$]/,h)?r.push(n(h,e)+": "+n(e[h],e)):r.push(h+": "+n(e[h],e))));if(typeof CS=="function")for(var g=0;g<o.length;g++)JG.call(e,o[g])&&r.push("["+n(o[g])+"]: "+n(e[o[g]],e));return r}var gk=O1,rv=m7e,q7e=B7e,H7e=gk("%TypeError%"),e2=gk("%WeakMap%",!0),t2=gk("%Map%",!0),V7e=rv("WeakMap.prototype.get",!0),Z7e=rv("WeakMap.prototype.set",!0),X7e=rv("WeakMap.prototype.has",!0),J7e=rv("Map.prototype.get",!0),e8e=rv("Map.prototype.set",!0),t8e=rv("Map.prototype.has",!0),yk=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},n8e=function(e,n){var t=yk(e,n);return t&&t.value},r8e=function(e,n,t){var r=yk(e,n);r?r.value=t:e.next={key:n,next:e.next,value:t}},i8e=function(e,n){return!!yk(e,n)},o8e=function(){var n,t,r,i={assert:function(o){if(!i.has(o))throw new H7e("Side channel does not contain "+q7e(o))},get:function(o){if(e2&&o&&(typeof o=="object"||typeof o=="function")){if(n)return V7e(n,o)}else if(t2){if(t)return J7e(t,o)}else if(r)return n8e(r,o)},has:function(o){if(e2&&o&&(typeof o=="object"||typeof o=="function")){if(n)return X7e(n,o)}else if(t2){if(t)return t8e(t,o)}else if(r)return i8e(r,o);return!1},set:function(o,s){e2&&o&&(typeof o=="object"||typeof o=="function")?(n||(n=new e2),Z7e(n,o,s)):t2?(t||(t=new t2),e8e(t,o,s)):(r||(r={key:{},next:null}),r8e(r,o,s))}};return i},a8e=String.prototype.replace,s8e=/%20/g,xS={RFC1738:"RFC1738",RFC3986:"RFC3986"},vk={default:xS.RFC3986,formatters:{RFC1738:function(e){return a8e.call(e,s8e,"+")},RFC3986:function(e){return String(e)}},RFC1738:xS.RFC1738,RFC3986:xS.RFC3986},l8e=vk,wS=Object.prototype.hasOwnProperty,P0=Array.isArray,Zh=function(){for(var e=[],n=0;n<256;++n)e.push("%"+((n<16?"0":"")+n.toString(16)).toUpperCase());return e}(),u8e=function(n){for(;n.length>1;){var t=n.pop(),r=t.obj[t.prop];if(P0(r)){for(var i=[],o=0;o<r.length;++o)typeof r[o]<"u"&&i.push(r[o]);t.obj[t.prop]=i}}},iQ=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},A8e=function e(n,t,r){if(!t)return n;if(typeof t!="object"){if(P0(n))n.push(t);else if(n&&typeof n=="object")(r&&(r.plainObjects||r.allowPrototypes)||!wS.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 P0(n)&&!P0(t)&&(i=iQ(n,r)),P0(n)&&P0(t)?(t.forEach(function(o,s){if(wS.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 wS.call(o,s)?o[s]=e(o[s],a,r):o[s]=a,o},i)},c8e=function(n,t){return Object.keys(t).reduce(function(r,i){return r[i]=t[i],r},n)},d8e=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}},h8e=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(C){return"%26%23"+parseInt(C.slice(2),16)+"%3B"});for(var a="",h=0;h<s.length;++h){var g=s.charCodeAt(h);if(g===45||g===46||g===95||g===126||g>=48&&g<=57||g>=65&&g<=90||g>=97&&g<=122||o===l8e.RFC1738&&(g===40||g===41)){a+=s.charAt(h);continue}if(g<128){a=a+Zh[g];continue}if(g<2048){a=a+(Zh[192|g>>6]+Zh[128|g&63]);continue}if(g<55296||g>=57344){a=a+(Zh[224|g>>12]+Zh[128|g>>6&63]+Zh[128|g&63]);continue}h+=1,g=65536+((g&1023)<<10|s.charCodeAt(h)&1023),a+=Zh[240|g>>18]+Zh[128|g>>12&63]+Zh[128|g>>6&63]+Zh[128|g&63]}return a},f8e=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),h=0;h<a.length;++h){var g=a[h],C=s[g];typeof C=="object"&&C!==null&&r.indexOf(C)===-1&&(t.push({obj:s,prop:g}),r.push(C))}return u8e(t),n},p8e=function(n){return Object.prototype.toString.call(n)==="[object RegExp]"},m8e=function(n){return!n||typeof n!="object"?!1:!!(n.constructor&&n.constructor.isBuffer&&n.constructor.isBuffer(n))},g8e=function(n,t){return[].concat(n,t)},y8e=function(n,t){if(P0(n)){for(var r=[],i=0;i<n.length;i+=1)r.push(t(n[i]));return r}return t(n)},oQ={arrayToObject:iQ,assign:c8e,combine:g8e,compact:f8e,decode:d8e,encode:h8e,isBuffer:m8e,isRegExp:p8e,maybeMap:y8e,merge:A8e},aQ=o8e,k2=oQ,N_=vk,v8e=Object.prototype.hasOwnProperty,fF={brackets:function(n){return n+"[]"},comma:"comma",indices:function(n,t){return n+"["+t+"]"},repeat:function(n){return n}},fp=Array.isArray,_8e=Array.prototype.push,sQ=function(e,n){_8e.apply(e,fp(n)?n:[n])},C8e=Date.prototype.toISOString,pF=N_.default,nA={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:k2.encode,encodeValuesOnly:!1,format:pF,formatter:N_.formatters[pF],indices:!1,serializeDate:function(n){return C8e.call(n)},skipNulls:!1,strictNullHandling:!1},b8e=function(n){return typeof n=="string"||typeof n=="number"||typeof n=="boolean"||typeof n=="symbol"||typeof n=="bigint"},MS={},x8e=function e(n,t,r,i,o,s,a,h,g,C,B,k,P,L,J,N){for(var $=n,q=N,oe=0,ce=!1;(q=q.get(MS))!==void 0&&!ce;){var me=q.get(n);if(oe+=1,typeof me<"u"){if(me===oe)throw new RangeError("Cyclic object value");ce=!0}typeof q.get(MS)>"u"&&(oe=0)}if(typeof h=="function"?$=h(t,$):$ instanceof Date?$=B($):r==="comma"&&fp($)&&($=k2.maybeMap($,function(Bt){return Bt instanceof Date?B(Bt):Bt})),$===null){if(o)return a&&!L?a(t,nA.encoder,J,"key",k):t;$=""}if(b8e($)||k2.isBuffer($)){if(a){var he=L?t:a(t,nA.encoder,J,"key",k);return[P(he)+"="+P(a($,nA.encoder,J,"value",k))]}return[P(t)+"="+P(String($))]}var V=[];if(typeof $>"u")return V;var ae;if(r==="comma"&&fp($))L&&a&&($=k2.maybeMap($,a)),ae=[{value:$.length>0?$.join(",")||null:void 0}];else if(fp(h))ae=h;else{var ye=Object.keys($);ae=g?ye.sort(g):ye}for(var Oe=i&&fp($)&&$.length===1?t+"[]":t,De=0;De<ae.length;++De){var He=ae[De],ke=typeof He=="object"&&typeof He.value<"u"?He.value:$[He];if(!(s&&ke===null)){var nt=fp($)?typeof r=="function"?r(Oe,He):Oe:Oe+(C?"."+He:"["+He+"]");N.set(n,oe);var be=aQ();be.set(MS,N),sQ(V,e(ke,nt,r,i,o,s,r==="comma"&&L&&fp($)?null:a,h,g,C,B,k,P,L,J,be))}}return V},w8e=function(n){if(!n)return nA;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||nA.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=N_.default;if(typeof n.format<"u"){if(!v8e.call(N_.formatters,n.format))throw new TypeError("Unknown format option provided.");r=n.format}var i=N_.formatters[r],o=nA.filter;return(typeof n.filter=="function"||fp(n.filter))&&(o=n.filter),{addQueryPrefix:typeof n.addQueryPrefix=="boolean"?n.addQueryPrefix:nA.addQueryPrefix,allowDots:typeof n.allowDots>"u"?nA.allowDots:!!n.allowDots,charset:t,charsetSentinel:typeof n.charsetSentinel=="boolean"?n.charsetSentinel:nA.charsetSentinel,delimiter:typeof n.delimiter>"u"?nA.delimiter:n.delimiter,encode:typeof n.encode=="boolean"?n.encode:nA.encode,encoder:typeof n.encoder=="function"?n.encoder:nA.encoder,encodeValuesOnly:typeof n.encodeValuesOnly=="boolean"?n.encodeValuesOnly:nA.encodeValuesOnly,filter:o,format:r,formatter:i,serializeDate:typeof n.serializeDate=="function"?n.serializeDate:nA.serializeDate,skipNulls:typeof n.skipNulls=="boolean"?n.skipNulls:nA.skipNulls,sort:typeof n.sort=="function"?n.sort:null,strictNullHandling:typeof n.strictNullHandling=="boolean"?n.strictNullHandling:nA.strictNullHandling}},M8e=function(e,n){var t=e,r=w8e(n),i,o;typeof r.filter=="function"?(o=r.filter,t=o("",t)):fp(r.filter)&&(o=r.filter,i=o);var s=[];if(typeof t!="object"||t===null)return"";var a;n&&n.arrayFormat in fF?a=n.arrayFormat:n&&"indices"in n?a=n.indices?"indices":"repeat":a="indices";var h=fF[a];if(n&&"commaRoundTrip"in n&&typeof n.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var g=h==="comma"&&n&&n.commaRoundTrip;i||(i=Object.keys(t)),r.sort&&i.sort(r.sort);for(var C=aQ(),B=0;B<i.length;++B){var k=i[B];r.skipNulls&&t[k]===null||sQ(s,x8e(t[k],k,h,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,C))}var P=s.join(r.delimiter),L=r.addQueryPrefix===!0?"?":"";return r.charsetSentinel&&(r.charset==="iso-8859-1"?L+="utf8=%26%2310003%3B&":L+="utf8=%E2%9C%93&"),P.length>0?L+P:""},Fy=oQ,CO=Object.prototype.hasOwnProperty,S8e=Array.isArray,Au={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:Fy.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},E8e=function(e){return e.replace(/&#(\d+);/g,function(n,t){return String.fromCharCode(parseInt(t,10))})},lQ=function(e,n){return e&&typeof e=="string"&&n.comma&&e.indexOf(",")>-1?e.split(","):e},O8e="utf8=%26%2310003%3B",B8e="utf8=%E2%9C%93",k8e=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,h,g=t.charset;if(t.charsetSentinel)for(h=0;h<s.length;++h)s[h].indexOf("utf8=")===0&&(s[h]===B8e?g="utf-8":s[h]===O8e&&(g="iso-8859-1"),a=h,h=s.length);for(h=0;h<s.length;++h)if(h!==a){var C=s[h],B=C.indexOf("]="),k=B===-1?C.indexOf("="):B+1,P,L;k===-1?(P=t.decoder(C,Au.decoder,g,"key"),L=t.strictNullHandling?null:""):(P=t.decoder(C.slice(0,k),Au.decoder,g,"key"),L=Fy.maybeMap(lQ(C.slice(k+1),t),function(J){return t.decoder(J,Au.decoder,g,"value")})),L&&t.interpretNumericEntities&&g==="iso-8859-1"&&(L=E8e(L)),C.indexOf("[]=")>-1&&(L=S8e(L)?[L]:L),CO.call(r,P)?r[P]=Fy.combine(r[P],L):r[P]=L}return r},I8e=function(e,n,t,r){for(var i=r?n:lQ(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 h=a.charAt(0)==="["&&a.charAt(a.length-1)==="]"?a.slice(1,-1):a,g=parseInt(h,10);!t.parseArrays&&h===""?s={0:i}:!isNaN(g)&&a!==h&&String(g)===h&&g>=0&&t.parseArrays&&g<=t.arrayLimit?(s=[],s[g]=i):h!=="__proto__"&&(s[h]=i)}i=s}return i},T8e=function(n,t,r,i){if(n){var o=r.allowDots?n.replace(/\.([^.[]+)/g,"[$1]"):n,s=/(\[[^[\]]*])/,a=/(\[[^[\]]*])/g,h=r.depth>0&&s.exec(o),g=h?o.slice(0,h.index):o,C=[];if(g){if(!r.plainObjects&&CO.call(Object.prototype,g)&&!r.allowPrototypes)return;C.push(g)}for(var B=0;r.depth>0&&(h=a.exec(o))!==null&&B<r.depth;){if(B+=1,!r.plainObjects&&CO.call(Object.prototype,h[1].slice(1,-1))&&!r.allowPrototypes)return;C.push(h[1])}return h&&C.push("["+o.slice(h.index)+"]"),I8e(C,t,r,i)}},K8e=function(n){if(!n)return Au;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"?Au.charset:n.charset;return{allowDots:typeof n.allowDots>"u"?Au.allowDots:!!n.allowDots,allowPrototypes:typeof n.allowPrototypes=="boolean"?n.allowPrototypes:Au.allowPrototypes,allowSparse:typeof n.allowSparse=="boolean"?n.allowSparse:Au.allowSparse,arrayLimit:typeof n.arrayLimit=="number"?n.arrayLimit:Au.arrayLimit,charset:t,charsetSentinel:typeof n.charsetSentinel=="boolean"?n.charsetSentinel:Au.charsetSentinel,comma:typeof n.comma=="boolean"?n.comma:Au.comma,decoder:typeof n.decoder=="function"?n.decoder:Au.decoder,delimiter:typeof n.delimiter=="string"||Fy.isRegExp(n.delimiter)?n.delimiter:Au.delimiter,depth:typeof n.depth=="number"||n.depth===!1?+n.depth:Au.depth,ignoreQueryPrefix:n.ignoreQueryPrefix===!0,interpretNumericEntities:typeof n.interpretNumericEntities=="boolean"?n.interpretNumericEntities:Au.interpretNumericEntities,parameterLimit:typeof n.parameterLimit=="number"?n.parameterLimit:Au.parameterLimit,parseArrays:n.parseArrays!==!1,plainObjects:typeof n.plainObjects=="boolean"?n.plainObjects:Au.plainObjects,strictNullHandling:typeof n.strictNullHandling=="boolean"?n.strictNullHandling:Au.strictNullHandling}},P8e=function(e,n){var t=K8e(n);if(e===""||e===null||typeof e>"u")return t.plainObjects?Object.create(null):{};for(var r=typeof e=="string"?k8e(e,t):e,i=t.plainObjects?Object.create(null):{},o=Object.keys(r),s=0;s<o.length;++s){var a=o[s],h=T8e(a,r[a],t,typeof e=="string");i=Fy.merge(i,h,t)}return t.allowSparse===!0?i:Fy.compact(i)},F8e=M8e,D8e=P8e,L8e=vk,U8e={formats:L8e,parse:D8e,stringify:F8e},R8e=kBe;function Cd(){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 z8e=/^([a-z0-9.+-]+:)/i,j8e=/:[0-9]*$/,W8e=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,N8e=["<",">",'"',"`"," ","\r",`
`," "],G8e=["{","}","|","\\","^","`"].concat(N8e),bO=["'"].concat(G8e),mF=["%","/","?",";","#"].concat(bO),gF=["/","?","#"],Q8e=255,yF=/^[+a-z0-9A-Z_-]{0,63}$/,$8e=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,Y8e={javascript:!0,"javascript:":!0},xO={javascript:!0,"javascript:":!0},yy={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},wO=U8e;function wb(e,n,t){if(e&&typeof e=="object"&&e instanceof Cd)return e;var r=new Cd;return r.parse(e,n,t),r}Cd.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 h=W8e.exec(a);if(h)return this.path=a,this.href=a,this.pathname=h[1],h[2]?(this.search=h[2],n?this.query=wO.parse(this.search.substr(1)):this.query=this.search.substr(1)):n&&(this.search="",this.query={}),this}var g=z8e.exec(a);if(g){g=g[0];var C=g.toLowerCase();this.protocol=C,a=a.substr(g.length)}if(t||g||a.match(/^\/\/[^@/]+@[^@/]+/)){var B=a.substr(0,2)==="//";B&&!(g&&xO[g])&&(a=a.substr(2),this.slashes=!0)}if(!xO[g]&&(B||g&&!yy[g])){for(var k=-1,P=0;P<gF.length;P++){var L=a.indexOf(gF[P]);L!==-1&&(k===-1||L<k)&&(k=L)}var J,N;k===-1?N=a.lastIndexOf("@"):N=a.lastIndexOf("@",k),N!==-1&&(J=a.slice(0,N),a=a.slice(N+1),this.auth=decodeURIComponent(J)),k=-1;for(var P=0;P<mF.length;P++){var L=a.indexOf(mF[P]);L!==-1&&(k===-1||L<k)&&(k=L)}k===-1&&(k=a.length),this.host=a.slice(0,k),a=a.slice(k),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 ce=q[P];if(ce&&!ce.match(yF)){for(var me="",he=0,V=ce.length;he<V;he++)ce.charCodeAt(he)>127?me+="x":me+=ce[he];if(!me.match(yF)){var ae=q.slice(0,P),ye=q.slice(P+1),Oe=ce.match($8e);Oe&&(ae.push(Oe[1]),ye.unshift(Oe[2])),ye.length&&(a="/"+ye.join(".")+a),this.hostname=ae.join(".");break}}}this.hostname.length>Q8e?this.hostname="":this.hostname=this.hostname.toLowerCase(),$||(this.hostname=R8e.toASCII(this.hostname));var De=this.port?":"+this.port:"",He=this.hostname||"";this.host=He+De,this.href+=this.host,$&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),a[0]!=="/"&&(a="/"+a))}if(!Y8e[C])for(var P=0,oe=bO.length;P<oe;P++){var ke=bO[P];if(a.indexOf(ke)!==-1){var nt=encodeURIComponent(ke);nt===ke&&(nt=escape(ke)),a=a.split(ke).join(nt)}}var be=a.indexOf("#");be!==-1&&(this.hash=a.substr(be),a=a.slice(0,be));var Bt=a.indexOf("?");if(Bt!==-1?(this.search=a.substr(Bt),this.query=a.substr(Bt+1),n&&(this.query=wO.parse(this.query)),a=a.slice(0,Bt)):n&&(this.search="",this.query={}),a&&(this.pathname=a),yy[C]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var De=this.pathname||"",kt=this.search||"";this.path=De+kt}return this.href=this.format(),this};function q8e(e){return typeof e=="string"&&(e=wb(e)),e instanceof Cd?e.format():Cd.prototype.format.call(e)}Cd.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=wO.stringify(this.query,{arrayFormat:"repeat",addQueryPrefix:!1}));var s=this.search||o&&"?"+o||"";return n&&n.substr(-1)!==":"&&(n+=":"),this.slashes||(!n||yy[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 H8e(e,n){return wb(e,!1,!0).resolve(n)}Cd.prototype.resolve=function(e){return this.resolveObject(wb(e,!1,!0)).format()};function V8e(e,n){return e?wb(e,!1,!0).resolveObject(n):n}Cd.prototype.resolveObject=function(e){if(typeof e=="string"){var n=new Cd;n.parse(e,!1,!0),e=n}for(var t=new Cd,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 h=s[a];h!=="protocol"&&(t[h]=e[h])}return yy[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(!yy[e.protocol]){for(var g=Object.keys(e),C=0;C<g.length;C++){var B=g[C];t[B]=e[B]}return t.href=t.format(),t}if(t.protocol=e.protocol,!e.host&&!xO[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 k=t.pathname||"",P=t.search||"";t.path=k+P}return t.slashes=t.slashes||e.slashes,t.href=t.format(),t}var L=t.pathname&&t.pathname.charAt(0)==="/",J=e.host||e.pathname&&e.pathname.charAt(0)==="/",N=J||L||t.host&&e.pathname,$=N,q=t.pathname&&t.pathname.split("/")||[],oe=e.pathname&&e.pathname.split("/")||[],ce=t.protocol&&!yy[t.protocol];if(ce&&(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),N=N&&(oe[0]===""||q[0]==="")),J)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(ce){t.host=q.shift(),t.hostname=t.host;var me=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;me&&(t.auth=me.shift(),t.hostname=me.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 he=q.slice(-1)[0],V=(t.host||e.host||q.length>1)&&(he==="."||he==="..")||he==="",ae=0,ye=q.length;ye>=0;ye--)he=q[ye],he==="."?q.splice(ye,1):he===".."?(q.splice(ye,1),ae++):ae&&(q.splice(ye,1),ae--);if(!N&&!$)for(;ae--;ae)q.unshift("..");N&&q[0]!==""&&(!q[0]||q[0].charAt(0)!=="/")&&q.unshift(""),V&&q.join("/").substr(-1)!=="/"&&q.push("");var Oe=q[0]===""||q[0]&&q[0].charAt(0)==="/";if(ce){t.hostname=Oe?"":q.length?q.shift():"",t.host=t.hostname;var me=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;me&&(t.auth=me.shift(),t.hostname=me.shift(),t.host=t.hostname)}return N=N||t.host&&q.length,N&&!Oe&&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};Cd.prototype.parseHost=function(){var e=this.host,n=j8e.exec(e);n&&(n=n[0],n!==":"&&(this.port=n.substr(1)),e=e.substr(0,e.length-n.length)),e&&(this.hostname=e)};m1.parse=wb;m1.resolve=H8e;m1.resolveObject=V8e;m1.format=q8e;m1.Url=Cd;function zo(){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 zo=function(){return s},s}zo();function uQ(e,n,t){zo().f[0]++,zo().s[0]++,fetch(e,{mode:"cors",credentials:"same-origin"}).then(function(r){return zo().f[1]++,zo().s[1]++,r.json()}).then(function(r){zo().f[2]++,zo().s[2]++,t(r)}).catch(function(){zo().f[3]++,zo().s[3]++,console.warn("Can not metadata for "+e),zo().s[4]++,t(n)})}function Z8e(e,n){if(zo().f[4]++,zo().s[5]++,e)zo().b[0][1]++;else return zo().b[0][0]++,zo().s[6]++,n([]);const t=(zo().s[7]++,m1.parse(e)),r=(zo().s[8]++,"/%7Bfontstack%7D/%7Brange%7D.pbf");zo().s[9]++,t.pathname===r?(zo().b[1][0]++,zo().s[10]++,t.pathname="/fontstacks.json"):(zo().b[1][1]++,zo().s[11]++,t.pathname=t.pathname.replace(r,".json"));const i=(zo().s[12]++,m1.format(t));zo().s[13]++,uQ(i,[],n)}function X8e(e,n){if(zo().f[5]++,zo().s[14]++,e)zo().b[2][1]++;else return zo().b[2][0]++,zo().s[15]++,n([]);const t=(zo().s[16]++,e+".json");zo().s[17]++,uQ(t,{},r=>(zo().f[6]++,zo().s[18]++,n(Object.keys(r))))}function $l(){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 $l=function(){return s},s}$l();function J8e(){$l().f[0]++;const e=($l().s[0]++,new URL(window.location.href));return $l().s[1]++,e.searchParams.get("style")}function AQ(e,n){$l().f[1]++,$l().s[2]++,console.log("Loading style",e),$l().s[3]++,fetch(e,{mode:"cors",credentials:"same-origin"}).then(function(t){return $l().f[2]++,$l().s[4]++,t.json()}).then(function(t){$l().f[3]++,$l().s[5]++,n(Iu.ensureStyleValidity(t))}).catch(function(){$l().f[4]++,$l().s[6]++,console.warn("Could not fetch default style",e),$l().s[7]++,n(Iu.emptyStyle)})}function vF(){$l().f[5]++;const e=($l().s[8]++,new URL(window.location.href));$l().s[9]++,e.searchParams.delete("style"),$l().s[10]++,window.history.replaceState({},document.title,e.toString())}function EA(){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 EA=function(){return s},s}EA();function cQ(e,n){EA().f[0]++;const t=(EA().s[0]++,vZ(e,n));return EA().s[1]++,t.map(r=>(EA().f[1]++,EA().s[2]++,r.command+" "+r.args.join(" ")))}function eke(e,n){return EA().f[2]++,EA().s[3]++,cQ(e,n).map(t=>(EA().f[3]++,EA().s[4]++,"Undo "+t))}function tke(e,n){return EA().f[4]++,EA().s[5]++,cQ(e,n).map(t=>(EA().f[5]++,EA().s[6]++,"Redo "+t))}function zr(){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 zr=function(){return s},s}zr();const BC=(zr().s[0]++,"maputnik"),dQ=(zr().s[1]++,"style"),_F=(zr().s[2]++,{latest:[BC,"latest_style"].join(":"),accessToken:[BC,"access_token"].join(":")}),nke=(zr().s[3]++,GG[0].url);function CF(e){zr().f[0]++,zr().s[4]++,AQ(nke,e)}function rke(){zr().f[1]++;const e=(zr().s[5]++,[]);zr().s[6]++;for(let n=(zr().s[7]++,0);n<window.localStorage.length;n++){const t=(zr().s[8]++,window.localStorage.key(n));zr().s[9]++,hQ(t)?(zr().b[0][0]++,zr().s[10]++,e.push(ike(t))):zr().b[0][1]++}return zr().s[11]++,e}function hQ(e){zr().f[2]++;const n=(zr().s[12]++,e.split(":"));return zr().s[13]++,zr().b[1][0]++,n.length===3&&(zr().b[1][1]++,n[0]===BC)&&(zr().b[1][2]++,n[1]===dQ)}function ike(e){if(zr().f[3]++,zr().s[14]++,hQ(e))zr().b[2][1]++;else throw zr().b[2][0]++,zr().s[15]++,"Key is not a valid style key";const n=(zr().s[16]++,e.split(":")),t=(zr().s[17]++,n[2]);return zr().s[18]++,t}function bF(e){return zr().f[4]++,zr().s[19]++,[BC,dQ,e].join(":")}class xF{constructor(){an(this,"mapStyles");zr().f[5]++,zr().s[20]++,this.mapStyles=rke()}init(n){zr().f[6]++,zr().s[21]++,n(null)}purge(){zr().f[7]++,zr().s[22]++;for(let n=(zr().s[23]++,0);n<window.localStorage.length;n++){const t=(zr().s[24]++,window.localStorage.key(n));zr().s[25]++,t.startsWith(BC)?(zr().b[3][0]++,zr().s[26]++,window.localStorage.removeItem(t)):zr().b[3][1]++}}latestStyle(n){if(zr().f[8]++,zr().s[27]++,this.mapStyles.length===0)return zr().b[4][0]++,zr().s[28]++,CF(n);zr().b[4][1]++;const t=(zr().s[29]++,window.localStorage.getItem(_F.latest)),r=(zr().s[30]++,window.localStorage.getItem(bF(t)));if(zr().s[31]++,r)return zr().b[5][0]++,zr().s[32]++,n(JSON.parse(r));zr().b[5][1]++,zr().s[33]++,CF(n)}save(n){zr().f[9]++,zr().s[34]++,n=Iu.ensureStyleValidity(n);const t=(zr().s[35]++,bF(n.id));return zr().s[36]++,window.localStorage.setItem(t,JSON.stringify(n)),zr().s[37]++,window.localStorage.setItem(_F.latest,n.id),zr().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 MO=function(e,n){return MO=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])},MO(e,n)};function fQ(e,n){MO(e,n);function t(){this.constructor=e}e.prototype=n===null?Object.create(n):(t.prototype=n.prototype,new t)}function oke(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 ake(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 ske(){for(var e=[],n=0;n<arguments.length;n++)e=e.concat(ake(arguments[n]));return e}var pQ=function(){function e(n,t){this.target=t,this.type=n}return e}(),lke=function(e){fQ(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}(pQ),uke=function(e){fQ(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}(pQ);/*!
* Reconnecting WebSocket
* by Pedro Ladaria <pedro.ladaria@gmail.com>
* https://github.com/pladaria/reconnecting-websocket
* License MIT
*/var Ake=function(){if(typeof WebSocket<"u")return WebSocket},cke=function(e){return typeof e<"u"&&!!e&&e.CLOSING===2},x0={maxReconnectionDelay:1e4,minReconnectionDelay:1e3+Math.random()*4e3,minUptime:5e3,reconnectionDelayGrowFactor:1.3,connectionTimeout:4e3,maxRetries:1/0,maxEnqueuedMessages:1/0,startClosed:!1,debug:!1},dke=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?x0.minUptime:s;clearTimeout(i._connectTimeout),i._uptimeTimeout=setTimeout(function(){return i._acceptOpen()},a),i._ws.binaryType=i._binaryType,i._messageQueue.forEach(function(h){return i._ws.send(h)}),i._messageQueue=[],i.onopen&&i.onopen(o),i._listeners.open.forEach(function(h){return i._callEventListener(o,h)})},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?x0.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=oke(i),s=o.next();!s.done;s=o.next()){var a=s.value;this._callEventListener(n,a)}}catch(h){t={error:h}}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,ske(["RWS>"],n))},e.prototype._getNextDelay=function(){var n=this._options,t=n.reconnectionDelayGrowFactor,r=t===void 0?x0.reconnectionDelayGrowFactor:t,i=n.minReconnectionDelay,o=i===void 0?x0.minReconnectionDelay:i,s=n.maxReconnectionDelay,a=s===void 0?x0.maxReconnectionDelay:s,h=0;return this._retryCount>0&&(h=o*Math.pow(r,this._retryCount-1),h>a&&(h=a)),this._debug("next delay",h),h},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?x0.maxRetries:r,o=t.connectionTimeout,s=o===void 0?x0.connectionTimeout:o,a=t.WebSocket,h=a===void 0?Ake():a;if(this._retryCount>=i){this._debug("max retries reached",this._retryCount,">=",i);return}if(this._retryCount++,this._debug("connect",this._retryCount),this._removeListeners(),!cke(h))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 h(g,n._protocols):new h(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 lke(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 uke(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 Nr(){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 Nr=function(){return s},s}Nr();class hke{constructor(n){an(this,"localUrl");an(this,"websocketUrl");an(this,"latestStyleId",(Nr().s[0]++,void 0));an(this,"onLocalStyleChange");Nr().f[0]++,Nr().s[1]++,this.onLocalStyleChange=(Nr().b[0][0]++,n.onLocalStyleChange||(Nr().b[0][1]++,()=>{Nr().f[1]++}));const t=(Nr().s[2]++,Nr().b[1][0]++,n.port||(Nr().b[1][1]++,"8000")),r=(Nr().s[3]++,Nr().b[2][0]++,n.host||(Nr().b[2][1]++,"localhost"));Nr().s[4]++,this.localUrl=`http://${r}:${t}`,Nr().s[5]++,this.websocketUrl=`ws://${r}:${t}/ws`,Nr().s[6]++,this.init=this.init.bind(this)}init(n){Nr().f[2]++,Nr().s[7]++,fetch(this.localUrl+"/styles",{mode:"cors"}).then(t=>(Nr().f[3]++,Nr().s[8]++,t.json())).then(t=>{Nr().f[4]++;const r=(Nr().s[9]++,t);Nr().s[10]++,this.latestStyleId=r[0],Nr().s[11]++,this.notifyLocalChanges(),Nr().s[12]++,n(null)}).catch(()=>{Nr().f[5]++,Nr().s[13]++,n(new Error("Can not connect to style API"))})}notifyLocalChanges(){Nr().f[6]++;const n=(Nr().s[14]++,new dke(this.websocketUrl));Nr().s[15]++,n.onmessage=t=>{if(Nr().f[7]++,Nr().s[16]++,t.data)Nr().b[3][1]++;else{Nr().b[3][0]++,Nr().s[17]++;return}Nr().s[18]++,console.log("Received style update from API");let r=(Nr().s[19]++,Iu.emptyStyle);Nr().s[20]++;try{Nr().s[21]++,r=JSON.parse(t.data)}catch(o){Nr().s[22]++,console.error(o)}const i=(Nr().s[23]++,Iu.ensureStyleValidity(r));Nr().s[24]++,this.onLocalStyleChange(i)}}latestStyle(n){if(Nr().f[8]++,Nr().s[25]++,this.latestStyleId)Nr().b[4][0]++,Nr().s[26]++,fetch(this.localUrl+"/styles/"+this.latestStyleId,{mode:"cors"}).then(function(t){return Nr().f[9]++,Nr().s[27]++,t.json()}).then(function(t){Nr().f[10]++,Nr().s[28]++,n(Iu.ensureStyleValidity(t))});else throw Nr().b[4][1]++,Nr().s[29]++,new Error("No latest style available. You need to init the api backend first.")}save(n){Nr().f[11]++;const t=(Nr().s[30]++,sR(Iu.stripAccessTokens(Iu.replaceAccessTokens(n)))),r=(Nr().s[31]++,n.id);return Nr().s[32]++,fetch(this.localUrl+"/styles/"+r,{method:"PUT",mode:"cors",headers:{"Content-Type":"application/json; charset=utf-8"},body:t}).catch(function(i){Nr().f[12]++,Nr().s[33]++,i?(Nr().b[5][0]++,Nr().s[34]++,console.error(i)):Nr().b[5][1]++}),Nr().s[35]++,n}}function es(){var e="/home/runner/work/maputnik/maputnik/src/libs/revisions.ts",n="9277d165d3b1fd7c235a1faab33cf41596d9966e",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:66}},5:{start:{line:16,column:4},end:{line:16,column:34}},6:{start:{line:17,column:4},end:{line:17,column:22}},7:{start:{line:20,column:4},end:{line:22,column:5}},8:{start:{line:21,column:6},end:{line:21,column:24}},9:{start:{line:23,column:4},end:{line:23,column:24}},10:{start:{line:26,column:4},end:{line:28,column:5}},11:{start:{line:27,column:6},end:{line:27,column:24}},12:{start:{line:29,column:4},end:{line:29,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:18,column:3}},line:14},4:{name:"(anonymous_4)",decl:{start:{line:19,column:2},end:{line:19,column:3}},loc:{start:{line:19,column:9},end:{line:24,column:3}},line:19},5:{name:"(anonymous_5)",decl:{start:{line:25,column:2},end:{line:25,column:3}},loc:{start:{line:25,column:9},end:{line:30,column:3}},line:25}},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:20,column:4},end:{line:22,column:5}},type:"if",locations:[{start:{line:20,column:4},end:{line:22,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:20},2:{loc:{start:{line:26,column:4},end:{line:28,column:5}},type:"if",locations:[{start:{line:26,column:4},end:{line:28,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:26}},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,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,YAAY,KAAK,UAAU,MAAM,GAAG,KAAK,aAAa,CAAC;AAE5D,SAAK,UAAU,KAAK,QAAQ;AAC5B,SAAK;AAAA,EAEP;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:"9277d165d3b1fd7c235a1faab33cf41596d9966e"},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 fke{constructor(n=(es().b[0][0]++,[])){an(this,"revisions");an(this,"currentIdx");es().f[0]++,es().s[0]++,this.revisions=n,es().s[1]++,this.currentIdx=n.length-1}get latest(){return es().f[1]++,es().s[2]++,this.revisions[this.revisions.length-1]}get current(){return es().f[2]++,es().s[3]++,this.revisions[this.currentIdx]}addRevision(n){es().f[3]++,es().s[4]++,this.revisions=this.revisions.slice(0,this.currentIdx+1),es().s[5]++,this.revisions.push(n),es().s[6]++,this.currentIdx++}undo(){return es().f[4]++,es().s[7]++,this.currentIdx>0?(es().b[1][0]++,es().s[8]++,this.currentIdx--):es().b[1][1]++,es().s[9]++,this.current}redo(){return es().f[5]++,es().s[10]++,this.currentIdx<this.revisions.length-1?(es().b[2][0]++,es().s[11]++,this.currentIdx++):es().b[2][1]++,es().s[12]++,this.current}}var mQ="Expected a function",wF=NaN,pke="[object Symbol]",mke=/^\s+|\s+$/g,gke=/^[-+]0x[0-9a-f]+$/i,yke=/^0b[01]+$/i,vke=/^0o[0-7]+$/i,_ke=parseInt,Cke=typeof window=="object"&&window&&window.Object===Object&&window,bke=typeof self=="object"&&self&&self.Object===Object&&self,xke=Cke||bke||Function("return this")(),wke=Object.prototype,Mke=wke.toString,Ske=Math.max,Eke=Math.min,SS=function(){return xke.Date.now()};function Oke(e,n,t){var r,i,o,s,a,h,g=0,C=!1,B=!1,k=!0;if(typeof e!="function")throw new TypeError(mQ);n=MF(n)||0,k4(t)&&(C=!!t.leading,B="maxWait"in t,o=B?Ske(MF(t.maxWait)||0,n):o,k="trailing"in t?!!t.trailing:k);function P(he){var V=r,ae=i;return r=i=void 0,g=he,s=e.apply(ae,V),s}function L(he){return g=he,a=setTimeout($,n),C?P(he):s}function J(he){var V=he-h,ae=he-g,ye=n-V;return B?Eke(ye,o-ae):ye}function N(he){var V=he-h,ae=he-g;return h===void 0||V>=n||V<0||B&&ae>=o}function $(){var he=SS();if(N(he))return q(he);a=setTimeout($,J(he))}function q(he){return a=void 0,k&&r?P(he):(r=i=void 0,s)}function oe(){a!==void 0&&clearTimeout(a),g=0,r=h=i=a=void 0}function ce(){return a===void 0?s:q(SS())}function me(){var he=SS(),V=N(he);if(r=arguments,i=this,h=he,V){if(a===void 0)return L(h);if(B)return a=setTimeout($,n),P(h)}return a===void 0&&(a=setTimeout($,n)),s}return me.cancel=oe,me.flush=ce,me}function Bke(e,n,t){var r=!0,i=!0;if(typeof e!="function")throw new TypeError(mQ);return k4(t)&&(r="leading"in t?!!t.leading:r,i="trailing"in t?!!t.trailing:i),Oke(e,n,{leading:r,maxWait:n,trailing:i})}function k4(e){var n=typeof e;return!!e&&(n=="object"||n=="function")}function kke(e){return!!e&&typeof e=="object"}function Ike(e){return typeof e=="symbol"||kke(e)&&Mke.call(e)==pke}function MF(e){if(typeof e=="number")return e;if(Ike(e))return wF;if(k4(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=k4(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=e.replace(mke,"");var t=yke.test(e);return t||vke.test(e)?_ke(e.slice(2),t?2:8):gke.test(e)?wF:+e}var Tke=Bke;const Kke=fa(Tke);var I4={exports:{}};I4.exports;(function(e,n){var t=200,r="__lodash_hash_undefined__",i=1,o=2,s=9007199254740991,a="[object Arguments]",h="[object Array]",g="[object AsyncFunction]",C="[object Boolean]",B="[object Date]",k="[object Error]",P="[object Function]",L="[object GeneratorFunction]",J="[object Map]",N="[object Number]",$="[object Null]",q="[object Object]",oe="[object Promise]",ce="[object Proxy]",me="[object RegExp]",he="[object Set]",V="[object String]",ae="[object Symbol]",ye="[object Undefined]",Oe="[object WeakMap]",De="[object ArrayBuffer]",He="[object DataView]",ke="[object Float32Array]",nt="[object Float64Array]",be="[object Int8Array]",Bt="[object Int16Array]",kt="[object Int32Array]",Yt="[object Uint8Array]",jt="[object Uint8ClampedArray]",Xe="[object Uint16Array]",rt="[object Uint32Array]",ot=/[\\^$.*+?()[\]{}|]/g,on=/^\[object .+?Constructor\]$/,gt=/^(?:0|[1-9]\d*)$/,at={};at[ke]=at[nt]=at[be]=at[Bt]=at[kt]=at[Yt]=at[jt]=at[Xe]=at[rt]=!0,at[a]=at[h]=at[De]=at[C]=at[He]=at[B]=at[k]=at[P]=at[J]=at[N]=at[q]=at[me]=at[he]=at[V]=at[Oe]=!1;var It=typeof window=="object"&&window&&window.Object===Object&&window,Lt=typeof self=="object"&&self&&self.Object===Object&&self,Me=It||Lt||Function("return this")(),fe=n&&!n.nodeType&&n,xe=fe&&!0&&e&&!e.nodeType&&e,Ue=xe&&xe.exports===fe,et=Ue&&It.process,it=function(){try{return et&&et.binding&&et.binding("util")}catch{}}(),bt=it&&it.isTypedArray;function Ut(R,se){for(var Le=-1,mt=R==null?0:R.length,Dn=0,en=[];++Le<mt;){var Sr=R[Le];se(Sr,Le,R)&&(en[Dn++]=Sr)}return en}function Rt(R,se){for(var Le=-1,mt=se.length,Dn=R.length;++Le<mt;)R[Dn+Le]=se[Le];return R}function pt(R,se){for(var Le=-1,mt=R==null?0:R.length;++Le<mt;)if(se(R[Le],Le,R))return!0;return!1}function rr(R,se){for(var Le=-1,mt=Array(R);++Le<R;)mt[Le]=se(Le);return mt}function mn(R){return function(se){return R(se)}}function vn(R,se){return R.has(se)}function Xn(R,se){return R==null?void 0:R[se]}function cr(R){var se=-1,Le=Array(R.size);return R.forEach(function(mt,Dn){Le[++se]=[Dn,mt]}),Le}function Mr(R,se){return function(Le){return R(se(Le))}}function Gr(R){var se=-1,Le=Array(R.size);return R.forEach(function(mt){Le[++se]=mt}),Le}var gr=Array.prototype,mi=Function.prototype,Se=Object.prototype,X=Me["__core-js_shared__"],H=mi.toString,Te=Se.hasOwnProperty,At=function(){var R=/[^.]+$/.exec(X&&X.keys&&X.keys.IE_PROTO||"");return R?"Symbol(src)_1."+R:""}(),St=Se.toString,Et=RegExp("^"+H.call(Te).replace(ot,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Nt=Ue?Me.Buffer:void 0,pn=Me.Symbol,Kn=Me.Uint8Array,En=Se.propertyIsEnumerable,m=gr.splice,Kt=pn?pn.toStringTag:void 0,Dr=Object.getOwnPropertySymbols,Fn=Nt?Nt.isBuffer:void 0,Fe=Mr(Object.keys,Object),de=qo(Me,"DataView"),Ce=qo(Me,"Map"),Be=qo(Me,"Promise"),ze=qo(Me,"Set"),tt=qo(Me,"WeakMap"),lt=qo(Object,"create"),ft=Wo(de),Ve=Wo(Ce),xt=Wo(Be),Xt=Wo(ze),Vt=Wo(tt),Ht=pn?pn.prototype:void 0,Qn=Ht?Ht.valueOf:void 0;function Mn(R){var se=-1,Le=R==null?0:R.length;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function or(){this.__data__=lt?lt(null):{},this.size=0}function ar(R){var se=this.has(R)&&delete this.__data__[R];return this.size-=se?1:0,se}function kr(R){var se=this.__data__;if(lt){var Le=se[R];return Le===r?void 0:Le}return Te.call(se,R)?se[R]:void 0}function jr(R){var se=this.__data__;return lt?se[R]!==void 0:Te.call(se,R)}function Lr(R,se){var Le=this.__data__;return this.size+=this.has(R)?0:1,Le[R]=lt&&se===void 0?r:se,this}Mn.prototype.clear=or,Mn.prototype.delete=ar,Mn.prototype.get=kr,Mn.prototype.has=jr,Mn.prototype.set=Lr;function Wr(R){var se=-1,Le=R==null?0:R.length;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function ir(){this.__data__=[],this.size=0}function ui(R){var se=this.__data__,Le=Cn(se,R);if(Le<0)return!1;var mt=se.length-1;return Le==mt?se.pop():m.call(se,Le,1),--this.size,!0}function Oi(R){var se=this.__data__,Le=Cn(se,R);return Le<0?void 0:se[Le][1]}function Yi(R){return Cn(this.__data__,R)>-1}function _o(R,se){var Le=this.__data__,mt=Cn(Le,R);return mt<0?(++this.size,Le.push([R,se])):Le[mt][1]=se,this}Wr.prototype.clear=ir,Wr.prototype.delete=ui,Wr.prototype.get=Oi,Wr.prototype.has=Yi,Wr.prototype.set=_o;function Jr(R){var se=-1,Le=R==null?0:R.length;for(this.clear();++se<Le;){var mt=R[se];this.set(mt[0],mt[1])}}function xo(){this.size=0,this.__data__={hash:new Mn,map:new(Ce||Wr),string:new Mn}}function Wa(R){var se=ia(this,R).delete(R);return this.size-=se?1:0,se}function Ba(R){return ia(this,R).get(R)}function bi(R){return ia(this,R).has(R)}function os(R,se){var Le=ia(this,R),mt=Le.size;return Le.set(R,se),this.size+=Le.size==mt?0:1,this}Jr.prototype.clear=xo,Jr.prototype.delete=Wa,Jr.prototype.get=Ba,Jr.prototype.has=bi,Jr.prototype.set=os;function hi(R){var se=-1,Le=R==null?0:R.length;for(this.__data__=new Jr;++se<Le;)this.add(R[se])}function Wn(R){return this.__data__.set(R,r),this}function eo(R){return this.__data__.has(R)}hi.prototype.add=hi.prototype.push=Wn,hi.prototype.has=eo;function io(R){var se=this.__data__=new Wr(R);this.size=se.size}function qi(){this.__data__=new Wr,this.size=0}function ve(R){var se=this.__data__,Le=se.delete(R);return this.size=se.size,Le}function Ye(R){return this.__data__.get(R)}function Jt(R){return this.__data__.has(R)}function sn(R,se){var Le=this.__data__;if(Le instanceof Wr){var mt=Le.__data__;if(!Ce||mt.length<t-1)return mt.push([R,se]),this.size=++Le.size,this;Le=this.__data__=new Jr(mt)}return Le.set(R,se),this.size=Le.size,this}io.prototype.clear=qi,io.prototype.delete=ve,io.prototype.get=Ye,io.prototype.has=Jt,io.prototype.set=sn;function Ft(R,se){var Le=ss(R),mt=!Le&&Uu(R),Dn=!Le&&!mt&&Do(R),en=!Le&&!mt&&!Dn&&Cl(R),Sr=Le||mt||Dn||en,Ur=Sr?rr(R.length,String):[],yr=Ur.length;for(var Ir in R)(se||Te.call(R,Ir))&&!(Sr&&(Ir=="length"||Dn&&(Ir=="offset"||Ir=="parent")||en&&(Ir=="buffer"||Ir=="byteLength"||Ir=="byteOffset")||lA(Ir,yr)))&&Ur.push(Ir);return Ur}function Cn(R,se){for(var Le=R.length;Le--;)if(Na(R[Le][0],se))return Le;return-1}function ur(R,se,Le){var mt=se(R);return ss(R)?mt:Rt(mt,Le(R))}function fi(R){return R==null?R===void 0?ye:$:Kt&&Kt in Object(R)?vs(R):uA(R)}function ei(R){return oa(R)&&fi(R)==a}function Zo(R,se,Le,mt,Dn){return R===se?!0:R==null||se==null||!oa(R)&&!oa(se)?R!==R&&se!==se:Fa(R,se,Le,mt,Zo,Dn)}function Fa(R,se,Le,mt,Dn,en){var Sr=ss(R),Ur=ss(se),yr=Sr?h:ma(R),Ir=Ur?h:ma(se);yr=yr==a?q:yr,Ir=Ir==a?q:Ir;var Bi=yr==q,fo=Ir==q,xi=yr==Ir;if(xi&&Do(R)){if(!Do(se))return!1;Sr=!0,Bi=!1}if(xi&&!Bi)return en||(en=new io),Sr||Cl(R)?ka(R,se,Le,mt,Dn,en):pa(R,se,yr,Le,mt,Dn,en);if(!(Le&i)){var Hr=Bi&&Te.call(R,"__wrapped__"),Hi=fo&&Te.call(se,"__wrapped__");if(Hr||Hi){var Io=Hr?R.value():R,wo=Hi?se.value():se;return en||(en=new io),Dn(Io,wo,Le,mt,en)}}return xi?(en||(en=new io),Zl(R,se,Le,mt,Dn,en)):!1}function Or(R){if(!Dl(R)||Lu(R))return!1;var se=vl(R)?Et:on;return se.test(Wo(R))}function gi(R){return oa(R)&&_l(R.length)&&!!at[fi(R)]}function Ks(R){if(!mu(R))return Fe(R);var se=[];for(var Le in Object(R))Te.call(R,Le)&&Le!="constructor"&&se.push(Le);return se}function ka(R,se,Le,mt,Dn,en){var Sr=Le&i,Ur=R.length,yr=se.length;if(Ur!=yr&&!(Sr&&yr>Ur))return!1;var Ir=en.get(R);if(Ir&&en.get(se))return Ir==se;var Bi=-1,fo=!0,xi=Le&o?new hi:void 0;for(en.set(R,se),en.set(se,R);++Bi<Ur;){var Hr=R[Bi],Hi=se[Bi];if(mt)var Io=Sr?mt(Hi,Hr,Bi,se,R,en):mt(Hr,Hi,Bi,R,se,en);if(Io!==void 0){if(Io)continue;fo=!1;break}if(xi){if(!pt(se,function(wo,Ga){if(!vn(xi,Ga)&&(Hr===wo||Dn(Hr,wo,Le,mt,en)))return xi.push(Ga)})){fo=!1;break}}else if(!(Hr===Hi||Dn(Hr,Hi,Le,mt,en))){fo=!1;break}}return en.delete(R),en.delete(se),fo}function pa(R,se,Le,mt,Dn,en,Sr){switch(Le){case He:if(R.byteLength!=se.byteLength||R.byteOffset!=se.byteOffset)return!1;R=R.buffer,se=se.buffer;case De:return!(R.byteLength!=se.byteLength||!en(new Kn(R),new Kn(se)));case C:case B:case N:return Na(+R,+se);case k:return R.name==se.name&&R.message==se.message;case me:case V:return R==se+"";case J:var Ur=cr;case he:var yr=mt&i;if(Ur||(Ur=Gr),R.size!=se.size&&!yr)return!1;var Ir=Sr.get(R);if(Ir)return Ir==se;mt|=o,Sr.set(R,se);var Bi=ka(Ur(R),Ur(se),mt,Dn,en,Sr);return Sr.delete(R),Bi;case ae:if(Qn)return Qn.call(R)==Qn.call(se)}return!1}function Zl(R,se,Le,mt,Dn,en){var Sr=Le&i,Ur=as(R),yr=Ur.length,Ir=as(se),Bi=Ir.length;if(yr!=Bi&&!Sr)return!1;for(var fo=yr;fo--;){var xi=Ur[fo];if(!(Sr?xi in se:Te.call(se,xi)))return!1}var Hr=en.get(R);if(Hr&&en.get(se))return Hr==se;var Hi=!0;en.set(R,se),en.set(se,R);for(var Io=Sr;++fo<yr;){xi=Ur[fo];var wo=R[xi],Ga=se[xi];if(mt)var Ll=Sr?mt(Ga,wo,xi,se,R,en):mt(wo,Ga,xi,R,se,en);if(!(Ll===void 0?wo===Ga||Dn(wo,Ga,Le,mt,en):Ll)){Hi=!1;break}Io||(Io=xi=="constructor")}if(Hi&&!Io){var Xl=R.constructor,ga=se.constructor;Xl!=ga&&"constructor"in R&&"constructor"in se&&!(typeof Xl=="function"&&Xl instanceof Xl&&typeof ga=="function"&&ga instanceof ga)&&(Hi=!1)}return en.delete(R),en.delete(se),Hi}function as(R){return ur(R,AA,Fu)}function ia(R,se){var Le=R.__data__;return Du(se)?Le[typeof se=="string"?"string":"hash"]:Le.map}function qo(R,se){var Le=Xn(R,se);return Or(Le)?Le:void 0}function vs(R){var se=Te.call(R,Kt),Le=R[Kt];try{R[Kt]=void 0;var mt=!0}catch{}var Dn=St.call(R);return mt&&(se?R[Kt]=Le:delete R[Kt]),Dn}var Fu=Dr?function(R){return R==null?[]:(R=Object(R),Ut(Dr(R),function(se){return En.call(R,se)}))}:go,ma=fi;(de&&ma(new de(new ArrayBuffer(1)))!=He||Ce&&ma(new Ce)!=J||Be&&ma(Be.resolve())!=oe||ze&&ma(new ze)!=he||tt&&ma(new tt)!=Oe)&&(ma=function(R){var se=fi(R),Le=se==q?R.constructor:void 0,mt=Le?Wo(Le):"";if(mt)switch(mt){case ft:return He;case Ve:return J;case xt:return oe;case Xt:return he;case Vt:return Oe}return se});function lA(R,se){return se=se??s,!!se&&(typeof R=="number"||gt.test(R))&&R>-1&&R%1==0&&R<se}function Du(R){var se=typeof R;return se=="string"||se=="number"||se=="symbol"||se=="boolean"?R!=="__proto__":R===null}function Lu(R){return!!At&&At in R}function mu(R){var se=R&&R.constructor,Le=typeof se=="function"&&se.prototype||Se;return R===Le}function uA(R){return St.call(R)}function Wo(R){if(R!=null){try{return H.call(R)}catch{}try{return R+""}catch{}}return""}function Na(R,se){return R===se||R!==R&&se!==se}var Uu=ei(function(){return arguments}())?ei:function(R){return oa(R)&&Te.call(R,"callee")&&!En.call(R,"callee")},ss=Array.isArray;function ll(R){return R!=null&&_l(R.length)&&!vl(R)}var Do=Fn||oo;function gu(R,se){return Zo(R,se)}function vl(R){if(!Dl(R))return!1;var se=fi(R);return se==P||se==L||se==g||se==ce}function _l(R){return typeof R=="number"&&R>-1&&R%1==0&&R<=s}function Dl(R){var se=typeof R;return R!=null&&(se=="object"||se=="function")}function oa(R){return R!=null&&typeof R=="object"}var Cl=bt?mn(bt):gi;function AA(R){return ll(R)?Ft(R):Ks(R)}function go(){return[]}function oo(){return!1}e.exports=gu})(I4,I4.exports);var Pke=I4.exports;const SO=fa(Pke);function ni(){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 ni=function(){return s},s}ni();class Fke{constructor(n=(ni().b[0][0]++,{})){an(this,"onSourcesChange");an(this,"onVectorLayersChange");an(this,"throttledAnalyzeVectorLayerFields");an(this,"_sources");an(this,"_vectorLayers");ni().f[0]++,ni().s[0]++,this.onSourcesChange=(ni().b[1][0]++,n.onSourcesChange||(ni().b[1][1]++,()=>{ni().f[1]++})),ni().s[1]++,this.onVectorLayersChange=(ni().b[2][0]++,n.onVectorLayersChange||(ni().b[2][1]++,()=>{ni().f[2]++})),ni().s[2]++,this._sources={},ni().s[3]++,this._vectorLayers={},ni().s[4]++,this.throttledAnalyzeVectorLayerFields=Kke(this.analyzeVectorLayerFields,5e3)}analyzeMap(n){ni().f[3]++;const t=(ni().s[5]++,{...this._sources});ni().s[6]++,Object.keys(n.style.sourceCaches).forEach(r=>{ni().f[4]++,ni().s[7]++,this._sources[r]=n.style.sourceCaches[r]._source.vectorLayerIds}),ni().s[8]++,SO(t,this._sources)?ni().b[3][1]++:(ni().b[3][0]++,ni().s[9]++,this.onSourcesChange(this._sources)),ni().s[10]++,this.throttledAnalyzeVectorLayerFields(n)}analyzeVectorLayerFields(n){ni().f[5]++;const t=(ni().s[11]++,{...this._vectorLayers});ni().s[12]++,Object.keys(this._sources).forEach(r=>{ni().f[6]++,ni().s[13]++,(ni().b[4][0]++,this._sources[r]||(ni().b[4][1]++,[])).forEach(i=>{ni().f[7]++;const o=(ni().s[14]++,ni().b[5][0]++,this._vectorLayers[i]||(ni().b[5][1]++,{})),s=(ni().s[15]++,{sourceLayer:i});ni().s[16]++,n.querySourceFeatures(r,s).forEach(a=>{ni().f[8]++,ni().s[17]++,Object.keys(a.properties).forEach(h=>{ni().f[9]++;const g=(ni().s[18]++,ni().b[6][0]++,o[h]||(ni().b[6][1]++,{}));ni().s[19]++,g[a.properties[h]]={},ni().s[20]++,o[h]=g})}),ni().s[21]++,this._vectorLayers[i]=o})}),ni().s[22]++,SO(t,this._vectorLayers)?ni().b[7][1]++:(ni().b[7][0]++,ni().s[23]++,this.onVectorLayersChange(this._vectorLayers))}get sources(){return ni().f[10]++,ni().s[24]++,this._sources}get vectorLayers(){return ni().f[11]++,ni().s[25]++,this._vectorLayers}}function Yo(){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 Yo=function(){return s},s}Yo();const G_=(Yo().s[0]++,{});function _k(){Yo().f[0]++;const e=(Yo().s[1]++,new URL(window.location.href).searchParams),n=(Yo().s[2]++,e.get("debug"));return Yo().s[3]++,n?(Yo().b[0][0]++,Yo().s[4]++,!!n.match(/^(|1|true)$/)):(Yo().b[0][1]++,Yo().s[5]++,!1)}function gQ(){return Yo().f[1]++,Yo().s[6]++,new Error("Debug not enabled, enable by appending '?debug' to your query string")}function Dke(e,n,t){if(Yo().f[2]++,Yo().s[7]++,_k())Yo().b[1][1]++;else throw Yo().b[1][0]++,Yo().s[8]++,gQ();Yo().s[9]++,G_[e]=(Yo().b[2][0]++,G_[e]||(Yo().b[2][1]++,{})),Yo().s[10]++,G_[e][n]=t}function Lke(e,n){if(Yo().f[3]++,Yo().s[11]++,_k())Yo().b[3][1]++;else throw Yo().b[3][0]++,Yo().s[12]++,gQ();if(Yo().s[13]++,Object.prototype.hasOwnProperty.call(G_,e))return Yo().b[4][0]++,Yo().s[14]++,G_[e][n];Yo().b[4][1]++}const O0=(Yo().s[15]++,{enabled:_k,get:Lke,set:Dke});Yo().s[16]++;window.debug=O0;function ie(){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 ie=function(){return s},s}ie();ie().s[0]++;window.Buffer=MH.Buffer;function Uke(e,n){ie().f[0]++;const t=(ie().s[1]++,e.match(/\.tilehosting\.com/)),r=(ie().s[2]++,e.match(/\.maptiler\.com/)),i=(ie().s[3]++,e.match(/\.thunderforest\.com/));if(ie().s[4]++,ie().b[1][0]++,t||(ie().b[1][1]++,r)){ie().b[0][0]++;const o=(ie().s[5]++,Iu.getAccessToken("openmaptiles",n,{allowFallback:!0}));if(ie().s[6]++,o)return ie().b[2][0]++,ie().s[7]++,e.replace("{key}",o);ie().b[2][1]++}else if(ie().b[0][1]++,ie().s[8]++,i){ie().b[3][0]++;const o=(ie().s[9]++,Iu.getAccessToken("thunderforest",n,{allowFallback:!0}));if(ie().s[10]++,o)return ie().b[4][0]++,ie().s[11]++,e.replace("{key}",o);ie().b[4][1]++}else return ie().b[3][1]++,ie().s[12]++,e}function SF(e,n,t){return ie().f[1]++,ie().s[13]++,{...e,$root:{...e.$root,[n]:{...e.$root[n],values:t}}}}class Rke extends Sn.Component{constructor(t){ie().f[2]++,ie().s[15]++;super(t);an(this,"revisionStore");an(this,"styleStore");an(this,"layerWatcher");an(this,"shortcutEl",(ie().s[14]++,null));an(this,"handleKeyPress",(ie().s[66]++,t=>{ie().f[18]++,ie().s[67]++,navigator.platform.toUpperCase().indexOf("MAC")>=0?(ie().b[18][0]++,ie().s[68]++,ie().b[20][0]++,t.metaKey&&(ie().b[20][1]++,t.shiftKey)&&(ie().b[20][2]++,t.keyCode===90)?(ie().b[19][0]++,ie().s[69]++,t.preventDefault(),ie().s[70]++,this.onRedo()):(ie().b[19][1]++,ie().s[71]++,ie().b[22][0]++,t.metaKey&&(ie().b[22][1]++,t.keyCode===90)?(ie().b[21][0]++,ie().s[72]++,t.preventDefault(),ie().s[73]++,this.onUndo()):ie().b[21][1]++)):(ie().b[18][1]++,ie().s[74]++,ie().b[24][0]++,t.ctrlKey&&(ie().b[24][1]++,t.keyCode===90)?(ie().b[23][0]++,ie().s[75]++,t.preventDefault(),ie().s[76]++,this.onUndo()):(ie().b[23][1]++,ie().s[77]++,ie().b[26][0]++,t.ctrlKey&&(ie().b[26][1]++,t.keyCode===89)?(ie().b[25][0]++,ie().s[78]++,t.preventDefault(),ie().s[79]++,this.onRedo()):ie().b[25][1]++))}));an(this,"onChangeMetadataProperty",(ie().s[90]++,(t,r)=>{ie().f[26]++,ie().s[91]++,ie().b[31][0]++,t==="maputnik:renderer"&&(ie().b[31][1]++,r!==xV(this.state.mapStyle,["metadata","maputnik:renderer"],"mlgljs"))?(ie().b[30][0]++,ie().s[92]++,this.setState({mapState:"map"})):ie().b[30][1]++;const i=(ie().s[93]++,{...this.state.mapStyle,metadata:{...this.state.mapStyle.metadata,[t]:r}});ie().s[94]++,this.onStyleChanged(i)}));an(this,"onStyleChanged",(ie().s[95]++,(t,r=(ie().b[32][0]++,{}))=>{ie().f[27]++,ie().s[96]++,r={save:!0,addRevision:!0,initialLoad:!1,...r},ie().s[97]++,r.initialLoad?(ie().b[33][0]++,ie().s[98]++,this.getInitialStateFromUrl(t)):ie().b[33][1]++;const i=(ie().s[99]++,ie().b[34][0]++,Sd(t)||(ie().b[34][1]++,[])),o=(ie().s[100]++,[]);if(ie().s[101]++,ie().b[36][0]++,t&&(ie().b[36][1]++,t.layers)){ie().b[35][0]++;const h=(ie().s[102]++,new window.Map);ie().s[103]++,t.layers.forEach((g,C)=>{if(ie().f[28]++,ie().s[104]++,ie().b[38][0]++,g.id===""&&(ie().b[38][1]++,h.has(g.id))){ie().b[37][0]++;const B=(ie().s[105]++,new Error(`layers[${C}]: duplicate layer id [empty_string], previously used`));ie().s[106]++,o.push(B)}else ie().b[37][1]++;ie().s[107]++,h.set(g.id,!0)})}else ie().b[35][1]++;const s=(ie().s[108]++,o.concat(i).map(h=>{ie().f[29]++;const g=(ie().s[109]++,h.message.match(/layers\[(\d+)\]: (duplicate layer id "?(.*)"?, previously used)/));if(ie().s[110]++,g){ie().b[39][0]++;const[,k,P]=(ie().s[111]++,g);return ie().s[112]++,{message:h.message,parsed:{type:"layer",data:{index:parseInt(k,10),key:"id",message:P}}}}else ie().b[39][1]++;const C=(ie().s[113]++,h.message.match(/layers\[(\d+)\]: (source "(?:.*)" not found)/));if(ie().s[114]++,C){ie().b[40][0]++;const[,k,P]=(ie().s[115]++,C);return ie().s[116]++,{message:h.message,parsed:{type:"layer",data:{index:parseInt(k,10),key:"source",message:P}}}}else ie().b[40][1]++;const B=(ie().s[117]++,h.message.match(/layers\[(\d+)\]\.(?:(\S+)\.)?(\S+): (.*)/));if(ie().s[118]++,B){ie().b[41][0]++;const[,k,P,L,J]=(ie().s[119]++,B),N=(ie().s[120]++,ie().b[43][0]++,P&&(ie().b[43][1]++,L)?(ie().b[42][0]++,[P,L].join(".")):(ie().b[42][1]++,L));return ie().s[121]++,{message:h.message,parsed:{type:"layer",data:{index:parseInt(k,10),key:N,message:J}}}}else return ie().b[41][1]++,ie().s[122]++,{message:h.message}}));let a=(ie().s[123]++,void 0);ie().s[124]++,i.length>0?(ie().b[44][0]++,ie().s[125]++,a=DI(t),ie().s[126]++,i.forEach(h=>{ie().f[30]++;const{message:g}=(ie().s[127]++,h);if(ie().s[128]++,g){ie().b[45][0]++,ie().s[129]++;try{const C=(ie().s[130]++,g.split(":")[0]),B=(ie().s[131]++,C.match(/^\S+?\[\d+\]\.[^[]+/)[0]);ie().s[132]++,H4.unset(a,B)}catch(C){ie().s[133]++,console.warn(C)}}else ie().b[45][1]++})):ie().b[44][1]++,ie().s[134]++,t.glyphs!==this.state.mapStyle.glyphs?(ie().b[46][0]++,ie().s[135]++,this.updateFonts(t.glyphs)):ie().b[46][1]++,ie().s[136]++,t.sprite!==this.state.mapStyle.sprite?(ie().b[47][0]++,ie().s[137]++,this.updateIcons(t.sprite)):ie().b[47][1]++,ie().s[138]++,r.addRevision?(ie().b[48][0]++,ie().s[139]++,this.revisionStore.addRevision(t)):ie().b[48][1]++,ie().s[140]++,r.save?(ie().b[49][0]++,ie().s[141]++,this.saveStyle(t)):ie().b[49][1]++,ie().s[142]++,this.setState({mapStyle:t,dirtyMapStyle:a,errors:s},()=>{ie().f[31]++,ie().s[143]++,this.fetchSources(),ie().s[144]++,this.setStateInUrl()})}));an(this,"onUndo",(ie().s[145]++,()=>{ie().f[32]++;const t=(ie().s[146]++,this.revisionStore.undo()),r=(ie().s[147]++,eke(this.state.mapStyle,t));ie().s[148]++,this.onStyleChanged(t,{addRevision:!1}),ie().s[149]++,this.setState({infos:r})}));an(this,"onRedo",(ie().s[150]++,()=>{ie().f[33]++;const t=(ie().s[151]++,this.revisionStore.redo()),r=(ie().s[152]++,tke(this.state.mapStyle,t));ie().s[153]++,this.onStyleChanged(t,{addRevision:!1}),ie().s[154]++,this.setState({infos:r})}));an(this,"onMoveLayer",(ie().s[155]++,t=>{ie().f[34]++;let{oldIndex:r,newIndex:i}=(ie().s[156]++,t),o=(ie().s[157]++,this.state.mapStyle.layers);if(ie().s[158]++,r=RI(r,0,o.length-1),ie().s[159]++,i=RI(i,0,o.length-1),ie().s[160]++,r===i){ie().b[50][0]++,ie().s[161]++;return}else ie().b[50][1]++;ie().s[162]++,r===this.state.selectedLayerIndex?(ie().b[51][0]++,ie().s[163]++,this.setState({selectedLayerIndex:i})):ie().b[51][1]++,ie().s[164]++,o=o.slice(0),ie().s[165]++,wV(o,r,i),ie().s[166]++,this.onLayersChange(o)}));an(this,"onLayersChange",(ie().s[167]++,t=>{ie().f[35]++;const r=(ie().s[168]++,{...this.state.mapStyle,layers:t});ie().s[169]++,this.onStyleChanged(r)}));an(this,"onLayerDestroy",(ie().s[170]++,t=>{ie().f[36]++;const r=(ie().s[171]++,this.state.mapStyle.layers),i=(ie().s[172]++,r.slice(0));ie().s[173]++,i.splice(t,1),ie().s[174]++,this.onLayersChange(i)}));an(this,"onLayerCopy",(ie().s[175]++,t=>{ie().f[37]++;const r=(ie().s[176]++,this.state.mapStyle.layers),i=(ie().s[177]++,r.slice(0)),o=(ie().s[178]++,DI(i[t]));ie().s[179]++,o.id=o.id+"-copy",ie().s[180]++,i.splice(t,0,o),ie().s[181]++,this.onLayersChange(i)}));an(this,"onLayerVisibilityToggle",(ie().s[182]++,t=>{ie().f[38]++;const r=(ie().s[183]++,this.state.mapStyle.layers),i=(ie().s[184]++,r.slice(0)),o=(ie().s[185]++,{...i[t]}),s=(ie().s[186]++,"layout"in o?(ie().b[52][0]++,{...o.layout}):(ie().b[52][1]++,{}));ie().s[187]++,s.visibility=s.visibility==="none"?(ie().b[53][0]++,"visible"):(ie().b[53][1]++,"none"),ie().s[188]++,o.layout=s,ie().s[189]++,i[t]=o,ie().s[190]++,this.onLayersChange(i)}));an(this,"onLayerIdChange",(ie().s[191]++,(t,r,i)=>{ie().f[39]++;const o=(ie().s[192]++,this.state.mapStyle.layers.slice(0));ie().s[193]++,o[t]={...o[t],id:i},ie().s[194]++,this.onLayersChange(o)}));an(this,"onLayerChanged",(ie().s[195]++,(t,r)=>{ie().f[40]++;const i=(ie().s[196]++,this.state.mapStyle.layers.slice(0));ie().s[197]++,i[t]=r,ie().s[198]++,this.onLayersChange(i)}));an(this,"setMapState",(ie().s[199]++,t=>{ie().f[41]++,ie().s[200]++,this.setState({mapState:t},this.setStateInUrl)}));an(this,"setDefaultValues",(ie().s[201]++,t=>{ie().f[42]++;const r=(ie().s[202]++,ie().b[54][0]++,t.metadata||(ie().b[54][1]++,{}));if(ie().s[203]++,r["maputnik:renderer"]===void 0){ie().b[55][0]++;const i=(ie().s[204]++,{...t,metadata:{...t.metadata,"maputnik:renderer":"mlgljs"}});return ie().s[205]++,i}else return ie().b[55][1]++,ie().s[206]++,t}));an(this,"openStyle",(ie().s[207]++,t=>{ie().f[43]++,ie().s[208]++,t=this.setDefaultValues(t),ie().s[209]++,this.onStyleChanged(t)}));an(this,"onMapChange",(ie().s[234]++,t=>{ie().f[49]++,ie().s[235]++,this.setState({mapView:t})}));an(this,"setStateInUrl",(ie().s[251]++,()=>{ie().f[53]++;const{mapState:t,mapStyle:r,isOpen:i}=(ie().s[252]++,this.state),{selectedLayerIndex:o}=(ie().s[253]++,this.state),s=(ie().s[254]++,new URL(location.href)),a=(ie().s[255]++,GI(JSON.stringify(r)));ie().s[256]++,s.searchParams.set("layer",`${a}~${o}`);const h=(ie().s[257]++,Object.entries(i).map(([g,C])=>(ie().f[54]++,ie().s[258]++,C===!0?(ie().b[67][0]++,g):(ie().b[67][1]++,null))).filter(g=>(ie().f[55]++,ie().s[259]++,g!==null)));ie().s[260]++,h.length>0?(ie().b[68][0]++,ie().s[261]++,s.searchParams.set("modal",h.join(","))):(ie().b[68][1]++,ie().s[262]++,s.searchParams.delete("modal")),ie().s[263]++,t==="map"?(ie().b[69][0]++,ie().s[264]++,s.searchParams.delete("view")):(ie().b[69][1]++,ie().s[265]++,t==="inspect"?(ie().b[70][0]++,ie().s[266]++,s.searchParams.set("view","inspect")):ie().b[70][1]++),ie().s[267]++,history.replaceState({selectedLayerIndex:o},"Maputnik",s.href)}));an(this,"getInitialStateFromUrl",(ie().s[268]++,t=>{ie().f[56]++;const r=(ie().s[269]++,new URL(location.href)),i=(ie().s[270]++,r.searchParams.get("modal"));if(ie().s[271]++,ie().b[72][0]++,i&&(ie().b[72][1]++,i!=="")){ie().b[71][0]++;const a=(ie().s[272]++,i.split(",")),h=(ie().s[273]++,{});ie().s[274]++,a.forEach(g=>{ie().f[57]++,ie().s[275]++,h[g]=!0}),ie().s[276]++,this.setState({isOpen:{...this.state.isOpen,...h}})}else ie().b[71][1]++;const o=(ie().s[277]++,r.searchParams.get("view"));ie().s[278]++,ie().b[74][0]++,o&&(ie().b[74][1]++,o!=="")?(ie().b[73][0]++,ie().s[279]++,this.setMapState(o)):ie().b[73][1]++;const s=(ie().s[280]++,r.searchParams.get("layer"));if(ie().s[281]++,s){ie().b[75][0]++,ie().s[282]++;try{const a=(ie().s[283]++,s.split("~")),[h,g]=(ie().s[284]++,[a[0],parseInt(a[1],10)]);let C=(ie().s[285]++,!0);if(ie().s[286]++,h!=="-"){ie().b[76][0]++;const B=(ie().s[287]++,GI(JSON.stringify(t)));ie().s[288]++,B!==parseInt(h,10)?(ie().b[77][0]++,ie().s[289]++,C=!1):ie().b[77][1]++}else ie().b[76][1]++;ie().s[290]++,C?(ie().b[78][0]++,ie().s[291]++,this.setState({selectedLayerIndex:g,selectedLayerOriginalId:t.layers[g].id})):ie().b[78][1]++}catch(a){ie().s[292]++,console.warn(a)}}else ie().b[75][1]++}));an(this,"onLayerSelect",(ie().s[293]++,t=>{ie().f[58]++,ie().s[294]++,this.setState({selectedLayerIndex:t,selectedLayerOriginalId:this.state.mapStyle.layers[t].id},this.setStateInUrl)}));an(this,"onChangeOpenlayersDebug",(ie().s[299]++,(t,r)=>{ie().f[61]++,ie().s[300]++,this.setState({openlayersDebugOptions:{...this.state.openlayersDebugOptions,[t]:r}})}));an(this,"onChangeMaplibreGlDebug",(ie().s[301]++,(t,r)=>{ie().f[62]++,ie().s[302]++,this.setState({maplibreGlDebugOptions:{...this.state.maplibreGlDebugOptions,[t]:r}})}));ie().s[16]++,nH(this),ie().s[17]++,this.revisionStore=new fke;const r=(ie().s[18]++,new URLSearchParams(window.location.search.substring(1)));let i=(ie().s[19]++,r.get("localport"));ie().s[20]++,ie().b[6][0]++,i==null&&(ie().b[6][1]++,window.location.port!=="80")&&(ie().b[6][2]++,window.location.port!=="443")?(ie().b[5][0]++,ie().s[21]++,i=window.location.port):ie().b[5][1]++,ie().s[22]++,this.styleStore=new hke({onLocalStyleChange:a=>(ie().f[3]++,ie().s[23]++,this.onStyleChanged(a,{save:!1})),port:i,host:r.get("localhost")});const o=(ie().s[24]++,[{key:"?",handler:()=>{ie().f[4]++,ie().s[25]++,this.toggleModal("shortcuts")}},{key:"o",handler:()=>{ie().f[5]++,ie().s[26]++,this.toggleModal("open")}},{key:"e",handler:()=>{ie().f[6]++,ie().s[27]++,this.toggleModal("export")}},{key:"d",handler:()=>{ie().f[7]++,ie().s[28]++,this.toggleModal("sources")}},{key:"s",handler:()=>{ie().f[8]++,ie().s[29]++,this.toggleModal("settings")}},{key:"i",handler:()=>{ie().f[9]++,ie().s[30]++,this.setMapState(this.state.mapState==="map"?(ie().b[7][0]++,"inspect"):(ie().b[7][1]++,"map"))}},{key:"m",handler:()=>{ie().f[10]++,ie().s[31]++,document.querySelector(".maplibregl-canvas").focus()}},{key:"!",handler:()=>{ie().f[11]++,ie().s[32]++,this.toggleModal("debug")}}]);ie().s[33]++,document.body.addEventListener("keyup",a=>{if(ie().f[12]++,ie().s[34]++,a.key==="Escape")ie().b[8][0]++,ie().s[35]++,a.target.blur(),ie().s[36]++,document.body.focus();else if(ie().b[8][1]++,ie().s[37]++,ie().b[10][0]++,this.state.isOpen.shortcuts||(ie().b[10][1]++,document.activeElement===document.body)){ie().b[9][0]++;const h=(ie().s[38]++,o.find(g=>(ie().f[13]++,ie().s[39]++,g.key===a.key)));ie().s[40]++,h?(ie().b[11][0]++,ie().s[41]++,this.setModal("shortcuts",!1),ie().s[42]++,h.handler()):ie().b[11][1]++}else ie().b[9][1]++});const s=(ie().s[43]++,J8e());ie().s[44]++,ie().b[13][0]++,s&&(ie().b[13][1]++,window.confirm("Load style from URL: "+s+" and discard current changes?"))?(ie().b[12][0]++,ie().s[45]++,this.styleStore=new xF,ie().s[46]++,AQ(s,a=>(ie().f[14]++,ie().s[47]++,this.onStyleChanged(a))),ie().s[48]++,vF()):(ie().b[12][1]++,ie().s[49]++,s?(ie().b[14][0]++,ie().s[50]++,vF()):ie().b[14][1]++,ie().s[51]++,this.styleStore.init(a=>{ie().f[15]++,ie().s[52]++,a?(ie().b[15][0]++,ie().s[53]++,console.log("Falling back to local storage for storing styles"),ie().s[54]++,this.styleStore=new xF):ie().b[15][1]++,ie().s[55]++,this.styleStore.latestStyle(h=>(ie().f[16]++,ie().s[56]++,this.onStyleChanged(h,{initialLoad:!0}))),ie().s[57]++,O0.enabled()?(ie().b[16][0]++,ie().s[58]++,O0.set("maputnik","styleStore",this.styleStore),ie().s[59]++,O0.set("maputnik","revisionStore",this.revisionStore)):ie().b[16][1]++})),ie().s[60]++,O0.enabled()?(ie().b[17][0]++,ie().s[61]++,O0.set("maputnik","revisionStore",this.revisionStore),ie().s[62]++,O0.set("maputnik","styleStore",this.styleStore)):ie().b[17][1]++,ie().s[63]++,this.state={errors:[],infos:[],mapStyle:Iu.emptyStyle,selectedLayerIndex:0,sources:{},vectorLayers:{},mapState:"map",spec:Ea,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}},ie().s[64]++,this.layerWatcher=new Fke({onVectorLayersChange:a=>(ie().f[17]++,ie().s[65]++,this.setState({vectorLayers:a}))})}componentDidMount(){ie().f[19]++,ie().s[80]++,window.addEventListener("keydown",this.handleKeyPress)}componentWillUnmount(){ie().f[20]++,ie().s[81]++,window.removeEventListener("keydown",this.handleKeyPress)}saveStyle(t){ie().f[21]++,ie().s[82]++,this.styleStore.save(t)}updateFonts(t){ie().f[22]++;const r=(ie().s[83]++,ie().b[27][0]++,this.state.mapStyle.metadata||(ie().b[27][1]++,{})),i=(ie().s[84]++,ie().b[28][0]++,r["maputnik:openmaptiles_access_token"]||(ie().b[28][1]++,LG.openmaptiles)),o=(ie().s[85]++,typeof t=="string"?(ie().b[29][0]++,t.replace("{key}",i)):(ie().b[29][1]++,t));ie().s[86]++,Z8e(o,s=>{ie().f[23]++,ie().s[87]++,this.setState({spec:SF(this.state.spec,"glyphs",s)})})}updateIcons(t){ie().f[24]++,ie().s[88]++,X8e(t,r=>{ie().f[25]++,ie().s[89]++,this.setState({spec:SF(this.state.spec,"sprite",r)})})}fetchSources(){ie().f[44]++;const t=(ie().s[210]++,{});ie().s[211]++;for(const[r,i]of Object.entries(this.state.mapStyle.sources))if(ie().s[212]++,ie().b[57][0]++,!Object.prototype.hasOwnProperty.call(this.state.sources,r)&&(ie().b[57][1]++,i.type==="vector")&&(ie().b[57][2]++,Object.prototype.hasOwnProperty.call(i,"url"))){ie().b[56][0]++,ie().s[213]++,t[r]={type:i.type,layers:[]};let o=(ie().s[214]++,i.url);ie().s[215]++;try{ie().s[216]++,o=Uke(o,this.state.mapStyle)}catch(s){ie().s[217]++,console.warn("Failed to setFetchAccessToken: ",s)}ie().s[218]++,fetch(o,{mode:"cors"}).then(s=>(ie().f[45]++,ie().s[219]++,s.json())).then(s=>{if(ie().f[46]++,ie().s[220]++,Object.prototype.hasOwnProperty.call(s,"vector_layers"))ie().b[58][1]++;else{ie().b[58][0]++,ie().s[221]++;return}const a=(ie().s[222]++,Object.assign({},{[r]:this.state.sources[r]}));ie().s[223]++;for(const h of s.vector_layers)ie().s[224]++,a[r].layers.push(h.id);ie().s[225]++,console.debug("Updating source: "+r),ie().s[226]++,this.setState({sources:a})}).catch(s=>{ie().f[47]++,ie().s[227]++,console.error("Failed to process sources for '%s'",o,s)})}else ie().b[56][1]++,ie().s[228]++,t[r]=(ie().b[59][0]++,this.state.sources[r]||(ie().b[59][1]++,this.state.mapStyle.sources[r]));ie().s[229]++,SO(this.state.sources,t)?ie().b[60][1]++:(ie().b[60][0]++,ie().s[230]++,console.debug("Setting sources"),ie().s[231]++,this.setState({sources:t}))}_getRenderer(){ie().f[48]++;const t=(ie().s[232]++,ie().b[61][0]++,this.state.mapStyle.metadata||(ie().b[61][1]++,{}));return ie().s[233]++,ie().b[62][0]++,t["maputnik:renderer"]||(ie().b[62][1]++,"mlgljs")}mapRenderer(){ie().f[50]++;const{mapStyle:t,dirtyMapStyle:r}=(ie().s[236]++,this.state),i=(ie().s[237]++,{mapStyle:(ie().b[63][0]++,r||(ie().b[63][1]++,t)),replaceAccessTokens:g=>(ie().f[51]++,ie().s[238]++,Iu.replaceAccessTokens(g,{allowFallback:!0})),onDataChange:g=>{ie().f[52]++,ie().s[239]++,this.layerWatcher.analyzeMap(g.map),ie().s[240]++,this.fetchSources()}}),o=(ie().s[241]++,this._getRenderer());let s;ie().s[242]++,o==="ol"?(ie().b[64][0]++,ie().s[243]++,s=G.jsx(uW,{...i,onChange:this.onMapChange,debugToolbox:this.state.openlayersDebugOptions.debugToolbox,onLayerSelect:this.onLayerSelect})):(ie().b[64][1]++,ie().s[244]++,s=G.jsx(UR,{...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;ie().s[245]++,this.state.mapState.match(/^filter-/)?(ie().b[65][0]++,ie().s[246]++,a=this.state.mapState.replace(/^filter-/,"")):ie().b[65][1]++;const h=(ie().s[247]++,{});return ie().s[248]++,a?(ie().b[66][0]++,ie().s[249]++,h.filter=`url('#${a}')`):ie().b[66][1]++,ie().s[250]++,G.jsx("div",{style:h,className:"maputnik-map__container","data-wd-key":"maplibre:container",children:s})}setModal(t,r){ie().f[59]++,ie().s[295]++,ie().b[80][0]++,t==="survey"&&(ie().b[80][1]++,r===!1)?(ie().b[79][0]++,ie().s[296]++,localStorage.setItem("survey","")):ie().b[79][1]++,ie().s[297]++,this.setState({isOpen:{...this.state.isOpen,[t]:r}},this.setStateInUrl)}toggleModal(t){ie().f[60]++,ie().s[298]++,this.setModal(t,!this.state.isOpen[t])}render(){ie().f[63]++;const t=(ie().s[303]++,ie().b[81][0]++,this.state.mapStyle.layers||(ie().b[81][1]++,[])),r=(ie().s[304]++,t.length>0?(ie().b[82][0]++,t[this.state.selectedLayerIndex]):(ie().b[82][1]++,void 0)),i=(ie().s[305]++,G.jsx(BOe,{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=(ie().s[306]++,G.jsx(Jfe,{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=(ie().s[307]++,r?(ie().b[83][0]++,G.jsx(hO,{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)):(ie().b[83][1]++,void 0)),a=(ie().s[308]++,this.state.errors.length+this.state.infos.length>0?(ie().b[84][0]++,G.jsx(PG,{currentLayer:r,selectedLayerIndex:this.state.selectedLayerIndex,onLayerSelect:this.onLayerSelect,mapStyle:this.state.mapStyle,errors:this.state.errors,infos:this.state.infos})):(ie().b[84][1]++,void 0)),h=(ie().s[309]++,G.jsxs("div",{children:[G.jsx(BBe,{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}),G.jsx(SBe,{ref:g=>(ie().f[64]++,ie().s[310]++,this.shortcutEl=g),isOpen:this.state.isOpen.shortcuts,onOpenToggle:this.toggleModal.bind(this,"shortcuts")}),G.jsx(KOe,{mapStyle:this.state.mapStyle,onStyleChanged:this.onStyleChanged,onChangeMetadataProperty:this.onChangeMetadataProperty,isOpen:this.state.isOpen.settings,onOpenToggle:this.toggleModal.bind(this,"settings")}),G.jsx(YOe,{mapStyle:this.state.mapStyle,onStyleChanged:this.onStyleChanged,isOpen:this.state.isOpen.export,onOpenToggle:this.toggleModal.bind(this,"export")}),G.jsx(MBe,{isOpen:this.state.isOpen.open,onStyleOpen:this.openStyle,onOpenToggle:this.toggleModal.bind(this,"open")}),G.jsx(lBe,{mapStyle:this.state.mapStyle,onStyleChanged:this.onStyleChanged,isOpen:this.state.isOpen.sources,onOpenToggle:this.toggleModal.bind(this,"sources")}),G.jsx(OBe,{isOpen:this.state.isOpen.survey,onOpenToggle:this.toggleModal.bind(this,"survey")})]}));return ie().s[311]++,G.jsx(KG,{toolbar:i,layerList:o,layerEditor:s,map:this.mapRenderer(),bottom:a,modals:h})}}WL.render(G.jsx(TS.Provider,{value:{className:"react-icons"},children:G.jsx(Rke,{})}),document.querySelector("#app"));document.querySelector(".loading").style.display="none";
//# sourceMappingURL=index-xcIkDGFp.js.map