(()=>{var xt=function(O){var D={};function o(_){if(D[_])return D[_].exports;var e=D[_]={i:_,l:!1,exports:{}};return O[_].call(e.exports,e,e.exports,o),e.l=!0,e.exports}return o.m=O,o.c=D,o.d=function(_,e,b){o.o(_,e)||Object.defineProperty(_,e,{enumerable:!0,get:b})},o.r=function(_){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(_,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(_,"__esModule",{value:!0})},o.t=function(_,e){if(1&e&&(_=o(_)),8&e||4&e&&typeof _=="object"&&_&&_.__esModule)return _;var b=Object.create(null);if(o.r(b),Object.defineProperty(b,"default",{enumerable:!0,value:_}),2&e&&typeof _!="string")for(var g in _)o.d(b,g,function(f){return _[f]}.bind(null,g));return b},o.n=function(_){var e=_&&_.__esModule?function(){return _.default}:function(){return _};return o.d(e,"a",e),e},o.o=function(_,e){return Object.prototype.hasOwnProperty.call(_,e)},o.p="",o(o.s=131)}([function(O,D,o){function _(u,i){return function(a){if(Array.isArray(a))return a}(u)||function(a,n){var t=[],r=!0,l=!1,d=void 0;try{for(var h,m=a[Symbol.iterator]();!(r=(h=m.next()).done)&&(t.push(h.value),!n||t.length!==n);r=!0);}catch(S){l=!0,d=S}finally{try{r||m.return==null||m.return()}finally{if(l)throw d}}return t}(u,i)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function e(u){return(e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(i){return typeof i}:function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i})(u)}var b=o(73),g=o(35);o(3),D.easeCubicInOut=function(u){if(u<=0)return 0;if(u>=1)return 1;var i=u*u,a=i*u;return 4*(u<.5?a:3*(u-i)+a-.75)},D.bezier=function(u,i,a,n){var t=new b(u,i,a,n);return function(r){return t.solve(r)}},D.ease=D.bezier(.25,.1,.25,1),D.clamp=function(u,i,a){return Math.min(a,Math.max(i,u))},D.wrap=function(u,i,a){var n=a-i,t=((u-i)%n+n)%n+i;return t===i?a:t},D.asyncAll=function(u,i,a){if(!u.length)return a(null,[]);var n=u.length,t=new Array(u.length),r=null;u.forEach(function(l,d){i(l,function(h,m){h&&(r=h),t[d]=m,--n==0&&a(r,t)})})},D.values=function(u){var i=[];for(var a in u)i.push(u[a]);return i},D.keysDifference=function(u,i){var a=[];for(var n in u)n in i||a.push(n);return a},D.extend=function(u){for(var i=arguments.length,a=new Array(i>1?i-1:0),n=1;n=0)return!0;return!1};var c={};D.warnOnce=function(u){c[u]||(typeof console<"u"&&console.warn(u),c[u]=!0)},D.isCounterClockwise=function(u,i,a){return(a.y-u.y)*(i.x-u.x)>(i.y-u.y)*(a.x-u.x)},D.calculateSignedArea=function(u){for(var i,a,n=0,t=0,r=u.length,l=r-1;t0||Math.abs(i.y-a.y)>0)&&Math.abs(D.calculateSignedArea(u))>.01},D.sphericalToCartesian=function(u){var i=_(u,3),a=i[0],n=i[1],t=i[2];return n+=90,n*=Math.PI/180,t*=Math.PI/180,{x:a*Math.cos(n)*Math.sin(t),y:a*Math.sin(n)*Math.sin(t),z:a*Math.cos(t)}},D.parseCacheControl=function(u){var i={};if(u.replace(/(?:^|(?:\s*\,\s*))([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)(?:\=(?:([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)|(?:\"((?:[^"\\]|\\.)*)\")))?/g,function(n,t,r,l){var d=r||l;return i[t]=!d||d.toLowerCase(),""}),i["max-age"]){var a=parseInt(i["max-age"],10);isNaN(a)?delete i["max-age"]:i["max-age"]=a}return i}},function(O,D,o){"use strict";(function(_){var e=o(135);/*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */function b(k,v){if(k===v)return 0;for(var x=k.length,T=v.length,E=0,C=Math.min(x,T);E=0;J--)if(X[J]!==R[J])return!1;for(J=X.length-1;J>=0;J--)if(W=X[J],!y(C[W],z[W],P,B))return!1;return!0}(k,v,x,T))}return x?k===v:k==v}function s(k){return Object.prototype.toString.call(k)=="[object Arguments]"}function p(k,v){if(!k||!v)return!1;if(Object.prototype.toString.call(v)=="[object RegExp]")return v.test(k);try{if(k instanceof v)return!0}catch{}return!Error.isPrototypeOf(v)&&v.call({},k)===!0}function w(k,v,x,T){var E;if(typeof v!="function")throw new TypeError('"block" argument must be a function');typeof x=="string"&&(T=x,x=null),E=function(P){var B;try{P()}catch(F){B=F}return B}(v),T=(x&&x.name?" ("+x.name+").":".")+(T?" "+T:"."),k&&!E&&m(E,x,"Missing expected exception"+T);var C=typeof T=="string",z=!k&&E&&!x;if((!k&&f.isError(E)&&C&&p(E,x)||z)&&m(E,x,"Got unwanted exception"+T),k&&E&&x&&!p(E,x)||!k&&E)throw E}t.AssertionError=function(k){this.name="AssertionError",this.actual=k.actual,this.expected=k.expected,this.operator=k.operator,k.message?(this.message=k.message,this.generatedMessage=!1):(this.message=function(P){return d(h(P.actual),128)+" "+P.operator+" "+d(h(P.expected),128)}(this),this.generatedMessage=!0);var v=k.stackStartFunction||m;if(Error.captureStackTrace)Error.captureStackTrace(this,v);else{var x=new Error;if(x.stack){var T=x.stack,E=l(v),C=T.indexOf(` `+E);if(C>=0){var z=T.indexOf(` `,C+1);T=T.substring(z+1)}this.stack=T}}},f.inherits(t.AssertionError,Error),t.fail=m,t.ok=S,t.equal=function(k,v,x){k!=v&&m(k,v,x,"==",t.equal)},t.notEqual=function(k,v,x){k==v&&m(k,v,x,"!=",t.notEqual)},t.deepEqual=function(k,v,x){y(k,v,!1)||m(k,v,x,"deepEqual",t.deepEqual)},t.deepStrictEqual=function(k,v,x){y(k,v,!0)||m(k,v,x,"deepStrictEqual",t.deepStrictEqual)},t.notDeepEqual=function(k,v,x){y(k,v,!1)&&m(k,v,x,"notDeepEqual",t.notDeepEqual)},t.notDeepStrictEqual=function k(v,x,T){y(v,x,!0)&&m(v,x,T,"notDeepStrictEqual",k)},t.strictEqual=function(k,v,x){k!==v&&m(k,v,x,"===",t.strictEqual)},t.notStrictEqual=function(k,v,x){k===v&&m(k,v,x,"!==",t.notStrictEqual)},t.throws=function(k,v,x){w(!0,k,v,x)},t.doesNotThrow=function(k,v,x){w(!1,k,v,x)},t.ifError=function(k){if(k)throw k},t.strict=e(function k(v,x){v||m(v,!0,x,"==",k)},t,{equal:t.strictEqual,deepEqual:t.deepStrictEqual,notEqual:t.notStrictEqual,notDeepEqual:t.notDeepStrictEqual}),t.strict.strict=t.strict;var A=Object.keys||function(k){var v=[];for(var x in k)c.call(k,x)&&v.push(x);return v}}).call(this,o(134))},function(O,D,o){var _=o(5),e=_.performance&&_.performance.now?_.performance.now.bind(_.performance):Date.now.bind(Date),b=_.requestAnimationFrame||_.mozRequestAnimationFrame||_.webkitRequestAnimationFrame||_.msRequestAnimationFrame,g=_.cancelAnimationFrame||_.mozCancelAnimationFrame||_.webkitCancelAnimationFrame||_.msCancelAnimationFrame;O.exports={now:e,frame:function(c){return b(c)},cancelFrame:function(c){return g(c)},getImageData:function(c){var u=_.document.createElement("canvas"),i=u.getContext("2d");if(!i)throw new Error("failed to create canvas 2d context");return u.width=c.width,u.height=c.height,i.drawImage(c,0,0,c.width,c.height),i.getImageData(0,0,c.width,c.height)},hardwareConcurrency:_.navigator.hardwareConcurrency||4,get devicePixelRatio(){return _.devicePixelRatio},supportsWebp:!1};var f=_.document.createElement("img");f.onload=function(){O.exports.supportsWebp=!0},f.src="data:image/webp;base64,UklGRh4AAABXRUJQVlA4TBEAAAAvAQAAAAfQ//73v/+BiOh/AAA="},function(O,D,o){"use strict";function _(e,b){this.x=e,this.y=b}O.exports=_,_.prototype={clone:function(){return new _(this.x,this.y)},add:function(e){return this.clone()._add(e)},sub:function(e){return this.clone()._sub(e)},multByPoint:function(e){return this.clone()._multByPoint(e)},divByPoint:function(e){return this.clone()._divByPoint(e)},mult:function(e){return this.clone()._mult(e)},div:function(e){return this.clone()._div(e)},rotate:function(e){return this.clone()._rotate(e)},rotateAround:function(e,b){return this.clone()._rotateAround(e,b)},matMult:function(e){return this.clone()._matMult(e)},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(e){return this.x===e.x&&this.y===e.y},dist:function(e){return Math.sqrt(this.distSqr(e))},distSqr:function(e){var b=e.x-this.x,g=e.y-this.y;return b*b+g*g},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(e){return Math.atan2(this.y-e.y,this.x-e.x)},angleWith:function(e){return this.angleWithSep(e.x,e.y)},angleWithSep:function(e,b){return Math.atan2(this.x*b-this.y*e,this.x*e+this.y*b)},_matMult:function(e){var b=e[0]*this.x+e[1]*this.y,g=e[2]*this.x+e[3]*this.y;return this.x=b,this.y=g,this},_add:function(e){return this.x+=e.x,this.y+=e.y,this},_sub:function(e){return this.x-=e.x,this.y-=e.y,this},_mult:function(e){return this.x*=e,this.y*=e,this},_div:function(e){return this.x/=e,this.y/=e,this},_multByPoint:function(e){return this.x*=e.x,this.y*=e.y,this},_divByPoint:function(e){return this.x/=e.x,this.y/=e.y,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var e=this.y;return this.y=this.x,this.x=-e,this},_rotate:function(e){var b=Math.cos(e),g=Math.sin(e),f=b*this.x-g*this.y,c=g*this.x+b*this.y;return this.x=f,this.y=c,this},_rotateAround:function(e,b){var g=Math.cos(e),f=Math.sin(e),c=b.x+g*(this.x-b.x)-f*(this.y-b.y),u=b.y+f*(this.x-b.x)+g*(this.y-b.y);return this.x=c,this.y=u,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},_.convert=function(e){return e instanceof _?e:Array.isArray(e)?new _(e[0],e[1]):e}},function(O,D,o){function _(v,x){if(!(v instanceof x))throw new TypeError("Cannot call a class as a function")}function e(v,x){for(var T=0;Tthis.end)return this.prior=null,E;if(this.value.isDataDriven())return this.prior=null,E;if(TC.zoomHistory.lastIntegerZoom?{from:x,to:T,fromScale:2,toScale:1,t:P+(1-P)*B}:{from:E,to:T,fromScale:.5,toScale:1,t:1-(1-B)*P}}},{key:"interpolate",value:function(x){return x}}]),v}(),k=function(){function v(x){_(this,v),this.specification=x}return b(v,[{key:"possiblyEvaluate",value:function(){}},{key:"interpolate",value:function(){}}]),v}();t("DataDrivenProperty",w),t("DataConstantProperty",p),t("CrossFadedProperty",A),t("HeatmapColorProperty",k),O.exports={PropertyValue:r,Transitionable:d,Transitioning:m,Layout:S,PossiblyEvaluatedPropertyValue:y,PossiblyEvaluated:s,DataConstantProperty:p,DataDrivenProperty:w,CrossFadedProperty:A,HeatmapColorProperty:k,Properties:function v(x){for(var T in _(this,v),this.properties=x,this.defaultPropertyValues={},this.defaultTransitionablePropertyValues={},this.defaultTransitioningPropertyValues={},this.defaultPossiblyEvaluatedValues={},x){var E=x[T],C=this.defaultPropertyValues[T]=new r(E,void 0),z=this.defaultTransitionablePropertyValues[T]=new l(E);this.defaultTransitioningPropertyValues[T]=z.untransitioned(),this.defaultPossiblyEvaluatedValues[T]=C.possiblyEvaluate({})}}}},function(O,D){O.exports=self},function(O,D){O.exports=8192},function(O,D){O.exports=function(o,_,e){this.message=(o?"".concat(o,": "):"")+e,_!=null&&_.__line__&&(this.line=_.__line__)}},function(O,D){var o={kind:"null"},_={kind:"number"},e={kind:"string"},b={kind:"boolean"},g={kind:"color"},f={kind:"object"},c={kind:"value"};function u(n,t){return{kind:"array",itemType:n,N:t}}function i(n){if(n.kind==="array"){var t=i(n.itemType);return typeof n.N=="number"?"array<".concat(t,", ").concat(n.N,">"):n.itemType.kind==="value"?"array":"array<".concat(t,">")}return n.kind}var a=[o,_,e,b,g,f,u(c)];O.exports={NullType:o,NumberType:_,StringType:e,BooleanType:b,ColorType:g,ObjectType:f,ValueType:c,array:u,ErrorType:{kind:"error"},toString:i,checkSubtype:function n(t,r){if(r.kind==="error")return null;if(t.kind==="array"){if(r.kind==="array"&&!n(t.itemType,r.itemType)&&(typeof t.N!="number"||t.N===r.N))return null}else{if(t.kind===r.kind)return null;if(t.kind==="value"){for(var l=0,d=a;l0||this._oneTimeListeners&&this._oneTimeListeners[n]&&this._oneTimeListeners[n].length>0||this._eventedParent&&this._eventedParent.listens(n)}},{key:"setEventedParent",value:function(n,t){return this._eventedParent=n,this._eventedParentData=t,this}}])&&_(u.prototype,i),a&&_(u,a),c}();O.exports=f},function(O,D,o){function _(S){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(y){return typeof y}:function(y){return y&&typeof Symbol=="function"&&y.constructor===Symbol&&y!==Symbol.prototype?"symbol":typeof y})(S)}var e=o(1),b=o(102),g=o(12),f=o(30),c=f.StylePropertyFunction,u=f.StyleExpression,i=f.StyleExpressionWithErrorHandling,a=f.ZoomDependentExpression,n=f.ZoomConstantExpression,t=o(42).CompoundExpression,r=o(90),l=o(5).ImageData,d={};function h(S,y){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};e(!d[S],"".concat(S," is already registered.")),Object.defineProperty(y,"_classRegistryKey",{value:S,writeable:!1}),d[S]={klass:y,omit:s.omit||[],shallow:s.shallow||[]}}for(var m in h("Object",Object),b.serialize=function(S,y){var s=S.toArrayBuffer();return y&&y.push(s),s},b.deserialize=function(S){return new b(S)},h("Grid",b),h("Color",g),h("StylePropertyFunction",c),h("StyleExpression",u,{omit:["_evaluator"]}),h("StyleExpressionWithErrorHandling",i,{omit:["_evaluator"]}),h("ZoomDependentExpression",a),h("ZoomConstantExpression",n),h("CompoundExpression",t,{omit:["_evaluate"]}),r)r[m]._classRegistryKey||h("Expression_".concat(m),r[m]);O.exports={register:h,serialize:function S(y,s){if(y==null||typeof y=="boolean"||typeof y=="number"||typeof y=="string"||y instanceof Boolean||y instanceof Number||y instanceof String||y instanceof Date||y instanceof RegExp)return y;if(y instanceof ArrayBuffer)return s&&s.push(y),y;if(ArrayBuffer.isView(y)){var p=y;return s&&s.push(p.buffer),p}if(y instanceof l)return s&&s.push(y.data.buffer),y;if(Array.isArray(y)){var w=[],A=!0,k=!1,v=void 0;try{for(var x,T=y[Symbol.iterator]();!(A=(x=T.next()).done);A=!0){var E=x.value;w.push(S(E,s))}}catch(Z){k=!0,v=Z}finally{try{A||T.return==null||T.return()}finally{if(k)throw v}}return w}if(_(y)==="object"){var C=y.constructor,z=C._classRegistryKey;if(!z)throw new Error("can't serialize object of unregistered class");e(d[z]);var P={};if(C.serialize)P._serialized=C.serialize(y,s);else for(var B in y)if(y.hasOwnProperty(B)&&!(d[z].omit.indexOf(B)>=0)){var F=y[B];P[B]=d[z].shallow.indexOf(B)>=0?F:S(F,s)}return{name:z,properties:P}}throw new Error("can't serialize object of type ".concat(_(y)))},deserialize:function S(y){if(y==null||typeof y=="boolean"||typeof y=="number"||typeof y=="string"||y instanceof Boolean||y instanceof Number||y instanceof String||y instanceof Date||y instanceof RegExp||y instanceof ArrayBuffer||ArrayBuffer.isView(y)||y instanceof l)return y;if(Array.isArray(y))return y.map(function(E){return S(E)});if(_(y)==="object"){var s=y,p=s.name,w=s.properties;if(!p)throw new Error("can't deserialize object of anonymous class");var A=d[p].klass;if(!A)throw new Error("can't deserialize unregistered class ".concat(p));if(A.deserialize)return A.deserialize(w._serialized);for(var k=Object.create(A.prototype),v=0,x=Object.keys(w);v=0?w[T]:S(w[T])}return k}throw new Error("can't deserialize object of type ".concat(_(y)))}}},function(O,D,o){function _(g,f){for(var c=0;c3&&arguments[3]!==void 0?arguments[3]:1;(function(r,l){if(!(r instanceof l))throw new TypeError("Cannot call a class as a function")})(this,g),this.r=i,this.g=a,this.b=n,this.a=t}var f,c,u;return f=g,u=[{key:"parse",value:function(i){if(i){if(i instanceof g)return i;if(typeof i=="string"){var a=e(i);if(a)return new g(a[0]/255*a[3],a[1]/255*a[3],a[2]/255*a[3],a[3])}}}}],(c=[{key:"toString",value:function(){var i=this,a=[this.r,this.g,this.b].map(function(n){return Math.round(255*n/i.a)});return"rgba(".concat(a.concat(this.a).join(","),")")}}])&&_(f.prototype,c),u&&_(f,u),g}();b.black=new b(0,0,0,1),b.white=new b(1,1,1,1),b.transparent=new b(0,0,0,0),O.exports=b},function(O,D,o){O.exports=o(140)},function(O,D,o){function _(I){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(j){return typeof j}:function(j){return j&&typeof Symbol=="function"&&j.constructor===Symbol&&j!==Symbol.prototype?"symbol":typeof j})(I)}function e(I,j){if(!(I instanceof j))throw new TypeError("Cannot call a class as a function")}function b(I,j){for(var M=0;M"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}}()?Reflect.construct:function(d,h,m){var S=[null];S.push.apply(S,h);var y=new(Function.bind.apply(d,S));return m&&f(y,m.prototype),y}).apply(null,arguments)}function f(t,r){return(f=Object.setPrototypeOf||function(l,d){return l.__proto__=d,l})(t,r)}function c(t){return(c=Object.setPrototypeOf?Object.getPrototypeOf:function(r){return r.__proto__||Object.getPrototypeOf(r)})(t)}var u=o(5),i={Unknown:"Unknown",Style:"Style",Source:"Source",Tile:"Tile",Glyphs:"Glyphs",SpriteImage:"SpriteImage",SpriteJSON:"SpriteJSON",Image:"Image"};D.ResourceType=i,typeof Object.freeze=="function"&&Object.freeze(i);var a=function(t){function r(l,d){var h;return function(m,S){if(!(m instanceof S))throw new TypeError("Cannot call a class as a function")}(this,r),(h=e(this,c(r).call(this,l))).status=d,h}return function(l,d){if(typeof d!="function"&&d!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(d&&d.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),d&&f(l,d)}(r,b(Error)),r}();function n(t){var r=new u.XMLHttpRequest;for(var l in r.open("GET",t.url,!0),t.headers)r.setRequestHeader(l,t.headers[l]);return r.withCredentials=t.credentials==="include",r}D.getJSON=function(t,r){var l=n(t);return l.setRequestHeader("Accept","application/json"),l.onerror=function(){r(new Error(l.statusText))},l.onload=function(){if(l.status>=200&&l.status<300&&l.response){var d;try{d=JSON.parse(l.response)}catch(h){return r(h)}r(null,d)}else r(new a(l.statusText,l.status))},l.send(),l},D.getArrayBuffer=function(t,r){var l=n(t);return l.responseType="arraybuffer",l.onerror=function(){r(new Error(l.statusText))},l.onload=function(){var d=l.response;if(d.byteLength===0&&l.status===200)return r(new Error("http status 200 returned without content."));l.status>=200&&l.status<300&&l.response?r(null,{data:d,cacheControl:l.getResponseHeader("Cache-Control"),expires:l.getResponseHeader("Expires")}):r(new a(l.statusText,l.status))},l.send(),l},D.getImage=function(t,r){return D.getArrayBuffer(t,function(l,d){if(l)r(l);else if(d){var h=new u.Image,m=u.URL||u.webkitURL;h.onload=function(){r(null,h),m.revokeObjectURL(h.src)};var S=new u.Blob([new Uint8Array(d.data)],{type:"image/png"});h.cacheControl=d.cacheControl,h.expires=d.expires,h.src=d.data.byteLength?m.createObjectURL(S):"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII="}})},D.getVideo=function(t,r){var l,d,h=u.document.createElement("video");h.onloadstart=function(){r(null,h)};for(var m=0;m=this.maxzoom)||this.visibility==="none"}},{key:"updateTransitions",value:function(p){this._transitioningPaint=this._transitionablePaint.transitioned(p,this._transitioningPaint)}},{key:"hasTransition",value:function(){return this._transitioningPaint.hasTransition()}},{key:"recalculate",value:function(p){this._unevaluatedLayout&&(this.layout=this._unevaluatedLayout.possiblyEvaluate(p)),this.paint=this._transitioningPaint.possiblyEvaluate(p)}},{key:"serialize",value:function(){var p={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==="none"&&(p.layout=p.layout||{},p.layout.visibility="none"),c.filterObject(p,function(w,A){return!(w===void 0||A==="layout"&&!Object.keys(w).length||A==="paint"&&!Object.keys(w).length)})}},{key:"_validate",value:function(p,w,A,k,v){return(!v||v.validate!==!1)&&i.emitErrors(this,p.call(i,{key:w,layerType:this.type,objectKey:A,value:k,styleSpec:u,style:{glyphs:!0,sprite:!0}}))}},{key:"hasOffscreenPass",value:function(){return!1}},{key:"resize",value:function(){}}])&&e(S.prototype,y),s&&e(S,s),m}());O.exports=l;var d={circle:o(151),heatmap:o(155),hillshade:o(158),fill:o(160),"fill-extrusion":o(165),line:o(169),symbol:o(174),background:o(180),raster:o(182)};l.create=function(h){return new d[h.type](h)}},function(O,D,o){function _(i,a){for(var n=0;n90||this.lat<-90)throw new Error("Invalid LngLat latitude value: must be between -90 and 90")}var c,u,i;return c=f,i=[{key:"convert",value:function(a){if(a instanceof f)return a;if(Array.isArray(a)&&(a.length===2||a.length===3))return new f(Number(a[0]),Number(a[1]));if(!Array.isArray(a)&&_(a)==="object"&&a!==null)return new f(Number(a.lng),Number(a.lat));throw new Error("`LngLatLike` argument must be specified as a LngLat instance, an object {lng: , lat: }, or an array of [, ]")}}],(u=[{key:"wrap",value:function(){return new f(b(this.lng,-180,180),this.lat)}},{key:"toArray",value:function(){return[this.lng,this.lat]}},{key:"toString",value:function(){return"LngLat(".concat(this.lng,", ").concat(this.lat,")")}},{key:"toBounds",value:function(a){var n=360*a/40075017,t=n/Math.cos(Math.PI/180*this.lat);return new(o(39))(new f(this.lng-t,this.lat-n),new f(this.lng+t,this.lat+n))}}])&&e(c.prototype,u),i&&e(c,i),f}();O.exports=g},function(O,D,o){O.exports=function(){"use strict";var _;return(_=new Float32Array(3))[0]=0,_[1]=0,_[2]=0,function(){var e=new Float32Array(4);e[0]=0,e[1]=0,e[2]=0,e[3]=0}(),{vec3:{transformMat3:function(e,b,g){var f=b[0],c=b[1],u=b[2];return e[0]=f*g[0]+c*g[3]+u*g[6],e[1]=f*g[1]+c*g[4]+u*g[7],e[2]=f*g[2]+c*g[5]+u*g[8],e}},vec4:{transformMat4:function(e,b,g){var f=b[0],c=b[1],u=b[2],i=b[3];return e[0]=g[0]*f+g[4]*c+g[8]*u+g[12]*i,e[1]=g[1]*f+g[5]*c+g[9]*u+g[13]*i,e[2]=g[2]*f+g[6]*c+g[10]*u+g[14]*i,e[3]=g[3]*f+g[7]*c+g[11]*u+g[15]*i,e}},mat2:{create:function(){var e=new Float32Array(4);return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e},rotate:function(e,b,g){var f=b[0],c=b[1],u=b[2],i=b[3],a=Math.sin(g),n=Math.cos(g);return e[0]=f*n+u*a,e[1]=c*n+i*a,e[2]=f*-a+u*n,e[3]=c*-a+i*n,e},scale:function(e,b,g){var f=b[0],c=b[1],u=b[2],i=b[3],a=g[0],n=g[1];return e[0]=f*a,e[1]=c*a,e[2]=u*n,e[3]=i*n,e}},mat3:{create:function(){var e=new Float32Array(9);return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=1,e[5]=0,e[6]=0,e[7]=0,e[8]=1,e},fromRotation:function(e,b){var g=Math.sin(b),f=Math.cos(b);return e[0]=f,e[1]=g,e[2]=0,e[3]=-g,e[4]=f,e[5]=0,e[6]=0,e[7]=0,e[8]=1,e}},mat4:{create:function(){var e=new Float32Array(16);return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},identity:function(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},translate:function(e,b,g){var f,c,u,i,a,n,t,r,l,d,h,m,S=g[0],y=g[1],s=g[2];return b===e?(e[12]=b[0]*S+b[4]*y+b[8]*s+b[12],e[13]=b[1]*S+b[5]*y+b[9]*s+b[13],e[14]=b[2]*S+b[6]*y+b[10]*s+b[14],e[15]=b[3]*S+b[7]*y+b[11]*s+b[15]):(f=b[0],c=b[1],u=b[2],i=b[3],a=b[4],n=b[5],t=b[6],r=b[7],l=b[8],d=b[9],h=b[10],m=b[11],e[0]=f,e[1]=c,e[2]=u,e[3]=i,e[4]=a,e[5]=n,e[6]=t,e[7]=r,e[8]=l,e[9]=d,e[10]=h,e[11]=m,e[12]=f*S+a*y+l*s+b[12],e[13]=c*S+n*y+d*s+b[13],e[14]=u*S+t*y+h*s+b[14],e[15]=i*S+r*y+m*s+b[15]),e},scale:function(e,b,g){var f=g[0],c=g[1],u=g[2];return e[0]=b[0]*f,e[1]=b[1]*f,e[2]=b[2]*f,e[3]=b[3]*f,e[4]=b[4]*c,e[5]=b[5]*c,e[6]=b[6]*c,e[7]=b[7]*c,e[8]=b[8]*u,e[9]=b[9]*u,e[10]=b[10]*u,e[11]=b[11]*u,e[12]=b[12],e[13]=b[13],e[14]=b[14],e[15]=b[15],e},multiply:function(e,b,g){var f=b[0],c=b[1],u=b[2],i=b[3],a=b[4],n=b[5],t=b[6],r=b[7],l=b[8],d=b[9],h=b[10],m=b[11],S=b[12],y=b[13],s=b[14],p=b[15],w=g[0],A=g[1],k=g[2],v=g[3];return e[0]=w*f+A*a+k*l+v*S,e[1]=w*c+A*n+k*d+v*y,e[2]=w*u+A*t+k*h+v*s,e[3]=w*i+A*r+k*m+v*p,w=g[4],A=g[5],k=g[6],v=g[7],e[4]=w*f+A*a+k*l+v*S,e[5]=w*c+A*n+k*d+v*y,e[6]=w*u+A*t+k*h+v*s,e[7]=w*i+A*r+k*m+v*p,w=g[8],A=g[9],k=g[10],v=g[11],e[8]=w*f+A*a+k*l+v*S,e[9]=w*c+A*n+k*d+v*y,e[10]=w*u+A*t+k*h+v*s,e[11]=w*i+A*r+k*m+v*p,w=g[12],A=g[13],k=g[14],v=g[15],e[12]=w*f+A*a+k*l+v*S,e[13]=w*c+A*n+k*d+v*y,e[14]=w*u+A*t+k*h+v*s,e[15]=w*i+A*r+k*m+v*p,e},perspective:function(e,b,g,f,c){var u=1/Math.tan(b/2),i=1/(f-c);return e[0]=u/g,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=u,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=(c+f)*i,e[11]=-1,e[12]=0,e[13]=0,e[14]=2*c*f*i,e[15]=0,e},rotateX:function(e,b,g){var f=Math.sin(g),c=Math.cos(g),u=b[4],i=b[5],a=b[6],n=b[7],t=b[8],r=b[9],l=b[10],d=b[11];return b!==e&&(e[0]=b[0],e[1]=b[1],e[2]=b[2],e[3]=b[3],e[12]=b[12],e[13]=b[13],e[14]=b[14],e[15]=b[15]),e[4]=u*c+t*f,e[5]=i*c+r*f,e[6]=a*c+l*f,e[7]=n*c+d*f,e[8]=t*c-u*f,e[9]=r*c-i*f,e[10]=l*c-a*f,e[11]=d*c-n*f,e},rotateZ:function(e,b,g){var f=Math.sin(g),c=Math.cos(g),u=b[0],i=b[1],a=b[2],n=b[3],t=b[4],r=b[5],l=b[6],d=b[7];return b!==e&&(e[8]=b[8],e[9]=b[9],e[10]=b[10],e[11]=b[11],e[12]=b[12],e[13]=b[13],e[14]=b[14],e[15]=b[15]),e[0]=u*c+t*f,e[1]=i*c+r*f,e[2]=a*c+l*f,e[3]=n*c+d*f,e[4]=t*c-u*f,e[5]=r*c-i*f,e[6]=l*c-a*f,e[7]=d*c-n*f,e},invert:function(e,b){var g=b[0],f=b[1],c=b[2],u=b[3],i=b[4],a=b[5],n=b[6],t=b[7],r=b[8],l=b[9],d=b[10],h=b[11],m=b[12],S=b[13],y=b[14],s=b[15],p=g*a-f*i,w=g*n-c*i,A=g*t-u*i,k=f*n-c*a,v=f*t-u*a,x=c*t-u*n,T=r*S-l*m,E=r*y-d*m,C=r*s-h*m,z=l*y-d*S,P=l*s-h*S,B=d*s-h*y,F=p*B-w*P+A*z+k*C-v*E+x*T;return F?(F=1/F,e[0]=(a*B-n*P+t*z)*F,e[1]=(c*P-f*B-u*z)*F,e[2]=(S*x-y*v+s*k)*F,e[3]=(d*v-l*x-h*k)*F,e[4]=(n*C-i*B-t*E)*F,e[5]=(g*B-c*C+u*E)*F,e[6]=(y*A-m*x-s*w)*F,e[7]=(r*x-d*A+h*w)*F,e[8]=(i*P-a*C+t*T)*F,e[9]=(f*C-g*P-u*T)*F,e[10]=(m*v-S*A+s*p)*F,e[11]=(l*A-r*v-h*p)*F,e[12]=(a*E-i*z-n*T)*F,e[13]=(g*z-f*E+c*T)*F,e[14]=(S*w-m*k-y*p)*F,e[15]=(r*k-l*w+d*p)*F,e):null},ortho:function(e,b,g,f,c,u,i){var a=1/(b-g),n=1/(f-c),t=1/(u-i);return e[0]=-2*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*n,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*t,e[11]=0,e[12]=(b+g)*a,e[13]=(c+f)*n,e[14]=(i+u)*t,e[15]=1,e}}}}()},function(O,D,o){function _(u,i){for(var a=0;athis.capacity){this.capacity=Math.max(t,Math.floor(5*this.capacity),128),this.arrayBuffer=new ArrayBuffer(this.capacity*this.bytesPerElement);var r=this.uint8;this._refreshViews(),r&&this.uint8.set(r)}}},{key:"_refreshViews",value:function(){throw new Error("_refreshViews() must be implemented by each concrete StructArray layout")}}])&&_(i.prototype,a),n&&_(i,n),u}();function c(u,i){return Math.ceil(u/i)*i}O.exports.StructArray=f,O.exports.Struct=function u(i,a){e(this,u),this._structArray=i,this._pos1=a*this.size,this._pos2=this._pos1/2,this._pos4=this._pos1/4,this._pos8=this._pos1/8},O.exports.viewTypes=g,O.exports.createLayout=function(u){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,a=0,n=0;return{members:u.map(function(t){b(t.name.length);var r,l=(r=t.type,g[r].BYTES_PER_ELEMENT),d=a=c(a,Math.max(i,l)),h=t.components||1;return n=Math.max(n,l),a+=l*h,{name:t.name,type:t.type,components:h,offset:d}}),size:c(a,Math.max(n,i)),alignment:i}}},function(O,D){function o(_){return _ instanceof Number||_ instanceof String||_ instanceof Boolean?_.valueOf():_}O.exports=o,O.exports.deep=function _(e){return Array.isArray(e)?e.map(_):o(e)}},function(O,D,o){function _(l){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(d){return typeof d}:function(d){return d&&typeof Symbol=="function"&&d.constructor===Symbol&&d!==Symbol.prototype?"symbol":typeof d})(l)}var e=o(1),b=o(12),g=o(8),f=g.NullType,c=g.NumberType,u=g.StringType,i=g.BooleanType,a=g.ColorType,n=g.ObjectType,t=g.ValueType,r=g.array;O.exports={Color:b,validateRGBA:function(l,d,h,m){return typeof l=="number"&&l>=0&&l<=255&&typeof d=="number"&&d>=0&&d<=255&&typeof h=="number"&&h>=0&&h<=255?m===void 0||typeof m=="number"&&m>=0&&m<=1?null:"Invalid rgba value [".concat([l,d,h,m].join(", "),"]: 'a' must be between 0 and 1."):"Invalid rgba value [".concat((typeof m=="number"?[l,d,h,m]:[l,d,h]).join(", "),"]: 'r', 'g', and 'b' must be between 0 and 255.")},isValue:function l(d){if(d===null||typeof d=="string"||typeof d=="boolean"||typeof d=="number"||d instanceof b)return!0;if(Array.isArray(d)){var h=!0,m=!1,S=void 0;try{for(var y,s=d[Symbol.iterator]();!(h=(y=s.next()).done);h=!0)if(!l(y.value))return!1}catch(w){m=!0,S=w}finally{try{h||s.return==null||s.return()}finally{if(m)throw S}}return!0}if(_(d)==="object"){for(var p in d)if(!l(d[p]))return!1;return!0}return!1},typeOf:function l(d){if(d===null)return f;if(typeof d=="string")return u;if(typeof d=="boolean")return i;if(typeof d=="number")return c;if(d instanceof b)return a;if(Array.isArray(d)){var h,m=d.length,S=!0,y=!1,s=void 0;try{for(var p,w=d[Symbol.iterator]();!(S=(p=w.next()).done);S=!0){var A=l(p.value);if(h){if(h===A)continue;h=t;break}h=A}}catch(k){y=!0,s=k}finally{try{S||w.return==null||w.return()}finally{if(y)throw s}}return r(h||t,m)}return e(_(d)==="object"),n}}},function(O,D,o){var _=o(12);function e(b,g,f){return b*(1-f)+g*f}O.exports={number:e,color:function(b,g,f){return new _(e(b.r,g.r,f),e(b.g,g.g,f),e(b.b,g.b,f),e(b.a,g.a,f))},array:function(b,g,f){return b.map(function(c,u){return e(c,g[u],f)})}}},function(O,D,o){function _(r,l){if(!(r instanceof l))throw new TypeError("Cannot call a class as a function")}function e(r,l){for(var d=0;d=0&&l<=25),f(d>=0&&d=0&&h0;A--)w+=(y&(p=1<=h),this.overscaledZ=l,this.wrap=d,this.canonical=new i(h,+m,+S),this.key=t(d,l,m,S)}return b(r,[{key:"scaledTo",value:function(l){f(l<=this.overscaledZ);var d=this.canonical.z-l;return l>this.canonical.z?new r(l,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new r(l,this.wrap,l,this.canonical.x>>d,this.canonical.y>>d)}},{key:"isChildOf",value:function(l){var d=this.canonical.z-l.canonical.z;return l.overscaledZ===0||l.overscaledZ>d&&l.canonical.y===this.canonical.y>>d}},{key:"children",value:function(l){if(this.overscaledZ>=l)return[new r(this.overscaledZ+1,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)];var d=this.canonical.z+1,h=2*this.canonical.x,m=2*this.canonical.y;return[new r(d,this.wrap,d,h,m),new r(d,this.wrap,d,h+1,m),new r(d,this.wrap,d,h,m+1),new r(d,this.wrap,d,h+1,m+1)]}},{key:"isLessThan",value:function(l){return this.wrapl.wrap)&&(this.overscaledZl.overscaledZ)&&(this.canonical.xl.canonical.x)&&this.canonical.y0&&typeof j[0]=="string"&&j[0]in y}function E(j,M){var N=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},V=new t(y,[],function(H){var Y={color:R,string:U,number:K,enum:U,boolean:q};return H.type==="array"?I(Y[H.value]||L,H.length):Y[H.type]||null}(M)),G=V.parse(j);return G?N.handleErrors===!1?A(new v(G)):A(new x(G,M)):(i(V.errors.length>0),k(V.errors))}var C=function(){function j(M,N){f(this,j),this.kind=M,this._styleExpression=N}return u(j,[{key:"evaluate",value:function(M,N){return this._styleExpression.evaluate(M,N)}}]),j}(),z=function(){function j(M,N,V){f(this,j),this.kind=M,this.zoomStops=V.labels,this._styleExpression=N,V instanceof h&&(this._interpolationType=V.interpolation)}return u(j,[{key:"evaluate",value:function(M,N){return this._styleExpression.evaluate(M,N)}},{key:"interpolationFactor",value:function(M,N,V){return this._interpolationType?h.interpolationFactor(this._interpolationType,M,N,V):0}}]),j}();function P(j,M){if((j=E(j,M,arguments.length>2&&arguments[2]!==void 0?arguments[2]:{})).result==="error")return j;var N=j.value.expression,V=s.isFeatureConstant(N);if(!V&&!M["property-function"])return k([new n("","property expressions not supported")]);var G=s.isGlobalPropertyConstant(N,["zoom"]);if(!G&&M["zoom-function"]===!1)return k([new n("","zoom expressions not supported")]);var H=function Y($){var Q=null;if($ instanceof S)Q=Y($.result);else if($ instanceof m){var tt=!0,et=!1,nt=void 0;try{for(var ot,it=$.args[Symbol.iterator]();!(tt=(ot=it.next()).done);tt=!0){var at=ot.value;if(Q=Y(at))break}}catch(st){et=!0,nt=st}finally{try{tt||it.return==null||it.return()}finally{if(et)throw nt}}}else($ instanceof d||$ instanceof h)&&$.input instanceof l&&$.input.name==="zoom"&&(Q=$);return Q instanceof n||$.eachChild(function(st){var rt=Y(st);rt instanceof n?Q=rt:!Q&&rt?Q=new n("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):Q&&rt&&Q!==rt&&(Q=new n("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),Q}(N);return H||G?H instanceof n?k([H]):H instanceof h&&M.function==="piecewise-constant"?k([new n("",'"interpolate" expressions cannot be used with this property')]):A(H?new z(V?"camera":"composite",j.value,H):new C(V?"constant":"source",j.value)):k([new n("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')])}var B=o(57),F=B.isFunction,Z=B.createFunction,W=o(25).Color,J=function(){function j(M,N){f(this,j),this._parameters=M,this._specification=N,a(this,Z(this._parameters,this._specification))}return u(j,null,[{key:"deserialize",value:function(M){return new j(M._parameters,M._specification)}},{key:"serialize",value:function(M){return{_parameters:M._parameters,_specification:M._specification}}}]),j}();O.exports={StyleExpression:v,StyleExpressionWithErrorHandling:x,isExpression:T,createExpression:E,createPropertyExpression:P,normalizePropertyExpression:function(j,M){if(F(j))return new J(j,M);if(T(j)){var N=P(j,M);if(N.result==="error")throw new Error(N.value.map(function(G){return"".concat(G.key,": ").concat(G.message)}).join(", "));return N.value}var V=j;return typeof j=="string"&&M.type==="color"&&(V=W.parse(j)),{kind:"constant",evaluate:function(){return V}}},ZoomConstantExpression:C,ZoomDependentExpression:z,StylePropertyFunction:J};var X=o(8),R=X.ColorType,U=X.StringType,K=X.NumberType,q=X.BooleanType,L=X.ValueType,I=X.array},function(O,D){function o(e,b){for(var g=0;g3&&arguments[3]!==void 0?arguments[3]:function(){return!0};_(this,y),this.programConfigurations={};var k=!0,v=!1,x=void 0;try{for(var T,E=p[Symbol.iterator]();!(k=(T=E.next()).done);k=!0){var C=T.value;this.programConfigurations[C.id]=h.createDynamic(C,w,A),this.programConfigurations[C.id].layoutAttributes=s}}catch(z){v=!0,x=z}finally{try{k||E.return==null||E.return()}finally{if(v)throw x}}}return b(y,[{key:"populatePaintArrays",value:function(s,p){for(var w in this.programConfigurations)this.programConfigurations[w].populatePaintArrays(s,p)}},{key:"get",value:function(s){return this.programConfigurations[s]}},{key:"upload",value:function(s){for(var p in this.programConfigurations)this.programConfigurations[p].upload(s)}},{key:"destroy",value:function(){for(var s in this.programConfigurations)this.programConfigurations[s].destroy()}}]),y}();function S(y,s){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"}[y]||y.replace("".concat(s,"-"),"").replace(/-/g,"_")}f("ConstantBinder",r),f("SourceExpressionBinder",l),f("CompositeExpressionBinder",d),f("ProgramConfiguration",h,{omit:["_buffers"]}),f("ProgramConfigurationSet",m),O.exports={ProgramConfiguration:h,ProgramConfigurationSet:m}},function(O,D,o){function _(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}function e(t,r){for(var l=0;lt.width||h.height>t.height||l.x>t.width-h.width||l.y>t.height-h.height)throw new RangeError("out of range source coordinates for image copy");if(h.width>r.width||h.height>r.height||d.x>r.width-h.width||d.y>r.height-h.height)throw new RangeError("out of range destination coordinates for image copy");var S=t.data,y=r.data;g(S!==y);for(var s=0;s=2||r===512?"@2x":"",h=e.supportsWebp?".webp":"$1";return l.path=l.path.replace(c,"".concat(d).concat(h)),function(m){for(var S=0;S0&&arguments[0]!==void 0?arguments[0]:[];(function(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")})(this,c),this.segments=n}var u,i,a;return u=c,(i=[{key:"prepareSegment",value:function(n,t,r){var l=this.segments[this.segments.length-1];return n>g&&e("Max vertices per segment is ".concat(g,": bucket requested ").concat(n)),(!l||l.vertexLength+n>O.exports.MAX_VERTEX_ARRAY_LENGTH)&&(l={vertexOffset:t.length,primitiveOffset:r.length,vertexLength:0,primitiveLength:0},this.segments.push(l)),l}},{key:"get",value:function(){return this.segments}},{key:"destroy",value:function(){var n=!0,t=!1,r=void 0;try{for(var l,d=this.segments[Symbol.iterator]();!(n=(l=d.next()).done);n=!0){var h=l.value;for(var m in h.vaos)h.vaos[m].destroy()}}catch(S){t=!0,r=S}finally{try{n||d.return==null||d.return()}finally{if(t)throw r}}}}])&&_(u.prototype,i),a&&_(u,a),c}();b("SegmentVector",f),O.exports={SegmentVector:f,MAX_VERTEX_ARRAY_LENGTH:g}},function(O,D,o){O.exports={LineIndexArray:o(14).LineIndexArray,TriangleIndexArray:o(14).TriangleIndexArray}},function(O,D,o){var _=o(0),e=o(6),b,g=(b=16,{min:-1*Math.pow(2,b-1),max:Math.pow(2,b-1)-1});O.exports=function(f){for(var c=e/f.extent,u=f.loadGeometry(),i=0;ig.max||t.yg.max)&&_.warnOnce("Geometry exceeds allowed extent, reduce your vector tile buffer size")}return u}},function(O,D,o){function _(g,f){for(var c=0;c1?_-1:0),b=1;b<_;b++)e[b-1]=arguments[b];for(var g=0,f=e;g0),S.length===1)r.errors.push.apply(r.errors,v.errors);else{var X=(S.length?S:m).map(function(U){var K,q=_(U,1)[0];return K=q,Array.isArray(K)?"(".concat(K.map(b).join(", "),")"):"(".concat(b(K.type),"...)")}).join(" | "),R=y.map(function(U){return b(U.type)}).join(", ");r.error("Expected arguments of type ".concat(X,", but found (").concat(R,") instead."))}return null}},{key:"register",value:function(t,r){for(var l in f(!u.definitions),u.definitions=r,r)t[l]=u}}],(a=[{key:"evaluate",value:function(t){return this._evaluate(t,this.args)}},{key:"eachChild",value:function(t){this.args.forEach(t)}},{key:"possibleOutputs",value:function(){return[void 0]}}])&&e(i.prototype,a),n&&e(i,n),u}();O.exports={CompoundExpression:c,varargs:function(u){return{type:u}}}},function(O,D,o){var _=o(7),e=o(17),b=o(29);O.exports=function(g){var f=g.key,c=g.value,u=g.valueSpec||{},i=g.objectElementValidators||{},a=g.style,n=g.styleSpec,t=[],r=e(c);if(r!=="object")return[new _(f,c,"object expected, ".concat(r," found"))];for(var l in c){var d=l.split(".")[0],h=u[d]||u["*"],m=void 0;if(i[d])m=i[d];else if(u[d])m=b;else if(i["*"])m=i["*"];else{if(!u["*"]){t.push(new _(f,c[l],'unknown property "'.concat(l,'"')));continue}m=b}t=t.concat(m({key:(f&&"".concat(f,"."))+l,value:c[l],valueSpec:h,style:a,styleSpec:n,object:c,objectKey:l},c))}for(var S in u)i[S]||u[S].required&&u[S].default===void 0&&c[S]===void 0&&t.push(new _(f,c,'missing required property "'.concat(S,'"')));return t}},function(O,D,o){var _=o(0).isCounterClockwise;function e(a,n,t){if(a.length>1){if(b(a,n))return!0;for(var r=0;r1?a.distSqr(t):a.distSqr(t.sub(n)._mult(l)._add(n))}function u(a,n){for(var t,r,l,d=!1,h=0;hn.y!=l.y>n.y&&n.x<(l.x-r.x)*(n.y-r.y)/(l.y-r.y)+r.x&&(d=!d);return d}function i(a,n){for(var t=!1,r=0,l=a.length-1;rn.y!=h.y>n.y&&n.x<(h.x-d.x)*(n.y-d.y)/(h.y-d.y)+d.x&&(t=!t)}return t}O.exports={multiPolygonIntersectsBufferedMultiPoint:function(a,n,t){for(var r=0;r=3){for(var m=0;m1&&arguments[1]!==void 0?arguments[1]:{};(function(M,N){if(!(M instanceof N))throw new TypeError("Cannot call a class as a function")})(this,X),(L=function(M,N){return!N||_(N)!=="object"&&typeof N!="function"?g(M):N}(this,b(X).call(this))).map=q,L.dispatcher=new y(x(),g(L)),L.imageManager=new n,L.glyphManager=new t(q._transformRequest,I.localIdeographFontFamily),L.lineAtlas=new l(256,512),L.crossTileSymbolIndex=new B,L._layers={},L._order=[],L.sourceCaches={},L.zoomHistory=new P,L._loaded=!1,L._resetUpdates();var j=g(L);return L._rtlTextPluginCallback=C.registerForPluginAvailability(function(M){for(var N in j.dispatcher.broadcast("loadRTLTextPlugin",M.pluginBlobURL,M.errorCallback),j.sourceCaches)j.sourceCaches[N].reload()}),L.on("data",function(M){if(M.dataType==="source"&&M.sourceDataType==="metadata"){var N=L.sourceCaches[M.sourceId];if(N){var V=N.getSource();if(V&&V.vectorLayerIds)for(var G in L._layers){var H=L._layers[G];H.source===V.id&&L._validateLayer(H)}}}}),L}var R,U,K;return function(q,L){if(typeof L!="function"&&L!==null)throw new TypeError("Super expression must either be null or a function");q.prototype=Object.create(L&&L.prototype,{constructor:{value:q,writable:!0,configurable:!0}}),L&&f(q,L)}(X,u),R=X,(U=[{key:"loadURL",value:function(q){var L=this,I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.fire("dataloading",{dataType:"style"});var j=typeof I.validate=="boolean"?I.validate:!m.isMapboxURL(q);q=m.normalizeStyleURL(q,I.accessToken);var M=this.map._transformRequest(q,h.ResourceType.Style);h.getJSON(M,function(N,V){N?L.fire("error",{error:N}):V&&L._load(V,j)})}},{key:"loadJSON",value:function(q){var L=this,I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.fire("dataloading",{dataType:"style"}),S.frame(function(){L._load(q,I.validate!==!1)})}},{key:"_load",value:function(q,L){var I=this;if(!L||!s.emitErrors(this,s(q))){for(var j in this._loaded=!0,this.stylesheet=q,q.sources)this.addSource(j,q.sources[j],{validate:!1});q.sprite?a(q.sprite,this.map._transformRequest,function(Q,tt){if(Q)I.fire("error",Q);else if(tt)for(var et in tt)I.imageManager.addImage(et,tt[et]);I.imageManager.setLoaded(!0),I.fire("data",{dataType:"style"})}):this.imageManager.setLoaded(!0),this.glyphManager.setURL(q.glyphs);var M=T(this.stylesheet.layers);this._order=M.map(function(Q){return Q.id}),this._layers={};var N=!0,V=!1,G=void 0;try{for(var H,Y=M[Symbol.iterator]();!(N=(H=Y.next()).done);N=!0){var $=H.value;($=i.create($)).setEventedParent(this,{layer:{id:$.id}}),this._layers[$.id]=$}}catch(Q){V=!0,G=Q}finally{try{N||Y.return==null||Y.return()}finally{if(V)throw G}}this.dispatcher.broadcast("setLayers",this._serializeLayers(this._order)),this.light=new r(this.stylesheet.light),this.fire("data",{dataType:"style"}),this.fire("style.load")}}},{key:"_validateLayer",value:function(q){var L=this.sourceCaches[q.source];if(L){var I=q.sourceLayer;if(I){var j=L.getSource();(j.type==="geojson"||j.vectorLayerIds&&j.vectorLayerIds.indexOf(I)===-1)&&this.fire("error",{error:new Error('Source layer "'.concat(I,'" ')+'does not exist on source "'.concat(j.id,'" ')+'as specified by style layer "'.concat(q.id,'"'))})}}}},{key:"loaded",value:function(){if(!this._loaded||Object.keys(this._updatedSources).length)return!1;for(var q in this.sourceCaches)if(!this.sourceCaches[q].loaded())return!1;return!!this.imageManager.isLoaded()}},{key:"_serializeLayers",value:function(q){var L=this;return q.map(function(I){return L._layers[I].serialize()})}},{key:"hasTransitions",value:function(){if(this.light&&this.light.hasTransition())return!0;for(var q in this.sourceCaches)if(this.sourceCaches[q].hasTransition())return!0;for(var L in this._layers)if(this._layers[L].hasTransition())return!0;return!1}},{key:"_checkLoaded",value:function(){if(!this._loaded)throw new Error("Style is not done loading")}},{key:"update",value:function(q){if(this._loaded){if(this._changed){var L=Object.keys(this._updatedLayers),I=Object.keys(this._removedLayers);for(var j in(L.length||I.length)&&this._updateWorkerLayers(L,I),this._updatedSources){var M=this._updatedSources[j];c(M==="reload"||M==="clear"),M==="reload"?this._reloadSource(j):M==="clear"&&this._clearSource(j)}for(var N in this._updatedPaintProps)this._layers[N].updateTransitions(q);this.light.updateTransitions(q),this._resetUpdates(),this.fire("data",{dataType:"style"})}for(var V in this.sourceCaches)this.sourceCaches[V].used=!1;var G=!0,H=!1,Y=void 0;try{for(var $,Q=this._order[Symbol.iterator]();!(G=($=Q.next()).done);G=!0){var tt=$.value,et=this._layers[tt];et.recalculate(q),!et.isHidden(q.zoom)&&et.source&&(this.sourceCaches[et.source].used=!0)}}catch(nt){H=!0,Y=nt}finally{try{G||Q.return==null||Q.return()}finally{if(H)throw Y}}this.light.recalculate(q),this.z=q.zoom}}},{key:"_updateWorkerLayers",value:function(q,L){this.dispatcher.broadcast("updateLayers",{layers:this._serializeLayers(q),removedIds:L})}},{key:"_resetUpdates",value:function(){this._changed=!1,this._updatedLayers={},this._removedLayers={},this._updatedSources={},this._updatedPaintProps={}}},{key:"setState",value:function(q){var L=this;if(this._checkLoaded(),s.emitErrors(this,s(q)))return!1;(q=d.clone(q)).layers=T(q.layers);var I=E(this.serialize(),q).filter(function(M){return!(M.command in Z)});if(I.length===0)return!1;var j=I.filter(function(M){return!(M.command in F)});if(j.length>0)throw new Error("Unimplemented: ".concat(j.map(function(M){return M.command}).join(", "),"."));return I.forEach(function(M){M.command!=="setTransition"&&L[M.command].apply(L,M.args)}),this.stylesheet=q,!0}},{key:"addImage",value:function(q,L){if(this.getImage(q))return this.fire("error",{error:new Error("An image with this name already exists.")});this.imageManager.addImage(q,L),this.fire("data",{dataType:"style"})}},{key:"getImage",value:function(q){return this.imageManager.getImage(q)}},{key:"removeImage",value:function(q){if(!this.getImage(q))return this.fire("error",{error:new Error("No image with this name exists.")});this.imageManager.removeImage(q),this.fire("data",{dataType:"style"})}},{key:"addSource",value:function(q,L,I){var j=this;if(this._checkLoaded(),this.sourceCaches[q]!==void 0)throw new Error("There is already a source with this ID");if(!L.type)throw new Error("The type property must be defined, but the only the following properties were given: ".concat(Object.keys(L).join(", "),"."));if(!(["vector","raster","geojson","video","image","canvas"].indexOf(L.type)>=0)||!this._validate(s.source,"sources.".concat(q),L,null,I)){var M=this.sourceCaches[q]=new k(q,L,this.dispatcher);M.style=this,M.setEventedParent(this,function(){return{isSourceLoaded:j.loaded(),source:M.serialize(),sourceId:q}}),M.onAdd(this.map),this._changed=!0}}},{key:"removeSource",value:function(q){if(this._checkLoaded(),this.sourceCaches[q]===void 0)throw new Error("There is no source with this ID");for(var L in this._layers)if(this._layers[L].source===q)return this.fire("error",{error:new Error('Source "'.concat(q,'" cannot be removed while layer "').concat(L,'" is using it.'))});var I=this.sourceCaches[q];delete this.sourceCaches[q],delete this._updatedSources[q],I.fire("data",{sourceDataType:"metadata",dataType:"source",sourceId:q}),I.setEventedParent(null),I.clearTiles(),I.onRemove&&I.onRemove(this.map),this._changed=!0}},{key:"setGeoJSONSourceData",value:function(q,L){this._checkLoaded(),c(this.sourceCaches[q]!==void 0,"There is no source with this ID");var I=this.sourceCaches[q].getSource();c(I.type==="geojson"),I.setData(L),this._changed=!0}},{key:"getSource",value:function(q){return this.sourceCaches[q]&&this.sourceCaches[q].getSource()}},{key:"addLayer",value:function(q,L,I){this._checkLoaded();var j=q.id;if(_(q.source)==="object"&&(this.addSource(j,q.source),q=d.clone(q),q=d.extend(q,{source:j})),!this._validate(s.layer,"layers.".concat(j),q,{arrayIndex:-1},I)){var M=i.create(q);this._validateLayer(M),M.setEventedParent(this,{layer:{id:j}});var N=L?this._order.indexOf(L):this._order.length;if(L&&N===-1)this.fire("error",{error:new Error('Layer with id "'.concat(L,'" does not exist on this map.'))});else{if(this._order.splice(N,0,j),this._layerOrderChanged=!0,this._layers[j]=M,this._removedLayers[j]&&M.source){var V=this._removedLayers[j];delete this._removedLayers[j],V.type!==M.type?this._updatedSources[M.source]="clear":(this._updatedSources[M.source]="reload",this.sourceCaches[M.source].pause())}this._updateLayer(M)}}}},{key:"moveLayer",value:function(q,L){if(this._checkLoaded(),this._changed=!0,this._layers[q]){var I=this._order.indexOf(q);this._order.splice(I,1);var j=L?this._order.indexOf(L):this._order.length;L&&j===-1?this.fire("error",{error:new Error('Layer with id "'.concat(L,'" does not exist on this map.'))}):(this._order.splice(j,0,q),this._layerOrderChanged=!0)}else this.fire("error",{error:new Error("The layer '".concat(q,"' does not exist in ")+"the map's style and cannot be moved.")})}},{key:"removeLayer",value:function(q){this._checkLoaded();var L=this._layers[q];if(L){L.setEventedParent(null);var I=this._order.indexOf(q);this._order.splice(I,1),this._layerOrderChanged=!0,this._changed=!0,this._removedLayers[q]=L,delete this._layers[q],delete this._updatedLayers[q],delete this._updatedPaintProps[q]}else this.fire("error",{error:new Error("The layer '".concat(q,"' does not exist in ")+"the map's style and cannot be removed.")})}},{key:"getLayer",value:function(q){return this._layers[q]}},{key:"setLayerZoomRange",value:function(q,L,I){this._checkLoaded();var j=this.getLayer(q);j?j.minzoom===L&&j.maxzoom===I||(L!=null&&(j.minzoom=L),I!=null&&(j.maxzoom=I),this._updateLayer(j)):this.fire("error",{error:new Error("The layer '".concat(q,"' does not exist in ")+"the map's style and cannot have zoom extent.")})}},{key:"setFilter",value:function(q,L){this._checkLoaded();var I=this.getLayer(q);if(I){if(!d.deepEqual(I.filter,L))return L==null?(I.filter=void 0,void this._updateLayer(I)):void(this._validate(s.filter,"layers.".concat(I.id,".filter"),L)||(I.filter=d.clone(L),this._updateLayer(I)))}else this.fire("error",{error:new Error("The layer '".concat(q,"' does not exist in ")+"the map's style and cannot be filtered.")})}},{key:"getFilter",value:function(q){return d.clone(this.getLayer(q).filter)}},{key:"setLayoutProperty",value:function(q,L,I){this._checkLoaded();var j=this.getLayer(q);j?d.deepEqual(j.getLayoutProperty(L),I)||(j.setLayoutProperty(L,I),this._updateLayer(j)):this.fire("error",{error:new Error("The layer '".concat(q,"' does not exist in ")+"the map's style and cannot be styled.")})}},{key:"getLayoutProperty",value:function(q,L){return this.getLayer(q).getLayoutProperty(L)}},{key:"setPaintProperty",value:function(q,L,I){this._checkLoaded();var j=this.getLayer(q);if(j){if(!d.deepEqual(j.getPaintProperty(L),I)){var M=j._transitionablePaint._values[L].value.isDataDriven();j.setPaintProperty(L,I),(j._transitionablePaint._values[L].value.isDataDriven()||M)&&this._updateLayer(j),this._changed=!0,this._updatedPaintProps[q]=!0}}else this.fire("error",{error:new Error("The layer '".concat(q,"' does not exist in ")+"the map's style and cannot be styled.")})}},{key:"getPaintProperty",value:function(q,L){return this.getLayer(q).getPaintProperty(L)}},{key:"getTransition",value:function(){return d.extend({duration:300,delay:0},this.stylesheet&&this.stylesheet.transition)}},{key:"serialize",value:function(){var q=this;return d.filterObject({version:this.stylesheet.version,name:this.stylesheet.name,metadata:this.stylesheet.metadata,light:this.stylesheet.light,center:this.stylesheet.center,zoom:this.stylesheet.zoom,bearing:this.stylesheet.bearing,pitch:this.stylesheet.pitch,sprite:this.stylesheet.sprite,glyphs:this.stylesheet.glyphs,transition:this.stylesheet.transition,sources:d.mapObject(this.sourceCaches,function(L){return L.serialize()}),layers:this._order.map(function(L){return q._layers[L].serialize()})},function(L){return L!==void 0})}},{key:"_updateLayer",value:function(q){this._updatedLayers[q.id]=!0,q.source&&!this._updatedSources[q.source]&&(this._updatedSources[q.source]="reload",this.sourceCaches[q.source].pause()),this._changed=!0}},{key:"_flattenRenderedFeatures",value:function(q){for(var L=[],I=this._order.length-1;I>=0;I--){var j=this._order[I],M=!0,N=!1,V=void 0;try{for(var G,H=q[Symbol.iterator]();!(M=(G=H.next()).done);M=!0){var Y=G.value[j];if(Y){var $=!0,Q=!1,tt=void 0;try{for(var et,nt=Y[Symbol.iterator]();!($=(et=nt.next()).done);$=!0){var ot=et.value;L.push(ot)}}catch(it){Q=!0,tt=it}finally{try{$||nt.return==null||nt.return()}finally{if(Q)throw tt}}}}}catch(it){N=!0,V=it}finally{try{M||H.return==null||H.return()}finally{if(N)throw V}}}return L}},{key:"queryRenderedFeatures",value:function(q,L,I,j){L&&L.filter&&this._validate(s.filter,"queryRenderedFeatures.filter",L.filter);var M={};if(L&&L.layers){if(!Array.isArray(L.layers))return this.fire("error",{error:"parameters.layers must be an Array."}),[];var N=!0,V=!1,G=void 0;try{for(var H,Y=L.layers[Symbol.iterator]();!(N=(H=Y.next()).done);N=!0){var $=H.value,Q=this._layers[$];if(!Q)return this.fire("error",{error:"The layer '".concat($,"' does not exist ")+"in the map's style and cannot be queried for features."}),[];M[Q.source]=!0}}catch(ot){V=!0,G=ot}finally{try{N||Y.return==null||Y.return()}finally{if(V)throw G}}}var tt=[];for(var et in this.sourceCaches)if(!L.layers||M[et]){var nt=A.rendered(this.sourceCaches[et],this._layers,q,L,I,j,this.collisionIndex);tt.push(nt)}return this._flattenRenderedFeatures(tt)}},{key:"querySourceFeatures",value:function(q,L){L&&L.filter&&this._validate(s.filter,"querySourceFeatures.filter",L.filter);var I=this.sourceCaches[q];return I?A.source(I,L):[]}},{key:"addSourceType",value:function(q,L,I){return p(q)?I(new Error('A source type called "'.concat(q,'" already exists.'))):(w(q,L),L.workerSourceURL?void this.dispatcher.broadcast("loadWorkerSource",{name:q,url:L.workerSourceURL},I):I(null,null))}},{key:"getLight",value:function(){return this.light.getLight()}},{key:"setLight",value:function(q){this._checkLoaded();var L=this.light.getLight(),I=!1;for(var j in q)if(!d.deepEqual(q[j],L[j])){I=!0;break}if(I){var M={now:S.now(),transition:d.extend({duration:300,delay:0},this.stylesheet.transition)};this.light.setLight(q),this.light.updateTransitions(M)}}},{key:"_validate",value:function(q,L,I,j,M){return(!M||M.validate!==!1)&&s.emitErrors(this,q.call(s,d.extend({key:L,style:this.serialize(),value:I,styleSpec:v},j)))}},{key:"_remove",value:function(){for(var q in C.evented.off("pluginAvailable",this._rtlTextPluginCallback),this.sourceCaches)this.sourceCaches[q].clearTiles();this.dispatcher.remove()}},{key:"_clearSource",value:function(q){this.sourceCaches[q].clearTiles()}},{key:"_reloadSource",value:function(q){this.sourceCaches[q].resume(),this.sourceCaches[q].reload()}},{key:"_updateSources",value:function(q){for(var L in this.sourceCaches)this.sourceCaches[L].update(q)}},{key:"_generateCollisionBoxes",value:function(){for(var q in this.sourceCaches)this._reloadSource(q)}},{key:"_updatePlacement",value:function(q,L,I){var j=this,M=!1,N=!1,V={},G=!0,H=!1,Y=void 0;try{for(var $,Q=this._order[Symbol.iterator]();!(G=($=Q.next()).done);G=!0){var tt=$.value,et=this._layers[tt];if(et.type==="symbol"){V[et.source]||function(){var ft=j.sourceCaches[et.source];V[et.source]=ft.getRenderableIds().map(function(ht){return ft.getTileByID(ht)}).sort(function(ht,mt){return mt.tileID.overscaledZ-ht.tileID.overscaledZ||(ht.tileID.isLessThan(mt.tileID)?-1:1)})}();var nt=this.crossTileSymbolIndex.addLayer(et,V[et.source]);M=M||nt}}}catch(ft){H=!0,Y=ft}finally{try{G||Q.return==null||Q.return()}finally{if(H)throw Y}}var ot=this._layerOrderChanged;if((ot||!this.pauseablePlacement||this.pauseablePlacement.isDone()&&!this.placement.stillRecent(S.now()))&&(this.pauseablePlacement=new z(q,this._order,ot,L,I),this._layerOrderChanged=!1),this.pauseablePlacement.isDone())this.placement.setStale();else{if(this.pauseablePlacement.continuePlacement(this._order,this._layers,V),this.pauseablePlacement.isDone()){var it=this.pauseablePlacement.placement;N=it.commit(this.placement,S.now()),(!this.placement||N||M)&&(this.placement=it,this.collisionIndex=this.placement.collisionIndex),this.placement.setRecent(S.now(),it.stale)}M&&this.pauseablePlacement.placement.setStale()}if(N||M){var at=!0,st=!1,rt=void 0;try{for(var lt,ct=this._order[Symbol.iterator]();!(at=(lt=ct.next()).done);at=!0){var ut=lt.value,pt=this._layers[ut];pt.type==="symbol"&&this.placement.updateLayerOpacities(pt,V[pt.source])}}catch(ft){st=!0,rt=ft}finally{try{at||ct.return==null||ct.return()}finally{if(st)throw rt}}}return!this.pauseablePlacement.isDone()||this.placement.hasTransitions(S.now())}},{key:"getImages",value:function(q,L,I){this.imageManager.getImages(L.icons,I)}},{key:"getGlyphs",value:function(q,L,I){this.glyphManager.getGlyphs(L.stacks,I)}}])&&e(R.prototype,U),K&&e(R,K),X}();O.exports=W},function(O,D,o){O.exports=o(141),O.exports.emitErrors=function(_,e){if(e&&e.length){var b=!0,g=!1,f=void 0;try{for(var c,u=e[Symbol.iterator]();!(b=(c=u.next()).done);b=!0){var i=c.value.message;_.fire("error",{error:new Error(i)})}}catch(a){g=!0,f=a}finally{try{b||u.return==null||u.return()}finally{if(g)throw f}}return!0}return!1}},function(O,D,o){function _(u,i){for(var a=0;a1}))return p.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);k={name:"cubic-bezier",controlPoints:E}}if(s.length-1<4)return p.error("Expected at least 4 arguments, but found only ".concat(s.length-1,"."));if((s.length-1)%2!=0)return p.error("Expected an even number of arguments.");if(!(v=p.parse(v,2,t)))return null;var C=[],z=null;p.expectedType&&p.expectedType.kind!=="value"&&(z=p.expectedType);for(var P=0;P=B)return p.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',Z);var J=p.parse(F,W,z);if(!J)return null;z=z||J.type,C.push([B,J])}return z.kind==="number"||z.kind==="color"||z.kind==="array"&&z.itemType.kind==="number"&&typeof z.N=="number"?new h(z,k,v,C):p.error("Type ".concat(n(z)," is not interpolatable."))}}],(S=[{key:"evaluate",value:function(s){var p=this.labels,w=this.outputs;if(p.length===1)return w[0].evaluate(s);var A=this.input.evaluate(s);if(A<=p[0])return w[0].evaluate(s);var k=p.length;if(A>=p[k-1])return w[k-1].evaluate(s);var v=r(p,A),x=p[v],T=p[v+1],E=h.interpolationFactor(this.interpolation,A,x,T),C=w[v].evaluate(s),z=w[v+1].evaluate(s);return i[this.type.kind.toLowerCase()](C,z,E)}},{key:"eachChild",value:function(s){s(this.input);var p=!0,w=!1,A=void 0;try{for(var k,v=this.outputs[Symbol.iterator]();!(p=(k=v.next()).done);p=!0)s(k.value)}catch(x){w=!0,A=x}finally{try{p||v.return==null||v.return()}finally{if(w)throw A}}}},{key:"possibleOutputs",value:function(){var s;return(s=[]).concat.apply(s,_(this.outputs.map(function(p){return p.possibleOutputs()})))}}])&&c(m.prototype,S),y&&c(m,y),h}();function d(h,m,S,y){var s=y-S,p=h-S;return s===0?0:m===1?p/s:(Math.pow(m,p)-1)/(Math.pow(m,s)-1)}O.exports=l},function(O,D,o){function _(h){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(m){return typeof m}:function(m){return m&&typeof Symbol=="function"&&m.constructor===Symbol&&m!==Symbol.prototype?"symbol":typeof m})(h)}var e=o(147),b=o(12),g=o(41),f=o(17),c=o(26),u=o(56);function i(h){return h}function a(h,m,S){return h!==void 0?h:m!==void 0?m:S!==void 0?S:void 0}function n(h,m,S,y,s){return a(_(S)===s?y[S]:void 0,h.default,m.default)}function t(h,m,S){if(f(S)!=="number")return a(h.default,m.default);var y=h.stops.length;if(y===1||S<=h.stops[0][0])return h.stops[0][1];if(S>=h.stops[y-1][0])return h.stops[y-1][1];var s=d(h.stops,S);return h.stops[s][1]}function r(h,m,S){var y=h.base!==void 0?h.base:1;if(f(S)!=="number")return a(h.default,m.default);var s=h.stops.length;if(s===1||S<=h.stops[0][0])return h.stops[0][1];if(S>=h.stops[s-1][0])return h.stops[s-1][1];var p=d(h.stops,S),w=function(T,E,C,z){var P=z-C,B=T-C;return P===0?0:E===1?B/P:(Math.pow(E,B)-1)/(Math.pow(E,P)-1)}(S,y,h.stops[p][0],h.stops[p+1][0]),A=h.stops[p][1],k=h.stops[p+1][1],v=c[m.type]||i;if(h.colorSpace&&h.colorSpace!=="rgb"){var x=e[h.colorSpace];v=function(T,E){return x.reverse(x.interpolate(x.forward(T),x.forward(E),w))}}return typeof A.evaluate=="function"?{evaluate:function(){for(var T=arguments.length,E=new Array(T),C=0;CS&&mm&&(p=w-1)}return Math.max(w-1,0)}O.exports={createFunction:function h(m,S){var y,s,p,w=S.type==="color",A=m.stops&&_(m.stops[0][0])==="object",k=A||m.property!==void 0,v=A||!k,x=m.type||(S.function==="interpolated"?"exponential":"interval");if(w&&((m=g({},m)).stops&&(m.stops=m.stops.map(function(L){return[L[0],b.parse(L[1])]})),m.default?m.default=b.parse(m.default):m.default=b.parse(S.default)),m.colorSpace&&m.colorSpace!=="rgb"&&!e[m.colorSpace])throw new Error("Unknown color space: ".concat(m.colorSpace));if(x==="exponential")y=r;else if(x==="interval")y=t;else if(x==="categorical"){y=n,s=Object.create(null);var T=!0,E=!1,C=void 0;try{for(var z,P=m.stops[Symbol.iterator]();!(T=(z=P.next()).done);T=!0){var B=z.value;s[B[0]]=B[1]}}catch(L){E=!0,C=L}finally{try{T||P.return==null||P.return()}finally{if(E)throw C}}p=_(m.stops[0][0])}else{if(x!=="identity")throw new Error('Unknown function type "'.concat(x,'"'));y=l}if(A){for(var F={},Z=[],W=0;W":case">=":t.length>=2&&f(t[1])==="$type"&&h.push(new _(r,t,'"$type" cannot be use with operator "'.concat(t[0],'"')));case"==":case"!=":t.length!==3&&h.push(new _(r,t,'filter array for operator "'.concat(t[0],'" must have 3 elements')));case"in":case"!in":t.length>=2&&(d=g(t[1]))!=="string"&&h.push(new _("".concat(r,"[1]"),t[1],"string expected, ".concat(d," found")));for(var m=2;m=2&&t[1]!=="$id"&&t[1]!=="$type";case"in":case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return t.length===3&&(Array.isArray(t[1])||Array.isArray(t[2]));case"any":case"all":var r=!0,l=!1,d=void 0;try{for(var h,m=t.slice(1)[Symbol.iterator]();!(r=(h=m.next()).done);r=!0){var S=h.value;if(!b(S)&&typeof S!="boolean")return!1}}catch(y){l=!0,d=y}finally{try{r||m.return==null||m.return()}finally{if(l)throw d}}return!0;default:return!0}}O.exports=function(t){if(!t)return function(){return!0};b(t)||(t=c(t));var r=e(t,g);if(r.result==="error")throw new Error(r.value.map(function(l){return"".concat(l.key,": ").concat(l.message)}).join(", "));return function(l,d){return r.value.evaluate(l,d)}},O.exports.isExpressionFilter=b;var g={type:"boolean",default:!1,function:!0,"property-function":!0,"zoom-function":!0};function f(t,r){return tr?1:0}function c(t){if(!t)return!0;var r,l=t[0];return t.length<=1?l!=="any":l==="=="?u(t[1],t[2],"=="):l==="!="?n(u(t[1],t[2],"==")):l==="<"||l===">"||l==="<="||l===">="?u(t[1],t[2],l):l==="any"?(r=t.slice(1),["any"].concat(r.map(c))):l==="all"?["all"].concat(t.slice(1).map(c)):l==="none"?["all"].concat(t.slice(1).map(c).map(n)):l==="in"?i(t[1],t.slice(2)):l==="!in"?n(i(t[1],t.slice(2))):l==="has"?a(t[1]):l!=="!has"||n(a(t[1]))}function u(t,r,l){switch(t){case"$type":return["filter-type-".concat(l),r];case"$id":return["filter-id-".concat(l),r];default:return["filter-".concat(l),t,r]}}function i(t,r){if(r.length===0)return!1;switch(t){case"$type":return["filter-type-in",["literal",r]];case"$id":return["filter-id-in",["literal",r]];default:return r.length>200&&!r.some(function(l){return _(l)!==_(r[0])})?["filter-in-large",t,["literal",r.sort(f)]]:["filter-in-small",t,["literal",r]]}}function a(t){switch(t){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",t]}}function n(t){return["!",t]}},function(O,D,o){function _(g,f){for(var c=0;c0)&&(N.value.kind!=="constant"||N.value.value.length>0),Y=G.value.kind!=="constant"||G.value.value&&G.value.value.length>0;if(this.features=[],H||Y){var $=I.iconDependencies,Q=I.glyphDependencies,tt={zoom:this.zoom},et=!0,nt=!1,ot=void 0;try{for(var it,at=L[Symbol.iterator]();!(et=(it=at.next()).done);et=!0){var st=it.value,rt=st.feature,lt=st.index,ct=st.sourceLayerIndex;if(j._featureFilter(tt,rt)){var ut=void 0;H&&(ut=j.getValueAndResolveTokens("text-field",rt),ut=T(ut,j,rt));var pt=void 0;if(Y&&(pt=j.getValueAndResolveTokens("icon-image",rt)),ut||pt){var ft={text:ut,icon:pt,index:lt,sourceLayerIndex:ct,geometry:z(rt),properties:rt.properties,type:P[rt.type]};if(rt.id!==void 0&&(ft.id=rt.id),this.features.push(ft),pt&&($[pt]=!0),ut){for(var ht=N.evaluate(rt).join(","),mt=Q[ht]=Q[ht]||{},dt=M.get("text-rotation-alignment")==="map"&&M.get("symbol-placement")==="line",vt=C.allowsVerticalWritingMode(ut),yt=0;yt=0;H--)V[H]={x:I[H].x,y:I[H].y,tileUnitDistanceFromAnchor:N},H>0&&(N+=I[H-1].dist(I[H]));for(var Y=0;Y0;this.addCollisionDebugVertices(Q,tt,et,nt,ot?this.collisionCircle:this.collisionBox,$.anchorPoint,V,ot)}}}}catch(it){I=!0,j=it}finally{try{L||N.return==null||N.return()}finally{if(I)throw j}}}},{key:"deserializeCollisionBoxes",value:function(L,I,j,M,N){for(var V={},G=I;G0}},{key:"hasIconData",value:function(){return this.icon.segments.get().length>0}},{key:"hasCollisionBoxData",value:function(){return this.collisionBox.segments.get().length>0}},{key:"hasCollisionCircleData",value:function(){return this.collisionCircle.segments.get().length>0}},{key:"sortFeatures",value:function(L){var I=this;if(this.sortFeaturesByY&&this.sortedAngle!==L&&(this.sortedAngle=L,!(this.text.segments.get().length>1||this.icon.segments.get().length>1))){for(var j=[],M=0;M=65097&&e<=65103)||!!_["CJK Compatibility Ideographs"](e)||!!_["CJK Compatibility"](e)||!!_["CJK Radicals Supplement"](e)||!!_["CJK Strokes"](e)||!(!_["CJK Symbols and Punctuation"](e)||e>=12296&&e<=12305||e>=12308&&e<=12319||e===12336)||!!_["CJK Unified Ideographs Extension A"](e)||!!_["CJK Unified Ideographs"](e)||!!_["Enclosed CJK Letters and Months"](e)||!!_["Hangul Compatibility Jamo"](e)||!!_["Hangul Jamo Extended-A"](e)||!!_["Hangul Jamo Extended-B"](e)||!!_["Hangul Jamo"](e)||!!_["Hangul Syllables"](e)||!!_.Hiragana(e)||!!_["Ideographic Description Characters"](e)||!!_.Kanbun(e)||!!_["Kangxi Radicals"](e)||!!_["Katakana Phonetic Extensions"](e)||!(!_.Katakana(e)||e===12540)||!(!_["Halfwidth and Fullwidth Forms"](e)||e===65288||e===65289||e===65293||e>=65306&&e<=65310||e===65339||e===65341||e===65343||e>=65371&&e<=65503||e===65507||e>=65512&&e<=65519)||!(!_["Small Form Variants"](e)||e>=65112&&e<=65118||e>=65123&&e<=65126)||!!_["Unified Canadian Aboriginal Syllabics"](e)||!!_["Unified Canadian Aboriginal Syllabics Extended"](e)||!!_["Vertical Forms"](e)||!!_["Yijing Hexagram Symbols"](e)||!!_["Yi Syllables"](e)||!!_["Yi Radicals"](e))},D.charHasNeutralVerticalOrientation=function(e){return!(!_["Latin-1 Supplement"](e)||e!==167&&e!==169&&e!==174&&e!==177&&e!==188&&e!==189&&e!==190&&e!==215&&e!==247)||!(!_["General Punctuation"](e)||e!==8214&&e!==8224&&e!==8225&&e!==8240&&e!==8241&&e!==8251&&e!==8252&&e!==8258&&e!==8263&&e!==8264&&e!==8265&&e!==8273)||!!_["Letterlike Symbols"](e)||!!_["Number Forms"](e)||!(!_["Miscellaneous Technical"](e)||!(e>=8960&&e<=8967||e>=8972&&e<=8991||e>=8996&&e<=9e3||e===9003||e>=9085&&e<=9114||e>=9150&&e<=9165||e===9167||e>=9169&&e<=9179||e>=9186&&e<=9215))||!(!_["Control Pictures"](e)||e===9251)||!!_["Optical Character Recognition"](e)||!!_["Enclosed Alphanumerics"](e)||!!_["Geometric Shapes"](e)||!(!_["Miscellaneous Symbols"](e)||e>=9754&&e<=9759)||!(!_["Miscellaneous Symbols and Arrows"](e)||!(e>=11026&&e<=11055||e>=11088&&e<=11097||e>=11192&&e<=11243))||!!_["CJK Symbols and Punctuation"](e)||!!_.Katakana(e)||!!_["Private Use Area"](e)||!!_["CJK Compatibility Forms"](e)||!!_["Small Form Variants"](e)||!!_["Halfwidth and Fullwidth Forms"](e)||e===8734||e===8756||e===8757||e>=9984&&e<=10087||e>=10102&&e<=10131||e===65532||e===65533},D.charHasRotatedVerticalOrientation=function(e){return!(D.charHasUprightVerticalOrientation(e)||D.charHasNeutralVerticalOrientation(e))}},function(O,D){O.exports={API_URL:"https://api.mapbox.com",REQUIRE_ACCESS_TOKEN:!0,ACCESS_TOKEN:null}},function(O,D,o){"use strict";O.exports=e;var _=o(190);function e(y){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(y)?y:new Uint8Array(y||0),this.pos=0,this.type=0,this.length=this.buf.length}e.Varint=0,e.Fixed64=1,e.Bytes=2,e.Fixed32=5;function b(y){return y.type===e.Bytes?y.readVarint()+y.pos:y.pos+1}function g(y,s,p){return p?4294967296*s+(y>>>0):4294967296*(s>>>0)+(y>>>0)}function f(y,s,p){var w=s<=16383?1:s<=2097151?2:s<=268435455?3:Math.floor(Math.log(s)/(7*Math.LN2));p.realloc(w);for(var A=p.pos-1;A>=y;A--)p.buf[A+w]=p.buf[A]}function c(y,s){for(var p=0;p>>8,y[p+2]=s>>>16,y[p+3]=s>>>24}function S(y,s){return(y[s]|y[s+1]<<8|y[s+2]<<16)+(y[s+3]<<24)}e.prototype={destroy:function(){this.buf=null},readFields:function(y,s,p){for(p=p||this.length;this.pos>3,k=this.pos;this.type=7&w,y(A,s,this),this.pos===k&&this.skip(w)}return s},readMessage:function(y,s){return this.readFields(y,s,this.readVarint()+this.pos)},readFixed32:function(){var y=h(this.buf,this.pos);return this.pos+=4,y},readSFixed32:function(){var y=S(this.buf,this.pos);return this.pos+=4,y},readFixed64:function(){var y=h(this.buf,this.pos)+4294967296*h(this.buf,this.pos+4);return this.pos+=8,y},readSFixed64:function(){var y=h(this.buf,this.pos)+4294967296*S(this.buf,this.pos+4);return this.pos+=8,y},readFloat:function(){var y=_.read(this.buf,this.pos,!0,23,4);return this.pos+=4,y},readDouble:function(){var y=_.read(this.buf,this.pos,!0,52,8);return this.pos+=8,y},readVarint:function(y){var s,p,w=this.buf;return s=127&(p=w[this.pos++]),p<128?s:(s|=(127&(p=w[this.pos++]))<<7,p<128?s:(s|=(127&(p=w[this.pos++]))<<14,p<128?s:(s|=(127&(p=w[this.pos++]))<<21,p<128?s:function(A,k,v){var x,T,E=v.buf;if(T=E[v.pos++],x=(112&T)>>4,T<128||(T=E[v.pos++],x|=(127&T)<<3,T<128)||(T=E[v.pos++],x|=(127&T)<<10,T<128)||(T=E[v.pos++],x|=(127&T)<<17,T<128)||(T=E[v.pos++],x|=(127&T)<<24,T<128)||(T=E[v.pos++],x|=(1&T)<<31,T<128))return g(A,x,k);throw new Error("Expected varint not more than 10 bytes")}(s|=(15&(p=w[this.pos]))<<28,y,this))))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var y=this.readVarint();return y%2==1?(y+1)/-2:y/2},readBoolean:function(){return Boolean(this.readVarint())},readString:function(){var y=this.readVarint()+this.pos,s=function(p,w,A){for(var k="",v=w;v239?4:C>223?3:C>191?2:1;if(v+P>A)break;P===1?C<128&&(z=C):P===2?(192&(x=p[v+1]))==128&&(z=(31&C)<<6|63&x)<=127&&(z=null):P===3?(x=p[v+1],T=p[v+2],(192&x)==128&&(192&T)==128&&((z=(15&C)<<12|(63&x)<<6|63&T)<=2047||z>=55296&&z<=57343)&&(z=null)):P===4&&(x=p[v+1],T=p[v+2],E=p[v+3],(192&x)==128&&(192&T)==128&&(192&E)==128&&((z=(15&C)<<18|(63&x)<<12|(63&T)<<6|63&E)<=65535||z>=1114112)&&(z=null)),z===null?(z=65533,P=1):z>65535&&(z-=65536,k+=String.fromCharCode(z>>>10&1023|55296),z=56320|1023&z),k+=String.fromCharCode(z),v+=P}return k}(this.buf,this.pos,y);return this.pos=y,s},readBytes:function(){var y=this.readVarint()+this.pos,s=this.buf.subarray(this.pos,y);return this.pos=y,s},readPackedVarint:function(y,s){if(this.type!==e.Bytes)return y.push(this.readVarint(s));var p=b(this);for(y=y||[];this.pos127;);else if(s===e.Bytes)this.pos=this.readVarint()+this.pos;else if(s===e.Fixed32)this.pos+=4;else{if(s!==e.Fixed64)throw new Error("Unimplemented type: "+s);this.pos+=8}},writeTag:function(y,s){this.writeVarint(y<<3|s)},realloc:function(y){for(var s=this.length||16;s268435455||y<0?function(s,p){var w,A;if(s>=0?(w=s%4294967296|0,A=s/4294967296|0):(A=~(-s/4294967296),4294967295^(w=~(-s%4294967296))?w=w+1|0:(w=0,A=A+1|0)),s>=18446744073709552e3||s<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");p.realloc(10),function(k,v,x){x.buf[x.pos++]=127&k|128,k>>>=7,x.buf[x.pos++]=127&k|128,k>>>=7,x.buf[x.pos++]=127&k|128,k>>>=7,x.buf[x.pos++]=127&k|128,k>>>=7,x.buf[x.pos]=127&k}(w,0,p),function(k,v){var x=(7&k)<<4;v.buf[v.pos++]|=x|((k>>>=3)?128:0),k&&(v.buf[v.pos++]=127&k|((k>>>=7)?128:0),k&&(v.buf[v.pos++]=127&k|((k>>>=7)?128:0),k&&(v.buf[v.pos++]=127&k|((k>>>=7)?128:0),k&&(v.buf[v.pos++]=127&k|((k>>>=7)?128:0),k&&(v.buf[v.pos++]=127&k)))))}(A,p)}(y,this):(this.realloc(4),this.buf[this.pos++]=127&y|(y>127?128:0),y<=127||(this.buf[this.pos++]=127&(y>>>=7)|(y>127?128:0),y<=127||(this.buf[this.pos++]=127&(y>>>=7)|(y>127?128:0),y<=127||(this.buf[this.pos++]=y>>>7&127))))},writeSVarint:function(y){this.writeVarint(y<0?2*-y-1:2*y)},writeBoolean:function(y){this.writeVarint(Boolean(y))},writeString:function(y){y=String(y),this.realloc(4*y.length),this.pos++;var s=this.pos;this.pos=function(w,A,k){for(var v,x,T=0;T55295&&v<57344){if(!x){v>56319||T+1===A.length?(w[k++]=239,w[k++]=191,w[k++]=189):x=v;continue}if(v<56320){w[k++]=239,w[k++]=191,w[k++]=189,x=v;continue}v=x-55296<<10|v-56320|65536,x=null}else x&&(w[k++]=239,w[k++]=191,w[k++]=189,x=null);v<128?w[k++]=v:(v<2048?w[k++]=v>>6|192:(v<65536?w[k++]=v>>12|224:(w[k++]=v>>18|240,w[k++]=v>>12&63|128),w[k++]=v>>6&63|128),w[k++]=63&v|128)}return k}(this.buf,y,this.pos);var p=this.pos-s;p>=128&&f(s,p,this),this.pos=s-1,this.writeVarint(p),this.pos+=p},writeFloat:function(y){this.realloc(4),_.write(this.buf,y,this.pos,!0,23,4),this.pos+=4},writeDouble:function(y){this.realloc(8),_.write(this.buf,y,this.pos,!0,52,8),this.pos+=8},writeBytes:function(y){var s=y.length;this.writeVarint(s),this.realloc(s);for(var p=0;p=128&&f(p,w,this),this.pos=p-1,this.writeVarint(w),this.pos+=w},writeMessage:function(y,s,p){this.writeTag(y,e.Bytes),this.writeRawMessage(s,p)},writePackedVarint:function(y,s){s.length&&this.writeMessage(y,c,s)},writePackedSVarint:function(y,s){s.length&&this.writeMessage(y,u,s)},writePackedBoolean:function(y,s){s.length&&this.writeMessage(y,n,s)},writePackedFloat:function(y,s){s.length&&this.writeMessage(y,i,s)},writePackedDouble:function(y,s){s.length&&this.writeMessage(y,a,s)},writePackedFixed32:function(y,s){s.length&&this.writeMessage(y,t,s)},writePackedSFixed32:function(y,s){s.length&&this.writeMessage(y,r,s)},writePackedFixed64:function(y,s){s.length&&this.writeMessage(y,l,s)},writePackedSFixed64:function(y,s){s.length&&this.writeMessage(y,d,s)},writeBytesField:function(y,s){this.writeTag(y,e.Bytes),this.writeBytes(s)},writeFixed32Field:function(y,s){this.writeTag(y,e.Fixed32),this.writeFixed32(s)},writeSFixed32Field:function(y,s){this.writeTag(y,e.Fixed32),this.writeSFixed32(s)},writeFixed64Field:function(y,s){this.writeTag(y,e.Fixed64),this.writeFixed64(s)},writeSFixed64Field:function(y,s){this.writeTag(y,e.Fixed64),this.writeSFixed64(s)},writeVarintField:function(y,s){this.writeTag(y,e.Varint),this.writeVarint(s)},writeSVarintField:function(y,s){this.writeTag(y,e.Varint),this.writeSVarint(s)},writeStringField:function(y,s){this.writeTag(y,e.Bytes),this.writeString(s)},writeFloatField:function(y,s){this.writeTag(y,e.Fixed32),this.writeFloat(s)},writeDoubleField:function(y,s){this.writeTag(y,e.Fixed64),this.writeDouble(s)},writeBooleanField:function(y,s){this.writeVarintField(y,Boolean(s))}}},function(O,D,o){var _=o(3),e=o(22),b=e.mat4,g=e.vec4,f=o(50),c=o(62).addDynamicAttributes,u=o(51).layout,i=o(205).WritingMode;function a(s,p){var w=[s.x,s.y,0,1];y(w,w,p);var A=w[3];return{point:new _(w[0]/A,w[1]/A),signedDistanceFromCamera:A}}function n(s,p){var w=s[0]/s[3],A=s[1]/s[3];return w>=-p[0]&&w<=p[0]&&A>=-p[1]&&A<=p[1]}function t(s,p,w,A,k,v,x,T,E,C,z,P){var B=T.glyphStartIndex+T.numGlyphs,F=T.lineStartIndex,Z=T.lineStartIndex+T.lineLength,W=p.getoffsetX(T.glyphStartIndex),J=p.getoffsetX(B-1),X=h(s*W,w,A,k,v,x,T.segment,F,Z,E,C,z,P);if(!X)return null;var R=h(s*J,w,A,k,v,x,T.segment,F,Z,E,C,z,P);return R?{first:X,last:R}:null}function r(s,p,w,A){return s===i.horizontal&&Math.abs(w.y-p.y)>Math.abs(w.x-p.x)*A?{useVertical:!0}:(s===i.vertical?p.yw.x)?{needsFlipping:!0}:null}function l(s,p,w,A,k,v,x,T,E,C,z,P,B,F){var Z,W=p/24,J=s.lineOffsetX*p,X=s.lineOffsetY*p;if(s.numGlyphs>1){var R=s.glyphStartIndex+s.numGlyphs,U=s.lineStartIndex,K=s.lineStartIndex+s.lineLength,q=t(W,T,J,X,w,z,P,s,E,v,B,!1);if(!q)return{notEnoughRoom:!0};var L=a(q.first.point,x).point,I=a(q.last.point,x).point;if(A&&!w){var j=r(s.writingMode,L,I,F);if(j)return j}Z=[q.first];for(var M=s.glyphStartIndex+1;M0?H.point:d(P,G,N,1,k),$=r(s.writingMode,N,Y,F);if($)return $}var Q=h(W*T.getoffsetX(s.glyphStartIndex),J,X,w,z,P,s.segment,s.lineStartIndex,s.lineStartIndex+s.lineLength,E,v,B,!1);if(!Q)return{notEnoughRoom:!0};Z=[Q]}var tt=!0,et=!1,nt=void 0;try{for(var ot,it=Z[Symbol.iterator]();!(tt=(ot=it.next()).done);tt=!0){var at=ot.value;c(C,at.point,at.angle)}}catch(st){et=!0,nt=st}finally{try{tt||it.return==null||it.return()}finally{if(et)throw nt}}return{}}function d(s,p,w,A,k){var v=a(s.add(s.sub(p)._unit()),k).point,x=w.sub(v);return w.add(x._mult(A/x.mag()))}function h(s,p,w,A,k,v,x,T,E,C,z,P,B){var F=A?s-p:s+p,Z=F>0?1:-1,W=0;A&&(Z*=-1,W=Math.PI),Z<0&&(W+=Math.PI);for(var J=Z>0?T+x:T+x+1,X=J,R=k,U=k,K=0,q=0,L=Math.abs(F);K+q<=L;){if((J+=Z)=E)return null;if(U=R,(R=P[J])===void 0){var I=new _(C.getx(J),C.gety(J)),j=a(I,z);if(j.signedDistanceFromCamera>0)R=P[J]=j.point;else{var M=J-Z;R=d(K===0?v:new _(C.getx(M),C.gety(M)),I,U,L-K+1,z)}}K+=q,q=U.dist(R)}var N=(L-K)/q,V=R.sub(U),G=V.mult(N)._add(U);return G._add(V._unit()._perp()._mult(w*Z)),{point:G,angle:W+Math.atan2(R.y-U.y,R.x-U.x),tileDistance:B?{prevTileDistance:J-Z===X?0:C.gettileUnitDistanceFromAnchor(J-Z),lastSegmentViewportDistance:L-K}:null}}O.exports={updateLineLabels:function(s,p,w,A,k,v,x,T){var E=A?s.textSizeData:s.iconSizeData,C=f.evaluateSizeForZoom(E,w.transform.zoom,u.properties[A?"text-size":"icon-size"]),z=[256/w.width*2+1,256/w.height*2+1],P=A?s.text.dynamicLayoutVertexArray:s.icon.dynamicLayoutVertexArray;P.clear();for(var B=s.lineVertexArray,F=A?s.text.placedSymbolArray:s.icon.placedSymbolArray,Z=w.transform.width/w.transform.height,W=!1,J=0;J0,H=H&&Y.offscreen);var tt=N.collisionArrays.textCircles;if(tt){var et=x.text.placedSymbolArray.get(N.placedTextSymbolIndices[0]),nt=c.evaluateSizeForFeature(x.textSizeData,R,et);$=this.collisionIndex.placeCollisionCircles(tt,X.get("text-allow-overlap"),z,P,N.key,et,x.lineVertexArray,x.glyphOffsetArray,nt,T,E,B,X.get("text-pitch-alignment")==="map"),V=X.get("text-allow-overlap")||$.circles.length>0,H=H&&$.offscreen}N.collisionArrays.iconBox&&(G=(Q=this.collisionIndex.placeCollisionBox(N.collisionArrays.iconBox,X.get("icon-allow-overlap"),P,T)).box.length>0,H=H&&Q.offscreen),U||K?K?U||(G=G&&V):V=G&&V:G=V=G&&V,V&&Y&&this.collisionIndex.insertCollisionBox(Y.box,X.get("text-ignore-placement"),W,J,x.bucketInstanceId,N.textBoxStartIndex),G&&Q&&this.collisionIndex.insertCollisionBox(Q.box,X.get("icon-ignore-placement"),W,J,x.bucketInstanceId,N.iconBoxStartIndex),V&&$&&this.collisionIndex.insertCollisionCircles($.circles,X.get("text-ignore-placement"),W,J,x.bucketInstanceId,N.textBoxStartIndex),a(N.crossTileID!==0),a(x.bucketInstanceId!==0),this.placements[N.crossTileID]=new l(V,G,H||x.justReloaded),F[N.crossTileID]=!0}}}catch(ot){L=!0,I=ot}finally{try{q||M.return==null||M.return()}finally{if(L)throw I}}x.justReloaded=!1}},{key:"commit",value:function(x,T){this.commitTime=T;var E=!1,C=x&&this.fadeDuration!==0?(this.commitTime-x.commitTime)/this.fadeDuration:1,z=x?x.opacities:{};for(var P in this.placements){var B=this.placements[P],F=z[P];F?(this.opacities[P]=new r(F,C,B.text,B.icon),E=E||B.text!==F.text.placed||B.icon!==F.icon.placed):(this.opacities[P]=new r(null,C,B.text,B.icon,B.skipFade),E=E||B.text||B.icon)}for(var Z in z){var W=z[Z];if(!this.opacities[Z]){var J=new r(W,C,!1,!1);J.isHidden()||(this.opacities[Z]=J,E=E||W.text.placed||W.icon.placed)}}return E}},{key:"updateLayerOpacities",value:function(x,T){var E={},C=!0,z=!1,P=void 0;try{for(var B,F=T[Symbol.iterator]();!(C=(B=F.next()).done);C=!0){var Z=B.value,W=Z.getBucket(x);W&&this.updateBucketOpacities(W,E,Z.collisionBoxArray)}}catch(J){z=!0,P=J}finally{try{C||F.return==null||F.return()}finally{if(z)throw P}}}},{key:"updateBucketOpacities",value:function(x,T,E){x.hasTextData()&&x.text.opacityVertexArray.clear(),x.hasIconData()&&x.icon.opacityVertexArray.clear(),x.hasCollisionBoxData()&&x.collisionBox.collisionVertexArray.clear(),x.hasCollisionCircleData()&&x.collisionCircle.collisionVertexArray.clear();for(var C=x.layers[0].layout,z=new r(null,0,C.get("text-allow-overlap"),C.get("icon-allow-overlap"),!0),P=0;P0||B.numVerticalGlyphVertices>0,J=B.numIconVertices>0;if(W){for(var X=k(Z.text),R=(B.numGlyphVertices+B.numVerticalGlyphVertices)/4,U=0;Ux}},{key:"setRecent",value:function(x,T){this.stale=T,this.recentUntil=x+this.fadeDuration}},{key:"setStale",value:function(){this.stale=!0}}]),v}();function h(v,x,T){v.emplaceBack(x?1:0,T?1:0),v.emplaceBack(x?1:0,T?1:0),v.emplaceBack(x?1:0,T?1:0),v.emplaceBack(x?1:0,T?1:0)}var m=Math.pow(2,25),S=Math.pow(2,24),y=Math.pow(2,17),s=Math.pow(2,16),p=Math.pow(2,9),w=Math.pow(2,8),A=Math.pow(2,1);function k(v){if(v.opacity===0&&!v.placed)return 0;if(v.opacity===1&&v.placed)return 4294967295;var x=v.placed?1:0,T=Math.floor(127*v.opacity);return T*m+x*S+T*y+x*s+T*p+x*w+T*A+x}O.exports=d},function(O,D,o){var _=o(1),e=o(28);D.isPatternMissing=function(b,g){if(!b)return!1;var f=g.imageManager.getPattern(b.from),c=g.imageManager.getPattern(b.to);return!f||!c},D.prepare=function(b,g,f){var c=g.context,u=c.gl,i=g.imageManager.getPattern(b.from),a=g.imageManager.getPattern(b.to);_(i&&a),u.uniform1i(f.uniforms.u_image,0),u.uniform2fv(f.uniforms.u_pattern_tl_a,i.tl),u.uniform2fv(f.uniforms.u_pattern_br_a,i.br),u.uniform2fv(f.uniforms.u_pattern_tl_b,a.tl),u.uniform2fv(f.uniforms.u_pattern_br_b,a.br);var n=g.imageManager.getPixelSize(),t=n.width,r=n.height;u.uniform2fv(f.uniforms.u_texsize,[t,r]),u.uniform1f(f.uniforms.u_mix,b.t),u.uniform2fv(f.uniforms.u_pattern_size_a,i.displaySize),u.uniform2fv(f.uniforms.u_pattern_size_b,a.displaySize),u.uniform1f(f.uniforms.u_scale_a,b.fromScale),u.uniform1f(f.uniforms.u_scale_b,b.toScale),c.activeTexture.set(u.TEXTURE0),g.imageManager.bind(g.context)},D.setTile=function(b,g,f){var c=g.context.gl;c.uniform1f(f.uniforms.u_tile_units_to_pixels,1/e(b,1,g.transform.tileZoom(b)));var u=Math.pow(2,b.tileID.overscaledZ),i=b.tileSize*Math.pow(2,g.transform.tileZoom(b))/u,a=i*(b.tileID.canonical.x+b.tileID.wrap*u),n=i*b.tileID.canonical.y;c.uniform2f(f.uniforms.u_pixel_coord_upper,a>>16,n>>16),c.uniform2f(f.uniforms.u_pixel_coord_lower,65535&a,65535&n)}},function(O,D,o){var _=o(72),e=o(2),b=o(132).version,g=o(133),f=o(295),c=o(296),u=o(128),i=o(297),a=o(298),n=o(299),t=o(129),r=o(53),l=o(21),d=o(39),h=o(3),m=o(10),S=o(64),y=o(49),s=o(300);O.exports={version:b,supported:_,workerCount:Math.max(Math.floor(e.hardwareConcurrency/2),1),setRTLTextPlugin:y.setRTLTextPlugin,Map:g,NavigationControl:f,GeolocateControl:c,AttributionControl:u,ScaleControl:i,FullscreenControl:a,Popup:n,Marker:t,Style:r,LngLat:l,LngLatBounds:d,Point:h,Evented:m,config:S,BasicRenderer:s,get accessToken(){return S.ACCESS_TOKEN},set accessToken(p){S.ACCESS_TOKEN=p}}},function(O,D,o){"use strict";function _(b){return!!(typeof window<"u"&&typeof document<"u"&&Array.prototype&&Array.prototype.every&&Array.prototype.filter&&Array.prototype.forEach&&Array.prototype.indexOf&&Array.prototype.lastIndexOf&&Array.prototype.map&&Array.prototype.some&&Array.prototype.reduce&&Array.prototype.reduceRight&&Array.isArray&&Function.prototype&&Function.prototype.bind&&Object.keys&&Object.create&&Object.getPrototypeOf&&Object.getOwnPropertyNames&&Object.isSealed&&Object.isFrozen&&Object.isExtensible&&Object.getOwnPropertyDescriptor&&Object.defineProperty&&Object.defineProperties&&Object.seal&&Object.freeze&&Object.preventExtensions&&"JSON"in window&&"parse"in JSON&&"stringify"in JSON&&function(){if(!("Worker"in window&&"Blob"in window&&"URL"in window))return!1;var g,f,c=new Blob([""],{type:"text/javascript"}),u=URL.createObjectURL(c);try{f=new Worker(u),g=!0}catch{g=!1}return f&&f.terminate(),URL.revokeObjectURL(u),g}()&&"Uint8ClampedArray"in window&&ArrayBuffer.isView&&function(g){return e[g]===void 0&&(e[g]=function(f){var c=document.createElement("canvas"),u=Object.create(_.webGLContextAttributes);return u.failIfMajorPerformanceCaveat=f,c.probablySupportsContext?c.probablySupportsContext("webgl",u)||c.probablySupportsContext("experimental-webgl",u):c.supportsContext?c.supportsContext("webgl",u)||c.supportsContext("experimental-webgl",u):c.getContext("webgl",u)||c.getContext("experimental-webgl",u)}(g)),e[g]}(b&&b.failIfMajorPerformanceCaveat))}O.exports?O.exports=_:window&&(window.mapboxgl=window.mapboxgl||{},window.mapboxgl.supported=_);var e={};_.webGLContextAttributes={antialias:!1,alpha:!0,stencil:!0,depth:!0}},function(O,D){function o(_,e,b,g){this.cx=3*_,this.bx=3*(b-_)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*e,this.by=3*(g-e)-this.cy,this.ay=1-this.cy-this.by,this.p1x=_,this.p1y=g,this.p2x=b,this.p2y=g}O.exports=o,o.prototype.sampleCurveX=function(_){return((this.ax*_+this.bx)*_+this.cx)*_},o.prototype.sampleCurveY=function(_){return((this.ay*_+this.by)*_+this.cy)*_},o.prototype.sampleCurveDerivativeX=function(_){return(3*this.ax*_+2*this.bx)*_+this.cx},o.prototype.solveCurveX=function(_,e){var b,g,f,c,u;for(e===void 0&&(e=1e-6),f=_,u=0;u<8;u++){if(c=this.sampleCurveX(f)-_,Math.abs(c)(g=1))return g;for(;bc?b=f:g=f,f=.5*(g-b)+b}return f},o.prototype.solve=function(_,e){return this.sampleCurveY(this.solveCurveX(_,e))}},function(O,D){function o(_){return(o=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})(_)}O.exports=function _(e,b){if(Array.isArray(e)){if(!Array.isArray(b)||e.length!==b.length)return!1;for(var g=0;g"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}}()?Reflect.construct:function(n,t,r){var l=[null];l.push.apply(l,t);var d=new(Function.bind.apply(n,l));return r&&g(d,r.prototype),d}).apply(null,arguments)}function g(u,i){return(g=Object.setPrototypeOf||function(a,n){return a.__proto__=n,a})(u,i)}function f(u){return(f=Object.setPrototypeOf?Object.getPrototypeOf:function(i){return i.__proto__||Object.getPrototypeOf(i)})(u)}var c=function(u){function i(a,n){var t;return function(r,l){if(!(r instanceof l))throw new TypeError("Cannot call a class as a function")}(this,i),(t=_(this,f(i).call(this,n))).message=n,t.key=a,t}return function(a,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function");a.prototype=Object.create(n&&n.prototype,{constructor:{value:a,writable:!0,configurable:!0}}),n&&g(a,n)}(i,e(Error)),i}();O.exports=c},function(O,D,o){function _(t){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r})(t)}function e(t,r){for(var l=0;l1&&arguments[1]!==void 0?arguments[1]:[],S=arguments.length>2?arguments[2]:void 0,y=arguments.length>3&&arguments[3]!==void 0?arguments[3]:new b,s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[];(function(p,w){if(!(p instanceof w))throw new TypeError("Cannot call a class as a function")})(this,t),this.registry=h,this.path=m,this.key=m.map(function(p){return"[".concat(p,"]")}).join(""),this.scope=y,this.errors=s,this.expectedType=S}var r,l,d;return r=t,(l=[{key:"parse",value:function(h,m,S,y){var s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{},p=this;if(m&&(p=p.concat(m,S,y)),h!==null&&typeof h!="string"&&typeof h!="boolean"&&typeof h!="number"||(h=["literal",h]),Array.isArray(h)){if(h.length===0)return p.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');var w=h[0];if(typeof w!="string")return p.error("Expression name must be a string, but found ".concat(_(w),' instead. If you wanted a literal array, use ["literal", [...]].'),0),null;var A=p.registry[w];if(A){var k=A.parse(h,p);if(!k)return null;if(p.expectedType){var v=p.expectedType,x=k.type;if(v.kind!=="string"&&v.kind!=="number"&&v.kind!=="boolean"||x.kind!=="value")if(v.kind==="array"&&x.kind==="value")s.omitTypeAnnotations||(k=new i(v,k));else if(v.kind!=="color"||x.kind!=="value"&&x.kind!=="string"){if(p.checkSubtype(p.expectedType,k.type))return null}else s.omitTypeAnnotations||(k=new a(v,[k]));else s.omitTypeAnnotations||(k=new u(v,[k]))}if(!(k instanceof c)&&function(E){var C=o(42).CompoundExpression,z=o(84),P=z.isGlobalPropertyConstant,B=z.isFeatureConstant,F=o(85);if(E instanceof F||E instanceof C&&E.name==="error")return!1;var Z=!0;return E.eachChild(function(W){W instanceof c||(Z=!1)}),Z?B(E)&&P(E,["zoom","heatmap-density"]):!1}(k)){var T=new(o(55));try{k=new c(k.type,k.evaluate(T))}catch(E){return p.error(E.message),null}}return k}return p.error('Unknown expression "'.concat(w,'". If you wanted a literal array, use ["literal", [...]].'),0)}return h===void 0?p.error("'undefined' value invalid. Use null instead."):_(h)==="object"?p.error('Bare objects invalid. Use ["literal", {...}] instead.'):p.error("Expected an array, but found ".concat(_(h)," instead."))}},{key:"concat",value:function(h,m,S){var y=typeof h=="number"?this.path.concat(h):this.path,s=S?this.scope.concat(S):this.scope;return new t(this.registry,y,m||null,s,this.errors)}},{key:"error",value:function(h){for(var m=arguments.length,S=new Array(m>1?m-1:0),y=1;y1&&arguments[1]!==void 0?arguments[1]:[];(function(S,y){if(!(S instanceof y))throw new TypeError("Cannot call a class as a function")})(this,b),this.parent=u,this.bindings={};var a=!0,n=!1,t=void 0;try{for(var r,l=i[Symbol.iterator]();!(a=(r=l.next()).done);a=!0){var d=o(r.value,2),h=d[0],m=d[1];this.bindings[h]=m}}catch(S){n=!0,t=S}finally{try{a||l.return==null||l.return()}finally{if(n)throw t}}}var g,f,c;return g=b,(f=[{key:"concat",value:function(u){return new b(this,u)}},{key:"get",value:function(u){if(this.bindings[u])return this.bindings[u];if(this.parent)return this.parent.get(u);throw new Error("".concat(u," not found in scope."))}},{key:"has",value:function(u){return!!this.bindings[u]||!!this.parent&&this.parent.has(u)}}])&&_(g.prototype,f),c&&_(g,c),b}();O.exports=e},function(O,D,o){function _(c,u){for(var i=0;i255?255:c}function e(c){return c<0?0:c>1?1:c}function b(c){return c[c.length-1]==="%"?_(parseFloat(c)/100*255):_(parseInt(c))}function g(c){return c[c.length-1]==="%"?e(parseFloat(c)/100):e(parseFloat(c))}function f(c,u,i){return i<0?i+=1:i>1&&(i-=1),6*i<1?c+(u-c)*i*6:2*i<1?u:3*i<2?c+(u-c)*(.6666666666666666-i)*6:c}try{D.parseCSSColor=function(c){var u,i=c.replace(/ /g,"").toLowerCase();if(i in o)return o[i].slice();if(i[0]==="#")return i.length===4?(u=parseInt(i.substr(1),16))>=0&&u<=4095?[(3840&u)>>4|(3840&u)>>8,240&u|(240&u)>>4,15&u|(15&u)<<4,1]:null:i.length===7&&(u=parseInt(i.substr(1),16))>=0&&u<=16777215?[(16711680&u)>>16,(65280&u)>>8,255&u,1]:null;var a=i.indexOf("("),n=i.indexOf(")");if(a!==-1&&n+1===i.length){var t=i.substr(0,a),r=i.substr(a+1,n-(a+1)).split(","),l=1;switch(t){case"rgba":if(r.length!==4)return null;l=g(r.pop());case"rgb":return r.length!==3?null:[b(r[0]),b(r[1]),b(r[2]),l];case"hsla":if(r.length!==4)return null;l=g(r.pop());case"hsl":if(r.length!==3)return null;var d=(parseFloat(r[0])%360+360)%360/360,h=g(r[1]),m=g(r[2]),S=m<=.5?m*(h+1):m+h-m*h,y=2*m-S;return[_(255*f(y,S,d+.3333333333333333)),_(255*f(y,S,d)),_(255*f(y,S,d-.3333333333333333)),l];default:return null}}return null}}catch{}},function(O,D,o){function _(S){return function(y){if(Array.isArray(y)){for(var s=0,p=new Array(y.length);s4)return s.error("Expected 1, 2, or 3 arguments, but found ".concat(y.length-1," instead."));var p,w;if(y.length>2){var A=y[1];if(typeof A!="string"||!(A in r))return s.error('The item type argument of "array" must be one of string, number, boolean',1);p=r[A]}else p=f;if(y.length>3){if(typeof y[2]!="number"||y[2]<0||y[2]!==Math.floor(y[2]))return s.error('The length argument to "array" must be a positive integer literal',2);w=y[2]}var k=g(p,w),v=s.parse(y[y.length-1],y.length-1,f);return v?new d(k,v):null}}],(m=[{key:"evaluate",value:function(y){var s=this.input.evaluate(y);if(a(this.type,n(s)))throw new t("Expected value to be of type ".concat(b(this.type),", but found ").concat(b(n(s))," instead."));return s}},{key:"eachChild",value:function(y){y(this.input)}},{key:"possibleOutputs",value:function(){return this.input.possibleOutputs()}}])&&_(h.prototype,m),S&&_(h,S),d}();O.exports=l},function(O,D,o){function _(d){return function(h){if(Array.isArray(h)){for(var m=0,S=new Array(h.length);m4?"Invalid rbga value ".concat(JSON.stringify(s),": expected an array containing either three or four numeric values."):n(s[0],s[1],s[2],s[3])))return new a(s[0]/255,s[1]/255,s[2]/255,s[3])}catch(W){A=!0,k=W}finally{try{w||x.return==null||x.return()}finally{if(A)throw k}}throw new t(p||"Could not parse color from value '".concat(typeof s=="string"?s:JSON.stringify(s),"'"))}var E=null,C=!0,z=!1,P=void 0;try{for(var B,F=this.args[Symbol.iterator]();!(C=(B=F.next()).done);C=!0)if((E=B.value.evaluate(y))!==null){var Z=Number(E);if(!isNaN(Z))return Z}}catch(W){z=!0,P=W}finally{try{C||F.return==null||F.return()}finally{if(z)throw P}}throw new t("Could not convert ".concat(JSON.stringify(E)," to number."))}},{key:"eachChild",value:function(y){this.args.forEach(y)}},{key:"possibleOutputs",value:function(){var y;return(y=[]).concat.apply(y,_(this.args.map(function(s){return s.possibleOutputs()})))}}])&&e(h.prototype,m),S&&e(h,S),d}();O.exports=l},function(O,D,o){var _=o(42).CompoundExpression;O.exports={isFeatureConstant:function e(b){if(b instanceof _&&(b.name==="get"&&b.args.length===1||b.name==="has"&&b.args.length===1||b.name==="properties"||b.name==="geometry-type"||b.name==="id"||b.name.startsWith("filter-")))return!1;var g=!0;return b.eachChild(function(f){g&&!e(f)&&(g=!1)}),g},isGlobalPropertyConstant:function e(b,g){if(b instanceof _&&g.indexOf(b.name)>=0)return!1;var f=!0;return b.eachChild(function(c){f&&!e(c,g)&&(f=!1)}),f}}},function(O,D){function o(e,b){for(var g=0;g=k)return h.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',x);var E=h.parse(v,T,w);if(!E)return null;w=w||E.type,p.push([k,E])}return new n(w,y,p)}}],(r=[{key:"evaluate",value:function(d){var h=this.labels,m=this.outputs;if(h.length===1)return m[0].evaluate(d);var S=this.input.evaluate(d);if(S<=h[0])return m[0].evaluate(d);var y=h.length;return S>=h[y-1]?m[y-1].evaluate(d):m[i(h,S)].evaluate(d)}},{key:"eachChild",value:function(d){d(this.input);var h=!0,m=!1,S=void 0;try{for(var y,s=this.outputs[Symbol.iterator]();!(h=(y=s.next()).done);h=!0)d(y.value)}catch(p){m=!0,S=p}finally{try{h||s.return==null||s.return()}finally{if(m)throw S}}}},{key:"possibleOutputs",value:function(){var d;return(d=[]).concat.apply(d,_(this.outputs.map(function(h){return h.possibleOutputs()})))}}])&&c(t.prototype,r),l&&c(t,l),n}();O.exports=a},function(O,D,o){var _=o(31);O.exports={findStopLessThanOrEqualTo:function(e,b){for(var g,f,c=0,u=e.length-1,i=0;c<=u;){if(g=e[i=Math.floor((c+u)/2)],f=e[i+1],b===g||b>g&&bb))throw new _("Input is not a number.");u=i-1}}return Math.max(i-1,0)}}},function(O,D,o){function _(i){return function(a){if(Array.isArray(a)){for(var n=0,t=new Array(a.length);nH.evaluate(M)}function I(M,N){var V=b(N,2),G=V[0],H=V[1];return G.evaluate(M)<=H.evaluate(M)}function j(M,N){var V=b(N,2),G=V[0],H=V[1];return G.evaluate(M)>=H.evaluate(M)}s.register(J,{error:[t,[c],function(M,N){var V=b(N,1)[0];throw new w(V.evaluate(M))}],typeof:[c,[n],function(M,N){var V=b(N,1)[0];return l(h(V.evaluate(M)))}],"to-string":[c,[n],function(M,N){var V=b(N,1)[0],G=e(V=V.evaluate(M));return V===null||G==="string"||G==="number"||G==="boolean"?String(V):V instanceof m?V.toString():JSON.stringify(V)}],"to-boolean":[u,[n],function(M,N){var V=b(N,1)[0];return Boolean(V.evaluate(M))}],"to-rgba":[r(f,4),[i],function(M,N){var V=b(N,1)[0].evaluate(M),G=V.r,H=V.g,Y=V.b,$=V.a;return[255*G/$,255*H/$,255*Y/$,$]}],rgb:[i,[f,f,f],X],rgba:[i,[f,f,f,f],X],length:{type:f,overloads:[[[c],K],[[r(n)],K]]},has:{type:u,overloads:[[[c],function(M,N){return R(b(N,1)[0].evaluate(M),M.properties())}],[[c,a],function(M,N){var V=b(N,2),G=V[0],H=V[1];return R(G.evaluate(M),H.evaluate(M))}]]},get:{type:n,overloads:[[[c],function(M,N){return U(b(N,1)[0].evaluate(M),M.properties())}],[[c,a],function(M,N){var V=b(N,2),G=V[0],H=V[1];return U(G.evaluate(M),H.evaluate(M))}]]},properties:[a,[],function(M){return M.properties()}],"geometry-type":[c,[],function(M){return M.geometryType()}],id:[n,[],function(M){return M.id()}],zoom:[f,[],function(M){return M.globals.zoom}],"heatmap-density":[f,[],function(M){return M.globals.heatmapDensity||0}],"+":[f,p(f),function(M,N){var V=0,G=!0,H=!1,Y=void 0;try{for(var $,Q=N[Symbol.iterator]();!(G=($=Q.next()).done);G=!0)V+=$.value.evaluate(M)}catch(tt){H=!0,Y=tt}finally{try{G||Q.return==null||Q.return()}finally{if(H)throw Y}}return V}],"*":[f,p(f),function(M,N){var V=1,G=!0,H=!1,Y=void 0;try{for(var $,Q=N[Symbol.iterator]();!(G=($=Q.next()).done);G=!0)V*=$.value.evaluate(M)}catch(tt){H=!0,Y=tt}finally{try{G||Q.return==null||Q.return()}finally{if(H)throw Y}}return V}],"-":{type:f,overloads:[[[f,f],function(M,N){var V=b(N,2),G=V[0],H=V[1];return G.evaluate(M)-H.evaluate(M)}],[[f],function(M,N){return-b(N,1)[0].evaluate(M)}]]},"/":[f,[f,f],function(M,N){var V=b(N,2),G=V[0],H=V[1];return G.evaluate(M)/H.evaluate(M)}],"%":[f,[f,f],function(M,N){var V=b(N,2),G=V[0],H=V[1];return G.evaluate(M)%H.evaluate(M)}],ln2:[f,[],function(){return Math.LN2}],pi:[f,[],function(){return Math.PI}],e:[f,[],function(){return Math.E}],"^":[f,[f,f],function(M,N){var V=b(N,2),G=V[0],H=V[1];return Math.pow(G.evaluate(M),H.evaluate(M))}],sqrt:[f,[f],function(M,N){var V=b(N,1)[0];return Math.sqrt(V.evaluate(M))}],log10:[f,[f],function(M,N){var V=b(N,1)[0];return Math.log10(V.evaluate(M))}],ln:[f,[f],function(M,N){var V=b(N,1)[0];return Math.log(V.evaluate(M))}],log2:[f,[f],function(M,N){var V=b(N,1)[0];return Math.log2(V.evaluate(M))}],sin:[f,[f],function(M,N){var V=b(N,1)[0];return Math.sin(V.evaluate(M))}],cos:[f,[f],function(M,N){var V=b(N,1)[0];return Math.cos(V.evaluate(M))}],tan:[f,[f],function(M,N){var V=b(N,1)[0];return Math.tan(V.evaluate(M))}],asin:[f,[f],function(M,N){var V=b(N,1)[0];return Math.asin(V.evaluate(M))}],acos:[f,[f],function(M,N){var V=b(N,1)[0];return Math.acos(V.evaluate(M))}],atan:[f,[f],function(M,N){var V=b(N,1)[0];return Math.atan(V.evaluate(M))}],min:[f,p(f),function(M,N){return Math.min.apply(Math,_(N.map(function(V){return V.evaluate(M)})))}],max:[f,p(f),function(M,N){return Math.max.apply(Math,_(N.map(function(V){return V.evaluate(M)})))}],"filter-==":[u,[c,n],function(M,N){var V=b(N,2),G=V[0],H=V[1];return M.properties()[G.value]===H.value}],"filter-id-==":[u,[n],function(M,N){var V=b(N,1)[0];return M.id()===V.value}],"filter-type-==":[u,[c],function(M,N){var V=b(N,1)[0];return M.geometryType()===V.value}],"filter-<":[u,[c,n],function(M,N){var V=b(N,2),G=V[0],H=V[1],Y=M.properties()[G.value],$=H.value;return e(Y)===e($)&&Y<$}],"filter-id-<":[u,[n],function(M,N){var V=b(N,1)[0],G=M.id(),H=V.value;return e(G)===e(H)&&G":[u,[c,n],function(M,N){var V=b(N,2),G=V[0],H=V[1],Y=M.properties()[G.value],$=H.value;return e(Y)===e($)&&Y>$}],"filter-id->":[u,[n],function(M,N){var V=b(N,1)[0],G=M.id(),H=V.value;return e(G)===e(H)&&G>H}],"filter-<=":[u,[c,n],function(M,N){var V=b(N,2),G=V[0],H=V[1],Y=M.properties()[G.value],$=H.value;return e(Y)===e($)&&Y<=$}],"filter-id-<=":[u,[n],function(M,N){var V=b(N,1)[0],G=M.id(),H=V.value;return e(G)===e(H)&&G<=H}],"filter->=":[u,[c,n],function(M,N){var V=b(N,2),G=V[0],H=V[1],Y=M.properties()[G.value],$=H.value;return e(Y)===e($)&&Y>=$}],"filter-id->=":[u,[n],function(M,N){var V=b(N,1)[0],G=M.id(),H=V.value;return e(G)===e(H)&&G>=H}],"filter-has":[u,[n],function(M,N){return b(N,1)[0].value in M.properties()}],"filter-has-id":[u,[],function(M){return M.id()!==null}],"filter-type-in":[u,[r(c)],function(M,N){return b(N,1)[0].value.indexOf(M.geometryType())>=0}],"filter-id-in":[u,[r(n)],function(M,N){return b(N,1)[0].value.indexOf(M.id())>=0}],"filter-in-small":[u,[c,r(n)],function(M,N){var V=b(N,2),G=V[0];return V[1].value.indexOf(M.properties()[G.value])>=0}],"filter-in-large":[u,[c,r(n)],function(M,N){var V=b(N,2),G=V[0],H=V[1];return function(Y,$,Q,tt){for(;Q<=tt;){var et=Q+tt>>1;if($[et]===Y)return!0;$[et]>Y?tt=et-1:Q=et+1}return!1}(M.properties()[G.value],H.value,0,H.value.length-1)}],">":{type:u,overloads:[[[f,f],L],[[c,c],L]]},"<":{type:u,overloads:[[[f,f],q],[[c,c],q]]},">=":{type:u,overloads:[[[f,f],j],[[c,c],j]]},"<=":{type:u,overloads:[[[f,f],I],[[c,c],I]]},all:{type:u,overloads:[[[u,u],function(M,N){var V=b(N,2),G=V[0],H=V[1];return G.evaluate(M)&&H.evaluate(M)}],[p(u),function(M,N){var V=!0,G=!1,H=void 0;try{for(var Y,$=N[Symbol.iterator]();!(V=(Y=$.next()).done);V=!0)if(!Y.value.evaluate(M))return!1}catch(Q){G=!0,H=Q}finally{try{V||$.return==null||$.return()}finally{if(G)throw H}}return!0}]]},any:{type:u,overloads:[[[u,u],function(M,N){var V=b(N,2),G=V[0],H=V[1];return G.evaluate(M)||H.evaluate(M)}],[p(u),function(M,N){var V=!0,G=!1,H=void 0;try{for(var Y,$=N[Symbol.iterator]();!(V=(Y=$.next()).done);V=!0)if(Y.value.evaluate(M))return!0}catch(Q){G=!0,H=Q}finally{try{V||$.return==null||$.return()}finally{if(G)throw H}}return!1}]]},"!":[u,[u],function(M,N){return!b(N,1)[0].evaluate(M)}],upcase:[c,[c],function(M,N){return b(N,1)[0].evaluate(M).toUpperCase()}],downcase:[c,[c],function(M,N){return b(N,1)[0].evaluate(M).toLowerCase()}],concat:[c,p(c),function(M,N){return N.map(function(V){return V.evaluate(M)}).join("")}]}),O.exports=J},function(O,D,o){var _=o(7),e=o(17),b=o(29),g=o(43),f=o(92),c=o(93),u=o(24);O.exports=function(i){var a,n,t,r=i.valueSpec,l=u(i.value.type),d={},h=l!=="categorical"&&i.value.property===void 0,m=!h,S=e(i.value.stops)==="array"&&e(i.value.stops[0])==="array"&&e(i.value.stops[0][0])==="object",y=g({key:i.key,value:i.value,valueSpec:i.styleSpec.function,style:i.style,styleSpec:i.styleSpec,objectElementValidators:{stops:function(w){if(l==="identity")return[new _(w.key,w.value,'identity function may not have a "stops" property')];var A=[],k=w.value;return A=A.concat(f({key:w.key,value:k,valueSpec:w.valueSpec,style:w.style,styleSpec:w.styleSpec,arrayElementValidator:s})),e(k)==="array"&&k.length===0&&A.push(new _(w.key,k,"array must have at least one stop")),A},default:function(w){return b({key:w.key,value:w.value,valueSpec:r,style:w.style,styleSpec:w.styleSpec})}}});return l==="identity"&&h&&y.push(new _(i.key,i.value,'missing required property "property"')),l==="identity"||i.value.stops||y.push(new _(i.key,i.value,'missing required property "stops"')),l==="exponential"&&i.valueSpec.function==="piecewise-constant"&&y.push(new _(i.key,i.value,"exponential functions not supported")),i.styleSpec.$version>=8&&(m&&!i.valueSpec["property-function"]?y.push(new _(i.key,i.value,"property functions not supported")):h&&!i.valueSpec["zoom-function"]&&i.objectKey!=="heatmap-color"&&y.push(new _(i.key,i.value,"zoom functions not supported"))),l!=="categorical"&&!S||i.value.property!==void 0||y.push(new _(i.key,i.value,'"property" property is required')),y;function s(w){var A=[],k=w.value,v=w.key;if(e(k)!=="array")return[new _(v,k,"array expected, ".concat(e(k)," found"))];if(k.length!==2)return[new _(v,k,"array length 2 expected, length ".concat(k.length," found"))];if(S){if(e(k[0])!=="object")return[new _(v,k,"object expected, ".concat(e(k[0])," found"))];if(k[0].zoom===void 0)return[new _(v,k,"object stop key must have zoom")];if(k[0].value===void 0)return[new _(v,k,"object stop key must have value")];if(t&&t>u(k[0].zoom))return[new _(v,k[0].zoom,"stop zoom values must appear in ascending order")];u(k[0].zoom)!==t&&(t=u(k[0].zoom),n=void 0,d={}),A=A.concat(g({key:"".concat(v,"[0]"),value:k[0],valueSpec:{zoom:{}},style:w.style,styleSpec:w.styleSpec,objectElementValidators:{zoom:c,value:p}}))}else A=A.concat(p({key:"".concat(v,"[0]"),value:k[0],valueSpec:{},style:w.style,styleSpec:w.styleSpec},k));return A.concat(b({key:"".concat(v,"[1]"),value:k[1],valueSpec:r,style:w.style,styleSpec:w.styleSpec}))}function p(w,A){var k=e(w.value),v=u(w.value),x=w.value!==null?w.value:A;if(a){if(k!==a)return[new _(w.key,x,"".concat(k," stop domain type must match previous stop domain type ").concat(a))]}else a=k;if(k!=="number"&&k!=="string"&&k!=="boolean")return[new _(w.key,x,"stop domain value must be a number, string, or boolean")];if(k!=="number"&&l!=="categorical"){var T="number expected, ".concat(k," found");return r["property-function"]&&l===void 0&&(T+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new _(w.key,x,T)]}return l!=="categorical"||k!=="number"||isFinite(v)&&Math.floor(v)===v?l!=="categorical"&&k==="number"&&n!==void 0&&vc.maximum?[new e(g,f,"".concat(f," is greater than the maximum value ").concat(c.maximum))]:[]}},function(O,D,o){var _=o(7),e=o(30),b=e.createExpression,g=e.createPropertyExpression,f=o(24);O.exports=function(c){var u=(c.expressionContext==="property"?g:b)(f.deep(c.value),c.valueSpec);return u.result==="error"?u.value.map(function(i){return new _("".concat(c.key).concat(i.key),c.value,i.message)}):c.expressionContext==="property"&&c.propertyKey==="text-font"&&u.value._styleExpression.expression.possibleOutputs().indexOf(void 0)!==-1?[new _(c.key,c.value,'Invalid data expression for "text-font". Output values must be contained as literals within the expression.')]:[]}},function(O,D,o){var _=o(7),e=o(24),b=o(43),g=o(59),f=o(96),c=o(98),u=o(29),i=o(41);O.exports=function(a){var n=[],t=a.value,r=a.key,l=a.style,d=a.styleSpec;t.type||t.ref||n.push(new _(r,t,'either "type" or "ref" is required'));var h,m=e(t.type),S=e(t.ref);if(t.id)for(var y=e(t.id),s=0;s=l[m+0]&&c>=l[m+1])?(a[h]=!0,i.push(r[h])):a[h]=!1}}},e.prototype._forEachCell=function(b,g,f,c,u,i,a,n){for(var t=this._convertToCellCoord(b),r=this._convertToCellCoord(g),l=this._convertToCellCoord(f),d=this._convertToCellCoord(c),h=t;h<=l;h++)for(var m=r;m<=d;m++){var S=this.d*m+h;if((!n||n(this._convertFromCellCoord(h),this._convertFromCellCoord(m),this._convertFromCellCoord(h+1),this._convertFromCellCoord(m+1)))&&u.call(this,b,g,f,c,S,i,a,n))return}},e.prototype._convertFromCellCoord=function(b){return(b-this.padding)/this.scale},e.prototype._convertToCellCoord=function(b){return Math.max(0,Math.min(this.d-1,Math.floor(b*this.scale)+this.padding))},e.prototype.toArrayBuffer=function(){if(this.arrayBuffer)return this.arrayBuffer;for(var b=this.cells,g=_+this.cells.length+1+1,f=0,c=0;c=i||B<0||B>=i)){var F=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray),Z=F.vertexLength;n(this.layoutVertexArray,P,B,-1,-1),n(this.layoutVertexArray,P,B,1,-1),n(this.layoutVertexArray,P,B,1,1),n(this.layoutVertexArray,P,B,-1,1),this.indexArray.emplaceBack(Z,Z+1,Z+2),this.indexArray.emplaceBack(Z,Z+3,Z+2),F.vertexLength+=4,F.primitiveLength+=2}}}catch(W){x=!0,T=W}finally{try{v||C.return==null||C.return()}finally{if(x)throw T}}}}catch(W){s=!0,p=W}finally{try{y||A.return==null||A.return()}finally{if(s)throw p}}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,m)}}])&&_(l.prototype,d),h&&_(l,h),r}();a("CircleBucket",t,{omit:["layers"]}),O.exports=t},function(O,D,o){"use strict";function _(v,x,T){T=T||2;var E,C,z,P,B,F,Z,W=x&&x.length,J=W?x[0]*T:v.length,X=e(v,0,J,T,!0),R=[];if(!X||X.next===X.prev)return R;if(W&&(X=function(K,q,L,I){var j,M,N,V,G,H=[];for(j=0,M=q.length;j80*T){E=z=v[0],C=P=v[1];for(var U=T;Uz&&(z=B),F>P&&(P=F);Z=(Z=Math.max(z-E,P-C))!==0?1/Z:0}return g(X,R,T,E,C,Z),R}function e(v,x,T,E,C){var z,P;if(C===k(v,x,T,E)>0)for(z=x;z=x;z-=E)P=p(z,v[z],v[z+1],P);return P&&m(P,P.next)&&(w(P),P=P.next),P}function b(v,x){if(!v)return v;x||(x=v);var T,E=v;do if(T=!1,E.steiner||!m(E,E.next)&&h(E.prev,E,E.next)!==0)E=E.next;else{if(w(E),(E=x=E.prev)===E.next)break;T=!0}while(T||E!==x);return x}function g(v,x,T,E,C,z,P){if(v){!P&&z&&function(W,J,X,R){var U=W;do U.z===null&&(U.z=t(U.x,U.y,J,X,R)),U.prevZ=U.prev,U.nextZ=U.next,U=U.next;while(U!==W);U.prevZ.nextZ=null,U.prevZ=null,function(K){var q,L,I,j,M,N,V,G,H=1;do{for(L=K,K=null,M=null,N=0;L;){for(N++,I=L,V=0,q=0;q0||G>0&&I;)V!==0&&(G===0||!I||L.z<=I.z)?(j=L,L=L.nextZ,V--):(j=I,I=I.nextZ,G--),M?M.nextZ=j:K=j,j.prevZ=M,M=j;L=I}M.nextZ=null,H*=2}while(N>1)}(U)}(v,E,C,z);for(var B,F,Z=v;v.prev!==v.next;)if(B=v.prev,F=v.next,z?c(v,E,C,z):f(v))x.push(B.i/T),x.push(v.i/T),x.push(F.i/T),w(v),v=F.next,Z=F.next;else if((v=F)===Z){P?P===1?g(v=u(v,x,T),x,T,E,C,z,2):P===2&&i(v,x,T,E,C,z):g(b(v),x,T,E,C,z,1);break}}}function f(v){var x=v.prev,T=v,E=v.next;if(h(x,T,E)>=0)return!1;for(var C=v.next.next;C!==v.prev;){if(l(x.x,x.y,T.x,T.y,E.x,E.y,C.x,C.y)&&h(C.prev,C,C.next)>=0)return!1;C=C.next}return!0}function c(v,x,T,E){var C=v.prev,z=v,P=v.next;if(h(C,z,P)>=0)return!1;for(var B=C.xz.x?C.x>P.x?C.x:P.x:z.x>P.x?z.x:P.x,W=C.y>z.y?C.y>P.y?C.y:P.y:z.y>P.y?z.y:P.y,J=t(B,F,x,T,E),X=t(Z,W,x,T,E),R=v.prevZ,U=v.nextZ;R&&R.z>=J&&U&&U.z<=X;){if(R!==v.prev&&R!==v.next&&l(C.x,C.y,z.x,z.y,P.x,P.y,R.x,R.y)&&h(R.prev,R,R.next)>=0||(R=R.prevZ,U!==v.prev&&U!==v.next&&l(C.x,C.y,z.x,z.y,P.x,P.y,U.x,U.y)&&h(U.prev,U,U.next)>=0))return!1;U=U.nextZ}for(;R&&R.z>=J;){if(R!==v.prev&&R!==v.next&&l(C.x,C.y,z.x,z.y,P.x,P.y,R.x,R.y)&&h(R.prev,R,R.next)>=0)return!1;R=R.prevZ}for(;U&&U.z<=X;){if(U!==v.prev&&U!==v.next&&l(C.x,C.y,z.x,z.y,P.x,P.y,U.x,U.y)&&h(U.prev,U,U.next)>=0)return!1;U=U.nextZ}return!0}function u(v,x,T){var E=v;do{var C=E.prev,z=E.next.next;!m(C,z)&&S(C,E,E.next,z)&&y(C,z)&&y(z,C)&&(x.push(C.i/T),x.push(E.i/T),x.push(z.i/T),w(E),w(E.next),E=v=z),E=E.next}while(E!==v);return E}function i(v,x,T,E,C,z){var P=v;do{for(var B=P.next.next;B!==P.prev;){if(P.i!==B.i&&d(P,B)){var F=s(P,B);return P=b(P,P.next),F=b(F,F.next),g(P,x,T,E,C,z),void g(F,x,T,E,C,z)}B=B.next}P=P.next}while(P!==v)}function a(v,x){return v.x-x.x}function n(v,x){if(x=function(E,C){var z,P=C,B=E.x,F=E.y,Z=-1/0;do{if(F<=P.y&&F>=P.next.y&&P.next.y!==P.y){var W=P.x+(F-P.y)*(P.next.x-P.x)/(P.next.y-P.y);if(W<=B&&W>Z){if(Z=W,W===B){if(F===P.y)return P;if(F===P.next.y)return P.next}z=P.x=P.x&&P.x>=R&&B!==P.x&&l(Fz.x)&&y(P,E)&&(z=P,K=J),P=P.next;return z}(v,x)){var T=s(x,v);b(T,T.next)}}function t(v,x,T,E,C){return(v=1431655765&((v=858993459&((v=252645135&((v=16711935&((v=32767*(v-T)*C)|v<<8))|v<<4))|v<<2))|v<<1))|(x=1431655765&((x=858993459&((x=252645135&((x=16711935&((x=32767*(x-E)*C)|x<<8))|x<<4))|x<<2))|x<<1))<<1}function r(v){var x=v,T=v;do(x.x=0&&(v-P)*(E-B)-(T-P)*(x-B)>=0&&(T-P)*(z-B)-(C-P)*(E-B)>=0}function d(v,x){return v.next.i!==x.i&&v.prev.i!==x.i&&!function(T,E){var C=T;do{if(C.i!==T.i&&C.next.i!==T.i&&C.i!==E.i&&C.next.i!==E.i&&S(C,C.next,T,E))return!0;C=C.next}while(C!==T);return!1}(v,x)&&y(v,x)&&y(x,v)&&function(T,E){var C=T,z=!1,P=(T.x+E.x)/2,B=(T.y+E.y)/2;do C.y>B!=C.next.y>B&&C.next.y!==C.y&&P<(C.next.x-C.x)*(B-C.y)/(C.next.y-C.y)+C.x&&(z=!z),C=C.next;while(C!==T);return z}(v,x)}function h(v,x,T){return(x.y-v.y)*(T.x-x.x)-(x.x-v.x)*(T.y-x.y)}function m(v,x){return v.x===x.x&&v.y===x.y}function S(v,x,T,E){return!!(m(v,x)&&m(T,E)||m(v,E)&&m(T,x))||h(v,x,T)>0!=h(v,x,E)>0&&h(T,E,v)>0!=h(T,E,x)>0}function y(v,x){return h(v.prev,v,v.next)<0?h(v,x,v.next)>=0&&h(v,v.prev,x)>=0:h(v,x,v.prev)<0||h(v,v.next,x)<0}function s(v,x){var T=new A(v.i,v.x,v.y),E=new A(x.i,x.x,x.y),C=v.next,z=x.prev;return v.next=x,x.prev=v,T.next=C,C.prev=T,E.next=T,T.prev=E,z.next=E,E.prev=z,E}function p(v,x,T,E){var C=new A(v,x,T);return E?(C.next=E.next,C.prev=E,E.next.prev=C,E.next=C):(C.prev=C,C.next=C),C}function w(v){v.next.prev=v.prev,v.prev.next=v.next,v.prevZ&&(v.prevZ.nextZ=v.nextZ),v.nextZ&&(v.nextZ.prevZ=v.prevZ)}function A(v,x,T){this.i=v,this.x=x,this.y=T,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function k(v,x,T,E){for(var C=0,z=x,P=T-E;z0&&(E+=v[C-1].length,T.holes.push(E))}return T}},function(O,D,o){var _=o(163),e=o(0).calculateSignedArea;function b(g,f){return f.area-g.area}O.exports=function(g,f){var c=g.length;if(c<=1)return[g];for(var u,i,a=[],n=0;n1)for(var r=0;r>3;i=n===1?u.readString():n===2?u.readFloat():n===3?u.readDouble():n===4?u.readVarint64():n===5?u.readVarint():n===6?u.readSVarint():n===7?u.readBoolean():null}return i}(c))}O.exports=e,e.prototype.feature=function(g){if(g<0||g>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[g];var f=this._pbf.readVarint()+this._pbf.pos;return new _(this._pbf,f,this.extent,this._keys,this._values)}},function(O,D,o){"use strict";var _=o(3);function e(f,c,u,i,a){this.properties={},this.extent=u,this.type=0,this._pbf=f,this._geometry=-1,this._keys=i,this._values=a,f.readFields(b,this,c)}function b(f,c,u){f==1?c.id=u.readVarint():f==2?function(i,a){for(var n=i.readVarint()+i.pos;i.pos>3}if(a--,i===1||i===2)n+=f.readSVarint(),t+=f.readSVarint(),i===1&&(c&&r.push(c),c=[]),c.push(new _(n,t));else{if(i!==7)throw new Error("unknown command "+i);c&&c.push(c[0].clone())}}return c&&r.push(c),r},e.prototype.bbox=function(){var f=this._pbf;f.pos=this._geometry;for(var c=f.readVarint()+f.pos,u=1,i=0,a=0,n=0,t=1/0,r=-1/0,l=1/0,d=-1/0;f.pos>3}if(i--,u===1||u===2)(a+=f.readSVarint())r&&(r=a),(n+=f.readSVarint())d&&(d=n);else if(u!==7)throw new Error("unknown command "+u)}return[t,l,r,d]},e.prototype.toGeoJSON=function(f,c,u){var i,a,n=this.extent*Math.pow(2,u),t=this.extent*f,r=this.extent*c,l=this.loadGeometry(),d=e.types[this.type];function h(y){for(var s=0;si?(this.lastIntegerZoom=i+1,this.lastIntegerZoomTime=u):this.lastFloorZoom=128&&o<=255},Arabic:function(o){return o>=1536&&o<=1791},"Arabic Supplement":function(o){return o>=1872&&o<=1919},"Arabic Extended-A":function(o){return o>=2208&&o<=2303},"Hangul Jamo":function(o){return o>=4352&&o<=4607},"Unified Canadian Aboriginal Syllabics":function(o){return o>=5120&&o<=5759},"Unified Canadian Aboriginal Syllabics Extended":function(o){return o>=6320&&o<=6399},"General Punctuation":function(o){return o>=8192&&o<=8303},"Letterlike Symbols":function(o){return o>=8448&&o<=8527},"Number Forms":function(o){return o>=8528&&o<=8591},"Miscellaneous Technical":function(o){return o>=8960&&o<=9215},"Control Pictures":function(o){return o>=9216&&o<=9279},"Optical Character Recognition":function(o){return o>=9280&&o<=9311},"Enclosed Alphanumerics":function(o){return o>=9312&&o<=9471},"Geometric Shapes":function(o){return o>=9632&&o<=9727},"Miscellaneous Symbols":function(o){return o>=9728&&o<=9983},"Miscellaneous Symbols and Arrows":function(o){return o>=11008&&o<=11263},"CJK Radicals Supplement":function(o){return o>=11904&&o<=12031},"Kangxi Radicals":function(o){return o>=12032&&o<=12255},"Ideographic Description Characters":function(o){return o>=12272&&o<=12287},"CJK Symbols and Punctuation":function(o){return o>=12288&&o<=12351},Hiragana:function(o){return o>=12352&&o<=12447},Katakana:function(o){return o>=12448&&o<=12543},Bopomofo:function(o){return o>=12544&&o<=12591},"Hangul Compatibility Jamo":function(o){return o>=12592&&o<=12687},Kanbun:function(o){return o>=12688&&o<=12703},"Bopomofo Extended":function(o){return o>=12704&&o<=12735},"CJK Strokes":function(o){return o>=12736&&o<=12783},"Katakana Phonetic Extensions":function(o){return o>=12784&&o<=12799},"Enclosed CJK Letters and Months":function(o){return o>=12800&&o<=13055},"CJK Compatibility":function(o){return o>=13056&&o<=13311},"CJK Unified Ideographs Extension A":function(o){return o>=13312&&o<=19903},"Yijing Hexagram Symbols":function(o){return o>=19904&&o<=19967},"CJK Unified Ideographs":function(o){return o>=19968&&o<=40959},"Yi Syllables":function(o){return o>=40960&&o<=42127},"Yi Radicals":function(o){return o>=42128&&o<=42191},"Hangul Jamo Extended-A":function(o){return o>=43360&&o<=43391},"Hangul Syllables":function(o){return o>=44032&&o<=55215},"Hangul Jamo Extended-B":function(o){return o>=55216&&o<=55295},"Private Use Area":function(o){return o>=57344&&o<=63743},"CJK Compatibility Ideographs":function(o){return o>=63744&&o<=64255},"Arabic Presentation Forms-A":function(o){return o>=64336&&o<=65023},"Vertical Forms":function(o){return o>=65040&&o<=65055},"CJK Compatibility Forms":function(o){return o>=65072&&o<=65103},"Small Form Variants":function(o){return o>=65104&&o<=65135},"Arabic Presentation Forms-B":function(o){return o>=65136&&o<=65279},"Halfwidth and Fullwidth Forms":function(o){return o>=65280&&o<=65519}}},function(O,D,o){var _=o(63);O.exports=function(e){for(var b="",g=0;g":"\uFE40","?":"\uFE16","@":"\uFF20","[":"\uFE47","\\":"\uFF3C","]":"\uFE48","^":"\uFF3E",_:"\uFE33","`":"\uFF40","{":"\uFE37","|":"\u2015","}":"\uFE38","~":"\uFF5E","\xA2":"\uFFE0","\xA3":"\uFFE1","\xA5":"\uFFE5","\xA6":"\uFFE4","\xAC":"\uFFE2","\xAF":"\uFFE3","\u2013":"\uFE32","\u2014":"\uFE31","\u2018":"\uFE43","\u2019":"\uFE44","\u201C":"\uFE41","\u201D":"\uFE42","\u2026":"\uFE19","\u2027":"\u30FB","\u20A9":"\uFFE6","\u3001":"\uFE11","\u3002":"\uFE12","\u3008":"\uFE3F","\u3009":"\uFE40","\u300A":"\uFE3D","\u300B":"\uFE3E","\u300C":"\uFE41","\u300D":"\uFE42","\u300E":"\uFE43","\u300F":"\uFE44","\u3010":"\uFE3B","\u3011":"\uFE3C","\u3014":"\uFE39","\u3015":"\uFE3A","\u3016":"\uFE17","\u3017":"\uFE18","\uFF01":"\uFE15","\uFF08":"\uFE35","\uFF09":"\uFE36","\uFF0C":"\uFE10","\uFF0D":"\uFE32","\uFF0E":"\u30FB","\uFF1A":"\uFE13","\uFF1B":"\uFE14","\uFF1C":"\uFE3F","\uFF1E":"\uFE40","\uFF1F":"\uFE16","\uFF3B":"\uFE47","\uFF3D":"\uFE48","\uFF3F":"\uFE33","\uFF5B":"\uFE37","\uFF5C":"\u2015","\uFF5D":"\uFE38","\uFF5F":"\uFE35","\uFF60":"\uFE36","\uFF61":"\uFE12","\uFF62":"\uFE41","\uFF63":"\uFE42"}},function(O,D,o){O.exports=function(){function _(g,f,c){c=c||{},this.w=g||64,this.h=f||64,this.autoResize=!!c.autoResize,this.shelves=[],this.freebins=[],this.stats={},this.bins={},this.maxId=0}function e(g,f,c){this.x=0,this.y=g,this.w=this.free=f,this.h=c}function b(g,f,c,u,i,a,n){this.id=g,this.x=f,this.y=c,this.w=u,this.h=i,this.maxw=a||u,this.maxh=n||i,this.refcount=0}return _.prototype.pack=function(g,f){g=[].concat(g),f=f||{};for(var c,u,i,a,n=[],t=0;tu.maxh||g>u.maxw||f<=u.maxh&&g<=u.maxw&&(a=u.maxw*u.maxh-g*f)i.free)){if(f===i.h)return this.allocShelf(n,g,f,c);f>i.h||fl)&&(d=2*Math.max(g,l)),(tt)&&(r=2*Math.max(f,t)),this.resize(d,r),this.packOne(g,f,c)):null},_.prototype.allocFreebin=function(g,f,c,u){var i=this.freebins.splice(g,1)[0];return i.id=u,i.w=f,i.h=c,i.refcount=0,this.bins[u]=i,this.ref(i),i},_.prototype.allocShelf=function(g,f,c,u){var i=this.shelves[g].alloc(f,c,u);return this.bins[u]=i,this.ref(i),i},_.prototype.shrink=function(){if(this.shelves.length>0){for(var g=0,f=0,c=0;cthis.free||f>this.h)return null;var u=this.x;return this.x+=g,this.free-=g,new b(c,u,this.y,g,f,g,this.h)},e.prototype.resize=function(g){return this.free+=g-this.w,this.w=g,!0},_}()},function(O,D,o){var _=o(0),e=o(16),b=o(2),g=o(34).normalizeSourceURL;O.exports=function(f,c,u){var i=function(a,n){if(a)return u(a);if(n){var t=_.pick(n,["tiles","minzoom","maxzoom","attribution","mapbox_logo","bounds"]);n.vector_layers&&(t.vectorLayers=n.vector_layers,t.vectorLayerIds=t.vectorLayers.map(function(r){return r.id})),u(null,t)}};f.url?e.getJSON(c(g(f.url),e.ResourceType.Source),i):b.frame(function(){return i(null,f)})}},function(O,D,o){function _(f,c){for(var u=0;u=n&&a.x=t&&a.y1||(Math.abs(Z)>1&&(Math.abs(Z+J)===1?Z+=J:Math.abs(Z-J)===1&&(Z-=J)),F.dem&&B.dem&&(B.dem.backfillBorder(F.dem,Z,W),B.neighboringTiles&&B.neighboringTiles[X]&&(B.neighboringTiles[X].backfilled=!0)))}}},{key:"getTile",value:function(x){return this.getTileByID(x.key)}},{key:"getTileByID",value:function(x){return this._tiles[x]}},{key:"getZoom",value:function(x){return x.zoom+x.scaleZoom(x.tileSize/this._source.tileSize)}},{key:"_findLoadedChildren",value:function(x,T,E){var C=!1;for(var z in this._tiles){var P=this._tiles[z];if(!(E[z]||!P.hasData()||P.tileID.overscaledZ<=x.overscaledZ||P.tileID.overscaledZ>T)){var B=Math.pow(2,P.tileID.canonical.z-x.canonical.z);if(Math.floor(P.tileID.canonical.x/B)===x.canonical.x&&Math.floor(P.tileID.canonical.y/B)===x.canonical.y)for(E[z]=P.tileID,C=!0;P&&P.tileID.overscaledZ-1>x.overscaledZ;){var F=P.tileID.scaledTo(P.tileID.overscaledZ-1);if(!F)break;(P=this._tiles[F.key])&&P.hasData()&&(delete E[z],E[F.key]=F)}}}return C}},{key:"findLoadedParent",value:function(x,T,E){for(var C=x.overscaledZ-1;C>=T;C--){var z=x.scaledTo(C);if(!z)return;var P=String(z.key),B=this._tiles[P];if(B&&B.hasData())return E[P]=z,B;if(this._cache.has(P))return E[P]=z,this._cache.get(P)}}},{key:"updateCacheSize",value:function(x){var T=(Math.ceil(x.width/this._source.tileSize)+1)*(Math.ceil(x.height/this._source.tileSize)+1),E=Math.floor(5*T),C=typeof this._maxTileCacheSize=="number"?Math.min(this._maxTileCacheSize,E):E;this._cache.setMaxSize(C)}},{key:"update",value:function(x){var T=this;if(this.transform=x,this._sourceLoaded&&!this._paused){var E;this.updateCacheSize(x),this._coveredTiles={},this.used?this._source.tileID?E=x.getVisibleUnwrappedCoordinates(this._source.tileID).map(function(I){return new h(I.canonical.z,I.wrap,I.canonical.z,I.canonical.x,I.canonical.y)}):(E=x.coveringTiles({tileSize:this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom,reparseOverscaled:this._source.reparseOverscaled}),this._source.hasTile&&(E=E.filter(function(I){return T._source.hasTile(I)}))):E=[];var C,z=(this._source.roundZoom?Math.round:Math.floor)(this.getZoom(x)),P=Math.max(z-w.maxOverzooming,this._source.minzoom),B=Math.max(z+w.maxUnderzooming,this._source.minzoom),F=this._updateRetainedTiles(E,z),Z={};if(s(this._source.type))for(var W=Object.keys(F),J=0;J=d.now())){this._findLoadedChildren(R,B,F)&&(F[X]=R);var K=this.findLoadedParent(R,P,Z);K&&this._addTile(K.tileID)}}for(C in Z)F[C]||(this._coveredTiles[C]=!0);for(C in Z)F[C]=Z[C];for(var q=t.keysDifference(this._tiles,F),L=0;Lthis._source.maxzoom){var X=F.children(this._source.maxzoom)[0],R=this.getTile(X);R&&R.hasData()?E[X.key]=X:J=!1}else{this._findLoadedChildren(F,P,E);for(var U=F.children(this._source.maxzoom),K=0;K=z;--q){var L=F.scaledTo(q);if(C[L.key]||(C[L.key]=!0,!(Z=this.getTile(L))&&W&&(Z=this._addTile(L)),Z&&(E[L.key]=L,W=Z.wasRequested(),Z.hasData())))break}}}return E}},{key:"_addTile",value:function(x){var T=this._tiles[x.key];if(T)return T;(T=this._cache.getAndRemove(x.key))&&this._cacheTimers[x.key]&&(clearTimeout(this._cacheTimers[x.key]),delete this._cacheTimers[x.key],this._setTileReloadTimer(x.key,T));var E=Boolean(T);return E||(T=new u(x,this._source.tileSize*x.overscaleFactor()),this._loadTile(T,this._tileLoaded.bind(this,T,x.key,T.state))),T?(T.uses++,this._tiles[x.key]=T,E||this._source.fire("dataloading",{tile:T,coord:T.tileID,dataType:"source"}),T):null}},{key:"_setTileReloadTimer",value:function(x,T){var E=this;x in this._timers&&(clearTimeout(this._timers[x]),delete this._timers[x]);var C=T.getExpiryTimeout();C&&(this._timers[x]=setTimeout(function(){E._reloadTile(x,"expired"),delete E._timers[x]},C))}},{key:"_setCacheInvalidationTimer",value:function(x,T){var E=this;x in this._cacheTimers&&(clearTimeout(this._cacheTimers[x]),delete this._cacheTimers[x]);var C=T.getExpiryTimeout();C&&(this._cacheTimers[x]=setTimeout(function(){E._cache.remove(x),delete E._cacheTimers[x]},C))}},{key:"_removeTile",value:function(x){var T=this._tiles[x];if(T&&(T.uses--,delete this._tiles[x],this._timers[x]&&(clearTimeout(this._timers[x]),delete this._timers[x]),!(T.uses>0)))if(T.hasData()){T.tileID=T.tileID.wrapped();var E=T.tileID.key;this._cache.add(E,T),this._setCacheInvalidationTimer(E,T)}else T.aborted=!0,this._abortTile(T),this._unloadTile(T)}},{key:"clearTiles",value:function(){for(var x in this._shouldReloadOnResume=!1,this._paused=!1,this._tiles)this._removeTile(x);this._resetCache()}},{key:"_resetCache",value:function(){for(var x in this._cacheTimers)clearTimeout(this._cacheTimers[x]);this._cacheTimers={},this._cache.reset()}},{key:"tilesIn",value:function(x){for(var T=[],E=this.getIds(),C=1/0,z=1/0,P=-1/0,B=-1/0,F=x[0].zoom,Z=0;Z=0&&U[1].y>=0){for(var K=[],q=0;q=d.now())return!0}return!1}}])&&e(A.prototype,k),v&&e(A,v),w}();function y(p,w){var A=w.zoomTo(p.canonical.z);return new l((A.column-(p.canonical.x+p.wrap*Math.pow(2,p.canonical.z)))*r,(A.row-p.canonical.y)*r)}function s(p){return p==="raster"||p==="image"||p==="video"}S.maxOverzooming=10,S.maxUnderzooming=3,O.exports=S},function(O,D,o){function _(p,w){for(var A=0;A>P.z,F=new d(P.x*B,P.y*B),Z=new d(F.x+B,F.y+B),W=this.segments.prepareSegment(4,T,E);T.emplaceBack(F.x,F.y,F.x,F.y),T.emplaceBack(Z.x,F.y,Z.x,F.y),T.emplaceBack(F.x,Z.y,F.x,Z.y),T.emplaceBack(Z.x,Z.y,Z.x,Z.y);var J=W.vertexLength;E.emplaceBack(J,J+1,J+2),E.emplaceBack(J+1,J+2,J+3),W.vertexLength+=4,W.primitiveLength+=2}this.maskedBoundsBuffer=x.createVertexBuffer(T,r.members),this.maskedIndexBuffer=x.createIndexBuffer(E)}}},{key:"hasData",value:function(){return this.state==="loaded"||this.state==="reloading"||this.state==="expired"}},{key:"setExpiryData",value:function(v){var x=this.expirationTime;if(v.cacheControl){var T=e.parseCacheControl(v.cacheControl);T["max-age"]&&(this.expirationTime=Date.now()+1e3*T["max-age"])}else v.expires&&(this.expirationTime=new Date(v.expires).getTime());if(this.expirationTime){var E=Date.now(),C=!1;if(this.expirationTime>E)C=!1;else if(x)if(this.expirationTime1&&arguments[1]!==void 0?arguments[1]:new g(l.width+2*c,l.height+2*c,25),h=arguments.length>2&&arguments[2]!==void 0?arguments[2]:new g(l.width+2*c,l.height+2*c,25);(function(m,S){if(!(m instanceof S))throw new TypeError("Cannot call a class as a function")})(this,a),this.transform=l,this.grid=d,this.ignoredGrid=h,this.pitchfactor=Math.cos(l._pitch)*l.cameraToCenterDistance,this.screenRightBoundary=l.width+c,this.screenBottomBoundary=l.height+c}var n,t,r;return n=a,(t=[{key:"placeCollisionBox",value:function(l,d,h,m){var S=this.projectAndGetPerspectiveRatio(m,l.anchorPointX,l.anchorPointY),y=h*S.perspectiveRatio,s=l.x1*y+S.point.x,p=l.y1*y+S.point.y,w=l.x2*y+S.point.x,A=l.y2*y+S.point.y;return!d&&this.grid.hitTest(s,p,w,A)?{box:[],offscreen:!1}:{box:[s,p,w,A],offscreen:this.isOffscreen(s,p,w,A)}}},{key:"approximateTileDistance",value:function(l,d,h,m,S){var y=S?1:m/this.pitchfactor,s=l.lastSegmentViewportDistance*h;return l.prevTileDistance+s+(y-1)*s*Math.abs(Math.sin(d))}},{key:"placeCollisionCircles",value:function(l,d,h,m,S,y,s,p,w,A,k,v,x){var T=[],E=this.projectAnchor(A,y.anchorX,y.anchorY),C=w/24,z=y.lineOffsetX*w,P=y.lineOffsetY*w,B=new e(y.anchorX,y.anchorY),F=f.project(B,k).point,Z=f.placeFirstAndLastGlyph(C,p,z,P,!1,F,B,y,s,k,{},!0),W=!1,J=!0,X=E.perspectiveRatio*m,R=1/(m*h),U=0,K=0;Z&&(U=this.approximateTileDistance(Z.first.tileDistance,Z.first.angle,R,E.cameraDistance,x),K=this.approximateTileDistance(Z.last.tileDistance,Z.last.angle,R,E.cameraDistance,x));for(var q=0;qK)i(l,q,!1);else{var N=this.projectPoint(A,L,I),V=j*X;if(T.length>0){var G=N.x-T[T.length-4],H=N.y-T[T.length-3];if(V*V*2>G*G+H*H&&q+8-U&&Y=this.screenRightBoundary||mthis.screenBottomBoundary}}])&&_(n.prototype,t),r&&_(n,r),a}();function i(a,n,t){a[n+4]=t?1:0}O.exports=u},function(O,D){function o(e,b){for(var g=0;gthis.max){var i=this.getAndRemove(this.order[0]);i&&this.onRemove(i)}return this}},{key:"has",value:function(c){return c in this.data}},{key:"keys",value:function(){return this.order}},{key:"getAndRemove",value:function(c){if(!this.has(c))return null;var u=this.data[c];return delete this.data[c],this.order.splice(this.order.indexOf(c),1),u}},{key:"get",value:function(c){return this.has(c)?this.data[c]:null}},{key:"remove",value:function(c){if(!this.has(c))return this;var u=this.data[c];return delete this.data[c],this.onRemove(u),this.order.splice(this.order.indexOf(c),1),this}},{key:"setMaxSize",value:function(c){for(this.max=c;this.order.length>this.max;){var u=this.getAndRemove(this.order[0]);u&&this.onRemove(u)}return this}}])&&o(b.prototype,g),f&&o(b,f),e}();O.exports=_},function(O,D,o){function _(L){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(I){return typeof I}:function(I){return I&&typeof Symbol=="function"&&I.constructor===Symbol&&I!==Symbol.prototype?"symbol":typeof I})(L)}function e(L,I){return!I||_(I)!=="object"&&typeof I!="function"?function(j){if(j===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return j}(L):I}function b(L){return(b=Object.setPrototypeOf?Object.getPrototypeOf:function(I){return I.__proto__||Object.getPrototypeOf(I)})(L)}function g(L,I){if(typeof I!="function"&&I!==null)throw new TypeError("Super expression must either be null or a function");L.prototype=Object.create(I&&I.prototype,{constructor:{value:L,writable:!0,configurable:!0}}),I&&f(L,I)}function f(L,I){return(f=Object.setPrototypeOf||function(j,M){return j.__proto__=M,j})(L,I)}function c(L,I){if(!(L instanceof I))throw new TypeError("Cannot call a class as a function")}function u(L,I){for(var j=0;jt.overscaledZ)for(var A in w){var k=w[A];k.tileID.isChildOf(t)&&k.findMatches(r.symbolInstances,t,s)}else{var v=w[t.scaledTo(Number(p)).key];v&&v.findMatches(r.symbolInstances,t,s)}}var x=!0,T=!1,E=void 0;try{for(var C,z=r.symbolInstances[Symbol.iterator]();!(x=(C=z.next()).done);x=!0){var P=C.value;P.crossTileID||(P.crossTileID=l.generate(),s[P.crossTileID]=!0)}}catch(B){T=!0,E=B}finally{try{x||z.return==null||z.return()}finally{if(T)throw E}}return this.indexes[t.overscaledZ]===void 0&&(this.indexes[t.overscaledZ]={}),this.indexes[t.overscaledZ][t.key]=new c(t,r.symbolInstances,r.bucketInstanceId),!0}},{key:"removeBucketCrossTileIDs",value:function(t,r){for(var l in r.indexedSymbolInstances){var d=!0,h=!1,m=void 0;try{for(var S,y=r.indexedSymbolInstances[l][Symbol.iterator]();!(d=(S=y.next()).done);d=!0){var s=S.value;delete this.usedCrossTileIDs[t][s.crossTileID]}}catch(p){h=!0,m=p}finally{try{d||y.return==null||y.return()}finally{if(h)throw m}}}}},{key:"removeStaleBuckets",value:function(t){var r=!1;for(var l in this.indexes){var d=this.indexes[l];for(var h in d)t[d[h].bucketInstanceId]||(this.removeBucketCrossTileIDs(l,d[h]),delete d[h],r=!0)}return r}}]),n}(),a=function(){function n(){_(this,n),this.layerIndexes={},this.crossTileIDs=new u,this.maxBucketInstanceId=0}return b(n,[{key:"addLayer",value:function(t,r){var l=this.layerIndexes[t.id];l===void 0&&(l=this.layerIndexes[t.id]=new i);var d=!1,h={},m=!0,S=!1,y=void 0;try{for(var s,p=r[Symbol.iterator]();!(m=(s=p.next()).done);m=!0){var w=s.value,A=w.getBucket(t);A&&(A.bucketInstanceId||(A.bucketInstanceId=++this.maxBucketInstanceId),l.addBucket(w.tileID,A,this.crossTileIDs)&&(d=!0),h[A.bucketInstanceId]=!0)}}catch(k){S=!0,y=k}finally{try{m||p.return==null||p.return()}finally{if(S)throw y}}return l.removeStaleBuckets(h)&&(d=!0),d}}]),n}();O.exports=a},function(O,D,o){function _(T,E){for(var C=0;C=0;this.currentLayer--){var N=this.style._layers[J[this.currentLayer]];N.source!==(j&&j.id)&&(M=[],(j=this.style.sourceCaches[N.source])&&(this.clearStencil(),M=j.getVisibleCoordinates(),j.getSource().isTileClipped&&this._renderTileClippingMasks(M))),this.renderLayer(this,j,N,M)}this.renderPass="translucent";var V,G=[];for(this.currentLayer=0,this.currentLayer;this.currentLayer0?B.pop():null}},{key:"_createProgramCached",value:function(P,B){this.cache=this.cache||{};var F="".concat(P).concat(B.cacheKey||"").concat(this._showOverdrawInspector?"/overdraw":"");return this.cache[F]||(this.cache[F]=new S(this.context,m[P],B,this._showOverdrawInspector)),this.cache[F]}},{key:"useProgram",value:function(P,B){var F=this._createProgramCached(P,B||this.emptyProgramConfiguration);return this.context.program.set(F.program),F}}])&&_(E.prototype,C),z&&_(E,z),T}();O.exports=x},function(O,D,o){var _=o(23).createLayout;O.exports=_([{name:"a_pos",type:"Int16",components:2}])},function(O,D,o){var _={prelude:{fragmentSource:o(218),vertexSource:o(219)},background:{fragmentSource:o(220),vertexSource:o(221)},backgroundPattern:{fragmentSource:o(222),vertexSource:o(223)},circle:{fragmentSource:o(224),vertexSource:o(225)},clippingMask:{fragmentSource:o(226),vertexSource:o(227)},heatmap:{fragmentSource:o(228),vertexSource:o(229)},heatmapTexture:{fragmentSource:o(230),vertexSource:o(231)},collisionBox:{fragmentSource:o(232),vertexSource:o(233)},collisionCircle:{fragmentSource:o(234),vertexSource:o(235)},debug:{fragmentSource:o(236),vertexSource:o(237)},fill:{fragmentSource:o(238),vertexSource:o(239)},fillOutline:{fragmentSource:o(240),vertexSource:o(241)},fillOutlinePattern:{fragmentSource:o(242),vertexSource:o(243)},fillPattern:{fragmentSource:o(244),vertexSource:o(245)},fillExtrusion:{fragmentSource:o(246),vertexSource:o(247)},fillExtrusionPattern:{fragmentSource:o(248),vertexSource:o(249)},extrusionTexture:{fragmentSource:o(250),vertexSource:o(251)},hillshadePrepare:{fragmentSource:o(252),vertexSource:o(253)},hillshade:{fragmentSource:o(254),vertexSource:o(255)},line:{fragmentSource:o(256),vertexSource:o(257)},linePattern:{fragmentSource:o(258),vertexSource:o(259)},lineSDF:{fragmentSource:o(260),vertexSource:o(261)},raster:{fragmentSource:o(262),vertexSource:o(263)},symbolIcon:{fragmentSource:o(264),vertexSource:o(265)},symbolSDF:{fragmentSource:o(266),vertexSource:o(267)}},e=/#pragma mapbox: ([\w]+) ([\w]+) ([\w]+) ([\w]+)/g,b=function(f){var c=_[f],u={};c.fragmentSource=c.fragmentSource.replace(e,function(i,a,n,t,r){return u[r]=!0,a==="define"?` #ifndef HAS_UNIFORM_u_`.concat(r,` varying `).concat(n," ").concat(t," ").concat(r,`; #else uniform `).concat(n," ").concat(t," u_").concat(r,`; #endif `):` #ifdef HAS_UNIFORM_u_`.concat(r,` `).concat(n," ").concat(t," ").concat(r," = u_").concat(r,`; #endif `)}),c.vertexSource=c.vertexSource.replace(e,function(i,a,n,t,r){var l=t==="float"?"vec2":"vec4";return u[r]?a==="define"?` #ifndef HAS_UNIFORM_u_`.concat(r,` uniform lowp float a_`).concat(r,`_t; attribute `).concat(n," ").concat(l," a_").concat(r,`; varying `).concat(n," ").concat(t," ").concat(r,`; #else uniform `).concat(n," ").concat(t," u_").concat(r,`; #endif `):` #ifndef HAS_UNIFORM_u_`.concat(r,` `).concat(r," = unpack_mix_").concat(l,"(a_").concat(r,", a_").concat(r,`_t); #else `).concat(n," ").concat(t," ").concat(r," = u_").concat(r,`; #endif `):a==="define"?` #ifndef HAS_UNIFORM_u_`.concat(r,` uniform lowp float a_`).concat(r,`_t; attribute `).concat(n," ").concat(l," a_").concat(r,`; #else uniform `).concat(n," ").concat(t," u_").concat(r,`; #endif `):` #ifndef HAS_UNIFORM_u_`.concat(r,` `).concat(n," ").concat(t," ").concat(r," = unpack_mix_").concat(l,"(a_").concat(r,", a_").concat(r,`_t); #else `).concat(n," ").concat(t," ").concat(r," = u_").concat(r,`; #endif `)})};for(var g in _)b(g);O.exports=_},function(O,D,o){function _(i,a){for(var n=0;n=0&&(d=0),d!==l)return}else if(r.ctrlKey||r.button!==0)return;e.disableDrag(),g.document.addEventListener("mousemove",this._onMove,{capture:!0}),g.document.addEventListener("mouseup",this._onUp),g.addEventListener("blur",this._onUp),this._active=!1,this._inertia=[[f.now(),this._map.getBearing()]],this._startPos=this._pos=e.mousePos(this._el,r),this._center=this._map.transform.centerPoint,r.preventDefault()}}},{key:"_onMove",value:function(r){this.isActive()||(this._active=!0,this._map.moving=!0,this._fireEvent("rotatestart",r),this._fireEvent("movestart",r),this._pitchWithRotate&&this._fireEvent("pitchstart",r));var l=this._map;l.stop();var d=this._pos,h=e.mousePos(this._el,r),m=.8*(d.x-h.x),S=-.5*(d.y-h.y),y=l.getBearing()-m,s=l.getPitch()-S,p=this._inertia,w=p[p.length-1];this._drainInertiaBuffer(),p.push([f.now(),l._normalizeBearing(y,w[1])]),l.transform.bearing=y,this._pitchWithRotate&&(this._fireEvent("pitch",r),l.transform.pitch=s),this._fireEvent("rotate",r),this._fireEvent("move",r),this._pos=h}},{key:"_onUp",value:function(r){var l=this;if(g.document.removeEventListener("mousemove",this._onMove,{capture:!0}),g.document.removeEventListener("mouseup",this._onUp),g.removeEventListener("blur",this._onUp),e.enableDrag(),this.isActive()){this._active=!1,this._fireEvent("rotateend",r),this._drainInertiaBuffer();var d=this._map,h=d.getBearing(),m=this._inertia,S=function(){Math.abs(h)180&&(x=180);var T=x/180;w+=k*x*(T/2),Math.abs(d._normalizeBearing(w,0))0&&l-r[0][0]>160;)r.shift()}}])&&_(a.prototype,n),t&&_(a,t),i}();O.exports=u},function(O,D,o){function _(c,u){for(var i=0;i=0)return!1;return!0}),this._container.innerHTML=n.join(" | "),this._editLink=null}}},{key:"_updateCompact",value:function(){this._map.getCanvasContainer().offsetWidth<=640?this._container.classList.add("mapboxgl-compact"):this._container.classList.remove("mapboxgl-compact")}}])&&_(u.prototype,i),a&&_(u,a),c}();O.exports=f},function(O,D,o){function _(i,a){for(var n=0;n180;){var i=g.locationPoint(e);if(i.x>=0&&i.y>=0&&i.x<=g.width&&i.y<=g.height)break;e.lng>g.center.lng?e.lng-=360:e.lng+=360}return e}},function(O,D,o){O.exports=o(71)},function(O){O.exports={name:"mapbox-gl",description:"A WebGL interactive maps library",version:"2.1.3",main:"dist/mapbox-gl.js",module:"dist/mapbox-gl.js",style:"dist/mapbox-gl.css",license:"SEE LICENSE IN LICENSE.txt",repository:{type:"git",url:"git://github.com/mapbox/mapbox-gl-js.git"},engines:{node:">=6.4.0"},dependencies:{"@mapbox/gl-matrix":"^0.0.1","@mapbox/mapbox-gl-supported":"^1.3.0","@mapbox/point-geometry":"^0.1.0","@mapbox/shelf-pack":"=3.1.0","@mapbox/sphericalmercator":"github:landtechnologies/sphericalmercator#24a1b89b4edc26fcfd6171d61c27e3a9ea2f885c","@mapbox/tiny-sdf":"^1.1.0","@mapbox/unitbezier":"^0.0.0","@mapbox/vector-tile":"^1.3.0","@mapbox/whoots-js":"^3.0.0",brfs:"^1.4.0",bubleify:"^0.7.0",csscolorparser:"~1.0.2",earcut:"^2.1.3","geojson-rewind":"^0.3.0","geojson-vt":"^3.0.0","gray-matter":"^3.0.8","grid-index":"^1.0.0","jsonlint-lines-primitives":"~1.6.0","mapbox-gl-supported":"^1.2.0",minimist:"0.0.8","package-json-versionify":"^1.0.2",pbf:"^3.0.5","point-geometry":"^0.0.0",quickselect:"^1.0.0",rw:"^1.3.3","shuffle-seed":"^1.1.6","sort-object":"^0.3.2",supercluster:"^2.3.0",through2:"^2.0.3",tinyqueue:"^1.1.0",unassertify:"^2.0.0",unflowify:"^1.0.0","vt-pbf":"^3.0.1",webworkify:"^1.5.0"},devDependencies:{"@babel/cli":"^7.4.4","@babel/core":"^7.4.5","@babel/plugin-proposal-class-properties":"^7.4.4","@babel/plugin-transform-flow-strip-types":"^7.4.4","@babel/preset-env":"^7.4.5","@mapbox/batfish":"^0.13.3","@mapbox/mapbox-gl-rtl-text":"^0.1.1","@mapbox/mapbox-gl-test-suite":"file:test/integration","babel-eslint":"^7.0.0","babel-loader":"^8.0.6","babel-preset-es2015":"^6.24.1",benchmark:"~2.1.0",browserify:"^14.0.0",coveralls:"^2.11.8",d3:"^4.12.0",derequire:"^2.0.6",documentation:"5.3.3",ejs:"^2.5.7",envify:"^4.0.0",eslint:"4.1.1","eslint-config-mourner":"^2.0.0","eslint-plugin-flowtype":"^2.34.0","eslint-plugin-html":"^3.0.0","eslint-plugin-node":"^5.1.1","eslint-plugin-react":"^7.3.0","execcommand-copy":"^1.1.0","flow-bin":"^0.62.0","flow-coverage-report":"^0.3.0","flow-remove-types":"^1.0.4","github-slugger":"^1.1.1",gl:"^4.0.1",glob:"^7.0.3","in-publish":"^2.0.0","is-builtin-module":"^1.0.0",jsdom:"^11.2.0","json-stringify-pretty-compact":"^1.0.4",lodash:"^4.16.0",minifyify:"^7.0.1","mock-geolocation":"^1.0.11","npm-run-all":"^4.0.1",nyc:"^10.1.2","object.entries":"^1.0.4",pngjs:"^3.0.0",prismjs:"^1.8.1","prop-types":"^15.6.0",proxyquire:"^1.7.9","raw-loader":"^0.5.1",react:"^16.0.0","react-dom":"^16.0.0","react-helmet":"^5.2.0",remark:"^8.0.0","remark-html":"^5.0.1","remark-react":"^4.0.1",request:"^2.79.0",sinon:"^2.1.0",slugg:"^1.2.1",st:"^1.2.0",stylelint:"^7.10.1",tap:"^10.3.0",watchify:"^3.7.0",webpack:"^4.35.0","webpack-cli":"^3.3.5","worker-loader":"^2.0.0"},browserify:{transform:["unflowify",["bubleify",{bubleError:!0,transforms:{dangerousForOf:!0},objectAssign:"Object.assign"}],"package-json-versionify","unassertify","brfs","./build/minifyify_style_spec","./build/strictify"]},browser:{"./src/util/window.js":"./src/util/browser/window.js","./src/util/web_worker.js":"./src/util/browser/web_worker.js"},scripts:{"build-dev":"browserify src/index.js --debug --ignore-transform unassertify --standalone mapboxgl > dist/mapbox-gl-dev.js && tap --no-coverage test/build/dev.test.js","watch-dev":"watchify src/index.js --debug --ignore-transform unassertify --standalone mapboxgl --outfile dist/mapbox-gl-dev.js --verbose","watch-style-property-editor":"watchify debug/style_property_editor.js --debug -o debug/style_property_editor_generated.js --standalone StylePropertyEditor --verbose","build-min":"browserify src/index.js --debug --plugin [minifyify --map mapbox-gl.js.map --output dist/mapbox-gl.js.map] --standalone mapboxgl | derequire > dist/mapbox-gl.js && tap --no-coverage test/build/min.test.js","build-token":"browserify debug/access_token.js --debug --transform envify > debug/access_token_generated.js","build-benchmarks":'BENCHMARK_VERSION="$(git rev-parse --abbrev-ref HEAD) $(git rev-parse --short=7 HEAD)" browserify bench/benchmarks.js --debug --transform envify --outfile bench/benchmarks_generated.js --verbose',"watch-benchmarks":'BENCHMARK_VERSION="$(git rev-parse --abbrev-ref HEAD) $(git rev-parse --short=7 HEAD)" watchify bench/benchmarks.js --debug --transform envify --outfile bench/benchmarks_generated.js --verbose',"watch-benchmarks-view":"watchify bench/benchmarks_view.js --debug --outfile bench/benchmarks_view_generated.js --verbose","start-server":"st --no-cache --localhost --port 9966 --index index.html .",start:"run-p build-token watch-dev watch-style-property-editor watch-benchmarks watch-benchmarks-view start-server","start-debug":"run-p build-token watch-dev watch-style-property-editor start-server","start-bench":"run-p build-token watch-benchmarks watch-benchmarks-view start-server","build-docs":"documentation build --github --format json --config ./docs/documentation.yml --output docs/components/api.json src/index.js",build:"run-s build-docs && DEPLOY_ENV=production batfish build # invoked by publisher when publishing docs on the mb-pages branch","start-docs":"run-s build-min build-docs && DEPLOY_ENV=local batfish start",lint:"eslint --cache --ignore-path .gitignore src test bench docs docs/pages/example/*.html debug/*.html","lint-docs":"documentation lint src/index.js","lint-css":"stylelint 'dist/mapbox-gl.css'","open-changed-examples":`git diff --name-only mb-pages HEAD -- docs/pages/example/*.html | awk '{print "http://127.0.0.1:4000/mapbox-gl-js/example/" substr($0,33,length($0)-37)}' | xargs open`,test:"run-s lint lint-css test-flow test-unit","test-suite":"run-s test-render test-query","test-suite-clean":'find test/integration/{render,query}-tests -mindepth 2 -type d -not \\( -exec test -e "{}/style.json" \\; \\) -print | xargs -t rm -r',"test-unit":"tap --reporter classic --no-coverage test/unit","test-render":"node --max-old-space-size=2048 test/render.test.js","test-query":"node test/query.test.js","test-expressions":"node test/expression.test.js","test-flow":"node build/generate-flow-typed-style-spec && flow .","test-flow-cov":"flow-coverage-report -i 'src/**/*.js' -t html","test-cov":"nyc --require=flow-remove-types/register --reporter=text-summary --reporter=lcov --cache run-s test-unit test-expressions test-query test-render",prepublish:"in-publish && run-s build-dev build-min || not-in-publish",codegen:"node build/generate-style-code.js && flow-node build/generate-struct-arrays.js"},bin:{"gl-style-migrate":"src/style-spec/bin/gl-style-migrate","gl-style-validate":"src/style-spec/bin/gl-style-validate","gl-style-format":"src/style-spec/bin/gl-style-format","gl-style-composite":"src/style-spec/bin/gl-style-composite"},files:["build/","dist/","flow-typed/","src/",".flowconfig"]}},function(O,D,o){function _(F){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Z){return typeof Z}:function(Z){return Z&&typeof Symbol=="function"&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z})(F)}function e(F,Z){for(var W=0;WR.maxZoom)throw new Error("maxZoom must be greater than minZoom");var K=new y(R.minZoom,R.maxZoom,R.renderWorldCopies);(U=function(I,j){return!j||_(j)!=="object"&&typeof j!="function"?b(I):j}(this,f(Z).call(this,K,R)))._interactive=R.interactive,U._maxTileCacheSize=R.maxTileCacheSize,U._failIfMajorPerformanceCaveat=R.failIfMajorPerformanceCaveat,U._preserveDrawingBuffer=R.preserveDrawingBuffer,U._trackResize=R.trackResize,U._bearingSnap=R.bearingSnap,U._refreshExpiredTiles=R.refreshExpiredTiles,U._fadeDuration=R.fadeDuration,U._crossFadingFactor=1;var q=R.transformRequest;if(U._transformRequest=q?function(I,j){return q(I,j)||{url:I}}:function(I){return{url:I}},typeof R.container=="string"){var L=a.document.getElementById(R.container);if(!L)throw new Error("Container '".concat(R.container,"' not found."));U._container=L}else{if(!(R.container instanceof r))throw new Error("Invalid type: 'container' must be a String or HTMLElement.");U._container=R.container}return R.maxBounds&&U.setMaxBounds(R.maxBounds),u.bindAll(["_onWindowOnline","_onWindowResize","_contextLost","_contextRestored","_update","_render","_onData","_onDataLoading"],b(U)),U._setupContainer(),U._setupPainter(),U.on("move",U._update.bind(b(U),!1)),U.on("zoom",U._update.bind(b(U),!0)),U.on("move",function(){U._rerender()}),a!==void 0&&(a.addEventListener("online",U._onWindowOnline,!1),a.addEventListener("resize",U._onWindowResize,!1)),p(b(U),R),U._hash=R.hash&&new s().addTo(b(U)),U._hash&&U._hash._onHashChange()||U.jumpTo({center:R.center,zoom:R.zoom,bearing:R.bearing,pitch:R.pitch}),U.resize(),R.style&&U.setStyle(R.style,{localIdeographFontFamily:R.localIdeographFontFamily}),R.attributionControl&&U.addControl(new x),U.addControl(new T,R.logoPosition),U.on("style.load",function(){this.transform.unmodified&&this.jumpTo(this.style.stylesheet)}),U.on("data",U._onData),U.on("dataloading",U._onDataLoading),U}var W,J,X;return function(R,U){if(typeof U!="function"&&U!==null)throw new TypeError("Super expression must either be null or a function");R.prototype=Object.create(U&&U.prototype,{constructor:{value:R,writable:!0,configurable:!0}}),U&&c(R,U)}(Z,w),W=Z,(J=[{key:"addControl",value:function(R,U){U===void 0&&R.getDefaultPosition&&(U=R.getDefaultPosition()),U===void 0&&(U="top-right");var K=R.onAdd(this),q=this._controlPositions[U];return U.indexOf("bottom")!==-1?q.insertBefore(K,q.firstChild):q.appendChild(K),this}},{key:"removeControl",value:function(R){return R.onRemove(this),this}},{key:"resize",value:function(){var R=this._containerDimensions(),U=R[0],K=R[1];return this._resizeCanvas(U,K),this.transform.resize(U,K),this.painter.resize(U,K),this.fire("movestart").fire("move").fire("resize").fire("moveend")}},{key:"getBounds",value:function(){var R=new k(this.transform.pointLocation(new v(0,this.transform.height)),this.transform.pointLocation(new v(this.transform.width,0)));return(this.transform.angle||this.transform.pitch)&&(R.extend(this.transform.pointLocation(new v(this.transform.size.x,0))),R.extend(this.transform.pointLocation(new v(0,this.transform.size.y)))),R}},{key:"getMaxBounds",value:function(){return this.transform.latRange&&this.transform.latRange.length===2&&this.transform.lngRange&&this.transform.lngRange.length===2?new k([this.transform.lngRange[0],this.transform.latRange[0]],[this.transform.lngRange[1],this.transform.latRange[1]]):null}},{key:"setMaxBounds",value:function(R){if(R){var U=k.convert(R);this.transform.lngRange=[U.getWest(),U.getEast()],this.transform.latRange=[U.getSouth(),U.getNorth()],this.transform._constrain(),this._update()}else R==null&&(this.transform.lngRange=null,this.transform.latRange=null,this._update());return this}},{key:"setMinZoom",value:function(R){if((R=R??0)>=0&&R<=this.transform.maxZoom)return this.transform.minZoom=R,this._update(),this.getZoom()=this.transform.minZoom)return this.transform.maxZoom=R,this._update(),this.getZoom()>R&&this.setZoom(R),this;throw new Error("maxZoom must be greater than the current minZoom")}},{key:"getMaxZoom",value:function(){return this.transform.maxZoom}},{key:"project",value:function(R){return this.transform.locationPoint(A.convert(R))}},{key:"unproject",value:function(R){return this.transform.pointLocation(v.convert(R))}},{key:"on",value:function(R,U,K){var q=this;if(K===void 0)return g(f(Z.prototype),"on",this).call(this,R,U);var L=function(){if(R==="mouseenter"||R==="mouseover"){var j=!1;return{layer:U,listener:K,delegates:{mousemove:function(H){var Y=q.getLayer(U)?q.queryRenderedFeatures(H.point,{layers:[U]}):[];Y.length?j||(j=!0,K.call(q,u.extend({features:Y},H,{type:R}))):j=!1},mouseout:function(){j=!1}}}}if(R==="mouseleave"||R==="mouseout"){var M=!1;return{layer:U,listener:K,delegates:{mousemove:function(H){(q.getLayer(U)?q.queryRenderedFeatures(H.point,{layers:[U]}):[]).length?M=!0:M&&(M=!1,K.call(q,u.extend({},H,{type:R})))},mouseout:function(H){M&&(M=!1,K.call(q,u.extend({},H,{type:R})))}}}}var N,V,G;return{layer:U,listener:K,delegates:(N={},V=R,G=function(H){var Y=q.getLayer(U)?q.queryRenderedFeatures(H.point,{layers:[U]}):[];Y.length&&K.call(q,u.extend({features:Y},H))},V in N?Object.defineProperty(N,V,{value:G,enumerable:!0,configurable:!0,writable:!0}):N[V]=G,N)}}();for(var I in this._delegatedListeners=this._delegatedListeners||{},this._delegatedListeners[R]=this._delegatedListeners[R]||[],this._delegatedListeners[R].push(L),L.delegates)this.on(I,L.delegates[I]);return this}},{key:"off",value:function(R,U,K){if(K===void 0)return g(f(Z.prototype),"off",this).call(this,R,U);if(this._delegatedListeners&&this._delegatedListeners[R])for(var q=this._delegatedListeners[R],L=0;L2&&arguments[2]!==void 0?arguments[2]:{},q=K.pixelRatio,L=q===void 0?1:q,I=K.sdf,j=I!==void 0&&I;if(U instanceof t){var M=i.getImageData(U),N=M.width,V=M.height,G=M.data;this.style.addImage(R,{data:new C({width:N,height:V},G),pixelRatio:L,sdf:j})}else{if(U.width===void 0||U.height===void 0)return this.fire("error",{error:new Error("Invalid arguments to map.addImage(). The second argument must be an `HTMLImageElement`, `ImageData`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")});var H=U.width,Y=U.height,$=U.data;this.style.addImage(R,{data:new C({width:H,height:Y},$.slice(0)),pixelRatio:L,sdf:j})}}},{key:"hasImage",value:function(R){return R?!!this.style.getImage(R):(this.fire("error",{error:new Error("Missing required image id")}),!1)}},{key:"removeImage",value:function(R){this.style.removeImage(R)}},{key:"loadImage",value:function(R,U){d.getImage(this._transformRequest(R,d.ResourceType.Image),U)}},{key:"addLayer",value:function(R,U){return this.style.addLayer(R,U),this._update(!0),this}},{key:"moveLayer",value:function(R,U){return this.style.moveLayer(R,U),this._update(!0),this}},{key:"removeLayer",value:function(R){return this.style.removeLayer(R),this._update(!0),this}},{key:"getLayer",value:function(R){return this.style.getLayer(R)}},{key:"setFilter",value:function(R,U){return this.style.setFilter(R,U),this._update(!0),this}},{key:"setLayerZoomRange",value:function(R,U,K){return this.style.setLayerZoomRange(R,U,K),this._update(!0),this}},{key:"getFilter",value:function(R){return this.style.getFilter(R)}},{key:"setPaintProperty",value:function(R,U,K){return this.style.setPaintProperty(R,U,K),this._update(!0),this}},{key:"getPaintProperty",value:function(R,U){return this.style.getPaintProperty(R,U)}},{key:"setLayoutProperty",value:function(R,U,K){return this.style.setLayoutProperty(R,U,K),this._update(!0),this}},{key:"getLayoutProperty",value:function(R,U){return this.style.getLayoutProperty(R,U)}},{key:"setLight",value:function(R){return this.style.setLight(R),this._update(!0),this}},{key:"getLight",value:function(){return this.style.getLight()}},{key:"getContainer",value:function(){return this._container}},{key:"getCanvasContainer",value:function(){return this._canvasContainer}},{key:"getCanvas",value:function(){return this._canvas}},{key:"_containerDimensions",value:function(){var R=0,U=0;return this._container&&(R=this._container.offsetWidth||400,U=this._container.offsetHeight||300),[R,U]}},{key:"_setupContainer",value:function(){var R=this._container;R.classList.add("mapboxgl-map"),(this._missingCSSContainer=l.create("div","mapboxgl-missing-css",R)).innerHTML="Missing Mapbox GL JS CSS";var U=this._canvasContainer=l.create("div","mapboxgl-canvas-container",R);this._interactive&&U.classList.add("mapboxgl-interactive"),this._canvas=l.create("canvas","mapboxgl-canvas",U),this._canvas.style.position="absolute",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");var K=this._containerDimensions();this._resizeCanvas(K[0],K[1]);var q=this._controlContainer=l.create("div","mapboxgl-control-container",R),L=this._controlPositions={};["top-left","top-right","bottom-left","bottom-right"].forEach(function(I){L[I]=l.create("div","mapboxgl-ctrl-".concat(I),q)})}},{key:"_resizeCanvas",value:function(R,U){var K=a.devicePixelRatio||1;this._canvas.width=K*R,this._canvas.height=K*U,this._canvas.style.width="".concat(R,"px"),this._canvas.style.height="".concat(U,"px")}},{key:"_setupPainter",value:function(){var R=u.extend({failIfMajorPerformanceCaveat:this._failIfMajorPerformanceCaveat,preserveDrawingBuffer:this._preserveDrawingBuffer},E.webGLContextAttributes),U=this._canvas.getContext("webgl",R)||this._canvas.getContext("experimental-webgl",R);U?this.painter=new S(U,this.transform):this.fire("error",{error:new Error("Failed to initialize WebGL")})}},{key:"_contextLost",value:function(R){R.preventDefault(),this._frameId&&(i.cancelFrame(this._frameId),this._frameId=null),this.fire("webglcontextlost",{originalEvent:R})}},{key:"_contextRestored",value:function(R){this._setupPainter(),this.resize(),this._update(),this.fire("webglcontextrestored",{originalEvent:R})}},{key:"loaded",value:function(){return!this._styleDirty&&!this._sourcesDirty&&!(!this.style||!this.style.loaded())}},{key:"_update",value:function(R){this.style&&(this._styleDirty=this._styleDirty||R,this._sourcesDirty=!0,this._rerender())}},{key:"_render",value:function(){this.isEasing()&&this._updateEase();var R=!1;if(this.style&&this._styleDirty){this._styleDirty=!1;var U=this.transform.zoom,K=i.now();this.style.zoomHistory.update(U,K);var q=new m(U,{now:K,fadeDuration:this._fadeDuration,zoomHistory:this.style.zoomHistory,transition:this.style.getTransition()}),L=q.crossFadingFactor();L===1&&L===this._crossFadingFactor||(R=!0,this._crossFadingFactor=L),this.style.update(q)}return this.style&&this._sourcesDirty&&(this._sourcesDirty=!1,this.style._updateSources(this.transform)),this._placementDirty=this.style&&this.style._updatePlacement(this.painter.transform,this.showCollisionBoxes,this._fadeDuration),this.painter.render(this.style,{showTileBoundaries:this.showTileBoundaries,showOverdrawInspector:this._showOverdrawInspector,rotating:this.rotating,zooming:this.zooming,fadeDuration:this._fadeDuration}),this.fire("render"),this.loaded()&&!this._loaded&&(this._loaded=!0,this.fire("load")),this.style&&(this.style.hasTransitions()||R)&&(this._styleDirty=!0),(this._sourcesDirty||this._repaint||this._styleDirty||this._placementDirty||this.isEasing())&&this._rerender(),this}},{key:"remove",value:function(){this._hash&&this._hash.remove(),i.cancelFrame(this._frameId),this._frameId=null,this.setStyle(null),a!==void 0&&(a.removeEventListener("resize",this._onWindowResize,!1),a.removeEventListener("online",this._onWindowOnline,!1));var R=this.painter.context.gl.getExtension("WEBGL_lose_context");R&&R.loseContext(),B(this._canvasContainer),B(this._controlContainer),B(this._missingCSSContainer),this._container.classList.remove("mapboxgl-map"),this.fire("remove")}},{key:"_rerender",value:function(){var R=this;this.style&&!this._frameId&&(this._frameId=i.frame(function(){R._frameId=null,R._render()}))}},{key:"_onWindowOnline",value:function(){this._update()}},{key:"_onWindowResize",value:function(){this._trackResize&&this.stop().resize()._update()}},{key:"_onData",value:function(R){this._update(R.dataType==="style"),this.fire("".concat(R.dataType,"data"),R)}},{key:"_onDataLoading",value:function(R){this.fire("".concat(R.dataType,"dataloading"),R)}},{key:"showTileBoundaries",get:function(){return!!this._showTileBoundaries},set:function(R){this._showTileBoundaries!==R&&(this._showTileBoundaries=R,this._update())}},{key:"showCollisionBoxes",get:function(){return!!this._showCollisionBoxes},set:function(R){this._showCollisionBoxes!==R&&(this._showCollisionBoxes=R,R?this.style._generateCollisionBoxes():this._update())}},{key:"showOverdrawInspector",get:function(){return!!this._showOverdrawInspector},set:function(R){this._showOverdrawInspector!==R&&(this._showOverdrawInspector=R,this._update())}},{key:"repaint",get:function(){return!!this._repaint},set:function(R){this._repaint=R,this._update()}},{key:"vertices",get:function(){return!!this._vertices},set:function(R){this._vertices=R,this._update()}}])&&e(W.prototype,J),X&&e(W,X),Z}();function B(F){F.parentNode&&F.parentNode.removeChild(F)}O.exports=P},function(O,D){var o;o=function(){return this}();try{o=o||new Function("return this")()}catch{typeof window=="object"&&(o=window)}O.exports=o},function(O,D,o){"use strict";/* object-assign (c) Sindre Sorhus @license MIT */var _=Object.getOwnPropertySymbols,e=Object.prototype.hasOwnProperty,b=Object.prototype.propertyIsEnumerable;O.exports=function(){try{if(!Object.assign)return!1;var g=new String("abc");if(g[5]="de",Object.getOwnPropertyNames(g)[0]==="5")return!1;for(var f={},c=0;c<10;c++)f["_"+String.fromCharCode(c)]=c;if(Object.getOwnPropertyNames(f).map(function(i){return f[i]}).join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(i){u[i]=i}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}()?Object.assign:function(g,f){for(var c,u,i=function(r){if(r==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(r)}(g),a=1;a=Z)return X;switch(X){case"%s":return String(F[B++]);case"%d":return Number(F[B++]);case"%j":try{return JSON.stringify(F[B++])}catch{return"[Circular]"}default:return X}}),J=F[B];B=3&&(B.depth=arguments[2]),arguments.length>=4&&(B.colors=arguments[3]),l(P)?B.showHidden=P:P&&D._extend(B,P),S(B.showHidden)&&(B.showHidden=!1),S(B.depth)&&(B.depth=2),S(B.colors)&&(B.colors=!1),S(B.customInspect)&&(B.customInspect=!0),B.colors&&(B.stylize=u),a(B,z,B.depth)}function u(z,P){var B=c.styles[P];return B?"\x1B["+c.colors[B][0]+"m"+z+"\x1B["+c.colors[B][1]+"m":z}function i(z,P){return z}function a(z,P,B){if(z.customInspect&&P&&A(P.inspect)&&P.inspect!==D.inspect&&(!P.constructor||P.constructor.prototype!==P)){var F=P.inspect(B,z);return m(F)||(F=a(z,F,B)),F}var Z=function(L,I){if(S(I))return L.stylize("undefined","undefined");if(m(I)){var j="'"+JSON.stringify(I).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return L.stylize(j,"string")}if(h(I))return L.stylize(""+I,"number");if(l(I))return L.stylize(""+I,"boolean");if(d(I))return L.stylize("null","null")}(z,P);if(Z)return Z;var W=Object.keys(P),J=function(L){var I={};return L.forEach(function(j,M){I[j]=!0}),I}(W);if(z.showHidden&&(W=Object.getOwnPropertyNames(P)),w(P)&&(W.indexOf("message")>=0||W.indexOf("description")>=0))return n(P);if(W.length===0){if(A(P)){var X=P.name?": "+P.name:"";return z.stylize("[Function"+X+"]","special")}if(y(P))return z.stylize(RegExp.prototype.toString.call(P),"regexp");if(p(P))return z.stylize(Date.prototype.toString.call(P),"date");if(w(P))return n(P)}var R,U="",K=!1,q=["{","}"];return r(P)&&(K=!0,q=["[","]"]),A(P)&&(U=" [Function"+(P.name?": "+P.name:"")+"]"),y(P)&&(U=" "+RegExp.prototype.toString.call(P)),p(P)&&(U=" "+Date.prototype.toUTCString.call(P)),w(P)&&(U=" "+n(P)),W.length!==0||K&&P.length!=0?B<0?y(P)?z.stylize(RegExp.prototype.toString.call(P),"regexp"):z.stylize("[Object]","special"):(z.seen.push(P),R=K?function(L,I,j,M,N){for(var V=[],G=0,H=I.length;G=0,M+N.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?j[0]+(I===""?"":I+` `)+" "+L.join(`, `)+" "+j[1]:j[0]+I+" "+L.join(", ")+" "+j[1]}(R,U,q)):q[0]+U+q[1]}function n(z){return"["+Error.prototype.toString.call(z)+"]"}function t(z,P,B,F,Z,W){var J,X,R;if((R=Object.getOwnPropertyDescriptor(P,Z)||{value:P[Z]}).get?X=R.set?z.stylize("[Getter/Setter]","special"):z.stylize("[Getter]","special"):R.set&&(X=z.stylize("[Setter]","special")),T(F,Z)||(J="["+Z+"]"),X||(z.seen.indexOf(R.value)<0?(X=d(B)?a(z,R.value,null):a(z,R.value,B-1)).indexOf(` `)>-1&&(X=W?X.split(` `).map(function(U){return" "+U}).join(` `).substr(2):` `+X.split(` `).map(function(U){return" "+U}).join(` `)):X=z.stylize("[Circular]","special")),S(J)){if(W&&Z.match(/^\d+$/))return X;(J=JSON.stringify(""+Z)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(J=J.substr(1,J.length-2),J=z.stylize(J,"name")):(J=J.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),J=z.stylize(J,"string"))}return J+": "+X}function r(z){return Array.isArray(z)}function l(z){return typeof z=="boolean"}function d(z){return z===null}function h(z){return typeof z=="number"}function m(z){return typeof z=="string"}function S(z){return z===void 0}function y(z){return s(z)&&k(z)==="[object RegExp]"}function s(z){return typeof z=="object"&&z!==null}function p(z){return s(z)&&k(z)==="[object Date]"}function w(z){return s(z)&&(k(z)==="[object Error]"||z instanceof Error)}function A(z){return typeof z=="function"}function k(z){return Object.prototype.toString.call(z)}function v(z){return z<10?"0"+z.toString(10):z.toString(10)}D.debuglog=function(z){if(S(g)&&(g=_.env.NODE_DEBUG||""),z=z.toUpperCase(),!f[z])if(new RegExp("\\b"+z+"\\b","i").test(g)){var P=_.pid;f[z]=function(){var B=D.format.apply(D,arguments);console.error("%s %d: %s",z,P,B)}}else f[z]=function(){};return f[z]},D.inspect=c,c.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},c.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},D.isArray=r,D.isBoolean=l,D.isNull=d,D.isNullOrUndefined=function(z){return z==null},D.isNumber=h,D.isString=m,D.isSymbol=function(z){return typeof z=="symbol"},D.isUndefined=S,D.isRegExp=y,D.isObject=s,D.isDate=p,D.isError=w,D.isFunction=A,D.isPrimitive=function(z){return z===null||typeof z=="boolean"||typeof z=="number"||typeof z=="string"||typeof z=="symbol"||z===void 0},D.isBuffer=o(138);var x=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function T(z,P){return Object.prototype.hasOwnProperty.call(z,P)}D.log=function(){var z,P;console.log("%s - %s",(z=new Date,P=[v(z.getHours()),v(z.getMinutes()),v(z.getSeconds())].join(":"),[z.getDate(),x[z.getMonth()],P].join(" ")),D.format.apply(D,arguments))},D.inherits=o(139),D._extend=function(z,P){if(!P||!s(P))return z;for(var B=Object.keys(P),F=B.length;F--;)z[B[F]]=P[B[F]];return z};var E=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;function C(z,P){if(!z){var B=new Error("Promise was rejected with a falsy value");B.reason=z,z=B}return P(z)}D.promisify=function(z){if(typeof z!="function")throw new TypeError('The "original" argument must be of type Function');if(E&&z[E]){var P;if(typeof(P=z[E])!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(P,E,{value:P,enumerable:!1,writable:!1,configurable:!0}),P}function P(){for(var B,F,Z=new Promise(function(X,R){B=X,F=R}),W=[],J=0;J1)for(var m=1;m`."},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.0511,180,85.0511],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."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},"*":{type:"*",doc:"Other keys to configure the data source."}},source_raster:{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://`."},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.0511,180,85.0511],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."},"*":{type:"*",doc:"Other keys to configure the data source."}},source_raster_dem:{type:{required:!0,type:"enum",values:{"raster-dem":{doc:"A raster DEM source using Mapbox Terrain RGB"}},doc:"The type of the source."},url:{type:"string",doc:"A URL to a TileJSON resource. Supported protocols are `http:`, `https:`, and `mapbox://`."},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.0511,180,85.0511],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."},"*":{type:"*",doc:"Other keys to configure the data source."}},source_geojson:{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)."},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."},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."},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)."}},source_video:{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."}}},source_image:{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."}}},source_canvas:{type:{required:!0,type:"enum",values:{canvas:{doc:"A canvas data source."}},doc:"The data type of the canvas source."},coordinates:{required:!0,doc:"Corners of canvas specified in longitude, latitude pairs.",type:"array",length:4,value:{type:"array",length:2,value:"number",doc:"A single longitude, latitude pair."}},animate:{type:"boolean",default:"true",doc:"Whether the canvas source is animated. If the canvas is static, `animate` should be set to `false` to improve performance."},canvas:{type:"string",required:!0,doc:"HTML ID of the canvas from which to read pixels."}},layer:{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"}}},"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 tiles","sdk-support":{"basic functionality":{js:"0.43.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 '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 on which the layer gets parsed and appears on."},maxzoom:{type:"number",minimum:0,maximum:24,doc:"The maximum zoom level on which the layer gets parsed and appears on."},filter:{type:"filter",doc:"A expression specifying conditions on source features. Only features that match the filter are displayed."},layout:{type:"layout",doc:"Layout properties for the layer."},paint:{type:"paint",doc:"Default paint properties for this layer."}},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:{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"}}}},layout_fill:{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"}}}},layout_circle:{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"}}}},layout_heatmap:{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"}}}},"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"}}}},layout_line:{"line-cap":{type:"enum",function:"piecewise-constant","zoom-function":!0,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":{}}},"line-join":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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"}}},"line-miter-limit":{type:"number",default:2,function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"line-round-limit":{type:"number",default:1.05,function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},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"},"data-driven styling":{}}}},layout_symbol:{"symbol-placement":{type:"enum",function:"piecewise-constant","zoom-function":!0,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."}},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"},"data-driven styling":{}}},"symbol-spacing":{type:"number",default:250,minimum:1,function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"symbol-avoid-edges":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}},"icon-allow-overlap":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"icon-ignore-placement":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"icon-optional":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"icon-rotation-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,values:{map:{doc:"When `symbol-placement` is set to `point`, aligns icons east-west. When `symbol-placement` is set to `line`, 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`, 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"},"data-driven styling":{}}},"icon-size":{type:"number",default:1,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-text-fit":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"icon-text-fit-padding":{type:"array",value:"number",length:4,default:[0,0,0,0],units:"pixels",function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"icon-image":{type:"string",function:"piecewise-constant","zoom-function":!0,"property-function":!0,doc:"Name of image in sprite to use for drawing an image background. Within literal values and zoom functions, property names enclosed in curly brackets (e.g. `{token}`) are replaced with the value of the named property. Expressions and property functions do not support this syntax; for equivalent functionality in expressions, use the [`concat`](#expressions-concat) and [`get`](#expressions-get) operators.",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"}}},"icon-rotate":{type:"number",default:0,period:360,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"icon-padding":{type:"number",default:2,minimum:0,function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"icon-keep-upright":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}},"icon-offset":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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"}}},"icon-pitch-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-pitch-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-rotation-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,values:{map:{doc:"When `symbol-placement` is set to `point`, aligns text east-west. When `symbol-placement` is set to `line`, 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`, 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"},"data-driven styling":{}}},"text-field":{type:"string",function:"piecewise-constant","zoom-function":!0,"property-function":!0,default:"",tokens:!0,doc:"Value to use for a text label. Within literal values and zoom functions, property names enclosed in curly brackets (e.g. `{token}`) are replaced with the value of the named property. Expressions and property functions do not support this syntax; for equivalent functionality in expressions, use the [`concat`](#expressions-concat) and [`get`](#expressions-get) operators.","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"}}},"text-font":{type:"array",value:"string",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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":{}}},"text-size":{type:"number",default:16,minimum:0,units:"pixels",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-max-width":{type:"number",default:10,minimum:0,units:"ems",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-line-height":{type:"number",default:1.2,units:"ems",function:"interpolated","zoom-function":!0,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":{}}},"text-letter-spacing":{type:"number",default:0,units:"ems",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-justify":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,values:{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"}}},"text-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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"],"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"}}},"text-max-angle":{type:"number",default:45,units:"degrees",function:"interpolated","zoom-function":!0,doc:"Maximum angle change between adjacent characters.",requires:["text-field",{"symbol-placement":"line"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}},"text-rotate":{type:"number",default:0,period:360,units:"degrees",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-padding":{type:"number",default:2,minimum:0,units:"pixels",function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"text-keep-upright":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}},"text-transform":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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"}}},"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.",value:"number",units:"ems",function:"interpolated","zoom-function":!0,"property-function":!0,length:2,default:[0,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.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},"text-allow-overlap":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-ignore-placement":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-optional":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},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"},"data-driven styling":{}}}},layout_raster:{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"},"data-driven styling":{}}}},layout_hillshade:{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"},"data-driven styling":{}}}},filter:{type:"array",value:"*",doc:"A filter selects specific features from a layer."},filter_operator:{type:"enum",values:{"==":{doc:'`["==", key, value]` equality: `feature[key] = value`'},"!=":{doc:'`["!=", key, value]` inequality: `feature[key] \u2260 value`'},">":{doc:'`[">", key, value]` greater than: `feature[key] > value`'},">=":{doc:'`[">=", key, value]` greater than or equal: `feature[key] \u2265 value`'},"<":{doc:'`["<", key, value]` less than: `feature[key] < value`'},"<=":{doc:'`["<=", key, value]` less than or equal: `feature[key] \u2264 value`'},in:{doc:'`["in", key, v0, ..., vn]` set inclusion: `feature[key] \u2208 {v0, ..., vn}`'},"!in":{doc:'`["!in", key, v0, ..., vn]` set exclusion: `feature[key] \u2209 {v0, ..., vn}`'},all:{doc:'`["all", f0, ..., fn]` logical `AND`: `f0 \u2227 ... \u2227 fn`'},any:{doc:'`["any", f0, ..., fn]` logical `OR`: `f0 \u2228 ... \u2228 fn`'},none:{doc:'`["none", f0, ..., fn]` logical `NOR`: `\xACf0 \u2227 ... \u2227 \xACfn`'},has:{doc:'`["has", key]` `feature[key]` exists'},"!has":{doc:'`["!has", key]` `feature[key]` does not exist'}},doc:"The filter operator."},geometry_type:{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."},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:{type:"array",minimum:0,maximum:22,value:["number","color"],length:2,doc:"Zoom level and value pair."},expression:{type:"array",value:"*",minimum:1,doc:"An expression defines a function that can be used for data-driven style properties or feature filters."},expression_name:{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"},var:{doc:'References variable bound using "let".',group:"Variable binding"},literal:{doc:"Provides a literal array or object value.",group:"Types"},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"},at:{doc:"Retrieves an item from an array.",group:"Lookup"},case:{doc:"Selects the first output whose corresponding test condition evaluates to true.",group:"Decision"},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 string or number expression (e.g. `["get", "building_type"]`). Each label can either be a single literal value or an array of values.',group:"Decision"},coalesce:{doc:"Evaluates each expression in turn until the first non-null value is obtained, and returns that value.",group:"Decision"},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 input if the input is less than the first stop.',group:"Ramps, scales, curves"},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`, 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"},ln2:{doc:"Returns mathematical constant ln(2).",group:"Math"},pi:{doc:"Returns the mathematical constant pi.",group:"Math"},e:{doc:"Returns the mathematical constant e.",group:"Math"},typeof:{doc:"Returns a string describing the type of the given value.",group:"Types"},string:{doc:"Asserts that the input value is a string. If multiple values are provided, each one is evaluated in order until a string value is obtained. If none of the inputs are strings, the expression is an error.",group:"Types"},number:{doc:"Asserts that the input value is a number. If multiple values are provided, each one is evaluated in order until a number value is obtained. If none of the inputs are numbers, the expression is an error.",group:"Types"},boolean:{doc:"Asserts that the input value is a boolean. If multiple values are provided, each one is evaluated in order until a boolean value is obtained. If none of the inputs are booleans, the expression is an error.",group:"Types"},object:{doc:"Asserts that the input value is an object. If it is not, the expression is an error.",group:"Types"},"to-string":{doc:'Converts the input value to a string. If the input is `null`, the result is `"null"`. 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"},"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"},"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"},"to-rgba":{doc:"Returns a four-element array containing the input color's red, green, blue, and alpha components, in that order.",group:"Color"},"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"},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"},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"},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"},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"},length:{doc:"Gets the length of an array or string.",group:"Lookup"},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"},"geometry-type":{doc:"Gets the feature's geometry type: Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon.",group:"Feature data"},id:{doc:"Gets the feature's id, if it has one.",group:"Feature data"},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"},"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"},"+":{doc:"Returns the sum of the inputs.",group:"Math"},"*":{doc:"Returns the product of the inputs.",group:"Math"},"-":{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"},"/":{doc:"Returns the result of floating point division of the first input by the second.",group:"Math"},"%":{doc:"Returns the remainder after integer division of the first input by the second.",group:"Math"},"^":{doc:"Returns the result of raising the first input to the power specified by the second.",group:"Math"},sqrt:{doc:"Returns the square root of the input.",group:"Math"},log10:{doc:"Returns the base-ten logarithm of the input.",group:"Math"},ln:{doc:"Returns the natural logarithm of the input.",group:"Math"},log2:{doc:"Returns the base-two logarithm of the input.",group:"Math"},sin:{doc:"Returns the sine of the input.",group:"Math"},cos:{doc:"Returns the cosine of the input.",group:"Math"},tan:{doc:"Returns the tangent of the input.",group:"Math"},asin:{doc:"Returns the arcsine of the input.",group:"Math"},acos:{doc:"Returns the arccosine of the input.",group:"Math"},atan:{doc:"Returns the arctangent of the input.",group:"Math"},min:{doc:"Returns the minimum value of the inputs.",group:"Math"},max:{doc:"Returns the maximum value of the inputs.",group:"Math"},"==":{doc:"Returns `true` if the input values are equal, `false` otherwise. The inputs must be numbers, strings, or booleans, and both of the same type.",group:"Decision"},"!=":{doc:"Returns `true` if the input values are not equal, `false` otherwise. The inputs must be numbers, strings, or booleans, and both of the same type.",group:"Decision"},">":{doc:"Returns `true` if the first input is strictly greater than the second, `false` otherwise. The inputs must be numbers or strings, and both of the same type.",group:"Decision"},"<":{doc:"Returns `true` if the first input is strictly less than the second, `false` otherwise. The inputs must be numbers or strings, and both of the same type.",group:"Decision"},">=":{doc:"Returns `true` if the first input is greater than or equal to the second, `false` otherwise. The inputs must be numbers or strings, and both of the same type.",group:"Decision"},"<=":{doc:"Returns `true` if the first input is less than or equal to the second, `false` otherwise. The inputs must be numbers or strings, and both of the same type.",group:"Decision"},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"},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"},"!":{doc:"Logical negation. Returns `true` if the input is `false`, and `false` if the input is `true`.",group:"Decision"},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"},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"},concat:{doc:"Returns a string consisting of the concatenation of the inputs.",group:"String"}}},light:{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."}},transition:!1,"zoom-function":!0,"property-function":!1,function:"piecewise-constant",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",transition:!0,function:"interpolated","zoom-function":!0,"property-function":!1,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\xB0 (0\xB0 when `light.anchor` is set to `viewport` corresponds to the top of the viewport, or 0\xB0 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\xB0, directly above, to 180\xB0, 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",default:"#ffffff",function:"interpolated","zoom-function":!0,"property-function":!1,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",default:.5,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!1,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"}}}},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",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"fill-opacity":{type:"number",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"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.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"fill-outline-color":{type:"color",doc:"The outline color of the fill. Matches the value of `fill-color` if unspecified.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"fill-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"fill-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"fill-pattern":{type:"string",function:"piecewise-constant","zoom-function":!0,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).","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}}},"paint_fill-extrusion":{"fill-extrusion-opacity":{type:"number",function:"interpolated","zoom-function":!0,"property-function":!1,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"}}},"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.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"fill-extrusion-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"fill-extrusion-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"fill-extrusion-pattern":{type:"string",function:"piecewise-constant","zoom-function":!0,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).","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{}}},"fill-extrusion-height":{type:"number",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"fill-extrusion-base":{type:"number",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}}},paint_line:{"line-opacity":{type:"number",doc:"The opacity at which the line will be drawn.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"line-color":{type:"color",doc:"The color with which the line will be drawn.",default:"#000000",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"line-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"line-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"line-width":{type:"number",default:1,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"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.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"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.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"line-blur":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"line-dasharray":{type:"array",value:"number",function:"piecewise-constant","zoom-function":!0,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.",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":{}}},"line-pattern":{type:"string",function:"piecewise-constant","zoom-function":!0,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).","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}}},paint_circle:{"circle-radius":{type:"number",default:5,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"circle-color":{type:"color",default:"#000000",doc:"The fill color of the circle.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"circle-blur":{type:"number",default:0,doc:"Amount to blur the circle. 1 blurs the circle such that only the centerpoint is full opacity.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"circle-opacity":{type:"number",doc:"The opacity at which the circle will be drawn.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"circle-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"circle-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"circle-pitch-scale":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"circle-pitch-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"circle-stroke-width":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"circle-stroke-color":{type:"color",default:"#000000",doc:"The stroke color of the circle.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"circle-stroke-opacity":{type:"number",doc:"The opacity of the circle's stroke.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}}},paint_heatmap:{"heatmap-radius":{type:"number",default:30,minimum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"},"data-driven styling":{}}},"heatmap-weight":{type:"number",default:1,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"},"data-driven styling":{js:"0.41.0"}}},"heatmap-intensity":{type:"number",default:1,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!1,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"},"data-driven styling":{}}},"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.',function:"interpolated","zoom-function":!1,"property-function":!1,transition:!1,"sdk-support":{"basic functionality":{js:"0.41.0"},"data-driven styling":{}}},"heatmap-opacity":{type:"number",doc:"The global opacity at which the heatmap layer will be drawn.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!1,transition:!0,"sdk-support":{"basic functionality":{js:"0.41.0"},"data-driven styling":{}}}},paint_symbol:{"icon-opacity":{doc:"The opacity at which the icon will be drawn.",type:"number",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"icon-color":{type:"color",default:"#000000",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"icon-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-halo-width":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-halo-blur":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"icon-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-opacity":{type:"number",doc:"The opacity at which the text will be drawn.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-color":{type:"color",doc:"The color with which the text will be drawn.",default:"#000000",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",function:"interpolated","zoom-function":!0,"property-function":!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"}}},"text-halo-width":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"text-halo-blur":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"text-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"text-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}}},paint_raster:{"raster-opacity":{type:"number",doc:"The opacity at which the image will be drawn.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,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":{}}},"raster-hue-rotate":{type:"number",default:0,period:360,function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"raster-brightness-min":{type:"number",function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"raster-brightness-max":{type:"number",function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"raster-saturation":{type:"number",doc:"Increase or reduce the saturation of the image.",default:0,minimum:-1,maximum:1,function:"interpolated","zoom-function":!0,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":{}}},"raster-contrast":{type:"number",doc:"Increase or reduce the contrast of the image.",default:0,minimum:-1,maximum:1,function:"interpolated","zoom-function":!0,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":{}}},"raster-fade-duration":{type:"number",default:300,minimum:0,function:"interpolated","zoom-function":!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"},"data-driven styling":{}}}},paint_hillshade:{"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`.",function:"interpolated","zoom-function":!0,transition:!1},"hillshade-illumination-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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."},"hillshade-exaggeration":{type:"number",doc:"Intensity of the hillshade",default:.5,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,transition:!0},"hillshade-shadow-color":{type:"color",default:"#000000",doc:"The shading color of areas that face away from the light source.",function:"interpolated","zoom-function":!0,transition:!0},"hillshade-highlight-color":{type:"color",default:"#FFFFFF",doc:"The shading color of areas that faces towards the light source.",function:"interpolated","zoom-function":!0,transition:!0},"hillshade-accent-color":{type:"color",default:"#000000",doc:"The shading color used to accentuate rugged terrain like sharp cliffs and gorges.",function:"interpolated","zoom-function":!0,transition:!0}},paint_background:{"background-color":{type:"color",default:"#000000",doc:"The color with which the background will be drawn.",function:"interpolated","zoom-function":!0,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"}}},"background-pattern":{type:"string",function:"piecewise-constant","zoom-function":!0,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).","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},"background-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity at which the background will be drawn.",function:"interpolated","zoom-function":!0,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}}},transition:{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."}}}},function(O,D,o){var _=o(75),e=o(29),b=o(13),g=o(150);function f(i,a){a=a||b;var n=[];return n=n.concat(e({key:"",value:i,valueSpec:a.$root,styleSpec:a,style:i,objectElementValidators:{glyphs:g,"*":function(){return[]}}})),i.constants&&(n=n.concat(_({key:"constants",value:i.constants,style:i,styleSpec:a}))),c(n)}function c(i){return[].concat(i).sort(function(a,n){return a.line-n.line})}function u(i){return function(){return c(i.apply(this,arguments))}}f.source=u(o(99)),f.light=u(o(100)),f.layer=u(o(95)),f.filter=u(o(59)),f.paintProperty=u(o(96)),f.layoutProperty=u(o(98)),O.exports=f},function(O,D,o){function _(i,a){for(var n=0;n=d.length)throw new c("Array index out of bounds: ".concat(l," > ").concat(d.length,"."));if(l!==Math.floor(l))throw new c("Array index must be an integer, but found ".concat(l," instead."));return d[l]}},{key:"eachChild",value:function(r){r(this.index),r(this.input)}},{key:"possibleOutputs",value:function(){return[void 0]}}])&&_(a.prototype,n),t&&_(a,t),i}();O.exports=u},function(O,D,o){function _(c){return function(u){if(Array.isArray(u)){for(var i=0,a=new Array(u.length);iNumber.MAX_SAFE_INTEGER)return s.error("Branch labels must be integers no larger than ".concat(Number.MAX_SAFE_INTEGER,"."));if(typeof x=="number"&&Math.floor(x)!==x)return s.error("Numeric branch labels must be integer values.");if(r){if(s.checkSubtype(r,g(x)))return null}else r=g(x);if(d[String(x)]!==void 0)return s.error("Branch labels must be unique.");d[String(x)]=h.length}}catch(z){w=!0,A=z}finally{try{p||v.return==null||v.return()}finally{if(w)throw A}}var T=t.parse(y,m,l);if(!T)return null;l=l||T.type,h.push(T)}var E=t.parse(n[1],1,r);if(!E)return null;var C=t.parse(n[n.length-1],n.length-1,l);return C?(b(r&&l),new c(r,l,E,d,h,C)):null}}],(i=[{key:"evaluate",value:function(n){var t=this.input.evaluate(n);return(this.outputs[this.cases[t]]||this.otherwise).evaluate(n)}},{key:"eachChild",value:function(n){n(this.input),this.outputs.forEach(n),n(this.otherwise)}},{key:"possibleOutputs",value:function(){var n;return(n=[]).concat.apply(n,_(this.outputs.map(function(t){return t.possibleOutputs()}))).concat(this.otherwise.possibleOutputs())}}])&&e(u.prototype,i),a&&e(u,a),c}();O.exports=f},function(O,D,o){function _(u){return function(i){if(Array.isArray(i)){for(var a=0,n=new Array(i.length);aa?Math.pow(s,.3333333333333333):s/i+c}function l(s){return s>u?s*s*s:i*(s-c)}function d(s){return 255*(s<=.0031308?12.92*s:1.055*Math.pow(s,.4166666666666667)-.055)}function h(s){return(s/=255)<=.04045?s/12.92:Math.pow((s+.055)/1.055,2.4)}function m(s){var p=h(s.r),w=h(s.g),A=h(s.b),k=r((.4124564*p+.3575761*w+.1804375*A)/b),v=r((.2126729*p+.7151522*w+.072175*A)/g);return{l:116*v-16,a:500*(k-v),b:200*(v-r((.0193339*p+.119192*w+.9503041*A)/f)),alpha:s.a}}function S(s){var p=(s.l+16)/116,w=isNaN(s.a)?p:p+s.a/500,A=isNaN(s.b)?p:p-s.b/200;return p=g*l(p),w=b*l(w),A=f*l(A),new _(d(3.2404542*w-1.5371385*p-.4985314*A),d(-.969266*w+1.8760108*p+.041556*A),d(.0556434*w-.2040259*p+1.0572252*A),s.alpha)}function y(s,p,w){var A=p-s;return s+w*(A>180||A<-180?A-360*Math.round(A/360):A)}O.exports={lab:{forward:m,reverse:S,interpolate:function(s,p,w){return{l:e(s.l,p.l,w),a:e(s.a,p.a,w),b:e(s.b,p.b,w),alpha:e(s.alpha,p.alpha,w)}}},hcl:{forward:function(s){var p=m(s),w=p.l,A=p.a,k=p.b,v=Math.atan2(k,A)*t;return{h:v<0?v+360:v,c:Math.sqrt(A*A+k*k),l:w,alpha:s.a}},reverse:function(s){var p=s.h*n,w=s.c;return S({l:s.l,a:Math.cos(p)*w,b:Math.sin(p)*w,alpha:s.alpha})},interpolate:function(s,p,w){return{h:y(s.h,p.h,w),c:e(s.c,p.c,w),l:e(s.l,p.l,w),alpha:e(s.alpha,p.alpha,w)}}}}},function(O,D,o){var _=o(17),e=o(7);O.exports=function(b){var g=b.value,f=b.key,c=_(g);return c!=="boolean"?[new e(f,g,"boolean expected, ".concat(c," found"))]:[]}},function(O,D,o){var _=o(7),e=o(17),b=o(80).parseCSSColor;O.exports=function(g){var f=g.key,c=g.value,u=e(c);return u!=="string"?[new _(f,c,"color expected, ".concat(u," found"))]:b(c)===null?[new _(f,c,'color expected, "'.concat(c,'" found'))]:[]}},function(O,D,o){var _=o(7),e=o(101);O.exports=function(b){var g=b.value,f=b.key,c=e(b);return c.length||(g.indexOf("{fontstack}")===-1&&c.push(new _(f,g,'"glyphs" url must include a "{fontstack}" token')),g.indexOf("{range}")===-1&&c.push(new _(f,g,'"glyphs" url must include a "{range}" token'))),c}},function(O,D,o){function _(m){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(S){return typeof S}:function(S){return S&&typeof Symbol=="function"&&S.constructor===Symbol&&S!==Symbol.prototype?"symbol":typeof S})(m)}function e(m,S){for(var y=0;yg?1:0}return function(b,g,f,c,u){(function i(a,n,t,r,l){for(;r>t;){if(r-t>600){var d=r-t+1,h=n-t+1,m=Math.log(d),S=.5*Math.exp(2*m/3),y=.5*Math.sqrt(m*S*(d-S)/d)*(h-d/2<0?-1:1),s=Math.max(t,Math.floor(n-h*S/d+y)),p=Math.min(r,Math.floor(n+(d-h)*S/d+y));i(a,n,s,p,l)}var w=a[n],A=t,k=r;for(_(a,t,n),l(a[r],w)>0&&_(a,t,r);A0;)k--}l(a[t],w)===0?_(a,t,k):_(a,++k,r),k<=n&&(t=k+1),n<=k&&(r=k-1)}})(b,g,f||0,c||b.length-1,u||e)}}()},function(O,D,o){var _=o(13),e=o(4),b=e.Properties,g=e.DataConstantProperty,f=e.DataDrivenProperty,c=e.CrossFadedProperty,u=(e.HeatmapColorProperty,new b({"fill-antialias":new g(_.paint_fill["fill-antialias"]),"fill-opacity":new f(_.paint_fill["fill-opacity"]),"fill-color":new f(_.paint_fill["fill-color"]),"fill-outline-color":new f(_.paint_fill["fill-outline-color"]),"fill-translate":new g(_.paint_fill["fill-translate"]),"fill-translate-anchor":new g(_.paint_fill["fill-translate-anchor"]),"fill-pattern":new c(_.paint_fill["fill-pattern"])}));O.exports={paint:u}},function(O,D,o){function _(h){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(m){return typeof m}:function(m){return m&&typeof Symbol=="function"&&m.constructor===Symbol&&m!==Symbol.prototype?"symbol":typeof m})(h)}function e(h,m){for(var S=0;S=1){var H=M[V-1];if(!y(G,H)){U.vertexLength+4>c&&(U=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray));var Y=G.sub(H)._perp()._unit(),$=H.dist(G);N+$>32768&&(N=0),m(this.layoutVertexArray,G.x,G.y,Y.x,Y.y,0,0,N),m(this.layoutVertexArray,G.x,G.y,Y.x,Y.y,0,1,N),N+=$,m(this.layoutVertexArray,H.x,H.y,Y.x,Y.y,0,0,N),m(this.layoutVertexArray,H.x,H.y,Y.x,Y.y,0,1,N);var Q=U.vertexLength;this.indexArray.emplaceBack(Q,Q+1,Q+2),this.indexArray.emplaceBack(Q+1,Q+2,Q+3),U.vertexLength+=4,U.primitiveLength+=2}}}}}catch(ht){q=!0,L=ht}finally{try{K||j.return==null||j.return()}finally{if(q)throw L}}U.vertexLength+F>c&&(U=this.segments.prepareSegment(F,this.layoutVertexArray,this.indexArray));var tt=[],et=[],nt=U.vertexLength,ot=!0,it=!1,at=void 0;try{for(var st,rt=B[Symbol.iterator]();!(ot=(st=rt.next()).done);ot=!0){var lt=st.value;if(lt.length!==0){lt!==B[0]&&et.push(tt.length/2);for(var ct=0;ctn)||p.y===w.y&&(p.y<0||p.y>n)}function s(p){return p.every(function(w){return w.x<0})||p.every(function(w){return w.x>n})||p.every(function(w){return w.y<0})||p.every(function(w){return w.y>n})}d("FillExtrusionBucket",S,{omit:["layers"]}),O.exports=S},function(O,D,o){var _=o(23).createLayout;O.exports=_([{name:"a_pos",components:2,type:"Int16"},{name:"a_normal_ed",components:4,type:"Int16"}],4)},function(O,D,o){var _=o(13),e=o(4),b=e.Properties,g=e.DataConstantProperty,f=e.DataDrivenProperty,c=e.CrossFadedProperty,u=(e.HeatmapColorProperty,new b({"fill-extrusion-opacity":new g(_["paint_fill-extrusion"]["fill-extrusion-opacity"]),"fill-extrusion-color":new f(_["paint_fill-extrusion"]["fill-extrusion-color"]),"fill-extrusion-translate":new g(_["paint_fill-extrusion"]["fill-extrusion-translate"]),"fill-extrusion-translate-anchor":new g(_["paint_fill-extrusion"]["fill-extrusion-translate-anchor"]),"fill-extrusion-pattern":new c(_["paint_fill-extrusion"]["fill-extrusion-pattern"]),"fill-extrusion-height":new f(_["paint_fill-extrusion"]["fill-extrusion-height"]),"fill-extrusion-base":new f(_["paint_fill-extrusion"]["fill-extrusion-base"])}));O.exports={paint:u}},function(O,D,o){function _(T){return(_=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})(T)}function e(T,E){if(!(T instanceof E))throw new TypeError("Cannot call a class as a function")}function b(T,E){for(var C=0;C0?E+2*T:T}O.exports=v},function(O,D,o){function _(S,y){for(var s=0;s>6)}var m=function(){function S(w){(function(A,k){if(!(A instanceof k))throw new TypeError("Cannot call a class as a function")})(this,S),this.zoom=w.zoom,this.overscaling=w.overscaling,this.layers=w.layers,this.layerIds=this.layers.map(function(A){return A.id}),this.index=w.index,this.layoutVertexArray=new e,this.indexArray=new c,this.programConfigurations=new f(b,w.layers,w.zoom),this.segments=new g}var y,s,p;return y=S,(s=[{key:"populate",value:function(w,A){var k=!0,v=!1,x=void 0;try{for(var T,E=w[Symbol.iterator]();!(k=(T=E.next()).done);k=!0){var C=T.value,z=C.feature,P=C.index,B=C.sourceLayerIndex;if(this.layers[0]._featureFilter({zoom:this.zoom},z)){var F=u(z);this.addFeature(z,F),A.featureIndex.insert(z,F,P,B,this.index)}}}catch(Z){v=!0,x=Z}finally{try{k||E.return==null||E.return()}finally{if(v)throw x}}}},{key:"isEmpty",value:function(){return this.layoutVertexArray.length===0}},{key:"upload",value:function(w){this.layoutVertexBuffer=w.createVertexBuffer(this.layoutVertexArray,b),this.indexBuffer=w.createIndexBuffer(this.indexArray),this.programConfigurations.upload(w)}},{key:"destroy",value:function(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}},{key:"addFeature",value:function(w,A){var k=this.layers[0].layout,v=k.get("line-join").evaluate(w),x=k.get("line-cap"),T=k.get("line-miter-limit"),E=k.get("line-round-limit"),C=!0,z=!1,P=void 0;try{for(var B,F=A[Symbol.iterator]();!(C=(B=F.next()).done);C=!0){var Z=B.value;this.addLine(Z,w,v,x,T,E)}}catch(W){z=!0,P=W}finally{try{C||F.return==null||F.return()}finally{if(z)throw P}}}},{key:"addLine",value:function(w,A,k,v,x,T){for(var E=a[A.type]==="Polygon",C=w.length;C>=2&&w[C-1].equals(w[C-2]);)C--;for(var z=0;zz){var H=Z.dist(K);if(H>2*P){var Y=Z.sub(Z.sub(K)._mult(P/H)._round());this.distance+=Y.dist(K),this.addCurrentVertex(Y,this.distance,L.mult(1),0,0,!1,F),K=Y}}var $=K&&q,Q=$?k:q?X:R;if($&&Q==="round"&&(Vx&&(Q="bevel"),Q==="bevel"&&(V>2&&(Q="flipbevel"),V100)M=I.clone().mult(-1);else{var tt=L.x*I.y-L.y*I.x>0?-1:1,et=V*L.add(I).mag()/L.sub(I).mag();M._perp()._mult(et*tt)}this.addCurrentVertex(Z,this.distance,M,0,0,!1,F),this.addCurrentVertex(Z,this.distance,M.mult(-1),0,0,!1,F)}else if(Q==="bevel"||Q==="fakeround"){var nt=L.x*I.y-L.y*I.x>0,ot=-Math.sqrt(V*V-1);if(nt?(J=0,W=ot):(W=0,J=ot),U||this.addCurrentVertex(Z,this.distance,L,W,J,!1,F),Q==="fakeround"){for(var it=Math.floor(8*(.5-(N-.5))),at=void 0,st=0;st=0;rt--)at=L.mult((rt+1)/(it+1))._add(I)._unit(),this.addPieSliceVertex(Z,this.distance,at,nt,F)}q&&this.addCurrentVertex(Z,this.distance,I,-W,-J,!1,F)}else Q==="butt"?(U||this.addCurrentVertex(Z,this.distance,L,0,0,!1,F),q&&this.addCurrentVertex(Z,this.distance,I,0,0,!1,F)):Q==="square"?(U||(this.addCurrentVertex(Z,this.distance,L,1,1,!1,F),this.e1=this.e2=-1),q&&this.addCurrentVertex(Z,this.distance,I,-1,-1,!1,F)):Q==="round"&&(U||(this.addCurrentVertex(Z,this.distance,L,0,0,!1,F),this.addCurrentVertex(Z,this.distance,L,1,1,!0,F),this.e1=this.e2=-1),q&&(this.addCurrentVertex(Z,this.distance,I,-1,-1,!0,F),this.addCurrentVertex(Z,this.distance,I,0,0,!1,F)));if(G&&j2*P){var ct=Z.add(q.sub(Z)._mult(P/lt)._round());this.distance+=ct.dist(Z),this.addCurrentVertex(ct,this.distance,I.mult(1),0,0,!1,F),Z=ct}}U=!1}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,A)}}},{key:"addCurrentVertex",value:function(w,A,k,v,x,T,E){var C,z=this.layoutVertexArray,P=this.indexArray;C=k.clone(),v&&C._sub(k.perp()._mult(v)),h(z,w,C,T,!1,v,A),this.e3=E.vertexLength++,this.e1>=0&&this.e2>=0&&(P.emplaceBack(this.e1,this.e2,this.e3),E.primitiveLength++),this.e1=this.e2,this.e2=this.e3,C=k.mult(-1),x&&C._sub(k.perp()._mult(x)),h(z,w,C,T,!0,-x,A),this.e3=E.vertexLength++,this.e1>=0&&this.e2>=0&&(P.emplaceBack(this.e1,this.e2,this.e3),E.primitiveLength++),this.e1=this.e2,this.e2=this.e3,A>d/2&&(this.distance=0,this.addCurrentVertex(w,this.distance,k,v,x,T,E))}},{key:"addPieSliceVertex",value:function(w,A,k,v,x){k=k.mult(v?-1:1);var T=this.layoutVertexArray,E=this.indexArray;h(T,w,k,!1,v,0,A),this.e3=x.vertexLength++,this.e1>=0&&this.e2>=0&&(E.emplaceBack(this.e1,this.e2,this.e3),x.primitiveLength++),v?this.e2=this.e3:this.e1=this.e3}}])&&_(y.prototype,s),p&&_(y,p),S}();n("LineBucket",m,{omit:["layers"]}),O.exports=m},function(O,D,o){var _=o(23).createLayout;O.exports=_([{name:"a_pos_normal",components:4,type:"Int16"},{name:"a_data",components:4,type:"Uint8"}],4)},function(O,D,o){"use strict";var _=o(106);function e(b,g,f){if(b===3){var c=new _(f,f.readVarint()+f.pos);c.length&&(g[c.name]=c)}}O.exports=function(b,g){this.layers=b.readFields(e,{},g)}},function(O,D,o){var _=o(13),e=o(4),b=e.Properties,g=e.DataConstantProperty,f=e.DataDrivenProperty,c=e.CrossFadedProperty,u=(e.HeatmapColorProperty,new b({"line-cap":new g(_.layout_line["line-cap"]),"line-join":new f(_.layout_line["line-join"]),"line-miter-limit":new g(_.layout_line["line-miter-limit"]),"line-round-limit":new g(_.layout_line["line-round-limit"])})),i=new b({"line-opacity":new f(_.paint_line["line-opacity"]),"line-color":new f(_.paint_line["line-color"]),"line-translate":new g(_.paint_line["line-translate"]),"line-translate-anchor":new g(_.paint_line["line-translate-anchor"]),"line-width":new f(_.paint_line["line-width"]),"line-gap-width":new f(_.paint_line["line-gap-width"]),"line-offset":new f(_.paint_line["line-offset"]),"line-blur":new f(_.paint_line["line-blur"]),"line-dasharray":new c(_.paint_line["line-dasharray"]),"line-pattern":new c(_.paint_line["line-pattern"])});O.exports={paint:i,layout:u}},function(O,D,o){function _(h){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(m){return typeof m}:function(m){return m&&typeof Symbol=="function"&&m.constructor===Symbol&&m!==Symbol.prototype?"symbol":typeof m})(h)}function e(h,m){for(var S=0;S1?"@2x":"";function r(){if(n)u(n);else if(i&&a){var l=e.getImageData(a),d={};for(var h in i){var m=i[h],S=m.width,y=m.height,s=m.x,p=m.y,w=m.sdf,A=m.pixelRatio,k=new g({width:S,height:y});g.copy(l,k,{x:s,y:p},{x:0,y:0},{width:S,height:y}),d[h]={data:k,pixelRatio:A,sdf:w}}u(null,d)}}_.getJSON(c(b(f,t,".json"),_.ResourceType.SpriteJSON),function(l,d){n||(n=l,i=d,r())}),_.getImage(c(b(f,t,".png"),_.ResourceType.SpriteImage),function(l,d){n||(n=l,a=d,r())})}},function(O,D,o){function _(i,a){for(var n=0;n65535)v(new Error("glyphs > 65535 not supported"));else{var P=E.requests[z];P||(P=E.requests[z]=[],e(x,z,d.url,d.requestTransform,function(B,F){if(F)for(var Z in F)E.glyphs[+Z]=F[+Z];var W=!0,J=!1,X=void 0;try{for(var R,U=P[Symbol.iterator]();!(W=(R=U.next()).done);W=!0)(0,R.value)(B,F)}catch(K){J=!0,X=K}finally{try{W||U.return==null||U.return()}finally{if(J)throw X}}delete E.requests[z]})),P.push(function(B,F){B?v(B):F&&v(null,{stack:x,id:T,glyph:F[T]||null})})}}else v(null,{stack:x,id:T,glyph:C})},function(k,v){if(k)l(k);else if(v){var x={},T=!0,E=!1,C=void 0;try{for(var z,P=v[Symbol.iterator]();!(T=(z=P.next()).done);T=!0){var B=z.value,F=B.stack,Z=B.id,W=B.glyph;(x[F]||(x[F]={}))[Z]=W&&{id:W.id,bitmap:W.bitmap.clone(),metrics:W.metrics}}}catch(J){E=!0,C=J}finally{try{T||P.return==null||P.return()}finally{if(E)throw C}}l(null,x)}})}},{key:"_tinySDF",value:function(r,l,d){var h=this.localIdeographFontFamily;if(h&&(g["CJK Unified Ideographs"](d)||g["Hangul Syllables"](d))){var m=r.tinySDF;if(!m){var S="400";/bold/i.test(l)?S="900":/medium/i.test(l)?S="500":/light/i.test(l)&&(S="200"),m=r.tinySDF=new b(24,3,8,.25,h,S)}return{id:d,bitmap:new c({width:30,height:30},m.draw(String.fromCharCode(d))),metrics:{width:24,height:24,left:0,top:-8,advance:24}}}}}])&&_(a.prototype,n),t&&_(a,t),i}();O.exports=u},function(O,D,o){var _=o(34).normalizeGlyphsURL,e=o(16),b=o(189);O.exports=function(g,f,c,u,i){var a=256*f,n=a+255,t=u(_(c).replace("{fontstack}",g).replace("{range}","".concat(a,"-").concat(n)),e.ResourceType.Glyphs);e.getArrayBuffer(t,function(r,l){if(r)i(r);else if(l){var d={},h=!0,m=!1,S=void 0;try{for(var y,s=b(l.data)[Symbol.iterator]();!(h=(y=s.next()).done);h=!0){var p=y.value;d[p.id]=p}}catch(w){m=!0,S=w}finally{try{h||s.return==null||s.return()}finally{if(m)throw S}}i(null,d)}})}},function(O,D,o){var _=o(33).AlphaImage,e=o(65),b=3;function g(u,i,a){u===1&&a.readMessage(f,i)}function f(u,i,a){if(u===3){var n=a.readMessage(c,{}),t=n.id,r=n.bitmap,l=n.width,d=n.height,h=n.left,m=n.top,S=n.advance;i.push({id:t,bitmap:new _({width:l+2*b,height:d+2*b},r),metrics:{width:l,height:d,left:h,top:m,advance:S}})}}function c(u,i,a){u===1?i.id=a.readVarint():u===2?i.bitmap=a.readBytes():u===3?i.width=a.readVarint():u===4?i.height=a.readVarint():u===5?i.left=a.readSVarint():u===6?i.top=a.readSVarint():u===7&&(i.advance=a.readVarint())}O.exports=function(u){return new e(u).readFields(g,[])},O.exports.GLYPH_PBF_BORDER=b},function(O,D){D.read=function(o,_,e,b,g){var f,c,u=8*g-b-1,i=(1<>1,n=-7,t=e?g-1:0,r=e?-1:1,l=o[_+t];for(t+=r,f=l&(1<<-n)-1,l>>=-n,n+=u;n>0;f=256*f+o[_+t],t+=r,n-=8);for(c=f&(1<<-n)-1,f>>=-n,n+=b;n>0;c=256*c+o[_+t],t+=r,n-=8);if(f===0)f=1-a;else{if(f===i)return c?NaN:1/0*(l?-1:1);c+=Math.pow(2,b),f-=a}return(l?-1:1)*c*Math.pow(2,f-b)},D.write=function(o,_,e,b,g,f){var c,u,i,a=8*f-g-1,n=(1<>1,r=g===23?Math.pow(2,-24)-Math.pow(2,-77):0,l=b?0:f-1,d=b?1:-1,h=_<0||_===0&&1/_<0?1:0;for(_=Math.abs(_),isNaN(_)||_===1/0?(u=isNaN(_)?1:0,c=n):(c=Math.floor(Math.log(_)/Math.LN2),_*(i=Math.pow(2,-c))<1&&(c--,i*=2),(_+=c+t>=1?r/i:r*Math.pow(2,1-t))*i>=2&&(c++,i/=2),c+t>=n?(u=0,c=n):c+t>=1?(u=(_*i-1)*Math.pow(2,g),c+=t):(u=_*Math.pow(2,t-1)*Math.pow(2,g),c=0));g>=8;o[e+l]=255&u,l+=d,u/=256,g-=8);for(c=c<0;o[e+l]=255&c,l+=d,c/=256,a-=8);o[e+l-d]|=128*h}},function(O,D,o){"use strict";O.exports=e,O.exports.default=e;var _=1e20;function e(f,c,u,i,a,n){this.fontSize=f||24,this.buffer=c===void 0?3:c,this.cutoff=i||.25,this.fontFamily=a||"sans-serif",this.fontWeight=n||"normal",this.radius=u||8;var t=this.size=this.fontSize+2*this.buffer;this.canvas=document.createElement("canvas"),this.canvas.width=this.canvas.height=t,this.ctx=this.canvas.getContext("2d"),this.ctx.font=this.fontWeight+" "+this.fontSize+"px "+this.fontFamily,this.ctx.textBaseline="middle",this.ctx.fillStyle="black",this.gridOuter=new Float64Array(t*t),this.gridInner=new Float64Array(t*t),this.f=new Float64Array(t),this.d=new Float64Array(t),this.z=new Float64Array(t+1),this.v=new Int16Array(t),this.middle=Math.round(t/2*(navigator.userAgent.indexOf("Gecko/")>=0?1.2:1))}function b(f,c,u,i,a,n,t){for(var r=0;rthis.height)return e.warnOnce("LineAtlas out of space"),null;for(var r=0,l=0;l",id:String(h),error:y?String(y):null,data:g(s,p)},p)};if(d.type==="")r=this.callbacks[d.id],delete this.callbacks[d.id],r&&d.error?r(new Error(d.error)):r&&r(null,f(d.data));else if(d.id!==void 0&&this.parent[d.type])this.parent[d.type](d.sourceMapId,f(d.data),m);else if(d.id!==void 0&&this.parent.getWorkerSource){var S=d.type.split(".");this.parent.getWorkerSource(d.sourceMapId,S[0])[S[1]](f(d.data),m)}else this.parent[d.type](f(d.data))}}},{key:"remove",value:function(){this.target.removeEventListener("message",this.receive,!1)}}])&&_(i.prototype,a),n&&_(i,n),u}();O.exports=c},function(O,D,o){function _(d){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(h){return typeof h}:function(h){return h&&typeof Symbol=="function"&&h.constructor===Symbol&&h!==Symbol.prototype?"symbol":typeof h})(d)}function e(d,h){for(var m=0;m0&&(x[new n(y.overscaledZ,A,s.z,w,s.y-1).key]={backfilled:!1},x[new n(y.overscaledZ,y.wrap,s.z,s.x,s.y-1).key]={backfilled:!1},x[new n(y.overscaledZ,v,s.z,k,s.y-1).key]={backfilled:!1}),s.y+1this.width||a<0||u>this.height)return!n&&[];var t=[];if(c<=0&&u<=0&&this.width<=i&&this.height<=a)t=Array.prototype.slice.call(this.boxKeys).concat(this.circleKeys);else{var r={hitTest:n,seenUids:{box:{},circle:{}}};this._forEachCell(c,u,i,a,this._queryCell,t,r)}return n?t.length>0:t}},{key:"_queryCircle",value:function(c,u,i,a){var n=c-i,t=c+i,r=u-i,l=u+i;if(t<0||n>this.width||l<0||r>this.height)return!a&&[];var d=[],h={hitTest:a,circle:{x:c,y:u,radius:i},seenUids:{box:{},circle:{}}};return this._forEachCell(n,r,t,l,this._queryCellCircle,d,h),a?d.length>0:d}},{key:"query",value:function(c,u,i,a){return this._query(c,u,i,a,!1)}},{key:"hitTest",value:function(c,u,i,a){return this._query(c,u,i,a,!0)}},{key:"hitTestCircle",value:function(c,u,i){return this._queryCircle(c,u,i,!0)}},{key:"_queryCell",value:function(c,u,i,a,n,t,r){var l=r.seenUids,d=this.boxCells[n];if(d!==null){var h=this.bboxes,m=!0,S=!1,y=void 0;try{for(var s,p=d[Symbol.iterator]();!(m=(s=p.next()).done);m=!0){var w=s.value;if(!l.box[w]){l.box[w]=!0;var A=4*w;if(c<=h[A+2]&&u<=h[A+3]&&i>=h[A+0]&&a>=h[A+1]){if(r.hitTest)return t.push(!0),!0;t.push(this.boxKeys[w])}}}}catch(F){S=!0,y=F}finally{try{m||p.return==null||p.return()}finally{if(S)throw y}}}var k=this.circleCells[n];if(k!==null){var v=this.circles,x=!0,T=!1,E=void 0;try{for(var C,z=k[Symbol.iterator]();!(x=(C=z.next()).done);x=!0){var P=C.value;if(!l.circle[P]){l.circle[P]=!0;var B=3*P;if(this._circleAndRectCollide(v[B],v[B+1],v[B+2],c,u,i,a)){if(r.hitTest)return t.push(!0),!0;t.push(this.circleKeys[P])}}}}catch(F){T=!0,E=F}finally{try{x||z.return==null||z.return()}finally{if(T)throw E}}}}},{key:"_queryCellCircle",value:function(c,u,i,a,n,t,r){var l=r.circle,d=r.seenUids,h=this.boxCells[n];if(h!==null){var m=this.bboxes,S=!0,y=!1,s=void 0;try{for(var p,w=h[Symbol.iterator]();!(S=(p=w.next()).done);S=!0){var A=p.value;if(!d.box[A]){d.box[A]=!0;var k=4*A;if(this._circleAndRectCollide(l.x,l.y,l.radius,m[k+0],m[k+1],m[k+2],m[k+3]))return t.push(!0),!0}}}catch(Z){y=!0,s=Z}finally{try{S||w.return==null||w.return()}finally{if(y)throw s}}}var v=this.circleCells[n];if(v!==null){var x=this.circles,T=!0,E=!1,C=void 0;try{for(var z,P=v[Symbol.iterator]();!(T=(z=P.next()).done);T=!0){var B=z.value;if(!d.circle[B]){d.circle[B]=!0;var F=3*B;if(this._circlesCollide(x[F],x[F+1],x[F+2],l.x,l.y,l.radius))return t.push(!0),!0}}}catch(Z){E=!0,C=Z}finally{try{T||P.return==null||P.return()}finally{if(E)throw C}}}}},{key:"_forEachCell",value:function(c,u,i,a,n,t,r){for(var l=this._convertToXCellCoord(c),d=this._convertToYCellCoord(u),h=this._convertToXCellCoord(i),m=this._convertToYCellCoord(a),S=l;S<=h;S++)for(var y=d;y<=m;y++){var s=this.xCellCount*y+S;if(n.call(this,c,u,i,a,s,t,r))return}}},{key:"_convertToXCellCoord",value:function(c){return Math.max(0,Math.min(this.xCellCount-1,Math.floor(c*this.xScale)))}},{key:"_convertToYCellCoord",value:function(c){return Math.max(0,Math.min(this.yCellCount-1,Math.floor(c*this.yScale)))}},{key:"_circlesCollide",value:function(c,u,i,a,n,t){var r=a-c,l=n-u,d=i+t;return d*d>r*r+l*l}},{key:"_circleAndRectCollide",value:function(c,u,i,a,n,t,r){var l=(t-a)/2,d=Math.abs(c-(a+l));if(d>l+i)return!1;var h=(r-n)/2,m=Math.abs(u-(n+h));if(m>h+i)return!1;if(d<=l||m<=h)return!0;var S=d-l,y=m-h;return S*S+y*y<=i*i}}])&&o(b.prototype,g),f&&o(b,f),e}();O.exports=_},function(O,D,o){var _,e;function b(m,S,y){return S in m?Object.defineProperty(m,S,{value:y,enumerable:!0,configurable:!0,writable:!0}):m[S]=y,m}var g=o(63),f=o(110),c=o(49),u={horizontal:1,vertical:2,horizontalOnly:3};O.exports={shapeText:function(m,S,y,s,p,w,A,k,v,x){var T=m.trim();x===u.vertical&&(T=f(T));var E,C=[],z={positionedGlyphs:C,text:T,top:k[1],bottom:k[1],left:k[0],right:k[0],writingMode:x},P=c.processBidirectionalText;return E=P?P(T,l(T,A,y,S)):function(B,F){var Z=[],W=0,J=!0,X=!1,R=void 0;try{for(var U,K=F[Symbol.iterator]();!(J=(U=K.next()).done);J=!0){var q=U.value;Z.push(B.substring(W,q)),W=q}}catch(L){X=!0,R=L}finally{try{J||K.return==null||K.return()}finally{if(X)throw R}}return W \n * @license MIT\n */function i(t,e){if(t===e)return 0;for(var n=t.length,r=e.length,i=0,o=Math.min(n,r);i=0;l--)if(c[l]!==f[l])return!1;for(l=c.length-1;l>=0;l--)if(s=c[l],!b(t[s],e[s],n,r))return!1;return!0}(t,e,n,r))}return n?t===e:t==e}function x(t){return"[object Arguments]"==Object.prototype.toString.call(t)}function w(t,e){if(!t||!e)return!1;if("[object RegExp]"==Object.prototype.toString.call(e))return e.test(t);try{if(t instanceof e)return!0}catch(t){}return!Error.isPrototypeOf(e)&&!0===e.call({},t)}function k(t,e,n,r){var i;if("function"!=typeof e)throw new TypeError(\'"block" argument must be a function\');"string"==typeof n&&(r=n,n=null),i=function(t){var e;try{t()}catch(t){e=t}return e}(e),r=(n&&n.name?" ("+n.name+").":".")+(r?" "+r:"."),t&&!i&&m(i,n,"Missing expected exception"+r);var o="string"==typeof r,s=!t&&i&&!n;if((!t&&a.isError(i)&&o&&w(i,n)||s)&&m(i,n,"Got unwanted exception"+r),t&&i&&n&&!w(i,n)||!t&&i)throw i}h.AssertionError=function(t){this.name="AssertionError",this.actual=t.actual,this.expected=t.expected,this.operator=t.operator,t.message?(this.message=t.message,this.generatedMessage=!1):(this.message=function(t){return d(v(t.actual),128)+" "+t.operator+" "+d(v(t.expected),128)}(this),this.generatedMessage=!0);var e=t.stackStartFunction||m;if(Error.captureStackTrace)Error.captureStackTrace(this,e);else{var n=new Error;if(n.stack){var r=n.stack,i=y(e),o=r.indexOf("\\n"+i);if(o>=0){var a=r.indexOf("\\n",o+1);r=r.substring(a+1)}this.stack=r}}},a.inherits(h.AssertionError,Error),h.fail=m,h.ok=g,h.equal=function(t,e,n){t!=e&&m(t,e,n,"==",h.equal)},h.notEqual=function(t,e,n){t==e&&m(t,e,n,"!=",h.notEqual)},h.deepEqual=function(t,e,n){b(t,e,!1)||m(t,e,n,"deepEqual",h.deepEqual)},h.deepStrictEqual=function(t,e,n){b(t,e,!0)||m(t,e,n,"deepStrictEqual",h.deepStrictEqual)},h.notDeepEqual=function(t,e,n){b(t,e,!1)&&m(t,e,n,"notDeepEqual",h.notDeepEqual)},h.notDeepStrictEqual=function t(e,n,r){b(e,n,!0)&&m(e,n,r,"notDeepStrictEqual",t)},h.strictEqual=function(t,e,n){t!==e&&m(t,e,n,"===",h.strictEqual)},h.notStrictEqual=function(t,e,n){t===e&&m(t,e,n,"!==",h.notStrictEqual)},h.throws=function(t,e,n){k(!0,t,e,n)},h.doesNotThrow=function(t,e,n){k(!1,t,e,n)},h.ifError=function(t){if(t)throw t},h.strict=r(function t(e,n){e||m(e,!0,n,"==",t)},h,{equal:h.strictEqual,deepEqual:h.deepStrictEqual,notEqual:h.notStrictEqual,notDeepEqual:h.notDeepStrictEqual}),h.strict.strict=h.strict;var _=Object.keys||function(t){var e=[];for(var n in t)s.call(t,n)&&e.push(n);return e}}).call(this,n(89))},function(t,e,n){function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){for(var n=0;nthis.end)return this.prior=null,n;if(this.value.isDataDriven())return this.prior=null,n;if(er.zoomHistory.lastIntegerZoom?{from:t,to:e,fromScale:2,toScale:1,t:o+(1-o)*a}:{from:n,to:e,fromScale:.5,toScale:1,t:1-(1-a)*o}}},{key:"interpolate",value:function(t){return t}}]),t}(),A=function(){function t(e){r(this,t),this.specification=e}return o(t,[{key:"possiblyEvaluate",value:function(){}},{key:"interpolate",value:function(){}}]),t}();p("DataDrivenProperty",_),p("DataConstantProperty",k),p("CrossFadedProperty",S),p("HeatmapColorProperty",A),t.exports={PropertyValue:y,Transitionable:v,Transitioning:g,Layout:b,PossiblyEvaluatedPropertyValue:x,PossiblyEvaluated:w,DataConstantProperty:k,DataDrivenProperty:_,CrossFadedProperty:S,HeatmapColorProperty:A,Properties:function t(e){for(var n in r(this,t),this.properties=e,this.defaultPropertyValues={},this.defaultTransitionablePropertyValues={},this.defaultTransitioningPropertyValues={},this.defaultPossiblyEvaluatedValues={},e){var i=e[n],o=this.defaultPropertyValues[n]=new y(i,void 0),a=this.defaultTransitionablePropertyValues[n]=new d(i);this.defaultTransitioningPropertyValues[n]=a.untransitioned(),this.defaultPossiblyEvaluatedValues[n]=o.possiblyEvaluate({})}}}},function(t,e,n){function r(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(t){i=!0,o=t}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var o=n(46),a=n(47);n(6);e.easeCubicInOut=function(t){if(t<=0)return 0;if(t>=1)return 1;var e=t*t,n=e*t;return 4*(t<.5?n:3*(t-e)+n-.75)},e.bezier=function(t,e,n,r){var i=new o(t,e,n,r);return function(t){return i.solve(t)}},e.ease=e.bezier(.25,.1,.25,1),e.clamp=function(t,e,n){return Math.min(n,Math.max(e,t))},e.wrap=function(t,e,n){var r=n-e,i=((t-e)%r+r)%r+e;return i===e?n:i},e.asyncAll=function(t,e,n){if(!t.length)return n(null,[]);var r=t.length,i=new Array(t.length),o=null;t.forEach(function(t,a){e(t,function(t,e){t&&(o=t),i[a]=e,0==--r&&n(o,i)})})},e.values=function(t){var e=[];for(var n in t)e.push(t[n]);return e},e.keysDifference=function(t,e){var n=[];for(var r in t)r in e||n.push(r);return n},e.extend=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r=0)return!0;return!1};var u={};e.warnOnce=function(t){u[t]||("undefined"!=typeof console&&console.warn(t),u[t]=!0)},e.isCounterClockwise=function(t,e,n){return(n.y-t.y)*(e.x-t.x)>(e.y-t.y)*(n.x-t.x)},e.calculateSignedArea=function(t){for(var e,n,r=0,i=0,o=t.length,a=o-1;i0||Math.abs(n.y-r.y)>0)&&Math.abs(e.calculateSignedArea(t))>.01},e.sphericalToCartesian=function(t){var e=r(t,3),n=e[0],i=e[1],o=e[2];return i+=90,i*=Math.PI/180,o*=Math.PI/180,{x:n*Math.cos(i)*Math.sin(o),y:n*Math.sin(i)*Math.sin(o),z:n*Math.cos(o)}},e.parseCacheControl=function(t){var e={};if(t.replace(/(?:^|(?:\\s*\\,\\s*))([^\\x00-\\x20\\(\\)<>@\\,;\\:\\\\"\\/\\[\\]\\?\\=\\{\\}\\x7F]+)(?:\\=(?:([^\\x00-\\x20\\(\\)<>@\\,;\\:\\\\"\\/\\[\\]\\?\\=\\{\\}\\x7F]+)|(?:\\"((?:[^"\\\\]|\\\\.)*)\\")))?/g,function(t,n,r,i){var o=r||i;return e[n]=!o||o.toLowerCase(),""}),e["max-age"]){var n=parseInt(e["max-age"],10);isNaN(n)?delete e["max-age"]:e["max-age"]=n}return e}},function(t,e,n){function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var i=n(0),o=n(48),a=n(13),s=n(14),u=s.StylePropertyFunction,l=s.StyleExpression,c=s.StyleExpressionWithErrorHandling,f=s.ZoomDependentExpression,h=s.ZoomConstantExpression,p=n(23).CompoundExpression,y=n(63),d=n(36).ImageData,v={};function m(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};i(!v[t],"".concat(t," is already registered.")),Object.defineProperty(e,"_classRegistryKey",{value:t,writeable:!1}),v[t]={klass:e,omit:n.omit||[],shallow:n.shallow||[]}}for(var g in m("Object",Object),o.serialize=function(t,e){var n=t.toArrayBuffer();return e&&e.push(n),n},o.deserialize=function(t){return new o(t)},m("Grid",o),m("Color",a),m("StylePropertyFunction",u),m("StyleExpression",l,{omit:["_evaluator"]}),m("StyleExpressionWithErrorHandling",c,{omit:["_evaluator"]}),m("ZoomDependentExpression",f),m("ZoomConstantExpression",h),m("CompoundExpression",p,{omit:["_evaluate"]}),y)y[g]._classRegistryKey||m("Expression_".concat(g),y[g]);t.exports={register:m,serialize:function t(e,n){if(null==e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||e instanceof Boolean||e instanceof Number||e instanceof String||e instanceof Date||e instanceof RegExp)return e;if(e instanceof ArrayBuffer)return n&&n.push(e),e;if(ArrayBuffer.isView(e)){var o=e;return n&&n.push(o.buffer),o}if(e instanceof d)return n&&n.push(e.data.buffer),e;if(Array.isArray(e)){var a=[],s=!0,u=!1,l=void 0;try{for(var c,f=e[Symbol.iterator]();!(s=(c=f.next()).done);s=!0){var h=c.value;a.push(t(h,n))}}catch(t){u=!0,l=t}finally{try{s||null==f.return||f.return()}finally{if(u)throw l}}return a}if("object"===r(e)){var p=e.constructor,y=p._classRegistryKey;if(!y)throw new Error("can\'t serialize object of unregistered class");i(v[y]);var m={};if(p.serialize)m._serialized=p.serialize(e,n);else for(var g in e)if(e.hasOwnProperty(g)&&!(v[y].omit.indexOf(g)>=0)){var b=e[g];m[g]=v[y].shallow.indexOf(g)>=0?b:t(b,n)}return{name:y,properties:m}}throw new Error("can\'t serialize object of type ".concat(r(e)))},deserialize:function t(e){if(null==e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||e instanceof Boolean||e instanceof Number||e instanceof String||e instanceof Date||e instanceof RegExp||e instanceof ArrayBuffer||ArrayBuffer.isView(e)||e instanceof d)return e;if(Array.isArray(e))return e.map(function(e){return t(e)});if("object"===r(e)){var n=e,i=n.name,o=n.properties;if(!i)throw new Error("can\'t deserialize object of anonymous class");var a=v[i].klass;if(!a)throw new Error("can\'t deserialize unregistered class ".concat(i));if(a.deserialize)return a.deserialize(o._serialized);for(var s=Object.create(a.prototype),u=0,l=Object.keys(o);u=0?o[c]:t(o[c])}return s}throw new Error("can\'t deserialize object of type ".concat(r(e)))}}},function(t,e){var n={kind:"null"},r={kind:"number"},i={kind:"string"},o={kind:"boolean"},a={kind:"color"},s={kind:"object"},u={kind:"value"};function l(t,e){return{kind:"array",itemType:t,N:e}}function c(t){if("array"===t.kind){var e=c(t.itemType);return"number"==typeof t.N?"array<".concat(e,", ").concat(t.N,">"):"value"===t.itemType.kind?"array":"array<".concat(e,">")}return t.kind}var f=[n,r,i,o,a,s,l(u)];t.exports={NullType:n,NumberType:r,StringType:i,BooleanType:o,ColorType:a,ObjectType:s,ValueType:u,array:l,ErrorType:{kind:"error"},toString:c,checkSubtype:function t(e,n){if("error"===n.kind)return null;if("array"===e.kind){if("array"===n.kind&&!t(e.itemType,n.itemType)&&("number"!=typeof e.N||e.N===n.N))return null}else{if(e.kind===n.kind)return null;if("value"===e.kind)for(var r=0,i=f;r=this.maxzoom)||"none"===this.visibility)}},{key:"updateTransitions",value:function(t){this._transitioningPaint=this._transitionablePaint.transitioned(t,this._transitioningPaint)}},{key:"hasTransition",value:function(){return this._transitioningPaint.hasTransition()}},{key:"recalculate",value:function(t){this._unevaluatedLayout&&(this.layout=this._unevaluatedLayout.possiblyEvaluate(t)),this.paint=this._transitioningPaint.possiblyEvaluate(t)}},{key:"serialize",value:function(){var t={id:this.id,type:this.type,source:this.source,"source-layer":this.sourceLayer,metadata:this.metadata,minzoom:this.minzoom,maxzoom:this.maxzoom,filter:this.filter,layout:this._unevaluatedLayout&&this._unevaluatedLayout.serialize(),paint:this._transitionablePaint&&this._transitionablePaint.serialize()};return"none"===this.visibility&&(t.layout=t.layout||{},t.layout.visibility="none"),u.filterObject(t,function(t,e){return!(void 0===t||"layout"===e&&!Object.keys(t).length||"paint"===e&&!Object.keys(t).length)})}},{key:"_validate",value:function(t,e,n,r,i){return(!i||!1!==i.validate)&&c.emitErrors(this,t.call(c,{key:e,layerType:this.type,objectKey:n,value:r,styleSpec:l,style:{glyphs:!0,sprite:!0}}))}},{key:"hasOffscreenPass",value:function(){return!1}},{key:"resize",value:function(){}}])&&i(n.prototype,r),h&&i(n,h),e}());t.exports=d;var v={circle:n(108),heatmap:n(112),hillshade:n(115),fill:n(117),"fill-extrusion":n(122),line:n(126),symbol:n(132),background:n(140),raster:n(142)};d.create=function(t){return new v[t.type](t)}},function(t,e,n){function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){for(var n=0;n=0&&t<=255&&"number"==typeof e&&e>=0&&e<=255&&"number"==typeof n&&n>=0&&n<=255?void 0===r||"number"==typeof r&&r>=0&&r<=1?null:"Invalid rgba value [".concat([t,e,n,r].join(", "),"]: \'a\' must be between 0 and 1."):"Invalid rgba value [".concat(("number"==typeof r?[t,e,n,r]:[t,e,n]).join(", "),"]: \'r\', \'g\', and \'b\' must be between 0 and 255.")},isValue:function t(e){if(null===e)return!0;if("string"==typeof e)return!0;if("boolean"==typeof e)return!0;if("number"==typeof e)return!0;if(e instanceof o)return!0;if(Array.isArray(e)){var n=!0,i=!1,a=void 0;try{for(var s,u=e[Symbol.iterator]();!(n=(s=u.next()).done);n=!0)if(!t(s.value))return!1}catch(t){i=!0,a=t}finally{try{n||null==u.return||u.return()}finally{if(i)throw a}}return!0}if("object"===r(e)){for(var l in e)if(!t(e[l]))return!1;return!0}return!1},typeOf:function t(e){if(null===e)return s;if("string"==typeof e)return l;if("boolean"==typeof e)return c;if("number"==typeof e)return u;if(e instanceof o)return f;if(Array.isArray(e)){var n,a=e.length,d=!0,v=!1,m=void 0;try{for(var g,b=e[Symbol.iterator]();!(d=(g=b.next()).done);d=!0){var x=t(g.value);if(n){if(n===x)continue;n=p;break}n=x}}catch(t){v=!0,m=t}finally{try{d||null==b.return||b.return()}finally{if(v)throw m}}return y(n||p,a)}return i("object"===r(e)),h}}},function(t,e){function n(t){return t instanceof Number||t instanceof String||t instanceof Boolean?t.valueOf():t}t.exports=n,t.exports.deep=function t(e){return Array.isArray(e)?e.map(t):n(e)}},function(t,e,n){function r(t,e){for(var n=0;n3&&void 0!==arguments[3]?arguments[3]:1;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.r=e,this.g=n,this.b=r,this.a=i}var e,n,o;return e=t,o=[{key:"parse",value:function(e){if(e){if(e instanceof t)return e;if("string"==typeof e){var n=i(e);if(n)return new t(n[0]/255*n[3],n[1]/255*n[3],n[2]/255*n[3],n[3])}}}}],(n=[{key:"toString",value:function(){var t=this,e=[this.r,this.g,this.b].map(function(e){return Math.round(255*e/t.a)});return"rgba(".concat(e.concat(this.a).join(","),")")}}])&&r(e.prototype,n),o&&r(e,o),t}();o.black=new o(0,0,0,1),o.white=new o(1,1,1,1),o.transparent=new o(0,0,0,0),t.exports=o},function(t,e,n){function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(t,e){return!e||"object"!==r(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn\'t been initialised - super() hasn\'t been called");return t}(t):e}function o(t){return(o=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function a(t,e){return(a=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function s(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function u(t,e){for(var n=0;n0&&"string"==typeof t[0]&&t[0]in x}function z(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=new p(x,[],function(t){var e={color:R,string:D,number:q,enum:D,boolean:N};if("array"===t.type)return J(e[t.value]||U,t.length);return e[t.type]||null}(e)),i=r.parse(t);return i?!1===n.handleErrors?S(new T(i)):S(new j(i,e)):(c(r.errors.length>0),A(r.errors))}var P=function(){function t(e,n){s(this,t),this.kind=e,this._styleExpression=n}return l(t,[{key:"evaluate",value:function(t,e){return this._styleExpression.evaluate(t,e)}}]),t}(),E=function(){function t(e,n,r){s(this,t),this.kind=e,this.zoomStops=r.labels,this._styleExpression=n,r instanceof m&&(this._interpolationType=r.interpolation)}return l(t,[{key:"evaluate",value:function(t,e){return this._styleExpression.evaluate(t,e)}},{key:"interpolationFactor",value:function(t,e,n){return this._interpolationType?m.interpolationFactor(this._interpolationType,t,e,n):0}}]),t}();function C(t,e){if("error"===(t=z(t,e,arguments.length>2&&void 0!==arguments[2]?arguments[2]:{})).result)return t;var n=t.value.expression,r=w.isFeatureConstant(n);if(!r&&!e["property-function"])return A([new h("","property expressions not supported")]);var i=w.isGlobalPropertyConstant(n,["zoom"]);if(!i&&!1===e["zoom-function"])return A([new h("","zoom expressions not supported")]);var o=function t(e){var n=null;if(e instanceof b)n=t(e.result);else if(e instanceof g){var r=!0,i=!1,o=void 0;try{for(var a,s=e.args[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){var u=a.value;if(n=t(u))break}}catch(t){i=!0,o=t}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}}else(e instanceof v||e instanceof m)&&e.input instanceof d&&"zoom"===e.input.name&&(n=e);if(n instanceof h)return n;e.eachChild(function(e){var r=t(e);r instanceof h?n=r:!n&&r?n=new h("",\'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.\'):n&&r&&n!==r&&(n=new h("",\'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.\'))});return n}(n);return o||i?o instanceof h?A([o]):o instanceof m&&"piecewise-constant"===e.function?A([new h("",\'"interpolate" expressions cannot be used with this property\')]):S(o?new E(r?"camera":"composite",t.value,o):new P(r?"constant":"source",t.value)):A([new h("",\'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.\')])}var M=n(35),I=M.isFunction,B=M.createFunction,V=n(11).Color,L=function(){function t(e,n){s(this,t),this._parameters=e,this._specification=n,f(this,B(this._parameters,this._specification))}return l(t,null,[{key:"deserialize",value:function(e){return new t(e._parameters,e._specification)}},{key:"serialize",value:function(t){return{_parameters:t._parameters,_specification:t._specification}}}]),t}();t.exports={StyleExpression:T,StyleExpressionWithErrorHandling:j,isExpression:O,createExpression:z,createPropertyExpression:C,normalizePropertyExpression:function(t,e){if(I(t))return new L(t,e);if(O(t)){var n=C(t,e);if("error"===n.result)throw new Error(n.value.map(function(t){return"".concat(t.key,": ").concat(t.message)}).join(", "));return n.value}var r=t;return"string"==typeof t&&"color"===e.type&&(r=V.parse(t)),{kind:"constant",evaluate:function(){return r}}},ZoomConstantExpression:P,ZoomDependentExpression:E,StylePropertyFunction:L};var F=n(4),R=F.ColorType,D=F.StringType,q=F.NumberType,N=F.BooleanType,U=F.ValueType,J=F.array},function(t,e){function n(t,e){for(var n=0;nthis.capacity){this.capacity=Math.max(t,Math.floor(5*this.capacity),128),this.arrayBuffer=new ArrayBuffer(this.capacity*this.bytesPerElement);var e=this.uint8;this._refreshViews(),e&&this.uint8.set(e)}}},{key:"_refreshViews",value:function(){throw new Error("_refreshViews() must be implemented by each concrete StructArray layout")}}])&&r(e.prototype,n),a&&r(e,a),t}();function u(t,e){return Math.ceil(t/e)*e}t.exports.StructArray=s,t.exports.Struct=function t(e,n){i(this,t),this._structArray=e,this._pos1=n*this.size,this._pos2=this._pos1/2,this._pos4=this._pos1/4,this._pos8=this._pos1/8},t.exports.viewTypes=a,t.exports.createLayout=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=0,r=0;return{members:t.map(function(t){o(t.name.length);var i,s=(i=t.type,a[i].BYTES_PER_ELEMENT),l=n=u(n,Math.max(e,s)),c=t.components||1;return r=Math.max(r,s),n+=s*c,{name:t.name,type:t.type,components:c,offset:l}}),size:u(n,Math.max(r,e)),alignment:e}}},function(t,e){t.exports=8192},function(t,e,n){var r=n(13);function i(t,e,n){return t*(1-n)+e*n}t.exports={number:i,color:function(t,e,n){return new r(i(t.r,e.r,n),i(t.g,e.g,n),i(t.b,e.b,n),i(t.a,e.a,n))},array:function(t,e,n){return t.map(function(t,r){return i(t,e[r],n)})}}},function(t,e,n){var r=n(2),i=n(18);var o,a=(o=16,{min:-1*Math.pow(2,o-1),max:Math.pow(2,o-1)-1});t.exports=function(t){for(var e=i/t.extent,n=t.loadGeometry(),o=0;oa.max||l.ya.max)&&r.warnOnce("Geometry exceeds allowed extent, reduce your vector tile buffer size")}return n}},function(t,e,n){t.exports.VectorTile=n(129),t.exports.VectorTileFeature=n(80),t.exports.VectorTileLayer=n(79)},function(t,e){t.exports=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r0),1===f.length)n.errors.push.apply(n.errors,g.errors);else{var P=(f.length?f:c).map(function(t){var e,n=r(t,1)[0];return e=n,Array.isArray(e)?"(".concat(e.map(o).join(", "),")"):"(".concat(o(e.type),"...)")}).join(" | "),E=h.map(function(t){return o(t.type)}).join(", ");n.error("Expected arguments of type ".concat(P,", but found (").concat(E,") instead."))}return null}},{key:"register",value:function(e,n){for(var r in s(!t.definitions),t.definitions=n,n)e[r]=t}}],(n=[{key:"evaluate",value:function(t){return this._evaluate(t,this.args)}},{key:"eachChild",value:function(t){this.args.forEach(t)}},{key:"possibleOutputs",value:function(){return[void 0]}}])&&i(e.prototype,n),u&&i(e,u),t}();t.exports={CompoundExpression:u,varargs:function(t){return{type:t}}}},function(t,e,n){var r=n(5),i=n(7),o=n(16);t.exports=function(t){var e=t.key,n=t.value,a=t.valueSpec||{},s=t.objectElementValidators||{},u=t.style,l=t.styleSpec,c=[],f=i(n);if("object"!==f)return[new r(e,n,"object expected, ".concat(f," found"))];for(var h in n){var p=h.split(".")[0],y=a[p]||a["*"],d=void 0;if(s[p])d=s[p];else if(a[p])d=o;else if(s["*"])d=s["*"];else{if(!a["*"]){c.push(new r(e,n[h],\'unknown property "\'.concat(h,\'"\')));continue}d=o}c=c.concat(d({key:(e?"".concat(e,"."):e)+h,value:n[h],valueSpec:y,style:u,styleSpec:l,object:n,objectKey:h},n))}for(var v in a)s[v]||a[v].required&&void 0===a[v].default&&void 0===n[v]&&c.push(new r(e,n,\'missing required property "\'.concat(v,\'"\')));return c}},function(t,e,n){function r(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:[];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),this.segments=t}var n,o,s;return n=e,(o=[{key:"prepareSegment",value:function(e,n,r){var o=this.segments[this.segments.length-1];return e>a&&i("Max vertices per segment is ".concat(a,": bucket requested ").concat(e)),(!o||o.vertexLength+e>t.exports.MAX_VERTEX_ARRAY_LENGTH)&&(o={vertexOffset:n.length,primitiveOffset:r.length,vertexLength:0,primitiveLength:0},this.segments.push(o)),o}},{key:"get",value:function(){return this.segments}},{key:"destroy",value:function(){var t=!0,e=!1,n=void 0;try{for(var r,i=this.segments[Symbol.iterator]();!(t=(r=i.next()).done);t=!0){var o=r.value;for(var a in o.vaos)o.vaos[a].destroy()}}catch(t){e=!0,n=t}finally{try{t||null==i.return||i.return()}finally{if(e)throw n}}}}])&&r(n.prototype,o),s&&r(n,s),e}();o("SegmentVector",s),t.exports={SegmentVector:s,MAX_VERTEX_ARRAY_LENGTH:a}},function(t,e,n){function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){for(var n=0;n3&&void 0!==arguments[3]?arguments[3]:function(){return!0};r(this,t),this.programConfigurations={};var a=!0,s=!1,u=void 0;try{for(var l,c=n[Symbol.iterator]();!(a=(l=c.next()).done);a=!0){var f=l.value;this.programConfigurations[f.id]=m.createDynamic(f,i,o),this.programConfigurations[f.id].layoutAttributes=e}}catch(t){s=!0,u=t}finally{try{a||null==c.return||c.return()}finally{if(s)throw u}}}return o(t,[{key:"populatePaintArrays",value:function(t,e){for(var n in this.programConfigurations)this.programConfigurations[n].populatePaintArrays(t,e)}},{key:"get",value:function(t){return this.programConfigurations[t]}},{key:"upload",value:function(t){for(var e in this.programConfigurations)this.programConfigurations[e].upload(t)}},{key:"destroy",value:function(){for(var t in this.programConfigurations)this.programConfigurations[t].destroy()}}]),t}();function b(t,e){return{"text-opacity":"opacity","icon-opacity":"opacity","text-color":"fill_color","icon-color":"fill_color","text-halo-color":"halo_color","icon-halo-color":"halo_color","text-halo-blur":"halo_blur","icon-halo-blur":"halo_blur","text-halo-width":"halo_width","icon-halo-width":"halo_width","line-gap-width":"gapwidth"}[t]||t.replace("".concat(e,"-"),"").replace(/-/g,"_")}s("ConstantBinder",y),s("SourceExpressionBinder",d),s("CompositeExpressionBinder",v),s("ProgramConfiguration",m,{omit:["_buffers"]}),s("ProgramConfigurationSet",g),t.exports={ProgramConfiguration:m,ProgramConfigurationSet:g}},function(t,e,n){t.exports={LineIndexArray:n(10).LineIndexArray,TriangleIndexArray:n(10).TriangleIndexArray}},function(t,e,n){var r=n(2).isCounterClockwise;function i(t,e,n){if(t.length>1){if(o(t,e))return!0;for(var r=0;r1?t.distSqr(n):t.distSqr(n.sub(e)._mult(i)._add(e))}function l(t,e){for(var n,r,i,o=!1,a=0;ae.y!=i.y>e.y&&e.x<(i.x-r.x)*(e.y-r.y)/(i.y-r.y)+r.x&&(o=!o);return o}function c(t,e){for(var n=!1,r=0,i=t.length-1;re.y!=a.y>e.y&&e.x<(a.x-o.x)*(e.y-o.y)/(a.y-o.y)+o.x&&(n=!n)}return n}t.exports={multiPolygonIntersectsBufferedMultiPoint:function(t,e,n){for(var r=0;r=3)for(var u=0;ut.width||i.height>t.height||n.x>t.width-i.width||n.y>t.height-i.height)throw new RangeError("out of range source coordinates for image copy");if(i.width>e.width||i.height>e.height||r.x>e.width-i.width||r.y>e.height-i.height)throw new RangeError("out of range destination coordinates for image copy");var s=t.data,u=e.data;a(s!==u);for(var l=0;l=65097&&t<=65103)||(!!r["CJK Compatibility Ideographs"](t)||(!!r["CJK Compatibility"](t)||(!!r["CJK Radicals Supplement"](t)||(!!r["CJK Strokes"](t)||(!(!r["CJK Symbols and Punctuation"](t)||t>=12296&&t<=12305||t>=12308&&t<=12319||12336===t)||(!!r["CJK Unified Ideographs Extension A"](t)||(!!r["CJK Unified Ideographs"](t)||(!!r["Enclosed CJK Letters and Months"](t)||(!!r["Hangul Compatibility Jamo"](t)||(!!r["Hangul Jamo Extended-A"](t)||(!!r["Hangul Jamo Extended-B"](t)||(!!r["Hangul Jamo"](t)||(!!r["Hangul Syllables"](t)||(!!r.Hiragana(t)||(!!r["Ideographic Description Characters"](t)||(!!r.Kanbun(t)||(!!r["Kangxi Radicals"](t)||(!!r["Katakana Phonetic Extensions"](t)||(!(!r.Katakana(t)||12540===t)||(!(!r["Halfwidth and Fullwidth Forms"](t)||65288===t||65289===t||65293===t||t>=65306&&t<=65310||65339===t||65341===t||65343===t||t>=65371&&t<=65503||65507===t||t>=65512&&t<=65519)||(!(!r["Small Form Variants"](t)||t>=65112&&t<=65118||t>=65123&&t<=65126)||(!!r["Unified Canadian Aboriginal Syllabics"](t)||(!!r["Unified Canadian Aboriginal Syllabics Extended"](t)||(!!r["Vertical Forms"](t)||(!!r["Yijing Hexagram Symbols"](t)||(!!r["Yi Syllables"](t)||!!r["Yi Radicals"](t))))))))))))))))))))))))))))))},e.charHasNeutralVerticalOrientation=function(t){return!(!r["Latin-1 Supplement"](t)||167!==t&&169!==t&&174!==t&&177!==t&&188!==t&&189!==t&&190!==t&&215!==t&&247!==t)||(!(!r["General Punctuation"](t)||8214!==t&&8224!==t&&8225!==t&&8240!==t&&8241!==t&&8251!==t&&8252!==t&&8258!==t&&8263!==t&&8264!==t&&8265!==t&&8273!==t)||(!!r["Letterlike Symbols"](t)||(!!r["Number Forms"](t)||(!(!r["Miscellaneous Technical"](t)||!(t>=8960&&t<=8967||t>=8972&&t<=8991||t>=8996&&t<=9e3||9003===t||t>=9085&&t<=9114||t>=9150&&t<=9165||9167===t||t>=9169&&t<=9179||t>=9186&&t<=9215))||(!(!r["Control Pictures"](t)||9251===t)||(!!r["Optical Character Recognition"](t)||(!!r["Enclosed Alphanumerics"](t)||(!!r["Geometric Shapes"](t)||(!(!r["Miscellaneous Symbols"](t)||t>=9754&&t<=9759)||(!(!r["Miscellaneous Symbols and Arrows"](t)||!(t>=11026&&t<=11055||t>=11088&&t<=11097||t>=11192&&t<=11243))||(!!r["CJK Symbols and Punctuation"](t)||(!!r.Katakana(t)||(!!r["Private Use Area"](t)||(!!r["CJK Compatibility Forms"](t)||(!!r["Small Form Variants"](t)||(!!r["Halfwidth and Fullwidth Forms"](t)||(8734===t||8756===t||8757===t||t>=9984&&t<=10087||t>=10102&&t<=10131||65532===t||65533===t)))))))))))))))))},e.charHasRotatedVerticalOrientation=function(t){return!(e.charHasUprightVerticalOrientation(t)||e.charHasNeutralVerticalOrientation(t))}},function(t,e,n){"use strict";t.exports=i;var r=n(146);function i(t){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(t)?t:new Uint8Array(t||0),this.pos=0,this.type=0,this.length=this.buf.length}i.Varint=0,i.Fixed64=1,i.Bytes=2,i.Fixed32=5;function o(t){return t.type===i.Bytes?t.readVarint()+t.pos:t.pos+1}function a(t,e,n){return n?4294967296*e+(t>>>0):4294967296*(e>>>0)+(t>>>0)}function s(t,e,n){var r=e<=16383?1:e<=2097151?2:e<=268435455?3:Math.floor(Math.log(e)/(7*Math.LN2));n.realloc(r);for(var i=n.pos-1;i>=t;i--)n.buf[i+r]=n.buf[i]}function u(t,e){for(var n=0;n>>8,t[n+2]=e>>>16,t[n+3]=e>>>24}function b(t,e){return(t[e]|t[e+1]<<8|t[e+2]<<16)+(t[e+3]<<24)}i.prototype={destroy:function(){this.buf=null},readFields:function(t,e,n){for(n=n||this.length;this.pos>3,o=this.pos;this.type=7&r,t(i,e,this),this.pos===o&&this.skip(r)}return e},readMessage:function(t,e){return this.readFields(t,e,this.readVarint()+this.pos)},readFixed32:function(){var t=m(this.buf,this.pos);return this.pos+=4,t},readSFixed32:function(){var t=b(this.buf,this.pos);return this.pos+=4,t},readFixed64:function(){var t=m(this.buf,this.pos)+4294967296*m(this.buf,this.pos+4);return this.pos+=8,t},readSFixed64:function(){var t=m(this.buf,this.pos)+4294967296*b(this.buf,this.pos+4);return this.pos+=8,t},readFloat:function(){var t=r.read(this.buf,this.pos,!0,23,4);return this.pos+=4,t},readDouble:function(){var t=r.read(this.buf,this.pos,!0,52,8);return this.pos+=8,t},readVarint:function(t){var e,n,r=this.buf;return e=127&(n=r[this.pos++]),n<128?e:(e|=(127&(n=r[this.pos++]))<<7,n<128?e:(e|=(127&(n=r[this.pos++]))<<14,n<128?e:(e|=(127&(n=r[this.pos++]))<<21,n<128?e:function(t,e,n){var r,i,o=n.buf;if(i=o[n.pos++],r=(112&i)>>4,i<128)return a(t,r,e);if(i=o[n.pos++],r|=(127&i)<<3,i<128)return a(t,r,e);if(i=o[n.pos++],r|=(127&i)<<10,i<128)return a(t,r,e);if(i=o[n.pos++],r|=(127&i)<<17,i<128)return a(t,r,e);if(i=o[n.pos++],r|=(127&i)<<24,i<128)return a(t,r,e);if(i=o[n.pos++],r|=(1&i)<<31,i<128)return a(t,r,e);throw new Error("Expected varint not more than 10 bytes")}(e|=(15&(n=r[this.pos]))<<28,t,this))))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var t=this.readVarint();return t%2==1?(t+1)/-2:t/2},readBoolean:function(){return Boolean(this.readVarint())},readString:function(){var t=this.readVarint()+this.pos,e=function(t,e,n){var r="",i=e;for(;i239?4:u>223?3:u>191?2:1;if(i+c>n)break;1===c?u<128&&(l=u):2===c?128==(192&(o=t[i+1]))&&(l=(31&u)<<6|63&o)<=127&&(l=null):3===c?(o=t[i+1],a=t[i+2],128==(192&o)&&128==(192&a)&&((l=(15&u)<<12|(63&o)<<6|63&a)<=2047||l>=55296&&l<=57343)&&(l=null)):4===c&&(o=t[i+1],a=t[i+2],s=t[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&((l=(15&u)<<18|(63&o)<<12|(63&a)<<6|63&s)<=65535||l>=1114112)&&(l=null)),null===l?(l=65533,c=1):l>65535&&(l-=65536,r+=String.fromCharCode(l>>>10&1023|55296),l=56320|1023&l),r+=String.fromCharCode(l),i+=c}return r}(this.buf,this.pos,t);return this.pos=t,e},readBytes:function(){var t=this.readVarint()+this.pos,e=this.buf.subarray(this.pos,t);return this.pos=t,e},readPackedVarint:function(t,e){if(this.type!==i.Bytes)return t.push(this.readVarint(e));var n=o(this);for(t=t||[];this.pos127;);else if(e===i.Bytes)this.pos=this.readVarint()+this.pos;else if(e===i.Fixed32)this.pos+=4;else{if(e!==i.Fixed64)throw new Error("Unimplemented type: "+e);this.pos+=8}},writeTag:function(t,e){this.writeVarint(t<<3|e)},realloc:function(t){for(var e=this.length||16;e268435455||t<0?function(t,e){var n,r;t>=0?(n=t%4294967296|0,r=t/4294967296|0):(r=~(-t/4294967296),4294967295^(n=~(-t%4294967296))?n=n+1|0:(n=0,r=r+1|0));if(t>=0x10000000000000000||t<-0x10000000000000000)throw new Error("Given varint doesn\'t fit into 10 bytes");e.realloc(10),function(t,e,n){n.buf[n.pos++]=127&t|128,t>>>=7,n.buf[n.pos++]=127&t|128,t>>>=7,n.buf[n.pos++]=127&t|128,t>>>=7,n.buf[n.pos++]=127&t|128,t>>>=7,n.buf[n.pos]=127&t}(n,0,e),function(t,e){var n=(7&t)<<4;if(e.buf[e.pos++]|=n|((t>>>=3)?128:0),!t)return;if(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),!t)return;if(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),!t)return;if(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),!t)return;if(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),!t)return;e.buf[e.pos++]=127&t}(r,e)}(t,this):(this.realloc(4),this.buf[this.pos++]=127&t|(t>127?128:0),t<=127||(this.buf[this.pos++]=127&(t>>>=7)|(t>127?128:0),t<=127||(this.buf[this.pos++]=127&(t>>>=7)|(t>127?128:0),t<=127||(this.buf[this.pos++]=t>>>7&127))))},writeSVarint:function(t){this.writeVarint(t<0?2*-t-1:2*t)},writeBoolean:function(t){this.writeVarint(Boolean(t))},writeString:function(t){t=String(t),this.realloc(4*t.length),this.pos++;var e=this.pos;this.pos=function(t,e,n){for(var r,i,o=0;o55295&&r<57344){if(!i){r>56319||o+1===e.length?(t[n++]=239,t[n++]=191,t[n++]=189):i=r;continue}if(r<56320){t[n++]=239,t[n++]=191,t[n++]=189,i=r;continue}r=i-55296<<10|r-56320|65536,i=null}else i&&(t[n++]=239,t[n++]=191,t[n++]=189,i=null);r<128?t[n++]=r:(r<2048?t[n++]=r>>6|192:(r<65536?t[n++]=r>>12|224:(t[n++]=r>>18|240,t[n++]=r>>12&63|128),t[n++]=r>>6&63|128),t[n++]=63&r|128)}return n}(this.buf,t,this.pos);var n=this.pos-e;n>=128&&s(e,n,this),this.pos=e-1,this.writeVarint(n),this.pos+=n},writeFloat:function(t){this.realloc(4),r.write(this.buf,t,this.pos,!0,23,4),this.pos+=4},writeDouble:function(t){this.realloc(8),r.write(this.buf,t,this.pos,!0,52,8),this.pos+=8},writeBytes:function(t){var e=t.length;this.writeVarint(e),this.realloc(e);for(var n=0;n=128&&s(n,r,this),this.pos=n-1,this.writeVarint(r),this.pos+=r},writeMessage:function(t,e,n){this.writeTag(t,i.Bytes),this.writeRawMessage(e,n)},writePackedVarint:function(t,e){e.length&&this.writeMessage(t,u,e)},writePackedSVarint:function(t,e){e.length&&this.writeMessage(t,l,e)},writePackedBoolean:function(t,e){e.length&&this.writeMessage(t,h,e)},writePackedFloat:function(t,e){e.length&&this.writeMessage(t,c,e)},writePackedDouble:function(t,e){e.length&&this.writeMessage(t,f,e)},writePackedFixed32:function(t,e){e.length&&this.writeMessage(t,p,e)},writePackedSFixed32:function(t,e){e.length&&this.writeMessage(t,y,e)},writePackedFixed64:function(t,e){e.length&&this.writeMessage(t,d,e)},writePackedSFixed64:function(t,e){e.length&&this.writeMessage(t,v,e)},writeBytesField:function(t,e){this.writeTag(t,i.Bytes),this.writeBytes(e)},writeFixed32Field:function(t,e){this.writeTag(t,i.Fixed32),this.writeFixed32(e)},writeSFixed32Field:function(t,e){this.writeTag(t,i.Fixed32),this.writeSFixed32(e)},writeFixed64Field:function(t,e){this.writeTag(t,i.Fixed64),this.writeFixed64(e)},writeSFixed64Field:function(t,e){this.writeTag(t,i.Fixed64),this.writeSFixed64(e)},writeVarintField:function(t,e){this.writeTag(t,i.Varint),this.writeVarint(e)},writeSVarintField:function(t,e){this.writeTag(t,i.Varint),this.writeSVarint(e)},writeStringField:function(t,e){this.writeTag(t,i.Bytes),this.writeString(e)},writeFloatField:function(t,e){this.writeTag(t,i.Fixed32),this.writeFloat(e)},writeDoubleField:function(t,e){this.writeTag(t,i.Fixed64),this.writeDouble(e)},writeBooleanField:function(t,e){this.writeVarintField(t,Boolean(e))}}},function(t,e,n){function r(t,e){for(var n=0;n1}))return n.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);u={name:"cubic-bezier",controlPoints:y}}if(e.length-1<4)return n.error("Expected at least 4 arguments, but found only ".concat(e.length-1,"."));if((e.length-1)%2!=0)return n.error("Expected an even number of arguments.");if(!(l=n.parse(l,2,p)))return null;var d=[],v=null;n.expectedType&&"value"!==n.expectedType.kind&&(v=n.expectedType);for(var m=0;m=g)return n.error(\'Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.\',x);var k=n.parse(b,w,v);if(!k)return null;v=v||k.type,d.push([g,k])}return"number"===v.kind||"color"===v.kind||"array"===v.kind&&"number"===v.itemType.kind&&"number"==typeof v.N?new t(v,u,l,d):n.error("Type ".concat(h(v)," is not interpolatable."))}}],(n=[{key:"evaluate",value:function(e){var n=this.labels,r=this.outputs;if(1===n.length)return r[0].evaluate(e);var i=this.input.evaluate(e);if(i<=n[0])return r[0].evaluate(e);var o=n.length;if(i>=n[o-1])return r[o-1].evaluate(e);var a=y(n,i),s=n[a],u=n[a+1],l=t.interpolationFactor(this.interpolation,i,s,u),f=r[a].evaluate(e),h=r[a+1].evaluate(e);return c[this.type.kind.toLowerCase()](f,h,l)}},{key:"eachChild",value:function(t){t(this.input);var e=!0,n=!1,r=void 0;try{for(var i,o=this.outputs[Symbol.iterator]();!(e=(i=o.next()).done);e=!0){t(i.value)}}catch(t){n=!0,r=t}finally{try{e||null==o.return||o.return()}finally{if(n)throw r}}}},{key:"possibleOutputs",value:function(){var t;return(t=[]).concat.apply(t,r(this.outputs.map(function(t){return t.possibleOutputs()})))}}])&&u(e.prototype,n),f&&u(e,f),t}();function v(t,e,n,r){var i=r-n,o=t-n;return 0===i?0:1===e?o/i:(Math.pow(e,o)-1)/(Math.pow(e,i)-1)}t.exports=d},function(t,e,n){function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var i=n(100),o=n(13),a=n(22),s=n(7),u=n(19),l=n(34);function c(t){return t}function f(t,e,n){return void 0!==t?t:void 0!==e?e:void 0!==n?n:void 0}function h(t,e,n,i,o){return f(r(n)===o?i[n]:void 0,t.default,e.default)}function p(t,e,n){if("number"!==s(n))return f(t.default,e.default);var r=t.stops.length;if(1===r)return t.stops[0][1];if(n<=t.stops[0][0])return t.stops[0][1];if(n>=t.stops[r-1][0])return t.stops[r-1][1];var i=v(t.stops,n);return t.stops[i][1]}function y(t,e,n){var r=void 0!==t.base?t.base:1;if("number"!==s(n))return f(t.default,e.default);var o=t.stops.length;if(1===o)return t.stops[0][1];if(n<=t.stops[0][0])return t.stops[0][1];if(n>=t.stops[o-1][0])return t.stops[o-1][1];var a=v(t.stops,n),l=function(t,e,n,r){var i=r-n,o=t-n;return 0===i?0:1===e?o/i:(Math.pow(e,o)-1)/(Math.pow(e,i)-1)}(n,r,t.stops[a][0],t.stops[a+1][0]),h=t.stops[a][1],p=t.stops[a+1][1],y=u[e.type]||c;if(t.colorSpace&&"rgb"!==t.colorSpace){var d=i[t.colorSpace];y=function(t,e){return d.reverse(d.interpolate(d.forward(t),d.forward(e),l))}}return"function"==typeof h.evaluate?{evaluate:function(){for(var t=arguments.length,e=new Array(t),n=0;nn&&ee&&(o=a-1)}return Math.max(a-1,0)}t.exports={createFunction:function t(e,n){var s,u,c,v="color"===n.type,m=e.stops&&"object"===r(e.stops[0][0]),g=m||void 0!==e.property,b=m||!g,x=e.type||("interpolated"===n.function?"exponential":"interval");if(v&&((e=a({},e)).stops&&(e.stops=e.stops.map(function(t){return[t[0],o.parse(t[1])]})),e.default?e.default=o.parse(e.default):e.default=o.parse(n.default)),e.colorSpace&&"rgb"!==e.colorSpace&&!i[e.colorSpace])throw new Error("Unknown color space: ".concat(e.colorSpace));if("exponential"===x)s=y;else if("interval"===x)s=p;else if("categorical"===x){s=h,u=Object.create(null);var w=!0,k=!1,_=void 0;try{for(var S,A=e.stops[Symbol.iterator]();!(w=(S=A.next()).done);w=!0){var T=S.value;u[T[0]]=T[1]}}catch(t){k=!0,_=t}finally{try{w||null==A.return||A.return()}finally{if(k)throw _}}c=r(e.stops[0][0])}else{if("identity"!==x)throw new Error(\'Unknown function type "\'.concat(x,\'"\'));s=d}if(m){for(var j={},O=[],z=0;z":case">=":n.length>=2&&"$type"===s(n[1])&&c.push(new r(i,n,\'"$type" cannot be use with operator "\'.concat(n[0],\'"\')));case"==":case"!=":3!==n.length&&c.push(new r(i,n,\'filter array for operator "\'.concat(n[0],\'" must have 3 elements\')));case"in":case"!in":n.length>=2&&"string"!==(l=a(n[1]))&&c.push(new r("".concat(i,"[1]"),n[1],"string expected, ".concat(l," found")));for(var f=2;f=2&&"$id"!==t[1]&&"$type"!==t[1];case"in":case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return 3===t.length&&(Array.isArray(t[1])||Array.isArray(t[2]));case"any":case"all":var e=!0,n=!1,r=void 0;try{for(var i,a=t.slice(1)[Symbol.iterator]();!(e=(i=a.next()).done);e=!0){var s=i.value;if(!o(s)&&"boolean"!=typeof s)return!1}}catch(t){n=!0,r=t}finally{try{e||null==a.return||a.return()}finally{if(n)throw r}}return!0;default:return!0}}t.exports=function(t){if(!t)return function(){return!0};o(t)||(t=u(t));var e=i(t,a);if("error"===e.result)throw new Error(e.value.map(function(t){return"".concat(t.key,": ").concat(t.message)}).join(", "));return function(t,n){return e.value.evaluate(t,n)}},t.exports.isExpressionFilter=o;var a={type:"boolean",default:!1,function:!0,"property-function":!0,"zoom-function":!0};function s(t,e){return te?1:0}function u(t){if(!t)return!0;var e,n=t[0];return t.length<=1?"any"!==n:"=="===n?l(t[1],t[2],"=="):"!="===n?h(l(t[1],t[2],"==")):"<"===n||">"===n||"<="===n||">="===n?l(t[1],t[2],n):"any"===n?(e=t.slice(1),["any"].concat(e.map(u))):"all"===n?["all"].concat(t.slice(1).map(u)):"none"===n?["all"].concat(t.slice(1).map(u).map(h)):"in"===n?c(t[1],t.slice(2)):"!in"===n?h(c(t[1],t.slice(2))):"has"===n?f(t[1]):"!has"!==n||h(f(t[1]))}function l(t,e,n){switch(t){case"$type":return["filter-type-".concat(n),e];case"$id":return["filter-id-".concat(n),e];default:return["filter-".concat(n),t,e]}}function c(t,e){if(0===e.length)return!1;switch(t){case"$type":return["filter-type-in",["literal",e]];case"$id":return["filter-id-in",["literal",e]];default:return e.length>200&&!e.some(function(t){return r(t)!==r(e[0])})?["filter-in-large",t,["literal",e.sort(s)]]:["filter-in-small",t,["literal",e]]}}function f(t){switch(t){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",t]}}function h(t){return["!",t]}},function(t,e,n){var r=n(120),i=n(2).calculateSignedArea;function o(t,e){return e.area-t.area}t.exports=function(t,e){var n=t.length;if(n<=1)return[t];for(var a,s,u=[],l=0;l1)for(var f=0;f0)&&("constant"!==i.value.kind||i.value.value.length>0),u="constant"!==a.value.kind||a.value.value&&a.value.value.length>0;if(this.features=[],s||u){var l=e.iconDependencies,c=e.glyphDependencies,f={zoom:this.zoom},h=!0,p=!1,y=void 0;try{for(var d,v=t[Symbol.iterator]();!(h=(d=v.next()).done);h=!0){var m=d.value,g=m.feature,b=m.index,x=m.sourceLayerIndex;if(n._featureFilter(f,g)){var w=void 0;s&&(w=n.getValueAndResolveTokens("text-field",g),w=O(w,n,g));var k=void 0;if(u&&(k=n.getValueAndResolveTokens("icon-image",g)),w||k){var _={text:w,icon:k,index:b,sourceLayerIndex:x,geometry:E(g),properties:g.properties,type:C[g.type]};if(void 0!==g.id&&(_.id=g.id),this.features.push(_),k&&(l[k]=!0),w)for(var S=i.evaluate(g).join(","),A=c[S]=c[S]||{},T="map"===r.get("text-rotation-alignment")&&"line"===r.get("symbol-placement"),j=P.allowsVerticalWritingMode(w),I=0;I=0;s--)o[s]={x:e[s].x,y:e[s].y,tileUnitDistanceFromAnchor:i},s>0&&(i+=e[s-1].dist(e[s]));for(var u=0;u0;this.addCollisionDebugVertices(c,f,h,p,y?this.collisionCircle:this.collisionBox,l.anchorPoint,o,y)}}}}catch(t){e=!0,n=t}finally{try{t||null==i.return||i.return()}finally{if(e)throw n}}}},{key:"deserializeCollisionBoxes",value:function(t,e,n,r,i){for(var o={},a=e;a0}},{key:"hasIconData",value:function(){return this.icon.segments.get().length>0}},{key:"hasCollisionBoxData",value:function(){return this.collisionBox.segments.get().length>0}},{key:"hasCollisionCircleData",value:function(){return this.collisionCircle.segments.get().length>0}},{key:"sortFeatures",value:function(t){var e=this;if(this.sortFeaturesByY&&this.sortedAngle!==t&&(this.sortedAngle=t,!(this.text.segments.get().length>1||this.icon.segments.get().length>1))){for(var n=[],r=0;r=200&&n.status<300&&n.response){var t;try{t=JSON.parse(n.response)}catch(t){return e(t)}e(null,t)}else e(new f(n.statusText,n.status))},n.send(),n},e.getArrayBuffer=function(t,e){var n=h(t);return n.responseType="arraybuffer",n.onerror=function(){e(new Error(n.statusText))},n.onload=function(){var t=n.response;if(0===t.byteLength&&200===n.status)return e(new Error("http status 200 returned without content."));n.status>=200&&n.status<300&&n.response?e(null,{data:t,cacheControl:n.getResponseHeader("Cache-Control"),expires:n.getResponseHeader("Expires")}):e(new f(n.statusText,n.status))},n.send(),n};e.getImage=function(t,n){return e.getArrayBuffer(t,function(t,e){if(t)n(t);else if(e){var r=new l.Image,i=l.URL||l.webkitURL;r.onload=function(){n(null,r),i.revokeObjectURL(r.src)};var o=new l.Blob([new Uint8Array(e.data)],{type:"image/png"});r.cacheControl=e.cacheControl,r.expires=e.expires,r.src=e.data.byteLength?i.createObjectURL(o):"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII="}})},e.getVideo=function(t,e){var n,r,i=l.document.createElement("video");i.onloadstart=function(){e(null,i)};for(var o=0;o(r=1))return r;for(;no?n=i:r=i,i=.5*(r-n)+n}return i},n.prototype.solve=function(t,e){return this.sampleCurveY(this.solveCurveX(t,e))}},function(t,e){function n(t,e){for(var n=0;n=c[p+0]&&r>=c[p+1])?(a[h]=!0,o.push(l[h])):a[h]=!1}}},i.prototype._forEachCell=function(t,e,n,r,i,o,a,s){for(var u=this._convertToCellCoord(t),l=this._convertToCellCoord(e),c=this._convertToCellCoord(n),f=this._convertToCellCoord(r),h=u;h<=c;h++)for(var p=l;p<=f;p++){var y=this.d*p+h;if((!s||s(this._convertFromCellCoord(h),this._convertFromCellCoord(p),this._convertFromCellCoord(h+1),this._convertFromCellCoord(p+1)))&&i.call(this,t,e,n,r,y,o,a,s))return}},i.prototype._convertFromCellCoord=function(t){return(t-this.padding)/this.scale},i.prototype._convertToCellCoord=function(t){return Math.max(0,Math.min(this.d-1,Math.floor(t*this.scale)+this.padding))},i.prototype.toArrayBuffer=function(){if(this.arrayBuffer)return this.arrayBuffer;for(var t=this.cells,e=r+this.cells.length+1+1,n=0,i=0;i255?255:t}function i(t){return t<0?0:t>1?1:t}function o(t){return"%"===t[t.length-1]?r(parseFloat(t)/100*255):r(parseInt(t))}function a(t){return"%"===t[t.length-1]?i(parseFloat(t)/100):i(parseFloat(t))}function s(t,e,n){return n<0?n+=1:n>1&&(n-=1),6*n<1?t+(e-t)*n*6:2*n<1?e:3*n<2?t+(e-t)*(2/3-n)*6:t}try{e.parseCSSColor=function(t){var e,i=t.replace(/ /g,"").toLowerCase();if(i in n)return n[i].slice();if("#"===i[0])return 4===i.length?(e=parseInt(i.substr(1),16))>=0&&e<=4095?[(3840&e)>>4|(3840&e)>>8,240&e|(240&e)>>4,15&e|(15&e)<<4,1]:null:7===i.length&&(e=parseInt(i.substr(1),16))>=0&&e<=16777215?[(16711680&e)>>16,(65280&e)>>8,255&e,1]:null;var u=i.indexOf("("),l=i.indexOf(")");if(-1!==u&&l+1===i.length){var c=i.substr(0,u),f=i.substr(u+1,l-(u+1)).split(","),h=1;switch(c){case"rgba":if(4!==f.length)return null;h=a(f.pop());case"rgb":return 3!==f.length?null:[o(f[0]),o(f[1]),o(f[2]),h];case"hsla":if(4!==f.length)return null;h=a(f.pop());case"hsl":if(3!==f.length)return null;var p=(parseFloat(f[0])%360+360)%360/360,y=a(f[1]),d=a(f[2]),v=d<=.5?d*(y+1):d+y-d*y,m=2*d-v;return[r(255*s(m,v,p+1/3)),r(255*s(m,v,p)),r(255*s(m,v,p-1/3)),h];default:return null}}return null}}catch(t){}},function(t,e){function n(t){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function r(t,e){return!e||"object"!==n(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn\'t been initialised - super() hasn\'t been called");return t}(t):e}function i(t){var e="function"==typeof Map?new Map:void 0;return(i=function(t){if(null===t||(n=t,-1===Function.toString.call(n).indexOf("[native code]")))return t;var n;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==e){if(e.has(t))return e.get(t);e.set(t,r)}function r(){return o(t,arguments,s(this).constructor)}return r.prototype=Object.create(t.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),a(r,t)})(t)}function o(t,e,n){return(o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}()?Reflect.construct:function(t,e,n){var r=[null];r.push.apply(r,e);var i=new(Function.bind.apply(t,r));return n&&a(i,n.prototype),i}).apply(null,arguments)}function a(t,e){return(a=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function s(t){return(s=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var u=function(t){function e(t,n){var i;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),(i=r(this,s(e).call(this,n))).message=n,i.key=t,i}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&a(t,e)}(e,i(Error)),e}();t.exports=u},function(t,e,n){function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(t,e){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2?arguments[2]:void 0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:new o,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.registry=e,this.path=n,this.key=n.map(function(t){return"[".concat(t,"]")}).join(""),this.scope=i,this.errors=a,this.expectedType=r}var e,h,p;return e=t,(h=[{key:"parse",value:function(t,e,i,o){var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},s=this;if(e&&(s=s.concat(e,i,o)),null!==t&&"string"!=typeof t&&"boolean"!=typeof t&&"number"!=typeof t||(t=["literal",t]),Array.isArray(t)){if(0===t.length)return s.error(\'Expected an array with at least one element. If you wanted a literal array, use ["literal", []].\');var h=t[0];if("string"!=typeof h)return s.error("Expression name must be a string, but found ".concat(r(h),\' instead. If you wanted a literal array, use ["literal", [...]].\'),0),null;var p=s.registry[h];if(p){var y=p.parse(t,s);if(!y)return null;if(s.expectedType){var d=s.expectedType,v=y.type;if("string"!==d.kind&&"number"!==d.kind&&"boolean"!==d.kind||"value"!==v.kind)if("array"===d.kind&&"value"===v.kind)a.omitTypeAnnotations||(y=new c(d,y));else if("color"!==d.kind||"value"!==v.kind&&"string"!==v.kind){if(s.checkSubtype(s.expectedType,y.type))return null}else a.omitTypeAnnotations||(y=new f(d,[y]));else a.omitTypeAnnotations||(y=new l(d,[y]))}if(!(y instanceof u)&&function(t){var e=n(23).CompoundExpression,r=n(57),i=r.isGlobalPropertyConstant,o=r.isFeatureConstant,a=n(58);if(t instanceof a)return!1;if(t instanceof e&&"error"===t.name)return!1;var s=!0;if(t.eachChild(function(t){t instanceof u||(s=!1)}),!s)return!1;return o(t)&&i(t,["zoom","heatmap-density"])}(y)){var m=new(n(33));try{y=new u(y.type,y.evaluate(m))}catch(t){return s.error(t.message),null}}return y}return s.error(\'Unknown expression "\'.concat(h,\'". If you wanted a literal array, use ["literal", [...]].\'),0)}return void 0===t?s.error("\'undefined\' value invalid. Use null instead."):"object"===r(t)?s.error(\'Bare objects invalid. Use ["literal", {...}] instead.\'):s.error("Expected an array, but found ".concat(r(t)," instead."))}},{key:"concat",value:function(e,n,r){var i="number"==typeof e?this.path.concat(e):this.path,o=r?this.scope.concat(r):this.scope;return new t(this.registry,i,n||null,o,this.errors)}},{key:"error",value:function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r1&&void 0!==arguments[1]?arguments[1]:[];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.parent=e,this.bindings={};var i=!0,o=!1,a=void 0;try{for(var s,u=r[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var l=n(s.value,2),c=l[0],f=l[1];this.bindings[c]=f}}catch(t){o=!0,a=t}finally{try{i||null==u.return||u.return()}finally{if(o)throw a}}}var e,i,o;return e=t,(i=[{key:"concat",value:function(e){return new t(this,e)}},{key:"get",value:function(t){if(this.bindings[t])return this.bindings[t];if(this.parent)return this.parent.get(t);throw new Error("".concat(t," not found in scope."))}},{key:"has",value:function(t){return!!this.bindings[t]||!!this.parent&&this.parent.has(t)}}])&&r(e.prototype,i),o&&r(e,o),t}();t.exports=i},function(t,e,n){function r(t,e){for(var n=0;n4)return n.error("Expected 1, 2, or 3 arguments, but found ".concat(e.length-1," instead."));var r,i;if(e.length>2){var o=e[1];if("string"!=typeof o||!(o in y))return n.error(\'The item type argument of "array" must be one of string, number, boolean\',1);r=y[o]}else r=s;if(e.length>3){if("number"!=typeof e[2]||e[2]<0||e[2]!==Math.floor(e[2]))return n.error(\'The length argument to "array" must be a positive integer literal\',2);i=e[2]}var u=a(r,i),l=n.parse(e[e.length-1],e.length-1,s);return l?new t(u,l):null}}],(n=[{key:"evaluate",value:function(t){var e=this.input.evaluate(t);if(f(this.type,h(e)))throw new p("Expected value to be of type ".concat(o(this.type),", but found ").concat(o(h(e))," instead."));return e}},{key:"eachChild",value:function(t){t(this.input)}},{key:"possibleOutputs",value:function(){return this.input.possibleOutputs()}}])&&r(e.prototype,n),i&&r(e,i),t}();t.exports=d},function(t,e,n){function r(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e4?"Invalid rbga value ".concat(JSON.stringify(e),": expected an array containing either three or four numeric values."):h(e[0],e[1],e[2],e[3])))return new f(e[0]/255,e[1]/255,e[2]/255,e[3])}}catch(t){i=!0,o=t}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}throw new p(n||"Could not parse color from value \'".concat("string"==typeof e?e:JSON.stringify(e),"\'"))}var l=null,c=!0,y=!1,d=void 0;try{for(var v,m=this.args[Symbol.iterator]();!(c=(v=m.next()).done);c=!0){if(null!==(l=v.value.evaluate(t))){var g=Number(l);if(!isNaN(g))return g}}}catch(t){y=!0,d=t}finally{try{c||null==m.return||m.return()}finally{if(y)throw d}}throw new p("Could not convert ".concat(JSON.stringify(l)," to number."))}},{key:"eachChild",value:function(t){this.args.forEach(t)}},{key:"possibleOutputs",value:function(){var t;return(t=[]).concat.apply(t,r(this.args.map(function(t){return t.possibleOutputs()})))}}])&&i(e.prototype,n),a&&i(e,a),t}();t.exports=d},function(t,e,n){var r=n(23).CompoundExpression;t.exports={isFeatureConstant:function t(e){if(e instanceof r){if("get"===e.name&&1===e.args.length)return!1;if("has"===e.name&&1===e.args.length)return!1;if("properties"===e.name||"geometry-type"===e.name||"id"===e.name)return!1;if(e.name.startsWith("filter-"))return!1}var n=!0;return e.eachChild(function(e){n&&!t(e)&&(n=!1)}),n},isGlobalPropertyConstant:function t(e,n){if(e instanceof r&&n.indexOf(e.name)>=0)return!1;var i=!0;return e.eachChild(function(e){i&&!t(e,n)&&(i=!1)}),i}}},function(t,e){function n(t,e){for(var n=0;n=y)return n.error(\'Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.\',v);var g=n.parse(d,m,h);if(!g)return null;h=h||g.type,f.push([y,g])}return new t(h,u,f)}}],(n=[{key:"evaluate",value:function(t){var e=this.labels,n=this.outputs;if(1===e.length)return n[0].evaluate(t);var r=this.input.evaluate(t);if(r<=e[0])return n[0].evaluate(t);var i=e.length;return r>=e[i-1]?n[i-1].evaluate(t):n[c(e,r)].evaluate(t)}},{key:"eachChild",value:function(t){t(this.input);var e=!0,n=!1,r=void 0;try{for(var i,o=this.outputs[Symbol.iterator]();!(e=(i=o.next()).done);e=!0){t(i.value)}}catch(t){n=!0,r=t}finally{try{e||null==o.return||o.return()}finally{if(n)throw r}}}},{key:"possibleOutputs",value:function(){var t;return(t=[]).concat.apply(t,r(this.outputs.map(function(t){return t.possibleOutputs()})))}}])&&u(e.prototype,n),f&&u(e,f),t}();t.exports=f},function(t,e,n){var r=n(15);t.exports={findStopLessThanOrEqualTo:function(t,e){for(var n,i,o=0,a=t.length-1,s=0;o<=a;){if(n=t[s=Math.floor((o+a)/2)],i=t[s+1],e===n||e>n&&ee))throw new r("Input is not a number.");a=s-1}}return Math.max(s-1,0)}}},function(t,e,n){function r(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);ei.evaluate(t)}function J(t,e){var n=o(e,2),r=n[0],i=n[1];return r.evaluate(t)<=i.evaluate(t)}function G(t,e){var n=o(e,2),r=n[0],i=n[1];return r.evaluate(t)>=i.evaluate(t)}w.register(L,{error:[p,[u],function(t,e){var n=o(e,1)[0];throw new _(n.evaluate(t))}],typeof:[u,[h],function(t,e){var n=o(e,1)[0];return d(m(n.evaluate(t)))}],"to-string":[u,[h],function(t,e){var n=o(e,1)[0],r=i(n=n.evaluate(t));return null===n||"string"===r||"number"===r||"boolean"===r?String(n):n instanceof g?n.toString():JSON.stringify(n)}],"to-boolean":[l,[h],function(t,e){var n=o(e,1)[0];return Boolean(n.evaluate(t))}],"to-rgba":[y(s,4),[c],function(t,e){var n=o(e,1)[0].evaluate(t),r=n.r,i=n.g,a=n.b,s=n.a;return[255*r/s,255*i/s,255*a/s,s]}],rgb:[c,[s,s,s],F],rgba:[c,[s,s,s,s],F],length:{type:s,overloads:[[[u],q],[[y(h)],q]]},has:{type:l,overloads:[[[u],function(t,e){return R(o(e,1)[0].evaluate(t),t.properties())}],[[u,f],function(t,e){var n=o(e,2),r=n[0],i=n[1];return R(r.evaluate(t),i.evaluate(t))}]]},get:{type:h,overloads:[[[u],function(t,e){return D(o(e,1)[0].evaluate(t),t.properties())}],[[u,f],function(t,e){var n=o(e,2),r=n[0],i=n[1];return D(r.evaluate(t),i.evaluate(t))}]]},properties:[f,[],function(t){return t.properties()}],"geometry-type":[u,[],function(t){return t.geometryType()}],id:[h,[],function(t){return t.id()}],zoom:[s,[],function(t){return t.globals.zoom}],"heatmap-density":[s,[],function(t){return t.globals.heatmapDensity||0}],"+":[s,k(s),function(t,e){var n=0,r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){n+=a.value.evaluate(t)}}catch(t){i=!0,o=t}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}],"*":[s,k(s),function(t,e){var n=1,r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){n*=a.value.evaluate(t)}}catch(t){i=!0,o=t}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}return n}],"-":{type:s,overloads:[[[s,s],function(t,e){var n=o(e,2),r=n[0],i=n[1];return r.evaluate(t)-i.evaluate(t)}],[[s],function(t,e){return-o(e,1)[0].evaluate(t)}]]},"/":[s,[s,s],function(t,e){var n=o(e,2),r=n[0],i=n[1];return r.evaluate(t)/i.evaluate(t)}],"%":[s,[s,s],function(t,e){var n=o(e,2),r=n[0],i=n[1];return r.evaluate(t)%i.evaluate(t)}],ln2:[s,[],function(){return Math.LN2}],pi:[s,[],function(){return Math.PI}],e:[s,[],function(){return Math.E}],"^":[s,[s,s],function(t,e){var n=o(e,2),r=n[0],i=n[1];return Math.pow(r.evaluate(t),i.evaluate(t))}],sqrt:[s,[s],function(t,e){var n=o(e,1)[0];return Math.sqrt(n.evaluate(t))}],log10:[s,[s],function(t,e){var n=o(e,1)[0];return Math.log10(n.evaluate(t))}],ln:[s,[s],function(t,e){var n=o(e,1)[0];return Math.log(n.evaluate(t))}],log2:[s,[s],function(t,e){var n=o(e,1)[0];return Math.log2(n.evaluate(t))}],sin:[s,[s],function(t,e){var n=o(e,1)[0];return Math.sin(n.evaluate(t))}],cos:[s,[s],function(t,e){var n=o(e,1)[0];return Math.cos(n.evaluate(t))}],tan:[s,[s],function(t,e){var n=o(e,1)[0];return Math.tan(n.evaluate(t))}],asin:[s,[s],function(t,e){var n=o(e,1)[0];return Math.asin(n.evaluate(t))}],acos:[s,[s],function(t,e){var n=o(e,1)[0];return Math.acos(n.evaluate(t))}],atan:[s,[s],function(t,e){var n=o(e,1)[0];return Math.atan(n.evaluate(t))}],min:[s,k(s),function(t,e){return Math.min.apply(Math,r(e.map(function(e){return e.evaluate(t)})))}],max:[s,k(s),function(t,e){return Math.max.apply(Math,r(e.map(function(e){return e.evaluate(t)})))}],"filter-==":[l,[u,h],function(t,e){var n=o(e,2),r=n[0],i=n[1];return t.properties()[r.value]===i.value}],"filter-id-==":[l,[h],function(t,e){var n=o(e,1)[0];return t.id()===n.value}],"filter-type-==":[l,[u],function(t,e){var n=o(e,1)[0];return t.geometryType()===n.value}],"filter-<":[l,[u,h],function(t,e){var n=o(e,2),r=n[0],a=n[1],s=t.properties()[r.value],u=a.value;return i(s)===i(u)&&s":[l,[u,h],function(t,e){var n=o(e,2),r=n[0],a=n[1],s=t.properties()[r.value],u=a.value;return i(s)===i(u)&&s>u}],"filter-id->":[l,[h],function(t,e){var n=o(e,1)[0],r=t.id(),a=n.value;return i(r)===i(a)&&r>a}],"filter-<=":[l,[u,h],function(t,e){var n=o(e,2),r=n[0],a=n[1],s=t.properties()[r.value],u=a.value;return i(s)===i(u)&&s<=u}],"filter-id-<=":[l,[h],function(t,e){var n=o(e,1)[0],r=t.id(),a=n.value;return i(r)===i(a)&&r<=a}],"filter->=":[l,[u,h],function(t,e){var n=o(e,2),r=n[0],a=n[1],s=t.properties()[r.value],u=a.value;return i(s)===i(u)&&s>=u}],"filter-id->=":[l,[h],function(t,e){var n=o(e,1)[0],r=t.id(),a=n.value;return i(r)===i(a)&&r>=a}],"filter-has":[l,[h],function(t,e){return o(e,1)[0].value in t.properties()}],"filter-has-id":[l,[],function(t){return null!==t.id()}],"filter-type-in":[l,[y(u)],function(t,e){return o(e,1)[0].value.indexOf(t.geometryType())>=0}],"filter-id-in":[l,[y(h)],function(t,e){return o(e,1)[0].value.indexOf(t.id())>=0}],"filter-in-small":[l,[u,y(h)],function(t,e){var n=o(e,2),r=n[0];return n[1].value.indexOf(t.properties()[r.value])>=0}],"filter-in-large":[l,[u,y(h)],function(t,e){var n=o(e,2),r=n[0],i=n[1];return function(t,e,n,r){for(;n<=r;){var i=n+r>>1;if(e[i]===t)return!0;e[i]>t?r=i-1:n=i+1}return!1}(t.properties()[r.value],i.value,0,i.value.length-1)}],">":{type:l,overloads:[[[s,s],U],[[u,u],U]]},"<":{type:l,overloads:[[[s,s],N],[[u,u],N]]},">=":{type:l,overloads:[[[s,s],G],[[u,u],G]]},"<=":{type:l,overloads:[[[s,s],J],[[u,u],J]]},all:{type:l,overloads:[[[l,l],function(t,e){var n=o(e,2),r=n[0],i=n[1];return r.evaluate(t)&&i.evaluate(t)}],[k(l),function(t,e){var n=!0,r=!1,i=void 0;try{for(var o,a=e[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){if(!o.value.evaluate(t))return!1}}catch(t){r=!0,i=t}finally{try{n||null==a.return||a.return()}finally{if(r)throw i}}return!0}]]},any:{type:l,overloads:[[[l,l],function(t,e){var n=o(e,2),r=n[0],i=n[1];return r.evaluate(t)||i.evaluate(t)}],[k(l),function(t,e){var n=!0,r=!1,i=void 0;try{for(var o,a=e[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){if(o.value.evaluate(t))return!0}}catch(t){r=!0,i=t}finally{try{n||null==a.return||a.return()}finally{if(r)throw i}}return!1}]]},"!":[l,[l],function(t,e){return!o(e,1)[0].evaluate(t)}],upcase:[u,[u],function(t,e){return o(e,1)[0].evaluate(t).toUpperCase()}],downcase:[u,[u],function(t,e){return o(e,1)[0].evaluate(t).toLowerCase()}],concat:[u,k(u),function(t,e){return e.map(function(e){return e.evaluate(t)}).join("")}]}),t.exports=L},function(t,e,n){var r=n(5);t.exports=function(t){var e=t.key,n=t.value;return n?[new r(e,n,"constants have been deprecated as of v8")]:[]}},function(t,e,n){var r=n(5),i=n(7),o=n(16),a=n(24),s=n(66),u=n(67),l=n(12);t.exports=function(t){var e,n,c,f=t.valueSpec,h=l(t.value.type),p={},y="categorical"!==h&&void 0===t.value.property,d=!y,v="array"===i(t.value.stops)&&"array"===i(t.value.stops[0])&&"object"===i(t.value.stops[0][0]),m=a({key:t.key,value:t.value,valueSpec:t.styleSpec.function,style:t.style,styleSpec:t.styleSpec,objectElementValidators:{stops:function(t){if("identity"===h)return[new r(t.key,t.value,\'identity function may not have a "stops" property\')];var e=[],n=t.value;e=e.concat(s({key:t.key,value:n,valueSpec:t.valueSpec,style:t.style,styleSpec:t.styleSpec,arrayElementValidator:g})),"array"===i(n)&&0===n.length&&e.push(new r(t.key,n,"array must have at least one stop"));return e},default:function(t){return o({key:t.key,value:t.value,valueSpec:f,style:t.style,styleSpec:t.styleSpec})}}});return"identity"===h&&y&&m.push(new r(t.key,t.value,\'missing required property "property"\')),"identity"===h||t.value.stops||m.push(new r(t.key,t.value,\'missing required property "stops"\')),"exponential"===h&&"piecewise-constant"===t.valueSpec.function&&m.push(new r(t.key,t.value,"exponential functions not supported")),t.styleSpec.$version>=8&&(d&&!t.valueSpec["property-function"]?m.push(new r(t.key,t.value,"property functions not supported")):y&&!t.valueSpec["zoom-function"]&&"heatmap-color"!==t.objectKey&&m.push(new r(t.key,t.value,"zoom functions not supported"))),"categorical"!==h&&!v||void 0!==t.value.property||m.push(new r(t.key,t.value,\'"property" property is required\')),m;function g(t){var e=[],s=t.value,h=t.key;if("array"!==i(s))return[new r(h,s,"array expected, ".concat(i(s)," found"))];if(2!==s.length)return[new r(h,s,"array length 2 expected, length ".concat(s.length," found"))];if(v){if("object"!==i(s[0]))return[new r(h,s,"object expected, ".concat(i(s[0])," found"))];if(void 0===s[0].zoom)return[new r(h,s,"object stop key must have zoom")];if(void 0===s[0].value)return[new r(h,s,"object stop key must have value")];if(c&&c>l(s[0].zoom))return[new r(h,s[0].zoom,"stop zoom values must appear in ascending order")];l(s[0].zoom)!==c&&(c=l(s[0].zoom),n=void 0,p={}),e=e.concat(a({key:"".concat(h,"[0]"),value:s[0],valueSpec:{zoom:{}},style:t.style,styleSpec:t.styleSpec,objectElementValidators:{zoom:u,value:b}}))}else e=e.concat(b({key:"".concat(h,"[0]"),value:s[0],valueSpec:{},style:t.style,styleSpec:t.styleSpec},s));return e.concat(o({key:"".concat(h,"[1]"),value:s[1],valueSpec:f,style:t.style,styleSpec:t.styleSpec}))}function b(t,o){var a=i(t.value),s=l(t.value),u=null!==t.value?t.value:o;if(e){if(a!==e)return[new r(t.key,u,"".concat(a," stop domain type must match previous stop domain type ").concat(e))]}else e=a;if("number"!==a&&"string"!==a&&"boolean"!==a)return[new r(t.key,u,"stop domain value must be a number, string, or boolean")];if("number"!==a&&"categorical"!==h){var c="number expected, ".concat(a," found");return f["property-function"]&&void 0===h&&(c+=\'\\nIf you intended to use a categorical function, specify `"type": "categorical"`.\'),[new r(t.key,u,c)]}return"categorical"!==h||"number"!==a||isFinite(s)&&Math.floor(s)===s?"categorical"!==h&&"number"===a&&void 0!==n&&so.maximum?[new i(e,n,"".concat(n," is greater than the maximum value ").concat(o.maximum))]:[]}},function(t,e,n){var r=n(5),i=n(14),o=i.createExpression,a=i.createPropertyExpression,s=n(12);t.exports=function(t){var e=("property"===t.expressionContext?a:o)(s.deep(t.value),t.valueSpec);return"error"===e.result?e.value.map(function(e){return new r("".concat(t.key).concat(e.key),t.value,e.message)}):"property"===t.expressionContext&&"text-font"===t.propertyKey&&-1!==e.value._styleExpression.expression.possibleOutputs().indexOf(void 0)?[new r(t.key,t.value,\'Invalid data expression for "text-font". Output values must be contained as literals within the expression.\')]:[]}},function(t,e,n){var r=n(5),i=n(12),o=n(24),a=n(38),s=n(70),u=n(72),l=n(16),c=n(22);t.exports=function(t){var e=[],n=t.value,f=t.key,h=t.style,p=t.styleSpec;n.type||n.ref||e.push(new r(f,n,\'either "type" or "ref" is required\'));var y,d=i(n.type),v=i(n.ref);if(n.id)for(var m=i(n.id),g=0;g0||this._oneTimeListeners&&this._oneTimeListeners[t]&&this._oneTimeListeners[t].length>0||this._eventedParent&&this._eventedParent.listens(t)}},{key:"setEventedParent",value:function(t,e){return this._eventedParent=t,this._eventedParentData=e,this}}])&&r(e.prototype,n),s&&r(e,s),t}();t.exports=s},function(t,e,n){function r(t,e){for(var n=0;n=c||m<0||m>=c)){var g=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray),b=g.vertexLength;h(this.layoutVertexArray,v,m,-1,-1),h(this.layoutVertexArray,v,m,1,-1),h(this.layoutVertexArray,v,m,1,1),h(this.layoutVertexArray,v,m,-1,1),this.indexArray.emplaceBack(b,b+1,b+2),this.indexArray.emplaceBack(b,b+3,b+2),g.vertexLength+=4,g.primitiveLength+=2}}}catch(t){l=!0,f=t}finally{try{u||null==y.return||y.return()}finally{if(l)throw f}}}}catch(t){r=!0,i=t}finally{try{n||null==a.return||a.return()}finally{if(r)throw i}}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,t)}}])&&r(e.prototype,n),f&&r(e,f),t}();f("CircleBucket",p,{omit:["layers"]}),t.exports=p},function(t,e,n){"use strict";function r(t,e,n){n=n||2;var r,s,u,l,c,p,d,v=e&&e.length,m=v?e[0]*n:t.length,g=i(t,0,m,n,!0),b=[];if(!g||g.next===g.prev)return b;if(v&&(g=function(t,e,n,r){var a,s,u,l,c,p=[];for(a=0,s=e.length;a80*n){r=u=t[0],s=l=t[1];for(var x=n;xu&&(u=c),p>l&&(l=p);d=0!==(d=Math.max(u-r,l-s))?1/d:0}return a(g,b,n,r,s,d),b}function i(t,e,n,r,i){var o,a;if(i===A(t,e,n,r)>0)for(o=e;o=e;o-=r)a=k(o,t[o],t[o+1],a);return a&&g(a,a.next)&&(_(a),a=a.next),a}function o(t,e){if(!t)return t;e||(e=t);var n,r=t;do{if(n=!1,r.steiner||!g(r,r.next)&&0!==m(r.prev,r,r.next))r=r.next;else{if(_(r),(r=e=r.prev)===r.next)break;n=!0}}while(n||r!==e);return e}function a(t,e,n,r,i,f,h){if(t){!h&&f&&function(t,e,n,r){var i=t;do{null===i.z&&(i.z=p(i.x,i.y,e,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,function(t){var e,n,r,i,o,a,s,u,l=1;do{for(n=t,t=null,o=null,a=0;n;){for(a++,r=n,s=0,e=0;e0||u>0&&r;)0!==s&&(0===u||!r||n.z<=r.z)?(i=n,n=n.nextZ,s--):(i=r,r=r.nextZ,u--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;n=r}o.nextZ=null,l*=2}while(a>1)}(i)}(t,r,i,f);for(var y,d,v=t;t.prev!==t.next;)if(y=t.prev,d=t.next,f?u(t,r,i,f):s(t))e.push(y.i/n),e.push(t.i/n),e.push(d.i/n),_(t),t=d.next,v=d.next;else if((t=d)===v){h?1===h?a(t=l(t,e,n),e,n,r,i,f,2):2===h&&c(t,e,n,r,i,f):a(o(t),e,n,r,i,f,1);break}}}function s(t){var e=t.prev,n=t,r=t.next;if(m(e,n,r)>=0)return!1;for(var i=t.next.next;i!==t.prev;){if(d(e.x,e.y,n.x,n.y,r.x,r.y,i.x,i.y)&&m(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function u(t,e,n,r){var i=t.prev,o=t,a=t.next;if(m(i,o,a)>=0)return!1;for(var s=i.xo.x?i.x>a.x?i.x:a.x:o.x>a.x?o.x:a.x,c=i.y>o.y?i.y>a.y?i.y:a.y:o.y>a.y?o.y:a.y,f=p(s,u,e,n,r),h=p(l,c,e,n,r),y=t.prevZ,v=t.nextZ;y&&y.z>=f&&v&&v.z<=h;){if(y!==t.prev&&y!==t.next&&d(i.x,i.y,o.x,o.y,a.x,a.y,y.x,y.y)&&m(y.prev,y,y.next)>=0)return!1;if(y=y.prevZ,v!==t.prev&&v!==t.next&&d(i.x,i.y,o.x,o.y,a.x,a.y,v.x,v.y)&&m(v.prev,v,v.next)>=0)return!1;v=v.nextZ}for(;y&&y.z>=f;){if(y!==t.prev&&y!==t.next&&d(i.x,i.y,o.x,o.y,a.x,a.y,y.x,y.y)&&m(y.prev,y,y.next)>=0)return!1;y=y.prevZ}for(;v&&v.z<=h;){if(v!==t.prev&&v!==t.next&&d(i.x,i.y,o.x,o.y,a.x,a.y,v.x,v.y)&&m(v.prev,v,v.next)>=0)return!1;v=v.nextZ}return!0}function l(t,e,n){var r=t;do{var i=r.prev,o=r.next.next;!g(i,o)&&b(i,r,r.next,o)&&x(i,o)&&x(o,i)&&(e.push(i.i/n),e.push(r.i/n),e.push(o.i/n),_(r),_(r.next),r=t=o),r=r.next}while(r!==t);return r}function c(t,e,n,r,i,s){var u=t;do{for(var l=u.next.next;l!==u.prev;){if(u.i!==l.i&&v(u,l)){var c=w(u,l);return u=o(u,u.next),c=o(c,c.next),a(u,e,n,r,i,s),void a(c,e,n,r,i,s)}l=l.next}u=u.next}while(u!==t)}function f(t,e){return t.x-e.x}function h(t,e){if(e=function(t,e){var n,r=e,i=t.x,o=t.y,a=-1/0;do{if(o<=r.y&&o>=r.next.y&&r.next.y!==r.y){var s=r.x+(o-r.y)*(r.next.x-r.x)/(r.next.y-r.y);if(s<=i&&s>a){if(a=s,s===i){if(o===r.y)return r;if(o===r.next.y)return r.next}n=r.x=r.x&&r.x>=c&&i!==r.x&&d(on.x)&&x(r,t)&&(n=r,h=u),r=r.next;return n}(t,e)){var n=w(e,t);o(n,n.next)}}function p(t,e,n,r,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-n)*i)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-r)*i)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function y(t){var e=t,n=t;do{(e.x=0&&(t-a)*(r-s)-(n-a)*(e-s)>=0&&(n-a)*(o-s)-(i-a)*(r-s)>=0}function v(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){var n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&b(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}(t,e)&&x(t,e)&&x(e,t)&&function(t,e){var n=t,r=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&i<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}(t,e)}function m(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function g(t,e){return t.x===e.x&&t.y===e.y}function b(t,e,n,r){return!!(g(t,e)&&g(n,r)||g(t,r)&&g(n,e))||m(t,e,n)>0!=m(t,e,r)>0&&m(n,r,t)>0!=m(n,r,e)>0}function x(t,e){return m(t.prev,t,t.next)<0?m(t,e,t.next)>=0&&m(t,t.prev,e)>=0:m(t,e,t.prev)<0||m(t,t.next,e)<0}function w(t,e){var n=new S(t.i,t.x,t.y),r=new S(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=i,i.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function k(t,e,n,r){var i=new S(t,e,n);return r?(i.next=r.next,i.prev=r,r.next.prev=i,r.next=i):(i.prev=i,i.next=i),i}function _(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function S(t,e,n){this.i=t,this.x=e,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function A(t,e,n,r){for(var i=0,o=e,a=n-r;o0&&(r+=t[i-1].length,n.holes.push(r))}return n}},function(t,e,n){"use strict";var r=n(80);function i(t,e){this.version=1,this.name=null,this.extent=4096,this.length=0,this._pbf=t,this._keys=[],this._values=[],this._features=[],t.readFields(o,this,e),this.length=this._features.length}function o(t,e,n){15===t?e.version=n.readVarint():1===t?e.name=n.readString():5===t?e.extent=n.readVarint():2===t?e._features.push(n.pos):3===t?e._keys.push(n.readString()):4===t&&e._values.push(function(t){var e=null,n=t.readVarint()+t.pos;for(;t.pos>3;e=1===r?t.readString():2===r?t.readFloat():3===r?t.readDouble():4===r?t.readVarint64():5===r?t.readVarint():6===r?t.readSVarint():7===r?t.readBoolean():null}return e}(n))}t.exports=i,i.prototype.feature=function(t){if(t<0||t>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[t];var e=this._pbf.readVarint()+this._pbf.pos;return new r(this._pbf,e,this.extent,this._keys,this._values)}},function(t,e,n){"use strict";var r=n(6);function i(t,e,n,r,i){this.properties={},this.extent=n,this.type=0,this._pbf=t,this._geometry=-1,this._keys=r,this._values=i,t.readFields(o,this,e)}function o(t,e,n){1==t?e.id=n.readVarint():2==t?function(t,e){var n=t.readVarint()+t.pos;for(;t.pos>3}if(o--,1===i||2===i)a+=t.readSVarint(),s+=t.readSVarint(),1===i&&(e&&u.push(e),e=[]),e.push(new r(a,s));else{if(7!==i)throw new Error("unknown command "+i);e&&e.push(e[0].clone())}}return e&&u.push(e),u},i.prototype.bbox=function(){var t=this._pbf;t.pos=this._geometry;for(var e=t.readVarint()+t.pos,n=1,r=0,i=0,o=0,a=1/0,s=-1/0,u=1/0,l=-1/0;t.pos>3}if(r--,1===n||2===n)(i+=t.readSVarint())s&&(s=i),(o+=t.readSVarint())l&&(l=o);else if(7!==n)throw new Error("unknown command "+n)}return[a,u,s,l]},i.prototype.toGeoJSON=function(t,e,n){var r,o,s=this.extent*Math.pow(2,n),u=this.extent*t,l=this.extent*e,c=this.loadGeometry(),f=i.types[this.type];function h(t){for(var e=0;e":"\uFE40","?":"\uFE16","@":"\uFF20","[":"\uFE47","\\\\":"\uFF3C","]":"\uFE48","^":"\uFF3E",_:"\uFE33","`":"\uFF40","{":"\uFE37","|":"\u2015","}":"\uFE38","~":"\uFF5E","\xA2":"\uFFE0","\xA3":"\uFFE1","\xA5":"\uFFE5","\xA6":"\uFFE4","\xAC":"\uFFE2","\xAF":"\uFFE3","\u2013":"\uFE32","\u2014":"\uFE31","\u2018":"\uFE43","\u2019":"\uFE44","\u201C":"\uFE41","\u201D":"\uFE42","\u2026":"\uFE19","\u2027":"\u30FB","\u20A9":"\uFFE6","\u3001":"\uFE11","\u3002":"\uFE12","\u3008":"\uFE3F","\u3009":"\uFE40","\u300A":"\uFE3D","\u300B":"\uFE3E","\u300C":"\uFE41","\u300D":"\uFE42","\u300E":"\uFE43","\u300F":"\uFE44","\u3010":"\uFE3B","\u3011":"\uFE3C","\u3014":"\uFE39","\u3015":"\uFE3A","\u3016":"\uFE17","\u3017":"\uFE18","\uFF01":"\uFE15","\uFF08":"\uFE35","\uFF09":"\uFE36","\uFF0C":"\uFE10","\uFF0D":"\uFE32","\uFF0E":"\u30FB","\uFF1A":"\uFE13","\uFF1B":"\uFE14","\uFF1C":"\uFE3F","\uFF1E":"\uFE40","\uFF1F":"\uFE16","\uFF3B":"\uFE47","\uFF3D":"\uFE48","\uFF3F":"\uFE33","\uFF5B":"\uFE37","\uFF5C":"\u2015","\uFF5D":"\uFE38","\uFF5F":"\uFE35","\uFF60":"\uFE36","\uFF61":"\uFE12","\uFF62":"\uFE41","\uFF63":"\uFE42"}},function(t,e,n){function r(t,e){for(var n=0;n=0&&e<=25),s(n>=0&&n=0&&i0;o--)i+=(e&(r=1<=i),this.overscaledZ=e,this.wrap=n,this.canonical=new c(i,+o,+a),this.key=p(n,e,o,a)}return o(t,[{key:"scaledTo",value:function(e){s(e<=this.overscaledZ);var n=this.canonical.z-e;return e>this.canonical.z?new t(e,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new t(e,this.wrap,e,this.canonical.x>>n,this.canonical.y>>n)}},{key:"isChildOf",value:function(t){var e=this.canonical.z-t.canonical.z;return 0===t.overscaledZ||t.overscaledZ>e&&t.canonical.y===this.canonical.y>>e}},{key:"children",value:function(e){if(this.overscaledZ>=e)return[new t(this.overscaledZ+1,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)];var n=this.canonical.z+1,r=2*this.canonical.x,i=2*this.canonical.y;return[new t(n,this.wrap,n,r,i),new t(n,this.wrap,n,r+1,i),new t(n,this.wrap,n,r,i+1),new t(n,this.wrap,n,r+1,i+1)]}},{key:"isLessThan",value:function(t){return this.wrapt.wrap)&&(this.overscaledZt.overscaledZ)&&(this.canonical.xt.canonical.x)&&this.canonical.yi.maxh||t>i.maxw||n<=i.maxh&&t<=i.maxw&&(a=i.maxw*i.maxh-t*n)o.free)){if(n===o.h)return this.allocShelf(s,t,n,r);n>o.h||nc)&&(f=2*Math.max(t,c)),(uu)&&(l=2*Math.max(n,u)),this.resize(f,l),this.packOne(t,n,r)):null},t.prototype.allocFreebin=function(t,e,n,r){var i=this.freebins.splice(t,1)[0];return i.id=r,i.w=e,i.h=n,i.refcount=0,this.bins[r]=i,this.ref(i),i},t.prototype.allocShelf=function(t,e,n,r){var i=this.shelves[t].alloc(e,n,r);return this.bins[r]=i,this.ref(i),i},t.prototype.shrink=function(){if(this.shelves.length>0){for(var t=0,e=0,n=0;nthis.free||e>this.h)return null;var i=this.x;return this.x+=t,this.free-=t,new n(r,i,this.y,t,e,t,this.h)},e.prototype.resize=function(t){return this.free+=t-this.w,this.w=t,!0},t}()},function(t,e,n){function r(t,e){for(var n=0;n",id:String(i),error:t?String(t):null,data:a(e,r)},r)};if(""===r.type)e=this.callbacks[r.id],delete this.callbacks[r.id],e&&r.error?e(new Error(r.error)):e&&e(null,s(r.data));else if(void 0!==r.id&&this.parent[r.type])this.parent[r.type](r.sourceMapId,s(r.data),o);else if(void 0!==r.id&&this.parent.getWorkerSource){var u=r.type.split(".");this.parent.getWorkerSource(r.sourceMapId,u[0])[u[1]](s(r.data),o)}else this.parent[r.type](s(r.data))}}},{key:"remove",value:function(){this.target.removeEventListener("message",this.receive,!1)}}])&&r(e.prototype,n),o&&r(e,o),t}();t.exports=u},function(t,e){function n(t){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}t.exports=function t(e,r){if(Array.isArray(e)){if(!Array.isArray(r)||e.length!==r.length)return!1;for(var i=0;i=o)return t;switch(t){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(t){return"[Circular]"}default:return t}}),u=r[n];n=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),y(n)?r.showHidden=n:n&&e._extend(r,n),g(r.showHidden)&&(r.showHidden=!1),g(r.depth)&&(r.depth=2),g(r.colors)&&(r.colors=!1),g(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=u),c(r,t,r.depth)}function u(t,e){var n=s.styles[e];return n?"\x1B["+s.colors[n][0]+"m"+t+"\x1B["+s.colors[n][1]+"m":t}function l(t,e){return t}function c(t,n,r){if(t.customInspect&&n&&_(n.inspect)&&n.inspect!==e.inspect&&(!n.constructor||n.constructor.prototype!==n)){var i=n.inspect(r,t);return m(i)||(i=c(t,i,r)),i}var o=function(t,e){if(g(e))return t.stylize("undefined","undefined");if(m(e)){var n="\'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/\'/g,"\\\\\'").replace(/\\\\"/g,\'"\')+"\'";return t.stylize(n,"string")}if(v(e))return t.stylize(""+e,"number");if(y(e))return t.stylize(""+e,"boolean");if(d(e))return t.stylize("null","null")}(t,n);if(o)return o;var a=Object.keys(n),s=function(t){var e={};return t.forEach(function(t,n){e[t]=!0}),e}(a);if(t.showHidden&&(a=Object.getOwnPropertyNames(n)),k(n)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return f(n);if(0===a.length){if(_(n)){var u=n.name?": "+n.name:"";return t.stylize("[Function"+u+"]","special")}if(b(n))return t.stylize(RegExp.prototype.toString.call(n),"regexp");if(w(n))return t.stylize(Date.prototype.toString.call(n),"date");if(k(n))return f(n)}var l,x="",S=!1,A=["{","}"];(p(n)&&(S=!0,A=["[","]"]),_(n))&&(x=" [Function"+(n.name?": "+n.name:"")+"]");return b(n)&&(x=" "+RegExp.prototype.toString.call(n)),w(n)&&(x=" "+Date.prototype.toUTCString.call(n)),k(n)&&(x=" "+f(n)),0!==a.length||S&&0!=n.length?r<0?b(n)?t.stylize(RegExp.prototype.toString.call(n),"regexp"):t.stylize("[Object]","special"):(t.seen.push(n),l=S?function(t,e,n,r,i){for(var o=[],a=0,s=e.length;a=0&&0,t+e.replace(/\\u001b\\[\\d\\d?m/g,"").length+1},0)>60)return n[0]+(""===e?"":e+"\\n ")+" "+t.join(",\\n ")+" "+n[1];return n[0]+e+" "+t.join(", ")+" "+n[1]}(l,x,A)):A[0]+x+A[1]}function f(t){return"["+Error.prototype.toString.call(t)+"]"}function h(t,e,n,r,i,o){var a,s,u;if((u=Object.getOwnPropertyDescriptor(e,i)||{value:e[i]}).get?s=u.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):u.set&&(s=t.stylize("[Setter]","special")),j(r,i)||(a="["+i+"]"),s||(t.seen.indexOf(u.value)<0?(s=d(n)?c(t,u.value,null):c(t,u.value,n-1)).indexOf("\\n")>-1&&(s=o?s.split("\\n").map(function(t){return" "+t}).join("\\n").substr(2):"\\n"+s.split("\\n").map(function(t){return" "+t}).join("\\n")):s=t.stylize("[Circular]","special")),g(a)){if(o&&i.match(/^\\d+$/))return s;(a=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=t.stylize(a,"name")):(a=a.replace(/\'/g,"\\\\\'").replace(/\\\\"/g,\'"\').replace(/(^"|"$)/g,"\'"),a=t.stylize(a,"string"))}return a+": "+s}function p(t){return Array.isArray(t)}function y(t){return"boolean"==typeof t}function d(t){return null===t}function v(t){return"number"==typeof t}function m(t){return"string"==typeof t}function g(t){return void 0===t}function b(t){return x(t)&&"[object RegExp]"===S(t)}function x(t){return"object"==typeof t&&null!==t}function w(t){return x(t)&&"[object Date]"===S(t)}function k(t){return x(t)&&("[object Error]"===S(t)||t instanceof Error)}function _(t){return"function"==typeof t}function S(t){return Object.prototype.toString.call(t)}function A(t){return t<10?"0"+t.toString(10):t.toString(10)}e.debuglog=function(n){if(g(o)&&(o=t.env.NODE_DEBUG||""),n=n.toUpperCase(),!a[n])if(new RegExp("\\\\b"+n+"\\\\b","i").test(o)){var r=t.pid;a[n]=function(){var t=e.format.apply(e,arguments);console.error("%s %d: %s",n,r,t)}}else a[n]=function(){};return a[n]},e.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},e.isArray=p,e.isBoolean=y,e.isNull=d,e.isNullOrUndefined=function(t){return null==t},e.isNumber=v,e.isString=m,e.isSymbol=function(t){return"symbol"==typeof t},e.isUndefined=g,e.isRegExp=b,e.isObject=x,e.isDate=w,e.isError=k,e.isFunction=_,e.isPrimitive=function(t){return null===t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||"symbol"==typeof t||void 0===t},e.isBuffer=n(93);var T=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function j(t,e){return Object.prototype.hasOwnProperty.call(t,e)}e.log=function(){var t,n;console.log("%s - %s",(t=new Date,n=[A(t.getHours()),A(t.getMinutes()),A(t.getSeconds())].join(":"),[t.getDate(),T[t.getMonth()],n].join(" ")),e.format.apply(e,arguments))},e.inherits=n(94),e._extend=function(t,e){if(!e||!x(e))return t;for(var n=Object.keys(e),r=n.length;r--;)t[n[r]]=e[n[r]];return t};var O="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function z(t,e){if(!t){var n=new Error("Promise was rejected with a falsy value");n.reason=t,t=n}return e(t)}e.promisify=function(t){if("function"!=typeof t)throw new TypeError(\'The "original" argument must be of type Function\');if(O&&t[O]){var e;if("function"!=typeof(e=t[O]))throw new TypeError(\'The "util.promisify.custom" argument must be of type Function\');return Object.defineProperty(e,O,{value:e,enumerable:!1,writable:!1,configurable:!0}),e}function e(){for(var e,n,r=new Promise(function(t,r){e=t,n=r}),i=[],o=0;o1)for(var n=1;n=n.length)throw new u("Array index out of bounds: ".concat(e," > ").concat(n.length,"."));if(e!==Math.floor(e))throw new u("Array index must be an integer, but found ".concat(e," instead."));return n[e]}},{key:"eachChild",value:function(t){t(this.index),t(this.input)}},{key:"possibleOutputs",value:function(){return[void 0]}}])&&r(e.prototype,n),i&&r(e,i),t}();t.exports=l},function(t,e,n){function r(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);eNumber.MAX_SAFE_INTEGER)return h.error("Branch labels must be integers no larger than ".concat(Number.MAX_SAFE_INTEGER,"."));if("number"==typeof g&&Math.floor(g)!==g)return h.error("Numeric branch labels must be integer values.");if(r){if(h.checkSubtype(r,a(g)))return null}else r=a(g);if(void 0!==s[String(g)])return h.error("Branch labels must be unique.");s[String(g)]=u.length}}catch(t){y=!0,d=t}finally{try{p||null==m.return||m.return()}finally{if(y)throw d}}var b=n.parse(f,l,i);if(!b)return null;i=i||b.type,u.push(b)}var x=n.parse(e[1],1,r);if(!x)return null;var w=n.parse(e[e.length-1],e.length-1,i);return w?(o(r&&i),new t(r,i,x,s,u,w)):null}}],(n=[{key:"evaluate",value:function(t){var e=this.input.evaluate(t);return(this.outputs[this.cases[e]]||this.otherwise).evaluate(t)}},{key:"eachChild",value:function(t){t(this.input),this.outputs.forEach(t),t(this.otherwise)}},{key:"possibleOutputs",value:function(){var t;return(t=[]).concat.apply(t,r(this.outputs.map(function(t){return t.possibleOutputs()}))).concat(this.otherwise.possibleOutputs())}}])&&i(e.prototype,n),s&&i(e,s),t}();t.exports=s},function(t,e,n){function r(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);ef?Math.pow(t,1/3):t/c+u}function d(t){return t>l?t*t*t:c*(t-u)}function v(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function m(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function g(t){var e=m(t.r),n=m(t.g),r=m(t.b),i=y((.4124564*e+.3575761*n+.1804375*r)/o),u=y((.2126729*e+.7151522*n+.072175*r)/a);return{l:116*u-16,a:500*(i-u),b:200*(u-y((.0193339*e+.119192*n+.9503041*r)/s)),alpha:t.a}}function b(t){var e=(t.l+16)/116,n=isNaN(t.a)?e:e+t.a/500,i=isNaN(t.b)?e:e-t.b/200;return e=a*d(e),n=o*d(n),i=s*d(i),new r(v(3.2404542*n-1.5371385*e-.4985314*i),v(-.969266*n+1.8760108*e+.041556*i),v(.0556434*n-.2040259*e+1.0572252*i),t.alpha)}function x(t,e,n){var r=e-t;return t+n*(r>180||r<-180?r-360*Math.round(r/360):r)}t.exports={lab:{forward:g,reverse:b,interpolate:function(t,e,n){return{l:i(t.l,e.l,n),a:i(t.a,e.a,n),b:i(t.b,e.b,n),alpha:i(t.alpha,e.alpha,n)}}},hcl:{forward:function(t){var e=g(t),n=e.l,r=e.a,i=e.b,o=Math.atan2(i,r)*p;return{h:o<0?o+360:o,c:Math.sqrt(r*r+i*i),l:n,alpha:t.a}},reverse:function(t){var e=t.h*h,n=t.c;return b({l:t.l,a:Math.cos(e)*n,b:Math.sin(e)*n,alpha:t.alpha})},interpolate:function(t,e,n){return{h:x(t.h,e.h,n),c:i(t.c,e.c,n),l:i(t.l,e.l,n),alpha:i(t.alpha,e.alpha,n)}}}}},function(t,e,n){function r(t,e){for(var n=0;n`."},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.0511,180,85.0511],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."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},"*":{type:"*",doc:"Other keys to configure the data source."}},source_raster:{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://`."},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.0511,180,85.0511],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."},"*":{type:"*",doc:"Other keys to configure the data source."}},source_raster_dem:{type:{required:!0,type:"enum",values:{"raster-dem":{doc:"A raster DEM source using Mapbox Terrain RGB"}},doc:"The type of the source."},url:{type:"string",doc:"A URL to a TileJSON resource. Supported protocols are `http:`, `https:`, and `mapbox://`."},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.0511,180,85.0511],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."},"*":{type:"*",doc:"Other keys to configure the data source."}},source_geojson:{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)."},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."},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."},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)."}},source_video:{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."}}},source_image:{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."}}},source_canvas:{type:{required:!0,type:"enum",values:{canvas:{doc:"A canvas data source."}},doc:"The data type of the canvas source."},coordinates:{required:!0,doc:"Corners of canvas specified in longitude, latitude pairs.",type:"array",length:4,value:{type:"array",length:2,value:"number",doc:"A single longitude, latitude pair."}},animate:{type:"boolean",default:"true",doc:"Whether the canvas source is animated. If the canvas is static, `animate` should be set to `false` to improve performance."},canvas:{type:"string",required:!0,doc:"HTML ID of the canvas from which to read pixels."}},layer:{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"}}},"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 tiles","sdk-support":{"basic functionality":{js:"0.43.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 \'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 on which the layer gets parsed and appears on."},maxzoom:{type:"number",minimum:0,maximum:24,doc:"The maximum zoom level on which the layer gets parsed and appears on."},filter:{type:"filter",doc:"A expression specifying conditions on source features. Only features that match the filter are displayed."},layout:{type:"layout",doc:"Layout properties for the layer."},paint:{type:"paint",doc:"Default paint properties for this layer."}},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:{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"}}}},layout_fill:{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"}}}},layout_circle:{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"}}}},layout_heatmap:{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"}}}},"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"}}}},layout_line:{"line-cap":{type:"enum",function:"piecewise-constant","zoom-function":!0,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":{}}},"line-join":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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"}}},"line-miter-limit":{type:"number",default:2,function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"line-round-limit":{type:"number",default:1.05,function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},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"},"data-driven styling":{}}}},layout_symbol:{"symbol-placement":{type:"enum",function:"piecewise-constant","zoom-function":!0,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."}},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"},"data-driven styling":{}}},"symbol-spacing":{type:"number",default:250,minimum:1,function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"symbol-avoid-edges":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}},"icon-allow-overlap":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"icon-ignore-placement":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"icon-optional":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"icon-rotation-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,values:{map:{doc:"When `symbol-placement` is set to `point`, aligns icons east-west. When `symbol-placement` is set to `line`, 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`, 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"},"data-driven styling":{}}},"icon-size":{type:"number",default:1,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-text-fit":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"icon-text-fit-padding":{type:"array",value:"number",length:4,default:[0,0,0,0],units:"pixels",function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"icon-image":{type:"string",function:"piecewise-constant","zoom-function":!0,"property-function":!0,doc:"Name of image in sprite to use for drawing an image background. Within literal values and zoom functions, property names enclosed in curly brackets (e.g. `{token}`) are replaced with the value of the named property. Expressions and property functions do not support this syntax; for equivalent functionality in expressions, use the [`concat`](#expressions-concat) and [`get`](#expressions-get) operators.",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"}}},"icon-rotate":{type:"number",default:0,period:360,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"icon-padding":{type:"number",default:2,minimum:0,function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"icon-keep-upright":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}},"icon-offset":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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"}}},"icon-pitch-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-pitch-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-rotation-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,values:{map:{doc:"When `symbol-placement` is set to `point`, aligns text east-west. When `symbol-placement` is set to `line`, 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`, 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"},"data-driven styling":{}}},"text-field":{type:"string",function:"piecewise-constant","zoom-function":!0,"property-function":!0,default:"",tokens:!0,doc:"Value to use for a text label. Within literal values and zoom functions, property names enclosed in curly brackets (e.g. `{token}`) are replaced with the value of the named property. Expressions and property functions do not support this syntax; for equivalent functionality in expressions, use the [`concat`](#expressions-concat) and [`get`](#expressions-get) operators.","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"}}},"text-font":{type:"array",value:"string",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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":{}}},"text-size":{type:"number",default:16,minimum:0,units:"pixels",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-max-width":{type:"number",default:10,minimum:0,units:"ems",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-line-height":{type:"number",default:1.2,units:"ems",function:"interpolated","zoom-function":!0,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":{}}},"text-letter-spacing":{type:"number",default:0,units:"ems",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-justify":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,values:{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"}}},"text-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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"],"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"}}},"text-max-angle":{type:"number",default:45,units:"degrees",function:"interpolated","zoom-function":!0,doc:"Maximum angle change between adjacent characters.",requires:["text-field",{"symbol-placement":"line"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}},"text-rotate":{type:"number",default:0,period:360,units:"degrees",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-padding":{type:"number",default:2,minimum:0,units:"pixels",function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"text-keep-upright":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}},"text-transform":{type:"enum",function:"piecewise-constant","zoom-function":!0,"property-function":!0,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"}}},"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.",value:"number",units:"ems",function:"interpolated","zoom-function":!0,"property-function":!0,length:2,default:[0,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.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},"text-allow-overlap":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-ignore-placement":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-optional":{type:"boolean",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},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"},"data-driven styling":{}}}},layout_raster:{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"},"data-driven styling":{}}}},layout_hillshade:{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"},"data-driven styling":{}}}},filter:{type:"array",value:"*",doc:"A filter selects specific features from a layer."},filter_operator:{type:"enum",values:{"==":{doc:\'`["==", key, value]` equality: `feature[key] = value`\'},"!=":{doc:\'`["!=", key, value]` inequality: `feature[key] \u2260 value`\'},">":{doc:\'`[">", key, value]` greater than: `feature[key] > value`\'},">=":{doc:\'`[">=", key, value]` greater than or equal: `feature[key] \u2265 value`\'},"<":{doc:\'`["<", key, value]` less than: `feature[key] < value`\'},"<=":{doc:\'`["<=", key, value]` less than or equal: `feature[key] \u2264 value`\'},in:{doc:\'`["in", key, v0, ..., vn]` set inclusion: `feature[key] \u2208 {v0, ..., vn}`\'},"!in":{doc:\'`["!in", key, v0, ..., vn]` set exclusion: `feature[key] \u2209 {v0, ..., vn}`\'},all:{doc:\'`["all", f0, ..., fn]` logical `AND`: `f0 \u2227 ... \u2227 fn`\'},any:{doc:\'`["any", f0, ..., fn]` logical `OR`: `f0 \u2228 ... \u2228 fn`\'},none:{doc:\'`["none", f0, ..., fn]` logical `NOR`: `\xACf0 \u2227 ... \u2227 \xACfn`\'},has:{doc:\'`["has", key]` `feature[key]` exists\'},"!has":{doc:\'`["!has", key]` `feature[key]` does not exist\'}},doc:"The filter operator."},geometry_type:{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."},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:\\n* In categorical functions, when the feature value does not match any of the stop domain values.\\n* In property and zoom-and-property functions, when a feature does not contain a value for the specified property.\\n* 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).\\n* In interval or exponential property and zoom-and-property functions, when the feature value is not numeric.\\nIf no default is provided, the style property\'s default is used in these circumstances."}},function_stop:{type:"array",minimum:0,maximum:22,value:["number","color"],length:2,doc:"Zoom level and value pair."},expression:{type:"array",value:"*",minimum:1,doc:"An expression defines a function that can be used for data-driven style properties or feature filters."},expression_name:{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"},var:{doc:\'References variable bound using "let".\',group:"Variable binding"},literal:{doc:"Provides a literal array or object value.",group:"Types"},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"},at:{doc:"Retrieves an item from an array.",group:"Lookup"},case:{doc:"Selects the first output whose corresponding test condition evaluates to true.",group:"Decision"},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 string or number expression (e.g. `["get", "building_type"]`). Each label can either be a single literal value or an array of values.\',group:"Decision"},coalesce:{doc:"Evaluates each expression in turn until the first non-null value is obtained, and returns that value.",group:"Decision"},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 input if the input is less than the first stop.\',group:"Ramps, scales, curves"},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`, 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"},ln2:{doc:"Returns mathematical constant ln(2).",group:"Math"},pi:{doc:"Returns the mathematical constant pi.",group:"Math"},e:{doc:"Returns the mathematical constant e.",group:"Math"},typeof:{doc:"Returns a string describing the type of the given value.",group:"Types"},string:{doc:"Asserts that the input value is a string. If multiple values are provided, each one is evaluated in order until a string value is obtained. If none of the inputs are strings, the expression is an error.",group:"Types"},number:{doc:"Asserts that the input value is a number. If multiple values are provided, each one is evaluated in order until a number value is obtained. If none of the inputs are numbers, the expression is an error.",group:"Types"},boolean:{doc:"Asserts that the input value is a boolean. If multiple values are provided, each one is evaluated in order until a boolean value is obtained. If none of the inputs are booleans, the expression is an error.",group:"Types"},object:{doc:"Asserts that the input value is an object. If it is not, the expression is an error.",group:"Types"},"to-string":{doc:\'Converts the input value to a string. If the input is `null`, the result is `"null"`. 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"},"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"},"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"},"to-rgba":{doc:"Returns a four-element array containing the input color\'s red, green, blue, and alpha components, in that order.",group:"Color"},"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"},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"},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"},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"},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"},length:{doc:"Gets the length of an array or string.",group:"Lookup"},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"},"geometry-type":{doc:"Gets the feature\'s geometry type: Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon.",group:"Feature data"},id:{doc:"Gets the feature\'s id, if it has one.",group:"Feature data"},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"},"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"},"+":{doc:"Returns the sum of the inputs.",group:"Math"},"*":{doc:"Returns the product of the inputs.",group:"Math"},"-":{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"},"/":{doc:"Returns the result of floating point division of the first input by the second.",group:"Math"},"%":{doc:"Returns the remainder after integer division of the first input by the second.",group:"Math"},"^":{doc:"Returns the result of raising the first input to the power specified by the second.",group:"Math"},sqrt:{doc:"Returns the square root of the input.",group:"Math"},log10:{doc:"Returns the base-ten logarithm of the input.",group:"Math"},ln:{doc:"Returns the natural logarithm of the input.",group:"Math"},log2:{doc:"Returns the base-two logarithm of the input.",group:"Math"},sin:{doc:"Returns the sine of the input.",group:"Math"},cos:{doc:"Returns the cosine of the input.",group:"Math"},tan:{doc:"Returns the tangent of the input.",group:"Math"},asin:{doc:"Returns the arcsine of the input.",group:"Math"},acos:{doc:"Returns the arccosine of the input.",group:"Math"},atan:{doc:"Returns the arctangent of the input.",group:"Math"},min:{doc:"Returns the minimum value of the inputs.",group:"Math"},max:{doc:"Returns the maximum value of the inputs.",group:"Math"},"==":{doc:"Returns `true` if the input values are equal, `false` otherwise. The inputs must be numbers, strings, or booleans, and both of the same type.",group:"Decision"},"!=":{doc:"Returns `true` if the input values are not equal, `false` otherwise. The inputs must be numbers, strings, or booleans, and both of the same type.",group:"Decision"},">":{doc:"Returns `true` if the first input is strictly greater than the second, `false` otherwise. The inputs must be numbers or strings, and both of the same type.",group:"Decision"},"<":{doc:"Returns `true` if the first input is strictly less than the second, `false` otherwise. The inputs must be numbers or strings, and both of the same type.",group:"Decision"},">=":{doc:"Returns `true` if the first input is greater than or equal to the second, `false` otherwise. The inputs must be numbers or strings, and both of the same type.",group:"Decision"},"<=":{doc:"Returns `true` if the first input is less than or equal to the second, `false` otherwise. The inputs must be numbers or strings, and both of the same type.",group:"Decision"},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"},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"},"!":{doc:"Logical negation. Returns `true` if the input is `false`, and `false` if the input is `true`.",group:"Decision"},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"},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"},concat:{doc:"Returns a string consisting of the concatenation of the inputs.",group:"String"}}},light:{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."}},transition:!1,"zoom-function":!0,"property-function":!1,function:"piecewise-constant",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",transition:!0,function:"interpolated","zoom-function":!0,"property-function":!1,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\xB0 (0\xB0 when `light.anchor` is set to `viewport` corresponds to the top of the viewport, or 0\xB0 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\xB0, directly above, to 180\xB0, 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",default:"#ffffff",function:"interpolated","zoom-function":!0,"property-function":!1,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",default:.5,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!1,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"}}}},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",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"fill-opacity":{type:"number",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"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.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"fill-outline-color":{type:"color",doc:"The outline color of the fill. Matches the value of `fill-color` if unspecified.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"fill-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"fill-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"fill-pattern":{type:"string",function:"piecewise-constant","zoom-function":!0,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).","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}}},"paint_fill-extrusion":{"fill-extrusion-opacity":{type:"number",function:"interpolated","zoom-function":!0,"property-function":!1,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"}}},"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.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"fill-extrusion-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"fill-extrusion-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"fill-extrusion-pattern":{type:"string",function:"piecewise-constant","zoom-function":!0,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).","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{}}},"fill-extrusion-height":{type:"number",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"fill-extrusion-base":{type:"number",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}}},paint_line:{"line-opacity":{type:"number",doc:"The opacity at which the line will be drawn.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"line-color":{type:"color",doc:"The color with which the line will be drawn.",default:"#000000",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"line-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"line-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"line-width":{type:"number",default:1,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"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.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"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.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"line-blur":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"line-dasharray":{type:"array",value:"number",function:"piecewise-constant","zoom-function":!0,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.",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":{}}},"line-pattern":{type:"string",function:"piecewise-constant","zoom-function":!0,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).","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}}}},paint_circle:{"circle-radius":{type:"number",default:5,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"circle-color":{type:"color",default:"#000000",doc:"The fill color of the circle.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"circle-blur":{type:"number",default:0,doc:"Amount to blur the circle. 1 blurs the circle such that only the centerpoint is full opacity.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"circle-opacity":{type:"number",doc:"The opacity at which the circle will be drawn.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"circle-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"circle-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"circle-pitch-scale":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"circle-pitch-alignment":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"circle-stroke-width":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"circle-stroke-color":{type:"color",default:"#000000",doc:"The stroke color of the circle.",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"circle-stroke-opacity":{type:"number",doc:"The opacity of the circle\'s stroke.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}}},paint_heatmap:{"heatmap-radius":{type:"number",default:30,minimum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"},"data-driven styling":{}}},"heatmap-weight":{type:"number",default:1,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"},"data-driven styling":{js:"0.41.0"}}},"heatmap-intensity":{type:"number",default:1,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!1,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"},"data-driven styling":{}}},"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.\',function:"interpolated","zoom-function":!1,"property-function":!1,transition:!1,"sdk-support":{"basic functionality":{js:"0.41.0"},"data-driven styling":{}}},"heatmap-opacity":{type:"number",doc:"The global opacity at which the heatmap layer will be drawn.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!1,transition:!0,"sdk-support":{"basic functionality":{js:"0.41.0"},"data-driven styling":{}}}},paint_symbol:{"icon-opacity":{doc:"The opacity at which the icon will be drawn.",type:"number",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"icon-color":{type:"color",default:"#000000",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"icon-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-halo-width":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-halo-blur":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"icon-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"icon-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}},"text-opacity":{type:"number",doc:"The opacity at which the text will be drawn.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-color":{type:"color",doc:"The color with which the text will be drawn.",default:"#000000",function:"interpolated","zoom-function":!0,"property-function":!0,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"}}},"text-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",function:"interpolated","zoom-function":!0,"property-function":!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"}}},"text-halo-width":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"text-halo-blur":{type:"number",default:0,minimum:0,function:"interpolated","zoom-function":!0,"property-function":!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"}}},"text-translate":{type:"array",value:"number",length:2,default:[0,0],function:"interpolated","zoom-function":!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"},"data-driven styling":{}}},"text-translate-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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"},"data-driven styling":{}}}},paint_raster:{"raster-opacity":{type:"number",doc:"The opacity at which the image will be drawn.",default:1,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,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":{}}},"raster-hue-rotate":{type:"number",default:0,period:360,function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"raster-brightness-min":{type:"number",function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"raster-brightness-max":{type:"number",function:"interpolated","zoom-function":!0,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"},"data-driven styling":{}}},"raster-saturation":{type:"number",doc:"Increase or reduce the saturation of the image.",default:0,minimum:-1,maximum:1,function:"interpolated","zoom-function":!0,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":{}}},"raster-contrast":{type:"number",doc:"Increase or reduce the contrast of the image.",default:0,minimum:-1,maximum:1,function:"interpolated","zoom-function":!0,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":{}}},"raster-fade-duration":{type:"number",default:300,minimum:0,function:"interpolated","zoom-function":!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"},"data-driven styling":{}}}},paint_hillshade:{"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`.",function:"interpolated","zoom-function":!0,transition:!1},"hillshade-illumination-anchor":{type:"enum",function:"piecewise-constant","zoom-function":!0,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."},"hillshade-exaggeration":{type:"number",doc:"Intensity of the hillshade",default:.5,minimum:0,maximum:1,function:"interpolated","zoom-function":!0,transition:!0},"hillshade-shadow-color":{type:"color",default:"#000000",doc:"The shading color of areas that face away from the light source.",function:"interpolated","zoom-function":!0,transition:!0},"hillshade-highlight-color":{type:"color",default:"#FFFFFF",doc:"The shading color of areas that faces towards the light source.",function:"interpolated","zoom-function":!0,transition:!0},"hillshade-accent-color":{type:"color",default:"#000000",doc:"The shading color used to accentuate rugged terrain like sharp cliffs and gorges.",function:"interpolated","zoom-function":!0,transition:!0}},paint_background:{"background-color":{type:"color",default:"#000000",doc:"The color with which the background will be drawn.",function:"interpolated","zoom-function":!0,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"}}},"background-pattern":{type:"string",function:"piecewise-constant","zoom-function":!0,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).","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},"background-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity at which the background will be drawn.",function:"interpolated","zoom-function":!0,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}}},transition:{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."}}}},function(t,e,n){t.exports=n(104),t.exports.emitErrors=function(t,e){if(e&&e.length){var n=!0,r=!1,i=void 0;try{for(var o,a=e[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var s=o.value.message;t.fire("error",{error:new Error(s)})}}catch(t){r=!0,i=t}finally{try{n||null==a.return||a.return()}finally{if(r)throw i}}return!0}return!1}},function(t,e,n){var r=n(64),i=n(16),o=n(8),a=n(107);function s(t,e){e=e||o;var n=[];return n=n.concat(i({key:"",value:t,valueSpec:e.$root,styleSpec:e,style:t,objectElementValidators:{glyphs:a,"*":function(){return[]}}})),t.constants&&(n=n.concat(r({key:"constants",value:t.constants,style:t,styleSpec:e}))),u(n)}function u(t){return[].concat(t).sort(function(t,e){return t.line-e.line})}function l(t){return function(){return u(t.apply(this,arguments))}}s.source=l(n(73)),s.light=l(n(74)),s.layer=l(n(69)),s.filter=l(n(38)),s.paintProperty=l(n(70)),s.layoutProperty=l(n(72)),t.exports=s},function(t,e,n){var r=n(7),i=n(5);t.exports=function(t){var e=t.value,n=t.key,o=r(e);return"boolean"!==o?[new i(n,e,"boolean expected, ".concat(o," found"))]:[]}},function(t,e,n){var r=n(5),i=n(7),o=n(49).parseCSSColor;t.exports=function(t){var e=t.key,n=t.value,a=i(n);return"string"!==a?[new r(e,n,"color expected, ".concat(a," found"))]:null===o(n)?[new r(e,n,\'color expected, "\'.concat(n,\'" found\'))]:[]}},function(t,e,n){var r=n(5),i=n(75);t.exports=function(t){var e=t.value,n=t.key,o=i(t);return o.length?o:(-1===e.indexOf("{fontstack}")&&o.push(new r(n,e,\'"glyphs" url must include a "{fontstack}" token\')),-1===e.indexOf("{range}")&&o.push(new r(n,e,\'"glyphs" url must include a "{range}" token\')),o)}},function(t,e,n){function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(t,e){for(var n=0;ne?1:0}return function(n,r,i,o,a){!function e(n,r,i,o,a){for(;o>i;){if(o-i>600){var s=o-i+1,u=r-i+1,l=Math.log(s),c=.5*Math.exp(2*l/3),f=.5*Math.sqrt(l*c*(s-c)/s)*(u-s/2<0?-1:1),h=Math.max(i,Math.floor(r-u*c/s+f)),p=Math.min(o,Math.floor(r+(s-u)*c/s+f));e(n,r,h,p,a)}var y=n[r],d=i,v=o;for(t(n,i,r),a(n[o],y)>0&&t(n,i,o);d0;)v--}0===a(n[i],y)?t(n,i,v):t(n,++v,o),v<=r&&(i=v+1),r<=v&&(o=v-1)}}(n,r,i||0,o||n.length-1,a||e)}}()},function(t,e,n){var r=n(8),i=n(1),o=i.Properties,a=i.DataConstantProperty,s=i.DataDrivenProperty,u=i.CrossFadedProperty,l=(i.HeatmapColorProperty,new o({"fill-antialias":new a(r.paint_fill["fill-antialias"]),"fill-opacity":new s(r.paint_fill["fill-opacity"]),"fill-color":new s(r.paint_fill["fill-color"]),"fill-outline-color":new s(r.paint_fill["fill-outline-color"]),"fill-translate":new a(r.paint_fill["fill-translate"]),"fill-translate-anchor":new a(r.paint_fill["fill-translate-anchor"]),"fill-pattern":new u(r.paint_fill["fill-pattern"])}));t.exports={paint:l}},function(t,e,n){function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(t,e){for(var n=0;n=1){var E=j[z-1];if(!x(P,E)){b.vertexLength+4>u&&(b=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray));var C=P.sub(E)._perp()._unit(),M=E.dist(P);O+M>32768&&(O=0),g(this.layoutVertexArray,P.x,P.y,C.x,C.y,0,0,O),g(this.layoutVertexArray,P.x,P.y,C.x,C.y,0,1,O),O+=M,g(this.layoutVertexArray,E.x,E.y,C.x,C.y,0,0,O),g(this.layoutVertexArray,E.x,E.y,C.x,C.y,0,1,O);var I=b.vertexLength;this.indexArray.emplaceBack(I,I+1,I+2),this.indexArray.emplaceBack(I+1,I+2,I+3),b.vertexLength+=4,b.primitiveLength+=2}}}}}catch(t){_=!0,S=t}finally{try{k||null==T.return||T.return()}finally{if(_)throw S}}b.vertexLength+l>u&&(b=this.segments.prepareSegment(l,this.layoutVertexArray,this.indexArray));var B=[],V=[],L=b.vertexLength,F=!0,R=!1,D=void 0;try{for(var q,N=s[Symbol.iterator]();!(F=(q=N.next()).done);F=!0){var U=q.value;if(0!==U.length){U!==s[0]&&V.push(B.length/2);for(var J=0;Jh)||t.y===e.y&&(t.y<0||t.y>h)}function w(t){return t.every(function(t){return t.x<0})||t.every(function(t){return t.x>h})||t.every(function(t){return t.y<0})||t.every(function(t){return t.y>h})}v("FillExtrusionBucket",b,{omit:["layers"]}),t.exports=b},function(t,e,n){var r=n(17).createLayout;t.exports=r([{name:"a_pos",components:2,type:"Int16"},{name:"a_normal_ed",components:4,type:"Int16"}],4)},function(t,e,n){var r=n(8),i=n(1),o=i.Properties,a=i.DataConstantProperty,s=i.DataDrivenProperty,u=i.CrossFadedProperty,l=(i.HeatmapColorProperty,new o({"fill-extrusion-opacity":new a(r["paint_fill-extrusion"]["fill-extrusion-opacity"]),"fill-extrusion-color":new s(r["paint_fill-extrusion"]["fill-extrusion-color"]),"fill-extrusion-translate":new a(r["paint_fill-extrusion"]["fill-extrusion-translate"]),"fill-extrusion-translate-anchor":new a(r["paint_fill-extrusion"]["fill-extrusion-translate-anchor"]),"fill-extrusion-pattern":new u(r["paint_fill-extrusion"]["fill-extrusion-pattern"]),"fill-extrusion-height":new s(r["paint_fill-extrusion"]["fill-extrusion-height"]),"fill-extrusion-base":new s(r["paint_fill-extrusion"]["fill-extrusion-base"])}));t.exports={paint:l}},function(t,e,n){function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){for(var n=0;n0?e+2*t:t}t.exports=T},function(t,e,n){function r(t,e){for(var n=0;n>6)}var g=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.zoom=e.zoom,this.overscaling=e.overscaling,this.layers=e.layers,this.layerIds=this.layers.map(function(t){return t.id}),this.index=e.index,this.layoutVertexArray=new i,this.indexArray=new u,this.programConfigurations=new s(o,e.layers,e.zoom),this.segments=new a}var e,n,h;return e=t,(n=[{key:"populate",value:function(t,e){var n=!0,r=!1,i=void 0;try{for(var o,a=t[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var s=o.value,u=s.feature,c=s.index,f=s.sourceLayerIndex;if(this.layers[0]._featureFilter({zoom:this.zoom},u)){var h=l(u);this.addFeature(u,h),e.featureIndex.insert(u,h,c,f,this.index)}}}catch(t){r=!0,i=t}finally{try{n||null==a.return||a.return()}finally{if(r)throw i}}}},{key:"isEmpty",value:function(){return 0===this.layoutVertexArray.length}},{key:"upload",value:function(t){this.layoutVertexBuffer=t.createVertexBuffer(this.layoutVertexArray,o),this.indexBuffer=t.createIndexBuffer(this.indexArray),this.programConfigurations.upload(t)}},{key:"destroy",value:function(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}},{key:"addFeature",value:function(t,e){var n=this.layers[0].layout,r=n.get("line-join").evaluate(t),i=n.get("line-cap"),o=n.get("line-miter-limit"),a=n.get("line-round-limit"),s=!0,u=!1,l=void 0;try{for(var c,f=e[Symbol.iterator]();!(s=(c=f.next()).done);s=!0){var h=c.value;this.addLine(h,t,r,i,o,a)}}catch(t){u=!0,l=t}finally{try{s||null==f.return||f.return()}finally{if(u)throw l}}}},{key:"addLine",value:function(t,e,n,r,i,o){for(var a="Polygon"===f[e.type],s=t.length;s>=2&&t[s-1].equals(t[s-2]);)s--;for(var u=0;uu){var P=d.dist(w);if(P>2*l){var E=d.sub(d.sub(w)._mult(l/P)._round());this.distance+=E.dist(w),this.addCurrentVertex(E,this.distance,_.mult(1),0,0,!1,p),w=E}}var C=w&&k,M=C?n:k?g:b;if(C&&"round"===M&&(Oi&&(M="bevel"),"bevel"===M&&(O>2&&(M="flipbevel"),O100)T=S.clone().mult(-1);else{var I=_.x*S.y-_.y*S.x>0?-1:1,B=O*_.add(S).mag()/_.sub(S).mag();T._perp()._mult(B*I)}this.addCurrentVertex(d,this.distance,T,0,0,!1,p),this.addCurrentVertex(d,this.distance,T.mult(-1),0,0,!1,p)}else if("bevel"===M||"fakeround"===M){var V=_.x*S.y-_.y*S.x>0,L=-Math.sqrt(O*O-1);if(V?(m=0,v=L):(v=0,m=L),x||this.addCurrentVertex(d,this.distance,_,v,m,!1,p),"fakeround"===M){for(var F=Math.floor(8*(.5-(j-.5))),R=void 0,D=0;D=0;q--)R=_.mult((q+1)/(F+1))._add(S)._unit(),this.addPieSliceVertex(d,this.distance,R,V,p)}k&&this.addCurrentVertex(d,this.distance,S,-v,-m,!1,p)}else"butt"===M?(x||this.addCurrentVertex(d,this.distance,_,0,0,!1,p),k&&this.addCurrentVertex(d,this.distance,S,0,0,!1,p)):"square"===M?(x||(this.addCurrentVertex(d,this.distance,_,1,1,!1,p),this.e1=this.e2=-1),k&&this.addCurrentVertex(d,this.distance,S,-1,-1,!1,p)):"round"===M&&(x||(this.addCurrentVertex(d,this.distance,_,0,0,!1,p),this.addCurrentVertex(d,this.distance,_,1,1,!0,p),this.e1=this.e2=-1),k&&(this.addCurrentVertex(d,this.distance,S,-1,-1,!0,p),this.addCurrentVertex(d,this.distance,S,0,0,!1,p)));if(z&&A2*l){var U=d.add(k.sub(d)._mult(l/N)._round());this.distance+=U.dist(d),this.addCurrentVertex(U,this.distance,S.mult(1),0,0,!1,p),d=U}}x=!1}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,e)}}},{key:"addCurrentVertex",value:function(t,e,n,r,i,o,a){var s,u=this.layoutVertexArray,l=this.indexArray;s=n.clone(),r&&s._sub(n.perp()._mult(r)),m(u,t,s,o,!1,r,e),this.e3=a.vertexLength++,this.e1>=0&&this.e2>=0&&(l.emplaceBack(this.e1,this.e2,this.e3),a.primitiveLength++),this.e1=this.e2,this.e2=this.e3,s=n.mult(-1),i&&s._sub(n.perp()._mult(i)),m(u,t,s,o,!0,-i,e),this.e3=a.vertexLength++,this.e1>=0&&this.e2>=0&&(l.emplaceBack(this.e1,this.e2,this.e3),a.primitiveLength++),this.e1=this.e2,this.e2=this.e3,e>v/2&&(this.distance=0,this.addCurrentVertex(t,this.distance,n,r,i,o,a))}},{key:"addPieSliceVertex",value:function(t,e,n,r,i){n=n.mult(r?-1:1);var o=this.layoutVertexArray,a=this.indexArray;m(o,t,n,!1,r,0,e),this.e3=i.vertexLength++,this.e1>=0&&this.e2>=0&&(a.emplaceBack(this.e1,this.e2,this.e3),i.primitiveLength++),r?this.e2=this.e3:this.e1=this.e3}}])&&r(e.prototype,n),h&&r(e,h),t}();h("LineBucket",g,{omit:["layers"]}),t.exports=g},function(t,e,n){var r=n(17).createLayout;t.exports=r([{name:"a_pos_normal",components:4,type:"Int16"},{name:"a_data",components:4,type:"Uint8"}],4)},function(t,e,n){"use strict";var r=n(79);function i(t,e,n){if(3===t){var i=new r(n,n.readVarint()+n.pos);i.length&&(e[i.name]=i)}}t.exports=function(t,e){this.layers=t.readFields(i,{},e)}},function(t,e,n){var r=n(8),i=n(1),o=i.Properties,a=i.DataConstantProperty,s=i.DataDrivenProperty,u=i.CrossFadedProperty,l=(i.HeatmapColorProperty,new o({"line-cap":new a(r.layout_line["line-cap"]),"line-join":new s(r.layout_line["line-join"]),"line-miter-limit":new a(r.layout_line["line-miter-limit"]),"line-round-limit":new a(r.layout_line["line-round-limit"])})),c=new o({"line-opacity":new s(r.paint_line["line-opacity"]),"line-color":new s(r.paint_line["line-color"]),"line-translate":new a(r.paint_line["line-translate"]),"line-translate-anchor":new a(r.paint_line["line-translate-anchor"]),"line-width":new s(r.paint_line["line-width"]),"line-gap-width":new s(r.paint_line["line-gap-width"]),"line-offset":new s(r.paint_line["line-offset"]),"line-blur":new s(r.paint_line["line-blur"]),"line-dasharray":new u(r.paint_line["line-dasharray"]),"line-pattern":new u(r.paint_line["line-pattern"])});t.exports={paint:c,layout:l}},function(t,e){function n(t,e){for(var n=0;nn?(this.lastIntegerZoom=n+1,this.lastIntegerZoomTime=e):this.lastFloorZoom=128&&t<=255},Arabic:function(t){return t>=1536&&t<=1791},"Arabic Supplement":function(t){return t>=1872&&t<=1919},"Arabic Extended-A":function(t){return t>=2208&&t<=2303},"Hangul Jamo":function(t){return t>=4352&&t<=4607},"Unified Canadian Aboriginal Syllabics":function(t){return t>=5120&&t<=5759},"Unified Canadian Aboriginal Syllabics Extended":function(t){return t>=6320&&t<=6399},"General Punctuation":function(t){return t>=8192&&t<=8303},"Letterlike Symbols":function(t){return t>=8448&&t<=8527},"Number Forms":function(t){return t>=8528&&t<=8591},"Miscellaneous Technical":function(t){return t>=8960&&t<=9215},"Control Pictures":function(t){return t>=9216&&t<=9279},"Optical Character Recognition":function(t){return t>=9280&&t<=9311},"Enclosed Alphanumerics":function(t){return t>=9312&&t<=9471},"Geometric Shapes":function(t){return t>=9632&&t<=9727},"Miscellaneous Symbols":function(t){return t>=9728&&t<=9983},"Miscellaneous Symbols and Arrows":function(t){return t>=11008&&t<=11263},"CJK Radicals Supplement":function(t){return t>=11904&&t<=12031},"Kangxi Radicals":function(t){return t>=12032&&t<=12255},"Ideographic Description Characters":function(t){return t>=12272&&t<=12287},"CJK Symbols and Punctuation":function(t){return t>=12288&&t<=12351},Hiragana:function(t){return t>=12352&&t<=12447},Katakana:function(t){return t>=12448&&t<=12543},Bopomofo:function(t){return t>=12544&&t<=12591},"Hangul Compatibility Jamo":function(t){return t>=12592&&t<=12687},Kanbun:function(t){return t>=12688&&t<=12703},"Bopomofo Extended":function(t){return t>=12704&&t<=12735},"CJK Strokes":function(t){return t>=12736&&t<=12783},"Katakana Phonetic Extensions":function(t){return t>=12784&&t<=12799},"Enclosed CJK Letters and Months":function(t){return t>=12800&&t<=13055},"CJK Compatibility":function(t){return t>=13056&&t<=13311},"CJK Unified Ideographs Extension A":function(t){return t>=13312&&t<=19903},"Yijing Hexagram Symbols":function(t){return t>=19904&&t<=19967},"CJK Unified Ideographs":function(t){return t>=19968&&t<=40959},"Yi Syllables":function(t){return t>=40960&&t<=42127},"Yi Radicals":function(t){return t>=42128&&t<=42191},"Hangul Jamo Extended-A":function(t){return t>=43360&&t<=43391},"Hangul Syllables":function(t){return t>=44032&&t<=55215},"Hangul Jamo Extended-B":function(t){return t>=55216&&t<=55295},"Private Use Area":function(t){return t>=57344&&t<=63743},"CJK Compatibility Ideographs":function(t){return t>=63744&&t<=64255},"Arabic Presentation Forms-A":function(t){return t>=64336&&t<=65023},"Vertical Forms":function(t){return t>=65040&&t<=65055},"CJK Compatibility Forms":function(t){return t>=65072&&t<=65103},"Small Form Variants":function(t){return t>=65104&&t<=65135},"Arabic Presentation Forms-B":function(t){return t>=65136&&t<=65279},"Halfwidth and Fullwidth Forms":function(t){return t>=65280&&t<=65519}}},function(t,e,n){var r=n(14).normalizePropertyExpression,i=n(19),o=n(2);t.exports={getSizeData:function(t,e){var n=e.expression;if("constant"===n.kind)return{functionType:"constant",layoutSize:n.evaluate({zoom:t+1})};if("source"===n.kind)return{functionType:"source"};for(var r=n.zoomStops,i=0;i>1,c=-7,f=n?i-1:0,h=n?-1:1,p=t[e+f];for(f+=h,o=p&(1<<-c)-1,p>>=-c,c+=s;c>0;o=256*o+t[e+f],f+=h,c-=8);for(a=o&(1<<-c)-1,o>>=-c,c+=r;c>0;a=256*a+t[e+f],f+=h,c-=8);if(0===o)o=1-l;else{if(o===u)return a?NaN:1/0*(p?-1:1);a+=Math.pow(2,r),o-=l}return(p?-1:1)*a*Math.pow(2,o-r)},e.write=function(t,e,n,r,i,o){var a,s,u,l=8*o-i-1,c=(1<>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:o-1,y=r?1:-1,d=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,a=c):(a=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-a))<1&&(a--,u*=2),(e+=a+f>=1?h/u:h*Math.pow(2,1-f))*u>=2&&(a++,u/=2),a+f>=c?(s=0,a=c):a+f>=1?(s=(e*u-1)*Math.pow(2,i),a+=f):(s=e*Math.pow(2,f-1)*Math.pow(2,i),a=0));i>=8;t[n+p]=255&s,p+=y,s/=256,i-=8);for(a=a<0;t[n+p]=255&a,p+=y,a/=256,l-=8);t[n+p-y]|=128*d}},function(t,e,n){function r(t,e){for(var n=0;n=B.maxzoom))if("none"!==B.visibility)v(I,this.zoom),(x[B.id]=B.createBucket({index:d.bucketLayerIDs.length,layers:I,zoom:this.zoom,pixelRatio:this.pixelRatio,overscaling:this.overscaling,collisionBoxArray:this.collisionBoxArray})).populate(T,w),d.bucketLayerIDs.push(I.map(function(t){return t.id}))}}catch(t){P=!0,E=t}finally{try{z||null==M.return||M.return()}finally{if(P)throw E}}}}var V=l.mapObject(w.glyphDependencies,function(t){return Object.keys(t).map(Number)});Object.keys(V).length?n.send("getGlyphs",{uid:this.uid,stacks:V},function(t,e){m||(m=t,g=e,F.call(p))}):g={};var L=Object.keys(w.iconDependencies);function F(){if(m)return r(m);if(g&&b){var t=h(g),e=f(b);for(var n in x){var i=x[n];i instanceof u&&(v(i.layers,this.zoom),o(i,g,t.positions,b,e.positions,this.showCollisionBoxes))}this.status="done",r(null,{buckets:l.values(x).filter(function(t){return!t.isEmpty()}),featureIndex:d,collisionBoxArray:this.collisionBoxArray,glyphAtlasImage:t.image,iconAtlasImage:e.image})}}L.length?n.send("getImages",{icons:L},function(t,e){m||(m=t,b=e,F.call(p))}):b={},F.call(this)}}])&&r(e.prototype,n),p&&r(e,p),t}();function v(t,e){var n=new p(e),r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){a.value.recalculate(n)}}catch(t){i=!0,o=t}finally{try{r||null==s.return||s.return()}finally{if(i)throw o}}}t.exports=d},function(t,e,n){function r(t,e){for(var n=0;n=b||i.y<0||i.y>=b||t.symbolInstances.push(function(t,e,n,r,i,o,s,u,l,f,h,v,m,g,b,w,k,S,A,T,j,O){var z,P,E=t.addToLineVertexArray(e,n),C=0,M=0,I=0,B=r.horizontal?r.horizontal.text:"",V=[];r.horizontal&&(z=new y(s,n,e,u,l,f,r.horizontal,h,v,m,t.overscaling),M+=_(t,e,r.horizontal,o,m,A,T,g,E,r.vertical?c.horizontal:c.horizontalOnly,V,j,O),r.vertical&&(I+=_(t,e,r.vertical,o,m,A,T,g,E,c.vertical,V,j,O)));var L=z?z.boxStartIndex:t.collisionBoxArray.length,F=z?z.boxEndIndex:t.collisionBoxArray.length;if(i){var R=p(e,i,o,k,r.horizontal,A,T);P=new y(s,n,e,u,l,f,i,b,w,!1,t.overscaling),C=4*R.length;var D=t.iconSizeData,q=null;"source"===D.functionType?q=[10*o.layout.get("icon-size").evaluate(T)]:"composite"===D.functionType&&(q=[10*O.compositeIconSizes[0].evaluate(T),10*O.compositeIconSizes[1].evaluate(T)]),t.addSymbols(t.icon,R,q,S,k,T,!1,e,E.lineStartIndex,E.lineLength)}var N=P?P.boxStartIndex:t.collisionBoxArray.length,U=P?P.boxEndIndex:t.collisionBoxArray.length;t.glyphOffsetArray.length>=x.MAX_GLYPHS&&d.warnOnce("Too many glyphs being rendered in a tile. See https://github.com/mapbox/mapbox-gl-js/issues/2907");var J=new a,G=new a;return{key:B,textBoxStartIndex:L,textBoxEndIndex:F,iconBoxStartIndex:N,iconBoxEndIndex:U,textOffset:g,iconOffset:S,anchor:e,line:n,featureIndex:u,feature:T,numGlyphVertices:M,numVerticalGlyphVertices:I,numIconVertices:C,textOpacityState:J,iconOpacityState:G,isDuplicate:!1,placedTextSymbolIndices:V,crossTileID:0}}(t,i,r,n,s,t.layers[0],t.collisionBoxArray,e.index,e.sourceLayerIndex,t.index,j,E,I,k,z,C,B,A,{zoom:t.zoom},e,u,l))};if("line"===w.get("symbol-placement")){var F=!0,R=!1,D=void 0;try{for(var q,N=o(e.geometry,0,0,b,b)[Symbol.iterator]();!(F=(q=N.next()).done);F=!0){var U=q.value,J=i(U,P,M,n.vertical||n.horizontal,s,24,O,t.overscaling,b),G=!0,Z=!1,H=void 0;try{for(var W,Y=J[Symbol.iterator]();!(G=(W=Y.next()).done);G=!0){var K=W.value,X=n.horizontal;X&&S(t,X.text,V,K)||L(U,K)}}catch(t){Z=!0,H=t}finally{try{G||null==Y.return||Y.return()}finally{if(Z)throw H}}}}catch(t){R=!0,D=t}finally{try{F||null==N.return||N.return()}finally{if(R)throw D}}}else if("Polygon"===e.type){var $=!0,Q=!1,tt=void 0;try{for(var et,nt=g(e.geometry,0)[Symbol.iterator]();!($=(et=nt.next()).done);$=!0){var rt=et.value,it=m(rt,16);L(rt[0],new r(it.x,it.y,0))}}catch(t){Q=!0,tt=t}finally{try{$||null==nt.return||nt.return()}finally{if(Q)throw tt}}}else if("LineString"===e.type){var ot=!0,at=!1,st=void 0;try{for(var ut,lt=e.geometry[Symbol.iterator]();!(ot=(ut=lt.next()).done);ot=!0){var ct=ut.value;L(ct,new r(ct[0].x,ct[0].y,0))}}catch(t){at=!0,st=t}finally{try{ot||null==lt.return||lt.return()}finally{if(at)throw st}}}else if("Point"===e.type){var ft=!0,ht=!1,pt=void 0;try{for(var yt,dt=e.geometry[Symbol.iterator]();!(ft=(yt=dt.next()).done);ft=!0){var vt=yt.value,mt=!0,gt=!1,bt=void 0;try{for(var xt,wt=vt[Symbol.iterator]();!(mt=(xt=wt.next()).done);mt=!0){var kt=xt.value;L([kt],new r(kt.x,kt.y,0))}}catch(t){gt=!0,bt=t}finally{try{mt||null==wt.return||wt.return()}finally{if(gt)throw bt}}}}catch(t){ht=!0,pt=t}finally{try{ft||null==dt.return||dt.return()}finally{if(ht)throw pt}}}}function _(t,e,n,r,i,o,a,s,u,l,c,f,p){var y=h(e,n,r,i,o,a,f),d=t.textSizeData,v=null;return"source"===d.functionType?v=[10*r.layout.get("text-size").evaluate(a)]:"composite"===d.functionType&&(v=[10*p.compositeTextSizes[0].evaluate(a),10*p.compositeTextSizes[1].evaluate(a)]),t.addSymbols(t.text,y,v,s,i,a,l,e,u.lineStartIndex,u.lineLength),c.push(t.text.placedSymbolArray.length-1),4*y.length}function S(t,e,n,r){var i=t.compareText;if(e in i){for(var o=i[e],a=o.length-1;a>=0;a--)if(r.dist(o[a])=0&&A=0&&T=0&&m+p<=y){var j=new i(A,T,_,b);j._round(),s&&!o(e,j,l,s,u)||g.push(j)}}v+=k}f||g.length||c||(g=t(e,v/2,a,s,u,l,c,!0,h));return g}(t,y?e/2*c%e:(p/2+d)*l*c%e,e,h,n,p*l,y,!1,f)}},function(t,e){t.exports=function(t,e,n,r,i){if(void 0===e.segment)return!0;var o=e,a=e.segment+1,s=0;for(;s>-n/2;){if(--a<0)return!1;s-=t[a].dist(o),o=t[a]}s+=t[a].dist(t[a+1]),a++;var u=[],l=0;for(;sr;)l-=u.shift().angleDelta;if(l>i)return!1;a++,s+=f.dist(h)}return!0}},function(t,e,n){var r=n(6);t.exports=function(t,e,n,i,o){for(var a=[],s=0;s=i&&h.x>=i||(f.x>=i?f=new r(i,f.y+(h.y-f.y)*((i-f.x)/(h.x-f.x)))._round():h.x>=i&&(h=new r(i,f.y+(h.y-f.y)*((i-f.x)/(h.x-f.x)))._round()),f.y>=o&&h.y>=o||(f.y>=o?f=new r(f.x+(h.x-f.x)*((o-f.y)/(h.y-f.y)),o)._round():h.y>=o&&(h=new r(f.x+(h.x-f.x)*((o-f.y)/(h.y-f.y)),o)._round()),l&&f.equals(l[l.length-1])||(l=[f],a.push(l)),l.push(h)))))}return a}},function(t,e,n){function r(t,e){for(var n=0;n0&&(v=Math.max(10*u,v),this._addLineCollisionCircles(e,n,r,r.segment,m,v,i,o,a,f))}else e.emplaceBack(r.x,r.y,y,h,d,p,i,o,a,0,0);this.boxEndIndex=e.length}var e,r,i;return e=t,(r=[{key:"_addLineCollisionCircles",value:function(t,e,n,r,i,o,a,s,u,l){var c=o/2,f=Math.floor(i/c),h=1+.4*Math.log(l)/Math.LN2,p=Math.floor(f*h/2),y=-o/2,d=n,v=r+1,m=y,g=-i/2,b=g-i/4;do{if(--v<0){if(m>g)return;v=0;break}m-=e[v].dist(d),d=e[v]}while(m>b);for(var x=e[v].dist(e[v+1]),w=-p;wi&&(_+=k-i),!(_=e.length)return;x=e[v].dist(e[v+1])}var S=_-m,A=e[v],T=e[v+1].sub(A)._unit()._mult(S)._add(A)._round(),j=Math.abs(_-y)t.y!=f.y>t.y&&t.x<(f.x-c.x)*(t.y-c.y)/(f.y-c.y)+c.x&&(n=!n),r=Math.min(r,o(t,c,f))}return(n?1:-1)*Math.sqrt(r)}(this.p,r),this.max=this.d+this.h*Math.SQRT2}t.exports=function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],o=1/0,u=1/0,l=-1/0,c=-1/0,f=t[0],h=0;hl)&&(l=p.x),(!h||p.y>c)&&(c=p.y)}var y=l-o,d=c-u,v=Math.min(y,d),m=v/2,g=new r(null,a);if(0===v)return new i(o,u);for(var b=o;bw.d||!w.d)&&(w=_,n&&console.log("found best %d after %d probes",Math.round(1e4*_.d)/1e4,k)),_.max-w.d<=e||(m=_.h/2,g.push(new s(_.p.x-m,_.p.y-m,m,t)),g.push(new s(_.p.x+m,_.p.y-m,m,t)),g.push(new s(_.p.x-m,_.p.y+m,m,t)),g.push(new s(_.p.x+m,_.p.y+m,m,t)),k+=4)}return n&&(console.log("num probes: ".concat(k)),console.log("best distance: ".concat(w.d))),w.p}},function(t,e,n){"use strict";function r(t,e){if(!(this instanceof r))return new r(t,e);if(this.data=t||[],this.length=this.data.length,this.compare=e||i,this.length>0)for(var n=(this.length>>1)-1;n>=0;n--)this._down(n)}function i(t,e){return te?1:0}t.exports=r,t.exports.default=r,r.prototype={push:function(t){this.data.push(t),this.length++,this._up(this.length-1)},pop:function(){if(0!==this.length){var t=this.data[0];return this.length--,this.length>0&&(this.data[0]=this.data[this.length],this._down(0)),this.data.pop(),t}},peek:function(){return this.data[0]},_up:function(t){for(var e=this.data,n=this.compare,r=e[t];t>0;){var i=t-1>>1,o=e[i];if(n(r,o)>=0)break;e[t]=o,t=i}e[t]=r},_down:function(t){for(var e=this.data,n=this.compare,r=this.length>>1,i=e[t];t=0)break;e[t]=s,t=o}e[t]=i}}},function(t,e,n){var r=n(85),i=n(29).RGBAImage,o=1;function a(t,e){var n=e.pixelRatio,r={x:t.x+o,y:t.y+o,w:t.w-2*o,h:t.h-2*o};return{pixelRatio:n,textureRect:r,tl:[r.x,r.y],br:[r.x+r.w,r.y+r.h],displaySize:[r.w/n,r.h/n]}}t.exports={imagePosition:a,makeImageAtlas:function(t){var e=new i({width:0,height:0}),n={},s=new r(0,0,{autoResize:!0});for(var u in t){var l=t[u],c=s.packOne(l.data.width+2*o,l.data.height+2*o);e.resize({width:s.w,height:s.h}),i.copy(l.data,e,{x:0,y:0},{x:c.x+o,y:c.y+o},l.data),n[u]=a(c,l)}return s.shrink(),e.resize({width:s.w,height:s.h}),{image:e,positions:n}}}},function(t,e,n){var r=n(85),i=n(29).AlphaImage,o=1;t.exports={makeGlyphAtlas:function(t){var e=new i({width:0,height:0}),n={},a=new r(0,0,{autoResize:!0});for(var s in t){var u=t[s],l=n[s]={};for(var c in u){var f=u[+c];if(f&&0!==f.bitmap.width&&0!==f.bitmap.height){var h=a.packOne(f.bitmap.width+2*o,f.bitmap.height+2*o);e.resize({width:a.w,height:a.h}),i.copy(f.bitmap,e,{x:0,y:0},{x:h.x+o,y:h.y+o},f.bitmap),l[c]={rect:h,metrics:f.metrics}}}}return a.shrink(),e.resize({width:a.w,height:a.h}),{image:e,positions:n}}}},function(t,e,n){function r(t,e){for(var n=0;n=this.dim+this.border||e<-this.border||e>=this.dim+this.border)throw new RangeError("out of range source coordinates for DEM data");return(e+this.border)*this.stride+(t+this.border)}}]),t}();u("Level",l);var c=function(){function t(e,n,i){r(this,t),this.uid=e,this.scale=n||1,this.level=i||new l(256,512),this.loaded=!!i}return o(t,[{key:"loadFromImage",value:function(t){if(t.height!==t.width)throw new RangeError("DEM tiles must be square");for(var e=this.level=new l(t.width,t.width/2),n=t.data,r=0;r=0}(t)===e?t:t.reverse()}t.exports=function t(e,n){switch(e&&e.type||null){case"FeatureCollection":return e.features=e.features.map(i(t,n)),e;case"Feature":return e.geometry=t(e.geometry,n),e;case"Polygon":case"MultiPolygon":return function(t,e){"Polygon"===t.type?t.coordinates=o(t.coordinates,e):"MultiPolygon"===t.type&&(t.coordinates=t.coordinates.map(i(o,e)));return t}(e,n);default:return e}}},function(t,e,n){var r=n(169);function i(t){var e=0;if(t&&t.length>0){e+=Math.abs(o(t[0]));for(var n=1;n2){for(u=0;u>31}function f(t,e){for(var n=t.loadGeometry(),r=t.type,i=0,o=0,a=n.length,s=0;s=1e4?Math.round(e/1e3)+"k":e>=1e3?Math.round(e/100)/10+"k":e;return f(f({},t.properties),{cluster:!0,cluster_id:t.id,point_count:e,point_count_abbreviated:n})}function l(t){return t/360+.5}function c(t){var e=Math.sin(t*Math.PI/180),n=.5-.25*Math.log((1+e)/(1-e))/Math.PI;return n<0?0:n>1?1:n}function f(t,e){for(var n in e)t[n]=e[n];return t}function h(t){return t.x}function p(t){return t.y}t.exports=function(t){return new i(t)},i.prototype={options:{minZoom:0,maxZoom:16,radius:40,extent:512,nodeSize:64,log:!1,reduce:null,initial:function(){return{}},map:function(t){return t}},load:function(t){var e=this.options.log;e&&console.time("total time");var n="prepare "+t.length+" points";e&&console.time(n),this.points=t;var i=t.map(a);e&&console.timeEnd(n);for(var o=this.options.maxZoom;o>=this.options.minZoom;o--){var s=+Date.now();this.trees[o+1]=r(i,h,p,this.options.nodeSize,Float32Array),i=this._cluster(i,o),e&&console.log("z%d: %d clusters in %dms",o,i.length,+Date.now()-s)}return this.trees[this.options.minZoom]=r(i,h,p,this.options.nodeSize,Float32Array),e&&console.timeEnd("total time"),this},getClusters:function(t,e){for(var n=this.trees[this._limitZoom(e)],r=n.range(l(t[0]),c(t[3]),l(t[2]),c(t[1])),i=[],o=0;oo;){if(a-o>600){var u=a-o+1,l=i-o+1,c=Math.log(u),f=.5*Math.exp(2*c/3),h=.5*Math.sqrt(c*f*(u-f)/u)*(l-u/2<0?-1:1),p=Math.max(o,Math.floor(i-l*f/u+h)),y=Math.min(a,Math.floor(i+(u-l)*f/u+h));t(e,n,i,p,y,s)}var d=n[2*i+s],v=o,m=a;for(r(e,n,o,i),n[2*a+s]>d&&r(e,n,o,a);vd;)m--}n[2*o+s]===d?r(e,n,o,m):r(e,n,++m,a),m<=i&&(o=m+1),i<=m&&(a=m-1)}}(e,n,u,o,a,s%2);t(e,n,i,o,u-1,s+1);t(e,n,i,u+1,a,s+1)}},function(t,e,n){"use strict";t.exports=function(t,e,n,r,i,o,a){var s,u,l=[0,t.length-1,0],c=[];for(;l.length;){var f=l.pop(),h=l.pop(),p=l.pop();if(h-p<=a)for(var y=p;y<=h;y++)s=e[2*y],u=e[2*y+1],s>=n&&s<=i&&u>=r&&u<=o&&c.push(t[y]);else{var d=Math.floor((p+h)/2);s=e[2*d],u=e[2*d+1],s>=n&&s<=i&&u>=r&&u<=o&&c.push(t[d]);var v=(f+1)%2;(0===f?n<=s:r<=u)&&(l.push(p),l.push(d-1),l.push(v)),(0===f?i>=s:o>=u)&&(l.push(d+1),l.push(h),l.push(v))}}return c}},function(t,e,n){"use strict";function r(t,e,n,r){var i=t-n,o=e-r;return i*i+o*o}t.exports=function(t,e,n,i,o,a){var s=[0,t.length-1,0],u=[],l=o*o;for(;s.length;){var c=s.pop(),f=s.pop(),h=s.pop();if(f-h<=a)for(var p=h;p<=f;p++)r(e[2*p],e[2*p+1],n,i)<=l&&u.push(t[p]);else{var y=Math.floor((h+f)/2),d=e[2*y],v=e[2*y+1];r(d,v,n,i)<=l&&u.push(t[y]);var m=(c+1)%2;(0===c?n-o<=d:i-o<=v)&&(s.push(h),s.push(y-1),s.push(m)),(0===c?n+o>=d:i+o>=v)&&(s.push(y+1),s.push(f),s.push(m))}}return u}},function(t,e,n){"use strict";function r(t,e,n,r,i,o){var a=i-n,s=o-r;if(0!==a||0!==s){var u=((t-n)*a+(e-r)*s)/(a*a+s*s);u>1?(n=i,r=o):u>0&&(n+=a*u,r+=s*u)}return(a=t-n)*a+(s=e-r)*s}function i(t,e,n,r){var i={id:void 0===t?null:t,type:e,geometry:n,tags:r,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0};return function(t){var e=t.geometry,n=t.type;if("Point"===n||"MultiPoint"===n||"LineString"===n)o(t,e);else if("Polygon"===n||"MultiLineString"===n)for(var r=0;r0&&(s+=i?(o*h-l*a)/2:Math.sqrt(Math.pow(l-o,2)+Math.pow(h-a,2))),o=l,a=h}var p=e.length-3;e[2]=1,function t(e,n,i,o){for(var a,s=o,u=i-n>>1,l=i-n,c=e[n],f=e[n+1],h=e[i],p=e[i+1],y=n+3;ys)a=y,s=d;else if(d===s){var v=Math.abs(y-u);vo&&(a-n>3&&t(e,n,a,o),e[a+2]=s,i-a>3&&t(e,a,i,o))}(e,0,p,n),e[p+2]=1,e.size=Math.abs(s),e.start=0,e.end=e.size}function l(t,e,n,r){for(var i=0;i1?1:n}function h(t,e,n,r,o,a,s,u){if(r/=e,a>=(n/=e)&&s=r)return null;for(var l=[],c=0;c=n&&g=r)){var b=[];if("Point"===d||"MultiPoint"===d)p(h,b,n,r,o);else if("LineString"===d)y(h,b,n,r,o,!1,u.lineMetrics);else if("MultiLineString"===d)v(h,b,n,r,o,!1);else if("Polygon"===d)v(h,b,n,r,o,!0);else if("MultiPolygon"===d)for(var x=0;x=n&&a<=r&&(e.push(t[o]),e.push(t[o+1]),e.push(t[o+2]))}}function y(t,e,n,r,i,o,a){for(var s,u,l=d(t),c=0===i?g:b,f=t.start,h=0;hn&&(u=c(l,p,y,x,w,n),a&&(l.start=f+s*u)):k>r?_=n&&(u=c(l,p,y,x,w,n),S=!0),_>r&&k<=r&&(u=c(l,p,y,x,w,r),S=!0),!o&&S&&(a&&(l.end=f+s*u),e.push(l),l=d(t)),a&&(f+=s)}var A=t.length-3;p=t[A],y=t[A+1],v=t[A+2],(k=0===i?p:y)>=n&&k<=r&&m(l,p,y,v),A=l.length-3,o&&A>=3&&(l[A]!==l[0]||l[A+1]!==l[1])&&m(l,l[0],l[1],l[2]),l.length&&e.push(l)}function d(t){var e=[];return e.size=t.size,e.start=t.start,e.end=t.end,e}function v(t,e,n,r,i,o){for(var a=0;aa.maxX&&(a.maxX=c),f>a.maxY&&(a.maxY=f)}return a}function A(t,e,n,r){var i=e.geometry,o=e.type,a=[];if("Point"===o||"MultiPoint"===o)for(var s=0;s0&&e.size<(i?a:r))n.numPoints+=e.length/3;else{for(var s=[],u=0;ua)&&(n.numSimplified++,s.push(e[u]),s.push(e[u+1])),n.numPoints++;i&&function(t,e){for(var n=0,r=0,i=t.length,o=i-2;r0===e)for(r=0,i=t.length;r24)throw new Error("maxZoom should be in the 0-24 range");if(e.promoteId&&e.generateId)throw new Error("promoteId and generateId cannot be used together.");var r=function(t,e){var n=[];if("FeatureCollection"===t.type)for(var r=0;r1&&console.time("creation"),p=this.tiles[f]=S(t,e,n,r,u),this.tileCoords.push({z:e,x:n,y:r}),l)){l>1&&(console.log("tile z%d-%d-%d (features: %d, points: %d, simplified: %d)",e,n,r,p.numFeatures,p.numPoints,p.numSimplified),console.timeEnd("creation"));var y="z"+e;this.stats[y]=(this.stats[y]||0)+1,this.total++}if(p.source=t,i){if(e===u.maxZoom||e===i)continue;var d=1<1&&console.time("clipping");var v,m,g,b,x,w,k=.5*u.buffer/u.extent,_=.5-k,A=.5+k,T=1+k;v=m=g=b=null,x=h(t,c,n-k,n+A,0,p.minX,p.maxX,u),w=h(t,c,n+_,n+T,0,p.minX,p.maxX,u),t=null,x&&(v=h(x,c,r-k,r+A,1,p.minY,p.maxY,u),m=h(x,c,r+_,r+T,1,p.minY,p.maxY,u),x=null),w&&(g=h(w,c,r-k,r+A,1,p.minY,p.maxY,u),b=h(w,c,r+_,r+T,1,p.minY,p.maxY,u),w=null),l>1&&console.timeEnd("clipping"),s.push(v||[],e+1,2*n,2*r),s.push(m||[],e+1,2*n,2*r+1),s.push(g||[],e+1,2*n+1,2*r),s.push(b||[],e+1,2*n+1,2*r+1)}}},O.prototype.getTile=function(t,e,n){var r=this.options,i=r.extent,o=r.debug;if(t<0||t>24)return null;var a=1<1&&console.log("drilling down to z%d-%d-%d",t,e,n);for(var u,l=t,c=e,f=n;!u&&l>0;)l--,c=Math.floor(c/2),f=Math.floor(f/2),u=this.tiles[z(l,c,f)];return u&&u.source?(o>1&&console.log("found parent tile z%d-%d-%d",l,c,f),o>1&&console.time("drilling down"),this.splitTile(u.source,l,c,f,t,e,n),o>1&&console.timeEnd("drilling down"),this.tiles[s]?k(this.tiles[s],i):null):null}}]);\n',null)}},function(O,D,o){"use strict";var _=window.URL||window.webkitURL;O.exports=function(e,b){try{try{var g;try{(g=new(window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder)).append(e),g=g.getBlob()}catch{g=new Blob([e])}return new Worker(_.createObjectURL(g))}catch{return new Worker("data:application/javascript,"+encodeURIComponent(e))}}catch{if(!b)throw Error("Inline worker is not supported");return new Worker(b)}}},function(O,D,o){var _=o(215);function e(b,g){var f={};for(var c in b)c!=="ref"&&(f[c]=b[c]);return _.forEach(function(u){u in g&&(f[u]=g[u])}),f}O.exports=function(b){b=b.slice();for(var g=Object.create(null),f=0;f2};this._currentPlacementIndex>=0;){var h=n[a[this._currentPlacementIndex]],m=this.placement.collisionIndex.transform.zoom;if(h.type==="symbol"&&(!h.minzoom||h.minzoom<=m)&&(!h.maxzoom||h.maxzoom>m)){if(this._inProgressLayer||(this._inProgressLayer=new c),this._inProgressLayer.continuePlacement(t[h.source],this.placement,this._showCollisionBoxes,h,d))return;delete this._inProgressLayer}this._currentPlacementIndex--}this._done=!0}}]),i}();O.exports=u},function(O,D){O.exports=`#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 `},function(O,D){O.exports=`#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 // Unpack a pair of values that have been packed into a single float. // The packed values are assumed to be 8-bit unsigned integers, and are // packed like so: // packedValue = floor(input[0]) * 256 + input[1], 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)); } // To minimize the number of attributes needed, we encode a 4-component // color into a pair of floats (i.e. a vec2) as follows: // [ floor(color.r * 255) * 256 + color.g * 255, // floor(color.b * 255) * 256 + color.g * 255 ] vec4 decode_color(const vec2 encodedColor) { return vec4( unpack_float(encodedColor[0]) / 255.0, unpack_float(encodedColor[1]) / 255.0 ); } // Unpack a pair of paint values and interpolate between them. float unpack_mix_vec2(const vec2 packedValue, const float t) { return mix(packedValue[0], packedValue[1], t); } // Unpack a pair of paint values and interpolate between them. vec4 unpack_mix_vec4(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); } // The offset depends on how many pixels are between the world origin and the edge of the tile: // vec2 offset = mod(pixel_coord, size) // // At high zoom levels there are a ton of pixels between the world origin and the edge of the tile. // The glsl spec only guarantees 16 bits of precision for highp floats. We need more than that. // // The pixel_coord is passed in as two 16 bit values: // pixel_coord_upper = floor(pixel_coord / 2^16) // pixel_coord_lower = mod(pixel_coord, 2^16) // // The offset is calculated in a series of steps that should preserve this precision: 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; } `},function(O,D){O.exports=`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 } `},function(O,D){O.exports=`attribute vec2 a_pos; uniform mat4 u_matrix; void main() { gl_Position = u_matrix * vec4(a_pos, 0, 1); } `},function(O,D){O.exports=`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 } `},function(O,D){O.exports=`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); } `},function(O,D){O.exports=`#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 varying vec3 v_data; 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 = opacity_t * mix(color * opacity, stroke_color * stroke_opacity, color_t); #ifdef OVERDRAW_INSPECTOR gl_FragColor = vec4(1.0); #endif } `},function(O,D){O.exports=`uniform mat4 u_matrix; uniform bool u_scale_with_map; uniform bool u_pitch_with_map; uniform vec2 u_extrude_scale; uniform highp float u_camera_to_center_distance; attribute vec2 a_pos; #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 varying vec3 v_data; 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 // unencode the extrusion vector that we snuck into the a_pos vector vec2 extrude = vec2(mod(a_pos, 2.0) * 2.0 - 1.0); // multiply a_pos by 0.5, since we had it * 2 in order to sneak // in extrusion data vec2 circle_center = floor(a_pos * 0.5); if (u_pitch_with_map) { vec2 corner_position = circle_center; if (u_scale_with_map) { corner_position += extrude * (radius + stroke_width) * u_extrude_scale; } else { // Pitching the circle with the map effectively scales it with the map // To counteract the effect for pitch-scale: viewport, we rescale the // whole circle based on the pitch scaling effect at its central point vec4 projected_center = u_matrix * vec4(circle_center, 0, 1); corner_position += extrude * (radius + stroke_width) * u_extrude_scale * (projected_center.w / u_camera_to_center_distance); } gl_Position = u_matrix * vec4(corner_position, 0, 1); } else { gl_Position = u_matrix * vec4(circle_center, 0, 1); if (u_scale_with_map) { gl_Position.xy += extrude * (radius + stroke_width) * u_extrude_scale * u_camera_to_center_distance; } else { gl_Position.xy += extrude * (radius + stroke_width) * u_extrude_scale * gl_Position.w; } } // This is a minimum blur distance that serves as a faux-antialiasing for // the circle. since blur is a ratio of the circle's size and the intent is // to keep the blur at roughly 1px, the two are inversely related. lowp float antialiasblur = 1.0 / DEVICE_PIXEL_RATIO / (radius + stroke_width); v_data = vec3(extrude.x, extrude.y, antialiasblur); } `},function(O,D){O.exports=`void main() { gl_FragColor = vec4(1.0); } `},function(O,D){O.exports=`attribute vec2 a_pos; uniform mat4 u_matrix; void main() { gl_Position = u_matrix * vec4(a_pos, 0, 1); } `},function(O,D){O.exports=`#pragma mapbox: define highp float weight uniform highp float u_intensity; varying vec2 v_extrude; // Gaussian kernel coefficient: 1 / sqrt(2 * PI) #define GAUSS_COEF 0.3989422804014327 void main() { #pragma mapbox: initialize highp float weight // Kernel density estimation with a Gaussian kernel of size 5x5 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 } `},function(O,D){O.exports=`#pragma mapbox: define highp float weight #pragma mapbox: define mediump float radius 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; // Effective "0" in the kernel density texture to adjust the kernel size to; // this empirically chosen number minimizes artifacts on overlapping kernels // for typical heatmap cases (assuming clustered source) const highp float ZERO = 1.0 / 255.0 / 16.0; // Gaussian kernel coefficient: 1 / sqrt(2 * PI) #define GAUSS_COEF 0.3989422804014327 void main(void) { #pragma mapbox: initialize highp float weight #pragma mapbox: initialize mediump float radius // unencode the extrusion vector that we snuck into the a_pos vector vec2 unscaled_extrude = vec2(mod(a_pos, 2.0) * 2.0 - 1.0); // This 'extrude' comes in ranging from [-1, -1], to [1, 1]. We'll use // it to produce the vertices of a square mesh framing the point feature // we're adding to the kernel density texture. We'll also pass it as // a varying, so that the fragment shader can determine the distance of // each fragment from the point feature. // Before we do so, we need to scale it up sufficiently so that the // kernel falls effectively to zero at the edge of the mesh. // That is, we want to know S such that // weight * u_intensity * GAUSS_COEF * exp(-0.5 * 3.0^2 * S^2) == ZERO // Which solves to: // S = sqrt(-2.0 * log(ZERO / (weight * u_intensity * GAUSS_COEF))) / 3.0 float S = sqrt(-2.0 * log(ZERO / weight / u_intensity / GAUSS_COEF)) / 3.0; // Pass the varying in units of radius v_extrude = S * unscaled_extrude; // Scale by radius and the zoom-based scale factor to produce actual // mesh position vec2 extrude = v_extrude * radius * u_extrude_scale; // multiply a_pos by 0.5, since we had it * 2 in order to sneak // in extrusion data vec4 pos = vec4(floor(a_pos * 0.5) + extrude, 0, 1); gl_Position = u_matrix * pos; } `},function(O,D){O.exports=`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 } `},function(O,D){O.exports=`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; } `},function(O,D){O.exports=` varying float v_placed; varying float v_notUsed; void main() { float alpha = 0.5; // Red = collision, hide label gl_FragColor = vec4(1.0, 0.0, 0.0, 1.0) * alpha; // Blue = no collision, label is showing if (v_placed > 0.5) { gl_FragColor = vec4(0.0, 0.0, 1.0, 0.5) * alpha; } if (v_notUsed > 0.5) { // This box not used, fade it out gl_FragColor *= .1; } }`},function(O,D){O.exports=`attribute vec2 a_pos; attribute vec2 a_anchor_pos; attribute vec2 a_extrude; attribute vec2 a_placed; 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 = 0.5 + 0.5 * (u_camera_to_center_distance / camera_to_anchor_distance); gl_Position = u_matrix * vec4(a_pos, 0.0, 1.0); gl_Position.xy += a_extrude * u_extrude_scale * gl_Position.w * collision_perspective_ratio; v_placed = a_placed.x; v_notUsed = a_placed.y; } `},function(O,D){O.exports=` varying float v_placed; varying float v_notUsed; varying float v_radius; varying vec2 v_extrude; varying vec2 v_extrude_scale; void main() { float alpha = 0.5; // Red = collision, hide label vec4 color = vec4(1.0, 0.0, 0.0, 1.0) * alpha; // Blue = no collision, label is showing if (v_placed > 0.5) { color = vec4(0.0, 0.0, 1.0, 0.5) * alpha; } if (v_notUsed > 0.5) { // This box not used, fade it out color *= .2; } float extrude_scale_length = length(v_extrude_scale); float extrude_length = length(v_extrude) * extrude_scale_length; float stroke_width = 15.0 * extrude_scale_length; float radius = v_radius * extrude_scale_length; float distance_to_edge = abs(extrude_length - radius); float opacity_t = smoothstep(-stroke_width, 0.0, -distance_to_edge); gl_FragColor = opacity_t * color; } `},function(O,D){O.exports=`attribute vec2 a_pos; attribute vec2 a_anchor_pos; attribute vec2 a_extrude; attribute vec2 a_placed; uniform mat4 u_matrix; uniform vec2 u_extrude_scale; uniform float u_camera_to_center_distance; varying float v_placed; varying float v_notUsed; varying float v_radius; varying vec2 v_extrude; varying vec2 v_extrude_scale; 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 = 0.5 + 0.5 * (u_camera_to_center_distance / camera_to_anchor_distance); gl_Position = u_matrix * vec4(a_pos, 0.0, 1.0); highp float padding_factor = 1.2; // Pad the vertices slightly to make room for anti-alias blur gl_Position.xy += a_extrude * u_extrude_scale * padding_factor * gl_Position.w * collision_perspective_ratio; v_placed = a_placed.x; v_notUsed = a_placed.y; v_radius = abs(a_extrude.y); // We don't pitch the circles, so both units of the extrusion vector are equal in magnitude to the radius v_extrude = a_extrude * padding_factor; v_extrude_scale = u_extrude_scale * u_camera_to_center_distance * collision_perspective_ratio; } `},function(O,D){O.exports=`uniform highp vec4 u_color; void main() { gl_FragColor = u_color; } `},function(O,D){O.exports=`attribute vec2 a_pos; uniform mat4 u_matrix; void main() { gl_Position = u_matrix * vec4(a_pos, 0, 1); } `},function(O,D){O.exports=`#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 } `},function(O,D){O.exports=`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); } `},function(O,D){O.exports=`#pragma mapbox: define highp vec4 outline_color #pragma mapbox: define lowp float opacity varying vec2 v_pos; 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 } `},function(O,D){O.exports=`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; } `},function(O,D){O.exports=`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 sampler2D u_image; varying vec2 v_pos_a; varying vec2 v_pos_b; varying vec2 v_pos; #pragma mapbox: define lowp float opacity void main() { #pragma mapbox: initialize lowp float opacity 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); // find distance to outline for alpha interpolation float dist = length(v_pos - gl_FragCoord.xy); float alpha = 1.0 - smoothstep(0.0, 1.0, dist); gl_FragColor = mix(color1, color2, u_mix) * alpha * opacity; #ifdef OVERDRAW_INSPECTOR gl_FragColor = vec4(1.0); #endif } `},function(O,D){O.exports=`uniform mat4 u_matrix; uniform vec2 u_world; 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; varying vec2 v_pos; #pragma mapbox: define lowp float opacity void main() { #pragma mapbox: initialize lowp float opacity 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); v_pos = (gl_Position.xy / gl_Position.w + 1.0) / 2.0 * u_world; } `},function(O,D){O.exports=`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 sampler2D u_image; varying vec2 v_pos_a; varying vec2 v_pos_b; #pragma mapbox: define lowp float opacity void main() { #pragma mapbox: initialize lowp float opacity 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) * opacity; #ifdef OVERDRAW_INSPECTOR gl_FragColor = vec4(1.0); #endif } `},function(O,D){O.exports=`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; #pragma mapbox: define lowp float opacity void main() { #pragma mapbox: initialize lowp float opacity 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); } `},function(O,D){O.exports=`varying vec4 v_color; #pragma mapbox: define lowp float base #pragma mapbox: define lowp float height #pragma mapbox: define highp vec4 color void main() { #pragma mapbox: initialize lowp float base #pragma mapbox: initialize lowp float height #pragma mapbox: initialize highp vec4 color gl_FragColor = v_color; #ifdef OVERDRAW_INSPECTOR gl_FragColor = vec4(1.0); #endif } `},function(O,D){O.exports=`uniform mat4 u_matrix; uniform vec3 u_lightcolor; uniform lowp vec3 u_lightpos; uniform lowp float u_lightintensity; attribute vec2 a_pos; attribute vec4 a_normal_ed; varying vec4 v_color; #pragma mapbox: define lowp float base #pragma mapbox: define lowp float height #pragma mapbox: define highp vec4 color void main() { #pragma mapbox: initialize lowp float base #pragma mapbox: initialize lowp float height #pragma mapbox: initialize highp vec4 color vec3 normal = a_normal_ed.xyz; base = max(0.0, base); height = max(0.0, height); float t = mod(normal.x, 2.0); gl_Position = u_matrix * vec4(a_pos, t > 0.0 ? height : base, 1); // Relative luminance (how dark/bright is the surface color?) 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); // Add slight ambient lighting so no extrusions are totally black vec4 ambientlight = vec4(0.03, 0.03, 0.03, 1.0); color += ambientlight; // Calculate cos(theta), where theta is the angle between surface normal and diffuse light ray float directional = clamp(dot(normal / 16384.0, u_lightpos), 0.0, 1.0); // Adjust directional so that // the range of values for highlight/shading is narrower // with lower light intensity // and with lighter/brighter surface colors directional = mix((1.0 - u_lightintensity), max((1.0 - colorvalue + u_lightintensity), 1.0), directional); // Add gradient along z axis of side surfaces if (normal.y != 0.0) { directional *= clamp((t + base) * pow(height / 150.0, 0.5), mix(0.7, 0.98, 1.0 - u_lightintensity), 1.0); } // Assign final color based on surface + ambient light color, diffuse light directional, and light color // with lower bounds adjusted to hue of light // so that shading is tinted with the complementary (opposite) color to the light color 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); } `},function(O,D){O.exports=`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 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 void main() { #pragma mapbox: initialize lowp float base #pragma mapbox: initialize lowp float height 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); vec4 mixedColor = mix(color1, color2, u_mix); gl_FragColor = mixedColor * v_lighting; #ifdef OVERDRAW_INSPECTOR gl_FragColor = vec4(1.0); #endif } `},function(O,D){O.exports=`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; uniform float u_height_factor; uniform vec3 u_lightcolor; uniform lowp vec3 u_lightpos; uniform lowp float u_lightintensity; attribute vec2 a_pos; attribute vec4 a_normal_ed; varying vec2 v_pos_a; varying vec2 v_pos_b; varying vec4 v_lighting; varying float v_directional; #pragma mapbox: define lowp float base #pragma mapbox: define lowp float height void main() { #pragma mapbox: initialize lowp float base #pragma mapbox: initialize lowp float height vec3 normal = a_normal_ed.xyz; float edgedistance = a_normal_ed.w; base = max(0.0, base); height = max(0.0, height); float t = mod(normal.x, 2.0); float z = t > 0.0 ? height : base; gl_Position = u_matrix * vec4(a_pos, z, 1); vec2 pos = normal.x == 1.0 && normal.y == 0.0 && normal.z == 16384.0 ? a_pos // extrusion top : vec2(edgedistance, z * u_height_factor); // extrusion side 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, 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, 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 *= 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)); } `},function(O,D){O.exports=`uniform sampler2D u_image; uniform float u_opacity; varying vec2 v_pos; void main() { gl_FragColor = texture2D(u_image, v_pos) * u_opacity; #ifdef OVERDRAW_INSPECTOR gl_FragColor = vec4(0.0); #endif } `},function(O,D){O.exports=`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; } `},function(O,D){O.exports=`#ifdef GL_ES precision highp float; #endif uniform sampler2D u_image; varying vec2 v_pos; uniform vec2 u_dimension; uniform float u_zoom; float getElevation(vec2 coord, float bias) { // Convert encoded elevation value to meters vec4 data = texture2D(u_image, coord) * 255.0; return (data.r + data.g * 256.0 + data.b * 256.0 * 256.0) / 4.0; } void main() { vec2 epsilon = 1.0 / u_dimension; // queried pixels: // +-----------+ // | | | | // | a | b | c | // | | | | // +-----------+ // | | | | // | d | e | f | // | | | | // +-----------+ // | | | | // | g | h | i | // | | | | // +-----------+ 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); // here we divide the x and y slopes by 8 * pixel size // where pixel size (aka meters/pixel) is: // circumference of the world / (pixels per tile * number of tiles) // which is equivalent to: 8 * 40075016.6855785 / (512 * pow(2, u_zoom)) // which can be reduced to: pow(2, 19.25619978527 - u_zoom) // we want to vertically exaggerate the hillshading though, because otherwise // it is barely noticeable at low zooms. to do this, we multiply this by some // scale factor pow(2, (u_zoom - 14) * a) where a is an arbitrary value and 14 is the // maxzoom of the tile source. here we use a=0.3 which works out to the // expression below. see nickidlugash's awesome breakdown for more info // https://github.com/mapbox/mapbox-gl-js/pull/5286#discussion_r148419556 float exaggeration = u_zoom < 2.0 ? 0.4 : u_zoom < 4.5 ? 0.35 : 0.3; vec2 deriv = vec2( (c + f + f + i) - (a + d + d + g), (g + h + h + i) - (a + b + b + c) ) / pow(2.0, (u_zoom - 14.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 } `},function(O,D){O.exports=`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) / 2.0 + 0.25; } `},function(O,D){O.exports=`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); // We divide the slope by a scale factor based on the cosin of the pixel's approximate latitude // to account for mercator projection distortion. see #4807 for details float scaleFactor = cos(radians((u_latrange[0] - u_latrange[1]) * (1.0 - v_pos.y) + u_latrange[1])); // We also multiply the slope by an arbitrary z-factor of 1.25 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; // We add PI to make this property match the global light object, which adds PI/2 to the light's azimuthal // position property to account for 0deg corresponding to north/the top of the viewport in the style spec // and the original shader was written to accept (-illuminationDirection - 90) as the azimuthal. float azimuth = u_light.y + PI; // We scale the slope exponentially based on intensity, using a calculation similar to // the exponential interpolation function in the style spec: // https://github.com/mapbox/mapbox-gl-js/blob/master/src/style-spec/expression/definitions/interpolate.js#L217-L228 // so that higher intensity values create more opaque hillshading. 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; // The accent color is calculated with the cosine of the slope while the shade color is calculated with the sine // so that the accent color's rate of change eases in while the shade color's eases out. float accent = cos(scaledSlope); // We multiply both the accent and shade color by a clamped intensity value // so that intensities >= 0.5 do not additionally affect the color values // while intensity values < 0.5 make the overall color more transparent. 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 } `},function(O,D){O.exports=`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; } `},function(O,D){O.exports=`#pragma mapbox: define highp vec4 color #pragma mapbox: define lowp float blur #pragma mapbox: define lowp float opacity varying vec2 v_width2; varying vec2 v_normal; varying float v_gamma_scale; void main() { #pragma mapbox: initialize highp vec4 color #pragma mapbox: initialize lowp float blur #pragma mapbox: initialize lowp float opacity // Calculate the distance of the pixel from the line in pixels. float dist = length(v_normal) * v_width2.s; // Calculate the antialiasing fade factor. This is either when fading in // the line in case of an offset line (v_width2.t) or when fading out // (v_width2.s) float blur2 = (blur + 1.0 / 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 } `},function(O,D){O.exports=` // the distance over which the line edge fades out. // Retina devices need a smaller distance to avoid aliasing. #define ANTIALIASING 1.0 / DEVICE_PIXEL_RATIO / 2.0 // floor(127 / 2) == 63.0 // the maximum allowed miter limit is 2.0 at the moment. the extrude normal is // stored in a byte (-128..127). we scale regular normals up to length 63, but // there are also "special" normals that have a bigger length (of up to 126 in // this case). // #define scale 63.0 #define scale 0.015873016 attribute vec4 a_pos_normal; attribute vec4 a_data; uniform mat4 u_matrix; uniform mediump float u_ratio; uniform vec2 u_gl_units_to_pixels; varying vec2 v_normal; varying vec2 v_width2; 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 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 vec2 a_extrude = a_data.xy - 128.0; float a_direction = mod(a_data.z, 4.0) - 1.0; vec2 pos = a_pos_normal.xy; // x is 1 if it's a round cap, 0 otherwise // y is 1 if the normal points up, and -1 if it points down mediump vec2 normal = a_pos_normal.zw; v_normal = normal; // these transformations used to be applied in the JS and native code bases. // moved them into the shader for clarity and simplicity. 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) + ANTIALIASING; // Scale the extrusion vector down to a normal and then up by the line width // of this vertex. mediump vec2 dist = outset * a_extrude * scale; // Calculate the offset when drawing a line that is to the side of the actual line. // We do this by creating a vector that points towards the extrude, but rotate // it when we're drawing round end points (a_direction = -1 or 1) since their // extrude vector points in another direction. 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; // calculate how much the perspective view squishes or stretches the extrude float extrude_length_without_perspective = length(dist); float extrude_length_with_perspective = length(projected_extrude.xy / gl_Position.w * u_gl_units_to_pixels); v_gamma_scale = extrude_length_without_perspective / extrude_length_with_perspective; v_width2 = vec2(outset, inset); } `},function(O,D){O.exports=`uniform vec2 u_pattern_size_a; uniform vec2 u_pattern_size_b; 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_fade; uniform sampler2D u_image; varying vec2 v_normal; varying vec2 v_width2; varying float v_linesofar; varying float v_gamma_scale; #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 // Calculate the distance of the pixel from the line in pixels. float dist = length(v_normal) * v_width2.s; // Calculate the antialiasing fade factor. This is either when fading in // the line in case of an offset line (v_width2.t) or when fading out // (v_width2.s) float blur2 = (blur + 1.0 / 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 / u_pattern_size_a.x, 1.0); float x_b = mod(v_linesofar / u_pattern_size_b.x, 1.0); float y_a = 0.5 + (v_normal.y * v_width2.s / u_pattern_size_a.y); float y_b = 0.5 + (v_normal.y * v_width2.s / u_pattern_size_b.y); vec2 pos_a = mix(u_pattern_tl_a / u_texsize, u_pattern_br_a / u_texsize, vec2(x_a, y_a)); vec2 pos_b = mix(u_pattern_tl_b / u_texsize, u_pattern_br_b / u_texsize, vec2(x_b, y_b)); 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 } `},function(O,D){O.exports=`// floor(127 / 2) == 63.0 // the maximum allowed miter limit is 2.0 at the moment. the extrude normal is // stored in a byte (-128..127). we scale regular normals up to length 63, but // there are also "special" normals that have a bigger length (of up to 126 in // this case). // #define scale 63.0 #define scale 0.015873016 // We scale the distance before adding it to the buffers so that we can store // long distances for long segments. Use this value to unscale the distance. #define LINE_DISTANCE_SCALE 2.0 // the distance over which the line edge fades out. // Retina devices need a smaller distance to avoid aliasing. #define ANTIALIASING 1.0 / DEVICE_PIXEL_RATIO / 2.0 attribute vec4 a_pos_normal; attribute vec4 a_data; uniform mat4 u_matrix; uniform mediump float u_ratio; uniform vec2 u_gl_units_to_pixels; varying vec2 v_normal; varying vec2 v_width2; varying float v_linesofar; varying float v_gamma_scale; #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 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 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 = a_pos_normal.xy; // x is 1 if it's a round cap, 0 otherwise // y is 1 if the normal points up, and -1 if it points down mediump vec2 normal = a_pos_normal.zw; v_normal = normal; // these transformations used to be applied in the JS and native code bases. // moved them into the shader for clarity and simplicity. 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) + ANTIALIASING; // Scale the extrusion vector down to a normal and then up by the line width // of this vertex. mediump vec2 dist = outset * a_extrude * scale; // Calculate the offset when drawing a line that is to the side of the actual line. // We do this by creating a vector that points towards the extrude, but rotate // it when we're drawing round end points (a_direction = -1 or 1) since their // extrude vector points in another direction. 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; // calculate how much the perspective view squishes or stretches the extrude float extrude_length_without_perspective = length(dist); float extrude_length_with_perspective = length(projected_extrude.xy / gl_Position.w * u_gl_units_to_pixels); v_gamma_scale = extrude_length_without_perspective / extrude_length_with_perspective; v_linesofar = a_linesofar; v_width2 = vec2(outset, inset); } `},function(O,D){O.exports=` 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 // Calculate the distance of the pixel from the line in pixels. float dist = length(v_normal) * v_width2.s; // Calculate the antialiasing fade factor. This is either when fading in // the line in case of an offset line (v_width2.t) or when fading out // (v_width2.s) float blur2 = (blur + 1.0 / 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 } `},function(O,D){O.exports=`// floor(127 / 2) == 63.0 // the maximum allowed miter limit is 2.0 at the moment. the extrude normal is // stored in a byte (-128..127). we scale regular normals up to length 63, but // there are also "special" normals that have a bigger length (of up to 126 in // this case). // #define scale 63.0 #define scale 0.015873016 // We scale the distance before adding it to the buffers so that we can store // long distances for long segments. Use this value to unscale the distance. #define LINE_DISTANCE_SCALE 2.0 // the distance over which the line edge fades out. // Retina devices need a smaller distance to avoid aliasing. #define ANTIALIASING 1.0 / DEVICE_PIXEL_RATIO / 2.0 attribute vec4 a_pos_normal; attribute vec4 a_data; uniform mat4 u_matrix; uniform mediump float u_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_gl_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 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 = a_pos_normal.xy; // x is 1 if it's a round cap, 0 otherwise // y is 1 if the normal points up, and -1 if it points down mediump vec2 normal = a_pos_normal.zw; v_normal = normal; // these transformations used to be applied in the JS and native code bases. // moved them into the shader for clarity and simplicity. 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) + ANTIALIASING; // Scale the extrusion vector down to a normal and then up by the line width // of this vertex. mediump vec2 dist =outset * a_extrude * scale; // Calculate the offset when drawing a line that is to the side of the actual line. // We do this by creating a vector that points towards the extrude, but rotate // it when we're drawing round end points (a_direction = -1 or 1) since their // extrude vector points in another direction. 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; // calculate how much the perspective view squishes or stretches the extrude float extrude_length_without_perspective = length(dist); float extrude_length_with_perspective = length(projected_extrude.xy / gl_Position.w * u_gl_units_to_pixels); v_gamma_scale = extrude_length_without_perspective / extrude_length_with_perspective; v_tex_a = vec2(a_linesofar * u_patternscale_a.x / floorwidth, normal.y * u_patternscale_a.y + u_tex_y_a); v_tex_b = vec2(a_linesofar * u_patternscale_b.x / floorwidth, normal.y * u_patternscale_b.y + u_tex_y_b); v_width2 = vec2(outset, inset); } `},function(O,D){O.exports=`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() { // read and cross-fade colors from the main and parent tiles 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; // spin rgb = vec3( dot(rgb, u_spin_weights.xyz), dot(rgb, u_spin_weights.zxy), dot(rgb, u_spin_weights.yzx)); // saturation float average = (color.r + color.g + color.b) / 3.0; rgb += (average - rgb) * u_saturation_factor; // contrast rgb = (rgb - 0.5) * u_contrast_factor + 0.5; // brightness 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 } `},function(O,D){O.exports=`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); // We are using Int16 for texture position coordinates to give us enough precision for // fractional coordinates. We use 8192 to scale the texture coordinates in the buffer // as an arbitrarily high number to preserve adequate precision when rendering. // This is also the same value as the EXTENT we are using for our tile buffer pos coordinates, // so math for modifying either is consistent. v_pos0 = (((a_texture_pos / 8192.0) - 0.5) / u_buffer_scale ) + 0.5; v_pos1 = (v_pos0 * u_scale_parent) + u_tl_parent; } `},function(O,D){O.exports=`uniform sampler2D u_texture; #pragma mapbox: define lowp float opacity varying vec2 v_tex; void main() { #pragma mapbox: initialize lowp float opacity lowp float alpha = opacity; gl_FragColor = texture2D(u_texture, v_tex) * alpha; #ifdef OVERDRAW_INSPECTOR gl_FragColor = vec4(1.0); #endif } `},function(O,D){O.exports=`const float PI = 3.141592653589793; attribute vec4 a_pos_offset; attribute vec4 a_data; attribute vec3 a_projected_pos; uniform bool u_is_size_zoom_constant; uniform bool u_is_size_feature_constant; uniform highp float u_size_t; // used to interpolate between zoom stops when size is a composite function uniform highp float u_size; // used when size is both zoom and feature constant 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; #pragma mapbox: define lowp float opacity uniform mat4 u_matrix; uniform mat4 u_label_plane_matrix; uniform mat4 u_gl_coord_matrix; uniform bool u_is_text; uniform bool u_pitch_with_map; uniform vec2 u_texsize; varying vec2 v_tex; 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; 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[0], a_size[1], u_size_t) / 10.0; } else if (u_is_size_zoom_constant && !u_is_size_feature_constant) { size = a_size[0] / 10.0; } else if (!u_is_size_zoom_constant && u_is_size_feature_constant) { size = u_size; } else { size = u_size; } vec4 projectedPoint = u_matrix * vec4(a_pos, 0, 1); highp float camera_to_anchor_distance = projectedPoint.w; // See comments in symbol_sdf.vertex 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 = 0.5 + 0.5 * distance_ratio; size *= perspective_ratio; float fontScale = u_is_text ? size / 24.0 : size; highp float symbol_rotation = 0.0; if (u_rotate_symbol) { // See comments in symbol_sdf.vertex vec4 offsetProjectedPoint = u_matrix * vec4(a_pos + vec2(1, 0), 0, 1); vec2 a = projectedPoint.xy / projectedPoint.w; vec2 b = offsetProjectedPoint.xy / offsetProjectedPoint.w; symbol_rotation = atan((b.y - a.y) / u_aspect_ratio, b.x - a.x); } highp float angle_sin = sin(segment_angle + symbol_rotation); highp float angle_cos = cos(segment_angle + symbol_rotation); mat2 rotation_matrix = mat2(angle_cos, -1.0 * angle_sin, angle_sin, angle_cos); vec4 projected_pos = u_label_plane_matrix * vec4(a_projected_pos.xy, 0.0, 1.0); gl_Position = u_gl_coord_matrix * vec4(projected_pos.xy / projected_pos.w + rotation_matrix * (a_offset / 64.0 * fontScale), 0.0, 1.0); v_tex = a_tex / u_texsize; } `},function(O,D){O.exports=`#define SDF_PX 8.0 #define EDGE_GAMMA 0.105/DEVICE_PIXEL_RATIO uniform bool u_has_halo; #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 uniform sampler2D u_texture; uniform highp float u_gamma_scale; uniform bool u_is_text; varying vec2 v_data0; varying vec3 v_data1; 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 tex = v_data0.xy; float gamma_scale = v_data1.x; float size = v_data1.y; lowp float dist = texture2D(u_texture, tex).a; float fontScale = u_is_text ? size / 24.0 : size; lowp vec4 color = fill_color; highp float gamma = EDGE_GAMMA / (fontScale * u_gamma_scale); lowp float buff = (256.0 - 64.0) / 256.0; highp float gamma_scaled = gamma * u_gamma_scale; highp float alpha = smoothstep(buff - gamma_scaled, buff + gamma_scaled, dist); if (u_has_halo) { gamma = (halo_blur * 1.19 / SDF_PX + EDGE_GAMMA) / (fontScale * u_gamma_scale); highp float gamma_scaled_halo = gamma * u_gamma_scale; lowp float buff_halo = (6.0 - halo_width / fontScale) / SDF_PX; highp float alpha_halo = smoothstep(buff_halo - gamma_scaled, buff_halo + gamma_scaled, dist); color = mix(halo_color, color, alpha); alpha = alpha_halo; } gl_FragColor = color * (alpha * opacity); #ifdef OVERDRAW_INSPECTOR gl_FragColor = vec4(1.0); #endif } `},function(O,D){O.exports=`const float PI = 3.141592653589793; attribute vec4 a_pos_offset; attribute vec4 a_data; attribute vec3 a_projected_pos; // contents of a_size vary based on the type of property value // used for {text,icon}-size. // For constants, a_size is disabled. // For source functions, we bind only one value per vertex: the value of {text,icon}-size evaluated for the current feature. // For composite functions: // [ text-size(lowerZoomStop, feature), // text-size(upperZoomStop, feature) ] uniform bool u_is_size_zoom_constant; uniform bool u_is_size_feature_constant; uniform highp float u_size_t; // used to interpolate between zoom stops when size is a composite function uniform highp float u_size; // used when size is both zoom and feature constant #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 uniform mat4 u_matrix; uniform mat4 u_label_plane_matrix; uniform mat4 u_gl_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; 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; 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[0], a_size[1], u_size_t) / 10.0; } else if (u_is_size_zoom_constant && !u_is_size_feature_constant) { size = a_size[0] / 10.0; } else if (!u_is_size_zoom_constant && u_is_size_feature_constant) { size = u_size; } else { size = u_size; } vec4 projectedPoint = u_matrix * vec4(a_pos, 0, 1); highp float camera_to_anchor_distance = projectedPoint.w; // If the label is pitched with the map, layout is done in pitched space, // which makes labels in the distance smaller relative to viewport space. // We counteract part of that effect by multiplying by the perspective ratio. // If the label isn't pitched with the map, we do layout in viewport space, // which makes labels in the distance larger relative to the features around // them. We counteract part of that effect by dividing by the perspective ratio. 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 = 0.5 + 0.5 * distance_ratio; size *= perspective_ratio; float fontScale = u_is_text ? size / 24.0 : size; highp float symbol_rotation = 0.0; if (u_rotate_symbol) { // Point labels with 'rotation-alignment: map' are horizontal with respect to tile units // To figure out that angle in projected space, we draw a short horizontal line in tile // space, project it, and measure its angle in projected space. vec4 offsetProjectedPoint = u_matrix * vec4(a_pos + vec2(1, 0), 0, 1); vec2 a = projectedPoint.xy / projectedPoint.w; vec2 b = offsetProjectedPoint.xy / offsetProjectedPoint.w; symbol_rotation = atan((b.y - a.y) / u_aspect_ratio, b.x - a.x); } highp float angle_sin = sin(segment_angle + symbol_rotation); highp float angle_cos = cos(segment_angle + symbol_rotation); mat2 rotation_matrix = mat2(angle_cos, -1.0 * angle_sin, angle_sin, angle_cos); vec4 projected_pos = u_label_plane_matrix * vec4(a_projected_pos.xy, 0.0, 1.0); gl_Position = u_gl_coord_matrix * vec4(projected_pos.xy / projected_pos.w + rotation_matrix * (a_offset / 64.0 * fontScale), 0.0, 1.0); float gamma_scale = gl_Position.w; vec2 tex = a_tex / u_texsize; v_data0 = vec2(tex.x, tex.y); v_data1 = vec3(gamma_scale, size, 1.0); } `},function(O,D,o){function _(i,a,n){return a in i?Object.defineProperty(i,a,{value:n,enumerable:!0,configurable:!0,writable:!0}):i[a]=n,i}function e(i,a){for(var n=0;n0){var l=b.now(),d=(l-u.timeAdded)/r,h=i?(l-i.timeAdded)/r:-1,m=a.getSource(),S=t.coveringZoomLevel({tileSize:m.tileSize,roundZoom:m.roundZoom}),y=!i||Math.abs(i.tileID.overscaledZ-S)>Math.abs(u.tileID.overscaledZ-S),s=y&&u.refreshedUponExpiration?1:_.clamp(y?d:1-h,0,1);return u.refreshedUponExpiration&&d>=1&&(u.refreshedUponExpiration=!1),i?{opacity:1,mix:1-s}:{opacity:s,mix:0}}return{opacity:1,mix:0}}O.exports=function(u,i,a,n){if(u.renderPass==="translucent"&&a.paint.get("raster-opacity")!==0){var t=u.context,r=t.gl,l=i.getSource(),d=u.useProgram("raster");t.setStencilMode(g.disabled),t.setColorMode(u.colorModeForRenderPass()),r.uniform1f(d.uniforms.u_brightness_low,a.paint.get("raster-brightness-min")),r.uniform1f(d.uniforms.u_brightness_high,a.paint.get("raster-brightness-max")),r.uniform1f(d.uniforms.u_saturation_factor,(m=a.paint.get("raster-saturation"),m>0?1-1/(1.001-m):-m)),r.uniform1f(d.uniforms.u_contrast_factor,(h=a.paint.get("raster-contrast"),h>0?1/(1-h):1+h)),r.uniform3fv(d.uniforms.u_spin_weights,function(W){W*=Math.PI/180;var J=Math.sin(W),X=Math.cos(W);return[(2*X+1)/3,(-Math.sqrt(3)*J-X+1)/3,(Math.sqrt(3)*J-X+1)/3]}(a.paint.get("raster-hue-rotate"))),r.uniform1f(d.uniforms.u_buffer_scale,1),r.uniform1i(d.uniforms.u_image0,0),r.uniform1i(d.uniforms.u_image1,1);var h,m,S=n.length&&n[0].overscaledZ,y=!0,s=!1,p=void 0;try{for(var w,A=n[Symbol.iterator]();!(y=(w=A.next()).done);y=!0){var k=w.value;t.setDepthMode(u.depthModeForSublayer(k.overscaledZ-S,a.paint.get("raster-opacity")===1?f.ReadWrite:f.ReadOnly,r.LESS));var v=i.getTile(k),x=u.transform.calculatePosMatrix(k.toUnwrapped());v.registerFadeDuration(a.paint.get("raster-fade-duration")),r.uniformMatrix4fv(d.uniforms.u_matrix,!1,x);var T=i.findLoadedParent(k,0,{}),E=c(v,T,i,a,u.transform),C=void 0,z=void 0;if(t.activeTexture.set(r.TEXTURE0),v.texture.bind(r.LINEAR,r.CLAMP_TO_EDGE,r.LINEAR_MIPMAP_NEAREST),t.activeTexture.set(r.TEXTURE1),T?(T.texture.bind(r.LINEAR,r.CLAMP_TO_EDGE,r.LINEAR_MIPMAP_NEAREST),C=Math.pow(2,T.tileID.overscaledZ-v.tileID.overscaledZ),z=[v.tileID.canonical.x*C%1,v.tileID.canonical.y*C%1]):v.texture.bind(r.LINEAR,r.CLAMP_TO_EDGE,r.LINEAR_MIPMAP_NEAREST),r.uniform2fv(d.uniforms.u_tl_parent,z||[0,0]),r.uniform1f(d.uniforms.u_scale_parent,C||1),r.uniform1f(d.uniforms.u_fade_t,E.mix),r.uniform1f(d.uniforms.u_opacity,E.opacity*a.paint.get("raster-opacity")),l instanceof e){var P=l.boundsBuffer,B=l.boundsVAO;B.bind(t,d,P,[]),r.drawArrays(r.TRIANGLE_STRIP,0,P.length)}else if(v.maskedBoundsBuffer&&v.maskedIndexBuffer&&v.segments)d.draw(t,r.TRIANGLES,a.id,v.maskedBoundsBuffer,v.maskedIndexBuffer,v.segments);else{var F=u.rasterBoundsBuffer,Z=u.rasterBoundsVAO;Z.bind(t,d,F,[]),r.drawArrays(r.TRIANGLE_STRIP,0,F.length)}}}catch(W){s=!0,p=W}finally{try{y||A.return==null||A.return()}finally{if(s)throw p}}}}},function(O,D,o){var _=o(70),e=o(18),b=o(15);O.exports=function(g,f,c){var u=c.paint.get("background-color"),i=c.paint.get("background-opacity");if(i!==0){var a,n=g.context,t=n.gl,r=g.transform,l=r.tileSize,d=c.paint.get("background-pattern"),h=d||u.a!==1||i!==1?"translucent":"opaque";if(g.renderPass===h){if(n.setStencilMode(e.disabled),n.setDepthMode(g.depthModeForSublayer(0,h==="opaque"?b.ReadWrite:b.ReadOnly)),n.setColorMode(g.colorModeForRenderPass()),d){if(_.isPatternMissing(d,g))return;a=g.useProgram("backgroundPattern"),_.prepare(d,g,a),g.tileExtentPatternVAO.bind(n,a,g.tileExtentBuffer,[])}else a=g.useProgram("background"),t.uniform4fv(a.uniforms.u_color,[u.r,u.g,u.b,u.a]),g.tileExtentVAO.bind(n,a,g.tileExtentBuffer,[]);t.uniform1f(a.uniforms.u_opacity,i);var m=r.coveringTiles({tileSize:l}),S=!0,y=!1,s=void 0;try{for(var p,w=m[Symbol.iterator]();!(S=(p=w.next()).done);S=!0){var A=p.value;d&&_.setTile({tileID:A,tileSize:l},g,a),t.uniformMatrix4fv(a.uniforms.u_matrix,!1,g.transform.calculatePosMatrix(A.toUnwrapped())),t.drawArrays(t.TRIANGLE_STRIP,0,g.tileExtentBuffer.length)}}catch(k){y=!0,s=k}finally{try{S||w.return==null||w.return()}finally{if(y)throw s}}}}}},function(O,D,o){var _=o(2),e=o(22).mat4,b=o(6),g=o(40),f=o(14).PosArray,c=o(125),u=o(15),i=o(18);function a(t,r,l){var d=t.context,h=d.gl;d.lineWidth.set(1*_.devicePixelRatio);var m=l.posMatrix,S=t.useProgram("debug");d.setDepthMode(u.disabled),d.setStencilMode(i.disabled),d.setColorMode(t.colorModeForRenderPass()),h.uniformMatrix4fv(S.uniforms.u_matrix,!1,m),h.uniform4f(S.uniforms.u_color,1,0,0,1),t.debugVAO.bind(d,S,t.debugBuffer,[]),h.drawArrays(h.LINE_STRIP,0,t.debugBuffer.length);for(var y=function(E,C,z,P){P=P||1;var B,F,Z,W,J,X,R,U,K=[];for(B=0,F=E.length;B":[24,[4,18,20,9,4,0]],"?":[18,[3,16,3,17,4,19,5,20,7,21,11,21,13,20,14,19,15,17,15,15,14,13,13,12,9,10,9,7,-1,-1,9,2,8,1,9,0,10,1,9,2]],"@":[27,[18,13,17,15,15,16,12,16,10,15,9,14,8,11,8,8,9,6,11,5,14,5,16,6,17,8,-1,-1,12,16,10,14,9,11,9,8,10,6,11,5,-1,-1,18,16,17,8,17,6,19,5,21,5,23,7,24,10,24,12,23,15,22,17,20,19,18,20,15,21,12,21,9,20,7,19,5,17,4,15,3,12,3,9,4,6,5,4,7,2,9,1,12,0,15,0,18,1,20,2,21,3,-1,-1,19,16,18,8,18,6,19,5]],A:[18,[9,21,1,0,-1,-1,9,21,17,0,-1,-1,4,7,14,7]],B:[21,[4,21,4,0,-1,-1,4,21,13,21,16,20,17,19,18,17,18,15,17,13,16,12,13,11,-1,-1,4,11,13,11,16,10,17,9,18,7,18,4,17,2,16,1,13,0,4,0]],C:[21,[18,16,17,18,15,20,13,21,9,21,7,20,5,18,4,16,3,13,3,8,4,5,5,3,7,1,9,0,13,0,15,1,17,3,18,5]],D:[21,[4,21,4,0,-1,-1,4,21,11,21,14,20,16,18,17,16,18,13,18,8,17,5,16,3,14,1,11,0,4,0]],E:[19,[4,21,4,0,-1,-1,4,21,17,21,-1,-1,4,11,12,11,-1,-1,4,0,17,0]],F:[18,[4,21,4,0,-1,-1,4,21,17,21,-1,-1,4,11,12,11]],G:[21,[18,16,17,18,15,20,13,21,9,21,7,20,5,18,4,16,3,13,3,8,4,5,5,3,7,1,9,0,13,0,15,1,17,3,18,5,18,8,-1,-1,13,8,18,8]],H:[22,[4,21,4,0,-1,-1,18,21,18,0,-1,-1,4,11,18,11]],I:[8,[4,21,4,0]],J:[16,[12,21,12,5,11,2,10,1,8,0,6,0,4,1,3,2,2,5,2,7]],K:[21,[4,21,4,0,-1,-1,18,21,4,7,-1,-1,9,12,18,0]],L:[17,[4,21,4,0,-1,-1,4,0,16,0]],M:[24,[4,21,4,0,-1,-1,4,21,12,0,-1,-1,20,21,12,0,-1,-1,20,21,20,0]],N:[22,[4,21,4,0,-1,-1,4,21,18,0,-1,-1,18,21,18,0]],O:[22,[9,21,7,20,5,18,4,16,3,13,3,8,4,5,5,3,7,1,9,0,13,0,15,1,17,3,18,5,19,8,19,13,18,16,17,18,15,20,13,21,9,21]],P:[21,[4,21,4,0,-1,-1,4,21,13,21,16,20,17,19,18,17,18,14,17,12,16,11,13,10,4,10]],Q:[22,[9,21,7,20,5,18,4,16,3,13,3,8,4,5,5,3,7,1,9,0,13,0,15,1,17,3,18,5,19,8,19,13,18,16,17,18,15,20,13,21,9,21,-1,-1,12,4,18,-2]],R:[21,[4,21,4,0,-1,-1,4,21,13,21,16,20,17,19,18,17,18,15,17,13,16,12,13,11,4,11,-1,-1,11,11,18,0]],S:[20,[17,18,15,20,12,21,8,21,5,20,3,18,3,16,4,14,5,13,7,12,13,10,15,9,16,8,17,6,17,3,15,1,12,0,8,0,5,1,3,3]],T:[16,[8,21,8,0,-1,-1,1,21,15,21]],U:[22,[4,21,4,6,5,3,7,1,10,0,12,0,15,1,17,3,18,6,18,21]],V:[18,[1,21,9,0,-1,-1,17,21,9,0]],W:[24,[2,21,7,0,-1,-1,12,21,7,0,-1,-1,12,21,17,0,-1,-1,22,21,17,0]],X:[20,[3,21,17,0,-1,-1,17,21,3,0]],Y:[18,[1,21,9,11,9,0,-1,-1,17,21,9,11]],Z:[20,[17,21,3,0,-1,-1,3,21,17,21,-1,-1,3,0,17,0]],"[":[14,[4,25,4,-7,-1,-1,5,25,5,-7,-1,-1,4,25,11,25,-1,-1,4,-7,11,-7]],"\\":[14,[0,21,14,-3]],"]":[14,[9,25,9,-7,-1,-1,10,25,10,-7,-1,-1,3,25,10,25,-1,-1,3,-7,10,-7]],"^":[16,[6,15,8,18,10,15,-1,-1,3,12,8,17,13,12,-1,-1,8,17,8,0]],_:[16,[0,-2,16,-2]],"`":[10,[6,21,5,20,4,18,4,16,5,15,6,16,5,17]],a:[19,[15,14,15,0,-1,-1,15,11,13,13,11,14,8,14,6,13,4,11,3,8,3,6,4,3,6,1,8,0,11,0,13,1,15,3]],b:[19,[4,21,4,0,-1,-1,4,11,6,13,8,14,11,14,13,13,15,11,16,8,16,6,15,3,13,1,11,0,8,0,6,1,4,3]],c:[18,[15,11,13,13,11,14,8,14,6,13,4,11,3,8,3,6,4,3,6,1,8,0,11,0,13,1,15,3]],d:[19,[15,21,15,0,-1,-1,15,11,13,13,11,14,8,14,6,13,4,11,3,8,3,6,4,3,6,1,8,0,11,0,13,1,15,3]],e:[18,[3,8,15,8,15,10,14,12,13,13,11,14,8,14,6,13,4,11,3,8,3,6,4,3,6,1,8,0,11,0,13,1,15,3]],f:[12,[10,21,8,21,6,20,5,17,5,0,-1,-1,2,14,9,14]],g:[19,[15,14,15,-2,14,-5,13,-6,11,-7,8,-7,6,-6,-1,-1,15,11,13,13,11,14,8,14,6,13,4,11,3,8,3,6,4,3,6,1,8,0,11,0,13,1,15,3]],h:[19,[4,21,4,0,-1,-1,4,10,7,13,9,14,12,14,14,13,15,10,15,0]],i:[8,[3,21,4,20,5,21,4,22,3,21,-1,-1,4,14,4,0]],j:[10,[5,21,6,20,7,21,6,22,5,21,-1,-1,6,14,6,-3,5,-6,3,-7,1,-7]],k:[17,[4,21,4,0,-1,-1,14,14,4,4,-1,-1,8,8,15,0]],l:[8,[4,21,4,0]],m:[30,[4,14,4,0,-1,-1,4,10,7,13,9,14,12,14,14,13,15,10,15,0,-1,-1,15,10,18,13,20,14,23,14,25,13,26,10,26,0]],n:[19,[4,14,4,0,-1,-1,4,10,7,13,9,14,12,14,14,13,15,10,15,0]],o:[19,[8,14,6,13,4,11,3,8,3,6,4,3,6,1,8,0,11,0,13,1,15,3,16,6,16,8,15,11,13,13,11,14,8,14]],p:[19,[4,14,4,-7,-1,-1,4,11,6,13,8,14,11,14,13,13,15,11,16,8,16,6,15,3,13,1,11,0,8,0,6,1,4,3]],q:[19,[15,14,15,-7,-1,-1,15,11,13,13,11,14,8,14,6,13,4,11,3,8,3,6,4,3,6,1,8,0,11,0,13,1,15,3]],r:[13,[4,14,4,0,-1,-1,4,8,5,11,7,13,9,14,12,14]],s:[17,[14,11,13,13,10,14,7,14,4,13,3,11,4,9,6,8,11,7,13,6,14,4,14,3,13,1,10,0,7,0,4,1,3,3]],t:[12,[5,21,5,4,6,1,8,0,10,0,-1,-1,2,14,9,14]],u:[19,[4,14,4,4,5,1,7,0,10,0,12,1,15,4,-1,-1,15,14,15,0]],v:[16,[2,14,8,0,-1,-1,14,14,8,0]],w:[22,[3,14,7,0,-1,-1,11,14,7,0,-1,-1,11,14,15,0,-1,-1,19,14,15,0]],x:[17,[3,14,14,0,-1,-1,14,14,3,0]],y:[16,[2,14,8,0,-1,-1,14,14,8,0,6,-4,4,-6,2,-7,1,-7]],z:[17,[14,14,3,0,-1,-1,3,14,14,14,-1,-1,3,0,14,0]],"{":[14,[9,25,7,24,6,23,5,21,5,19,6,17,7,16,8,14,8,12,6,10,-1,-1,7,24,6,22,6,20,7,18,8,17,9,15,9,13,8,11,4,9,8,7,9,5,9,3,8,1,7,0,6,-2,6,-4,7,-6,-1,-1,6,8,8,6,8,4,7,2,6,1,5,-1,5,-3,6,-5,7,-6,9,-7]],"|":[8,[4,25,4,-7]],"}":[14,[5,25,7,24,8,23,9,21,9,19,8,17,7,16,6,14,6,12,8,10,-1,-1,7,24,8,22,8,20,7,18,6,17,5,15,5,13,6,11,10,9,6,7,5,5,5,3,6,1,7,0,8,-2,8,-4,7,-6,-1,-1,8,8,6,6,6,4,7,2,8,1,9,-1,9,-3,8,-5,7,-6,5,-7]],"~":[24,[3,6,3,8,4,11,6,12,8,12,10,11,14,8,16,7,18,7,20,8,21,10,-1,-1,3,8,4,10,6,11,8,11,10,10,14,7,16,6,18,6,20,7,21,10,21,12]]}},function(O,D,o){function _(m,S){for(var y=0;yp.maxzoom&&(w=p.maxzoom);var k=this.pointCoordinate(this.centerPoint,w),v=new b(k.column-.5,k.row-.5),x=[this.pointCoordinate(new b(0,0),w),this.pointCoordinate(new b(this.width,0),w),this.pointCoordinate(new b(this.width,this.height),w),this.pointCoordinate(new b(0,this.height),w)];return u(w,x,p.reparseOverscaled?A:w,this._renderWorldCopies).sort(function(T,E){return v.dist(T.canonical)-v.dist(E.canonical)})}},{key:"resize",value:function(p,w){this.width=p,this.height=w,this.pixelsToGLUnits=[2/p,-2/w],this._constrain(),this._calcMatrices()}},{key:"zoomScale",value:function(p){return Math.pow(2,p)}},{key:"scaleZoom",value:function(p){return Math.log(p)/Math.LN2}},{key:"project",value:function(p){return new b(this.lngX(p.lng),this.latY(p.lat))}},{key:"unproject",value:function(p){return new e(this.xLng(p.x),this.yLat(p.y))}},{key:"lngX",value:function(p){return(180+p)*this.worldSize/360}},{key:"latY",value:function(p){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+p*Math.PI/360)))*this.worldSize/360}},{key:"xLng",value:function(p){return 360*p/this.worldSize-180}},{key:"yLat",value:function(p){var w=180-360*p/this.worldSize;return 360/Math.PI*Math.atan(Math.exp(w*Math.PI/180))-90}},{key:"setLocationAtPoint",value:function(p,w){var A=this.pointCoordinate(w)._sub(this.pointCoordinate(this.centerPoint));this.center=this.coordinateLocation(this.locationCoordinate(p)._sub(A)),this._renderWorldCopies&&(this.center=this.center.wrap())}},{key:"locationPoint",value:function(p){return this.coordinatePoint(this.locationCoordinate(p))}},{key:"pointLocation",value:function(p){return this.coordinateLocation(this.pointCoordinate(p))}},{key:"locationCoordinate",value:function(p){return new g(this.lngX(p.lng)/this.tileSize,this.latY(p.lat)/this.tileSize,this.zoom).zoomTo(this.tileZoom)}},{key:"coordinateLocation",value:function(p){var w=p.zoomTo(this.zoom);return new e(this.xLng(w.column*this.tileSize),this.yLat(w.row*this.tileSize))}},{key:"pointCoordinate",value:function(p,w){w===void 0&&(w=this.tileZoom);var A=[p.x,p.y,0,1],k=[p.x,p.y,1,1];r.transformMat4(A,A,this.pixelMatrixInverse),r.transformMat4(k,k,this.pixelMatrixInverse);var v=A[3],x=k[3],T=A[1]/v,E=k[1]/x,C=A[2]/v,z=k[2]/x,P=C===z?0:(0-C)/(z-C);return new g(c(A[0]/v,k[0]/x,P)/this.tileSize,c(T,E,P)/this.tileSize,this.zoom)._zoomTo(w)}},{key:"coordinatePoint",value:function(p){var w=p.zoomTo(this.zoom),A=[w.column*this.tileSize,w.row*this.tileSize,0,1];return r.transformMat4(A,A,this.pixelMatrix),new b(A[0]/A[3],A[1]/A[3])}},{key:"calculatePosMatrix",value:function(p){var w=p.key;if(this._posMatrixCache[w])return this._posMatrixCache[w];var A=p.canonical,k=this.worldSize/this.zoomScale(A.z),v=A.x+Math.pow(2,A.z)*p.wrap,x=l.identity(new Float64Array(16));return l.translate(x,x,[v*k,A.y*k,0]),l.scale(x,x,[k/n,k/n,1]),l.multiply(x,this.projMatrix,x),this._posMatrixCache[w]=new Float32Array(x),this._posMatrixCache[w]}},{key:"_constrain",value:function(){if(this.center&&this.width&&this.height&&!this._constraining){this._constraining=!0;var p,w,A,k,v=-90,x=90,T=-180,E=180,C=this.size,z=this._unmodified;if(this.latRange){var P=this.latRange;v=this.latY(P[1]),p=(x=this.latY(P[0]))-vx&&(k=x-W)}if(this.lngRange){var J=this.x,X=C.x/2;J-XE&&(A=E-X)}A===void 0&&k===void 0||(this.center=this.unproject(new b(A!==void 0?A:this.x,k!==void 0?k:this.y))),this._unmodified=z,this._constraining=!1}}},{key:"_calcMatrices",value:function(){if(this.height){this.cameraToCenterDistance=.5/Math.tan(this._fov/2)*this.height;var p=this._fov/2,w=Math.PI/2+this._pitch,A=Math.sin(p)*this.cameraToCenterDistance/Math.sin(Math.PI-w-p),k=1.01*(Math.cos(Math.PI/2-this._pitch)*A+this.cameraToCenterDistance),v=new Float64Array(16);l.perspective(v,this._fov,this.width/this.height,1,k),l.scale(v,v,[1,-1,1]),l.translate(v,v,[0,0,-this.cameraToCenterDistance]),l.rotateX(v,v,this._pitch),l.rotateZ(v,v,this.angle),l.translate(v,v,[-this.x,-this.y,0]);var x=this.worldSize/(2*Math.PI*6378137*Math.abs(Math.cos(this.center.lat*(Math.PI/180))));if(l.scale(v,v,[1,1,x,1]),this.projMatrix=v,v=l.create(),l.scale(v,v,[this.width/2,-this.height/2,1]),l.translate(v,v,[1,-1,0]),this.pixelMatrix=l.multiply(new Float64Array(16),v,this.projMatrix),!(v=l.invert(new Float64Array(16),this.pixelMatrix)))throw new Error("failed to invert matrix");this.pixelMatrixInverse=v,this._posMatrixCache={}}}},{key:"minZoom",get:function(){return this._minZoom},set:function(p){this._minZoom!==p&&(this._minZoom=p,this.zoom=Math.max(this.zoom,p))}},{key:"maxZoom",get:function(){return this._maxZoom},set:function(p){this._maxZoom!==p&&(this._maxZoom=p,this.zoom=Math.min(this.zoom,p))}},{key:"renderWorldCopies",get:function(){return this._renderWorldCopies}},{key:"worldSize",get:function(){return this.tileSize*this.scale}},{key:"centerPoint",get:function(){return this.size._div(2)}},{key:"size",get:function(){return new b(this.width,this.height)}},{key:"bearing",get:function(){return-this.angle/Math.PI*180},set:function(p){var w=-f.wrap(p,-180,180)*Math.PI/180;this.angle!==w&&(this._unmodified=!1,this.angle=w,this._calcMatrices(),this.rotationMatrix=d.create(),d.rotate(this.rotationMatrix,this.rotationMatrix,this.angle))}},{key:"pitch",get:function(){return this._pitch/Math.PI*180},set:function(p){var w=f.clamp(p,0,60)/180*Math.PI;this._pitch!==w&&(this._unmodified=!1,this._pitch=w,this._calcMatrices())}},{key:"fov",get:function(){return this._fov/Math.PI*180},set:function(p){p=Math.max(.01,Math.min(60,p)),this._fov!==p&&(this._unmodified=!1,this._fov=p/180*Math.PI,this._calcMatrices())}},{key:"zoom",get:function(){return this._zoom},set:function(p){var w=Math.min(Math.max(p,this.minZoom),this.maxZoom);this._zoom!==w&&(this._unmodified=!1,this._zoom=w,this.scale=this.zoomScale(w),this.tileZoom=Math.floor(w),this.zoomFraction=w-this.tileZoom,this._constrain(),this._calcMatrices())}},{key:"center",get:function(){return this._center},set:function(p){p.lat===this._center.lat&&p.lng===this._center.lng||(this._unmodified=!1,this._center=p,this._constrain(),this._calcMatrices())}},{key:"unmodified",get:function(){return this._unmodified}},{key:"x",get:function(){return this.lngX(this.center.lng)}},{key:"y",get:function(){return this.latY(this.center.lat)}},{key:"point",get:function(){return new b(this.x,this.y)}}])&&_(S.prototype,y),s&&_(S,s),m}();O.exports=h},function(O,D,o){o(35);var _=o(27).OverscaledTileID;function e(f,c){if(f.row>c.row){var u=f;f=c,c=u}return{x0:f.column,y0:f.row,x1:c.column,y1:c.row,dx:c.column-f.column,dy:c.row-f.row}}function b(f,c,u,i,a){var n=Math.max(u,Math.floor(c.y0)),t=Math.min(i,Math.ceil(c.y1));if(f.x0===c.x0&&f.y0===c.y0?f.x0+c.dy/f.dy*f.dx0,m=c.dx<0,S=n;Sl.dy&&(t=r,r=l,l=t),r.dy>d.dy&&(t=r,r=d,d=t),l.dy>d.dy&&(t=l,l=d,d=t),r.dy&&b(d,r,i,a,n),l.dy&&b(d,l,i,a,n)}O.exports=function(f,c,u,i){i===void 0&&(i=!0);var a=1<=0&&d<=a)for(h=r;h=3&&(this._map.jumpTo({center:[+n[2],+n[1]],zoom:+n[0],bearing:+(n[3]||0),pitch:+(n[4]||0)}),!0)}},{key:"_updateHashUnthrottled",value:function(){var n=this.getHashString();b.history.replaceState("","",n)}}])&&_(u.prototype,i),a&&_(u,a),c}();O.exports=f},function(O,D){O.exports=function(o,_){var e=!1,b=0;return function(){return e=!0,b||function g(){b=0,e&&(o(),b=setTimeout(g,_),e=!1)}(),b}}},function(O,D,o){var _=o(9),e=o(3),b={scrollZoom:o(286),boxZoom:o(287),dragRotate:o(127),dragPan:o(288),keyboard:o(289),doubleClickZoom:o(290),touchZoomRotate:o(291)};O.exports=function(g,f){var c=g.getCanvasContainer(),u=null,i=!1,a=null,n=null;for(var t in b)g[t]=new b[t](g,f),f.interactive&&f[t]&&g[t].enable(f[t]);function r(){n=null}function l(h,m){var S=_.mousePos(c,m);return g.fire(h,{lngLat:g.unproject(S),point:S,originalEvent:m})}function d(h,m){var S=_.touchPos(c,m),y=S.reduce(function(s,p,w,A){return s.add(p.div(A.length))},new e(0,0));return g.fire(h,{lngLat:g.unproject(y),point:y,lngLats:S.map(function(s){return g.unproject(s)},this),points:S,originalEvent:m})}c.addEventListener("mouseout",function(h){l("mouseout",h)},!1),c.addEventListener("mousedown",function(h){g.doubleClickZoom.isActive()||g.stop(),a=_.mousePos(c,h),l("mousedown",h),i=!0},!1),c.addEventListener("mouseup",function(h){var m=g.dragRotate&&g.dragRotate.isActive();u&&!m&&l("contextmenu",u),u=null,i=!1,l("mouseup",h)},!1),c.addEventListener("mousemove",function(h){if(!(g.dragPan&&g.dragPan.isActive())&&!(g.dragRotate&&g.dragRotate.isActive())){for(var m=h.toElement||h.target;m&&m!==c;)m=m.parentNode;m===c&&l("mousemove",h)}},!1),c.addEventListener("touchstart",function(h){g.stop(),d("touchstart",h),!(!h.touches||h.touches.length>1)&&(n?(clearTimeout(n),n=null,l("dblclick",h)):n=setTimeout(r,300))},!1),c.addEventListener("touchend",function(h){d("touchend",h)},!1),c.addEventListener("touchmove",function(h){d("touchmove",h)},!1),c.addEventListener("touchcancel",function(h){d("touchcancel",h)},!1),c.addEventListener("click",function(h){_.mousePos(c,h).equals(a)&&l("click",h)},!1),c.addEventListener("dblclick",function(h){l("dblclick",h),h.preventDefault()},!1),c.addEventListener("contextmenu",function(h){var m=g.dragRotate&&g.dragRotate.isActive();i||m?i&&(u=h):l("contextmenu",h),h.preventDefault()},!1)}},function(O,D,o){function _(n,t){for(var r=0;r400?(this._type=null,this._lastValue=h,this._timeout=setTimeout(this._onTimeout,40)):this._type||(this._type=Math.abs(S*h)<200?"trackpad":"wheel",this._timeout&&(clearTimeout(this._timeout),this._timeout=null,h+=this._lastValue)),d.shiftKey&&h&&(h/=4),this._type&&this._zoom(-h,d),d.preventDefault()}},{key:"_onTimeout",value:function(){this._type="wheel",this._zoom(-this._lastValue)}},{key:"_zoom",value:function(d,h){if(d!==0){var m=this._map,S=2/(1+Math.exp(-Math.abs(d/100)));d<0&&S!==0&&(S=1/S);var y=m.ease?m.ease.to:m.transform.scale,s=m.transform.scaleZoom(y*S);m.zoomTo(s,{duration:this._type==="wheel"?200:0,around:this._aroundCenter?m.getCenter():m.unproject(this._pos),delayEndEvents:200,smoothEasing:!0},{originalEvent:h})}}}])&&_(t.prototype,r),l&&_(t,l),n}();O.exports=a},function(O,D,o){function _(u,i){for(var a=0;a1400&&(w=1400,p._unit()._mult(w));var A=w/750,k=p.mult(-A/2);this._map.panBy(k,{duration:1e3*A,easing:c,noMoveStart:!0},{originalEvent:r})}}}}},{key:"_onMouseUp",value:function(r){this._ignoreEvent(r)||(this._onUp(r),g.document.removeEventListener("mousemove",this._onMove),g.document.removeEventListener("mouseup",this._onMouseUp),g.removeEventListener("blur",this._onMouseUp))}},{key:"_onTouchEnd",value:function(r){this._ignoreEvent(r)||(this._onUp(r),g.document.removeEventListener("touchmove",this._onMove),g.document.removeEventListener("touchend",this._onTouchEnd))}},{key:"_fireEvent",value:function(r,l){return this._map.fire(r,{originalEvent:l})}},{key:"_ignoreEvent",value:function(r){var l=this._map;return!(!l.boxZoom||!l.boxZoom.isActive())||!(!l.dragRotate||!l.dragRotate.isActive())||(r.touches?r.touches.length>1:!!r.ctrlKey||r.type!=="mousemove"&&r.button&&r.button!==0)}},{key:"_drainInertiaBuffer",value:function(){for(var r=this._inertia,l=f.now();r.length>0&&l-r[0][0]>160;)r.shift()}}])&&_(a.prototype,n),t&&_(a,t),i}();O.exports=u},function(O,D,o){function _(f,c){for(var u=0;u.15;Math.abs(y)>10?this._gestureIntent="rotate":w&&(this._gestureIntent="zoom"),this._gestureIntent&&(this._startVec=m,this._startScale=s.transform.scale,this._startBearing=s.transform.bearing)}r.preventDefault()}}},{key:"_onEnd",value:function(r){g.document.removeEventListener("touchmove",this._onMove),g.document.removeEventListener("touchend",this._onEnd),this._drainInertiaBuffer();var l=this._inertia,d=this._map;if(l.length<2)d.snapToNorth({},{originalEvent:r});else{var h=l[l.length-1],m=l[0],S=d.transform.scaleZoom(this._startScale*h[1]),y=d.transform.scaleZoom(this._startScale*m[1]),s=S-y,p=(h[0]-m[0])/1e3,w=h[2];if(p!==0&&S!==y){var A=.15*s/p;Math.abs(A)>2.5&&(A=A>0?2.5:-2.5);var k=1e3*Math.abs(A/(12*.15)),v=S+A*k/2e3;v<0&&(v=0),d.easeTo({zoom:v,duration:k,easing:c,around:this._aroundCenter?d.getCenter():d.unproject(w)},{originalEvent:r})}else d.snapToNorth({},{originalEvent:r})}}},{key:"_drainInertiaBuffer",value:function(){for(var r=this._inertia,l=f.now();r.length>2&&l-r[0][0]>160;)r.shift()}}])&&_(a.prototype,n),t&&_(a,t),i}();O.exports=u},function(O,D,o){function _(d){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(h){return typeof h}:function(h){return h&&typeof Symbol=="function"&&h.constructor===Symbol&&h!==Symbol.prototype?"symbol":typeof h})(d)}function e(d,h){for(var m=0;mW?1:0}),["bottom","left","right","top"]))return c.warnOnce("options.padding must be a positive number, or an Object with keys 'bottom', 'left', 'right', 'top'"),this;s=n.convert(s);var k=[(p.padding.left-p.padding.right)/2,(p.padding.top-p.padding.bottom)/2],v=Math.min(p.padding.right,p.padding.left),x=Math.min(p.padding.top,p.padding.bottom);p.offset=[p.offset[0]+k[0],p.offset[1]+k[1]];var T=t.convert(p.offset),E=this.transform,C=E.project(s.getNorthWest()),z=E.project(s.getSouthEast()),P=z.sub(C),B=(E.width-2*v-2*Math.abs(T.x))/P.x,F=(E.height-2*x-2*Math.abs(T.y))/P.y;return F<0||B<0?(c.warnOnce("Map cannot fit within canvas with the given bounds, padding, and/or offset."),this):(p.center=E.unproject(C.add(z).div(2)),p.zoom=Math.min(E.scaleZoom(E.scale*Math.min(B,F)),p.maxZoom),p.bearing=0,p.linear?this.easeTo(p,w):this.flyTo(p,w))}},{key:"jumpTo",value:function(s,p){this.stop();var w=this.transform,A=!1,k=!1,v=!1;return"zoom"in s&&w.zoom!==+s.zoom&&(A=!0,w.zoom=+s.zoom),s.center!==void 0&&(w.center=a.convert(s.center)),"bearing"in s&&w.bearing!==+s.bearing&&(k=!0,w.bearing=+s.bearing),"pitch"in s&&w.pitch!==+s.pitch&&(v=!0,w.pitch=+s.pitch),this.fire("movestart",p).fire("move",p),A&&this.fire("zoomstart",p).fire("zoom",p).fire("zoomend",p),k&&this.fire("rotate",p),v&&this.fire("pitchstart",p).fire("pitch",p).fire("pitchend",p),this.fire("moveend",p)}},{key:"easeTo",value:function(s,p){var w=this;this.stop(),(s=c.extend({offset:[0,0],duration:500,easing:c.ease},s)).animate===!1&&(s.duration=0),s.smoothEasing&&s.duration!==0&&(s.easing=this._smoothOutEasing(s.duration));var A=this.transform,k=this.getZoom(),v=this.getBearing(),x=this.getPitch(),T="zoom"in s?+s.zoom:k,E="bearing"in s?this._normalizeBearing(s.bearing,v):v,C="pitch"in s?+s.pitch:x,z=A.centerPoint.add(t.convert(s.offset)),P=A.pointLocation(z),B=a.convert(s.center||P);this._normalizeCenter(B);var F,Z,W=A.project(P),J=A.project(B).sub(W),X=A.zoomScale(T-k);return s.around&&(F=a.convert(s.around),Z=A.locationPoint(F)),this.zooming=T!==k,this.rotating=v!==E,this.pitching=C!==x,this._prepareEase(p,s.noMoveStart),clearTimeout(this._onEaseEnd),this._ease(function(R){if(w.zooming&&(A.zoom=u(k,T,R)),w.rotating&&(A.bearing=u(v,E,R)),w.pitching&&(A.pitch=u(x,C,R)),F)A.setLocationAtPoint(F,Z);else{var U=A.zoomScale(A.zoom-k),K=T>k?Math.min(2,X):Math.max(.5,X),q=Math.pow(K,1-R),L=A.unproject(W.add(J.mult(R*q)).mult(U));A.setLocationAtPoint(A.renderWorldCopies?L.wrap():L,z)}w._fireMoveEvents(p)},function(){s.delayEndEvents?w._onEaseEnd=setTimeout(function(){return w._easeToEnd(p)},s.delayEndEvents):w._easeToEnd(p)},s),this}},{key:"_prepareEase",value:function(s,p){this.moving=!0,p||this.fire("movestart",s),this.zooming&&this.fire("zoomstart",s),this.pitching&&this.fire("pitchstart",s)}},{key:"_fireMoveEvents",value:function(s){this.fire("move",s),this.zooming&&this.fire("zoom",s),this.rotating&&this.fire("rotate",s),this.pitching&&this.fire("pitch",s)}},{key:"_easeToEnd",value:function(s){var p=this.zooming,w=this.pitching;this.moving=!1,this.zooming=!1,this.rotating=!1,this.pitching=!1,p&&this.fire("zoomend",s),w&&this.fire("pitchend",s),this.fire("moveend",s)}},{key:"flyTo",value:function(s,p){var w=this;this.stop(),s=c.extend({offset:[0,0],speed:1.2,curve:1.42,easing:c.ease},s);var A=this.transform,k=this.getZoom(),v=this.getBearing(),x=this.getPitch(),T="zoom"in s?c.clamp(+s.zoom,A.minZoom,A.maxZoom):k,E="bearing"in s?this._normalizeBearing(s.bearing,v):v,C="pitch"in s?+s.pitch:x,z=A.zoomScale(T-k),P=A.centerPoint.add(t.convert(s.offset)),B=A.pointLocation(P),F=a.convert(s.center||B);this._normalizeCenter(F);var Z=A.project(B),W=A.project(F).sub(Z),J=s.curve,X=Math.max(A.width,A.height),R=X/z,U=W.mag();if("minZoom"in s){var K=c.clamp(Math.min(s.minZoom,k,T),A.minZoom,A.maxZoom),q=X/A.zoomScale(K-k);J=Math.sqrt(q/U*2)}var L=J*J;function I(Q){var tt=(R*R-X*X+(Q?-1:1)*L*L*U*U)/(2*(Q?R:X)*L*U);return Math.log(Math.sqrt(tt*tt+1)-tt)}function j(Q){return(Math.exp(Q)-Math.exp(-Q))/2}function M(Q){return(Math.exp(Q)+Math.exp(-Q))/2}var N=I(0),V=function(Q){return M(N)/M(N+J*Q)},G=function(Q){return X*((M(N)*(j(tt=N+J*Q)/M(tt))-j(N))/L)/U;var tt},H=(I(1)-N)/J;if(Math.abs(U)<1e-6||!isFinite(H)){if(Math.abs(X-R)<1e-6)return this.easeTo(s,p);var Y=Rs.maxDuration&&(s.duration=0),this.zooming=!0,this.rotating=v!==E,this.pitching=C!==x,this._prepareEase(p,!1),this._ease(function(Q){var tt=Q*H,et=1/V(tt);A.zoom=k+A.scaleZoom(et),w.rotating&&(A.bearing=u(v,E,Q)),w.pitching&&(A.pitch=u(x,C,Q));var nt=A.unproject(Z.add(W.mult(G(tt))).mult(et));A.setLocationAtPoint(A.renderWorldCopies?nt.wrap():nt,P),w._fireMoveEvents(p)},function(){return w._easeToEnd(p)},s),this}},{key:"isEasing",value:function(){return!!this._easeFn}},{key:"isMoving",value:function(){return this.moving}},{key:"stop",value:function(){return this._easeFn&&this._finishEase(),this}},{key:"_ease",value:function(s,p,w){w.animate===!1||w.duration===0?(s(1),p()):(this._easeStart=i.now(),this._easeFn=s,this._finishFn=p,this._easeOptions=w,this._update())}},{key:"_updateEase",value:function(){var s=Math.min((i.now()-this._easeStart)/this._easeOptions.duration,1);this._easeFn(this._easeOptions.easing(s)),s===1&&this._finishEase()}},{key:"_finishEase",value:function(){delete this._easeFn;var s=this._finishFn;delete this._finishFn,s.call(this)}},{key:"_normalizeBearing",value:function(s,p){s=c.wrap(s,-180,180);var w=Math.abs(s-p);return Math.abs(s-360-p)180?-360:w<-180?360:0}}},{key:"_smoothOutEasing",value:function(s){var p=c.ease;if(this._prevEase){var w=this._prevEase,A=(i.now()-w.start)/w.duration,k=w.easing(A+.01)-w.easing(A),v=.27/Math.sqrt(k*k+1e-4)*.01,x=Math.sqrt(.0729-v*v);p=c.bezier(v,x,.25,1)}return this._prevEase={start:i.now(),duration:s,easing:p},p}}])&&e(m.prototype,S),y&&e(m,y),h}();O.exports=l},function(O,D,o){function _(f,c){for(var u=0;u5280){var k=A/5280;f(t,l,k,"mi")}else f(t,l,A,"ft")}else if(r&&r.unit==="nautical"){var v=h/1852;f(t,l,v,"nm")}else f(t,l,h,"m")})(this._map,this._container,this.options)}},{key:"onAdd",value:function(n){return this._map=n,this._container=e.create("div","mapboxgl-ctrl mapboxgl-ctrl-scale",n.getContainer()),this._map.on("move",this._onMove),this._onMove(),this._container}},{key:"onRemove",value:function(){e.remove(this._container),this._map.off("move",this._onMove),this._map=void 0}}])&&_(u.prototype,i),a&&_(u,a),c}();function f(c,u,i,a){var n,t,r,l=(n=i,(t=Math.pow(10,"".concat(Math.floor(n)).length-1))*(r=(r=n/t)>=10?10:r>=5?5:r>=3?3:r>=2?2:1)),d=l/i;a==="m"&&l>=1e3&&(l/=1e3,a="km"),c.style.width="".concat(u*d,"px"),c.innerHTML=l+a}O.exports=g},function(O,D,o){function _(c,u){for(var i=0;ithis._map.transform.height-v?["bottom"]:[],p.xthis._map.transform.width-k/2&&w.push("right"),w=w.length===0?"bottom":w.join("-")}var x=p.add(A[w]).round(),T={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%)"},E=this._container.classList;for(var C in T)E.remove("mapboxgl-popup-anchor-".concat(C));E.add("mapboxgl-popup-anchor-".concat(w)),i.setTransform(this._container,"".concat(T[w]," translate(").concat(x.x,"px,").concat(x.y,"px)"))}}},{key:"_onClickClose",value:function(){this.remove()}}])&&e(S.prototype,y),s&&e(S,s),m}();O.exports=d},function(O,D,o){function _(y){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(s){return typeof s}:function(s){return s&&typeof Symbol=="function"&&s.constructor===Symbol&&s!==Symbol.prototype?"symbol":typeof s})(y)}function e(y,s){for(var p=0;p3&&arguments[3]!==void 0)||arguments[3];return this._queuedConfigChanges.push(function(){return T._style.setPaintProperty(k,v,x)}),E?this._processConfigQueue(++this._configId):function(){return T._processConfigQueue(++T._configId)}}},{key:"setLayoutProperty",value:function(k,v,x){var T=this,E=!(arguments.length>3&&arguments[3]!==void 0)||arguments[3];return this._queuedConfigChanges.push(function(){return T._style.setLayoutProperty(k,v,x)}),E?this._processConfigQueue(++this._configId):function(){return T._processConfigQueue(++T._configId)}}},{key:"setFilter",value:function(k,v){var x=this,T=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2];return this._queuedConfigChanges.push(function(){return x._style.setFilter(k,v)}),T?this._processConfigQueue(++this._configId):function(){return x._processConfigQueue(++x._configId)}}},{key:"_processConfigQueue",value:function(k){var v=this;return this._style.loadedPromise.then(function(){if(v._configId!==k)return!1;for(v._cancelAllPendingRenders();v._queuedConfigChanges.length;)v._queuedConfigChanges.shift()();return v._style.update(new l(16)),v.fire("configChanged"),!0})}},{key:"getLayersVisible",value:function(k,v){var x=this;return Object.keys(this._style._layers).filter(function(T){return x._style.getLayoutProperty(T,"visibility")==="visible"}).filter(function(T){var E,C=(E=x._style._layers[T])&&E._eventedParent.stylesheet.layers.find(function(z){return z.id===E.id});return(!k||C&&(C.minzoom_===void 0||k>=C.minzoom_)&&(C.maxzoom_===void 0||k<=C.maxzoom_))&&(!v||C&&C.source===v)})}},{key:"getLayerOriginalFilter",value:function(k){var v=this._initStyle.layers.find(function(x){return x.id===k});return v&&v.filter}},{key:"getLayerOriginalPaint",value:function(k){var v=this._initStyle.layers.find(function(x){return x.id===k});return v&&v.paint}},{key:"getLayerOriginalLayout",value:function(k){var v=this._initStyle.layers.find(function(x){return x.id===k});return v&&v.layout}},{key:"getVisibleSources",value:function(k){var v=this;return Object.keys(this._style.sourceCaches).filter(function(x){return v.getLayersVisible(v.painter._filterForZoom,x).length>0})}},{key:"filterForZoom",value:function(k){k!==this.painter._filterForZoom&&(this.painter._filterForZoom=k)}},{key:"_cancelAllPendingRenders",value:function(){var k=this;this._pendingRenders.forEach(function(v){return k._finishRender(v.tileSetID,v.renderId,"canceled")}),this._pendingRenders.clear(),Object.values(this._style.sourceCaches).forEach(function(v){return v.invalidateAllLoadedTiles()})}},{key:"_finishRender",value:function(k,v,x){var T=this._pendingRenders.get(k);if(T&&T.renderId===v){for(;T.consumers.length;)T.consumers.shift().next(x);this._pendingRenders.delete(k)}}},{key:"_canonicalizeSpec",value:function(k,v){var x=k.map(function(E){return E.left}).reduce(function(E,C){return Math.min(E,C)},1/0),T=k.map(function(E){return E.top}).reduce(function(E,C){return Math.min(E,C)},1/0);return{tilesSpec:k.map(function(E){return{source:E.source,z:E.z,x:E.x,y:E.y,top:E.top-T,left:E.left-x,size:E.size}}),drawSpec:{srcLeft:v.srcLeft-x,srcTop:v.srcTop-T,width:v.width,height:v.height,destLeft:v.destLeft,destTop:v.destTop}}}},{key:"_tileSpecToString",value:function(k){return k.map(function(v){return"".concat(v.source," ").concat(v.z," ").concat(v.x," ").concat(v.y," ").concat(v.left," ").concat(v.top," ").concat(v.size)}).sort().join(" ")}},{key:"releaseRender",value:function(k){var v=this._pendingRenders.get(k.tileSetID);if(k.tiles.forEach(function(T){return T.cache.releaseTile(T)}),v&&v.renderId===k.renderId){k.consumer.next("canceled");var x=v.consumers.indexOf(k.consumer);x!==-1&&v.consumers.splice(x,1),v.consumers.length===0&&this._finishRender(v.tileSetID,k.renderId,"fully-canceled")}}},{key:"renderTiles",value:function(k,v,x,T){var E=this,C=this._canonicalizeSpec(x,v);v=C.drawSpec,x=C.tilesSpec;var z=this._tileSpecToString(x),P={ctx:k,drawSpec:v,tilesSpec:x,next:T},B=this._pendingRenders.get(z);if(B)return B.tiles.forEach(function(W){return W.uses++}),B.consumers.push(P),{renderId:B.renderId,consumer:P,tiles:B.tiles,tileSetID:z};var F=++this._nextRenderId;B={tileSetID:z,renderId:F,tiles:x.map(function(W){var J=new n(W.z,0,W.z,W.x,W.y,0);return E._style.sourceCaches[W.source].acquireTile(J,W.size)}),consumers:[P]},this._pendingRenders.set(z,B);var Z=[];return Promise.all(B.tiles.map(function(W,J){return W.loadedPromise.catch(function(X){return Z.push(J)})})).catch(function(W){return E._finishRender(z,F,W)}).then(function(){if((B=E._pendingRenders.get(z))&&B.renderId===F){var W=Z.length?"".concat(Z.length," of ").concat(x.length," tiles not available"):null;if(x.length-Z.length==0)return B.consumers.forEach(function(L){return L.ctx.clearRect(v.destLeft,v.destTop,v.width,v.height)}),void E._finishRender(z,F,W);Object.values(E._style.sourceCaches).forEach(function(L){return L.currentlyRenderingTiles=[]}),x.forEach(function(L,I){if(!Z.includes(I)){var j=B.tiles[I];j.tileSize=L.size,j.left=L.left,j.top=L.top,E._style.sourceCaches[L.source].currentlyRenderingTiles.push(j)}});for(var J=B.consumers.map(function(L){return L.drawSpec.srcLeft}).reduce(function(L,I){return Math.min(L,I)},1/0),X=B.consumers.map(function(L){return L.drawSpec.srcTop}).reduce(function(L,I){return Math.min(L,I)},1/0),R=B.consumers.map(function(L){return L.drawSpec.srcLeft+L.drawSpec.width}).reduce(function(L,I){return Math.max(L,I)},-1/0),U=B.consumers.map(function(L){return L.drawSpec.srcTop+L.drawSpec.height}).reduce(function(L,I){return Math.max(L,I)},-1/0),K=function(L){for(var I=function(M){var N=B.consumers.filter(function(V){return V.drawSpec.srcLeft+V.drawSpec.width>L&&V.drawSpec.srcLeftM&&V.drawSpec.srcTop=y.maxzoom_||g(f(n.prototype),"renderLayer",this).call(this,d,h,m,S)}}])&&e(t.prototype,r),l&&e(t,l),n}();O.exports=i},function(O,D,o){function _(t){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r})(t)}function e(t,r){for(var l=0;l0),--h.uses>0||(delete this._tilesInUse[h.tileID.key],h.hasData()||this._isDud?this._tileCache.add(h.tileID.key,h):(this._source.abortTile(h),this._source.unloadTile(h)))}},{key:"invalidateAllLoadedTiles",value:function(){var h=this;Object.values(this._tilesInUse).forEach(function(m){return!m._isDud&&(m.loadedPromise=null)}),this._tileCache.keys().forEach(function(m){var S=h._tileCache.get(m);!S._isDud&&(S.loadedPromise=null)})}},{key:"tilesIn",value:function(h){var m=i.px([h.lng,h.lat],h.tileZ,!1).map(function(A){return A/256}),S=0|m[0],y=0|m[1],s=m.map(function(A){return(A-(0|A))*u}),p=s[0],w=s[1];return Object.values(this._tilesInUse).filter(function(A){return A.hasData()}).map(function(A){return{tile:A,tileID:A.tileID,queryGeometry:[[c.convert([p+u*(S-A.tileID.canonical.x),w+u*(y-A.tileID.canonical.y)])]],scale:1}})}},{key:"reload",value:function(){}},{key:"pause",value:function(){}},{key:"resume",value:function(){}}])&&_(r.prototype,l),d&&_(r,d),t}();O.exports=n},function(O,D,o){"use strict";function _(e,b){this.x=e,this.y=b}O.exports=_,_.prototype={clone:function(){return new _(this.x,this.y)},add:function(e){return this.clone()._add(e)},sub:function(e){return this.clone()._sub(e)},mult:function(e){return this.clone()._mult(e)},div:function(e){return this.clone()._div(e)},rotate:function(e){return this.clone()._rotate(e)},matMult:function(e){return this.clone()._matMult(e)},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(e){return this.x===e.x&&this.y===e.y},dist:function(e){return Math.sqrt(this.distSqr(e))},distSqr:function(e){var b=e.x-this.x,g=e.y-this.y;return b*b+g*g},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(e){return Math.atan2(this.y-e.y,this.x-e.x)},angleWith:function(e){return this.angleWithSep(e.x,e.y)},angleWithSep:function(e,b){return Math.atan2(this.x*b-this.y*e,this.x*e+this.y*b)},_matMult:function(e){var b=e[0]*this.x+e[1]*this.y,g=e[2]*this.x+e[3]*this.y;return this.x=b,this.y=g,this},_add:function(e){return this.x+=e.x,this.y+=e.y,this},_sub:function(e){return this.x-=e.x,this.y-=e.y,this},_mult:function(e){return this.x*=e,this.y*=e,this},_div:function(e){return this.x/=e,this.y/=e,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var e=this.y;return this.y=this.x,this.x=-e,this},_rotate:function(e){var b=Math.cos(e),g=Math.sin(e),f=b*this.x-g*this.y,c=g*this.x+b*this.y;return this.x=f,this.y=c,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},_.convert=function(e){return e instanceof _?e:Array.isArray(e)?new _(e[0],e[1]):e}},function(O,D,o){var _=function(){var e={},b=Math.PI/180,g=180/Math.PI,f=6378137,c=20037508342789244e-9;function u(i){if(i=i||{},this.size=i.size||256,!e[this.size]){var a=this.size,n=e[this.size]={};n.Bc=[],n.Cc=[],n.zc=[],n.Ac=[];for(var t=0;t<30;t++)n.Bc.push(a/360),n.Cc.push(a/(2*Math.PI)),n.zc.push(a/2),n.Ac.push(a),a*=2}this.Bc=e[this.size].Bc,this.Cc=e[this.size].Cc,this.zc=e[this.size].zc,this.Ac=e[this.size].Ac}return u.prototype.px=function(i,a,n){n===void 0&&(n=!0);var t=this.zc[a],r=Math.min(Math.max(Math.sin(b*i[1]),-.9999),.9999),l=t+i[0]*this.Bc[a],d=t+.5*Math.log((1+r)/(1-r))*-this.Cc[a];return n&&(l=Math.round(l),d=Math.round(d)),l>this.Ac[a]&&(l=this.Ac[a]),d>this.Ac[a]&&(d=this.Ac[a]),[l,d]},u.prototype.ll=function(i,a){var n=(i[1]-this.zc[a])/-this.Cc[a];return[(i[0]-this.zc[a])/this.Bc[a],g*(2*Math.atan(Math.exp(n))-.5*Math.PI)]},u.prototype.bbox=function(i,a,n,t,r){t&&(a=Math.pow(2,n)-1-a);var l=[i*this.size,(+a+1)*this.size],d=[(+i+1)*this.size,a*this.size],h=this.ll(l,n).concat(this.ll(d,n));return r==="900913"?this.convert(h,"900913"):h},u.prototype.xyz=function(i,a,n,t){t==="900913"&&(i=this.convert(i,"WGS84"));var r=[i[0],i[1]],l=[i[2],i[3]],d=this.px(r,a),h=this.px(l,a),m=[Math.floor(d[0]/this.size),Math.floor((h[0]-1)/this.size)],S=[Math.floor(h[1]/this.size),Math.floor((d[1]-1)/this.size)],y={minX:Math.min.apply(Math,m)<0?0:Math.min.apply(Math,m),minY:Math.min.apply(Math,S)<0?0:Math.min.apply(Math,S),maxX:Math.max.apply(Math,m),maxY:Math.max.apply(Math,S)};if(n){var s={minY:Math.pow(2,a)-1-y.maxY,maxY:Math.pow(2,a)-1-y.minY};y.minY=s.minY,y.maxY=s.maxY}return y},u.prototype.convert=function(i,a){return a==="900913"?this.forward(i.slice(0,2)).concat(this.forward(i.slice(2,4))):this.inverse(i.slice(0,2)).concat(this.inverse(i.slice(2,4)))},u.prototype.forward=function(i){var a=[f*i[0]*b,f*Math.log(Math.tan(.25*Math.PI+.5*i[1]*b))];return a[0]>c&&(a[0]=c),a[0]<-c&&(a[0]=-c),a[1]>c&&(a[1]=c),a[1]<-c&&(a[1]=-c),a},u.prototype.inverse=function(i){return[i[0]*g/f,(.5*Math.PI-2*Math.atan(Math.exp(-i[1]/f)))*g]},u}();O.exports=_},function(O,D){function o(_){return(o=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})(_)}O.exports=function(_){o(_)==="object"&&Array.isArray(_.layers)&&(_.layers.forEach(function(e){typeof e.minzoom=="number"&&(e.minzoom_=e.minzoom,delete e.minzoom),typeof e.maxzoom=="number"&&(e.maxzoom_=e.maxzoom,delete e.maxzoom)}),_.layers=_.layers.filter(function(e){return e.type!=="raster"&&e.type!=="background"}))}},function(O,D,o){"use strict";function _(b){return!!(typeof window<"u"&&typeof document<"u"&&Array.prototype&&Array.prototype.every&&Array.prototype.filter&&Array.prototype.forEach&&Array.prototype.indexOf&&Array.prototype.lastIndexOf&&Array.prototype.map&&Array.prototype.some&&Array.prototype.reduce&&Array.prototype.reduceRight&&Array.isArray&&Function.prototype&&Function.prototype.bind&&Object.keys&&Object.create&&Object.getPrototypeOf&&Object.getOwnPropertyNames&&Object.isSealed&&Object.isFrozen&&Object.isExtensible&&Object.getOwnPropertyDescriptor&&Object.defineProperty&&Object.defineProperties&&Object.seal&&Object.freeze&&Object.preventExtensions&&"JSON"in window&&"parse"in JSON&&"stringify"in JSON&&"Worker"in window&&"Uint8ClampedArray"in window&&function(g){return e[g]===void 0&&(e[g]=function(f){var c=document.createElement("canvas"),u=Object.create(_.webGLContextAttributes);return u.failIfMajorPerformanceCaveat=f,c.probablySupportsContext?c.probablySupportsContext("webgl",u)||c.probablySupportsContext("experimental-webgl",u):c.supportsContext?c.supportsContext("webgl",u)||c.supportsContext("experimental-webgl",u):c.getContext("webgl",u)||c.getContext("experimental-webgl",u)}(g)),e[g]}(b&&b.failIfMajorPerformanceCaveat))}O.exports?O.exports=_:window&&(window.mapboxgl=window.mapboxgl||{},window.mapboxgl.supported=_);var e={};_.webGLContextAttributes={antialias:!1,alpha:!0,stencil:!0,depth:!0}}]),_t=xt;})();