qd-changjing/public/leaflet/libs/deck.gl/5.1.3/deck.gl.min.js

12 lines
840 KiB
JavaScript
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*!
*
* deck.gl.js (https://github.com/SuperMap/deck.gl.git)
* license: MIT
*
* origin: 'https://github.com/uber/deck.gl.git'
* fork: 'https://github.com/SuperMap/deck.gl.git'
* branch: 'https://github.com/SuperMap/deck.gl/tree/deck.gl-for-iclient'
*
*
*/
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.deckgl=t():e.deckgl=t()}(this,function(){return function(n){var r={};function i(e){if(r[e])return r[e].exports;var t=r[e]={i:e,l:!1,exports:{}};return n[e].call(t.exports,t,t.exports,i),t.l=!0,t.exports}return i.m=n,i.c=r,i.i=function(e){return e},i.d=function(e,t,n){i.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:n})},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,"a",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p="",i(i.s=288)}([function(e,t,n){var v=n(3),g=n(33),y=n(19),_=n(20),m=n(28),b="prototype",E=function(e,t,n){var r,i,o,a,s=e&E.F,u=e&E.G,c=e&E.S,l=e&E.P,f=e&E.B,d=u?v:c?v[t]||(v[t]={}):(v[t]||{})[b],h=u?g:g[t]||(g[t]={}),p=h[b]||(h[b]={});for(r in u&&(n=t),n)o=((i=!s&&d&&void 0!==d[r])?d:n)[r],a=f&&i?m(o,v):l&&"function"==typeof o?m(Function.call,o):o,d&&_(d,r,o,e&E.U),h[r]!=o&&y(h,r,a),l&&p[r]!=o&&(p[r]=o)};v.core=g,E.F=1,E.G=2,E.S=4,E.P=8,E.B=16,E.W=32,E.U=64,E.R=128,e.exports=E},function(E,e,w){"use strict";(function(t){function o(e,t){if(e===t)return 0;for(var n=e.length,r=t.length,i=0,o=Math.min(n,r);i<o;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:r<n?1:0}function a(e){return t.Buffer&&"function"==typeof t.Buffer.isBuffer?t.Buffer.isBuffer(e):!(null==e||!e._isBuffer)}var l=w(684),r=Object.prototype.hasOwnProperty,f=Array.prototype.slice,n="foo"===function(){}.name;function s(e){return Object.prototype.toString.call(e)}function u(e){return!a(e)&&("function"==typeof t.ArrayBuffer&&("function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):!!e&&(e instanceof DataView||!!(e.buffer&&e.buffer instanceof ArrayBuffer))))}var c=E.exports=e,i=/\s*function\s+([^\(\s]*)\s*/;function d(e){if(l.isFunction(e)){if(n)return e.name;var t=e.toString().match(i);return t&&t[1]}}function h(e,t){return"string"==typeof e?e.length<t?e:e.slice(0,t):e}function p(e){if(n||!l.isFunction(e))return l.inspect(e);var t=d(e);return"[Function"+(t?": "+t:"")+"]"}function v(e,t,n,r,i){throw new c.AssertionError({message:n,actual:e,expected:t,operator:r,stackStartFunction:i})}function e(e,t){e||v(e,!0,t,"==",c.ok)}function g(e,t,n,r){if(e===t)return!0;if(a(e)&&a(t))return 0===o(e,t);if(l.isDate(e)&&l.isDate(t))return e.getTime()===t.getTime();if(l.isRegExp(e)&&l.isRegExp(t))return e.source===t.source&&e.global===t.global&&e.multiline===t.multiline&&e.lastIndex===t.lastIndex&&e.ignoreCase===t.ignoreCase;if(null!==e&&"object"==typeof e||null!==t&&"object"==typeof t){if(u(e)&&u(t)&&s(e)===s(t)&&!(e instanceof Float32Array||e instanceof Float64Array))return 0===o(new Uint8Array(e.buffer),new Uint8Array(t.buffer));if(a(e)!==a(t))return!1;var i=(r=r||{actual:[],expected:[]}).actual.indexOf(e);return-1!==i&&i===r.expected.indexOf(t)||(r.actual.push(e),r.expected.push(t),function(e,t,n,r){if(null==e||null==t)return!1;if(l.isPrimitive(e)||l.isPrimitive(t))return e===t;if(n&&Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1;var i=y(e),o=y(t);if(i&&!o||!i&&o)return!1;if(i)return e=f.call(e),t=f.call(t),g(e,t,n);var a,s,u=b(e),c=b(t);if(u.length!==c.length)return!1;for(u.sort(),c.sort(),s=u.length-1;0<=s;s--)if(u[s]!==c[s])return!1;for(s=u.length-1;0<=s;s--)if(a=u[s],!g(e[a],t[a],n,r))return!1;return!0}(e,t,n,r))}return n?e===t:e==t}function y(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function _(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function m(e,t,n,r){var i;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof n&&(r=n,n=null),i=function(e){var t;try{e()}catch(e){t=e}return t}(t),r=(n&&n.name?" ("+n.name+").":".")+(r?" "+r:"."),e&&!i&&v(i,n,"Missing expected exception"+r);var o="string"==typeof r,a=!e&&i&&!n;if((!e&&l.isError(i)&&o&&_(i,n)||a)&&v(i,n,"Got unwanted exception"+r),e&&i&&n&&!_(i,n)||!e&&i)throw i}c.AssertionError=function(e){var t;this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=h(p((t=this).actual),128)+" "+t.operator+" "+h(p(t.expected),128),this.generatedMessage=!0);var n=e.stackStartFunction||v;if(Error.captureStackTrace)Error.captureStackTrace(this,n);else{var r=new Error;if(r.stack){var i=r.stack,o=d(n),a=i.indexOf("\n"+o);if(0<=a){var s=i.indexOf("\n",a+1);i=i.substring(s+1)}this.stack=i}}},l.inherits(c.AssertionError,Error),c.fail=v,c.ok=e,c.equal=function(e,t,n){e!=t&&v(e,t,n,"==",c.equal)},c.notEqual=function(e,t,n){e==t&&v(e,t,n,"!=",c.notEqual)},c.deepEqual=function(e,t,n){g(e,t,!1)||v(e,t,n,"deepEqual",c.deepEqual)},c.deepStrictEqual=function(e,t,n){g(e,t,!0)||v(e,t,n,"deepStrictEqual",c.deepStrictEqual)},c.notDeepEqual=function(e,t,n){g(e,t,!1)&&v(e,t,n,"notDeepEqual",c.notDeepEqual)},c.notDeepStrictEqual=function e(t,n,r){g(t,n,!0)&&v(t,n,r,"notDeepStrictEqual",e)},c.strictEqual=function(e,t,n){e!==t&&v(e,t,n,"===",c.strictEqual)},c.notStrictEqual=function(e,t,n){e===t&&v(e,t,n,"!==",c.notStrictEqual)},c.throws=function(e,t,n){m(!0,e,t,n)},c.doesNotThrow=function(e,t,n){m(!1,e,t,n)},c.ifError=function(e){if(e)throw e};var b=Object.keys||function(e){var t=[];for(var n in e)r.call(e,n)&&t.push(n);return t}}).call(e,w(47))},function(e,t,n){var r=n(5);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){var r=n(98)("wks"),i=n(58),o=n(3).Symbol,a="function"==typeof o;(e.exports=function(e){return r[e]||(r[e]=a&&o[e]||(a?o:i)("Symbol."+e))}).store=r},function(e,t,g){"use strict";g.d(t,"h",function(){return u}),g.d(t,"i",function(){return c}),t.a=l,t.b=x,t.j=function(e){i()(l(e),s)},t.g=function(e){i()(x(e),c)},t.c=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};Object.assign(O,{width:1,height:1},e)},t.d=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e=Object.assign({},O,e),n=t.canvas,r=t.width,i=t.height,o=t.throwOnError,a=t.manageState,s=t.debug;function u(e){if(o)throw new Error(e);return null}var c=void 0;if(w.a){var l=void 0;l=n?"string"==typeof n?g.i(m.d)({id:n}):n:g.i(m.c)({id:"lumagl-canvas",width:r,height:i,onError:u}),c=g.i(m.e)({canvas:l,opts:e})}else c=function(e){var t=e.width,n=e.height,r=e.opts,i=e.onError,o=r.webgl1;if(r.webgl2&&!o)return i("headless-gl does not support WebGL2");if(!y.d)return i(S);if(!P.default.globals.headlessGL)return i(A);var a=P.default.globals.headlessGL(t,n,r);return a||i(T)}({width:r,height:i,opts:e,onError:u});if(!c)return null;a&&g.i(_.a)(c,{copyState:!1,log:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return w.b.log.apply(w.b,[1].concat(t))}});w.a&&s&&(c=g.i(b.a)(c,{debug:s}),w.b.priority=Math.max(w.b.priority,1));return f=c,d=x(f)?"WebGL2":"WebGL1",h=g.i(E.d)(f),p=h?"("+h.vendor+","+h.renderer+")":"",v=f.debug?" debug":"",w.b.once(0,""+d+v+" context "+p),c;var f,d,h,p,v},t.e=function(e){},t.f=function(e){n.a.poll(e)};var y=g(38),_=g(164),m=g(60),b=g(269),E=g(165),n=g(166),w=g(8),P=g(106),r=g(1),i=g.n(r),o=34962,a=32874,s="Invalid WebGLRenderingContext",u=s,c="Requires WebGL2",S="WebGL API is missing. To run luma.gl under Node.js, please \"npm install gl\"\nand import 'luma.gl/headless' before importing 'luma.gl'.",A="Cannot create headless WebGL context, headlessGL not available",T="headlessGL failed to create headless WebGL context";function l(e){return Boolean(e&&(e instanceof y.b||e.ARRAY_BUFFER===o))}function x(e){return Boolean(e&&(e instanceof y.c||e.TEXTURE_BINDING_3D===a))}var O={webgl2:!0,webgl1:!0,throwOnFailure:!0,manageState:!0,canvas:null,debug:!1,width:800,height:600}},function(e,t,n){"use strict";var r=n(262);n.d(t,"a",function(){return r.a});n(660);var i=n(661);n.d(t,"d",function(){return i.a}),n.d(t,"e",function(){return i.b}),n.d(t,"f",function(){return i.c});var o=n(263);n.d(t,"b",function(){return o.a}),n.d(t,"c",function(){return o.b});var a=n(163);n.d(t,"h",function(){return a.c}),n.d(t,"g",function(){return a.d})},function(e,t,n){e.exports=!n(4)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,n){var r=n(2),i=n(207),o=n(37),a=Object.defineProperty;t.f=n(9)?Object.defineProperty:function(e,t,n){if(r(e),t=o(t,!0),r(n),i)try{return a(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){var r=n(36),i=Math.min;e.exports=function(e){return 0<e?i(r(e),9007199254740991):0}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"experimental",function(){return ue});var r=n(25);n.d(t,"GL",function(){return r.a}),n.d(t,"glGet",function(){return r.b}),n.d(t,"glKey",function(){return r.c});var i=n(60);n.d(t,"trackContextCreation",function(){return i.a}),n.d(t,"trackContextState",function(){return i.b});var o=n(7);n.d(t,"isWebGL",function(){return o.a}),n.d(t,"isWebGL2",function(){return o.b}),n.d(t,"setContextDefaults",function(){return o.c}),n.d(t,"createGLContext",function(){return o.d}),n.d(t,"deleteGLContext",function(){return o.e}),n.d(t,"pollContext",function(){return o.f});var a=n(68);n.d(t,"resetParameters",function(){return a.a}),n.d(t,"getParameter",function(){return a.b}),n.d(t,"getParameters",function(){return a.c}),n.d(t,"setParameter",function(){return a.d}),n.d(t,"setParameters",function(){return a.e}),n.d(t,"withParameters",function(){return a.f}),n.d(t,"getModifiedParameters",function(){return a.g});var s=n(165);n.d(t,"getContextInfo",function(){return s.a}),n.d(t,"getGLContextInfo",function(){return s.b}),n.d(t,"getContextLimits",function(){return s.c}),n.d(t,"glGetDebugInfo",function(){return s.d});var u=n(108);n.d(t,"FEATURES",function(){return u.a}),n.d(t,"hasFeature",function(){return u.b}),n.d(t,"hasFeatures",function(){return u.c}),n.d(t,"getFeatures",function(){return u.d});var c=n(269);n.d(t,"makeDebugContext",function(){return c.a});var l=n(267);n.d(t,"installParameterDefinitions",function(){return l.a});var f=n(67);n.d(t,"Buffer",function(){return f.a});var d=n(111);n.d(t,"Shader",function(){return d.a}),n.d(t,"VertexShader",function(){return d.b}),n.d(t,"FragmentShader",function(){return d.c});var h=n(109);n.d(t,"Program",function(){return h.a});var p=n(69);n.d(t,"Framebuffer",function(){return p.a});var v=n(110);n.d(t,"Renderbuffer",function(){return v.a});var g=n(167);n.d(t,"Texture2D",function(){return g.a});var y=n(275);n.d(t,"TextureCube",function(){return y.a});var _=n(270);n.d(t,"draw",function(){return _.a});var m=n(107);n.d(t,"clear",function(){return m.a}),n.d(t,"clearBuffer",function(){return m.b});var b=n(271);n.d(t,"FenceSync",function(){return b.a});var E=n(273);n.d(t,"Query",function(){return E.a});var w=n(274);n.d(t,"Sampler",function(){return w.a});var P=n(668);n.d(t,"Texture3D",function(){return P.a});var S=n(667);n.d(t,"Texture2DArray",function(){return S.a});var A=n(276);n.d(t,"TransformFeedback",function(){return A.a});var T=n(169);n.d(t,"VertexArray",function(){return T.a});var x=n(669);n.d(t,"UniformBufferLayout",function(){return x.a});var O=n(104);n.d(t,"Model",function(){return O.a});var R=n(249);n.d(t,"AnimationLoop",function(){return R.a});var C=n(626);n.d(t,"pickModels",function(){return C.a});var k=n(627);n.d(t,"encodePickingColor",function(){return k.a}),n.d(t,"decodePickingColor",function(){return k.b}),n.d(t,"getNullPickingColor",function(){return k.c});var M=n(641);n.d(t,"addEvents",function(){return M.a});var L=n(45);n.d(t,"Geometry",function(){return L.a});var I=n(251);n.d(t,"ConeGeometry",function(){return I.a});var N=n(252);n.d(t,"CubeGeometry",function(){return N.a});var F=n(253);n.d(t,"CylinderGeometry",function(){return F.a});var j=n(254);n.d(t,"IcoSphereGeometry",function(){return j.a});var D=n(255);n.d(t,"PlaneGeometry",function(){return D.a});var B=n(256);n.d(t,"SphereGeometry",function(){return B.a});var U=n(105);n.d(t,"TruncatedConeGeometry",function(){return U.a});var G=n(633);n.d(t,"Cone",function(){return G.a});var V=n(634);n.d(t,"Cube",function(){return V.a});var z=n(635);n.d(t,"Cylinder",function(){return z.a});var W=n(636);n.d(t,"IcoSphere",function(){return W.a});var X=n(637);n.d(t,"Plane",function(){return X.a});var H=n(638);n.d(t,"Sphere",function(){return H.a});var Y=n(639);n.d(t,"TruncatedCone",function(){return Y.a});var K=n(632);n.d(t,"ClipSpaceQuad",function(){return K.a});var Z=n(630);n.n(Z);n.o(Z,"setPathPrefix")&&n.d(t,"setPathPrefix",function(){return Z.setPathPrefix}),n.o(Z,"loadFile")&&n.d(t,"loadFile",function(){return Z.loadFile}),n.o(Z,"loadImage")&&n.d(t,"loadImage",function(){return Z.loadImage}),n.o(Z,"loadFiles")&&n.d(t,"loadFiles",function(){return Z.loadFiles}),n.o(Z,"loadImages")&&n.d(t,"loadImages",function(){return Z.loadImages}),n.o(Z,"loadTextures")&&n.d(t,"loadTextures",function(){return Z.loadTextures}),n.o(Z,"loadProgram")&&n.d(t,"loadProgram",function(){return Z.loadProgram}),n.o(Z,"loadModel")&&n.d(t,"loadModel",function(){return Z.loadModel}),n.o(Z,"parseModel")&&n.d(t,"parseModel",function(){return Z.parseModel});var q=n(259);n.d(t,"ShaderCache",function(){return q.a});var Q=n(258);n.d(t,"assembleShaders",function(){return Q.a});var J=n(162);n.d(t,"registerShaderModules",function(){return J.a}),n.d(t,"setDefaultShaderModules",function(){return J.b});var $=n(646);n.d(t,"fp32",function(){return $.a});var ee=n(650);n.d(t,"fp64",function(){return ee.a});var te=n(260);n.d(t,"project",function(){return te.a});var ne=n(654);n.d(t,"lighting",function(){return ne.a});var re=n(645);n.d(t,"dirlight",function(){return re.a});var ie=n(656);n.d(t,"picking",function(){return ie.a});var oe=n(644);n.d(t,"diffuse",function(){return oe.a});var ae=n(16);n.d(t,"radians",function(){return ae.radians}),n.d(t,"degrees",function(){return ae.degrees}),n.d(t,"Vector2",function(){return ae.Vector2}),n.d(t,"Vector3",function(){return ae.Vector3}),n.d(t,"Vector4",function(){return ae.Vector4}),n.d(t,"Matrix4",function(){return ae.Matrix4}),n.d(t,"Quaternion",function(){return ae.Quaternion});var se=n(272);n.d(t,"readPixels",function(){return se.a}),n.d(t,"FramebufferObject",function(){return p.a}),n(106);var ue={clearBuffer:m.b}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.experimental=t.lighting=t.project64=t.project=t.OrthographicViewport=t.PerspectiveViewport=t.WebMercatorViewport=t.Viewport=t.CompositeLayer=t.Layer=t.AttributeManager=t.LayerManager=t.COORDINATE_SYSTEM=void 0;var r=n(70);Object.defineProperty(t,"COORDINATE_SYSTEM",{enumerable:!0,get:function(){return r.COORDINATE_SYSTEM}});var i=n(184);Object.defineProperty(t,"LayerManager",{enumerable:!0,get:function(){return G(i).default}});var o=n(182);Object.defineProperty(t,"AttributeManager",{enumerable:!0,get:function(){return G(o).default}});var a=n(123);Object.defineProperty(t,"Layer",{enumerable:!0,get:function(){return G(a).default}});var s=n(337);Object.defineProperty(t,"CompositeLayer",{enumerable:!0,get:function(){return G(s).default}});var u=n(42);Object.defineProperty(t,"Viewport",{enumerable:!0,get:function(){return G(u).default}});var c=n(86);Object.defineProperty(t,"WebMercatorViewport",{enumerable:!0,get:function(){return G(c).default}});var l=n(355);Object.defineProperty(t,"PerspectiveViewport",{enumerable:!0,get:function(){return G(l).default}});var f=n(354);Object.defineProperty(t,"OrthographicViewport",{enumerable:!0,get:function(){return G(f).default}});var d=n(83);Object.defineProperty(t,"project",{enumerable:!0,get:function(){return G(d).default}});var h=n(192);Object.defineProperty(t,"project64",{enumerable:!0,get:function(){return G(h).default}});var p=n(191);Object.defineProperty(t,"lighting",{enumerable:!0,get:function(){return G(p).default}}),n(338),n(190);var v=G(n(333)),g=G(n(179)),y=G(n(82)),_=G(n(121)),m=G(n(178)),b=G(n(353)),E=G(n(356)),w=G(n(85)),P=G(n(341)),S=G(n(188)),A=G(n(189)),T=G(n(181)),x=G(n(122)),O=n(186),R=G(O),C=G(n(125)),k=G(n(346)),M=n(84),L=G(n(17)),I=n(349),N=n(194),F=G(n(347)),j=n(348),D=n(352),B=n(126),U=n(195);function G(e){return e&&e.__esModule?e:{default:e}}t.experimental={ViewportControls:_.default,FirstPersonState:v.default,OrbitState:g.default,MapState:y.default,Controller:_.default,MapController:m.default,FirstPersonViewport:b.default,ThirdPersonViewport:E.default,OrbitViewport:w.default,DeckGLJS:P.default,MapControllerJS:S.default,OrbitControllerJS:A.default,EffectManager:T.default,Effect:x.default,TRANSITION_EVENTS:O.TRANSITION_EVENTS,LinearInterpolator:C.default,ViewportFlyToInterpolator:k.default,TransitionManager:R.default,extractViewportFrom:M.extractViewportFrom,BinSorter:F.default,linearScale:D.linearScale,getLinearScale:D.getLinearScale,quantizeScale:D.quantizeScale,getQuantizeScale:D.getQuantizeScale,clamp:D.clamp,defaultColorRange:j.defaultColorRange,log:L.default,get:I.get,count:N.count,flatten:B.flatten,countVertices:B.countVertices,flattenVertices:B.flattenVertices,fillArray:B.fillArray,enable64bitSupport:U.enable64bitSupport,fp64ify:U.fp64ify,fp64LowPart:U.fp64LowPart}},function(e,t,n){var r=n(34);e.exports=function(e){return Object(r(e))}},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"experimental",function(){return f});var r=n(280);n.d(t,"Vector2",function(){return r.a});var i=n(113);n.d(t,"Vector3",function(){return i.a});var o=n(281);n.d(t,"Vector4",function(){return o.a});var a=n(278);n.d(t,"Matrix4",function(){return a.a});var s=n(279);n.d(t,"Quaternion",function(){return s.a});var u=n(31);n.d(t,"config",function(){return u.a}),n.d(t,"checkNumber",function(){return u.g}),n.d(t,"configure",function(){return u.h}),n.d(t,"formatValue",function(){return u.b}),n.d(t,"isArray",function(){return u.i}),n.d(t,"clone",function(){return u.j}),n.d(t,"radians",function(){return u.d}),n.d(t,"degrees",function(){return u.f}),n.d(t,"sin",function(){return u.k}),n.d(t,"cos",function(){return u.l}),n.d(t,"tan",function(){return u.m}),n.d(t,"asin",function(){return u.n}),n.d(t,"acos",function(){return u.o}),n.d(t,"atan",function(){return u.p}),n.d(t,"clamp",function(){return u.e}),n.d(t,"equals",function(){return u.c});var c=n(670),l=n(671),f={Euler:c.a,SphericalCoordinates:l.a}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=n(1),u=(r=i)&&r.__esModule?r:{default:r};function c(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var l={};function f(e,t){for(var n=arguments.length,r=Array(2<n?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var o,a;((0,u.default)(Number.isFinite(e),"log priority must be a number"),e<=f.priority)&&(r=d.apply(void 0,[t].concat(c(r))),console.debug?(o=console).debug.apply(o,c(r)):(a=console).info.apply(a,c(r)))}function d(e){"function"==typeof e&&(e=e());for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return"string"==typeof e?n.unshift("deck.gl "+e):(n.unshift(e),n.unshift("deck.gl")),n}f.priority=0,(f.log=f).once=function(e,t){for(var n=arguments.length,r=Array(2<n?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var o;!l[t]&&e<=f.priority&&(a=r,a&&0<a.length&&"object"===s(a[0])&&null!==a[0]&&"AssertionError"===a[0].name&&(a=Array.prototype.slice.call(a)).unshift("assert("+a[0].message+")"),r=a,(o=console).error.apply(o,c(d.apply(void 0,[t].concat(c(r))))),l[t]=!0);var a},f.time=function(e,t){(0,u.default)(Number.isFinite(e),"log priority must be a number"),e<=f.priority&&(console.time?console.time(t):console.info(t))},f.timeEnd=function(e,t){(0,u.default)(Number.isFinite(e),"log priority must be a number"),e<=f.priority&&(console.timeEnd?console.timeEnd(t):console.info(t))},f.warn=function(e){if(!l[e]){for(var t,n=arguments.length,r=Array(1<n?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];(t=console).warn.apply(t,["deck.gl: "+e].concat(r)),l[e]=!0}},f.error=function(e){for(var t,n=arguments.length,r=Array(1<n?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];(t=console).error.apply(t,["deck.gl: "+e].concat(r))},f.deprecated=function(e,t){f.warn("`"+e+"` is deprecated and will be removed in a later version. Use `"+t+"` instead")},f.removed=function(e,t){f.error("`"+e+"` is no longer supported. Use `"+t+"` instead, check our upgrade-guide.md for more details")},f.group=function(e,t){var n=(2<arguments.length&&void 0!==arguments[2]?arguments[2]:{}).collapsed;e<=f.priority&&(void 0!==n&&n?console.groupCollapsed("luma.gl: "+t):console.group("luma.gl: "+t))},f.groupEnd=function(e,t){e<=f.priority&&console.groupEnd("luma.gl: "+t)},t.default=f},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t,n){var r=n(10),i=n(54);e.exports=n(9)?function(e,t,n){return r.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var o=n(3),a=n(19),s=n(18),u=n(58)("src"),r="toString",i=Function[r],c=(""+i).split(r);n(33).inspectSource=function(e){return i.call(e)},(e.exports=function(e,t,n,r){var i="function"==typeof n;i&&(s(n,"name")||a(n,"name",t)),e[t]!==n&&(i&&(s(n,u)||a(n,u,e[t]?""+e[t]:c.join(String(t)))),e===o?e[t]=n:r?e[t]?e[t]=n:a(e,t,n):(delete e[t],a(e,t,n)))})(Function.prototype,r,function(){return"function"==typeof this&&this[u]||i.call(this)})},function(e,t,n){var r=n(0),i=n(4),a=n(34),s=/"/g,o=function(e,t,n,r){var i=String(a(e)),o="<"+t;return""!==n&&(o+=" "+n+'="'+String(r).replace(s,"&quot;")+'"'),o+">"+i+"</"+t+">"};e.exports=function(t,e){var n={};n[t]=e(o),r(r.P+r.F*i(function(){var e=""[t]('"');return e!==e.toLowerCase()||3<e.split('"').length}),"String",n)}},function(e,t,n){var r=n(73),i=n(54),o=n(24),a=n(37),s=n(18),u=n(207),c=Object.getOwnPropertyDescriptor;t.f=n(9)?c:function(e,t){if(e=o(e),t=a(t,!0),u)try{return c(e,t)}catch(e){}if(s(e,t))return i(!r.f.call(e,t),e[t])}},function(e,t,n){var r=n(18),i=n(14),o=n(144)("IE_PROTO"),a=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=i(e),r(e,o)?e[o]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?a:null}},function(e,t,n){var r=n(72),i=n(34);e.exports=function(e){return r(i(e))}},function(e,t,n){"use strict";t.b=function(e){return n.i(i.a)(r.a,e)},t.c=function(e){return n.i(i.b)(r.a,e)};var r=n(46),i=n(662);n.d(t,"d",function(){return r.a}),t.a=r.a},function(e,t){var n,r,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(e){n=o}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var u,c=[],l=!1,f=-1;function d(){l&&u&&(l=!1,u.length?c=u.concat(c):f=-1,c.length&&h())}function h(){if(!l){var e=s(d);l=!0;for(var t=c.length;t;){for(u=c,c=[];++f<t;)u&&u[f].run();f=-1,t=c.length}u=null,l=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function v(){}i.nextTick=function(e){var t=new Array(arguments.length-1);if(1<arguments.length)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];c.push(new p(e,t)),1!==c.length||l||s(h)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=v,i.addListener=v,i.once=v,i.off=v,i.removeListener=v,i.removeAllListeners=v,i.emit=v,i.prependListener=v,i.prependOnceListener=v,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t,n){var o=n(15);e.exports=function(r,i,e){if(o(r),void 0===i)return r;switch(e){case 1:return function(e){return r.call(i,e)};case 2:return function(e,t){return r.call(i,e,t)};case 3:return function(e,t,n){return r.call(i,e,t,n)}}return function(){return r.apply(i,arguments)}}},function(e,t,n){"use strict";var r=n(4);e.exports=function(e,t){return!!e&&r(function(){t?e.call(null,function(){},1):e.call(null)})}},function(e,t,g){"use strict";var n=g(106),y=g(7),_=g(25),a=g(8),r=g(1),s=g.n(r),u=g(60),i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var c="Resource subclass must define virtual methods",o=function(){function o(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),g.i(y.j)(e);var n=t.id,r=t.userData,i=void 0===r?{}:r;this.gl=e,this.ext=g.i(u.f)(e),this.id=n||g.i(a.d)(this.constructor.name),this.userData=i,this.opts=t,this._handle=t.handle,void 0===this._handle&&(this._handle=this._createHandle()),this._addStats()}return i(o,[{key:"toString",value:function(){return this.constructor.name+"("+this.id+")"}},{key:"delete",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).deleteChildren,t=void 0!==e&&e,n=this._handle&&this._deleteHandle(this._handle);return this._handle=null,n&&t&&n.filter(Boolean).forEach(function(e){e.delete()}),this}},{key:"unbind",value:function(){this.bind(null)}},{key:"getParameter",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};e=g.i(_.b)(e),s()(e);var n=(this.constructor.PARAMETERS||{})[e];if(n){var r=g.i(y.b)(this.gl);if(!((!("webgl2"in n)||r)&&(!("extension"in n)||this.gl.getExtension(n.extension)))){var i=n.webgl1,o="webgl2"in n?n.webgl2:n.webgl1;return r?o:i}}return this._getParameter(e,t)}},{key:"getParameters",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t={},n=t.parameters,r=t.keys,i=this.constructor.PARAMETERS||{},o=g.i(y.b)(this.gl),a={},s=n||Object.keys(i),u=!0,c=!1,l=void 0;try{for(var f,d=s[Symbol.iterator]();!(u=(f=d.next()).done);u=!0){var h=f.value,p=i[h];if(p&&(!("webgl2"in p)||o)&&(!("extension"in p)||this.gl.getExtension(p.extension))){var v=r?g.i(_.c)(h):h;a[v]=this.getParameter(h,e),r&&"GLenum"===p.type&&(a[v]=g.i(_.c)(a[v]))}}}catch(e){c=!0,l=e}finally{try{!u&&d.return&&d.return()}finally{if(c)throw l}}return a}},{key:"setParameter",value:function(e,t){e=g.i(_.b)(e),s()(e);var n=(this.constructor.PARAMETERS||{})[e];if(n){var r=g.i(y.b)(this.gl);if(!((!("webgl2"in n)||r)&&(!("extension"in n)||this.gl.getExtension(n.extension))))throw new Error("Parameter not available on this platform");"GLenum"===n.type&&(t=g.i(_.b)(t))}return this._setParameter(e,t),this}},{key:"setParameters",value:function(e){for(var t in e)this.setParameter(t,e[t]);return this}},{key:"initialize",value:function(e){}},{key:"_createHandle",value:function(){throw new Error(c)}},{key:"_deleteHandle",value:function(){throw new Error(c)}},{key:"_getOptsFromHandle",value:function(){throw new Error(c)}},{key:"_getParameter",value:function(e,t){throw new Error(c)}},{key:"_setParameter",value:function(e,t){throw new Error(c)}},{key:"_context",value:function(){return this.gl.luma=this.gl.luma||{},this.gl.luma}},{key:"_addStats",value:function(){var e=this.constructor.name,t=n.default.stats;t.resourceCount=t.resourceCount||0,t.resourceMap=t.resourceMap||{},t.resourceCount++,t.resourceMap[e]=t.resourceMap[e]||{count:0},t.resourceMap[e].count++}},{key:"handle",get:function(){return this._handle}}]),o}();t.a=o},function(e,t,n){"use strict";n.d(t,"a",function(){return o}),t.h=function(e){"epsilon"in e&&(o.EPSILON=e.epsilon),"debug"in e&&(o.debug=e.debug)},t.g=function(e){if(!Number.isFinite(e))throw new Error("Invalid number "+e);return e},t.b=function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).precision,n=void 0===t?o.precision||4:t;return e=r(e),parseFloat(e.toPrecision(n))},t.i=i,t.j=a,t.d=function(e){return s(e,function(e){return e/180*Math.PI})},t.f=u,t.k=function(e){return s(e,function(e){return Math.sin(e)})},t.l=function(e){return s(e,function(e){return Math.cos(e)})},t.m=function(e){return s(e,function(e){return Math.tan(e)})},t.n=function(e){return s(e,function(e){return Math.asin(e)})},t.o=function(e){return s(e,function(e){return Math.acos(e)})},t.p=function(e){return s(e,function(e){return Math.atan(e)})},t.e=function(e,t,n){return s(e,function(e){return Math.max(t,Math.min(n,e))})};var o={EPSILON:1e-12,debug:!0,precision:4,printTypes:!(t.c=function e(t,n){var r=Math.abs;if(Array.isArray(t)&&Array.isArray(n)){if(t===n)return!0;if(t.length!==n.length)return!1;for(var i=0;i<t.length;++i)if(!e(t[i],n[i]))return!1;return!0}return r(t-n)<=o.EPSILON*Math.max(1,r(t),r(n))}),printDegrees:!1,printRowMajor:!0};function r(e){return Math.round(e/o.EPSILON)*o.EPSILON}function i(e){return Array.isArray(e)||ArrayBuffer.isView(e)&&void 0!==e.length}function a(e){return e.clone?e.clone():Array(e)}function s(e,t){if(i(e)){for(var n=a(e),r=0;r<n.length;++r)n[r]=t(n[r],r,n);return n}return t(e)}function u(e){return s(e,function(e){return 180*e/Math.PI})}},function(e,t,n){var m=n(28),b=n(72),E=n(14),w=n(11),r=n(129);e.exports=function(f,e){var d=1==f,h=2==f,p=3==f,v=4==f,g=6==f,y=5==f||g,_=e||r;return function(e,t,n){for(var r,i,o=E(e),a=b(o),s=m(t,n,3),u=w(a.length),c=0,l=d?_(e,u):h?_(e,0):void 0;c<u;c++)if((y||c in a)&&(i=s(r=a[c],c,o),f))if(d)l[c]=i;else if(i)switch(f){case 3:return!0;case 5:return r;case 6:return c;case 2:l.push(r)}else if(v)return!1;return g?-1:p||v?v:l}}},function(e,t){var n=e.exports={version:"2.5.3"};"number"==typeof __e&&(__e=n)},function(e,t){e.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,n){var i=n(0),o=n(33),a=n(4);e.exports=function(e,t){var n=(o.Object||{})[e]||Object[e],r={};r[e]=t(n),i(i.S+i.F*a(function(){n(1)}),"Object",r)}},function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(0<e?r:n)(e)}},function(e,t,n){var i=n(5);e.exports=function(e,t){if(!i(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!i(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!i(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!i(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")}},function(e,t,n){"use strict";var r=n(268);n.d(t,"b",function(){return r.a}),n.d(t,"e",function(){return r.d}),n.d(t,"c",function(){return r.b}),n.d(t,"d",function(){return r.c});n(60);var i=n(46);n.d(t,"f",function(){return i.a}),t.a=i.a},function(e,t,n){var o=n(228),r=n(0),i=n(98)("metadata"),a=i.store||(i.store=new(n(231))),s=function(e,t,n){var r=a.get(e);if(!r){if(!n)return;a.set(e,r=new o)}var i=r.get(t);if(!i){if(!n)return;r.set(t,i=new o)}return i};e.exports={store:a,map:s,has:function(e,t,n){var r=s(t,n,!1);return void 0!==r&&r.has(e)},get:function(e,t,n){var r=s(t,n,!1);return void 0===r?void 0:r.get(e)},set:function(e,t,n,r){s(n,r,!0).set(e,t)},keys:function(e,t){var n=s(e,t,!1),r=[];return n&&n.forEach(function(e,t){r.push(t)}),r},key:function(e){return void 0===e||"symbol"==typeof e?e:String(e)},exp:function(e){r(r.S,"Reflect",e)}}},function(e,t,n){"use strict";if(n(9)){var y=n(50),_=n(3),m=n(4),b=n(0),E=n(100),r=n(150),d=n(28),w=n(48),i=n(54),P=n(19),o=n(55),a=n(36),S=n(11),A=n(226),s=n(57),u=n(37),c=n(18),T=n(71),x=n(5),h=n(14),p=n(136),O=n(51),R=n(23),C=n(52).f,v=n(153),l=n(58),f=n(6),g=n(32),k=n(87),M=n(99),L=n(154),I=n(63),N=n(93),F=n(56),j=n(128),D=n(199),B=n(10),U=n(22),G=B.f,V=U.f,z=_.RangeError,W=_.TypeError,X=_.Uint8Array,H="ArrayBuffer",Y="Shared"+H,K="BYTES_PER_ELEMENT",Z="prototype",q=Array[Z],Q=r.ArrayBuffer,J=r.DataView,$=g(0),ee=g(2),te=g(3),ne=g(4),re=g(5),ie=g(6),oe=k(!0),ae=k(!1),se=L.values,ue=L.keys,ce=L.entries,le=q.lastIndexOf,fe=q.reduce,de=q.reduceRight,he=q.join,pe=q.sort,ve=q.slice,ge=q.toString,ye=q.toLocaleString,_e=f("iterator"),me=f("toStringTag"),be=l("typed_constructor"),Ee=l("def_constructor"),we=E.CONSTR,Pe=E.TYPED,Se=E.VIEW,Ae="Wrong length!",Te=g(1,function(e,t){return ke(M(e,e[Ee]),t)}),xe=m(function(){return 1===new X(new Uint16Array([1]).buffer)[0]}),Oe=!!X&&!!X[Z].set&&m(function(){new X(1).set({})}),Re=function(e,t){var n=a(e);if(n<0||n%t)throw z("Wrong offset!");return n},Ce=function(e){if(x(e)&&Pe in e)return e;throw W(e+" is not a typed array!")},ke=function(e,t){if(!(x(e)&&be in e))throw W("It is not a typed array constructor!");return new e(t)},Me=function(e,t){return Le(M(e,e[Ee]),t)},Le=function(e,t){for(var n=0,r=t.length,i=ke(e,r);n<r;)i[n]=t[n++];return i},Ie=function(e,t,n){G(e,t,{get:function(){return this._d[n]}})},Ne=function(e){var t,n,r,i,o,a,s=h(e),u=arguments.length,c=1<u?arguments[1]:void 0,l=void 0!==c,f=v(s);if(null!=f&&!p(f)){for(a=f.call(s),r=[],t=0;!(o=a.next()).done;t++)r.push(o.value);s=r}for(l&&2<u&&(c=d(c,arguments[2],2)),t=0,n=S(s.length),i=ke(this,n);t<n;t++)i[t]=l?c(s[t],t):s[t];return i},Fe=function(){for(var e=0,t=arguments.length,n=ke(this,t);e<t;)n[e]=arguments[e++];return n},je=!!X&&m(function(){ye.call(new X(1))}),De=function(){return ye.apply(je?ve.call(Ce(this)):Ce(this),arguments)},Be={copyWithin:function(e,t){return D.call(Ce(this),e,t,2<arguments.length?arguments[2]:void 0)},every:function(e){return ne(Ce(this),e,1<arguments.length?arguments[1]:void 0)},fill:function(e){return j.apply(Ce(this),arguments)},filter:function(e){return Me(this,ee(Ce(this),e,1<arguments.length?arguments[1]:void 0))},find:function(e){return re(Ce(this),e,1<arguments.length?arguments[1]:void 0)},findIndex:function(e){return ie(Ce(this),e,1<arguments.length?arguments[1]:void 0)},forEach:function(e){$(Ce(this),e,1<arguments.length?arguments[1]:void 0)},indexOf:function(e){return ae(Ce(this),e,1<arguments.length?arguments[1]:void 0)},includes:function(e){return oe(Ce(this),e,1<arguments.length?arguments[1]:void 0)},join:function(e){return he.apply(Ce(this),arguments)},lastIndexOf:function(e){return le.apply(Ce(this),arguments)},map:function(e){return Te(Ce(this),e,1<arguments.length?arguments[1]:void 0)},reduce:function(e){return fe.apply(Ce(this),arguments)},reduceRight:function(e){return de.apply(Ce(this),arguments)},reverse:function(){for(var e,t=this,n=Ce(t).length,r=Math.floor(n/2),i=0;i<r;)e=t[i],t[i++]=t[--n],t[n]=e;return t},some:function(e){return te(Ce(this),e,1<arguments.length?arguments[1]:void 0)},sort:function(e){return pe.call(Ce(this),e)},subarray:function(e,t){var n=Ce(this),r=n.length,i=s(e,r);return new(M(n,n[Ee]))(n.buffer,n.byteOffset+i*n.BYTES_PER_ELEMENT,S((void 0===t?r:s(t,r))-i))}},Ue=function(e,t){return Me(this,ve.call(Ce(this),e,t))},Ge=function(e){Ce(this);var t=Re(arguments[1],1),n=this.length,r=h(e),i=S(r.length),o=0;if(n<i+t)throw z(Ae);for(;o<i;)this[t+o]=r[o++]},Ve={entries:function(){return ce.call(Ce(this))},keys:function(){return ue.call(Ce(this))},values:function(){return se.call(Ce(this))}},ze=function(e,t){return x(e)&&e[Pe]&&"symbol"!=typeof t&&t in e&&String(+t)==String(t)},We=function(e,t){return ze(e,t=u(t,!0))?i(2,e[t]):V(e,t)},Xe=function(e,t,n){return!(ze(e,t=u(t,!0))&&x(n)&&c(n,"value"))||c(n,"get")||c(n,"set")||n.configurable||c(n,"writable")&&!n.writable||c(n,"enumerable")&&!n.enumerable?G(e,t,n):(e[t]=n.value,e)};we||(U.f=We,B.f=Xe),b(b.S+b.F*!we,"Object",{getOwnPropertyDescriptor:We,defineProperty:Xe}),m(function(){ge.call({})})&&(ge=ye=function(){return he.call(this)});var He=o({},Be);o(He,Ve),P(He,_e,Ve.values),o(He,{slice:Ue,set:Ge,constructor:function(){},toString:ge,toLocaleString:De}),Ie(He,"buffer","b"),Ie(He,"byteOffset","o"),Ie(He,"byteLength","l"),Ie(He,"length","e"),G(He,me,{get:function(){return this[Pe]}}),e.exports=function(e,f,t,o){var d=e+((o=!!o)?"Clamped":"")+"Array",n="get"+e,a="set"+e,h=_[d],s=h||{},r=h&&R(h),i=!h||!E.ABV,u={},c=h&&h[Z],p=function(e,i){G(e,i,{get:function(){return e=i,(t=this._d).v[n](e*f+t.o,xe);var e,t},set:function(e){return t=i,n=e,r=this._d,o&&(n=(n=Math.round(n))<0?0:255<n?255:255&n),void r.v[a](t*f+r.o,n,xe);var t,n,r},enumerable:!0})};i?(h=t(function(e,t,n,r){w(e,h,d,"_d");var i,o,a,s,u=0,c=0;if(x(t)){if(!(t instanceof Q||(s=T(t))==H||s==Y))return Pe in t?Le(h,t):Ne.call(h,t);i=t,c=Re(n,f);var l=t.byteLength;if(void 0===r){if(l%f)throw z(Ae);if((o=l-c)<0)throw z(Ae)}else if(l<(o=S(r)*f)+c)throw z(Ae);a=o/f}else a=A(t),i=new Q(o=a*f);for(P(e,"_d",{b:i,o:c,l:o,e:a,v:new J(i)});u<a;)p(e,u++)}),c=h[Z]=O(He),P(c,"constructor",h)):m(function(){h(1)})&&m(function(){new h(-1)})&&N(function(e){new h,new h(null),new h(1.5),new h(e)},!0)||(h=t(function(e,t,n,r){var i;return w(e,h,d),x(t)?t instanceof Q||(i=T(t))==H||i==Y?void 0!==r?new s(t,Re(n,f),r):void 0!==n?new s(t,Re(n,f)):new s(t):Pe in t?Le(h,t):Ne.call(h,t):new s(A(t))}),$(r!==Function.prototype?C(s).concat(C(r)):C(s),function(e){e in h||P(h,e,s[e])}),h[Z]=c,y||(c.constructor=h));var l=c[_e],v=!!l&&("values"==l.name||null==l.name),g=Ve.values;P(h,be,!0),P(c,Pe,d),P(c,Se,!0),P(c,Ee,h),(o?new h(1)[me]==d:me in c)||G(c,me,{get:function(){return d}}),u[d]=h,b(b.G+b.W+b.F*(h!=s),u),b(b.S,d,{BYTES_PER_ELEMENT:f}),b(b.S+b.F*m(function(){s.of.call(h,1)}),d,{from:Ne,of:Fe}),K in c||P(c,K,f),b(b.P,d,Be),F(d),b(b.P+b.F*Oe,d,{set:Ge}),b(b.P+b.F*!v,d,Ve),y||c.toString==ge||(c.toString=ge),b(b.P+b.F*m(function(){new h(1).slice()}),d,{slice:Ue}),b(b.P+b.F*(m(function(){return[1,2].toLocaleString()!=new h([1,2]).toLocaleString()})||!m(function(){c.toLocaleString.call([1,2])})),d,{toLocaleString:De}),I[d]=v?l:g,y||v||P(c,_e,g)}}else e.exports=function(){}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(45);n.d(t,"Geometry",function(){return r.a});var i=n(251);n.d(t,"ConeGeometry",function(){return i.a});var o=n(252);n.d(t,"CubeGeometry",function(){return o.a});var a=n(253);n.d(t,"CylinderGeometry",function(){return a.a});var s=n(254);n.d(t,"IcoSphereGeometry",function(){return s.a});var u=n(255);n.d(t,"PlaneGeometry",function(){return u.a});var c=n(256);n.d(t,"SphereGeometry",function(){return c.a});var l=n(105);n.d(t,"TruncatedConeGeometry",function(){return l.a})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var y=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),a=i(n(17)),s=n(127),F=n(16),u=i(n(77)),c=i(n(78)),l=i(n(75)),f=i(n(156)),j=i(n(76)),D=n(79),B=i(n(1));function i(e){return e&&e.__esModule?e:{default:e}}var U=[0,0,0],G=(0,s.createMat4)(),V={pixelsPerMeter:[1,1,1],metersPerPixel:[1,1,1],pixelsPerDegree:[1,1,1],degreesPerPixel:[1,1,1]},o=function(){function N(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,N);var t=e.id,n=void 0===t?null:t,r=e.x,i=void 0===r?0:r,o=e.y,a=void 0===o?0:o,s=e.width,u=void 0===s?1:s,c=e.height,l=void 0===c?1:c,f=e.viewMatrix,d=void 0===f?G:f,h=e.projectionMatrix,p=void 0===h?null:h,v=e.fovy,g=void 0===v?75:v,y=e.near,_=void 0===y?.1:y,m=e.far,b=void 0===m?1e3:m,E=e.longitude,w=void 0===E?null:E,P=e.latitude,S=void 0===P?null:P,A=e.zoom,T=void 0===A?null:A,x=e.position,O=void 0===x?null:x,R=e.modelMatrix,C=void 0===R?null:R,k=e.distanceScales,M=void 0===k?null:k;if(this.isGeographicCoordinateSystem=e.isGeographicCoordinateSystem,this.id=n||this.constructor.displayName||"viewport",this.isGeospatial=Number.isFinite(S)&&Number.isFinite(w),this.x=i,this.y=a,this.width=u||1,this.height=l||1,this.zoom=T,Number.isFinite(this.zoom)||(this.zoom=this.isGeospatial?(0,D.getMeterZoom)({latitude:S}):0),this.scale=Math.pow(2,this.zoom),this.distanceScales=this.isGeospatial?(0,D.getDistanceScales)({latitude:S,longitude:w,scale:this.scale,isGeographicCoordinateSystem:this.isGeographicCoordinateSystem}):M||V,this.focalDistance=e.focalDistance||1,this.distanceScales.metersPerPixel=new F.Vector3(this.distanceScales.metersPerPixel),this.distanceScales.pixelsPerMeter=new F.Vector3(this.distanceScales.pixelsPerMeter),this.position=U,this.meterOffset=U,O&&(this.position=O,this.modelMatrix=C,this.meterOffset=C?C.transformVector(O):O),this.viewMatrixUncentered=d,this.isGeospatial?(this.center=(0,D.getWorldPosition)({longitude:w,latitude:S,scale:this.scale,distanceScales:this.distanceScales,meterOffset:this.meterOffset}),this.viewMatrix=(new F.Matrix4).multiplyRight(this.viewMatrixUncentered).scale([1,-1,1]).translate(new F.Vector3(this.center||U).negate())):(this.center=O,this.viewMatrix=d),p)this.projectionMatrix=p;else{(0,B.default)(Number.isFinite(g));var L=g*(Math.PI/180),I=this.width/this.height;this.projectionMatrix=(0,j.default)([],L,I,_,b)}this._initMatrices(),this.equals=this.equals.bind(this),this.project=this.project.bind(this),this.unproject=this.unproject.bind(this),this.projectFlat=this.projectFlat.bind(this),this.unprojectFlat=this.unprojectFlat.bind(this),this.getMatrices=this.getMatrices.bind(this)}return r(N,[{key:"equals",value:function(e){return e instanceof N&&(e.width===this.width&&e.height===this.height&&(0,F.equals)(e.projectionMatrix,this.projectionMatrix)&&(0,F.equals)(e.viewMatrix,this.viewMatrix))}},{key:"project",value:function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).topLeft,n=void 0===t||t,r=y(e,3),i=r[0],o=r[1],a=r[2],s=void 0===a?0:a,u=this.projectFlat([i,o]),c=y(u,2),l=c[0],f=c[1],d=(0,D.worldToPixels)([l,f,s],this.pixelProjectionMatrix),h=y(d,2),p=h[0],v=h[1],g=n?v:this.height-v;return 2===e.length?[p,g]:[p,g,d[2]]}},{key:"unproject",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.topLeft,r=void 0===n||n,i=t.targetZ,o=y(e,3),a=o[0],s=o[1],u=o[2],c=r?s:this.height-s,l=(0,D.pixelsToWorld)([a,c,u],this.pixelUnprojectionMatrix,i),f=this.unprojectFlat(l),d=y(f,2),h=d[0],p=d[1];return Number.isFinite(u)?[h,p,l[2]]:Number.isFinite(i)?[h,p,i]:[h,p]}},{key:"projectFlat",value:function(e){var t=y(e,2);t[0],t[1],1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return this._projectFlat.apply(this,arguments)}},{key:"unprojectFlat",value:function(e){1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return this._unprojectFlat.apply(this,arguments)}},{key:"_projectFlat",value:function(e){1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return e}},{key:"_unprojectFlat",value:function(e){1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return e}},{key:"getMercatorParams",value:function(){var e=this._addMetersToLngLat([this.longitude||0,this.latitude||0],this.meterOffset);return{longitude:e[0],latitude:e[1]}}},{key:"isMapSynched",value:function(){return!1}},{key:"getDistanceScales",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return e?(0,D.getDistanceScales)({longitude:e[0],latitude:e[1],scale:this.scale,highPrecision:!0}):this.distanceScales}},{key:"getMatrices",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).modelMatrix,t=void 0===e?null:e,n=this.viewProjectionMatrix,r=this.pixelProjectionMatrix,i=this.pixelUnprojectionMatrix;return t&&(n=(0,l.default)([],this.viewProjectionMatrix,t),r=(0,l.default)([],this.pixelProjectionMatrix,t),i=(0,f.default)([],r)),Object.assign({modelViewProjectionMatrix:n,viewProjectionMatrix:this.viewProjectionMatrix,viewMatrix:this.viewMatrix,projectionMatrix:this.projectionMatrix,pixelProjectionMatrix:r,pixelUnprojectionMatrix:i,width:this.width,height:this.height,scale:this.scale})}},{key:"getCameraPosition",value:function(){return this.cameraPosition}},{key:"getCameraDirection",value:function(){return this.cameraDirection}},{key:"getCameraUp",value:function(){return this.cameraUp}},{key:"_addMetersToLngLat",value:function(e,t){var n=y(e,3),r=n[0],i=n[1],o=n[2],a=void 0===o?0:o,s=this._metersToLngLatDelta(t),u=y(s,3),c=u[0],l=u[1],f=u[2],d=void 0===f?0:f;return 2===e.length?[r+c,i+l]:[r+c,i+l,a+d]}},{key:"_metersToLngLatDelta",value:function(e){var t=y(e,3),n=t[0],r=t[1],i=t[2],o=void 0===i?0:i;(0,B.default)(Number.isFinite(n)&&Number.isFinite(r)&&Number.isFinite(o),"Illegal argument to Viewport");var a=this.distanceScales,s=a.pixelsPerMeter,u=a.degreesPerPixel,c=n*s[0]*u[0],l=r*s[1]*u[1];return 2===e.length?[c,l]:[c,l,o]}},{key:"_initMatrices",value:function(){var e=(0,s.createMat4)();(0,l.default)(e,e,this.projectionMatrix),(0,l.default)(e,e,this.viewMatrix),this.viewProjectionMatrix=e,this.viewMatrixInverse=(0,f.default)([],this.viewMatrix)||this.viewMatrix;var t=(0,s.extractCameraVectors)({viewMatrix:this.viewMatrix,viewMatrixInverse:this.viewMatrixInverse}),n=t.eye,r=t.direction,i=t.up;this.cameraPosition=n,this.cameraDirection=r,this.cameraUp=i;var o=(0,s.createMat4)();(0,u.default)(o,o,[this.width/2,-this.height/2,1]),(0,c.default)(o,o,[1,-1,0]),(0,l.default)(o,o,this.viewProjectionMatrix),this.pixelProjectionMatrix=o,this.pixelUnprojectionMatrix=(0,f.default)((0,s.createMat4)(),this.pixelProjectionMatrix),this.pixelUnprojectionMatrix||a.default.warn("Pixel project matrix not invertible")}}]),N}();(t.default=o).displayName="Viewport"},function(e,t,n){var r=n(6)("unscopables"),i=Array.prototype;null==i[r]&&n(19)(i,r,{}),e.exports=function(e){i[r][e]=!0}},function(e,t,n){var r=n(58)("meta"),i=n(5),o=n(18),a=n(10).f,s=0,u=Object.isExtensible||function(){return!0},c=!n(4)(function(){return u(Object.preventExtensions({}))}),l=function(e){a(e,r,{value:{i:"O"+ ++s,w:{}}})},f=e.exports={KEY:r,NEED:!1,fastKey:function(e,t){if(!i(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!o(e,r)){if(!u(e))return"F";if(!t)return"E";l(e)}return e[r].i},getWeak:function(e,t){if(!o(e,r)){if(!u(e))return!0;if(!t)return!1;l(e)}return e[r].w},onFreeze:function(e){return c&&f.NEED&&u(e)&&!o(e,r)&&l(e),e}}},function(e,t,u){"use strict";t.b=f;var c=u(8),n=u(1),r=u.n(n),i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var l={POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6};function f(e){var t="string"==typeof e?l[e]||l.TRIANGLES:e;return r()(0<=t&&t<=l.TRIANGLE_FAN,"Illegal drawMode"),t}var o=function(){function s(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);var t=e.id,n=e.drawMode,r=void 0===n?l.TRIANGLES:n,i=e.vertexCount,o=void 0===i?void 0:i,a=e.attributes;this.id=t||u.i(c.d)(this.constructor.name),this.drawMode=f(r),this.vertexCount=o,this.attributes={},this.needsRedraw=!0,this.userData={},Object.seal(this),a&&this.setAttributes(a)}return i(s,[{key:"setNeedsRedraw",value:function(){var e=!(0<arguments.length&&void 0!==arguments[0])||arguments[0];return this.needsRedraw=e,this}},{key:"getNeedsRedraw",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).clearRedrawFlags,t=void 0!==e&&e,n=!1;return n=n||this.needsRedraw,this.needsRedraw=this.needsRedraw&&!t,n}},{key:"setVertexCount",value:function(e){this.vertexCount=e}},{key:"getVertexCount",value:function(){return void 0!==this.vertexCount?this.vertexCount:this.attributes.indices?this.attributes.indices.value.length:this.attributes.vertices?this.attributes.vertices.value.length/3:!!this.attributes.positions&&this.attributes.positions.value.length/3}},{key:"hasAttribute",value:function(e){return Boolean(this.attributes[e])}},{key:"getAttribute",value:function(e){var t=this.attributes[e];return r()(t),t.value}},{key:"getArray",value:function(e){var t=this.attributes[e];return r()(t),t.value}},{key:"getAttributes",value:function(){return this.attributes}},{key:"setAttributes",value:function(e){for(var t in e){var n=e[t];n=ArrayBuffer.isView(n)?{value:n}:n,r()(ArrayBuffer.isView(n.value),this._print(t)+": must be typed array or object with value as typed array"),this._autoDetectAttribute(t,n),this.attributes[t]=Object.assign({},n,{instanced:n.instanced||0})}return this.setNeedsRedraw(),this}},{key:"_autoDetectAttribute",value:function(e,t){var n=void 0;switch(e){case"indices":n=n||"indices";break;case"texCoords":case"texCoord1":case"texCoord2":case"texCoord3":n="uvs";break;case"vertices":case"positions":case"normals":case"pickingColors":n="vectors"}switch(n){case"vectors":t.size=t.size||3;break;case"uvs":t.size=t.size||2;break;case"indices":t.size=t.size||1,t.isIndexed=t.isIndexed||!0,r()(t.value instanceof Uint16Array||t.value instanceof Uint32Array,'attribute array for "indices" must be of integer type')}r()(t.size,"attribute "+e+" needs size")}},{key:"_print",value:function(e){return"Geometry "+this.id+" attribute "+e}}]),s}();t.a=o},function(e,t,n){"use strict";t.a={DEPTH_BUFFER_BIT:256,STENCIL_BUFFER_BIT:1024,COLOR_BUFFER_BIT:16384,POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6,ZERO:0,ONE:1,SRC_COLOR:768,ONE_MINUS_SRC_COLOR:769,SRC_ALPHA:770,ONE_MINUS_SRC_ALPHA:771,DST_ALPHA:772,ONE_MINUS_DST_ALPHA:773,DST_COLOR:774,ONE_MINUS_DST_COLOR:775,SRC_ALPHA_SATURATE:776,CONSTANT_COLOR:32769,ONE_MINUS_CONSTANT_COLOR:32770,CONSTANT_ALPHA:32771,ONE_MINUS_CONSTANT_ALPHA:32772,FUNC_ADD:32774,FUNC_SUBTRACT:32778,FUNC_REVERSE_SUBTRACT:32779,BLEND_EQUATION:32777,BLEND_EQUATION_RGB:32777,BLEND_EQUATION_ALPHA:34877,BLEND_DST_RGB:32968,BLEND_SRC_RGB:32969,BLEND_DST_ALPHA:32970,BLEND_SRC_ALPHA:32971,BLEND_COLOR:32773,ARRAY_BUFFER_BINDING:34964,ELEMENT_ARRAY_BUFFER_BINDING:34965,LINE_WIDTH:2849,ALIASED_POINT_SIZE_RANGE:33901,ALIASED_LINE_WIDTH_RANGE:33902,CULL_FACE_MODE:2885,FRONT_FACE:2886,DEPTH_RANGE:2928,DEPTH_WRITEMASK:2930,DEPTH_CLEAR_VALUE:2931,DEPTH_FUNC:2932,STENCIL_CLEAR_VALUE:2961,STENCIL_FUNC:2962,STENCIL_FAIL:2964,STENCIL_PASS_DEPTH_FAIL:2965,STENCIL_PASS_DEPTH_PASS:2966,STENCIL_REF:2967,STENCIL_VALUE_MASK:2963,STENCIL_WRITEMASK:2968,STENCIL_BACK_FUNC:34816,STENCIL_BACK_FAIL:34817,STENCIL_BACK_PASS_DEPTH_FAIL:34818,STENCIL_BACK_PASS_DEPTH_PASS:34819,STENCIL_BACK_REF:36003,STENCIL_BACK_VALUE_MASK:36004,STENCIL_BACK_WRITEMASK:36005,VIEWPORT:2978,SCISSOR_BOX:3088,COLOR_CLEAR_VALUE:3106,COLOR_WRITEMASK:3107,UNPACK_ALIGNMENT:3317,PACK_ALIGNMENT:3333,MAX_TEXTURE_SIZE:3379,MAX_VIEWPORT_DIMS:3386,SUBPIXEL_BITS:3408,RED_BITS:3410,GREEN_BITS:3411,BLUE_BITS:3412,ALPHA_BITS:3413,DEPTH_BITS:3414,STENCIL_BITS:3415,POLYGON_OFFSET_UNITS:10752,POLYGON_OFFSET_FACTOR:32824,TEXTURE_BINDING_2D:32873,SAMPLE_BUFFERS:32936,SAMPLES:32937,SAMPLE_COVERAGE_VALUE:32938,SAMPLE_COVERAGE_INVERT:32939,COMPRESSED_TEXTURE_FORMATS:34467,VENDOR:7936,RENDERER:7937,VERSION:7938,IMPLEMENTATION_COLOR_READ_TYPE:35738,IMPLEMENTATION_COLOR_READ_FORMAT:35739,BROWSER_DEFAULT_WEBGL:37444,STATIC_DRAW:35044,STREAM_DRAW:35040,DYNAMIC_DRAW:35048,ARRAY_BUFFER:34962,ELEMENT_ARRAY_BUFFER:34963,BUFFER_SIZE:34660,BUFFER_USAGE:34661,CURRENT_VERTEX_ATTRIB:34342,VERTEX_ATTRIB_ARRAY_ENABLED:34338,VERTEX_ATTRIB_ARRAY_SIZE:34339,VERTEX_ATTRIB_ARRAY_STRIDE:34340,VERTEX_ATTRIB_ARRAY_TYPE:34341,VERTEX_ATTRIB_ARRAY_NORMALIZED:34922,VERTEX_ATTRIB_ARRAY_POINTER:34373,VERTEX_ATTRIB_ARRAY_BUFFER_BINDING:34975,CULL_FACE:2884,FRONT:1028,BACK:1029,FRONT_AND_BACK:1032,BLEND:3042,DEPTH_TEST:2929,DITHER:3024,POLYGON_OFFSET_FILL:32823,SAMPLE_ALPHA_TO_COVERAGE:32926,SAMPLE_COVERAGE:32928,SCISSOR_TEST:3089,STENCIL_TEST:2960,NO_ERROR:0,INVALID_ENUM:1280,INVALID_VALUE:1281,INVALID_OPERATION:1282,OUT_OF_MEMORY:1285,CONTEXT_LOST_WEBGL:37442,CW:2304,CCW:2305,DONT_CARE:4352,FASTEST:4353,NICEST:4354,GENERATE_MIPMAP_HINT:33170,BYTE:5120,UNSIGNED_BYTE:5121,SHORT:5122,UNSIGNED_SHORT:5123,INT:5124,UNSIGNED_INT:5125,FLOAT:5126,DEPTH_COMPONENT:6402,ALPHA:6406,RGB:6407,RGBA:6408,LUMINANCE:6409,LUMINANCE_ALPHA:6410,UNSIGNED_SHORT_4_4_4_4:32819,UNSIGNED_SHORT_5_5_5_1:32820,UNSIGNED_SHORT_5_6_5:33635,FRAGMENT_SHADER:35632,VERTEX_SHADER:35633,COMPILE_STATUS:35713,DELETE_STATUS:35712,LINK_STATUS:35714,VALIDATE_STATUS:35715,ATTACHED_SHADERS:35717,ACTIVE_ATTRIBUTES:35721,ACTIVE_UNIFORMS:35718,MAX_VERTEX_ATTRIBS:34921,MAX_VERTEX_UNIFORM_VECTORS:36347,MAX_VARYING_VECTORS:36348,MAX_COMBINED_TEXTURE_IMAGE_UNITS:35661,MAX_VERTEX_TEXTURE_IMAGE_UNITS:35660,MAX_TEXTURE_IMAGE_UNITS:34930,MAX_FRAGMENT_UNIFORM_VECTORS:36349,SHADER_TYPE:35663,SHADING_LANGUAGE_VERSION:35724,CURRENT_PROGRAM:35725,NEVER:512,ALWAYS:519,LESS:513,EQUAL:514,LEQUAL:515,GREATER:516,GEQUAL:518,NOTEQUAL:517,KEEP:7680,REPLACE:7681,INCR:7682,DECR:7683,INVERT:5386,INCR_WRAP:34055,DECR_WRAP:34056,NEAREST:9728,LINEAR:9729,NEAREST_MIPMAP_NEAREST:9984,LINEAR_MIPMAP_NEAREST:9985,NEAREST_MIPMAP_LINEAR:9986,LINEAR_MIPMAP_LINEAR:9987,TEXTURE_MAG_FILTER:10240,TEXTURE_MIN_FILTER:10241,TEXTURE_WRAP_S:10242,TEXTURE_WRAP_T:10243,TEXTURE_2D:3553,TEXTURE:5890,TEXTURE_CUBE_MAP:34067,TEXTURE_BINDING_CUBE_MAP:34068,TEXTURE_CUBE_MAP_POSITIVE_X:34069,TEXTURE_CUBE_MAP_NEGATIVE_X:34070,TEXTURE_CUBE_MAP_POSITIVE_Y:34071,TEXTURE_CUBE_MAP_NEGATIVE_Y:34072,TEXTURE_CUBE_MAP_POSITIVE_Z:34073,TEXTURE_CUBE_MAP_NEGATIVE_Z:34074,MAX_CUBE_MAP_TEXTURE_SIZE:34076,TEXTURE0:33984,ACTIVE_TEXTURE:34016,REPEAT:10497,CLAMP_TO_EDGE:33071,MIRRORED_REPEAT:33648,TEXTURE_WIDTH:4096,TEXTURE_HEIGHT:4097,FLOAT_VEC2:35664,FLOAT_VEC3:35665,FLOAT_VEC4:35666,INT_VEC2:35667,INT_VEC3:35668,INT_VEC4:35669,BOOL:35670,BOOL_VEC2:35671,BOOL_VEC3:35672,BOOL_VEC4:35673,FLOAT_MAT2:35674,FLOAT_MAT3:35675,FLOAT_MAT4:35676,SAMPLER_2D:35678,SAMPLER_CUBE:35680,LOW_FLOAT:36336,MEDIUM_FLOAT:36337,HIGH_FLOAT:36338,LOW_INT:36339,MEDIUM_INT:36340,HIGH_INT:36341,FRAMEBUFFER:36160,RENDERBUFFER:36161,RGBA4:32854,RGB5_A1:32855,RGB565:36194,DEPTH_COMPONENT16:33189,STENCIL_INDEX:6401,STENCIL_INDEX8:36168,DEPTH_STENCIL:34041,RENDERBUFFER_WIDTH:36162,RENDERBUFFER_HEIGHT:36163,RENDERBUFFER_INTERNAL_FORMAT:36164,RENDERBUFFER_RED_SIZE:36176,RENDERBUFFER_GREEN_SIZE:36177,RENDERBUFFER_BLUE_SIZE:36178,RENDERBUFFER_ALPHA_SIZE:36179,RENDERBUFFER_DEPTH_SIZE:36180,RENDERBUFFER_STENCIL_SIZE:36181,FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE:36048,FRAMEBUFFER_ATTACHMENT_OBJECT_NAME:36049,FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL:36050,FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE:36051,COLOR_ATTACHMENT0:36064,DEPTH_ATTACHMENT:36096,STENCIL_ATTACHMENT:36128,DEPTH_STENCIL_ATTACHMENT:33306,NONE:0,FRAMEBUFFER_COMPLETE:36053,FRAMEBUFFER_INCOMPLETE_ATTACHMENT:36054,FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:36055,FRAMEBUFFER_INCOMPLETE_DIMENSIONS:36057,FRAMEBUFFER_UNSUPPORTED:36061,FRAMEBUFFER_BINDING:36006,RENDERBUFFER_BINDING:36007,READ_FRAMEBUFFER:36008,DRAW_FRAMEBUFFER:36009,MAX_RENDERBUFFER_SIZE:34024,INVALID_FRAMEBUFFER_OPERATION:1286,UNPACK_FLIP_Y_WEBGL:37440,UNPACK_PREMULTIPLY_ALPHA_WEBGL:37441,UNPACK_COLORSPACE_CONVERSION_WEBGL:37443,READ_BUFFER:3074,UNPACK_ROW_LENGTH:3314,UNPACK_SKIP_ROWS:3315,UNPACK_SKIP_PIXELS:3316,PACK_ROW_LENGTH:3330,PACK_SKIP_ROWS:3331,PACK_SKIP_PIXELS:3332,TEXTURE_BINDING_3D:32874,UNPACK_SKIP_IMAGES:32877,UNPACK_IMAGE_HEIGHT:32878,MAX_3D_TEXTURE_SIZE:32883,MAX_ELEMENTS_VERTICES:33e3,MAX_ELEMENTS_INDICES:33001,MAX_TEXTURE_LOD_BIAS:34045,MAX_FRAGMENT_UNIFORM_COMPONENTS:35657,MAX_VERTEX_UNIFORM_COMPONENTS:35658,MAX_ARRAY_TEXTURE_LAYERS:35071,MIN_PROGRAM_TEXEL_OFFSET:35076,MAX_PROGRAM_TEXEL_OFFSET:35077,MAX_VARYING_COMPONENTS:35659,FRAGMENT_SHADER_DERIVATIVE_HINT:35723,RASTERIZER_DISCARD:35977,VERTEX_ARRAY_BINDING:34229,MAX_VERTEX_OUTPUT_COMPONENTS:37154,MAX_FRAGMENT_INPUT_COMPONENTS:37157,MAX_SERVER_WAIT_TIMEOUT:37137,MAX_ELEMENT_INDEX:36203,RED:6403,RGB8:32849,RGBA8:32856,RGB10_A2:32857,TEXTURE_3D:32879,TEXTURE_WRAP_R:32882,TEXTURE_MIN_LOD:33082,TEXTURE_MAX_LOD:33083,TEXTURE_BASE_LEVEL:33084,TEXTURE_MAX_LEVEL:33085,TEXTURE_COMPARE_MODE:34892,TEXTURE_COMPARE_FUNC:34893,SRGB:35904,SRGB8:35905,SRGB8_ALPHA8:35907,COMPARE_REF_TO_TEXTURE:34894,RGBA32F:34836,RGB32F:34837,RGBA16F:34842,RGB16F:34843,TEXTURE_2D_ARRAY:35866,TEXTURE_BINDING_2D_ARRAY:35869,R11F_G11F_B10F:35898,RGB9_E5:35901,RGBA32UI:36208,RGB32UI:36209,RGBA16UI:36214,RGB16UI:36215,RGBA8UI:36220,RGB8UI:36221,RGBA32I:36226,RGB32I:36227,RGBA16I:36232,RGB16I:36233,RGBA8I:36238,RGB8I:36239,RED_INTEGER:36244,RGB_INTEGER:36248,RGBA_INTEGER:36249,R8:33321,RG8:33323,R16F:33325,R32F:33326,RG16F:33327,RG32F:33328,R8I:33329,R8UI:33330,R16I:33331,R16UI:33332,R32I:33333,R32UI:33334,RG8I:33335,RG8UI:33336,RG16I:33337,RG16UI:33338,RG32I:33339,RG32UI:33340,R8_SNORM:36756,RG8_SNORM:36757,RGB8_SNORM:36758,RGBA8_SNORM:36759,RGB10_A2UI:36975,TEXTURE_IMMUTABLE_FORMAT:37167,TEXTURE_IMMUTABLE_LEVELS:33503,UNSIGNED_INT_2_10_10_10_REV:33640,UNSIGNED_INT_10F_11F_11F_REV:35899,UNSIGNED_INT_5_9_9_9_REV:35902,FLOAT_32_UNSIGNED_INT_24_8_REV:36269,UNSIGNED_INT_24_8:34042,HALF_FLOAT:5131,RG:33319,RG_INTEGER:33320,INT_2_10_10_10_REV:36255,CURRENT_QUERY:34917,QUERY_RESULT:34918,QUERY_RESULT_AVAILABLE:34919,ANY_SAMPLES_PASSED:35887,ANY_SAMPLES_PASSED_CONSERVATIVE:36202,MAX_DRAW_BUFFERS:34852,DRAW_BUFFER0:34853,DRAW_BUFFER1:34854,DRAW_BUFFER2:34855,DRAW_BUFFER3:34856,DRAW_BUFFER4:34857,DRAW_BUFFER5:34858,DRAW_BUFFER6:34859,DRAW_BUFFER7:34860,DRAW_BUFFER8:34861,DRAW_BUFFER9:34862,DRAW_BUFFER10:34863,DRAW_BUFFER11:34864,DRAW_BUFFER12:34865,DRAW_BUFFER13:34866,DRAW_BUFFER14:34867,DRAW_BUFFER15:34868,MAX_COLOR_ATTACHMENTS:36063,COLOR_ATTACHMENT1:36065,COLOR_ATTACHMENT2:36066,COLOR_ATTACHMENT3:36067,COLOR_ATTACHMENT4:36068,COLOR_ATTACHMENT5:36069,COLOR_ATTACHMENT6:36070,COLOR_ATTACHMENT7:36071,COLOR_ATTACHMENT8:36072,COLOR_ATTACHMENT9:36073,COLOR_ATTACHMENT10:36074,COLOR_ATTACHMENT11:36075,COLOR_ATTACHMENT12:36076,COLOR_ATTACHMENT13:36077,COLOR_ATTACHMENT14:36078,COLOR_ATTACHMENT15:36079,SAMPLER_3D:35679,SAMPLER_2D_SHADOW:35682,SAMPLER_2D_ARRAY:36289,SAMPLER_2D_ARRAY_SHADOW:36292,SAMPLER_CUBE_SHADOW:36293,INT_SAMPLER_2D:36298,INT_SAMPLER_3D:36299,INT_SAMPLER_CUBE:36300,INT_SAMPLER_2D_ARRAY:36303,UNSIGNED_INT_SAMPLER_2D:36306,UNSIGNED_INT_SAMPLER_3D:36307,UNSIGNED_INT_SAMPLER_CUBE:36308,UNSIGNED_INT_SAMPLER_2D_ARRAY:36311,MAX_SAMPLES:36183,SAMPLER_BINDING:35097,PIXEL_PACK_BUFFER:35051,PIXEL_UNPACK_BUFFER:35052,PIXEL_PACK_BUFFER_BINDING:35053,PIXEL_UNPACK_BUFFER_BINDING:35055,COPY_READ_BUFFER:36662,COPY_WRITE_BUFFER:36663,COPY_READ_BUFFER_BINDING:36662,COPY_WRITE_BUFFER_BINDING:36663,FLOAT_MAT2x3:35685,FLOAT_MAT2x4:35686,FLOAT_MAT3x2:35687,FLOAT_MAT3x4:35688,FLOAT_MAT4x2:35689,FLOAT_MAT4x3:35690,UNSIGNED_INT_VEC2:36294,UNSIGNED_INT_VEC3:36295,UNSIGNED_INT_VEC4:36296,UNSIGNED_NORMALIZED:35863,SIGNED_NORMALIZED:36764,VERTEX_ATTRIB_ARRAY_INTEGER:35069,VERTEX_ATTRIB_ARRAY_DIVISOR:35070,TRANSFORM_FEEDBACK_BUFFER_MODE:35967,MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS:35968,TRANSFORM_FEEDBACK_VARYINGS:35971,TRANSFORM_FEEDBACK_BUFFER_START:35972,TRANSFORM_FEEDBACK_BUFFER_SIZE:35973,TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN:35976,MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS:35978,MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS:35979,INTERLEAVED_ATTRIBS:35980,SEPARATE_ATTRIBS:35981,TRANSFORM_FEEDBACK_BUFFER:35982,TRANSFORM_FEEDBACK_BUFFER_BINDING:35983,TRANSFORM_FEEDBACK:36386,TRANSFORM_FEEDBACK_PAUSED:36387,TRANSFORM_FEEDBACK_ACTIVE:36388,TRANSFORM_FEEDBACK_BINDING:36389,FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING:33296,FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE:33297,FRAMEBUFFER_ATTACHMENT_RED_SIZE:33298,FRAMEBUFFER_ATTACHMENT_GREEN_SIZE:33299,FRAMEBUFFER_ATTACHMENT_BLUE_SIZE:33300,FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE:33301,FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE:33302,FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE:33303,FRAMEBUFFER_DEFAULT:33304,DEPTH24_STENCIL8:35056,DRAW_FRAMEBUFFER_BINDING:36006,READ_FRAMEBUFFER_BINDING:36010,RENDERBUFFER_SAMPLES:36011,FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER:36052,FRAMEBUFFER_INCOMPLETE_MULTISAMPLE:36182,UNIFORM_BUFFER:35345,UNIFORM_BUFFER_BINDING:35368,UNIFORM_BUFFER_START:35369,UNIFORM_BUFFER_SIZE:35370,MAX_VERTEX_UNIFORM_BLOCKS:35371,MAX_FRAGMENT_UNIFORM_BLOCKS:35373,MAX_COMBINED_UNIFORM_BLOCKS:35374,MAX_UNIFORM_BUFFER_BINDINGS:35375,MAX_UNIFORM_BLOCK_SIZE:35376,MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS:35377,MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS:35379,UNIFORM_BUFFER_OFFSET_ALIGNMENT:35380,ACTIVE_UNIFORM_BLOCKS:35382,UNIFORM_TYPE:35383,UNIFORM_SIZE:35384,UNIFORM_BLOCK_INDEX:35386,UNIFORM_OFFSET:35387,UNIFORM_ARRAY_STRIDE:35388,UNIFORM_MATRIX_STRIDE:35389,UNIFORM_IS_ROW_MAJOR:35390,UNIFORM_BLOCK_BINDING:35391,UNIFORM_BLOCK_DATA_SIZE:35392,UNIFORM_BLOCK_ACTIVE_UNIFORMS:35394,UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES:35395,UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER:35396,UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER:35398,OBJECT_TYPE:37138,SYNC_CONDITION:37139,SYNC_STATUS:37140,SYNC_FLAGS:37141,SYNC_FENCE:37142,SYNC_GPU_COMMANDS_COMPLETE:37143,UNSIGNALED:37144,SIGNALED:37145,ALREADY_SIGNALED:37146,TIMEOUT_EXPIRED:37147,CONDITION_SATISFIED:37148,WAIT_FAILED:37149,SYNC_FLUSH_COMMANDS_BIT:1,COLOR:6144,DEPTH:6145,STENCIL:6146,MIN:32775,MAX:32776,DEPTH_COMPONENT24:33190,STREAM_READ:35041,STREAM_COPY:35042,STATIC_READ:35045,STATIC_COPY:35046,DYNAMIC_READ:35049,DYNAMIC_COPY:35050,DEPTH_COMPONENT32F:36012,DEPTH32F_STENCIL8:36013,INVALID_INDEX:4294967295,TIMEOUT_IGNORED:-1,MAX_CLIENT_WAIT_TIMEOUT_WEBGL:37447,VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE:35070,UNMASKED_VENDOR_WEBGL:37445,UNMASKED_RENDERER_WEBGL:37446,MAX_TEXTURE_MAX_ANISOTROPY_EXT:34047,TEXTURE_MAX_ANISOTROPY_EXT:34046,COMPRESSED_RGB_S3TC_DXT1_EXT:33776,COMPRESSED_RGBA_S3TC_DXT1_EXT:33777,COMPRESSED_RGBA_S3TC_DXT3_EXT:33778,COMPRESSED_RGBA_S3TC_DXT5_EXT:33779,COMPRESSED_R11_EAC:37488,COMPRESSED_SIGNED_R11_EAC:37489,COMPRESSED_RG11_EAC:37490,COMPRESSED_SIGNED_RG11_EAC:37491,COMPRESSED_RGB8_ETC2:37492,COMPRESSED_RGBA8_ETC2_EAC:37493,COMPRESSED_SRGB8_ETC2:37494,COMPRESSED_SRGB8_ALPHA8_ETC2_EAC:37495,COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2:37496,COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2:37497,COMPRESSED_RGB_PVRTC_4BPPV1_IMG:35840,COMPRESSED_RGBA_PVRTC_4BPPV1_IMG:35842,COMPRESSED_RGB_PVRTC_2BPPV1_IMG:35841,COMPRESSED_RGBA_PVRTC_2BPPV1_IMG:35843,COMPRESSED_RGB_ETC1_WEBGL:36196,COMPRESSED_RGB_ATC_WEBGL:35986,COMPRESSED_RGBA_ATC_EXPLICIT_ALPHA_WEBGL:35986,COMPRESSED_RGBA_ATC_INTERPOLATED_ALPHA_WEBGL:34798,UNSIGNED_INT_24_8_WEBGL:34042,HALF_FLOAT_OES:36193,RGBA32F_EXT:34836,RGB32F_EXT:34837,FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE_EXT:33297,UNSIGNED_NORMALIZED_EXT:35863,MIN_EXT:32775,MAX_EXT:32776,SRGB_EXT:35904,SRGB_ALPHA_EXT:35906,SRGB8_ALPHA8_EXT:35907,FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING_EXT:33296,FRAGMENT_SHADER_DERIVATIVE_HINT_OES:35723,COLOR_ATTACHMENT0_WEBGL:36064,COLOR_ATTACHMENT1_WEBGL:36065,COLOR_ATTACHMENT2_WEBGL:36066,COLOR_ATTACHMENT3_WEBGL:36067,COLOR_ATTACHMENT4_WEBGL:36068,COLOR_ATTACHMENT5_WEBGL:36069,COLOR_ATTACHMENT6_WEBGL:36070,COLOR_ATTACHMENT7_WEBGL:36071,COLOR_ATTACHMENT8_WEBGL:36072,COLOR_ATTACHMENT9_WEBGL:36073,COLOR_ATTACHMENT10_WEBGL:36074,COLOR_ATTACHMENT11_WEBGL:36075,COLOR_ATTACHMENT12_WEBGL:36076,COLOR_ATTACHMENT13_WEBGL:36077,COLOR_ATTACHMENT14_WEBGL:36078,COLOR_ATTACHMENT15_WEBGL:36079,DRAW_BUFFER0_WEBGL:34853,DRAW_BUFFER1_WEBGL:34854,DRAW_BUFFER2_WEBGL:34855,DRAW_BUFFER3_WEBGL:34856,DRAW_BUFFER4_WEBGL:34857,DRAW_BUFFER5_WEBGL:34858,DRAW_BUFFER6_WEBGL:34859,DRAW_BUFFER7_WEBGL:34860,DRAW_BUFFER8_WEBGL:34861,DRAW_BUFFER9_WEBGL:34862,DRAW_BUFFER10_WEBGL:34863,DRAW_BUFFER11_WEBGL:34864,DRAW_BUFFER12_WEBGL:34865,DRAW_BUFFER13_WEBGL:34866,DRAW_BUFFER14_WEBGL:34867,DRAW_BUFFER15_WEBGL:34868,MAX_COLOR_ATTACHMENTS_WEBGL:36063,MAX_DRAW_BUFFERS_WEBGL:34852,VERTEX_ARRAY_BINDING_OES:34229,QUERY_COUNTER_BITS_EXT:34916,CURRENT_QUERY_EXT:34917,QUERY_RESULT_EXT:34918,QUERY_RESULT_AVAILABLE_EXT:34919,TIME_ELAPSED_EXT:35007,TIMESTAMP_EXT:36392,GPU_DISJOINT_EXT:36795}},function(wA,xA){var yA;yA=function(){return this}();try{yA=yA||Function("return this")()||eval("this")}catch(e){"object"==typeof window&&(yA=window)}wA.exports=yA},function(e,t){e.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t,n){var d=n(28),h=n(210),p=n(136),v=n(2),g=n(11),y=n(153),_={},m={};(t=e.exports=function(e,t,n,r,i){var o,a,s,u,c=i?function(){return e}:y(e),l=d(n,r,t?2:1),f=0;if("function"!=typeof c)throw TypeError(e+" is not iterable!");if(p(c)){for(o=g(e.length);f<o;f++)if((u=t?l(v(a=e[f])[0],a[1]):l(e[f]))===_||u===m)return u}else for(s=c.call(e);!(a=s.next()).done;)if((u=h(s,l,a.value,t))===_||u===m)return u}).BREAK=_,t.RETURN=m},function(e,t){e.exports=!1},function(e,t,r){var i=r(2),o=r(216),a=r(132),s=r(144)("IE_PROTO"),u=function(){},c="prototype",l=function(){var e,t=r(131)("iframe"),n=a.length;for(t.style.display="none",r(134).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),l=e.F;n--;)delete l[c][a[n]];return l()};e.exports=Object.create||function(e,t){var n;return null!==e?(u[c]=i(e),n=new u,u[c]=null,n[s]=e):n=l(),void 0===t?n:o(n,t)}},function(e,t,n){var r=n(218),i=n(132).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,i)}},function(e,t,n){var r=n(218),i=n(132);e.exports=Object.keys||function(e){return r(e,i)}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,n){var i=n(20);e.exports=function(e,t,n){for(var r in t)i(e,r,t[r],n);return e}},function(e,t,n){"use strict";var r=n(3),i=n(10),o=n(9),a=n(6)("species");e.exports=function(e){var t=r[e];o&&t&&!t[a]&&i.f(t,a,{configurable:!0,get:function(){return this}})}},function(e,t,n){var r=n(36),i=Math.max,o=Math.min;e.exports=function(e,t){return(e=r(e))<0?i(e+t,0):o(e,t)}},function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(249);n.d(t,"AnimationLoop",function(){return r.a}),n.d(t,"requestAnimationFrame",function(){return r.b}),n.d(t,"cancelAnimationFrame",function(){return r.c});var i=n(104);n.d(t,"Model",function(){return i.a})},function(e,t,n){"use strict";var r=n(663);n.d(t,"g",function(){return r.c}),n.d(t,"c",function(){return r.a}),n.d(t,"d",function(){return r.b}),n.d(t,"h",function(){return r.d});var i=n(664);n.d(t,"a",function(){return i.a}),n.d(t,"e",function(){return i.b});var o=n(265);n.d(t,"f",function(){return o.a});var a=n(164);n.d(t,"b",function(){return a.a});var s=n(665);n.d(t,"j",function(){return s.a});var u=n(264);n.d(t,"i",function(){return u.a});n(46)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(25);n.d(t,"GL",function(){return r.d}),n.d(t,"default",function(){return r.d});var i=n(268);n.d(t,"Image",function(){return i.e}),n.d(t,"WebGLRenderingContext",function(){return i.a}),n.d(t,"WebGLProgram",function(){return i.f}),n.d(t,"WebGLShader",function(){return i.g}),n.d(t,"WebGLBuffer",function(){return i.d}),n.d(t,"WebGLFramebuffer",function(){return i.h}),n.d(t,"WebGLRenderbuffer",function(){return i.i}),n.d(t,"WebGLTexture",function(){return i.j}),n.d(t,"WebGLUniformLocation",function(){return i.k}),n.d(t,"WebGLActiveInfo",function(){return i.l}),n.d(t,"WebGLShaderPrecisionFormat",function(){return i.m}),n.d(t,"WebGL2RenderingContext",function(){return i.b}),n.d(t,"webGLTypesAvailable",function(){return i.c});var o=n(7);n.d(t,"isWebGL",function(){return o.a}),n.d(t,"isWebGL2",function(){return o.b}),n.d(t,"createGLContext",function(){return o.d}),n.d(t,"deleteGLContext",function(){return o.e});var a=n(68);n.d(t,"withParameters",function(){return a.f}),n.d(t,"resetParameters",function(){return a.a});var s=n(165);n.d(t,"getContextInfo",function(){return s.a});var u=n(67);n.d(t,"Buffer",function(){return u.a});var c=n(111);n.d(t,"Shader",function(){return c.a}),n.d(t,"VertexShader",function(){return c.b}),n.d(t,"FragmentShader",function(){return c.c});var l=n(109);n.d(t,"Program",function(){return l.a});var f=n(69);n.d(t,"Framebuffer",function(){return f.a});var d=n(110);n.d(t,"Renderbuffer",function(){return d.a});var h=n(167);n.d(t,"Texture2D",function(){return h.a});var p=n(275);n.d(t,"TextureCube",function(){return p.a});var v=n(270);n.d(t,"draw",function(){return v.a});var g=n(107);n.d(t,"clear",function(){return g.a});var y=n(272);n.d(t,"readPixels",function(){return y.a});var _=n(168);n.d(t,"parseUniformName",function(){return _.a}),n.d(t,"getUniformSetter",function(){return _.b}),n.d(t,"checkUniformValues",function(){return _.c});var m=n(169);n.d(t,"VertexArray",function(){return m.a})},function(e,t,C){"use strict";var n,k=C(25),M=C(38),L=C(7),I=C(68),r=C(30),N=C(67),T=C(8),i=C(1),F=C.n(i),o=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function x(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var a=[k.a.LINEAR,k.a.NEAREST],l=(x(n={},k.a.RGB,{dataFormat:k.a.RGB,types:[k.a.UNSIGNED_BYTE,k.a.UNSIGNED_SHORT_5_6_5]}),x(n,k.a.RGBA,{dataFormat:k.a.RGBA,types:[k.a.UNSIGNED_BYTE,k.a.UNSIGNED_SHORT_4_4_4_4,k.a.UNSIGNED_SHORT_5_5_5_1]}),x(n,k.a.ALPHA,{dataFormat:k.a.ALPHA,types:[k.a.UNSIGNED_BYTE]}),x(n,k.a.LUMINANCE,{dataFormat:k.a.LUMINANCE,types:[k.a.UNSIGNED_BYTE]}),x(n,k.a.LUMINANCE_ALPHA,{dataFormat:k.a.LUMINANCE_ALPHA,types:[k.a.UNSIGNED_BYTE]}),n);var s=function(e){function s(e,t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);var n=t.id,r=void 0===n?C.i(T.d)("texture"):n,i=t.handle,o=t.target,a=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(s.__proto__||Object.getPrototypeOf(s)).call(this,e,{id:r,handle:i}));return a.target=o,a.hasFloatTexture=e.getExtension("OES_texture_float"),a.textureUnit=void 0,a}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(s,r["a"]),o(s,null,[{key:"isSupported",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.format,r=t.linearFiltering;F()(C.i(L.a)(e),L.h);var i=!0;return n&&(i=(i=i&&function(e,t){F()(C.i(L.a)(e),L.h);var n=l[t];if(!n)return!1;if(void 0===n.gl1&&void 0===n.gl2)return!0;var r=C.i(L.b)(e)&&n.gl2||n.gl1;return"string"==typeof r?e.getExtension(r):r}(e,n))&&(!r||function(e,t){var n=l[t];switch(n&&n.types[0]){case k.a.FLOAT:return e.getExtension("OES_texture_float_linear");case k.a.HALF_FLOAT:return e.getExtension("OES_texture_half_float_linear");default:return!0}}(e,n))),i}}]),o(s,[{key:"toString",value:function(){return"Texture("+this.id+","+this.width+"x"+this.height+")"}},{key:"initialize",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.data,n=e.pixels,r=void 0===n?null:n,i=e.format,o=void 0===i?k.a.RGBA:i,a=e.type,s=void 0===a?k.a.UNSIGNED_BYTE:a,u=e.border,c=void 0===u?0:u,l=e.recreate,f=void 0!==l&&l,d=e.parameters,h=void 0===d?{}:d,p=e.pixelStore,v=void 0===p?{}:p,g=e.unpackFlipY,y=void 0===g||g,_=e.mipmaps,m=void 0===_||_;t||(t=r);var b=e.width,E=e.height,w=e.dataFormat,P=this._deduceParameters({format:o,type:s,dataFormat:w,compressed:!1,data:t,width:b,height:E});b=P.width,E=P.height,w=P.dataFormat,this.width=b,this.height=E,this.format=o,this.type=s,this.dataFormat=w,this.border=c,this.mipmaps=m;var S=x({},k.a.UNPACK_FLIP_Y_WEBGL,y),A=Object.assign({},S,v);this._isNPOT()&&(T.b.warn("texture: "+this+" is Non-Power-Of-Two, disabling mipmaping"),m=!1,this._updateForNPOT(h)),this.setImageData({data:t,width:b,height:E,format:o,type:s,dataFormat:w,border:c,mipmaps:m,parameters:A}),m&&this.generateMipmap(),this.setParameters(h),f&&(this.data=t)}},{key:"resize",value:function(e){var t=e.width,n=e.height;return t!==this.width||n!==this.height?this.initialize({width:t,height:n,format:this.format,type:this.type,dataFormat:this.dataFormat,border:this.border,mipmaps:!1}):this}},{key:"generateMipmap",value:function(){var e=this,t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};return this.gl.bindTexture(this.target,this.handle),C.i(I.f)(this.gl,t,function(){e.gl.generateMipmap(e.target)}),this.gl.bindTexture(this.target,null),this}},{key:"setImageData",value:function(e){var t=this,n=e.target,r=void 0===n?this.target:n,i=e.pixels,o=void 0===i?null:i,a=e.data,s=void 0===a?null:a,u=e.width,c=e.height,l=e.level,f=void 0===l?0:l,d=e.format,h=void 0===d?k.a.RGBA:d,p=e.type,v=e.dataFormat,g=e.offset,y=void 0===g?0:g,_=e.border,m=void 0===_?0:_,b=e.compressed,E=void 0!==b&&b,w=e.parameters,P=void 0===w?{}:w;s||(s=o);var S=this._deduceParameters({format:h,type:p,dataFormat:v,compressed:E,data:s,width:u,height:c});p=S.type,v=S.dataFormat,E=S.compressed,u=S.width,c=S.height;var A=this.gl;A.bindTexture(this.target,this.handle);var T,x=this._getDataType({data:s,compressed:E});s=x.data,T=x.dataType,C.i(I.f)(this.gl,P,function(){switch(T){case"null":A.texImage2D(r,f,h,u,c,m,v,p,s);break;case"typed-array":A.texImage2D(r,f,h,u,c,m,v,p,s,y);break;case"buffer":F()(C.i(L.b)(A),L.i),A.bindBuffer(k.a.PIXEL_UNPACK_BUFFER,s.handle||s),A.texImage2D(r,f,h,u,c,m,h,p,y);break;case"browser-object":A.texImage2D(r,f,h,h,p,s);break;case"compressed":A.compressedTexImage2D(t.target,f,h,u,c,m,s);break;default:F()(!1,"Unknown image data type")}})}},{key:"setSubImageData",value:function(e){var t=this,n=e.target,r=void 0===n?this.target:n,i=e.pixels,o=void 0===i?null:i,a=e.data,s=void 0===a?null:a,u=e.x,c=void 0===u?0:u,l=e.y,f=void 0===l?0:l,d=e.width,h=e.height,p=e.level,v=void 0===p?0:p,g=e.format,y=void 0===g?k.a.RGBA:g,_=e.type,m=e.dataFormat,b=e.compressed,E=void 0!==b&&b,w=e.offset,P=void 0===w?0:w,S=e.border,A=void 0===S?0:S,T=e.parameters,x=void 0===T?{}:T,O=this._deduceParameters({format:y,type:_,dataFormat:m,compressed:E,data:s,width:d,height:h});if(_=O.type,m=O.dataFormat,E=O.compressed,d=O.width,h=O.height,s||(s=o),s&&s.data){var R=s;s=R.data,d=R.shape[0],h=R.shape[1]}s instanceof N.a&&(s=s.handle),this.gl.bindTexture(this.target,this.handle),C.i(I.f)(this.gl,x,function(){E?t.gl.compressedTexSubImage2D(r,v,c,f,d,h,y,s):null===s?t.gl.texSubImage2D(r,v,y,d,h,A,m,_,null):ArrayBuffer.isView(s)?t.gl.texSubImage2D(r,v,c,f,d,h,y,_,s,P):s instanceof M.e?(F()(C.i(L.b)(t.gl),L.i),t.gl.bindBuffer(k.a.PIXEL_UNPACK_BUFFER,s),t.gl.texSubImage2D(r,v,y,d,h,A,y,_,P),t.gl.bindBuffer(k.a.GL_PIXEL_UNPACK_BUFFER,null)):t.gl.texSubImage2D(r,v,c,f,y,_,s)}),this.gl.bindTexture(this.target,null)}},{key:"copyFramebuffer",value:function(e){var t=e.target,n=(void 0===t&&this.target,e.framebuffer),r=(e.offset,e.x),i=void 0===r?0:r,o=e.y,a=void 0===o?0:o,s=e.width,u=e.height,c=e.level,l=void 0===c?0:c,f=e.internalFormat,d=void 0===f?k.a.RGBA:f,h=e.border,p=void 0===h?0:h;n&&n.bind(),this.bind(),this.gl.copyTexImage2D(this.target,l,d,i,a,s,u,p),this.unbind(),n&&n.unbind()}},{key:"getActiveUnit",value:function(){return this.gl.getParameter(k.a.ACTIVE_TEXTURE)-k.a.TEXTURE0}},{key:"bind",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:this.textureUnit;if(void 0===e)throw new Error("Texture.bind: must specify texture unit");return this.textureUnit=e,this.gl.activeTexture(k.a.TEXTURE0+e),this.gl.bindTexture(this.target,this.handle),e}},{key:"unbind",value:function(){if(void 0===this.textureUnit)throw new Error("Texture.unbind: texture unit not specified");return this.gl.activeTexture(k.a.TEXTURE0+this.textureUnit),this.gl.bindTexture(this.target,null),this.textureUnit}},{key:"_getDataType",value:function(e){var t=e.data,n=e.compressed;return void 0!==n&&n?{data:t,dataType:"compressed"}:null===t?{data:t,dataType:"null"}:ArrayBuffer.isView(t)?{data:t,dataType:"typed-array"}:t instanceof N.a?{data:t.handle,dataType:"buffer"}:t instanceof M.e?{data:t,dataType:"buffer"}:{data:t,dataType:"browser-object"}}},{key:"setImage3D",value:function(e){var t=e.level,n=void 0===t?0:t,r=e.internalformat,i=void 0===r?k.a.RGBA:r,o=e.width,a=e.height,s=e.depth,u=void 0===s?1:s,c=e.border,l=void 0===c?0:c,f=e.format,d=e.type,h=void 0===d?k.a.UNSIGNED_BYTE:d,p=e.offset,v=void 0===p?0:p,g=e.pixels;return ArrayBuffer.isView(g)?this.gl.texImage3D(this.target,n,i,o,a,u,l,f,h,g):g instanceof N.a&&(this.gl.bindBuffer(k.a.PIXEL_UNPACK_BUFFER,g.handle),this.gl.texImage3D(this.target,n,i,o,a,u,l,f,h,v)),this}},{key:"_deduceParameters",value:function(e){var t=e.format,n=e.data,r=e.width,i=e.height,o=e.dataFormat,a=e.type,s=e.compressed,u=l[t];o=o||u&&u.dataFormat,a=a||u&&u.types[0],s=s||u&&u.compressed;var c=this._deduceImageSize({data:n,width:r,height:i});return{dataFormat:o,type:a,compressed:s,width:r=c.width,height:i=c.height,format:t,data:n}}},{key:"_deduceImageSize",value:function(e){var t=e.data,n=e.width,r=e.height,i=void 0;return i="undefined"!=typeof ImageData&&t instanceof ImageData?{width:t.width,height:t.height}:"undefined"!=typeof HTMLImageElement&&t instanceof HTMLImageElement?{width:t.naturalWidth,height:t.naturalHeight}:"undefined"!=typeof HTMLCanvasElement&&t instanceof HTMLCanvasElement?{width:t.width,height:t.height}:"undefined"!=typeof HTMLVideoElement&&t instanceof HTMLVideoElement?{width:t.videoWidth,height:t.videoHeight}:t?{width:n,height:r}:{width:0<=n?n:1,height:0<=r?r:1},F()(i,"Could not deduced texture size"),F()(void 0===n||i.width===n,"Deduced texture width does not match supplied width"),F()(void 0===r||i.height===r,"Deduced texture height does not match supplied height"),i}},{key:"_createHandle",value:function(){return this.gl.createTexture()}},{key:"_deleteHandle",value:function(){this.gl.deleteTexture(this.handle)}},{key:"_getParameter",value:function(e){switch(e){case k.a.TEXTURE_WIDTH:return this.width;case k.a.TEXTURE_HEIGHT:return this.height;default:this.gl.bindTexture(this.target,this.handle);var t=this.gl.getTexParameter(this.target,e);return this.gl.bindTexture(this.target,null),t}}},{key:"_setParameter",value:function(e,t){switch(this.gl.bindTexture(this.target,this.handle),t=this._getNPOTParam(e,t),e){case k.a.TEXTURE_MIN_LOD:case k.a.TEXTURE_MAX_LOD:this.gl.texParameterf(this.handle,e,t);break;case k.a.TEXTURE_WIDTH:case k.a.TEXTURE_HEIGHT:throw new Error("Cannot set emulated parameter");default:this.gl.texParameteri(this.target,e,t)}return this.gl.bindTexture(this.target,null),this}},{key:"_isNPOT",value:function(){return!(C.i(L.b)(this.gl)||C.i(T.e)(this.width)&&C.i(T.e)(this.height))}},{key:"_updateForNPOT",value:function(e){void 0===e[this.gl.TEXTURE_MIN_FILTER]&&(T.b.warn("texture: "+this+" is Non-Power-Of-Two, forcing TEXTURE_MIN_FILTER to LINEAR"),e[this.gl.TEXTURE_MIN_FILTER]=this.gl.LINEAR),void 0===e[this.gl.TEXTURE_WRAP_S]&&(T.b.warn("texture: "+this+" is Non-Power-Of-Two, forcing TEXTURE_WRAP_S to CLAMP_TO_EDGE"),e[this.gl.TEXTURE_WRAP_S]=this.gl.CLAMP_TO_EDGE),void 0===e[this.gl.TEXTURE_WRAP_T]&&(T.b.warn("texture: "+this+" is Non-Power-Of-Two, forcing TEXTURE_WRAP_T to CLAMP_TO_EDGE"),e[this.gl.TEXTURE_WRAP_T]=this.gl.CLAMP_TO_EDGE)}},{key:"_getNPOTParam",value:function(e,t){if(this._isNPOT())switch(e){case k.a.TEXTURE_MIN_FILTER:-1===a.indexOf(t)&&(T.b.warn("texture: "+this+" is Non-Power-Of-Two, forcing TEXTURE_MIN_FILTER to LINEAR"),t=k.a.LINEAR);break;case k.a.TEXTURE_WRAP_S:case k.a.TEXTURE_WRAP_T:t!==k.a.CLAMP_TO_EDGE&&(T.b.warn("texture: "+this+" is Non-Power-Of-Two, "+C.i(k.c)(e)+" to CLAMP_TO_EDGE"),t=k.a.CLAMP_TO_EDGE)}return t}}]),s}();t.a=s},function(e,t){e.exports={}},function(e,t,n){var r=n(10).f,i=n(18),o=n(6)("toStringTag");e.exports=function(e,t,n){e&&!i(e=n?e:e.prototype,o)&&r(e,o,{configurable:!0,value:t})}},function(e,t,n){var a=n(0),r=n(34),s=n(4),u=n(148),i="["+u+"]",o=RegExp("^"+i+i+"*"),c=RegExp(i+i+"*$"),l=function(e,t,n){var r={},i=s(function(){return!!u[e]()||"…"!="…"[e]()}),o=r[e]=i?t(f):u[e];n&&(r[n]=o),a(a.P+a.F*i,"String",r)},f=l.trim=function(e,t){return e=String(r(e)),1&t&&(e=e.replace(o,"")),2&t&&(e=e.replace(c,"")),e};e.exports=l},function(e,t,n){var r=n(5);e.exports=function(e,t){if(!r(e)||e._t!==t)throw TypeError("Incompatible receiver, "+t+" required!");return e}},function(e,t,v){"use strict";var u=v(38),g=v(7),y=v(163),n=v(30),r=v(1),_=v.n(r),i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function m(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var c="Illegal or missing parameter to Buffer",b=36662,l=36663,E=function e(){var t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},n=t.type,r=t.size,i=void 0===r?1:r,o=t.offset,a=void 0===o?0:o,s=t.stride,u=void 0===s?0:s,c=t.normalized,l=void 0!==c&&c,f=t.integer,d=void 0!==f&&f,h=t.instanced,p=void 0===h?0:h;m(this,e),this.type=n,this.size=i,this.offset=a,this.stride=u,this.normalized=l,this.integer=d,this.instanced=p},o=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};m(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,t));return n.target=t.target||(n.gl.webgl2?b:u.a.ARRAY_BUFFER),n.index=null,n.setData(t),Object.seal(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,n["a"]),i(r,[{key:"setDataLayout",value:function(e){var t=e.layout,n=e.type,r=e.size,i=void 0===r?1:r,o=e.offset,a=void 0===o?0:o,s=e.stride,u=void 0===s?0:s,c=e.normalized,l=void 0!==c&&c,f=e.integer,d=void 0!==f&&f,h=e.instanced,p=void 0===h?0:h;return this.layout=t||new E({type:n||this.type,size:i,offset:a,stride:u,normalized:l,integer:d,instanced:p}),this}},{key:"initialize",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.data,n=e.bytes,r=e.usage,i=void 0===r?u.a.STATIC_DRAW:r,o=(e.layout,e.type),a=(e.size,e.offset,e.stride,e.normalized,e.integer,e.instanced,arguments[0]);t?(o=o||v.i(y.b)(t),n=t.byteLength,_()(o,c)):(o=o||u.a.FLOAT,n&&0!==n||(n=0,t=new Float32Array(0))),this.bytes=n,this.bytesUsed=n,this.data=t,this.type=o,this.usage=i,this.setDataLayout(Object.assign(a));var s=this.gl.webgl2?l:this.target;return this.gl.bindBuffer(s,this.handle),this.gl.bufferData(s,t||n,i),this.gl.bindBuffer(s,null),this}},{key:"setData",value:function(e){return this.initialize(e)}},{key:"subData",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.data,n=e.offset,r=void 0===n?0:n,i=e.srcOffset,o=void 0===i?0:i,a=e.length;_()(t,c);var s=this.gl.webgl2?l:this.target;return this.gl.bindBuffer(s,this.handle),0!==o||void 0!==a?(v.i(g.g)(this.gl),this.gl.bufferSubData(this.target,r,t,o,a||0)):this.gl.bufferSubData(s,r,t),this.gl.bindBuffer(s,null),this}},{key:"copyData",value:function(e){var t=e.sourceBuffer,n=e.readOffset,r=void 0===n?0:n,i=e.writeOffset,o=void 0===i?0:i,a=e.size;return v.i(g.g)(this.gl),this.gl.bindBuffer(b,t.handle),this.gl.bindBuffer(l,this.handle),this.gl.copyBufferSubData(b,l,r,o,a),this.gl.bindBuffer(b,null),this.gl.bindBuffer(l,null),this}},{key:"getData",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.dstData,n=void 0===t?null:t,r=e.srcByteOffset,i=void 0===r?0:r,o=e.dstOffset,a=void 0===o?0:o,s=e.length,u=void 0===s?0:s;v.i(g.g)(this.gl);var c=v.i(y.a)(this.type,{clamped:!1}),l=this._getAvailableElementCount(i),f=void 0,d=void 0,h=a;n?f=(d=n.length)-h:d=h+(f=Math.min(l,u||l));var p=Math.min(l,f);return u=u||p,_()(u<=p,"Invalid srcByteOffset, dstOffset and length combination"),n=n||new c(d),this.gl.bindBuffer(b,this.handle),this.gl.getBufferSubData(b,i,n,a,u),this.gl.bindBuffer(b,null),n}},{key:"bind",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.target,n=void 0===t?this.target:t,r=e.index,i=void 0===r?this.index:r,o=e.offset,a=void 0===o?0:o,s=e.size;switch(n===u.a.UNIFORM_BUFFER||35982===n?void 0!==s?"ranged":" indexed":"non-indexed"){case"non-indexed":this.gl.bindBuffer(n,this.handle);break;case"indexed":v.i(g.g)(this.gl),_()(0===a,c),this.gl.bindBufferBase(n,i,this.handle);break;case"ranged":v.i(g.g)(this.gl),this.gl.bindBufferRange(n,i,this.handle,a,s);break;default:throw new Error(c)}return this}},{key:"unbind",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.target,n=void 0===t?this.target:t,r=e.index,i=void 0===r?this.index:r;return n===u.a.UNIFORM_BUFFER||35982===n?this.gl.bindBufferBase(n,i,null):this.gl.bindBuffer(n,null),this}},{key:"getIndexedParameter",value:function(e,t){var n=this.gl.webgl2?b:this.target;return this.gl.bindBuffer(n,t),this.gl.getIndexedParameter(e,t)}},{key:"_createHandle",value:function(){return this.gl.createBuffer()}},{key:"_deleteHandle",value:function(){this.gl.deleteBuffer(this.handle)}},{key:"_getParameter",value:function(e){this.gl.bindBuffer(this.target,this.handle);var t=this.gl.getBufferParameter(this.target,e);return this.gl.bindBuffer(this.target,null),t}},{key:"_getAvailableElementCount",value:function(e){var t=v.i(y.a)(this.type,{clamped:!1});return this.bytes/t.BYTES_PER_ELEMENT-e/t.BYTES_PER_ELEMENT}}]),r}();t.a=o},function(e,t,a){"use strict";t.e=p,t.f=function(e,t,n){if(a.i(l.f)(t))return n(e);var r=t.nocatch,i=void 0===r||r;u()(!t.frameBuffer),a.i(s.b)(e),p(e,t);var o=void 0;if(i)o=n(e),a.i(s.c)(e);else try{o=n(e)}finally{a.i(s.c)(e)}return o};var c=a(46),s=a(164),n=a(1),u=a.n(n),l=a(8),i=a(266);a.d(t,"b",function(){return i.d}),a.d(t,"c",function(){return i.a}),a.d(t,"d",function(){return i.e}),a.d(t,"a",function(){return i.f}),a.d(t,"g",function(){return i.g});var f=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")};function d(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var o={framebuffer:function(e,t){var n=t&&t.handle?t.handle:t;return e.bindFramebuffer(c.a.FRAMEBUFFER,n)},blend:function(e,t){return t?e.enable(c.a.BLEND):e.disable(c.a.BLEND)},blendColor:function(e,t){return e.blendColor.apply(e,d(t))},blendEquation:function(e,t){t=h(t)?t:[t,t],e.blendEquationSeparate.apply(e,d(t))},blendFunc:function(e,t){t=h(t)&&2===t.length?[].concat(d(t),d(t)):t,e.blendFuncSeparate.apply(e,d(t))},clearColor:function(e,t){return e.clearColor.apply(e,d(t))},clearDepth:function(e,t){return e.clearDepth(t)},clearStencil:function(e,t){return e.clearStencil(t)},colorMask:function(e,t){return e.colorMask.apply(e,d(t))},cull:function(e,t){return t?e.enable(c.a.CULL_FACE):e.disable(c.a.CULL_FACE)},cullFace:function(e,t){return e.cullFace(t)},depthTest:function(e,t){return t?e.enable(c.a.DEPTH_TEST):e.disable(c.a.DEPTH_TEST)},depthFunc:function(e,t){return e.depthFunc(t)},depthMask:function(e,t){return e.depthMask(t)},depthRange:function(e,t){return e.depthRange.apply(e,d(t))},dither:function(e,t){return t?e.enable(c.a.DITHER):e.disable(c.a.DITHER)},derivativeHint:function(e,t){e.hint(c.a.FRAGMENT_SHADER_DERIVATIVE_HINT,t)},frontFace:function(e,t){return e.frontFace(t)},mipmapHint:function(e,t){return e.hint(c.a.GENERATE_MIPMAP_HINT,t)},lineWidth:function(e,t){return e.lineWidth(t)},polygonOffsetFill:function(e,t){return t?e.enable(c.a.POLYGON_OFFSET_FILL):e.disable(c.a.POLYGON_OFFSET_FILL)},polygonOffset:function(e,t){return e.polygonOffset.apply(e,d(t))},sampleCoverage:function(e,t){return e.sampleCoverage.apply(e,d(t))},scissorTest:function(e,t){return t?e.enable(c.a.SCISSOR_TEST):e.disable(c.a.SCISSOR_TEST)},scissor:function(e,t){return e.scissor.apply(e,d(t))},stencilTest:function(e,t){return t?e.enable(c.a.STENCIL_TEST):e.disable(c.a.STENCIL_TEST)},stencilMask:function(e,t){t=h(t)?t:[t,t];var n=f(t,2),r=n[0],i=n[1];e.stencilMaskSeparate(c.a.FRONT,r),e.stencilMaskSeparate(c.a.BACK,i)},stencilFunc:function(e,t){t=h(t)&&3===t.length?[].concat(d(t),d(t)):t;var n=f(t,6),r=n[0],i=n[1],o=n[2],a=n[3],s=n[4],u=n[5];e.stencilFuncSeparate(c.a.FRONT,r,i,o),e.stencilFuncSeparate(c.a.BACK,a,s,u)},stencilOp:function(e,t){t=h(t)&&3===t.length?[].concat(d(t),d(t)):t;var n=f(t,6),r=n[0],i=n[1],o=n[2],a=n[3],s=n[4],u=n[5];e.stencilOpSeparate(c.a.FRONT,r,i,o),e.stencilOpSeparate(c.a.BACK,a,s,u)},viewport:function(e,t){return e.viewport.apply(e,d(t))}};function h(e){return Array.isArray(e)||ArrayBuffer.isView(e)}function p(e,t){for(var n in a.i(i.c)(e,t),t){var r=o[n];r&&r(e,t[n],n)}}},function(e,t,C){"use strict";var k=C(38),M=C(7),n=C(108),s=C(107),i=C(30),u=C(167),p=C(110),b=C(163),d=C(8),r=C(1),L=C.n(r),v=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var w=36160,I=36009,N=36064,a="Multiple render targets not supported",l=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,t));return n.width=null,n.height=null,n.attachments={},n.readBuffer=N,n.drawBuffers=[N],n.initialize(t),Object.seal(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,i["a"]),o(r,[{key:"MAX_COLOR_ATTACHMENTS",get:function(){return this.gl.getParameter(this.gl.MAX_COLOR_ATTACHMENTS)}},{key:"MAX_DRAW_BUFFERS",get:function(){return this.gl.getParameter(this.gl.MAX_DRAW_BUFFERS)}}],[{key:"isSupported",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.colorBufferFloat,r=t.colorBufferHalfFloat;return n&&e.getExtension(C.i(M.b)(e)?"EXT_color_buffer_float":"WEBGL_color_buffer_float"),r&&e.getExtension(C.i(M.b)(e)?"EXT_color_buffer_float":"EXT_color_buffer_half_float")}},{key:"getDefaultFramebuffer",value:function(e){return e.luma=e.luma||{},e.luma.defaultFramebuffer||(e.luma.defaultFramebuffer=new r(e,{handle:null,attachments:{}})),e.luma.defaultFramebuffer}}]),o(r,[{key:"initialize",value:function(e){var t=e.width,n=void 0===t?1:t,r=e.height,i=void 0===r?1:r,o=e.attachments,a=void 0===o?null:o,s=e.color,u=void 0===s||s,c=e.depth,l=void 0===c||c,f=e.stencil,d=void 0!==f&&f,h=e.check,p=void 0===h||h,v=e.readBuffer,g=e.drawBuffers;if(L()(0<=n&&0<=i,"Width and height need to be integers"),this.width=n,this.height=i,a)for(var y in a){var _=a[y];(Array.isArray(_)?_[0]:_).resize({width:n,height:i})}else a=this._createDefaultAttachments({color:u,depth:l,stencil:d,width:n,height:i});this.update({clearAttachments:!0,attachments:a,readBuffer:v,drawBuffers:g}),a&&p&&this.checkStatus()}},{key:"update",value:function(e){var t=e.attachments,n=void 0===t?{}:t,r=e.readBuffer,i=e.drawBuffers,o=e.clearAttachments,a=void 0!==o&&o;this.attach(n,{clearAttachments:a});var s=this.gl,u=s.bindFramebuffer(w,this.handle);return r&&this._setReadBuffer(r),i&&this._setDrawBuffers(i),s.bindFramebuffer(w,u),this}},{key:"resize",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.width,n=e.height;if(null===this.handle)return L()(void 0===t&&void 0===n),this.width=this.gl.drawingBufferWidth,this.height=this.gl.drawingBufferHeight,this;for(var r in void 0===t&&(t=this.gl.drawingBufferWidth),void 0===n&&(n=this.gl.drawingBufferHeight),t!==this.width&&n!==this.height&&d.b.log(2,"Resizing framebuffer "+this.id+" to "+t+"x"+n),this.attachments)this.attachments[r].resize({width:t,height:n});return this.width=t,this.height=n,this}},{key:"attach",value:function(e){var t=this,n=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).clearAttachments,r={};void 0!==n&&n&&Object.keys(this.attachments).forEach(function(e){r[e]=null}),Object.assign(r,e);var i=this.gl.bindFramebuffer(w,this.handle);for(var o in r){L()("undefined"!==o,"Misspelled framebuffer binding point?");var a=r[o],s=a;if(s)if(s instanceof p.a)this._attachRenderbuffer({attachment:o,renderbuffer:s});else if(Array.isArray(a)){var u=v(a,3),c=u[0],l=u[1],f=void 0===l?0:l,d=u[2],h=void 0===d?0:d;s=c,this._attachTexture({attachment:o,texture:c,layer:f,level:h})}else this._attachTexture({attachment:o,texture:s,layer:0,level:0});else this._unattach({attachment:o});s&&s.resize({width:this.width,height:this.height})}this.gl.bindFramebuffer(w,i),Object.assign(this.attachments,e),Object.keys(this.attachments).filter(function(e){return!t.attachments[e]}).forEach(function(e){delete t.attachments[e]})}},{key:"checkStatus",value:function(){var e,t=this.gl,n=t.bindFramebuffer(w,this.handle),r=t.checkFramebufferStatus(w);if(t.bindFramebuffer(w,n),r!==t.FRAMEBUFFER_COMPLETE)throw new Error((e=r,(l.STATUS||{})[e]||"Framebuffer error "+e));return this}},{key:"clear",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.color,n=e.depth,r=e.stencil,i=e.drawBuffers,o=void 0===i?[]:i,a=this.gl.bindFramebuffer(w,this.handle);return(t||n||r)&&C.i(s.a)(this.gl,{color:t,depth:n,stencil:r}),o.forEach(function(e,t){C.i(s.b)({drawBuffer:t,value:e})}),this.gl.bindFramebuffer(w,a),this}},{key:"readPixels",value:function(e){var t=e.x,n=void 0===t?0:t,r=e.y,i=void 0===r?0:r,o=e.width,a=void 0===o?this.width:o,s=e.height,u=void 0===s?this.height:s,c=e.format,l=void 0===c?k.a.RGBA:c,f=e.type,d=e.pixelArray,h=void 0===d?null:d,p=e.attachment,v=void 0===p?N:p,g=this.gl;if(v===k.a.COLOR_ATTACHMENT0&&null===this.handle&&(v=k.a.FRONT),!h){f=f||g.UNSIGNED_BYTE;var y=C.i(b.a)(f,{clamped:!1}),_=function(e){switch(e){case k.a.ALPHA:return 1;case k.a.RGB:return 3;case k.a.RGBA:return 4;default:throw new Error("Unknown format")}}(l);h=h||new y(a*u*_)}f=f||C.i(b.b)(h);var m=this.gl.bindFramebuffer(w,this.handle);return this.gl.readPixels(n,i,a,u,l,f,h),this.gl.bindFramebuffer(w,m),h}},{key:"copyToDataUrl",value:function(){for(var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.attachment,n=void 0===t?N:t,r=e.maxHeight,i=void 0===r?Number.MAX_SAFE_INTEGER:r,o=this.readPixels({attachment:n}),a=this.width,s=this.height;i<s;){var u=C.i(d.g)({data:o,width:a,height:s});o=u.data,a=u.width,s=u.height}C.i(d.h)({data:o,width:a,height:s});var c=document.createElement("canvas");c.width=a,c.height=s;var l=c.getContext("2d"),f=l.createImageData(a,s);return f.data.set(o),l.putImageData(f,0,0),c.toDataURL()}},{key:"copyToImage",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.image,n=void 0===t?null:t,r=e.attachment,i=void 0===r?N:r,o=e.maxHeight,a=(void 0===o&&Number.MAX_SAFE_INTEGER,this.readDataUrl({attachment:i}));return(n=n||new Image).src=a,n}},{key:"copyToTexture",value:function(e){var t=e.texture,n=e.target,r=e.xoffset,i=void 0===r?0:r,o=e.yoffset,a=void 0===o?0:o,s=e.zoffset,u=void 0===s?0:s,c=e.mipmapLevel,l=void 0===c?0:c,f=e.attachment,d=void 0===f?N:f,h=e.x,p=void 0===h?0:h,v=e.y,g=void 0===v?0:v,y=e.width,_=e.height,m=this.gl,b=m.bindFramebuffer(w,this.handle),E=m.readBuffer(d);switch(y=Number.isFinite(y)?y:t.width,_=Number.isFinite(_)?_:t.height,t.target){case 3553:case 34067:m.copyTexSubImage2D(n||t.target,l,i,a,p,g,y,_);break;case 35866:case 32879:m.copyTexSubImage3D(n||t.target,l,i,a,u,p,g,y,_)}return m.readBuffer(E),m.bindFramebuffer(w,b),t}},{key:"blit",value:function(e){var t=e.srcFramebuffer,n=e.attachment,r=void 0===n?N:n,i=e.srcX0,o=void 0===i?0:i,a=e.srcY0,s=void 0===a?0:a,u=e.srcX1,c=e.srcY1,l=e.dstX0,f=void 0===l?0:l,d=e.dstY0,h=void 0===d?0:d,p=e.dstX1,v=e.dstY1,g=e.color,y=void 0===g||g,_=e.depth,m=void 0!==_&&_,b=e.stencil,E=void 0!==b&&b,w=e.mask,P=void 0===w?0:w,S=e.filter,A=void 0===S?k.a.NEAREST:S,T=this.gl;L()(C.i(M.b)(T),M.i),t.handle||r!==N||(r=k.a.FRONT),y&&(P|=16384),m&&(P|=256),E&&(P|=1024),L()(P),u=void 0===u?t.width:u,c=void 0===c?t.height:c,p=void 0===p?this.width:p,v=void 0===v?this.height:v;var x=T.bindFramebuffer(36008,this.handle),O=T.bindFramebuffer(I,t.handle),R=T.readBuffer(r);return T.blitFramebuffer(o,s,u,c,f,h,p,v,P,A),T.readBuffer(R),T.bindFramebuffer(I,O),T.bindFramebuffer(36008,x),this}},{key:"invalidate",value:function(e){var t=e.attachments,n=void 0===t?[]:t,r=e.x,i=void 0===r?0:r,o=e.y,a=void 0===o?0:o,s=e.width,u=e.height,c=this.gl;L()(C.i(M.b)(c,M.i));var l=c.bindFramebuffer(I,this.handle);return 0===i&&0===a&&void 0===s&&void 0===u?c.invalidateFramebuffer(I,n):c.invalidateFramebuffer(I,n,i,a,s,u),c.bindFramebuffer(I,l),this}},{key:"getAttachmentParameter",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.attachment,n=void 0===t?N:t,r=e.pname,i=this._getAttachmentParameterFallback(r);return null===i&&(this.gl.bindTexture(w,this.handle),i=this.gl.getFramebufferAttachmentParameter(w,n,r),this.gl.bindTexture(w,null)),i}},{key:"getAttachmentParameters",value:function(){0<arguments.length&&void 0!==arguments[0]&&arguments[0];var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.constructor.ATTACHMENT_PARAMETERS||{},t={};for(var n in e)t[n]=this.getAttachmentParameter(n);return this}},{key:"show",value:function(){return"undefined"!=typeof window&&window.open(this.copyToDataUrl(),"luma-debug-texture"),this}},{key:"log",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.priority,n=void 0===t?0:t,r=e.message,i=void 0===r?"":r;if(n>d.b.priority||"undefined"==typeof window)return this;i=i||"Framebuffer "+this.id;var o=this.copyToDataUrl({maxHeight:100});return d.b.image({priority:n,message:i,image:o},i),this}},{key:"bind",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).target,t=void 0===e?w:e;return this.gl.bindFramebuffer(t,this.handle),this}},{key:"unbind",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).target,t=void 0===e?w:e;return this.gl.bindFramebuffer(t,null),this}},{key:"_createDefaultAttachments",value:function(e){var t,n=e.color,r=e.depth,i=(e.stencil,e.width),o=e.height,a=null;n&&((a=a||{})[N]=new u.a(this.gl,{pixels:null,format:k.a.RGBA,type:k.a.UNSIGNED_BYTE,width:i,height:o,mipmaps:!1,parameters:(t={},c(t,k.a.TEXTURE_MIN_FILTER,k.a.NEAREST),c(t,k.a.TEXTURE_MAG_FILTER,k.a.NEAREST),c(t,k.a.TEXTURE_WRAP_S,k.a.CLAMP_TO_EDGE),c(t,k.a.TEXTURE_WRAP_T,k.a.CLAMP_TO_EDGE),t)}));return r&&((a=a||{})[36096]=new p.a(this.gl,{format:k.a.DEPTH_COMPONENT16,width:i,height:o})),a}},{key:"_unattach",value:function(e){var t=e.attachment;this.gl.bindRenderbuffer(36161,this.handle),this.gl.framebufferRenderbuffer(w,t,36161,null),delete this.attachments[t]}},{key:"_attachRenderbuffer",value:function(e){var t=e.attachment,n=void 0===t?N:t,r=e.renderbuffer;this.gl.framebufferRenderbuffer(w,n,36161,r.handle),this.attachments[n]=r}},{key:"_attachTexture",value:function(e){var t,n=e.attachment,r=void 0===n?N:n,i=e.texture,o=e.layer,a=e.level,s=this.gl;switch(s.bindTexture(i.target,i.handle),i.target){case 35866:case 32879:s.framebufferTextureLayer(w,r,i.target,a,o);break;case 34067:var u=(t=o)<34069?t+34069:t;s.framebufferTexture2D(w,r,u,i.handle,a);break;case 3553:s.framebufferTexture2D(w,r,3553,i.handle,a);break;default:L()(!1,"Illegal texture type")}s.bindTexture(i.target,null),this.attachments[r]=i}},{key:"_setReadBuffer",value:function(e,t){C.i(M.b)(e)?e.readBuffer(t):L()(t===N||t===k.a.BACK,a),this.readBuffer=t}},{key:"_setDrawBuffers",value:function(e,t){if(C.i(M.b)(e))e.drawBuffers(t);else{var n=e.getExtension("WEBGL_draw_buffers");n?n.drawBuffersWEBGL(t):L()(1===t.length&&(t[0]===N||t[0]===k.a.BACK),a)}this.drawBuffers=t}},{key:"_getAttachmentParameterFallback",value:function(e){var t=C.i(n.d)(this.gl);switch(e){case k.a.FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER:return t.webgl2?null:0;case k.a.FRAMEBUFFER_ATTACHMENT_RED_SIZE:case k.a.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE:case k.a.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE:case k.a.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE:case k.a.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE:case k.a.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE:return t.webgl2?null:8;case k.a.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE:return t.webgl2?null:k.a.UNSIGNED_INT;case k.a.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING:return t.webgl2||t.EXT_sRGB?null:k.a.LINEAR;default:return null}}},{key:"_createHandle",value:function(){return this.gl.createFramebuffer()}},{key:"_deleteHandle",value:function(){this.gl.deleteFramebuffer(this.handle)}},{key:"color",get:function(){return this.attachments[N]||null}},{key:"texture",get:function(){return this.attachments[N]||null}},{key:"depth",get:function(){return this.attachments[36096]||null}},{key:"stencil",get:function(){return this.attachments[36128]||null}}]),r}();t.a=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.COORDINATE_SYSTEM={LNGLAT:1,METER_OFFSETS:2,METERS:2,LNGLAT_OFFSETS:3,IDENTITY:0},t.LIFECYCLE={NO_STATE:"Awaiting state",MATCHED:"Matched. State transferred from previous layer",INITIALIZED:"Intialized",AWAITING_GC:"Discarded. Awaiting garbage collection",AWAITING_FINALIZATION:"No longer matched. Awaiting garbage collection",FINALIZED:"Finalized! Awaiting garbage collection"}},function(e,t,n){var i=n(27),o=n(6)("toStringTag"),a="Arguments"==i(function(){return arguments}());e.exports=function(e){var t,n,r;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=Object(e),o))?n:a?i(t):"Object"==(r=i(t))&&"function"==typeof t.callee?"Arguments":r}},function(e,t,n){var r=n(27);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,n){"use strict";function r(e){return function(){return e}}var i=function(){};i.thatReturns=r,i.thatReturnsFalse=r(!1),i.thatReturnsTrue=r(!0),i.thatReturnsNull=r(null),i.thatReturnsThis=function(){return this},i.thatReturnsArgument=function(e){return e},e.exports=i},function(e,t){e.exports=function(e,t,n){var r=t[0],i=t[1],o=t[2],a=t[3],s=t[4],u=t[5],c=t[6],l=t[7],f=t[8],d=t[9],h=t[10],p=t[11],v=t[12],g=t[13],y=t[14],_=t[15],m=n[0],b=n[1],E=n[2],w=n[3];return e[0]=m*r+b*s+E*f+w*v,e[1]=m*i+b*u+E*d+w*g,e[2]=m*o+b*c+E*h+w*y,e[3]=m*a+b*l+E*p+w*_,m=n[4],b=n[5],E=n[6],w=n[7],e[4]=m*r+b*s+E*f+w*v,e[5]=m*i+b*u+E*d+w*g,e[6]=m*o+b*c+E*h+w*y,e[7]=m*a+b*l+E*p+w*_,m=n[8],b=n[9],E=n[10],w=n[11],e[8]=m*r+b*s+E*f+w*v,e[9]=m*i+b*u+E*d+w*g,e[10]=m*o+b*c+E*h+w*y,e[11]=m*a+b*l+E*p+w*_,m=n[12],b=n[13],E=n[14],w=n[15],e[12]=m*r+b*s+E*f+w*v,e[13]=m*i+b*u+E*d+w*g,e[14]=m*o+b*c+E*h+w*y,e[15]=m*a+b*l+E*p+w*_,e}},function(e,t){e.exports=function(e,t,n,r,i){var o=1/Math.tan(t/2),a=1/(r-i);return e[0]=o/n,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=o,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=(i+r)*a,e[11]=-1,e[12]=0,e[13]=0,e[14]=2*i*r*a,e[15]=0,e}},function(e,t){e.exports=function(e,t,n){var r=n[0],i=n[1],o=n[2];return e[0]=t[0]*r,e[1]=t[1]*r,e[2]=t[2]*r,e[3]=t[3]*r,e[4]=t[4]*i,e[5]=t[5]*i,e[6]=t[6]*i,e[7]=t[7]*i,e[8]=t[8]*o,e[9]=t[9]*o,e[10]=t[10]*o,e[11]=t[11]*o,e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}},function(e,t){e.exports=function(e,t,n){var r,i,o,a,s,u,c,l,f,d,h,p,v=n[0],g=n[1],y=n[2];e[15]=t===e?(e[12]=t[0]*v+t[4]*g+t[8]*y+t[12],e[13]=t[1]*v+t[5]*g+t[9]*y+t[13],e[14]=t[2]*v+t[6]*g+t[10]*y+t[14],t[3]*v+t[7]*g+t[11]*y+t[15]):(r=t[0],i=t[1],o=t[2],a=t[3],s=t[4],u=t[5],c=t[6],l=t[7],f=t[8],d=t[9],h=t[10],p=t[11],e[0]=r,e[1]=i,e[2]=o,e[3]=a,e[4]=s,e[5]=u,e[6]=c,e[7]=l,e[8]=f,e[9]=d,e[10]=h,e[11]=p,e[12]=r*v+s*g+f*y+t[12],e[13]=i*v+u*g+d*y+t[13],e[14]=o*v+c*g+h*y+t[14],a*v+l*g+p*y+t[15]);return e}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(81);n.d(t,"default",function(){return r.a}),n.d(t,"WebMercatorViewport",function(){return r.a});var i=n(285);n.d(t,"fitBounds",function(){return i.a});var o=n(686);n.d(t,"normalizeViewportProps",function(){return o.a});var a=n(685);n.d(t,"flyToViewport",function(){return a.a});var s=n(80);n.d(t,"lngLatToWorld",function(){return s.a}),n.d(t,"worldToLngLat",function(){return s.b}),n.d(t,"worldToPixels",function(){return s.c}),n.d(t,"pixelsToWorld",function(){return s.d}),n.d(t,"getMeterZoom",function(){return s.e}),n.d(t,"getDistanceScales",function(){return s.f}),n.d(t,"getWorldPosition",function(){return s.g}),n.d(t,"getViewMatrix",function(){return s.h}),n.d(t,"getProjectionMatrix",function(){return s.i}),n.d(t,"PerspectiveMercatorViewport",function(){return r.a}),n.d(t,"getUncenteredViewMatrix",function(){return s.h}),n.d(t,"projectFlat",function(){return s.a}),n.d(t,"unprojectFlat",function(){return s.b})},function(e,t,h){"use strict";t.j=T,t.k=x,t.a=O,t.b=function(e,t,n){var r,i=b(e,2),o=i[0],a=i[1],s=o/(t*=S)*(2*c)-c;r=!0===n?c-2*a*c/t:2*(Math.atan(Math.exp(c-a/t*(2*c)))-E);return[s*P,r*P]},t.e=function(e){var t=e.latitude;_()(Number.isFinite(t));var n=Math.cos(t*w);return x(A*n)-8},t.f=R,t.g=function(e){var t=e.longitude,n=e.latitude,r=e.zoom,i=e.scale,o=e.meterOffset,a=e.distanceScales,s=void 0===a?null:a;i=void 0!==i?i:T(r);var u=O([t,n],i,!!s&&s.isGeographicCoordinateSystem),c=new f.Vector3(u[0],u[1],0);if(o){s=s||R({latitude:n,longitude:t,scale:i});var l=new f.Vector3(o).scale(s.pixelsPerMeter).scale([1,-1,1]);c.add(l)}return c},t.h=function(e){var t=e.height,n=e.pitch,r=e.bearing,i=e.altitude,o=e.center,a=void 0===o?null:o,s=e.flipY,u=void 0!==s&&s,c=h.i(p.a)();d()(c,c,[0,0,-i]),l()(c,c,[1,1,1/t]),v()(c,c,-n*w),g()(c,c,r*w),u&&l()(c,c,[1,-1,1]);a&&d()(c,c,new f.Vector3(a).negate());return c},t.i=function(e){var t=e.width,n=e.height,r=e.pitch,i=e.altitude,o=e.farZMultiplier,a=void 0===o?10:o,s=(p={altitude:i,pitch:r},v=p.altitude,g=p.pitch*w,y=Math.atan(.5/v),_=Math.sin(y)*v/Math.sin(Math.PI/2-g-y),{farZ:Math.cos(Math.PI/2-g)*_+v,nearZ:.1}),u=s.nearZ,c=s.farZ,l=(f={height:n,altitude:i},d=f.height,h=f.altitude,2*Math.atan(d/2/h));var f,d,h;var p,v,g,y,_;return m()([],l,t/n,u,c*a)},t.c=function(e,t){var n=b(e,3),r=n[0],i=n[1],o=n[2],a=void 0===o?0:o;return _()(Number.isFinite(r)&&Number.isFinite(i)&&Number.isFinite(a)),h.i(p.b)(t,[r,i,a,1])},t.d=function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,r=b(e,3),i=r[0],o=r[1],a=r[2];if(_()(Number.isFinite(i)&&Number.isFinite(o)),Number.isFinite(a)){var s=h.i(p.b)(t,[i,o,a,1]);return s}var u=h.i(p.b)(t,[i,o,0,1]),c=h.i(p.b)(t,[i,o,1,1]),l=u[2],f=c[2],d=l===f?0:((n||0)-l)/(f-l);return y()([],u,c,d)};var f=h(16),p=h(118),n=h(76),m=h.n(n),r=h(77),l=h.n(r),i=h(78),d=h.n(i),o=h(157),v=h.n(o),a=h(158),g=h.n(a),s=h(238),y=h.n(s),u=h(1),_=h.n(u),b=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},c=Math.PI,E=c/4,w=c/180,P=180/c,S=512,A=4003e4;function T(e){return Math.pow(2,e)}function x(e){return Math.log2(e)}function O(e,t,n){var r=b(e,2),i=r[0],o=r[1]*w;return[(t*=S)*(i*w+c)/(2*c),!0===n?t*(c-o)/(2*c):t*(c-Math.log(Math.tan(E+.5*o)))/(2*c)]}function R(e){var t=e.latitude,n=e.longitude,r=e.zoom,i=e.scale,o=e.highPrecision,a=e.isGeographicCoordinateSystem,s=void 0!==o&&o;i=void 0!==i?i:T(r),_()(Number.isFinite(t)&&Number.isFinite(n)&&Number.isFinite(i));var u={},c=S*i,l=Math.cos(t*w),f=c/360,d=f/l,h=c/A/l;if(u.pixelsPerMeter=[h,h,h],u.metersPerPixel=[1/h,1/h,1/h],u.pixelsPerDegree=[f,d,h],u.degreesPerPixel=[1/f,1/d,1/h],s){var p=w*Math.tan(t*w)/l,v=f*p/2,g=c/A*p,y=g/d*h;u.pixelsPerDegree2=[0,v,g],u.pixelsPerMeter2=[y,0,y]}return u.isGeographicCoordinateSystem=a,u}},function(e,t,P){"use strict";var n=P(687),S=P(80),o=P(285),r=P(159),s=P.n(r),i=P(160),u=P.n(i),a=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var c=function(e){function w(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.width,n=e.height,r=e.latitude,i=void 0===r?0:r,o=e.longitude,a=void 0===o?0:o,s=e.zoom,u=void 0===s?0:s,c=e.pitch,l=void 0===c?0:c,f=e.bearing,d=void 0===f?0:f,h=e.altitude,p=void 0===h?1.5:h,v=e.isGeographicCoordinateSystem,g=void 0===_ref$farZMultiplier||_ref$farZMultiplier;_ref$farZMultiplier=e.farZMultiplier,g=void 0===_ref$farZMultiplier?10:_ref$farZMultiplier,function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,w),t=t||1,n=n||1;var y=P.i(S.j)(u);p=Math.max(.75,p);var _=P.i(S.g)({longitude:a,latitude:i,scale:y}),m=P.i(S.i)({width:t,height:n,pitch:l,bearing:d,altitude:p,farZMultiplier:g}),b=P.i(S.h)({height:n,center:_,pitch:l,bearing:d,altitude:p,flipY:!0}),E=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(w.__proto__||Object.getPrototypeOf(w)).call(this,{width:t,height:n,viewMatrix:b,projectionMatrix:m,isGeographicCoordinateSystem:v}));return E.latitude=i,E.longitude=a,E.zoom=u,E.pitch=l,E.bearing=d,E.altitude=p,E.scale=y,E.center=_,Object.freeze(E),E}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(w,n["a"]),a(w,[{key:"projectFlat",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return P.i(S.a)(e,t)}},{key:"unprojectFlat",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return P.i(S.b)(e,t)}},{key:"getMapCenterByLngLatPosition",value:function(e){var t=e.lngLat,n=e.pos,r=P.i(S.d)(n,this.pixelUnprojectionMatrix),i=P.i(S.a)(t,this.scale),o=s()([],i,u()([],r)),a=s()([],this.center,o);return P.i(S.b)(a,this.scale)}},{key:"getLocationAtPoint",value:function(e){var t=e.lngLat,n=e.pos;return this.getMapCenterByLngLatPosition({lngLat:t,pos:n})}},{key:"fitBounds",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=this.width,r=this.height,i=P.i(o.a)(Object.assign({width:n,height:r,bounds:e},t));return new w({width:n,height:r,longitude:i.longitude,latitude:i.latitude,zoom:i.zoom})}}]),w}();t.a=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MAPBOX_LIMITS=void 0;var d=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=o(n(180)),s=n(79),h=o(s),x=o(n(1));function o(e){return e&&e.__esModule?e:{default:e}}var O=t.MAPBOX_LIMITS={minZoom:0,maxZoom:20,minPitch:0,maxPitch:60},R=0,C=0,k=1.5;function c(e,t,n){return e<t?t:n<e?n:e}var a=function(e){function T(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.width,n=e.height,r=e.latitude,i=e.longitude,o=e.zoom,a=e.bearing,s=void 0===a?C:a,u=e.pitch,c=void 0===u?R:u,l=e.altitude,f=void 0===l?k:l,d=e.maxZoom,h=void 0===d?O.maxZoom:d,p=e.minZoom,v=void 0===p?O.minZoom:p,g=e.maxPitch,y=void 0===g?O.maxPitch:g,_=e.minPitch,m=void 0===_?O.minPitch:_,b=e.startPanLngLat,E=e.startZoomLngLat,w=e.startBearing,P=e.startPitch,S=e.startZoom;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,T),(0,x.default)(Number.isFinite(i),"`longitude` must be supplied"),(0,x.default)(Number.isFinite(r),"`latitude` must be supplied"),(0,x.default)(Number.isFinite(o),"`zoom` must be supplied");var A=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(T.__proto__||Object.getPrototypeOf(T)).call(this,{width:t,height:n,latitude:r,longitude:i,zoom:o,bearing:s,pitch:c,altitude:f,maxZoom:h,minZoom:v,maxPitch:y,minPitch:m}));return A._interactiveState={startPanLngLat:b,startZoomLngLat:E,startBearing:w,startPitch:P,startZoom:S},A}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(T,i.default),r(T,[{key:"getViewportProps",value:function(){return this._viewportProps}},{key:"getInteractiveState",value:function(){return this._interactiveState}},{key:"panStart",value:function(e){var t=e.pos;return this._getUpdatedState({startPanLngLat:this._unproject(t)})}},{key:"pan",value:function(e){var t=e.pos,n=e.startPos,r=this._interactiveState.startPanLngLat||this._unproject(n);if(!r)return this;var i=this._calculateNewLngLat({startPanLngLat:r,pos:t}),o=d(i,2),a=o[0],s=o[1];return this._getUpdatedState({longitude:a,latitude:s})}},{key:"panEnd",value:function(){return this._getUpdatedState({startPanLngLat:null})}},{key:"rotateStart",value:function(e){e.pos;return this._getUpdatedState({startBearing:this._viewportProps.bearing,startPitch:this._viewportProps.pitch})}},{key:"rotate",value:function(e){var t=e.deltaScaleX,n=void 0===t?0:t,r=e.deltaScaleY,i=void 0===r?0:r,o=this._interactiveState,a=o.startBearing,s=o.startPitch;if(!Number.isFinite(a)||!Number.isFinite(s))return this;var u=this._calculateNewPitchAndBearing({deltaScaleX:n,deltaScaleY:i,startBearing:a,startPitch:s}),c=u.pitch,l=u.bearing;return this._getUpdatedState({bearing:l,pitch:c})}},{key:"rotateEnd",value:function(){return this._getUpdatedState({startBearing:null,startPitch:null})}},{key:"zoomStart",value:function(e){var t=e.pos;return this._getUpdatedState({startZoomLngLat:this._unproject(t),startZoom:this._viewportProps.zoom})}},{key:"zoom",value:function(e){var t=e.pos,n=e.startPos,r=e.scale;(0,x.default)(0<r,"`scale` must be a positive number");var i=this._interactiveState,o=i.startZoom,a=i.startZoomLngLat;Number.isFinite(o)||(o=this._viewportProps.zoom,a=this._unproject(n)||this._unproject(t)),(0,x.default)(a,"`startZoomLngLat` prop is required for zoom behavior to calculate where to position the map.");var s=this._calculateNewZoom({scale:r,startZoom:o}),u=new h.default(Object.assign({},this._viewportProps,{zoom:s})).getLocationAtPoint({lngLat:a,pos:t}),c=d(u,2),l=c[0],f=c[1];return this._getUpdatedState({zoom:s,longitude:l,latitude:f})}},{key:"zoomEnd",value:function(){return this._getUpdatedState({startZoomLngLat:null,startZoom:null})}},{key:"zoomIn",value:function(){return this._zoomFromCenter(2)}},{key:"zoomOut",value:function(){return this._zoomFromCenter(.5)}},{key:"moveLeft",value:function(){return this._panFromCenter([100,0])}},{key:"moveRight",value:function(){return this._panFromCenter([-100,0])}},{key:"moveUp",value:function(){return this._panFromCenter([0,100])}},{key:"moveDown",value:function(){return this._panFromCenter([0,-100])}},{key:"rotateLeft",value:function(){return this._getUpdatedState({bearing:this._viewportProps.bearing-15})}},{key:"rotateRight",value:function(){return this._getUpdatedState({bearing:this._viewportProps.bearing+15})}},{key:"rotateUp",value:function(){return this._getUpdatedState({pitch:this._viewportProps.pitch+10})}},{key:"rotateDown",value:function(){return this._getUpdatedState({pitch:this._viewportProps.pitch-10})}},{key:"_zoomFromCenter",value:function(e){var t=this._viewportProps,n=t.width,r=t.height;return this.zoom({pos:[n/2,r/2],scale:e})}},{key:"_panFromCenter",value:function(e){var t=this._viewportProps,n=t.width,r=t.height;return this.pan({startPos:[n/2,r/2],pos:[n/2+e[0],r/2+e[1]]})}},{key:"_getUpdatedState",value:function(e){return new T(Object.assign({},this._viewportProps,this._interactiveState,e))}},{key:"_applyConstraints",value:function(e){var t=e.maxZoom,n=e.minZoom,r=e.zoom;e.zoom=c(r,n,t);var i=e.maxPitch,o=e.minPitch,a=e.pitch;return e.pitch=c(a,o,i),Object.assign(e,(0,s.normalizeViewportProps)(e)),e}},{key:"_unproject",value:function(e){var t=new h.default(this._viewportProps);return e&&t.unproject(e)}},{key:"_calculateNewLngLat",value:function(e){var t=e.startPanLngLat,n=e.pos;return new h.default(this._viewportProps).getMapCenterByLngLatPosition({lngLat:t,pos:n})}},{key:"_calculateNewZoom",value:function(e){var t=e.scale,n=e.startZoom,r=this._viewportProps,i=r.maxZoom,o=r.minZoom;return c(n+Math.log2(t),o,i)}},{key:"_calculateNewPitchAndBearing",value:function(e){var t=e.deltaScaleX,n=e.deltaScaleY,r=e.startBearing,i=e.startPitch;n=c(n,-1,1);var o=this._viewportProps,a=o.minPitch,s=o.maxPitch,u=i;return 0<n?u=i+n*(s-i):n<0&&(u=i-n*(a-i)),{pitch:u,bearing:r+180*t}}}]),T}();t.default=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(12),i=s(n(344)),o=s(n(334)),a=n(345);function s(e){return e&&e.__esModule?e:{default:e}}var u={};t.default={name:"project",dependencies:[r.fp32],vs:""+i.default+o.default,getUniforms:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:u;return e.viewport?(0,a.getUniformsFromViewport)(e):{}},deprecations:[{type:"uniform vec3",old:"selectedPickingColor",new:"luma.gl's picking module"},{type:"uniform float",old:"renderPickingBuffer",new:"luma.gl's picking module"},{type:"uniform float",old:"pickingEnabled",new:"luma.gl's picking module"},{type:"uniform float",old:"projectionMode",new:"project_uCoordinateSystem"},{type:"uniform vec4",old:"projectionCenter",new:"project_uCenter"},{type:"uniform vec2",old:"projectionOrigin"},{type:"uniform mat4",old:"modelMatrix",new:"project_uModelMatrix"},{type:"uniform mat4",old:"viewMatrix"},{type:"uniform mat4",old:"projectionMatrix",new:"project_uViewProjectionMatrix"},{type:"uniform vec3",old:"projectionPixelsPerUnit",new:"project_uPixelsPerUnit"},{type:"uniform float",old:"projectionScale",new:"project_uScale"},{type:"uniform vec2",old:"viewportSize",new:"project_uViewportSize"},{type:"uniform float",old:"devicePixelRatio",new:"project_uDevicePixelRatio"},{type:"uniform vec3",old:"cameraPos",new:"project_uCameraPosition"},{type:"function",old:"scale",new:"project_scale",deprecated:1},{type:"function",old:"preproject",new:"project_position",deprecated:1},{type:"function",old:"project",new:"project_to_clipspace",deprecated:1}]}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.lerp=function n(e,r,i){if(Array.isArray(e))return e.map(function(e,t){return n(e,r[t],i)});return i*r+(1-i)*e},t.isValid=a,t.getEndValueByShortestPath=function(e,t,n){s(e)&&180<Math.abs(n-t)&&(n=n<0?n+360:n-360);return n},t.extractViewportFrom=function(n){var r={};return o.forEach(function(e){var t=n[e];a(t)&&(r[e]=t,s(e)&&(r[e]=(0,i.mod)(t+180,360)-180))}),r};var i=n(127),o=["width","height","longitude","latitude","zoom","bearing","pitch","position"],r={longitude:1,bearing:1};function a(e){return Number.isFinite(e)||Array.isArray(e)}function s(e){return r[e]}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var u=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=o(n(42)),M=n(127),L=o(n(75)),I=o(n(102)),N=o(n(77)),F=o(n(76)),j=o(n(78)),D=o(n(157)),B=o(n(235)),U=o(n(158));function o(e){return e&&e.__esModule?e:{default:e}}var G=Math.PI/180,a=function(e){function k(e){var t=e.id,n=void 0===t?"orbit-viewport":t,r=e.width,i=e.height,o=e.distance,a=e.rotationX,s=void 0===a?0:a,u=e.rotationOrbit,c=void 0===u?0:u,l=e.orbitAxis,f=void 0===l?"Z":l,d=e.lookAt,h=void 0===d?[0,0,0]:d,p=e.up,v=void 0===p?[0,1,0]:p,g=e.fov,y=void 0===g?75:g,_=e.near,m=void 0===_?1:_,b=e.far,E=void 0===b?100:b,w=e.zoom,P=void 0===w?1:w;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,k);var S=(0,D.default)([],(0,M.createMat4)(),-s/180*Math.PI);"Z"===f?(0,U.default)(S,S,-c/180*Math.PI):(0,B.default)(S,S,-c/180*Math.PI);var A=(0,M.createMat4)();(0,N.default)(A,A,[P,P,P]),(0,j.default)(A,A,[-h[0],-h[1],-h[2]]);var T=(0,I.default)([],[0,0,o],[0,0,0],v),x=y*G,O=r/i,R=(0,F.default)([],x,O,m,E),C=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(k.__proto__||Object.getPrototypeOf(k)).call(this,{id:n,viewMatrix:(0,L.default)(T,T,(0,L.default)(S,S,A)),projectionMatrix:R,width:r,height:i}));return C.width=r,C.height=i,C.distance=o,C.rotationX=s,C.rotationOrbit=c,C.orbitAxis=f,C.lookAt=h,C.up=v,C.fov=y,C.near=m,C.far=E,C.zoom=P,C}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(k,i.default),r(k,[{key:"project",value:function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).topLeft,n=void 0!==t&&t,r=(0,M.transformVector)(this.pixelProjectionMatrix,[].concat(function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(e),[1])),i=u(r,3),o=i[0],a=i[1],s=i[2];return[o,n?this.height-a:a,s]}},{key:"unproject",value:function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).topLeft,n=void 0!==t&&t,r=u(e,3),i=r[0],o=r[1],a=r[2],s=n?this.height-o:o;return(0,M.transformVector)(this.pixelUnprojectionMatrix,[i,s,a,1])}},{key:"fitBounds",value:function(e){var t=this.width,n=this.height,r=this.rotationX,i=this.rotationOrbit,o=this.orbitAxis,a=this.lookAt,s=this.up,u=this.fov;return new k({width:t,height:n,rotationX:r,rotationOrbit:i,orbitAxis:o,up:s,fov:u,near:this.near,far:this.far,zoom:this.zoom,lookAt:a,distance:Math.max(e[0],e[1],e[2])/2/Math.tan(u/180*Math.PI/2)})}}]),k}();(t.default=a).displayName="OrbitViewport"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var h=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=o(n(42)),w=n(79),s=o(n(159)),u=o(n(160)),f=o(n(1));function o(e){return e&&e.__esModule?e:{default:e}}var d="Illegal argument to WebMercatorViewport",a=function(e){function E(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,E);var t=e.latitude,n=void 0===t?0:t,r=e.longitude,i=void 0===r?0:r,o=e.zoom,a=void 0===o?11:o,s=e.pitch,u=void 0===s?0:s,c=e.bearing,l=void 0===c?0:c,f=e.farZMultiplier,d=void 0===f?10:f,h=e.width,p=e.height,v=e.altitude,g=e.isGeographicCoordinateSystem,y=void 0===v?1.5:v;h=h||1,p=p||1,y=Math.max(.75,y);var _=(0,w.getProjectionMatrix)({width:h,height:p,pitch:u,altitude:y,farZMultiplier:d}),m=(0,w.getViewMatrix)({height:p,pitch:u,bearing:l,altitude:y}),b=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(E.__proto__||Object.getPrototypeOf(E)).call(this,Object.assign({},e,{position:e.position&&[e.position[0],e.position[1],0],width:h,height:p,viewMatrix:m,longitude:i,latitude:n,zoom:a,projectionMatrix:_,isGeographicCoordinateSystem:g,focalDistance:1})));return b.latitude=n,b.longitude=i,b.zoom=a,b.pitch=u,b.bearing=l,b.altitude=y,b.metersToLngLatDelta=b.metersToLngLatDelta.bind(b),b.lngLatDeltaToMeters=b.lngLatDeltaToMeters.bind(b),b.addMetersToLngLat=b.addMetersToLngLat.bind(b),Object.freeze(b),b}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(E,i.default),r(E,[{key:"_projectFlat",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return(0,w.lngLatToWorld)(e,t)}},{key:"_unprojectFlat",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return(0,w.worldToLngLat)(e,t,this.isGeographicCoordinateSystem)}},{key:"metersToLngLatDelta",value:function(e){var t=h(e,3),n=t[0],r=t[1],i=t[2],o=void 0===i?0:i;(0,f.default)(Number.isFinite(n)&&Number.isFinite(r)&&Number.isFinite(o),d);var a=this.distanceScales,s=a.pixelsPerMeter,u=a.degreesPerPixel,c=n*s[0]*u[0],l=r*s[1]*u[1];return 2===e.length?[c,l]:[c,l,o]}},{key:"lngLatDeltaToMeters",value:function(e){var t=h(e,3),n=t[0],r=t[1],i=t[2],o=void 0===i?0:i;(0,f.default)(Number.isFinite(n)&&Number.isFinite(r)&&Number.isFinite(o),d);var a=this.distanceScales,s=a.pixelsPerDegree,u=a.metersPerPixel,c=n*s[0]*u[0],l=r*s[1]*u[1];return 2===e.length?[c,l]:[c,l,o]}},{key:"addMetersToLngLat",value:function(e,t){var n=h(e,3),r=n[0],i=n[1],o=n[2],a=void 0===o?0:o,s=this.metersToLngLatDelta(t),u=h(s,3),c=u[0],l=u[1],f=u[2],d=void 0===f?0:f;return 2===e.length?[r+c,i+l]:[r+c,i+l,a+d]}},{key:"getMapCenterByLngLatPosition",value:function(e){var t=e.lngLat,n=e.pos,r=(0,w.pixelsToWorld)(n,this.pixelUnprojectionMatrix),i=(0,w.lngLatToWorld)(t,this.scale),o=(0,s.default)([],i,(0,u.default)([],r)),a=(0,s.default)([],this.center,o);return(0,w.worldToLngLat)(a,this.scale,this.isGeographicCoordinateSystem)}},{key:"getLocationAtPoint",value:function(e){var t=e.lngLat,n=e.pos;return this.getMapCenterByLngLatPosition({lngLat:t,pos:n})}},{key:"fitBounds",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=this.width,r=this.height,i=(0,w.fitBounds)(Object.assign({width:n,height:r,bounds:e},t));return new E({width:n,height:r,longitude:i.longitude,latitude:i.latitude,zoom:i.zoom})}},{key:"isMapSynched",value:function(){var e=60,t=40,n=this.pitch,r=this.zoom;return n<=e+1e-6&&r<=t+1e-6}}]),E}();(t.default=a).displayName="WebMercatorViewport"},function(e,t,n){var u=n(24),c=n(11),l=n(57);e.exports=function(s){return function(e,t,n){var r,i=u(e),o=c(i.length),a=l(n,o);if(s&&t!=t){for(;a<o;)if((r=i[a++])!=r)return!0}else for(;a<o;a++)if((s||a in i)&&i[a]===t)return s||a||0;return!s&&-1}}},function(e,t,n){"use strict";var y=n(3),_=n(0),m=n(20),b=n(55),E=n(44),w=n(49),P=n(48),S=n(5),A=n(4),T=n(93),x=n(64),O=n(135);e.exports=function(r,e,t,n,i,o){var a=y[r],s=a,u=i?"set":"add",c=s&&s.prototype,l={},f=function(e){var n=c[e];m(c,e,"delete"==e?function(e){return!(o&&!S(e))&&n.call(this,0===e?0:e)}:"has"==e?function(e){return!(o&&!S(e))&&n.call(this,0===e?0:e)}:"get"==e?function(e){return o&&!S(e)?void 0:n.call(this,0===e?0:e)}:"add"==e?function(e){return n.call(this,0===e?0:e),this}:function(e,t){return n.call(this,0===e?0:e,t),this})};if("function"==typeof s&&(o||c.forEach&&!A(function(){(new s).entries().next()}))){var d=new s,h=d[u](o?{}:-0,1)!=d,p=A(function(){d.has(1)}),v=T(function(e){new s(e)}),g=!o&&A(function(){for(var e=new s,t=5;t--;)e[u](t,t);return!e.has(-0)});v||(((s=e(function(e,t){P(e,s,r);var n=O(new a,e,s);return null!=t&&w(t,i,n[u],n),n})).prototype=c).constructor=s),(p||g)&&(f("delete"),f("has"),i&&f("get")),(g||h)&&f(u),o&&c.clear&&delete c.clear}else s=n.getConstructor(e,r,i,u),b(s.prototype,t),E.NEED=!0;return x(s,r),l[r]=s,_(_.G+_.W+_.F*(s!=a),l),o||n.setStrong(s,r,i),s}},function(e,t,n){"use strict";var s=n(19),u=n(20),c=n(4),l=n(34),f=n(6);e.exports=function(t,e,n){var r=f(t),i=n(l,r,""[t]),o=i[0],a=i[1];c(function(){var e={};return e[r]=function(){return 7},7!=""[t](e)})&&(u(String.prototype,t,o),s(RegExp.prototype,r,2==e?function(e,t){return a.call(e,this,t)}:function(e){return a.call(e,this)}))}},function(e,t,n){"use strict";var r=n(2);e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,n){var r=n(27);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){var r=n(5),i=n(27),o=n(6)("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[o])?!!t:"RegExp"==i(e))}},function(e,t,n){var o=n(6)("iterator"),a=!1;try{var r=[7][o]();r.return=function(){a=!0},Array.from(r,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!a)return!1;var n=!1;try{var r=[7],i=r[o]();i.next=function(){return{done:n=!0}},r[o]=function(){return i},e(r)}catch(e){}return n}},function(e,t,n){"use strict";e.exports=n(50)||!n(4)(function(){var e=Math.random();__defineSetter__.call(null,e,function(){}),delete n(3)[e]})},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){"use strict";var r=n(0),a=n(15),s=n(28),u=n(49);e.exports=function(e){r(r.S,e,{from:function(e){var t,n,r,i,o=arguments[1];return a(this),(t=void 0!==o)&&a(o),null==e?new this:(n=[],t?(r=0,i=s(o,arguments[2],2),u(e,!1,function(e){n.push(i(e,r++))})):u(e,!1,n.push,n),new this(n))}})}},function(e,t,n){"use strict";var r=n(0);e.exports=function(e){r(r.S,e,{of:function(){for(var e=arguments.length,t=new Array(e);e--;)t[e]=arguments[e];return new this(t)}})}},function(e,t,n){var r=n(3),i="__core-js_shared__",o=r[i]||(r[i]={});e.exports=function(e){return o[e]||(o[e]={})}},function(e,t,n){var i=n(2),o=n(15),a=n(6)("species");e.exports=function(e,t){var n,r=i(e).constructor;return void 0===r||null==(n=i(r)[a])?t:o(n)}},function(e,t,n){for(var r,i=n(3),o=n(19),a=n(58),s=a("typed_array"),u=a("view"),c=!(!i.ArrayBuffer||!i.DataView),l=c,f=0,d="Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array".split(",");f<9;)(r=i[d[f++]])?(o(r.prototype,s,!0),o(r.prototype,u,!0)):l=!1;e.exports={ABV:c,CONSTR:l,TYPED:s,VIEW:u}},function(t,e,n){"use strict";(function(e){var f=function(e){};"production"!==e.env.NODE_ENV&&(f=function(e){if(void 0===e)throw new Error("invariant requires an error message argument")}),t.exports=function(e,t,n,r,i,o,a,s){if(f(t),!e){var u;if(void 0===t)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,i,o,a,s],l=0;(u=new Error(t.replace(/%s/g,function(){return c[l++]}))).name="Invariant Violation"}throw u.framesToPop=1,u}}}).call(e,n(26))},function(e,t,n){var P=n(572);e.exports=function(e,t,n,r){var i,o,a,s,u,c,l,f,d,h,p=t[0],v=t[1],g=t[2],y=r[0],_=r[1],m=r[2],b=n[0],E=n[1],w=n[2];if(Math.abs(p-b)<1e-6&&Math.abs(v-E)<1e-6&&Math.abs(g-w)<1e-6)return P(e);l=p-b,f=v-E,d=g-w,h=1/Math.sqrt(l*l+f*f+d*d),i=_*(d*=h)-m*(f*=h),o=m*(l*=h)-y*d,a=y*f-_*l,(h=Math.sqrt(i*i+o*o+a*a))?(i*=h=1/h,o*=h,a*=h):a=o=i=0;s=f*a-d*o,u=d*i-l*a,c=l*o-f*i,(h=Math.sqrt(s*s+u*u+c*c))?(s*=h=1/h,u*=h,c*=h):c=u=s=0;return e[0]=i,e[1]=s,e[2]=l,e[3]=0,e[4]=o,e[5]=u,e[6]=f,e[7]=0,e[8]=a,e[9]=c,e[10]=d,e[11]=0,e[12]=-(i*p+o*v+a*g),e[13]=-(s*p+u*v+c*g),e[14]=-(l*p+f*v+d*g),e[15]=1,e}},function(e,t){e.exports=function(e,t,n){var r=t[0],i=t[1],o=t[2],a=t[3];return e[0]=n[0]*r+n[4]*i+n[8]*o+n[12]*a,e[1]=n[1]*r+n[5]*i+n[9]*o+n[13]*a,e[2]=n[2]*r+n[6]*i+n[10]*o+n[14]*a,e[3]=n[3]*r+n[7]*i+n[11]*o+n[15]*a,e}},function(e,t,W){"use strict";var X=W(61),c=W(168),H=W(45),n=W(250),_=W(8),f=W(657),d=W(642),h=W(628),Y=W(273),r=W(1),K=W.n(r),i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var o=["renderPickingBuffer","pickingEnabled"],a=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,t));return K()(W.i(X.isWebGL)(e)),n.gl=e,n.init(t),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,n["a"]),i(r,[{key:"init",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.vs,n=void 0===t?null:t,r=e.fs,i=void 0===r?null:r,o=e.modules,a=void 0===o?null:o,s=e.defines,u=void 0===s?{}:s,c=e.moduleSettings,l=void 0===c?{}:c,f=e.defaultUniforms,d=e.program,h=void 0===d?null:d,p=e.shaderCache,v=void 0===p?null:p,g=e.isInstanced,y=void 0!==g&&g,_=e.instanced,m=e.vertexCount,b=void 0===m?void 0:m,E=e.instanceCount,w=void 0===E?0:E,P=e.drawMode,S=e.uniforms,A=void 0===S?{}:S,T=e.attributes,x=void 0===T?{}:T,O=e.geometry,R=void 0===O?null:O,C=e.pickable,k=void 0===C||C,M=e.pick,L=void 0===M?null:M,I=(e.render,e.onBeforeRender),N=void 0===I?function(){}:I,F=e.onAfterRender,j=void 0===F?function(){}:F,D=e.varyings,B=void 0===D?null:D,U=e.bufferMode,G=void 0===U?X.GL.SEPARATE_ATTRIBS:U,V=e.timerQueryEnabled,z=void 0!==V&&V;this._initializeProgram({vs:n,fs:i,modules:a,defines:u,moduleSettings:l,defaultUniforms:f,program:h,shaderCache:v,varyings:B,bufferMode:G}),this.uniforms={},A=Object.assign({},this.program.defaultUniforms,A),this.setUniforms(A),this.setUniforms(this.getModuleUniforms()),this.setUniforms(this.getModuleUniforms(l)),_&&(console.warn('Warning: Model constructor: parameter "instanced" renamed to "isInstanced".\nThis will become a hard error in a future version of luma.gl.'),y=y||_),this.buffers={},this.samplers={},this.userData={},this.drawParams={},this.dynamic=!1,this.needsRedraw=!0,R&&this.setGeometry(R),this.attributes={},this.setAttributes(x),void 0!==P&&(this.drawMode=W.i(H.b)(P)),void 0!==b&&(this.vertexCount=b),this.isInstanced=y,this.instanceCount=w,this.pickable=Boolean(k),this.pick=L||function(){return!1},this.onBeforeRender=N,this.onAfterRender=j,K()(void 0!==this.drawMode&&Number.isFinite(this.vertexCount),"Model needs drawMode and vertexCount"),this.timerQueryEnabled=z&&Y.a.isSupported(this.gl,{timer:!0}),this.timeElapsedQuery=void 0,this.lastQueryReturned=!0,this.stats={accumulatedFrameTime:0,averageFrameTime:0,profileFrameCount:0}}},{key:"delete",value:function(){this.program.delete(),W.i(h.a)(this.id)}},{key:"destroy",value:function(){this.delete()}},{key:"setNeedsRedraw",value:function(){var e=!(0<arguments.length&&void 0!==arguments[0])||arguments[0];return this.needsRedraw=e,this}},{key:"getNeedsRedraw",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).clearRedrawFlags,t=void 0!==e&&e,n=!1;return n=n||this.needsRedraw,this.needsRedraw=this.needsRedraw&&!t,n=n||this.geometry.getNeedsRedraw({clearRedrawFlags:t})}},{key:"setDrawMode",value:function(e){return this.drawMode=W.i(H.b)(e),this}},{key:"getDrawMode",value:function(){return this.drawMode}},{key:"setVertexCount",value:function(e){return K()(Number.isFinite(e)),this.vertexCount=e,this}},{key:"getVertexCount",value:function(){return this.vertexCount}},{key:"setInstanceCount",value:function(e){return K()(Number.isFinite(e)),this.instanceCount=e,this}},{key:"getInstanceCount",value:function(){return this.instanceCount}},{key:"getProgram",value:function(){return this.program}},{key:"setGeometry",value:function(e){return this.geometry=e,this.vertexCount=e.getVertexCount(),this.drawMode=e.drawMode,this._createBuffersFromAttributeDescriptors(this.geometry.getAttributes()),this.setNeedsRedraw(),this}},{key:"getAttributes",value:function(){return this.attributes}},{key:"setAttributes",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};return W.i(_.f)(e)||(Object.assign(this.attributes,e),this._createBuffersFromAttributeDescriptors(e),this.setNeedsRedraw()),this}},{key:"getUniforms",value:function(){return this.uniforms}},{key:"setUniforms",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=!1;for(var n in e)if(!W.i(c.d)(this.uniforms[n],e[n])){t=!0;break}return t&&(W.i(X.checkUniformValues)(e,this.id),Object.assign(this.uniforms,e),this.setNeedsRedraw()),this}},{key:"updateModuleSettings",value:function(e){var t=this.getModuleUniforms(e);return this.setUniforms(t)}},{key:"draw",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.moduleSettings,n=void 0===t?null:t,r=e.uniforms,i=void 0===r?{}:r,o=e.attributes,a=void 0===o?{}:o,s=e.samplers,u=void 0===s?{}:s,c=e.parameters,l=void 0===c?{}:c,f=e.settings,d=e.framebuffer,h=void 0===d?null:d,p=e.vertexArray,v=void 0===p?null:p,g=e.transformFeedback,y=void 0===g?null:g;return f&&(_.b.deprecated("settings","parameters"),l=f),n&&this.updateModuleSettings(n),h&&(l=Object.assign(l,{framebuffer:h})),this.render(i,a,u,y,l,v),h&&h.log({priority:2,message:"Rendered to "+h.id}),this}},{key:"render",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null,i=4<arguments.length&&void 0!==arguments[4]?arguments[4]:{},o=5<arguments.length&&void 0!==arguments[5]?arguments[5]:null;W.i(h.b)(this);var a=this.addViewUniforms(e);W.i(h.c)(this.id,a),this.setUniforms(a),this.setAttributes(t),Object.assign(this.samplers,n),_.b.group(2,">>> RENDERING MODEL "+this.id,{collapsed:_.b.priority<=2}),this.setProgramState({vertexArray:o}),this._logAttributesAndUniforms(2,a),this.onBeforeRender();var s=this.drawParams;s.isInstanced&&!this.isInstanced&&_.b.warn("Found instanced attributes on non-instanced model");var u=s.isIndexed,c=s.indexType,l=this.isInstanced,f=this.instanceCount;return this._timerQueryStart(),this.program.draw({parameters:i,drawMode:this.getDrawMode(),vertexCount:this.getVertexCount(),vertexArray:o,transformFeedback:r,isIndexed:u,indexType:c,isInstanced:l,instanceCount:f}),this._timerQueryEnd(),this.onAfterRender(),this.unsetProgramState(),this.setNeedsRedraw(!1),_.b.groupEnd(2,">>> RENDERING MODEL "+this.id),this}},{key:"setProgramState",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).vertexArray,t=void 0===e?null:e,n=this.program;return n.use(),this.drawParams={},n.setBuffers(this.buffers,{drawParams:this.drawParams}),n.checkAttributeBindings({vertexArray:t}),n.setUniforms(this.uniforms,this.samplers),this}},{key:"unsetProgramState",value:function(){return this.program.unsetBuffers(),this}},{key:"addViewUniforms",value:function(e){var t=e.camera,n=e.viewMatrix,r=e.modelMatrix,i=t?t.getUniforms():{},o=n?this.getCoordinateUniforms(n,r):{};return Object.assign({},e,i,o)}},{key:"_initializeProgram",value:function(e){var t=e.vs,n=e.fs,r=e.modules,i=e.defines,o=(e.moduleSettings,e.defaultUniforms,e.program),a=e.shaderCache,s=e.varyings,u=e.bufferMode;if(this.getModuleUniforms=function(e){},!o){t||(t=f.a.vs),n||(n=f.a.fs);var c=W.i(d.a)(this.gl,{vs:t,fs:n,modules:r,defines:i});t=c.vs,n=c.fs,o=a?a.getProgram(this.gl,{vs:t,fs:n,id:this.id}):new X.Program(this.gl,{vs:t,fs:n,varyings:s,bufferMode:u});var l=c.getUniforms;this.getModuleUniforms=l||function(e){}}this.program=o,K()(this.program instanceof X.Program,"Model needs a program")}},{key:"_checkForDeprecatedUniforms",value:function(t){o.forEach(function(e){e in t&&_.b.deprecated(e,"use picking shader module and Model class updateModuleSettings()")})}},{key:"_timerQueryStart",value:function(){!0===this.timerQueryEnabled&&(this.timeElapsedQuery||(this.timeElapsedQuery=new Y.a(this.gl)),this.lastQueryReturned&&(this.lastQueryReturned=!1,this.timeElapsedQuery.beginTimeElapsedQuery()))}},{key:"_timerQueryEnd",value:function(){if(!0===this.timerQueryEnabled&&(this.timeElapsedQuery.end(),this.timeElapsedQuery.isResultAvailable())){this.lastQueryReturned=!0;var e=this.timeElapsedQuery.getResult();this.stats.lastFrameTime=e,this.stats.accumulatedFrameTime+=e,this.stats.profileFrameCount++,this.stats.averageFrameTime=this.stats.accumulatedFrameTime/this.stats.profileFrameCount,_.b.log(2,"GPU time "+this.program.id+": "+this.stats.lastFrameTime+"ms average "+this.stats.averageFrameTime+"ms accumulated: "+this.stats.accumulatedFrameTime+"ms count: "+this.stats.profileFrameCount)}}},{key:"_createBuffersFromAttributeDescriptors",value:function(e){var t=this.program.gl;for(var n in e){var r=e[n];if(r instanceof X.Buffer)this.buffers[n]=r;else if(r.isGeneric)this.buffers[n]=r.value;else{this.buffers[n]=this.buffers[n]||new X.Buffer(t,{target:r.isIndexed?X.GL.ELEMENT_ARRAY_BUFFER:X.GL.ARRAY_BUFFER}),this.buffers[n].setData({data:r.value}).setDataLayout(r)}}return this}},{key:"_logAttributesAndUniforms",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};if(_.b.priority>=e){var n=this._getAttributesTable({header:this.id+" attributes",program:this.program,attributes:Object.assign({},this.geometry.attributes,this.attributes)});_.b.table(e,n);var r=W.i(c.e)({header:this.id+" uniforms",program:this.program,uniforms:Object.assign({},this.uniforms,t)}),i=r.table,o=r.unusedTable,a=r.unusedCount;_.b.table(e,i),_.b.log(e,(a||"No")+" unused uniforms ",o)}else{var s=W.i(c.e)({header:this.id+" uniforms",program:this.program,uniforms:Object.assign({},this.uniforms,t),undefinedOnly:!0}),u=s.table;0<s.count&&_.b.table(e,u)}W.i(h.d)(this,t)}},{key:"_getAttributesTable",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.attributes,n=e.header,r=void 0===n?"Attributes":n,i=(e.instanced,e.program);K()(i);var o=i._attributeLocations,a={};for(var s in o){var u=t[s],c=o[s];a[s]=this._getAttributeEntry(u,c,r)}for(var l in t){var f=t[l];a[l]||(a[l]=this._getAttributeEntry(f,null,r))}return a}},{key:"_getAttributeEntry",value:function(e,t,n){var r=function(e){return Math.round(10*e)/10},i="NOT PROVIDED",o=0,a="N/A",s="N/A",u="N/A",c="N/A";if(e&&null===t&&(t=e.isIndexed?"ELEMENT_ARRAY_BUFFER":"NOT USED"),e instanceof X.Buffer){var l=e;i=l.layout.type,o=l.layout.instanced,a=l.layout.size,s=r(l.data.length/l.layout.size),u=l.data.length*l.data.BYTES_PER_ELEMENT}else e&&(i=e.value.constructor.name,o=e.instanced,a=e.size,s=r(e.value.length/e.size),u=e.value.length*e.value.BYTES_PER_ELEMENT,c=e.value);var f,d,h,p=-1!==(i=String(i).replace("Array","")).indexOf("nt");return f={"Inst/Verts/Comps/Bytes/Type/Loc":(o?"I ":"P ")+" "+s+" (x"+a+"="+u+" "+i+") loc="+t},d=n,h=W.i(_.c)(c,{size:a,isInteger:p}),d in f?Object.defineProperty(f,d,{value:h,enumerable:!0,configurable:!0,writable:!0}):f[d]=h,f}},{key:"isPickable",value:function(){return this.pickable}},{key:"setPickable",value:function(){var e=!(0<arguments.length&&void 0!==arguments[0])||arguments[0];return this.pickable=Boolean(e),this}},{key:"getGeometry",value:function(){return this.geometry}},{key:"varyingMap",get:function(){return this.program.varyingMap}}]),r}();t.a=a},function(e,t,n){"use strict";var r=n(45);var i=function(e){function V(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,V);for(var t=e.bottomRadius,n=void 0===t?0:t,r=e.topRadius,i=void 0===r?0:r,o=e.height,a=void 0===o?1:o,s=e.nradial,u=void 0===s?10:s,c=e.nvertical,l=void 0===c?10:c,f=e.topCap,d=void 0!==f&&f,h=e.bottomCap,p=void 0!==h&&h,v=(d?2:0)+(p?2:0),g=(u+1)*(l+1+v),y=Math.atan2(n-i,a),_=Math.sin,m=Math.cos,b=Math.PI,E=m(y),w=_(y),P=d?-2:0,S=l+(p?2:0),A=u+1,T=new Float32Array(3*g),x=new Float32Array(3*g),O=new Float32Array(2*g),R=new Uint16Array(u*(l+v)*6),C=0,k=0,M=P;M<=S;M++){var L=M/l,I=a*L,N=void 0;N=M<0?(I=0,L=1,n):l<M?(I=a,L=1,i):n+M/l*(i-n),-2!==M&&M!==l+2||(L=N=0),I-=a/2;for(var F=0;F<A;F++){var j=_(F*b*2/u),D=m(F*b*2/u);T[C+0]=j*N,T[C+1]=I,T[C+2]=D*N,x[C+0]=M<0||l<M?0:j*E,x[C+1]=M<0?-1:l<M?1:w,x[C+2]=M<0||l<M?0:D*E,O[k+0]=F/u,O[k+1]=L,k+=2,C+=3}}for(var B=0;B<l+v;B++)for(var U=0;U<u;U++){var G=6*(B*u+U);R[G+0]=A*(B+0)+0+U,R[G+1]=A*(B+0)+1+U,R[G+2]=A*(B+1)+1+U,R[G+3]=A*(B+0)+0+U,R[G+4]=A*(B+1)+1+U,R[G+5]=A*(B+1)+0+U}return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(V.__proto__||Object.getPrototypeOf(V)).call(this,Object.assign({},e,{attributes:{positions:T,normals:x,texCoords:O,indices:R}})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(V,r["a"]),V}();t.a=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(262),i=n(261),o=n(263);n.d(t,"global",function(){return i.b});var a="5.1.4";if(i.b.luma&&i.b.luma.VERSION!==a)throw new Error("luma.gl - multiple VERSIONs detected: "+i.b.luma.VERSION+" vs "+a);i.b.luma||(r.a&&console.log("luma.gl 5.1.4 - set luma.log.priority=1 (or higher) to trace rendering"),i.b.luma=i.b.luma||{VERSION:a,version:a,log:o.a,stats:{},globals:{headlessGL:null,headlessTypes:null,modules:{},nodeIO:{}}}),t.default=i.b.luma},function(e,t,d){"use strict";t.a=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.framebuffer,r=void 0===n?null:n,i=t.color,o=void 0===i?null:i,a=t.depth,s=void 0===a?null:a,u=t.stencil,c=void 0===u?null:u,l={};r&&(l.framebuffer=r);var f=0;o&&(f|=y,!0!==o&&(l.clearColor=o));s&&(f|=v,!0!==s&&(l.clearDepth=s));c&&(f|=g,!0!==s&&(l.clearStencil=s));p()(0!==f,w),d.i(h.f)(e,l,function(){e.clear(f)})},t.b=function(r){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},t=e.framebuffer,n=void 0===t?null:t,i=e.buffer,o=void 0===i?_:i,a=e.drawBuffer,s=void 0===a?0:a,u=e.value,c=void 0===u?[0,0,0,0]:u;p()(d.i(l.b)(r),l.i),d.i(h.f)(r,{framebuffer:n},function(){switch(o){case _:switch(c.constructor){case Int32Array:r.clearBufferiv(o,s,c);break;case Uint32Array:r.clearBufferuiv(o,s,c);break;case Float32Array:default:r.clearBufferfv(o,s,c)}break;case m:r.clearBufferfv(m,0,[c]);break;case b:r.clearBufferiv(b,0,[c]);break;case E:var e=f(c,2),t=e[0],n=e[1];r.clearBufferfi(E,0,t,n);break;default:p()(!1,w)}})};var l=d(7),h=d(68),n=d(1),p=d.n(n),f=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},v=256,g=1024,y=16384,_=6144,m=6145,b=6146,E=34041,w="clear: bad arguments"},function(e,t,o){"use strict";o.d(t,"a",function(){return r}),t.b=function(e,t){return c(e,t)},t.c=c,t.d=function(e){if(e.luma=e.luma||{},!e.luma.caps)for(var t in e.luma.caps={},e.luma.caps.webgl2=o.i(a.b)(e),u)e.luma.caps[t]=i(e,t);return e.luma.caps};var a=o(7),n=o(1),s=o.n(n),u={VERTEX_ARRAY_OBJECT:["OES_vertex_array_object",!0],TIMER_QUERY:["EXT_disjoint_timer_query","EXT_disjoint_timer_query_webgl2"],INSTANCED_RENDERING:["ANGLE_instanced_arrays",!0],MULTIPLE_RENDER_TARGETS:["WEBGL_draw_buffers",!0],ELEMENT_INDEX_UINT32:["OES_element_index_uint",!0],BLEND_EQUATION_MINMAX:["EXT_blend_minmax",!0],COLOR_ENCODING_SRGB:["EXT_sRGB",!0],TEXTURE_DEPTH:["WEBGL_depth_texture",!0],TEXTURE_FLOAT:["OES_texture_float",!0],TEXTURE_HALF_FLOAT:["OES_texture_half_float",!0],TEXTURE_FILTER_LINEAR_FLOAT:["OES_texture_float_linear"],TEXTURE_FILTER_LINEAR_HALF_FLOAT:["OES_texture_half_float_linear"],TEXTURE_FILTER_ANISOTROPIC:["EXT_texture_filter_anisotropic"],COLOR_ATTACHMENT_RGBA32F:["WEBGL_color_buffer_float","EXT_color_buffer_float"],COLOR_ATTACHMENT_FLOAT:[!1,"EXT_color_buffer_float"],COLOR_ATTACHMENT_HALF_FLOAT:[!1,"EXT_color_buffer_half_float"],GLSL_FRAG_DATA:["WEBGL_draw_buffers",!0],GLSL_FRAG_DEPTH:["EXT_frag_depth",!0],GLSL_DERIVATIVES:["OES_standard_derivatives",!0],GLSL_TEXTURE_LOD:["EXT_shader_texture_lod",!0]},r={};function i(e,t){var n=u[t];s()(n,t);var r=o.i(a.b)(e)&&n[1]||n[0],i="string"==typeof r?Boolean(e.getExtension(r)):r;return s()(!1===i||!0===i),i}function c(t,e){return(e=Array.isArray(e)?e:[e]).every(function(e){return i(t,e)})}Object.keys(u).forEach(function(e){r[e]=e})},function(e,t,x){"use strict";var O=x(38),R=x(7),C=x(68),k=x(169),n=x(30),u=x(62),c=x(69),M=x(276),o=x(168),l=x(111),h=x(67),a=x(8),r=x(1),f=x.n(r),i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var s=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,t));return n.initialize(t),n.vertexAttributes=k.a.getDefaultArray(e),Object.seal(n),n._setId(t.id),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,n["a"]),i(r,[{key:"initialize",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.vs,n=e.fs,r=e.defaultUniforms,i=e.varyings,o=e.bufferMode,a=void 0===o?O.a.SEPARATE_ATTRIBS:o;return this.vs="string"==typeof t?new l.b(this.gl,t):t,this.fs="string"==typeof n?new l.c(this.gl,n):n,f()(this.vs instanceof l.b,"Program: bad vertex shader"),f()(this.fs instanceof l.c,"Program: bad fragment shader"),this.defaultUniforms=r,this.varyingMap=i?(x.i(R.g)(this.gl),this.varyings=i,this.gl.transformFeedbackVaryings(this.handle,i,a),function(e,t){var n={},r=0;f()(t===O.a.SEPARATE_ATTRIBS||t===O.a.INTERLEAVED_ATTRIBS);var i=t===O.a.SEPARATE_ATTRIBS?1:0,o=!0,a=!1,s=void 0;try{for(var u,c=e[Symbol.iterator]();!(o=(u=c.next()).done);o=!0){var l=u.value;n[l]=r,r+=i}}catch(e){a=!0,s=e}finally{try{!o&&c.return&&c.return()}finally{if(a)throw s}}return n}(i,a)):{},this._compileAndLink(),this}},{key:"checkAttributeBindings",value:function(e){var t=e.vertexArray,n=t?t.filledLocations:this.vertexAttributes.filledLocations;for(var r in this._attributeToLocationMap){var i=this._attributeToLocationMap[r];n[i]||this._warnedLocations[i]||(a.b.warn("Program "+this.id+": Attribute "+i+":"+r+" not supplied"),this._warnedLocations[i]=!0)}return this}},{key:"reset",value:function(){this.unsetBuffers()}},{key:"use",value:function(){return this.gl.useProgram(this.handle),this}},{key:"draw",value:function(e){var t=this,n=e.drawMode,r=void 0===n?O.a.TRIANGLES:n,i=e.vertexCount,o=e.offset,a=void 0===o?0:o,s=e.start,u=e.end,c=e.isIndexed,l=void 0!==c&&c,f=e.indexType,d=void 0===f?O.a.UNSIGNED_SHORT:f,h=e.isInstanced,p=void 0!==h&&h,v=e.instanceCount,g=void 0===v?0:v,y=e.vertexArray,_=void 0===y?null:y,m=e.transformFeedback,b=void 0===m?null:m,E=e.uniforms,w=void 0===E?{}:E,P=e.samplers,S=void 0===P?{}:P,A=e.parameters,T=void 0===A?{}:A;return(_=_||k.a.getDefaultArray(this.gl)).bind(function(){if(t.gl.useProgram(t.handle),b){var e=x.i(M.b)({drawMode:r});b.begin(e)}t.setUniforms(w,S),x.i(C.f)(t.gl,T,function(){l&&p?t.ext.drawElementsInstanced(r,i,d,a,g):l&&x.i(R.b)(t.gl)&&!isNaN(s)&&!isNaN(u)?t.gl.drawElementsRange(r,s,u,i,d,a):l?t.gl.drawElements(r,i,d,a):p?t.ext.drawArraysInstanced(r,a,i,g):t.gl.drawArrays(r,a,i)}),b&&b.end()}),this}},{key:"setBuffers",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.clear,r=void 0===n||n,i=t.drawParams,o=void 0===i?{}:i;r&&this.vertexAttributes.clearBindings(),o.isInstanced=!1,o.isIndexed=!1,o.indexType=null;for(var a=this._sortBuffersByLocation(e),s=a.locations,u=a.elements,c=0;c<s.length;++c){var l=e[s[c]];if(l)if(l instanceof h.a){var f=l.layout.instanced?1:0;this.vertexAttributes.setBuffer({location:c,buffer:l}),this.vertexAttributes.setDivisor(c,f),o.isInstanced=0<l.layout.instanced,this.vertexAttributes.enable(c)}else this.vertexAttributes.setGeneric({location:c,array:l}),this.vertexAttributes.disable(c,!0);else this.vertexAttributes.disable(c)}if(u){var d=e[u];d.bind(),o.isIndexed=!0,o.indexType=d.layout.type}return this}},{key:"unsetBuffers",value:function(){for(var e=this._attributeCount,t=1;t<e;++t)this.vertexAttributes.disable(t);return this.gl.bindBuffer(O.a.ELEMENT_ARRAY_BUFFER,null),this}},{key:"setUniforms",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};for(var n in e){var r=e[n],i=this._uniformSetters[n],o=t[n];if(i)if(r instanceof c.a&&(r=r.texture),r instanceof u.a){void 0===i.textureIndex&&(i.textureIndex=this._textureIndexCounter++);var a=r,s=i.textureIndex;a.bind(s),o&&o.bind(s),i(s)}else i(r)}return this}},{key:"getAttributeCount",value:function(){return this._getParameter(O.a.ACTIVE_ATTRIBUTES)}},{key:"getAttributeLocation",value:function(e){return this.gl.getAttribLocation(this.handle,e)}},{key:"getAttributeInfo",value:function(e){return this.gl.getActiveAttrib(this.handle,e)}},{key:"getUniformCount",value:function(){return this._getParameter(O.a.ACTIVE_UNIFORMS)}},{key:"getUniformInfo",value:function(e){return this.gl.getActiveUniform(this.handle,e)}},{key:"getUniformLocation",value:function(e){return this.gl.getUniformLocation(this.handle,e)}},{key:"getUniformValue",value:function(e){return this.gl.getUniform(this.handle,e)}},{key:"getVarying",value:function(e,t){return this.gl.getTransformFeedbackVarying(e,t)}},{key:"getFragDataLocation",value:function(e){return x.i(R.g)(this.gl),this.gl.getFragDataLocation(this.handle,e)}},{key:"getAttachedShaders",value:function(){return this.gl.getAttachedShaders(this.handle)}},{key:"_compileAndLink",value:function(){var e=this.gl;if((e.attachShader(this.handle,this.vs.handle),e.attachShader(this.handle,this.fs.handle),a.b.time(3,"linkProgram for "+this._getName()),e.linkProgram(this.handle),a.b.timeEnd(3,"linkProgram for "+this._getName()),e.debug||0<a.b.priority)&&(e.validateProgram(this.handle),!e.getProgramParameter(this.handle,e.LINK_STATUS)))throw new Error("Error linking "+e.getProgramInfoLog(this.handle));this._queryAttributeLocations(),this._queryUniformLocations()}},{key:"_sortBuffersByLocation",value:function(e){var t=null,n=[];if(x.i(a.f)(e))return{locations:n,elements:t};for(var r in n=new Array(this._attributeCount),e){var i=e[r],o=this._attributeToLocationMap[r];if(void 0===o){if(i.target===O.a.ELEMENT_ARRAY_BUFFER&&t)throw new Error(this._print(r)+" duplicate GL.ELEMENT_ARRAY_BUFFER");i.target===O.a.ELEMENT_ARRAY_BUFFER?t=r:this._warnedLocations[o]||(a.b.log(2,this._print(r)+" not used"),this._warnedLocations[o]=!0)}else{if(i.target===O.a.ELEMENT_ARRAY_BUFFER)throw new Error(this._print(r)+":"+o+" has both location and type gl.ELEMENT_ARRAY_BUFFER");n[o]=r}}return{locations:n,elements:t}}},{key:"_areAllAttributesEnabled",value:function(){for(var e=this._attributeCount,t=0;t<e;++t)if(!this.vertexAttributes.isEnabled(t))return!1;return!0}},{key:"_print",value:function(e){return"Program "+this.id+": Attribute "+e}},{key:"_createHandle",value:function(){return this.gl.createProgram()}},{key:"_deleteHandle",value:function(){this.gl.deleteProgram(this.handle)}},{key:"_getName",value:function(){var e=this.vs.getName()||this.fs.getName();return e=(e=e.replace(/shader/i,""))?e+"-program":"program"}},{key:"_getOptionsFromHandle",value:function(e){var t=this.gl.getAttachedShaders(e),n={},r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){var u=a.value;switch(this.gl.getShaderParameter(this.handle,O.a.SHADER_TYPE)){case O.a.VERTEX_SHADER:n.vs=new l.b({handle:u});break;case O.a.FRAGMENT_SHADER:n.fs=new l.c({handle:u})}}}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}},{key:"_getParameter",value:function(e){return this.gl.getProgramParameter(this.handle,e)}},{key:"_queryAttributeLocations",value:function(){this._attributeToLocationMap={},this._attributeCount=this.getAttributeCount();for(var e=0;e<this._attributeCount;e++){var t=this.getAttributeInfo(e).name;this._attributeToLocationMap[t]=this.getAttributeLocation(t)}this._warnedLocations={}}},{key:"_queryUniformLocations",value:function(){var e=this.gl;this._uniformSetters={},this._uniformCount=this.getUniformCount();for(var t=0;t<this._uniformCount;t++){var n=this.getUniformInfo(t),r=x.i(o.a)(n.name),i=this.getUniformLocation(r.name);this._uniformSetters[r.name]=x.i(o.b)(e,i,n,r.isArray)}this._textureIndexCounter=0}},{key:"_setId",value:function(e){if(!e){var t=this._getName();this.id=x.i(a.d)(t)}}}]),r}();t.a=s},function(e,t,u){"use strict";var n,r=u(25),c=u(7),i=u(30),o=u(1),l=u.n(o),a=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var f=36161,d="EXT_color_buffer_float",h=(s(n={},r.a.DEPTH_COMPONENT16,{}),s(n,r.a.DEPTH_COMPONENT24,{gl2:!0}),s(n,r.a.DEPTH_COMPONENT32F,{gl2:!0}),s(n,r.a.STENCIL_INDEX8,{}),s(n,r.a.DEPTH_STENCIL,{}),s(n,r.a.DEPTH24_STENCIL8,{gl2:!0}),s(n,r.a.DEPTH32F_STENCIL8,{gl2:!0}),s(n,r.a.RGBA4,{}),s(n,r.a.RGB565,{}),s(n,r.a.RGB5_A1,{}),s(n,r.a.R8,{gl2:!0}),s(n,r.a.R8UI,{gl2:!0}),s(n,r.a.R8I,{gl2:!0}),s(n,r.a.R16UI,{gl2:!0}),s(n,r.a.R16I,{gl2:!0}),s(n,r.a.R32UI,{gl2:!0}),s(n,r.a.R32I,{gl2:!0}),s(n,r.a.RG8,{gl2:!0}),s(n,r.a.RG8UI,{gl2:!0}),s(n,r.a.RG8I,{gl2:!0}),s(n,r.a.RG16UI,{gl2:!0}),s(n,r.a.RG16I,{gl2:!0}),s(n,r.a.RG32UI,{gl2:!0}),s(n,r.a.RG32I,{gl2:!0}),s(n,r.a.RGB8,{gl2:!0}),s(n,r.a.RGBA8,{gl2:!0}),s(n,r.a.RGB10_A2,{gl2:!0}),s(n,r.a.RGBA8UI,{gl2:!0}),s(n,r.a.RGBA8I,{gl2:!0}),s(n,r.a.RGB10_A2UI,{gl2:!0}),s(n,r.a.RGBA16UI,{gl2:!0}),s(n,r.a.RGBA16I,{gl2:!0}),s(n,r.a.RGBA32I,{gl2:!0}),s(n,r.a.RGBA32UI,{gl2:!0}),s(n,r.a.R16F,{gl2:d}),s(n,r.a.RG16F,{gl2:d}),s(n,r.a.RGBA16F,{gl2:d}),s(n,r.a.R32F,{gl2:d}),s(n,r.a.RG32F,{gl2:d}),s(n,r.a.RGBA32F,{gl2:d}),s(n,r.a.R11F_G11F_B10F,{gl2:d}),n);var p=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,t));return n.initialize(t),Object.seal(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,i["a"]),a(r,null,[{key:"isSupported",value:function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).format;return!t||function(e,t,n){var r=n[t];if(!r)return!1;var i=u.i(c.b)(e)&&r.gl2||r.gl1;return"string"==typeof i?e.getExtension(i):i}(e,t,h)}},{key:"getSamplesForFormat",value:function(e,t){var n=t.format;return e.getInternalformatParameter(f,n,32937)}}]),a(r,[{key:"initialize",value:function(e){var t=e.format,n=e.width,r=void 0===n?1:n,i=e.height,o=void 0===i?1:i,a=e.samples,s=void 0===a?0:a;return l()(t,"Needs format"),this.gl.bindRenderbuffer(f,this.handle),0!==s&&u.i(c.b)(this.gl)?this.gl.renderbufferStorageMultisample(f,s,t,r,o):this.gl.renderbufferStorage(f,t,r,o),this.format=t,this.width=r,this.height=o,this.samples=s,this}},{key:"resize",value:function(e){var t=e.width,n=e.height;return t!==this.width||n!==this.height?this.initialize({width:t,height:n,format:this.format,samples:this.samples}):this}},{key:"_createHandle",value:function(){return this.gl.createRenderbuffer()}},{key:"_deleteHandle",value:function(){this.gl.deleteRenderbuffer(this.handle)}},{key:"_syncHandle",value:function(e){this.format=this.getParameter(36164),this.width=this.getParameter(36162),this.height=this.getParameter(36163),this.samples=this.getParameter(36011)}},{key:"_getParameter",value:function(e){return this.gl.bindRenderbuffer(f,this.handle),this.gl.getRenderbufferParameter(f,e)}}]),r}();t.a=p},function(e,t,o){"use strict";o.d(t,"a",function(){return i}),o.d(t,"b",function(){return p}),o.d(t,"c",function(){return v});var a=o(60),s=o(7),n=o(30),u=o(8),r=o(1),c=o.n(r),l=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function f(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function h(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var i=function(e){function i(e,t,n){f(this,i),o.i(s.j)(e),c()("string"==typeof t,"Shader: GLSL source code must be a JavaScript string");var r=d(this,(i.__proto__||Object.getPrototypeOf(i)).call(this,e,{id:o.i(a.i)(t)||o.i(u.d)(i.getTypeName(n))}));return r.shaderType=n,r.source=t,r.opts.source=t,r.initialize(r.opts),r}return h(i,n["a"]),l(i,null,[{key:"getTypeName",value:function(e){switch(e){case 35633:return"vertex-shader";case 35632:return"fragment-shader";default:return c()(!1),"unknown"}}}]),l(i,[{key:"initialize",value:function(e){var t=e.source,n=o.i(a.i)(t);n&&(this.id=o.i(u.d)(n)),this._compile(t),this.opts.source=t}},{key:"getParameter",value:function(e){return this.gl.getShaderParameter(this.handle,e)}},{key:"toString",value:function(){return this.getTypeName(this.shaderType)+":"+this.id}},{key:"getName",value:function(){return o.i(a.i)(this.opts.source)||"unnamed-shader"}},{key:"getSource",value:function(){return this.gl.getShaderSource(this.handle)}},{key:"getTranslatedSource",value:function(){var e=this.gl.getExtension("WEBGL_debug_shaders");return e?e.getTranslatedShaderSource(this.handle):"No translated source available. WEBGL_debug_shaders not implemented"}},{key:"_compile",value:function(){if(this.gl.shaderSource(this.handle,this.source),this.gl.compileShader(this.handle),!this.getParameter(35713)){var e=this.gl.getShaderInfoLog(this.handle),t=o.i(a.j)(e,this.source,this.shaderType),n=t.shaderName,r=t.errors,i=t.warnings;throw u.b.error("GLSL compilation errors in "+n+"\n"+r),u.b.warn("GLSL compilation warnings in "+n+"\n"+i),new Error("GLSL compilation errors in "+n)}}},{key:"_deleteHandle",value:function(){this.gl.deleteShader(this.handle)}},{key:"_getOptsFromHandle",value:function(){return{type:this.getParameter(35663),source:this.getSource()}}}]),i}(),p=function(e){function n(e,t){return f(this,n),d(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,t,35633))}return h(n,i),l(n,[{key:"_createHandle",value:function(){return this.gl.createShader(35633)}}]),n}(),v=function(e){function n(e,t){return f(this,n),d(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,t,35632))}return h(n,i),l(n,[{key:"_createHandle",value:function(){return this.gl.createShader(35632)}}]),n}()},function(e,t,r){"use strict";var i=r(31),n=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function o(t){function e(){var e=Reflect.construct(t,Array.from(arguments));return Object.setPrototypeOf(e,Object.getPrototypeOf(this)),e}return e.prototype=Object.create(t.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t,e}var a=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,o(Array)),n(t,[{key:"clone",value:function(){var e=(new this.constructor).copy(this);return e.check(),e}},{key:"copy",value:function(e){for(var t=0;t<this.ELEMENTS;++t)this[t]=e[t];return this.check()}},{key:"set",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];for(var r=0;r<this.ELEMENTS;++r)this[r]=t[r]||0;return this.check()}},{key:"fromArray",value:function(e){for(var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=0;n<this.ELEMENTS;++n)this[n]=e[n+t];return this.check()}},{key:"toString",value:function(){return this.formatString(i.a)}},{key:"formatString",value:function(e){for(var t="",n=0;n<this.ELEMENTS;++n)t+=(0<n?", ":"")+r.i(i.b)(this[n],e);return(e.printTypes?this.constructor.name:"")+"["+t+"]"}},{key:"toArray",value:function(){for(var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[],t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=0;n<this.ELEMENTS;++n)e[t+n]=this[n];return e}},{key:"toFloat32Array",value:function(){return new Float32Array(this)}},{key:"equals",value:function(e){if(!e||this.length!==e.length)return!1;for(var t=0;t<this.ELEMENTS;++t)if(!r.i(i.c)(this[t],e[t]))return!1;return!0}},{key:"exactEquals",value:function(e){if(!e||this.length!==e.length)return!1;for(var t=0;t<this.ELEMENTS;++t)if(this[t]!==e[t])return!1;return!0}},{key:"negate",value:function(){for(var e=0;e<this.ELEMENTS;++e)this[e]=-this[e];return this.check()}},{key:"inverse",value:function(){for(var e=0;e<this.ELEMENTS;++e)this[e]=1/this[e];return this.check()}},{key:"lerp",value:function(e,t){for(var n,r=0;r<this.ELEMENTS;++r)n=this[r],this[r]=n+t*(e[0]-n);return this.check()}},{key:"validate",value:function(){for(var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:this,t=e&&e.length===this.ELEMENTS,n=0;n<this.ELEMENTS;++n)t=t&&Number.isFinite(e[n]);return t}},{key:"check",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:this;if(i.a.debug&&!this.validate(e))throw new Error("Invalid "+this.constructor.name);return this}}]),t}();t.a=a},function(e,t,n){"use strict";t.b=function(e){var t=Number.isFinite;return 3===e.length&&t(e[0])&&t(e[1])&&t(e[2])};var r=n(170),o=n(31),i=n(613),a=n.n(i),s=n(604),u=n.n(s),c=n(603),l=n.n(c),f=n(614),d=n.n(f),h=n(607),p=n.n(h),v=n(605),g=n.n(v),y=n(611),_=n.n(y),m=n(612),b=n.n(m),E=n(239),w=n.n(E),P=n(608),S=n.n(P),A=n(609),T=n.n(A),x=n(610),O=n.n(x),R=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var C=[0,0,0];var k=function(e){function i(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(i.__proto__||Object.getPrototypeOf(i)).call(this));return Array.isArray(e)&&1===arguments.length?r.copy(e):r.set(e,t,n),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(i,r["a"]),R(i,[{key:"set",value:function(e,t,n){return a()(this,e,t,n),this.check()}},{key:"angle",value:function(e){return u()(this,e)}},{key:"add",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,l()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check()}},{key:"subtract",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,d()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check()}},{key:"multiply",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,p()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check()}},{key:"scale",value:function(e){return Number.isFinite(e)?_()(this,this,e):p()(this,this,e),this.check()}},{key:"cross",value:function(e){return w()(this,this,e),this.check()}},{key:"rotateX",value:function(e){var t=e.radians,n=e.origin,r=void 0===n?C:n;return S()(this,this,r,t),this.check()}},{key:"rotateY",value:function(e){var t=e.radians,n=e.origin,r=void 0===n?C:n;return T()(this,this,r,t),this.check()}},{key:"rotateZ",value:function(e){var t=e.radians,n=e.origin,r=void 0===n?C:n;return O()(this,this,r,t),this.check()}},{key:"operation",value:function(e){for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.apply(void 0,[this,this].concat(n)),this.check()}},{key:"divide",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,g()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check()}},{key:"scaleAndAdd",value:function(e,t){return b()(this,this,e,t),this.check()}},{key:"ELEMENTS",get:function(){return 3}},{key:"x",get:function(){return this[0]},set:function(e){return this[0]=n.i(o.g)(e)}},{key:"y",get:function(){return this[1]},set:function(e){return this[1]=n.i(o.g)(e)}},{key:"z",get:function(){return this[2]},set:function(e){return this[2]=n.i(o.g)(e)}}]),i}();t.a=k},function(e,t,n){"use strict";n.d(t,"a",function(){return i}),n.d(t,"b",function(){return o}),n.d(t,"c",function(){return a}),n.d(t,"f",function(){return s}),n.d(t,"g",function(){return u}),n.d(t,"e",function(){return c}),n.d(t,"d",function(){return l});var r=n(283),i=r.b?[[r.b.Rotate,{enable:!1}],[r.b.Pinch,{enable:!1}],[r.b.Swipe,{enable:!1}],[r.b.Pan,{threshold:0,enable:!1}],[r.b.Press,{enable:!1}],[r.b.Tap,{event:"doubletap",taps:2,enable:!1}],[r.b.Tap,{enable:!1}]]:null,o={rotate:["pinch"]},a={doubletap:["tap"]},s={pointerdown:"pointerdown",pointermove:"pointermove",pointerup:"pointerup",touchstart:"pointerdown",touchmove:"pointermove",touchend:"pointerup",mousedown:"pointerdown",mousemove:"pointermove",mouseup:"pointerup"},u={KEY_EVENTS:["keydown","keyup"],MOUSE_EVENTS:["mousedown","mousemove","mouseup","mouseleave"],WHEEL_EVENTS:["wheel","mousewheel","DOMMouseScroll"]},c={tap:"tap",doubletap:"doubletap",press:"press",pinch:"pinch",pinchin:"pinch",pinchout:"pinch",pinchstart:"pinch",pinchmove:"pinch",pinchend:"pinch",pinchcancel:"pinch",rotate:"rotate",rotatestart:"rotate",rotatemove:"rotate",rotateend:"rotate",rotatecancel:"rotate",pan:"pan",panstart:"pan",panmove:"pan",panup:"pan",pandown:"pan",panleft:"pan",panright:"pan",panend:"pan",pancancel:"pan",swipe:"swipe",swipeleft:"swipe",swiperight:"swipe",swipeup:"swipe",swipedown:"swipe"},l={click:"tap",dblclick:"doubletap",mousedown:"pointerdown",mousemove:"pointermove",mouseup:"pointerup",mouseleave:"pointerleave"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(672);n.d(t,"EventManager",function(){return r.a})},function(n,e,r){(function(e){if("production"!==e.env.NODE_ENV){var t="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103;n.exports=r(679)(function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},!0)}else n.exports=r(678)()}).call(e,r(26))},function(t,e,n){"use strict";(function(e){"production"===e.env.NODE_ENV?t.exports=n(681):t.exports=n(680)}).call(e,n(26))},function(e,t,n){"use strict";t.a=function(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]},t.b=function(e,t){var n=a()([],t,e);return i()(n,n,1/n[3]),n},t.d=function(e,t){var n=e%t;return n<0?t+n:n},t.c=function(e,t,n){return n*t+(1-n)*e};var r=n(161),i=n.n(r),o=n(103),a=n.n(o)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),o=n(12),a=c(n(316)),s=c(n(315)),u=c(n(314));function c(e){return e&&e.__esModule?e:{default:e}}var l=i.experimental.fp64LowPart,f=i.experimental.enable64bitSupport,d=[0,0,0,255],h={widthScale:1,widthMinPixels:0,widthMaxPixels:Number.MAX_SAFE_INTEGER,rounded:!1,miterLimit:4,fp64:!1,dashJustified:!1,getPath:function(e){return e.path},getColor:function(e){return e.color||d},getWidth:function(e){return e.width||1},getDashArray:null},p=function(e){var t=e[0],n=e[e.length-1];return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]},v=function(e){function c(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(c.__proto__||Object.getPrototypeOf(c)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(c,i.Layer),r(c,[{key:"getShaders",value:function(){return f(this.props)?{vs:s.default,fs:u.default,modules:["project64","picking"]}:{vs:a.default,fs:u.default,modules:["picking"]}}},{key:"initializeState",value:function(){this.getAttributeManager().addInstanced({instanceStartPositions:{size:3,update:this.calculateStartPositions},instanceEndPositions:{size:3,update:this.calculateEndPositions},instanceLeftDeltas:{size:3,update:this.calculateLeftDeltas},instanceRightDeltas:{size:3,update:this.calculateRightDeltas},instanceStrokeWidths:{size:1,accessor:"getWidth",update:this.calculateStrokeWidths},instanceDashArrays:{size:2,accessor:"getDashArray",update:this.calculateDashArrays},instanceColors:{size:4,type:o.GL.UNSIGNED_BYTE,accessor:"getColor",update:this.calculateColors},instancePickingColors:{size:3,type:o.GL.UNSIGNED_BYTE,update:this.calculatePickingColors}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.addInstanced({instanceStartEndPositions64xyLow:{size:4,update:this.calculateInstanceStartEndPositions64xyLow}}):r.remove(["instanceStartEndPositions64xyLow"])}}},{key:"updateState",value:function(e){var t=e.oldProps,n=e.props,r=e.changeFlags;(function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0})(c.prototype.__proto__||Object.getPrototypeOf(c.prototype),"updateState",this).call(this,{props:n,oldProps:t,changeFlags:r});var i=this.props.getPath,o=this.getAttributeManager();if(n.fp64!==t.fp64){var a=this.context.gl;this.setState({model:this._getModel(a)})}if(this.updateAttribute({props:n,oldProps:t,changeFlags:r}),r.dataChanged||r.updateTriggersChanged&&(r.updateTriggersChanged.all||r.updateTriggersChanged.getPath)){var s=n.data.map(i),u=s.reduce(function(e,t){return e+t.length-1},0);this.setState({paths:s,numInstances:u}),o.invalidateAll()}}},{key:"draw",value:function(e){var t=e.uniforms,n=this.props,r=n.rounded,i=n.miterLimit,o=n.widthScale,a=n.widthMinPixels,s=n.widthMaxPixels,u=n.dashJustified;this.state.model.render(Object.assign({},t,{jointType:Number(r),alignMode:Number(u),widthScale:o,miterLimit:i,widthMinPixels:a,widthMaxPixels:s}))}},{key:"_getModel",value:function(e){return new o.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:new o.Geometry({drawMode:o.GL.TRIANGLES,attributes:{indices:new Uint16Array([0,2,1,1,2,4,1,4,3,3,4,5]),positions:new Float32Array([0,0,1,0,-1,0,0,1,0,1,-1,0,1,1,0,1,0,1])}}),isInstanced:!0,shaderCache:this.context.shaderCache}))}},{key:"calculateStartPositions",value:function(e){var t=this.state.paths,i=e.value,o=0;t.forEach(function(e){for(var t=e.length-1,n=0;n<t;n++){var r=e[n];i[o++]=r[0],i[o++]=r[1],i[o++]=r[2]||0}})}},{key:"calculateEndPositions",value:function(e){var t=this.state.paths,r=e.value,i=0;t.forEach(function(e){for(var t=1;t<e.length;t++){var n=e[t];r[i++]=n[0],r[i++]=n[1],r[i++]=n[2]||0}})}},{key:"calculateInstanceStartEndPositions64xyLow",value:function(e){var t=this.state.paths,o=e.value,a=0;t.forEach(function(e){for(var t=e.length-1,n=0;n<t;n++){var r=e[n],i=e[n+1];o[a++]=l(r[0]),o[a++]=l(r[1]),o[a++]=l(i[0]),o[a++]=l(i[1])}})}},{key:"calculateLeftDeltas",value:function(e){var t=this.state.paths,o=e.value,a=0;t.forEach(function(e){for(var t=e.length-1,n=p(e)?e[e.length-2]:e[0],r=0;r<t;r++){var i=e[r];o[a++]=i[0]-n[0],o[a++]=i[1]-n[1],o[a++]=i[2]-n[2]||0,n=i}})}},{key:"calculateRightDeltas",value:function(e){var t=this.state.paths,i=e.value,o=0;t.forEach(function(e){for(var t=1;t<e.length;t++){var n=e[t],r=e[t+1];r||(r=p(e)?e[1]:n),i[o++]=r[0]-n[0],i[o++]=r[1]-n[1],i[o++]=r[2]-n[2]||0}})}},{key:"calculateStrokeWidths",value:function(e){var t=this.props,i=t.data,o=t.getWidth,n=this.state.paths,a=e.value,s=0;n.forEach(function(e,t){for(var n=o(i[t],t),r=1;r<e.length;r++)a[s++]=n})}},{key:"calculateDashArrays",value:function(e){var t=this.props,i=t.data,o=t.getDashArray;if(o){var n=this.state.paths,a=e.value,s=0;n.forEach(function(e,t){for(var n=o(i[t],t),r=1;r<e.length;r++)a[s++]=n[0],a[s++]=n[1]})}}},{key:"calculateColors",value:function(e){var t=this.props,i=t.data,o=t.getColor,n=this.state.paths,a=e.value,s=0;n.forEach(function(e,t){var n=o(i[t],t);isNaN(n[3])&&(n[3]=255);for(var r=1;r<e.length;r++)a[s++]=n[0],a[s++]=n[1],a[s++]=n[2],a[s++]=n[3]})}},{key:"calculatePickingColors",value:function(e){var i=this,t=this.state.paths,o=e.value,a=0;t.forEach(function(e,t){for(var n=i.encodePickingColor(t),r=1;r<e.length;r++)o[a++]=n[0],o[a++]=n[1],o[a++]=n[2]})}}]),c}();(t.default=v).layerName="PathLayer",v.defaultProps=h},function(e,t,n){"use strict";function a(e){return 1<=e.length&&2<=e[0].length&&Number.isFinite(e[0][0])}function l(e){(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).dimensions;return a(e)?[e]:e}Object.defineProperty(t,"__esModule",{value:!0}),t.isSimple=a,t.normalize=l,t.getVertexCount=function(e){return a(e)?e.length:e.reduce(function(e,t){return e+t.length},0)},t.getTriangleCount=function(e){var t=0,n=!0,r=!0,i=!1,o=void 0;try{for(var a,s=l(e)[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){var u=a.value,c=u.length;t+=n?3<=c?c-2:0:c+1,n=!1}}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return t},t.forEachVertex=function(r,i){if(a(r))return void r.forEach(i);var o=0;r.forEach(function(e){e.forEach(function(e,t,n){return i(e,o,r)}),o++})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var d=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=u(n(82)),o=u(n(125)),a=n(186),s=u(n(1));function u(e){return e&&e.__esModule?e:{default:e}}var h={transitionDuration:0},c={transitionDuration:300,transitionEasing:function(e){return e},transitionInterpolator:new o.default,transitionInterruption:a.TRANSITION_EVENTS.BREAK},E=["wheel"],w=["panstart","panmove","panend"],P=["pinchstart","pinchmove","pinchend"],S=["doubletap"],A=["keydown"],l=function(){function n(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),(0,s.default)(e),this.ViewportState=e,this.viewportState=null,this.viewportStateProps=null,this.eventManager=null,this._events=null,this._state={isDragging:!1},this.events=[],this.handleEvent=this.handleEvent.bind(this),this.setOptions(t),this.constructor===n&&Object.seal(this)}return r(n,[{key:"handleEvent",value:function(e){var t=this.ViewportState;switch(this.viewportState=new t(Object.assign({},this.viewportStateProps,this._state)),e.type){case"panstart":return this._onPanStart(e);case"panmove":return this._onPan(e);case"panend":return this._onPanEnd(e);case"pinchstart":return this._onPinchStart(e);case"pinchmove":return this._onPinch(e);case"pinchend":return this._onPinchEnd(e);case"doubletap":return this._onDoubleTap(e);case"wheel":return this._onWheel(e);case"keydown":return this._onKeyDown(e);default:return!1}}},{key:"getCenter",value:function(e){var t=e.offsetCenter;return[t.x,t.y]}},{key:"isFunctionKeyPressed",value:function(e){var t=e.srcEvent;return Boolean(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}},{key:"isDragging",value:function(){return this._state.isDragging}},{key:"setOptions",value:function(e){var t=e.onViewportChange,n=e.onStateChange,r=void 0===n?this.onStateChange:n,i=e.eventManager,o=void 0===i?this.eventManager:i,a=e.scrollZoom,s=void 0===a||a,u=e.dragPan,c=void 0===u||u,l=e.dragRotate,f=void 0===l||l,d=e.doubleClickZoom,h=void 0===d||d,p=e.touchZoom,v=void 0===p||p,g=e.touchRotate,y=void 0!==g&&g,_=e.keyboard,m=void 0===_||_;this.onViewportChange=t,this.onStateChange=r,this.viewportStateProps=e,this.eventManager!==o&&(this.eventManager=o,this._events={},this.toggleEvents(this.events,!0));var b=Boolean(this.onViewportChange);this.toggleEvents(E,b&&s),this.toggleEvents(w,b&&(c||f)),this.toggleEvents(P,b&&(v||y)),this.toggleEvents(S,b&&h),this.toggleEvents(A,b&&m),this.scrollZoom=s,this.dragPan=c,this.dragRotate=f,this.doubleClickZoom=h,this.touchZoom=v,this.touchRotate=y,this.keyboard=m}},{key:"toggleEvents",value:function(e,t){var n=this;this.eventManager&&e.forEach(function(e){n._events[e]!==t&&((n._events[e]=t)?n.eventManager.on(e,n.handleEvent):n.eventManager.off(e,n.handleEvent))})}},{key:"setState",value:function(e){Object.assign(this._state,e),this.onStateChange&&this.onStateChange(this._state)}},{key:"updateViewport",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},r=this.viewportState.getViewportProps(),i=Object.assign({},e.getViewportProps(),t);if(this.onViewportChange&&Object.keys(i).some(function(e){return r[e]!==i[e]})){var o=this.viewportState.getViewport?this.viewportState.getViewport():null;this.onViewportChange(i,o)}this.setState(Object.assign({},e.getInteractiveState(),n))}},{key:"_onPanStart",value:function(e){var t=this.getCenter(e),n=this.viewportState.panStart({pos:t}).rotateStart({pos:t});return this.updateViewport(n,h,{isDragging:!0})}},{key:"_onPan",value:function(e){return this.isFunctionKeyPressed(e)||e.rightButton?this._onPanRotate(e):this._onPanMove(e)}},{key:"_onPanEnd",value:function(e){var t=this.viewportState.panEnd().rotateEnd();return this.updateViewport(t,null,{isDragging:!1})}},{key:"_onPanMove",value:function(e){if(!this.dragPan)return!1;var t=this.getCenter(e),n=this.viewportState.pan({pos:t});return this.updateViewport(n,h,{isDragging:!0})}},{key:"_onPanRotate",value:function(e){return!!this.dragRotate&&(this.viewportState instanceof i.default?this._onPanRotateMap(e):this._onPanRotateStandard(e))}},{key:"_onPanRotateStandard",value:function(e){var t=e.deltaX,n=e.deltaY,r=this.viewportState.getViewportProps(),i=t/r.width,o=n/r.height,a=this.viewportState.rotate({deltaScaleX:i,deltaScaleY:o});return this.updateViewport(a,h,{isDragging:!0})}},{key:"_onPanRotateMap",value:function(e){var t=e.deltaX,n=e.deltaY,r=this.getCenter(e),i=d(r,2)[1],o=i-n,a=this.viewportState.getViewportProps(),s=a.width,u=a.height,c=t/s,l=0;0<n?5<Math.abs(u-o)&&(l=n/(o-u)*1.2):n<0&&5<o&&(l=1-i/o),l=Math.min(1,Math.max(-1,l));var f=this.viewportState.rotate({deltaScaleX:c,deltaScaleY:l});return this.updateViewport(f,h,{isDragging:!0})}},{key:"_onWheel",value:function(e){if(!this.scrollZoom)return!1;var t=this.getCenter(e),n=e.delta,r=2/(1+Math.exp(-Math.abs(.01*n)));n<0&&0!==r&&(r=1/r);var i=this.viewportState.zoom({pos:t,scale:r});return this.updateViewport(i,h)}},{key:"_onPinchStart",value:function(e){var t=this.getCenter(e),n=this.viewportState.zoomStart({pos:t}).rotateStart({pos:t});return this._state.startPinchRotation=e.rotation,this.updateViewport(n,h,{isDragging:!0})}},{key:"_onPinch",value:function(e){if(!this.touchZoom&&!this.touchRotate)return!1;var t=this.viewportState;if(this.touchZoom){var n=e.scale,r=this.getCenter(e);t=t.zoom({pos:r,scale:n})}if(this.touchRotate){var i=e.rotation,o=this._state.startPinchRotation;t=t.rotate({deltaScaleX:-(i-o)/180})}return this.updateViewport(t,h,{isDragging:!0})}},{key:"_onPinchEnd",value:function(e){var t=this.viewportState.zoomEnd().rotateEnd();return this._state.startPinchRotation=0,this.updateViewport(t,null,{isDragging:!1})}},{key:"_onDoubleTap",value:function(e){if(!this.doubleClickZoom)return!1;var t=this.getCenter(e),n=this.isFunctionKeyPressed(e),r=this.viewportState.zoom({pos:t,scale:n?.5:2});return this.updateViewport(r,c)}},{key:"_onKeyDown",value:function(e){if(!this.keyboard)return!1;var t=this.isFunctionKeyPressed(e),n=this.viewportState,r=void 0;switch(e.srcEvent.keyCode){case 189:r=t?n.zoomOut().zoomOut():n.zoomOut();break;case 187:r=t?n.zoomIn().zoomIn():n.zoomIn();break;case 37:r=t?n.rotateLeft():n.moveLeft();break;case 39:r=t?n.rotateRight():n.moveRight();break;case 38:r=t?n.rotateUp():n.moveUp();break;case 40:r=t?n.rotateDown():n.moveDown();break;default:return!1}return this.updateViewport(r,c)}}]),n}();t.default=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var i=0,o=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.id="effect",this.count=i++,this.visible=!0,this.priority=0,this.needsRedraw=!1}return r(e,[{key:"initialize",value:function(e){e.gl,e.layerManager}},{key:"finalize",value:function(e){e.gl,e.layerManager}},{key:"preDraw",value:function(e){e.gl,e.layerManager}},{key:"draw",value:function(e){e.gl,e.layerManager}},{key:"setNeedsRedraw",value:function(){var e=!(0<arguments.length&&void 0!==arguments[0])||arguments[0];this.needsRedraw=e}}]),e}();t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),o=n(70),a=p(n(182)),s=p(n(185)),u=n(194),c=p(n(17)),l=n(340),f=n(187),d=n(124),v=n(12),h=p(n(1));function p(e){return e&&e.__esModule?e:{default:e}}var g=Object.freeze({}),y=function(){},_={dataComparator:null,updateTriggers:{},numInstances:void 0,visible:!0,pickable:!1,opacity:.8,onHover:y,onClick:y,coordinateSystem:o.COORDINATE_SYSTEM.LNGLAT,coordinateOrigin:[0,0,0],parameters:{},uniforms:{},framebuffer:null,animation:null,getPolygonOffset:function(e){return[0,100*-e.layerIndex]},highlightedObjectIndex:null,autoHighlight:!1,highlightColor:[0,0,128,128]},m=0,b=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.props=l.createProps.apply(this,arguments),this.id=this.props.id,this.oldProps=g,this.count=m++,this.lifecycle=o.LIFECYCLE.NO_STATE,this.state=null,this.context=null,this.parentLayer=null,this.internalState=null,Object.seal(this)}return i(e,[{key:"clone",value:function(e){return new this.constructor(Object.assign({},this.props,e))}},{key:"toString",value:function(){return(this.constructor.layerName||this.constructor.name)+"({id: '"+this.props.id+"'})"}},{key:"setState",value:function(e){Object.assign(this.state,e),this.state.needsRedraw=!0}},{key:"setNeedsRedraw",value:function(){var e=!(0<arguments.length&&void 0!==arguments[0])||arguments[0];this.state&&(this.state.needsRedraw=e)}},{key:"getNeedsRedraw",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).clearRedrawFlags,t=void 0!==e&&e;return this._getNeedsRedraw(t)}},{key:"getModels",value:function(){return this.state.models||(this.state.model?[this.state.model]:[])}},{key:"needsUpdate",value:function(){return this.shouldUpdateState(this._getUpdateParams())}},{key:"isPickable",value:function(){return this.props.pickable&&this.props.visible}},{key:"getAttributeManager",value:function(){return this.state&&this.state.attributeManager}},{key:"getFirstObject",value:function(){var e=this.props.data,t=!0,n=!1,r=void 0;try{for(var i,o=e[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){return i.value}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}return null}},{key:"project",value:function(e){var t=this.context.viewport;return(0,h.default)(Array.isArray(e),"Layer.project needs [lng,lat]"),t.project(e)}},{key:"unproject",value:function(e){var t=this.context.viewport;return(0,h.default)(Array.isArray(e),"Layer.unproject needs [x,y]"),t.unproject(e)}},{key:"projectFlat",value:function(e){var t=this.context.viewport;return(0,h.default)(Array.isArray(e),"Layer.project needs [lng,lat]"),t.projectFlat(e)}},{key:"unprojectFlat",value:function(e){var t=this.context.viewport;return(0,h.default)(Array.isArray(e),"Layer.unproject needs [x,y]"),t.unprojectFlat(e)}},{key:"screenToDevicePixels",value:function(e){return c.default.deprecated("screenToDevicePixels","DeckGL prop useDevicePixels for conversion"),e*("undefined"!=typeof window?window.devicePixelRatio:1)}},{key:"nullPickingColor",value:function(){return[0,0,0]}},{key:"encodePickingColor",value:function(e){return(0,h.default)(0==(e+1>>24&255),"index out of picking color range"),[e+1&255,e+1>>8&255,e+1>>8>>8&255]}},{key:"decodePickingColor",value:function(e){(0,h.default)(e instanceof Uint8Array);var t=r(e,3);return t[0]+256*t[1]+65536*t[2]-1}},{key:"initializeState",value:function(){throw new Error("Layer "+this+" has not defined initializeState")}},{key:"shouldUpdateState",value:function(e){e.oldProps,e.props,e.oldContext,e.context;return e.changeFlags.propsOrDataChanged}},{key:"updateState",value:function(e){e.oldProps,e.props,e.oldContext,e.context;var t=e.changeFlags,n=this.getAttributeManager();t.dataChanged&&n&&n.invalidateAll()}},{key:"finalizeState",value:function(){}},{key:"updateTransition",value:function(){var e=this.state,t=e.model,n=e.attributeManager,r=n&&n.updateTransition();t&&r&&t.setAttributes(n.getChangedAttributes({transition:!0}))}},{key:"draw",value:function(e){var t=!0,n=!1,r=void 0;try{for(var i,o=this.getModels()[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){i.value.draw(e)}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}}},{key:"getPickingInfo",value:function(e){var t=e.info,n=(e.mode,t.index);return 0<=n&&Array.isArray(this.props.data)&&(t.object=this.props.data[n]),t}},{key:"invalidateAttribute",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"all",t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"",n=this.getAttributeManager();n&&("all"===e?(c.default.log(1,"updateTriggers invalidating all attributes: "+t),n.invalidateAll()):(c.default.log(1,"updateTriggers invalidating attribute "+e+": "+t),n.invalidate(e)))}},{key:"updateAttributes",value:function(e){var t=this.getAttributeManager();if(t){var n=this.getNumInstances(e);t.update({data:e.data,numInstances:n,props:e,transitions:e.transitions,buffers:e,context:this,ignoreUnknownAttributes:!0});var r=this.state.model;if(r){var i=t.getChangedAttributes({clearChangedFlags:!0});r.setAttributes(i)}}}},{key:"calculateInstancePickingColors",value:function(e,t){for(var n=t.numInstances,r=e.value,i=e.size,o=0;o<n;o++){var a=this.encodePickingColor(o);r[o*i+0]=a[0],r[o*i+1]=a[1],r[o*i+2]=a[2]}}},{key:"getNumInstances",value:function(e){if(e=e||this.props,this.state&&void 0!==this.state.numInstances)return this.state.numInstances;if(void 0!==e.numInstances)return e.numInstances;var t=e.data;return(0,u.count)(t)}},{key:"_initialize",value:function(){(0,h.default)(0===arguments.length),(0,h.default)(this.context.gl),(0,h.default)(!this.state);var e=new a.default(this.context.gl,{id:this.props.id});e.addInstanced({instancePickingColors:{type:v.GL.UNSIGNED_BYTE,size:3,update:this.calculateInstancePickingColors}}),this.internalState={subLayers:null,stats:new s.default({id:"draw"})},this.state={attributeManager:e,model:null,needsRedraw:!0},this.initializeState(this.context),this.setChangeFlags({dataChanged:!0,propsChanged:!0,viewportChanged:!0}),this._updateState(this._getUpdateParams()),this.isComposite&&this._renderLayers(!0);var t=this.state.model;t&&(t.id=this.props.id,t.program.id=this.props.id+"-program",t.geometry.id=this.props.id+"-geometry",t.setAttributes(e.getAttributes())),this.isComposite&&this._renderLayers(),this.clearChangeFlags()}},{key:"_update",value:function(){(0,h.default)(0===arguments.length);var e=this.needsUpdate(),t=this._getUpdateParams();e&&this._updateState(t),this.isComposite&&this._renderLayers(e),this.clearChangeFlags(),this.oldProps=g}},{key:"_updateState",value:function(e){this.updateState(e),this.updateAttributes(this.props),this._updateBaseUniforms(),this._updateModuleSettings(),this.state.model&&this.state.model.setInstanceCount(this.getNumInstances())}},{key:"_finalize",value:function(){(0,h.default)(0===arguments.length),this.finalizeState(this.context),(0,d.removeLayerInSeer)(this.id)}},{key:"drawLayer",value:function(e){var t=this,n=e.moduleParameters,r=void 0===n?null:n,i=e.uniforms,o=void 0===i?{}:i,a=e.parameters,s=void 0===a?{}:a;if(o.picking_uActive||this.updateTransition(),r){var u=!0,c=!1,l=void 0;try{for(var f,d=this.getModels()[Symbol.iterator]();!(u=(f=d.next()).done);u=!0){f.value.updateModuleSettings(r)}}catch(e){c=!0,l=e}finally{try{!u&&d.return&&d.return()}finally{if(c)throw l}}}var h=this.props.getPolygonOffset,p=h&&h(o)||[0,0];s.polygonOffset=p,(0,v.withParameters)(this.context.gl,s,function(){t.draw({moduleParameters:r,uniforms:o,parameters:s,context:t.context})})}},{key:"pickLayer",value:function(e){return this.getPickingInfo(e)}},{key:"getChangeFlags",value:function(){return this.internalState.changeFlags}},{key:"setChangeFlags",value:function(e){var t=this;this.internalState.changeFlags=this.internalState.changeFlags||{};var n=this.internalState.changeFlags;e.dataChanged&&!n.dataChanged&&(n.dataChanged=e.dataChanged,c.default.log(2,function(){return"dataChanged: "+e.dataChanged+" in "+t.id})),e.updateTriggersChanged&&!n.updateTriggersChanged&&(n.updateTriggersChanged=n.updateTriggersChanged&&e.updateTriggersChanged?Object.assign({},e.updateTriggersChanged,n.updateTriggersChanged):e.updateTriggersChanged||n.updateTriggersChanged,c.default.log(2,function(){return"updateTriggersChanged: "+Object.keys(e.updateTriggersChanged).join(", ")+" in "+t.id})),e.propsChanged&&!n.propsChanged&&(n.propsChanged=e.propsChanged,c.default.log(2,function(){return"propsChanged: "+e.propsChanged+" in "+t.id})),e.viewportChanged&&!n.viewportChanged&&(n.viewportChanged=e.viewportChanged,c.default.log(3,function(){return"viewportChanged: "+e.viewportChanged+" in "+t.id}));var r=e.dataChanged||e.updateTriggersChanged||e.propsChanged;n.propsOrDataChanged=n.propsOrDataChanged||r,n.somethingChanged=n.somethingChanged||r||e.viewportChanged}},{key:"clearChangeFlags",value:function(){this.internalState.changeFlags={dataChanged:!1,propsChanged:!1,updateTriggersChanged:!1,viewportChanged:!1,propsOrDataChanged:!1,somethingChanged:!1}}},{key:"printChangeFlags",value:function(){var e=this.internalState.changeFlags;return(e.dataChanged?"data ":"")+(e.propsChanged?"props ":"")+(e.updateTriggersChanged?"triggers ":"")+(e.viewportChanged?"viewport":"")}},{key:"diffProps",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:this.props,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.oldProps,n=(0,f.diffProps)(e,t);if(n.updateTriggersChanged)for(var r in n.updateTriggersChanged)n.updateTriggersChanged[r]&&this._activeUpdateTrigger(r);return this.setChangeFlags(n)}},{key:"_getUpdateParams",value:function(){return{props:this.props,oldProps:this.oldProps,context:this.context,oldContext:this.oldContext||{},changeFlags:this.internalState.changeFlags}}},{key:"_getNeedsRedraw",value:function(e){if(!this.state)return!1;var t=!1;t=t||this.state.needsRedraw&&this.id,this.state.needsRedraw=this.state.needsRedraw&&!e;var n=this.getAttributeManager(),r=n&&n.getNeedsRedraw({clearRedrawFlags:e});t=t||r;var i=!0,o=!1,a=void 0;try{for(var s,u=this.getModels()[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value,l=c.getNeedsRedraw({clearRedrawFlags:e});l&&"string"!=typeof l&&(l="model "+c.id),t=t||l}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}return t}},{key:"_transferState",value:function(e){var t=e.state,n=e.internalState,r=e.props;(0,h.default)(t&&n),(t.layer=this).state=t,this.internalState=n,this.oldProps=r;var i=!0,o=!1,a=void 0;try{for(var s,u=this.getModels()[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){s.value.userData.layer=this}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}this.diffProps()}},{key:"_activeUpdateTrigger",value:function(e){this.invalidateAttribute(e)}},{key:"_checkRequiredProp",value:function(e,t){var n=this.props[e];if(void 0===n)throw new Error("Property "+e+" undefined in layer "+this);if(t&&!t(n))throw new Error("Bad property "+e+" in layer "+this)}},{key:"_updateBaseUniforms",value:function(){var e={opacity:Math.pow(this.props.opacity,1/2.2),ONE:1},t=!0,n=!1,r=void 0;try{for(var i,o=this.getModels()[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){i.value.setUniforms(e)}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}this.state.needsRedraw=!0}},{key:"_updateModuleSettings",value:function(){var e={pickingHighlightColor:this.props.highlightColor},t=!0,n=!1,r=void 0;try{for(var i,o=this.getModels()[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){i.value.updateModuleSettings(e)}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}}},{key:"setUniforms",value:function(e){var t=!0,n=!1,r=void 0;try{for(var i,o=this.getModels()[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){i.value.setUniforms(e)}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}this.state.needsRedraw=!0,c.default.deprecated("layer.setUniforms","model.setUniforms")}},{key:"stats",get:function(){return this.internalState.stats}}]),e}();(t.default=b).layerName="Layer",b.defaultProps=_},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.removeLayerInSeer=t.updateLayerInSeer=t.initLayerInSeer=t.seerInitListener=t.layerEditListener=t.applyPropOverrides=t.setPropOverrides=void 0;var r,i=n(173),o=(r=i)&&r.__esModule?r:{default:r};var a=new Map;t.setPropOverrides=function(e,t,n){o.default.isReady()&&(a.has(e)||a.set(e,new Map),a.get(e).set(t,n))},t.applyPropOverrides=function(n){if(o.default.isReady()&&n.id){var e=a.get(n.id);e&&e.forEach(function(e,t){!function e(t,n,r){t&&(1<n.length?e(t[n[0]],n.slice(1),r):t[n[0]]=r)}(n,t,e),"data"===t[0]&&(n.data=[].concat(function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(n.data)))})}},t.layerEditListener=function(e){o.default.isReady()&&o.default.listenFor("deck.gl",e)},t.seerInitListener=function(e){o.default.isReady()&&o.default.listenFor("init",e)},t.initLayerInSeer=function(e){if(o.default.isReady()&&e){var t=[e.constructor.layerName];o.default.listItem("deck.gl",e.id,{badges:t,links:e.state&&e.state.model?["luma.gl:"+e.state.model.id]:void 0,parent:e.parentLayer?e.parentLayer.id:void 0})}},t.updateLayerInSeer=function(e){if(o.default.isReady()&&!o.default.throttle("deck.gl:"+e.id,1e3)){var t=function(e){var t=[{path:"objects.props",data:e.props}],n=[e.constructor.layerName];if(e.state){if(e.state.attributeManager){var r=e.state.attributeManager.getAttributes();t.push({path:"objects.attributes",data:r}),n.push(e.state.attributeManager.stats.getTimeString())}if(e.state.model){e.state.model.timerQueryEnabled=!0;var i=e.state.model.stats.lastFrameTime;i&&n.push((1e3*i).toFixed(0)+"μs")}}return t.push({path:"badges",data:n}),t}(e);o.default.multiUpdate("deck.gl",e.id,t)}},t.removeLayerInSeer=function(e){o.default.isReady()&&e&&o.default.deleteItem("deck.gl",e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=o(n(193)),d=n(84),h=o(n(1));function o(e){return e&&e.__esModule?e:{default:e}}var a=["longitude","latitude","zoom","bearing","pitch"],s=function(e){function n(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:a;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this));return t.propNames=e,t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,i.default),r(n,[{key:"initializeProps",value:function(e,t){var n={},r={},i=!0,o=!1,a=void 0;try{for(var s,u=this.propNames[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value,l=e[c],f=t[c];(0,h.default)((0,d.isValid)(l)&&(0,d.isValid)(f),c+" must be supplied for transition"),n[c]=l,r[c]=(0,d.getEndValueByShortestPath)(c,l,f)}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}return{start:n,end:r}}},{key:"interpolateProps",value:function(e,t,n){var r={},i=!0,o=!1,a=void 0;try{for(var s,u=this.propNames[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value;r[c]=(0,d.lerp)(e[c],t[c],n)}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}return r}}]),n}();t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.flatten=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.filter,r=void 0===n?function(){return!0}:n,i=t.map,o=void 0===i?function(e){return e}:i,a=t.result,s=void 0===a?[]:a;return Array.isArray(e)?function e(t,n,r,i){for(var o=-1;++o<t.length;){var a=t[o];Array.isArray(a)?e(a,n,r,i):n(a)&&i.push(r(a))}return i}(e,r,o,s):r(e)?[o(e)]:[]},t.countVertices=function e(t){var n=0;var r=-1;for(;++r<t.length;){var i=t[r];Array.isArray(i)||ArrayBuffer.isView(i)?n+=e(i):n++}return n},t.flattenVertices=function e(t){var n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},r=n.result,i=void 0===r?[]:r,o=n.dimensions,a=void 0===o?3:o;var s=-1;var u=0;for(;++s<t.length;){var c=t[s];Array.isArray(c)||ArrayBuffer.isView(c)?e(c,{result:i,dimensions:a}):u<a&&(i.push(c),u++)}0<u&&u<a&&i.push(0);return i},t.fillArray=function(e){for(var t=e.target,n=e.source,r=e.start,i=void 0===r?0:r,o=e.count,a=void 0===o?1:o,s=n.length,u=a*s,c=0,l=i;c<s;c++)t[l++]=n[c];for(;c<u;)c<u-c?(t.copyWithin(i+c,i,i+c),c*=2):(t.copyWithin(i+c,i,i+u-c),c=u);return t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.transformVector=function(e,t){if(!e)return null;var n=(0,o.default)([0,0,0,0],t,e),r=1/n[3];return(0,i.default)(n,n,[r,r,r,r]),n},t.createMat4=function(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]},t.extractCameraVectors=function(e){var t=e.viewMatrix,n=e.viewMatrixInverse;return{eye:[n[12],n[13],n[14]],direction:[t[2],t[6],t[10]],up:[t[1],t[5],t[9]]}},t.mod=function(e,t){(0,r.default)(Number.isFinite(e)&&Number.isFinite(t));var n=e%t;return n<0?t+n:n};var i=a(n(246)),o=a(n(103)),r=a(n(1));function a(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";var s=n(14),u=n(57),c=n(11);e.exports=function(e){for(var t=s(this),n=c(t.length),r=arguments.length,i=u(1<r?arguments[1]:void 0,n),o=2<r?arguments[2]:void 0,a=void 0===o?n:u(o,n);i<a;)t[i++]=e;return t}},function(e,t,n){var r=n(368);e.exports=function(e,t){return new(r(e))(t)}},function(e,t,n){"use strict";var r=n(10),i=n(54);e.exports=function(e,t,n){t in e?r.f(e,t,i(0,n)):e[t]=n}},function(e,t,n){var r=n(5),i=n(3).document,o=r(i)&&r(i.createElement);e.exports=function(e){return o?i.createElement(e):{}}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t,n){var r=n(6)("match");e.exports=function(t){var n=/./;try{"/./"[t](n)}catch(e){try{return n[r]=!1,!"/./"[t](n)}catch(e){}}return!0}},function(e,t,n){var r=n(3).document;e.exports=r&&r.documentElement},function(e,t,n){var o=n(5),a=n(143).set;e.exports=function(e,t,n){var r,i=t.constructor;return i!==n&&"function"==typeof i&&(r=i.prototype)!==n.prototype&&o(r)&&a&&a(e,r),e}},function(e,t,n){var r=n(63),i=n(6)("iterator"),o=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||o[i]===e)}},function(e,t,n){"use strict";var r=n(51),i=n(54),o=n(64),a={};n(19)(a,n(6)("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=r(a,{next:i(1,n)}),o(e,t+" Iterator")}},function(e,t,n){"use strict";var m=n(50),b=n(0),E=n(20),w=n(19),P=n(18),S=n(63),A=n(137),T=n(64),x=n(23),O=n(6)("iterator"),R=!([].keys&&"next"in[].keys()),C="values",k=function(){return this};e.exports=function(e,t,n,r,i,o,a){A(n,t,r);var s,u,c,l=function(e){if(!R&&e in p)return p[e];switch(e){case"keys":case C:return function(){return new n(this,e)}}return function(){return new n(this,e)}},f=t+" Iterator",d=i==C,h=!1,p=e.prototype,v=p[O]||p["@@iterator"]||i&&p[i],g=!R&&v||l(i),y=i?d?l("entries"):g:void 0,_="Array"==t&&p.entries||v;if(_&&(c=x(_.call(new e)))!==Object.prototype&&c.next&&(T(c,f,!0),m||P(c,O)||w(c,O,k)),d&&v&&v.name!==C&&(h=!0,g=function(){return v.call(this)}),m&&!a||!R&&!h&&p[O]||w(p,O,g),S[t]=g,S[f]=k,i)if(s={values:d?g:l(C),keys:o?g:l("keys"),entries:y},a)for(u in s)u in p||E(p,u,s[u]);else b(b.P+b.F*(R||h),t,s);return s}},function(e,t){var n=Math.expm1;e.exports=!n||22025.465794806718<n(10)||n(10)<22025.465794806718||-2e-17!=n(-2e-17)?function(e){return 0==(e=+e)?e:-1e-6<e&&e<1e-6?e+e*e/2:Math.exp(e)-1}:n},function(e,t){e.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},function(e,t,n){var s=n(3),u=n(149).set,c=s.MutationObserver||s.WebKitMutationObserver,l=s.process,f=s.Promise,d="process"==n(27)(l);e.exports=function(){var n,r,i,e=function(){var e,t;for(d&&(e=l.domain)&&e.exit();n;){t=n.fn,n=n.next;try{t()}catch(e){throw n?i():r=void 0,e}}r=void 0,e&&e.enter()};if(d)i=function(){l.nextTick(e)};else if(!c||s.navigator&&s.navigator.standalone)if(f&&f.resolve){var t=f.resolve();i=function(){t.then(e)}}else i=function(){u.call(s,e)};else{var o=!0,a=document.createTextNode("");new c(e).observe(a,{characterData:!0}),i=function(){a.data=o=!o}}return function(e){var t={fn:e,next:void 0};r&&(r.next=t),n||(n=t,i()),r=t}}},function(e,t,n){"use strict";var i=n(15);function r(e){var n,r;this.promise=new e(function(e,t){if(void 0!==n||void 0!==r)throw TypeError("Bad Promise constructor");n=e,r=t}),this.resolve=i(n),this.reject=i(r)}e.exports.f=function(e){return new r(e)}},function(e,t,i){var n=i(5),r=i(2),o=function(e,t){if(r(e),!n(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,n,r){try{(r=i(28)(Function.call,i(22).f(Object.prototype,"__proto__").set,2))(e,[]),n=!(e instanceof Array)}catch(e){n=!0}return function(e,t){return o(e,t),n?e.__proto__=t:r(e,t),e}}({},!1):void 0),check:o}},function(e,t,n){var r=n(98)("keys"),i=n(58);e.exports=function(e){return r[e]||(r[e]=i(e))}},function(e,t,n){var u=n(36),c=n(34);e.exports=function(s){return function(e,t){var n,r,i=String(c(e)),o=u(t),a=i.length;return o<0||a<=o?s?"":void 0:(n=i.charCodeAt(o))<55296||56319<n||o+1===a||(r=i.charCodeAt(o+1))<56320||57343<r?s?i.charAt(o):n:s?i.slice(o,o+2):r-56320+(n-55296<<10)+65536}}},function(e,t,n){var r=n(92),i=n(34);e.exports=function(e,t,n){if(r(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(i(e))}},function(e,t,n){"use strict";var i=n(36),o=n(34);e.exports=function(e){var t=String(o(this)),n="",r=i(e);if(r<0||r==1/0)throw RangeError("Count can't be negative");for(;0<r;(r>>>=1)&&(t+=t))1&r&&(n+=t);return n}},function(e,t){e.exports="\t\n\v\f\r    \u2028\u2029\ufeff"},function(e,t,n){var r,i,o,a=n(28),s=n(208),u=n(134),c=n(131),l=n(3),f=l.process,d=l.setImmediate,h=l.clearImmediate,p=l.MessageChannel,v=l.Dispatch,g=0,y={},_="onreadystatechange",m=function(){var e=+this;if(y.hasOwnProperty(e)){var t=y[e];delete y[e],t()}},b=function(e){m.call(e.data)};d&&h||(d=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return y[++g]=function(){s("function"==typeof e?e:Function(e),t)},r(g),g},h=function(e){delete y[e]},"process"==n(27)(f)?r=function(e){f.nextTick(a(m,e,1))}:v&&v.now?r=function(e){v.now(a(m,e,1))}:p?(o=(i=new p).port2,i.port1.onmessage=b,r=a(o.postMessage,o,1)):l.addEventListener&&"function"==typeof postMessage&&!l.importScripts?(r=function(e){l.postMessage(e+"","*")},l.addEventListener("message",b,!1)):r=_ in c("script")?function(e){u.appendChild(c("script"))[_]=function(){u.removeChild(this),m.call(e)}}:function(e){setTimeout(a(m,e,1),0)}),e.exports={set:d,clear:h}},function(e,t,n){"use strict";var r=n(3),i=n(9),o=n(50),a=n(100),s=n(19),u=n(55),c=n(4),l=n(48),f=n(36),d=n(11),h=n(226),p=n(52).f,v=n(10).f,g=n(128),y=n(64),_="ArrayBuffer",m="DataView",b="prototype",E="Wrong index!",w=r[_],P=r[m],S=r.Math,A=r.RangeError,T=r.Infinity,x=w,O=S.abs,R=S.pow,C=S.floor,k=S.log,M=S.LN2,L="byteLength",I="byteOffset",N=i?"_b":"buffer",F=i?"_l":L,j=i?"_o":I;function D(e,t,n){var r,i,o,a=new Array(n),s=8*n-t-1,u=(1<<s)-1,c=u>>1,l=23===t?R(2,-24)-R(2,-77):0,f=0,d=e<0||0===e&&1/e<0?1:0;for((e=O(e))!=e||e===T?(i=e!=e?1:0,r=u):(r=C(k(e)/M),e*(o=R(2,-r))<1&&(r--,o*=2),2<=(e+=1<=r+c?l/o:l*R(2,1-c))*o&&(r++,o/=2),u<=r+c?(i=0,r=u):1<=r+c?(i=(e*o-1)*R(2,t),r+=c):(i=e*R(2,c-1)*R(2,t),r=0));8<=t;a[f++]=255&i,i/=256,t-=8);for(r=r<<t|i,s+=t;0<s;a[f++]=255&r,r/=256,s-=8);return a[--f]|=128*d,a}function B(e,t,n){var r,i=8*n-t-1,o=(1<<i)-1,a=o>>1,s=i-7,u=n-1,c=e[u--],l=127&c;for(c>>=7;0<s;l=256*l+e[u],u--,s-=8);for(r=l&(1<<-s)-1,l>>=-s,s+=t;0<s;r=256*r+e[u],u--,s-=8);if(0===l)l=1-a;else{if(l===o)return r?NaN:c?-T:T;r+=R(2,t),l-=a}return(c?-1:1)*r*R(2,l-t)}function U(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]}function G(e){return[255&e]}function V(e){return[255&e,e>>8&255]}function z(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]}function W(e){return D(e,52,8)}function X(e){return D(e,23,4)}function H(e,t,n){v(e[b],t,{get:function(){return this[n]}})}function Y(e,t,n,r){var i=h(+n);if(i+t>e[F])throw A(E);var o=e[N]._b,a=i+e[j],s=o.slice(a,a+t);return r?s:s.reverse()}function K(e,t,n,r,i,o){var a=h(+n);if(a+t>e[F])throw A(E);for(var s=e[N]._b,u=a+e[j],c=r(+i),l=0;l<t;l++)s[u+l]=c[o?l:t-l-1]}if(a.ABV){if(!c(function(){w(1)})||!c(function(){new w(-1)})||c(function(){return new w,new w(1.5),new w(NaN),w.name!=_})){for(var Z,q=(w=function(e){return l(this,w),new x(h(e))})[b]=x[b],Q=p(x),J=0;Q.length>J;)(Z=Q[J++])in w||s(w,Z,x[Z]);o||(q.constructor=w)}var $=new P(new w(2)),ee=P[b].setInt8;$.setInt8(0,2147483648),$.setInt8(1,2147483649),!$.getInt8(0)&&$.getInt8(1)||u(P[b],{setInt8:function(e,t){ee.call(this,e,t<<24>>24)},setUint8:function(e,t){ee.call(this,e,t<<24>>24)}},!0)}else w=function(e){l(this,w,_);var t=h(e);this._b=g.call(new Array(t),0),this[F]=t},P=function(e,t,n){l(this,P,m),l(e,w,m);var r=e[F],i=f(t);if(i<0||r<i)throw A("Wrong offset!");if(r<i+(n=void 0===n?r-i:d(n)))throw A("Wrong length!");this[N]=e,this[j]=i,this[F]=n},i&&(H(w,L,"_l"),H(P,"buffer","_b"),H(P,L,"_l"),H(P,I,"_o")),u(P[b],{getInt8:function(e){return Y(this,1,e)[0]<<24>>24},getUint8:function(e){return Y(this,1,e)[0]},getInt16:function(e){var t=Y(this,2,e,arguments[1]);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=Y(this,2,e,arguments[1]);return t[1]<<8|t[0]},getInt32:function(e){return U(Y(this,4,e,arguments[1]))},getUint32:function(e){return U(Y(this,4,e,arguments[1]))>>>0},getFloat32:function(e){return B(Y(this,4,e,arguments[1]),23,4)},getFloat64:function(e){return B(Y(this,8,e,arguments[1]),52,8)},setInt8:function(e,t){K(this,1,e,G,t)},setUint8:function(e,t){K(this,1,e,G,t)},setInt16:function(e,t){K(this,2,e,V,t,arguments[2])},setUint16:function(e,t){K(this,2,e,V,t,arguments[2])},setInt32:function(e,t){K(this,4,e,z,t,arguments[2])},setUint32:function(e,t){K(this,4,e,z,t,arguments[2])},setFloat32:function(e,t){K(this,4,e,X,t,arguments[2])},setFloat64:function(e,t){K(this,8,e,W,t,arguments[2])}});y(w,_),y(P,m),s(P[b],a.VIEW,!0),t[_]=w,t[m]=P},function(e,t,n){var r=n(3).navigator;e.exports=r&&r.userAgent||""},function(e,t,n){var r=n(3),i=n(33),o=n(50),a=n(227),s=n(10).f;e.exports=function(e){var t=i.Symbol||(i.Symbol=o?{}:r.Symbol||{});"_"==e.charAt(0)||e in t||s(t,e,{value:a.f(e)})}},function(e,t,n){var r=n(71),i=n(6)("iterator"),o=n(63);e.exports=n(33).getIteratorMethod=function(e){if(null!=e)return e[i]||e["@@iterator"]||o[r(e)]}},function(e,t,n){"use strict";var r=n(43),i=n(211),o=n(63),a=n(24);e.exports=n(138)(Array,"Array",function(e,t){this._t=a(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,i(1)):i(0,"keys"==t?n:"values"==t?e[n]:[n,e[n]])},"values"),o.Arguments=o.Array,r("keys"),r("values"),r("entries")},function(n,e,r){"use strict";(function(e){var t=r(74);if("production"!==e.env.NODE_ENV){t=function(e,t){if(void 0===t)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");if(0!==t.indexOf("Failed Composite propType: ")&&!e){for(var n=arguments.length,r=Array(2<n?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];(function(e){for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i=0,o="Warning: "+e.replace(/%s/g,function(){return n[i++]});"undefined"!=typeof console&&console.error(o);try{throw new Error(o)}catch(e){}}).apply(void 0,[t].concat(r))}}}n.exports=t}).call(e,r(26))},function(e,t){e.exports=function(e,t){var n=t[0],r=t[1],i=t[2],o=t[3],a=t[4],s=t[5],u=t[6],c=t[7],l=t[8],f=t[9],d=t[10],h=t[11],p=t[12],v=t[13],g=t[14],y=t[15],_=n*s-r*a,m=n*u-i*a,b=n*c-o*a,E=r*u-i*s,w=r*c-o*s,P=i*c-o*u,S=l*v-f*p,A=l*g-d*p,T=l*y-h*p,x=f*g-d*v,O=f*y-h*v,R=d*y-h*g,C=_*R-m*O+b*x+E*T-w*A+P*S;return C?(C=1/C,e[0]=(s*R-u*O+c*x)*C,e[1]=(i*O-r*R-o*x)*C,e[2]=(v*P-g*w+y*E)*C,e[3]=(d*w-f*P-h*E)*C,e[4]=(u*T-a*R-c*A)*C,e[5]=(n*R-i*T+o*A)*C,e[6]=(g*b-p*P-y*m)*C,e[7]=(l*P-d*b+h*m)*C,e[8]=(a*O-s*T+c*S)*C,e[9]=(r*T-n*O-o*S)*C,e[10]=(p*w-v*b+y*_)*C,e[11]=(f*b-l*w-h*_)*C,e[12]=(s*A-a*x-u*S)*C,e[13]=(n*x-r*A+i*S)*C,e[14]=(v*m-p*E-g*_)*C,e[15]=(l*E-f*m+d*_)*C,e):null}},function(e,t){e.exports=function(e,t,n){var r=Math.sin(n),i=Math.cos(n),o=t[4],a=t[5],s=t[6],u=t[7],c=t[8],l=t[9],f=t[10],d=t[11];t!==e&&(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]);return e[4]=o*i+c*r,e[5]=a*i+l*r,e[6]=s*i+f*r,e[7]=u*i+d*r,e[8]=c*i-o*r,e[9]=l*i-a*r,e[10]=f*i-s*r,e[11]=d*i-u*r,e}},function(e,t){e.exports=function(e,t,n){var r=Math.sin(n),i=Math.cos(n),o=t[0],a=t[1],s=t[2],u=t[3],c=t[4],l=t[5],f=t[6],d=t[7];t!==e&&(e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]);return e[0]=o*i+c*r,e[1]=a*i+l*r,e[2]=s*i+f*r,e[3]=u*i+d*r,e[4]=c*i-o*r,e[5]=l*i-a*r,e[6]=f*i-s*r,e[7]=d*i-u*r,e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}},function(e,t){e.exports=function(e,t){return e[0]=-t[0],e[1]=-t[1],e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e}},function(e,t,n){"use strict";t.a=s,t.b=function(e){a=e},t.c=m,t.d=function(e){return function(e){e=e.concat(a);var n={};return function e(t){var n=t.modules,r=t.level,i=t.result;if(5<=r)throw new Error("Possible loop in shader dependency graph");var o=!0,a=!1,s=void 0;try{for(var u,c=n[Symbol.iterator]();!(o=(u=c.next()).done);o=!0){var l=u.value,f=m(l);(void 0===i[f.name]||i[f.name]<r)&&(i[f.name]=r)}}catch(e){a=!0,s=e}finally{try{!o&&c.return&&c.return()}finally{if(a)throw s}}var d=!0,h=!1,p=void 0;try{for(var v,g=n[Symbol.iterator]();!(d=(v=g.next()).done);d=!0){var y=v.value,_=m(y);_.dependencies&&e({modules:_.dependencies,level:r+1,result:i})}}catch(e){h=!0,p=e}finally{try{!d&&g.return&&g.return()}finally{if(h)throw p}}return i}({modules:e,level:0,result:n}),Object.keys(n).sort(function(e,t){return n[t]-n[e]})}(e.map(function(e){return"string"!=typeof e?(s([e],{ignoreMultipleRegistrations:!0}),e.name):e}))};var r=n(1),i=n.n(r),o={},a=[];function s(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).ignoreMultipleRegistrations,n=void 0!==t&&t,r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){u(a.value,{ignoreMultipleRegistrations:n})}}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}}function m(e){if("string"!=typeof e){var t=e;return i()("string"==typeof t.name),u(t,{ignoreMultipleRegistrations:!0}),t}var n=o[e];return n||i()(!1,"Unknown shader module "+e),n}function u(e,t){var n=t.ignoreMultipleRegistrations,r=void 0!==n&&n;if(i()(e.name,"shader module has no name"),!r&&o[e.name])throw new Error("shader module "+e.name+" already registered");(o[e.name]=e).dependencies=e.dependencies||[],e.deprecations=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[];return e.forEach(function(e){switch(e.type){case"function":e.regex=new RegExp("\\b"+e.old+"\\(");break;default:e.regex=new RegExp(e.type+" "+e.old+";")}}),e}(e.deprecations)}},function(e,t,n){"use strict";t.b=function(e){switch(ArrayBuffer.isView(e)?e.constructor:e){case Float32Array:return c;case Uint16Array:return a;case Uint32Array:return u;case Uint8Array:case Uint8ClampedArray:return i;case Int8Array:return r;case Int16Array:return o;case Int32Array:return s;default:throw new Error(h)}},t.a=function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).clamped,n=void 0===t||t;switch(e){case c:return Float32Array;case a:case d:case l:case f:return Uint16Array;case u:return Uint32Array;case i:return n?Uint8ClampedArray:Uint8Array;case r:return Int8Array;case o:return Int16Array;case s:return Int32Array;default:throw new Error("Failed to deduce typed array type from GL constant")}},t.c=function(e){var t=e.data,n=e.width,r=e.height,i=e.bytesPerPixel,o=void 0===i?4:i,a=e.temp,s=n*o;a=a||new Uint8Array(s);for(var u=0;u<r/2;++u){var c=u*s,l=(r-u-1)*s;a.set(t.subarray(c,c+s)),t.copyWithin(c,l,l+s),t.set(a,l)}},t.d=function(e){for(var t=e.data,n=e.width,r=e.height,i=Math.round(n/2),o=Math.round(r/2),a=new Uint8Array(i*o*4),s=0;s<o;s++)for(var u=0;u<i;u++)for(var c=0;c<4;c++)a[4*(s*i+u)+c]=t[4*(2*s*n+2*u)+c];return{data:a,width:i,height:o}};var r=5120,i=5121,o=5122,a=5123,s=5124,u=5125,c=5126,l=32819,f=32820,d=33635,h="Failed to deduce GL constant from typed array"},function(e,t,s){"use strict";t.a=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.enable,r=void 0===n||n,i=t.copyState;if(l()(void 0!==i),!e.state){for(var o in s.i(c.a)(e),e.state=new v(e,{copyState:i,enable:r}),d){var a=d[o];p(e,o,a)}h(e,"getParameter"),h(e,"isEnabled")}return e.state.enable=r,e},t.b=function(e){l()(e.state),e.state.push()},t.c=function(e){l()(e.state),e.state.pop()};var a=s(46),u=s(266),c=s(265),n=s(1),l=s.n(n),r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function f(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var o=function(e,t){var n=Array.isArray(e)||ArrayBuffer.isView(e),r=Array.isArray(t)||ArrayBuffer.isView(t);if(n&&r&&e.length===t.length){for(var i=0;i<e.length;++i)if(e[i]!==t[i])return!1;return!0}return e===t},d={enable:function(e,t){return e(f({},t,!0))},disable:function(e,t){return e(f({},t,!1))},pixelStorei:function(e,t,n){return e(f({},t,n))},hint:function(e,t,n){return e(f({},t,n))},bindFramebuffer:function(e,t,n){var r;switch(t){case a.a.FRAMEBUFFER:return e((f(r={},a.a.DRAW_FRAMEBUFFER_BINDING,n),f(r,a.a.READ_FRAMEBUFFER_BINDING,n),r));case a.a.DRAW_FRAMEBUFFER:return e(f({},a.a.DRAW_FRAMEBUFFER_BINDING,n));case a.a.READ_FRAMEBUFFER:return e(f({},a.a.READ_FRAMEBUFFER_BINDING,n));default:return null}},blendColor:function(e,t,n,r,i){return e(f({},a.a.BLEND_COLOR,new Float32Array([t,n,r,i])))},blendEquation:function(e,t){var n;return e((f(n={},a.a.BLEND_EQUATION_RGB,t),f(n,a.a.BLEND_EQUATION_ALPHA,t),n))},blendEquationSeparate:function(e,t,n){var r;return e((f(r={},a.a.BLEND_EQUATION_RGB,t),f(r,a.a.BLEND_EQUATION_ALPHA,n),r))},blendFunc:function(e,t,n){var r;return e((f(r={},a.a.BLEND_SRC_RGB,t),f(r,a.a.BLEND_DST_RGB,n),f(r,a.a.BLEND_SRC_ALPHA,t),f(r,a.a.BLEND_DST_ALPHA,n),r))},blendFuncSeparate:function(e,t,n,r,i){var o;return e((f(o={},a.a.BLEND_SRC_RGB,t),f(o,a.a.BLEND_DST_RGB,n),f(o,a.a.BLEND_SRC_ALPHA,r),f(o,a.a.BLEND_DST_ALPHA,i),o))},clearColor:function(e,t,n,r,i){return e(f({},a.a.COLOR_CLEAR_VALUE,new Float32Array([t,n,r,i])))},clearDepth:function(e,t){return e(f({},a.a.DEPTH_CLEAR_VALUE,t))},clearStencil:function(e,t){return e(f({},a.a.STENCIL_CLEAR_VALUE,t))},colorMask:function(e,t,n,r,i){return e(f({},a.a.COLOR_WRITEMASK,[t,n,r,i]))},cullFace:function(e,t){return e(f({},a.a.CULL_FACE_MODE,t))},depthFunc:function(e,t){return e(f({},a.a.DEPTH_FUNC,t))},depthRange:function(e,t,n){return e(f({},a.a.DEPTH_RANGE,new Float32Array([t,n])))},depthMask:function(e,t){return e(f({},a.a.DEPTH_WRITEMASK,t))},frontFace:function(e,t){return e(f({},a.a.FRONT_FACE,t))},lineWidth:function(e,t){return e(f({},a.a.LINE_WIDTH,t))},polygonOffset:function(e,t,n){var r;return e((f(r={},a.a.POLYGON_OFFSET_FACTOR,t),f(r,a.a.POLYGON_OFFSET_UNITS,n),r))},sampleCoverage:function(e,t,n){var r;return e((f(r={},a.a.SAMPLE_COVERAGE_VALUE,t),f(r,a.a.SAMPLE_COVERAGE_INVERT,n),r))},scissor:function(e,t,n,r,i){return e(f({},a.a.SCISSOR_BOX,new Int32Array([t,n,r,i])))},stencilMask:function(e,t){var n;return e((f(n={},a.a.STENCIL_WRITEMASK,t),f(n,a.a.STENCIL_BACK_WRITEMASK,t),n))},stencilMaskSeparate:function(e,t,n){return e(f({},t===a.a.FRONT?a.a.STENCIL_WRITEMASK:a.a.STENCIL_BACK_WRITEMASK,n))},stencilFunc:function(e,t,n,r){var i;return e((f(i={},a.a.STENCIL_FUNC,t),f(i,a.a.STENCIL_REF,n),f(i,a.a.STENCIL_VALUE_MASK,r),f(i,a.a.STENCIL_BACK_FUNC,t),f(i,a.a.STENCIL_BACK_REF,n),f(i,a.a.STENCIL_BACK_VALUE_MASK,r),i))},stencilFuncSeparate:function(e,t,n,r,i){var o;return e((f(o={},t===a.a.FRONT?a.a.STENCIL_FUNC:a.a.STENCIL_BACK_FUNC,n),f(o,t===a.a.FRONT?a.a.STENCIL_REF:a.a.STENCIL_BACK_REF,r),f(o,t===a.a.FRONT?a.a.STENCIL_VALUE_MASK:a.a.STENCIL_BACK_VALUE_MASK,i),o))},stencilOp:function(e,t,n,r){var i;return e((f(i={},a.a.STENCIL_FAIL,t),f(i,a.a.STENCIL_PASS_DEPTH_FAIL,n),f(i,a.a.STENCIL_PASS_DEPTH_PASS,r),f(i,a.a.STENCIL_BACK_FAIL,t),f(i,a.a.STENCIL_BACK_PASS_DEPTH_FAIL,n),f(i,a.a.STENCIL_BACK_PASS_DEPTH_PASS,r),i))},stencilOpSeparate:function(e,t,n,r,i){var o;return e((f(o={},t===a.a.FRONT?a.a.STENCIL_FAIL:a.a.STENCIL_BACK_FAIL,n),f(o,t===a.a.FRONT?a.a.STENCIL_PASS_DEPTH_FAIL:a.a.STENCIL_BACK_PASS_DEPTH_FAIL,r),f(o,t===a.a.FRONT?a.a.STENCIL_PASS_DEPTH_PASS:a.a.STENCIL_BACK_PASS_DEPTH_PASS,i),o))},viewport:function(e,t,n,r,i){return e(f({},a.a.VIEWPORT,new Int32Array([t,n,r,i])))}};function h(t,e){var n=t[e].bind(t);t[e]=function(){var e=arguments.length<=0?void 0:arguments[0];return e in t.state.cache||(t.state.cache[e]=n.apply(void 0,arguments)),t.state.enable?t.state.cache[e]:n.apply(void 0,arguments)},Object.defineProperty(t[e],"name",{value:e+"-from-cache",configurable:!1})}function p(s,u,c){var l=s[u].bind(s);s[u]=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r,i=c.apply(void 0,[s.state._updateCache].concat(t)),o=i.valueChanged,a=i.oldValue;o&&((r=s.state).log.apply(r,["gl."+u].concat(t)),l.apply(void 0,t));return a},Object.defineProperty(s[u],"name",{value:u+"-to-cache",configurable:!1})}var v=function(){function a(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.copyState,r=void 0!==n&&n,i=t.log,o=void 0===i?function(){}:i;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),this.gl=e,this.stateStack=[],this.enable=!0,this.cache=r?s.i(u.a)(e):Object.assign({},u.b),this.log=o,this._updateCache=this._updateCache.bind(this),Object.seal(this)}return r(a,[{key:"push",value:function(){0<arguments.length&&void 0!==arguments[0]&&arguments[0];this.stateStack.push({})}},{key:"pop",value:function(){l()(0<this.stateStack.length);var e=this.stateStack[this.stateStack.length-1];s.i(u.c)(this.gl,e,this.cache),this.stateStack.pop()}},{key:"_updateCache",value:function(e){var t=!1,n=void 0,r=0<this.stateStack.length&&this.stateStack[this.stateStack.length-1];for(var i in e)l()(void 0!==i),o(e[i],this.cache[i])||(t=!0,n=this.cache[i],!r||i in r||(r[i]=this.cache[i]),this.cache[i]=e[i]);return{valueChanged:t,oldValue:n}}}]),a}()},function(e,t,u){"use strict";t.c=i,t.b=o,t.a=function(e){var t=i(e),n=o(e);return{vendor:n[a]||n[s.a.VENDOR],renderer:n[f]||n[s.a.RENDERER],version:n[s.a.VERSION],shadingLanguageVersion:n[s.a.SHADING_LANGUAGE_VERSION],info:n,limits:t,webgl1MinLimits:e.luma.webgl1MinLimits,webgl2MinLimits:e.luma.webgl2MinLimits}},t.d=function(e){return t=e,n=t.getParameter(s.a.VENDOR),r=t.getParameter(s.a.RENDERER),i=t.getExtension("WEBGL_debug_renderer_info"),o=i&&t.getParameter(i.UNMASKED_VENDOR_WEBGL||s.a.VENDOR),a=i&&t.getParameter(i.UNMASKED_RENDERER_WEBGL||s.a.RENDERER),{vendor:o||n,renderer:a||r,vendorMasked:n,rendererMasked:r,version:t.getParameter(s.a.VERSION),shadingLanguageVersion:t.getParameter(s.a.SHADING_LANGUAGE_VERSION)};var t,n,r,i,o,a};var n,s=u(25),c=u(7);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var l=(r(n={},s.a.ALIASED_LINE_WIDTH_RANGE,{gl1:new Float32Array([1,1])}),r(n,s.a.ALIASED_POINT_SIZE_RANGE,{gl1:new Float32Array([1,1])}),r(n,s.a.MAX_TEXTURE_SIZE,{gl1:64,gl2:2048}),r(n,s.a.MAX_CUBE_MAP_TEXTURE_SIZE,{gl1:16}),r(n,s.a.MAX_TEXTURE_IMAGE_UNITS,{gl1:8}),r(n,s.a.MAX_COMBINED_TEXTURE_IMAGE_UNITS,{gl1:8}),r(n,s.a.MAX_VERTEX_TEXTURE_IMAGE_UNITS,{gl1:0}),r(n,s.a.MAX_RENDERBUFFER_SIZE,{gl1:1}),r(n,s.a.MAX_VARYING_VECTORS,{gl1:8}),r(n,s.a.MAX_VERTEX_ATTRIBS,{gl1:8}),r(n,s.a.MAX_VERTEX_UNIFORM_VECTORS,{gl1:128}),r(n,s.a.MAX_FRAGMENT_UNIFORM_VECTORS,{gl1:16}),r(n,s.a.MAX_VIEWPORT_DIMS,{gl1:new Int32Array([0,0])}),r(n,s.a.MAX_3D_TEXTURE_SIZE,{gl1:0,gl2:256}),r(n,s.a.MAX_ARRAY_TEXTURE_LAYERS,{gl1:0,gl2:256}),r(n,s.a.MAX_CLIENT_WAIT_TIMEOUT_WEBGL,{gl1:0,gl2:0}),r(n,s.a.MAX_COLOR_ATTACHMENTS,{gl1:0,gl2:4}),r(n,s.a.MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MAX_COMBINED_UNIFORM_BLOCKS,{gl1:0,gl2:0}),r(n,s.a.MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MAX_DRAW_BUFFERS,{gl1:0,gl2:4}),r(n,s.a.MAX_ELEMENT_INDEX,{gl1:0,gl2:0}),r(n,s.a.MAX_ELEMENTS_INDICES,{gl1:0,gl2:0}),r(n,s.a.MAX_ELEMENTS_VERTICES,{gl1:0,gl2:0}),r(n,s.a.MAX_FRAGMENT_INPUT_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MAX_FRAGMENT_UNIFORM_BLOCKS,{gl1:0,gl2:0}),r(n,s.a.MAX_FRAGMENT_UNIFORM_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MAX_SAMPLES,{gl1:0,gl2:0}),r(n,s.a.MAX_SERVER_WAIT_TIMEOUT,{gl1:0,gl2:0}),r(n,s.a.MAX_TEXTURE_LOD_BIAS,{gl1:0,gl2:0}),r(n,s.a.MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS,{gl1:0,gl2:0}),r(n,s.a.MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MAX_UNIFORM_BLOCK_SIZE,{gl1:0,gl2:0}),r(n,s.a.MAX_UNIFORM_BUFFER_BINDINGS,{gl1:0,gl2:0}),r(n,s.a.MAX_VARYING_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MAX_VERTEX_OUTPUT_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MAX_VERTEX_UNIFORM_BLOCKS,{gl1:0,gl2:0}),r(n,s.a.MAX_VERTEX_UNIFORM_COMPONENTS,{gl1:0,gl2:0}),r(n,s.a.MIN_PROGRAM_TEXEL_OFFSET,{gl1:0,gl2:-8,negative:!0}),r(n,s.a.MAX_PROGRAM_TEXEL_OFFSET,{gl1:0,gl2:7}),r(n,s.a.UNIFORM_BUFFER_OFFSET_ALIGNMENT,{gl1:0,gl2:0}),n);function i(e){if(e.luma=e.luma||{},!e.luma.limits){e.luma.limits={},e.luma.webgl1MinLimits={},e.luma.webgl2MinLimits={};var t=u.i(c.b)(e);for(var n in l){var r=l[n],i=r.gl1,o="gl2"in r?r.gl2:r.gl1,a=t?o:i,s="gl2"in r&&!t||"extension"in r&&!e.getExtension(r.extension)?a:e.getParameter(n);e.luma.limits[n]=s,e.luma.webgl1MinLimits[n]=i,e.luma.webgl2MinLimits[n]=o}}return e.luma.limits}function o(e){if(e.luma=e.luma||{},!e.luma.info){var t,n=e.getExtension("WEBGL_debug_renderer_info");e.luma.info=(r(t={},s.a.VENDOR,e.getParameter(s.a.VENDOR)),r(t,s.a.RENDERER,e.getParameter(s.a.RENDERER)),r(t,s.a.UNMASKED_VENDOR_WEBGL,e.getParameter(n&&n.UNMASKED_VENDOR_WEBGL||s.a.VENDOR)),r(t,s.a.UNMASKED_RENDERER_WEBGL,e.getParameter(n&&n.UNMASKED_RENDERER_WEBGL||s.a.RENDERER)),r(t,s.a.VERSION,e.getParameter(s.a.VERSION)),r(t,s.a.SHADING_LANGUAGE_VERSION,e.getParameter(s.a.SHADING_LANGUAGE_VERSION)),t)}return e.luma.info}var a=37445,f=37446},function(e,t,n){"use strict";var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var i=function(e){return e},o=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.pendingQueries=new Set,this.invalidQueryType=null,this.invalidErrorMessage="",this.checkInvalid=function(){return!1}}return r(e,[{key:"poll",value:function(e){this.cancelInvalidQueries(e);var t=!0,n=!1,r=void 0;try{for(var i,o=this.pendingQueries.values()[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){var a=i.value;if(a.isResultAvailable()){var s=a.getResult();this.resolveQuery(a,s)}}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}}},{key:"setInvalidator",value:function(e){var t=e.queryType,n=e.errorMessage,r=e.checkInvalid;this.invalidQueryType=t,this.invalidErrorMessage=n,this.checkInvalid=r}},{key:"beginQuery",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:i,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:i;this.cancelInvalidQueries(e.gl),this.cancelQuery(e);var r={};return e.promise=new Promise(function(e,t){r.resolve=e,r.reject=t}),Object.assign(e.promise,r),this.pendingQueries.add(e),e.promise.then(t).catch(n)}},{key:"resolveQuery",value:function(e,t){this.pendingQueries.delete(e),e.promise.resolve(t)}},{key:"rejectQuery",value:function(e,t){this.pendingQueries.delete(e),e.promise&&e.promise.reject(new Error(t))}},{key:"deleteQuery",value:function(e){return this.rejectQuery(e,"Query was deleted before result was available")}},{key:"cancelQuery",value:function(e){return this.rejectQuery(e,"Query was canceled before result was available")}},{key:"invalidateQuery",value:function(e){e instanceof this.invalidQueryType&&this.rejectQuery(e,this.invalidErrorMessage)}},{key:"cancelInvalidQueries",value:function(e){if(this.checkInvalid(e)){var t=!0,n=!1,r=void 0;try{for(var i,o=this.pendingQueries.values()[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){var a=i.value;this.invalidateQuery(a)}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}}}}]),e}();t.a=new o},function(e,t,i){"use strict";var n=i(38),o=i(7),a=i(62),s=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var r=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),i.i(o.j)(e);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,Object.assign({},t,{target:e.TEXTURE_2D})));return n.initialize(t),Object.seal(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,a["a"]),s(r,null,[{key:"isSupported",value:function(e,t){return a.a.isSupported(e,t)}}]),s(r,[{key:"bind",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:this.textureUnit,t=this.gl;if(void 0===e)throw new Error("Texture.bind: must specify texture unit");return this.textureUnit=e,t.activeTexture(t.TEXTURE0+e),t.bindTexture(this.target,this.handle),e}},{key:"unbind",value:function(){var e=this.gl;if(void 0===this.textureUnit)throw new Error("Texture.unbind: texture unit not specified");return e.activeTexture(e.TEXTURE0+this.textureUnit),e.bindTexture(this.target,null),this.textureUnit}},{key:"getActiveUnit",value:function(){return this.gl.getParameter(n.f.ACTIVE_TEXTURE)-n.f.TEXTURE0}}]),r}();t.a=r},function(e,t,L){"use strict";t.a=function(e){var t=e.match(/([^\[]*)(\[[0-9]+\])?/);if(!t||t.length<2)throw new Error("Failed to parse GLSL uniform name "+e);return{name:t[1],length:t[2]||1,isArray:Boolean(t[2])}},t.b=function(e,t,n){var r=a[n.type];if(r)return r.bind(null,e,t);throw new Error("Unknown GLSL uniform type "+n.type)},t.c=function(e,t){for(var n in e){var r=e[n];if(!p(r))throw t=t?t+" ":"",console.error(t+" Bad uniform "+n,r),new Error(t+" Bad uniform "+n)}return!0},t.e=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.header,n=void 0===t?"Uniforms":t,r=e.program,i=e.uniforms,o=e.undefinedOnly,a=void 0!==o&&o;N()(r);var s=r._uniformSetters,u={},c=Object.keys(s).sort(),l=0,f=!0,d=!1,h=void 0;try{for(var p,v=c[Symbol.iterator]();!(f=(p=v.next()).done);f=!0){var g=p.value;g.match(".*_.*")||g.match(".*Matrix")||j({table:u,header:n,uniforms:i,uniformName:g,undefinedOnly:a})&&l++}}catch(e){d=!0,h=e}finally{try{!f&&v.return&&v.return()}finally{if(d)throw h}}var y=!0,_=!1,m=void 0;try{for(var b,E=c[Symbol.iterator]();!(y=(b=E.next()).done);y=!0){var w=b.value;w.match(".*Matrix")&&j({table:u,header:n,uniforms:i,uniformName:w,undefinedOnly:a})&&l++}}catch(e){_=!0,m=e}finally{try{!y&&E.return&&E.return()}finally{if(_)throw m}}var P=!0,S=!1,A=void 0;try{for(var T,x=c[Symbol.iterator]();!(P=(T=x.next()).done);P=!0){var O=T.value;u[O]||j({table:u,header:n,uniforms:i,uniformName:O,undefinedOnly:a})&&l++}}catch(e){S=!0,A=e}finally{try{!P&&x.return&&x.return()}finally{if(S)throw A}}var R=0,C={};if(!a)for(var k in i){var M=i[k];u[k]||(R++,C[k]=F({Type:"NOT USED: "+M},n,L.i(I.c)(M)))}return{table:u,count:l,unusedTable:C,unusedCount:R}},t.d=function(e,t){if(Array.isArray(e)||ArrayBuffer.isView(e)){if(!t)return!1;var n=e.length;if(t.length!==n)return!1;for(var r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}return e===t};var n,r=L(69),i=L(62),I=L(8),o=L(1),N=L.n(o);function F(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var a=(F(n={},5126,function(e,t,n){return e.uniform1f(t,n)}),F(n,35664,function(e,t,n){return e.uniform2fv(t,f(n,2))}),F(n,35665,function(e,t,n){return e.uniform3fv(t,f(n,3))}),F(n,35666,function(e,t,n){return e.uniform4fv(t,f(n,4))}),F(n,5124,function(e,t,n){return e.uniform1i(t,n)}),F(n,35667,function(e,t,n){return e.uniform2iv(t,d(n,2))}),F(n,35668,function(e,t,n){return e.uniform3iv(t,d(n,3))}),F(n,35669,function(e,t,n){return e.uniform4iv(t,d(n,4))}),F(n,35670,function(e,t,n){return e.uniform1i(t,n)}),F(n,35671,function(e,t,n){return e.uniform2iv(t,d(n,2))}),F(n,35672,function(e,t,n){return e.uniform3iv(t,d(n,3))}),F(n,35673,function(e,t,n){return e.uniform4iv(t,d(n,4))}),F(n,35674,function(e,t,n){return e.uniformMatrix2fv(t,!1,f(n,4))}),F(n,35675,function(e,t,n){return e.uniformMatrix3fv(t,!1,f(n,9))}),F(n,35676,function(e,t,n){return e.uniformMatrix4fv(t,!1,f(n,16))}),F(n,35678,function(e,t,n){return e.uniform1i(t,n)}),F(n,35680,function(e,t,n){return e.uniform1i(t,n)}),F(n,5125,function(e,t,n){return e.uniform1ui(t,n)}),F(n,36294,function(e,t,n){return e.uniform2uiv(t,h(n,2))}),F(n,36295,function(e,t,n){return e.uniform3uiv(t,h(n,3))}),F(n,36296,function(e,t,n){return e.uniform4uiv(t,h(n,4))}),F(n,35685,function(e,t,n){return e.uniformMatrix2x3fv(t,!1,f(n,6))}),F(n,35686,function(e,t,n){return e.uniformMatrix2x4fv(t,!1,f(n,8))}),F(n,35687,function(e,t,n){return e.uniformMatrix3x2fv(t,!1,f(n,6))}),F(n,35688,function(e,t,n){return e.uniformMatrix3x4fv(t,!1,f(n,12))}),F(n,35689,function(e,t,n){return e.uniformMatrix4x2fv(t,!1,f(n,8))}),F(n,35690,function(e,t,n){return e.uniformMatrix4x3fv(t,!1,f(n,12))}),F(n,35679,function(e,t,n){return e.uniform1i(t,n)}),F(n,35682,function(e,t,n){return e.uniform1i(t,n)}),F(n,36289,function(e,t,n){return e.uniform1i(t,n)}),F(n,36292,function(e,t,n){return e.uniform1i(t,n)}),F(n,36293,function(e,t,n){return e.uniform1i(t,n)}),F(n,36298,function(e,t,n){return e.uniform1i(t,n)}),F(n,36299,function(e,t,n){return e.uniform1i(t,n)}),F(n,36300,function(e,t,n){return e.uniform1i(t,n)}),F(n,36303,function(e,t,n){return e.uniform1i(t,n)}),F(n,36306,function(e,t,n){return e.uniform1i(t,n)}),F(n,36307,function(e,t,n){return e.uniform1i(t,n)}),F(n,36308,function(e,t,n){return e.uniform1i(t,n)}),F(n,36311,function(e,t,n){return e.uniform1i(t,n)}),n),s={},u={},c={};function l(e,t,n,r){var i=e.length;if(i%t&&I.b.warn("Uniform size should be multiples of "+t,e),e instanceof n)return e;var o=r[i];o||(o=new n(i),r[i]=o);for(var a=0;a<i;a++)o[a]=e[a];return o}function f(e,t){return l(e,t,Float32Array,s)}function d(e,t){return l(e,t,Int32Array,u)}function h(e,t){return l(e,t,Uint32Array,c)}function p(e){return Array.isArray(e)?0<e.length&&e.every(function(e){return isFinite(e)}):ArrayBuffer.isView(e)?0<e.length:!!isFinite(e)||(e instanceof i.a||e instanceof r.a&&Boolean(e.texture))}function j(e){var t=e.table,n=e.header,r=e.uniforms,i=e.uniformName,o=e.undefinedOnly,a=r[i],s=null!=a;return(!o||!s)&&(t[i]=F({Type:s?a:"NOT PROVIDED"},n,s?L.i(I.c)(a):"N/A"),!0)}},function(e,t,l){"use strict";var i=l(25),f=l(7),n=l(30),r=l(1),d=l.n(r),a=l(8),o=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var s=[34338,34339,34340,34341,34922,34373,34975,35069,35070],u=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,t));return n.elements=null,n.buffers={},n.locations={},n.names={},n.drawParameters={},n._bound=!1,n._filledLocations={},Object.seal(n),n.initialize(t),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,n["a"]),o(r,[{key:"MAX_ATTRIBUTES",get:function(){return this.gl.getParameter(this.gl.MAX_VERTEX_ATTRIBS)}}],[{key:"isSupported",value:function(e){return l.i(f.b)(e)||e.getExtension("OES_vertex_array_object")}},{key:"getDefaultArray",value:function(e){return e.luma=e.luma||{},e.luma.defaultVertexArray||(e.luma.defaultVertexArray=new r(e,{handle:null})),e.luma.defaultVertexArray}},{key:"getMaxAttributes",value:function(e){return e.getParameter(e.MAX_VERTEX_ATTRIBS)}}]),o(r,[{key:"initialize",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.buffers,n=void 0===t?{}:t,r=e.elements,i=void 0===r?null:r,o=e.locations,a=void 0===o?{}:o;this.setLocations(a),this.setBuffers(n,{clear:!0}),this.setElements(i)}},{key:"setLocations",value:function(e){this.locations=e,this.names={}}},{key:"setElements",value:function(e){return d()(!e||34963===e.target,"elements must be GL.ELEMENT_ARRAY_BUFFER"),this.ext.bindVertexArray(this.handle),this.gl.bindBuffer(34963,e&&e.handle),this.ext.bindVertexArray(null),this.elements=e,this}},{key:"_getBufferAndLayout",value:function(e){var t=void 0,n=void 0;return n=e.handle?(t=e).layout:(t=e.buffer,Object.assign({},t.layout,e.layout||{},e)),{buffer:t,layout:n}}},{key:"setBuffers",value:function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).clear;(void 0===t||t)&&this.clearBindings();var n=this._getLocations(e),r=n.locations,i=n.elements;for(var o in this.ext.bindVertexArray(this.handle),r){var a=r[o];if(a){var s=this._getBufferAndLayout(a),u=s.buffer,c=s.layout;this.setBuffer({location:o,buffer:u,layout:c}),this.setDivisor(o,c.instanced?1:0),this.enable(o)}else this.disable(o)}this.buffers=e,this.ext.bindVertexArray(null),i&&this.setElements(i)}},{key:"enable",value:function(e){var t=this;this.bind(function(){t.gl.enableVertexAttribArray(e)})}},{key:"clearBindings",value:function(){var t=this,e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).disableZero,n=void 0!==e&&e;this.bind(function(){for(var e in t._filledLocations)t._filledLocations[e]&&(0<e||n)&&t.gl.disableVertexAttribArray(e);t._filledLocations={}})}},{key:"disable",value:function(e){var t=this,n=1<arguments.length&&void 0!==arguments[1]&&arguments[1];(0<e||n)&&this.bind(function(){t.gl.disableVertexAttribArray(e)})}},{key:"setDivisor",value:function(e,t){var n=this;this.bind(function(){n.ext.vertexAttribDivisor(e,t)})}},{key:"setBuffer",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},a=e.location,s=e.buffer,t=e.target,u=e.layout,c=this.gl;t=void 0!==t?t:s.target,u=void 0!==u?u:s.layout,d()(t,"setBuffer needs target"),d()(u,"setBuffer called on uninitialized buffer"),this._filledLocations[a]=!0,this.bind(function(){s.bind({target:c.ARRAY_BUFFER});var e=u,t=e.size,n=e.type,r=e.normalized,i=e.stride,o=e.offset;u.integer?(d()(l.i(f.b)(c)),c.vertexAttribIPointer(a,t,n,i,o)):c.vertexAttribPointer(a,t,n,r,i,o)})}},{key:"setGeneric",value:function(e){var t=e.location,n=e.array;switch(this._filledLocations[t]=!0,n.constructor){case Float32Array:this._setGenericFloatArray(t,n);break;case Int32Array:this._setGenericIntArray(t,n);break;case Uint32Array:this._setGenericUintArray(t,n);break;default:this.setGenericValues.apply(this,[t].concat(function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(n)))}}},{key:"_setGenericFloatArray",value:function(e,t){var n=this.gl;switch(t.length){case 1:n.vertexAttrib1fv(e,t);break;case 2:n.vertexAttrib2fv(e,t);break;case 3:n.vertexAttrib3fv(e,t);break;case 4:n.vertexAttrib4fv(e,t);break;default:d()(!1)}}},{key:"_setGenericIntArray",value:function(e,t){var n=this.gl;switch(d()(l.i(f.b)(n)),t.length){case 1:n.vertexAttribI1iv(e,t);break;case 2:n.vertexAttribI2iv(e,t);break;case 3:n.vertexAttribI3iv(e,t);break;case 4:n.vertexAttribI4iv(e,t);break;default:d()(!1)}}},{key:"_setGenericUintArray",value:function(e,t){var n=this.gl;switch(d()(l.i(f.b)(n)),t.length){case 1:n.vertexAttribI1uiv(e,t);break;case 2:n.vertexAttribI2uiv(e,t);break;case 3:n.vertexAttribI3uiv(e,t);break;case 4:n.vertexAttribI4uiv(e,t);break;default:d()(!1)}}},{key:"setGenericValues",value:function(e,t,n,r,i){var o=this.gl;switch(arguments.length-1){case 1:o.vertexAttrib1f(e,t);break;case 2:o.vertexAttrib2f(e,t,n);break;case 3:o.vertexAttrib3f(e,t,n,r);break;case 4:o.vertexAttrib4f(e,t,n,r,i);break;default:d()(!1)}}},{key:"bind",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:this.handle;if("function"!=typeof e)return this.bindVertexArray(e),this;var t=void 0;return this._bound?t=e():(this.ext.bindVertexArray(this.handle),this._bound=!0,t=e(),this.ext.bindVertexArray(null),this._bound=!1),t}},{key:"_deduceDrawParameters",value:function(){var t=!1,e=!1,n=null;return this.elements&&(e=!0,n=this.elements.layout.type),this.buffers.forEach(function(e){0<e.layout.instanced&&(t=!0)}),{isInstanced:t,isIndexed:e,indexType:n}}},{key:"_getLocations",value:function(e){var t=null,n={};for(var r in e){var i=e[r];i&&34963===i.target&&(d()(!t,"Duplicate GL.ELEMENT_ARRAY_BUFFER"),t=i);var o=Number(r);Number.isFinite(o)||(o=this.locations[r]),d()(Number.isFinite(o)),d()(!n[o],"Duplicate attribute for binding point "+o),n[o]=i}return{locations:n,elements:t}}},{key:"_sortBuffersByLocation",value:function(e){var t=null,n=new Array(this._attributeCount).fill(null);for(var r in e){var i=e[r];34963===i.target?(d()(!t,"Duplicate GL.ELEMENT_ARRAY_BUFFER"),t=i):this._warn[r]||(a.b.warn(2,this._print(r)+" not used"),this._warn[r]=!0);var o=Number(r);Number.isFinite(o)||(o=this.locations[r]),n[o]=r,d()(null===n[o],"Duplicate attribute for binding point "+o),n[o]=o}return{locations:n,elements:t}}},{key:"_createHandle",value:function(){return this.ext.createVertexArray()}},{key:"_deleteHandle",value:function(e){return this.ext.deleteVertexArray(e),[this.elements]}},{key:"_getParameter",value:function(e,t){var n=t.location;d()(Number.isFinite(n)),this.ext.bindVertexArray(this.handle);var r=void 0;switch(e){case 34373:r=this.gl.getVertexAttribOffset(n,e);break;default:r=this.ext.getVertexAttrib(n,e)}return this.ext.bindVertexArray(null),r}},{key:"_getData",value:function(){var r=this;return new Array(this.MAX_ATTRIBUTES).fill(0).map(function(e,t){var n={};return s.forEach(function(e){n[l.i(i.c)(e)]=r.getParameter(e,{location:t})}),n})}},{key:"_bind",value:function(e){this.ext.bindVertexArray(e)}},{key:"filledLocations",get:function(){return this._filledLocations}}]),r}();t.a=u},function(e,t,i){"use strict";var n=i(112),o=i(31),r=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var a=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}var n=Math.sqrt;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),r(t,[{key:"len",value:function(){return n(this.lengthSquared())}},{key:"magnitude",value:function(){return n(this.lengthSquared())}},{key:"lengthSquared",value:function(){for(var e=0,t=0;t<this.ELEMENTS;++t)e+=this[t]*this[t];return e}},{key:"distance",value:function(e){return n(this.distanceSquared(e))}},{key:"distanceSquared",value:function(e){for(var t,n=0,r=0;r<this.ELEMENTS;++r)n+=(t=this[r]-e[r])*t;return i.i(o.g)(n)}},{key:"dot",value:function(e){for(var t=0,n=0;n<this.ELEMENTS;++n)t+=this[n]*e[n];return i.i(o.g)(t)}},{key:"normalize",value:function(){var e=this.magnitude();if(0!==e)for(var t=0;t<this.ELEMENTS;++t)this[t]/=e;return this.check()}}]),t}(n.a);t.a=a},function(e,t,n){"use strict";var u=Object.getOwnPropertySymbols,c=Object.prototype.hasOwnProperty,l=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach(function(e){r[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,r,i=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(e),o=1;o<arguments.length;o++){for(var a in n=Object(arguments[o]))c.call(n,a)&&(i[a]=n[a]);if(u){r=u(n);for(var s=0;s<r.length;s++)l.call(n,r[s])&&(i[r[s]]=n[r[s]])}}return i}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a="undefined"!=typeof window&&window.addEventListener,i=new Map,s=function(){return a&&window.__SEER_INITIALIZED__},u=function(e,t){var n=i.get(e),r=Date.now();return!!(n&&r-n<t)||(i.set(e,r),!1)},c=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};if(a&&s()){var n,r=new Set,i=JSON.stringify(t,(n=r,function(e,t){if(!t||"object"!==(void 0===t?"undefined":o(t))||!n.has(t))return n.add(t),Object.prototype.toString.call(t).slice(8,-1).includes("Array")?Array.prototype.slice.call(t,0,20):t}));try{window.postMessage({type:e,payload:i,source:"seer-agent"},"*")}catch(e){if(u("seer-log",2e3))return;console.log(e)}}},l=new Map,r=function(e){if(e&&e.data&&"seer-core"===e.data.source){var t=e.data,n=t.type,r=t.payload,i=l.get(n);i&&i.forEach(function(e){return e(r)})}},f=function(){a&&!window.__SEER_LISTENER__&&(window.addEventListener("message",r),window.__SEER_LISTENER__=!0)};t.default={send:c,throttle:u,isReady:s,list:function(e,t){return c("LIST",{key:e,data:t})},listItem:function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};return c("LIST_ITEM",{key:e,itemKey:t,data:n})},updateItem:function(e,t,n,r){return c("UPDATE_ITEM",{key:e,itemKey:t,path:n,data:r})},multiUpdate:function(e,t,n){return c("MULTI_UPDATE_ITEM",{key:e,itemKey:t,array:n})},deleteItem:function(e,t){return c("DELETE_ITEM",{key:e,itemKey:t})},addLog:function(e,t,n){return c("ADD_LOG",{key:e,itemKey:t,msg:n})},listeners:l,listenFor:function(e,t){if(a){if(!e||!t)throw new Error("Please provide a type and callback");l.has(e)||l.set(e,[]),window.__SEER_LISTENER__||f(),l.get(e).push(t)}},removeListener:function(n){l.forEach(function(e,t){l.set(t,e.filter(function(e){return e!==n}))})},init:f,clean:function(){a&&window.__SEER_LISTENER__&&(window.removeEventListener("message",r),delete window.__SEER_LISTENER__)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),a=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},i=n(13),s=n(12),u=o(n(297)),c=o(n(296)),l=o(n(295));function o(e){return e&&e.__esModule?e:{default:e}}var d=i.experimental.fp64LowPart,f=i.experimental.enable64bitSupport,h=[255,0,255,255],p=function(e){function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,i.Layer),r(o,[{key:"getShaders",value:function(){var e=this.context.shaderCache;return f(this.props)?{vs:c.default,fs:l.default,modules:["project64","lighting","picking"],shaderCache:e}:{vs:u.default,fs:l.default,modules:["lighting","picking"],shaderCache:e}}},{key:"initializeState",value:function(){this.getAttributeManager().addInstanced({instancePositions:{size:4,transition:!0,accessor:["getPosition","getElevation"],update:this.calculateInstancePositions},instanceColors:{size:4,type:s.GL.UNSIGNED_BYTE,transition:!0,accessor:"getColor",update:this.calculateInstanceColors}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.addInstanced({instancePositions64xyLow:{size:2,accessor:"getPosition",update:this.calculateInstancePositions64xyLow}}):r.remove(["instancePositions64xyLow"])}}},{key:"updateState",value:function(e){var t=e.props,n=e.oldProps,r=e.changeFlags;if(a(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"updateState",this).call(this,{props:t,oldProps:n,changeFlags:r}),t.fp64!==n.fp64){var i=this.context.gl;this.setState({model:this._getModel(i)})}this.updateAttribute({props:t,oldProps:n,changeFlags:r}),this.updateUniforms()}},{key:"_getModel",value:function(e){return new s.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:new s.CubeGeometry,isInstanced:!0,shaderCache:this.context.shaderCache}))}},{key:"updateUniforms",value:function(){var e=this.props,t=e.opacity,n=e.extruded,r=e.elevationScale,i=e.coverage,o=e.lightSettings;this.state.model.setUniforms(Object.assign({},{extruded:n,elevationScale:r,opacity:t,coverage:i},o))}},{key:"draw",value:function(e){var t=e.uniforms,n=this.context.viewport.getDistanceScales().pixelsPerMeter;a(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"draw",this).call(this,{uniforms:Object.assign({cellSize:this.props.cellSize*n[0]},t)})}},{key:"calculateInstancePositions",value:function(e){var t=this.props,n=t.data,r=t.getPosition,i=t.getElevation,o=e.value,a=e.size,s=0,u=!0,c=!1,l=void 0;try{for(var f,d=n[Symbol.iterator]();!(u=(f=d.next()).done);u=!0){var h=f.value,p=r(h),v=i(h)||0;o[s+0]=p[0],o[s+1]=p[1],o[s+2]=0,o[s+3]=v,s+=a}}catch(e){c=!0,l=e}finally{try{!u&&d.return&&d.return()}finally{if(c)throw l}}}},{key:"calculateInstancePositions64xyLow",value:function(e){var t=this.props,n=t.data,r=t.getPosition,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=d(f[0]),i[o++]=d(f[1])}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceColors",value:function(e){var t=this.props,n=t.data,r=t.getColor,i=e.value,o=e.size,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r(l.value)||h;i[a+0]=d[0],i[a+1]=d[1],i[a+2]=d[2],i[a+3]=Number.isFinite(d[3])?d[3]:h[3],a+=o}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}}]),o}();(t.default=p).layerName="GridCellLayer",p.defaultProps={cellSize:1e3,coverage:1,elevationScale:1,extruded:!0,fp64:!1,getPosition:function(e){return e.position},getElevation:function(e){return e.elevation},getColor:function(e){return e.color},lightSettings:{lightsPosition:[-122.45,37.65,8e3,-122.45,37.2,1e3],ambientRatio:.4,diffuseRatio:.6,specularRatio:.8,lightsStrength:[1,0,.8,0],numberOfLights:2}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var m=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),a=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},i=n(13),s=n(12),u=o(n(302)),c=o(n(301)),l=o(n(300));function o(e){return e&&e.__esModule?e:{default:e}}var f=i.experimental.log,d=i.experimental.fp64LowPart,h=i.experimental.enable64bitSupport,p=[255,0,255,255],v=function(e){function o(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var t=!1;return e.hexagonVertices||e.radius&&Number.isFinite(e.angle)?e.hexagonVertices&&(!Array.isArray(e.hexagonVertices)||e.hexagonVertices.length<6)&&(f.once(0,"HexagonCellLayer: hexagonVertices needs to be an array of 6 points"),t=!0):(f.once(0,"HexagonCellLayer: Either hexagonVertices or radius and angle are needed to calculate primitive hexagon."),t=!0),t&&(f.once(0,"Now using 1000 meter as default radius, 0 as default angle"),e.radius=1e3,e.angle=0),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,e))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,i.Layer),r(o,[{key:"getShaders",value:function(){return h(this.props)?{vs:c.default,fs:l.default,modules:["project64","lighting","picking"]}:{vs:u.default,fs:l.default,modules:["lighting","picking"]}}},{key:"initializeState",value:function(){this.getAttributeManager().addInstanced({instancePositions:{size:3,transition:!0,accessor:["getCentroid","getElevation"],update:this.calculateInstancePositions},instanceColors:{size:4,type:s.GL.UNSIGNED_BYTE,transition:!0,accessor:"getColor",update:this.calculateInstanceColors}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.addInstanced({instancePositions64xyLow:{size:2,accessor:"getCentroid",update:this.calculateInstancePositions64xyLow}}):r.remove(["instancePositions64xyLow"])}}},{key:"updateState",value:function(e){var t=e.props,n=e.oldProps,r=e.changeFlags;if(a(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"updateState",this).call(this,{props:t,oldProps:n,changeFlags:r}),t.fp64!==n.fp64){var i=this.context.gl;this.setState({model:this._getModel(i)})}this.updateAttribute({props:t,oldProps:n,changeFlags:r}),this.updateUniforms()}},{key:"updateRadiusAngle",value:function(){var e=void 0,t=void 0,n=this.props.hexagonVertices;if(Array.isArray(n)&&6<=n.length){var r=this.props.hexagonVertices,i=r[0],o=r[3],a=this.projectFlat(i),s=this.projectFlat(o),u=a[0]-s[0],c=a[1]-s[1],l=Math.sqrt(u*u+c*c);e=Math.acos(u/l)*-Math.sign(c)+Math.PI/2,t=l/2}else if(this.props.radius&&Number.isFinite(this.props.angle)){var f=this.context.viewport.getDistanceScales().pixelsPerMeter;e=this.props.angle,t=this.props.radius*f[0]}return{angle:e,radius:t}}},{key:"getCylinderGeometry",value:function(e){return new s.CylinderGeometry({radius:e,topRadius:e,bottomRadius:e,topCap:!0,bottomCap:!0,height:1,nradial:6,nvertical:1})}},{key:"updateUniforms",value:function(){var e=this.props,t=e.opacity,n=e.elevationScale,r=e.extruded,i=e.coverage,o=e.lightSettings;this.state.model.setUniforms(Object.assign({},{extruded:r,opacity:t,coverage:i,elevationScale:n},o))}},{key:"_getModel",value:function(e){return new s.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:this.getCylinderGeometry(1),isInstanced:!0,shaderCache:this.context.shaderCache}))}},{key:"draw",value:function(e){var t=e.uniforms;a(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"draw",this).call(this,{uniforms:Object.assign(this.updateRadiusAngle(),t)})}},{key:"calculateInstancePositions",value:function(e){var t=this.props,n=t.data,r=t.getCentroid,i=t.getElevation,o=e.value,a=e.size,s=0,u=!0,c=!1,l=void 0;try{for(var f,d=n[Symbol.iterator]();!(u=(f=d.next()).done);u=!0){var h=f.value,p=r(h),v=m(p,2),g=v[0],y=v[1],_=i(h);o[s+0]=g,o[s+1]=y,o[s+2]=_||0,s+=a}}catch(e){c=!0,l=e}finally{try{!u&&d.return&&d.return()}finally{if(c)throw l}}}},{key:"calculateInstancePositions64xyLow",value:function(e){var t=this.props,n=t.data,r=t.getCentroid,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=d(f[0]),i[o++]=d(f[1])}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceColors",value:function(e){var t=this.props,n=t.data,r=t.getColor,i=e.value,o=e.size,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r(l.value)||p;i[a+0]=d[0],i[a+1]=d[1],i[a+2]=d[2],i[a+3]=Number.isFinite(d[3])?d[3]:p[3],a+=o}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}}]),o}();(t.default=v).layerName="HexagonCellLayer",v.defaultProps={hexagonVertices:null,radius:null,angle:null,coverage:1,elevationScale:1,extruded:!0,fp64:!1,getCentroid:function(e){return e.centroid},getColor:function(e){return e.color},getElevation:function(e){return e.elevation},lightSettings:{lightsPosition:[-122.45,37.75,8e3,-122,38,5e3],ambientRatio:.4,diffuseRatio:.6,specularRatio:.8,lightsStrength:[1.2,0,.8,0],numberOfLights:2}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),a=n(12),s=o(n(324)),u=o(n(323)),c=o(n(322));function o(e){return e&&e.__esModule?e:{default:e}}var d=i.experimental.fp64LowPart,l=i.experimental.enable64bitSupport,h=[0,0,0,255],f={radiusScale:1,radiusMinPixels:0,radiusMaxPixels:Number.MAX_SAFE_INTEGER,strokeWidth:1,outline:!1,fp64:!1,getPosition:function(e){return e.position},getRadius:function(e){return e.radius||1},getColor:function(e){return e.color||h}},p=function(e){function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,i.Layer),r(o,[{key:"getShaders",value:function(e){var t=this.context.shaderCache;return l(this.props)?{vs:u.default,fs:c.default,modules:["project64","picking"],shaderCache:t}:{vs:s.default,fs:c.default,modules:["picking"],shaderCache:t}}},{key:"initializeState",value:function(){this.state.attributeManager.addInstanced({instancePositions:{size:3,transition:!0,accessor:"getPosition",update:this.calculateInstancePositions},instanceRadius:{size:1,transition:!0,accessor:"getRadius",defaultValue:1,update:this.calculateInstanceRadius},instanceColors:{size:4,transition:!0,type:a.GL.UNSIGNED_BYTE,accessor:"getColor",update:this.calculateInstanceColors}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.addInstanced({instancePositions64xyLow:{size:2,accessor:"getPosition",update:this.calculateInstancePositions64xyLow}}):r.remove(["instancePositions64xyLow"])}}},{key:"updateState",value:function(e){var t=e.props,n=e.oldProps,r=e.changeFlags;if(function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0}(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"updateState",this).call(this,{props:t,oldProps:n,changeFlags:r}),t.fp64!==n.fp64){var i=this.context.gl;this.setState({model:this._getModel(i)})}this.updateAttribute({props:t,oldProps:n,changeFlags:r})}},{key:"draw",value:function(e){var t=e.uniforms,n=this.props,r=n.radiusScale,i=n.radiusMinPixels,o=n.radiusMaxPixels,a=n.outline,s=n.strokeWidth;this.state.model.render(Object.assign({},t,{outline:a?1:0,strokeWidth:s,radiusScale:r,radiusMinPixels:i,radiusMaxPixels:o}))}},{key:"_getModel",value:function(e){return new a.Model(e,Object.assign(this.getShaders(),{id:this.props.id,geometry:new a.Geometry({drawMode:a.GL.TRIANGLE_FAN,attributes:{positions:new Float32Array([-1,-1,0,-1,1,0,1,1,0,1,-1,0])}}),isInstanced:!0,shaderCache:this.context.shaderCache}))}},{key:"calculateInstancePositions",value:function(e){var t=this.props,n=t.data,r=t.getPosition,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=f[0],i[o++]=f[1],i[o++]=f[2]||0}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstancePositions64xyLow",value:function(e){var t=this.props,n=t.data,r=t.getPosition,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=d(f[0]),i[o++]=d(f[1])}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceRadius",value:function(e){var t=this.props,n=t.data,r=t.getRadius,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=isNaN(f)?1:f}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceColors",value:function(e){var t=this.props,n=t.data,r=t.getColor,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value)||h;i[o++]=f[0],i[o++]=f[1],i[o++]=f[2],i[o++]=isNaN(f[3])?255:f[3]}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}}]),o}();(t.default=p).layerName="ScatterplotLayer",p.defaultProps=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),a=n(12),d=n(187),h=n(329),p=n(328),s=o(n(332)),u=o(n(331)),c=o(n(330));function o(e){return e&&e.__esModule?e:{default:e}}var l=i.experimental.enable64bitSupport,f=i.experimental.get,v={extruded:!1,wireframe:!1,fp64:!1,elevationScale:1,getPolygon:function(e){return f(e,"polygon")||f(e,"geometry.coordinates")},getElevation:function(e){return f(e,"elevation")||f(e,"properties.height")||0},getColor:function(e){return f(e,"color")||f(e,"properties.color")},lightSettings:{lightsPosition:[-122.45,37.75,8e3,-122,38,5e3],ambientRatio:.05,diffuseRatio:.6,specularRatio:.8,lightsStrength:[2,0,0,0],numberOfLights:2}},g=function(e){function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,i.Layer),r(o,[{key:"getShaders",value:function(){return l(this.props)?{vs:u.default,fs:c.default,modules:["project64","lighting","picking"]}:{vs:s.default,fs:c.default,modules:["lighting","picking"]}}},{key:"initializeState",value:function(){var e=this.context.gl;this.setState({numInstances:0,IndexType:e.getExtension("OES_element_index_uint")?Uint32Array:Uint16Array});this.getAttributeManager().add({indices:{size:1,isIndexed:!0,update:this.calculateIndices,noAlloc:!0},positions:{size:3,accessor:"getElevation",update:this.calculatePositions,noAlloc:!0},normals:{size:3,update:this.calculateNormals,noAlloc:!0},colors:{size:4,type:a.GL.UNSIGNED_BYTE,accessor:"getColor",update:this.calculateColors,noAlloc:!0},pickingColors:{size:3,type:a.GL.UNSIGNED_BYTE,update:this.calculatePickingColors,noAlloc:!0}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.add({positions64xyLow:{size:2,update:this.calculatePositionsLow}}):r.remove(["positions64xyLow"])}}},{key:"draw",value:function(e){var t=e.uniforms,n=this.props,r=n.extruded,i=n.lightSettings,o=n.elevationScale;this.state.model.render(Object.assign({},t,{extruded:r?1:0,elevationScale:o},i))}},{key:"updateState",value:function(e){var t=e.props,n=e.oldProps,r=e.changeFlags;if(function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0}(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"updateState",this).call(this,{props:t,oldProps:n,changeFlags:r}),this.updateGeometry({props:t,oldProps:n,changeFlags:r})){var i=this.context.gl;this.setState({model:this._getModel(i)})}this.updateAttribute({props:t,oldProps:n,changeFlags:r})}},{key:"updateGeometry",value:function(e){var t=this,n=e.props,r=e.oldProps,i=e.changeFlags,o=n.extruded!==r.extruded||n.wireframe!==r.wireframe||n.fp64!==r.fp64||i.updateTriggersChanged&&(i.updateTriggersChanged.all||i.updateTriggersChanged.getPolygon),a=i.updateTriggersChanged&&(0,d.compareProps)({oldProps:r.updateTriggers.getElevation||{},newProps:n.updateTriggers.getElevation||{},triggerName:"getElevation"});if(i.dataChanged||o||a){var s=n.getPolygon,u=n.extruded,c=n.wireframe,l=n.getElevation,f=n.data.map(s);this.setState({polygonTesselator:u?new p.PolygonTesselatorExtruded({polygons:f,wireframe:c,getHeight:function(e){return l(t.props.data[e])},fp64:this.props.fp64}):new h.PolygonTesselator({polygons:f,fp64:this.props.fp64})}),this.state.attributeManager.invalidateAll()}return o}},{key:"_getModel",value:function(e){return new a.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:new a.Geometry({drawMode:this.props.wireframe?a.GL.LINES:a.GL.TRIANGLES,attributes:{}}),vertexCount:0,isIndexed:!0,shaderCache:this.context.shaderCache}))}},{key:"calculateIndices",value:function(e){e.value=this.state.polygonTesselator.indices(),e.target=a.GL.ELEMENT_ARRAY_BUFFER,this.state.model.setVertexCount(e.value.length/e.size)}},{key:"calculatePositions",value:function(e){e.value=this.state.polygonTesselator.positions().positions}},{key:"calculatePositionsLow",value:function(e){e.value=this.state.polygonTesselator.positions().positions64xyLow}},{key:"calculateNormals",value:function(e){e.value=this.state.polygonTesselator.normals()}},{key:"calculateColors",value:function(e){var t=this;e.value=this.state.polygonTesselator.colors({getColor:function(e){return t.props.getColor(t.props.data[e])}})}},{key:"calculatePickingColors",value:function(e){e.value=this.state.polygonTesselator.pickingColors()}}]),o}();(t.default=g).layerName="SolidPolygonLayer",g.defaultProps=v},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=a(n(121)),o=a(n(82));function a(e){return e&&e.__esModule?e:{default:e}}var s=function(e){function t(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,o.default,e))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),r(t,[{key:"_onPan",value:function(e){return this.isFunctionKeyPressed(e)?this._onPanRotate(e):this._onPanMove(e)}}]),t}();t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),E=i(n(85)),A=i(n(1));function i(e){return e&&e.__esModule?e:{default:e}}var T={lookAt:[0,0,0],rotationX:0,rotationOrbit:0,fov:50,near:1,far:100,translationX:0,translationY:0,zoom:1},x={minZoom:0,maxZoom:1/0};function w(e,t,n){return e<t?t:n<e?n:e}function O(e,t){return Number.isFinite(e)?e:t}var o=function(){function S(e){var t=e.width,n=e.height,r=e.distance,i=e.rotationX,o=e.rotationOrbit,a=e.orbitAxis,s=e.bounds,u=e.lookAt,c=e.fov,l=e.near,f=e.far,d=e.translationX,h=e.translationY,p=e.zoom,v=e.minZoom,g=e.maxZoom,y=e.startPanViewport,_=e.startPanPos,m=e.isPanning,b=e.startRotateViewport,E=e.isRotating,w=e.startZoomViewport,P=e.startZoomPos;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,S),(0,A.default)(Number.isFinite(t),"`width` must be supplied"),(0,A.default)(Number.isFinite(n),"`height` must be supplied"),(0,A.default)(Number.isFinite(r),"`distance` must be supplied"),this._viewportProps=this._applyConstraints({width:t,height:n,distance:r,rotationX:O(i,T.rotationX),rotationOrbit:O(o,T.rotationOrbit),orbitAxis:a,bounds:s,lookAt:u||T.lookAt,fov:O(c,T.fov),near:O(l,T.near),far:O(f,T.far),translationX:O(d,T.translationX),translationY:O(h,T.translationY),zoom:O(p,T.zoom),minZoom:O(v,x.minZoom),maxZoom:O(g,x.maxZoom)}),this._interactiveState={startPanViewport:y,startPanPos:_,isPanning:m,startRotateViewport:b,isRotating:E,startZoomViewport:w,startZoomPos:P}}return r(S,[{key:"getViewportProps",value:function(){return this._viewportProps}},{key:"getInteractiveState",value:function(){return this._interactiveState}},{key:"panStart",value:function(e){var t=e.pos,n=new E.default(this._viewportProps);return this._getUpdatedOrbitState({startPanPos:t,startPanViewport:n})}},{key:"pan",value:function(e){var t=e.pos,n=e.startPos;if(this._interactiveState.isRotating)return this._getUpdatedOrbitState();var r=this._interactiveState.startPanPos||n;(0,A.default)(r,"`startPanPos` props is required");var i=this._interactiveState.startPanViewport||new E.default(this._viewportProps),o=t[0]-r[0],a=t[1]-r[1],s=i.project(i.lookAt),u=i.unproject([s[0]-o,s[1]-a,s[2]]);return this._getUpdatedOrbitState({lookAt:u,isPanning:!0})}},{key:"panEnd",value:function(){return this._getUpdatedOrbitState({startPanViewport:null,startPanPos:null,isPanning:null})}},{key:"rotateStart",value:function(e){e.pos;var t=new E.default(this._viewportProps);return this._getUpdatedOrbitState({startRotateViewport:t})}},{key:"rotate",value:function(e){var t=e.deltaScaleX,n=e.deltaScaleY;if(this._interactiveState.isPanning)return this._getUpdatedOrbitState();var r=this._interactiveState.startRotateViewport||{},i=r.rotationX,o=r.rotationOrbit;i=O(i,this._viewportProps.rotationX),o=O(o,this._viewportProps.rotationOrbit);var a=w(i-180*n,-89.999,89.999),s=(o-180*t)%360;return this._getUpdatedOrbitState({rotationX:a,rotationOrbit:s,isRotating:!0})}},{key:"rotateEnd",value:function(){return this._getUpdatedOrbitState({startRotateViewport:null,isRotating:null})}},{key:"zoomStart",value:function(e){var t=e.pos,n=new E.default(this._viewportProps);return this._getUpdatedOrbitState({startZoomViewport:n,startZoomPos:t})}},{key:"zoom",value:function(e){var t=e.pos,n=e.startPos,r=e.scale,i=this._viewportProps,o=i.zoom,a=i.minZoom,s=i.maxZoom,u=i.width,c=i.height,l=this._interactiveState.startZoomPos||n||t,f=this._interactiveState.startZoomViewport||new E.default(this._viewportProps),d=w(o*r,a,s),h=t[0]-l[0],p=t[1]-l[1],v=l[0]-u/2,g=c/2-l[1],y=f.project(f.lookAt),_=y[0]-v+v*d/o+h,m=y[1]+g-g*d/o-p,b=f.unproject([_,m,y[2]]);return this._getUpdatedOrbitState({lookAt:b,zoom:d})}},{key:"zoomEnd",value:function(){return this._getUpdatedOrbitState({startZoomPos:null})}},{key:"_getUpdatedOrbitState",value:function(e){return new S(Object.assign({},this._viewportProps,this._interactiveState,e))}},{key:"_applyConstraints",value:function(e){var t=e.maxZoom,n=e.minZoom,r=e.zoom;return e.zoom=t<r?t:r,e.zoom=r<n?n:r,e}}]),S}();t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),a=n(16),o=n(1),s=(r=o)&&r.__esModule?r:{default:r};var u=a.experimental.SphericalCoordinates,c={position:[0,0,0],lookAt:[0,0,0],up:[0,0,1],rotationX:0,rotationY:0,fov:50,near:1,far:100},l=function(){function o(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var t=e.width,n=e.height,r=e.position,i=void 0===r?c.position:r;(0,s.default)(Number.isFinite(t),"`width` must be supplied"),(0,s.default)(Number.isFinite(n),"`height` must be supplied"),this._viewportProps=this._applyConstraints(Object.assign({},e,{position:new a.Vector3(i)}))}return i(o,[{key:"getViewportProps",value:function(){return this._viewportProps}},{key:"getDirection",value:function(){return new u({bearing:this._viewportProps.bearing,pitch:this._viewportProps.pitch}).toVector3().normalize()}},{key:"getDirectionFromBearing",value:function(e){return new u({bearing:e,pitch:90}).toVector3().normalize()}},{key:"_applyConstraints",value:function(e){return e}}]),o}();t.default=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var r=function(){function r(e){var t=e.gl,n=e.layerManager;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),this.gl=t,this.layerManager=n,this._effects=[]}return i(r,[{key:"addEffect",value:function(e){this._effects.push(e),this._sortEffects(),e.initialize({gl:this.gl,layerManager:this.layerManager})}},{key:"removeEffect",value:function(e){var t=this._effects.indexOf(e);return 0<=t&&(e.finalize({gl:this.gl,layerManager:this.layerManager}),this._effects.splice(t,1),!0)}},{key:"preDraw",value:function(){var e=!0,t=!1,n=void 0;try{for(var r,i=this._effects[Symbol.iterator]();!(e=(r=i.next()).done);e=!0){var o=r.value;o.needsRedraw&&o.preDraw({gl:this.gl,layerManager:this.layerManager})}}catch(e){t=!0,n=e}finally{try{!e&&i.return&&i.return()}finally{if(t)throw n}}}},{key:"draw",value:function(){var e=!0,t=!1,n=void 0;try{for(var r,i=this._effects[Symbol.iterator]();!(e=(r=i.next()).done);e=!0){var o=r.value;o.needsRedraw&&o.draw({gl:this.gl,layerManager:this.layerManager})}}catch(e){t=!0,n=e}finally{try{!e&&i.return&&i.return()}finally{if(t)throw n}}}},{key:"_sortEffects",value:function(){this._effects.sort(function(e,t){return e.priority>t.priority?-1:e.priority<t.priority?1:e.count-t.count})}}]),r}();t.default=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();t.glArrayFromType=h;var o=r(n(185)),f=r(n(17)),d=n(12),y=r(n(1)),a=r(n(335));function r(e){return e&&e.__esModule?e:{default:e}}function s(){}function h(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).clamped,n=void 0===t||t;switch(e){case d.GL.FLOAT:return Float32Array;case d.GL.UNSIGNED_SHORT:case d.GL.UNSIGNED_SHORT_5_6_5:case d.GL.UNSIGNED_SHORT_4_4_4_4:case d.GL.UNSIGNED_SHORT_5_5_5_1:return Uint16Array;case d.GL.UNSIGNED_INT:return Uint32Array;case d.GL.UNSIGNED_BYTE:return n?Uint8ClampedArray:Uint8Array;case d.GL.BYTE:return Int8Array;case d.GL.SHORT:return Int16Array;case d.GL.INT:return Int32Array;default:throw new Error("Failed to deduce type from array")}}var p={savedMessages:null,timeStart:null,onLog:function(e){var t=e.level,n=e.message;f.default.log(t,n)},onUpdateStart:function(e){e.level,e.id,e.numInstances;p.savedMessages=[],p.timeStart=new Date},onUpdate:function(e){e.level;var t=e.message;p.savedMessages&&p.savedMessages.push(t)},onUpdateEnd:function(e){var t=e.level,n=e.id,r=e.numInstances,i=Math.round(new Date-p.timeStart)+"ms";f.default.group(t,"Updated attributes for "+r+" instances in "+n+" in "+i,{collapsed:!0});var o=!0,a=!1,s=void 0;try{for(var u,c=p.savedMessages[Symbol.iterator]();!(o=(u=c.next()).done);o=!0){var l=u.value;f.default.log(t,l)}}catch(e){a=!0,s=e}finally{try{!o&&c.return&&c.return()}finally{if(a)throw s}}f.default.groupEnd(t,"Updated attributes for "+r+" instances in "+n+" in "+i),p.savedMessages=null}},u=function(){function r(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).id,n=void 0===t?"attribute-manager":t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),this.id=n,this.gl=e,this.attributes={},this.updateTriggers={},this.accessors={},this.allocedInstances=-1,this.needsRedraw=!0,this.userData={},this.stats=new o.default({id:"attr"}),this.attributeTransitionManger=new a.default(e,{id:n+"-transitions"}),Object.seal(this)}return i(r,null,[{key:"setDefaultLogFunctions",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.onLog,n=e.onUpdateStart,r=e.onUpdate,i=e.onUpdateEnd;void 0!==t&&(p.onLog=t||s),void 0!==n&&(p.onUpdateStart=n||s),void 0!==r&&(p.onUpdate=r||s),void 0!==i&&(p.onUpdateEnd=i||s)}}]),i(r,[{key:"add",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};this._add(e,t)}},{key:"remove",value:function(e){for(var t=0;t<e.length;t++){var n=e[t];void 0!==this.attributes[n]&&delete this.attributes[n]}}},{key:"invalidate",value:function(e){var t=this._invalidateTrigger(e);p.onLog({level:2,message:"invalidated attributes "+t+" ("+e+") for "+this.id,id:this.identifier})}},{key:"invalidateAll",value:function(){for(var e in this.attributes)this.attributes[e].needsUpdate=!0;p.onLog({level:2,message:"invalidated all attributes for "+this.id,id:this.identifier})}},{key:"_invalidateTrigger",value:function(e){var n=this.attributes,t=this.updateTriggers[e];if(t)t.forEach(function(e){var t=n[e];t&&(t.needsUpdate=!0)});else{var r="invalidating non-existent trigger "+e+" for "+this.id+"\n";r+="Valid triggers: "+Object.keys(n).join(", "),f.default.warn(r,t)}return t}},{key:"update",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.data,n=e.numInstances,r=e.transitions,i=e.props,o=void 0===i?{}:i,a=e.buffers,s=void 0===a?{}:a,u=e.context,c=void 0===u?{}:u,l=e.ignoreUnknownAttributes,f=void 0!==l&&l;this._checkExternalBuffers({buffers:s,ignoreUnknownAttributes:f}),this._setExternalBuffers(s),this._analyzeBuffers({numInstances:n})&&(p.onUpdateStart({level:1,id:this.id,numInstances:n}),this.stats.timeStart(),this._updateBuffers({numInstances:n,data:t,props:o,context:c}),this.stats.timeEnd(),p.onUpdateEnd({level:1,id:this.id,numInstances:n})),this.attributeTransitionManger.update(this.attributes,r)}},{key:"getAttributes",value:function(){return this.attributes}},{key:"getChangedAttributes",value:function(e){var t=e.transition,n=void 0!==t&&t,r=e.clearChangedFlags,i=void 0!==r&&r,o=this.attributes,a=this.attributeTransitionManger;if(n)return a.getAttributes();var s={};for(var u in o){var c=o[u];c.changed&&(c.changed=c.changed&&!i,a.hasAttribute(u)||(s[u]=c))}return s}},{key:"getNeedsRedraw",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).clearRedrawFlags,t=void 0!==e&&e,n=this.needsRedraw;return this.needsRedraw=this.needsRedraw&&!t,n&&this.id}},{key:"setNeedsRedraw",value:function(){!(0<arguments.length&&void 0!==arguments[0])||arguments[0];return this.needsRedraw=!0,this}},{key:"addInstanced",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};this._add(e,t,{instanced:1})}},{key:"getAccessors",value:function(){return this.updateTriggers}},{key:"_add",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},r={};for(var i in e){i in t&&(e[i]=Object.assign({},e[i],t[i]));var o=e[i],a=o.isGeneric||!1,s=o.isIndexed||o.elements,u=o.elements?1:o.size,c=o.value||null,l=Object.assign({target:void 0,userData:{}},o,{isExternalBuffer:!1,needsAlloc:!1,needsUpdate:!1,changed:!1,isGeneric:a,isIndexed:s,size:u,value:c},n);Object.seal(l),this._validateAttributeDefinition(i,l),r[i]=l}Object.assign(this.attributes,r),this._mapUpdateTriggersToAttributes()}},{key:"_mapUpdateTriggersToAttributes",value:function(){var n=this,r={},e=function(t){var e=n.attributes[t].accessor;r[t]=[t],"string"==typeof e&&(e=[e]),Array.isArray(e)&&e.forEach(function(e){r[e]||(r[e]=[]),r[e].push(t)})};for(var t in this.attributes)e(t);this.updateTriggers=r}},{key:"_validateAttributeDefinition",value:function(e,t){if((0,y.default)(1<=t.size&&t.size<=4,"Attribute definition for "+e+" invalid size"),!(t.noAlloc||"function"==typeof t.update||"string"==typeof t.accessor))throw new Error("Attribute "+e+" missing update or accessor")}},{key:"_checkExternalBuffers",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.buffers,n=void 0===t?{}:t,r=e.ignoreUnknownAttributes,i=void 0!==r&&r,o=this.attributes;for(var a in n){if(!o[a]&&!i)throw new Error("Unknown attribute prop "+a)}}},{key:"_setExternalBuffers",value:function(e){var t=this.attributes,n=this.numInstances;for(var r in t){var i=t[r],o=e[r];if(i.isExternalBuffer=!1,o){var a=h(i.type||d.GL.FLOAT);if(!(o instanceof a))throw new Error("Attribute "+r+" must be of type "+a.name);if(i.auto&&o.length<=n*i.size)throw new Error("Attribute prop array must match length and size");i.isExternalBuffer=!0,i.needsUpdate=!1,i.value!==o&&(i.value=o,i.changed=!0,this.needsRedraw=!0)}}}},{key:"_analyzeBuffers",value:function(e){var t=e.numInstances,n=this.attributes;(0,y.default)(void 0!==t,"numInstances not defined");var r=!1;for(var i in n){var o=n[i];if(!o.isExternalBuffer)(null===o.value||o.value.length/o.size<t)&&(o.update||o.accessor)&&(r=o.needsAlloc=!0),o.needsUpdate&&(r=!0)}return r}},{key:"_updateBuffers",value:function(e){var t=e.numInstances,n=e.data,r=e.props,i=e.context,o=this.attributes,a=Math.max(t,1);for(var s in o){var u=o[s];if(u.needsAlloc){var c=h(u.type||d.GL.FLOAT);u.value=new c(u.size*a),p.onUpdate({level:2,message:s+" allocated "+a,id:this.id}),u.needsAlloc=!1,u.needsUpdate=!0}}for(var l in o){var f=o[l];f.needsUpdate&&this._updateBuffer({attribute:f,attributeName:l,numInstances:t,data:n,props:r,context:i})}this.allocedInstances=a}},{key:"_updateBuffer",value:function(e){var t=e.attribute,n=e.attributeName,r=e.numInstances,i=e.data,o=e.props,a=e.context,s=t.update,u=t.accessor,c=new Date;s?(s.call(a,t,{data:i,props:o,numInstances:r}),this._checkAttributeArray(t,n)):u?(this._updateBufferViaStandardAccessor({attribute:t,data:i,props:o}),this._checkAttributeArray(t,n)):p.onUpdate({level:2,message:n+" missing update function",id:this.id});var l=Math.round(new Date-c)+"ms";p.onUpdate({level:2,message:n+" updated "+r+" "+l,id:this.id}),t.needsUpdate=!1,t.changed=!0,this.needsRedraw=!0}},{key:"_updateBufferViaStandardAccessor",value:function(e){var t=e.attribute,n=e.data,r=e.props,i=t.accessor,o=t.value,a=t.size,s=r[i];(0,y.default)("function"==typeof s,'accessor "'+i+'" is not a function');var u=t.defaultValue,c=void 0===u?[0,0,0,0]:u;c=Array.isArray(c)?c:[c];var l=0,f=!0,d=!1,h=void 0;try{for(var p,v=n[Symbol.iterator]();!(f=(p=v.next()).done);f=!0){var g=s(p.value);switch(g=Array.isArray(g)?g:[g],a){case 4:o[l+3]=Number.isFinite(g[3])?g[3]:c[3];case 3:o[l+2]=Number.isFinite(g[2])?g[2]:c[2];case 2:o[l+1]=Number.isFinite(g[1])?g[1]:c[1];case 1:o[l+0]=Number.isFinite(g[0])?g[0]:c[0]}l+=a}}catch(e){d=!0,h=e}finally{try{!f&&v.return&&v.return()}finally{if(d)throw h}}}},{key:"_checkAttributeArray",value:function(e,t){var n=e.value;if(n&&4<=n.length&&!(Number.isFinite(n[0])&&Number.isFinite(n[1])&&Number.isFinite(n[2])&&Number.isFinite(n[3])))throw new Error("Illegal attribute generated for "+t)}},{key:"updateTransition",value:function(){var e=this.attributeTransitionManger.setCurrentTime(Date.now());return this.needsRedraw=this.needsRedraw||e,e}}]),r}();t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPixelRatio=void 0,t.drawLayers=g,t.drawPickingBuffer=function(e,t){var n=t.layers,r=t.viewports,i=t.onViewportActive,o=t.useDevicePixels,a=t.pickingFBO,s=t.deviceRect,u=s.x,c=s.y,l=s.width,f=s.height,d=t.layerFilter,h=void 0===d?null:d,p=t.redrawReason,v=void 0===p?"":p;return(0,k.withParameters)(e,{framebuffer:a,scissorTest:!0,scissor:[u,c,l,f],clearColor:[0,0,0,0]},function(){g(e,{layers:n,viewports:r,onViewportActive:i,useDevicePixels:o,drawPickingColors:!0,layerFilter:h,pass:"picking",redrawReason:v,parameters:{blend:!0,blendFunc:[e.ONE,e.ZERO,e.CONSTANT_ALPHA,e.ZERO],blendEquation:e.FUNC_ADD,blendColor:[0,0,0,0]}})})};var k=n(12),M=i(n(17)),r=i(n(1));function i(e){return e&&e.__esModule?e:{default:e}}var L=2,I=0,N=t.getPixelRatio=function(e){var t=e.useDevicePixels;return(0,r.default)("boolean"==typeof t,"Invalid useDevicePixels"),t&&"undefined"!=typeof window?window.devicePixelRatio:1},F=function(e,t){var n=t.viewport,r=t.pixelRatio,i=e.canvas?e.canvas.clientHeight:100,o=n;return[o.x*r,(i-o.y-o.height)*r,o.width*r,o.height*r]};function g(E,e){var w=e.layers,t=e.viewports,P=e.onViewportActive,S=e.useDevicePixels,n=e.drawPickingColors,A=void 0!==n&&n,r=e.deviceRect,T=void 0===r?null:r,i=e.parameters,x=void 0===i?{}:i,o=e.layerFilter,O=void 0===o?null:o,a=e.pass,R=void 0===a?"draw":a,s=e.redrawReason,C=void 0===s?"":s;!function(e,t){t.useDevicePixels;var n=e.drawingBufferWidth,r=e.drawingBufferHeight;(0,k.withParameters)(e,{viewport:[0,0,n,r]},function(){e.clear(k.GL.COLOR_BUFFER_BIT|k.GL.DEPTH_BUFFER_BIT)})}(E,{useDevicePixels:S}),t.forEach(function(e,t){var n,r,i,o,a,s,u,c,l,f,d,h,p,v,g,y,_,m,b=(n=e).viewport?n.viewport:n;P(b),r=E,o=(i={layers:w,viewport:b,useDevicePixels:S,drawPickingColors:A,deviceRect:T,parameters:x,layerFilter:O,pass:R,redrawReason:C}).layers,a=i.viewport,s=i.useDevicePixels,u=i.drawPickingColors,c=void 0!==u&&u,i.deviceRect,l=i.parameters,f=void 0===l?{}:l,d=i.layerFilter,h=i.pass,p=void 0===h?"draw":h,v=i.redrawReason,g=void 0===v?"":v,y=N({useDevicePixels:s}),_=F(r,{viewport:a,pixelRatio:y}),m={totalCount:o.length,visibleCount:0,compositeCount:0,pickableCount:0},(0,k.setParameters)(r,f||{}),o.forEach(function(e,t){var n=e.props.visible;c&&(n=n&&e.props.pickable),n&&d&&(n=d({layer:e,viewport:a,isPicking:c})),n&&e.props.pickable&&m.pickableCount++,e.isComposite&&m.compositeCount++,n&&(e.isComposite||m.visibleCount++,function(e){e.gl;var t=e.layer,n=e.layerIndex,r=e.drawPickingColors,i=e.glViewport,o=e.parameters,a=Object.assign({},t.props,{viewport:t.context.viewport,pickingActive:r?1:0}),s=Object.assign({},t.context.uniforms,{layerIndex:n}),u=Object.assign({},t.props.parameters||{},o);Object.assign(u,{viewport:i}),r?Object.assign(u,{blendColor:[0,0,0,(n+1)/255]}):Object.assign(a,function(e){if(Number.isInteger(e.props.highlightedObjectIndex)){var t=0<=e.props.highlightedObjectIndex?e.encodePickingColor(e.props.highlightedObjectIndex):null;return{pickingSelectedColor:t}}return null}(t)),t.drawLayer({moduleParameters:a,uniforms:s,parameters:u})}({gl:r,layer:e,layerIndex:t,drawPickingColors:c,glViewport:_,parameters:f}))}),I++,function(e){var t=e.renderStats,n=e.pass,r=e.redrawReason;if(M.default.priority>=L){var i=t.totalCount,o=t.visibleCount,a=t.compositeCount,s=t.pickableCount,u=i-a,c=u-o,l="";l+="RENDER #"+I+" "+o+" (of "+i+" layers) to "+n+" because "+r+" ",M.default.priority>L&&(l+="("+c+" hidden, "+a+" composite "+s+" unpickable)"),M.default.log(L,l)}}({renderStats:m,pass:p,redrawReason:g})})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),c=g(n(1)),o=n(12),a=g(n(173)),i=g(n(123)),l=n(183),d=n(339),s=n(70),u=g(n(42)),f=g(n(86)),h=g(n(17)),p=n(126),v=n(124);function g(e){return e&&e.__esModule?e:{default:e}}var y={uniforms:{},viewports:[],viewport:null,layerFilter:null,viewportChanged:!0,pickingFBO:null,useDevicePixels:!0,lastPickedInfo:{index:-1,layerId:null}},_=function(e){return e instanceof i.default?""+e:e?"invalid":"null"},m=function(){function i(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.eventManager,r=t.isGeographicCoordinateSystem;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),this.lastRenderedLayers=[],this.prevLayers=[],this.layers=[],this.oldContext={},this.context=Object.assign({},y,{gl:e,shaderCache:new o.ShaderCache({gl:e,_cachePrograms:!0})}),this.width=100,this.height=100,this.viewDescriptors=[],this.viewDescriptorsChanged=!0,this.viewports=[],this._needsRedraw="Initial render",this._pickingRadius=0,this._eventManager=null,this._onLayerClick=null,this._onLayerHover=null,this._onClick=this._onClick.bind(this),this._onPointerMove=this._onPointerMove.bind(this),this._onPointerLeave=this._onPointerLeave.bind(this),this._pickAndCallback=this._pickAndCallback.bind(this),this._initSeer=this._initSeer.bind(this),this._editSeer=this._editSeer.bind(this),(0,v.seerInitListener)(this._initSeer),(0,v.layerEditListener)(this._editSeer),Object.seal(this),n&&this._initEventHandling(n),this.setViewports([new f.default({width:1,height:1,latitude:0,longitude:0,zoom:1,isGeographicCoordinateSystem:r})])}return r(i,[{key:"finalize",value:function(){a.default.removeListener(this._initSeer),a.default.removeListener(this._editSeer)}},{key:"needsRedraw",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).clearRedrawFlags,t=void 0===e||e;return this._checkIfNeedsRedraw(t)}},{key:"setNeedsRedraw",value:function(e){this._needsRedraw=this._needsRedraw||e}},{key:"getLayers",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).layerIds,n=void 0===e?null:e;return n?this.layers.filter(function(t){return n.find(function(e){return 0===t.id.indexOf(e)})}):this.layers}},{key:"getViewports",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.width,n=e.height;return(t!==this.width||n!==this.height||this.viewDescriptorsChanged)&&(this._rebuildViewportsFromViews({viewDescriptors:this.viewDescriptors,width:t,height:n}),this.width=t,this.height=n),this.viewports}},{key:"setParameters",value:function(e){"eventManager"in e&&this._initEventHandling(e.eventManager),("pickingRadius"in e||"onLayerClick"in e||"onLayerHover"in e)&&this._setEventHandlingParameters(e),"layers"in e&&this.setLayers(e.layers),"viewports"in e&&this.setViewports(e.viewports),"layerFilter"in e&&(this.context.layerFilter=e.layerFilter,this.context.layerFilter!==e.layerFilter&&this.setNeedsRedraw("layerFilter changed")),"drawPickingColors"in e&&this.context.drawPickingColors!==e.drawPickingColors&&this.setNeedsRedraw("drawPickingColors changed"),Object.assign(this.context,e)}},{key:"setViewports",value:function(e){var t=(0,p.flatten)(e,{filter:Boolean}).map(function(e){return e instanceof u.default?{viewport:e}:e});this.viewDescriptorsChanged=this.viewDescriptorsChanged||this._diffViews(t,this.viewDescriptors),this.viewDescriptorsChanged&&(this.viewDescriptors=t,this._rebuildViewportsFromViews({viewDescriptors:this.viewDescriptors}),this.viewDescriptorsChanged=!1)}},{key:"setLayers",value:function(e){if((0,c.default)(this.context.viewport,"LayerManager.updateLayers: viewport not set"),e===this.lastRenderedLayers)return h.default.log(3,"Ignoring layer update due to layer array not changed"),this;this.lastRenderedLayers=e,e=(0,p.flatten)(e,{filter:Boolean});var t=!0,n=!1,r=void 0;try{for(var i,o=e[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){i.value.context=this.context}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}this.prevLayers=this.layers;var a=this._updateLayers({oldLayers:this.prevLayers,newLayers:e}),s=a.error,u=a.generatedLayers;if(this.layers=u,s)throw s;return this}},{key:"drawLayers",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.pass,n=void 0===t?"render to screen":t,r=e.redrawReason,i=void 0===r?"unknown reason":r,o=this.context,a=o.gl,s=o.useDevicePixels,u=o.drawPickingColors;(0,l.drawLayers)(a,{layers:this.layers,viewports:this.getViewports(),onViewportActive:this._activateViewport.bind(this),useDevicePixels:s,drawPickingColors:u,pass:n,layerFilter:this.context.layerFilter,redrawReason:i})}},{key:"pickObject",value:function(e){var t=e.x,n=e.y,r=e.mode,i=e.radius,o=void 0===i?0:i,a=e.layerIds,s=e.layerFilter,u=this.context,c=u.gl,l=u.useDevicePixels,f=this.getLayers({layerIds:a});return(0,d.pickObject)(c,{x:t,y:n,radius:o,layers:f,mode:r,layerFilter:s,viewports:this.getViewports(),onViewportActive:this._activateViewport.bind(this),pickingFBO:this._getPickingBuffer(),lastPickedInfo:this.context.lastPickedInfo,useDevicePixels:l})}},{key:"pickObjects",value:function(e){var t=e.x,n=e.y,r=e.width,i=e.height,o=e.layerIds,a=e.layerFilter,s=this.context,u=s.gl,c=s.useDevicePixels,l=this.getLayers({layerIds:o});return(0,d.pickVisibleObjects)(u,{x:t,y:n,width:r,height:i,layers:l,layerFilter:a,mode:"pickObjects",viewport:this.context.viewport,viewports:this.getViewports(),onViewportActive:this._activateViewport.bind(this),pickingFBO:this._getPickingBuffer(),useDevicePixels:c})}},{key:"updateLayers",value:function(e){var t=e.newLayers;h.default.deprecated("updateLayers","setLayers"),this.setLayers(t)}},{key:"setViewport",value:function(e){return h.default.deprecated("setViewport","setViewports"),this.setViewports([e]),this}},{key:"_checkIfNeedsRedraw",value:function(e){var t=this._needsRedraw;e&&(this._needsRedraw=!1);var n=!0,r=!1,i=void 0;try{for(var o,a=this.layers[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var s=o.value.getNeedsRedraw({clearRedrawFlags:e});t=t||s}}catch(e){r=!0,i=e}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}return t}},{key:"_rebuildViewportsFromViews",value:function(e){var t=this,n=e.viewDescriptors,r=e.width,i=e.height,o=n.map(function(e){return e.viewport instanceof u.default?e.viewport:t._makeViewportFromViewDescriptor({viewDescriptor:e,width:r,height:i})});this.setNeedsRedraw("Viewport(s) changed");var a=o[0];(0,c.default)(a instanceof u.default,"Invalid viewport"),this.context.viewports=o,this._activateViewport(a),this.viewports=o,this.viewDescriptorsChanged=!1}},{key:"_makeViewportFromViewDescriptor",value:function(e){var t=e.viewDescriptor,n=(e.width,e.height,t.type),r=t.viewState,i=this._getViewDimensions({viewDescriptor:t});return new n(Object.assign({},t,i,r))}},{key:"_diffViews",value:function(n,r){var i=this;return n.length!==r.length||n.some(function(e,t){return i._diffView(n[t],r[t])})}},{key:"_diffView",value:function(e,t){return e.viewport?!t.viewport||!e.viewport.equals(t.viewport):e!==t}},{key:"_getViewDimensions",value:function(e){var t=e.viewDescriptor,n=(e.width,e.height,function(e,t){return e});return{x:n(t.x),y:n(t.y),width:n(t.width),height:n(t.height)}}},{key:"_initEventHandling",value:function(e){this._eventManager=e,this._eventManager.on({click:this._onClick,pointermove:this._onPointerMove,pointerleave:this._onPointerLeave})}},{key:"_setEventHandlingParameters",value:function(e){var t=e.pickingRadius,n=e.onLayerClick,r=e.onLayerHover;isNaN(t)||(this._pickingRadius=t),void 0!==n&&(this._onLayerClick=n),void 0!==r&&(this._onLayerHover=r),this._validateEventHandling()}},{key:"_activateViewport",value:function(e){if(Object.assign(this.oldContext,this.context),this.context.viewport=e,this.context.viewportChanged=!0,this.context.uniforms={},(0,h.default)(4,e),this.context.viewportChanged){var t=!0,n=!1,r=void 0;try{for(var i,o=this.layers[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){var a=i.value;a.setChangeFlags({viewportChanged:"Viewport changed"}),this._updateLayer(a)}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}}return(0,c.default)(this.context.viewport,"LayerManager: viewport not set"),this}},{key:"_getPickingBuffer",value:function(){var e=this.context.gl;return this.context.pickingFBO=this.context.pickingFBO||new o.Framebuffer(e),this.context.pickingFBO.resize({width:e.canvas.width,height:e.canvas.height}),this.context.pickingFBO}},{key:"_updateLayers",value:function(e){var t=e.oldLayers,n=e.newLayers,r={},i=!0,o=!1,a=void 0;try{for(var s,u=t[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value;r[c.id]?h.default.warn("Multiple old layers with same id "+_(c)):r[c.id]=c}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}var l=[],f=this._updateSublayersRecursively({newLayers:n,oldLayerMap:r,generatedLayers:l}),d=this._finalizeOldLayers(r);return{error:f||d,generatedLayers:l}}},{key:"_updateSublayersRecursively",value:function(e){var t=e.newLayers,n=e.oldLayerMap,r=e.generatedLayers,i=null,o=!0,a=!1,s=void 0;try{for(var u,c=t[Symbol.iterator]();!(o=(u=c.next()).done);o=!0){var l=u.value;l.context=this.context;var f=n[l.id];null===f&&h.default.warn("Multiple new layers with same id "+_(l));var d=n[l.id]=null;try{f?(this._transferLayerState(f,l),this._updateLayer(l),(0,v.updateLayerInSeer)(l)):(this._initializeLayer(l),(0,v.initLayerInSeer)(l)),r.push(l),d=l.isComposite&&l.getSubLayers()}catch(e){h.default.warn("error during matching of "+_(l),e),i=i||e}d&&this._updateSublayersRecursively({newLayers:d,oldLayerMap:n,generatedLayers:r})}}catch(e){a=!0,s=e}finally{try{!o&&c.return&&c.return()}finally{if(a)throw s}}return i}},{key:"_finalizeOldLayers",value:function(e){var t=null;for(var n in e){var r=e[n];r&&(t=t||this._finalizeLayer(r))}return t}},{key:"_initializeLayer",value:function(t){(0,c.default)(!t.state),(0,h.default)(2,"initializing "+_(t));var n=null;try{t._initialize(),t.lifecycle=s.LIFECYCLE.INITIALIZED}catch(e){h.default.warn("error while initializing "+_(t)+"\n",e),n=n||e}(0,c.default)(t.state),t.state.layer=t;var e=!0,r=!1,i=void 0;try{for(var o,a=t.getModels()[Symbol.iterator]();!(e=(o=a.next()).done);e=!0){o.value.userData.layer=t}}catch(e){r=!0,i=e}finally{try{!e&&a.return&&a.return()}finally{if(r)throw i}}return n}},{key:"_transferLayerState",value:function(e,t){t!==e?((0,h.default)(4,"matched "+_(t),e,"->",t),t.lifecycle=s.LIFECYCLE.MATCHED,e.lifecycle=s.LIFECYCLE.AWAITING_GC,t._transferState(e)):(h.default.log(4,"Matching layer is unchanged "+t.id),t.lifecycle=s.LIFECYCLE.MATCHED,t.oldProps=t.props)}},{key:"_updateLayer",value:function(t){h.default.log(4,"updating "+t+" because: "+t.printChangeFlags());var n=null;try{t._update()}catch(e){h.default.warn("error during update of "+_(t),e),n=e}return n}},{key:"_finalizeLayer",value:function(t){(0,c.default)(t.state),(0,c.default)(t.lifecycle!==s.LIFECYCLE.AWAITING_FINALIZATION),t.lifecycle=s.LIFECYCLE.AWAITING_FINALIZATION;var n=null;this.setNeedsRedraw("finalized "+_(t));try{t._finalize()}catch(e){h.default.warn("error during finalization of "+_(t),e),n=e}return t.lifecycle=s.LIFECYCLE.FINALIZED,(0,h.default)(2,"finalizing "+_(t)),n}},{key:"_validateEventHandling",value:function(){(this.onLayerClick||this.onLayerHover)&&this.layers.length&&!this.layers.some(function(e){return e.props.pickable})&&h.default.warn("You have supplied a top-level input event handler (e.g. `onLayerClick`), but none of your layers have set the `pickable` flag.")}},{key:"_onClick",value:function(e){e.offsetCenter&&this._pickAndCallback({callback:this._onLayerClick,event:e,mode:"click"})}},{key:"_onPointerMove",value:function(e){e.leftButton||e.rightButton||this._pickAndCallback({callback:this._onLayerHover,event:e,mode:"hover"})}},{key:"_onPointerLeave",value:function(e){this.pickObject({x:-1,y:-1,radius:this._pickingRadius,mode:"hover"})}},{key:"_pickAndCallback",value:function(e){var t=e.event.offsetCenter,n=this._pickingRadius,r=this.pickObject({x:t.x,y:t.y,radius:n,mode:e.mode});if(e.callback){var i=r.find(function(e){return 0<=e.index})||null;e.callback(i,r,e.event.srcEvent)}}},{key:"_initSeer",value:function(){this.layers.forEach(function(e){(0,v.initLayerInSeer)(e),(0,v.updateLayerInSeer)(e)})}},{key:"_editSeer",value:function(e){if("edit"===e.type&&"props"===e.valuePath[0]){(0,v.setPropOverrides)(e.itemKey,e.valuePath.slice(1),e.value);var t=this.layers.map(function(e){return new e.constructor(e.props)});this.updateLayers({newLayers:t})}}}]),i}();t.default=m},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();t.formatTime=o,t.leftPad=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:8;for(;e.length<t;)e=" "+e;return e};var i=function(){function n(e){var t=e.id;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),this.id=t,this.time=0,this.total=0,this.average=0,this.count=0,this._time=0}return r(n,[{key:"timeStart",value:function(){this._time=this.timestampMs()}},{key:"timeEnd",value:function(){this.time=this.timestampMs()-this._time,this.total+=this.time,this.count++,this.average=this.total/this.count}},{key:"timestampMs",value:function(){return"undefined"!=typeof window&&window.performance?window.performance.now():Date.now()}},{key:"getTimeString",value:function(){return this.id+":"+o(this.time)+"("+this.count+")"}}]),n}();function o(e){return e<10?e.toFixed(2)+"ms":e<100?e.toFixed(1)+"ms":e<1e3?e.toFixed(0)+"ms":(e/1e3).toFixed(2)+"s"}t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TRANSITION_EVENTS=void 0;var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=a(n(125)),f=n(84),o=a(n(1));function a(e){return e&&e.__esModule?e:{default:e}}var s=function(){},u=t.TRANSITION_EVENTS={BREAK:1,SNAP_TO_END:2,IGNORE:3},c={transitionDuration:0,transitionEasing:function(e){return e},transitionInterpolator:new i.default,transitionInterruption:u.BREAK,onTransitionStart:s,onTransitionInterrupt:s,onTransitionEnd:s},l={animation:null,propsInTransition:null,startProps:null,endProps:null},d=function(){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),this.props=e,this.state=l,this._onTransitionFrame=this._onTransitionFrame.bind(this)}return r(t,[{key:"getViewportInTransition",value:function(){return this.state.propsInTransition}},{key:"processViewportChange",value:function(e){var t=!1,n=this.props;if(this.props=e,this._shouldIgnoreViewportChange(n,e))return t;var r=this._isTransitionInProgress();if(this._isTransitionEnabled(e)){var i=Object.assign({},n,this.state.interruption===u.SNAP_TO_END?this.state.endProps:this.state.propsInTransition||n);r&&n.onTransitionInterrupt(),e.onTransitionStart(),this._triggerTransition(i,e),t=!0}else r&&(n.onTransitionInterrupt(),this._endTransition());return t}},{key:"_isTransitionInProgress",value:function(){return this.state.propsInTransition}},{key:"_isTransitionEnabled",value:function(e){return 0<e.transitionDuration&&e.transitionInterpolator}},{key:"_isUpdateDueToCurrentTransition",value:function(e){return!!this.state.propsInTransition&&this.state.interpolator.arePropsEqual(e,this.state.propsInTransition)}},{key:"_shouldIgnoreViewportChange",value:function(e,t){return this._isTransitionInProgress()?this.state.interruption===u.IGNORE||this._isUpdateDueToCurrentTransition(t):!this._isTransitionEnabled(t)||t.transitionInterpolator.arePropsEqual(e,t)}},{key:"_triggerTransition",value:function(e,t){(0,o.default)(this._isTransitionEnabled(t),"Transition is not enabled"),cancelAnimationFrame(this.state.animation);var n=t.transitionInterpolator.initializeProps(e,t);this.state={duration:t.transitionDuration,easing:t.transitionEasing,interpolator:t.transitionInterpolator,interruption:t.transitionInterruption,startTime:Date.now(),startProps:n.start,endProps:n.end,animation:null,propsInTransition:{}},this._onTransitionFrame()}},{key:"_onTransitionFrame",value:function(){this.state.animation=requestAnimationFrame(this._onTransitionFrame),this._updateViewport()}},{key:"_endTransition",value:function(){cancelAnimationFrame(this.state.animation),this.state=l}},{key:"_updateViewport",value:function(){var e=Date.now(),t=this.state,n=t.startTime,r=t.duration,i=t.easing,o=t.interpolator,a=t.startProps,s=t.endProps,u=!1,c=(e-n)/r;1<=c&&(c=1,u=!0),c=i(c);var l=o.interpolateProps(a,s,c);this.state.propsInTransition=(0,f.extractViewportFrom)(Object.assign({},this.props,l)),this.props.onViewportChange&&this.props.onViewportChange(this.state.propsInTransition,{inTransition:!0}),u&&(this._endTransition(),this.props.onTransitionEnd())}}]),t}();(t.default=d).defaultProps=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.diffProps=function(e,t){var n=o({newProps:e,oldProps:t,ignoreProps:{data:null,updateTriggers:null}}),r=function(e,t){if(null===t)return"oldProps is null, initial diff";var n=e.dataComparator;if(n){if(!n(e.data,t.data))return"Data comparator detected a change"}else if(e.data!==t.data)return"A new data container was supplied";return null}(e,t),i=!1;r||(i=function(e,t){if(null===t)return"oldProps is null, initial diff";if("all"in e.updateTriggers){var n=s(t,e,"all");if(n)return{all:!0}}var r={},i=!1;for(var o in e.updateTriggers)if("all"!==o){var a=s(t,e,o);a&&(r[o]=!0,i=r)}return i}(e,t));return{dataChanged:r,propsChanged:n,updateTriggersChanged:i}},t.compareProps=o;var r,i=n(1),h=(r=i)&&r.__esModule?r:{default:r};function o(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.newProps,n=e.oldProps,r=e.ignoreProps,i=void 0===r?{}:r,o=e.shallowCompareProps,a=void 0===o?{}:o,s=e.triggerName,u=void 0===s?"props":s;if((0,h.default)(void 0!==n&&void 0!==t,"compareProps args"),n===t)return null;if("object"!==(void 0===t?"undefined":d(t))||null===t)return u+" changed shallowly";if("object"!==(void 0===n?"undefined":d(n))||null===n)return u+" changed shallowly";for(var c in n)if(!(c in i)){if(!(c in t))return u+"."+c+" dropped: "+n[c]+" -> undefined";var l=t[c]&&n[c]&&t[c].equals;if(l&&!l.call(t[c],n[c]))return u+"."+c+" changed deeply: "+n[c]+" -> "+t[c];if(c in a)"function"===d(t[c])&&"function"==typeof n[c]&&(l=!0);if(!l&&n[c]!==t[c])return u+"."+c+" changed shallowly: "+n[c]+" -> "+t[c]}for(var f in t)if(!(f in i||f in n))return u+"."+f+" added: undefined -> "+t[f];return null}function s(e,t,n){var r=e.updateTriggers[n]||{};return o({oldProps:t.updateTriggers[n]||{},newProps:r,triggerName:n})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=u(n(116)),o=n(115),a=u(n(178)),s=n(82);function u(e){return e&&e.__esModule?e:{default:e}}var c={GRABBING:"-webkit-grabbing",GRAB:"-webkit-grab",POINTER:"pointer"},l={width:i.default.number.isRequired,height:i.default.number.isRequired,longitude:i.default.number.isRequired,latitude:i.default.number.isRequired,zoom:i.default.number.isRequired,bearing:i.default.number,pitch:i.default.number,altitude:i.default.number,maxZoom:i.default.number,minZoom:i.default.number,maxPitch:i.default.number,minPitch:i.default.number,onViewportChange:i.default.func,scrollZoom:i.default.bool,dragPan:i.default.bool,dragRotate:i.default.bool,doubleClickZoom:i.default.bool,touchZoomRotate:i.default.bool,getCursor:i.default.func,controls:i.default.shape({events:i.default.arrayOf(i.default.string),handleEvent:i.default.func})},f=Object.assign({},s.MAPBOX_LIMITS,{onViewportChange:null,scrollZoom:!0,dragPan:!0,dragRotate:!0,doubleClickZoom:!0,touchZoomRotate:!0,getCursor:function(e){return e.isDragging?c.GRABBING:c.GRAB}}),d=function(){function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),e=Object.assign({},f,e),this.props=e,this.state={isDragging:!1},this.canvas=e.canvas;var t=new o.EventManager(this.canvas);this._eventManager=t,this._controls=this.props.controls||new a.default,this._controls.setOptions(Object.assign({},this.props,{onStateChange:this._onInteractiveStateChange.bind(this),eventManager:t}))}return r(n,[{key:"setProps",value:function(e){e=Object.assign({},this.props,e),this.props=e,this._controls.setOptions(e)}},{key:"finalize",value:function(){this._eventManager.destroy()}},{key:"_onInteractiveStateChange",value:function(e){var t=e.isDragging,n=void 0!==t&&t;if(n!==this.state.isDragging){this.state.isDragging=n;var r=this.props.getCursor;this.canvas.style.cursor=r(this.state)}}}]),n}();(t.default=d).displayName="MapController",d.propTypes=l,d.defaultProps=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=c(n(116)),o=c(n(85)),a=c(n(179)),s=c(n(121)),u=n(115);function c(e){return e&&e.__esModule?e:{default:e}}var l={GRABBING:"-webkit-grabbing",GRAB:"-webkit-grab",POINTER:"pointer"},f={lookAt:i.default.arrayOf(i.default.number),distance:i.default.number,rotationX:i.default.number,rotationY:i.default.number,translationX:i.default.number,translationY:i.default.number,zoom:i.default.number,minZoom:i.default.number,maxZoom:i.default.number,fov:i.default.number,near:i.default.number,far:i.default.number,width:i.default.number.isRequired,height:i.default.number.isRequired,bounds:i.default.object,onViewportChange:i.default.func.isRequired,getCursor:i.default.func,orbitControls:i.default.object},d={lookAt:[0,0,0],rotationX:0,rotationY:0,translationX:0,translationY:0,distance:10,zoom:1,minZoom:0,maxZoom:1/0,fov:50,near:1,far:1e3,getCursor:function(e){return e.isDragging?l.GRABBING:l.GRAB}},h=function(){function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),e=Object.assign({},d,e),this.props=e,this.state={isDragging:!1},this.canvas=e.canvas;var t=new u.EventManager(this.canvas);this._eventManager=t,this._controls=e.orbitControls||new s.default(a.default),this._controls.setOptions(Object.assign({},this.props,{onStateChange:this._onInteractiveStateChange.bind(this),eventManager:t}))}return r(n,null,[{key:"getViewport",value:function(e){return new o.default(e)}}]),r(n,[{key:"setProps",value:function(e){e=Object.assign({},this.props,e),this.props=e,this._controls.setOptions(e)}},{key:"finalize",value:function(){this._eventManager.destroy()}},{key:"_onInteractiveStateChange",value:function(e){var t=e.isDragging,n=void 0!==t&&t;if(n!==this.state.isDragging){this.state.isDragging=n;var r=this.props.getCursor;this.canvas.style.cursor=r(this.state)}}}]),n}();(t.default=h).displayName="OrbitController",h.propTypes=f,h.defaultProps=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.lighting=t.project64=t.project=t.picking=t.fp64=t.fp32=void 0,t.initializeShaderModules=u;var r=n(12),i=s(n(83)),o=s(n(192)),a=s(n(191));function s(e){return e&&e.__esModule?e:{default:e}}function u(){(0,r.registerShaderModules)([r.fp32,r.fp64,i.default,o.default,a.default,r.picking]),(0,r.setDefaultShaderModules)([i.default])}u(),t.fp32=r.fp32,t.fp64=r.fp64,t.picking=r.picking,t.project=i.default,t.project64=o.default,t.lighting=a.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=o(n(342)),i=o(n(83));function o(e){return e&&e.__esModule?e:{default:e}}t.default={name:"lighting",dependencies:[i.default],vs:r.default}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(12),i=u(n(83)),o=n(195),a=u(n(196)),s=u(n(343));function u(e){return e&&e.__esModule?e:{default:e}}t.default={name:"project64",dependencies:[i.default,r.fp64],vs:s.default,getUniforms:function(){0<arguments.length&&void 0!==arguments[0]&&arguments[0];var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},t=e.project_uViewProjectionMatrix,n=e.project_uScale;if(t&&n)return c({project_uViewProjectionMatrix:t,project_uScale:n});return{}},deprecations:[{type:"uniform vec2",old:"projectionFP64[16]",new:"project_uViewProjectionMatrixFP64"},{type:"uniform vec2",old:"projectionScaleFP64",new:"project64_uScale"}]};var c=(0,a.default)(function(e){var t=e.project_uViewProjectionMatrix,n=e.project_uScale,r=(0,o.fp64ifyMatrix4)(t),i=(0,o.fp64ify)(n);return{project_uViewProjectionMatrixFP64:r,project64_uViewProjectionMatrix:r,project64_uScale:i}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),u=n(16),o=n(1),a=(r=o)&&r.__esModule?r:{default:r};var s=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}return i(e,[{key:"arePropsEqual",value:function(e,t){var n=!0,r=!1,i=void 0;try{for(var o,a=(this.propNames||[])[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var s=o.value;if(!(0,u.equals)(e[s],t[s]))return!1}}catch(e){r=!0,i=e}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}return!0}},{key:"initializeProps",value:function(e,t){return{start:e,end:t}}},{key:"interpolateProps",value:function(e,t,n){(0,a.default)(!1,"interpolateProps is not implemented")}}]),e}();t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.count=function(e){if(t=e,null===t||"object"!==(void 0===t?"undefined":r(t)))throw new Error(i);var t;if("function"==typeof e.count)return e.count();if(Number.isFinite(e.size))return e.size;if(Number.isFinite(e.length))return e.length;if(n=e,null!==n&&"object"===(void 0===n?"undefined":r(n))&&n.constructor===Object)return Object.keys(e).length;var n;throw new Error(o)};var i="count(): argument not an object",o="count(): argument not a container"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.fp64ify=s,t.fp64ifyMatrix4=function(e){for(var t=new Float32Array(32),n=0;n<4;++n)for(var r=0;r<4;++r){var i=4*n+r;s(e[4*r+n],t,2*i)}return t},t.fp64LowPart=function(e){return e-Math.fround(e)},t.enable64bitSupport=function(e){if(e.fp64){if(e.coordinateSystem===a.COORDINATE_SYSTEM.LNGLAT)return!0;o.default.once(0,"64-bit mode only works with coordinateSystem set to\n COORDINATE_SYSTEM.LNGLAT. Rendering in 32-bit mode instead")}return!1};var r,i=n(17),o=(r=i)&&r.__esModule?r:{default:r},a=n(70);function s(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[],n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,r=Math.fround(e),i=e-Math.fround(e);return t[n]=r,t[n+1]=i,t}},function(e,t,n){"use strict";function o(e,t){if(e===t)return!0;if(Array.isArray(e)){var n=e.length;if(!t||t.length!==n)return!1;for(var r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}return!1}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(n){var r={},i=void 0;return function(e){for(var t in e)if(!o(e[t],r[t])){i=n(e),r=e;break}return i}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=Object.getPrototypeOf(e),n=Object.getOwnPropertyNames(t),r=!0,i=!1,o=void 0;try{for(var a,s=function(){var t=a.value;"function"==typeof e[t]&&(c.find(function(e){return t===e})||(e[t]=e[t].bind(e)))},u=n[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s()}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}};var c=["constructor","render","componentWillMount","componentDidMount","componentWillReceiveProps","shouldComponentUpdate","componentWillUpdate","componentDidUpdate","componentWillUnmount"]},function(e,t,n){var r=n(27);e.exports=function(e,t){if("number"!=typeof e&&"Number"!=r(e))throw TypeError(t);return+e}},function(e,t,n){"use strict";var c=n(14),l=n(57),f=n(11);e.exports=[].copyWithin||function(e,t){var n=c(this),r=f(n.length),i=l(e,r),o=l(t,r),a=2<arguments.length?arguments[2]:void 0,s=Math.min((void 0===a?r:l(a,r))-o,r-i),u=1;for(o<i&&i<o+s&&(u=-1,o+=s-1,i+=s-1);0<s--;)o in n?n[i]=n[o]:delete n[i],i+=u,o+=u;return n}},function(e,t,n){var r=n(49);e.exports=function(e,t){var n=[];return r(e,!1,n.push,n,t),n}},function(e,t,n){var l=n(15),f=n(14),d=n(72),h=n(11);e.exports=function(e,t,n,r,i){l(t);var o=f(e),a=d(o),s=h(o.length),u=i?s-1:0,c=i?-1:1;if(n<2)for(;;){if(u in a){r=a[u],u+=c;break}if(u+=c,i?u<0:s<=u)throw TypeError("Reduce of empty array with no initial value")}for(;i?0<=u:u<s;u+=c)u in a&&(r=t(r,a[u],u,o));return r}},function(e,t,n){"use strict";var o=n(15),a=n(5),s=n(208),u=[].slice,c={};e.exports=Function.bind||function(t){var n=o(this),r=u.call(arguments,1),i=function(){var e=r.concat(u.call(arguments));return this instanceof i?function(e,t,n){if(!(t in c)){for(var r=[],i=0;i<t;i++)r[i]="a["+i+"]";c[t]=Function("F,a","return new F("+r.join(",")+")")}return c[t](e,n)}(n,e.length,e):s(n,e,t)};return a(n.prototype)&&(i.prototype=n.prototype),i}},function(e,t,n){"use strict";var a=n(10).f,s=n(51),u=n(55),c=n(28),l=n(48),f=n(49),r=n(138),i=n(211),o=n(56),d=n(9),h=n(44).fastKey,p=n(66),v=d?"_s":"size",g=function(e,t){var n,r=h(t);if("F"!==r)return e._i[r];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,o,n,r){var i=e(function(e,t){l(e,i,o,"_i"),e._t=o,e._i=s(null),e._f=void 0,e._l=void 0,e[v]=0,null!=t&&f(t,n,e[r],e)});return u(i.prototype,{clear:function(){for(var e=p(this,o),t=e._i,n=e._f;n;n=n.n)n.r=!0,n.p&&(n.p=n.p.n=void 0),delete t[n.i];e._f=e._l=void 0,e[v]=0},delete:function(e){var t=p(this,o),n=g(t,e);if(n){var r=n.n,i=n.p;delete t._i[n.i],n.r=!0,i&&(i.n=r),r&&(r.p=i),t._f==n&&(t._f=r),t._l==n&&(t._l=i),t[v]--}return!!n},forEach:function(e){p(this,o);for(var t,n=c(e,1<arguments.length?arguments[1]:void 0,3);t=t?t.n:this._f;)for(n(t.v,t.k,this);t&&t.r;)t=t.p},has:function(e){return!!g(p(this,o),e)}}),d&&a(i.prototype,"size",{get:function(){return p(this,o)[v]}}),i},def:function(e,t,n){var r,i,o=g(e,t);return o?o.v=n:(e._l=o={i:i=h(t,!0),k:t,v:n,p:r=e._l,n:void 0,r:!1},e._f||(e._f=o),r&&(r.n=o),e[v]++,"F"!==i&&(e._i[i]=o)),e},getEntry:g,setStrong:function(e,n,t){r(e,n,function(e,t){this._t=p(e,n),this._k=t,this._l=void 0},function(){for(var e=this._k,t=this._l;t&&t.r;)t=t.p;return this._t&&(this._l=t=t?t.n:this._t._f)?i(0,"keys"==e?t.k:"values"==e?t.v:[t.k,t.v]):(this._t=void 0,i(1))},t?"entries":"values",!t,!0),o(n)}}},function(e,t,n){var r=n(71),i=n(200);e.exports=function(e){return function(){if(r(this)!=e)throw TypeError(e+"#toJSON isn't generic");return i(this)}}},function(e,t,n){"use strict";var a=n(55),s=n(44).getWeak,i=n(2),u=n(5),c=n(48),l=n(49),r=n(32),f=n(18),d=n(66),o=r(5),h=r(6),p=0,v=function(e){return e._l||(e._l=new g)},g=function(){this.a=[]},y=function(e,t){return o(e.a,function(e){return e[0]===t})};g.prototype={get:function(e){var t=y(this,e);if(t)return t[1]},has:function(e){return!!y(this,e)},set:function(e,t){var n=y(this,e);n?n[1]=t:this.a.push([e,t])},delete:function(t){var e=h(this.a,function(e){return e[0]===t});return~e&&this.a.splice(e,1),!!~e}},e.exports={getConstructor:function(e,n,r,i){var o=e(function(e,t){c(e,o,n,"_i"),e._t=n,e._i=p++,e._l=void 0,null!=t&&l(t,r,e[i],e)});return a(o.prototype,{delete:function(e){if(!u(e))return!1;var t=s(e);return!0===t?v(d(this,n)).delete(e):t&&f(t,this._i)&&delete t[this._i]},has:function(e){if(!u(e))return!1;var t=s(e);return!0===t?v(d(this,n)).has(e):t&&f(t,this._i)}}),o},def:function(e,t,n){var r=s(i(t),!0);return!0===r?v(e).set(t,n):r[e._i]=n,e},ufstore:v}},function(e,t,n){"use strict";var p=n(91),v=n(5),g=n(11),y=n(28),_=n(6)("isConcatSpreadable");e.exports=function e(t,n,r,i,o,a,s,u){for(var c,l,f=o,d=0,h=!!s&&y(s,u,3);d<i;){if(d in r){if(c=h?h(r[d],d,n):r[d],l=!1,v(c)&&(l=void 0!==(l=c[_])?!!l:p(c)),l&&0<a)f=e(t,n,c,g(c.length),f,a-1)-1;else{if(9007199254740991<=f)throw TypeError();t[f]=c}f++}d++}return f}},function(e,t,n){e.exports=!n(9)&&!n(4)(function(){return 7!=Object.defineProperty(n(131)("div"),"a",{get:function(){return 7}}).a})},function(e,t){e.exports=function(e,t,n){var r=void 0===n;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},function(e,t,n){var r=n(5),i=Math.floor;e.exports=function(e){return!r(e)&&isFinite(e)&&i(e)===e}},function(e,t,n){var o=n(2);e.exports=function(t,e,n,r){try{return r?e(o(n)[0],n[1]):e(n)}catch(e){var i=t.return;throw void 0!==i&&o(i.call(t)),e}}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,n){var o=n(140),r=Math.pow,a=r(2,-52),s=r(2,-23),u=r(2,127)*(2-s),c=r(2,-126);e.exports=Math.fround||function(e){var t,n,r=Math.abs(e),i=o(e);return r<c?i*(r/c/s+1/a-1/a)*c*s:u<(n=(t=(1+s/a)*r)-(t-r))||n!=n?i*(1/0):i*n}},function(e,t){e.exports=Math.log1p||function(e){return-1e-8<(e=+e)&&e<1e-8?e-e*e/2:Math.log(1+e)}},function(e,t){e.exports=Math.scale||function(e,t,n,r,i){return 0===arguments.length||e!=e||t!=t||n!=n||r!=r||i!=i?NaN:e===1/0||e===-1/0?e:(e-t)*(i-r)/(n-t)+r}},function(e,t,n){"use strict";var d=n(53),h=n(95),p=n(73),v=n(14),g=n(72),i=Object.assign;e.exports=!i||n(4)(function(){var e={},t={},n=Symbol(),r="abcdefghijklmnopqrst";return e[n]=7,r.split("").forEach(function(e){t[e]=e}),7!=i({},e)[n]||Object.keys(i({},t)).join("")!=r})?function(e,t){for(var n=v(e),r=arguments.length,i=1,o=h.f,a=p.f;i<r;)for(var s,u=g(arguments[i++]),c=o?d(u).concat(o(u)):d(u),l=c.length,f=0;f<l;)a.call(u,s=c[f++])&&(n[s]=u[s]);return n}:i},function(e,t,n){var a=n(10),s=n(2),u=n(53);e.exports=n(9)?Object.defineProperties:function(e,t){s(e);for(var n,r=u(t),i=r.length,o=0;o<i;)a.f(e,n=r[o++],t[n]);return e}},function(e,t,n){var r=n(24),i=n(52).f,o={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return a&&"[object Window]"==o.call(e)?function(e){try{return i(e)}catch(e){return a.slice()}}(e):i(r(e))}},function(e,t,n){var a=n(18),s=n(24),u=n(87)(!1),c=n(144)("IE_PROTO");e.exports=function(e,t){var n,r=s(e),i=0,o=[];for(n in r)n!=c&&a(r,n)&&o.push(n);for(;t.length>i;)a(r,n=t[i++])&&(~u(o,n)||o.push(n));return o}},function(e,t,n){var u=n(53),c=n(24),l=n(73).f;e.exports=function(s){return function(e){for(var t,n=c(e),r=u(n),i=r.length,o=0,a=[];o<i;)l.call(n,t=r[o++])&&a.push(s?[t,n[t]]:n[t]);return a}}},function(e,t,n){var r=n(52),i=n(95),o=n(2),a=n(3).Reflect;e.exports=a&&a.ownKeys||function(e){var t=r.f(o(e)),n=i.f;return n?t.concat(n(e)):t}},function(e,t,n){var r=n(3).parseFloat,i=n(65).trim;e.exports=1/r(n(148)+"-0")!=-1/0?function(e){var t=i(String(e),3),n=r(t);return 0===n&&"-"==t.charAt(0)?-0:n}:r},function(e,t,n){var r=n(3).parseInt,i=n(65).trim,o=n(148),a=/^[-+]?0[xX]/;e.exports=8!==r(o+"08")||22!==r(o+"0x16")?function(e,t){var n=i(String(e),3);return r(n,t>>>0||(a.test(n)?16:10))}:r},function(e,t){e.exports=function(e){try{return{e:!1,v:e()}}catch(e){return{e:!0,v:e}}}},function(e,t,n){var r=n(2),i=n(5),o=n(142);e.exports=function(e,t){if(r(e),i(t)&&t.constructor===e)return t;var n=o.f(e);return(0,n.resolve)(t),n.promise}},function(e,t,n){var l=n(11),f=n(147),d=n(34);e.exports=function(e,t,n,r){var i=String(d(e)),o=i.length,a=void 0===n?" ":String(n),s=l(t);if(s<=o||""==a)return i;var u=s-o,c=f.call(a,Math.ceil(u/a.length));return c.length>u&&(c=c.slice(0,u)),r?c+i:i+c}},function(e,t,n){var r=n(36),i=n(11);e.exports=function(e){if(void 0===e)return 0;var t=r(e),n=i(t);if(t!==n)throw RangeError("Wrong length!");return n}},function(e,t,n){t.f=n(6)},function(e,t,n){"use strict";var r=n(203),i=n(66);e.exports=n(88)("Map",function(e){return function(){return e(this,0<arguments.length?arguments[0]:void 0)}},{get:function(e){var t=r.getEntry(i(this,"Map"),e);return t&&t.v},set:function(e,t){return r.def(i(this,"Map"),0===e?0:e,t)}},r,!0)},function(e,t,n){n(9)&&"g"!=/./g.flags&&n(10).f(RegExp.prototype,"flags",{configurable:!0,get:n(90)})},function(e,t,n){"use strict";var r=n(203),i=n(66);e.exports=n(88)("Set",function(e){return function(){return e(this,0<arguments.length?arguments[0]:void 0)}},{add:function(e){return r.def(i(this,"Set"),e=0===e?0:e,e)}},r)},function(e,t,n){"use strict";var o,r=n(32)(0),a=n(20),i=n(44),s=n(215),u=n(205),c=n(5),l=n(4),f=n(66),d="WeakMap",h=i.getWeak,p=Object.isExtensible,v=u.ufstore,g={},y=function(e){return function(){return e(this,0<arguments.length?arguments[0]:void 0)}},_={get:function(e){if(c(e)){var t=h(e);return!0===t?v(f(this,d)).get(e):t?t[this._i]:void 0}},set:function(e,t){return u.def(f(this,d),e,t)}},m=e.exports=n(88)(d,y,_,u,!0,!0);l(function(){return 7!=(new m).set((Object.freeze||Object)(g),7).get(g)})&&(s((o=u.getConstructor(y,d)).prototype,_),i.NEED=!0,r(["delete","has","get","set"],function(r){var e=m.prototype,i=e[r];a(e,r,function(e,t){if(!c(e)||p(e))return i.call(this,e,t);this._f||(this._f=new o);var n=this._f[r](e,t);return"set"==r?this:n})}))},function(e,t,n){"use strict";function r(e,t,n){n=n||2;var r,i,o,a,s,u,c,l=t&&t.length,f=l?t[0]*n:e.length,d=v(e,0,f,n,!0),h=[];if(!d)return h;if(l&&(d=function(e,t,n,r){var i,o,a,s,u,c=[];for(i=0,o=t.length;i<o;i++)a=t[i]*r,s=i<o-1?t[i+1]*r:e.length,(u=v(e,a,s,r,!1))===u.next&&(u.steiner=!0),c.push(E(u));for(c.sort(_),i=0;i<c.length;i++)m(c[i],n),n=g(n,n.next);return n}(e,t,d,n)),e.length>80*n){r=o=e[0],i=a=e[1];for(var p=n;p<f;p+=n)(s=e[p])<r&&(r=s),(u=e[p+1])<i&&(i=u),o<s&&(o=s),a<u&&(a=u);c=0!==(c=Math.max(o-r,a-i))?1/c:0}return y(d,h,n,r,i,c),h}function v(e,t,n,r,i){var o,a;if(i===0<x(e,t,n,r))for(o=t;o<n;o+=r)a=u(o,e[o],e[o+1],a);else for(o=n-r;t<=o;o-=r)a=u(o,e[o],e[o+1],a);return a&&s(a,a.next)&&(T(a),a=a.next),a}function g(e,t){if(!e)return e;t||(t=e);var n,r=e;do{if(n=!1,r.steiner||!s(r,r.next)&&0!==P(r.prev,r,r.next))r=r.next;else{if(T(r),(r=t=r.prev)===r.next)break;n=!0}}while(n||r!==t);return t}function y(e,t,n,r,i,o,a){if(e){!a&&o&&function(e,t,n,r){var i=e;for(;null===i.z&&(i.z=b(i.x,i.y,t,n,r)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next,i!==e;);i.prevZ.nextZ=null,i.prevZ=null,function(e){var t,n,r,i,o,a,s,u,c=1;do{for(n=e,o=e=null,a=0;n;){for(a++,r=n,t=s=0;t<c&&(s++,r=r.nextZ);t++);for(u=c;0<s||0<u&&r;)0!==s&&(0===u||!r||n.z<=r.z)?(n=(i=n).nextZ,s--):(r=(i=r).nextZ,u--),o?o.nextZ=i:e=i,i.prevZ=o,o=i;n=r}o.nextZ=null,c*=2}while(1<a)}(i)}(e,r,i,o);for(var s,u,c=e;e.prev!==e.next;)if(s=e.prev,u=e.next,o?f(e,r,i,o):l(e))t.push(s.i/n),t.push(e.i/n),t.push(u.i/n),T(e),e=u.next,c=u.next;else if((e=u)===c){a?1===a?y(e=d(e,t,n),t,n,r,i,o,2):2===a&&h(e,t,n,r,i,o):y(g(e),t,n,r,i,o,1);break}}}function l(e){var t=e.prev,n=e,r=e.next;if(0<=P(t,n,r))return!1;for(var i=e.next.next;i!==e.prev;){if(w(t.x,t.y,n.x,n.y,r.x,r.y,i.x,i.y)&&0<=P(i.prev,i,i.next))return!1;i=i.next}return!0}function f(e,t,n,r){var i=e.prev,o=e,a=e.next;if(0<=P(i,o,a))return!1;for(var s=i.x<o.x?i.x<a.x?i.x:a.x:o.x<a.x?o.x:a.x,u=i.y<o.y?i.y<a.y?i.y:a.y:o.y<a.y?o.y:a.y,c=i.x>o.x?i.x>a.x?i.x:a.x:o.x>a.x?o.x:a.x,l=i.y>o.y?i.y>a.y?i.y:a.y:o.y>a.y?o.y:a.y,f=b(s,u,t,n,r),d=b(c,l,t,n,r),h=e.prevZ,p=e.nextZ;h&&h.z>=f&&p&&p.z<=d;){if(h!==e.prev&&h!==e.next&&w(i.x,i.y,o.x,o.y,a.x,a.y,h.x,h.y)&&0<=P(h.prev,h,h.next))return!1;if(h=h.prevZ,p!==e.prev&&p!==e.next&&w(i.x,i.y,o.x,o.y,a.x,a.y,p.x,p.y)&&0<=P(p.prev,p,p.next))return!1;p=p.nextZ}for(;h&&h.z>=f;){if(h!==e.prev&&h!==e.next&&w(i.x,i.y,o.x,o.y,a.x,a.y,h.x,h.y)&&0<=P(h.prev,h,h.next))return!1;h=h.prevZ}for(;p&&p.z<=d;){if(p!==e.prev&&p!==e.next&&w(i.x,i.y,o.x,o.y,a.x,a.y,p.x,p.y)&&0<=P(p.prev,p,p.next))return!1;p=p.nextZ}return!0}function d(e,t,n){var r=e;do{var i=r.prev,o=r.next.next;!s(i,o)&&p(i,r,r.next,o)&&S(i,o)&&S(o,i)&&(t.push(i.i/n),t.push(r.i/n),t.push(o.i/n),T(r),T(r.next),r=e=o),r=r.next}while(r!==e);return r}function h(e,t,n,r,i,o){var a,s,u=e;do{for(var c=u.next.next;c!==u.prev;){if(u.i!==c.i&&(s=c,(a=u).next.i!==s.i&&a.prev.i!==s.i&&!function(e,t){var n=e;do{if(n.i!==e.i&&n.next.i!==e.i&&n.i!==t.i&&n.next.i!==t.i&&p(n,n.next,e,t))return!0;n=n.next}while(n!==e);return!1}(a,s)&&S(a,s)&&S(s,a)&&function(e,t){var n=e,r=!1,i=(e.x+t.x)/2,o=(e.y+t.y)/2;for(;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,n!==e;);return r}(a,s))){var l=A(u,c);return u=g(u,u.next),l=g(l,l.next),y(u,t,n,r,i,o),void y(l,t,n,r,i,o)}c=c.next}u=u.next}while(u!==e)}function _(e,t){return e.x-t.x}function m(e,t){if(t=function(e,t){var n,r=t,i=e.x,o=e.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&&a<s){if((a=s)===i){if(o===r.y)return r;if(o===r.next.y)return r.next}n=r.x<r.next.x?r:r.next}}r=r.next}while(r!==t);if(!n)return null;if(i===a)return n.prev;var u,c=n,l=n.x,f=n.y,d=1/0;r=n.next;for(;r!==c;)i>=r.x&&r.x>=l&&i!==r.x&&w(o<f?i:a,o,l,f,o<f?a:i,o,r.x,r.y)&&((u=Math.abs(o-r.y)/(i-r.x))<d||u===d&&r.x>n.x)&&S(r,e)&&(n=r,d=u),r=r.next;return n}(e,t)){var n=A(t,e);g(n,n.next)}}function b(e,t,n,r,i){return(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-n)*i)|e<<8))|e<<4))|e<<2))|e<<1))|(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-r)*i)|t<<8))|t<<4))|t<<2))|t<<1))<<1}function E(e){for(var t=e,n=e;t.x<n.x&&(n=t),(t=t.next)!==e;);return n}function w(e,t,n,r,i,o,a,s){return 0<=(i-a)*(t-s)-(e-a)*(o-s)&&0<=(e-a)*(r-s)-(n-a)*(t-s)&&0<=(n-a)*(o-s)-(i-a)*(r-s)}function P(e,t,n){return(t.y-e.y)*(n.x-t.x)-(t.x-e.x)*(n.y-t.y)}function s(e,t){return e.x===t.x&&e.y===t.y}function p(e,t,n,r){return!!(s(e,t)&&s(n,r)||s(e,r)&&s(n,t))||0<P(e,t,n)!=0<P(e,t,r)&&0<P(n,r,e)!=0<P(n,r,t)}function S(e,t){return P(e.prev,e,e.next)<0?0<=P(e,t,e.next)&&0<=P(e,e.prev,t):P(e,t,e.prev)<0||P(e,e.next,t)<0}function A(e,t){var n=new a(e.i,e.x,e.y),r=new a(t.i,t.x,t.y),i=e.next,o=t.prev;return(e.next=t).prev=e,(n.next=i).prev=n,(r.next=n).prev=r,(o.next=r).prev=o,r}function u(e,t,n,r){var i=new a(e,t,n);return r?(i.next=r.next,(i.prev=r).next.prev=i,r.next=i):(i.prev=i).next=i,i}function T(e){e.next.prev=e.prev,e.prev.next=e.next,e.prevZ&&(e.prevZ.nextZ=e.nextZ),e.nextZ&&(e.nextZ.prevZ=e.prevZ)}function a(e,t,n){this.i=e,this.x=t,this.y=n,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function x(e,t,n,r){for(var i=0,o=t,a=n-r;o<n;o+=r)i+=(e[a]-e[o])*(e[o+1]+e[a+1]),a=o;return i}e.exports=r,(e.exports.default=r).deviation=function(e,t,n,r){var i=t&&t.length,o=i?t[0]*n:e.length,a=Math.abs(x(e,0,o,n));if(i)for(var s=0,u=t.length;s<u;s++){var c=t[s]*n,l=s<u-1?t[s+1]*n:e.length;a-=Math.abs(x(e,c,l,n))}var f=0;for(s=0;s<r.length;s+=3){var d=r[s]*n,h=r[s+1]*n,p=r[s+2]*n;f+=Math.abs((e[d]-e[p])*(e[h+1]-e[d+1])-(e[d]-e[h])*(e[p+1]-e[d+1]))}return 0===a&&0===f?0:Math.abs((f-a)/a)},r.flatten=function(e){for(var t=e[0][0].length,n={vertices:[],holes:[],dimensions:t},r=0,i=0;i<e.length;i++){for(var o=0;o<e[i].length;o++)for(var a=0;a<t;a++)n.vertices.push(e[i][o][a]);0<i&&(r+=e[i-1].length,n.holes.push(r))}return n}},function(n,e,t){"use strict";(function(e){var t={};"production"!==e.env.NODE_ENV&&Object.freeze(t),n.exports=t}).call(e,t(26))},function(e,t){e.exports=function(e,t,n,r,i,o,a){var s=1/(t-n),u=1/(r-i),c=1/(o-a);return e[0]=-2*s,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*u,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*c,e[11]=0,e[12]=(t+n)*s,e[13]=(i+r)*u,e[14]=(a+o)*c,e[15]=1,e}},function(e,t){e.exports=function(e,t,n){var r=Math.sin(n),i=Math.cos(n),o=t[0],a=t[1],s=t[2],u=t[3],c=t[8],l=t[9],f=t[10],d=t[11];t!==e&&(e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]);return e[0]=o*i-c*r,e[1]=a*i-l*r,e[2]=s*i-f*r,e[3]=u*i-d*r,e[8]=o*r+c*i,e[9]=a*r+l*i,e[10]=s*r+f*i,e[11]=u*r+d*i,e}},function(e,t,n){e.exports=n(247)},function(e,t){e.exports=function(e,t,n){n*=.5;var r=Math.sin(n);return e[0]=r*t[0],e[1]=r*t[1],e[2]=r*t[2],e[3]=Math.cos(n),e}},function(e,t){e.exports=function(e,t,n,r){var i=t[0],o=t[1];return e[0]=i+r*(n[0]-i),e[1]=o+r*(n[1]-o),e}},function(e,t){e.exports=function(e,t,n){var r=t[0],i=t[1],o=t[2],a=n[0],s=n[1],u=n[2];return e[0]=i*u-o*s,e[1]=o*a-r*u,e[2]=r*s-i*a,e}},function(e,t){e.exports=function(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}},function(e,t){e.exports=function(e){var t=e[0],n=e[1],r=e[2];return Math.sqrt(t*t+n*n+r*r)}},function(e,t){e.exports=function(e,t){var n=t[0],r=t[1],i=t[2],o=n*n+r*r+i*i;0<o&&(o=1/Math.sqrt(o),e[0]=t[0]*o,e[1]=t[1]*o,e[2]=t[2]*o);return e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e[2]=t[2]+n[2],e[3]=t[3]+n[3],e}},function(e,t){e.exports=function(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]+e[3]*t[3]}},function(e,t){e.exports=function(e,t,n,r){var i=t[0],o=t[1],a=t[2],s=t[3];return e[0]=i+r*(n[0]-i),e[1]=o+r*(n[1]-o),e[2]=a+r*(n[2]-a),e[3]=s+r*(n[3]-s),e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e[2]=t[2]*n[2],e[3]=t[3]*n[3],e}},function(e,t){e.exports=function(e,t){var n=t[0],r=t[1],i=t[2],o=t[3],a=n*n+r*r+i*i+o*o;0<a&&(a=1/Math.sqrt(a),e[0]=n*a,e[1]=r*a,e[2]=i*a,e[3]=o*a);return e}},function(e,t){e.exports=function(e,t,n,r,i){return e[0]=t,e[1]=n,e[2]=r,e[3]=i,e}},function(e,t,O){"use strict";t.b=o,t.c=a;var R=O(8),n=O(60),C=O(61),r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function o(e){return R.a?window.requestAnimationFrame(e):setTimeout(e,1e3/60)}function a(e){return R.a?window.cancelAnimationFrame(e):clearTimeout(e)}var s={preserveDrawingBuffer:!0},u=function(){function x(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,x);var t=e.onCreateContext,n=void 0===t?function(e){return O.i(C.createGLContext)(e)}:t,r=e.onInitialize,i=void 0===r?function(){}:r,o=e.onRender,a=void 0===o?function(){}:o,s=e.onFinalize,u=void 0===s?function(){}:s,c=e.gl,l=void 0===c?null:c,f=e.glOptions,d=void 0===f?{}:f,h=e.width,p=void 0===h?null:h,v=e.height,g=void 0===v?null:v,y=e.createFramebuffer,_=void 0!==y&&y,m=e.autoResizeViewport,b=void 0===m||m,E=e.autoResizeDrawingBuffer,w=void 0===E||E,P=e.useDevicePixels,S=void 0===P||P,A=e.isGeographicCoordinateSystem,T=void 0!==A&&A;return this.isGeographicCoordinateSystem=T,"useDevicePixelRatio"in e&&(R.b.deprecated("useDevicePixelRatio","useDevicePixels"),S=e.useDevicePixelRatio),this._onCreateContext=n,this.start=this.start.bind(this),this.stop=this.stop.bind(this),this._renderFrame=this._renderFrame.bind(this),this.glOptions=d,this._createFramebuffer=_,this._onInitialize=i,this._onRender=a,this._onFinalize=u,this.width=p,this.height=g,this.gl=l,this.setProps({autoResizeViewport:b,autoResizeDrawingBuffer:w,useDevicePixels:S}),this}return i(x,[{key:"setNeedsRedraw",value:function(e){return this.needsRedraw=this.needsRedraw||e,this}},{key:"setProps",value:function(e){return"autoResizeViewport"in e&&(this.autoResizeViewport=e.autoResizeViewport),"autoResizeDrawingBuffer"in e&&(this.autoResizeDrawingBuffer=e.autoResizeDrawingBuffer),"useDevicePixels"in e&&(this.useDevicePixels=e.useDevicePixels),this}},{key:"start",value:function(){var t=this,e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};return this._stopped=!1,this._animationFrameId||(this._startPromise=O.i(n.g)().then(function(){return t._stopped?null:(t._createWebGLContext(e),t._initializeCallbackData(),t._updateCallbackData(),t._resizeCanvasDrawingBuffer(),t._resizeViewport(),t._onInitialize(t._callbackData))}).then(function(e){t._stopped||(t._addCallbackData(e||{}),!1===e||t._animationFrameId||(t._animationFrameId=o(t._renderFrame)))})),this}},{key:"stop",value:function(){return this._animationFrameId&&(this._finalizeCallbackData(),a(this._animationFrameId),this._animationFrameId=null,this._stopped=!0),this}},{key:"setViewParameters",value:function(e){var t=e.autoResizeDrawingBuffer,n=void 0===t||t,r=e.autoResizeCanvas,i=void 0===r||r,o=e.autoResizeViewport,a=void 0===o||o,s=e.useDevicePixels,u=void 0===s||s,c=e.useDevicePixelRatio,l=void 0===c?null:c;return R.b.deprecated("AnimationLoop.setViewParameters","AnimationLoop.setProps"),this.autoResizeViewport=a,this.autoResizeCanvas=i,this.autoResizeDrawingBuffer=n,this.useDevicePixels=u,null!==l&&(R.b.deprecated("useDevicePixelRatio","useDevicePixels"),this.useDevicePixels=l),this}},{key:"_setupFrame",value:function(){this._onSetupFrame?this._onSetupFrame(this._callbackData):(this._resizeCanvasDrawingBuffer(),this._resizeViewport(),this._resizeFramebuffer())}},{key:"_renderFrame",value:function(){this._setupFrame(),this._updateCallbackData(),this._onRender(this._callbackData),this._callbackData.tick++,this._stopped||(this._animationFrameId=o(this._renderFrame))}},{key:"_initializeCallbackData",value:function(){this._callbackData={gl:this.gl,canvas:this.gl.canvas,framebuffer:this.framebuffer,stop:this.stop,tick:0,tock:0,isGeographicCoordinateSystem:this.isGeographicCoordinateSystem,useDevicePixels:this.useDevicePixels}}},{key:"_updateCallbackData",value:function(){var e=this.gl.canvas;this._callbackData.width=e.width,this._callbackData.height=e.height,this._callbackData.aspect=e.width/e.height}},{key:"_finalizeCallbackData",value:function(){this._onFinalize(this._callbackData)}},{key:"_addCallbackData",value:function(e){"object"===(void 0===e?"undefined":r(e))&&null!==e&&(this._callbackData=Object.assign({},this._callbackData,e))}},{key:"_createWebGLContext",value:function(e){if((e=Object.assign({},e,s,this.glOptions)).gl?this.gl=e.gl:this.gl=this._onCreateContext(e),!O.i(C.isWebGL)(this.gl))throw new Error("AnimationLoop.onCreateContext - illegal context returned");this._createFramebuffer&&(this.framebuffer=new C.Framebuffer(this.gl)),O.i(C.resetParameters)(this.gl)}},{key:"_resizeViewport",value:function(){this.autoResizeViewport&&this.gl.viewport(0,0,this.gl.canvas.width,this.gl.canvas.height)}},{key:"_resizeFramebuffer",value:function(){this.framebuffer&&this.framebuffer.resize({width:this.gl.canvas.width,height:this.gl.canvas.height})}},{key:"_resizeCanvasDrawingBuffer",value:function(){this.autoResizeDrawingBuffer&&O.i(n.h)(this.gl.canvas,{useDevicePixels:this.useDevicePixels})}}]),x}();t.a=u},function(e,t,r){"use strict";var i=r(8),o=r(16),n=r(1),a=r.n(n),s=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var u=function(){function n(e){var t=e.id;e.display;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),this.position=new o.Vector3,this.rotation=new o.Vector3,this.scale=new o.Vector3(1,1,1),this.matrix=new o.Matrix4,this.id=t||r.i(i.d)(this.constructor.name),this.display=!0,this.userData={}}return s(n,[{key:"setPosition",value:function(e){return a()(3===e.length,"setPosition requires vector argument"),this.position=e,this}},{key:"setRotation",value:function(e){return a()(3===e.length,"setRotation requires vector argument"),this.rotation=e,this}},{key:"setScale",value:function(e){return a()(3===e.length,"setScale requires vector argument"),this.scale=e,this}},{key:"setMatrixComponents",value:function(e){var t=e.position,n=e.rotation,r=e.scale,i=e.update,o=void 0===i||i;return t&&this.setPosition(t),n&&this.setRotation(n),r&&this.setScale(r),o&&this.updateMatrix(),this}},{key:"updateMatrix",value:function(){var e=this.position,t=this.rotation,n=this.scale;return this.matrix.identity(),this.matrix.translate(e),this.matrix.rotateXYZ(t),this.matrix.scale(n),this}},{key:"update",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.position,n=e.rotation,r=e.scale;return t&&this.setPosition(t),n&&this.setRotation(n),r&&this.setScale(r),this.updateMatrix(),this}},{key:"getCoordinateUniforms",value:function(e,t){a()(e),t=t||this.matrix;var n=new o.Matrix4(e).multiplyRight(t),r=n.invert(),i=r.transpose();return{viewMatrix:e,modelMatrix:t,objectMatrix:t,worldMatrix:n,worldInverseMatrix:r,worldInverseTransposeMatrix:i}}},{key:"transform",value:function(){if(this.parent){var e=this.parent;this.endPosition.set(this.position.add(e.endPosition)),this.endRotation.set(this.rotation.add(e.endRotation)),this.endScale.set(this.scale.add(e.endScale))}else this.endPosition.set(this.position),this.endRotation.set(this.rotation),this.endScale.set(this.scale);for(var t=this.children,n=0;n<t.length;++n)t[n].transform();return this}}]),n}();t.a=u},function(e,t,n){"use strict";var r=n(105);var i=function(e){function o(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var t=e.radius,n=void 0===t?1:t,r=e.cap,i=void 0===r||r;return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,Object.assign({},e,{topRadius:0,topCap:Boolean(i),bottomCap:Boolean(i),bottomRadius:n})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,r["a"]),o}();t.a=i},function(e,t,i){"use strict";var n=i(45),o=i(8);var r=function(e){function r(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var t=e.id,n=void 0===t?i.i(o.d)("cube-geometry"):t;return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,Object.assign({},e,{id:n,attributes:{indices:new Uint16Array(a),positions:new Float32Array(s),normals:new Float32Array(u),texCoords:new Float32Array(c)}})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,n["a"]),r}();t.a=r;var a=new Uint16Array([0,1,2,0,2,3,4,5,6,4,6,7,8,9,10,8,10,11,12,13,14,12,14,15,16,17,18,16,18,19,20,21,22,20,22,23]),s=new Float32Array([-1,-1,1,1,-1,1,1,1,1,-1,1,1,-1,-1,-1,-1,1,-1,1,1,-1,1,-1,-1,-1,1,-1,-1,1,1,1,1,1,1,1,-1,-1,-1,-1,1,-1,-1,1,-1,1,-1,-1,1,1,-1,-1,1,1,-1,1,1,1,1,-1,1,-1,-1,-1,-1,-1,1,-1,1,1,-1,1,-1]),u=new Float32Array([0,0,1,0,0,1,0,0,1,0,0,1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,1,0,0,1,0,0,1,0,0,1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,1,0,0,1,0,0,1,0,0,1,0,0,-1,0,0,-1,0,0,-1,0,0,-1,0,0]),c=new Float32Array([0,0,1,0,1,1,0,1,1,0,1,1,0,1,0,0,0,1,0,0,1,0,1,1,1,1,0,1,0,0,1,0,1,0,1,1,0,1,0,0,0,0,1,0,1,1,0,1])},function(e,t,n){"use strict";var i=n(105);var r=function(e){function r(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var t=e.radius,n=void 0===t?1:t;return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,Object.assign({},e,{bottomRadius:n,topRadius:n})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,i["a"]),r}();t.a=r},function(e,t,n){"use strict";var r=n(45),Y=n(16);var K=[-1,0,0,0,1,0,0,0,-1,0,0,1,0,-1,0,1,0,0],Z=[3,4,5,3,5,1,3,1,0,3,0,4,4,0,2,4,2,5,2,0,1,5,2,1],i=function(e){function H(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,H);var t=e.iterations,n=void 0===t?0:t,r=Math.PI,i=2*r,l=[].concat(K),o=[].concat(Z);l.push(),o.push();for(var f,a=(f={},function(e,t){var n=((e*=3)<(t*=3)?e:t)+"|"+(t<e?e:t);if(n in f)return f[n];var r=l[e],i=l[e+1],o=l[e+2],a=(r+l[t])/2,s=(i+l[t+1])/2,u=(o+l[t+2])/2,c=Math.sqrt(a*a+s*s+u*u);return a/=c,s/=c,u/=c,l.push(a,s,u),f[n]=l.length/3-1}),s=0;s<n;s++){for(var u=[],c=0;c<o.length;c+=3){var d=a(o[c+0],o[c+1]),h=a(o[c+1],o[c+2]),p=a(o[c+2],o[c+0]);u.push(p,o[c+0],d,d,o[c+1],h,h,o[c+2],p,d,h,p)}o=u}for(var v=new Array(3*o.length),g=new Array(2*o.length),y=o.length-3;0<=y;y-=3){var _=o[y+0],m=o[y+1],b=o[y+2],E=3*_,w=3*m,P=3*b,S=2*_,A=2*m,T=2*b,x=l[E+0],O=l[E+1],R=l[E+2],C=Math.acos(R/Math.sqrt(x*x+O*O+R*R))/r,k=1-(Math.atan2(O,x)+r)/i,M=l[w+0],L=l[w+1],I=l[w+2],N=Math.acos(I/Math.sqrt(M*M+L*L+I*I))/r,F=1-(Math.atan2(L,M)+r)/i,j=l[P+0],D=l[P+1],B=l[P+2],U=Math.acos(B/Math.sqrt(j*j+D*D+B*B))/r,G=1-(Math.atan2(D,j)+r)/i,V=[j-M,D-L,B-I],z=[x-M,O-L,R-I],W=new Y.Vector3(V).cross(z).normalize(),X=void 0;(0===k||0===F||0===G)&&(0===k||.5<k)&&(0===F||.5<F)&&(0===G||.5<G)&&(l.push(l[E+0],l[E+1],l[E+2]),X=l.length/3-1,o.push(X),g[2*X+0]=1,g[2*X+1]=C,v[3*X+0]=W.x,v[3*X+1]=W.y,v[3*X+2]=W.z,l.push(l[w+0],l[w+1],l[w+2]),X=l.length/3-1,o.push(X),g[2*X+0]=1,g[2*X+1]=N,v[3*X+0]=W.x,v[3*X+1]=W.y,v[3*X+2]=W.z,l.push(l[P+0],l[P+1],l[P+2]),X=l.length/3-1,o.push(X),g[2*X+0]=1,g[2*X+1]=U,v[3*X+0]=W.x,v[3*X+1]=W.y,v[3*X+2]=W.z),v[E+0]=v[w+0]=v[P+0]=W.x,v[E+1]=v[w+1]=v[P+1]=W.y,v[E+2]=v[w+2]=v[P+2]=W.z,g[S+0]=k,g[S+1]=C,g[A+0]=F,g[A+1]=N,g[T+0]=G,g[T+1]=U}return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(H.__proto__||Object.getPrototypeOf(H)).call(this,Object.assign({},e,{attributes:{positions:new Float32Array(l),normals:new Float32Array(v),texCoords:new Float32Array(g),indices:new Uint16Array(o)}})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(H,r["a"]),H}();t.a=i},function(e,t,D){"use strict";var n=D(45),B=D(8);var r=function(e){function j(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,j);var t=e.type,n=void 0===t?"x,y":t,r=e.offset,i=void 0===r?0:r,o=e.flipCull,a=void 0!==o&&o,s=e.unpack,u=void 0!==s&&s,c=e.id,l=void 0===c?D.i(B.d)("plane-geometry"):c,f=n.split(","),d=e[f[0]+"len"],h=e[f[1]+"len"],p=e["n"+f[0]]||1,v=e["n"+f[1]]||1,g=(p+1)*(v+1),y=new Float32Array(3*g),_=new Float32Array(3*g),m=new Float32Array(2*g);a&&(d=-d);for(var b=0,E=0,w=0;w<=v;w++)for(var P=0;P<=p;P++){var S=P/p,A=w/v;switch(m[b+0]=a?1-S:S,m[b+1]=A,n){case"x,y":y[E+0]=d*S-.5*d,y[E+1]=h*A-.5*h,y[E+2]=i,_[E+0]=0,_[E+1]=0,_[E+2]=a?1:-1;break;case"x,z":y[E+0]=d*S-.5*d,y[E+1]=i,y[E+2]=h*A-.5*h,_[E+0]=0,_[E+1]=a?1:-1,_[E+2]=0;break;case"y,z":y[E+0]=i,y[E+1]=d*S-.5*d,y[E+2]=h*A-.5*h,_[E+0]=a?1:-1,_[E+1]=0,_[E+2]=0}b+=2,E+=3}for(var T=p+1,x=new Uint16Array(p*v*6),O=0;O<v;O++)for(var R=0;R<p;R++){var C=6*(O*p+R);x[C+0]=(O+0)*T+R,x[C+1]=(O+1)*T+R,x[C+2]=(O+0)*T+R+1,x[C+3]=(O+1)*T+R,x[C+4]=(O+1)*T+R+1,x[C+5]=(O+0)*T+R+1}if(u){for(var k=new Float32Array(3*x.length),M=new Float32Array(3*x.length),L=new Float32Array(2*x.length),I=0;I<x.length;++I){var N=x[I];k[3*I+0]=y[3*N+0],k[3*I+1]=y[3*N+1],k[3*I+2]=y[3*N+2],M[3*I+0]=_[3*N+0],M[3*I+1]=_[3*N+1],M[3*I+2]=_[3*N+2],L[2*I+0]=m[2*N+0],L[2*I+1]=m[2*N+1]}y=k,_=M,m=L,x=void 0}var F={positions:y,normals:_,texCoords:m};return x&&(F.indices=x),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(j.__proto__||Object.getPrototypeOf(j)).call(this,Object.assign({},e,{attributes:F,id:l})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(j,n["a"]),j}();t.a=r},function(e,t,l){"use strict";var n=l(45),f=l(8);var r=function(e){function c(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c);var t=e.nlat,n=void 0===t?10:t,r=e.nlong,i=void 0===r?10:r,o=e.radius,a=void 0===o?1:o,s=e.id,u=void 0===s?l.i(f.d)("sphere-geometry"):s;return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(c.__proto__||Object.getPrototypeOf(c)).call(this,Object.assign({},e,{id:u,attributes:function(e,t,n){var r=Math.PI-0,i=2*Math.PI-0,o=(e+1)*(t+1);if("number"==typeof n){var a=n;n=function(e,t,n,r,i){return a}}for(var s=new Float32Array(3*o),u=new Float32Array(3*o),c=new Float32Array(2*o),l=new Uint16Array(e*t*6),f=0;f<=e;f++)for(var d=0;d<=t;d++){var h=d/t,p=f/e,v=d+f*(t+1),g=2*v,y=3*v,_=i*h,m=r*p,b=Math.sin(_),E=Math.cos(_),w=Math.sin(m),P=Math.cos(m),S=E*w,A=P,T=b*w,x=n(S,A,T,h,p);s[y+0]=x*S,s[y+1]=x*A,s[y+2]=x*T,u[y+0]=S,u[y+1]=A,u[y+2]=T,c[g+0]=h,c[g+1]=p}for(var O=e+1,R=0;R<e;R++)for(var C=0;C<t;C++){var k=6*(R*t+C);l[k+0]=C*O+R,l[k+1]=C*O+R+1,l[k+2]=(C+1)*O+R,l[k+3]=(C+1)*O+R,l[k+4]=C*O+R+1,l[k+5]=(C+1)*O+R+1}return{positions:s,indices:l,normals:u,texCoords:c}}(n,i,a)})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(c,n["a"]),c}();t.a=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setPathPrefix=function(e){o=e},t.loadFile=function(e,t){"string"==typeof e||t||(e=(t=e).url);return t.url=o?o+e:e,(0,r.requestFile)(t)},t.loadImage=function(r,i){return r=o?o+r:r,new Promise(function(e,t){try{var n=new Image;n.onload=function(){return e(n)},n.onerror=function(){return t(new Error("Could not load image "+r+"."))},n.crossOrigin=i&&i.crossOrigin||"anonymous",n.src=r}catch(e){t(e)}})};var r=n(629),o=""},function(e,t,S){"use strict";t.a=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.vs,r=t.fs,i=S.i(f.d)(t.modules||[]);return{gl:e,vs:c(e,Object.assign({},t,{source:n,type:u,modules:i})),fs:c(e,Object.assign({},t,{source:r,type:x,modules:i})),getUniforms:(l=i,function(e){var t={},n=!0,r=!1,i=void 0;try{for(var o,a=l[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var s=o.value,u=S.i(f.c)(s),c=u.getUniforms?u.getUniforms(e,t):{};Object.assign(t,c)}}catch(e){r=!0,i=e}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}return t}),modules:function(e){var t={},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,u=S.i(f.c)(s);t[s]=u}}catch(e){r=!0,i=e}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}return t}(i)};var l};var n,r,f=S(162),A=S(643),i=S(655),o=S(1),T=S.n(o),a=S(8);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var u="vs",x="fs",O=(s(n={},u,"vertex"),s(n,x,"fragment"),n),R=(s(r={},u,i.a),s(r,x,i.b),r),C="#ifdef GL_ES\nprecision highp float;\n#endif\n\n";function k(e,t){S.i(f.c)(e).deprecations.forEach(function(e){e.regex.test(t)&&(e.deprecated?a.b.deprecated(e.old,e.new):a.b.removed(e.old,e.new))})}function M(e,t){var n=S.i(f.c)(e),r=void 0;switch(t){case u:r=n.vs||n.vertexShader;break;case x:r=n.fs||n.fragmentShader;break;default:T()(!1)}return"string"!=typeof r?"":"#define MODULE_"+e.toUpperCase()+"\n"+r+"// END MODULE_"+e+"\n\n"}function c(e,t){var n=t.id,r=t.source,i=t.type,o=t.modules,a=void 0===o?[]:o,s=t.defines,u=void 0===s?{}:s;T()("string"==typeof r,"shader source must be a string");var c=r.split("\n"),l="",f=r;0===c[0].indexOf("#version ")&&(l=c[0],f=c.slice(1).join("\n"));var d,h,p,v,g=(h=(d={id:n,source:r,type:i}).id,p=d.source,v=d.type,(h&&"string"==typeof h&&-1===p.indexOf("SHADER_NAME")?"\n#define SHADER_NAME "+h+"_"+O[v]+"\n\n":"")+"\n"+S.i(A.a)(e)+"\n"+S.i(A.b)(e)+"\n"+function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=0,n="";for(var r in e)0===t&&(n+="\n// APPLICATION DEFINES\n"),t++,n+="#define "+r.toUpperCase()+" "+e[r]+"\n";return 0===t&&(n+="\n"),n}(u)+"\n"+(i===x?C:"")+"\n"),y=!1,_=!0,m=!1,b=void 0;try{for(var E,w=a[Symbol.iterator]();!(_=(E=w.next()).done);_=!0){var P=E.value;switch(P){case"inject":y=!0;break;default:k(P,f),g+=M(P,i)}}}catch(e){m=!0,b=e}finally{try{!_&&w.return&&w.return()}finally{if(m)throw b}}return g=l+g+f,y&&g.replace("}s*$",R),g}},function(e,t,n){"use strict";var r=n(111),a=n(109),i=n(1),o=n.n(i),s=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var u=function(){function i(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.gl,n=e._cachePrograms,r=void 0!==n&&n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),o()(t),this.gl=t,this.vertexShaders={},this.fragmentShaders={},this.programs={},this._cachePrograms=r}return s(i,[{key:"delete",value:function(){return this}},{key:"getVertexShader",value:function(e,t){o()("string"==typeof t),o()(this._compareContexts(e,this.gl));var n=this.vertexShaders[t];return n||(n=new r.b(e,t),this.vertexShaders[t]=n),n}},{key:"getFragmentShader",value:function(e,t){o()("string"==typeof t),o()(this._compareContexts(e,this.gl));var n=this.fragmentShaders[t];return n||(n=new r.c(e,t),this.fragmentShaders[t]=n),n}},{key:"getProgram",value:function(e,t){o()(this._compareContexts(e,this.gl)),o()("string"==typeof t.vs),o()("string"==typeof t.fs),o()("string"==typeof t.id);var n=this._getProgramKey(t),r=this.programs[n];return r?this._resetProgram(r):(r=this._createNewProgram(e,t),this._cachePrograms&&this._checkProgramProp(r)&&(this.programs[n]=r)),r}},{key:"_getProgramKey",value:function(e){return e.id+"-"+e.vs+"-"+e.fs}},{key:"_checkProgramProp",value:function(e){return!e.varyings}},{key:"_createNewProgram",value:function(e,t){var n=t.vs,r=t.fs,i=this.getVertexShader(e,n),o=this.getFragmentShader(e,r);return new a.a(this.gl,Object.assign({},t,{vs:i,fs:o}))}},{key:"_resetProgram",value:function(e,t){e.reset()}},{key:"_compareContexts",value:function(e,t){return(e.gl||e)===(t.gl||t)}}]),i}();t.a=u},function(e,t,n){"use strict";var r=n(16),i=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],o={modelMatrix:i,viewMatrix:i,projectionMatrix:i,cameraPositionWorld:[0,0,0]};t.a={name:"project",getUniforms:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:o,t=(1<arguments.length&&void 0!==arguments[1]&&arguments[1],{});return void 0!==e.modelMatrix&&(t.modelMatrix=e.modelMatrix),void 0!==e.viewMatrix&&(t.viewMatrix=e.viewMatrix),void 0!==e.projectionMatrix&&(t.projectionMatrix=e.projectionMatrix),void 0!==e.cameraPositionWorld&&(t.cameraPositionWorld=e.cameraPositionWorld),void 0===e.projectionMatrix&&void 0===e.viewMatrix||(t.viewProjectionMatrix=new r.Matrix4(e.projectionMatrix).multiplyRight(e.viewMatrix)),t},vs:"varying vec4 project_vPositionWorld;\nvarying vec3 project_vNormalWorld;\n\nvec4 project_getPosition_World() {\n return project_vPositionWorld;\n}\n\nvec3 project_getNormal_World() {\n return project_vNormalWorld;\n}\n\n\n// Unprefixed uniforms\nuniform mat4 modelMatrix;\nuniform mat4 viewMatrix;\nuniform mat4 projectionMatrix;\nuniform mat4 viewProjectionMatrix;\nuniform vec3 cameraPositionWorld;\n\nstruct World {\n vec3 position;\n vec3 normal;\n};\n\nWorld world;\n\nvoid project_setPosition(vec4 position) {\n project_vPositionWorld = position;\n}\n\nvoid project_setNormal(vec3 normal) {\n project_vNormalWorld = normal;\n}\n\nvoid project_setPositionAndNormal_World(vec3 position, vec3 normal) {\n world.position = position;\n world.normal = normal;\n}\n\nvoid project_setPositionAndNormal_Model(vec3 position, vec3 normal) {\n world.position = (modelMatrix * vec4(position, 1.)).xyz;\n world.normal = mat3(modelMatrix) * normal;\n}\n\nvec4 project_model_to_clipspace(vec4 position) {\n return viewProjectionMatrix * modelMatrix * position;\n}\n\nvec4 project_model_to_clipspace(vec3 position) {\n return viewProjectionMatrix * modelMatrix * vec4(position, 1.);\n}\n\nvec4 project_world_to_clipspace(vec3 position) {\n return viewProjectionMatrix * vec4(position, 1.);\n}\n\nvec4 project_view_to_clipspace(vec3 position) {\n return projectionMatrix * vec4(position, 1.);\n}\n\nvec4 project_to_clipspace(vec3 position) {\n return viewProjectionMatrix * vec4(position, 1.);\n}\n",fs:"\nvarying vec4 project_vPositionWorld;\nvarying vec3 project_vNormalWorld;\n\nvec4 project_getPosition_World() {\n return project_vPositionWorld;\n}\n\nvec3 project_getNormal_World() {\n return project_vNormalWorld;\n}\n"}},function(e,r,i){"use strict";(function(e){i.d(r,"a",function(){return t}),i.d(r,"b",function(){return n});var t="undefined"!=typeof window?window:e,n=void 0!==e?e:window;"undefined"!=typeof document&&document}).call(r,i(47))},function(e,r,i){"use strict";(function(e){i.d(r,"a",function(){return n});var t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n=!("object"===(void 0===e?"undefined":t(e))&&"[object process]"===String(e)&&!e.browser)}).call(r,i(26))},function(e,t,n){"use strict";t.b=u,console.debug=console.debug||console.log;var o={},l={priority:0,table:function(e,t){e<=l.priority&&t&&console.table(t)},log:function(e,t){if(e<=l.priority){for(var n,r=arguments.length,i=Array(2<r?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];(n=console).debug.apply(n,["luma.gl: "+t].concat(i))}},info:function(e,t){if(e<=l.priority){for(var n,r=arguments.length,i=Array(2<r?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];(n=console).log.apply(n,["luma.gl: "+t].concat(i))}},once:function(e,t){if(!o[t]){for(var n=arguments.length,r=Array(2<n?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];l.log.apply(l,[e,t].concat(r)),o[t]=!0}},warn:function(e){if(!o[e]){for(var t,n=arguments.length,r=Array(1<n?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];(t=console).warn.apply(t,["luma.gl: "+e].concat(r)),o[e]=!0}},error:function(e){for(var t,n=arguments.length,r=Array(1<n?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];(t=console).error.apply(t,["luma.gl: "+e].concat(r))},image:function(e){var t=e.priority,n=e.image,r=e.message,i=void 0===r?"":r,o=e.scale,a=void 0===o?1:o;if(!(t>l.priority)&&"undefined"!=typeof window){if("string"==typeof n){var s=new Image;s.onload=f.bind(null,s,i,a),s.src=n}var u=n.nodeName||"";if("img"===u.toLowerCase()&&f(n,i,a),"canvas"===u.toLowerCase()){var c=new Image;c.onload=f.bind(null,c,i,a),c.src=n.toDataURL()}}},deprecated:function(e,t){l.warn("`"+e+"` is deprecated and will be removed in a later version. Use `"+t+"` instead")},removed:function(e,t){l.error("`"+e+"` is no longer supported. Use `"+t+"` instead, check our Upgrade Guide for more details")},group:function(e,t){var n=(2<arguments.length&&void 0!==arguments[2]?arguments[2]:{}).collapsed,r=void 0!==n&&n;e<=l.priority&&(r?console.groupCollapsed("luma.gl: "+t):console.group("luma.gl: "+t))},groupEnd:function(e,t){e<=l.priority&&console.groupEnd("luma.gl: "+t)},time:function(e,t){e<=l.priority&&(console.time?console.time(t):console.info(t))},timeEnd:function(e,t){e<=l.priority&&(console.timeEnd?console.timeEnd(t):console.info(t))}};function f(e,t,n){var r=e.width*n,i=e.height*n,o=e.src.replace(/\(/g,"%28").replace(/\)/g,"%29");console.log(t+" %c+",["font-size:1px;","padding:"+Math.floor(i/2)+"px "+Math.floor(r/2)+"px;","line-height:"+i+"px;","background:url("+o+");","background-size:"+r+"px "+i+"px;","color:transparent;"].join(""))}function u(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.isInteger,r=void 0!==n&&n;if(Array.isArray(e)||ArrayBuffer.isView(e))return function(e,t){for(var n=t.maxElts,r=void 0===n?16:n,i=t.size,o=void 0===i?1:i,a="[",s=0;s<e.length&&s<r;++s)0<s&&(a+=","+(s%o==0?" ":"")),a+=u(e[s],t);return a+(e.length>r?"...":"]")}(e,t);if(!Number.isFinite(e))return String(e);if(Math.abs(e)<1e-16)return r?"0":"0.";if(r)return e.toFixed(0);if(100<Math.abs(e)&&Math.abs(e)<1e4)return e.toFixed(0);var i=e.toPrecision(2);return i.indexOf(".0")===i.length-2?i.slice(0,-1):i}t.a=l},function(e,t,n){"use strict";t.a=function(e){var t=e.match(/#define[\s*]SHADER_NAME[\s*]([A-Za-z0-9_-]+)[\s*]/);return t?t[1]:"unnamed"},t.b=function(e){switch(e){case r:return"fragment";case i:return"vertex";default:return"unknown type"}};var r=35632,i=35633},function(e,t,n){"use strict";t.a=function(e){if(e.luma=e.luma||{},function(e){e.luma.extensions={};var t=e.getSupportedExtensions(),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;e.luma[s]=e.getExtension(s)}}catch(e){r=!0,i=e}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}}(e),!e.luma.polyfilled){for(var t in h)"overrides"!==t&&s(e,{extension:t,target:e.luma,target2:e});n={target:(r=e).luma,target2:e},i=n.target,o=n.target2,a=h.OVERRIDES,Object.keys(a).forEach(function(e){if("function"==typeof a[e]){var t=r[e]?r[e].bind(r):function(){},n=a[e].bind(null,r,t);i[e]=n,o[e]=n}}),e.luma.polyfilled=!0}var r,n,i,o,a;return e};var r,i=n(1),l=n.n(i),o=n(666);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var f="ANGLE_instanced_arrays";function d(e){return e&&32874===e.TEXTURE_BINDING_3D}var h=(a(r={},"OES_vertex_array_object",{meta:{suffix:"OES"},createVertexArray:function(){l()(!1,"VertexArray requires WebGL2 or OES_vertex_array_object extension")},deleteVertexArray:function(){},bindVertexArray:function(){},isVertexArray:function(){return!1}}),a(r,f,{meta:{suffix:"ANGLE"},vertexAttribDivisor:function(e,t){l()(0===t,"WebGL instanced rendering not supported")},drawElementsInstanced:function(){},drawArraysInstanced:function(){}}),a(r,"WEBGL_draw_buffers",{meta:{suffix:"WEBGL"},drawBuffers:function(){l()(!1)}}),a(r,"EXT_disjoint_timer_query",{meta:{suffix:"EXT"},createQuery:function(){l()(!1)},deleteQuery:function(){l()(!1)},beginQuery:function(){l()(!1)},endQuery:function(){},getQuery:function(e,t){return this.getQueryObject(e,t)},getQueryParameter:function(e,t){return this.getQueryObject(e,t)},queryCounter:function(){},getQueryObject:function(){}}),a(r,"EXT_disjoint_timer_query_webgl2",{meta:{suffix:"EXT"},queryCounter:null}),a(r,"OVERRIDES",{readBuffer:function(e,t,n){d(e)&&t(n)},getVertexAttrib:function(e,t,n,r){var i,o,a=(o=f,{webgl2:d(i=e),ext:i.getExtension(o)}),s=a.webgl2,u=a.ext,c=void 0;switch(r){case 35069:c=!!s&&void 0;break;case 35070:c=s||u?void 0:0}return void 0!==c?c:t(n,r)},getProgramParameter:function(e,t,n,r){if(!d(e))switch(r){case 35967:return 35981;case 35971:case 35382:return 0}return t(n,r)},getInternalformatParameter:function(e,t,n,r,i){if(!d(e))switch(i){case 32937:return new Int32Array([0])}return e.getInternalformatParameter(n,r,i)},getTexParameter:function(e,t,n,r){switch(r){case 34046:var i=e.luma.extensions.EXT_texture_filter_anisotropic;r=i&&i.TEXTURE_MAX_ANISOTROPY_EXT||34046}return t(n,r)},getParameter:o.a,hint:function(e,t,n,r){return t(n,r)}}),r);function s(r,e){var t=e.extension,i=e.target,o=e.target2,a=h[t];l()(a);var n=a.meta,s=(void 0===n?{}:n).suffix,u=void 0===s?"":s,c=r.getExtension(t);Object.keys(a).forEach(function(e){var t=""+e+u,n=null;"meta"===e||"function"==typeof r[e]||(c&&"function"==typeof c[t]?n=function(){return c[t].apply(c,arguments)}:"function"==typeof a[e]&&(n=a[e].bind(i))),n&&(i[e]=n,o[e]=n)})}},function(e,t,r){"use strict";r.d(t,"b",function(){return d}),t.e=function(e,t,n){var r=m[t],i=r?r(e,Number(t)):e.getParameter(Number(t)),o=g[t];return c()("function"==typeof o),o(e,n,Number(t)),i},t.c=E,t.d=w,t.a=P,t.f=function(e){E(e,Object.assign({},d,{}))},t.g=function(e){var t=P(d),n={};for(var r in d)b(t[r],d[r])||(n[r]=t[r]);return n};var n,i,o,a=r(46),s=r(7),u=r(1),c=r.n(u);function l(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function f(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var d=(f(n={},a.a.BLEND,!1),f(n,a.a.BLEND_COLOR,new Float32Array([0,0,0,0])),f(n,a.a.BLEND_EQUATION_RGB,a.a.FUNC_ADD),f(n,a.a.BLEND_EQUATION_ALPHA,a.a.FUNC_ADD),f(n,a.a.BLEND_SRC_RGB,a.a.ONE),f(n,a.a.BLEND_DST_RGB,a.a.ZERO),f(n,a.a.BLEND_SRC_ALPHA,a.a.ONE),f(n,a.a.BLEND_DST_ALPHA,a.a.ZERO),f(n,a.a.COLOR_CLEAR_VALUE,new Float32Array([0,0,0,0])),f(n,a.a.COLOR_WRITEMASK,[!0,!0,!0,!0]),f(n,a.a.CULL_FACE,!1),f(n,a.a.CULL_FACE_MODE,a.a.BACK),f(n,a.a.DEPTH_TEST,!1),f(n,a.a.DEPTH_CLEAR_VALUE,1),f(n,a.a.DEPTH_FUNC,a.a.LESS),f(n,a.a.DEPTH_RANGE,new Float32Array([0,1])),f(n,a.a.DEPTH_WRITEMASK,!0),f(n,a.a.DITHER,!0),f(n,a.a.FRAMEBUFFER_BINDING,null),f(n,a.a.FRONT_FACE,a.a.CCW),f(n,a.a.GENERATE_MIPMAP_HINT,a.a.DONT_CARE),f(n,a.a.LINE_WIDTH,1),f(n,a.a.POLYGON_OFFSET_FILL,!1),f(n,a.a.POLYGON_OFFSET_FACTOR,0),f(n,a.a.POLYGON_OFFSET_UNITS,0),f(n,a.a.SAMPLE_COVERAGE_VALUE,1),f(n,a.a.SAMPLE_COVERAGE_INVERT,!1),f(n,a.a.SCISSOR_TEST,!1),f(n,a.a.SCISSOR_BOX,new Int32Array([0,0,1024,1024])),f(n,a.a.STENCIL_TEST,!1),f(n,a.a.STENCIL_CLEAR_VALUE,0),f(n,a.a.STENCIL_WRITEMASK,4294967295),f(n,a.a.STENCIL_BACK_WRITEMASK,4294967295),f(n,a.a.STENCIL_FUNC,a.a.ALWAYS),f(n,a.a.STENCIL_REF,0),f(n,a.a.STENCIL_VALUE_MASK,4294967295),f(n,a.a.STENCIL_BACK_FUNC,a.a.ALWAYS),f(n,a.a.STENCIL_BACK_REF,0),f(n,a.a.STENCIL_BACK_VALUE_MASK,4294967295),f(n,a.a.STENCIL_FAIL,a.a.KEEP),f(n,a.a.STENCIL_PASS_DEPTH_FAIL,a.a.KEEP),f(n,a.a.STENCIL_PASS_DEPTH_PASS,a.a.KEEP),f(n,a.a.STENCIL_BACK_FAIL,a.a.KEEP),f(n,a.a.STENCIL_BACK_PASS_DEPTH_FAIL,a.a.KEEP),f(n,a.a.STENCIL_BACK_PASS_DEPTH_PASS,a.a.KEEP),f(n,a.a.VIEWPORT,new Int32Array([0,0,1024,1024])),f(n,a.a.PACK_ALIGNMENT,4),f(n,a.a.UNPACK_ALIGNMENT,4),f(n,a.a.UNPACK_FLIP_Y_WEBGL,!1),f(n,a.a.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!1),f(n,a.a.UNPACK_COLORSPACE_CONVERSION_WEBGL,a.a.BROWSER_DEFAULT_WEBGL),f(n,a.a.FRAGMENT_SHADER_DERIVATIVE_HINT,a.a.DONT_CARE),f(n,a.a.READ_FRAMEBUFFER_BINDING,null),f(n,a.a.RASTERIZER_DISCARD,!1),f(n,a.a.PACK_ROW_LENGTH,0),f(n,a.a.PACK_SKIP_PIXELS,0),f(n,a.a.PACK_SKIP_ROWS,0),f(n,a.a.UNPACK_ROW_LENGTH,0),f(n,a.a.UNPACK_IMAGE_HEIGHT,0),f(n,a.a.UNPACK_SKIP_PIXELS,0),f(n,a.a.UNPACK_SKIP_ROWS,0),f(n,a.a.UNPACK_SKIP_IMAGES,0),n),h=function(e,t,n){return t?e.enable(n):e.disable(n)},p=function(e,t,n){return e.hint(n,t)},v=function(e,t,n){return e.pixelStorei(n,t)},g=(f(i={},a.a.BLEND,h),f(i,a.a.BLEND_COLOR,function(e,t){return e.blendColor.apply(e,l(t))}),f(i,a.a.BLEND_EQUATION_RGB,"blendEquation"),f(i,a.a.BLEND_EQUATION_ALPHA,"blendEquation"),f(i,a.a.BLEND_SRC_RGB,"blendFunc"),f(i,a.a.BLEND_DST_RGB,"blendFunc"),f(i,a.a.BLEND_SRC_ALPHA,"blendFunc"),f(i,a.a.BLEND_DST_ALPHA,"blendFunc"),f(i,a.a.COLOR_CLEAR_VALUE,function(e,t){return e.clearColor.apply(e,l(t))}),f(i,a.a.COLOR_WRITEMASK,function(e,t){return e.colorMask.apply(e,l(t))}),f(i,a.a.CULL_FACE,h),f(i,a.a.CULL_FACE_MODE,function(e,t){return e.cullFace(t)}),f(i,a.a.DEPTH_TEST,h),f(i,a.a.DEPTH_CLEAR_VALUE,function(e,t){return e.clearDepth(t)}),f(i,a.a.DEPTH_FUNC,function(e,t){return e.depthFunc(t)}),f(i,a.a.DEPTH_RANGE,function(e,t){return e.depthRange.apply(e,l(t))}),f(i,a.a.DEPTH_WRITEMASK,function(e,t){return e.depthMask(t)}),f(i,a.a.DITHER,h),f(i,a.a.FRAGMENT_SHADER_DERIVATIVE_HINT,p),f(i,a.a.FRAMEBUFFER_BINDING,function(e,t){var n=r.i(s.b)(e)?a.a.DRAW_FRAMEBUFFER:a.a.FRAMEBUFFER;return e.bindFramebuffer(n,t)}),f(i,a.a.FRONT_FACE,function(e,t){return e.frontFace(t)}),f(i,a.a.GENERATE_MIPMAP_HINT,p),f(i,a.a.LINE_WIDTH,function(e,t){return e.lineWidth(t)}),f(i,a.a.POLYGON_OFFSET_FILL,h),f(i,a.a.POLYGON_OFFSET_FACTOR,"polygonOffset"),f(i,a.a.POLYGON_OFFSET_UNITS,"polygonOffset"),f(i,a.a.RASTERIZER_DISCARD,h),f(i,a.a.SAMPLE_COVERAGE_VALUE,"sampleCoverage"),f(i,a.a.SAMPLE_COVERAGE_INVERT,"sampleCoverage"),f(i,a.a.SCISSOR_TEST,h),f(i,a.a.SCISSOR_BOX,function(e,t){return e.scissor.apply(e,l(t))}),f(i,a.a.STENCIL_TEST,h),f(i,a.a.STENCIL_CLEAR_VALUE,function(e,t){return e.clearStencil(t)}),f(i,a.a.STENCIL_WRITEMASK,function(e,t){return e.stencilMaskSeparate(a.a.FRONT,t)}),f(i,a.a.STENCIL_BACK_WRITEMASK,function(e,t){return e.stencilMaskSeparate(a.a.BACK,t)}),f(i,a.a.STENCIL_FUNC,"stencilFuncFront"),f(i,a.a.STENCIL_REF,"stencilFuncFront"),f(i,a.a.STENCIL_VALUE_MASK,"stencilFuncFront"),f(i,a.a.STENCIL_BACK_FUNC,"stencilFuncBack"),f(i,a.a.STENCIL_BACK_REF,"stencilFuncBack"),f(i,a.a.STENCIL_BACK_VALUE_MASK,"stencilFuncBack"),f(i,a.a.STENCIL_FAIL,"stencilOpFront"),f(i,a.a.STENCIL_PASS_DEPTH_FAIL,"stencilOpFront"),f(i,a.a.STENCIL_PASS_DEPTH_PASS,"stencilOpFront"),f(i,a.a.STENCIL_BACK_FAIL,"stencilOpBack"),f(i,a.a.STENCIL_BACK_PASS_DEPTH_FAIL,"stencilOpBack"),f(i,a.a.STENCIL_BACK_PASS_DEPTH_PASS,"stencilOpBack"),f(i,a.a.VIEWPORT,function(e,t){return e.viewport.apply(e,l(t))}),f(i,a.a.PACK_ALIGNMENT,v),f(i,a.a.UNPACK_ALIGNMENT,v),f(i,a.a.UNPACK_FLIP_Y_WEBGL,v),f(i,a.a.UNPACK_PREMULTIPLY_ALPHA_WEBGL,v),f(i,a.a.UNPACK_COLORSPACE_CONVERSION_WEBGL,v),f(i,a.a.PACK_ROW_LENGTH,v),f(i,a.a.PACK_SKIP_PIXELS,v),f(i,a.a.PACK_SKIP_ROWS,v),f(i,a.a.READ_FRAMEBUFFER_BINDING,function(e,t){return e.bindFramebuffer(a.a.READ_FRAMEBUFFER,t)}),f(i,a.a.UNPACK_ROW_LENGTH,v),f(i,a.a.UNPACK_IMAGE_HEIGHT,v),f(i,a.a.UNPACK_SKIP_PIXELS,v),f(i,a.a.UNPACK_SKIP_ROWS,v),f(i,a.a.UNPACK_SKIP_IMAGES,v),i),y={blendEquation:function(e,t){return e.blendEquationSeparate(t[a.a.BLEND_EQUATION_RGB],t[a.a.BLEND_EQUATION_ALPHA])},blendFunc:function(e,t){return e.blendFuncSeparate(t[a.a.BLEND_SRC_RGB],t[a.a.BLEND_DST_RGB],t[a.a.BLEND_SRC_ALPHA],t[a.a.BLEND_DST_ALPHA])},polygonOffset:function(e,t){return e.polygonOffset(t[a.a.POLYGON_OFFSET_FACTOR],t[a.a.POLYGON_OFFSET_UNITS])},sampleCoverage:function(e,t){return e.sampleCoverage(t[a.a.SAMPLE_COVERAGE_VALUE],t[a.a.SAMPLE_COVERAGE_INVERT])},stencilFuncFront:function(e,t){return e.stencilFuncSeparate(a.a.FRONT,t[a.a.STENCIL_FUNC],t[a.a.STENCIL_REF],t[a.a.STENCIL_VALUE_MASK])},stencilFuncBack:function(e,t){return e.stencilFuncSeparate(a.a.BACK,t[a.a.STENCIL_BACK_FUNC],t[a.a.STENCIL_BACK_REF],t[a.a.STENCIL_BACK_VALUE_MASK])},stencilOpFront:function(e,t){return e.stencilOpSeparate(a.a.FRONT,t[a.a.STENCIL_FAIL],t[a.a.STENCIL_PASS_DEPTH_FAIL],t[a.a.STENCIL_PASS_DEPTH_PASS])},stencilOpBack:function(e,t){return e.stencilOpSeparate(a.a.BACK,t[a.a.STENCIL_BACK_FAIL],t[a.a.STENCIL_BACK_PASS_DEPTH_FAIL],t[a.a.STENCIL_BACK_PASS_DEPTH_PASS])}},_=function(e,t){return e.isEnabled(t)},m=(f(o={},a.a.BLEND,_),f(o,a.a.CULL_FACE,_),f(o,a.a.DEPTH_TEST,_),f(o,a.a.DITHER,_),f(o,a.a.POLYGON_OFFSET_FILL,_),f(o,a.a.SAMPLE_ALPHA_TO_COVERAGE,_),f(o,a.a.SAMPLE_COVERAGE,_),f(o,a.a.SCISSOR_TEST,_),f(o,a.a.STENCIL_TEST,_),f(o,a.a.RASTERIZER_DISCARD,_),o),b=function(e,t){if(e===t)return!0;var n=Array.isArray(e)||ArrayBuffer.isView(e),r=Array.isArray(t)||ArrayBuffer.isView(t);if(n&&r&&e.length===t.length){for(var i=0;i<e.length;++i)if(e[i]!==t[i])return!1;return!0}return!1};function E(e,t){var n={};for(var r in t){var i=g[r];i&&("string"==typeof i?n[i]=!0:i(e,t[r],Number(r)))}var o=e.state&&e.state.cache;if(o){var a=Object.assign({},o,t);for(var s in n){(0,y[s])(e,a)}}}function w(e,t){var n=m[t];return n?n(e,Number(t)):e.getParameter(Number(t))}function P(e,t){t=t||d;var n=Array.isArray(t)?t:Object.keys(t),r={},i=!0,o=!1,a=void 0;try{for(var s,u=n[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value;r[c]=w(e,c)}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}return r}},function(e,t,n){"use strict";t.a=function(){l.a.PARAMETERS=_,f.a.PARAMETERS=m,d.a.ATTACHMENT_PARAMETERS=b,d.a.STATUS=E,h.a.PARAMETERS=w,p.a.PARAMETERS=P,v.a.PARAMETERS=S,g.a.PARAMETERS=A};var r,i,o,a,s,u,c=n(46),l=n(67),f=n(271),d=n(69),h=n(109),p=n(110),v=n(274),g=n(62);function y(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var _=(y(r={},c.a.BUFFER_SIZE,{webgl1:0}),y(r,c.a.BUFFER_USAGE,{webgl1:0}),r),m=[c.a.OBJECT_TYPE,c.a.SYNC_STATUS,c.a.SYNC_CONDITION,c.a.SYNC_FLAGS],b=[c.a.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME,c.a.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE,c.a.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE,c.a.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL,c.a.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING,c.a.FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER,c.a.FRAMEBUFFER_ATTACHMENT_RED_SIZE,c.a.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE,c.a.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE,c.a.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE,c.a.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE,c.a.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE,c.a.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE],E=(y(i={},c.a.FRAMEBUFFER_COMPLETE,"Success. Framebuffer is correctly set up"),y(i,c.a.FRAMEBUFFER_INCOMPLETE_ATTACHMENT,"Framebuffer attachment types mismatched or some attachment point not attachment complete"),y(i,c.a.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT,"Framebuffer has no attachment"),y(i,c.a.FRAMEBUFFER_INCOMPLETE_DIMENSIONS,"Framebuffer attachments do not have the same size"),y(i,c.a.FRAMEBUFFER_UNSUPPORTED,"Framebuffer attachment format not supported or depth and stencil attachments are not same"),y(i,c.a.FRAMEBUFFER_INCOMPLETE_MULTISAMPLE,"Framebuffer attachement SAMPLES differs among renderbuffers, or are mixed with textures"),i),w=(y(o={},c.a.DELETE_STATUS,{webgl1:0}),y(o,c.a.LINK_STATUS,{webgl1:0}),y(o,c.a.VALIDATE_STATUS,{webgl1:0}),y(o,c.a.ATTACHED_SHADERS,{webgl1:0}),y(o,c.a.ACTIVE_ATTRIBUTES,{webgl1:0}),y(o,c.a.ACTIVE_UNIFORMS,{webgl1:0}),y(o,c.a.TRANSFORM_FEEDBACK_BUFFER_MODE,{webgl2:0}),y(o,c.a.TRANSFORM_FEEDBACK_VARYINGS,{webgl2:0}),y(o,c.a.ACTIVE_UNIFORM_BLOCKS,{webgl2:0}),o),P=(y(a={},c.a.RENDERBUFFER_WIDTH,{webgl1:0}),y(a,c.a.RENDERBUFFER_HEIGHT,{webgl1:0}),y(a,c.a.RENDERBUFFER_INTERNAL_FORMAT,{type:"GLenum",webgl1:c.a.RGBA4}),y(a,c.a.RENDERBUFFER_GREEN_SIZE,{webgl1:0}),y(a,c.a.RENDERBUFFER_BLUE_SIZE,{webgl1:0}),y(a,c.a.RENDERBUFFER_RED_SIZE,{webgl1:0}),y(a,c.a.RENDERBUFFER_ALPHA_SIZE,{webgl1:0}),y(a,c.a.RENDERBUFFER_DEPTH_SIZE,{webgl1:0}),y(a,c.a.RENDERBUFFER_STENCIL_SIZE,{webgl1:0}),y(a,c.a.RENDERBUFFER_SAMPLES,{webgl2:1}),a),S=(y(s={},c.a.TEXTURE_MAG_FILTER,{webgl2:!0}),y(s,c.a.TEXTURE_MIN_FILTER,{webgl2:!0}),y(s,c.a.TEXTURE_WRAP_S,{webgl2:!0}),y(s,c.a.TEXTURE_WRAP_T,{webgl2:!0}),y(s,c.a.TEXTURE_WRAP_R,{webgl2:!0}),y(s,c.a.TEXTURE_BASE_LEVEL,{webgl2:!0}),y(s,c.a.TEXTURE_MAX_LEVEL,{webgl2:!0}),y(s,c.a.TEXTURE_COMPARE_FUNC,{webgl2:!0}),y(s,c.a.TEXTURE_COMPARE_MODE,{webgl2:!0}),y(s,c.a.TEXTURE_MIN_LOD,{webgl2:!0}),y(s,c.a.TEXTURE_MAX_LOD,{webgl2:!0}),s),A=(y(u={},c.a.TEXTURE_MAG_FILTER,{type:"GLenum",webgl1:c.a.LINEAR}),y(u,c.a.TEXTURE_MIN_FILTER,{type:"GLenum",webgl1:c.a.NEAREST_MIPMAP_LINEAR}),y(u,c.a.TEXTURE_WRAP_S,{type:"GLenum",webgl1:c.a.REPEAT}),y(u,c.a.TEXTURE_WRAP_T,{type:"GLenum",webgl1:c.a.REPEAT}),y(u,c.a.TEXTURE_WRAP_R,{type:"GLenum",webgl2:c.a.REPEAT}),y(u,c.a.TEXTURE_BASE_LEVEL,{webgl2:0}),y(u,c.a.TEXTURE_MAX_LEVEL,{webgl2:1e3}),y(u,c.a.TEXTURE_COMPARE_FUNC,{type:"GLenum",webgl2:c.a.LEQUAL}),y(u,c.a.TEXTURE_COMPARE_MODE,{type:"GLenum",webgl2:c.a.NONE}),y(u,c.a.TEXTURE_MIN_LOD,{webgl2:-1e3}),y(u,c.a.TEXTURE_MAX_LOD,{webgl2:1e3}),y(u,c.a.TEXTURE_WIDTH,{webgl1:0}),y(u,c.a.TEXTURE_HEIGHT,{webgl1:0}),u)},function(e,t,n){"use strict";n.d(t,"c",function(){return x}),n.d(t,"e",function(){return R}),n.d(t,"a",function(){return u}),n.d(t,"f",function(){return l}),n.d(t,"g",function(){return d}),n.d(t,"d",function(){return p}),n.d(t,"h",function(){return g}),n.d(t,"i",function(){return _}),n.d(t,"j",function(){return b}),n.d(t,"k",function(){return w}),n.d(t,"l",function(){return S}),n.d(t,"m",function(){return T}),n.d(t,"b",function(){return O});var r=n(106);function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=function e(){i(this,e)},a=r.default.globals.headlessTypes||r.global,s=a.WebGLRenderingContext,u=void 0===s?o:s,c=a.WebGLProgram,l=void 0===c?o:c,f=a.WebGLShader,d=void 0===f?o:f,h=a.WebGLBuffer,p=void 0===h?o:h,v=a.WebGLFramebuffer,g=void 0===v?o:v,y=a.WebGLRenderbuffer,_=void 0===y?o:y,m=a.WebGLTexture,b=void 0===m?o:m,E=a.WebGLUniformLocation,w=void 0===E?o:E,P=a.WebGLActiveInfo,S=void 0===P?o:P,A=a.WebGLShaderPrecisionFormat,T=void 0===A?o:A,x=u!==o&&l!==o&&d!==o&&p!==o&&g!==o&&_!==o&&b!==o&&w!==o&&S!==o&&T!==o;var O=r.global.WebGL2RenderingContext||function e(){i(this,e)},R=r.global.Image||function e(){i(this,e)}},function(e,t,n){"use strict";t.a=function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).debug;return null!==e?t?function(e){if(null===e)return null;var t=a(e);if(t.realContext)return e;if(t.debugContext)return t.debugContext;var n=o.a.makeDebugContext(e,s,l);return Object.assign(function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}.prototype,n),(t.debugContext=n).debug=!0,n.gl=e,n}(e):function(e){if(null===e)return null;var t=a(e);return t.realContext?t.realContext:e}(e):null};var r=n(688),o=n.n(r),u=n(8),i=n(267);function a(e){return e.luma=e.luma||{},e.luma}function c(e,t){var n=o.a.glFunctionArgsToString(e,t);return"gl."+e+"("+(n=n.slice(0,100)+(100<n.length?"...":""))+")"}function s(e,t,n){if(!u.b.nothrow){var r=o.a.glEnumToString(e),i=o.a.glFunctionArgsToString(t,n);throw new Error(r+" in gl."+t+"("+i+")")}}function l(e,t){if(u.b.debug){var n=void 0;if(4<=u.b.priority&&(n=c(e,t),u.b.info(4,""+n)),u.b.break){n=n||c(e,t);u.b.break&&u.b.break.every(function(e){return-1!==n.indexOf(e)})}var r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){if(void 0===a.value)throw n=n||c(e,t),new Error("Undefined argument: "+n)}}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}}}n.i(i.a)()},function(e,t,E){"use strict";t.a=function(e,t){var n=t.drawMode,r=void 0===n?w.a.TRIANGLES:n,i=t.vertexCount,o=t.offset,a=void 0===o?0:o,s=t.isIndexed,u=void 0!==s&&s,c=t.indexType,l=void 0===c?w.a.UNSIGNED_SHORT:c,f=t.isInstanced,d=void 0!==f&&f,h=t.instanceCount,p=void 0===h?0:h;E.i(P.j)(e);e.getExtension("ANGLE_instanced_arrays");if(d){var v=isWebGL2(e),g=e.getExtension("ANGLE_instanced_arrays"),y=v?e:g,_=v?"":"ANGLE",m="drawElementsInstanced"+_,b="drawArraysInstanced"+_;u?y[m](r,i,l,a,p):y[b](r,a,i,p)}else u?e.drawElements(r,i,l,a):e.drawArrays(r,a,i)};var w=E(25),P=E(7),n=E(1);E.n(n)},function(e,t,i){"use strict";var o=i(38),a=i(7),n=i(30),s=i(166),u=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var r=function(e){function r(e,t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),i.i(a.g)(e);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,t));return n.promise=null,Object.seal(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,n["a"]),u(r,[{key:"wait",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.flags,n=void 0===t?0:t,r=e.timeout,i=void 0===r?o.a.TIMEOUT_IGNORED:r;return this.gl.waitSync(this.handle,n,i),this}},{key:"clientWait",value:function(e){var t=e.flags,n=void 0===t?o.a.SYNC_FLUSH_COMMANDS_BIT:t,r=e.timeout,i=this.gl.clientWaitSync(this.handle,n,r);switch(i){case o.a.ALREADY_SIGNALED:case o.a.TIMEOUT_EXPIRED:case o.a.CONDITION_SATISFIED:case o.a.WAIT_FAILED:}return i}},{key:"cancel",value:function(){s.a.cancelQuery(this)}},{key:"isSignaled",value:function(){return this.getParameter(o.a.SYNC_STATUS)===o.a.SIGNALED}},{key:"isResultAvailable",value:function(){return this.isSignaled()}},{key:"getResult",value:function(){return this.isSignaled()}},{key:"getParameter",value:function(e){return this.gl.getSyncParameter(this.handle,e)}},{key:"_createHandle",value:function(){return this.gl.fenceSync(o.a.SYNC_GPU_COMMANDS_COMPLETE,0)}},{key:"_deleteHandle",value:function(){s.a.deleteQuery(this),this.gl.deleteSync(this.handle)}}]),r}();t.a=r},function(e,t,g){"use strict";t.a=function(e,t){var n=t.x,r=t.y,i=t.width,o=void 0===i?1:i,a=t.height,s=void 0===a?1:a,u=t.data,c=t.dataOffset,l=void 0===c?0:c,f=t.type,d=void 0===f?y.a.UNSIGNED_BYTE:f,h=t.sourceHeight,p=t.format,v=void 0===p?y.a.RGBA:p;u=u||new Uint8Array(4*o*s),r=h?h-r:r,l?(g.i(_.g)(e),e.readPixels(n,r,o,s,v,d,u,l)):e.readPixels(n,r,o,s,v,d,u);return u};var y=g(38),_=g(7),n=g(1);g.n(n)},function(e,t,d){"use strict";var n=d(30),r=d(166),h=d(108),p=d(7),v=d(60),i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var u=function(e){return e},o=function(e){function s(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(s.__proto__||Object.getPrototypeOf(s)).call(this,e,t)),r=t.onComplete,i=void 0===r?u:r,o=t.onError,a=void 0===o?u:o;return n.target=null,n.onComplete=i,n.onError=a,n.promise=null,Object.seal(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(s,n["a"]),i(s,null,[{key:"isSupported",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.queries,r=void 0!==n&&n,i=t.timers,o=void 0!==i&&i,a=t.timestamps,s=void 0!==a&&a,u=d.i(p.b)(e),c=d.i(h.c)(e,h.a.TIMER_QUERY),l=u||c;if(r&&(l=l&&u),o&&(l=l&&c),s){d.i(v.f)(e);var f=e.getQuery(36392,34916);l=l&&0<f}return l}}]),i(s,[{key:"beginTimeElapsedQuery",value:function(){return this.begin(35007)}},{key:"beginOcclusionQuery",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).conservative,t=void 0!==e&&e;return this.begin(t?36202:35887)}},{key:"beginTransformFeedbackQuery",value:function(){return this.begin(35976)}},{key:"getTimestamp",value:function(){r.a.beginQuery(this,this.onComplete,this.onError);try{this.gl.queryCounter(this.handle,36392)}catch(e){r.a.rejectQuery(this,'Timer queries require "EXT_disjoint_timer_query" extension')}return this}},{key:"begin",value:function(e){r.a.beginQuery(this,this.onComplete,this.onError),this.target=e;try{this.gl.beginQuery(this.target,this.handle)}catch(e){r.a.rejectQuery(this,"Query not supported")}return this}},{key:"end",value:function(){return this.target&&(this.ext.endQuery(this.target),this.target=null),this}},{key:"cancel",value:function(){return this.end(),r.a.cancelQuery(this),this}},{key:"isResultAvailable",value:function(){return this.gl.getQueryParameter(this.handle,34919)}},{key:"getResult",value:function(){var e=this.gl.getQueryParameter(this.handle,34918);return Number.isFinite(e)?e/1e6:0}},{key:"_createHandle",value:function(){return s.isSupported(this.gl)?this.gl.createQuery():null}},{key:"_deleteHandle",value:function(){r.a.deleteQuery(this),this.gl.deleteQuery(this.handle)}}],[{key:"poll",value:function(e){r.a.poll(e)}}]),s}();t.a=o,r.a.setInvalidator({queryType:o,errorMessage:"Disjoint GPU operation invalidated timer queries",checkInvalid:function(e){return e.getParameter(36795)}})},function(e,t,i){"use strict";var n=i(38),o=i(7),a=i(30),s=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var r=function(e){function r(e,t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),i.i(o.g)(e);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,t));return Object.seal(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,a["a"]),s(r,null,[{key:"isSupported",value:function(e){return i.i(o.b)(e)}},{key:"isHandle",value:function(e){return this.gl.isSampler(this.handle)}}]),s(r,[{key:"bind",value:function(e){return this.gl.bindSampler(e,this.handle),this}},{key:"unbind",value:function(e){return this.gl.bindSampler(e,null),this}},{key:"_createHandle",value:function(){return this.gl.createSampler()}},{key:"_deleteHandle",value:function(){this.gl.deleteSampler(this.handle)}},{key:"_getParameter",value:function(e){return this.gl.getSamplerParameter(this.handle,e)}},{key:"_setParameter",value:function(e,t){switch(e){case n.a.TEXTURE_MIN_LOD:case n.a.TEXTURE_MAX_LOD:this.gl.samplerParameterf(this.handle,e,t);break;default:this.gl.samplerParameteri(this.handle,e,t)}return this}}]),r}();t.a=r},function(e,t,n){"use strict";var S=n(25),i=n(62),r=n(1),p=n.n(r),o=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var A=[S.d.TEXTURE_CUBE_MAP_POSITIVE_X,S.d.TEXTURE_CUBE_MAP_NEGATIVE_X,S.d.TEXTURE_CUBE_MAP_POSITIVE_Y,S.d.TEXTURE_CUBE_MAP_NEGATIVE_Y,S.d.TEXTURE_CUBE_MAP_POSITIVE_Z,S.d.TEXTURE_CUBE_MAP_NEGATIVE_Z],a=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,Object.assign({},t,{target:S.d.TEXTURE_CUBE_MAP})));return n.initialize(t),Object.seal(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,i["a"]),o(r,[{key:"initialize",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.format,n=void 0===t?S.d.RGBA:t,r=e.mipmaps,i=void 0===r||r,o=e.width,a=void 0===o?1:o,s=e.height,u=void 0===s?1:s,c=e.type,l=void 0===c?S.d.UNSIGNED_BYTE:c,f=e.dataFormat,d=this._deduceParameters({format:n,type:l,dataFormat:f});l=d.type,f=d.dataFormat;var h=this._deduceImageSize({data:e[S.d.TEXTURE_CUBE_MAP_POSITIVE_X],width:a,height:u});a=h.width,u=h.height,p()(a===u),this.setCubeMapImageData(e),i&&this.generateMipmap(e),this.opts=e}},{key:"subImage",value:function(e){var t=e.face,n=e.data,r=e.x,i=void 0===r?0:r,o=e.y,a=void 0===o?0:o,s=e.mipmapLevel,u=void 0===s?0:s;return this._subImage({target:t,data:n,x:i,y:a,mipmapLevel:u})}},{key:"setCubeMapImageData",value:function(e){var t=e.width,n=e.height,r=e.pixels,i=e.data,o=e.border,a=void 0===o?0:o,s=e.format,u=void 0===s?S.d.RGBA:s,c=e.type,l=void 0===c?S.d.UNSIGNED_BYTE:c,f=(e.generateMipmap,this.gl);if(r=r||i,this.bind(),this.width||this.height){var d=!0,h=!1,p=void 0;try{for(var v,g=A[Symbol.iterator]();!(d=(v=g.next()).done);d=!0){var y=v.value;f.texImage2D(y,0,u,t,n,a,u,l,r[y])}}catch(e){h=!0,p=e}finally{try{!d&&g.return&&g.return()}finally{if(h)throw p}}}else{var _=!0,m=!1,b=void 0;try{for(var E,w=A[Symbol.iterator]();!(_=(E=w.next()).done);_=!0){var P=E.value;f.texImage2D(P,0,u,u,l,r[P])}}catch(e){m=!0,b=e}finally{try{!_&&w.return&&w.return()}finally{if(m)throw b}}}}},{key:"bind",value:function(){var e=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).index;return void 0!==e&&this.gl.activeTexture(S.d.TEXTURE0+e),this.gl.bindTexture(S.d.TEXTURE_CUBE_MAP,this.handle),e}},{key:"unbind",value:function(){return this.gl.bindTexture(S.d.TEXTURE_CUBE_MAP,null),this}}]),r}();(t.a=a).FACES=A},function(e,t,i){"use strict";t.b=function(e){switch(e.drawMode){case n.a.POINTS:return n.a.POINTS;case n.a.LINES:case n.a.LINE_STRIP:case n.a.LINE_LOOP:return n.a.LINES;case n.a.TRIANGLES:case n.a.TRIANGLE_STRIP:case n.a.TRIANGLE_FAN:return n.a.TRIANGLES;default:return c()(!1),0}};var n=i(25),o=i(30),a=i(7),r=i(1),c=i.n(r),s=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var u=36386,l=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),i.i(a.g)(e);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,t));return n.buffers={},Object.seal(n),n.initialize(t),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,o["a"]),s(r,null,[{key:"isSupported",value:function(e){return i.i(a.b)(e)}},{key:"isHandle",value:function(e){return this.gl.isTransformFeedback(this.handle)}}]),s(r,[{key:"initialize",value:function(e){var t=e.buffers,n=void 0===t?{}:t,r=e.varyingMap,i=void 0===r?{}:r;this.bindBuffers(n,{clear:!0,varyingMap:i})}},{key:"bindBuffers",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.clear,r=void 0!==n&&n,i=t.varyingMap,o=void 0===i?{}:i;for(var a in r&&(this._unbindBuffers(),this.buffers={}),e){var s=e[a],u=Number.isFinite(Number(a))?Number(a):o[a];c()(Number.isFinite(u)),this.buffers[u]=s}}},{key:"begin",value:function(e){return this._bindBuffers(),this.gl.bindTransformFeedback(u,this.handle),this.gl.beginTransformFeedback(e),this}},{key:"pause",value:function(){return this.gl.bindTransformFeedback(u,this.handle),this.gl.pauseTransformFeedback(),this.gl.bindTransformFeedback(u,null),this._unbindBuffers(),this}},{key:"resume",value:function(){return this._bindBuffers(),this.gl.bindTransformFeedback(u,this.handle),this.gl.resumeTransformFeedback(),this}},{key:"end",value:function(){return this.gl.bindTransformFeedback(u,this.handle),this.gl.endTransformFeedback(),this.gl.bindTransformFeedback(u,null),this._unbindBuffers(),this}},{key:"bindBuffer",value:function(e){var t=e.index,n=e.buffer,r=e.offset,i=void 0===r?0:r,o=e.size;return n.unbind(),this.gl.bindTransformFeedback(u,this.handle),void 0===o?this.gl.bindBufferBase(35982,t,n.handle):this.gl.bindBufferRange(35982,t,n.handle,i,o),this}},{key:"unbindBuffer",value:function(e){var t=e.index;return this.gl.bindTransformFeedback(u,this.handle),this.gl.bindBufferBase(35982,t,null),this}},{key:"_bindBuffers",value:function(){for(var e in this.buffers)this.bindBuffer({buffer:this.buffers[e],index:Number(e)})}},{key:"_unbindBuffers",value:function(){for(var e in this.buffers)this.unbindBuffer({buffer:this.buffers[e],index:Number(e)})}},{key:"_createHandle",value:function(){return this.gl.createTransformFeedback()}},{key:"_deleteHandle",value:function(){this.gl.deleteTransformFeedback(this.handle)}}]),r}();t.a=l},function(e,t,n){"use strict";t.a=function(e,t){if(!e)throw new Error("Assertion failed. "+t)}},function(e,t,n){"use strict";var r=n(112),o=n(31),a=n(280),s=n(113),u=n(281),c=n(277),i=n(569),l=n.n(i),f=n(570),d=n.n(f),h=n(571),p=n.n(h),v=n(102),g=n.n(v),y=n(234),_=n.n(y),m=n(76),b=n.n(m),E=n(574),w=n.n(E),P=n(156),S=n.n(P),A=n(75),T=n.n(A),x=n(157),O=n.n(x),R=n(235),C=n.n(R),k=n(158),M=n.n(k),L=n(573),I=n.n(L),N=n(77),F=n.n(N),j=n(78),D=n.n(j),B=n(602),U=n.n(B),G=n(615),V=n.n(G),z=n(103),W=n.n(z),X=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},H=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var Y=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];var K=[0,0,0,0],Z=function(e){function i(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(i.__proto__||Object.getPrototypeOf(i)).call(this));return Array.isArray(t[0])&&1===arguments.length?r.copy(t[0]):r.identity(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(i,r["a"]),H(i,[{key:"setRowMajor",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:1,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:0,i=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,o=5<arguments.length&&void 0!==arguments[5]?arguments[5]:1,a=6<arguments.length&&void 0!==arguments[6]?arguments[6]:0,s=7<arguments.length&&void 0!==arguments[7]?arguments[7]:0,u=8<arguments.length&&void 0!==arguments[8]?arguments[8]:0,c=9<arguments.length&&void 0!==arguments[9]?arguments[9]:0,l=10<arguments.length&&void 0!==arguments[10]?arguments[10]:1,f=11<arguments.length&&void 0!==arguments[11]?arguments[11]:0,d=12<arguments.length&&void 0!==arguments[12]?arguments[12]:0,h=13<arguments.length&&void 0!==arguments[13]?arguments[13]:0,p=14<arguments.length&&void 0!==arguments[14]?arguments[14]:0,v=15<arguments.length&&void 0!==arguments[15]?arguments[15]:1;return this.set(e,i,u,d,t,o,c,h,n,a,l,p,r,s,f,v)}},{key:"setColumnMajor",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:1,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:0,i=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,o=5<arguments.length&&void 0!==arguments[5]?arguments[5]:1,a=6<arguments.length&&void 0!==arguments[6]?arguments[6]:0,s=7<arguments.length&&void 0!==arguments[7]?arguments[7]:0,u=8<arguments.length&&void 0!==arguments[8]?arguments[8]:0,c=9<arguments.length&&void 0!==arguments[9]?arguments[9]:0,l=10<arguments.length&&void 0!==arguments[10]?arguments[10]:1,f=11<arguments.length&&void 0!==arguments[11]?arguments[11]:0,d=12<arguments.length&&void 0!==arguments[12]?arguments[12]:0,h=13<arguments.length&&void 0!==arguments[13]?arguments[13]:0,p=14<arguments.length&&void 0!==arguments[14]?arguments[14]:0,v=15<arguments.length&&void 0!==arguments[15]?arguments[15]:1;return this.set(e,t,n,r,i,o,a,s,u,c,l,f,d,h,p,v)}},{key:"set",value:function(e,t,n,r,i,o,a,s,u,c,l,f,d,h,p,v){return this[0]=e,this[1]=t,this[2]=n,this[3]=r,this[4]=i,this[5]=o,this[6]=a,this[7]=s,this[8]=u,this[9]=c,this[10]=l,this[11]=f,this[12]=d,this[13]=h,this[14]=p,this[15]=v,this.check(),this}},{key:"determinant",value:function(){return l()(this)}},{key:"identity",value:function(){for(var e=0;e<Y.length;++e)this[e]=Y[e];return this.check(),this}},{key:"fromQuaternion",value:function(e){return d()(this,e),this.check(),this}},{key:"frustum",value:function(e){var t=e.left,n=e.right,r=e.bottom,i=e.top,o=e.near,a=e.far;return p()(this,t,n,r,i,o,a),this.check(),this}},{key:"lookAt",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.eye,n=e.center,r=void 0===n?[0,0,0]:n,i=e.up,o=void 0===i?[0,1,0]:i;return g()(this,t,r,o),this.check(),this}},{key:"ortho",value:function(e){var t=e.left,n=e.right,r=e.bottom,i=e.top,o=e.near,a=void 0===o?.1:o,s=e.far,u=void 0===s?500:s;return _()(this,t,n,r,i,a,u),this.check(),this}},{key:"perspective",value:function(){var e=Math.PI,t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},n=t.fov,r=void 0===n?45*e/180:n,i=t.aspect,o=void 0===i?1:i,a=t.near,s=void 0===a?.1:a,u=t.far,c=void 0===u?500:u;if(2*e<r)throw Error("radians");return b()(this,r,o,s,c),this.check(),this}},{key:"transpose",value:function(){return w()(this,this),this.check(),this}},{key:"invert",value:function(){return S()(this,this),this.check(),this}},{key:"multiplyLeft",value:function(e){return T()(this,e,this),this.check(),this}},{key:"multiplyRight",value:function(e){return T()(this,this,e),this.check(),this}},{key:"rotateX",value:function(e){return O()(this,this,e),this.check(),this}},{key:"rotateY",value:function(e){return C()(this,this,e),this.check(),this}},{key:"rotateZ",value:function(e){return M()(this,this,e),this.check(),this}},{key:"rotateXYZ",value:function(e){var t=X(e,3),n=t[0],r=t[1],i=t[2];return this.rotateX(n).rotateY(r).rotateZ(i)}},{key:"rotateAxis",value:function(e,t){return I()(this,this,e,t),this.check(),this}},{key:"scale",value:function(e){return F()(this,this,e),this.check(),this}},{key:"translate",value:function(e){return D()(this,this,e),this.check(),this}},{key:"transformVector2",value:function(e,t){return t=t||new a.a,U()(t,e,this),n.i(c.a)(n.i(a.b)(t)),t}},{key:"transformVector3",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:new s.a;return t=t||new s.a,V()(t,e,this),n.i(c.a)(n.i(s.b)(t)),t}},{key:"transformVector4",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:new u.a;return t=t||new u.a,W()(t,e,this),n.i(c.a)(n.i(u.b)(t)),t}},{key:"transformVector",value:function(e,t){switch(e.length){case 2:return this.transformVector2(e,t);case 3:return this.transformVector3(e,t);case 4:return this.transformVector4(e,t);default:throw new Error("Illegal vector")}}},{key:"transformDirection",value:function(e,t){switch(e.length){case 2:W()(K,[e[0],e[1],0,0],this),(t=t||new a.a)[0]=K[0],t[1]=K[1];break;case 3:W()(K,[e[0],e[1],e[2],0],this),(t=t||new s.a)[0]=K[0],t[1]=K[1],t[2]=K[2];break;case 4:n.i(c.a)(0===e[3]),t=t||new u.a,W()(t,e,this);break;default:throw new Error("Illegal vector")}return t}},{key:"transformPoint",value:function(e,t){switch(e.length){case 2:t=t||new a.a,W()(t,[e[0],e[1],0,1],this),t.length=2,n.i(c.a)(n.i(a.b)(t));break;case 3:t=t||new s.a,W()(t,[e[0],e[1],e[2],1],this),t.length=3,n.i(c.a)(n.i(s.b)(t));break;case 4:n.i(c.a)(0!==e[3]),t=t||new u.a,W()(t,e,this),n.i(c.a)(n.i(u.b)(t));break;default:throw new Error("Illegal vector")}return t}},{key:"ELEMENTS",get:function(){return 16}},{key:"m00",get:function(){return this[0]},set:function(e){return this[0]=n.i(o.g)(e)}},{key:"m01",get:function(){return this[4]},set:function(e){return this[4]=n.i(o.g)(e)}},{key:"m02",get:function(){return this[8]},set:function(e){return this[8]=n.i(o.g)(e)}},{key:"m03",get:function(){return this[12]},set:function(e){return this[12]=n.i(o.g)(e)}},{key:"m10",get:function(){return this[1]},set:function(e){return this[1]=n.i(o.g)(e)}},{key:"m11",get:function(){return this[5]},set:function(e){return this[5]=n.i(o.g)(e)}},{key:"m12",get:function(){return this[9]},set:function(e){return this[9]=n.i(o.g)(e)}},{key:"m13",get:function(){return this[13]},set:function(e){return this[13]=n.i(o.g)(e)}},{key:"m20",get:function(){return this[2]},set:function(e){return this[2]=n.i(o.g)(e)}},{key:"m21",get:function(){return this[6]},set:function(e){return this[6]=n.i(o.g)(e)}},{key:"m22",get:function(){return this[10]},set:function(e){return this[10]=n.i(o.g)(e)}},{key:"m23",get:function(){return this[14]},set:function(e){return this[14]=n.i(o.g)(e)}},{key:"m30",get:function(){return this[3]},set:function(e){return this[3]=n.i(o.g)(e)}},{key:"m31",get:function(){return this[7]},set:function(e){return this[7]=n.i(o.g)(e)}},{key:"m32",get:function(){return this[11]},set:function(e){return this[11]=n.i(o.g)(e)}},{key:"m33",get:function(){return this[15]},set:function(e){return this[15]=n.i(o.g)(e)}}]),i}();t.a=Z},function(e,t,n){"use strict";var r=n(112),i=n(31),o=n(579),a=n.n(o),s=n(580),u=n.n(s),c=n(582),l=n.n(c),f=n(592),d=n.n(f),h=n(578),p=n.n(h),v=n(588),g=n.n(v),y=n(575),_=n.n(y),m=n(576),b=n.n(m),E=n(577),w=n.n(E),P=n(581),S=n.n(P),A=n(583),T=n.n(A),x=n(584),O=n.n(x),R=n(236),C=n.n(R),k=n(585),M=n.n(k),L=n(586),I=n.n(L),N=n(587),F=n.n(N),j=n(589),D=n.n(j),B=n(590),U=n.n(B),G=n(237),V=n.n(G),z=n(591),W=n.n(z),X=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var H=[0,0,0,1];var Y=function(e){function o(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:1;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var i=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this));return Array.isArray(e)&&1===arguments.length?i.copy(e):i.set(e,t,n,r),i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,r["a"]),X(o,[{key:"fromMatrix3",value:function(e){return a()(this,e),this.check(),this}},{key:"fromValues",value:function(e,t,n,r){return this.set(e,t,n,r)}},{key:"identity",value:function(){return u()(this),this.check(),this}},{key:"length",value:function(){return l()(this)}},{key:"squaredLength",value:function(){return d()(this)}},{key:"dot",value:function(e,t){if(void 0!==t)throw new Error("Quaternion.dot only takes one argument");return p()(this,e)}},{key:"rotationTo",value:function(e,t){return g()(this,e,t),this.check(),this}},{key:"add",value:function(e,t){if(void 0!==t)throw new Error("Quaternion.add only takes one argument");return _()(this,e),this.check(),this}},{key:"calculateW",value:function(){return b()(this,this),this.check(),this}},{key:"conjugate",value:function(){return w()(this,this),this.check(),this}},{key:"invert",value:function(){return S()(this,this),this.check(),this}},{key:"lerp",value:function(e,t,n){return T()(this,e,t,n),this.check(),this}},{key:"multiply",value:function(e,t){if(void 0!==t)throw new Error("Quaternion.multiply only takes one argument");return O()(this,this,t),this.check(),this}},{key:"normalize",value:function(){return C()(this,this),this.check(),this}},{key:"rotateX",value:function(e){return M()(this,this,e),this.check(),this}},{key:"rotateY",value:function(e){return I()(this,this,e),this.check(),this}},{key:"rotateZ",value:function(e){return F()(this,this,e),this.check(),this}},{key:"scale",value:function(e){return D()(this,this,e),this.check(),this}},{key:"set",value:function(e,t,n,r){return U()(this,e,t,n,r),this.check(),this}},{key:"setAxisAngle",value:function(e,t){return V()(this,e,t),this.check(),this}},{key:"slerp",value:function(e){var t=e.start,n=void 0===t?H:t,r=e.target,i=e.ratio;return W()(this,n,r,i),this.check(),this}},{key:"ELEMENTS",get:function(){return 4}},{key:"x",get:function(){return this[0]},set:function(e){return this[0]=n.i(i.g)(e)}},{key:"y",get:function(){return this[1]},set:function(e){return this[1]=n.i(i.g)(e)}},{key:"z",get:function(){return this[2]},set:function(e){return this[2]=n.i(i.g)(e)}},{key:"w",get:function(){return this[3]},set:function(e){return this[3]=n.i(i.g)(e)}}]),o}();t.a=Y},function(e,t,n){"use strict";t.b=function(e){var t=Number.isFinite;return 2===e.length&&t(e[0])&&t(e[1])};var r=n(170),i=n(31),o=n(600),a=n.n(o),s=n(159),c=n.n(s),u=n(601),l=n.n(u),f=n(596),d=n.n(f),h=n(594),p=n.n(h),v=n(598),g=n.n(v),y=n(599),_=n.n(y),m=n(160),b=n.n(m),E=n(597),w=n.n(E),P=n(595),S=n.n(P),A=n(593),T=n.n(A),x=n(238),O=n.n(x),R=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var C=function(e){function r(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this));return Array.isArray(e)&&1===arguments.length?n.copy(e):n.set(e,t),n}var t=Math.atan2;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,e),R(r,[{key:"set",value:function(e,t){return a()(this,e,t),this.check(),this}},{key:"add",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,c()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this}},{key:"subtract",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,l()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check(),this}},{key:"multiply",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,d()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check(),this}},{key:"divide",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,p()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check(),this}},{key:"scale",value:function(e){return Number.isFinite(e)&&g()(this,this,e),this.check(),this}},{key:"scaleAndAdd",value:function(e,t){return _()(this,this,e,t),this.check(),this}},{key:"negate",value:function(){return b()(this,this),this.check(),this}},{key:"normalize",value:function(){return w()(this,this),this.check(),this}},{key:"dot",value:function(e){return S()(this,e)}},{key:"cross",value:function(e){return T()(this,this,e),this.check(),this}},{key:"lerp",value:function(e,t){return O()(this,this,e,t),this.check(),this}},{key:"horizontalAngle",value:function(){return t(this.y,this.x)}},{key:"verticalAngle",value:function(){return t(this.x,this.y)}},{key:"operation",value:function(e){for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.apply(void 0,[this,this].concat(n)),this.check(),this}},{key:"ELEMENTS",get:function(){return 2}},{key:"x",get:function(){return this[0]},set:function(e){return this[0]=n.i(i.g)(e)}},{key:"y",get:function(){return this[1]},set:function(e){return this[1]=n.i(i.g)(e)}}]),r}(r.a);t.a=C},function(e,t,n){"use strict";t.b=function(e){var t=Number.isFinite;return 4===e.length&&t(e[0])&&t(e[1])&&t(e[2])&&t(e[3])};var r=n(170),i=n(31),o=n(248),a=n.n(o),s=n(616),u=n.n(s),c=n(243),l=n.n(c),f=n(623),d=n.n(f),h=n(246),p=n.n(h),v=n(617),g=n.n(v),y=n(161),_=n.n(y),m=n(621),b=n.n(m),E=n(620),w=n.n(E),P=n(618),S=n.n(P),A=n(247),T=n.n(A),x=n(244),O=n.n(x),R=n(245),C=n.n(R),k=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var M=function(e){function o(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:0;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var i=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this));return Array.isArray(e)&&1===arguments.length?i.copy(e):i.set(e,t,n,r),i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,r["a"]),k(o,[{key:"set",value:function(e,t,n,r){return a()(this,e,t,n,r),this.check(),this}},{key:"distance",value:function(e){return u()(e)}},{key:"add",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,l()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check(),this}},{key:"subtract",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,d()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check(),this}},{key:"multiply",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,p()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check(),this}},{key:"divide",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s,u=t[Symbol.iterator]();!(r=(a=u.next()).done);r=!0)s=a.value,g()(this,this,s)}catch(e){i=!0,o=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw o}}return this.check(),this}},{key:"scale",value:function(e){return _()(this,this,e),this.check(),this}},{key:"scaleAndAdd",value:function(e,t){return b()(this,this,e,t),this.check(),this}},{key:"negate",value:function(){return w()(this,this),this.check(),this}},{key:"inverse",value:function(){return S()(this,this),this.check(),this}},{key:"normalize",value:function(){return T()(this,this),this.check(),this}},{key:"dot",value:function(e){return O()(this,e)}},{key:"lerp",value:function(e,t){return C()(this,this,e,t),this.check(),this}},{key:"ELEMENTS",get:function(){return 4}},{key:"x",get:function(){return this[0]},set:function(e){return this[0]=n.i(i.g)(e)}},{key:"y",get:function(){return this[1]},set:function(e){return this[1]=n.i(i.g)(e)}},{key:"z",get:function(){return this[2]},set:function(e){return this[2]=n.i(i.g)(e)}},{key:"w",get:function(){return this[3]},set:function(e){return this[3]=n.i(i.g)(e)}}]),o}();t.a=M},function(o,e,t){(function(e,t){var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r="object"!==(void 0===e?"undefined":n(e))||"[object process]"!==String(e)||e.browser,i="undefined"!=typeof navigator?navigator.userAgent.toLowerCase():"";o.exports={window:"undefined"!=typeof window?window:t,global:void 0!==t?t:window,document:"undefined"!=typeof document?document:{},isBrowser:r,userAgent:i}}).call(e,t(26),t(47))},function(e,t,n){"use strict";n.d(t,"a",function(){return a});var r=n(282),i=(n.n(r),n(677)),o=void 0;r.isBrowser&&(o=n(624)),o&&(n.i(i.a)(o.PointerEventInput),n.i(i.b)(o.MouseInput));var a=o?o.Manager:function(e){var t={},n=function(){return t};return t.get=function(){return null},t.set=n,t.on=n,t.off=n,t.destroy=n,t.emit=n,t};t.b=o},function(e,t,n){"use strict";(function(u){if("production"!==u.env.NODE_ENV)var c=n(101),l=n(155),f=n(172),d={};e.exports=function(e,t,n,r,i){if("production"!==u.env.NODE_ENV)for(var o in e)if(e.hasOwnProperty(o)){var a;try{c("function"==typeof e[o],"%s: %s type `%s` is invalid; it must be a function, usually from the `prop-types` package, but received `%s`.",r||"React class",n,o,typeof e[o]),a=e[o](t,o,r,n,null,f)}catch(e){a=e}if(l(!a||a instanceof Error,"%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",r||"React class",n,o,typeof a),a instanceof Error&&!(a.message in d)){d[a.message]=!0;var s=i?i():"";l(!1,"Failed %s type: %s%s",n,a.message,null!=s?s:"")}}}}).call(t,n(26))},function(e,t,n){"use strict";t.a=function(e){var t=e.width,n=e.height,r=e.bounds,i=e.padding,o=void 0===i?0:i,a=e.offset,s=void 0===a?[0,0]:a,u=A(r,2),c=A(u[0],2),l=c[0],f=c[1],d=A(u[1],2),h=d[0],p=d[1],v=new S.a({width:t,height:n,longitude:0,latitude:0,zoom:0}),g=v.project([l,p]),y=v.project([h,f]),_=[Math.abs(y[0]-g[0]),Math.abs(y[1]-g[1])],m=[(y[0]+g[0])/2,(y[1]+g[1])/2],b=(t-2*o-2*Math.abs(s[0]))/_[0],E=(n-2*o-2*Math.abs(s[1]))/_[1],w=v.unproject(m),P=v.zoom+Math.log2(Math.abs(Math.min(b,E)));return{longitude:w[0],latitude:w[1],zoom:P}};var S=n(81),A=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.experimental=t.DeckGL=t.default=t.GeoJsonLayer=t.PolygonLayer=t.PathLayer=t.HexagonCellLayer=t.HexagonLayer=t.GridCellLayer=t.GridLayer=t.ScreenGridLayer=t.ScatterplotLayer=t.PointCloudLayer=t.LineLayer=t.IconLayer=t.ArcLayer=t.lighting=t.project64=t.project=t.OrthographicViewport=t.PerspectiveViewport=t.WebMercatorViewport=t.Viewport=t.CompositeLayer=t.Layer=t.AttributeManager=t.LayerManager=t.COORDINATE_SYSTEM=void 0;var r=n(13);Object.defineProperty(t,"COORDINATE_SYSTEM",{enumerable:!0,get:function(){return r.COORDINATE_SYSTEM}}),Object.defineProperty(t,"LayerManager",{enumerable:!0,get:function(){return r.LayerManager}}),Object.defineProperty(t,"AttributeManager",{enumerable:!0,get:function(){return r.AttributeManager}}),Object.defineProperty(t,"Layer",{enumerable:!0,get:function(){return r.Layer}}),Object.defineProperty(t,"CompositeLayer",{enumerable:!0,get:function(){return r.CompositeLayer}}),Object.defineProperty(t,"Viewport",{enumerable:!0,get:function(){return r.Viewport}}),Object.defineProperty(t,"WebMercatorViewport",{enumerable:!0,get:function(){return r.WebMercatorViewport}}),Object.defineProperty(t,"PerspectiveViewport",{enumerable:!0,get:function(){return r.PerspectiveViewport}}),Object.defineProperty(t,"OrthographicViewport",{enumerable:!0,get:function(){return r.OrthographicViewport}}),Object.defineProperty(t,"project",{enumerable:!0,get:function(){return r.project}}),Object.defineProperty(t,"project64",{enumerable:!0,get:function(){return r.project64}}),Object.defineProperty(t,"lighting",{enumerable:!0,get:function(){return r.lighting}});var i=n(309);Object.defineProperty(t,"ArcLayer",{enumerable:!0,get:function(){return i.ArcLayer}}),Object.defineProperty(t,"IconLayer",{enumerable:!0,get:function(){return i.IconLayer}}),Object.defineProperty(t,"LineLayer",{enumerable:!0,get:function(){return i.LineLayer}}),Object.defineProperty(t,"PointCloudLayer",{enumerable:!0,get:function(){return i.PointCloudLayer}}),Object.defineProperty(t,"ScatterplotLayer",{enumerable:!0,get:function(){return i.ScatterplotLayer}}),Object.defineProperty(t,"ScreenGridLayer",{enumerable:!0,get:function(){return i.ScreenGridLayer}}),Object.defineProperty(t,"GridLayer",{enumerable:!0,get:function(){return i.GridLayer}}),Object.defineProperty(t,"GridCellLayer",{enumerable:!0,get:function(){return i.GridCellLayer}}),Object.defineProperty(t,"HexagonLayer",{enumerable:!0,get:function(){return i.HexagonLayer}}),Object.defineProperty(t,"HexagonCellLayer",{enumerable:!0,get:function(){return i.HexagonCellLayer}}),Object.defineProperty(t,"PathLayer",{enumerable:!0,get:function(){return i.PathLayer}}),Object.defineProperty(t,"PolygonLayer",{enumerable:!0,get:function(){return i.PolygonLayer}}),Object.defineProperty(t,"GeoJsonLayer",{enumerable:!0,get:function(){return i.GeoJsonLayer}});var o=n(362);Object.defineProperty(t,"default",{enumerable:!0,get:function(){return s(o).default}}),Object.defineProperty(t,"DeckGL",{enumerable:!0,get:function(){return o.DeckGL}});var a=s(n(359));function s(e){return e&&e.__esModule?e:{default:e}}var u={},c=r.experimental.ViewState,l=r.experimental.FirstPersonState,f=r.experimental.OrbitState,d=r.experimental.MapState,h=r.experimental.Controller,p=r.experimental.FirstPersonController,v=r.experimental.FirstPersonViewport,g=r.experimental.OrbitViewport,y=r.experimental.ThirdPersonViewport,_=r.experimental.TRANSITION_EVENTS,m=r.experimental.LinearInterpolator,b=r.experimental.ViewportFlyToInterpolator,E=r.experimental.DeckGLJS,w=r.experimental.MapControllerJS,P=r.experimental.EffectManager,S=r.experimental.Effect;Object.assign(u,{ViewState:c,FirstPersonState:l,OrbitState:f,MapState:d,Controller:h,FirstPersonController:p,FirstPersonViewport:v,OrbitViewport:g,ThirdPersonViewport:y,TRANSITION_EVENTS:_,LinearInterpolator:m,ViewportFlyToInterpolator:b,DeckGLJS:E,MapControllerJS:w,EffectManager:P,Effect:S});var A=r.experimental.TransitionManager,T=r.experimental.extractViewportFrom,x=r.experimental.BinSorter,O=r.experimental.linearScale,R=r.experimental.getLinearScale,C=r.experimental.quantizeScale,k=r.experimental.getQuantizeScale,M=r.experimental.clamp,L=r.experimental.defaultColorRange,I=r.experimental.log,N=r.experimental.get,F=r.experimental.count,j=r.experimental.flatten,D=r.experimental.countVertices,B=r.experimental.flattenVertices,U=r.experimental.fillArray,G=r.experimental.enable64bitSupport,V=r.experimental.fp64ify,z=r.experimental.fp64LowPart;Object.assign(u,{TransitionManager:A,extractViewportFrom:T,BinSorter:x,linearScale:O,getLinearScale:R,quantizeScale:C,getQuantizeScale:k,clamp:M,defaultColorRange:L,log:I,get:N,count:F,flatten:j,countVertices:D,flattenVertices:B,fillArray:U,enable64bitSupport:G,fp64ify:V,fp64LowPart:z}),Object.assign(u,{ReflectionEffect:a.default}),Object.assign(u,{MapController:o.MapController,OrbitController:o.OrbitController,ViewportController:o.ViewportController}),t.experimental=u},function(e,t,n){"use strict";(function(e){if(n(566),n(366),n(367),e._babelPolyfill)throw new Error("only one instance of babel-polyfill is allowed");e._babelPolyfill=!0;function t(e,t,n){e[t]||Object.defineProperty(e,t,{writable:!0,configurable:!0,value:n})}t(String.prototype,"padLeft","".padStart),t(String.prototype,"padRight","".padEnd),"pop,reverse,shift,keys,values,entries,indexOf,every,some,forEach,map,filter,find,findIndex,includes,join,slice,concat,push,splice,unshift,sort,lastIndexOf,reduce,reduceRight,copyWithin,fill".split(",").forEach(function(e){[][e]&&t(Array,e,Function.call.bind([][e]))})}).call(t,n(47))},function(e,t,n){"use strict";n(287);var r=function(e){{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}}(n(286));"undefined"!=typeof window&&(window.DeckGL=r)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME arc-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nvarying vec4 vColor;\n\nvoid main(void) {\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME arc-layer-vertex-shader-64\n\nattribute vec3 positions;\nattribute vec4 instanceSourceColors;\nattribute vec4 instanceTargetColors;\n\nattribute vec4 instancePositions;\nattribute vec4 instancePositions64Low;\n\nattribute vec3 instancePickingColors;\n\nuniform float numSegments;\nuniform float strokeWidth;\nuniform float opacity;\n\nvarying vec4 vColor;\n\nvec2 paraboloid_fp64(vec2 source[2], vec2 target[2], float ratio) {\n\n vec2 x[2];\n vec2_mix_fp64(source, target, ratio, x);\n vec2 center[2];\n vec2_mix_fp64(source, target, 0.5, center);\n\n vec2 dSourceCenter = vec2_distance_fp64(source, center);\n vec2 dXCenter = vec2_distance_fp64(x, center);\n return mul_fp64(sum_fp64(dSourceCenter, dXCenter), sub_fp64(dSourceCenter, dXCenter));\n}\n\n// offset vector by strokeWidth pixels\n// offset_direction is -1 (left) or 1 (right)\nvec2 getExtrusionOffset(vec2 line_clipspace, float offset_direction) {\n // normalized direction of the line\n vec2 dir_screenspace = normalize(line_clipspace * project_uViewportSize);\n // rotate by 90 degrees\n dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x);\n\n vec2 offset_screenspace = dir_screenspace * offset_direction * strokeWidth / 2.0;\n vec2 offset_clipspace = project_pixel_to_clipspace(offset_screenspace).xy;\n\n return offset_clipspace;\n}\n\nfloat getSegmentRatio(float index) {\n return smoothstep(0.0, 1.0, index / (numSegments - 1.0));\n}\n\nvoid get_pos_fp64(vec2 source[2], vec2 target[2], float segmentRatio, out vec2 position[4]) {\n\n vec2 vertex_height = paraboloid_fp64(source, target, segmentRatio);\n\n vec2 position_temp[2];\n\n vec2_mix_fp64(source, target, segmentRatio, position_temp);\n\n position[0] = position_temp[0];\n position[1] = position_temp[1];\n\n if (vertex_height.x < 0.0 || (vertex_height.x == 0.0 && vertex_height.y <= 0.0)) {\n vertex_height = vec2(0.0, 0.0);\n }\n\n position[2] = sqrt_fp64(vertex_height);\n position[3] = vec2(1.0, 0.0);\n}\n\nvoid main(void) {\n vec4 instanceSourcePositions64 = vec4(instancePositions.x,\n instancePositions64Low.x, instancePositions.y, instancePositions64Low.y);\n vec4 instanceTargetPositions64 = vec4(instancePositions.z,\n instancePositions64Low.z, instancePositions.w, instancePositions64Low.w);\n\n vec2 projected_source_coord[2];\n vec2 projected_target_coord[2];\n\n project_position_fp64(instanceSourcePositions64, projected_source_coord);\n project_position_fp64(instanceTargetPositions64, projected_target_coord);\n\n float segmentIndex = positions.x;\n float segmentRatio = getSegmentRatio(segmentIndex);\n\n // if it's the first point, use next - current as direction\n // otherwise use current - prev\n float indexDir = mix(-1.0, 1.0, step(segmentIndex, 0.0));\n float nextSegmentRatio = getSegmentRatio(segmentIndex + indexDir);\n\n vec2 curr_pos_modelspace[4];\n\n get_pos_fp64(projected_source_coord, projected_target_coord, segmentRatio,\n curr_pos_modelspace);\n\n vec2 next_pos_modelspace[4];\n\n get_pos_fp64(projected_source_coord, projected_target_coord, nextSegmentRatio,\n next_pos_modelspace);\n\n vec4 curr_pos_clipspace = project_to_clipspace_fp64(curr_pos_modelspace);\n vec4 next_pos_clipspace = project_to_clipspace_fp64(next_pos_modelspace);\n\n vec2 offset = getExtrusionOffset(next_pos_clipspace.xy - curr_pos_clipspace.xy, positions.y);\n\n gl_Position = curr_pos_clipspace + vec4(offset, 0.0, 0.0);\n\n vec4 color = mix(instanceSourceColors, instanceTargetColors, segmentRatio) / 255.;\n vColor = vec4(color.rgb, color.a * opacity);\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME arc-layer-vertex-shader\n\nattribute vec3 positions;\nattribute vec4 instanceSourceColors;\nattribute vec4 instanceTargetColors;\nattribute vec4 instancePositions;\nattribute vec3 instancePickingColors;\n\nuniform float numSegments;\nuniform float strokeWidth;\nuniform float opacity;\n\nvarying vec4 vColor;\n\nfloat paraboloid(vec2 source, vec2 target, float ratio) {\n\n vec2 x = mix(source, target, ratio);\n vec2 center = mix(source, target, 0.5);\n\n float dSourceCenter = distance(source, center);\n float dXCenter = distance(x, center);\n return (dSourceCenter + dXCenter) * (dSourceCenter - dXCenter);\n}\n\n// offset vector by strokeWidth pixels\n// offset_direction is -1 (left) or 1 (right)\nvec2 getExtrusionOffset(vec2 line_clipspace, float offset_direction) {\n // normalized direction of the line\n vec2 dir_screenspace = normalize(line_clipspace * project_uViewportSize);\n // rotate by 90 degrees\n dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x);\n\n vec2 offset_screenspace = dir_screenspace * offset_direction * strokeWidth / 2.0;\n vec2 offset_clipspace = project_pixel_to_clipspace(offset_screenspace).xy;\n\n return offset_clipspace;\n}\n\nfloat getSegmentRatio(float index) {\n return smoothstep(0.0, 1.0, index / (numSegments - 1.0));\n}\n\nvec3 getPos(vec2 source, vec2 target, float segmentRatio) {\n float vertex_height = paraboloid(source, target, segmentRatio);\n\n return vec3(\n mix(source, target, segmentRatio),\n sqrt(max(0.0, vertex_height))\n );\n}\n\nvoid main(void) {\n vec2 source = project_position(instancePositions.xy);\n vec2 target = project_position(instancePositions.zw);\n\n float segmentIndex = positions.x;\n float segmentRatio = getSegmentRatio(segmentIndex);\n // if it's the first point, use next - current as direction\n // otherwise use current - prev\n float indexDir = mix(-1.0, 1.0, step(segmentIndex, 0.0));\n float nextSegmentRatio = getSegmentRatio(segmentIndex + indexDir);\n\n vec3 currPos = getPos(source, target, segmentRatio);\n vec3 nextPos = getPos(source, target, nextSegmentRatio);\n vec4 curr = project_to_clipspace(vec4(currPos, 1.0));\n vec4 next = project_to_clipspace(vec4(nextPos, 1.0));\n\n // extrude\n vec2 offset = getExtrusionOffset((next.xy - curr.xy) * indexDir, positions.y);\n gl_Position = curr + vec4(offset, 0.0, 0.0);\n\n vec4 color = mix(instanceSourceColors, instanceTargetColors, segmentRatio) / 255.;\n vColor = vec4(color.rgb, color.a * opacity);\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),a=n(12),s=o(n(291)),u=o(n(290)),c=o(n(289));function o(e){return e&&e.__esModule?e:{default:e}}var g=i.experimental.fp64LowPart,l=i.experimental.enable64bitSupport,f=[0,0,0,255],d={strokeWidth:1,fp64:!1,getSourcePosition:function(e){return e.sourcePosition},getTargetPosition:function(e){return e.targetPosition},getSourceColor:function(e){return e.color||f},getTargetColor:function(e){return e.color||f}},h=function(e){function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,i.Layer),r(o,[{key:"getShaders",value:function(){return l(this.props)?{vs:u.default,fs:c.default,modules:["project64","picking"]}:{vs:s.default,fs:c.default,modules:["picking"]}}},{key:"initializeState",value:function(){this.getAttributeManager().addInstanced({instancePositions:{size:4,transition:!0,accessor:["getSourcePosition","getTargetPosition"],update:this.calculateInstancePositions},instanceSourceColors:{size:4,type:a.GL.UNSIGNED_BYTE,transition:!0,accessor:"getSourceColor",update:this.calculateInstanceSourceColors},instanceTargetColors:{size:4,type:a.GL.UNSIGNED_BYTE,transition:!0,accessor:"getTargetColor",update:this.calculateInstanceTargetColors}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.addInstanced({instancePositions64Low:{size:4,accessor:["getSourcePosition","getTargetPosition"],update:this.calculateInstancePositions64Low}}):r.remove(["instancePositions64Low"])}}},{key:"updateState",value:function(e){var t=e.props,n=e.oldProps,r=e.changeFlags;if(function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0}(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"updateState",this).call(this,{props:t,oldProps:n,changeFlags:r}),t.fp64!==n.fp64){var i=this.context.gl;this.setState({model:this._getModel(i)})}this.updateAttribute({props:t,oldProps:n,changeFlags:r})}},{key:"draw",value:function(e){var t=e.uniforms,n=this.props.strokeWidth;this.state.model.render(Object.assign({},t,{strokeWidth:n}))}},{key:"_getModel",value:function(e){for(var t=[],n=0;n<50;n++)t=t.concat([n,-1,0,n,1,0]);var r=new a.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:new a.Geometry({drawMode:a.GL.TRIANGLE_STRIP,attributes:{positions:new Float32Array(t)}}),isInstanced:!0,shaderCache:this.context.shaderCache}));return r.setUniforms({numSegments:50}),r}},{key:"calculateInstancePositions",value:function(e){var t=this.props,n=t.data,r=t.getSourcePosition,i=t.getTargetPosition,o=e.value,a=e.size,s=0,u=!0,c=!1,l=void 0;try{for(var f,d=n[Symbol.iterator]();!(u=(f=d.next()).done);u=!0){var h=f.value,p=r(h),v=i(h);o[s+0]=p[0],o[s+1]=p[1],o[s+2]=v[0],o[s+3]=v[1],s+=a}}catch(e){c=!0,l=e}finally{try{!u&&d.return&&d.return()}finally{if(c)throw l}}}},{key:"calculateInstancePositions64Low",value:function(e){var t=this.props,n=t.data,r=t.getSourcePosition,i=t.getTargetPosition,o=e.value,a=e.size,s=0,u=!0,c=!1,l=void 0;try{for(var f,d=n[Symbol.iterator]();!(u=(f=d.next()).done);u=!0){var h=f.value,p=r(h),v=i(h);o[s+0]=g(p[0]),o[s+1]=g(p[1]),o[s+2]=g(v[0]),o[s+3]=g(v[1]),s+=a}}catch(e){c=!0,l=e}finally{try{!u&&d.return&&d.return()}finally{if(c)throw l}}}},{key:"calculateInstanceSourceColors",value:function(e){var t=this.props,n=t.data,r=t.getSourceColor,i=e.value,o=e.size,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r(l.value);i[a+0]=d[0],i[a+1]=d[1],i[a+2]=d[2],i[a+3]=isNaN(d[3])?255:d[3],a+=o}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}},{key:"calculateInstanceTargetColors",value:function(e){var t=this.props,n=t.data,r=t.getTargetColor,i=e.value,o=e.size,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r(l.value);i[a+0]=d[0],i[a+1]=d[1],i[a+2]=d[2],i[a+3]=isNaN(d[3])?255:d[3],a+=o}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}}]),o}();(t.default=h).layerName="ArcLayer",h.defaultProps=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),o=c(n(176)),a=c(n(119)),s=c(n(177)),u=n(294);function c(e){return e&&e.__esModule?e:{default:e}}var l=i.experimental.get,f=[0,0,0,255],d=[0,0,0,255],h={stroked:!0,filled:!0,extruded:!1,wireframe:!1,lineWidthScale:1,lineWidthMinPixels:0,lineWidthMaxPixels:Number.MAX_SAFE_INTEGER,lineJointRounded:!1,lineMiterLimit:4,elevationScale:1,pointRadiusScale:1,pointRadiusMinPixels:0,pointRadiusMaxPixels:Number.MAX_SAFE_INTEGER,fp64:!1,getLineColor:function(e){return l(e,"properties.lineColor")||f},getFillColor:function(e){return l(e,"properties.fillColor")||d},getRadius:function(e){return l(e,"properties.radius")||l(e,"properties.size")||1},getLineWidth:function(e){return l(e,"properties.lineWidth")||1},getElevation:function(e){return l(e,"properties.elevation")||1e3},subLayers:{PointLayer:o.default,LineLayer:a.default,PolygonLayer:s.default},lightSettings:{lightsPosition:[-122.45,37.75,8e3,-122,38,5e3],ambientRatio:.05,diffuseRatio:.6,specularRatio:.8,lightsStrength:[2,0,0,0],numberOfLights:2}},N=function(e){return e.geometry.coordinates},p=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.CompositeLayer),r(t,[{key:"initializeState",value:function(){this.state={features:{}}}},{key:"updateState",value:function(e){e.oldProps,e.props;if(e.changeFlags.dataChanged){var t=this.props.data,n=(0,u.getGeojsonFeatures)(t);this.state.features=(0,u.separateGeojsonFeatures)(n)}}},{key:"getPickingInfo",value:function(e){var t=e.info;return Object.assign(t,{object:t.object&&t.object.feature||t.object})}},{key:"renderLayers",value:function(){var e=this.state.features,t=e.pointFeatures,n=e.lineFeatures,r=e.polygonFeatures,i=e.polygonOutlineFeatures,o=this.props,a=o.stroked,s=o.filled,u=o.extruded,c=o.wireframe,l=o.subLayers,f=o.lightSettings,d=this.props,h=d.lineWidthScale,p=d.lineWidthMinPixels,v=d.lineWidthMaxPixels,g=d.lineJointRounded,y=d.lineMiterLimit,_=d.pointRadiusScale,m=d.pointRadiusMinPixels,b=d.pointRadiusMaxPixels,E=d.elevationScale,w=d.fp64,P=this.props,S=P.getLineColor,A=P.getFillColor,T=P.getRadius,x=P.getLineWidth,O=P.getElevation,R=P.updateTriggers,C=t&&0<t.length,k=n&&0<n.length,M=i&&0<i.length,L=r&&0<r.length,I=s&&L&&new l.PolygonLayer(this.getSubLayerProps({id:"polygon-fill",updateTriggers:{getElevation:R.getElevation,getColor:R.getFillColor}}),{data:r,fp64:w,extruded:u,elevationScale:E,wireframe:!1,lightSettings:f,getPolygon:N,getElevation:O,getColor:A});return[!u&&I,c&&u&&L&&new l.PolygonLayer(this.getSubLayerProps({id:"polygon-wireframe",updateTriggers:{getElevation:R.getElevation,getColor:R.getLineColor}}),{data:r,fp64:w,extruded:u,elevationScale:E,wireframe:!0,getPolygon:N,getElevation:O,getColor:S}),!u&&a&&M&&new l.LineLayer(this.getSubLayerProps({id:"polygon-outline",updateTriggers:{getColor:R.getLineColor,getWidth:R.getLineWidth}}),{data:i,fp64:w,widthScale:h,widthMinPixels:p,widthMaxPixels:v,rounded:g,miterLimit:y,getPath:N,getColor:S,getWidth:x}),k&&new l.LineLayer(this.getSubLayerProps({id:"line-paths",updateTriggers:{getColor:R.getLineColor,getWidth:R.getLineWidth}}),{data:n,fp64:w,widthScale:h,widthMinPixels:p,widthMaxPixels:v,rounded:g,miterLimit:y,getPath:N,getColor:S,getWidth:x}),C&&new l.PointLayer(this.getSubLayerProps({id:"points",updateTriggers:{getColor:R.getFillColor,getRadius:R.getRadius}}),{data:t,fp64:w,radiusScale:_,radiusMinPixels:m,radiusMaxPixels:b,getPosition:N,getColor:A,getRadius:T}),u&&I]}}]),t}();(t.default=p).layerName="GeoJsonLayer",p.defaultProps=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getGeojsonFeatures=function(e){if(Array.isArray(e))return e;switch((0,c.default)(e.type,"GeoJSON does not have type"),e.type){case"GeometryCollection":return(0,c.default)(Array.isArray(e.geometries),"GeoJSON does not have geometries array"),e.geometries.map(function(e){return{geometry:e}});case"Feature":return[e];case"FeatureCollection":return(0,c.default)(Array.isArray(e.features),"GeoJSON does not have features array"),e.features;default:return[{geometry:e}]}},t.separateGeojsonFeatures=function(e){var o=[],a=[],s=[],u=[];return e.forEach(function(t){(0,c.default)(t&&t.geometry,"GeoJSON does not have geometry");var e=t.geometry,n=e.type,r=e.coordinates,i=t.properties;switch(function(e,t){var n=l[e];for((0,c.default)(n,"Unknown GeoJSON type "+e);t&&0<--n;)t=t[0];(0,c.default)(t&&Number.isFinite(t[0]),e+" coordinates are malformed")}(n,r),n){case"Point":o.push(t);break;case"MultiPoint":r.forEach(function(e){o.push({geometry:{coordinates:e},properties:i,feature:t})});break;case"LineString":a.push(t);break;case"MultiLineString":r.forEach(function(e){a.push({geometry:{coordinates:e},properties:i,feature:t})});break;case"Polygon":s.push(t),r.forEach(function(e){u.push({geometry:{coordinates:e},properties:i,feature:t})});break;case"MultiPolygon":r.forEach(function(e){s.push({geometry:{coordinates:e},properties:i,feature:t}),e.forEach(function(e){u.push({geometry:{coordinates:e},properties:i,feature:t})})})}}),{pointFeatures:o,lineFeatures:a,polygonFeatures:s,polygonOutlineFeatures:u}};var r,i=n(1),c=(r=i)&&r.__esModule?r:{default:r};var l={Point:1,MultiPoint:2,LineString:2,MultiLineString:3,Polygon:3,MultiPolygon:4}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME grid-cell-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nvarying vec4 vColor;\n\nvoid main(void) {\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME grid-cell-layer-vertex-shader-64\n\nattribute vec3 positions;\nattribute vec3 normals;\n\nattribute vec4 instancePositions;\nattribute vec2 instancePositions64xyLow;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\n// Custom uniforms\nuniform float extruded;\nuniform float cellSize;\nuniform float coverage;\nuniform float opacity;\nuniform float elevationScale;\n\n// A magic number to scale elevation so that 1 unit approximate to 1 meter\n#define ELEVATION_SCALE 0.8\n\n// Result\nvarying vec4 vColor;\n\nvoid main(void) {\n vec4 instancePositions64xy = vec4(\n instancePositions.x,\n instancePositions64xyLow.x,\n instancePositions.y,\n instancePositions64xyLow.y);\n\n vec2 projected_coord_xy[2];\n project_position_fp64(instancePositions64xy, projected_coord_xy);\n\n // if ahpha == 0.0 or z < 0.0, do not render element\n float noRender = float(instanceColors.a == 0.0 || instancePositions.w < 0.0);\n float finalCellSize = cellSize * mix(1.0, 0.0, noRender);\n\n projected_coord_xy[0] = sum_fp64(projected_coord_xy[0],\n vec2((positions.x * coverage + 1.0) * finalCellSize / 2.0, 0.0));\n projected_coord_xy[1] = sum_fp64(projected_coord_xy[1],\n vec2((positions.y * coverage - 1.0) * finalCellSize / 2.0, 0.0));\n\n float elevation = 0.0;\n\n if (extruded > 0.5) {\n elevation = project_scale(instancePositions.w * (positions.z + 1.0) *\n ELEVATION_SCALE * elevationScale) + 1.0;\n }\n\n vec2 vertex_pos_modelspace[4];\n vertex_pos_modelspace[0] = projected_coord_xy[0];\n vertex_pos_modelspace[1] = projected_coord_xy[1];\n vertex_pos_modelspace[2] = vec2(elevation, 0.0);\n vertex_pos_modelspace[3] = vec2(1.0, 0.0);\n\n vec4 position_worldspace = vec4(\n vertex_pos_modelspace[0].x, vertex_pos_modelspace[1].x,\n vertex_pos_modelspace[2].x, vertex_pos_modelspace[3].x);\n\n gl_Position = project_to_clipspace_fp64(vertex_pos_modelspace);\n\n float lightWeight = 1.0;\n\n if (extruded > 0.5) {\n lightWeight = getLightWeight(\n position_worldspace.xyz, // the w component is always 1.0\n normals\n );\n }\n\n vec3 lightWeightedColor = lightWeight * instanceColors.rgb;\n vec4 color = vec4(lightWeightedColor, instanceColors.a * opacity) / 255.0;\n vColor = color;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME grid-cell-layer-vertex-shader\n\nattribute vec3 positions;\nattribute vec3 normals;\n\nattribute vec4 instancePositions;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\n// Custom uniforms\nuniform float extruded;\nuniform float cellSize;\nuniform float coverage;\nuniform float opacity;\nuniform float elevationScale;\n\n// A magic number to scale elevation so that 1 unit approximate to 1 meter\n#define ELEVATION_SCALE 0.8\n\n// Result\nvarying vec4 vColor;\n\nvoid main(void) {\n\n vec2 topLeftPos = project_position(instancePositions.xy);\n\n // if ahpha == 0.0 or z < 0.0, do not render element\n float noRender = float(instanceColors.a == 0.0 || instancePositions.w < 0.0);\n float finalCellSize = cellSize * mix(1.0, 0.0, noRender);\n\n // cube gemoetry vertics are between -1 to 1, scale and transform it to between 0, 1\n vec2 pos = topLeftPos + vec2(\n (positions.x * coverage + 1.0) / 2.0 * finalCellSize,\n (positions.y * coverage - 1.0) / 2.0 * finalCellSize);\n\n float elevation = 0.0;\n\n if (extruded > 0.5) {\n elevation = project_scale(instancePositions.w * (positions.z + 1.0) *\n ELEVATION_SCALE * elevationScale);\n }\n\n // extrude positions\n vec3 extrudedPosition = vec3(pos.xy, elevation + 1.0);\n vec4 position_worldspace = vec4(extrudedPosition, 1.0);\n gl_Position = project_to_clipspace(position_worldspace);\n\n float lightWeight = 1.0;\n\n if (extruded > 0.5) {\n lightWeight = getLightWeight(\n position_worldspace.xyz, // the w component is always 1.0\n normals\n );\n }\n\n vec3 lightWeightedColor = lightWeight * instanceColors.rgb;\n vec4 color = vec4(lightWeightedColor, instanceColors.a * opacity) / 255.0;\n vColor = color;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pointToDensityGridData=function(e,t,n){var r=function(){for(var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[],t=arguments[1],s=arguments[2],n=1/0,r=-1/0,i=void 0,o=0;o<e.length;o++)i=s(e[o])[1],Number.isFinite(i)&&(n=i<n?i:n,r=r<i?i:r);var u=(a=t,c=(n+r)/2,p=a,l=p/v*(180/Math.PI),d=c,h=a,f=h/v*(180/Math.PI)/Math.cos(d*Math.PI/180),{yOffset:l,xOffset:f});var a,c,l,f,d,h,p;if(u.xOffset<=0||u.yOffset<=0)return{gridHash:{},gridOffset:u};return{gridHash:e.reduce(function(e,t){var n=s(t)[1],r=s(t)[0];if(!Number.isFinite(n)||!Number.isFinite(r))return e;var i=Math.floor((n+90)/u.yOffset),o=Math.floor((r+180)/u.xOffset),a=i+"-"+o;return e[a]=e[a]||{count:0,points:[]},e[a].count+=1,e[a].points.push(t),e},{}),gridOffset:u}}(e,t,n),i=r.gridHash,o=r.gridOffset,a=(s=i,u=o,Object.keys(s).reduce(function(e,t,n){var r=t.split("-"),i=parseInt(r[0],10),o=parseInt(r[1],10);return e.push(Object.assign({index:n,position:[u.xOffset*o-180,u.yOffset*i-90]},s[t])),e},[]));var s,u;return{gridOffset:o,layerData:a}};var v=6378e3},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),o=n(13),a=n(174),u=(r=a)&&r.__esModule?r:{default:r},c=n(298);var l=o.experimental.BinSorter,s=o.experimental.defaultColorRange,f=o.experimental.getQuantizeScale,d=o.experimental.getLinearScale;function h(){}var p={colorDomain:null,colorRange:s,getColorValue:function(e){return e.length},lowerPercentile:0,upperPercentile:100,onSetColorDomain:h,elevationDomain:null,elevationRange:[0,1e3],getElevationValue:function(e){return e.length},elevationLowerPercentile:0,elevationUpperPercentile:100,elevationScale:1,onSetElevationDomain:h,cellSize:1e3,coverage:1,getPosition:function(e){return e.position},extruded:!1,fp64:!1,lightSettings:{lightsPosition:[-122.45,37.75,8e3,-122,38,5e3],ambientRatio:.05,diffuseRatio:.6,specularRatio:.8,lightsStrength:[2,0,0,0],numberOfLights:2}},v=function(e){function s(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(s.__proto__||Object.getPrototypeOf(s)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(s,o.CompositeLayer),i(s,[{key:"initializeState",value:function(){this.state={layerData:[],sortedColorBins:null,sortedElevationBins:null,colorValueDomain:null,elevationValueDomain:null,colorScaleFunc:h,elevationScaleFunc:h,dimensionUpdaters:this.getDimensionUpdaters()}}},{key:"updateState",value:function(e){var t=this,n=e.oldProps,r=e.props,i=e.changeFlags,o=this.getDimensionChanges(n,r);i.dataChanged||this.needsReProjectPoints(n,r)?this.getLayerData():o&&o.forEach(function(e){return"function"==typeof e&&e.apply(t)})}},{key:"needsReProjectPoints",value:function(e,t){return e.cellSize!==t.cellSize}},{key:"getDimensionUpdaters",value:function(){return{getColor:[{id:"value",triggers:["getColorValue"],updater:this.getSortedColorBins},{id:"domain",triggers:["lowerPercentile","upperPercentile"],updater:this.getColorValueDomain},{id:"scaleFunc",triggers:["colorDomain","colorRange"],updater:this.getColorScale}],getElevation:[{id:"value",triggers:["getElevationValue"],updater:this.getSortedElevationBins},{id:"domain",triggers:["elevationLowerPercentile","elevationUpperPercentile"],updater:this.getElevationValueDomain},{id:"scaleFunc",triggers:["elevationDomain","elevationRange"],updater:this.getElevationScale}]}}},{key:"getDimensionChanges",value:function(t,n){var e=this.state.dimensionUpdaters,r=[];for(var i in e){var o=e[i].find(function(e){return e.triggers.some(function(e){return t[e]!==n[e]})});o&&r.push(o.updater)}return r.length?r:null}},{key:"getPickingInfo",value:function(e){var t=e.info,n=this.state,r=n.sortedColorBins,i=n.sortedElevationBins,o=null;if(t.picked&&-1<t.index){var a=this.state.layerData[t.index],s=r.binMap[a.index]&&r.binMap[a.index].value,u=i.binMap[a.index]&&i.binMap[a.index].value;o=Object.assign({colorValue:s,elevationValue:u},a)}return Object.assign(t,{picked:Boolean(o),object:o})}},{key:"getUpdateTriggers",value:function(){var a=this,s=this.state.dimensionUpdaters,u={},e=function(t){var e=!0,n=!(u[t]={}),r=void 0;try{for(var i,o=s[t][Symbol.iterator]();!(e=(i=o.next()).done);e=!0){i.value.triggers.forEach(function(e){u[t][e]=a.props[e]})}}catch(e){n=!0,r=e}finally{try{!e&&o.return&&o.return()}finally{if(n)throw r}}};for(var t in s)e(t);return u}},{key:"getLayerData",value:function(){var e=this.props,t=e.data,n=e.cellSize,r=e.getPosition,i=(0,c.pointToDensityGridData)(t,n,r).layerData;this.setState({layerData:i}),this.getSortedBins()}},{key:"getValueDomain",value:function(){this.getColorValueDomain(),this.getElevationValueDomain()}},{key:"getSortedBins",value:function(){this.getSortedColorBins(),this.getSortedElevationBins()}},{key:"getSortedColorBins",value:function(){var e=this.props.getColorValue,t=new l(this.state.layerData||[],e);this.setState({sortedColorBins:t}),this.getColorValueDomain()}},{key:"getSortedElevationBins",value:function(){var e=this.props.getElevationValue,t=new l(this.state.layerData||[],e);this.setState({sortedElevationBins:t}),this.getElevationValueDomain()}},{key:"getColorValueDomain",value:function(){var e=this.props,t=e.lowerPercentile,n=e.upperPercentile,r=e.onSetColorDomain;this.state.colorValueDomain=this.state.sortedColorBins.getValueRange([t,n]),"function"==typeof r&&r(this.state.colorValueDomain),this.getColorScale()}},{key:"getElevationValueDomain",value:function(){var e=this.props,t=e.elevationLowerPercentile,n=e.elevationUpperPercentile,r=e.onSetElevationDomain;this.state.elevationValueDomain=this.state.sortedElevationBins.getValueRange([t,n]),"function"==typeof r&&r(this.state.elevationValueDomain),this.getElevationScale()}},{key:"getColorScale",value:function(){var e=this.props.colorRange,t=this.props.colorDomain||this.state.colorValueDomain;this.state.colorScaleFunc=f(t,e)}},{key:"getElevationScale",value:function(){var e=this.props.elevationRange,t=this.props.elevationDomain||this.state.elevationValueDomain;this.state.elevationScaleFunc=d(t,e)}},{key:"_onGetSublayerColor",value:function(e){var t=this.state,n=t.sortedColorBins,r=t.colorScaleFunc,i=t.colorValueDomain,o=n.binMap[e.index]&&n.binMap[e.index].value,a=this.props.colorDomain||i,s=o>=a[0]&&o<=a[a.length-1]?r(o):[0,0,0,0];return s[3]=Number.isFinite(s[3])?s[3]:255,s}},{key:"_onGetSublayerElevation",value:function(e){var t=this.state,n=t.sortedElevationBins,r=t.elevationScaleFunc,i=t.elevationValueDomain,o=n.binMap[e.index]&&n.binMap[e.index].value,a=this.props.elevationDomain||i;return o>=a[0]&&o<=a[a.length-1]?r(o):-1}},{key:"getSubLayerProps",value:function(){var e=this.props,t=e.elevationScale,n=e.fp64,r=e.extruded,i=e.cellSize,o=e.coverage,a=e.lightSettings;return function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0}(s.prototype.__proto__||Object.getPrototypeOf(s.prototype),"getSubLayerProps",this).call(this,{id:"grid-cell",data:this.state.layerData,fp64:n,cellSize:i,coverage:o,lightSettings:a,elevationScale:t,extruded:r,getColor:this._onGetSublayerColor.bind(this),getElevation:this._onGetSublayerElevation.bind(this),updateTriggers:this.getUpdateTriggers()})}},{key:"getSubLayerClass",value:function(){return u.default}},{key:"renderLayers",value:function(){return new(this.getSubLayerClass())(this.getSubLayerProps())}}]),s}();(t.default=v).layerName="GridLayer",v.defaultProps=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME hexagon-cell-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nvarying vec4 vColor;\n\nvoid main(void) {\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME hexagon-cell-layer-vertex-shader-64\n\nattribute vec3 positions;\nattribute vec3 normals;\n\nattribute vec3 instancePositions;\nattribute vec2 instancePositions64xyLow;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\n// Custom uniforms\nuniform float opacity;\nuniform float radius;\nuniform float angle;\nuniform float extruded;\nuniform float coverage;\nuniform float elevationScale;\n\n// Result\nvarying vec4 vColor;\n\n// A magic number to scale elevation so that 1 unit approximate to 1 meter.\n#define ELEVATION_SCALE 0.8\n\nvoid main(void) {\n\n // rotate primitive position and normal\n mat2 rotationMatrix = mat2(cos(angle), -sin(angle), sin(angle), cos(angle));\n\n vec2 rPos = rotationMatrix * positions.xz;\n vec2 rNorm = rotationMatrix * normals.xz; // the hexagon cells has y axis as the vertical axis\n\n vec3 rotatedPositions = vec3(rPos.x, positions.y, rPos.y);\n vec3 rotatedNormals = vec3(rNorm.x, rNorm.y, normals.y);\n\n // calculate elevation, if 3d not enabled set to 0\n // cylindar gemoetry height are between -0.5 to 0.5, transform it to between 0, 1\n float elevation = 0.0;\n\n if (extruded > 0.5) {\n elevation = project_scale(instancePositions.z * (positions.y + 0.5) *\n ELEVATION_SCALE * elevationScale);\n }\n\n // if alpha == 0.0 or z < 0.0, do not render element\n float noRender = float(instanceColors.a == 0.0 || instancePositions.z < 0.0);\n float dotRadius = radius * mix(coverage, 0.0, noRender);\n\n // project center of hexagon\n\n vec4 instancePositions64xy = vec4(\n instancePositions.x, instancePositions64xyLow.x,\n instancePositions.y, instancePositions64xyLow.y);\n\n vec2 projected_coord_xy[2];\n project_position_fp64(instancePositions64xy, projected_coord_xy);\n\n vec2 vertex_pos_localspace[4];\n vec4_fp64(vec4(rotatedPositions.xz * dotRadius, 0.0, 1.0), vertex_pos_localspace);\n\n vec2 vertex_pos_modelspace[4];\n vertex_pos_modelspace[0] = sum_fp64(vertex_pos_localspace[0], projected_coord_xy[0]);\n vertex_pos_modelspace[1] = sum_fp64(vertex_pos_localspace[1], projected_coord_xy[1]);\n vertex_pos_modelspace[2] = sum_fp64(vertex_pos_localspace[2], vec2(elevation, 0.0));\n vertex_pos_modelspace[3] = vec2(1.0, 0.0);\n\n vec4 position_worldspace = vec4(\n vertex_pos_modelspace[0].x, vertex_pos_modelspace[1].x,\n vertex_pos_modelspace[2].x, vertex_pos_modelspace[3].x);\n\n gl_Position = project_to_clipspace_fp64(vertex_pos_modelspace);\n\n // Light calculations\n // Worldspace is the linear space after Mercator projection\n\n vec3 normals_worldspace = rotatedNormals;\n\n float lightWeight = 1.0;\n\n if (extruded > 0.5) {\n lightWeight = getLightWeight(\n position_worldspace.xyz, // the w component is always 1.0\n normals_worldspace\n );\n }\n\n vec3 lightWeightedColor = lightWeight * instanceColors.rgb;\n\n // Color: Either opacity-multiplied instance color, or picking color\n vColor = vec4(lightWeightedColor, opacity * instanceColors.a) / 255.0;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="\n#define SHADER_NAME hexagon-cell-layer-vertex-shader\n\nattribute vec3 positions;\nattribute vec3 normals;\n\nattribute vec3 instancePositions;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\n// Custom uniforms\nuniform float opacity;\nuniform float radius;\nuniform float angle;\nuniform float extruded;\nuniform float coverage;\nuniform float elevationScale;\n\n// Result\nvarying vec4 vColor;\n\n// A magic number to scale elevation so that 1 unit approximate to 1 meter.\n#define ELEVATION_SCALE 0.8\n\nvoid main(void) {\n\n // rotate primitive position and normal\n mat2 rotationMatrix = mat2(cos(angle), -sin(angle), sin(angle), cos(angle));\n\n vec2 rPos = rotationMatrix * positions.xz;\n vec2 rNorm = rotationMatrix * normals.xz; // the hexagon cells has y axis as the vertical axis\n\n vec3 rotatedPositions = vec3(rPos.x, positions.y, rPos.y);\n vec3 rotatedNormals = vec3(rNorm.x, rNorm.y, normals.y);\n\n // calculate elevation, if 3d not enabled set to 0\n // cylindar gemoetry height are between -0.5 to 0.5, transform it to between 0, 1\n float elevation = 0.0;\n\n if (extruded > 0.5) {\n elevation = project_scale(instancePositions.z * (positions.y + 0.5) *\n ELEVATION_SCALE * elevationScale);\n }\n\n // if ahpha == 0.0 or z < 0.0, do not render element\n float noRender = float(instanceColors.a == 0.0 || instancePositions.z < 0.0);\n float dotRadius = radius * mix(coverage, 0.0, noRender);\n\n // project center of hexagon\n vec4 centroidPosition = vec4(project_position(instancePositions.xy), elevation, 0.0);\n\n vec4 position_worldspace = centroidPosition + vec4(vec2(rotatedPositions.xz * dotRadius), 0., 1.);\n\n gl_Position = project_to_clipspace(position_worldspace);\n\n // Light calculations\n // Worldspace is the linear space after Mercator projection\n\n vec3 normals_worldspace = rotatedNormals;\n\n float lightWeight = 1.0;\n\n if (extruded > 0.5) {\n lightWeight = getLightWeight(\n position_worldspace.xyz, // the w component is always 1.0\n normals_worldspace\n );\n }\n\n vec3 lightWeightedColor = lightWeight * instanceColors.rgb;\n\n // opacity-multiplied instance color\n vColor = vec4(lightWeightedColor, opacity * instanceColors.a) / 255.0;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pointToHexbin=function(e,n){var t=e.data,r=e.radius,i=e.getPosition,o=u(r,n),a=t.map(function(e){return Object.assign({screenCoord:n.projectFlat(i(e))},e)});return{hexagons:(0,s.hexbin)().radius(o).x(function(e){return e.screenCoord[0]}).y(function(e){return e.screenCoord[1]})(a).map(function(e,t){return{centroid:n.unprojectFlat([e.x,e.y]),points:e,index:t}})}},t.getRadiusInPixel=u;var s=n(567);function u(e,t){return e*t.getDistanceScales().pixelsPerMeter[0]}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),o=n(13),a=n(175),u=(r=a)&&r.__esModule?r:{default:r},s=n(303);var c=o.experimental.log,l=o.experimental.BinSorter,f=o.experimental.getQuantizeScale,d=o.experimental.getLinearScale;function h(){}var p={colorDomain:null,colorRange:o.experimental.defaultColorRange,getColorValue:function(e){return e.length},lowerPercentile:0,upperPercentile:100,onSetColorDomain:h,elevationDomain:null,elevationRange:[0,1e3],getElevationValue:function(e){return e.length},elevationLowerPercentile:0,elevationUpperPercentile:100,elevationScale:1,onSetElevationDomain:h,radius:1e3,coverage:1,extruded:!1,hexagonAggregator:s.pointToHexbin,getPosition:function(e){return e.position},fp64:!1,lightSettings:{lightsPosition:[-122.45,37.75,8e3,-122,38,5e3],ambientRatio:.05,diffuseRatio:.6,specularRatio:.8,lightsStrength:[2,0,0,0],numberOfLights:2}},v=function(e){function s(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),e.hexagonAggregator||e.radius||(c.once(0,"HexagonLayer: Default hexagonAggregator requires radius prop to be set, Now using 1000 meter as default"),e.radius=p.radius),Number.isFinite(e.upperPercentile)&&(100<e.upperPercentile||e.upperPercentile<0)&&(c.once(0,"HexagonLayer: upperPercentile should be between 0 and 100. Assign to 100 by default"),e.upperPercentile=p.upperPercentile),Number.isFinite(e.lowerPercentile)&&(100<e.lowerPercentile||e.lowerPercentile<0)&&(c.once(0,"HexagonLayer: lowerPercentile should be between 0 and 100. Assign to 0 by default"),e.lowerPercentile=p.upperPercentile),e.lowerPercentile>=e.upperPercentile&&(c.once(0,"HexagonLayer: lowerPercentile should not be bigger than upperPercentile. Assign to 0 by default"),e.lowerPercentile=p.lowerPercentile),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(s.__proto__||Object.getPrototypeOf(s)).call(this,e))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(s,o.CompositeLayer),i(s,[{key:"initializeState",value:function(){this.state={hexagons:[],hexagonVertices:null,sortedColorBins:null,sortedElevationBins:null,colorValueDomain:null,elevationValueDomain:null,colorScaleFunc:h,elevationScaleFunc:h,dimensionUpdaters:this.getDimensionUpdaters()}}},{key:"updateState",value:function(e){var t=this,n=e.oldProps,r=e.props,i=e.changeFlags,o=this.getDimensionChanges(n,r);i.dataChanged||this.needsReProjectPoints(n,r)?this.getHexagons():o&&o.forEach(function(e){return"function"==typeof e&&e.apply(t)})}},{key:"needsReProjectPoints",value:function(e,t){return e.radius!==t.radius||e.hexagonAggregator!==t.hexagonAggregator}},{key:"getDimensionUpdaters",value:function(){return{getColor:[{id:"value",triggers:["getColorValue"],updater:this.getSortedColorBins},{id:"domain",triggers:["lowerPercentile","upperPercentile"],updater:this.getColorValueDomain},{id:"scaleFunc",triggers:["colorDomain","colorRange"],updater:this.getColorScale}],getElevation:[{id:"value",triggers:["getElevationValue"],updater:this.getSortedElevationBins},{id:"domain",triggers:["elevationLowerPercentile","elevationUpperPercentile"],updater:this.getElevationValueDomain},{id:"scaleFunc",triggers:["elevationDomain","elevationRange"],updater:this.getElevationScale}]}}},{key:"getDimensionChanges",value:function(t,n){var e=this.state.dimensionUpdaters,r=[];for(var i in e){var o=e[i].find(function(e){return e.triggers.some(function(e){return t[e]!==n[e]})});o&&r.push(o.updater)}return r.length?r:null}},{key:"getHexagons",value:function(){var e=this.props.hexagonAggregator,t=this.context.viewport,n=e(this.props,t),r=n.hexagons,i=n.hexagonVertices;this.setState({hexagons:r,hexagonVertices:i}),this.getSortedBins()}},{key:"getPickingInfo",value:function(e){var t=e.info,n=this.state,r=n.sortedColorBins,i=n.sortedElevationBins,o=null;if(t.picked&&-1<t.index){var a=this.state.hexagons[t.index],s=r.binMap[a.index]&&r.binMap[a.index].value,u=i.binMap[a.index]&&i.binMap[a.index].value;o=Object.assign({colorValue:s,elevationValue:u},a)}return Object.assign(t,{picked:Boolean(o),object:o})}},{key:"getUpdateTriggers",value:function(){var a=this,s=this.state.dimensionUpdaters,u={},e=function(t){var e=!0,n=!(u[t]={}),r=void 0;try{for(var i,o=s[t][Symbol.iterator]();!(e=(i=o.next()).done);e=!0){i.value.triggers.forEach(function(e){u[t][e]=a.props[e]})}}catch(e){n=!0,r=e}finally{try{!e&&o.return&&o.return()}finally{if(n)throw r}}};for(var t in s)e(t);return u}},{key:"getValueDomain",value:function(){this.getColorValueDomain(),this.getElevationValueDomain()}},{key:"getSortedBins",value:function(){this.getSortedColorBins(),this.getSortedElevationBins()}},{key:"getSortedColorBins",value:function(){var e=this.props.getColorValue,t=new l(this.state.hexagons||[],e);this.setState({sortedColorBins:t}),this.getColorValueDomain()}},{key:"getSortedElevationBins",value:function(){var e=this.props.getElevationValue,t=new l(this.state.hexagons||[],e);this.setState({sortedElevationBins:t}),this.getElevationValueDomain()}},{key:"getColorValueDomain",value:function(){var e=this.props,t=e.lowerPercentile,n=e.upperPercentile,r=e.onSetColorDomain;this.state.colorValueDomain=this.state.sortedColorBins.getValueRange([t,n]),"function"==typeof r&&r(this.state.colorValueDomain),this.getColorScale()}},{key:"getElevationValueDomain",value:function(){var e=this.props,t=e.elevationLowerPercentile,n=e.elevationUpperPercentile,r=e.onSetElevationDomain;this.state.elevationValueDomain=this.state.sortedElevationBins.getValueRange([t,n]),"function"==typeof r&&r(this.state.elevationValueDomain),this.getElevationScale()}},{key:"getColorScale",value:function(){var e=this.props.colorRange,t=this.props.colorDomain||this.state.colorValueDomain;this.state.colorScaleFunc=f(t,e)}},{key:"getElevationScale",value:function(){var e=this.props.elevationRange,t=this.props.elevationDomain||this.state.elevationValueDomain;this.state.elevationScaleFunc=d(t,e)}},{key:"_onGetSublayerColor",value:function(e){var t=this.state,n=t.sortedColorBins,r=t.colorScaleFunc,i=t.colorValueDomain,o=n.binMap[e.index]&&n.binMap[e.index].value,a=this.props.colorDomain||i,s=o>=a[0]&&o<=a[a.length-1]?r(o):[0,0,0,0];return s[3]=Number.isFinite(s[3])?s[3]:255,s}},{key:"_onGetSublayerElevation",value:function(e){var t=this.state,n=t.sortedElevationBins,r=t.elevationScaleFunc,i=t.elevationValueDomain,o=n.binMap[e.index]&&n.binMap[e.index].value,a=this.props.elevationDomain||i;return o>=a[0]&&o<=a[a.length-1]?r(o):-1}},{key:"getSubLayerProps",value:function(){var e=this.props,t=e.radius,n=e.elevationScale,r=e.extruded,i=e.coverage,o=e.lightSettings,a=e.fp64;return function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0}(s.prototype.__proto__||Object.getPrototypeOf(s.prototype),"getSubLayerProps",this).call(this,{id:"hexagon-cell",data:this.state.hexagons,fp64:a,hexagonVertices:this.state.hexagonVertices,radius:t,elevationScale:n,angle:Math.PI,extruded:r,coverage:i,lightSettings:o,getColor:this._onGetSublayerColor.bind(this),getElevation:this._onGetSublayerElevation.bind(this),updateTriggers:this.getUpdateTriggers()})}},{key:"getSubLayerClass",value:function(){return u.default}},{key:"renderLayers",value:function(){return new(this.getSubLayerClass())(this.getSubLayerProps())}}]),s}();(t.default=v).layerName="HexagonLayer",v.defaultProps=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME icon-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nuniform float opacity;\nuniform sampler2D iconsTexture;\n\nvarying float vColorMode;\nvarying vec4 vColor;\nvarying vec2 vTextureCoords;\n\nconst float MIN_ALPHA = 0.05;\n\nvoid main(void) {\n vec4 texColor = texture2D(iconsTexture, vTextureCoords);\n\n // if colorMode == 0, use pixel color from the texture\n // if colorMode == 1 or rendering picking buffer, use texture as transparency mask\n vec3 color = mix(texColor.rgb, vColor.rgb, vColorMode);\n float a = texColor.a * opacity * mix(1.0, vColor.a, vColorMode);\n\n if (a < MIN_ALPHA) {\n discard;\n }\n\n gl_FragColor = vec4(color, a);\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default='#define SHADER_NAME icon-layer-vertex-shader-64\n\nattribute vec2 positions;\n\nattribute vec3 instancePositions;\nattribute vec2 instancePositions64xyLow;\nattribute float instanceSizes;\nattribute float instanceAngles;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\nattribute vec4 instanceIconFrames;\nattribute float instanceColorModes;\nattribute vec2 instanceOffsets;\n\nuniform float sizeScale;\nuniform vec2 iconsTextureDim;\n\nvarying float vColorMode;\nvarying vec4 vColor;\nvarying vec2 vTextureCoords;\n\nvec2 rotate_by_angle(vec2 vertex, float angle) {\n float angle_radian = angle * PI / 180.0;\n float cos_angle = cos(angle_radian);\n float sin_angle = sin(angle_radian);\n mat2 rotationMatrix = mat2(cos_angle, -sin_angle, sin_angle, cos_angle);\n return rotationMatrix * vertex;\n}\n\nvoid main(void) {\n vec2 iconSize = instanceIconFrames.zw;\n // scale icon height to match instanceSize\n float instanceScale = iconSize.y == 0.0 ? 0.0 : instanceSizes / iconSize.y;\n\n // scale and rotate vertex in "pixel" value and convert back to fraction in clipspace\n vec2 pixelOffset = positions / 2.0 * iconSize + instanceOffsets;\n pixelOffset = rotate_by_angle(pixelOffset, instanceAngles) * sizeScale * instanceScale;\n pixelOffset.y *= -1.0;\n\n vec4 instancePositions64xy = vec4(\n instancePositions.x, instancePositions64xyLow.x,\n instancePositions.y, instancePositions64xyLow.y);\n\n vec2 projected_coord_xy[2];\n project_position_fp64(instancePositions64xy, projected_coord_xy);\n\n vec2 vertex_pos_modelspace[4];\n vertex_pos_modelspace[0] = projected_coord_xy[0];\n vertex_pos_modelspace[1] = projected_coord_xy[1];\n vertex_pos_modelspace[2] = vec2(project_scale(instancePositions.z), 0.0);\n vertex_pos_modelspace[3] = vec2(1.0, 0.0);\n\n gl_Position = project_to_clipspace_fp64(vertex_pos_modelspace);\n gl_Position += project_pixel_to_clipspace(pixelOffset);\n\n vTextureCoords = mix(\n instanceIconFrames.xy,\n instanceIconFrames.xy + iconSize,\n (positions.xy + 1.0) / 2.0\n ) / iconsTextureDim;\n\n vTextureCoords.y = 1.0 - vTextureCoords.y;\n\n vColor = instanceColors / 255.;\n\n vColorMode = instanceColorModes;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n'},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default='#define SHADER_NAME icon-layer-vertex-shader\n\nattribute vec2 positions;\n\nattribute vec3 instancePositions;\nattribute float instanceSizes;\nattribute float instanceAngles;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\nattribute vec4 instanceIconFrames;\nattribute float instanceColorModes;\nattribute vec2 instanceOffsets;\n\nuniform float sizeScale;\nuniform vec2 iconsTextureDim;\n\nvarying float vColorMode;\nvarying vec4 vColor;\nvarying vec2 vTextureCoords;\n\nvec2 rotate_by_angle(vec2 vertex, float angle) {\n float angle_radian = angle * PI / 180.0;\n float cos_angle = cos(angle_radian);\n float sin_angle = sin(angle_radian);\n mat2 rotationMatrix = mat2(cos_angle, -sin_angle, sin_angle, cos_angle);\n return rotationMatrix * vertex;\n}\n\nvoid main(void) {\n vec2 iconSize = instanceIconFrames.zw;\n // scale icon height to match instanceSize\n float instanceScale = iconSize.y == 0.0 ? 0.0 : instanceSizes / iconSize.y;\n\n // scale and rotate vertex in "pixel" value and convert back to fraction in clipspace\n vec2 pixelOffset = positions / 2.0 * iconSize + instanceOffsets;\n pixelOffset = rotate_by_angle(pixelOffset, instanceAngles) * sizeScale * instanceScale;\n pixelOffset.y *= -1.0;\n\n vec3 center = project_position(instancePositions);\n gl_Position = project_to_clipspace(vec4(center, 1.0));\n gl_Position += project_pixel_to_clipspace(pixelOffset);\n\n vTextureCoords = mix(\n instanceIconFrames.xy,\n instanceIconFrames.xy + iconSize,\n (positions.xy + 1.0) / 2.0\n ) / iconsTextureDim;\n\n vTextureCoords.y = 1.0 - vTextureCoords.y;\n\n vColor = instanceColors / 255.;\n\n vColorMode = instanceColorModes;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n'},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var f=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),d=n(12),o=u(n(307)),a=u(n(306)),s=u(n(305));function u(e){return e&&e.__esModule?e:{default:e}}function h(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var p=i.experimental.fp64LowPart,c=i.experimental.enable64bitSupport,l=[0,0,0,255],v=d.GL.LINEAR_MIPMAP_LINEAR,g=d.GL.LINEAR,y={iconAtlas:null,iconMapping:{},sizeScale:1,fp64:!1,getPosition:function(e){return e.position},getIcon:function(e){return e.icon},getColor:function(e){return e.color||l},getSize:function(e){return e.size||1},getAngle:function(e){return e.angle||0}},_=function(e){function l(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,l),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(l.__proto__||Object.getPrototypeOf(l)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(l,i.Layer),r(l,[{key:"getShaders",value:function(){return c(this.props)?{vs:a.default,fs:s.default,modules:["project64","picking"]}:{vs:o.default,fs:s.default,modules:["picking"]}}},{key:"initializeState",value:function(){this.getAttributeManager().addInstanced({instancePositions:{size:3,transition:!0,accessor:"getPosition",update:this.calculateInstancePositions},instanceSizes:{size:1,transition:!0,accessor:"getSize",update:this.calculateInstanceSizes},instanceOffsets:{size:2,accessor:"getIcon",update:this.calculateInstanceOffsets},instanceIconFrames:{size:4,accessor:"getIcon",update:this.calculateInstanceIconFrames},instanceColorModes:{size:1,type:d.GL.UNSIGNED_BYTE,accessor:"getIcon",update:this.calculateInstanceColorMode},instanceColors:{size:4,type:d.GL.UNSIGNED_BYTE,transition:!0,accessor:"getColor",update:this.calculateInstanceColors},instanceAngles:{size:1,transition:!0,accessor:"getAngle",update:this.calculateInstanceAngles}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.addInstanced({instancePositions64xyLow:{size:2,accessor:"getPosition",update:this.calculateInstancePositions64xyLow}}):r.remove(["instancePositions64xyLow"])}}},{key:"updateState",value:function(e){var r=this,t=e.oldProps,n=e.props,i=e.changeFlags;(function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0})(l.prototype.__proto__||Object.getPrototypeOf(l.prototype),"updateState",this).call(this,{props:n,oldProps:t,changeFlags:i});var o,a=n.iconAtlas,s=n.iconMapping;if(t.iconMapping!==s){var u=this.getAttributeManager();u.invalidate("instanceOffsets"),u.invalidate("instanceIconFrames"),u.invalidate("instanceColorModes")}t.iconAtlas!==a&&(a instanceof d.Texture2D?(a.setParameters((h(o={},d.GL.TEXTURE_MIN_FILTER,v),h(o,d.GL.TEXTURE_MAG_FILTER,g),o)),this.setState({iconsTexture:a})):"string"==typeof a&&(0,d.loadTextures)(this.context.gl,{urls:[a]}).then(function(e){var t,n=f(e,1)[0];n.setParameters((h(t={},d.GL.TEXTURE_MIN_FILTER,v),h(t,d.GL.TEXTURE_MAG_FILTER,g),t)),r.setState({iconsTexture:n})}));if(n.fp64!==t.fp64){var c=this.context.gl;this.setState({model:this._getModel(c)})}this.updateAttribute({props:n,oldProps:t,changeFlags:i})}},{key:"draw",value:function(e){var t=e.uniforms,n=this.props.sizeScale,r=this.state.iconsTexture;r&&this.state.model.render(Object.assign({},t,{iconsTexture:r,iconsTextureDim:[r.width,r.height],sizeScale:n}))}},{key:"_getModel",value:function(e){return new d.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:new d.Geometry({drawMode:d.GL.TRIANGLE_FAN,attributes:{positions:new Float32Array([-1,-1,0,-1,1,0,1,1,0,1,-1,0])}}),isInstanced:!0,shaderCache:this.context.shaderCache}))}},{key:"calculateInstancePositions",value:function(e){var t=this.props,n=t.data,r=t.getPosition,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=f[0],i[o++]=f[1],i[o++]=f[2]||0}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstancePositions64xyLow",value:function(e){var t=this.props,n=t.data,r=t.getPosition,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=p(f[0]),i[o++]=p(f[1])}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceSizes",value:function(e){var t=this.props,n=t.data,r=t.getSize,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=c.value;i[o++]=r(f)}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceAngles",value:function(e){var t=this.props,n=t.data,r=t.getAngle,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=c.value;i[o++]=r(f)}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceColors",value:function(e){var t=this.props,n=t.data,r=t.getColor,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=f[0],i[o++]=f[1],i[o++]=f[2],i[o++]=isNaN(f[3])?255:f[3]}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceOffsets",value:function(e){var t=this.props,n=t.data,r=t.iconMapping,i=t.getIcon,o=e.value,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r[i(l.value)]||{};o[a++]=d.width/2-d.anchorX||0,o[a++]=d.height/2-d.anchorY||0}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}},{key:"calculateInstanceColorMode",value:function(e){var t=this.props,n=t.data,r=t.iconMapping,i=t.getIcon,o=e.value,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=i(l.value),h=r[d]&&r[d].mask;o[a++]=h?1:0}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}},{key:"calculateInstanceIconFrames",value:function(e){var t=this.props,n=t.data,r=t.iconMapping,i=t.getIcon,o=e.value,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r[i(l.value)]||{};o[a++]=d.x||0,o[a++]=d.y||0,o[a++]=d.width||0,o[a++]=d.height||0}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}}]),l}();(t.default=_).layerName="IconLayer",_.defaultProps=y},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(292);Object.defineProperty(t,"ArcLayer",{enumerable:!0,get:function(){return g(r).default}});var i=n(308);Object.defineProperty(t,"IconLayer",{enumerable:!0,get:function(){return g(i).default}});var o=n(313);Object.defineProperty(t,"LineLayer",{enumerable:!0,get:function(){return g(o).default}});var a=n(320);Object.defineProperty(t,"PointCloudLayer",{enumerable:!0,get:function(){return g(a).default}});var s=n(176);Object.defineProperty(t,"ScatterplotLayer",{enumerable:!0,get:function(){return g(s).default}});var u=n(327);Object.defineProperty(t,"ScreenGridLayer",{enumerable:!0,get:function(){return g(u).default}});var c=n(299);Object.defineProperty(t,"GridLayer",{enumerable:!0,get:function(){return g(c).default}});var l=n(174);Object.defineProperty(t,"GridCellLayer",{enumerable:!0,get:function(){return g(l).default}});var f=n(304);Object.defineProperty(t,"HexagonLayer",{enumerable:!0,get:function(){return g(f).default}});var d=n(175);Object.defineProperty(t,"HexagonCellLayer",{enumerable:!0,get:function(){return g(d).default}});var h=n(119);Object.defineProperty(t,"PathLayer",{enumerable:!0,get:function(){return g(h).default}});var p=n(321);Object.defineProperty(t,"PolygonLayer",{enumerable:!0,get:function(){return g(p).default}});var v=n(293);function g(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"GeoJsonLayer",{enumerable:!0,get:function(){return g(v).default}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME line-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nvarying vec4 vColor;\n\nvoid main(void) {\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME line-layer-vertex-shader-64\n\nattribute vec3 positions;\nattribute vec3 instanceSourcePositions;\nattribute vec3 instanceTargetPositions;\nattribute vec4 instanceSourceTargetPositions64xyLow;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\nuniform float strokeWidth;\nuniform float opacity;\n\nvarying vec4 vColor;\n\n// offset vector by strokeWidth pixels\n// offset_direction is -1 (left) or 1 (right)\nvec2 getExtrusionOffset(vec2 line_clipspace, float offset_direction) {\n // normalized direction of the line\n vec2 dir_screenspace = normalize(line_clipspace * project_uViewportSize);\n // rotate by 90 degrees\n dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x);\n\n vec2 offset_screenspace = dir_screenspace * offset_direction * strokeWidth / 2.0;\n vec2 offset_clipspace = project_pixel_to_clipspace(offset_screenspace).xy;\n\n return offset_clipspace;\n}\n\nvoid main(void) {\n // Position\n vec4 instanceSourcePositions64 = vec4(\n instanceSourcePositions.x, instanceSourceTargetPositions64xyLow.x,\n instanceSourcePositions.y, instanceSourceTargetPositions64xyLow.y);\n\n vec4 instanceTargetPositions64 = vec4(\n instanceTargetPositions.x, instanceSourceTargetPositions64xyLow.z,\n instanceTargetPositions.y, instanceSourceTargetPositions64xyLow.w);\n\n vec2 projected_source_coord[2];\n vec2 projected_target_coord[2];\n\n project_position_fp64(instanceSourcePositions64, projected_source_coord);\n project_position_fp64(instanceTargetPositions64, projected_target_coord);\n\n vec2 source_pos_modelspace[4];\n source_pos_modelspace[0] = projected_source_coord[0];\n source_pos_modelspace[1] = projected_source_coord[1];\n source_pos_modelspace[2] = vec2(project_scale(instanceSourcePositions.z), 0.0);\n source_pos_modelspace[3] = vec2(1.0, 0.0);\n\n vec4 source_pos_clipspace = project_to_clipspace_fp64(source_pos_modelspace);\n\n vec2 target_pos_modelspace[4];\n target_pos_modelspace[0] = projected_target_coord[0];\n target_pos_modelspace[1] = projected_target_coord[1];\n target_pos_modelspace[2] = vec2(project_scale(instanceTargetPositions.z), 0.0);\n target_pos_modelspace[3] = vec2(1.0, 0.0);\n\n vec4 target_pos_clipspace = project_to_clipspace_fp64(target_pos_modelspace);\n\n float segmentIndex = positions.x;\n vec4 p = mix(source_pos_clipspace, target_pos_clipspace, segmentIndex);\n\n vec2 offset = getExtrusionOffset(target_pos_clipspace.xy - source_pos_clipspace.xy, positions.y);\n\n gl_Position = p + vec4(offset, 0.0, 0.0);\n\n // Color\n vColor = vec4(instanceColors.rgb, instanceColors.a * opacity) / 255.;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME line-layer-vertex-shader\n\nattribute vec3 positions;\nattribute vec3 instanceSourcePositions;\nattribute vec3 instanceTargetPositions;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\nuniform float strokeWidth;\nuniform float opacity;\n\nvarying vec4 vColor;\n\n// offset vector by strokeWidth pixels\n// offset_direction is -1 (left) or 1 (right)\nvec2 getExtrusionOffset(vec2 line_clipspace, float offset_direction) {\n // normalized direction of the line\n vec2 dir_screenspace = normalize(line_clipspace * project_uViewportSize);\n // rotate by 90 degrees\n dir_screenspace = vec2(-dir_screenspace.y, dir_screenspace.x);\n\n vec2 offset_screenspace = dir_screenspace * offset_direction * strokeWidth / 2.0;\n vec2 offset_clipspace = project_pixel_to_clipspace(offset_screenspace).xy;\n\n return offset_clipspace;\n}\n\nvoid main(void) {\n // Position\n vec3 sourcePos = project_position(instanceSourcePositions);\n vec3 targetPos = project_position(instanceTargetPositions);\n vec4 source = project_to_clipspace(vec4(sourcePos, 1.0));\n vec4 target = project_to_clipspace(vec4(targetPos, 1.0));\n\n // linear interpolation of source & target to pick right coord\n float segmentIndex = positions.x;\n vec4 p = mix(source, target, segmentIndex);\n\n // extrude\n vec2 offset = getExtrusionOffset(target.xy - source.xy, positions.y);\n gl_Position = p + vec4(offset, 0.0, 0.0);\n\n // Color\n vColor = vec4(instanceColors.rgb, instanceColors.a * opacity) / 255.;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),a=n(12),s=o(n(312)),u=o(n(311)),c=o(n(310));function o(e){return e&&e.__esModule?e:{default:e}}var g=i.experimental.fp64LowPart,l=i.experimental.enable64bitSupport,f=[0,0,0,255],d={strokeWidth:1,fp64:!1,getSourcePosition:function(e){return e.sourcePosition},getTargetPosition:function(e){return e.targetPosition},getColor:function(e){return e.color||f}},h=function(e){function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,i.Layer),r(o,[{key:"getShaders",value:function(){return l(this.props)?{vs:u.default,fs:c.default,modules:["project64","picking"]}:{vs:s.default,fs:c.default,modules:["picking"]}}},{key:"initializeState",value:function(){this.getAttributeManager().addInstanced({instanceSourcePositions:{size:3,transition:!0,accessor:"getSourcePosition",update:this.calculateInstanceSourcePositions},instanceTargetPositions:{size:3,transition:!0,accessor:"getTargetPosition",update:this.calculateInstanceTargetPositions},instanceColors:{size:4,type:a.GL.UNSIGNED_BYTE,transition:!0,accessor:"getColor",update:this.calculateInstanceColors}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.addInstanced({instanceSourceTargetPositions64xyLow:{size:4,accessor:["getSourcePosition","getTargetPosition"],update:this.calculateInstanceSourceTargetPositions64xyLow}}):r.remove(["instanceSourceTargetPositions64xyLow"])}}},{key:"updateState",value:function(e){var t=e.props,n=e.oldProps,r=e.changeFlags;if(function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0}(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"updateState",this).call(this,{props:t,oldProps:n,changeFlags:r}),t.fp64!==n.fp64){var i=this.context.gl;this.setState({model:this._getModel(i)})}this.updateAttribute({props:t,oldProps:n,changeFlags:r})}},{key:"draw",value:function(e){var t=e.uniforms,n=this.props.strokeWidth;this.state.model.render(Object.assign({},t,{strokeWidth:n}))}},{key:"_getModel",value:function(e){return new a.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:new a.Geometry({drawMode:a.GL.TRIANGLE_STRIP,attributes:{positions:new Float32Array([0,-1,0,0,1,0,1,-1,0,1,1,0])}}),isInstanced:!0,shaderCache:this.context.shaderCache}))}},{key:"calculateInstanceSourcePositions",value:function(e){var t=this.props,n=t.data,r=t.getSourcePosition,i=e.value,o=e.size,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r(l.value);i[a+0]=d[0],i[a+1]=d[1],i[a+2]=isNaN(d[2])?0:d[2],a+=o}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}},{key:"calculateInstanceTargetPositions",value:function(e){var t=this.props,n=t.data,r=t.getTargetPosition,i=e.value,o=e.size,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r(l.value);i[a+0]=d[0],i[a+1]=d[1],i[a+2]=isNaN(d[2])?0:d[2],a+=o}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}},{key:"calculateInstanceSourceTargetPositions64xyLow",value:function(e){var t=this.props,n=t.data,r=t.getSourcePosition,i=t.getTargetPosition,o=e.value,a=e.size,s=0,u=!0,c=!1,l=void 0;try{for(var f,d=n[Symbol.iterator]();!(u=(f=d.next()).done);u=!0){var h=f.value,p=r(h),v=i(h);o[s+0]=g(p[0]),o[s+1]=g(p[1]),o[s+2]=g(v[0]),o[s+3]=g(v[1]),s+=a}}catch(e){c=!0,l=e}finally{try{!u&&d.return&&d.return()}finally{if(c)throw l}}}},{key:"calculateInstanceColors",value:function(e){var t=this.props,n=t.data,r=t.getColor,i=e.value,o=e.size,a=0,s=!0,u=!1,c=void 0;try{for(var l,f=n[Symbol.iterator]();!(s=(l=f.next()).done);s=!0){var d=r(l.value);i[a+0]=d[0],i[a+1]=d[1],i[a+2]=d[2],i[a+3]=isNaN(d[3])?255:d[3],a+=o}}catch(e){u=!0,c=e}finally{try{!s&&f.return&&f.return()}finally{if(u)throw c}}}}]),o}();(t.default=h).layerName="LineLayer",h.defaultProps=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME path-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nuniform float jointType;\nuniform float miterLimit;\nuniform float alignMode;\n\nvarying vec4 vColor;\nvarying vec2 vCornerOffset;\nvarying float vMiterLength;\nvarying vec2 vDashArray;\nvarying float vPathPosition;\nvarying float vPathLength;\n\n// mod doesn't work correctly for negative numbers\nfloat mod2(float a, float b) {\n return a - floor(a / b) * b;\n}\n\nfloat round(float x) {\n return floor(x + 0.5);\n}\n\n// if given position is in the gap part of the dashed line\n// dashArray.x: solid stroke length, relative to width\n// dashArray.y: gap length, relative to width\n// alignMode:\n// 0 - no adjustment\n// o---- ---- ---- ---- o---- -o---- ---- o\n// 1 - stretch to fit, draw half dash at each end for nicer joints\n// o-- ---- ---- ---- --o-- --o-- ---- --o\nbool dash_isFragInGap() {\n float solidLength = vDashArray.x;\n float gapLength = vDashArray.y;\n\n float unitLength = solidLength + gapLength;\n\n if (unitLength == 0.0) {\n return false;\n }\n\n unitLength = mix(\n unitLength,\n vPathLength / round(vPathLength / unitLength),\n alignMode\n );\n\n float offset = alignMode * solidLength / 2.0;\n\n return gapLength > 0.0 &&\n vPathPosition >= 0.0 &&\n vPathPosition <= vPathLength &&\n mod2(vPathPosition + offset, unitLength) > solidLength;\n}\n\nvoid main(void) {\n // if joint is rounded, test distance from the corner\n if (jointType > 0.0 && vMiterLength > 0.0 && length(vCornerOffset) > 1.0) {\n // Enable to debug joints\n // gl_FragColor = vec4(0., 1., 0., 1.);\n // return;\n discard;\n }\n if (jointType == 0.0 && vMiterLength > miterLimit) {\n // Enable to debug joints\n // gl_FragColor = vec4(0., 0., 1., 1.);\n // return;\n discard;\n }\n if (vColor.a == 0.0 || dash_isFragInGap()) {\n // Enable to debug joints\n // gl_FragColor = vec4(0., 1., 1., 1.);\n // return;\n discard;\n }\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="\n#define SHADER_NAME path-layer-vertex-shader\n\nattribute vec3 positions;\n\nattribute vec3 instanceStartPositions;\nattribute vec3 instanceEndPositions;\nattribute vec4 instanceStartEndPositions64xyLow;\nattribute vec3 instanceLeftDeltas;\nattribute vec3 instanceRightDeltas;\nattribute float instanceStrokeWidths;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\nattribute vec2 instanceDashArrays;\n\nuniform float widthScale;\nuniform float widthMinPixels;\nuniform float widthMaxPixels;\nuniform float jointType;\nuniform float miterLimit;\n\nuniform float opacity;\n\nvarying vec4 vColor;\nvarying vec2 vCornerOffset;\nvarying float vMiterLength;\nvarying vec2 vDashArray;\nvarying float vPathPosition;\nvarying float vPathLength;\n\nconst float EPSILON = 0.001;\nconst float PIXEL_EPSILON = 0.1;\n\nfloat flipIfTrue(bool flag) {\n return -(float(flag) * 2. - 1.);\n}\n\nvec3 lineJoin(vec2 prevPoint64[2], vec2 currPoint64[2], vec2 nextPoint64[2]) {\n\n float width = clamp(project_scale(instanceStrokeWidths * widthScale),\n widthMinPixels, widthMaxPixels) / 2.0;\n\n vec2 deltaA64[2];\n vec2 deltaB64[2];\n\n vec2_sub_fp64(currPoint64, prevPoint64, deltaA64);\n vec2_sub_fp64(nextPoint64, currPoint64, deltaB64);\n\n vec2 lengthA64 = vec2_length_fp64(deltaA64);\n vec2 lengthB64 = vec2_length_fp64(deltaB64);\n\n vec2 deltaA = vec2(deltaA64[0].x, deltaA64[1].x);\n vec2 deltaB = vec2(deltaB64[0].x, deltaB64[1].x);\n\n float lenA = lengthA64.x;\n float lenB = lengthB64.x;\n\n vec2 offsetVec;\n float offsetScale;\n float offsetDirection;\n\n // when two points are closer than PIXEL_EPSILON in pixels,\n // assume they are the same point to avoid precision issue\n lenA = lenA > PIXEL_EPSILON ? lenA : 0.0;\n lenB = lenB > PIXEL_EPSILON ? lenB : 0.0;\n vec2 dirA = lenA > 0. ? deltaA / lenA : vec2(0.0, 0.0);\n vec2 dirB = lenB > 0. ? deltaB / lenB : vec2(0.0, 0.0);\n\n vec2 perpA = vec2(-dirA.y, dirA.x);\n vec2 perpB = vec2(-dirB.y, dirB.x);\n\n // tangent of the corner\n vec2 tangent = vec2(dirA + dirB);\n tangent = length(tangent) > 0. ? normalize(tangent) : perpA;\n // direction of the corner\n vec2 miterVec = vec2(-tangent.y, tangent.x);\n // width offset from current position\n vec2 perp = mix(perpB, perpA, positions.x);\n float L = mix(lenB, lenA, positions.x);\n\n // cap super sharp angles\n float sinHalfA = abs(dot(miterVec, perp));\n float cosHalfA = abs(dot(dirA, miterVec));\n bool turnsRight = dirA.x * dirB.y > dirA.y * dirB.x;\n\n // relative position to the corner:\n // -1: inside (smaller side of the angle)\n // 0: center\n // 1: outside (bigger side of the angle)\n float cornerPosition = mix(\n flipIfTrue(turnsRight == (positions.y > 0.0)),\n 0.0,\n positions.z\n );\n\n offsetScale = 1.0 / max(sinHalfA, EPSILON);\n\n // do not bevel if line segment is too short\n cornerPosition *= float(cornerPosition <= 0.0 || sinHalfA < min(lenA, lenB) / width * cosHalfA);\n // trim if inside corner extends further than the line segment\n offsetScale = mix(\n offsetScale,\n min(offsetScale, L / width / max(cosHalfA, EPSILON)),\n float(cornerPosition < 0.0)\n );\n\n vMiterLength = mix(\n offsetScale * cornerPosition,\n mix(offsetScale, 0.0, cornerPosition),\n step(0.0, cornerPosition)\n ) - sinHalfA * jointType;\n offsetDirection = mix(\n positions.y,\n mix(\n flipIfTrue(turnsRight),\n positions.y * flipIfTrue(turnsRight == (positions.x == 1.)),\n cornerPosition\n ),\n step(0.0, cornerPosition)\n );\n offsetVec = mix(miterVec, -tangent, step(0.5, cornerPosition));\n offsetScale = mix(offsetScale, 1.0 / max(cosHalfA, 0.001), step(0.5, cornerPosition));\n\n // special treatment for start cap and end cap\n // using a small number as the limit for determining if the lenA or lenB is 0\n float isStartCap = step(lenA, 1.0e-5);\n float isEndCap = step(lenB, 1.0e-5);\n float isCap = max(isStartCap, isEndCap);\n\n // 0: center, 1: side\n cornerPosition = isCap * (1.0 - positions.z);\n\n // start of path: use next - curr\n offsetVec = mix(offsetVec, mix(dirB, perpB, cornerPosition), isStartCap);\n // end of path: use curr - prev\n offsetVec = mix(offsetVec, mix(dirA, perpA, cornerPosition), isEndCap);\n\n // extend out a triangle to envelope the round cap\n offsetScale = mix(\n offsetScale,\n mix(4.0 * jointType, 1.0, cornerPosition),\n isCap\n );\n vMiterLength = mix(vMiterLength, 1.0 - cornerPosition, isCap);\n\n offsetDirection = mix(\n offsetDirection,\n mix(flipIfTrue(isStartCap > 0.), positions.y, cornerPosition),\n isCap\n );\n\n vCornerOffset = offsetVec * offsetDirection * offsetScale;\n\n // Generate variables for dash calculation\n vDashArray = instanceDashArrays;\n vPathLength = L / width;\n float isEnd = positions.x;\n vec2 offsetFromStartOfPath = mix(vCornerOffset, vCornerOffset + deltaA / width, isEnd);\n vec2 dir = mix(dirB, dirA, isEnd);\n vPathPosition = dot(offsetFromStartOfPath, dir);\n\n return vec3(vCornerOffset * width, 0.0);\n}\n\nvoid main() {\n vColor = vec4(instanceColors.rgb, instanceColors.a * opacity) / 255.;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n\n float isEnd = positions.x;\n\n // Calculate current position\n vec3 currPosition = mix(instanceStartPositions, instanceEndPositions, isEnd);\n currPosition = project_position(currPosition);\n\n // Calculate current position 64bit\n\n vec2 instanceStartPositions64[2];\n instanceStartPositions64[0] = vec2(instanceStartPositions.x, instanceStartEndPositions64xyLow.x);\n instanceStartPositions64[1] = vec2(instanceStartPositions.y, instanceStartEndPositions64xyLow.y);\n\n vec2 instanceEndPositions64[2];\n instanceEndPositions64[0] = vec2(instanceEndPositions.x, instanceStartEndPositions64xyLow.z);\n instanceEndPositions64[1] = vec2(instanceEndPositions.y, instanceStartEndPositions64xyLow.w);\n\n vec2 tempCurrPosition64[2];\n vec2_mix_fp64(instanceStartPositions64, instanceEndPositions64, isEnd, tempCurrPosition64);\n\n vec4 currPosition64 = vec4(tempCurrPosition64[0].xy, tempCurrPosition64[1].xy);\n\n vec2 projected_curr_position[2];\n project_position_fp64(currPosition64, projected_curr_position);\n float projected_curr_position_z = project_scale(currPosition.z);\n\n // Calculate previous position\n\n vec3 prevPosition = mix(-instanceLeftDeltas, vec3(0.0), isEnd);\n\n // Calculate prev position 64bit\n\n vec2 tempPrevPosition64[2];\n tempPrevPosition64[0] = sum_fp64(vec2(prevPosition.x, 0.0), instanceStartPositions64[0]);\n tempPrevPosition64[1] = sum_fp64(vec2(prevPosition.y, 0.0), instanceStartPositions64[1]);\n\n vec4 prevPosition64 = vec4(tempPrevPosition64[0].xy, tempPrevPosition64[1].xy);\n\n vec2 projected_prev_position[2];\n project_position_fp64(prevPosition64, projected_prev_position);\n\n // Calculate next positions\n vec3 nextPosition = mix(vec3(0.0), instanceRightDeltas, isEnd);\n\n // Calculate next position 64bit\n\n vec2 tempNextPosition64[2];\n tempNextPosition64[0] = sum_fp64(vec2(nextPosition.x, 0.0), instanceEndPositions64[0]);\n tempNextPosition64[1] = sum_fp64(vec2(nextPosition.y, 0.0), instanceEndPositions64[1]);\n\n vec4 nextPosition64 = vec4(tempNextPosition64[0].xy, tempNextPosition64[1].xy);\n\n vec2 projected_next_position[2];\n project_position_fp64(nextPosition64, projected_next_position);\n\n vec3 pos = lineJoin(projected_prev_position, projected_curr_position, projected_next_position);\n vec2 vertex_pos_modelspace[4];\n\n vertex_pos_modelspace[0] = sum_fp64(vec2(pos.x, 0.0), projected_curr_position[0]);\n vertex_pos_modelspace[1] = sum_fp64(vec2(pos.y, 0.0), projected_curr_position[1]);\n vertex_pos_modelspace[2] = vec2(pos.z + projected_curr_position_z, 0.0);\n vertex_pos_modelspace[3] = vec2(1.0, 0.0);\n\n gl_Position = project_to_clipspace_fp64(vertex_pos_modelspace);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME path-layer-vertex-shader-64\n\nattribute vec3 positions;\n\nattribute vec3 instanceStartPositions;\nattribute vec3 instanceEndPositions;\nattribute vec3 instanceLeftDeltas;\nattribute vec3 instanceRightDeltas;\nattribute float instanceStrokeWidths;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\nattribute vec2 instanceDashArrays;\n\nuniform float widthScale;\nuniform float widthMinPixels;\nuniform float widthMaxPixels;\nuniform float jointType;\nuniform float miterLimit;\n\nuniform float opacity;\n\nvarying vec4 vColor;\nvarying vec2 vCornerOffset;\nvarying float vMiterLength;\nvarying vec2 vDashArray;\nvarying float vPathPosition;\nvarying float vPathLength;\n\nconst float EPSILON = 0.001;\nconst float PIXEL_EPSILON = 0.1;\n\nfloat flipIfTrue(bool flag) {\n return -(float(flag) * 2. - 1.);\n}\n\n// calculate line join positions\nvec3 lineJoin(\n vec3 prevPoint, vec3 currPoint, vec3 nextPoint,\n float relativePosition, bool isEnd, bool isJoint,\n float width\n) {\n vec2 deltaA = currPoint.xy - prevPoint.xy;\n vec2 deltaB = nextPoint.xy - currPoint.xy;\n\n float lenA = length(deltaA);\n float lenB = length(deltaB);\n\n // when two points are closer than PIXEL_EPSILON in pixels,\n // assume they are the same point to avoid precision issue\n lenA = lenA > PIXEL_EPSILON ? lenA : 0.0;\n lenB = lenB > PIXEL_EPSILON ? lenB : 0.0;\n\n vec2 dirA = lenA > 0. ? normalize(deltaA) : vec2(0.0, 0.0);\n vec2 dirB = lenB > 0. ? normalize(deltaB) : vec2(0.0, 0.0);\n\n vec2 perpA = vec2(-dirA.y, dirA.x);\n vec2 perpB = vec2(-dirB.y, dirB.x);\n\n // tangent of the corner\n vec2 tangent = vec2(dirA + dirB);\n tangent = length(tangent) > 0. ? normalize(tangent) : perpA;\n // direction of the corner\n vec2 miterVec = vec2(-tangent.y, tangent.x);\n // width offset from current position\n vec2 perp = isEnd ? perpA : perpB;\n float L = isEnd ? lenA : lenB;\n\n // cap super sharp angles\n float sinHalfA = abs(dot(miterVec, perp));\n float cosHalfA = abs(dot(dirA, miterVec));\n\n bool turnsRight = dirA.x * dirB.y > dirA.y * dirB.x;\n\n float offsetScale = 1.0 / max(sinHalfA, EPSILON);\n\n float cornerPosition = isJoint ?\n 0.0 :\n flipIfTrue(turnsRight == (relativePosition > 0.0));\n\n // do not bevel if line segment is too short\n cornerPosition *=\n float(cornerPosition <= 0.0 || sinHalfA < min(lenA, lenB) / width * cosHalfA);\n\n // trim if inside corner extends further than the line segment\n if (cornerPosition < 0.0) {\n offsetScale = min(offsetScale, L / width / max(cosHalfA, EPSILON));\n }\n\n vMiterLength = cornerPosition >= 0.0 ?\n mix(offsetScale, 0.0, cornerPosition) :\n offsetScale * cornerPosition;\n vMiterLength -= sinHalfA * jointType;\n\n float offsetDirection = mix(\n positions.y,\n mix(\n flipIfTrue(turnsRight),\n positions.y * flipIfTrue(turnsRight == (positions.x == 1.)),\n cornerPosition\n ),\n step(0.0, cornerPosition)\n );\n\n vec2 offsetVec = mix(miterVec, -tangent, step(0.5, cornerPosition));\n offsetScale = mix(offsetScale, 1.0 / max(cosHalfA, 0.001), step(0.5, cornerPosition));\n\n // special treatment for start cap and end cap\n // TODO - This has an issue. len is always positive because it is length.\n // Step returns zero if -lenA<0, so practically this is a comparison of\n // lenA with zero, with lots of problems because of the -lenA. Can we use EPSILON?\n bool isStartCap = step(0.0, -lenA) > 0.5;\n bool isEndCap = step(0.0, -lenB) > 0.5;\n bool isCap = isStartCap || isEndCap;\n\n // 0: center, 1: side\n cornerPosition = isCap ? (1.0 - positions.z) : 0.;\n\n // start of path: use next - curr\n if (isStartCap) {\n offsetVec = mix(dirB, perpB, cornerPosition);\n }\n\n // end of path: use curr - prev\n if (isEndCap) {\n offsetVec = mix(dirA, perpA, cornerPosition);\n }\n\n // extend out a triangle to envelope the round cap\n if (isCap) {\n offsetScale = mix(4.0 * jointType, 1.0, cornerPosition);\n vMiterLength = 1.0 - cornerPosition;\n offsetDirection = mix(flipIfTrue(isStartCap), positions.y, cornerPosition);\n }\n\n vCornerOffset = offsetVec * offsetDirection * offsetScale;\n\n // Generate variables for dash calculation\n vDashArray = instanceDashArrays;\n vPathLength = L / width;\n // vec2 offsetFromStartOfPath = isEnd ? vCornerOffset + deltaA / width : vCornerOffset;\n vec2 offsetFromStartOfPath = vCornerOffset;\n if (isEnd) {\n offsetFromStartOfPath += deltaA / width;\n }\n vec2 dir = isEnd ? dirA : dirB;\n vPathPosition = dot(offsetFromStartOfPath, dir);\n\n return currPoint + vec3(vCornerOffset * width, 0.0);\n}\n\n// calculate line join positions\n// extract params from attributes and uniforms\nvec3 lineJoin(vec3 prevPoint, vec3 currPoint, vec3 nextPoint) {\n\n // relative position to the corner:\n // -1: inside (smaller side of the angle)\n // 0: center\n // 1: outside (bigger side of the angle)\n\n float relativePosition = positions.y;\n bool isEnd = positions.x > EPSILON;\n bool isJoint = positions.z > EPSILON;\n\n float width = clamp(project_scale(instanceStrokeWidths * widthScale),\n widthMinPixels, widthMaxPixels) / 2.0;\n\n return lineJoin(\n prevPoint, currPoint, nextPoint,\n relativePosition, isEnd, isJoint,\n width\n );\n}\n\nvoid main() {\n vColor = vec4(instanceColors.rgb, instanceColors.a * opacity) / 255.;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n\n float isEnd = positions.x;\n\n vec3 prevPosition = mix(-instanceLeftDeltas, vec3(0.0), isEnd) + instanceStartPositions;\n prevPosition = project_position(prevPosition);\n\n vec3 currPosition = mix(instanceStartPositions, instanceEndPositions, isEnd);\n currPosition = project_position(currPosition);\n\n vec3 nextPosition = mix(vec3(0.0), instanceRightDeltas, isEnd) + instanceEndPositions;\n nextPosition = project_position(nextPosition);\n\n vec3 pos = lineJoin(prevPosition, currPosition, nextPosition);\n\n gl_Position = project_to_clipspace(vec4(pos, 1.0));\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME point-cloud-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nvarying vec4 vColor;\nvarying vec2 unitPosition;\n\nvoid main(void) {\n\n float distToCenter = length(unitPosition);\n\n if (distToCenter > 1.0) {\n discard;\n }\n\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME point-cloud-layer-vertex-shader-64\n\nattribute vec3 positions;\n\nattribute vec3 instancePositions;\nattribute vec2 instancePositions64xyLow;\nattribute vec3 instanceNormals;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\nuniform float opacity;\nuniform float radiusPixels;\n\nvarying vec4 vColor;\nvarying vec2 unitPosition;\n\nvoid main(void) {\n // position on the containing square in [-1, 1] space\n unitPosition = positions.xy;\n\n vec4 instancePositions64xy = vec4(\n instancePositions.x, instancePositions64xyLow.x,\n instancePositions.y, instancePositions64xyLow.y);\n\n vec2 projected_coord_xy[2];\n project_position_fp64(instancePositions64xy, projected_coord_xy);\n\n vec2 vertex_pos_modelspace[4];\n vertex_pos_modelspace[0] = projected_coord_xy[0];\n vertex_pos_modelspace[1] = projected_coord_xy[1];\n vertex_pos_modelspace[2] = vec2(project_scale(instancePositions.z), 0.0);\n vertex_pos_modelspace[3] = vec2(1.0, 0.0);\n\n gl_Position = project_to_clipspace_fp64(vertex_pos_modelspace);\n gl_Position += project_pixel_to_clipspace(positions.xy * radiusPixels);\n\n vec4 position_worldspace = vec4(\n projected_coord_xy[0].x, projected_coord_xy[1].x,\n project_scale(instancePositions.z), 1.0);\n\n // Apply lighting\n float lightWeight = getLightWeight(position_worldspace.xyz, // the w component is always 1.0\n instanceNormals);\n\n // Apply opacity to instance color, or return instance picking color\n vColor = vec4(lightWeight * instanceColors.rgb, instanceColors.a * opacity) / 255.;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME point-cloud-layer-vertex-shader\n\nattribute vec3 positions;\n\nattribute vec3 instancePositions;\nattribute vec3 instanceNormals;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\nuniform float opacity;\nuniform float radiusPixels;\n\nvarying vec4 vColor;\nvarying vec2 unitPosition;\n\nvoid main(void) {\n // position on the containing square in [-1, 1] space\n unitPosition = positions.xy;\n\n // Find the center of the point and add the current vertex\n vec4 position_worldspace = vec4(project_position(instancePositions), 1.0);\n gl_Position = project_to_clipspace(position_worldspace) ;\n gl_Position += project_pixel_to_clipspace(positions.xy * radiusPixels);\n\n // Apply lighting\n float lightWeight = getLightWeight(position_worldspace.xyz, // the w component is always 1.0\n instanceNormals);\n\n // Apply opacity to instance color, or return instance picking color\n vColor = vec4(lightWeight * instanceColors.rgb, instanceColors.a * opacity) / 255.;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),a=n(12),s=o(n(319)),u=o(n(318)),c=o(n(317));function o(e){return e&&e.__esModule?e:{default:e}}var d=i.experimental.fp64LowPart,l=i.experimental.enable64bitSupport,f=[0,0,0,255],h={radiusPixels:10,fp64:!1,getPosition:function(e){return e.position},getNormal:function(e){return e.normal},getColor:function(e){return e.color||f},lightSettings:{lightsPosition:[0,0,5e3,-1e3,1e3,8e3,5e3,-5e3,1e3],ambientRatio:.2,diffuseRatio:.6,specularRatio:.8,lightsStrength:[1,0,.8,0,.4,0],numberOfLights:3}},p=function(e){function o(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,i.Layer),r(o,[{key:"getShaders",value:function(e){var t=this.context.shaderCache;return l(this.props)?{vs:u.default,fs:c.default,modules:["project64","lighting","picking"],shaderCache:t}:{vs:s.default,fs:c.default,modules:["lighting","picking"],shaderCache:t}}},{key:"initializeState",value:function(){this.state.attributeManager.addInstanced({instancePositions:{size:3,transition:!0,accessor:"getPosition",update:this.calculateInstancePositions},instanceNormals:{size:3,transition:!0,accessor:"getNormal",defaultValue:1,update:this.calculateInstanceNormals},instanceColors:{size:4,type:a.GL.UNSIGNED_BYTE,transition:!0,accessor:"getColor",update:this.calculateInstanceColors}})}},{key:"updateAttribute",value:function(e){var t=e.props,n=e.oldProps;e.changeFlags;if(t.fp64!==n.fp64){var r=this.getAttributeManager();r.invalidateAll(),t.fp64&&t.coordinateSystem===i.COORDINATE_SYSTEM.LNGLAT?r.addInstanced({instancePositions64xyLow:{size:2,accessor:"getPosition",update:this.calculateInstancePositions64xyLow}}):r.remove(["instancePositions64xyLow"])}}},{key:"updateState",value:function(e){var t=e.props,n=e.oldProps,r=e.changeFlags;if(function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0}(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"updateState",this).call(this,{props:t,oldProps:n,changeFlags:r}),t.fp64!==n.fp64){var i=this.context.gl;this.setState({model:this._getModel(i)})}this.updateAttribute({props:t,oldProps:n,changeFlags:r})}},{key:"draw",value:function(e){var t=e.uniforms,n=this.props,r=n.radiusPixels,i=n.lightSettings;this.state.model.render(Object.assign({},t,{radiusPixels:r},i))}},{key:"_getModel",value:function(e){for(var t=[],n=0;n<3;n++){var r=n/3*Math.PI*2;t.push(2*Math.cos(r),2*Math.sin(r),0)}return new a.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:new a.Geometry({drawMode:a.GL.TRIANGLES,attributes:{positions:new Float32Array(t)}}),isInstanced:!0,shaderCache:this.context.shaderCache}))}},{key:"calculateInstancePositions",value:function(e){var t=this.props,n=t.data,r=t.getPosition,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=f[0],i[o++]=f[1],i[o++]=f[2]||0}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstancePositions64xyLow",value:function(e){var t=this.props,n=t.data,r=t.getPosition,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=d(f[0]),i[o++]=d(f[1])}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceNormals",value:function(e){var t=this.props,n=t.data,r=t.getNormal,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=f[0],i[o++]=f[1],i[o++]=f[2]}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}},{key:"calculateInstanceColors",value:function(e){var t=this.props,n=t.data,r=t.getColor,i=e.value,o=0,a=!0,s=!1,u=void 0;try{for(var c,l=n[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=r(c.value);i[o++]=f[0],i[o++]=f[1],i[o++]=f[2],i[o++]=isNaN(f[3])?255:f[3]}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}}}]),o}();(t.default=p).layerName="PointCloudLayer",p.defaultProps=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(13),x=o(n(177)),O=o(n(119)),a=function(e){{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}}(n(120));function o(e){return e&&e.__esModule?e:{default:e}}var s=i.experimental.get,u=[0,0,0,255],c=[0,0,0,255],l={stroked:!0,filled:!0,extruded:!1,elevationScale:1,wireframe:!1,lineWidthScale:1,lineWidthMinPixels:0,lineWidthMaxPixels:Number.MAX_SAFE_INTEGER,lineJointRounded:!1,lineMiterLimit:4,lineDashJustified:!1,fp64:!1,getPolygon:function(e){return s(e,"polygon")},getFillColor:function(e){return s(e,"fillColor")||c},getLineColor:function(e){return s(e,"lineColor")||u},getLineWidth:function(e){return s(e,"lineWidth")||1},getLineDashArray:null,getElevation:function(e){return s(e,"elevation")||1e3},lightSettings:{lightsPosition:[-122.45,37.75,8e3,-122,38,5e3],ambientRatio:.05,diffuseRatio:.6,specularRatio:.8,lightsStrength:[2,0,0,0],numberOfLights:2}},f=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.CompositeLayer),r(t,[{key:"initializeState",value:function(){this.state={paths:[]}}},{key:"updateState",value:function(e){var n=this,t=(e.oldProps,e.props,e.changeFlags);if(t.dataChanged||t.updateTriggersChanged&&(t.updateTriggersChanged.all||t.updateTriggersChanged.getPolygon)){var r=this.props,i=r.data,o=r.getPolygon;this.state.paths=[],i.forEach(function(t){a.normalize(o(t)).forEach(function(e){return n.state.paths.push({path:e,object:t})})})}}},{key:"getPickingInfo",value:function(e){var t=e.info;return Object.assign(t,{object:t.object&&t.object.object||t.object})}},{key:"renderLayers",value:function(){var e=this.props,t=e.data,n=e.stroked,r=e.filled,i=e.extruded,o=e.wireframe,a=e.elevationScale,s=this.props,u=s.lineWidthScale,c=s.lineWidthMinPixels,l=s.lineWidthMaxPixels,f=s.lineJointRounded,d=s.lineMiterLimit,h=s.lineDashJustified,p=s.fp64,v=this.props,g=v.getFillColor,y=v.getLineColor,_=v.getLineWidth,m=v.getLineDashArray,b=v.getElevation,E=v.getPolygon,w=v.updateTriggers,P=v.lightSettings,S=this.state.paths,A=t&&0<t.length,T=r&&A&&new x.default(this.getSubLayerProps({id:"fill",updateTriggers:{getElevation:w.getElevation,getColor:w.getFillColor}}),{data:t,extruded:i,elevationScale:a,fp64:p,wireframe:!1,getPolygon:E,getElevation:b,getColor:g,lightSettings:P});return[!i&&T,i&&o&&A&&new x.default(this.getSubLayerProps({id:"wireframe",updateTriggers:{getElevation:w.getElevation,getColor:w.getLineColor}}),{data:t,fp64:p,extruded:!0,elevationScale:a,wireframe:!0,getPolygon:E,getElevation:b,getColor:y}),!i&&n&&A&&new O.default(this.getSubLayerProps({id:"stroke",updateTriggers:{getWidth:w.getLineWidth,getColor:w.getLineColor,getDashArray:w.getLineDashArray}}),{data:S,fp64:p,widthScale:u,widthMinPixels:c,widthMaxPixels:l,rounded:f,miterLimit:d,dashJustified:h,getPath:function(e){return e.path},getColor:function(e){return y(e.object)},getWidth:function(e){return _(e.object)},getDashArray:m&&function(e){return m(e.object)}}),i&&T]}}]),t}();(t.default=f).layerName="PolygonLayer",f.defaultProps=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME scatterplot-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nvarying vec4 vColor;\nvarying vec2 unitPosition;\nvarying float innerUnitRadius;\n\nvoid main(void) {\n\n float distToCenter = length(unitPosition);\n\n if (distToCenter > 1.0 || distToCenter < innerUnitRadius) {\n discard;\n }\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME scatterplot-layer-vertex-shader-64\n\nattribute vec3 positions;\n\nattribute vec3 instancePositions;\nattribute vec2 instancePositions64xyLow;\nattribute float instanceRadius;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\n// Only one-dimensional arrays may be declared in GLSL ES 1.0. specs p.24\nuniform float opacity;\nuniform float radiusScale;\nuniform float radiusMinPixels;\nuniform float radiusMaxPixels;\nuniform float outline;\nuniform float strokeWidth;\n\nvarying vec4 vColor;\nvarying vec2 unitPosition;\nvarying float innerUnitRadius;\n\nvoid main(void) {\n // Multiply out radius and clamp to limits\n float outerRadiusPixels = clamp(\n project_scale(radiusScale * instanceRadius),\n radiusMinPixels, radiusMaxPixels\n );\n\n // outline is centered at the radius\n // outer radius needs to offset by half stroke width\n outerRadiusPixels += outline * strokeWidth / 2.0;\n\n // position on the containing square in [-1, 1] space\n unitPosition = positions.xy;\n // 0 - solid circle, 1 - stroke with lineWidth=0\n innerUnitRadius = outline * (1.0 - strokeWidth / outerRadiusPixels);\n\n vec4 instancePositions64xy = vec4(\n instancePositions.x, instancePositions64xyLow.x,\n instancePositions.y, instancePositions64xyLow.y);\n\n vec2 projected_coord_xy[2];\n project_position_fp64(instancePositions64xy, projected_coord_xy);\n\n vec2 vertex_pos_localspace[4];\n vec4_fp64(vec4(positions * outerRadiusPixels, 0.0), vertex_pos_localspace);\n\n vec2 vertex_pos_modelspace[4];\n vertex_pos_modelspace[0] = sum_fp64(vertex_pos_localspace[0], projected_coord_xy[0]);\n vertex_pos_modelspace[1] = sum_fp64(vertex_pos_localspace[1], projected_coord_xy[1]);\n vertex_pos_modelspace[2] = sum_fp64(vertex_pos_localspace[2],\n vec2(project_scale(instancePositions.z), 0.0));\n vertex_pos_modelspace[3] = vec2(1.0, 0.0);\n\n gl_Position = project_to_clipspace_fp64(vertex_pos_modelspace);\n\n vColor = vec4(instanceColors.rgb, instanceColors.a * opacity) / 255.;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME scatterplot-layer-vertex-shader\n\nattribute vec3 positions;\n\nattribute vec3 instancePositions;\nattribute float instanceRadius;\nattribute vec4 instanceColors;\nattribute vec3 instancePickingColors;\n\nuniform float opacity;\nuniform float radiusScale;\nuniform float radiusMinPixels;\nuniform float radiusMaxPixels;\nuniform float outline;\nuniform float strokeWidth;\n\nvarying vec4 vColor;\nvarying vec2 unitPosition;\nvarying float innerUnitRadius;\n\nvoid main(void) {\n // Multiply out radius and clamp to limits\n float outerRadiusPixels = clamp(\n project_scale(radiusScale * instanceRadius),\n radiusMinPixels, radiusMaxPixels\n );\n // outline is centered at the radius\n // outer radius needs to offset by half stroke width\n outerRadiusPixels += outline * strokeWidth / 2.0;\n\n // position on the containing square in [-1, 1] space\n unitPosition = positions.xy;\n // 0 - solid circle, 1 - stroke with lineWidth=0\n innerUnitRadius = outline * (1.0 - strokeWidth / outerRadiusPixels);\n\n // Find the center of the point and add the current vertex\n vec3 center = project_position(instancePositions);\n vec3 vertex = positions * outerRadiusPixels;\n gl_Position = project_to_clipspace(vec4(center + vertex, 1.0));\n\n // Apply opacity to instance color, or return instance picking color\n vColor = vec4(instanceColors.rgb, instanceColors.a * opacity) / 255.;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME screen-grid-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nvarying vec4 vColor;\n\nvoid main(void) {\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME screen-grid-layer-vertex-shader\n\nattribute vec3 vertices;\nattribute vec3 instancePositions;\nattribute float instanceCount;\nattribute vec3 instancePickingColors;\n\nuniform float maxCount;\nuniform float opacity;\nuniform vec4 minColor;\nuniform vec4 maxColor;\nuniform vec3 cellScale;\n\nvarying vec4 vColor;\n\nvoid main(void) {\n vec4 color = mix(minColor, maxColor, instanceCount / maxCount) / 255.;\n\n vColor = vec4(color.rgb, color.a * opacity);\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(instancePickingColors);\n\n gl_Position = vec4(instancePositions + vertices * cellScale, 1.);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),o=n(13),a=n(12),s=i(n(326)),u=i(n(325));function i(e){return e&&e.__esModule?e:{default:e}}var c=function(e){function i(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(i.__proto__||Object.getPrototypeOf(i)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(i,o.Layer),r(i,[{key:"getShaders",value:function(){return{vs:s.default,fs:u.default,modules:["picking"]}}},{key:"initializeState",value:function(){var e=this.getAttributeManager(),t=this.context.gl;e.addInstanced({instancePositions:{size:3,update:this.calculateInstancePositions},instanceCount:{size:1,accessor:["getPosition","getWeight"],update:this.calculateInstanceCount}}),this.setState({model:this._getModel(t)})}},{key:"shouldUpdateState",value:function(e){return e.changeFlags.somethingChanged}},{key:"updateState",value:function(e){var t=e.oldProps,n=e.props,r=e.changeFlags;(function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0})(i.prototype.__proto__||Object.getPrototypeOf(i.prototype),"updateState",this).call(this,{props:n,oldProps:t,changeFlags:r}),(n.cellSizePixels!==t.cellSizePixels||r.viewportChanged)&&this.updateCell()}},{key:"draw",value:function(e){var t=e.uniforms,n=this.props,r=n.minColor,i=n.maxColor,o=n.parameters,a=void 0===o?{}:o,s=this.state,u=s.model,c=s.cellScale,l=s.maxCount;t=Object.assign({},t,{minColor:r,maxColor:i,cellScale:c,maxCount:l}),u.draw({uniforms:t,parameters:Object.assign({depthTest:!1,depthMask:!1},a)})}},{key:"_getModel",value:function(e){return new a.Model(e,Object.assign({},this.getShaders(),{id:this.props.id,geometry:new a.Geometry({drawMode:a.GL.TRIANGLE_FAN,attributes:{vertices:new Float32Array([0,0,0,1,0,0,1,1,0,0,1,0])}}),isInstanced:!0,shaderCache:this.context.shaderCache}))}},{key:"updateCell",value:function(){var e=this.context.viewport,t=e.width,n=e.height,r=this.props.cellSizePixels,i=new Float32Array([(r-2)/t*2,-(r-2)/n*2,1]),o=Math.ceil(t/r),a=Math.ceil(n/r);this.setState({cellScale:i,numCol:o,numRow:a,numInstances:o*a}),this.getAttributeManager().invalidateAll()}},{key:"calculateInstancePositions",value:function(e,t){for(var n=t.numInstances,r=this.context.viewport,i=r.width,o=r.height,a=this.props.cellSizePixels,s=this.state.numCol,u=e.value,c=e.size,l=0;l<n;l++){var f=l%s,d=Math.floor(l/s);u[l*c+0]=f*a/i*2-1,u[l*c+1]=1-d*a/o*2,u[l*c+2]=0}}},{key:"calculateInstanceCount",value:function(e){var t=this.props,n=t.data,r=t.cellSizePixels,i=t.getPosition,o=t.getWeight,a=this.state,s=a.numCol,u=a.numRow,c=e.value,l=0;c.fill(0);var f=!0,d=!1,h=void 0;try{for(var p,v=n[Symbol.iterator]();!(f=(p=v.next()).done);f=!0){var g=p.value,y=this.project(i(g)),_=Math.floor(y[0]/r),m=Math.floor(y[1]/r);if(0<=_&&_<s&&0<=m&&m<u){var b=_+m*s;c[b]+=o(g),c[b]>l&&(l=c[b])}}}catch(e){d=!0,h=e}finally{try{!f&&v.return&&v.return()}finally{if(d)throw h}}this.setState({maxCount:l})}}]),i}();(t.default=c).layerName="ScreenGridLayer",c.defaultProps={cellSizePixels:100,minColor:[0,0,0,255],maxColor:[0,255,0,255],getPosition:function(e){return e.position},getWeight:function(e){return 1}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PolygonTesselatorExtruded=void 0;var r,i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),x=function(e){{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}}(n(120)),o=n(13),a=n(232),O=(r=a)&&r.__esModule?r:{default:r};var R=o.experimental.fp64LowPart,C=o.experimental.fillArray;function k(e,t){for(var n=t.length,r=e.length,i=0;i<n;i++)e[r++]=t[i];return e}function M(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:[];return 1<t?e.forEach(function(e){return M(e,t-1,n)}):k(n,e),n}var h=[0,0,0,255];t.PolygonTesselatorExtruded=function(){function T(e){var t=e.polygons,n=e.getHeight,r=void 0===n?function(e){return 1e3}:n,i=(e.getColor,e.wireframe),o=void 0!==i&&i,a=e.fp64,s=void 0!==a&&a;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,T),this.fp64=s;var u=t=t.map(function(e,t){var n=r(t)||0;return x.normalize(e).map(function(e){return e.map(function(e){return[e[0],e[1],n]})})});this.groupedVertices=t;var c=t.reduce(function(e,t){return e+x.getVertexCount(t)},0);this.pointCount=c,this.wireframe=o,this.attributes={};var l,f,d,h,p,v,g,y,_,m,b,E,w,P,S,A=(f=(l={groupedVertices:u,pointCount:c,wireframe:o}).groupedVertices,d=l.pointCount,h=l.wireframe,v=(p=void 0!==h&&h)?2:5,g=new Float32Array(3*d*v),y=0,f.forEach(function(e){for(var t=M(e,3),n=t.slice(0),r=t.length-1;0<r;)n[r]=0,r-=3;var i=t.length;p?(C({target:g,source:t,start:y}),C({target:g,source:n,start:y+i})):(C({target:g,source:t,start:y,count:3}),C({target:g,source:n,start:y+3*i,count:2})),y+=i*v}),g);Object.assign(this.attributes,{positions:function(e,t){var n=void 0;if(t){var r=e.length/3;n=new Float32Array(2*r);for(var i=0;i<r;i++)n[2*i+0]=R(e[3*i+0]),n[2*i+1]=R(e[3*i+1])}return{positions:e,positions64xyLow:n}}(A,this.fp64),indices:function(e){var t=e.groupedVertices,n=e.wireframe,r=void 0!==n&&n,i=r?2:5,s=[];t.reduce(function(e,t){return s.push(e),e+x.getVertexCount(t)*i},0);var o=t.map(function(e,t){return r?(n=e,i=s[t],o=x.getVertexCount(n),a=[],n.forEach(function(e){a.push(i);for(var t=e.length,n=1;n<t-1;n++)a.push(n+i,n+i);a.push(i);for(var r=0;r<t-1;r++)a.push(r+i,r+o+i);i+=t}),a):function(e,o){var a=x.getVertexCount(e),t=null,n=e.length-1;if(n){t=[];for(var r=0,i=0;i<n;i++)r+=e[i].length,t[i]=r}var s=(0,O.default)(M(e,3),t,3).map(function(e){return e+o});return e.forEach(function(e){for(var t,n,r=e.length,i=0;i<r-1;i++)t=o+i,n=a,s.push(t+n,t+3*n,t+2*n+1,t+2*n+1,t+3*n,t+4*n+1);o+=r}),s}(e,s[t]);var n,i,o,a});return new Uint32Array(M(o,2))}({groupedVertices:u,wireframe:o}),normals:function(e){var t=e.groupedVertices,n=e.pointCount,r=e.wireframe,o=[0,0,1],i=r?2:5,a=new Float32Array(3*n*i),s=0;if(r)return C({target:a,source:o,count:n*i});return t.map(function(e,t){var n=x.getVertexCount(e);C({target:a,source:o,start:s,count:n}),s+=3*n;var r=[],i=[];e.forEach(function(e){var t=function(e){var t,n,r=[],i=null,o=!0,a=!1,s=void 0;try{for(var u,c=e[Symbol.iterator]();!(o=(u=c.next()).done);o=!0){var l=u.value;if(i){var f=(n=l,[(t=i)[1]-n[1],n[0]-t[0],0]);k(r,f)}i=l}}catch(e){a=!0,s=e}finally{try{!o&&c.return&&c.return()}finally{if(a)throw s}}return r}(e),n=t.slice(0,3);k(r,t),k(r,n),k(i,n),k(i,t)}),C({target:a,start:s,count:2,source:r.concat(i)}),s+=3*n*4}),a}({groupedVertices:u,pointCount:c,wireframe:o}),pickingColors:(_={groupedVertices:u,pointCount:c,wireframe:o},m=_.groupedVertices,b=_.pointCount,E=_.wireframe,w=void 0!==E&&E?2:5,P=new Uint8ClampedArray(3*b*w),S=0,m.forEach(function(e,t){var n,r=x.getVertexCount(e),i=[(n=t)+1&255,n+1>>8&255,n+1>>8>>8&255];C({target:P,source:i,start:S,count:r*w}),S+=i.length*r*w}),P)})}return i(T,[{key:"indices",value:function(){return this.attributes.indices}},{key:"positions",value:function(){return this.attributes.positions}},{key:"normals",value:function(){return this.attributes.normals}},{key:"colors",value:function(){var e,t,n,i,r,o,a,s,u=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).getColor,c=void 0===u?function(e){return h}:u,l=this.groupedVertices,f=this.pointCount,d=this.wireframe;return t=(e={groupedVertices:l,pointCount:f,wireframe:d,getColor:c}).groupedVertices,n=e.pointCount,i=e.getColor,r=e.wireframe,o=void 0!==r&&r?2:5,a=new Uint8ClampedArray(4*n*o),s=0,t.forEach(function(e,t){var n=i(t);n[3]=Number.isFinite(n[3])?n[3]:255;var r=x.getVertexCount(e);C({target:a,source:n,start:s,count:r*o}),s+=n.length*r*o}),a}},{key:"pickingColors",value:function(){return this.attributes.pickingColors}}]),T}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PolygonTesselator=void 0;var r,o=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),p=function(e){{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}}(n(120)),i=n(232),v=(r=i)&&r.__esModule?r:{default:r},a=n(13);var g=a.experimental.fp64LowPart,y=a.experimental.flattenVertices,l=a.experimental.fillArray;var f=[0,0,0,255];t.PolygonTesselator=function(){function i(e){var t=e.polygons,n=e.fp64,r=void 0!==n&&n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),this.polygons=t.map(function(e){return p.normalize(e)}),this.pointCount=this.polygons.reduce(function(e,t){return e+p.getVertexCount(t)},0),this.fp64=r}return o(i,[{key:"indices",value:function(){return function(e){var t=e.polygons,n=e.IndexType,r=void 0===n?Uint32Array:n,i=3*(u=t,u.reduce(function(e,t){return e+p.getTriangleCount(t)},0)),f=(o=t,a=new Array(o.length+1),s=a[0]=0,o.forEach(function(e,t){s+=p.getVertexCount(e),a[t+1]=s}),a);var o,a,s;var u;if(r===Uint16Array&&65535<i)throw new Error("Vertex count exceeds browser's limit");var d=new r(i),h=0;return t.forEach(function(e,t){var n,r,i,o=!0,a=!1,s=void 0;try{for(var u,c=(n=e,r=void 0,i=void 0,r=function(e){var t=null;if(1<e.length){var n=0;t=[],e.forEach(function(e){n+=e.length,t.push(n)}),t.pop()}return t}(n),i=y(n),(0,v.default)(i,r,3))[Symbol.iterator]();!(o=(u=c.next()).done);o=!0){var l=u.value;d[h++]=l+f[t]}}catch(e){a=!0,s=e}finally{try{!o&&c.return&&c.return()}finally{if(a)throw s}}}),d}({polygons:this.polygons,indexCount:this.indexCount})}},{key:"positions",value:function(){return function(e){var t=e.polygons,n=e.pointCount,i=e.fp64,o=new Float32Array(3*n),a=void 0;i&&(a=new Float32Array(2*n));var s=0,u=0,r=!0,c=!1,l=void 0;try{for(var f,d=t[Symbol.iterator]();!(r=(f=d.next()).done);r=!0){var h=f.value;p.forEachVertex(h,function(e){var t=e[0],n=e[1],r=e[2]||0;o[s++]=t,o[s++]=n,o[s++]=r,i&&(a[u++]=g(t),a[u++]=g(n))})}}catch(e){c=!0,l=e}finally{try{!r&&d.return&&d.return()}finally{if(c)throw l}}return{positions:o,positions64xyLow:a}}({polygons:this.polygons,pointCount:this.pointCount,fp64:this.fp64})}},{key:"normals",value:function(){return function(e){e.polygons;var t=e.pointCount;return new Float32Array(3*t)}({polygons:this.polygons,pointCount:this.pointCount})}},{key:"colors",value:function(){var e,t,n,i,o,a,r=(0<arguments.length&&void 0!==arguments[0]?arguments[0]:{}).getColor,s=void 0===r?function(e){return f}:r,u=this.polygons,c=this.pointCount;return t=(e={polygons:u,pointCount:c,getColor:s}).polygons,n=e.pointCount,i=e.getColor,o=new Uint8ClampedArray(4*n),a=0,t.forEach(function(e,t){var n=i(t);n[3]=Number.isFinite(n[3])?n[3]:255;var r=p.getVertexCount(e);l({target:o,source:n,start:a,count:r}),a+=n.length*r}),o}},{key:"pickingColors",value:function(){var e,t,n,o,a,r=this.polygons,i=this.pointCount;return t=(e={polygons:r,pointCount:i}).polygons,n=e.pointCount,o=new Uint8ClampedArray(3*n),a=0,t.forEach(function(e,t){var n,r=[((n=t)+1)%256,Math.floor((n+1)/256)%256,Math.floor((n+1)/256/256)%256],i=p.getVertexCount(e);l({target:o,source:r,start:a,count:i}),a+=r.length*i}),o}}]),i}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME solid-polygon-layer-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nvarying vec4 vColor;\n\nvoid main(void) {\n gl_FragColor = vColor;\n\n // use highlight color if this fragment belongs to the selected object.\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n\n // use picking color if rendering to picking FBO.\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME solid-polygon-layer-vertex-shader-64\n\nattribute vec3 positions;\nattribute vec2 positions64xyLow;\nattribute vec3 normals;\nattribute vec4 colors;\nattribute vec3 pickingColors;\n\nuniform float extruded;\nuniform float elevationScale;\nuniform float opacity;\n\nvarying vec4 vColor;\n\nvoid main(void) {\n vec4 positions64xy = vec4(positions.x, positions64xyLow.x, positions.y, positions64xyLow.y);\n\n vec2 projected_coord_xy[2];\n project_position_fp64(positions64xy, projected_coord_xy);\n\n vec2 vertex_pos_modelspace[4];\n vertex_pos_modelspace[0] = projected_coord_xy[0];\n vertex_pos_modelspace[1] = projected_coord_xy[1];\n vertex_pos_modelspace[2] = vec2(project_scale(positions.z * elevationScale), 0.0);\n vertex_pos_modelspace[3] = vec2(1.0, 0.0);\n\n gl_Position = project_to_clipspace_fp64(vertex_pos_modelspace);\n\n vec4 position_worldspace = vec4(\n vertex_pos_modelspace[0].x, vertex_pos_modelspace[1].x,\n vertex_pos_modelspace[2].x, vertex_pos_modelspace[3].x);\n\n float lightWeight = 1.0;\n\n if (extruded > 0.5) {\n lightWeight = getLightWeight(\n position_worldspace.xyz, // the w component is always 1.0\n project_normal(normals)\n );\n }\n\n vec3 lightWeightedColor = lightWeight * colors.rgb;\n vColor = vec4(lightWeightedColor, colors.a * opacity) / 255.0;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(pickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME solid-polygon-layer-vertex-shader\n\nattribute vec3 positions;\nattribute vec3 normals;\nattribute vec4 colors;\nattribute vec3 pickingColors;\n\nuniform float extruded;\nuniform float elevationScale;\nuniform float opacity;\n\nvarying vec4 vColor;\n\nvoid main(void) {\n \n vec4 position_worldspace = vec4(project_position(\n vec3(positions.x, positions.y, positions.z * elevationScale)),\n 1.0\n );\n gl_Position = project_to_clipspace(position_worldspace);\n\n float lightWeight = 1.0;\n \n if (extruded > 0.5) {\n // Here, the input parameters should be\n // position_worldspace.xyz / position_worldspace.w.\n // However, this calculation generates all zeros on\n // MacBook Pro with Intel Iris Pro GPUs for unclear reasons.\n // (see https://github.com/uber/deck.gl/issues/559)\n // Since the w component is always 1.0 in our shaders,\n // we decided to just provide xyz component of position_worldspace\n // to the getLightWeight() function\n lightWeight = getLightWeight(\n position_worldspace.xyz,\n project_normal(normals)\n );\n }\n\n vec3 lightWeightedColor = lightWeight * colors.rgb;\n vColor = vec4(lightWeightedColor, colors.a * opacity) / 255.0;\n\n // Set color to be rendered to picking fbo (also used to check for selection highlight).\n picking_setPickingColor(pickingColors);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var l=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=a(n(180)),o=n(16),f=a(n(1));function a(e){return e&&e.__esModule?e:{default:e}}function d(e,t){return Number.isFinite(e)?e:t}var s=function(e){function g(e){var t=e.width,n=e.height,r=e.position,i=e.bearing,o=e.pitch,a=e.longitude,s=e.latitude,u=e.zoom,c=(e.syncBearing,e.bounds,e.startPanEventPosition),l=e.startPanPosition,f=e.startRotateCenter,d=e.startRotateViewport,h=e.startZoomPos,p=e.startZoom;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,g);var v=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(g.__proto__||Object.getPrototypeOf(g)).call(this,{width:t,height:n,position:r,bearing:i,pitch:o,longitude:a,latitude:s,zoom:u}));return v._interactiveState={startPanEventPosition:c,startPanPosition:l,startRotateCenter:f,startRotateViewport:d,startZoomPos:h,startZoom:p},v}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(g,i.default),r(g,[{key:"getInteractiveState",value:function(){return this._interactiveState}},{key:"panStart",value:function(e){var t=e.pos,n=this._viewportProps,r=n.translationX,i=n.translationY;return this._getUpdatedState({startPanPosition:[r,i],startPanEventPosition:t})}},{key:"pan",value:function(e){var t=e.pos,n=e.startPos,r=this._interactiveState.startPanEventPosition||n;(0,f.default)(r,"`startPanEventPosition` props is required");var i=this._interactiveState.startPanPosition||[],o=l(i,2),a=o[0],s=o[1];a=d(a,this._viewportProps.translationX),s=d(s,this._viewportProps.translationY);var u=t[0]-r[0],c=t[1]-r[1];return this._getUpdatedState({translationX:a+u,translationY:s-c})}},{key:"panEnd",value:function(){return this._getUpdatedState({startPanPosition:null,startPanPos:null})}},{key:"rotateStart",value:function(e){e.pos;return this._getUpdatedState({startRotateCenter:this._viewportProps.position,startRotateViewport:this._viewportProps})}},{key:"rotate",value:function(e){var t=e.deltaScaleX,n=e.deltaScaleY,r=this._viewportProps,i=r.bearing,o=r.pitch;return this._getUpdatedState({bearing:i+10*t,pitch:o-10*n})}},{key:"rotateEnd",value:function(){return this._getUpdatedState({startRotateCenter:null,startRotateViewport:null})}},{key:"zoomStart",value:function(e){var t=e.pos;return this._getUpdatedState({startZoomPos:t,startZoom:this._viewportProps.zoom})}},{key:"zoom",value:function(e){var t,n,r,i=e.pos,o=e.startPos,a=e.scale,s=this._viewportProps,u=s.zoom,c=s.minZoom,l=s.maxZoom,f=s.width,d=s.height,h=(s.translationX,s.translationY,this._interactiveState.startZoomPos||o||i),p=(r=l,(t=u*a)<(n=c)?n:r<t?r:t);i[0],h[0],i[1],h[1],h[0],h[1];return p/u<1?this.moveBackward():this.moveForward()}},{key:"zoomEnd",value:function(){return this._getUpdatedState({startZoomPos:null,startZoom:null})}},{key:"moveLeft",value:function(){var e=this._viewportProps.bearing-2;return this._getUpdatedState({bearing:e})}},{key:"moveRight",value:function(){var e=this._viewportProps.bearing+2;return this._getUpdatedState({bearing:e})}},{key:"moveForward",value:function(){var e=this._viewportProps.position,t=this.getDirection(),n=new o.Vector3(t).normalize().scale(1);return this._getUpdatedState({position:new o.Vector3(e).add(n)})}},{key:"moveBackward",value:function(){var e=this._viewportProps.position,t=this.getDirection(),n=new o.Vector3(t).normalize().scale(-1);return this._getUpdatedState({position:new o.Vector3(e).add(n)})}},{key:"moveUp",value:function(){var e=this._viewportProps.position;return this._getUpdatedState({position:new o.Vector3(e).add([0,0,1])})}},{key:"moveDown",value:function(){var e=this._viewportProps.position,t=1<=e[2]?[0,0,-1]:[0,0,0];return this._getUpdatedState({position:new o.Vector3(e).add(t)})}},{key:"zoomIn",value:function(){return this._getUpdatedState({zoom:this._viewportProps.zoom+.2})}},{key:"zoomOut",value:function(){return this._getUpdatedState({zoom:this._viewportProps.zoom-.2})}},{key:"_getUpdatedState",value:function(e){return new g(Object.assign({},this._viewportProps,this._interactiveState,e))}}]),g}();t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="float scale(float position) {\n return project_scale(position);\n}\n\nvec2 scale(vec2 position) {\n return project_scale(position);\n}\n\nvec3 scale(vec3 position) {\n return project_scale(position);\n}\n\nvec4 scale(vec4 position) {\n return project_scale(position);\n}\n\nvec2 preproject(vec2 position) {\n return project_position(position);\n}\n\nvec3 preproject(vec3 position) {\n return project_position(position);\n}\n\nvec4 preproject(vec4 position) {\n return project_position(position);\n}\n\nvec4 project(vec4 position) {\n return project_to_clipspace(position);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),l=n(12),o=r(n(336)),a=r(n(17)),s=r(n(1));function r(e){return e&&e.__esModule?e:{default:e}}var f=1,d=2,u=3,c=function(){},h=function(){function r(e,t){var n=t.id;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),this.id=n,this.gl=e,this.isSupported=l.TransformFeedback.isSupported(e),this.attributeTransitions={},this.needsRedraw=!1,this.model=null,this.isSupported?this.transformFeedback=new l.TransformFeedback(e):a.default.warn(0,"WebGL2 not supported by this browser. Transition animation is disabled.")}return i(r,[{key:"update",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};if(this.opts=t,this.isSupported){var n=!1,r=this.attributeTransitions,i={};for(var o in e){var a=this._updateAttribute(o,e[o]);a&&(r[o]||(r[o]=a,n=!0),i[o]=a)}for(var s in r){var u=e[s];u&&u.transition||(delete r[s],n=!0)}n?this._createModel():this.model&&this.model.setTransitions(i)}}},{key:"hasAttribute",value:function(e){return e in this.attributeTransitions}},{key:"getAttributes",value:function(){var e={};for(var t in this.attributeTransitions){var n=this.attributeTransitions[t];n.buffer&&(e[t]=n.buffer)}return e}},{key:"setCurrentTime",value:function(e){if(!this.model)return!1;var t={},n={},r=this.needsRedraw;for(var i in this.needsRedraw=!1,this.attributeTransitions){var o=this.attributeTransitions[i];n[o.bufferIndex]=o.buffer;var a=1;o.state===f&&(o.startTime=e,o.state=d,o.onStart(o)),o.state===d&&(1<=(a=(e-o.startTime)/o.duration)&&(a=1,o.state=u,o.onEnd(o)),r=!0),t[o.name+"Time"]=o.easing(a)}return r&&this._runTransformFeedback({uniforms:t,buffers:n}),r}},{key:"_updateAttribute",value:function(e,t){var n=this._getTransitionSettings(t);if(n){var r=this.attributeTransitions[e];if(r?t.changed:(r={name:e,attribute:t},!0))return this._triggerTransition(r,n),r}return null}},{key:"_runTransformFeedback",value:function(e){var t,n,r,i=e.uniforms,o=e.buffers,a=this.model,s=this.transformFeedback;s.bindBuffers(o,{}),a.draw({uniforms:i,transformFeedback:s,parameters:(t={},n=l.GL.RASTERIZER_DISCARD,r=!0,n in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t)})}},{key:"_createModel",value:function(){this.model&&this.model.destroy(),this.model=new o.default(this.gl,{id:this.id,transitions:this.attributeTransitions})}},{key:"_getCurrentAttributeState",value:function(e){var t=e.attribute,n=e.buffer,r=t.value,i=t.type,o=t.size;if(n){var a=new Float32Array(r);return n.getData({dstData:a}),r instanceof Float32Array||(a=new r.constructor(a)),{size:o,type:i,value:a}}return{size:o,type:i,value:r}}},{key:"_getTransitionSettings",value:function(e){var t=this.opts,n=e.transition,r=e.accessor;return n?Array.isArray(r)?r.map(function(e){return t[e]}).find(Boolean):t[r]:null}},{key:"_normalizeTransitionSettings",value:function(e){return Number.isFinite(e)&&(e={duration:e}),(0,s.default)(e&&0<e.duration),{duration:e.duration,easing:e.easing||function(e){return e},onStart:e.onStart||c,onEnd:e.onEnd||c,onInterrupt:e.onInterrupt||c}}},{key:"_triggerTransition",value:function(e,t){this.needsRedraw=!0;var n=e.attribute,r=e.buffer,i=n.value,o=n.size,a=this._normalizeTransitionSettings(t),s=!r||e.bufferSize<i.length,u=this._getCurrentAttributeState(e),c=new l.Buffer(this.gl,{size:o,data:i});s&&(r&&r.delete(),e.buffer=new l.Buffer(this.gl,{size:o,instanced:n.instanced,data:new Float32Array(i.length),usage:l.GL.DYNAMIC_COPY}),e.bufferSize=i.length),Object.assign(e,a),e.fromState=u,e.toState=c,e.state===d&&e.onInterrupt(e),e.state=f}}]),r}();t.default=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),a=n(12);function s(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var c={1:"float",2:"vec2",3:"vec3",4:"vec4"};var i=function(e){function o(e,t){var n=t.id,r=t.transitions;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o);var i=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,e,Object.assign({id:n,geometry:new a.Geometry({id:n,drawMode:a.GL.POINTS}),vertexCount:0,isIndexed:!0},function(e){var t=[],n=[],r=[],i=[],o=[];for(var a in e){var s=e[a],u=c[s.attribute.size];u&&(s.bufferIndex=t.length,t.push(a),n.push("attribute "+u+" "+a+"From;"),n.push("attribute "+u+" "+a+"To;"),r.push("uniform float "+a+"Time;"),i.push("varying "+u+" "+a+";"),o.push(a+" = mix("+a+"From, "+a+"To,\n "+a+"Time);"))}return{vs:"\n#define SHADER_NAME feedback-vertex-shader\n"+n.join("\n")+"\n"+r.join("\n")+"\n"+i.join("\n")+"\n\nvoid main(void) {\n "+o.join("\n")+"\n gl_Position = vec4(0.0);\n}\n",fs:"#define SHADER_NAME feedback-fragment-shader\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\n"+i.join("\n")+"\n\nvoid main(void) {\n gl_FragColor = vec4(0.0);\n}\n",varyings:t}}(r))));return i.setTransitions(r),i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(o,a.Model),r(o,[{key:"setTransitions",value:function(e){for(var t in e){var n,r=e[t],i=r.fromState,o=r.toState,a=r.attribute;this.setAttributes((s(n={},t+"From",i),s(n,t+"To",o),n)),this.setVertexCount(a.value.length/a.size)}}}]),o}();t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=o(n(123)),a=o(n(17)),s=n(126);function o(e){return e&&e.__esModule?e:{default:e}}var u=function(e){function t(e){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),r(t,[{key:"getSubLayers",value:function(){return this.internalState.subLayers||[]}},{key:"initializeState",value:function(){}},{key:"getPickingInfo",value:function(e){return e.info}},{key:"renderLayers",value:function(){return null}},{key:"getSubLayerProps",value:function(e){var t=this.props,n={opacity:t.opacity,pickable:t.pickable,visible:t.visible,parameters:t.parameters,getPolygonOffset:t.getPolygonOffset,highlightedObjectIndex:t.highlightedObjectIndex,autoHighlight:t.autoHighlight,highlightColor:t.highlightColor,coordinateSystem:t.coordinateSystem,coordinateOrigin:t.coordinateOrigin,modelMatrix:t.modelMatrix};return e&&Object.assign(n,e,{id:this.props.id+"-"+e.id,updateTriggers:Object.assign({all:this.props.updateTriggers.all},e.updateTriggers)}),n}},{key:"_renderLayers",value:function(){var e=this.internalState.subLayers;e&&!this.needsUpdate()?a.default.log(3,"Composite layer reused subLayers "+this,this.internalState.subLayers):(e=this.renderLayers(),e=(0,s.flatten)(e,{filter:Boolean}),this.internalState.subLayers=e,a.default.log(2,"Composite layer rendered new subLayers "+this,e));var t=!0,n=!1,r=void 0;try{for(var i,o=e[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){i.value.parentLayer=this}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}}},{key:"isComposite",get:function(){return!0}}]),t}();(t.default=u).layerName="CompositeLayer"},function(e,t,n){"use strict";var r,i=n(350),o=n(17),a=(r=o)&&r.__esModule?r:{default:r};var s="5.1.3";if(i.global.deck&&i.global.deck.VERSION!==s)throw new Error("deck.gl - multiple versions detected: "+i.global.deck.VERSION+" vs "+s);i.global.deck||(console.log("deck.gl 5.1.3 - set deck.log.priority=1 (or higher) to trace attribute updates"),i.global.deck=i.global.deck||{VERSION:s,version:s,log:a.default}),console.table||(console.table=function(){}),n(190)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pickObject=function(e,t){var n=t.layers,r=t.viewports,i=t.x,o=t.y,a=t.radius,s=t.layerFilter,u=t.mode,c=t.onViewportActive,l=t.pickingFBO,f=t.lastPickedInfo,d=t.useDevicePixels,h=(0,E.getPixelRatio)({useDevicePixels:d}),p=Math.round(i*h),v=Math.round(e.canvas.height-o*h),g=Math.round(a*h),y=function(e){var t=e.deviceX,n=e.deviceY,r=e.deviceRadius,i=e.deviceWidth,o=e.deviceHeight;if(!(0<=t&&0<=n&&t<i&&n<o))return null;var a=Math.max(0,t-r),s=Math.max(0,n-r),u=Math.min(i,t+r)-a+1,c=Math.min(o,n+r)-s+1;return{x:a,y:s,width:u,height:c}}({deviceX:p,deviceY:v,deviceRadius:g,deviceWidth:l.width,deviceHeight:l.height}),_=y&&w(e,{layers:n,viewports:r,onViewportActive:c,useDevicePixels:d,pickingFBO:l,deviceRect:y,layerFilter:s,redrawReason:u});return function(e){var t=e.pickInfo,n=e.lastPickedInfo,u=e.mode,r=e.layers,i=e.viewports,o=e.x,a=e.y,s=e.deviceX,c=e.deviceY,l=e.pixelRatio,f=t.pickedColor,d=t.pickedLayer,h=t.pickedObjectIndex,p=d?[d]:[];if("hover"===u){var v=n.index,g=n.layerId,y=d&&d.props.id;if(y!==g||h!==v){if(y!==g){var _=r.find(function(e){return e.props.id===g});_&&p.unshift(_)}n.layerId=y,n.index=h}}var m=(w={viewports:i},w.viewports[0]),b={color:null,layer:null,index:-1,picked:!1,x:o,y:a,pixel:[o,a],lngLat:m.unproject([o,a]),devicePixel:[s,c],pixelRatio:l},E=new Map;var w;return p.forEach(function(e){var t=Object.assign({},b);e===d&&(t.color=f,t.index=h,t.picked=!0),(t=O({layer:e,info:t,mode:u}))&&E.set(t.layer.id,t);var n={pickingSelectedColor:e.props.autoHighlight&&d===e?f:null},r=!0,i=!1,o=void 0;try{for(var a,s=e.getModels()[Symbol.iterator]();!(r=(a=s.next()).done);r=!0)a.value.updateModuleSettings(n)}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}}),P=E,S=u,A=[],P.forEach(function(e){var t=!1;switch(S){case"click":t=e.layer.props.onClick(e);break;case"hover":t=e.layer.props.onHover(e);break;case"query":break;default:throw new Error("unknown pick type")}t||A.push(e)}),A;var P,S,A}({pickInfo:_&&m(e,{pickedColors:_,layers:n,deviceX:p,deviceY:v,deviceRadius:g,deviceRect:y})||x,lastPickedInfo:f,mode:u,layers:n,viewports:r,x:i,y:o,deviceX:p,deviceY:v,pixelRatio:h})},t.pickVisibleObjects=function(e,t){var n=t.layers,r=t.viewports,i=t.x,o=t.y,a=t.width,s=t.height,u=t.mode,c=t.layerFilter,l=t.onViewportActive,f=t.pickingFBO,d=t.useDevicePixels,h=(0,E.getPixelRatio)({useDevicePixels:d}),p=Math.round(i*h),v=Math.round(e.canvas.height-o*h),g=Math.round((i+a)*h),y=Math.round(e.canvas.height-(o+s)*h),_=w(e,{layers:n,viewports:r,onViewportActive:l,pickingFBO:f,useDevicePixels:d,deviceRect:{x:p,y:y,width:g-p,height:v-y},layerFilter:c,redrawReason:u}),m=function(e,t){var n=t.pickedColors,r=t.layers,i=new Map;if(n)for(var o=0;o<n.length;o+=4){var a=n[o+3]-1;if(0<=a){var s=n.slice(o,o+4),u=s.join(",");if(!i.has(u)){var c=r[a];c?i.set(u,{pickedColor:s,pickedLayer:c,pickedObjectIndex:c.decodePickingColor(s)}):A.default.error("Picked non-existent layer. Is picking buffer corrupt?")}}}return Array.from(i.values())}(0,{pickedColors:_,layers:n}),b=new Map;return m.forEach(function(e){var t={color:e.pickedColor,layer:null,index:e.pickedObjectIndex,picked:!0,x:i,y:o,width:a,height:s,pixelRatio:h};t=O({layer:e.pickedLayer,info:t,mode:u}),b.has(t.object)||b.set(t.object,t)}),Array.from(b.values())},t.getClosestFromPickingBuffer=m;var E=n(183),A=r(n(17)),T=r(n(1));function r(e){return e&&e.__esModule?e:{default:e}}var x={pickedColor:null,pickedLayer:null,pickedObjectIndex:-1};function w(e,t){var n=t.layers,r=t.viewports,i=t.onViewportActive,o=t.useDevicePixels,a=t.pickingFBO,s=t.deviceRect,u=t.layerFilter,c=t.redrawReason;if((0,T.default)(s),(0,T.default)(Number.isFinite(s.width)&&0<s.width,"`width` must be > 0"),(0,T.default)(Number.isFinite(s.height)&&0<s.height,"`height` must be > 0"),n.filter(function(e){return e.isPickable()}).length<1)return null;(0,E.drawPickingBuffer)(e,{layers:n,viewports:r,onViewportActive:i,useDevicePixels:o,pickingFBO:a,deviceRect:s,layerFilter:u,redrawReason:c});var l=s.x,f=s.y,d=s.width,h=s.height,p=new Uint8Array(d*h*4);return a.readPixels({x:l,y:f,width:d,height:h,pixelArray:p}),p}function m(e,t){var n=t.pickedColors,r=t.layers,i=t.deviceX,o=t.deviceY,a=t.deviceRadius,s=t.deviceRect;(0,T.default)(n);for(var u=s.x,c=s.y,l=s.width,f=s.height,d=a*a,h=-1,p=0,v=0;v<f;v++){var g=v+c-o,y=g*g;if(d<y)p+=4*l;else for(var _=0;_<l;_++){if(0<=n[p+3]-1){var m=_+u-i,b=m*m+y;b<=d&&(d=b,h=p)}p+=4}}if(0<=h){var E=n[h+3]-1,w=n.slice(h,h+4),P=r[E];if(P){var S=P.decodePickingColor(w);return{pickedColor:w,pickedLayer:P,pickedObjectIndex:S}}A.default.error("Picked non-existent layer. Is picking buffer corrupt?")}return x}function O(e){for(var t=e.layer,n=e.info,r=e.mode;t&&n;){var i=n.layer||t;n.layer=t,n=t.pickLayer({info:n,mode:r,sourceLayer:i}),t=t.parentLayer}return n}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EMPTY_ARRAY=void 0,t.createProps=function(){0<arguments.length&&void 0!==arguments[0]&&arguments[0];for(var e=function e(t){var n=u(t,"_props");if(n)return n;var r=t.prototype;if(!r)return{defaultProps:{}};var i=Object.getPrototypeOf(t);var o=r&&e(i)||null;var a=u(t,"defaultProps")||{};var s=Object.create(null);Object.assign(s,o&&o.defaultProps,a);c(s,t);t._props={defaultProps:s};return t._props}(this.constructor).defaultProps,t=Object.create(e,{_layer:{enumerable:!1,value:this},_asyncProps:{enumerable:!1,value:{}}}),n=0;n<arguments.length;++n)Object.assign(t,arguments[n]);return t.data=t.data||s,(0,i.applyPropOverrides)(t),Object.freeze(t),t};var r,i=n(124),o=n(17),a=(r=o)&&r.__esModule?r:{default:r};var s=t.EMPTY_ARRAY=Object.freeze([]);function u(e,t){return Object.prototype.hasOwnProperty.call(e,t)&&e[t]}function c(e,t){var n,r,i={};delete e.id,Object.assign(i,{id:{configurable:!1,writable:!0,value:(n=t,r=u(n,"layerName"),r||a.default.once(0,n.name+".layerName not specified"),r||n.name)}}),Object.defineProperties(e,i)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),c=a(n(184)),f=a(n(181)),i=a(n(122)),_=a(n(86)),d=n(115),h=n(12),o=a(n(116));function a(e){return e&&e.__esModule?e:{default:e}}function s(){}var u={id:o.default.string,width:o.default.number.isRequired,height:o.default.number.isRequired,layers:o.default.array,viewports:o.default.array,effects:o.default.arrayOf(o.default.instanceOf(i.default)),layerFilter:o.default.func,glOptions:o.default.object,gl:o.default.object,pickingRadius:o.default.number,onWebGLInitialized:o.default.func,onBeforeRender:o.default.func,onAfterRender:o.default.func,onLayerClick:o.default.func,onLayerHover:o.default.func,useDevicePixels:o.default.bool,debug:o.default.bool,drawPickingColors:o.default.bool},p={id:"deckgl-overlay",pickingRadius:0,layerFilter:null,glOptions:{},gl:null,layers:[],effects:[],onWebGLInitialized:s,onBeforeRender:s,onAfterRender:s,onLayerClick:null,onLayerHover:null,useDevicePixels:!0,debug:!1,drawPickingColors:!1},l=function(){function l(e){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,l),e=Object.assign({},p,e),this.state={},this.needsRedraw=!0,this.layerManager=null,this.effectManager=null,this.viewports=[],this._onRendererInitialized=this._onRendererInitialized.bind(this),this._onRenderFrame=this._onRenderFrame.bind(this),this.canvas=this._createCanvas(e);var n=e,r=n.width,i=n.height,o=n.gl,a=n.glOptions,s=n.debug,u=n.isGeographicCoordinateSystem,c=n.useDevicePixels;this.animationLoop=new h.AnimationLoop({width:r,height:i,useDevicePixels:c,isGeographicCoordinateSystem:u,onCreateContext:function(e){return o||(0,h.createGLContext)(Object.assign({},a,{canvas:t.canvas,debug:s}))},onInitialize:this._onRendererInitialized,onRender:this._onRenderFrame,onBeforeRender:e.onBeforeRender,onAfterRender:e.onAfterRender}),this.animationLoop.start(),this.setProps(e)}return r(l,[{key:"setProps",value:function(e){if(e=Object.assign({},this.props,e),this.props=e,this.layerManager){var t=e,n=t.layers,r=t.pickingRadius,i=t.onLayerClick,o=t.onLayerHover,a=t.useDevicePixels,s=t.drawPickingColors,u=t.layerFilter,c=e.viewports||e.viewport;if(!c){var l=e,f=l.width,d=l.height,h=l.latitude,p=l.longitude,v=l.zoom,g=l.pitch,y=l.bearing;c=[new _.default({width:f,height:d,latitude:h,longitude:p,zoom:v,pitch:g,bearing:y,isGeographicCoordinateSystem:e.isGeographicCoordinateSystem})]}this.layerManager.setParameters({layers:n,viewports:c,useDevicePixels:a,drawPickingColors:s,layerFilter:u,pickingRadius:r,onLayerClick:i,onLayerHover:o}),this.animationLoop.setViewParameters({useDevicePixels:a})}}},{key:"finalize",value:function(){this.animationLoop.stop(),this.animationLoop=null,this.layerManager&&(this.layerManager.finalize(),this.layerManager=null)}},{key:"pickObject",value:function(e){var t=e.x,n=e.y,r=e.radius,i=void 0===r?0:r,o=e.layerIds,a=void 0===o?null:o,s=this.layerManager.pickObject({x:t,y:n,radius:i,layerIds:a,mode:"query"});return s.length?s[0]:null}},{key:"pickObjects",value:function(e){var t=e.x,n=e.y,r=e.width,i=void 0===r?1:r,o=e.height,a=void 0===o?1:o,s=e.layerIds,u=void 0===s?null:s;return this.layerManager.pickObjects({x:t,y:n,width:i,height:a,layerIds:u})}},{key:"getViewports",value:function(){return this.layerManager?this.layerManager.getViewports():[]}},{key:"_createCanvas",value:function(e){if(e.canvas)return e.canvas;var t=e.id,n=e.width,r=e.height,i=e.style,o=document.createElement("canvas");return o.id=t,o.width=n,o.height=r,o.style=i,(e.parent||document.body).appendChild(o),o}},{key:"_onRendererInitialized",value:function(e){var t=e.gl,n=e.canvas;(0,h.setParameters)(t,{blend:!0,blendFunc:[h.GL.SRC_ALPHA,h.GL.ONE_MINUS_SRC_ALPHA,h.GL.ONE,h.GL.ONE_MINUS_SRC_ALPHA],polygonOffsetFill:!0,depthTest:!0,depthFunc:h.GL.LEQUAL}),this.props.onWebGLInitialized(t),this.layerManager=new c.default(t,{eventManager:new d.EventManager(n),isGeographicCoordinateSystem:e.isGeographicCoordinateSystem}),this.effectManager=new f.default({gl:t,layerManager:this.layerManager});var r=!0,i=!1,o=void 0;try{for(var a,s=this.props.effects[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){var u=a.value;this.effectManager.addEffect(u)}}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}this.setProps(this.props)}},{key:"_onRenderFrame",value:function(e){var t=e.gl,n=this.layerManager.needsRedraw({clearRedrawFlags:!0});n&&(this.props.onBeforeRender({gl:t}),this.layerManager.drawLayers({pass:"screen",redrawReason:n,drawPickingColors:this.props.drawPickingColors}),this.props.onAfterRender({gl:t}))}}]),l}();(t.default=l).propTypes=u,l.defaultProps=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define NUM_OF_LIGHTS 2\n\n// TODO these should be using lighting_ prefix\nuniform vec3 lightsPosition[16];\nuniform vec2 lightsStrength[16];\nuniform float ambientRatio;\nuniform float diffuseRatio;\nuniform float specularRatio;\n\nfloat lighting_getLightWeight(vec3 position_worldspace_vec3, vec3 normals_worldspace) {\n float lightWeight = 0.0;\n\n vec3 normals_worldspace_vec3 = normals_worldspace.xyz;\n\n vec3 camera_pos_worldspace = project_uCameraPosition;\n vec3 view_direction = normalize(camera_pos_worldspace - position_worldspace_vec3);\n\n for (int i = 0; i < NUM_OF_LIGHTS; i++) {\n vec3 light_position_worldspace = project_position(lightsPosition[i]);\n vec3 light_direction = normalize(light_position_worldspace - position_worldspace_vec3);\n\n vec3 halfway_direction = normalize(light_direction + view_direction);\n float lambertian = dot(light_direction, normals_worldspace_vec3);\n float specular = 0.0;\n if (lambertian > 0.0) {\n float specular_angle = max(dot(normals_worldspace_vec3, halfway_direction), 0.0);\n specular = pow(specular_angle, 32.0);\n }\n lambertian = max(lambertian, 0.0);\n lightWeight += (ambientRatio + lambertian * diffuseRatio + specular * specularRatio) *\n lightsStrength[i].x;\n\n }\n\n return lightWeight;\n}\n\n// DEPRECATED - Backwards compatibility\n\nfloat getLightWeight(vec3 position_worldspace_vec3, vec3 normals_worldspace) {\n return lighting_getLightWeight(position_worldspace_vec3, normals_worldspace);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="\nconst vec2 WORLD_SCALE_FP64 = vec2(81.4873275756836, 0.0000032873668232014097);\n\nuniform vec2 project64_uScale;\nuniform vec2 project_uViewProjectionMatrixFP64[16];\n\n// longitude: lnglat_fp64.xy; latitude: lnglat_fp64.zw\nvoid mercatorProject_fp64(vec4 lnglat_fp64, out vec2 out_val[2]) {\n\n#if defined(NVIDIA_FP64_WORKAROUND)\n out_val[0] = sum_fp64(radians_fp64(lnglat_fp64.xy), PI_FP64 * ONE);\n#else\n out_val[0] = sum_fp64(radians_fp64(lnglat_fp64.xy), PI_FP64);\n#endif\n out_val[1] = sub_fp64(PI_FP64,\n log_fp64(tan_fp64(sum_fp64(PI_4_FP64, radians_fp64(lnglat_fp64.zw) / 2.0))));\n return;\n}\n\nvoid project_position_fp64(vec4 position_fp64, out vec2 out_val[2]) {\n vec2 pos_fp64[2];\n mercatorProject_fp64(position_fp64, pos_fp64);\n vec2 x_fp64 = mul_fp64(pos_fp64[0], project64_uScale);\n vec2 y_fp64 = mul_fp64(pos_fp64[1], project64_uScale);\n out_val[0] = mul_fp64(x_fp64, WORLD_SCALE_FP64);\n out_val[1] = mul_fp64(y_fp64, WORLD_SCALE_FP64);\n\n return;\n}\n\nvec4 project_to_clipspace_fp64(vec2 vertex_pos_modelspace[4]) {\n vec2 vertex_pos_clipspace[4];\n mat4_vec4_mul_fp64(project_uViewProjectionMatrixFP64, vertex_pos_modelspace,\n vertex_pos_clipspace);\n return vec4(\n vertex_pos_clipspace[0].x,\n vertex_pos_clipspace[1].x,\n vertex_pos_clipspace[2].x,\n vertex_pos_clipspace[3].x\n );\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default='// EXTERNAL CONSTANTS: these must match JavaScript constants in "src/core/lib/constants.js"\nconst float COORDINATE_SYSTEM_IDENTITY = 0.;\nconst float COORDINATE_SYSTEM_LNG_LAT = 1.;\nconst float COORDINATE_SYSTEM_METER_OFFSETS = 2.;\nconst float COORDINATE_SYSTEM_LNGLAT_OFFSETS = 3.;\n\nuniform float project_uCoordinateSystem;\nuniform float project_uScale;\nuniform vec3 project_uPixelsPerMeter;\nuniform vec3 project_uPixelsPerDegree;\nuniform vec3 project_uPixelsPerUnit;\nuniform vec3 project_uPixelsPerUnit2;\nuniform vec4 project_uCenter;\nuniform mat4 project_uModelMatrix;\nuniform mat4 project_uViewProjectionMatrix;\nuniform vec2 project_uViewportSize;\nuniform float project_uDevicePixelRatio;\nuniform float project_uFocalDistance;\nuniform vec3 project_uCameraPosition;\n\nconst float TILE_SIZE = 512.0;\nconst float PI = 3.1415926536;\nconst float WORLD_SCALE = TILE_SIZE / (PI * 2.0);\n\n//\n// Scaling offsets - scales meters to "pixels"\n// Note the scalar version of project_scale is for scaling the z component only\n//\nfloat project_scale(float meters) {\n return meters * project_uPixelsPerMeter.z;\n}\n\nvec2 project_scale(vec2 meters) {\n return meters * project_uPixelsPerMeter.xy;\n}\n\nvec3 project_scale(vec3 meters) {\n return meters * project_uPixelsPerMeter;\n}\n\nvec4 project_scale(vec4 meters) {\n return vec4(meters.xyz * project_uPixelsPerMeter, meters.w);\n}\n\n//\n// Projecting normal - transform deltas from current coordinate system to\n// normals in the worldspace\n//\nvec3 project_normal(vec3 vector) {\n if (project_uCoordinateSystem == COORDINATE_SYSTEM_LNG_LAT ||\n project_uCoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSETS) {\n return normalize(vector * project_uPixelsPerDegree);\n }\n return normalize(vector * project_uPixelsPerMeter);\n}\n\nvec4 project_offset_(vec4 offset) {\n vec3 pixelsPerUnit = project_uPixelsPerUnit + project_uPixelsPerUnit2 * offset.y;\n return vec4(offset.xyz * pixelsPerUnit, offset.w);\n}\n\n//\n// Projecting positions - non-linear projection: lnglats => unit tile [0-1, 0-1]\n//\nvec2 project_mercator_(vec2 lnglat) {\n return vec2(\n radians(lnglat.x) + PI,\n PI - log(tan_fp32(PI * 0.25 + radians(lnglat.y) * 0.5))\n );\n}\n\n//\n// Projects lnglats (or meter offsets, depending on mode) to pixels\n//\nvec4 project_position(vec4 position) {\n // TODO - why not simply subtract center and fall through?\n if (project_uCoordinateSystem == COORDINATE_SYSTEM_LNG_LAT) {\n return project_uModelMatrix * vec4(\n project_mercator_(position.xy) * WORLD_SCALE * project_uScale,\n project_scale(position.z),\n position.w\n );\n }\n\n if (project_uCoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSETS) {\n return project_offset_(position);\n }\n\n // METER_OFFSETS or IDENTITY\n // Apply model matrix\n vec4 position_modelspace = project_uModelMatrix * position;\n return project_offset_(position_modelspace);\n}\n\nvec3 project_position(vec3 position) {\n vec4 projected_position = project_position(vec4(position, 1.0));\n return projected_position.xyz;\n}\n\nvec2 project_position(vec2 position) {\n vec4 projected_position = project_position(vec4(position, 0.0, 1.0));\n return projected_position.xy;\n}\n\n//\n// Projects from "world" coordinates to clip space.\n// Uses project_uViewProjectionMatrix\n//\nvec4 project_to_clipspace(vec4 position) {\n if (project_uCoordinateSystem == COORDINATE_SYSTEM_METER_OFFSETS ||\n project_uCoordinateSystem == COORDINATE_SYSTEM_LNGLAT_OFFSETS) {\n // Needs to be divided with project_uPixelsPerMeter\n position.w *= project_uPixelsPerMeter.z;\n }\n return project_uViewProjectionMatrix * position + project_uCenter;\n}\n\n// Returns a clip space offset that corresponds to a given number of **non-device** pixels\nvec4 project_pixel_to_clipspace(vec2 pixels) {\n vec2 offset = pixels / project_uViewportSize * project_uDevicePixelRatio;\n return vec4(offset * project_uFocalDistance, 0.0, 0.0);\n}\n'},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getUniformsFromViewport=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.viewport,n=e.modelMatrix,r=void 0===n?null:n,i=e.coordinateSystem,o=void 0===i?_.COORDINATE_SYSTEM.LNGLAT:i,a=e.coordinateOrigin,s=void 0===a?d:a,u=e.projectionMode,c=e.positionOrigin;(0,y.default)(t),void 0!==u&&l.default.removed("projectionMode","coordinateSystem");void 0!==c&&l.default.removed("positionOrigin","coordinateOrigin");return Object.assign({project_uModelMatrix:r||f},h({viewport:t,coordinateSystem:o,coordinateOrigin:s}))};var v=i(n(75)),g=i(n(103)),l=i(n(17)),y=i(n(1)),_=n(70),r=i(n(196)),m=n(79);function i(e){return e&&e.__esModule?e:{default:e}}var b=[0,0,0,0],E=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0],f=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],w=[0,0,0],d=[0,0,0],h=(0,r.default)(function(e){var t=e.viewport,n=e.coordinateSystem,r=e.coordinateOrigin,i=t.zoom;(0,y.default)(0<=i);var o=function(e){var t=e.viewport,n=e.coordinateSystem,r=e.coordinateOrigin,i=e.coordinateZoom,o=t.viewMatrixUncentered,a=t.viewMatrix,s=t.projectionMatrix,u=t.viewProjectionMatrix,c=void 0;switch(n){case _.COORDINATE_SYSTEM.IDENTITY:case _.COORDINATE_SYSTEM.LNGLAT:c=b;break;case _.COORDINATE_SYSTEM.LNGLAT_OFFSETS:case _.COORDINATE_SYSTEM.METER_OFFSETS:var l=(0,m.lngLatToWorld)(r,Math.pow(2,i));c=(0,g.default)([],[l[0],l[1],0,1],u),a=o||a,u=(0,v.default)([],s,a),u=(0,v.default)([],u,E);break;default:throw new Error("Unknown projection mode")}return{viewMatrix:a,viewProjectionMatrix:u,projectionCenter:c,cameraPos:t.cameraPosition}}({coordinateSystem:n,coordinateOrigin:r,coordinateZoom:i,viewport:t}),a=o.projectionCenter,s=o.viewProjectionMatrix,u=o.cameraPos;(0,y.default)(s,"Viewport missing modelViewProjectionMatrix");var c=t.getDistanceScales(),l="undefined"!=typeof window&&window.devicePixelRatio||1,f=[t.width*l,t.height*l],d={project_uCoordinateSystem:n,project_uCenter:a,project_uViewportSize:f,project_uDevicePixelRatio:l,project_uFocalDistance:t.focalDistance||1,project_uPixelsPerMeter:c.pixelsPerMeter,project_uPixelsPerDegree:c.pixelsPerDegree,project_uPixelsPerUnit:c.pixelsPerMeter,project_uPixelsPerUnit2:w,project_uScale:t.scale,project_uViewProjectionMatrix:s,project_uCameraPosition:u};if(n===_.COORDINATE_SYSTEM.METER_OFFSETS){var h=t.getDistanceScales(r);d.project_uPixelsPerUnit=h.pixelsPerMeter,d.project_uPixelsPerUnit2=h.pixelsPerMeter2}if(n===_.COORDINATE_SYSTEM.LNGLAT_OFFSETS){var p=t.getDistanceScales(r);d.project_uPixelsPerUnit=p.pixelsPerDegree,d.project_uPixelsPerUnit2=p.pixelsPerDegree2}return d})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=o(n(193)),b=n(84),l=n(79),E=o(n(1));function o(e){return e&&e.__esModule?e:{default:e}}var a=["longitude","latitude","zoom","bearing","pitch"],w=["latitude","longitude","zoom","width","height"],P=["bearing","pitch"],s=function(e){function t(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var e=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return e.propNames=a,e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),r(t,[{key:"initializeProps",value:function(e,t){var n={},r={},i=!0,o=!1,a=void 0;try{for(var s,u=w[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value,l=e[c],f=t[c];(0,E.default)((0,b.isValid)(l)&&(0,b.isValid)(f),c+" must be supplied for transition"),n[c]=l,r[c]=(0,b.getEndValueByShortestPath)(c,l,f)}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}var d=!0,h=!1,p=void 0;try{for(var v,g=P[Symbol.iterator]();!(d=(v=g.next()).done);d=!0){var y=v.value,_=e[y]||0,m=t[y]||0;n[y]=_,r[y]=(0,b.getEndValueByShortestPath)(y,_,m)}}catch(e){h=!0,p=e}finally{try{!d&&g.return&&g.return()}finally{if(h)throw p}}return{start:n,end:r}}},{key:"interpolateProps",value:function(e,t,n){var r=(0,l.flyToViewport)(e,t,n),i=!0,o=!1,a=void 0;try{for(var s,u=P[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value;r[c]=(0,b.lerp)(e[c],t[c],n)}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}return r}}]),t}();t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var s=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var i=function(e){return e.length},o=function(){function n(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[],t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:i;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),this.sortedBins=this.getSortedBins(e,t),this.maxCount=this.getMaxCount(),this.binMap=this.getBinMap()}return r(n,[{key:"getSortedBins",value:function(e,i){return e.reduce(function(e,t,n){var r=i(t.points);return null!=r&&e.push({i:Number.isFinite(t.index)?t.index:n,value:r,counts:t.points.length}),e},[]).sort(function(e,t){return e.value-t.value})}},{key:"getValueRange",value:function(e){var t=s(e,2),n=t[0],r=t[1],i=this.sortedBins.length;if(!i)return[0,0];var o=Math.ceil(n/100*(i-1)),a=Math.floor(r/100*(i-1));return[this.sortedBins[o].value,this.sortedBins[a].value]}},{key:"getMaxCount",value:function(){var t=0;return this.sortedBins.forEach(function(e){return t=t>e.counts?t:e.counts}),t}},{key:"getBinMap",value:function(){return this.sortedBins.reduce(function(e,t){return Object.assign(e,(n={},r=t.i,i=t,r in n?Object.defineProperty(n,r,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[r]=i,n));var n,r,i},{})}}]),n}();t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.defaultColorRange=[[255,255,178],[254,217,118],[254,178,76],[253,141,60],[240,59,32],[189,0,38]]},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.get=function(e,t){var n=function(e){if("string"!=typeof e)return Array.isArray(e)?e:[e];var t=g[e];t||(t=e.split("."),g[e]=t);return t}(t),r=e,i=!0,o=!1,a=void 0;try{for(var s,u=n[Symbol.iterator]();!(i=(s=u.next()).done);i=!0){var c=s.value;if(null===(d=r)||"object"!==(void 0===d?"undefined":h(d)))return;var l=(f=r,void 0,Object.getPrototypeOf(f).get?v:p);r=l(r,c)}}catch(e){o=!0,a=e}finally{try{!i&&u.return&&u.return()}finally{if(o)throw a}}var f;var d;return r};var p=function(e,t){return e[t]},v=function(e,t){return e.get(t)},g={}},function(i,e,t){"use strict";(function(e,t){var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r="object"!==(void 0===e?"undefined":n(e))||"[object process]"!==String(e)||e.browser;i.exports={window:"undefined"!=typeof window?window:t,global:void 0!==t?t:window,document:"undefined"!=typeof document?document:{},isBrowser:r}}).call(e,t(26),t(47))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.inheritsFrom=function(e,t){for(;e;){if(e===t)return!0;e=Object.getPrototypeOf(e)}return!1}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")};t.linearScale=function(e,t,n){return(n-e[0])/(e[1]-e[0])*(t[1]-t[0])+t[0]},t.quantizeScale=function(e,t,n){var r=(e[1]-e[0])/t.length,i=Math.floor((n-e[0])/r),o=Math.max(Math.min(i,t.length-1),0);return t[o]},t.getQuantizeScale=function(i,o){return function(e){var t=(i[1]-i[0])/o.length,n=Math.floor((e-i[0])/t),r=Math.max(Math.min(n,o.length-1),0);return o[r]}},t.getLinearScale=function(t,n){return function(e){return(e-t[0])/(t[1]-t[0])*(n[1]-n[0])+n[0]}},t.clamp=function(e,t){var n=o(e,2),r=n[0],i=n[1];return Math.min(i,Math.max(r,t))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(42),o=(r=i)&&r.__esModule?r:{default:r},h=n(16);var p=h.experimental.SphericalCoordinates;var a=function(e){function d(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,d);var t,n,r,i=e.modelMatrix,o=void 0===i?null:i,a=e.bearing,s=e.up,u=void 0===s?[0,0,1]:s,c=(n=(t={bearing:a,pitch:89}).bearing,r=t.pitch,new p({bearing:n,pitch:r}).toVector3().normalize()),l=o?o.transformDirection(c):c,f=(new h.Matrix4).lookAt({eye:[0,0,0],center:l,up:u});return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(d.__proto__||Object.getPrototypeOf(d)).call(this,Object.assign({},e,{zoom:null,viewMatrix:f})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(d,o.default),d}();(t.default=a).displayName="FirstPersonViewport"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(n(42)),b=i(n(102)),E=i(n(234));function i(e){return e&&e.__esModule?e:{default:e}}var o=function(e){function m(e){var t=e.width,n=e.height,r=e.eye,i=void 0===r?[0,0,1]:r,o=e.lookAt,a=void 0===o?[0,0,0]:o,s=e.up,u=void 0===s?[0,1,0]:s,c=e.near,l=void 0===c?1:c,f=e.far,d=void 0===f?100:f,h=e.left,p=e.top,v=e.right,g=void 0===v?null:v,y=e.bottom,_=void 0===y?null:y;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,m),g=Number.isFinite(g)?g:h+t,_=Number.isFinite(_)?_:p+n,function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(m.__proto__||Object.getPrototypeOf(m)).call(this,{viewMatrix:(0,b.default)([],i,a,u),projectionMatrix:(0,E.default)([],h,g,_,p,l,d),width:t,height:n}))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(m,r.default),m}();t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(n(42)),_=i(n(102)),m=i(n(76));function i(e){return e&&e.__esModule?e:{default:e}}var b=Math.PI/180,o=function(e){function y(e){var t=e.width,n=e.height,r=e.eye,i=e.lookAt,o=void 0===i?[0,0,0]:i,a=e.up,s=void 0===a?[0,1,0]:a,u=e.fovy,c=void 0===u?75:u,l=e.near,f=void 0===l?1:l,d=e.far,h=void 0===d?100:d,p=e.aspect,v=void 0===p?null:p;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,y);var g=c*b;return v=Number.isFinite(v)?v:t/n,function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(y.__proto__||Object.getPrototypeOf(y)).call(this,{viewMatrix:(0,_.default)([],r,o,s),projectionMatrix:(0,m.default)([],g,v,f,h),width:t,height:n}))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(y,r.default),y}();t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(42),o=(r=i)&&r.__esModule?r:{default:r},d=n(16);var h=d.experimental.SphericalCoordinates;var a=function(e){function f(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f);var t,n,r,i=e.bearing,o=e.pitch,a=e.position,s=e.up,u=50*e.zoom,c=(n=(t={bearing:i,pitch:o}).bearing,r=t.pitch,new h({bearing:n,pitch:r}).toVector3().normalize()).scale(-u).multiply(new d.Vector3(1,1,-1)),l=(new d.Matrix4).multiplyRight((new d.Matrix4).lookAt({eye:c,center:a,up:s}));return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,Object.assign({},e,{zoom:null,viewMatrix:l})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(f,o.default),f}();(t.default=a).displayName="ThirdPersonViewport"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default='#define SHADER_NAME reflection-effect-fs\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\nuniform sampler2D reflectionTexture;\nuniform int reflectionTextureWidth;\nuniform int reflectionTextureHeight;\n\nuniform float reflectivity;\nuniform float blur;\n\n\nvarying vec2 uv;\n\n#define KERNEL_SIZE 7\n\n/*\n * Samples from tex with a gaussian-shaped patch, centered at uv and\n * with standard deviation sigma. The size of the texture in\n * pixels must be specified by dim\n */\nvec4 sample_gaussian(sampler2D tex, vec2 dim, vec2 uv, float sigma) {\n if (sigma == 0.0) {\n return texture2D(tex, uv);\n }\n\n vec2 delta = 1.0 / dim;\n vec2 top_left = uv - delta * float(KERNEL_SIZE+1) / 2.0;\n\n vec4 color = vec4(0);\n float sum = 0.0;\n for (int i = 0; i < KERNEL_SIZE; ++i) {\n for (int j = 0; j < KERNEL_SIZE; ++j) {\n vec2 uv2 = top_left + vec2(i, j) * delta;\n float d = length((uv2 - uv) * dim);\n float f = exp(-(d*d) / (2.0*sigma * sigma));\n color += f * texture2D(tex, uv2);\n sum += f;\n }\n }\n return color / sum;\n}\n\nvoid main(void) {\n //map blur in [0, 1] to sigma in [0, inf]\n //alpha will determine the "steepness" of our curve.\n //this was picked just to make the scale feel "natural"\n //if our image is 1000 pixels wide, a blur of 0.5 should correspond\n //to a sigma of 1 pixels\n float alpha = 1000.0;\n float sigma = blur / (alpha * (1.0 - blur));\n //let this be our standard deviation in terms of screen-widths.\n //rewrite this in terms of pixels.\n sigma *= float(reflectionTextureWidth);\n\n\n gl_FragColor = sample_gaussian(reflectionTexture, vec2(reflectionTextureWidth,\n reflectionTextureHeight), vec2(uv.x, 1. - uv.y), sigma);\n //because our canvas expects alphas to be pre-multiplied, we multiply by whole\n //color vector by reflectivity, not just the alpha channel\n gl_FragColor *= reflectivity;\n}\n'},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default="#define SHADER_NAME reflection-effect-vs\n\nattribute vec3 vertices;\n\nvarying vec2 uv;\n\nvoid main(void) {\n uv = vertices.xy;\n gl_Position = vec4(2. * vertices.xy - vec2(1., 1.), 1., 1.);\n}\n"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),a=n(12),o=r(n(122)),s=r(n(86)),u=r(n(358)),c=r(n(357));function r(e){return e&&e.__esModule?e:{default:e}}var l=function(e){function r(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:.5,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:.5;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this));return n.reflectivity=e,n.blur=t,n.framebuffer=null,n.setNeedsRedraw(),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,o.default),i(r,[{key:"getShaders",value:function(){return{vs:u.default,fs:c.default,modules:[],shaderCache:this.context.shaderCache}}},{key:"initialize",value:function(e){var t=e.gl;e.layerManager;this.unitQuad=new a.Model(t,Object.assign({},this.getShaders(),{id:"reflection-effect",geometry:new a.Geometry({drawMode:a.GL.TRIANGLE_FAN,vertices:new Float32Array([0,0,0,1,0,0,1,1,0,0,1,0])})})),this.framebuffer=new a.Framebuffer(t,{depth:!0})}},{key:"preDraw",value:function(e){var t=e.gl,n=e.layerManager,r=n.context.viewport,i="undefined"!=typeof window&&window.devicePixelRatio||1;this.framebuffer.resize({width:i*r.width,height:i*r.height});var o=r.pitch;this.framebuffer.bind(),n.setViewport(new s.default(Object.assign({},r,{pitch:-180-o}))),t.clear(a.GL.COLOR_BUFFER_BIT|a.GL.DEPTH_BUFFER_BIT),n.drawLayers({pass:"reflection"}),n.setViewport(r),this.framebuffer.unbind()}},{key:"draw",value:function(e){e.gl,e.layerManager;this.unitQuad.render({reflectionTexture:this.framebuffer.texture,reflectionTextureWidth:this.framebuffer.width,reflectionTextureHeight:this.framebuffer.height,reflectivity:this.reflectivity,blur:this.blur})}},{key:"finalize",value:function(e){e.gl,e.layerManager}}]),r}();t.default=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),p=n(117),o=u(p),i=u(n(197)),a=n(351),s=n(13);function u(e){return e&&e.__esModule?e:{default:e}}function c(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var l=s.experimental.DeckGLJS,f=s.experimental.log,d=function(e){function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e));return t.state={},t.children=[],(0,i.default)(t),t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,o.default.Component),r(n,[{key:"componentDidMount",value:function(){this.deck=new l(Object.assign({},this.props,{canvas:this.overlay})),this._updateFromProps(this.props)}},{key:"componentWillReceiveProps",value:function(e){this._updateFromProps(e)}},{key:"componentWillUnmount",value:function(){this.deck.finalize()}},{key:"queryObject",value:function(e){return f.deprecated("queryObject","pickObject"),this.deck.pickObject(e)}},{key:"pickObject",value:function(e){var t=e.x,n=e.y,r=e.radius,i=void 0===r?0:r,o=e.layerIds,a=void 0===o?null:o;return this.deck.pickObject({x:t,y:n,radius:i,layerIds:a})}},{key:"queryVisibleObjects",value:function(e){return f.deprecated("queryVisibleObjects","pickObjects"),this.pickObjects(e)}},{key:"pickObjects",value:function(e){var t=e.x,n=e.y,r=e.width,i=void 0===r?1:r,o=e.height,a=void 0===o?1:o,s=e.layerIds,u=void 0===s?null:s;return this.deck.pickObjects({x:t,y:n,width:i,height:a,layerIds:u})}},{key:"_updateFromProps",value:function(e){var t=this._extractJSXLayers(e.children),n=t.layers,r=t.children;this.deck&&this.deck.setProps(Object.assign({},e,{layers:n?[].concat(c(n),c(e.layers)):e.layers})),this.children=r}},{key:"_extractJSXLayers",value:function(e){var r=[],i=null;return o.default.Children.forEach(e,function(e){if(e){var t=e.type;if((0,a.inheritsFrom)(t,s.Layer)){var n=new t(e.props);(i=i||[]).push(n)}else r.push(e)}}),{layers:i,children:r}}},{key:"_renderChildrenUnderViewports",value:function(e){var n=this,t=this.deck?this.deck.getViewports():[],r={};return t.forEach(function(e){e.id&&(r[e.id]=e)}),e.map(function(e,t){return e.props.viewportId?n._positionChild({child:e,viewportMap:r,i:t}):e})}},{key:"_positionChild",value:function(e){var t=e.child,n=e.viewportMap,r=e.i,i=t.props.viewportId,o=i&&n[i];if(!o)return null;var a=o.x,s=o.y,u=o.width,c=o.height,l=Object.assign({},t.props,{width:u,height:c});Object.assign(l,o.getMercatorParams(),{visible:o.isMapSynched()});var f=(0,p.cloneElement)(t,l),d={position:"absolute",left:a,top:s,width:u,height:c},h="viewport-child-"+i+"-"+r;return(0,p.createElement)("div",{key:h,id:h,style:d},f)}},{key:"render",value:function(){var t=this,e=this._renderChildrenUnderViewports(this.children),n=this.props,r=n.id,i=n.width,o=n.height,a=n.style,s=(0,p.createElement)("canvas",{ref:function(e){return t.overlay=e},key:"overlay",id:r,style:Object.assign({},{position:"absolute",left:0,top:0,width:i,height:o},a)});return e.push(s),(0,p.createElement)("div",{id:"deckgl-wrapper"},e)}}]),n}();(t.default=d).propTypes=l.propTypes,d.defaultProps=l.defaultProps},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(117),o=s(n(189)),a=s(n(85));function s(e){return e&&e.__esModule?e:{default:e}}var u=function(e){function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e));return t.controller=null,t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,i.PureComponent),r(n,null,[{key:"getViewport",value:function(e){return new a.default(e)}}]),r(n,[{key:"componentDidMount",value:function(){this.controller=new o.default(Object.assign({},this.props,{canvas:this.eventCanvas}))}},{key:"componentWillUpdate",value:function(e){this.controller.setProps(e)}},{key:"componentWillUnmount",value:function(){this.controller.finalize()}},{key:"render",value:function(){var t=this,e=this.props,n={width:e.width,height:e.height,position:"relative"};return(0,i.createElement)("div",{key:"map-controls",ref:function(e){return t.eventCanvas=e},style:n},this.props.children)}}]),n}();(t.default=u).displayName="OrbitController",u.propTypes=o.default.propTypes,u.defaultProps=o.default.defaultProps},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(360);Object.defineProperty(t,"DeckGL",{enumerable:!0,get:function(){return u(r).default}}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return u(r).default}});var i=n(365);Object.defineProperty(t,"ViewportController",{enumerable:!0,get:function(){return u(i).default}});var o=n(363);Object.defineProperty(t,"MapController",{enumerable:!0,get:function(){return u(o).default}});var a=n(361);Object.defineProperty(t,"OrbitController",{enumerable:!0,get:function(){return u(a).default}});var s=n(197);function u(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"autobind",{enumerable:!0,get:function(){return u(s).default}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),o=n(117),a=n(188),s=(r=a)&&r.__esModule?r:{default:r};var u=function(e){function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e));return t.controller=null,t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,o.PureComponent),i(n,[{key:"componentDidMount",value:function(){this.controller=new s.default(Object.assign({},this.props,{canvas:this.eventCanvas}))}},{key:"componentWillUpdate",value:function(e){this.controller.setProps(e)}},{key:"componentWillUnmount",value:function(){this.controller.finalize()}},{key:"render",value:function(){var t=this,e=this.props,n={width:e.width,height:e.height,position:"relative"};return(0,o.createElement)("div",{key:"map-controls",ref:function(e){return t.eventCanvas=e},style:n},this.props.children)}}]),n}();(t.default=u).displayName="MapController",u.propTypes=s.default.propTypes,u.defaultProps=s.default.defaultProps},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default={GRABBING:"-webkit-grabbing",GRAB:"-webkit-grab",POINTER:"pointer"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}(),i=n(117),o=c(n(116)),a=n(115),s=n(13),u=c(n(364));function c(e){return e&&e.__esModule?e:{default:e}}var l=s.experimental.ViewportControls,f=s.experimental.TransitionManager,d={viewportState:o.default.func,state:o.default.object,width:o.default.number.isRequired,height:o.default.number.isRequired,longitude:o.default.number.isRequired,latitude:o.default.number.isRequired,zoom:o.default.number.isRequired,bearing:o.default.number,pitch:o.default.number,altitude:o.default.number,position:o.default.array,maxZoom:o.default.number,minZoom:o.default.number,maxPitch:o.default.number,minPitch:o.default.number,onViewportChange:o.default.func,transitionDuration:o.default.number,transitionInterpolator:o.default.object,transitionInterruption:o.default.number,transitionEasing:o.default.func,onTransitionStart:o.default.func,onTransitionInterrupt:o.default.func,onTransitionEnd:o.default.func,scrollZoom:o.default.bool,dragPan:o.default.bool,dragRotate:o.default.bool,doubleClickZoom:o.default.bool,touchZoomRotate:o.default.bool,getCursor:o.default.func,controls:o.default.shape({events:o.default.arrayOf(o.default.string),handleEvent:o.default.func})},h=Object.assign({},f.defaultProps,{onViewportChange:null,scrollZoom:!0,dragPan:!0,dragRotate:!0,doubleClickZoom:!0,touchZoomRotate:!0,getCursor:function(e){return e.isDragging?u.default.GRABBING:u.default.GRAB}}),p=function(e){function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e));return t.state={isDragging:!1},t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,i.Component),r(n,[{key:"componentDidMount",value:function(){this._eventManager=new a.EventManager(this.eventCanvas),this._controls=this.props.controls||new l(this.props.viewportState),this._controls.setOptions(Object.assign({},this.props,{onStateChange:this._onInteractiveStateChange.bind(this),eventManager:this._eventManager})),this._transitionManger=new f(this.props)}},{key:"shouldComponentUpdate",value:function(e,t){return!this._transitionManger||!this._transitionManger.processViewportChange(e)}},{key:"componentWillUpdate",value:function(e){this._controls&&this._controls.setOptions(e)}},{key:"componentWillUnmount",value:function(){this._eventManager.destroy()}},{key:"_onInteractiveStateChange",value:function(e){var t=e.isDragging,n=void 0!==t&&t;n!==this.state.isDragging&&this.setState({isDragging:n})}},{key:"render",value:function(){var t=this,e=this.props,n={width:e.width,height:e.height,position:"relative",cursor:(0,e.getCursor)(this.state)};return(0,i.createElement)("div",{key:"map-controls",ref:function(e){return t.eventCanvas=e},style:n},this.props.children)}}]),n}();(t.default=p).displayName="ViewportController",p.propTypes=d,p.defaultProps=h},function(M,e,t){(function(e){!function(e){"use strict";var u,t=Object.prototype,c=t.hasOwnProperty,n="function"==typeof Symbol?Symbol:{},i=n.iterator||"@@iterator",r=n.asyncIterator||"@@asyncIterator",o=n.toStringTag||"@@toStringTag",a="object"==typeof M,s=e.regeneratorRuntime;if(s)a&&(M.exports=s);else{(s=e.regeneratorRuntime=a?M.exports:{}).wrap=m;var f="suspendedStart",d="suspendedYield",h="executing",p="completed",v={},l={};l[i]=function(){return this};var g=Object.getPrototypeOf,y=g&&g(g(C([])));y&&y!==t&&c.call(y,i)&&(l=y);var _=P.prototype=E.prototype=Object.create(l);w.prototype=_.constructor=P,P.constructor=w,P[o]=w.displayName="GeneratorFunction",s.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===w||"GeneratorFunction"===(t.displayName||t.name))},s.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,P):(e.__proto__=P,o in e||(e[o]="GeneratorFunction")),e.prototype=Object.create(_),e},s.awrap=function(e){return{__await:e}},S(A.prototype),A.prototype[r]=function(){return this},s.AsyncIterator=A,s.async=function(e,t,n,r){var i=new A(m(e,t,n,r));return s.isGeneratorFunction(t)?i:i.next().then(function(e){return e.done?e.value:i.next()})},S(_),_[o]="Generator",_[i]=function(){return this},_.toString=function(){return"[object Generator]"},s.keys=function(n){var r=[];for(var e in n)r.push(e);return r.reverse(),function e(){for(;r.length;){var t=r.pop();if(t in n)return e.value=t,e.done=!1,e}return e.done=!0,e}},s.values=C,R.prototype={constructor:R,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=u,this.done=!1,this.delegate=null,this.method="next",this.arg=u,this.tryEntries.forEach(O),!e)for(var t in this)"t"===t.charAt(0)&&c.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=u)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(n){if(this.done)throw n;var r=this;function e(e,t){return o.type="throw",o.arg=n,r.next=e,t&&(r.method="next",r.arg=u),!!t}for(var t=this.tryEntries.length-1;0<=t;--t){var i=this.tryEntries[t],o=i.completion;if("root"===i.tryLoc)return e("end");if(i.tryLoc<=this.prev){var a=c.call(i,"catchLoc"),s=c.call(i,"finallyLoc");if(a&&s){if(this.prev<i.catchLoc)return e(i.catchLoc,!0);if(this.prev<i.finallyLoc)return e(i.finallyLoc)}else if(a){if(this.prev<i.catchLoc)return e(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return e(i.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;0<=n;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&c.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var i=r;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var o=i?i.completion:{};return o.type=e,o.arg=t,i?(this.method="next",this.next=i.finallyLoc,v):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),v},finish:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),O(n),v}},catch:function(e){for(var t=this.tryEntries.length-1;0<=t;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;O(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:C(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=u),v}}}function m(e,t,n,r){var o,a,s,u,i=t&&t.prototype instanceof E?t:E,c=Object.create(i.prototype),l=new R(r||[]);return c._invoke=(o=e,a=n,s=l,u=f,function(e,t){if(u===h)throw new Error("Generator is already running");if(u===p){if("throw"===e)throw t;return k()}for(s.method=e,s.arg=t;;){var n=s.delegate;if(n){var r=T(n,s);if(r){if(r===v)continue;return r}}if("next"===s.method)s.sent=s._sent=s.arg;else if("throw"===s.method){if(u===f)throw u=p,s.arg;s.dispatchException(s.arg)}else"return"===s.method&&s.abrupt("return",s.arg);u=h;var i=b(o,a,s);if("normal"===i.type){if(u=s.done?p:d,i.arg===v)continue;return{value:i.arg,done:s.done}}"throw"===i.type&&(u=p,s.method="throw",s.arg=i.arg)}}),c}function b(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}function E(){}function w(){}function P(){}function S(e){["next","throw","return"].forEach(function(t){e[t]=function(e){return this._invoke(t,e)}})}function A(s){function u(e,t,n,r){var i=b(s[e],s,t);if("throw"!==i.type){var o=i.arg,a=o.value;return a&&"object"==typeof a&&c.call(a,"__await")?Promise.resolve(a.__await).then(function(e){u("next",e,n,r)},function(e){u("throw",e,n,r)}):Promise.resolve(a).then(function(e){o.value=e,n(o)},r)}r(i.arg)}var t;"object"==typeof e.process&&e.process.domain&&(u=e.process.domain.bind(u)),this._invoke=function(n,r){function e(){return new Promise(function(e,t){u(n,r,e,t)})}return t=t?t.then(e,e):e()}}function T(e,t){var n=e.iterator[t.method];if(n===u){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=u,T(e,t),"throw"===t.method))return v;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var r=b(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,v;var i=r.arg;return i?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=u),t.delegate=null,v):i:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,v)}function x(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function O(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function R(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(x,this),this.reset(!0)}function C(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,r=function e(){for(;++n<t.length;)if(c.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=u,e.done=!0,e};return r.next=r}}return{next:k}}function k(){return{value:u,done:!0}}}("object"==typeof e?e:"object"==typeof window?window:"object"==typeof self?self:this)}).call(e,t(47))},function(e,t,n){n(374),e.exports=n(33).RegExp.escape},function(e,t,n){var r=n(5),i=n(91),o=n(6)("species");e.exports=function(e){var t;return i(e)&&("function"!=typeof(t=e.constructor)||t!==Array&&!i(t.prototype)||(t=void 0),r(t)&&null===(t=t[o])&&(t=void 0)),void 0===t?Array:t}},function(e,t,n){"use strict";var r=n(4),i=Date.prototype.getTime,o=Date.prototype.toISOString,a=function(e){return 9<e?e:"0"+e};e.exports=r(function(){return"0385-07-25T07:06:39.999Z"!=o.call(new Date(-5e13-1))})||!r(function(){o.call(new Date(NaN))})?function(){if(!isFinite(i.call(this)))throw RangeError("Invalid time value");var e=this.getUTCFullYear(),t=this.getUTCMilliseconds(),n=e<0?"-":9999<e?"+":"";return n+("00000"+Math.abs(e)).slice(n?-6:-4)+"-"+a(this.getUTCMonth()+1)+"-"+a(this.getUTCDate())+"T"+a(this.getUTCHours())+":"+a(this.getUTCMinutes())+":"+a(this.getUTCSeconds())+"."+(99<t?t:"0"+a(t))+"Z"}:o},function(e,t,n){"use strict";var r=n(2),i=n(37);e.exports=function(e){if("string"!==e&&"number"!==e&&"default"!==e)throw TypeError("Incorrect hint");return i(r(this),"number"!=e)}},function(e,t,n){var s=n(53),u=n(95),c=n(73);e.exports=function(e){var t=s(e),n=u.f;if(n)for(var r,i=n(e),o=c.f,a=0;i.length>a;)o.call(e,r=i[a++])&&t.push(r);return t}},function(e,t){e.exports=function(t,n){var r=n===Object(n)?function(e){return n[e]}:n;return function(e){return String(e).replace(t,r)}}},function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}},function(e,t,n){var r=n(0),i=n(372)(/[\\^$*+?.()|[\]{}]/g,"\\$&");r(r.S,"RegExp",{escape:function(e){return i(e)}})},function(e,t,n){var r=n(0);r(r.P,"Array",{copyWithin:n(199)}),n(43)("copyWithin")},function(e,t,n){"use strict";var r=n(0),i=n(32)(4);r(r.P+r.F*!n(29)([].every,!0),"Array",{every:function(e){return i(this,e,arguments[1])}})},function(e,t,n){var r=n(0);r(r.P,"Array",{fill:n(128)}),n(43)("fill")},function(e,t,n){"use strict";var r=n(0),i=n(32)(2);r(r.P+r.F*!n(29)([].filter,!0),"Array",{filter:function(e){return i(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(0),i=n(32)(6),o="findIndex",a=!0;o in[]&&Array(1)[o](function(){a=!1}),r(r.P+r.F*a,"Array",{findIndex:function(e){return i(this,e,1<arguments.length?arguments[1]:void 0)}}),n(43)(o)},function(e,t,n){"use strict";var r=n(0),i=n(32)(5),o=!0;"find"in[]&&Array(1).find(function(){o=!1}),r(r.P+r.F*o,"Array",{find:function(e){return i(this,e,1<arguments.length?arguments[1]:void 0)}}),n(43)("find")},function(e,t,n){"use strict";var r=n(0),i=n(32)(0),o=n(29)([].forEach,!0);r(r.P+r.F*!o,"Array",{forEach:function(e){return i(this,e,arguments[1])}})},function(e,t,n){"use strict";var d=n(28),r=n(0),h=n(14),p=n(210),v=n(136),g=n(11),y=n(130),_=n(153);r(r.S+r.F*!n(93)(function(e){Array.from(e)}),"Array",{from:function(e){var t,n,r,i,o=h(e),a="function"==typeof this?this:Array,s=arguments.length,u=1<s?arguments[1]:void 0,c=void 0!==u,l=0,f=_(o);if(c&&(u=d(u,2<s?arguments[2]:void 0,2)),null==f||a==Array&&v(f))for(n=new a(t=g(o.length));l<t;l++)y(n,l,c?u(o[l],l):o[l]);else for(i=f.call(o),n=new a;!(r=i.next()).done;l++)y(n,l,c?p(i,u,[r.value,l],!0):r.value);return n.length=l,n}})},function(e,t,n){"use strict";var r=n(0),i=n(87)(!1),o=[].indexOf,a=!!o&&1/[1].indexOf(1,-0)<0;r(r.P+r.F*(a||!n(29)(o)),"Array",{indexOf:function(e){return a?o.apply(this,arguments)||0:i(this,e,arguments[1])}})},function(e,t,n){var r=n(0);r(r.S,"Array",{isArray:n(91)})},function(e,t,n){"use strict";var r=n(0),i=n(24),o=[].join;r(r.P+r.F*(n(72)!=Object||!n(29)(o)),"Array",{join:function(e){return o.call(i(this),void 0===e?",":e)}})},function(e,t,n){"use strict";var r=n(0),i=n(24),o=n(36),a=n(11),s=[].lastIndexOf,u=!!s&&1/[1].lastIndexOf(1,-0)<0;r(r.P+r.F*(u||!n(29)(s)),"Array",{lastIndexOf:function(e){if(u)return s.apply(this,arguments)||0;var t=i(this),n=a(t.length),r=n-1;for(1<arguments.length&&(r=Math.min(r,o(arguments[1]))),r<0&&(r=n+r);0<=r;r--)if(r in t&&t[r]===e)return r||0;return-1}})},function(e,t,n){"use strict";var r=n(0),i=n(32)(1);r(r.P+r.F*!n(29)([].map,!0),"Array",{map:function(e){return i(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(0),i=n(130);r(r.S+r.F*n(4)(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);e<t;)i(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){"use strict";var r=n(0),i=n(201);r(r.P+r.F*!n(29)([].reduceRight,!0),"Array",{reduceRight:function(e){return i(this,e,arguments.length,arguments[1],!0)}})},function(e,t,n){"use strict";var r=n(0),i=n(201);r(r.P+r.F*!n(29)([].reduce,!0),"Array",{reduce:function(e){return i(this,e,arguments.length,arguments[1],!1)}})},function(e,t,n){"use strict";var r=n(0),i=n(134),c=n(27),l=n(57),f=n(11),d=[].slice;r(r.P+r.F*n(4)(function(){i&&d.call(i)}),"Array",{slice:function(e,t){var n=f(this.length),r=c(this);if(t=void 0===t?n:t,"Array"==r)return d.call(this,e,t);for(var i=l(e,n),o=l(t,n),a=f(o-i),s=new Array(a),u=0;u<a;u++)s[u]="String"==r?this.charAt(i+u):this[i+u];return s}})},function(e,t,n){"use strict";var r=n(0),i=n(32)(3);r(r.P+r.F*!n(29)([].some,!0),"Array",{some:function(e){return i(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(0),i=n(15),o=n(14),a=n(4),s=[].sort,u=[1,2,3];r(r.P+r.F*(a(function(){u.sort(void 0)})||!a(function(){u.sort(null)})||!n(29)(s)),"Array",{sort:function(e){return void 0===e?s.call(o(this)):s.call(o(this),i(e))}})},function(e,t,n){n(56)("Array")},function(e,t,n){var r=n(0);r(r.S,"Date",{now:function(){return(new Date).getTime()}})},function(e,t,n){var r=n(0),i=n(369);r(r.P+r.F*(Date.prototype.toISOString!==i),"Date",{toISOString:i})},function(e,t,n){"use strict";var r=n(0),i=n(14),o=n(37);r(r.P+r.F*n(4)(function(){return null!==new Date(NaN).toJSON()||1!==Date.prototype.toJSON.call({toISOString:function(){return 1}})}),"Date",{toJSON:function(e){var t=i(this),n=o(t);return"number"!=typeof n||isFinite(n)?t.toISOString():null}})},function(e,t,n){var r=n(6)("toPrimitive"),i=Date.prototype;r in i||n(19)(i,r,n(370))},function(e,t,n){var r=Date.prototype,i="Invalid Date",o=r.toString,a=r.getTime;new Date(NaN)+""!=i&&n(20)(r,"toString",function(){var e=a.call(this);return e==e?o.call(this):i})},function(e,t,n){var r=n(0);r(r.P,"Function",{bind:n(202)})},function(e,t,n){"use strict";var r=n(5),i=n(23),o=n(6)("hasInstance"),a=Function.prototype;o in a||n(10).f(a,o,{value:function(e){if("function"!=typeof this||!r(e))return!1;if(!r(this.prototype))return e instanceof this;for(;e=i(e);)if(this.prototype===e)return!0;return!1}})},function(e,t,n){var r=n(10).f,i=Function.prototype,o=/^\s*function ([^ (]*)/;"name"in i||n(9)&&r(i,"name",{configurable:!0,get:function(){try{return(""+this).match(o)[1]}catch(e){return""}}})},function(e,t,n){var r=n(0),i=n(213),o=Math.sqrt,a=Math.acosh;r(r.S+r.F*!(a&&710==Math.floor(a(Number.MAX_VALUE))&&a(1/0)==1/0),"Math",{acosh:function(e){return(e=+e)<1?NaN:94906265.62425156<e?Math.log(e)+Math.LN2:i(e-1+o(e-1)*o(e+1))}})},function(e,t,n){var r=n(0),i=Math.asinh;r(r.S+r.F*!(i&&0<1/i(0)),"Math",{asinh:function e(t){return isFinite(t=+t)&&0!=t?t<0?-e(-t):Math.log(t+Math.sqrt(t*t+1)):t}})},function(e,t,n){var r=n(0),i=Math.atanh;r(r.S+r.F*!(i&&1/i(-0)<0),"Math",{atanh:function(e){return 0==(e=+e)?e:Math.log((1+e)/(1-e))/2}})},function(e,t,n){var r=n(0),i=n(140);r(r.S,"Math",{cbrt:function(e){return i(e=+e)*Math.pow(Math.abs(e),1/3)}})},function(e,t,n){var r=n(0);r(r.S,"Math",{clz32:function(e){return(e>>>=0)?31-Math.floor(Math.log(e+.5)*Math.LOG2E):32}})},function(e,t,n){var r=n(0),i=Math.exp;r(r.S,"Math",{cosh:function(e){return(i(e=+e)+i(-e))/2}})},function(e,t,n){var r=n(0),i=n(139);r(r.S+r.F*(i!=Math.expm1),"Math",{expm1:i})},function(e,t,n){var r=n(0);r(r.S,"Math",{fround:n(212)})},function(e,t,n){var r=n(0),u=Math.abs;r(r.S,"Math",{hypot:function(e,t){for(var n,r,i=0,o=0,a=arguments.length,s=0;o<a;)s<(n=u(arguments[o++]))?(i=i*(r=s/n)*r+1,s=n):i+=0<n?(r=n/s)*r:n;return s===1/0?1/0:s*Math.sqrt(i)}})},function(e,t,n){var r=n(0),i=Math.imul;r(r.S+r.F*n(4)(function(){return-5!=i(4294967295,5)||2!=i.length}),"Math",{imul:function(e,t){var n=+e,r=+t,i=65535&n,o=65535&r;return 0|i*o+((65535&n>>>16)*o+i*(65535&r>>>16)<<16>>>0)}})},function(e,t,n){var r=n(0);r(r.S,"Math",{log10:function(e){return Math.log(e)*Math.LOG10E}})},function(e,t,n){var r=n(0);r(r.S,"Math",{log1p:n(213)})},function(e,t,n){var r=n(0);r(r.S,"Math",{log2:function(e){return Math.log(e)/Math.LN2}})},function(e,t,n){var r=n(0);r(r.S,"Math",{sign:n(140)})},function(e,t,n){var r=n(0),i=n(139),o=Math.exp;r(r.S+r.F*n(4)(function(){return-2e-17!=!Math.sinh(-2e-17)}),"Math",{sinh:function(e){return Math.abs(e=+e)<1?(i(e)-i(-e))/2:(o(e-1)-o(-e-1))*(Math.E/2)}})},function(e,t,n){var r=n(0),i=n(139),o=Math.exp;r(r.S,"Math",{tanh:function(e){var t=i(e=+e),n=i(-e);return t==1/0?1:n==1/0?-1:(t-n)/(o(e)+o(-e))}})},function(e,t,n){var r=n(0);r(r.S,"Math",{trunc:function(e){return(0<e?Math.floor:Math.ceil)(e)}})},function(e,t,n){"use strict";var r=n(3),i=n(18),o=n(27),a=n(135),l=n(37),s=n(4),u=n(52).f,c=n(22).f,f=n(10).f,d=n(65).trim,h="Number",p=r[h],v=p,g=p.prototype,y=o(n(51)(g))==h,_="trim"in String.prototype,m=function(e){var t=l(e,!1);if("string"==typeof t&&2<t.length){var n,r,i,o=(t=_?t.trim():d(t,3)).charCodeAt(0);if(43===o||45===o){if(88===(n=t.charCodeAt(2))||120===n)return NaN}else if(48===o){switch(t.charCodeAt(1)){case 66:case 98:r=2,i=49;break;case 79:case 111:r=8,i=55;break;default:return+t}for(var a,s=t.slice(2),u=0,c=s.length;u<c;u++)if((a=s.charCodeAt(u))<48||i<a)return NaN;return parseInt(s,r)}}return+t};if(!p(" 0o1")||!p("0b1")||p("+0x1")){p=function(e){var t=arguments.length<1?0:e,n=this;return n instanceof p&&(y?s(function(){g.valueOf.call(n)}):o(n)!=h)?a(new v(m(t)),n,p):m(t)};for(var b,E=n(9)?u(v):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),w=0;E.length>w;w++)i(v,b=E[w])&&!i(p,b)&&f(p,b,c(v,b));(p.prototype=g).constructor=p,n(20)(r,h,p)}},function(e,t,n){var r=n(0);r(r.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,n){var r=n(0),i=n(3).isFinite;r(r.S,"Number",{isFinite:function(e){return"number"==typeof e&&i(e)}})},function(e,t,n){var r=n(0);r(r.S,"Number",{isInteger:n(209)})},function(e,t,n){var r=n(0);r(r.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,n){var r=n(0),i=n(209),o=Math.abs;r(r.S,"Number",{isSafeInteger:function(e){return i(e)&&o(e)<=9007199254740991}})},function(e,t,n){var r=n(0);r(r.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,n){var r=n(0);r(r.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,n){var r=n(0),i=n(221);r(r.S+r.F*(Number.parseFloat!=i),"Number",{parseFloat:i})},function(e,t,n){var r=n(0),i=n(222);r(r.S+r.F*(Number.parseInt!=i),"Number",{parseInt:i})},function(e,t,n){"use strict";var r=n(0),c=n(36),l=n(198),f=n(147),i=1..toFixed,o=Math.floor,a=[0,0,0,0,0,0],d="Number.toFixed: incorrect invocation!",h=function(e,t){for(var n=-1,r=t;++n<6;)r+=e*a[n],a[n]=r%1e7,r=o(r/1e7)},p=function(e){for(var t=6,n=0;0<=--t;)n+=a[t],a[t]=o(n/e),n=n%e*1e7},v=function(){for(var e=6,t="";0<=--e;)if(""!==t||0===e||0!==a[e]){var n=String(a[e]);t=""===t?n:t+f.call("0",7-n.length)+n}return t},g=function(e,t,n){return 0===t?n:t%2==1?g(e,t-1,n*e):g(e*e,t/2,n)};r(r.P+r.F*(!!i&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!n(4)(function(){i.call({})})),"Number",{toFixed:function(e){var t,n,r,i,o=l(this,d),a=c(e),s="",u="0";if(a<0||20<a)throw RangeError(d);if(o!=o)return"NaN";if(o<=-1e21||1e21<=o)return String(o);if(o<0&&(s="-",o=-o),1e-21<o)if(n=(t=function(e){for(var t=0,n=e;4096<=n;)t+=12,n/=4096;for(;2<=n;)t+=1,n/=2;return t}(o*g(2,69,1))-69)<0?o*g(2,-t,1):o/g(2,t,1),n*=4503599627370496,0<(t=52-t)){for(h(0,n),r=a;7<=r;)h(1e7,0),r-=7;for(h(g(10,r,1),0),r=t-1;23<=r;)p(1<<23),r-=23;p(1<<r),h(1,1),p(2),u=v()}else h(0,n),h(1<<-t,0),u=v()+f.call("0",a);return u=0<a?s+((i=u.length)<=a?"0."+f.call("0",a-i)+u:u.slice(0,i-a)+"."+u.slice(i-a)):s+u}})},function(e,t,n){"use strict";var r=n(0),i=n(4),o=n(198),a=1..toPrecision;r(r.P+r.F*(i(function(){return"1"!==a.call(1,void 0)})||!i(function(){a.call({})})),"Number",{toPrecision:function(e){var t=o(this,"Number#toPrecision: incorrect invocation!");return void 0===e?a.call(t):a.call(t,e)}})},function(e,t,n){var r=n(0);r(r.S+r.F,"Object",{assign:n(215)})},function(e,t,n){var r=n(0);r(r.S,"Object",{create:n(51)})},function(e,t,n){var r=n(0);r(r.S+r.F*!n(9),"Object",{defineProperties:n(216)})},function(e,t,n){var r=n(0);r(r.S+r.F*!n(9),"Object",{defineProperty:n(10).f})},function(e,t,n){var r=n(5),i=n(44).onFreeze;n(35)("freeze",function(t){return function(e){return t&&r(e)?t(i(e)):e}})},function(e,t,n){var r=n(24),i=n(22).f;n(35)("getOwnPropertyDescriptor",function(){return function(e,t){return i(r(e),t)}})},function(e,t,n){n(35)("getOwnPropertyNames",function(){return n(217).f})},function(e,t,n){var r=n(14),i=n(23);n(35)("getPrototypeOf",function(){return function(e){return i(r(e))}})},function(e,t,n){var r=n(5);n(35)("isExtensible",function(t){return function(e){return!!r(e)&&(!t||t(e))}})},function(e,t,n){var r=n(5);n(35)("isFrozen",function(t){return function(e){return!r(e)||!!t&&t(e)}})},function(e,t,n){var r=n(5);n(35)("isSealed",function(t){return function(e){return!r(e)||!!t&&t(e)}})},function(e,t,n){var r=n(0);r(r.S,"Object",{is:n(373)})},function(e,t,n){var r=n(14),i=n(53);n(35)("keys",function(){return function(e){return i(r(e))}})},function(e,t,n){var r=n(5),i=n(44).onFreeze;n(35)("preventExtensions",function(t){return function(e){return t&&r(e)?t(i(e)):e}})},function(e,t,n){var r=n(5),i=n(44).onFreeze;n(35)("seal",function(t){return function(e){return t&&r(e)?t(i(e)):e}})},function(e,t,n){var r=n(0);r(r.S,"Object",{setPrototypeOf:n(143).set})},function(e,t,n){"use strict";var r=n(71),i={};i[n(6)("toStringTag")]="z",i+""!="[object z]"&&n(20)(Object.prototype,"toString",function(){return"[object "+r(this)+"]"},!0)},function(e,t,n){var r=n(0),i=n(221);r(r.G+r.F*(parseFloat!=i),{parseFloat:i})},function(e,t,n){var r=n(0),i=n(222);r(r.G+r.F*(parseInt!=i),{parseInt:i})},function(e,t,n){"use strict";var r,i,o,a,s=n(50),u=n(3),c=n(28),l=n(71),f=n(0),d=n(5),h=n(15),p=n(48),v=n(49),g=n(99),y=n(149).set,_=n(141)(),m=n(142),b=n(223),E=n(224),w="Promise",P=u.TypeError,S=u.process,A=u[w],T="process"==l(S),x=function(){},O=i=m.f,R=!!function(){try{var e=A.resolve(1),t=(e.constructor={})[n(6)("species")]=function(e){e(x,x)};return(T||"function"==typeof PromiseRejectionEvent)&&e.then(x)instanceof t}catch(e){}}(),C=function(e){var t;return!(!d(e)||"function"!=typeof(t=e.then))&&t},k=function(c,n){if(!c._n){c._n=!0;var r=c._c;_(function(){for(var s=c._v,u=1==c._s,e=0,t=function(e){var t,n,r=u?e.ok:e.fail,i=e.resolve,o=e.reject,a=e.domain;try{r?(u||(2==c._h&&I(c),c._h=1),!0===r?t=s:(a&&a.enter(),t=r(s),a&&a.exit()),t===e.promise?o(P("Promise-chain cycle")):(n=C(t))?n.call(t,i,o):i(t)):o(s)}catch(e){o(e)}};r.length>e;)t(r[e++]);c._c=[],c._n=!1,n&&!c._h&&M(c)})}},M=function(o){y.call(u,function(){var e,t,n,r=o._v,i=L(o);if(i&&(e=b(function(){T?S.emit("unhandledRejection",r,o):(t=u.onunhandledrejection)?t({promise:o,reason:r}):(n=u.console)&&n.error&&n.error("Unhandled promise rejection",r)}),o._h=T||L(o)?2:1),o._a=void 0,i&&e.e)throw e.v})},L=function(e){return 1!==e._h&&0===(e._a||e._c).length},I=function(t){y.call(u,function(){var e;T?S.emit("rejectionHandled",t):(e=u.onrejectionhandled)&&e({promise:t,reason:t._v})})},N=function(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),k(t,!0))},F=function(e){var n,r=this;if(!r._d){r._d=!0,r=r._w||r;try{if(r===e)throw P("Promise can't be resolved itself");(n=C(e))?_(function(){var t={_w:r,_d:!1};try{n.call(e,c(F,t,1),c(N,t,1))}catch(e){N.call(t,e)}}):(r._v=e,r._s=1,k(r,!1))}catch(e){N.call({_w:r,_d:!1},e)}}};R||(A=function(e){p(this,A,w,"_h"),h(e),r.call(this);try{e(c(F,this,1),c(N,this,1))}catch(e){N.call(this,e)}},(r=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=n(55)(A.prototype,{then:function(e,t){var n=O(g(this,A));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=T?S.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&k(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),o=function(){var e=new r;this.promise=e,this.resolve=c(F,e,1),this.reject=c(N,e,1)},m.f=O=function(e){return e===A||e===a?new o(e):i(e)}),f(f.G+f.W+f.F*!R,{Promise:A}),n(64)(A,w),n(56)(w),a=n(33)[w],f(f.S+f.F*!R,w,{reject:function(e){var t=O(this);return(0,t.reject)(e),t.promise}}),f(f.S+f.F*(s||!R),w,{resolve:function(e){return E(s&&this===a?A:this,e)}}),f(f.S+f.F*!(R&&n(93)(function(e){A.all(e).catch(x)})),w,{all:function(e){var a=this,t=O(a),s=t.resolve,u=t.reject,n=b(function(){var r=[],i=0,o=1;v(e,!1,function(e){var t=i++,n=!1;r.push(void 0),o++,a.resolve(e).then(function(e){n||(n=!0,r[t]=e,--o||s(r))},u)}),--o||s(r)});return n.e&&u(n.v),t.promise},race:function(e){var t=this,n=O(t),r=n.reject,i=b(function(){v(e,!1,function(e){t.resolve(e).then(n.resolve,r)})});return i.e&&r(i.v),n.promise}})},function(e,t,n){var r=n(0),o=n(15),a=n(2),s=(n(3).Reflect||{}).apply,u=Function.apply;r(r.S+r.F*!n(4)(function(){s(function(){})}),"Reflect",{apply:function(e,t,n){var r=o(e),i=a(n);return s?s(r,t,i):u.call(r,t,i)}})},function(e,t,n){var r=n(0),s=n(51),u=n(15),c=n(2),l=n(5),i=n(4),f=n(202),d=(n(3).Reflect||{}).construct,h=i(function(){function e(){}return!(d(function(){},[],e)instanceof e)}),p=!i(function(){d(function(){})});r(r.S+r.F*(h||p),"Reflect",{construct:function(e,t){u(e),c(t);var n=arguments.length<3?e:u(arguments[2]);if(p&&!h)return d(e,t,n);if(e==n){switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3])}var r=[null];return r.push.apply(r,t),new(f.apply(e,r))}var i=n.prototype,o=s(l(i)?i:Object.prototype),a=Function.apply.call(e,o,t);return l(a)?a:o}})},function(e,t,n){var r=n(10),i=n(0),o=n(2),a=n(37);i(i.S+i.F*n(4)(function(){Reflect.defineProperty(r.f({},1,{value:1}),1,{value:2})}),"Reflect",{defineProperty:function(e,t,n){o(e),t=a(t,!0),o(n);try{return r.f(e,t,n),!0}catch(e){return!1}}})},function(e,t,n){var r=n(0),i=n(22).f,o=n(2);r(r.S,"Reflect",{deleteProperty:function(e,t){var n=i(o(e),t);return!(n&&!n.configurable)&&delete e[t]}})},function(e,t,n){"use strict";var r=n(0),i=n(2),o=function(e){this._t=i(e),this._i=0;var t,n=this._k=[];for(t in e)n.push(t)};n(137)(o,"Object",function(){var e,t=this._k;do{if(this._i>=t.length)return{value:void 0,done:!0}}while(!((e=t[this._i++])in this._t));return{value:e,done:!1}}),r(r.S,"Reflect",{enumerate:function(e){return new o(e)}})},function(e,t,n){var r=n(22),i=n(0),o=n(2);i(i.S,"Reflect",{getOwnPropertyDescriptor:function(e,t){return r.f(o(e),t)}})},function(e,t,n){var r=n(0),i=n(23),o=n(2);r(r.S,"Reflect",{getPrototypeOf:function(e){return i(o(e))}})},function(e,t,n){var a=n(22),s=n(23),u=n(18),r=n(0),c=n(5),l=n(2);r(r.S,"Reflect",{get:function e(t,n){var r,i,o=arguments.length<3?t:arguments[2];return l(t)===o?t[n]:(r=a.f(t,n))?u(r,"value")?r.value:void 0!==r.get?r.get.call(o):void 0:c(i=s(t))?e(i,n,o):void 0}})},function(e,t,n){var r=n(0);r(r.S,"Reflect",{has:function(e,t){return t in e}})},function(e,t,n){var r=n(0),i=n(2),o=Object.isExtensible;r(r.S,"Reflect",{isExtensible:function(e){return i(e),!o||o(e)}})},function(e,t,n){var r=n(0);r(r.S,"Reflect",{ownKeys:n(220)})},function(e,t,n){var r=n(0),i=n(2),o=Object.preventExtensions;r(r.S,"Reflect",{preventExtensions:function(e){i(e);try{return o&&o(e),!0}catch(e){return!1}}})},function(e,t,n){var r=n(0),i=n(143);i&&r(r.S,"Reflect",{setPrototypeOf:function(e,t){i.check(e,t);try{return i.set(e,t),!0}catch(e){return!1}}})},function(e,t,n){var u=n(10),c=n(22),l=n(23),f=n(18),r=n(0),d=n(54),h=n(2),p=n(5);r(r.S,"Reflect",{set:function e(t,n,r){var i,o,a=arguments.length<4?t:arguments[3],s=c.f(h(t),n);if(!s){if(p(o=l(t)))return e(o,n,r,a);s=d(0)}return f(s,"value")?!(!1===s.writable||!p(a)||((i=c.f(a,n)||d(0)).value=r,u.f(a,n,i),0)):void 0!==s.set&&(s.set.call(a,r),!0)}})},function(e,t,n){var r=n(3),o=n(135),i=n(10).f,a=n(52).f,s=n(92),u=n(90),c=r.RegExp,l=c,f=c.prototype,d=/a/g,h=/a/g,p=new c(d)!==d;if(n(9)&&(!p||n(4)(function(){return h[n(6)("match")]=!1,c(d)!=d||c(h)==h||"/a/i"!=c(d,"i")}))){c=function(e,t){var n=this instanceof c,r=s(e),i=void 0===t;return!n&&r&&e.constructor===c&&i?e:o(p?new l(r&&!i?e.source:e,t):l((r=e instanceof c)?e.source:e,r&&i?u.call(e):t),n?this:f,c)};for(var v=function(t){t in c||i(c,t,{configurable:!0,get:function(){return l[t]},set:function(e){l[t]=e}})},g=a(l),y=0;g.length>y;)v(g[y++]);(f.constructor=c).prototype=f,n(20)(r,"RegExp",c)}n(56)("RegExp")},function(e,t,n){n(89)("match",1,function(r,i,e){return[function(e){"use strict";var t=r(this),n=null==e?void 0:e[i];return void 0!==n?n.call(e,t):new RegExp(e)[i](String(t))},e]})},function(e,t,n){n(89)("replace",2,function(i,o,a){return[function(e,t){"use strict";var n=i(this),r=null==e?void 0:e[o];return void 0!==r?r.call(e,n,t):a.call(String(n),e,t)},a]})},function(e,t,n){n(89)("search",1,function(r,i,e){return[function(e){"use strict";var t=r(this),n=null==e?void 0:e[i];return void 0!==n?n.call(e,t):new RegExp(e)[i](String(t))},e]})},function(e,t,n){n(89)("split",2,function(i,o,a){"use strict";var h=n(92),p=a,v=[].push,e="split",g="length";if("c"=="abbc"[e](/(b)*/)[1]||4!="test"[e](/(?:)/,-1)[g]||2!="ab"[e](/(?:ab)*/)[g]||4!="."[e](/(.?)(.?)/)[g]||1<"."[e](/()()/)[g]||""[e](/.?/)[g]){var y=void 0===/()??/.exec("")[1];a=function(e,t){var n=String(this);if(void 0===e&&0===t)return[];if(!h(e))return p.call(n,e,t);var r,i,o,a,s,u=[],c=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),l=0,f=void 0===t?4294967295:t>>>0,d=new RegExp(e.source,c+"g");for(y||(r=new RegExp("^"+d.source+"$(?!\\s)",c));(i=d.exec(n))&&!(l<(o=i.index+i[0][g])&&(u.push(n.slice(l,i.index)),!y&&1<i[g]&&i[0].replace(r,function(){for(s=1;s<arguments[g]-2;s++)void 0===arguments[s]&&(i[s]=void 0)}),1<i[g]&&i.index<n[g]&&v.apply(u,i.slice(1)),a=i[0][g],l=o,u[g]>=f));)d.lastIndex===i.index&&d.lastIndex++;return l===n[g]?!a&&d.test("")||u.push(""):u.push(n.slice(l)),u[g]>f?u.slice(0,f):u}}else"0"[e](void 0,0)[g]&&(a=function(e,t){return void 0===e&&0===t?[]:p.call(this,e,t)});return[function(e,t){var n=i(this),r=null==e?void 0:e[o];return void 0!==r?r.call(e,n,t):a.call(String(n),e,t)},a]})},function(e,t,n){"use strict";n(229);var r=n(2),i=n(90),o=n(9),a="toString",s=/./[a],u=function(e){n(20)(RegExp.prototype,a,e,!0)};n(4)(function(){return"/a/b"!=s.call({source:"a",flags:"b"})})?u(function(){var e=r(this);return"/".concat(e.source,"/","flags"in e?e.flags:!o&&e instanceof RegExp?i.call(e):void 0)}):s.name!=a&&u(function(){return s.call(this)})},function(e,t,n){"use strict";n(21)("anchor",function(t){return function(e){return t(this,"a","name",e)}})},function(e,t,n){"use strict";n(21)("big",function(e){return function(){return e(this,"big","","")}})},function(e,t,n){"use strict";n(21)("blink",function(e){return function(){return e(this,"blink","","")}})},function(e,t,n){"use strict";n(21)("bold",function(e){return function(){return e(this,"b","","")}})},function(e,t,n){"use strict";var r=n(0),i=n(145)(!1);r(r.P,"String",{codePointAt:function(e){return i(this,e)}})},function(e,t,n){"use strict";var r=n(0),a=n(11),s=n(146),u="endsWith",c=""[u];r(r.P+r.F*n(133)(u),"String",{endsWith:function(e){var t=s(this,e,u),n=1<arguments.length?arguments[1]:void 0,r=a(t.length),i=void 0===n?r:Math.min(a(n),r),o=String(e);return c?c.call(t,o,i):t.slice(i-o.length,i)===o}})},function(e,t,n){"use strict";n(21)("fixed",function(e){return function(){return e(this,"tt","","")}})},function(e,t,n){"use strict";n(21)("fontcolor",function(t){return function(e){return t(this,"font","color",e)}})},function(e,t,n){"use strict";n(21)("fontsize",function(t){return function(e){return t(this,"font","size",e)}})},function(e,t,n){var r=n(0),o=n(57),a=String.fromCharCode,i=String.fromCodePoint;r(r.S+r.F*(!!i&&1!=i.length),"String",{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,i=0;i<r;){if(t=+arguments[i++],o(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?a(t):a(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){"use strict";var r=n(0),i=n(146);r(r.P+r.F*n(133)("includes"),"String",{includes:function(e){return!!~i(this,e,"includes").indexOf(e,1<arguments.length?arguments[1]:void 0)}})},function(e,t,n){"use strict";n(21)("italics",function(e){return function(){return e(this,"i","","")}})},function(e,t,n){"use strict";var r=n(145)(!0);n(138)(String,"String",function(e){this._t=String(e),this._i=0},function(){var e,t=this._t,n=this._i;return n>=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})})},function(e,t,n){"use strict";n(21)("link",function(t){return function(e){return t(this,"a","href",e)}})},function(e,t,n){var r=n(0),a=n(24),s=n(11);r(r.S,"String",{raw:function(e){for(var t=a(e.raw),n=s(t.length),r=arguments.length,i=[],o=0;o<n;)i.push(String(t[o++])),o<r&&i.push(String(arguments[o]));return i.join("")}})},function(e,t,n){var r=n(0);r(r.P,"String",{repeat:n(147)})},function(e,t,n){"use strict";n(21)("small",function(e){return function(){return e(this,"small","","")}})},function(e,t,n){"use strict";var r=n(0),i=n(11),o=n(146),a="startsWith",s=""[a];r(r.P+r.F*n(133)(a),"String",{startsWith:function(e){var t=o(this,e,a),n=i(Math.min(1<arguments.length?arguments[1]:void 0,t.length)),r=String(e);return s?s.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){"use strict";n(21)("strike",function(e){return function(){return e(this,"strike","","")}})},function(e,t,n){"use strict";n(21)("sub",function(e){return function(){return e(this,"sub","","")}})},function(e,t,n){"use strict";n(21)("sup",function(e){return function(){return e(this,"sup","","")}})},function(e,t,n){"use strict";n(65)("trim",function(e){return function(){return e(this,3)}})},function(e,t,n){"use strict";var r=n(3),a=n(18),i=n(9),o=n(0),s=n(20),u=n(44).KEY,c=n(4),l=n(98),f=n(64),d=n(58),h=n(6),p=n(227),v=n(152),g=n(371),y=n(91),_=n(2),m=n(5),b=n(24),E=n(37),w=n(54),P=n(51),S=n(217),A=n(22),T=n(10),x=n(53),O=A.f,R=T.f,C=S.f,k=r.Symbol,M=r.JSON,L=M&&M.stringify,I="prototype",N=h("_hidden"),F=h("toPrimitive"),j={}.propertyIsEnumerable,D=l("symbol-registry"),B=l("symbols"),U=l("op-symbols"),G=Object[I],V="function"==typeof k,z=r.QObject,W=!z||!z[I]||!z[I].findChild,X=i&&c(function(){return 7!=P(R({},"a",{get:function(){return R(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=O(G,t);r&&delete G[t],R(e,t,n),r&&e!==G&&R(G,t,r)}:R,H=function(e){var t=B[e]=P(k[I]);return t._k=e,t},Y=V&&"symbol"==typeof k.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof k},K=function(e,t,n){return e===G&&K(U,t,n),_(e),t=E(t,!0),_(n),a(B,t)?(n.enumerable?(a(e,N)&&e[N][t]&&(e[N][t]=!1),n=P(n,{enumerable:w(0,!1)})):(a(e,N)||R(e,N,w(1,{})),e[N][t]=!0),X(e,t,n)):R(e,t,n)},Z=function(e,t){_(e);for(var n,r=g(t=b(t)),i=0,o=r.length;i<o;)K(e,n=r[i++],t[n]);return e},q=function(e){var t=j.call(this,e=E(e,!0));return!(this===G&&a(B,e)&&!a(U,e))&&(!(t||!a(this,e)||!a(B,e)||a(this,N)&&this[N][e])||t)},Q=function(e,t){if(e=b(e),t=E(t,!0),e!==G||!a(B,t)||a(U,t)){var n=O(e,t);return!n||!a(B,t)||a(e,N)&&e[N][t]||(n.enumerable=!0),n}},J=function(e){for(var t,n=C(b(e)),r=[],i=0;n.length>i;)a(B,t=n[i++])||t==N||t==u||r.push(t);return r},$=function(e){for(var t,n=e===G,r=C(n?U:b(e)),i=[],o=0;r.length>o;)!a(B,t=r[o++])||n&&!a(G,t)||i.push(B[t]);return i};V||(s((k=function(){if(this instanceof k)throw TypeError("Symbol is not a constructor!");var t=d(0<arguments.length?arguments[0]:void 0),n=function(e){this===G&&n.call(U,e),a(this,N)&&a(this[N],t)&&(this[N][t]=!1),X(this,t,w(1,e))};return i&&W&&X(G,t,{configurable:!0,set:n}),H(t)})[I],"toString",function(){return this._k}),A.f=Q,T.f=K,n(52).f=S.f=J,n(73).f=q,n(95).f=$,i&&!n(50)&&s(G,"propertyIsEnumerable",q,!0),p.f=function(e){return H(h(e))}),o(o.G+o.W+o.F*!V,{Symbol:k});for(var ee="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),te=0;ee.length>te;)h(ee[te++]);for(var ne=x(h.store),re=0;ne.length>re;)v(ne[re++]);o(o.S+o.F*!V,"Symbol",{for:function(e){return a(D,e+="")?D[e]:D[e]=k(e)},keyFor:function(e){if(!Y(e))throw TypeError(e+" is not a symbol!");for(var t in D)if(D[t]===e)return t},useSetter:function(){W=!0},useSimple:function(){W=!1}}),o(o.S+o.F*!V,"Object",{create:function(e,t){return void 0===t?P(e):Z(P(e),t)},defineProperty:K,defineProperties:Z,getOwnPropertyDescriptor:Q,getOwnPropertyNames:J,getOwnPropertySymbols:$}),M&&o(o.S+o.F*(!V||c(function(){var e=k();return"[null]"!=L([e])||"{}"!=L({a:e})||"{}"!=L(Object(e))})),"JSON",{stringify:function(e){for(var t,n,r=[e],i=1;arguments.length>i;)r.push(arguments[i++]);if(n=t=r[1],(m(t)||void 0!==e)&&!Y(e))return y(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!Y(t))return t}),r[1]=t,L.apply(M,r)}}),k[I][F]||n(19)(k[I],F,k[I].valueOf),f(k,"Symbol"),f(Math,"Math",!0),f(r.JSON,"JSON",!0)},function(e,t,n){"use strict";var r=n(0),i=n(100),o=n(150),c=n(2),l=n(57),f=n(11),a=n(5),s=n(3).ArrayBuffer,d=n(99),h=o.ArrayBuffer,p=o.DataView,u=i.ABV&&s.isView,v=h.prototype.slice,g=i.VIEW,y="ArrayBuffer";r(r.G+r.W+r.F*(s!==h),{ArrayBuffer:h}),r(r.S+r.F*!i.CONSTR,y,{isView:function(e){return u&&u(e)||a(e)&&g in e}}),r(r.P+r.U+r.F*n(4)(function(){return!new h(2).slice(1,void 0).byteLength}),y,{slice:function(e,t){if(void 0!==v&&void 0===t)return v.call(c(this),e);for(var n=c(this).byteLength,r=l(e,n),i=l(void 0===t?n:t,n),o=new(d(this,h))(f(i-r)),a=new p(this),s=new p(o),u=0;r<i;)s.setUint8(u++,a.getUint8(r++));return o}}),n(56)(y)},function(e,t,n){var r=n(0);r(r.G+r.W+r.F*!n(100).ABV,{DataView:n(150).DataView})},function(e,t,n){n(40)("Float32",4,function(r){return function(e,t,n){return r(this,e,t,n)}})},function(e,t,n){n(40)("Float64",8,function(r){return function(e,t,n){return r(this,e,t,n)}})},function(e,t,n){n(40)("Int16",2,function(r){return function(e,t,n){return r(this,e,t,n)}})},function(e,t,n){n(40)("Int32",4,function(r){return function(e,t,n){return r(this,e,t,n)}})},function(e,t,n){n(40)("Int8",1,function(r){return function(e,t,n){return r(this,e,t,n)}})},function(e,t,n){n(40)("Uint16",2,function(r){return function(e,t,n){return r(this,e,t,n)}})},function(e,t,n){n(40)("Uint32",4,function(r){return function(e,t,n){return r(this,e,t,n)}})},function(e,t,n){n(40)("Uint8",1,function(r){return function(e,t,n){return r(this,e,t,n)}})},function(e,t,n){n(40)("Uint8",1,function(r){return function(e,t,n){return r(this,e,t,n)}},!0)},function(e,t,n){"use strict";var r=n(205),i=n(66);n(88)("WeakSet",function(e){return function(){return e(this,0<arguments.length?arguments[0]:void 0)}},{add:function(e){return r.def(i(this,"WeakSet"),e,!0)}},r,!1,!0)},function(e,t,n){"use strict";var r=n(0),i=n(206),o=n(14),a=n(11),s=n(15),u=n(129);r(r.P,"Array",{flatMap:function(e){var t,n,r=o(this);return s(e),t=a(r.length),n=u(r,0),i(n,r,r,t,0,1,e,arguments[1]),n}}),n(43)("flatMap")},function(e,t,n){"use strict";var r=n(0),i=n(206),o=n(14),a=n(11),s=n(36),u=n(129);r(r.P,"Array",{flatten:function(){var e=arguments[0],t=o(this),n=a(t.length),r=u(t,0);return i(r,t,t,n,0,void 0===e?1:s(e)),r}}),n(43)("flatten")},function(e,t,n){"use strict";var r=n(0),i=n(87)(!0);r(r.P,"Array",{includes:function(e){return i(this,e,1<arguments.length?arguments[1]:void 0)}}),n(43)("includes")},function(e,t,n){var r=n(0),i=n(141)(),o=n(3).process,a="process"==n(27)(o);r(r.G,{asap:function(e){var t=a&&o.domain;i(t?t.bind(e):e)}})},function(e,t,n){var r=n(0),i=n(27);r(r.S,"Error",{isError:function(e){return"Error"===i(e)}})},function(e,t,n){var r=n(0);r(r.G,{global:n(3)})},function(e,t,n){n(96)("Map")},function(e,t,n){n(97)("Map")},function(e,t,n){var r=n(0);r(r.P+r.R,"Map",{toJSON:n(204)("Map")})},function(e,t,n){var r=n(0);r(r.S,"Math",{clamp:function(e,t,n){return Math.min(n,Math.max(t,e))}})},function(e,t,n){var r=n(0);r(r.S,"Math",{DEG_PER_RAD:Math.PI/180})},function(e,t,n){var r=n(0),i=180/Math.PI;r(r.S,"Math",{degrees:function(e){return e*i}})},function(e,t,n){var r=n(0),o=n(214),a=n(212);r(r.S,"Math",{fscale:function(e,t,n,r,i){return a(o(e,t,n,r,i))}})},function(e,t,n){var r=n(0);r(r.S,"Math",{iaddh:function(e,t,n,r){var i=e>>>0,o=n>>>0;return(t>>>0)+(r>>>0)+((i&o|(i|o)&~(i+o>>>0))>>>31)|0}})},function(e,t,n){var r=n(0);r(r.S,"Math",{imulh:function(e,t){var n=+e,r=+t,i=65535&n,o=65535&r,a=n>>16,s=r>>16,u=(a*o>>>0)+(i*o>>>16);return a*s+(u>>16)+((i*s>>>0)+(65535&u)>>16)}})},function(e,t,n){var r=n(0);r(r.S,"Math",{isubh:function(e,t,n,r){var i=e>>>0,o=n>>>0;return(t>>>0)-(r>>>0)-((~i&o|~(i^o)&i-o>>>0)>>>31)|0}})},function(e,t,n){var r=n(0);r(r.S,"Math",{RAD_PER_DEG:180/Math.PI})},function(e,t,n){var r=n(0),i=Math.PI/180;r(r.S,"Math",{radians:function(e){return e*i}})},function(e,t,n){var r=n(0);r(r.S,"Math",{scale:n(214)})},function(e,t,n){var r=n(0);r(r.S,"Math",{signbit:function(e){return(e=+e)!=e?e:0==e?1/e==1/0:0<e}})},function(e,t,n){var r=n(0);r(r.S,"Math",{umulh:function(e,t){var n=+e,r=+t,i=65535&n,o=65535&r,a=n>>>16,s=r>>>16,u=(a*o>>>0)+(i*o>>>16);return a*s+(u>>>16)+((i*s>>>0)+(65535&u)>>>16)}})},function(e,t,n){"use strict";var r=n(0),i=n(14),o=n(15),a=n(10);n(9)&&r(r.P+n(94),"Object",{__defineGetter__:function(e,t){a.f(i(this),e,{get:o(t),enumerable:!0,configurable:!0})}})},function(e,t,n){"use strict";var r=n(0),i=n(14),o=n(15),a=n(10);n(9)&&r(r.P+n(94),"Object",{__defineSetter__:function(e,t){a.f(i(this),e,{set:o(t),enumerable:!0,configurable:!0})}})},function(e,t,n){var r=n(0),i=n(219)(!0);r(r.S,"Object",{entries:function(e){return i(e)}})},function(e,t,n){var r=n(0),u=n(220),c=n(24),l=n(22),f=n(130);r(r.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n,r=c(e),i=l.f,o=u(r),a={},s=0;o.length>s;)void 0!==(n=i(r,t=o[s++]))&&f(a,t,n);return a}})},function(e,t,n){"use strict";var r=n(0),i=n(14),o=n(37),a=n(23),s=n(22).f;n(9)&&r(r.P+n(94),"Object",{__lookupGetter__:function(e){var t,n=i(this),r=o(e,!0);do{if(t=s(n,r))return t.get}while(n=a(n))}})},function(e,t,n){"use strict";var r=n(0),i=n(14),o=n(37),a=n(23),s=n(22).f;n(9)&&r(r.P+n(94),"Object",{__lookupSetter__:function(e){var t,n=i(this),r=o(e,!0);do{if(t=s(n,r))return t.set}while(n=a(n))}})},function(e,t,n){var r=n(0),i=n(219)(!1);r(r.S,"Object",{values:function(e){return i(e)}})},function(e,t,n){"use strict";var r=n(0),o=n(3),a=n(33),i=n(141)(),s=n(6)("observable"),u=n(15),c=n(2),l=n(48),f=n(55),d=n(19),h=n(49),p=h.RETURN,v=function(e){return null==e?void 0:u(e)},g=function(e){var t=e._c;t&&(e._c=void 0,t())},y=function(e){return void 0===e._o},_=function(e){y(e)||(e._o=void 0,g(e))},m=function(t,e){c(t),this._c=void 0,this._o=t,t=new b(this);try{var n=e(t),r=n;null!=n&&("function"==typeof n.unsubscribe?n=function(){r.unsubscribe()}:u(n),this._c=n)}catch(e){return void t.error(e)}y(this)&&g(this)};m.prototype=f({},{unsubscribe:function(){_(this)}});var b=function(e){this._s=e};b.prototype=f({},{next:function(e){var t=this._s;if(!y(t)){var n=t._o;try{var r=v(n.next);if(r)return r.call(n,e)}catch(e){try{_(t)}finally{throw e}}}},error:function(e){var t=this._s;if(y(t))throw e;var n=t._o;t._o=void 0;try{var r=v(n.error);if(!r)throw e;e=r.call(n,e)}catch(e){try{g(t)}finally{throw e}}return g(t),e},complete:function(e){var t=this._s;if(!y(t)){var n=t._o;t._o=void 0;try{var r=v(n.complete);e=r?r.call(n,e):void 0}catch(e){try{g(t)}finally{throw e}}return g(t),e}}});var E=function(e){l(this,E,"Observable","_f")._f=u(e)};f(E.prototype,{subscribe:function(e){return new m(e,this._f)},forEach:function(r){var i=this;return new(a.Promise||o.Promise)(function(e,t){u(r);var n=i.subscribe({next:function(e){try{return r(e)}catch(e){t(e),n.unsubscribe()}},error:t,complete:e})})}}),f(E,{from:function(e){var t="function"==typeof this?this:E,n=v(c(e)[s]);if(n){var r=c(n.call(e));return r.constructor===t?r:new t(function(e){return r.subscribe(e)})}return new t(function(t){var n=!1;return i(function(){if(!n){try{if(h(e,!1,function(e){if(t.next(e),n)return p})===p)return}catch(e){if(n)throw e;return void t.error(e)}t.complete()}}),function(){n=!0}})},of:function(){for(var e=0,t=arguments.length,r=new Array(t);e<t;)r[e]=arguments[e++];return new("function"==typeof this?this:E)(function(t){var n=!1;return i(function(){if(!n){for(var e=0;e<r.length;++e)if(t.next(r[e]),n)return;t.complete()}}),function(){n=!0}})}}),d(E.prototype,s,function(){return this}),r(r.G,{Observable:E}),n(56)("Observable")},function(e,t,n){"use strict";var r=n(0),i=n(33),o=n(3),a=n(99),s=n(224);r(r.P+r.R,"Promise",{finally:function(t){var n=a(this,i.Promise||o.Promise),e="function"==typeof t;return this.then(e?function(e){return s(n,t()).then(function(){return e})}:t,e?function(e){return s(n,t()).then(function(){throw e})}:t)}})},function(e,t,n){"use strict";var r=n(0),i=n(142),o=n(223);r(r.S,"Promise",{try:function(e){var t=i.f(this),n=o(e);return(n.e?t.reject:t.resolve)(n.v),t.promise}})},function(e,t,n){var r=n(39),i=n(2),o=r.key,a=r.set;r.exp({defineMetadata:function(e,t,n,r){a(e,t,i(n),o(r))}})},function(e,t,n){var r=n(39),o=n(2),a=r.key,s=r.map,u=r.store;r.exp({deleteMetadata:function(e,t){var n=arguments.length<3?void 0:a(arguments[2]),r=s(o(t),n,!1);if(void 0===r||!r.delete(e))return!1;if(r.size)return!0;var i=u.get(t);return i.delete(n),!!i.size||u.delete(t)}})},function(e,t,n){var o=n(230),a=n(200),r=n(39),i=n(2),s=n(23),u=r.keys,c=r.key,l=function(e,t){var n=u(e,t),r=s(e);if(null===r)return n;var i=l(r,t);return i.length?n.length?a(new o(n.concat(i))):i:n};r.exp({getMetadataKeys:function(e){return l(i(e),arguments.length<2?void 0:c(arguments[1]))}})},function(e,t,n){var r=n(39),i=n(2),o=n(23),a=r.has,s=r.get,u=r.key,c=function(e,t,n){if(a(e,t,n))return s(e,t,n);var r=o(t);return null!==r?c(e,r,n):void 0};r.exp({getMetadata:function(e,t){return c(e,i(t),arguments.length<3?void 0:u(arguments[2]))}})},function(e,t,n){var r=n(39),i=n(2),o=r.keys,a=r.key;r.exp({getOwnMetadataKeys:function(e){return o(i(e),arguments.length<2?void 0:a(arguments[1]))}})},function(e,t,n){var r=n(39),i=n(2),o=r.get,a=r.key;r.exp({getOwnMetadata:function(e,t){return o(e,i(t),arguments.length<3?void 0:a(arguments[2]))}})},function(e,t,n){var r=n(39),i=n(2),o=n(23),a=r.has,s=r.key,u=function(e,t,n){if(a(e,t,n))return!0;var r=o(t);return null!==r&&u(e,r,n)};r.exp({hasMetadata:function(e,t){return u(e,i(t),arguments.length<3?void 0:s(arguments[2]))}})},function(e,t,n){var r=n(39),i=n(2),o=r.has,a=r.key;r.exp({hasOwnMetadata:function(e,t){return o(e,i(t),arguments.length<3?void 0:a(arguments[2]))}})},function(e,t,n){var r=n(39),i=n(2),o=n(15),a=r.key,s=r.set;r.exp({metadata:function(n,r){return function(e,t){s(n,r,(void 0!==t?i:o)(e),a(t))}}})},function(e,t,n){n(96)("Set")},function(e,t,n){n(97)("Set")},function(e,t,n){var r=n(0);r(r.P+r.R,"Set",{toJSON:n(204)("Set")})},function(e,t,n){"use strict";var r=n(0),i=n(145)(!0);r(r.P,"String",{at:function(e){return i(this,e)}})},function(e,t,n){"use strict";var r=n(0),i=n(34),o=n(11),a=n(92),s=n(90),u=RegExp.prototype,c=function(e,t){this._r=e,this._s=t};n(137)(c,"RegExp String",function(){var e=this._r.exec(this._s);return{value:e,done:null===e}}),r(r.P,"String",{matchAll:function(e){if(i(this),!a(e))throw TypeError(e+" is not a regexp!");var t=String(this),n="flags"in u?String(e.flags):s.call(e),r=new RegExp(e.source,~n.indexOf("g")?n:"g"+n);return r.lastIndex=o(e.lastIndex),new c(r,t)}})},function(e,t,n){"use strict";var r=n(0),i=n(225),o=n(151);r(r.P+r.F*/Version\/10\.\d+(\.\d+)? Safari\//.test(o),"String",{padEnd:function(e){return i(this,e,1<arguments.length?arguments[1]:void 0,!1)}})},function(e,t,n){"use strict";var r=n(0),i=n(225),o=n(151);r(r.P+r.F*/Version\/10\.\d+(\.\d+)? Safari\//.test(o),"String",{padStart:function(e){return i(this,e,1<arguments.length?arguments[1]:void 0,!0)}})},function(e,t,n){"use strict";n(65)("trimLeft",function(e){return function(){return e(this,1)}},"trimStart")},function(e,t,n){"use strict";n(65)("trimRight",function(e){return function(){return e(this,2)}},"trimEnd")},function(e,t,n){n(152)("asyncIterator")},function(e,t,n){n(152)("observable")},function(e,t,n){var r=n(0);r(r.S,"System",{global:n(3)})},function(e,t,n){n(96)("WeakMap")},function(e,t,n){n(97)("WeakMap")},function(e,t,n){n(96)("WeakSet")},function(e,t,n){n(97)("WeakSet")},function(e,t,n){for(var r=n(154),i=n(53),o=n(20),a=n(3),s=n(19),u=n(63),c=n(6),l=c("iterator"),f=c("toStringTag"),d=u.Array,h={CSSRuleList:!0,CSSStyleDeclaration:!1,CSSValueList:!1,ClientRectList:!1,DOMRectList:!1,DOMStringList:!1,DOMTokenList:!0,DataTransferItemList:!1,FileList:!1,HTMLAllCollection:!1,HTMLCollection:!1,HTMLFormElement:!1,HTMLSelectElement:!1,MediaList:!0,MimeTypeArray:!1,NamedNodeMap:!1,NodeList:!0,PaintRequestList:!1,Plugin:!1,PluginArray:!1,SVGLengthList:!1,SVGNumberList:!1,SVGPathSegList:!1,SVGPointList:!1,SVGStringList:!1,SVGTransformList:!1,SourceBufferList:!1,StyleSheetList:!0,TextTrackCueList:!1,TextTrackList:!1,TouchList:!1},p=i(h),v=0;v<p.length;v++){var g,y=p[v],_=h[y],m=a[y],b=m&&m.prototype;if(b&&(b[l]||s(b,l,d),b[f]||s(b,f,y),u[y]=d,_))for(g in r)b[g]||o(b,g,r[g],!0)}},function(e,t,n){var r=n(0),i=n(149);r(r.G+r.B,{setImmediate:i.set,clearImmediate:i.clear})},function(e,t,n){var r=n(3),i=n(0),o=n(151),a=[].slice,s=/MSIE .\./.test(o),u=function(i){return function(e,t){var n=2<arguments.length,r=!!n&&a.call(arguments,2);return i(n?function(){("function"==typeof e?e:Function(e)).apply(this,r)}:e,t)}};i(i.G+i.B+i.F*s,{setTimeout:u(r.setTimeout),setInterval:u(r.setInterval)})},function(e,t,n){n(494),n(433),n(435),n(434),n(437),n(439),n(444),n(438),n(436),n(446),n(445),n(441),n(442),n(440),n(432),n(443),n(447),n(448),n(400),n(402),n(401),n(450),n(449),n(420),n(430),n(431),n(421),n(422),n(423),n(424),n(425),n(426),n(427),n(428),n(429),n(403),n(404),n(405),n(406),n(407),n(408),n(409),n(410),n(411),n(412),n(413),n(414),n(415),n(416),n(417),n(418),n(419),n(481),n(486),n(493),n(484),n(476),n(477),n(482),n(487),n(489),n(472),n(473),n(474),n(475),n(478),n(479),n(480),n(483),n(485),n(488),n(490),n(491),n(492),n(395),n(397),n(396),n(399),n(398),n(384),n(382),n(388),n(385),n(391),n(393),n(381),n(387),n(378),n(392),n(376),n(390),n(389),n(383),n(386),n(375),n(377),n(380),n(379),n(394),n(154),n(466),n(471),n(229),n(467),n(468),n(469),n(470),n(451),n(228),n(230),n(231),n(506),n(495),n(496),n(501),n(504),n(505),n(499),n(502),n(500),n(503),n(497),n(498),n(452),n(453),n(454),n(455),n(456),n(459),n(457),n(458),n(460),n(461),n(462),n(463),n(465),n(464),n(509),n(507),n(508),n(550),n(553),n(552),n(554),n(555),n(551),n(556),n(557),n(531),n(534),n(530),n(528),n(529),n(532),n(533),n(515),n(549),n(514),n(548),n(560),n(562),n(513),n(547),n(559),n(561),n(512),n(558),n(511),n(516),n(517),n(518),n(519),n(520),n(522),n(521),n(523),n(524),n(525),n(527),n(526),n(536),n(537),n(538),n(539),n(541),n(540),n(543),n(542),n(544),n(545),n(546),n(510),n(535),n(565),n(564),n(563),e.exports=n(33)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(568);n.d(t,"hexbin",function(){return r.a})},function(e,t,n){"use strict";var i=Math.PI/3,l=[0,i,2*i,3*i,4*i,5*i];function f(e){return e[0]}function d(e){return e[1]}t.a=function(){var o,_,m,a=0,s=0,u=1,c=1,b=f,E=d;function n(e){var t,n={},r=[],i=e.length;for(t=0;t<i;++t)if(!isNaN(a=+b.call(null,o=e[t],t,e))&&!isNaN(s=+E.call(null,o,t,e))){var o,a,s,u=Math.round(s/=m),c=Math.round(a=a/_-(1&u)/2),l=s-u;if(1<3*Math.abs(l)){var f=a-c,d=c+(a<c?-1:1)/2,h=u+(s<u?-1:1),p=a-d,v=s-h;p*p+v*v<f*f+l*l&&(c=d+(1&u?1:-1)/2,u=h)}var g=c+"-"+u,y=n[g];y?y.push(o):(r.push(y=n[g]=[o]),y.x=(c+(1&u)/2)*_,y.y=u*m)}return r}function r(o){var a=0,s=0;return l.map(function(e){var t=Math.sin(e)*o,n=-Math.cos(e)*o,r=t-a,i=n-s;return a=t,s=n,[r,i]})}return n.hexagon=function(e){return"m"+r(null==e?o:+e).join("l")+"z"},n.centers=function(){for(var e=[],t=Math.round(s/m),n=Math.round(a/_),r=t*m;r<c+o;r+=m,++t)for(var i=n*_+(1&t)*_/2;i<u+_/2;i+=_)e.push([i,r]);return e},n.mesh=function(){var t=r(o).slice(0,4).join("l");return n.centers().map(function(e){return"M"+e+"m"+t}).join("")},n.x=function(e){return arguments.length?(b=e,n):b},n.y=function(e){return arguments.length?(E=e,n):E},n.radius=function(e){return arguments.length?(_=2*(o=+e)*Math.sin(i),m=1.5*o,n):o},n.size=function(e){return arguments.length?(a=s=0,u=+e[0],c=+e[1],n):[u-a,c-s]},n.extent=function(e){return arguments.length?(a=+e[0][0],s=+e[0][1],u=+e[1][0],c=+e[1][1],n):[[a,s],[u,c]]},n.radius(1)}},function(e,t){e.exports=function(e){var t=e[0],n=e[1],r=e[2],i=e[3],o=e[4],a=e[5],s=e[6],u=e[7],c=e[8],l=e[9],f=e[10],d=e[11],h=e[12],p=e[13],v=e[14],g=e[15];return(t*a-n*o)*(f*g-d*v)-(t*s-r*o)*(l*g-d*p)+(t*u-i*o)*(l*v-f*p)+(n*s-r*a)*(c*g-d*h)-(n*u-i*a)*(c*v-f*h)+(r*u-i*s)*(c*p-l*h)}},function(e,t){e.exports=function(e,t){var n=t[0],r=t[1],i=t[2],o=t[3],a=n+n,s=r+r,u=i+i,c=n*a,l=r*a,f=r*s,d=i*a,h=i*s,p=i*u,v=o*a,g=o*s,y=o*u;return e[0]=1-f-p,e[1]=l+y,e[2]=d-g,e[3]=0,e[4]=l-y,e[5]=1-c-p,e[6]=h+v,e[7]=0,e[8]=d+g,e[9]=h-v,e[10]=1-c-f,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}},function(e,t){e.exports=function(e,t,n,r,i,o,a){var s=1/(n-t),u=1/(i-r),c=1/(o-a);return e[0]=2*o*s,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=2*o*u,e[6]=0,e[7]=0,e[8]=(n+t)*s,e[9]=(i+r)*u,e[10]=(a+o)*c,e[11]=-1,e[12]=0,e[13]=0,e[14]=a*o*2*c,e[15]=0,e}},function(e,t){e.exports=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}},function(e,t){e.exports=function(e,t,n,r){var i,o,a,s,u,c,l,f,d,h,p,v,g,y,_,m,b,E,w,P,S,A,T,x,O=r[0],R=r[1],C=r[2],k=Math.sqrt(O*O+R*R+C*C);if(Math.abs(k)<1e-6)return null;O*=k=1/k,R*=k,C*=k,i=Math.sin(n),o=Math.cos(n),a=1-o,s=t[0],u=t[1],c=t[2],l=t[3],f=t[4],d=t[5],h=t[6],p=t[7],v=t[8],g=t[9],y=t[10],_=t[11],m=O*O*a+o,b=R*O*a+C*i,E=C*O*a-R*i,w=O*R*a-C*i,P=R*R*a+o,S=C*R*a+O*i,A=O*C*a+R*i,T=R*C*a-O*i,x=C*C*a+o,e[0]=s*m+f*b+v*E,e[1]=u*m+d*b+g*E,e[2]=c*m+h*b+y*E,e[3]=l*m+p*b+_*E,e[4]=s*w+f*P+v*S,e[5]=u*w+d*P+g*S,e[6]=c*w+h*P+y*S,e[7]=l*w+p*P+_*S,e[8]=s*A+f*T+v*x,e[9]=u*A+d*T+g*x,e[10]=c*A+h*T+y*x,e[11]=l*A+p*T+_*x,t!==e&&(e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]);return e}},function(e,t){e.exports=function(e,t){if(e===t){var n=t[1],r=t[2],i=t[3],o=t[6],a=t[7],s=t[11];e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=n,e[6]=t[9],e[7]=t[13],e[8]=r,e[9]=o,e[11]=t[14],e[12]=i,e[13]=a,e[14]=s}else e[0]=t[0],e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=t[1],e[5]=t[5],e[6]=t[9],e[7]=t[13],e[8]=t[2],e[9]=t[6],e[10]=t[10],e[11]=t[14],e[12]=t[3],e[13]=t[7],e[14]=t[11],e[15]=t[15];return e}},function(e,t,n){e.exports=n(243)},function(e,t){e.exports=function(e,t){var n=t[0],r=t[1],i=t[2];return e[0]=n,e[1]=r,e[2]=i,e[3]=Math.sqrt(Math.abs(1-n*n-r*r-i*i)),e}},function(e,t){e.exports=function(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e[3]=t[3],e}},function(e,t,n){e.exports=n(244)},function(e,t){e.exports=function(e,t){var n,r=t[0]+t[4]+t[8];if(0<r)n=Math.sqrt(r+1),e[3]=.5*n,n=.5/n,e[0]=(t[5]-t[7])*n,e[1]=(t[6]-t[2])*n,e[2]=(t[1]-t[3])*n;else{var i=0;t[4]>t[0]&&(i=1),t[8]>t[3*i+i]&&(i=2);var o=(i+1)%3,a=(i+2)%3;n=Math.sqrt(t[3*i+i]-t[3*o+o]-t[3*a+a]+1),e[i]=.5*n,n=.5/n,e[3]=(t[3*o+a]-t[3*a+o])*n,e[o]=(t[3*o+i]+t[3*i+o])*n,e[a]=(t[3*a+i]+t[3*i+a])*n}return e}},function(e,t){e.exports=function(e){return e[0]=0,e[1]=0,e[2]=0,e[3]=1,e}},function(e,t){e.exports=function(e,t){var n=t[0],r=t[1],i=t[2],o=t[3],a=n*n+r*r+i*i+o*o,s=a?1/a:0;return e[0]=-n*s,e[1]=-r*s,e[2]=-i*s,e[3]=o*s,e}},function(e,t,n){e.exports=n(619)},function(e,t,n){e.exports=n(245)},function(e,t){e.exports=function(e,t,n){var r=t[0],i=t[1],o=t[2],a=t[3],s=n[0],u=n[1],c=n[2],l=n[3];return e[0]=r*l+a*s+i*c-o*u,e[1]=i*l+a*u+o*s-r*c,e[2]=o*l+a*c+r*u-i*s,e[3]=a*l-r*s-i*u-o*c,e}},function(e,t){e.exports=function(e,t,n){n*=.5;var r=t[0],i=t[1],o=t[2],a=t[3],s=Math.sin(n),u=Math.cos(n);return e[0]=r*u+a*s,e[1]=i*u+o*s,e[2]=o*u-i*s,e[3]=a*u-r*s,e}},function(e,t){e.exports=function(e,t,n){n*=.5;var r=t[0],i=t[1],o=t[2],a=t[3],s=Math.sin(n),u=Math.cos(n);return e[0]=r*u-o*s,e[1]=i*u+a*s,e[2]=o*u+r*s,e[3]=a*u-i*s,e}},function(e,t){e.exports=function(e,t,n){n*=.5;var r=t[0],i=t[1],o=t[2],a=t[3],s=Math.sin(n),u=Math.cos(n);return e[0]=r*u+i*s,e[1]=i*u-r*s,e[2]=o*u+a*s,e[3]=a*u-o*s,e}},function(e,t,n){var i=n(240),o=n(239),a=n(241),s=n(242),u=n(236),c=n(237);e.exports=function(e,t,n){var r=i(t,n);return r<-.999999?(o(l,f,t),a(l)<1e-6&&o(l,d,t),s(l,l),c(e,l,Math.PI),e):.999999<r?(e[0]=0,e[1]=0,e[2]=0,e[3]=1,e):(o(l,t,n),e[0]=l[0],e[1]=l[1],e[2]=l[2],e[3]=1+r,u(e,e))};var l=[0,0,0],f=[1,0,0],d=[0,1,0]},function(e,t,n){e.exports=n(161)},function(e,t,n){e.exports=n(248)},function(e,t){e.exports=function(e,t,n,r){var i,o,a,s,u,c=t[0],l=t[1],f=t[2],d=t[3],h=n[0],p=n[1],v=n[2],g=n[3];(o=c*h+l*p+f*v+d*g)<0&&(o=-o,h=-h,p=-p,v=-v,g=-g);u=1e-6<1-o?(i=Math.acos(o),a=Math.sin(i),s=Math.sin((1-r)*i)/a,Math.sin(r*i)/a):(s=1-r,r);return e[0]=s*c+u*h,e[1]=s*l+u*p,e[2]=s*f+u*v,e[3]=s*d+u*g,e}},function(e,t,n){e.exports=n(622)},function(e,t){e.exports=function(e,t,n){var r=t[0]*n[1]-t[1]*n[0];return e[0]=e[1]=0,e[2]=r,e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e}},function(e,t){e.exports=function(e,t){return e[0]*t[0]+e[1]*t[1]}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e}},function(e,t){e.exports=function(e,t){var n=t[0],r=t[1],i=n*n+r*r;0<i&&(i=1/Math.sqrt(i),e[0]=t[0]*i,e[1]=t[1]*i);return e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}},function(e,t){e.exports=function(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e}},function(e,t){e.exports=function(e,t,n){return e[0]=t,e[1]=n,e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}},function(e,t){e.exports=function(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[4]*i+n[12],e[1]=n[1]*r+n[5]*i+n[13],e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e[2]=t[2]+n[2],e}},function(e,t,n){e.exports=function(e,t){var n=o(e[0],e[1],e[2]),r=o(t[0],t[1],t[2]);a(n,n),a(r,r);var i=s(n,r);return 1<i?0:Math.acos(i)};var o=n(606),a=n(242),s=n(240)},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e[2]=t[2]/n[2],e}},function(e,t){e.exports=function(e,t,n){var r=new Float32Array(3);return r[0]=e,r[1]=t,r[2]=n,r}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e[2]=t[2]*n[2],e}},function(e,t){e.exports=function(e,t,n,r){var i=[],o=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],o[0]=i[0],o[1]=i[1]*Math.cos(r)-i[2]*Math.sin(r),o[2]=i[1]*Math.sin(r)+i[2]*Math.cos(r),e[0]=o[0]+n[0],e[1]=o[1]+n[1],e[2]=o[2]+n[2],e}},function(e,t){e.exports=function(e,t,n,r){var i=[],o=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],o[0]=i[2]*Math.sin(r)+i[0]*Math.cos(r),o[1]=i[1],o[2]=i[2]*Math.cos(r)-i[0]*Math.sin(r),e[0]=o[0]+n[0],e[1]=o[1]+n[1],e[2]=o[2]+n[2],e}},function(e,t){e.exports=function(e,t,n,r){var i=[],o=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],o[0]=i[0]*Math.cos(r)-i[1]*Math.sin(r),o[1]=i[0]*Math.sin(r)+i[1]*Math.cos(r),o[2]=i[2],e[0]=o[0]+n[0],e[1]=o[1]+n[1],e[2]=o[2]+n[2],e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e}},function(e,t){e.exports=function(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e[2]=t[2]+n[2]*r,e}},function(e,t){e.exports=function(e,t,n,r){return e[0]=t,e[1]=n,e[2]=r,e}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e[2]=t[2]-n[2],e}},function(e,t){e.exports=function(e,t,n){var r=t[0],i=t[1],o=t[2],a=n[3]*r+n[7]*i+n[11]*o+n[15];return a=a||1,e[0]=(n[0]*r+n[4]*i+n[8]*o+n[12])/a,e[1]=(n[1]*r+n[5]*i+n[9]*o+n[13])/a,e[2]=(n[2]*r+n[6]*i+n[10]*o+n[14])/a,e}},function(e,t){e.exports=function(e,t){var n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2],o=t[3]-e[3];return Math.sqrt(n*n+r*r+i*i+o*o)}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e[2]=t[2]/n[2],e[3]=t[3]/n[3],e}},function(e,t){e.exports=function(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e[3]=1/t[3],e}},function(e,t){e.exports=function(e){var t=e[0],n=e[1],r=e[2],i=e[3];return Math.sqrt(t*t+n*n+r*r+i*i)}},function(e,t){e.exports=function(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e[3]=-t[3],e}},function(e,t){e.exports=function(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e[2]=t[2]+n[2]*r,e[3]=t[3]+n[3]*r,e}},function(e,t){e.exports=function(e){var t=e[0],n=e[1],r=e[2],i=e[3];return t*t+n*n+r*r+i*i}},function(e,t){e.exports=function(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e[2]=t[2]-n[2],e[3]=t[3]-n[3],e}},function(We,Xe,He){var Ye;!function(o,s,e,v){"use strict";var a,u=["","webkit","Moz","MS","ms","o"],t=s.createElement("div"),n="function",c=Math.round,g=Math.abs,y=Date.now;function l(e,t,n){return setTimeout(_(e,n),t)}function r(e,t,n){return!!Array.isArray(e)&&(f(e,n[t],n),!0)}function f(e,t,n){var r;if(e)if(e.forEach)e.forEach(t,n);else if(e.length!==v)for(r=0;r<e.length;)t.call(n,e[r],r,e),r++;else for(r in e)e.hasOwnProperty(r)&&t.call(n,e[r],r,e)}function i(r,e,t){var i="DEPRECATED METHOD: "+e+"\n"+t+" AT \n";return function(){var e=new Error("get-stack-trace"),t=e&&e.stack?e.stack.replace(/^[^\(]+?[\n$]/gm,"").replace(/^\s+at\s+/gm,"").replace(/^Object.<anonymous>\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",n=o.console&&(o.console.warn||o.console.log);return n&&n.call(o.console,i,t),r.apply(this,arguments)}}a="function"!=typeof Object.assign?function(e){if(e===v||null===e)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),n=1;n<arguments.length;n++){var r=arguments[n];if(r!==v&&null!==r)for(var i in r)r.hasOwnProperty(i)&&(t[i]=r[i])}return t}:Object.assign;var d=i(function(e,t,n){for(var r=Object.keys(t),i=0;i<r.length;)(!n||n&&e[r[i]]===v)&&(e[r[i]]=t[r[i]]),i++;return e},"extend","Use `assign`."),h=i(function(e,t){return d(e,t,!0)},"merge","Use `assign`.");function p(e,t,n){var r,i=t.prototype;(r=e.prototype=Object.create(i)).constructor=e,r._super=i,n&&a(r,n)}function _(e,t){return function(){return e.apply(t,arguments)}}function m(e,t){return typeof e==n?e.apply(t&&t[0]||v,t):e}function b(e,t){return e===v?t:e}function E(t,e,n){f(A(e),function(e){t.addEventListener(e,n,!1)})}function w(t,e,n){f(A(e),function(e){t.removeEventListener(e,n,!1)})}function P(e,t){for(;e;){if(e==t)return!0;e=e.parentNode}return!1}function S(e,t){return-1<e.indexOf(t)}function A(e){return e.trim().split(/\s+/g)}function T(e,t,n){if(e.indexOf&&!n)return e.indexOf(t);for(var r=0;r<e.length;){if(n&&e[r][n]==t||!n&&e[r]===t)return r;r++}return-1}function x(e){return Array.prototype.slice.call(e,0)}function O(e,n,t){for(var r=[],i=[],o=0;o<e.length;){var a=n?e[o][n]:e[o];T(i,a)<0&&r.push(e[o]),i[o]=a,o++}return t&&(r=n?r.sort(function(e,t){return e[n]>t[n]}):r.sort()),r}function R(e,t){for(var n,r,i=t[0].toUpperCase()+t.slice(1),o=0;o<u.length;){if((r=(n=u[o])?n+i:t)in e)return r;o++}return v}var C=1;function k(e){var t=e.ownerDocument||e;return t.defaultView||t.parentWindow||o}var M="ontouchstart"in o,L=R(o,"PointerEvent")!==v,I=M&&/mobile|tablet|ip(ad|hone|od)|android/i.test(navigator.userAgent),N="touch",F=25,j=1,D=4,B=8,U=1,G=2,V=4,z=8,W=16,X=G|V,H=z|W,Y=X|H,K=["x","y"],Z=["clientX","clientY"];function q(t,e){var n=this;this.manager=t,this.callback=e,this.element=t.element,this.target=t.options.inputTarget,this.domHandler=function(e){m(t.options.enable,[t])&&n.handler(e)},this.init()}function Q(e,t,n){var r=n.pointers.length,i=n.changedPointers.length,o=t&j&&r-i==0,a=t&(D|B)&&r-i==0;n.isFirst=!!o,n.isFinal=!!a,o&&(e.session={}),n.eventType=t,function(e,t){var n=e.session,r=t.pointers,i=r.length;n.firstInput||(n.firstInput=J(t));1<i&&!n.firstMultiple?n.firstMultiple=J(t):1===i&&(n.firstMultiple=!1);var o=n.firstInput,a=n.firstMultiple,s=a?a.center:o.center,u=t.center=$(r);t.timeStamp=y(),t.deltaTime=t.timeStamp-o.timeStamp,t.angle=re(s,u),t.distance=ne(s,u),function(e,t){var n=t.center,r=e.offsetDelta||{},i=e.prevDelta||{},o=e.prevInput||{};t.eventType!==j&&o.eventType!==D||(i=e.prevDelta={x:o.deltaX||0,y:o.deltaY||0},r=e.offsetDelta={x:n.x,y:n.y});t.deltaX=i.x+(n.x-r.x),t.deltaY=i.y+(n.y-r.y)}(n,t),t.offsetDirection=te(t.deltaX,t.deltaY);var c=ee(t.deltaTime,t.deltaX,t.deltaY);t.overallVelocityX=c.x,t.overallVelocityY=c.y,t.overallVelocity=g(c.x)>g(c.y)?c.x:c.y,t.scale=a?(d=a.pointers,h=r,ne(h[0],h[1],Z)/ne(d[0],d[1],Z)):1,t.rotation=a?(l=a.pointers,f=r,re(f[1],f[0],Z)+re(l[1],l[0],Z)):0,t.maxPointers=n.prevInput?t.pointers.length>n.prevInput.maxPointers?t.pointers.length:n.prevInput.maxPointers:t.pointers.length,function(e,t){var n,r,i,o,a=e.lastInterval||t,s=t.timeStamp-a.timeStamp;if(t.eventType!=B&&(F<s||a.velocity===v)){var u=t.deltaX-a.deltaX,c=t.deltaY-a.deltaY,l=ee(s,u,c);r=l.x,i=l.y,n=g(l.x)>g(l.y)?l.x:l.y,o=te(u,c),e.lastInterval=t}else n=a.velocity,r=a.velocityX,i=a.velocityY,o=a.direction;t.velocity=n,t.velocityX=r,t.velocityY=i,t.direction=o}(n,t);var l,f;var d,h;var p=e.element;P(t.srcEvent.target,p)&&(p=t.srcEvent.target);t.target=p}(e,n),e.emit("hammer.input",n),e.recognize(n),e.session.prevInput=n}function J(e){for(var t=[],n=0;n<e.pointers.length;)t[n]={clientX:c(e.pointers[n].clientX),clientY:c(e.pointers[n].clientY)},n++;return{timeStamp:y(),pointers:t,center:$(t),deltaX:e.deltaX,deltaY:e.deltaY}}function $(e){var t=e.length;if(1===t)return{x:c(e[0].clientX),y:c(e[0].clientY)};for(var n=0,r=0,i=0;i<t;)n+=e[i].clientX,r+=e[i].clientY,i++;return{x:c(n/t),y:c(r/t)}}function ee(e,t,n){return{x:t/e||0,y:n/e||0}}function te(e,t){return e===t?U:g(e)>=g(t)?e<0?G:V:t<0?z:W}function ne(e,t,n){n||(n=K);var r=t[n[0]]-e[n[0]],i=t[n[1]]-e[n[1]];return Math.sqrt(r*r+i*i)}function re(e,t,n){n||(n=K);var r=t[n[0]]-e[n[0]],i=t[n[1]]-e[n[1]];return 180*Math.atan2(i,r)/Math.PI}q.prototype={handler:function(){},init:function(){this.evEl&&E(this.element,this.evEl,this.domHandler),this.evTarget&&E(this.target,this.evTarget,this.domHandler),this.evWin&&E(k(this.element),this.evWin,this.domHandler)},destroy:function(){this.evEl&&w(this.element,this.evEl,this.domHandler),this.evTarget&&w(this.target,this.evTarget,this.domHandler),this.evWin&&w(k(this.element),this.evWin,this.domHandler)}};var ie={mousedown:j,mousemove:2,mouseup:D},oe="mousedown",ae="mousemove mouseup";function se(){this.evEl=oe,this.evWin=ae,this.pressed=!1,q.apply(this,arguments)}p(se,q,{handler:function(e){var t=ie[e.type];t&j&&0===e.button&&(this.pressed=!0),2&t&&1!==e.which&&(t=D),this.pressed&&(t&D&&(this.pressed=!1),this.callback(this.manager,t,{pointers:[e],changedPointers:[e],pointerType:"mouse",srcEvent:e}))}});var ue={pointerdown:j,pointermove:2,pointerup:D,pointercancel:B,pointerout:B},ce={2:N,3:"pen",4:"mouse",5:"kinect"},le="pointerdown",fe="pointermove pointerup pointercancel";function de(){this.evEl=le,this.evWin=fe,q.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}o.MSPointerEvent&&!o.PointerEvent&&(le="MSPointerDown",fe="MSPointerMove MSPointerUp MSPointerCancel"),p(de,q,{handler:function(e){var t=this.store,n=!1,r=e.type.toLowerCase().replace("ms",""),i=ue[r],o=ce[e.pointerType]||e.pointerType,a=o==N,s=T(t,e.pointerId,"pointerId");i&j&&(0===e.button||a)?s<0&&(t.push(e),s=t.length-1):i&(D|B)&&(n=!0),s<0||(t[s]=e,this.callback(this.manager,i,{pointers:t,changedPointers:[e],pointerType:o,srcEvent:e}),n&&t.splice(s,1))}});var he={touchstart:j,touchmove:2,touchend:D,touchcancel:B};function pe(){this.evTarget="touchstart",this.evWin="touchstart touchmove touchend touchcancel",this.started=!1,q.apply(this,arguments)}p(pe,q,{handler:function(e){var t=he[e.type];if(t===j&&(this.started=!0),this.started){var n=function(e,t){var n=x(e.touches),r=x(e.changedTouches);t&(D|B)&&(n=O(n.concat(r),"identifier",!0));return[n,r]}.call(this,e,t);t&(D|B)&&n[0].length-n[1].length==0&&(this.started=!1),this.callback(this.manager,t,{pointers:n[0],changedPointers:n[1],pointerType:N,srcEvent:e})}}});var ve={touchstart:j,touchmove:2,touchend:D,touchcancel:B},ge="touchstart touchmove touchend touchcancel";function ye(){this.evTarget=ge,this.targetIds={},q.apply(this,arguments)}p(ye,q,{handler:function(e){var t=ve[e.type],n=function(e,t){var n=x(e.touches),r=this.targetIds;if(t&(2|j)&&1===n.length)return r[n[0].identifier]=!0,[n,n];var i,o,a=x(e.changedTouches),s=[],u=this.target;if(o=n.filter(function(e){return P(e.target,u)}),t===j)for(i=0;i<o.length;)r[o[i].identifier]=!0,i++;i=0;for(;i<a.length;)r[a[i].identifier]&&s.push(a[i]),t&(D|B)&&delete r[a[i].identifier],i++;return s.length?[O(o.concat(s),"identifier",!0),s]:void 0}.call(this,e,t);n&&this.callback(this.manager,t,{pointers:n[0],changedPointers:n[1],pointerType:N,srcEvent:e})}});var _e=2500;function me(){q.apply(this,arguments);var e=_(this.handler,this);this.touch=new ye(this.manager,e),this.mouse=new se(this.manager,e),this.primaryTouch=null,this.lastTouches=[]}function be(e){var t=e.changedPointers[0];if(t.identifier===this.primaryTouch){var n={x:t.clientX,y:t.clientY};this.lastTouches.push(n);var r=this.lastTouches;setTimeout(function(){var e=r.indexOf(n);-1<e&&r.splice(e,1)},_e)}}p(me,q,{handler:function(e,t,n){var r=n.pointerType==N,i="mouse"==n.pointerType;if(!(i&&n.sourceCapabilities&&n.sourceCapabilities.firesTouchEvents)){if(r)(function(e,t){e&j?(this.primaryTouch=t.changedPointers[0].identifier,be.call(this,t)):e&(D|B)&&be.call(this,t)}).call(this,t,n);else if(i&&function(e){for(var t=e.srcEvent.clientX,n=e.srcEvent.clientY,r=0;r<this.lastTouches.length;r++){var i=this.lastTouches[r],o=Math.abs(t-i.x),a=Math.abs(n-i.y);if(o<=25&&a<=25)return!0}return!1}.call(this,n))return;this.callback(e,t,n)}},destroy:function(){this.touch.destroy(),this.mouse.destroy()}});var Ee=R(t.style,"touchAction"),we=Ee!==v,Pe="manipulation",Se="none",Ae="pan-x",Te="pan-y",xe=function(){if(!we)return!1;var t={},n=o.CSS&&o.CSS.supports;return["auto","manipulation","pan-y","pan-x","pan-x pan-y","none"].forEach(function(e){t[e]=!n||o.CSS.supports("touch-action",e)}),t}();function Oe(e,t){this.manager=e,this.set(t)}Oe.prototype={set:function(e){"compute"==e&&(e=this.compute()),we&&this.manager.element.style&&xe[e]&&(this.manager.element.style[Ee]=e),this.actions=e.toLowerCase().trim()},update:function(){this.set(this.manager.options.touchAction)},compute:function(){var t=[];return f(this.manager.recognizers,function(e){m(e.options.enable,[e])&&(t=t.concat(e.getTouchAction()))}),function(e){if(S(e,Se))return Se;var t=S(e,Ae),n=S(e,Te);if(t&&n)return Se;if(t||n)return t?Ae:Te;if(S(e,Pe))return Pe;return"auto"}(t.join(" "))},preventDefaults:function(e){var t=e.srcEvent,n=e.offsetDirection;if(this.manager.session.prevented)t.preventDefault();else{var r=this.actions,i=S(r,Se)&&!xe.none,o=S(r,Te)&&!xe[Te],a=S(r,Ae)&&!xe[Ae];if(i){var s=1===e.pointers.length,u=e.distance<2,c=e.deltaTime<250;if(s&&u&&c)return}if(!a||!o)return i||o&&n&X||a&&n&H?this.preventSrc(t):void 0}},preventSrc:function(e){this.manager.session.prevented=!0,e.preventDefault()}};var Re=1;function Ce(e){this.options=a({},this.defaults,e||{}),this.id=C++,this.manager=null,this.options.enable=b(this.options.enable,!0),this.state=Re,this.simultaneous={},this.requireFail=[]}function ke(e){return 16&e?"cancel":8&e?"end":4&e?"move":2&e?"start":""}function Me(e){return e==W?"down":e==z?"up":e==G?"left":e==V?"right":""}function Le(e,t){var n=t.manager;return n?n.get(e):e}function Ie(){Ce.apply(this,arguments)}function Ne(){Ie.apply(this,arguments),this.pX=null,this.pY=null}function Fe(){Ie.apply(this,arguments)}function je(){Ce.apply(this,arguments),this._timer=null,this._input=null}function De(){Ie.apply(this,arguments)}function Be(){Ie.apply(this,arguments)}function Ue(){Ce.apply(this,arguments),this.pTime=!1,this.pCenter=!1,this._timer=null,this._input=null,this.count=0}function Ge(e,t){return(t=t||{}).recognizers=b(t.recognizers,Ge.defaults.preset),new Ve(e,t)}Ce.prototype={defaults:{},set:function(e){return a(this.options,e),this.manager&&this.manager.touchAction.update(),this},recognizeWith:function(e){if(r(e,"recognizeWith",this))return this;var t=this.simultaneous;return t[(e=Le(e,this)).id]||(t[e.id]=e).recognizeWith(this),this},dropRecognizeWith:function(e){return r(e,"dropRecognizeWith",this)||(e=Le(e,this),delete this.simultaneous[e.id]),this},requireFailure:function(e){if(r(e,"requireFailure",this))return this;var t=this.requireFail;return-1===T(t,e=Le(e,this))&&(t.push(e),e.requireFailure(this)),this},dropRequireFailure:function(e){if(r(e,"dropRequireFailure",this))return this;e=Le(e,this);var t=T(this.requireFail,e);return-1<t&&this.requireFail.splice(t,1),this},hasRequireFailures:function(){return 0<this.requireFail.length},canRecognizeWith:function(e){return!!this.simultaneous[e.id]},emit:function(t){var n=this,e=this.state;function r(e){n.manager.emit(e,t)}e<8&&r(n.options.event+ke(e)),r(n.options.event),t.additionalEvent&&r(t.additionalEvent),8<=e&&r(n.options.event+ke(e))},tryEmit:function(e){if(this.canEmit())return this.emit(e);this.state=32},canEmit:function(){for(var e=0;e<this.requireFail.length;){if(!(this.requireFail[e].state&(32|Re)))return!1;e++}return!0},recognize:function(e){var t=a({},e);if(!m(this.options.enable,[this,t]))return this.reset(),void(this.state=32);56&this.state&&(this.state=Re),this.state=this.process(t),30&this.state&&this.tryEmit(t)},process:function(e){},getTouchAction:function(){},reset:function(){}},p(Ie,Ce,{defaults:{pointers:1},attrTest:function(e){var t=this.options.pointers;return 0===t||e.pointers.length===t},process:function(e){var t=this.state,n=e.eventType,r=6&t,i=this.attrTest(e);return r&&(n&B||!i)?16|t:r||i?n&D?8|t:2&t?4|t:2:32}}),p(Ne,Ie,{defaults:{event:"pan",threshold:10,pointers:1,direction:Y},getTouchAction:function(){var e=this.options.direction,t=[];return e&X&&t.push(Te),e&H&&t.push(Ae),t},directionTest:function(e){var t=this.options,n=!0,r=e.distance,i=e.direction,o=e.deltaX,a=e.deltaY;return i&t.direction||(r=t.direction&X?(i=0===o?U:o<0?G:V,n=o!=this.pX,Math.abs(e.deltaX)):(i=0===a?U:a<0?z:W,n=a!=this.pY,Math.abs(e.deltaY))),e.direction=i,n&&r>t.threshold&&i&t.direction},attrTest:function(e){return Ie.prototype.attrTest.call(this,e)&&(2&this.state||!(2&this.state)&&this.directionTest(e))},emit:function(e){this.pX=e.deltaX,this.pY=e.deltaY;var t=Me(e.direction);t&&(e.additionalEvent=this.options.event+t),this._super.emit.call(this,e)}}),p(Fe,Ie,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[Se]},attrTest:function(e){return this._super.attrTest.call(this,e)&&(Math.abs(e.scale-1)>this.options.threshold||2&this.state)},emit:function(e){if(1!==e.scale){var t=e.scale<1?"in":"out";e.additionalEvent=this.options.event+t}this._super.emit.call(this,e)}}),p(je,Ce,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return["auto"]},process:function(e){var t=this.options,n=e.pointers.length===t.pointers,r=e.distance<t.threshold,i=e.deltaTime>t.time;if(this._input=e,!r||!n||e.eventType&(D|B)&&!i)this.reset();else if(e.eventType&j)this.reset(),this._timer=l(function(){this.state=8,this.tryEmit()},t.time,this);else if(e.eventType&D)return 8;return 32},reset:function(){clearTimeout(this._timer)},emit:function(e){8===this.state&&(e&&e.eventType&D?this.manager.emit(this.options.event+"up",e):(this._input.timeStamp=y(),this.manager.emit(this.options.event,this._input)))}}),p(De,Ie,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[Se]},attrTest:function(e){return this._super.attrTest.call(this,e)&&(Math.abs(e.rotation)>this.options.threshold||2&this.state)}}),p(Be,Ie,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:X|H,pointers:1},getTouchAction:function(){return Ne.prototype.getTouchAction.call(this)},attrTest:function(e){var t,n=this.options.direction;return n&(X|H)?t=e.overallVelocity:n&X?t=e.overallVelocityX:n&H&&(t=e.overallVelocityY),this._super.attrTest.call(this,e)&&n&e.offsetDirection&&e.distance>this.options.threshold&&e.maxPointers==this.options.pointers&&g(t)>this.options.velocity&&e.eventType&D},emit:function(e){var t=Me(e.offsetDirection);t&&this.manager.emit(this.options.event+t,e),this.manager.emit(this.options.event,e)}}),p(Ue,Ce,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[Pe]},process:function(e){var t=this.options,n=e.pointers.length===t.pointers,r=e.distance<t.threshold,i=e.deltaTime<t.time;if(this.reset(),e.eventType&j&&0===this.count)return this.failTimeout();if(r&&i&&n){if(e.eventType!=D)return this.failTimeout();var o=!this.pTime||e.timeStamp-this.pTime<t.interval,a=!this.pCenter||ne(this.pCenter,e.center)<t.posThreshold;if(this.pTime=e.timeStamp,this.pCenter=e.center,a&&o?this.count+=1:this.count=1,this._input=e,0===this.count%t.taps)return this.hasRequireFailures()?(this._timer=l(function(){this.state=8,this.tryEmit()},t.interval,this),2):8}return 32},failTimeout:function(){return this._timer=l(function(){this.state=32},this.options.interval,this),32},reset:function(){clearTimeout(this._timer)},emit:function(){8==this.state&&(this._input.tapCount=this.count,this.manager.emit(this.options.event,this._input))}}),Ge.VERSION="2.0.7",Ge.defaults={domEvents:!1,touchAction:"compute",enable:!0,inputTarget:null,inputClass:null,preset:[[De,{enable:!1}],[Fe,{enable:!1},["rotate"]],[Be,{direction:X}],[Ne,{direction:X},["swipe"]],[Ue],[Ue,{event:"doubletap",taps:2},["tap"]],[je]],cssProps:{userSelect:"none",touchSelect:"none",touchCallout:"none",contentZooming:"none",userDrag:"none",tapHighlightColor:"rgba(0,0,0,0)"}};function Ve(e,t){var n;this.options=a({},Ge.defaults,t||{}),this.options.inputTarget=this.options.inputTarget||e,this.handlers={},this.session={},this.recognizers=[],this.oldCssProps={},this.element=e,this.input=new((n=this).options.inputClass||(L?de:I?ye:M?me:se))(n,Q),this.touchAction=new Oe(this,this.options.touchAction),ze(this,!0),f(this.options.recognizers,function(e){var t=this.add(new e[0](e[1]));e[2]&&t.recognizeWith(e[2]),e[3]&&t.requireFailure(e[3])},this)}function ze(n,r){var i,o=n.element;o.style&&(f(n.options.cssProps,function(e,t){i=R(o.style,t),o.style[i]=r?(n.oldCssProps[i]=o.style[i],e):n.oldCssProps[i]||""}),r||(n.oldCssProps={}))}Ve.prototype={set:function(e){return a(this.options,e),e.touchAction&&this.touchAction.update(),e.inputTarget&&(this.input.destroy(),this.input.target=e.inputTarget,this.input.init()),this},stop:function(e){this.session.stopped=e?2:1},recognize:function(e){var t=this.session;if(!t.stopped){var n;this.touchAction.preventDefaults(e);var r=this.recognizers,i=t.curRecognizer;(!i||i&&8&i.state)&&(i=t.curRecognizer=null);for(var o=0;o<r.length;)n=r[o],2===t.stopped||i&&n!=i&&!n.canRecognizeWith(i)?n.reset():n.recognize(e),!i&&14&n.state&&(i=t.curRecognizer=n),o++}},get:function(e){if(e instanceof Ce)return e;for(var t=this.recognizers,n=0;n<t.length;n++)if(t[n].options.event==e)return t[n];return null},add:function(e){if(r(e,"add",this))return this;var t=this.get(e.options.event);return t&&this.remove(t),this.recognizers.push(e),(e.manager=this).touchAction.update(),e},remove:function(e){if(r(e,"remove",this))return this;if(e=this.get(e)){var t=this.recognizers,n=T(t,e);-1!==n&&(t.splice(n,1),this.touchAction.update())}return this},on:function(e,t){if(e!==v&&t!==v){var n=this.handlers;return f(A(e),function(e){n[e]=n[e]||[],n[e].push(t)}),this}},off:function(e,t){if(e!==v){var n=this.handlers;return f(A(e),function(e){t?n[e]&&n[e].splice(T(n[e],t),1):delete n[e]}),this}},emit:function(e,t){var n,r,i;this.options.domEvents&&(n=e,r=t,(i=s.createEvent("Event")).initEvent(n,!0,!0),(i.gesture=r).target.dispatchEvent(i));var o=this.handlers[e]&&this.handlers[e].slice();if(o&&o.length){t.type=e,t.preventDefault=function(){t.srcEvent.preventDefault()};for(var a=0;a<o.length;)o[a](t),a++}},destroy:function(){this.element&&ze(this,!1),this.handlers={},this.session={},this.input.destroy(),this.element=null}},a(Ge,{INPUT_START:j,INPUT_MOVE:2,INPUT_END:D,INPUT_CANCEL:B,STATE_POSSIBLE:Re,STATE_BEGAN:2,STATE_CHANGED:4,STATE_ENDED:8,STATE_RECOGNIZED:8,STATE_CANCELLED:16,STATE_FAILED:32,DIRECTION_NONE:U,DIRECTION_LEFT:G,DIRECTION_RIGHT:V,DIRECTION_UP:z,DIRECTION_DOWN:W,DIRECTION_HORIZONTAL:X,DIRECTION_VERTICAL:H,DIRECTION_ALL:Y,Manager:Ve,Input:q,TouchAction:Oe,TouchInput:ye,MouseInput:se,PointerEventInput:de,TouchMouseInput:me,SingleTouchInput:pe,Recognizer:Ce,AttrRecognizer:Ie,Tap:Ue,Pan:Ne,Swipe:Be,Pinch:Fe,Rotate:De,Press:je,on:E,off:w,each:f,merge:h,extend:d,assign:a,inherit:p,bindFn:_,prefixed:R}),(void 0!==o?o:"undefined"!=typeof self?self:{}).Hammer=Ge,(Ye=function(){return Ge}.call(Xe,He,Xe,We))===v||(We.exports=Ye)}(window,document)},function(e,t,n){"use strict";var i=n(250),d=n(16),r=n(1),o=n.n(r),a=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function c(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var s=function(e){function f(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f);var t=e.children,n=void 0===t?[]:t;n.every(function(e){return o()(e instanceof i.a)});var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,e));return r.children=n,r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(f,i["a"]),a(f,[{key:"add",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){var u=a.value;Array.isArray(u)?this.add.apply(this,c(u)):this.children.push(u)}}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return this}},{key:"remove",value:function(e){var t=this.children,n=t.indexOf(e);return-1<n&&t.splice(n,1),this}},{key:"removeAll",value:function(){return this.children=[],this}},{key:"traverse",value:function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).modelMatrix,n=void 0===t?new d.Matrix4:t,r=!0,i=!1,o=void 0;try{for(var a,s=this.children[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){var u=a.value,c=u.matrix;n=n.multiplyRight(c);var l=void 0;if(l=u instanceof f?u.traverse(e,{modelMatrix:n}):e(u,{}))return l}}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return null}},{key:"traverseReverse",value:function(e){for(var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).modelMatrix,n=void 0===t?new d.Matrix4:t,r=this.children.length-1;0<=r;--r){var i=this.children[r],o=i.matrix;n=n.multiplyRight(o);var a=void 0;if(a=i instanceof f?i.traverseReverse(e,{modelMatrix:n}):e(i,{}))return a}return null}}]),f}();t.a=s},function(e,t,b){"use strict";t.a=function(r,e){var t=e.models,n=e.position,i=e.uniforms,o=void 0===i?{}:i,a=e.parameters,s=void 0===a?{}:a,u=e.settings,c=e.useDevicePixelRatio,l=void 0===c?null:c,f=e.useDevicePixels,d=void 0===f||f,h=e.framebuffer;S()(b.i(E.isWebGL)(r),T),S()(h,T),S()(n,T),null!==l&&(w.b.deprecated("useDevicePixelRatio","useDevicePixels"),d=l);var p=A(n,2),v=p[0],g=p[1];h.resize({width:r.canvas.width,height:r.canvas.height});var y=d&&"undefined"!=typeof window?window.devicePixelRatio:1,_=v*y,m=r.canvas.height-g*y;return new P.a({children:t}).traverseReverse(function(e){if(e.isPickable()){b.i(E.clear)(r,{framebuffer:h,color:!0,depth:!0}),e.setUniforms({picking_uActive:1}),e.draw({uniforms:o,parameters:s,settings:u,framebuffer:h}),e.setUniforms({picking_uActive:0});var t=h.readPixels({x:_,y:m,width:1,height:1,format:r.RGBA,type:r.UNSIGNED_BYTE}),n=0!==t[0]||0!==t[1]||0!==t[2];if(n)return{model:e,color:t,x:v,y:g,deviceX:_,deviceY:m}}return null})};var E=b(61),w=b(8),P=b(625),n=b(1),S=b.n(n),A=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},T="Illegal argument to pick"},function(e,t,n){"use strict";t.a=function(e){return[e+1&255,e+1>>8&255,e+1>>16&255]},t.b=function(e){var t=o(e,3),n=t[0],r=t[1],i=t[2];return n+256*r+65536*i-1},t.c=function(){return r};var o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=new Uint8Array([0,0,0])},function(e,t,n){"use strict";n.d(t,"b",function(){return o}),n.d(t,"d",function(){return a}),n.d(t,"a",function(){return c}),n.d(t,"c",function(){return d});var r=n(173),i=n.n(r),s=n(261),u={},o=function(e){u[e.id]||(u[e.id]=e,i.a.listItem("luma.gl",e.id))},a=function(e,t){if(i.a.isReady()&&!i.a.throttle("luma.gl:"+e.id,1e3)){var n=Object.assign({},e.geometry.attributes,e.attributes),r=Object.assign({},e.uniforms,t);i.a.multiUpdate("luma.gl",e.id,[{path:"objects.uniforms",data:r},{path:"objects.attributes",data:n}])}},c=function(e){delete u[e],i.a.deleteItem("luma.gl",e)},l=function e(t,n,r){t&&(1<n.length?e(t[n[0]],n.slice(1),r):t[n[0]]=r)},f=new Map,d=function(e,n){if(s.a.__SEER_INITIALIZED__&&e){var t=f.get(e);t&&t.forEach(function(e,t){l(n,t,e)})}};i.a.listenFor("luma.gl",function(e){var t=u[e.itemKey];if(t&&"edit"===e.type&&"uniforms"===e.valuePath[0]){var n,r,i,o=e.valuePath.slice(1);n=e.itemKey,r=o,i=e.value,s.a.__SEER_INITIALIZED__&&(f.has(n)||f.set(n,new Map),f.get(n).set(r,i));var a=t.getUniforms();l(a,o,e.value),t.setUniforms(a)}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function P(){}t.requestFile=function(e){return new i(e).sendAsync()};var l=4,i=function(){function w(e){var t=e.url,n=e.path,r=void 0===n?null:n,i=e.method,o=void 0===i?"GET":i,a=e.asynchronous,s=void 0===a||a,u=e.noCache,c=void 0!==u&&u,l=e.sendAsBinary,f=void 0!==l&&l,d=e.responseType,h=void 0!==d&&d,p=e.onProgress,v=void 0===p?P:p,g=e.onError,y=void 0===g?P:g,_=e.onAbort,m=void 0===_?P:_,b=e.onComplete,E=void 0===b?P:b;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,w),this.url=r?r.join(r,t):t,this.method=o,this.async=s,this.noCache=c,this.sendAsBinary=f,this.responseType=h,this.req=new XMLHttpRequest,this.req.onload=function(e){return E(e)},this.req.onerror=function(e){return y(e)},this.req.onabort=function(e){return m(e)},this.req.onprogress=function(e){e.lengthComputable?v(e,Math.round(e.loaded/e.total*100)):v(e,-1)}}return r(w,[{key:"setRequestHeader",value:function(e,t){return this.req.setRequestHeader(e,t),this}},{key:"sendAsync",value:function(){var u=this,c=0<arguments.length&&void 0!==arguments[0]?arguments[0]:this.body||null;return new Promise(function(t,n){try{var r=u.req,e=u.method,i=u.noCache,o=u.sendAsBinary,a=u.responseType,s=i?u.url+(0<=u.url.indexOf("?")?"&":"?")+Date.now():u.url;r.open(e,s,u.async),a&&(r.responseType=a),u.async&&(r.onreadystatechange=function(e){r.readyState===l&&(200===r.status?t(r.responseType?r.response:r.responseText):n(new Error(r.status+": "+s)))}),o?r.sendAsBinary(c):r.send(c),u.async||(200===r.status?t(r.responseType?r.response:r.responseText):n(new Error(r.status+": "+s)))}catch(e){n(e)}})}}]),w}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(257);Object.defineProperty(t,"setPathPrefix",{enumerable:!0,get:function(){return r.setPathPrefix}}),Object.defineProperty(t,"loadFile",{enumerable:!0,get:function(){return r.loadFile}}),Object.defineProperty(t,"loadImage",{enumerable:!0,get:function(){return r.loadImage}});var i=n(631);Object.defineProperty(t,"loadFiles",{enumerable:!0,get:function(){return i.loadFiles}}),Object.defineProperty(t,"loadImages",{enumerable:!0,get:function(){return i.loadImages}}),Object.defineProperty(t,"loadTextures",{enumerable:!0,get:function(){return i.loadTextures}}),Object.defineProperty(t,"loadProgram",{enumerable:!0,get:function(){return i.loadProgram}}),Object.defineProperty(t,"loadModel",{enumerable:!0,get:function(){return i.loadModel}}),Object.defineProperty(t,"parseModel",{enumerable:!0,get:function(){return i.parseModel}})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")};t.loadTexture=function(n,e){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{},i=r.urls,t=r.onProgress,o=void 0===t?c:t;return(0,s.default)("string"==typeof e,"loadTexture: url must be string"),p(Object.assign({urls:i,onProgress:o},r)).then(function(e){return e.map(function(e,t){return new l.Texture2D(n,Object.assign({id:i[t]},r,{data:e}))})})},t.loadFiles=h,t.loadImages=p,t.loadTextures=function(r){var i=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},o=i.urls,e=i.onProgress,t=void 0===e?c:e;return(0,s.default)(o.every(function(e){return"string"==typeof e}),"loadTextures: {urls} must be array of strings"),p(Object.assign({urls:o,onProgress:t},i)).then(function(e){return e.map(function(e,t){var n=Array.isArray(i.parameters)?i.parameters[t]:i.parameters;return n=void 0===n?{}:n,new l.Texture2D(r,Object.assign({id:o[t]},n,{data:e}))})})},t.loadProgram=function(i){var o=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},e=o.vs,t=o.fs,n=o.onProgress,r=void 0===n?c:n;return h(Object.assign({urls:[e,t],onProgress:r},o)).then(function(e){var t=a(e,2),n=t[0],r=t[1];return new l.Program(i,Object.assign({vs:n,fs:r},o))})},t.loadModel=function(r){var i=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},e=i.url,t=i.onProgress,n=void 0===t?c:t;return h(Object.assign({urls:[e],onProgress:n},i)).then(function(e){var t=a(e,1),n=t[0];return o(r,Object.assign({file:n},i))})},t.parseModel=o;var r,i=n(1),s=(r=i)&&r.__esModule?r:{default:r},u=n(257),l=n(61),f=n(59),d=n(41);function c(){}function h(){var n=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},r=n.urls,e=n.onProgress,i=void 0===e?c:e;(0,s.default)(r.every(function(e){return"string"==typeof e}),"loadImages: {urls} must be array of strings");var o=0;return Promise.all(r.map(function(t){var e=(0,u.loadFile)(Object.assign({url:t},n));return e.then(function(e){return i({progress:++o/r.length,count:o,total:r.length,url:t})}),e}))}function p(){var n=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},r=n.urls,e=n.onProgress,i=void 0===e?c:e;(0,s.default)(r.every(function(e){return"string"==typeof e}),"loadImages: {urls} must be array of strings");var o=0;return Promise.all(r.map(function(t){var e=(0,u.loadImage)(t,n);return e.then(function(e){return i({progress:++o/r.length,count:o,total:r.length,url:t})}),e}))}function o(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.file,r=t.program,i=void 0===r?new l.Program(e):r,o="string"==typeof n?function(e){try{return JSON.parse(e)}catch(e){throw new Error("Failed to parse JSON: "+e)}}(n):n,a={},s={};for(var u in o){var c=o[u];Array.isArray(c)?a[u]="indices"===u?new Uint16Array(c):new Float32Array(c):s[u]=c}return new f.Model(e,Object.assign({program:i,geometry:new d.Geometry({attributes:a})},s,t))}},function(e,t,n){"use strict";var r=n(59),o=n(41),a=n(61);var s=[-1,-1,1,-1,-1,1,1,1],i=function(e){function i(e,t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i);var n=s.map(function(e){return-1===e?0:e}),r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(i.__proto__||Object.getPrototypeOf(i)).call(this,e,Object.assign({},t,{vs:"attribute vec2 aClipSpacePosition;\nattribute vec2 aTexCoord;\nattribute vec2 aCoordinate;\n\nvarying vec2 position;\nvarying vec2 coordinate;\nvarying vec2 uv;\n\nvoid main(void) {\n gl_Position = vec4(aClipSpacePosition, 0., 1.);\n position = aClipSpacePosition;\n coordinate = aCoordinate;\n uv = aTexCoord;\n}\n",geometry:new o.Geometry({drawMode:a.GL.TRIANGLE_STRIP,vertexCount:4,attributes:{aClipSpacePosition:{size:2,value:new Float32Array(s)},aTexCoord:{size:2,value:new Float32Array(n)},aCoordinate:{size:2,value:new Float32Array(n)}}})})));return r.setVertexCount(4),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(i,r["Model"]),i}();t.a=i},function(e,t,n){"use strict";var r=n(41),i=n(59);var o=function(e){function n(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,Object.assign({},t,{geometry:new r.ConeGeometry(t)})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,i["Model"]),n}();t.a=o},function(e,t,o){"use strict";var a=o(41),n=o(59),s=o(8);var r=function(e){function i(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i);var n=t.id,r=void 0===n?o.i(s.d)("cube"):n;return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(i.__proto__||Object.getPrototypeOf(i)).call(this,e,Object.assign({},t,{id:r,geometry:new a.CubeGeometry(t)})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(i,n["Model"]),i}();t.a=r},function(e,t,n){"use strict";var r=n(41),i=n(104);var o=function(e){function n(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,Object.assign({},t,{geometry:new r.CylinderGeometry(t)})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,i["a"]),n}();t.a=o},function(e,t,n){"use strict";var r=n(59),i=n(41);var o=function(e){function n(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,Object.assign({},t,{geometry:new i.IcoSphereGeometry(t)})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,r["Model"]),n}();t.a=o},function(e,t,o){"use strict";var a=o(41),n=o(104),s=o(8);var r=function(e){function i(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i);var n=t.id,r=void 0===n?o.i(s.d)("plane"):n;return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(i.__proto__||Object.getPrototypeOf(i)).call(this,e,Object.assign({},t,{id:r,geometry:new a.PlaneGeometry(t)})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(i,n["a"]),i}();t.a=r},function(e,t,o){"use strict";var n=o(59),a=o(41),s=o(8);var r=function(e){function i(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i);var n=t.id,r=void 0===n?o.i(s.d)("sphere"):n;return function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(i.__proto__||Object.getPrototypeOf(i)).call(this,e,Object.assign({},t,{id:r,geometry:new a.SphereGeometry(t)})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(i,n["Model"]),i}();t.a=r},function(e,t,n){"use strict";var r=n(41),i=n(59);var o=function(e){function n(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,Object.assign({},t,{geometry:new r.TruncatedConeGeometry(t)})))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,i["Model"]),n}();t.a=o},function(e,t,n){"use strict";t.a=function(e){var n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},r=(n=Object.assign({},s,n)).bind;if(r)for(var t in n)t.match(/^on[a-zA-Z0-9]+$/)&&function(e,t){n[e]=function(){t.apply(r,Array.prototype.slice.call(arguments))}}(t,n[t]);return new a(e,n)};var r=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function i(){}function o(e){return!0!==e&&e}function P(e){var t=e.getBoundingClientRect();return{x:t.left,y:t.top,bbox:t}}function S(e){var t=e.which||e.keyCode,n=function(e){var t=u;for(var n in t)if(t[n]===e)return n;return null}(t),r=t-111;return 0<r&&r<13&&(n="f"+r),{code:t,key:n=n||String.fromCharCode(t).toLowerCase(),shift:e.shiftKey,control:e.ctrlKey,alt:e.altKey,meta:e.metaKey}}var a=function(){function n(e,t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),this.scene=t.scene,this.domElem=e,this.pos=P(e),this.opt=this.callbacks=t,this.size={width:e.width||e.offsetWidth,height:e.height||e.offsetHeight},this.attachEvents()}return r(n,[{key:"attachEvents",value:function(){var r=this,e=this.domElem,t=this.opt;if(t.disableContextMenu&&(e.oncontextmenu=function(){return!1}),t.enableMouse){["mouseup","mousedown","mousemove","mouseover","mouseout"].forEach(function(n){e.addEventListener(n,function(e,t){r[n](r.eventInfo(n,e,t))},!1)});var n="";n=document.getBoxObjectFor||null!==window.mozInnerScreenX?"DOMMouseScroll":"mousewheel",e.addEventListener(n,function(e,t){r.mousewheel(r.eventInfo("mousewheel",e,t))},!1)}t.enableTouch&&["touchstart","touchmove","touchend"].forEach(function(n){e.addEventListener(n,function(e,t){r[n](r.eventInfo(n,e,t))},!1)}),t.enableKeyboard&&["keydown","keyup"].forEach(function(n){document.addEventListener(n,function(e,t){r[n](r.eventInfo(n,e,t))},!1)})}},{key:"eventInfo",value:function(e,t,n){for(var r,i,o,a=this.domElem,s=this.scene,u=this.opt,c=this.getSize(),l=u.relative,f=u.centerOrigin,d=u.cachePosition&&this.pos||P(a),h=(r=(r=n)||window,t||r.event),p=function(e,t){t=t||window,e=e||t.event;var n=t.document;if(n=n.documentElement||n.body,e.touches&&e.touches.length){for(var r=[],i=e.touches.length,o=void 0,a=0;a<i;++a)o=e.touches[a],r.push({x:o.pageX||o.clientX+n.scrollLeft,y:o.pageY||o.clientY+n.scrollTop});return r}return[{x:e.pageX||e.clientX+n.scrollLeft,y:e.pageY||e.clientY+n.scrollTop}]}(t,n),v=p[0].x,g=p[0].y,y={},_=void 0,m=void 0,b=0,E=p.length;b<E;++b)_=p[b].x,m=p[b].y,l&&(_-=d.x,m-=d.y,f&&(_-=c.width/2,m-=c.height/2,m*=-1)),p[b].x=_,p[b].y=m;switch(e){case"mousewheel":y.wheel=(o=h).wheelDelta?o.wheelDelta/120:-(o.detail||0)/3;break;case"keydown":case"keyup":Object.assign(y,S(h));break;case"mouseup":y.isRightClick=3===(i=h).which||2===i.button}var w=void 0;return Object.assign(y,{x:p[0].x,y:p[0].y,posArray:p,cache:!1,stop:function(){var e;(e=h).stopPropagation&&e.stopPropagation(),e.cancelBubble=!0,e.preventDefault?e.preventDefault():e.returnValue=!1},getTarget:function(){return w||(w=u.picking&&s.pick(v-d.x,g-d.y)||!0)}}),y.event=h,y}},{key:"getSize",value:function(){if(this.cacheSize)return this.size;var e=this.domElem;return{width:e.width||e.offsetWidth,height:e.height||e.offsetHeight}}},{key:"mouseup",value:function(e){this.moved||(e.isRightClick?this.callbacks.onRightClick(e,this.hovered):this.callbacks.onClick(e,o(this.pressed))),this.pressed&&(this.moved?this.callbacks.onDragEnd(e,o(this.pressed)):this.callbacks.onDragCancel(e,o(this.pressed)),this.pressed=this.moved=!1)}},{key:"mouseout",value:function(e){for(var t=e.relatedTarget,n=this.domElem;t&&t.parentNode;){if(n===t.parentNode)return;t=t.parentNode}this.hovered&&(this.callbacks.onMouseLeave(e,this.hovered),this.hovered=!1),this.pressed&&this.moved&&(this.callbacks.onDragEnd(e),this.pressed=this.moved=!1)}},{key:"mouseover",value:function(e){}},{key:"mousemove",value:function(e){if(this.pressed)return this.moved=!0,void this.callbacks.onDragMove(e,o(this.pressed));if(this.hovered){var t=o(e.getTarget());t&&t.hash===this.hash?this.callbacks.onMouseMove(e,this.hovered):(this.callbacks.onMouseLeave(e,this.hovered),this.hovered=t,(this.hash=t)&&(this.hash=t.hash,this.callbacks.onMouseEnter(e,this.hovered)))}else this.hovered=o(e.getTarget()),this.hash=this.hovered,this.hovered&&(this.hash=this.hovered.hash,this.callbacks.onMouseEnter(e,this.hovered));this.opt.picking||this.callbacks.onMouseMove(e)}},{key:"mousewheel",value:function(e){this.callbacks.onMouseWheel(e)}},{key:"mousedown",value:function(e){this.pressed=e.getTarget(),this.callbacks.onDragStart(e,o(this.pressed))}},{key:"touchstart",value:function(e){this.touched=e.getTarget(),this.touchedLastPosition={x:e.x,y:e.y},this.callbacks.onTouchStart(e,o(this.touched))}},{key:"touchmove",value:function(e){this.touched&&(this.touchMoved=!0,this.callbacks.onTouchMove(e,o(this.touched)))}},{key:"touchend",value:function(e){this.touched&&(this.touchMoved?this.callbacks.onTouchEnd(e,o(this.touched)):(e.x=isNaN(e.x)?this.touchedLastPosition.x:e.x,e.y=isNaN(e.y)?this.touchedLastPosition.y:e.y,this.callbacks.onTap(e,o(this.touched)),this.callbacks.onTouchCancel(e,o(this.touched))),this.touched=this.touchMoved=!1)}},{key:"keydown",value:function(e){this.callbacks.onKeyDown(e)}},{key:"keyup",value:function(e){this.callbacks.onKeyUp(e)}}]),n}();Object.assign(a.prototype,{hovered:!1,pressed:!1,touched:!1,touchedLastPosition:{x:0,y:0},touchMoved:!1,moved:!1});var s={cachePosition:!0,cacheSize:!0,relative:!0,centerOrigin:!0,disableContextMenu:!0,bind:!1,picking:!1,enableTouch:!0,enableMouse:!0,enableKeyboard:!0,onClick:i,onRightClick:i,onDragStart:i,onDragMove:i,onDragEnd:i,onDragCancel:i,onTouchStart:i,onTouchMove:i,onTouchEnd:i,onTouchCancel:i,onTap:i,onMouseMove:i,onMouseEnter:i,onMouseLeave:i,onMouseWheel:i,onKeyDown:i,onKeyUp:i},u={enter:13,up:38,down:40,left:37,right:39,esc:27,space:32,backspace:8,tab:9,delete:46}},function(e,t,n){"use strict";var r=n(640);n.d(t,"a",function(){return r.a})},function(e,t,n){"use strict";n(162);var r=n(258);n.d(t,"a",function(){return r.a});n(259)},function(e,t,r){"use strict";t.a=function(e){var t="",n=r.i(i.getContextInfo)(e);o(n,"nvidia")?t+="#define NVIDIA_GPU\n// Nvidia optimizes away the calculation necessary for emulated fp64\n#define LUMA_FP64_CODE_ELIMINATION_WORKAROUND 1\n":o(n,"intel")?t+="#define INTEL_GPU\n// Intel optimizes away the calculation necessary for emulated fp64\n#define LUMA_FP64_CODE_ELIMINATION_WORKAROUND 1\n// Intel's built-in 'tan' function doesn't have acceptable precision\n#define LUMA_FP32_TAN_PRECISION_WORKAROUND 1\n// Intel GPU doesn't have full 32 bits precision in same cases, causes overflow\n#define LUMA_FP64_HIGH_BITS_OVERFLOW_WORKAROUND 1\n":o(n,"amd")?t+="#define AMD_GPU\n":t+="#define DEFAULT_GPU\n// Prevent driver from optimizing away the calculation necessary for emulated fp64\n#define LUMA_FP64_CODE_ELIMINATION_WORKAROUND 1\n// Intel's built-in 'tan' function doesn't have acceptable precision\n#define LUMA_FP32_TAN_PRECISION_WORKAROUND 1\n// Intel GPU doesn't have full 32 bits precision in same cases, causes overflow\n#define LUMA_FP64_HIGH_BITS_OVERFLOW_WORKAROUND 1\n";return t},t.b=function(e){var t="// Defines for shader portability\n#if (__VERSION__ > 120)\n# define attribute in\n# define varying out\n# define FRAG_DEPTH\n# define DERIVATIVES\n# define DRAW_BUFFERS\n# define TEXTURE_LOD\n#else\n// # define in attribute\n// # define out varying\n#endif // __VERSION\n";r.i(n.b)(e,n.a.GLSL_FRAG_DEPTH)&&(t+="// FRAG_DEPTH => gl_FragDepth is available\n#ifdef GL_EXT_frag_depth\n#extension GL_EXT_frag_depth : enable\n# define FRAG_DEPTH\n# define gl_FragDepth gl_FragDepthEXT\n#endif\n");r.i(n.b)(e,n.a.GLSL_DERIVATIVES)&&(t+="// DERIVATIVES => dxdF, dxdY and fwidth are available\n#ifdef GL_OES_standard_derivatives\n#extension GL_OES_standard_derivatives : enable\n# define DERIVATIVES\n#endif\n");r.i(n.b)(e,n.a.GLSL_FRAG_DATA)&&(t+="// DRAW_BUFFERS => gl_FragData[] is available\n#ifdef GL_EXT_draw_buffers\n#extension GL_EXT_draw_buffers : require\n#define DRAW_BUFFERS\n#endif\n");r.i(n.b)(e,n.a.GLSL_TEXTURE_LOD)&&(t+="// TEXTURE_LOD => texture2DLod etc are available\n#ifdef GL_EXT_shader_texture_lod\n#extension GL_EXT_shader_texture_lod : enable\n# define TEXTURE_LOD\n#define texture2DLod texture2DLodEXT\n#define texture2DProjLod texture2DProjLodEXT\n#define texture2DProjLod texture2DProjLodEXT\n#define textureCubeLod textureCubeLodEXT\n#define texture2DGrad texture2DGradEXT\n#define texture2DProjGrad texture2DProjGradEXT\n#define texture2DProjGrad texture2DProjGradEXT\n#define textureCubeGrad textureCubeGradEXT\n#endif\n");return t};var i=r(61),n=r(108);function o(e,t){var n=e.vendor,r=e.renderer,i=void 0;switch(t){case"nvidia":i=n.match(/NVIDIA/i)||r.match(/NVIDIA/i);break;case"intel":i=n.match(/INTEL/i)||r.match(/INTEL/i);break;case"amd":i=n.match(/AMD/i)||r.match(/AMD/i)||n.match(/ATI/i)||r.match(/ATI/i);break;default:i=!1}return i}},function(e,t,n){"use strict";var r={diffuseTexture:null,diffuseColor:[.5,.5,.5,1]};t.a={name:"diffuse",getUniforms:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:r,t={};return void 0!==e.diffuseTexture&&(t.diffuse_uHasTexture=Boolean(e.diffuseTexture),t.diffuse_uTexture=e.diffuseTexture),void 0!==e.diffuseColor&&(t.diffuse_uColor=e.diffuseColor),t},vs:"varying vec2 diffuse_vTexCoord;\n\n/* Set the UV coordinate from attributes */\nvoid diffuse_setTextureCoordinate(vec2 uv) {\n diffuse_vTexCoord = uv;\n}\n",fs:"uniform vec4 diffuse_uColor;\nuniform bool diffuse_uHasTexture;\nuniform sampler2D diffuse_uTexture;\n\nvarying vec2 diffuse_vTexCoord;\n\n// Gets diffuse color of material from uniform\n// If we have a standard (diffuse) texture, set color to texture\n// return (vec4) - rgba\n//\nvec4 diffuse_getColor() {\n vec2 texCoord = diffuse_vTexCoord;\n return diffuse_uHasTexture ?\n texture2D(diffuse_uTexture, vec2(texCoord.s, texCoord.t)) :\n diffuse_uColor;\n}\n\nvec4 diffuse_filterColor(vec4 color) {\n return diffuse_getColor();\n}\n"}},function(e,t,n){"use strict";var r=n(260),i={lightDirection:new Float32Array([1,1,2])};t.a={name:"dirlight",vs:null,fs:"uniform vec3 dirlight_uLightDirection;\n\n/*\n * Returns color attenuated by angle from light source\n */\nvec4 dirlight_filterColor(vec4 color) {\n vec3 normal = project_getNormal_World();\n float d = abs(dot(normalize(normal), normalize(dirlight_uLightDirection)));\n return vec4(color.rgb * d, color.a);\n}\n",getUniforms:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:i,t={};return e.lightDirection&&(t.dirlight_uLightDirection=e.lightDirection),t},dependencies:[r.a]}},function(e,t,n){"use strict";t.a={name:"fp32",vs:"#ifdef LUMA_FP32_TAN_PRECISION_WORKAROUND\n\n// All these functions are for substituting tan() function from Intel GPU only\nconst float TWO_PI = 6.2831854820251465;\nconst float PI_2 = 1.5707963705062866;\nconst float PI_16 = 0.1963495463132858;\n\nconst float SIN_TABLE_0 = 0.19509032368659973;\nconst float SIN_TABLE_1 = 0.3826834261417389;\nconst float SIN_TABLE_2 = 0.5555702447891235;\nconst float SIN_TABLE_3 = 0.7071067690849304;\n\nconst float COS_TABLE_0 = 0.9807852506637573;\nconst float COS_TABLE_1 = 0.9238795042037964;\nconst float COS_TABLE_2 = 0.8314695954322815;\nconst float COS_TABLE_3 = 0.7071067690849304;\n\nconst float INVERSE_FACTORIAL_3 = 1.666666716337204e-01; // 1/3!\nconst float INVERSE_FACTORIAL_5 = 8.333333767950535e-03; // 1/5!\nconst float INVERSE_FACTORIAL_7 = 1.9841270113829523e-04; // 1/7!\nconst float INVERSE_FACTORIAL_9 = 2.75573188446287533e-06; // 1/9!\n\nfloat sin_taylor_fp32(float a) {\n float r, s, t, x;\n\n if (a == 0.0) {\n return 0.0;\n }\n\n x = -a * a;\n s = a;\n r = a;\n\n r = r * x;\n t = r * INVERSE_FACTORIAL_3;\n s = s + t;\n\n r = r * x;\n t = r * INVERSE_FACTORIAL_5;\n s = s + t;\n\n r = r * x;\n t = r * INVERSE_FACTORIAL_7;\n s = s + t;\n\n r = r * x;\n t = r * INVERSE_FACTORIAL_9;\n s = s + t;\n\n return s;\n}\n\nvoid sincos_taylor_fp32(float a, out float sin_t, out float cos_t) {\n if (a == 0.0) {\n sin_t = 0.0;\n cos_t = 1.0;\n }\n sin_t = sin_taylor_fp32(a);\n cos_t = sqrt(1.0 - sin_t * sin_t);\n}\n\nfloat tan_taylor_fp32(float a) {\n float sin_a;\n float cos_a;\n\n if (a == 0.0) {\n return 0.0;\n }\n\n // 2pi range reduction\n float z = floor(a / TWO_PI);\n float r = a - TWO_PI * z;\n\n float t;\n float q = floor(r / PI_2 + 0.5);\n int j = int(q);\n\n if (j < -2 || j > 2) {\n return 0.0 / 0.0;\n }\n\n t = r - PI_2 * q;\n\n q = floor(t / PI_16 + 0.5);\n int k = int(q);\n int abs_k = int(abs(float(k)));\n\n if (abs_k > 4) {\n return 0.0 / 0.0;\n } else {\n t = t - PI_16 * q;\n }\n\n float u = 0.0;\n float v = 0.0;\n\n float sin_t, cos_t;\n float s, c;\n sincos_taylor_fp32(t, sin_t, cos_t);\n\n if (k == 0) {\n s = sin_t;\n c = cos_t;\n } else {\n if (abs(float(abs_k) - 1.0) < 0.5) {\n u = COS_TABLE_0;\n v = SIN_TABLE_0;\n } else if (abs(float(abs_k) - 2.0) < 0.5) {\n u = COS_TABLE_1;\n v = SIN_TABLE_1;\n } else if (abs(float(abs_k) - 3.0) < 0.5) {\n u = COS_TABLE_2;\n v = SIN_TABLE_2;\n } else if (abs(float(abs_k) - 4.0) < 0.5) {\n u = COS_TABLE_3;\n v = SIN_TABLE_3;\n }\n if (k > 0) {\n s = u * sin_t + v * cos_t;\n c = u * cos_t - v * sin_t;\n } else {\n s = u * sin_t - v * cos_t;\n c = u * cos_t + v * sin_t;\n }\n }\n\n if (j == 0) {\n sin_a = s;\n cos_a = c;\n } else if (j == 1) {\n sin_a = c;\n cos_a = -s;\n } else if (j == -1) {\n sin_a = -c;\n cos_a = s;\n } else {\n sin_a = -s;\n cos_a = -c;\n }\n return sin_a / cos_a;\n}\n#endif\n\nfloat tan_fp32(float a) {\n#ifdef LUMA_FP32_TAN_PRECISION_WORKAROUND\n return tan_taylor_fp32(a);\n#else\n return tan(a);\n#endif\n}\n",fs:null}},function(e,t,n){"use strict";t.a="uniform float ONE;\n\n/*\nAbout LUMA_FP64_CODE_ELIMINATION_WORKAROUND\n\nThe purpose of this workaround is to prevent shader compilers from\noptimizing away necessary arithmetic operations by swapping their sequences\nor transform the equation to some 'equivalent' from.\n\nThe method is to multiply an artifical variable, ONE, which will be known to\nthe compiler to be 1 only at runtime. The whole expression is then represented\nas a polynomial with respective to ONE. In the coefficients of all terms, only one a\nand one b should appear\n\nerr = (a + b) * ONE^6 - a * ONE^5 - (a + b) * ONE^4 + a * ONE^3 - b - (a + b) * ONE^2 + a * ONE\n*/\n\n// Divide float number to high and low floats to extend fraction bits\nvec2 split(float a) {\n const float SPLIT = 4097.0;\n float t = a * SPLIT;\n#if defined(LUMA_FP64_CODE_ELIMINATION_WORKAROUND)\n float a_hi = t * ONE - (t - a);\n float a_lo = a * ONE - a_hi;\n#else\n float a_hi = t - (t - a);\n float a_lo = a - a_hi;\n#endif\n return vec2(a_hi, a_lo);\n}\n\n// Divide float number again when high float uses too many fraction bits\nvec2 split2(vec2 a) {\n vec2 b = split(a.x);\n b.y += a.y;\n return b;\n}\n\n// Special sum operation when a > b\nvec2 quickTwoSum(float a, float b) {\n#if defined(LUMA_FP64_CODE_ELIMINATION_WORKAROUND)\n float sum = (a + b) * ONE;\n float err = b - (sum - a) * ONE;\n#else\n float sum = a + b;\n float err = b - (sum - a);\n#endif\n return vec2(sum, err);\n}\n\n// General sum operation\nvec2 twoSum(float a, float b) {\n float s = (a + b);\n#if defined(LUMA_FP64_CODE_ELIMINATION_WORKAROUND)\n float v = (s * ONE - a) * ONE;\n float err = (a - (s - v) * ONE) * ONE * ONE * ONE + (b - v);\n#else\n float v = s - a;\n float err = (a - (s - v)) + (b - v);\n#endif\n return vec2(s, err);\n}\n\nvec2 twoSub(float a, float b) {\n float s = (a - b);\n#if defined(LUMA_FP64_CODE_ELIMINATION_WORKAROUND)\n float v = (s * ONE - a) * ONE;\n float err = (a - (s - v) * ONE) * ONE * ONE * ONE - (b + v);\n#else\n float v = s - a;\n float err = (a - (s - v)) - (b + v);\n#endif\n return vec2(s, err);\n}\n\nvec2 twoSqr(float a) {\n float prod = a * a;\n vec2 a_fp64 = split(a);\n#if defined(LUMA_FP64_CODE_ELIMINATION_WORKAROUND)\n float err = ((a_fp64.x * a_fp64.x - prod) * ONE + 2.0 * a_fp64.x *\n a_fp64.y * ONE * ONE) + a_fp64.y * a_fp64.y * ONE * ONE * ONE;\n#else\n float err = ((a_fp64.x * a_fp64.x - prod) + 2.0 * a_fp64.x * a_fp64.y) + a_fp64.y * a_fp64.y;\n#endif\n return vec2(prod, err);\n}\n\nvec2 twoProd(float a, float b) {\n float prod = a * b;\n vec2 a_fp64 = split(a);\n vec2 b_fp64 = split(b);\n float err = ((a_fp64.x * b_fp64.x - prod) + a_fp64.x * b_fp64.y +\n a_fp64.y * b_fp64.x) + a_fp64.y * b_fp64.y;\n return vec2(prod, err);\n}\n\nvec2 sum_fp64(vec2 a, vec2 b) {\n vec2 s, t;\n s = twoSum(a.x, b.x);\n t = twoSum(a.y, b.y);\n s.y += t.x;\n s = quickTwoSum(s.x, s.y);\n s.y += t.y;\n s = quickTwoSum(s.x, s.y);\n return s;\n}\n\nvec2 sub_fp64(vec2 a, vec2 b) {\n vec2 s, t;\n s = twoSub(a.x, b.x);\n t = twoSub(a.y, b.y);\n s.y += t.x;\n s = quickTwoSum(s.x, s.y);\n s.y += t.y;\n s = quickTwoSum(s.x, s.y);\n return s;\n}\n\nvec2 mul_fp64(vec2 a, vec2 b) {\n vec2 prod = twoProd(a.x, b.x);\n // y component is for the error\n prod.y += a.x * b.y;\n#if defined(LUMA_FP64_HIGH_BITS_OVERFLOW_WORKAROUND)\n prod = split2(prod);\n#endif\n prod = quickTwoSum(prod.x, prod.y);\n prod.y += a.y * b.x;\n#if defined(LUMA_FP64_HIGH_BITS_OVERFLOW_WORKAROUND)\n prod = split2(prod);\n#endif\n prod = quickTwoSum(prod.x, prod.y);\n return prod;\n}\n\nvec2 div_fp64(vec2 a, vec2 b) {\n float xn = 1.0 / b.x;\n#if defined(LUMA_FP64_HIGH_BITS_OVERFLOW_WORKAROUND)\n vec2 yn = mul_fp64(a, vec2(xn, 0));\n#else\n vec2 yn = a * xn;\n#endif\n float diff = (sub_fp64(a, mul_fp64(b, yn))).x;\n vec2 prod = twoProd(xn, diff);\n return sum_fp64(yn, prod);\n}\n\nvec2 sqrt_fp64(vec2 a) {\n if (a.x == 0.0 && a.y == 0.0) return vec2(0.0, 0.0);\n if (a.x < 0.0) return vec2(0.0 / 0.0, 0.0 / 0.0);\n\n float x = 1.0 / sqrt(a.x);\n float yn = a.x * x;\n#if defined(LUMA_FP64_CODE_ELIMINATION_WORKAROUND)\n vec2 yn_sqr = twoSqr(yn) * ONE;\n#else\n vec2 yn_sqr = twoSqr(yn);\n#endif\n float diff = sub_fp64(a, yn_sqr).x;\n vec2 prod = twoProd(x * 0.5, diff);\n#if defined(LUMA_FP64_HIGH_BITS_OVERFLOW_WORKAROUND)\n return sum_fp64(split(yn), prod);\n#else\n return sum_fp64(vec2(yn, 0.0), prod);\n#endif\n}\n"},function(e,t,n){"use strict";t.a="const vec2 E_FP64 = vec2(2.7182817459106445e+00, 8.254840366817007e-08);\nconst vec2 LOG2_FP64 = vec2(0.6931471824645996e+00, -1.9046542121259336e-09);\nconst vec2 PI_FP64 = vec2(3.1415927410125732, -8.742278012618954e-8);\nconst vec2 TWO_PI_FP64 = vec2(6.2831854820251465, -1.7484556025237907e-7);\nconst vec2 PI_2_FP64 = vec2(1.5707963705062866, -4.371139006309477e-8);\nconst vec2 PI_4_FP64 = vec2(0.7853981852531433, -2.1855695031547384e-8);\nconst vec2 PI_16_FP64 = vec2(0.19634954631328583, -5.463923757886846e-9);\nconst vec2 PI_16_2_FP64 = vec2(0.39269909262657166, -1.0927847515773692e-8);\nconst vec2 PI_16_3_FP64 = vec2(0.5890486240386963, -1.4906100798128818e-9);\nconst vec2 PI_180_FP64 = vec2(0.01745329238474369, 1.3519960498364902e-10);\n\nconst vec2 SIN_TABLE_0_FP64 = vec2(0.19509032368659973, -1.6704714833615242e-9);\nconst vec2 SIN_TABLE_1_FP64 = vec2(0.3826834261417389, 6.22335089017767e-9);\nconst vec2 SIN_TABLE_2_FP64 = vec2(0.5555702447891235, -1.1769521357507529e-8);\nconst vec2 SIN_TABLE_3_FP64 = vec2(0.7071067690849304, 1.2101617041793133e-8);\n\nconst vec2 COS_TABLE_0_FP64 = vec2(0.9807852506637573, 2.9739473106360492e-8);\nconst vec2 COS_TABLE_1_FP64 = vec2(0.9238795042037964, 2.8307490351764386e-8);\nconst vec2 COS_TABLE_2_FP64 = vec2(0.8314695954322815, 1.6870263741530778e-8);\nconst vec2 COS_TABLE_3_FP64 = vec2(0.7071067690849304, 1.2101617152815436e-8);\n\nconst vec2 INVERSE_FACTORIAL_3_FP64 = vec2(1.666666716337204e-01, -4.967053879312289e-09); // 1/3!\nconst vec2 INVERSE_FACTORIAL_4_FP64 = vec2(4.16666679084301e-02, -1.2417634698280722e-09); // 1/4!\nconst vec2 INVERSE_FACTORIAL_5_FP64 = vec2(8.333333767950535e-03, -4.34617203337595e-10); // 1/5!\nconst vec2 INVERSE_FACTORIAL_6_FP64 = vec2(1.3888889225199819e-03, -3.3631094437103215e-11); // 1/6!\nconst vec2 INVERSE_FACTORIAL_7_FP64 = vec2(1.9841270113829523e-04, -2.725596874933456e-12); // 1/7!\nconst vec2 INVERSE_FACTORIAL_8_FP64 = vec2(2.4801587642286904e-05, -3.406996025904184e-13); // 1/8!\nconst vec2 INVERSE_FACTORIAL_9_FP64 = vec2(2.75573188446287533e-06, 3.7935713937038186e-14); // 1/9!\nconst vec2 INVERSE_FACTORIAL_10_FP64 = vec2(2.755731998149713e-07, -7.575112367869873e-15); // 1/10!\n\nfloat nint(float d) {\n if (d == floor(d)) return d;\n return floor(d + 0.5);\n}\n\nvec2 nint_fp64(vec2 a) {\n float hi = nint(a.x);\n float lo;\n vec2 tmp;\n if (hi == a.x) {\n lo = nint(a.y);\n tmp = quickTwoSum(hi, lo);\n } else {\n lo = 0.0;\n if (abs(hi - a.x) == 0.5 && a.y < 0.0) {\n hi -= 1.0;\n }\n tmp = vec2(hi, lo);\n }\n return tmp;\n}\n\n/* k_power controls how much range reduction we would like to have\nRange reduction uses the following method:\nassume a = k_power * r + m * log(2), k and m being integers.\nSet k_power = 4 (we can choose other k to trade accuracy with performance.\nwe only need to calculate exp(r) and using exp(a) = 2^m * exp(r)^k_power;\n*/\n\nvec2 exp_fp64(vec2 a) {\n // We need to make sure these two numbers match\n // as bit-wise shift is not available in GLSL 1.0\n const int k_power = 4;\n const float k = 16.0;\n\n const float inv_k = 1.0 / k;\n\n if (a.x <= -88.0) return vec2(0.0, 0.0);\n if (a.x >= 88.0) return vec2(1.0 / 0.0, 1.0 / 0.0);\n if (a.x == 0.0 && a.y == 0.0) return vec2(1.0, 0.0);\n if (a.x == 1.0 && a.y == 0.0) return E_FP64;\n\n float m = floor(a.x / LOG2_FP64.x + 0.5);\n vec2 r = sub_fp64(a, mul_fp64(LOG2_FP64, vec2(m, 0.0))) * inv_k;\n vec2 s, t, p;\n\n p = mul_fp64(r, r);\n s = sum_fp64(r, p * 0.5);\n p = mul_fp64(p, r);\n t = mul_fp64(p, INVERSE_FACTORIAL_3_FP64);\n\n s = sum_fp64(s, t);\n p = mul_fp64(p, r);\n t = mul_fp64(p, INVERSE_FACTORIAL_4_FP64);\n\n s = sum_fp64(s, t);\n p = mul_fp64(p, r);\n t = mul_fp64(p, INVERSE_FACTORIAL_5_FP64);\n\n // s = sum_fp64(s, t);\n // p = mul_fp64(p, r);\n // t = mul_fp64(p, INVERSE_FACTORIAL_6_FP64);\n\n // s = sum_fp64(s, t);\n // p = mul_fp64(p, r);\n // t = mul_fp64(p, INVERSE_FACTORIAL_7_FP64);\n\n s = sum_fp64(s, t);\n\n\n // At this point, s = exp(r) - 1; but after following 4 recursions, we will get exp(r) ^ 512 - 1.\n for (int i = 0; i < k_power; i++) {\n s = sum_fp64(s * 2.0, mul_fp64(s, s));\n }\n\n#if defined(NVIDIA_FP64_WORKAROUND) || defined(INTEL_FP64_WORKAROUND)\n s = sum_fp64(s, vec2(ONE, 0.0));\n#else\n s = sum_fp64(s, vec2(1.0, 0.0));\n#endif\n\n return s * pow(2.0, m);\n// return r;\n}\n\nvec2 log_fp64(vec2 a)\n{\n if (a.x == 1.0 && a.y == 0.0) return vec2(0.0, 0.0);\n if (a.x <= 0.0) return vec2(0.0 / 0.0, 0.0 / 0.0);\n vec2 x = vec2(log(a.x), 0.0);\n vec2 s;\n#if defined(NVIDIA_FP64_WORKAROUND) || defined(INTEL_FP64_WORKAROUND)\n s = vec2(ONE, 0.0);\n#else\n s = vec2(1.0, 0.0);\n#endif\n\n x = sub_fp64(sum_fp64(x, mul_fp64(a, exp_fp64(-x))), s);\n return x;\n}\n\nvec2 sin_taylor_fp64(vec2 a) {\n vec2 r, s, t, x;\n\n if (a.x == 0.0 && a.y == 0.0) {\n return vec2(0.0, 0.0);\n }\n\n x = -mul_fp64(a, a);\n s = a;\n r = a;\n\n r = mul_fp64(r, x);\n t = mul_fp64(r, INVERSE_FACTORIAL_3_FP64);\n s = sum_fp64(s, t);\n\n r = mul_fp64(r, x);\n t = mul_fp64(r, INVERSE_FACTORIAL_5_FP64);\n s = sum_fp64(s, t);\n\n /* keep the following commented code in case we need them\n for extra accuracy from the Taylor expansion*/\n\n // r = mul_fp64(r, x);\n // t = mul_fp64(r, INVERSE_FACTORIAL_7_FP64);\n // s = sum_fp64(s, t);\n\n // r = mul_fp64(r, x);\n // t = mul_fp64(r, INVERSE_FACTORIAL_9_FP64);\n // s = sum_fp64(s, t);\n\n return s;\n}\n\nvec2 cos_taylor_fp64(vec2 a) {\n vec2 r, s, t, x;\n\n if (a.x == 0.0 && a.y == 0.0) {\n return vec2(1.0, 0.0);\n }\n\n x = -mul_fp64(a, a);\n r = x;\n s = sum_fp64(vec2(1.0, 0.0), r * 0.5);\n\n r = mul_fp64(r, x);\n t = mul_fp64(r, INVERSE_FACTORIAL_4_FP64);\n s = sum_fp64(s, t);\n\n r = mul_fp64(r, x);\n t = mul_fp64(r, INVERSE_FACTORIAL_6_FP64);\n s = sum_fp64(s, t);\n\n /* keep the following commented code in case we need them\n for extra accuracy from the Taylor expansion*/\n\n // r = mul_fp64(r, x);\n // t = mul_fp64(r, INVERSE_FACTORIAL_8_FP64);\n // s = sum_fp64(s, t);\n\n // r = mul_fp64(r, x);\n // t = mul_fp64(r, INVERSE_FACTORIAL_10_FP64);\n // s = sum_fp64(s, t);\n\n return s;\n}\n\nvoid sincos_taylor_fp64(vec2 a, out vec2 sin_t, out vec2 cos_t) {\n if (a.x == 0.0 && a.y == 0.0) {\n sin_t = vec2(0.0, 0.0);\n cos_t = vec2(1.0, 0.0);\n }\n\n sin_t = sin_taylor_fp64(a);\n cos_t = sqrt_fp64(sub_fp64(vec2(1.0, 0.0), mul_fp64(sin_t, sin_t)));\n}\n\nvec2 sin_fp64(vec2 a) {\n if (a.x == 0.0 && a.y == 0.0) {\n return vec2(0.0, 0.0);\n }\n\n // 2pi range reduction\n vec2 z = nint_fp64(div_fp64(a, TWO_PI_FP64));\n vec2 r = sub_fp64(a, mul_fp64(TWO_PI_FP64, z));\n\n vec2 t;\n float q = floor(r.x / PI_2_FP64.x + 0.5);\n int j = int(q);\n\n if (j < -2 || j > 2) {\n return vec2(0.0 / 0.0, 0.0 / 0.0);\n }\n\n t = sub_fp64(r, mul_fp64(PI_2_FP64, vec2(q, 0.0)));\n\n q = floor(t.x / PI_16_FP64.x + 0.5);\n int k = int(q);\n\n if (k == 0) {\n if (j == 0) {\n return sin_taylor_fp64(t);\n } else if (j == 1) {\n return cos_taylor_fp64(t);\n } else if (j == -1) {\n return -cos_taylor_fp64(t);\n } else {\n return -sin_taylor_fp64(t);\n }\n }\n\n int abs_k = int(abs(float(k)));\n\n if (abs_k > 4) {\n return vec2(0.0 / 0.0, 0.0 / 0.0);\n } else {\n t = sub_fp64(t, mul_fp64(PI_16_FP64, vec2(q, 0.0)));\n }\n\n vec2 u = vec2(0.0, 0.0);\n vec2 v = vec2(0.0, 0.0);\n\n#if defined(NVIDIA_FP64_WORKAROUND) || defined(INTEL_FP64_WORKAROUND)\n if (abs(float(abs_k) - 1.0) < 0.5) {\n u = COS_TABLE_0_FP64;\n v = SIN_TABLE_0_FP64;\n } else if (abs(float(abs_k) - 2.0) < 0.5) {\n u = COS_TABLE_1_FP64;\n v = SIN_TABLE_1_FP64;\n } else if (abs(float(abs_k) - 3.0) < 0.5) {\n u = COS_TABLE_2_FP64;\n v = SIN_TABLE_2_FP64;\n } else if (abs(float(abs_k) - 4.0) < 0.5) {\n u = COS_TABLE_3_FP64;\n v = SIN_TABLE_3_FP64;\n }\n#else\n if (abs_k == 1) {\n u = COS_TABLE_0_FP64;\n v = SIN_TABLE_0_FP64;\n } else if (abs_k == 2) {\n u = COS_TABLE_1_FP64;\n v = SIN_TABLE_1_FP64;\n } else if (abs_k == 3) {\n u = COS_TABLE_2_FP64;\n v = SIN_TABLE_2_FP64;\n } else if (abs_k == 4) {\n u = COS_TABLE_3_FP64;\n v = SIN_TABLE_3_FP64;\n }\n#endif\n\n vec2 sin_t, cos_t;\n sincos_taylor_fp64(t, sin_t, cos_t);\n\n\n\n vec2 result = vec2(0.0, 0.0);\n if (j == 0) {\n if (k > 0) {\n result = sum_fp64(mul_fp64(u, sin_t), mul_fp64(v, cos_t));\n } else {\n result = sub_fp64(mul_fp64(u, sin_t), mul_fp64(v, cos_t));\n }\n } else if (j == 1) {\n if (k > 0) {\n result = sub_fp64(mul_fp64(u, cos_t), mul_fp64(v, sin_t));\n } else {\n result = sum_fp64(mul_fp64(u, cos_t), mul_fp64(v, sin_t));\n }\n } else if (j == -1) {\n if (k > 0) {\n result = sub_fp64(mul_fp64(v, sin_t), mul_fp64(u, cos_t));\n } else {\n result = -sum_fp64(mul_fp64(v, sin_t), mul_fp64(u, cos_t));\n }\n } else {\n if (k > 0) {\n result = -sum_fp64(mul_fp64(u, sin_t), mul_fp64(v, cos_t));\n } else {\n result = sub_fp64(mul_fp64(v, cos_t), mul_fp64(u, sin_t));\n }\n }\n\n return result;\n}\n\nvec2 cos_fp64(vec2 a) {\n if (a.x == 0.0 && a.y == 0.0) {\n return vec2(1.0, 0.0);\n }\n\n // 2pi range reduction\n vec2 z = nint_fp64(div_fp64(a, TWO_PI_FP64));\n vec2 r = sub_fp64(a, mul_fp64(TWO_PI_FP64, z));\n\n vec2 t;\n float q = floor(r.x / PI_2_FP64.x + 0.5);\n int j = int(q);\n\n if (j < -2 || j > 2) {\n return vec2(0.0 / 0.0, 0.0 / 0.0);\n }\n\n t = sub_fp64(r, mul_fp64(PI_2_FP64, vec2(q, 0.0)));\n\n q = floor(t.x / PI_16_FP64.x + 0.5);\n int k = int(q);\n\n if (k == 0) {\n if (j == 0) {\n return cos_taylor_fp64(t);\n } else if (j == 1) {\n return -sin_taylor_fp64(t);\n } else if (j == -1) {\n return sin_taylor_fp64(t);\n } else {\n return -cos_taylor_fp64(t);\n }\n }\n\n int abs_k = int(abs(float(k)));\n\n if (abs_k > 4) {\n return vec2(0.0 / 0.0, 0.0 / 0.0);\n } else {\n t = sub_fp64(t, mul_fp64(PI_16_FP64, vec2(q, 0.0)));\n }\n\n vec2 u = vec2(0.0, 0.0);\n vec2 v = vec2(0.0, 0.0);\n\n#if defined(NVIDIA_FP64_WORKAROUND) || defined(INTEL_FP64_WORKAROUND)\n if (abs(float(abs_k) - 1.0) < 0.5) {\n u = COS_TABLE_0_FP64;\n v = SIN_TABLE_0_FP64;\n } else if (abs(float(abs_k) - 2.0) < 0.5) {\n u = COS_TABLE_1_FP64;\n v = SIN_TABLE_1_FP64;\n } else if (abs(float(abs_k) - 3.0) < 0.5) {\n u = COS_TABLE_2_FP64;\n v = SIN_TABLE_2_FP64;\n } else if (abs(float(abs_k) - 4.0) < 0.5) {\n u = COS_TABLE_3_FP64;\n v = SIN_TABLE_3_FP64;\n }\n#else\n if (abs_k == 1) {\n u = COS_TABLE_0_FP64;\n v = SIN_TABLE_0_FP64;\n } else if (abs_k == 2) {\n u = COS_TABLE_1_FP64;\n v = SIN_TABLE_1_FP64;\n } else if (abs_k == 3) {\n u = COS_TABLE_2_FP64;\n v = SIN_TABLE_2_FP64;\n } else if (abs_k == 4) {\n u = COS_TABLE_3_FP64;\n v = SIN_TABLE_3_FP64;\n }\n#endif\n\n vec2 sin_t, cos_t;\n sincos_taylor_fp64(t, sin_t, cos_t);\n\n vec2 result = vec2(0.0, 0.0);\n if (j == 0) {\n if (k > 0) {\n result = sub_fp64(mul_fp64(u, cos_t), mul_fp64(v, sin_t));\n } else {\n result = sum_fp64(mul_fp64(u, cos_t), mul_fp64(v, sin_t));\n }\n } else if (j == 1) {\n if (k > 0) {\n result = -sum_fp64(mul_fp64(u, sin_t), mul_fp64(v, cos_t));\n } else {\n result = sub_fp64(mul_fp64(v, cos_t), mul_fp64(u, sin_t));\n }\n } else if (j == -1) {\n if (k > 0) {\n result = sum_fp64(mul_fp64(u, sin_t), mul_fp64(v, cos_t));\n } else {\n result = sub_fp64(mul_fp64(u, sin_t), mul_fp64(v, cos_t));\n }\n } else {\n if (k > 0) {\n result = sub_fp64(mul_fp64(v, sin_t), mul_fp64(u, cos_t));\n } else {\n result = -sum_fp64(mul_fp64(u, cos_t), mul_fp64(v, sin_t));\n }\n }\n\n return result;\n}\n\nvec2 tan_fp64(vec2 a) {\n vec2 sin_a;\n vec2 cos_a;\n\n if (a.x == 0.0 && a.y == 0.0) {\n return vec2(0.0, 0.0);\n }\n\n // 2pi range reduction\n vec2 z = nint_fp64(div_fp64(a, TWO_PI_FP64));\n vec2 r = sub_fp64(a, mul_fp64(TWO_PI_FP64, z));\n\n vec2 t;\n float q = floor(r.x / PI_2_FP64.x + 0.5);\n int j = int(q);\n\n\n if (j < -2 || j > 2) {\n return vec2(0.0 / 0.0, 0.0 / 0.0);\n }\n\n t = sub_fp64(r, mul_fp64(PI_2_FP64, vec2(q, 0.0)));\n\n q = floor(t.x / PI_16_FP64.x + 0.5);\n int k = int(q);\n int abs_k = int(abs(float(k)));\n\n // We just can't get PI/16 * 3.0 very accurately.\n // so let's just store it\n if (abs_k > 4) {\n return vec2(0.0 / 0.0, 0.0 / 0.0);\n } else {\n t = sub_fp64(t, mul_fp64(PI_16_FP64, vec2(q, 0.0)));\n }\n\n\n vec2 u = vec2(0.0, 0.0);\n vec2 v = vec2(0.0, 0.0);\n\n vec2 sin_t, cos_t;\n vec2 s, c;\n sincos_taylor_fp64(t, sin_t, cos_t);\n\n if (k == 0) {\n s = sin_t;\n c = cos_t;\n } else {\n#if defined(NVIDIA_FP64_WORKAROUND) || defined(INTEL_FP64_WORKAROUND)\n if (abs(float(abs_k) - 1.0) < 0.5) {\n u = COS_TABLE_0_FP64;\n v = SIN_TABLE_0_FP64;\n } else if (abs(float(abs_k) - 2.0) < 0.5) {\n u = COS_TABLE_1_FP64;\n v = SIN_TABLE_1_FP64;\n } else if (abs(float(abs_k) - 3.0) < 0.5) {\n u = COS_TABLE_2_FP64;\n v = SIN_TABLE_2_FP64;\n } else if (abs(float(abs_k) - 4.0) < 0.5) {\n u = COS_TABLE_3_FP64;\n v = SIN_TABLE_3_FP64;\n }\n#else\n if (abs_k == 1) {\n u = COS_TABLE_0_FP64;\n v = SIN_TABLE_0_FP64;\n } else if (abs_k == 2) {\n u = COS_TABLE_1_FP64;\n v = SIN_TABLE_1_FP64;\n } else if (abs_k == 3) {\n u = COS_TABLE_2_FP64;\n v = SIN_TABLE_2_FP64;\n } else if (abs_k == 4) {\n u = COS_TABLE_3_FP64;\n v = SIN_TABLE_3_FP64;\n }\n#endif\n if (k > 0) {\n s = sum_fp64(mul_fp64(u, sin_t), mul_fp64(v, cos_t));\n c = sub_fp64(mul_fp64(u, cos_t), mul_fp64(v, sin_t));\n } else {\n s = sub_fp64(mul_fp64(u, sin_t), mul_fp64(v, cos_t));\n c = sum_fp64(mul_fp64(u, cos_t), mul_fp64(v, sin_t));\n }\n }\n\n if (j == 0) {\n sin_a = s;\n cos_a = c;\n } else if (j == 1) {\n sin_a = c;\n cos_a = -s;\n } else if (j == -1) {\n sin_a = -c;\n cos_a = s;\n } else {\n sin_a = -s;\n cos_a = -c;\n }\n return div_fp64(sin_a, cos_a);\n}\n\nvec2 radians_fp64(vec2 degree) {\n return mul_fp64(degree, PI_180_FP64);\n}\n\nvec2 mix_fp64(vec2 a, vec2 b, float x) {\n vec2 range = sub_fp64(b, a);\n return sum_fp64(a, mul_fp64(range, vec2(x, 0.0)));\n}\n\n// Vector functions\n// vec2 functions\nvoid vec2_sum_fp64(vec2 a[2], vec2 b[2], out vec2 out_val[2]) {\n out_val[0] = sum_fp64(a[0], b[0]);\n out_val[1] = sum_fp64(a[1], b[1]);\n}\n\nvoid vec2_sub_fp64(vec2 a[2], vec2 b[2], out vec2 out_val[2]) {\n out_val[0] = sub_fp64(a[0], b[0]);\n out_val[1] = sub_fp64(a[1], b[1]);\n}\n\nvoid vec2_mul_fp64(vec2 a[2], vec2 b[2], out vec2 out_val[2]) {\n out_val[0] = mul_fp64(a[0], b[0]);\n out_val[1] = mul_fp64(a[1], b[1]);\n}\n\nvoid vec2_div_fp64(vec2 a[2], vec2 b[2], out vec2 out_val[2]) {\n out_val[0] = div_fp64(a[0], b[0]);\n out_val[1] = div_fp64(a[1], b[1]);\n}\n\nvoid vec2_mix_fp64(vec2 x[2], vec2 y[2], float a, out vec2 out_val[2]) {\n vec2 range[2];\n vec2_sub_fp64(y, x, range);\n vec2 portion[2];\n portion[0] = range[0] * a;\n portion[1] = range[1] * a;\n vec2_sum_fp64(x, portion, out_val);\n}\n\nvec2 vec2_length_fp64(vec2 x[2]) {\n return sqrt_fp64(sum_fp64(mul_fp64(x[0], x[0]), mul_fp64(x[1], x[1])));\n}\n\nvoid vec2_normalize_fp64(vec2 x[2], out vec2 out_val[2]) {\n vec2 length = vec2_length_fp64(x);\n vec2 length_vec2[2];\n length_vec2[0] = length;\n length_vec2[1] = length;\n\n vec2_div_fp64(x, length_vec2, out_val);\n}\n\nvec2 vec2_distance_fp64(vec2 x[2], vec2 y[2]) {\n vec2 diff[2];\n vec2_sub_fp64(x, y, diff);\n return vec2_length_fp64(diff);\n}\n\nvec2 vec2_dot_fp64(vec2 a[2], vec2 b[2]) {\n vec2 v[2];\n\n v[0] = mul_fp64(a[0], b[0]);\n v[1] = mul_fp64(a[1], b[1]);\n\n return sum_fp64(v[0], v[1]);\n}\n\n// vec3 functions\nvoid vec3_sub_fp64(vec2 a[3], vec2 b[3], out vec2 out_val[3]) {\n for (int i = 0; i < 3; i++) {\n out_val[i] = sum_fp64(a[i], b[i]);\n }\n}\n\nvoid vec3_sum_fp64(vec2 a[3], vec2 b[3], out vec2 out_val[3]) {\n for (int i = 0; i < 3; i++) {\n out_val[i] = sum_fp64(a[i], b[i]);\n }\n}\n\nvec2 vec3_length_fp64(vec2 x[3]) {\n return sqrt_fp64(sum_fp64(sum_fp64(mul_fp64(x[0], x[0]), mul_fp64(x[1], x[1])),\n mul_fp64(x[2], x[2])));\n}\n\nvec2 vec3_distance_fp64(vec2 x[3], vec2 y[3]) {\n vec2 diff[3];\n vec3_sub_fp64(x, y, diff);\n return vec3_length_fp64(diff);\n}\n\n// vec4 functions\nvoid vec4_fp64(vec4 a, out vec2 out_val[4]) {\n out_val[0].x = a[0];\n out_val[0].y = 0.0;\n\n out_val[1].x = a[1];\n out_val[1].y = 0.0;\n\n out_val[2].x = a[2];\n out_val[2].y = 0.0;\n\n out_val[3].x = a[3];\n out_val[3].y = 0.0;\n}\n\nvoid vec4_scalar_mul_fp64(vec2 a[4], vec2 b, out vec2 out_val[4]) {\n out_val[0] = mul_fp64(a[0], b);\n out_val[1] = mul_fp64(a[1], b);\n out_val[2] = mul_fp64(a[2], b);\n out_val[3] = mul_fp64(a[3], b);\n}\n\nvoid vec4_sum_fp64(vec2 a[4], vec2 b[4], out vec2 out_val[4]) {\n for (int i = 0; i < 4; i++) {\n out_val[i] = sum_fp64(a[i], b[i]);\n }\n}\n\nvoid vec4_dot_fp64(vec2 a[4], vec2 b[4], out vec2 out_val) {\n vec2 v[4];\n\n v[0] = mul_fp64(a[0], b[0]);\n v[1] = mul_fp64(a[1], b[1]);\n v[2] = mul_fp64(a[2], b[2]);\n v[3] = mul_fp64(a[3], b[3]);\n\n out_val = sum_fp64(sum_fp64(v[0], v[1]), sum_fp64(v[2], v[3]));\n}\n\nvoid mat4_vec4_mul_fp64(vec2 b[16], vec2 a[4], out vec2 out_val[4]) {\n vec2 tmp[4];\n\n for (int i = 0; i < 4; i++)\n {\n for (int j = 0; j < 4; j++)\n {\n tmp[j] = b[j + i * 4];\n }\n vec4_dot_fp64(a, tmp, out_val[i]);\n }\n}\n"},function(e,t,n){"use strict"},function(e,t,n){"use strict";n(649);var r=n(647),i=n(648),o=r.a+"\n"+i.a;t.a={name:"fp64",vs:o,fs:null};r.a},function(e,t,n){"use strict";t.a=" // empty\n"},function(e,t,n){"use strict";t.a="#ifdef GL_ES\nprecision highp float;\n#endif\n\n#define LIGHT_MAX 4\n\nvarying vec3 lighting_vLightWeighting;\n\nvec4 lighting_apply(vec4 color) {\n // set color from texture\n return vec4(color.rgb * lighting_vLightWeighting, color.a);\n}\n\n// spec-map.fs\n\nuniform mat4 viewMatrix;\n\n\nvarying vec4 lighting_vColor;\nvarying vec4 lighting_vTransformedNormal;\nvarying vec4 lighting_vPosition;\n\nuniform float shininess;\nuniform bool enableSpecularMap;\nuniform bool enableLights;\n\nuniform vec3 ambientColor;\nuniform vec3 directionalColor;\nuniform vec3 lightingDirection;\n\nuniform vec3 lighting_uPointLocation[LIGHT_MAX];\nuniform vec3 lighting_uPointColor[LIGHT_MAX];\nuniform float lighting_uPointSpecularEnable[LIGHT_MAX];\nuniform vec3 lighting_uPointSpecularColor[LIGHT_MAX];\nuniform int numberPoints;\n\n\nvec3 lighting__calculate_light_weighting() {\n\treturn lighting__calculate_light_weighting(shininess);\n}\n\nvec3 lighting__calculate_light_weighting(shininess) {\n vec3 normal = vTransformedNormal.xyz;\n vec3 eyeDirection = normalize(-vPosition.xyz);\n\n vec3 specularLight = vec3(0., 0., 0.);\n vec3 diffuseLight = vec3(0., 0., 0.);\n\n for (int i = 0; i < LIGHT_MAX; i++) {\n if (i < numberPoints) {\n vec3 transformedPointLocation = (viewMatrix * vec4(lighting_uPointLocation[i], 1.0)).xyz;\n vec3 lightDirection = normalize(transformedPointLocation - vPosition.xyz);\n\n if (lighting_uPointSpecularEnable > 0.) {\n vec3 reflectionDirection = reflect(-lightDirection, normal);\n float specularLightWeighting =\n pow(max(dot(reflectionDirection, eyeDirection), 0.0), shininessVal);\n specularLight += specularLightWeighting * lighting_uPointSpecularColor[i];\n }\n\n float diffuseLightWeighting = max(dot(normal, lightDirection), 0.0);\n diffuseLight += diffuseLightWeighting * lighting_uPointColor[i];\n } else {\n break;\n }\n }\n\n return ambientColor + diffuseLight + specularLight;\n}\n\nvoid lighting_filterColor(fragmentColor) {\n if (!lighting_enable) {\n \treturn fragmentColor;\n } else {\n \tvec3 lightWeighting = lighting__calculate_light_weighting();\n \treturn vec4(fragmentColor.rgb * lightWeighting, fragmentColor.a);\n }\n}\n\n// render-tex.fs\n\nuniform vec3 material_uAmbientColor;\nuniform vec3 material_uDiffuseColor;\nuniform vec3 material_uSpecularColor;\nuniform vec3 material_uEmissiveColor;\n\nuniform bool hasTexture1;\nuniform sampler2D sampler1;\n\nuniform mat4 viewMatrix;\n\nvoid apply_lighting(color) {\n vec3 ambientLightWeighting = ambientColor;\n\n vec3 normal = vTransformedNormal.xyz;\n vec3 eyeDirection = normalize(-vPosition.xyz);\n\n vec3 specularLight = vec3(0.0, 0.0, 0.0);\n vec3 diffuseLight = vec3(0.0, 0.0, 0.0);\n\n for (int i = 0; i < LIGHT_MAX; i++) {\n if (i < numberPoints) {\n vec3 transformedPointLocation = (viewMatrix * vec4(pointLocation[i], 1.0)).xyz;\n vec3 lightDirection = normalize(transformedPointLocation - vPosition.xyz);\n\n if (enableSpecularHighlights) {\n vec3 reflectionDirection = reflect(-lightDirection, normal);\n float specularLightWeighting =\n pow(max(dot(reflectionDirection, eyeDirection), 0.0), shininess);\n specularLight += specularLightWeighting * pointSpecularColor[i];\n }\n\n float diffuseLightWeighting = max(dot(normal, lightDirection), 0.0);\n diffuseLight += diffuseLightWeighting * pointColor[i];\n } else {\n break;\n }\n }\n\n vec3 matAmbientColor = material_uAmbientColor * color.rgb;\n vec3 matDiffuseColor = material_uDiffuseColor * color.rgb;\n vec3 matSpecularColor = material_uSpecularColor * color.rgb;\n vec3 matEmissiveColor = material_uEmissiveColor * color.rgb;\n gl_FragColor = vec4(\n matAmbientColor * ambientLightWeighting\n + matDiffuseColor * diffuseLightWeighting\n + matSpecularColor * specularLightWeighting\n + matEmissiveColor,\n color.a\n );\n}\n\n/// frag-lighting\n\n vec3 lightWeighting;\n if (!enableLights) {\n lightWeighting = vec3(1.0, 1.0, 1.0);\n } else {\n vec3 lightDirection;\n float specularLightWeighting = 0.0;\n float diffuseLightWeighting = 0.0;\n vec3 specularLight = vec3(0.0, 0.0, 0.0);\n vec3 diffuseLight = vec3(0.0, 0.0, 0.0);\n\n vec3 transformedPointLocation;\n vec3 normal = vTransformedNormal.xyz;\n\n vec3 eyeDirection = normalize(-vPosition.xyz);\n vec3 reflectionDirection;\n\n vec3 pointWeight = vec3(0.0, 0.0, 0.0);\n\n for (int i = 0; i < LIGHT_MAX; i++) {\n if (i < numberPoints) {\n transformedPointLocation = (viewMatrix * vec4(pointLocation[i], 1.0)).xyz;\n lightDirection = normalize(transformedPointLocation - vPosition.xyz);\n\n if (enableSpecular[i] > 0.0) {\n reflectionDirection = reflect(-lightDirection, normal);\n specularLightWeighting = pow(max(dot(reflectionDirection, eyeDirection), 0.0), shininess);\n specularLight += specularLightWeighting * pointSpecularColor[i];\n }\n\n diffuseLightWeighting = max(dot(normal, lightDirection), 0.0);\n diffuseLight += diffuseLightWeighting * pointColor[i];\n } else {\n break;\n }\n }\n\n lightWeighting = ambientColor + diffuseLight + specularLight;\n }\n\n// reflection / refraction configs\nuniform float reflection;\nuniform float refraction;\n\n///\n // has cube texture then apply reflection\n // if (hasTextureCube1) {\n // vec3 nReflection = normalize(vReflection);\n // vec3 reflectionValue;\n // if (refraction > 0.0) {\n // reflectionValue = refract(nReflection, vNormal.xyz, refraction);\n // } else {\n // reflectionValue = -reflect(nReflection, vNormal.xyz);\n // }\n\n // // TODO(nico): check whether this is right.\n // vec4 cubeColor = textureCube(samplerCube1,\n // vec3(-reflectionValue.x, -reflectionValue.y, reflectionValue.z));\n // gl_FragColor = vec4(mix(gl_FragColor.xyz, cubeColor.xyz, reflection), 1.0);\n // }\n"},function(e,t,n){"use strict";t.a="#define LIGHT_MAX 4\n\n/*\n// lighting configuration\nuniform bool enableLights;\nuniform vec3 ambientColor;\nuniform vec3 directionalColor;\nuniform vec3 lightingDirection;\n\n// point lights configuration\nuniform vec3 pointLocation[LIGHT_MAX];\nuniform vec3 pointColor[LIGHT_MAX];\nuniform int numberPoints;\n\n// reflection / refraction configuration\nuniform bool useReflection;\n*/\n\nuniform bool lighting_uEnableLights;\nuniform vec3 lighting_uAmbientColor;\nuniform vec3 lighting_uDirection;\nuniform vec3 lighting_uDirectionalColor;\n\n// point lights configuration\nuniform int lighting_uPointCount;\nuniform vec3 lighting_uPointLocation[LIGHT_MAX];\nuniform vec3 lighting_uPointColor[LIGHT_MAX];\n\n// reflection / refraction configuration\nuniform bool lighting_uEnableReflections;\n\n// varyings\nvarying vec4 lighting_vPosition;\nvarying vec4 lighting_vNormal;\nvarying vec3 lighting_vColor;\nvarying vec3 lighting_vLightWeighting;\nvarying vec3 lighting_vReflection;\n\nvoid lighting_setPositionAndNormal(vec3 position, vec3 normal) {\n lighting_vPosition = worldMatrix * vec4(position, 1.);\n lighting_vNormal = worldInverseTransposeMatrix * vec4(normal, 1.);;\n}\n\nvoid lighting__getLightWeigting() {\n float directionalLightWeighting = max(dot(lighting_vNormal.xyz, lighting_uDirection), 0.);\n vec3 pointWeight = vec3(0., 0., 0.);\n for (int i = 0; i < LIGHT_MAX; i++) {\n if (i < numberPoints) {\n vec4 mvLightPosition = viewMatrix * vec4(lighting_uPointLocation[i], 1.);\n vec3 pointLightDirection = normalize(mvLightPosition.xyz - lighting_vPosition.xyz);\n pointWeight += max(dot(lighting_vNormal.xyz, pointLightDirection), 0.) * pointColor[i];\n } else {\n break;\n }\n }\n return ambientColor + (directionalColor * directionalLightWeighting) + pointWeight;\n}\n\nvoid lighting_apply(vec3 position, vec3 normal) {\n lighting_setPositionAndNormal(position, normal);\n\n // lighting code\n if(!lighting_uEnableLights) {\n lighting_vLightWeighting = vec3(1., 1., 1.);\n } else {\n lighting_vLightWeighting = lighting__getLightWeighting();\n }\n}\n\nvoid lighting_set_reflection(vec3 position) {\n // refraction / reflection code\n if (lighting_uEnableReflections) {\n lighting_vReflection = (viewInverseMatrix[3] - (worldMatrix * vec4(position, 1.))).xyz;\n } else {\n lighting_vReflection = vec3(1., 1., 1.);\n }\n}\n"},function(e,t,n){"use strict";var h=n(16),r=n(651),i=n(653),o=n(652),a=r.a+"\n"+i.a+"\n",s=r.a+"\n"+o.a+"\n";t.a={name:"lighting",vs:a,fs:s,getUniforms:function(e){var t,n,r,i,o=e.lightingEnable,a=void 0!==o&&o,s=e.lightingAmbientColor,u=void 0===s?[.2,.2,.2]:s,c=e.lightingDirection,l=void 0===c?[1,1,1]:c,f=(e.lightingDirectionalColor,e.lightingPointLights),d=void 0===f?[]:f;return Object.assign({lightingEnable:a,lightingAmbientColor:u},(n=(t=l).color,r=t.direction,i=new h.Vector3(r.x,r.y,r.z).normalize().scale(-1,-1,-1),{directionalColor:[n.r,n.g,n.b],lightingDirection:[i.x,i.y,i.z]}),function(e){var t=(e=e instanceof Array?e:[e]).length,n=[],r=[],i=[],o=[],a=!0,s=!1,u=void 0;try{for(var c,l=e[Symbol.iterator]();!(a=(c=l.next()).done);a=!0){var f=c.value,d=f.position,h=f.color,p=f.diffuse,v=f.specular,g=h||p;n.push(d.x,d.y,d.z),r.push(g.r,g.g,g.b),i.push(Number(Boolean(v))),v?o.push(v.r,v.g,v.b):o.push(0,0,0)}}catch(e){s=!0,u=e}finally{try{!a&&l.return&&l.return()}finally{if(s)throw u}}return{numberPoints:t,pointLocation:n,pointColor:r,enableSpecular:i,pointSpecularColor:o}}(d))}}},function(e,t,n){"use strict";n.d(t,"a",function(){return r}),n.d(t,"b",function(){return i});var r="#ifdef MODULE_LOGDEPTH\n logdepth_adjustPosition(gl_Position);\n#endif\n",i="#ifdef MODULE_MATERIAL\n gl_FragColor = material_filterColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_LIGHTING\n gl_FragColor = lighting_filterColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_FOG\n gl_FragColor = fog_filterColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_PICKING\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_LOGDEPTH\n logdepth_setFragDepth();\n#endif\n"},function(e,t,n){"use strict";var r={pickingSelectedColor:null,pickingHighlightColor:new Uint8Array([0,255,255,255]),pickingThreshold:1,pickingActive:!1};t.a={name:"picking",vs:"uniform vec3 picking_uSelectedColor;\nuniform float picking_uThreshold;\nuniform bool picking_uSelectedColorValid;\n\nvarying vec4 picking_vRGBcolor_Aselected;\n\nconst float COLOR_SCALE = 1. / 255.;\n\nbool isVertexPicked(vec3 vertexColor) {\n return\n picking_uSelectedColorValid &&\n abs(vertexColor.r - picking_uSelectedColor.r) < picking_uThreshold &&\n abs(vertexColor.g - picking_uSelectedColor.g) < picking_uThreshold &&\n abs(vertexColor.b - picking_uSelectedColor.b) < picking_uThreshold;\n}\n\nvoid picking_setPickingColor(vec3 pickingColor) {\n // Do the comparison with selected item color in vertex shader as it should mean fewer compares\n picking_vRGBcolor_Aselected.a =\n float(isVertexPicked(pickingColor));\n\n // Stores the picking color so that the fragment shader can render it during picking\n picking_vRGBcolor_Aselected.rgb = pickingColor * COLOR_SCALE;\n}\n",fs:"uniform bool picking_uActive; // true during rendering to offscreen picking buffer\nuniform vec3 picking_uSelectedColor;\nuniform vec4 picking_uHighlightColor;\n\nvarying vec4 picking_vRGBcolor_Aselected;\n\nconst float COLOR_SCALE = 1. / 255.;\n\n/*\n * Returns highlight color if this item is selected.\n */\nvec4 picking_filterHighlightColor(vec4 color) {\n bool selected = bool(picking_vRGBcolor_Aselected.a);\n return selected ? (picking_uHighlightColor * COLOR_SCALE) : color;\n}\n\n/*\n * Returns picking color if picking enabled else unmodified argument.\n */\nvec4 picking_filterPickingColor(vec4 color) {\n vec3 pickingColor = picking_vRGBcolor_Aselected.rgb;\n return picking_uActive ? vec4(pickingColor, 1.0) : color;\n}\n",getUniforms:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:r,t={};if(void 0!==e.pickingSelectedColor)if(null===e.pickingSelectedColor)t.picking_uSelectedColorValid=0;else{var n=[e.pickingSelectedColor[0],e.pickingSelectedColor[1],e.pickingSelectedColor[2]];t.picking_uSelectedColorValid=1,t.picking_uSelectedColor=n}return void 0!==e.pickingHighlightColor&&(t.picking_uHighlightColor=e.pickingHighlightColor),void 0!==e.pickingThreshold&&(t.picking_uThreshold=e.pickingThreshold),void 0!==e.pickingActive&&(t.picking_uActive=e.pickingActive?1:0),t}}},function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n(659),i=n(658),o={vs:r.a,fs:i.a,defaultUniforms:{}}},function(e,t,n){"use strict";t.a="#define SHADER_NAME luma-modular-fragment\n\n#ifdef GL_ES\nprecision highp float;\n#endif\n\n// varyings\nvarying vec4 vColor;\n\nvoid main(){\n gl_FragColor = vec4(1., 0., 1., 1.);\n\n#ifdef MODULE_DIFFUSE\n gl_FragColor = diffuse_filterColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_MATERIAL\n gl_FragColor = material_filterColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_LIGHTING\n gl_FragColor = lighting_filterColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_FOG\n gl_FragColor = fog_filterColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_PICKING\n gl_FragColor = picking_filterHighlightColor(gl_FragColor);\n gl_FragColor = picking_filterPickingColor(gl_FragColor);\n#endif\n\n#ifdef MODULE_LOGDEPTH\n logdepth_setFragDepth(gl_Position);\n#endif\n}\n"},function(e,t,n){"use strict";t.a="#define SHADER_NAME luma_modular_vertex\n\n// object attributes\nattribute vec3 positions;\nattribute vec3 normals;\nattribute vec4 colors;\nattribute vec2 texCoords;\nattribute vec3 pickingColors;\n\nvoid main(void) {\n\n // Set up position\n#ifdef MODULE_GEOMETRY\n geometry_setPosition(positions);\n geometry_setNormal(normals);\n#endif\n\n#ifdef MODULE_PROJECT\n project_setPositionAndNormal_Model(positions, normals);\n gl_Position = project_model_to_clipspace(positions);\n#endif\n\n // Set up depth\n#ifdef MODULE_LOGDEPTH\n logdepth_adjustPosition(gl_Position);\n#endif\n\n#ifdef MODULE_DIFFUSE\n diffuse_setTextureCoordinate(texCoords);\n#endif\n\n // Set up color calculations\n#ifdef MODULE_MATERIAL\n material_setDiffuseColor(colors);\n material_setDiffuseTextureCoordinates(texCoords);\n#endif\n\n#ifdef MODULE_LIGHTING\n lighting_setPositionAndNormal(positions, normals);\n lighting_apply_light(positions);\n lighting_apply_reflection(positions);\n#endif\n\n#ifdef MODULE_PICKING\n picking_setPickingColor(pickingColors);\n#endif\n\n}\n"},function(e,t,n){"use strict"},function(e,t,n){"use strict";t.a=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"id";o[e]=o[e]||1;var t=o[e]++;return e+"-"+t},t.b=function(e){return i()("number"==typeof e,"Input must be a number"),e&&0==(e&e-1)},t.c=function(e){var t=!0;for(var n in e){t=!1;break}return t};var r=n(1),i=n.n(r),o={}},function(e,t,n){"use strict";t.a=function(e,t){if("string"!=typeof t)return t;var n=Number(t);if(!isNaN(n))return n;t=t.replace(/^.*\./,"");var r=e[t];return i()(void 0!==r,"Accessing undefined constant GL."+t),r},t.b=function(e,t){for(var n in t=Number(t),e)if(e[n]===t)return"gl."+n;return String(t)},t.c=function(e,t){for(var n in i()(void 0!==t,"undefined key"),t=Number(t),e)if(e[n]===t)return"gl."+n;return String(t)};var r=n(1),i=n.n(r)},function(e,t,n){"use strict";t.c=l,t.a=function(e){var t=e.width,n=void 0===t?800:t,r=e.height,i=void 0===r?600:r,o=e.id,a=void 0===o?"gl-canvas":o,s=e.insert,u=void 0===s||s,c=document.createElement("canvas");c.id=a,c.style.width=Number.isFinite(n)?n+"px":"100%",c.style.height=Number.isFinite(i)?i+"px":"100%",u&&l().then(function(e){var t=e.body;t.insertBefore(c,t.firstChild)});return c},t.b=function(e){var t=e.id;if(r)return document.getElementById(t);throw new Error("createGLContext called on canvas '"+t+"' before page was loaded")},t.d=function(e,t){var n=t.useDevicePixelRatio,r=void 0===n?null:n,i=t.useDevicePixels,o=void 0===i||i;null!==r&&(s.b.deprecated("useDevicePixelRatio","useDevicePixels"),o=r);var a=function(e,t){var n=t.useDevicePixels,r=void 0===n||n;"useDevicePixelRatio"in t&&(s.b.deprecated("useDevicePixelRatio","useDevicePixels"),r=t.useDevicePixels||t.useDevicePixelRatio);var i=r&&window.devicePixelRatio||1,o=(a=e,{width:a.clientWidth,height:a.clientHeight});var a;return{width:Math.floor(o.width*i),height:Math.floor(o.height*i),devicePixelRatio:i}}(e,{useDevicePixels:o});a.width===e.width&&a.height===e.height||(e.width=a.width,e.height=a.height)};var s=n(8),r=s.a&&"complete"===document.readyState,i=s.a?new Promise(function(e,t){r?e(document):window.onload=function(){r=!0,e(document)}}):Promise.resolve({});function l(){return i}},function(e,t,n){"use strict";t.b=function(e){var t=e.canvas,n=e.opts,r=void 0===n?{}:n,i=e.onError,o=void 0===i?function(e){return null}:i;function a(e){o("WebGL context: "+(e.statusMessage||"Unknown error"))}t.addEventListener("webglcontextcreationerror",a,!1);var s=r.webgl1,u=void 0===s||s,c=r.webgl2,l=void 0===c||c,f=null;l&&(f=(f=f||t.getContext("webgl2",r))||t.getContext("experimental-webgl2",r));u&&(f=(f=f||t.getContext("webgl",r))||t.getContext("experimental-webgl",r));return t.removeEventListener("webglcontextcreationerror",a,!1),f||o("Failed to create "+(l&&!u?"WebGL2":"WebGL")+" context")},t.a=function(e){var t=e.onContextCreate,r=void 0===t?function(){return null}:t,n=e.onContextCreated,i=void 0===n?function(){}:n;if(a()(r||i),"undefined"!=typeof HTMLCanvasElement){var o=HTMLCanvasElement.prototype.getContext;HTMLCanvasElement.prototype.getContext=function(e,t){var n=void 0;return"webgl"===e&&(n=r({canvas:this,type:e,opts:t,getContext:o.bind(this)})),(n=n||o.call(this,e,t))instanceof WebGLRenderingContext&&i({canvas:this,context:n,type:e,opts:t}),n}}};var r=n(1),a=n.n(r)},function(e,t,p){"use strict";t.a=n;var v=p(264);function n(e,t,n){for(var r=e.split(/\r?\n/),i={},o={},a=p.i(v.a)(t)||"(unnamed)",s=p.i(v.b)(n)+" shader "+a,u=0;u<r.length;u++){var c=r[u];if(!(c.length<=1)){var l=c.split(":"),f=l[0],d=parseInt(l[2],10);if(isNaN(d))throw new Error("GLSL compilation error in "+s+": "+e);"WARNING"!==f?i[d]=c:o[d]=c}}var h=function(e){var o=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1,a=2<arguments.length&&void 0!==arguments[2]?arguments[2]:": ",t=e.split(/\r?\n/),s=String(t.length+o-1).length;return t.map(function(e,t){var n=t+o,r=String(n).length,i=y(n,s-r);return i+a+e})}(t);return{shaderName:s,errors:g(i,h),warnings:g(o,h)}}function g(e,t){for(var n="",r=0;r<t.length;r++){var i=t[r];if((e[r+3]||e[r+2]||e[r+1])&&(n+=i+"\n",e[r+1])){var o=e[r+1],a=o.split(":",3),s=a[0],u=parseInt(a[1],10)||0;n+=y("^^^ "+s+": "+o.substring(a.join(":").length+1).trim()+"\n\n",u)}}return n}function y(e,t){for(var n="",r=0;r<t;++r)n+=" ";return""+n+e}},function(e,t,n){"use strict";t.a=function(e,t,n){var r=l[n],i="function"==typeof r?r(e,t,n):r;return void 0!==i?i:t(n)};var r,i=n(46);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var a="OES_element_index",s="WEBGL_draw_buffers",u="WEBGL_debug_renderer_info",c=function(e){return f(e)?void 0:0},l=(o(r={},i.a.READ_BUFFER,function(e){return f(e)?void 0:i.a.COLOR_ATTACHMENT0}),o(r,35723,function(e){return f(e)?void 0:4352}),o(r,i.a.RASTERIZER_DISCARD,c),o(r,i.a.SAMPLES,c),o(r,36795,function(e,t){var n=f(e)?e.getExtension("EXT_disjoint_timer_query_webgl2"):e.getExtension("EXT_disjoint_timer_query");return n&&n.GPU_DISJOINT_EXT?t(n.GPU_DISJOINT_EXT):0}),o(r,37445,function(e,t){var n=e.getExtension(u);return t(n&&n.UNMASKED_VENDOR_WEBGL||i.a.VENDOR)}),o(r,37446,function(e,t){var n=e.getExtension(u);return t(n&&n.UNMASKED_RENDERER_WEBGL||i.a.RENDERER)}),o(r,34047,function(e,t){var n=e.luma.extensions.EXT_texture_filter_anisotropic;return n?t(n.MAX_TEXTURE_MAX_ANISOTROPY_EXT):1}),o(r,i.a.MAX_3D_TEXTURE_SIZE,c),o(r,i.a.MAX_ARRAY_TEXTURE_LAYERS,c),o(r,i.a.MAX_CLIENT_WAIT_TIMEOUT_WEBGL,c),o(r,i.a.MAX_COLOR_ATTACHMENTS,function(e,t){if(!f(e)){var n=e.getExtension(s);return n?t(n.MAX_COLOR_ATTACHMENTS_WEBGL):0}}),o(r,i.a.MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS,c),o(r,i.a.MAX_COMBINED_UNIFORM_BLOCKS,c),o(r,i.a.MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS,c),o(r,i.a.MAX_DRAW_BUFFERS,function(e){if(!f(e)){var t=e.getExtension(s);return t?t.MAX_DRAW_BUFFERS_WEBGL:0}}),o(r,i.a.MAX_ELEMENT_INDEX,function(e){return e.getExtension(a)?2147483647:65535}),o(r,i.a.MAX_ELEMENTS_INDICES,function(e){return e.getExtension(a)?16777216:65535}),o(r,i.a.MAX_ELEMENTS_VERTICES,function(e){return 16777216}),o(r,i.a.MAX_FRAGMENT_INPUT_COMPONENTS,c),o(r,i.a.MAX_FRAGMENT_UNIFORM_BLOCKS,c),o(r,i.a.MAX_FRAGMENT_UNIFORM_COMPONENTS,c),o(r,i.a.MAX_SAMPLES,c),o(r,i.a.MAX_SERVER_WAIT_TIMEOUT,c),o(r,i.a.MAX_TEXTURE_LOD_BIAS,c),o(r,i.a.MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS,c),o(r,i.a.MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS,c),o(r,i.a.MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS,c),o(r,i.a.MAX_UNIFORM_BLOCK_SIZE,c),o(r,i.a.MAX_UNIFORM_BUFFER_BINDINGS,c),o(r,i.a.MAX_VARYING_COMPONENTS,c),o(r,i.a.MAX_VERTEX_OUTPUT_COMPONENTS,c),o(r,i.a.MAX_VERTEX_UNIFORM_BLOCKS,c),o(r,i.a.MAX_VERTEX_UNIFORM_COMPONENTS,c),o(r,i.a.MIN_PROGRAM_TEXEL_OFFSET,c),o(r,i.a.MAX_PROGRAM_TEXEL_OFFSET,c),o(r,i.a.UNIFORM_BUFFER_OFFSET_ALIGNMENT,c),r);function f(e){return e&&32874===e.TEXTURE_BINDING_3D}},function(e,t,r){"use strict";var i=r(7),o=r(62),a=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var n=function(e){function n(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);!function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,t));throw new Error("Texture2DArray not yet implemented")}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,o["a"]),a(n,null,[{key:"isSupported",value:function(e){return r.i(i.b)(e)}}]),n}();t.a=n},function(e,t,o){"use strict";var y=o(38),i=o(7),a=o(68),n=o(62),_=o(67),s=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var r=function(e){function r(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),o.i(i.g)(e);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,e,Object.assign({},t,{target:t.target||y.a.TEXTURE_3D})));return n.width=null,n.height=null,n.depth=null,Object.seal(n),n.setImageData(t),t.generateMipmap&&n.generateMipmap(),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(r,n["a"]),s(r,null,[{key:"isSupported",value:function(e){return o.i(i.b)(e)}}]),s(r,[{key:"initialize",value:function(){var e=this,t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};this.opts=Object.assign({},this.opts,t);var n=this.opts,r=n.pixels,i=n.settings;i&&(o.i(a.f)(i,function(){r&&e.setImage3D(e.opts)}),this.setParameters(t))}},{key:"setImage3D",value:function(e){var t=e.level,n=void 0===t?0:t,r=e.internalformat,i=void 0===r?y.a.RGBA:r,o=e.width,a=e.height,s=e.depth,u=void 0===s?1:s,c=e.border,l=void 0===c?0:c,f=e.format,d=e.type,h=void 0===d?y.a.UNSIGNED_BYTE:d,p=e.offset,v=void 0===p?0:p,g=e.pixels;ArrayBuffer.isView(g)?this.gl.texImage3D(this.target,n,i,o,a,u,l,f,h,g):g instanceof _.a&&(this.gl.bindBuffer(y.a.PIXEL_UNPACK_BUFFER,g.handle),this.gl.texImage3D(this.target,n,i,o,a,u,l,f,h,v),this.gl.bindBuffer(y.a.PIXEL_UNPACK_BUFFER,g.handle))}}]),r}();t.a=r},function(e,t,n){"use strict";var r,i=n(1),s=n.n(i),u=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var c=5126,l=(a(r={},c,[c,1]),a(r,35664,[c,2]),a(r,35665,[c,3]),a(r,35666,[c,4]),a(r,5124,[5124,1]),a(r,35667,[5124,2]),a(r,35668,[5124,3]),a(r,35669,[5124,4]),a(r,5125,[5125,1]),a(r,36294,[5125,2]),a(r,36295,[5125,3]),a(r,36296,[5125,4]),a(r,35670,[c,1]),a(r,35671,[c,2]),a(r,35672,[c,3]),a(r,35673,[c,4]),a(r,35674,[c,8]),a(r,35685,[c,8]),a(r,35686,[c,8]),a(r,35675,[c,12]),a(r,35687,[c,12]),a(r,35688,[c,12]),a(r,35676,[c,16]),a(r,35689,[c,16]),a(r,35690,[c,16]),r),f=function(){function i(e){var t;for(var n in function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),this.layout={},this.size=0,e)this._addUniform(n,e[n]);var r=new Float32Array(this.size);this.typedArray=(a(t={},c,r),a(t,5124,new Int32Array(r.buffer)),a(t,5125,new Uint32Array(r.buffer)),t)}return o(i,[{key:"getBytes",value:function(){return 4*this.size}},{key:"getData",value:function(){return this.typedArray[c]}},{key:"getSubData",value:function(e){var t=void 0,n=void 0;if(void 0===e)t=this.data,n=0;else{var r=this.offsets[e],i=r+this.sizes[e];t=this.data.subarray(r,i),n=4*r}return{data:t,offset:n}}},{key:"setUniforms",value:function(e){for(var t in e)this._setValue(t,e[t]);return this}},{key:"_setValue",value:function(e,t){var n=this.layout[e];s()(n,"UniformLayoutStd140 illegal argument");var r=this.typedArray[n.type];1===n.size?r[n.offset]=t:r.set(t,n.offset)}},{key:"_addUniform",value:function(e,t){var n=l[t];s()(n,"UniformBufferLayout illegal argument");var r=u(n,2),i=r[0],o=r[1],a=this.size;this.size=this._alignTo(this.size,o),this.size+=o,this.layout[e]={type:i,size:o,offset:a}}},{key:"_alignTo",value:function(e,t){switch(t){case 1:return e;case 2:return e+e%2;default:return e+(4-e%4)%4}}}]),i}();t.a=f},function(e,t,v){"use strict";var n=v(112),g=v(31),j=v(278),r=v(279),o=v(113),a=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var D="Unknown Euler angle order",y=.99999;var i=function(e){function F(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:F.DefaultOrder;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,F);var i=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(F.__proto__||Object.getPrototypeOf(F)).call(this));return 0<arguments.length&&Array.isArray(arguments[0])?i.fromVector3.apply(i,arguments):i.set(e,t,n,r),i}var i=Number.isFinite;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(F,e),a(F,[{key:"ELEMENTS",get:function(){return 4}}],[{key:"rotationOrder",value:function(e){return F.RotationOrders[e]}},{key:"ZYX",get:function(){return 0}},{key:"YXZ",get:function(){return 1}},{key:"XZY",get:function(){return 2}},{key:"ZXY",get:function(){return 3}},{key:"YZX",get:function(){return 4}},{key:"XYZ",get:function(){return 5}},{key:"RollPitchYaw",get:function(){return 0}},{key:"DefaultOrder",get:function(){return F.ZYX}},{key:"RotationOrders",get:function(){return["ZYX","YXZ","XZY","ZXY","YZX","XYZ"]}}]),a(F,[{key:"copy",value:function(e){for(var t=0;t<3;++t)this[t]=e[t];return this[3]=i(e[3])||this.order,this.check(),this}},{key:"set",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:0,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:0,r=arguments[3];return this[0]=e,this[1]=t,this[2]=n,this[3]=i(r)?r:this[3],this.check(),this}},{key:"validate",value:function(){return 0<=(e=this[3])&&e<6&&i(this[0])&&i(this[1])&&i(this[2]);var e}},{key:"toArray",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[],t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0;return e[t]=this[0],e[t+1]=this[1],e[t+2]=this[2],e}},{key:"toArray4",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[],t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0;return e[t]=this[0],e[t+1]=this[1],e[t+2]=this[2],e[t+3]=this[3],e}},{key:"toVector3",value:function(e){return e?e.set(this[0],this[1],this[2]):new o.a(this[0],this[1],this[2])}},{key:"fromVector3",value:function(e,t){return this.set(e[0],e[1],e[2],i(t)?t:this[3])}},{key:"fromArray",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0;return this[0]=e[0+t],this[1]=e[1+t],this[2]=e[2+t],void 0!==e[3]&&(this[3]=e[3]),this.check(),this}},{key:"fromRollPitchYaw",value:function(e,t,n){return this.set(e,t,n,F.ZYX)}},{key:"fromQuaternion",value:function(e,t){return this._fromRotationMatrix(j.a.fromQuaternion(e),t),this.check(),this}},{key:"fromRotationMatrix",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:F.DefaultOrder;return this._fromRotationMatrix(e,t),this.check(),this}},{key:"getRotationMatrix",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:new j.a;return this._getRotationMatrix(e),e}},{key:"getQuaternion",value:function(){var e=new r.a;switch(this[4]){case F.XYZ:return e.rotateX(this[0]).rotateY(this[1]).rotateZ(this[2]);case F.YXZ:return e.rotateY(this[0]).rotateX(this[1]).rotateZ(this[2]);case F.ZXY:return e.rotateZ(this[0]).rotateX(this[1]).rotateY(this[2]);case F.ZYX:return e.rotateZ(this[0]).rotateY(this[1]).rotateX(this[2]);case F.YZX:return e.rotateY(this[0]).rotateZ(this[1]).rotateX(this[2]);case F.XZY:return e.rotateX(this[0]).rotateZ(this[1]).rotateY(this[2]);default:throw new Error(D)}}},{key:"_fromRotationMatrix",value:function(e){var t=Math.atan2,n=Math.abs,r=Math.asin,i=1<arguments.length&&void 0!==arguments[1]?arguments[1]:F.DefaultOrder,o=e.elements,a=o[0],s=o[4],u=o[8],c=o[1],l=o[5],f=o[9],d=o[2],h=o[6],p=o[10];switch(i=i||this[3]){case F.XYZ:this[1]=r(v.i(g.e)(u,-1,1)),n(u)<y?(this[0]=t(-f,p),this[2]=t(-s,a)):(this[0]=t(h,l),this[2]=0);break;case F.YXZ:this[0]=r(-v.i(g.e)(f,-1,1)),n(f)<y?(this[1]=t(u,p),this[2]=t(c,l)):(this[1]=t(-d,a),this[2]=0);break;case F.ZXY:this[0]=r(v.i(g.e)(h,-1,1)),n(h)<y?(this[1]=t(-d,p),this[2]=t(-s,l)):(this[1]=0,this[2]=t(c,a));break;case F.ZYX:this[1]=r(-v.i(g.e)(d,-1,1)),n(d)<y?(this[0]=t(h,p),this[2]=t(c,a)):(this[0]=0,this[2]=t(-s,l));break;case F.YZX:this[2]=r(v.i(g.e)(c,-1,1)),n(c)<y?(this[0]=t(-f,l),this[1]=t(-d,a)):(this[0]=0,this[1]=t(u,p));break;case F.XZY:this[2]=r(-v.i(g.e)(s,-1,1)),n(s)<y?(this[0]=t(h,l),this[1]=t(u,a)):(this[0]=t(-f,p),this[1]=0);break;default:throw new Error(D)}return this[3]=i,this}},{key:"_getRotationMatrix",value:function(){var e=Math.sin,t=Math.cos,n=new j.a,r=this.x,i=this.y,o=this.z,a=t(r),s=t(i),u=t(o),c=e(r),l=e(i),f=e(o);switch(this[3]){case F.XYZ:var d=a*u,h=a*f,p=c*u,v=c*f;n[0]=s*u,n[4]=-s*f,n[8]=l,n[1]=h+p*l,n[5]=d-v*l,n[9]=-c*s,n[2]=v-d*l,n[6]=p+h*l,n[10]=a*s;break;case F.YXZ:var g=s*u,y=s*f,_=l*u,m=l*f;n[0]=g+m*c,n[4]=_*c-y,n[8]=a*l,n[1]=a*f,n[5]=a*u,n[9]=-c,n[2]=y*c-_,n[6]=m+g*c,n[10]=a*s;break;case F.ZXY:var b=s*u,E=s*f,w=l*u,P=l*f;n[0]=b-P*c,n[4]=-a*f,n[8]=w+E*c,n[1]=E+w*c,n[5]=a*u,n[9]=P-b*c,n[2]=-a*l,n[6]=c,n[10]=a*s;break;case F.ZYX:var S=a*u,A=a*f,T=c*u,x=c*f;n[0]=s*u,n[4]=T*l-A,n[8]=S*l+x,n[1]=s*f,n[5]=x*l+S,n[9]=A*l-T,n[2]=-l,n[6]=c*s,n[10]=a*s;break;case F.YZX:var O=a*s,R=a*l,C=c*s,k=c*l;n[0]=s*u,n[4]=k-O*f,n[8]=C*f+R,n[1]=f,n[5]=a*u,n[9]=-c*u,n[2]=-l*u,n[6]=R*f+C,n[10]=O-k*f;break;case F.XZY:var M=a*s,L=a*l,I=c*s,N=c*l;n[0]=s*u,n[4]=-f,n[8]=l*u,n[1]=M*f+N,n[5]=a*u,n[9]=L*f-I,n[2]=I*f-L,n[6]=c*u,n[10]=N*f+M;break;default:throw new Error(D)}return n[3]=0,n[7]=0,n[11]=0,n[12]=0,n[13]=0,n[14]=0,n[15]=1,this}},{key:"x",get:function(){return this[0]},set:function(e){return this[0]=v.i(g.g)(e)}},{key:"y",get:function(){return this[1]},set:function(e){return this[1]=v.i(g.g)(e)}},{key:"z",get:function(){return this[2]},set:function(e){return this[2]=v.i(g.g)(e)}},{key:"alpha",get:function(){return this[0]},set:function(e){return this[0]=v.i(g.g)(e)}},{key:"beta",get:function(){return this[1]},set:function(e){return this[1]=v.i(g.g)(e)}},{key:"gamma",get:function(){return this[2]},set:function(e){return this[2]=v.i(g.g)(e)}},{key:"phi",get:function(){return this[0]},set:function(e){return this[0]=v.i(g.g)(e)}},{key:"theta",get:function(){return this[1]},set:function(e){return this[1]=v.i(g.g)(e)}},{key:"psi",get:function(){return this[2]},set:function(e){return this[2]=v.i(g.g)(e)}},{key:"roll",get:function(){return this[0]},set:function(e){return this[0]=v.i(g.g)(e)}},{key:"pitch",get:function(){return this[1]},set:function(e){return this[1]=v.i(g.g)(e)}},{key:"yaw",get:function(){return this[2]},set:function(e){return this[2]=v.i(g.g)(e)}},{key:"order",get:function(){return this[3]},set:function(e){return this[3]=function(e){if(e<0&&6<=e)throw new Error(D);return e}(e)}}]),F}(n.a);t.a=i},function(e,t,o){"use strict";var a=o(31),n=o(113),r=o(241),i=o.n(r),s=o(277),l=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},f=function(){function r(e,t){for(var n,r=0;r<t.length;r++)(n=t[r]).enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var u=function(){function u(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.phi,n=e.theta,r=e.radius,i=e.bearing,o=e.pitch,a=(e.altitude,e.radiusScale),s=void 0===a?6371e3:a;(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")})(this,u),0===arguments.length?(this.phi=0,this.theta=0,this.radius=1):c(t)||c(n)?(this.phi=t||0,this.theta=n||0):(c(i)||c(o))&&(this.bearing=i||0,this.pitch=o||0),this.radius=r||1,this.radiusScale=s||1,this.check()}var t=Math.PI,c=Number.isFinite;return f(u,[{key:"toString",value:function(){return this.formatString(a.a)}},{key:"formatString",value:function(e){var t=e.printTypes,n=(e.printDegrees,a.b);return(t?"Spherical":"")+"[rho:"+n(this.radius)+",theta:"+n(this.theta)+",phi:"+n(this.phi)+"]"}},{key:"equals",value:function(e){return o.i(a.c)(this.radius,e.radius)&&o.i(a.c)(this.theta,e.theta)&&o.i(a.c)(this.phi,e.phi)}},{key:"exactEquals",value:function(e){return this.radius===e.radius&&this.theta===e.theta&&this.phi===e.phi}},{key:"set",value:function(e,t,n){return this.radius=e,this.phi=t,this.theta=n,this.check()}},{key:"clone",value:function(){return(new this.constructor).copy(this)}},{key:"copy",value:function(e){return this.radius=e.radius,this.phi=e.phi,this.theta=e.theta,this.check()}},{key:"fromLngLatZ",value:function(e){var t=l(e,3),n=t[0],r=t[1],i=t[2];this.radius=1+i/this.radiusScale,this.phi=o.i(a.d)(r),this.theta=o.i(a.d)(n)}},{key:"fromVector3",value:function(e){return this.radius=i()(e),0===this.radius?(this.theta=0,this.phi=0):(this.theta=Math.atan2(e[0],e[1]),this.phi=Math.acos(o.i(a.e)(e[2]/this.radius,-1,1))),this.check()}},{key:"toVector3",value:function(){return new n.a(0,0,this.radius).rotateX({radians:this.theta}).rotateZ({radians:this.phi})}},{key:"makeSafe",value:function(){this.phi=Math.max(1e-6,Math.min(t-1e-6,this.phi))}},{key:"check",value:function(){return o.i(s.a)(c(this.phi)&&c(this.theta)&&0<this.radius),this}},{key:"bearing",get:function(){return 180-o.i(a.f)(this.phi)},set:function(e){this.phi=t-o.i(a.d)(e)}},{key:"pitch",get:function(){return o.i(a.f)(this.theta)},set:function(e){this.theta=o.i(a.d)(e)}},{key:"longitude",get:function(){return o.i(a.f)(this.phi)}},{key:"latitude",get:function(){return o.i(a.f)(this.theta)}},{key:"lng",get:function(){return o.i(a.f)(this.phi)}},{key:"lat",get:function(){return o.i(a.f)(this.theta)}},{key:"z",get:function(){return(this.radius-1)*this.radiusScale}}]),u}();t.a=u},function(e,t,n){"use strict";var o=n(283),a=n(675),s=n(674),u=n(673),c=n(114),i=n(676),l=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();function f(e){e.preventDefault()}var r=function(){function r(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),this.options=t,this.eventHandlers=[],this._onBasicInput=this._onBasicInput.bind(this),this._onOtherEvent=this._onOtherEvent.bind(this),this.setElement(e);var n=t.events;n&&this.on(n)}return l(r,[{key:"setElement",value:function(e){var i=this;if(this.element&&this.destroy(),this.element=e){var t=this.options,n=t.Manager||o.a;this.manager=new n(e,{recognizers:t.recognizers||c.a}).on("hammer.input",this._onBasicInput),t.recognizers||Object.keys(c.b).forEach(function(e){var t=i.manager.get(e);t&&c.b[e].forEach(function(e){t.recognizeWith(e)})}),this.wheelInput=new a.a(e,this._onOtherEvent,{enable:!1}),this.moveInput=new s.a(e,this._onOtherEvent,{enable:!1}),this.keyInput=new u.a(e,this._onOtherEvent,{enable:!1}),t.rightButton&&e.addEventListener("contextmenu",f),this.eventHandlers.forEach(function(e){var t=e.recognizerName,n=e.eventAlias,r=e.wrappedHandler;i._toggleRecognizer(t,!0),i.manager.on(n,r)})}}},{key:"destroy",value:function(){this.element&&(this.element.removeEventListener("contextmenu",f),this.wheelInput.destroy(),this.moveInput.destroy(),this.keyInput.destroy(),this.manager.destroy(),this.wheelInput=null,this.moveInput=null,this.keyInput=null,this.manager=null,this.element=null)}},{key:"on",value:function(e,t,n){if("string"==typeof e)this._addEventHandler(e,t,n);else for(var r in n=t,e)this._addEventHandler(r,e[r],n)}},{key:"off",value:function(e,t){if("string"==typeof e)this._removeEventHandler(e,t);else for(var n in e)this._removeEventHandler(n,e[n])}},{key:"_toggleRecognizer",value:function(n,r){var i=this.manager;if(i){var e=i.get(n);if(e){e.set({enable:r});var t=c.c[n];t&&!this.options.recognizers&&t.forEach(function(e){var t=i.get(e);r?t.requireFailure(n):t.dropRequireFailure(n)})}this.wheelInput.enableEventType(n,r),this.moveInput.enableEventType(n,r),this.keyInput.enableEventType(n,r)}}},{key:"_addEventHandler",value:function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,r=this.manager,i=this.eventHandlers,o=this._wrapEventHandler(e,t,n),a=c.d[e]||e,s=c.e[a]||a;this._toggleRecognizer(s,!0);var u=i.filter(function(e){return e.eventAlias===a&&e.srcElement!==n&&(!e.srcElement||e.srcElement.contains(n))});i.push({event:e,eventAlias:a,recognizerName:s,srcElement:n,handler:t,wrappedHandler:o}),u.forEach(function(e){return r.off(a,e.wrappedHandler)}),r&&r.on(a,o),u.forEach(function(e){return r.on(a,e.wrappedHandler)})}},{key:"_removeEventHandler",value:function(e,t){for(var n=this.manager,r=this.eventHandlers,i=!1,o=r.length;o--;){var a=r[o];a.event===e&&a.handler===t&&(n&&n.off(a.eventAlias,a.wrappedHandler),r.splice(o,1),i=!0)}if(i){var s=c.d[e]||e,u=c.e[s]||s;r.find(function(e){return e.recognizerName===u})||this._toggleRecognizer(u,!1)}}},{key:"_wrapEventHandler",value:function(n,r,i){var o=this;return function(e){var t=e.mjolnirEvent;(t||(t=o._normalizeEvent(e),e.mjolnirEvent=t),t.handled&&t.handled!==i)||(!i||i.contains(e.srcEvent.target))&&r(Object.assign({},t,{type:n,stopPropagation:function(){t.handled||(t.handled=i)}}))}}},{key:"_normalizeEvent",value:function(e){var t=this.element;return Object.assign({},e,n.i(i.a)(e),n.i(i.b)(e,t),{handled:!1,rootElement:t})}},{key:"_onBasicInput",value:function(e){var t=e.srcEvent,n=c.f[t.type];n&&this.manager.emit(n,e)}},{key:"_onOtherEvent",value:function(e){this.manager.emit(e.type,e)}}]),r}();t.a=r},function(e,t,n){"use strict";var r=n(114),o=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var a=r.g.KEY_EVENTS,i=function(){function i(t,e){var n=this,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),this.element=t,this.callback=e,this.options=Object.assign({enable:!0},r),this.enableDownEvent=this.options.enable,this.enableUpEvent=this.options.enable,this.events=a.concat(r.events||[]),this.handleEvent=this.handleEvent.bind(this),t.tabIndex=1,t.style.outline="none",this.events.forEach(function(e){return t.addEventListener(e,n.handleEvent)})}return o(i,[{key:"destroy",value:function(){var t=this;this.events.forEach(function(e){return t.element.removeEventListener(e,t.handleEvent)})}},{key:"enableEventType",value:function(e,t){"keydown"===e&&(this.enableDownEvent=t),"keyup"===e&&(this.enableUpEvent=t)}},{key:"handleEvent",value:function(e){var t=e.target||e.srcElement;"INPUT"===t.tagName&&"text"===t.type||"TEXTAREA"===t.tagName||(this.enableDownEvent&&"keydown"===e.type&&this.callback({type:"keydown",srcEvent:e,key:e.key,target:e.target}),this.enableUpEvent&&"keyup"===e.type&&this.callback({type:"keyup",srcEvent:e,key:e.key,target:e.target}))}}]),i}();t.a=i},function(e,t,n){"use strict";var r=n(114),o=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var a=r.g.MOUSE_EVENTS,s="pointermove",u="pointerleave",i=function(){function i(t,e){var n=this,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),this.element=t,this.callback=e,this.pressed=!1,this.options=Object.assign({enable:!0},r),this.enableMoveEvent=this.options.enable,this.enableLeaveEvent=this.options.enable,this.events=a.concat(r.events||[]),this.handleEvent=this.handleEvent.bind(this),this.events.forEach(function(e){return t.addEventListener(e,n.handleEvent)})}return o(i,[{key:"destroy",value:function(){var t=this;this.events.forEach(function(e){return t.element.removeEventListener(e,t.handleEvent)})}},{key:"enableEventType",value:function(e,t){e===s&&(this.enableMoveEvent=t),e===u&&(this.enableLeaveEvent=t)}},{key:"handleEvent",value:function(e){if(this.enableLeaveEvent&&"mouseleave"===e.type&&this.callback({type:u,srcEvent:e,pointerType:"mouse",target:e.target}),this.enableMoveEvent)switch(e.type){case"mousedown":0<=e.button&&(this.pressed=!0);break;case"mousemove":0===e.which&&(this.pressed=!1),this.pressed||this.callback({type:s,srcEvent:e,pointerType:"mouse",target:e.target});break;case"mouseup":this.pressed=!1}}}]),i}();t.a=i},function(e,t,n){"use strict";var r=n(114),u=n(282),o=(n.n(u),function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}());var c=-1!==u.userAgent.indexOf("firefox"),a=r.g.WHEEL_EVENTS,l=4.000244140625,i=function(){function i(t,e){var n=this,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),this.element=t,this.callback=e,this.options=Object.assign({enable:!0},r),this.time=0,this.wheelPosition=null,this.type=null,this.timeout=null,this.lastValue=0,this.events=a.concat(r.events||[]),this.handleEvent=this.handleEvent.bind(this),this.events.forEach(function(e){return t.addEventListener(e,n.handleEvent)})}return o(i,[{key:"destroy",value:function(){var t=this;this.events.forEach(function(e){return t.element.removeEventListener(e,t.handleEvent)})}},{key:"enableEventType",value:function(e,t){"wheel"===e&&(this.options.enable=t)}},{key:"handleEvent",value:function(e){if(this.options.enable){e.preventDefault();var t=e.deltaY;u.window.WheelEvent&&(c&&e.deltaMode===u.window.WheelEvent.DOM_DELTA_PIXEL&&(t/=u.window.devicePixelRatio),e.deltaMode===u.window.WheelEvent.DOM_DELTA_LINE&&(t*=40));var n=this.type,r=this.timeout,i=this.lastValue,o=this.time,a=(u.window&&u.window.performance||Date).now(),s=a-(o||0);this.wheelPosition={x:e.clientX,y:e.clientY},o=a,0!==t&&t%l==0?(n="wheel",t=Math.floor(t/l)):0!==t&&Math.abs(t)<4?n="trackpad":400<s?(n=null,i=t,r=u.window.setTimeout(function(){this._onWheel(e,-i,this.wheelPosition),n="wheel"}.bind(this),40)):n||(n=Math.abs(s*t)<200?"trackpad":"wheel",r&&(u.window.clearTimeout(r),r=null,t+=i)),e.shiftKey&&t&&(t*=.25),n&&this._onWheel(e,-t,this.wheelPosition)}}},{key:"_onWheel",value:function(e,t,n){this.callback({type:"wheel",center:n,delta:t,srcEvent:e,pointerType:"mouse",target:e.target})}}]),i}();t.a=i},function(e,t,n){"use strict";t.a=function(e){var t=d[e.srcEvent.type];if(!t)return null;var n=e.srcEvent,r=n.buttons,i=n.button,o=n.which,a=!1,s=!1,u=!1;t===f||t===l&&!Number.isFinite(r)?(a=o===h,s=o===p,u=o===v):t===l?(a=Boolean(r&m),s=Boolean(r&E),u=Boolean(r&b)):t===c&&(a=i===g,s=i===y,u=i===_);return{leftButton:a,middleButton:s,rightButton:u}},t.b=function(e,t){var n=e.srcEvent;if(!e.center&&!Number.isFinite(n.clientX))return null;var r=e.center||{x:n.clientX,y:n.clientY},i=t.getBoundingClientRect(),o=i.width/t.offsetWidth,a=i.height/t.offsetHeight,s={x:(r.x-i.left-t.clientLeft)/o,y:(r.y-i.top-t.clientTop)/a};return{center:r,offsetCenter:s}};var c=1,l=2,f=4,d={pointerdown:c,pointermove:l,pointerup:f,mousedown:c,mousemove:l,mouseup:f},h=1,p=2,v=3,g=0,y=1,_=2,m=1,b=2,E=4},function(e,t,n){"use strict";t.a=function(e){var n=e.prototype.handler;e.prototype.handler=function(t){var e=this.store;0<t.button&&(function(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return!0;return!1}(e,function(e){return e.pointerId===t.pointerId})||e.push(t)),n.call(this,t)}},t.b=function(e){e.prototype.handler=function(e){var t=a[e.type];t&r&&0<=e.button&&(this.pressed=!0),t&i&&0===e.which&&(t=o),this.pressed&&(t&o&&(this.pressed=!1),this.callback(this.manager,t,{pointers:[e],changedPointers:[e],pointerType:"mouse",srcEvent:e}))}};var r=1,i=2,o=4,a={mousedown:r,mousemove:i,mouseup:o}},function(e,t,n){"use strict";var r=n(74),a=n(101),s=n(172);e.exports=function(){function e(e,t,n,r,i,o){o!==s&&a(!1,"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types")}function t(){return e}var n={array:e.isRequired=e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t};return n.checkPropTypes=r,n.PropTypes=n}},function(e,t,n){"use strict";(function(v){var i=n(74),g=n(101),y=n(155),_=n(171),m=n(172),b=n(284);e.exports=function(s,f){var o="function"==typeof Symbol&&Symbol.iterator,a="@@iterator";var d="<<anonymous>>",e={array:t("array"),bool:t("boolean"),func:t("function"),number:t("number"),object:t("object"),string:t("string"),symbol:t("symbol"),any:n(i.thatReturnsNull),arrayOf:function(c){return n(function(e,t,n,r,i){if("function"!=typeof c)return new h("Property `"+i+"` of component `"+n+"` has invalid PropType notation inside arrayOf.");var o=e[t];if(!Array.isArray(o)){var a=p(o);return new h("Invalid "+r+" `"+i+"` of type `"+a+"` supplied to `"+n+"`, expected an array.")}for(var s=0;s<o.length;s++){var u=c(o,s,n,r,i+"["+s+"]",m);if(u instanceof Error)return u}return null})},element:n(function(e,t,n,r,i){var o=e[t];if(s(o))return null;var a=p(o);return new h("Invalid "+r+" `"+i+"` of type `"+a+"` supplied to `"+n+"`, expected a single ReactElement.")}),instanceOf:function(u){return n(function(e,t,n,r,i){if(e[t]instanceof u)return null;var o=u.name||d,a=(s=e[t],s.constructor&&s.constructor.name?s.constructor.name:d);var s;return new h("Invalid "+r+" `"+i+"` of type `"+a+"` supplied to `"+n+"`, expected instance of `"+o+"`.")})},node:n(function(e,t,n,r,i){return u(e[t])?null:new h("Invalid "+r+" `"+i+"` supplied to `"+n+"`, expected a ReactNode.")}),objectOf:function(c){return n(function(e,t,n,r,i){if("function"!=typeof c)return new h("Property `"+i+"` of component `"+n+"` has invalid PropType notation inside objectOf.");var o=e[t],a=p(o);if("object"!==a)return new h("Invalid "+r+" `"+i+"` of type `"+a+"` supplied to `"+n+"`, expected an object.");for(var s in o)if(o.hasOwnProperty(s)){var u=c(o,s,n,r,i+"."+s,m);if(u instanceof Error)return u}return null})},oneOf:function(u){if(!Array.isArray(u))return"production"!==v.env.NODE_ENV&&y(!1,"Invalid argument supplied to oneOf, expected an instance of array."),i.thatReturnsNull;return n(function(e,t,n,r,i){for(var o=e[t],a=0;a<u.length;a++)if(c(o,u[a]))return null;var s=JSON.stringify(u);return new h("Invalid "+r+" `"+i+"` of value `"+o+"` supplied to `"+n+"`, expected one of "+s+".")})},oneOfType:function(s){if(!Array.isArray(s))return"production"!==v.env.NODE_ENV&&y(!1,"Invalid argument supplied to oneOfType, expected an instance of array."),i.thatReturnsNull;for(var e=0;e<s.length;e++){var t=s[e];if("function"!=typeof t)return y(!1,"Invalid argument supplied to oneOfType. Expected an array of check functions, but received %s at index %s.",r(t),e),i.thatReturnsNull}return n(function(e,t,n,r,i){for(var o=0;o<s.length;o++){var a=s[o];if(null==a(e,t,n,r,i,m))return null}return new h("Invalid "+r+" `"+i+"` supplied to `"+n+"`.")})},shape:function(l){return n(function(e,t,n,r,i){var o=e[t],a=p(o);if("object"!==a)return new h("Invalid "+r+" `"+i+"` of type `"+a+"` supplied to `"+n+"`, expected `object`.");for(var s in l){var u=l[s];if(u){var c=u(o,s,n,r,i+"."+s,m);if(c)return c}}return null})},exact:function(f){return n(function(e,t,n,r,i){var o=e[t],a=p(o);if("object"!==a)return new h("Invalid "+r+" `"+i+"` of type `"+a+"` supplied to `"+n+"`, expected `object`.");var s=_({},e[t],f);for(var u in s){var c=f[u];if(!c)return new h("Invalid "+r+" `"+i+"` key `"+u+"` supplied to `"+n+"`.\nBad object: "+JSON.stringify(e[t],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(f),null," "));var l=c(o,u,n,r,i+"."+u,m);if(l)return l}return null})}};function c(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function h(e){this.message=e,this.stack=""}function n(u){if("production"!==v.env.NODE_ENV)var c={},l=0;function e(e,t,n,r,i,o,a){if(r=r||d,o=o||n,a!==m)if(f)g(!1,"Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");else if("production"!==v.env.NODE_ENV&&"undefined"!=typeof console){var s=r+":"+n;!c[s]&&l<3&&(y(!1,"You are manually calling a React.PropTypes validation function for the `%s` prop on `%s`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details.",o,r),c[s]=!0,l++)}return null==t[n]?e?null===t[n]?new h("The "+i+" `"+o+"` is marked as required in `"+r+"`, but its value is `null`."):new h("The "+i+" `"+o+"` is marked as required in `"+r+"`, but its value is `undefined`."):null:u(t,n,r,i,o)}var t=e.bind(null,!1);return t.isRequired=e.bind(null,!0),t}function t(s){return n(function(e,t,n,r,i,o){var a=e[t];return p(a)===s?null:new h("Invalid "+r+" `"+i+"` of type `"+l(a)+"` supplied to `"+n+"`, expected `"+s+"`.")})}function u(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(u);if(null===e||s(e))return!0;var t=function(e){var t=e&&(o&&e[o]||e[a]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!u(n.value))return!1}else for(;!(n=r.next()).done;){var i=n.value;if(i&&!u(i[1]))return!1}return!0;default:return!1}}function p(e){var t,n=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":(t=e,"symbol"===n||"Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol?"symbol":n)}function l(e){if(null==e)return""+e;var t=p(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function r(e){var t=l(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return h.prototype=Error.prototype,e.checkPropTypes=b,e.PropTypes=e}}).call(t,n(26))},function(pe,e,ve){"use strict";(function(e){"production"!==e.env.NODE_ENV&&function(){var p=ve(171),r=ve(233),y=ve(101),b=ve(155),l=ve(74),i=ve(284),e="function"==typeof Symbol&&Symbol.for,E=e?Symbol.for("react.element"):60103,_=e?Symbol.for("react.call"):60104,m=e?Symbol.for("react.return"):60105,w=e?Symbol.for("react.portal"):60106,u=e?Symbol.for("react.fragment"):60107,n="function"==typeof Symbol&&Symbol.iterator,o="@@iterator";function P(e){if(null==e)return null;var t=n&&e[n]||e[o];return"function"==typeof t?t:null}var a=function(e,t){if(void 0===t)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");if(!e){for(var n=arguments.length,r=Array(2<n?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];(function(e){for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i=0,o="Warning: "+e.replace(/%s/g,function(){return n[i++]});"undefined"!=typeof console&&console.warn(o);try{throw new Error(o)}catch(e){}}).apply(void 0,[t].concat(r))}},s={};function c(e,t){var n=e.constructor,r=n&&(n.displayName||n.name)||"ReactClass",i=r+"."+t;s[i]||(b(!1,"%s(...): Can only update a mounted or mounting component. This usually means you called %s() on an unmounted component. This is a no-op.\n\nPlease check the code for the %s component.",t,t,r),s[i]=!0)}var f={isMounted:function(e){return!1},enqueueForceUpdate:function(e,t,n){c(e,"forceUpdate")},enqueueReplaceState:function(e,t,n,r){c(e,"replaceState")},enqueueSetState:function(e,t,n,r){c(e,"setState")}};function d(e,t,n){this.props=e,this.context=t,this.refs=r,this.updater=n||f}d.prototype.isReactComponent={},d.prototype.setState=function(e,t){"object"!=typeof e&&"function"!=typeof e&&null!=e&&y(!1,"setState(...): takes an object of state variables to update or a function which returns an object of state variables."),this.updater.enqueueSetState(this,e,t,"setState")},d.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};var t={isMounted:["isMounted","Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks."],replaceState:["replaceState","Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)."]},h=function(e,t){Object.defineProperty(d.prototype,e,{get:function(){a(!1,"%s(...) is deprecated in plain JavaScript React classes. %s",t[0],t[1])}})};for(var v in t)t.hasOwnProperty(v)&&h(v,t[v]);function g(e,t,n){this.props=e,this.context=t,this.refs=r,this.updater=n||f}function S(){}S.prototype=d.prototype;var A=g.prototype=new S;function T(e,t,n){this.props=e,this.context=t,this.refs=r,this.updater=n||f}A.constructor=g,p(A,d.prototype),A.isPureReactComponent=!0;var x=T.prototype=new S;x.constructor=T,p(x,d.prototype),x.unstable_isAsyncReactComponent=!0,x.render=function(){return this.props.children};var O,R,C={current:null},k=Object.prototype.hasOwnProperty,M={key:!0,ref:!0,__self:!0,__source:!0};function L(e){if(k.call(e,"ref")){var t=Object.getOwnPropertyDescriptor(e,"ref").get;if(t&&t.isReactWarning)return!1}return void 0!==e.ref}function I(e){if(k.call(e,"key")){var t=Object.getOwnPropertyDescriptor(e,"key").get;if(t&&t.isReactWarning)return!1}return void 0!==e.key}var N=function(e,t,n,r,i,o,a){var s={$$typeof:E,type:e,key:t,ref:n,props:a,_owner:o,_store:{}};return Object.defineProperty(s._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(s,"_self",{configurable:!1,enumerable:!1,writable:!1,value:r}),Object.defineProperty(s,"_source",{configurable:!1,enumerable:!1,writable:!1,value:i}),Object.freeze&&(Object.freeze(s.props),Object.freeze(s)),s};function F(e,t,n){var r,i={},o=null,a=null,s=null,u=null;if(null!=t)for(r in L(t)&&(a=t.ref),I(t)&&(o=""+t.key),s=void 0===t.__self?null:t.__self,u=void 0===t.__source?null:t.__source,t)k.call(t,r)&&!M.hasOwnProperty(r)&&(i[r]=t[r]);var c,l,f,d,h,p,v=arguments.length-2;if(1===v)i.children=n;else if(1<v){for(var g=Array(v),y=0;y<v;y++)g[y]=arguments[y+2];Object.freeze&&Object.freeze(g),i.children=g}if(e&&e.defaultProps){var _=e.defaultProps;for(r in _)void 0===i[r]&&(i[r]=_[r])}if((o||a)&&(void 0===i.$$typeof||i.$$typeof!==E)){var m="function"==typeof e?e.displayName||e.name||"Unknown":e;o&&(d=i,h=m,(p=function(){O||b(!(O=!0),"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://fb.me/react-special-props)",h)}).isReactWarning=!0,Object.defineProperty(d,"key",{get:p,configurable:!0})),a&&(c=i,l=m,(f=function(){R||b(!(R=!0),"%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://fb.me/react-special-props)",l)}).isReactWarning=!0,Object.defineProperty(c,"ref",{get:f,configurable:!0}))}return N(e,o,a,s,u,C.current,i)}function j(e){return"object"==typeof e&&null!==e&&e.$$typeof===E}var D={getCurrentStack:null,getStackAddendum:function(){var e=D.getCurrentStack;return e?e():null}},B=".",U=":";var G=!1,V=/\/+/g;function z(e){return(""+e).replace(V,"$&/")}var W=10,X=[];function H(e,t,n,r){if(X.length){var i=X.pop();return i.result=e,i.keyPrefix=t,i.func=n,i.context=r,i.count=0,i}return{result:e,keyPrefix:t,func:n,context:r,count:0}}function Y(e){e.result=null,e.keyPrefix=null,e.func=null,e.context=null,e.count=0,X.length<W&&X.push(e)}function K(e,t,n){return null==e?0:function e(t,n,r,i){var o=typeof t;"undefined"!==o&&"boolean"!==o||(t=null);var a,s=!1;if(null===t)s=!0;else switch(o){case"string":case"number":s=!0;break;case"object":switch(t.$$typeof){case E:case _:case m:case w:s=!0}}if(s)return r(i,t,""===n?B+Z(t,0):n),1;var u=0,c=""===n?B:n+U;if(Array.isArray(t))for(var l=0;l<t.length;l++)u+=e(a=t[l],c+Z(a,l),r,i);else{var f=P(t);if("function"==typeof f){f===t.entries&&(b(G,"Using Maps as children is unsupported and will likely yield unexpected results. Convert it to a sequence/iterable of keyed ReactElements instead.%s",D.getStackAddendum()),G=!0);for(var d,h=f.call(t),p=0;!(d=h.next()).done;)u+=e(a=d.value,c+Z(a,p++),r,i)}else if("object"===o){var v;v=" If you meant to render a collection of children, use an array instead."+D.getStackAddendum();var g=""+t;y(!1,"Objects are not valid as a React child (found: %s).%s","[object Object]"===g?"object with keys {"+Object.keys(t).join(", ")+"}":g,v)}}return u}(e,"",t,n)}function Z(e,t){return"object"==typeof e&&null!==e&&null!=e.key?(n=e.key,r={"=":"=0",":":"=2"},"$"+(""+n).replace(/[=:]/g,function(e){return r[e]})):t.toString(36);var n,r}function q(e,t,n){var r=e.func,i=e.context;r.call(i,t,e.count++)}function Q(e,t,n){var r,i,o=e.result,a=e.keyPrefix,s=e.func,u=e.context,c=s.call(u,t,e.count++);Array.isArray(c)?J(c,o,n,l.thatReturnsArgument):null!=c&&(j(c)&&(i=a+(!(r=c).key||t&&t.key===c.key?"":z(c.key)+"/")+n,c=N(r.type,i,r.ref,r._self,r._source,r._owner,r.props)),o.push(c))}function J(e,t,n,r,i){var o="";null!=n&&(o=z(n)+"/");var a=H(t,o,r,i);K(e,Q,a),Y(a)}function $(e){var t=e.type;return"string"==typeof t?t:"function"==typeof t?t.displayName||t.name:null}var ee=null,te=!1,ne=function(){var e,t,n,r,i="";if(ee){var o=null==(r=ee)?"#empty":"string"==typeof r||"number"==typeof r?"#text":"string"==typeof r.type?r.type:r.type===u?"React.Fragment":r.type.displayName||r.type.name||"Unknown",a=ee._owner;i+=(e=o,t=ee._source,n=a&&$(a),"\n in "+(e||"Unknown")+(t?" (at "+t.fileName.replace(/^.*[\\\/]/,"")+":"+t.lineNumber+")":n?" (created by "+n+")":""))}return i+=D.getStackAddendum()||""},re=new Map([["children",!0],["key",!0]]);function ie(){if(C.current){var e=$(C.current);if(e)return"\n\nCheck the render method of `"+e+"`."}return""}var oe={};function ae(e,t){if(e._store&&!e._store.validated&&null==e.key){e._store.validated=!0;var n=function(e){var t=ie();if(!t){var n="string"==typeof e?e:e.displayName||e.name;n&&(t="\n\nCheck the top-level render call using <"+n+">.")}return t}(t);if(!oe[n]){oe[n]=!0;var r="";e&&e._owner&&e._owner!==C.current&&(r=" It was passed a child from "+$(e._owner)+"."),ee=e,b(!1,'Each child in an array or iterator should have a unique "key" prop.%s%s See https://fb.me/react-warning-keys for more information.%s',n,r,ne()),ee=null}}}function se(e,t){if("object"==typeof e)if(Array.isArray(e))for(var n=0;n<e.length;n++){var r=e[n];j(r)&&ae(r,t)}else if(j(e))e._store&&(e._store.validated=!0);else if(e){var i=P(e);if("function"==typeof i&&i!==e.entries)for(var o,a=i.call(e);!(o=a.next()).done;)j(o.value)&&ae(o.value,t)}}function ue(e){var t=e.type;if("function"==typeof t){var n=t.displayName||t.name,r=t.propTypes;r?(i(r,(ee=e).props,"prop",n,ne),ee=null):void 0===t.PropTypes||te||b(!(te=!0),"Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",n||"Unknown"),"function"==typeof t.getDefaultProps&&b(t.getDefaultProps.isReactClassApproved,"getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function ce(e,t,n){var r="string"==typeof e||"function"==typeof e||"symbol"==typeof e||"number"==typeof e;if(!r){var i="";(void 0===e||"object"==typeof e&&null!==e&&0===Object.keys(e).length)&&(i+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var o=function(e){if(null==e||void 0===e.__source)return"";var t=e.__source;return"\n\nCheck your code at "+t.fileName.replace(/^.*[\\\/]/,"")+":"+t.lineNumber+"."}(t);i+=o||ie(),i+=ne()||"",b(!1,"React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",null==e?e:typeof e,i)}var a=F.apply(this,arguments);if(null==a)return a;if(r)for(var s=2;s<arguments.length;s++)se(arguments[s],e);return"symbol"==typeof e&&e===u?function(e){ee=e;var t=!0,n=!1,r=void 0;try{for(var i,o=Object.keys(e.props)[Symbol.iterator]();!(t=(i=o.next()).done);t=!0){var a=i.value;if(!re.has(a)){b(!1,"Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.%s",a,ne());break}}}catch(e){n=!0,r=e}finally{try{!t&&o.return&&o.return()}finally{if(n)throw r}}null!==e.ref&&b(!1,"Invalid attribute `ref` supplied to `React.Fragment`.%s",ne()),ee=null}(a):ue(a),a}var le={Children:{map:function(e,t,n){if(null==e)return e;var r=[];return J(e,r,null,t,n),r},forEach:function(e,t,n){if(null==e)return e;var r=H(null,null,t,n);K(e,q,r),Y(r)},count:function(e,t){return K(e,l.thatReturnsNull,null)},toArray:function(e){var t=[];return J(e,t,null,l.thatReturnsArgument),t},only:function(e){return j(e)||y(!1,"React.Children.only expected to receive a single React element child."),e}},Component:d,PureComponent:g,unstable_AsyncComponent:T,Fragment:u,createElement:ce,cloneElement:function(e,t,n){for(var r=function(e,t,n){var r,i,o=p({},e.props),a=e.key,s=e.ref,u=e._self,c=e._source,l=e._owner;if(null!=t)for(r in L(t)&&(s=t.ref,l=C.current),I(t)&&(a=""+t.key),e.type&&e.type.defaultProps&&(i=e.type.defaultProps),t)k.call(t,r)&&!M.hasOwnProperty(r)&&(void 0===t[r]&&void 0!==i?o[r]=i[r]:o[r]=t[r]);var f=arguments.length-2;if(1===f)o.children=n;else if(1<f){for(var d=Array(f),h=0;h<f;h++)d[h]=arguments[h+2];o.children=d}return N(e.type,a,s,u,c,l,o)}.apply(this,arguments),i=2;i<arguments.length;i++)se(arguments[i],r.type);return ue(r),r},createFactory:function(e){var t=ce.bind(null,e);return t.type=e,Object.defineProperty(t,"type",{enumerable:!1,get:function(){return a(!1,"Factory.type is deprecated. Access the class directly before passing it to createFactory."),Object.defineProperty(this,"type",{value:e}),e}}),t},isValidElement:j,version:"16.2.0",__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactCurrentOwner:C,assign:p}};p(le.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,{ReactDebugCurrentFrame:D,ReactComponentTreeHook:{}});var fe=Object.freeze({default:le}),de=fe&&le||fe,he=de.default?de.default:de;pe.exports=he}()}).call(e,ve(26))},function(e,t,n){"use strict";var l=n(171),r=n(233),o=n(74),i="function"==typeof Symbol&&Symbol.for,f=i?Symbol.for("react.element"):60103,u=i?Symbol.for("react.call"):60104,c=i?Symbol.for("react.return"):60105,d=i?Symbol.for("react.portal"):60106,a=i?Symbol.for("react.fragment"):60107,h="function"==typeof Symbol&&Symbol.iterator;function p(e){for(var t=arguments.length-1,n="Minified React error #"+e+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant="+e,r=0;r<t;r++)n+="&args[]="+encodeURIComponent(arguments[r+1]);throw(t=Error(n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings.")).name="Invariant Violation",t.framesToPop=1,t}var s={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}};function v(e,t,n){this.props=e,this.context=t,this.refs=r,this.updater=n||s}function g(e,t,n){this.props=e,this.context=t,this.refs=r,this.updater=n||s}function y(){}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){"object"!=typeof e&&"function"!=typeof e&&null!=e&&p("85"),this.updater.enqueueSetState(this,e,t,"setState")},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},y.prototype=v.prototype;var _=g.prototype=new y;function m(e,t,n){this.props=e,this.context=t,this.refs=r,this.updater=n||s}_.constructor=g,l(_,v.prototype),_.isPureReactComponent=!0;var b=m.prototype=new y;b.constructor=m,l(b,v.prototype),b.unstable_isAsyncReactComponent=!0,b.render=function(){return this.props.children};var E={current:null},w=Object.prototype.hasOwnProperty,P={key:!0,ref:!0,__self:!0,__source:!0};function S(e,t,n){var r,i={},o=null,a=null;if(null!=t)for(r in void 0!==t.ref&&(a=t.ref),void 0!==t.key&&(o=""+t.key),t)w.call(t,r)&&!P.hasOwnProperty(r)&&(i[r]=t[r]);var s=arguments.length-2;if(1===s)i.children=n;else if(1<s){for(var u=Array(s),c=0;c<s;c++)u[c]=arguments[c+2];i.children=u}if(e&&e.defaultProps)for(r in s=e.defaultProps)void 0===i[r]&&(i[r]=s[r]);return{$$typeof:f,type:e,key:o,ref:a,props:i,_owner:E.current}}function A(e){return"object"==typeof e&&null!==e&&e.$$typeof===f}var T=/\/+/g,x=[];function O(e,t,n,r){if(x.length){var i=x.pop();return i.result=e,i.keyPrefix=t,i.func=n,i.context=r,i.count=0,i}return{result:e,keyPrefix:t,func:n,context:r,count:0}}function R(e){e.result=null,e.keyPrefix=null,e.func=null,e.context=null,e.count=0,x.length<10&&x.push(e)}function C(e,t,n,r){var i=typeof e;"undefined"!==i&&"boolean"!==i||(e=null);var o=!1;if(null===e)o=!0;else switch(i){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case f:case u:case c:case d:o=!0}}if(o)return n(r,e,""===t?"."+k(e,0):t),1;if(o=0,t=""===t?".":t+":",Array.isArray(e))for(var a=0;a<e.length;a++){var s=t+k(i=e[a],a);o+=C(i,s,n,r)}else if("function"==typeof(s=null==e?null:"function"==typeof(s=h&&e[h]||e["@@iterator"])?s:null))for(e=s.call(e),a=0;!(i=e.next()).done;)o+=C(i=i.value,s=t+k(i,a++),n,r);else"object"===i&&p("31","[object Object]"===(n=""+e)?"object with keys {"+Object.keys(e).join(", ")+"}":n,"");return o}function k(e,t){return"object"==typeof e&&null!==e&&null!=e.key?(n=e.key,r={"=":"=0",":":"=2"},"$"+(""+n).replace(/[=:]/g,function(e){return r[e]})):t.toString(36);var n,r}function M(e,t){e.func.call(e.context,t,e.count++)}function L(e,t,n){var r=e.result,i=e.keyPrefix;e=e.func.call(e.context,t,e.count++),Array.isArray(e)?I(e,r,n,o.thatReturnsArgument):null!=e&&(A(e)&&(t=i+(!e.key||t&&t.key===e.key?"":(""+e.key).replace(T,"$&/")+"/")+n,e={$$typeof:f,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}),r.push(e))}function I(e,t,n,r,i){var o="";null!=n&&(o=(""+n).replace(T,"$&/")+"/"),t=O(t,o,r,i),null==e||C(e,"",L,t),R(t)}var N={Children:{map:function(e,t,n){if(null==e)return e;var r=[];return I(e,r,null,t,n),r},forEach:function(e,t,n){if(null==e)return e;t=O(null,null,t,n),null==e||C(e,"",M,t),R(t)},count:function(e){return null==e?0:C(e,"",o.thatReturnsNull,null)},toArray:function(e){var t=[];return I(e,t,null,o.thatReturnsArgument),t},only:function(e){return A(e)||p("143"),e}},Component:v,PureComponent:g,unstable_AsyncComponent:m,Fragment:a,createElement:S,cloneElement:function(e,t,n){var r=l({},e.props),i=e.key,o=e.ref,a=e._owner;if(null!=t){if(void 0!==t.ref&&(o=t.ref,a=E.current),void 0!==t.key&&(i=""+t.key),e.type&&e.type.defaultProps)var s=e.type.defaultProps;for(u in t)w.call(t,u)&&!P.hasOwnProperty(u)&&(r[u]=void 0===t[u]&&void 0!==s?s[u]:t[u])}var u=arguments.length-2;if(1===u)r.children=n;else if(1<u){s=Array(u);for(var c=0;c<u;c++)s[c]=arguments[c+2];r.children=s}return{$$typeof:f,type:e.type,key:i,ref:o,props:r,_owner:a}},createFactory:function(e){var t=S.bind(null,e);return t.type=e,t},isValidElement:A,version:"16.2.0",__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactCurrentOwner:E,assign:l}},F=Object.freeze({default:N}),j=F&&N||F;e.exports=j.default?j.default:j},function(e,t){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t){e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},function(e,x,d){(function(r,i){var s=/%[sdj%]/g;x.format=function(e){if(!b(e)){for(var t=[],n=0;n<arguments.length;n++)t.push(u(arguments[n]));return t.join(" ")}n=1;for(var r=arguments,i=r.length,o=String(e).replace(s,function(e){if("%%"===e)return"%";if(i<=n)return e;switch(e){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(e){return"[Circular]"}default:return e}}),a=r[n];n<i;a=r[++n])_(a)||!l(a)?o+=" "+a:o+=" "+u(a);return o},x.deprecate=function(e,t){if(E(r.process))return function(){return x.deprecate(e,t).apply(this,arguments)};if(!0===i.noDeprecation)return e;var n=!1;return function(){if(!n){if(i.throwDeprecation)throw new Error(t);i.traceDeprecation?console.trace(t):console.error(t),n=!0}return e.apply(this,arguments)}};var e,o={};function u(e,t){var n={seen:[],stylize:c};return 3<=arguments.length&&(n.depth=arguments[2]),4<=arguments.length&&(n.colors=arguments[3]),y(t)?n.showHidden=t:t&&x._extend(n,t),E(n.showHidden)&&(n.showHidden=!1),E(n.depth)&&(n.depth=2),E(n.colors)&&(n.colors=!1),E(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=a),h(n,e,n.depth)}function a(e,t){var n=u.styles[t];return n?"["+u.colors[n][0]+"m"+e+"["+u.colors[n][1]+"m":e}function c(e,t){return e}function h(t,n,r){if(t.customInspect&&n&&A(n.inspect)&&n.inspect!==x.inspect&&(!n.constructor||n.constructor.prototype!==n)){var e=n.inspect(r,t);return b(e)||(e=h(t,e,r)),e}var i=function(e,t){if(E(t))return e.stylize("undefined","undefined");if(b(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}if(m(t))return e.stylize(""+t,"number");if(y(t))return e.stylize(""+t,"boolean");if(_(t))return e.stylize("null","null")}(t,n);if(i)return i;var o,a=Object.keys(n),s=(o={},a.forEach(function(e,t){o[e]=!0}),o);if(t.showHidden&&(a=Object.getOwnPropertyNames(n)),S(n)&&(0<=a.indexOf("message")||0<=a.indexOf("description")))return p(n);if(0===a.length){if(A(n)){var u=n.name?": "+n.name:"";return t.stylize("[Function"+u+"]","special")}if(w(n))return t.stylize(RegExp.prototype.toString.call(n),"regexp");if(P(n))return t.stylize(Date.prototype.toString.call(n),"date");if(S(n))return p(n)}var c,l="",f=!1,d=["{","}"];(g(n)&&(f=!0,d=["[","]"]),A(n))&&(l=" [Function"+(n.name?": "+n.name:"")+"]");return w(n)&&(l=" "+RegExp.prototype.toString.call(n)),P(n)&&(l=" "+Date.prototype.toUTCString.call(n)),S(n)&&(l=" "+p(n)),0!==a.length||f&&0!=n.length?r<0?w(n)?t.stylize(RegExp.prototype.toString.call(n),"regexp"):t.stylize("[Object]","special"):(t.seen.push(n),c=f?function(t,n,r,i,e){for(var o=[],a=0,s=n.length;a<s;++a)T(n,String(a))?o.push(v(t,n,r,i,String(a),!0)):o.push("");return e.forEach(function(e){e.match(/^\d+$/)||o.push(v(t,n,r,i,e,!0))}),o}(t,n,r,s,a):a.map(function(e){return v(t,n,r,s,e,f)}),t.seen.pop(),function(e,t,n){if(60<e.reduce(function(e,t){return 0,0<=t.indexOf("\n")&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0))return n[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+n[1];return n[0]+t+" "+e.join(", ")+" "+n[1]}(c,l,d)):d[0]+l+d[1]}function p(e){return"["+Error.prototype.toString.call(e)+"]"}function v(e,t,n,r,i,o){var a,s,u;if((u=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?s=u.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):u.set&&(s=e.stylize("[Setter]","special")),T(r,i)||(a="["+i+"]"),s||(e.seen.indexOf(u.value)<0?-1<(s=_(n)?h(e,u.value,null):h(e,u.value,n-1)).indexOf("\n")&&(s=o?s.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+s.split("\n").map(function(e){return" "+e}).join("\n")):s=e.stylize("[Circular]","special")),E(a)){if(o&&i.match(/^\d+$/))return s;a=(a=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),e.stylize(a,"string"))}return a+": "+s}function g(e){return Array.isArray(e)}function y(e){return"boolean"==typeof e}function _(e){return null===e}function m(e){return"number"==typeof e}function b(e){return"string"==typeof e}function E(e){return void 0===e}function w(e){return l(e)&&"[object RegExp]"===t(e)}function l(e){return"object"==typeof e&&null!==e}function P(e){return l(e)&&"[object Date]"===t(e)}function S(e){return l(e)&&("[object Error]"===t(e)||e instanceof Error)}function A(e){return"function"==typeof e}function t(e){return Object.prototype.toString.call(e)}function n(e){return e<10?"0"+e.toString(10):e.toString(10)}x.debuglog=function(t){if(E(e)&&(e=i.env.NODE_DEBUG||""),t=t.toUpperCase(),!o[t])if(new RegExp("\\b"+t+"\\b","i").test(e)){var n=i.pid;o[t]=function(){var e=x.format.apply(x,arguments);console.error("%s %d: %s",t,n,e)}}else o[t]=function(){};return o[t]},(x.inspect=u).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]},u.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},x.isArray=g,x.isBoolean=y,x.isNull=_,x.isNullOrUndefined=function(e){return null==e},x.isNumber=m,x.isString=b,x.isSymbol=function(e){return"symbol"==typeof e},x.isUndefined=E,x.isRegExp=w,x.isObject=l,x.isDate=P,x.isError=S,x.isFunction=A,x.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},x.isBuffer=d(683);var f=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function T(e,t){return Object.prototype.hasOwnProperty.call(e,t)}x.log=function(){var e,t;console.log("%s - %s",(e=new Date,t=[n(e.getHours()),n(e.getMinutes()),n(e.getSeconds())].join(":"),[e.getDate(),f[e.getMonth()],t].join(" ")),x.format.apply(x,arguments))},x.inherits=d(682),x._extend=function(e,t){if(!t||!l(t))return e;for(var n=Object.keys(t),r=n.length;r--;)e[n[r]]=t[n[r]];return e}}).call(x,d(47),d(26))},function(e,t,I){"use strict";t.a=function(e,t,n){var r={},i=e.zoom,o=[e.longitude,e.latitude],a=I.i(j.j)(i),s=t.zoom,u=[t.longitude,t.latitude],c=I.i(j.j)(s-i),l=new N.Vector2(I.i(j.a)(o,a)),f=new N.Vector2(I.i(j.a)(u,a)).subtract(l),d=Math.max(e.width,e.height),h=d/c,p=Math.sqrt(f.x*f.x+f.y*f.y);if(Math.abs(p)<D){var v=!0,g=!1,y=void 0;try{for(var _,m=B[Symbol.iterator]();!(v=(_=m.next()).done);v=!0){var b=_.value,E=e[b],w=t[b];r[b]=I.i(F.c)(E,w,n)}}catch(e){g=!0,y=e}finally{try{!v&&m.return&&m.return()}finally{if(g)throw y}}return r}var P=1.414*1.414,S=(h*h-d*d+P*P*p*p)/(2*d*P*p),A=(h*h-d*d-P*P*p*p)/(2*h*P*p),T=Math.log(Math.sqrt(S*S+1)-S),x=Math.log(Math.sqrt(A*A+1)-A),O=n*((x-T)/1.414),R=Math.cosh(T)/Math.cosh(T+1.414*O),C=d*((Math.cosh(T)*Math.tanh(T+1.414*O)-Math.sinh(T))/P)/p,k=1/R,M=i+I.i(j.k)(k),L=I.i(j.b)(l.add(f.scale(C)).scale(k),I.i(j.j)(M));return r.longitude=L[0],r.latitude=L[1],r.zoom=M,r};var N=I(16),F=I(118),j=I(80),D=.01,B=["longitude","latitude","zoom"]},function(e,t,p){"use strict";t.a=function(e){var t=e.width,n=e.height,r=e.longitude,i=e.latitude,o=e.zoom,a=e.pitch,s=void 0===a?0:a,u=e.bearing,c=void 0===u?0:u;(r<-180||180<r)&&(r=p.i(g.d)(r+180,360)-180);(c<-180||180<c)&&(c=p.i(g.d)(c+180,360)-180);var l=new v.a({width:t,height:n,longitude:r,latitude:i,zoom:o}),f=l.project([r,y])[1],d=l.project([r,_])[1],h=0;d-f<n&&(o+=Math.log2(n/(d-f)),l=new v.a({width:t,height:n,longitude:r,latitude:i,zoom:o}),f=l.project([r,y])[1],d=l.project([r,_])[1]);0<f?h=f:d<n&&(h=d-n);h&&(i=l.unproject([t/2,n/2+h])[1]);return{width:t,height:n,longitude:r,latitude:i,zoom:o,pitch:s,bearing:c}};var v=p(81),g=p(118),y=85.05113,_=-85.05113},function(e,t,g){"use strict";var n=g(16),d=g(118),y=g(80),r=g(77),h=g.n(r),i=g(78),p=g.n(i),o=g(75),v=g.n(o),a=g(156),_=g.n(a),m=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},s=function(){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}}();var b=g.i(d.a)(),u=function(){function f(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.width,n=e.height,r=e.viewMatrix,i=void 0===r?b:r,o=e.projectionMatrix,a=e.isGeographicCoordinateSystem,s=void 0===o?b:o;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f),this.width=t||1,this.height=n||1,this.scale=1,this.viewMatrix=i,this.projectionMatrix=s,this.isGeographicCoordinateSystem=a;var u=g.i(d.a)();v()(u,u,this.projectionMatrix),v()(u,u,this.viewMatrix),this.viewProjectionMatrix=u;var c=g.i(d.a)();h()(c,c,[this.width/2,-this.height/2,1]),p()(c,c,[1,-1,0]),v()(c,c,this.viewProjectionMatrix);var l=_()(g.i(d.a)(),c);if(!l)throw new Error("Pixel project matrix not invertible");this.pixelProjectionMatrix=c,this.pixelUnprojectionMatrix=l,this.equals=this.equals.bind(this),this.project=this.project.bind(this),this.unproject=this.unproject.bind(this),this.projectFlat=this.projectFlat.bind(this),this.unprojectFlat=this.unprojectFlat.bind(this)}return s(f,[{key:"equals",value:function(e){return e instanceof f&&(e.width===this.width&&e.height===this.height&&g.i(n.equals)(e.projectionMatrix,this.projectionMatrix)&&g.i(n.equals)(e.viewMatrix,this.viewMatrix))}},{key:"project",value:function(e){var t=(1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).topLeft,n=void 0===t||t,r=m(e,3),i=r[0],o=r[1],a=r[2],s=this.projectFlat([i,o]),u=m(s,2),c=u[0],l=u[1],f=g.i(y.c)([c,l,a],this.pixelProjectionMatrix),d=m(f,2),h=d[0],p=d[1],v=n?p:this.height-p;return 2===e.length?[h,v]:[h,v,f[2]]}},{key:"unproject",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n=t.topLeft,r=void 0===n||n,i=t.targetZ,o=m(e,3),a=o[0],s=o[1],u=o[2],c=r?s:this.height-s,l=g.i(y.d)([a,c,u],this.pixelUnprojectionMatrix,i),f=this.unprojectFlat(l),d=m(f,2),h=d[0],p=d[1];return Number.isFinite(u)?[h,p,l[2]]:Number.isFinite(i)?[h,p,i]:[h,p]}},{key:"projectFlat",value:function(e){1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return e}},{key:"unprojectFlat",value:function(e){1<arguments.length&&void 0!==arguments[1]?arguments[1]:this.scale;return e}}]),f}();t.a=u},function(t,e,n){(function(e){WebGLDebugUtils=function(){var n;void 0===n&&(n=e);var l=function(e){var t;n.console&&n.console.error?n.console.error(e):(t=e,n.console&&n.console.log&&n.console.log(t))},f={enable:{1:{0:!0}},disable:{1:{0:!0}},getParameter:{1:{0:!0}},drawArrays:{3:{0:!0}},drawElements:{4:{0:!0,2:!0}},createShader:{1:{0:!0}},getShaderParameter:{2:{1:!0}},getProgramParameter:{2:{1:!0}},getShaderPrecisionFormat:{2:{0:!0,1:!0}},getVertexAttrib:{2:{1:!0}},vertexAttribPointer:{6:{2:!0}},bindTexture:{2:{0:!0}},activeTexture:{1:{0:!0}},getTexParameter:{2:{0:!0,1:!0}},texParameterf:{3:{0:!0,1:!0}},texParameteri:{3:{0:!0,1:!0,2:!0}},copyTexImage2D:{8:{0:!0,2:!0}},copyTexSubImage2D:{8:{0:!0}},generateMipmap:{1:{0:!0}},bindBuffer:{2:{0:!0}},getBufferParameter:{2:{0:!0,1:!0}},pixelStorei:{2:{0:!0,1:!0}},bindRenderbuffer:{2:{0:!0}},bindFramebuffer:{2:{0:!0}},checkFramebufferStatus:{1:{0:!0}},framebufferRenderbuffer:{4:{0:!0,1:!0,2:!0}},framebufferTexture2D:{5:{0:!0,1:!0,2:!0}},getFramebufferAttachmentParameter:{3:{0:!0,1:!0,2:!0}},getRenderbufferParameter:{2:{0:!0,1:!0}},renderbufferStorage:{4:{0:!0,1:!0}},clear:{1:{0:{enumBitwiseOr:["COLOR_BUFFER_BIT","DEPTH_BUFFER_BIT","STENCIL_BUFFER_BIT"]}}},depthFunc:{1:{0:!0}},blendFunc:{2:{0:!0,1:!0}},blendFuncSeparate:{4:{0:!0,1:!0,2:!0,3:!0}},blendEquation:{1:{0:!0}},blendEquationSeparate:{2:{0:!0,1:!0}},stencilFunc:{3:{0:!0}},stencilFuncSeparate:{4:{0:!0,1:!0}},stencilMaskSeparate:{2:{0:!0}},stencilOp:{3:{0:!0,1:!0,2:!0}},stencilOpSeparate:{4:{0:!0,1:!0,2:!0,3:!0}},cullFace:{1:{0:!0}},frontFace:{1:{0:!0}},drawArraysInstancedANGLE:{4:{0:!0}},drawElementsInstancedANGLE:{5:{0:!0,2:!0}},blendEquationEXT:{1:{0:!0}},bufferData:{3:{0:!0,2:!0},4:{0:!0,2:!0},5:{0:!0,2:!0}},bufferSubData:{3:{0:!0},4:{0:!0},5:{0:!0}},copyBufferSubData:{5:{0:!0,1:!0}},getBufferSubData:{3:{0:!0},4:{0:!0},5:{0:!0}},blitFramebuffer:{10:{8:{enumBitwiseOr:["COLOR_BUFFER_BIT","DEPTH_BUFFER_BIT","STENCIL_BUFFER_BIT"]},9:!0}},framebufferTextureLayer:{5:{0:!0,1:!0}},invalidateFramebuffer:{2:{0:!0}},invalidateSubFramebuffer:{6:{0:!0}},readBuffer:{1:{0:!0}},getInternalformatParameter:{3:{0:!0,1:!0,2:!0}},renderbufferStorageMultisample:{5:{0:!0,2:!0}},texStorage2D:{5:{0:!0,2:!0}},texStorage3D:{6:{0:!0,2:!0}},texImage2D:{9:{0:!0,2:!0,6:!0,7:!0},6:{0:!0,2:!0,3:!0,4:!0},10:{0:!0,2:!0,6:!0,7:!0}},texImage3D:{10:{0:!0,2:!0,7:!0,8:!0},11:{0:!0,2:!0,7:!0,8:!0}},texSubImage2D:{9:{0:!0,6:!0,7:!0},7:{0:!0,4:!0,5:!0},10:{0:!0,6:!0,7:!0}},texSubImage3D:{11:{0:!0,8:!0,9:!0},12:{0:!0,8:!0,9:!0}},copyTexSubImage3D:{9:{0:!0}},compressedTexImage2D:{7:{0:!0,2:!0},8:{0:!0,2:!0},9:{0:!0,2:!0}},compressedTexImage3D:{8:{0:!0,2:!0},9:{0:!0,2:!0},10:{0:!0,2:!0}},compressedTexSubImage2D:{8:{0:!0,6:!0},9:{0:!0,6:!0},10:{0:!0,6:!0}},compressedTexSubImage3D:{10:{0:!0,8:!0},11:{0:!0,8:!0},12:{0:!0,8:!0}},vertexAttribIPointer:{5:{2:!0}},drawArraysInstanced:{4:{0:!0}},drawElementsInstanced:{5:{0:!0,2:!0}},drawRangeElements:{6:{0:!0,4:!0}},readPixels:{7:{4:!0,5:!0},8:{4:!0,5:!0}},clearBufferfv:{3:{0:!0},4:{0:!0}},clearBufferiv:{3:{0:!0},4:{0:!0}},clearBufferuiv:{3:{0:!0},4:{0:!0}},clearBufferfi:{4:{0:!0}},beginQuery:{2:{0:!0}},endQuery:{1:{0:!0}},getQuery:{2:{0:!0,1:!0}},getQueryParameter:{2:{1:!0}},samplerParameteri:{3:{1:!0,2:!0}},samplerParameterf:{3:{1:!0}},getSamplerParameter:{2:{1:!0}},fenceSync:{2:{0:!0,1:{enumBitwiseOr:[]}}},clientWaitSync:{3:{1:{enumBitwiseOr:["SYNC_FLUSH_COMMANDS_BIT"]}}},waitSync:{3:{1:{enumBitwiseOr:[]}}},getSyncParameter:{2:{1:!0}},bindTransformFeedback:{2:{0:!0}},beginTransformFeedback:{1:{0:!0}},transformFeedbackVaryings:{3:{2:!0}},bindBufferBase:{3:{0:!0}},bindBufferRange:{5:{0:!0}},getIndexedParameter:{2:{0:!0}},getActiveUniforms:{3:{2:!0}},getActiveUniformBlockParameter:{3:{2:!0}}},r=null,d=null;function h(e){if(null==r)for(var t in r={},d={},e)"number"==typeof e[t]&&(r[e[t]]=t,d[t]=e[t])}function i(){if(null==r)throw"WebGLDebugUtils.init(ctx) not called"}function p(e){i();var t=r[e];return void 0!==t?"gl."+t:"/*UNKNOWN WebGL ENUM*/ 0x"+e.toString(16)}function v(e,t,n,r){var i;if(void 0!==(i=f[e])&&(void 0!==(i=i[t])&&i[n])){if("object"!=typeof i[n]||void 0===i[n].enumBitwiseOr)return p(r);for(var o=i[n].enumBitwiseOr,a=0,s=[],u=0;u<o.length;++u){var c=d[o[u]];0!=(r&c)&&(a|=c,s.push(p(c)))}return a===r?s.join(" | "):p(r)}return null===r?"null":void 0===r?"undefined":r.toString()}function P(e,t,n){e.__defineGetter__(n,function(){return t[n]}),e.__defineSetter__(n,function(e){t[n]=e})}function S(e){var t=!!e.createTransformFeedback;t&&e.bindVertexArray(null);var n=e.getParameter(e.MAX_VERTEX_ATTRIBS),r=e.createBuffer();e.bindBuffer(e.ARRAY_BUFFER,r);for(var i=0;i<n;++i)e.disableVertexAttribArray(i),e.vertexAttribPointer(i,4,e.FLOAT,!1,0,0),e.vertexAttrib1f(i,0),t&&e.vertexAttribDivisor(i,0);e.deleteBuffer(r);var o=e.getParameter(e.MAX_TEXTURE_IMAGE_UNITS);for(i=0;i<o;++i)e.activeTexture(e.TEXTURE0+i),e.bindTexture(e.TEXTURE_CUBE_MAP,null),e.bindTexture(e.TEXTURE_2D,null),t&&(e.bindTexture(e.TEXTURE_2D_ARRAY,null),e.bindTexture(e.TEXTURE_3D,null),e.bindSampler(i,null));if(e.activeTexture(e.TEXTURE0),e.useProgram(null),e.bindBuffer(e.ARRAY_BUFFER,null),e.bindBuffer(e.ELEMENT_ARRAY_BUFFER,null),e.bindFramebuffer(e.FRAMEBUFFER,null),e.bindRenderbuffer(e.RENDERBUFFER,null),e.disable(e.BLEND),e.disable(e.CULL_FACE),e.disable(e.DEPTH_TEST),e.disable(e.DITHER),e.disable(e.SCISSOR_TEST),e.blendColor(0,0,0,0),e.blendEquation(e.FUNC_ADD),e.blendFunc(e.ONE,e.ZERO),e.clearColor(0,0,0,0),e.clearDepth(1),e.clearStencil(-1),e.colorMask(!0,!0,!0,!0),e.cullFace(e.BACK),e.depthFunc(e.LESS),e.depthMask(!0),e.depthRange(0,1),e.frontFace(e.CCW),e.hint(e.GENERATE_MIPMAP_HINT,e.DONT_CARE),e.lineWidth(1),e.pixelStorei(e.PACK_ALIGNMENT,4),e.pixelStorei(e.UNPACK_ALIGNMENT,4),e.pixelStorei(e.UNPACK_FLIP_Y_WEBGL,!1),e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!1),e.UNPACK_COLORSPACE_CONVERSION_WEBGL&&e.pixelStorei(e.UNPACK_COLORSPACE_CONVERSION_WEBGL,e.BROWSER_DEFAULT_WEBGL),e.polygonOffset(0,0),e.sampleCoverage(1,!1),e.scissor(0,0,e.canvas.width,e.canvas.height),e.stencilFunc(e.ALWAYS,0,4294967295),e.stencilMask(4294967295),e.stencilOp(e.KEEP,e.KEEP,e.KEEP),e.viewport(0,0,e.canvas.width,e.canvas.height),e.clear(e.COLOR_BUFFER_BIT|e.DEPTH_BUFFER_BIT|e.STENCIL_BUFFER_BIT),t){e.drawBuffers([e.BACK]),e.readBuffer(e.BACK),e.bindBuffer(e.COPY_READ_BUFFER,null),e.bindBuffer(e.COPY_WRITE_BUFFER,null),e.bindBuffer(e.PIXEL_PACK_BUFFER,null),e.bindBuffer(e.PIXEL_UNPACK_BUFFER,null);var a=e.getParameter(e.MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS);for(i=0;i<a;++i)e.bindBufferBase(e.TRANSFORM_FEEDBACK_BUFFER,i,null);var s=e.getParameter(e.MAX_UNIFORM_BUFFER_BINDINGS);for(i=0;i<s;++i)e.bindBufferBase(e.UNIFORM_BUFFER,i,null);e.disable(e.RASTERIZER_DISCARD),e.pixelStorei(e.UNPACK_IMAGE_HEIGHT,0),e.pixelStorei(e.UNPACK_SKIP_IMAGES,0),e.pixelStorei(e.UNPACK_ROW_LENGTH,0),e.pixelStorei(e.UNPACK_SKIP_ROWS,0),e.pixelStorei(e.UNPACK_SKIP_PIXELS,0),e.pixelStorei(e.PACK_ROW_LENGTH,0),e.pixelStorei(e.PACK_SKIP_ROWS,0),e.pixelStorei(e.PACK_SKIP_PIXELS,0),e.hint(e.FRAGMENT_SHADER_DERIVATIVE_HINT,e.DONT_CARE)}for(;e.getError(););}return{init:h,mightBeEnum:function(e){return i(),void 0!==r[e]},glEnumToString:p,glFunctionArgToString:v,glFunctionArgsToString:function(e,t){for(var n="",r=t.length,i=0;i<r;++i)n+=(0==i?"":", ")+v(e,r,i,t[i]);return n},makeDebugContext:function t(n,i,o,a){a=a||n,h(n),i=i||function(e,t,n){for(var r="",i=n.length,o=0;o<i;++o)r+=(0==o?"":", ")+v(t,i,o,n[o]);l("WebGL error "+p(e)+" in "+t+"("+r+")")};var s={};function e(n,r){return function(){o&&o(r,arguments);var e=n[r].apply(n,arguments),t=a.getError();return 0!=t&&(s[t]=!0,i(t,r,arguments)),e}}var r={};for(var u in n)if("function"==typeof n[u])if("getExtension"!=u)r[u]=e(n,u);else{var c=e(n,u);r[u]=function(){var e=c.apply(n,arguments);return e?t(e,i,o,a):null}}else P(r,n,u);return r.getError=function(){for(var e in s)if(s.hasOwnProperty(e)&&s[e])return s[e]=!1,e;return n.NO_ERROR},r},makeLostContextSimulatingCanvas:function(r){var h,p,t,o,a,s=[],u=[],v={},g=1,y=!1,_=[],i=0,c=0,l=!1,f=0,m={};function d(t){return"function"==typeof t?t:function(e){t.handleEvent(e)}}function b(){++c,y||i==c&&r.loseContext()}function E(e,t){var n=e[t];return function(){if(b(),!y)return n.apply(e,arguments)}}function w(e){return{statusMessage:e,preventDefault:function(){l=!0}}}return r.getContext=(t=r.getContext,function(){var e=t.apply(r,arguments);if(e instanceof WebGLRenderingContext||n.WebGL2RenderingContext&&e instanceof WebGL2RenderingContext){if(e!=h){if(h)throw"got different context";p=n.WebGL2RenderingContext&&e instanceof WebGL2RenderingContext,v=function(n){for(var e in n)"function"==typeof n[e]?v[e]=E(n,e):P(v,n,e);v.getError=function(){if(b(),!y)for(;e=h.getError();)m[e]=!0;for(var e in m)if(m[e])return delete m[e],e;return v.NO_ERROR};var t=["createBuffer","createFramebuffer","createProgram","createRenderbuffer","createShader","createTexture"];p&&t.push("createQuery","createSampler","fenceSync","createTransformFeedback","createVertexArray");for(var r=0;r<t.length;++r){var i=t[r];v[i]=function(t){return function(){if(b(),y)return null;var e=t.apply(n,arguments);return e.__webglDebugContextLostId__=g,_.push(e),e}}(n[i])}var o=["getActiveAttrib","getActiveUniform","getBufferParameter","getContextAttributes","getAttachedShaders","getFramebufferAttachmentParameter","getParameter","getProgramParameter","getProgramInfoLog","getRenderbufferParameter","getShaderParameter","getShaderInfoLog","getShaderSource","getTexParameter","getUniform","getUniformLocation","getVertexAttrib"];p&&o.push("getInternalformatParameter","getQuery","getQueryParameter","getSamplerParameter","getSyncParameter","getTransformFeedbackVarying","getIndexedParameter","getUniformIndices","getActiveUniforms","getActiveUniformBlockParameter","getActiveUniformBlockName");for(var r=0;r<o.length;++r){var i=o[r];v[i]=function(e){return function(){return b(),y?null:e.apply(n,arguments)}}(v[i])}var a,s,u,c,l,f,d=["isBuffer","isEnabled","isFramebuffer","isProgram","isRenderbuffer","isShader","isTexture"];p&&d.push("isQuery","isSampler","isSync","isTransformFeedback","isVertexArray");for(var r=0;r<d.length;++r){var i=d[r];v[i]=function(e){return function(){return b(),!y&&e.apply(n,arguments)}}(v[i])}return v.checkFramebufferStatus=(f=v.checkFramebufferStatus,function(){return b(),y?v.FRAMEBUFFER_UNSUPPORTED:f.apply(n,arguments)}),v.getAttribLocation=(l=v.getAttribLocation,function(){return b(),y?-1:l.apply(n,arguments)}),v.getVertexAttribOffset=(c=v.getVertexAttribOffset,function(){return b(),y?0:c.apply(n,arguments)}),v.isContextLost=function(){return y},p&&(v.getFragDataLocation=(u=v.getFragDataLocation,function(){return b(),y?-1:u.apply(n,arguments)}),v.clientWaitSync=(s=v.clientWaitSync,function(){return b(),y?v.WAIT_FAILED:s.apply(n,arguments)}),v.getUniformBlockIndex=(a=v.getUniformBlockIndex,function(){return b(),y?v.INVALID_INDEX:a.apply(n,arguments)})),v}(h=e)}return v}return e}),a=(o=r).addEventListener,o.addEventListener=function(e,t,n){switch(e){case"webglcontextlost":i=t,s.push(d(i));break;case"webglcontextrestored":r=t,u.push(d(r));break;default:a.apply(o,arguments)}var r,i},r.loseContext=function(){if(!y){for(y=!0,i=0,++g;h.getError(););!function(){for(var e=Object.keys(m),t=0;t<e.length;++t)delete m[e[t]]}(),m[h.CONTEXT_LOST_WEBGL]=!0;var t=w("context lost"),n=s.slice();setTimeout(function(){for(var e=0;e<n.length;++e)n[e](t);0<=f&&setTimeout(function(){r.restoreContext()},f)},0)}},r.restoreContext=function(){y&&u.length&&setTimeout(function(){if(!l)throw"can not restore. webglcontestlost listener did not call event.preventDefault";!function(){for(var e=0;e<_.length;++e){var t=_[e];t instanceof WebGLBuffer?h.deleteBuffer(t):t instanceof WebGLFramebuffer?h.deleteFramebuffer(t):t instanceof WebGLProgram?h.deleteProgram(t):t instanceof WebGLRenderbuffer?h.deleteRenderbuffer(t):t instanceof WebGLShader?h.deleteShader(t):t instanceof WebGLTexture?h.deleteTexture(t):p&&(t instanceof WebGLQuery?h.deleteQuery(t):t instanceof WebGLSampler?h.deleteSampler(t):t instanceof WebGLSync?h.deleteSync(t):t instanceof WebGLTransformFeedback?h.deleteTransformFeedback(t):t instanceof WebGLVertexArrayObject&&h.deleteVertexArray(t))}}(),S(h),c=0,l=y=!1;for(var e=u.slice(),t=w("context restored"),n=0;n<e.length;++n)e[n](t)},0)},r.loseContextInNCalls=function(e){if(y)throw"You can not ask a lost contet to be lost";i=c+e},r.getNumCalls=function(){return c},r.setRestoreTimeout=function(e){f=e},r},resetToInitialState:S}}(),t.exports=WebGLDebugUtils}).call(e,n(47))}])});