@deck.gl/jupyter-widget 8.9.0 → 8.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +4 -4
- package/dist/index.js.map +2 -2
- package/package.json +8 -8
package/dist/index.js
CHANGED
|
@@ -504,14 +504,14 @@ uniform `+pe+" "+Ae+" u_"+ye+`;
|
|
|
504
504
|
`),qe=Te.concat(sh.vertexSource,m.vertexSource).join(`
|
|
505
505
|
`),tt=z.createShader(z.FRAGMENT_SHADER);if(z.isContextLost())this.failedToCreate=!0;else{z.shaderSource(tt,ke),z.compileShader(tt),z.attachShader(this.program,tt);var ht=z.createShader(z.VERTEX_SHADER);if(z.isContextLost())this.failedToCreate=!0;else{z.shaderSource(ht,qe),z.compileShader(ht),z.attachShader(this.program,ht),this.attributes={};var ut={};this.numAttributes=ne.length;for(var vt=0;vt<this.numAttributes;vt++)ne[vt]&&(z.bindAttribLocation(this.program,vt,ne[vt]),this.attributes[ne[vt]]=vt);z.linkProgram(this.program),z.deleteShader(ht),z.deleteShader(tt);for(var Et=0;Et<ye.length;Et++){var Nt=ye[Et];if(Nt&&!ut[Nt]){var Dt=z.getUniformLocation(this.program,Nt);Dt&&(ut[Nt]=Dt)}}this.fixedUniforms=I(d,ut),this.binderUniforms=w?w.getUniforms(d,ut):[]}}};function pl(d,A,m){var w=1/Qn(m,1,A.transform.tileZoom),I=Math.pow(2,m.tileID.overscaledZ),F=m.tileSize*Math.pow(2,A.transform.tileZoom)/I,z=F*(m.tileID.canonical.x+m.tileID.wrap*I),W=F*m.tileID.canonical.y;return{u_image:0,u_texsize:m.imageAtlasTexture.size,u_scale:[w,d.fromScale,d.toScale],u_fade:d.t,u_pixel_coord_upper:[z>>16,W>>16],u_pixel_coord_lower:[65535&z,65535&W]}}Wn.prototype.draw=function(d,A,m,w,I,F,z,W,Q,ne,pe,Ae,ye,Ce,Se,Be){var Te,ke=d.gl;if(!this.failedToCreate){for(var qe in d.program.set(this.program),d.setDepthMode(m),d.setStencilMode(w),d.setColorMode(I),d.setCullFace(F),this.fixedUniforms)this.fixedUniforms[qe].set(z[qe]);Ce&&Ce.setUniforms(d,this.binderUniforms,Ae,{zoom:ye});for(var tt=(Te={},Te[ke.LINES]=2,Te[ke.TRIANGLES]=3,Te[ke.LINE_STRIP]=1,Te)[A],ht=0,ut=pe.get();ht<ut.length;ht+=1){var vt=ut[ht],Et=vt.vaos||(vt.vaos={});(Et[W]||(Et[W]=new $s)).bind(d,this,Q,Ce?Ce.getPaintVertexBuffers():[],ne,vt.vertexOffset,Se,Be),ke.drawElements(A,vt.primitiveLength*tt,ke.UNSIGNED_SHORT,vt.primitiveOffset*tt*2)}}};var Qv=function(d,A,m,w){var I=A.style.light,F=I.properties.get("position"),z=[F.x,F.y,F.z],W=n.create$1();I.properties.get("anchor")==="viewport"&&n.fromRotation(W,-A.transform.angle),n.transformMat3(z,z,W);var Q=I.properties.get("color");return{u_matrix:d,u_lightpos:z,u_lightintensity:I.properties.get("intensity"),u_lightcolor:[Q.r,Q.g,Q.b],u_vertical_gradient:+m,u_opacity:w}},dc=function(d,A,m,w,I,F,z){return n.extend(Qv(d,A,m,w),pl(F,A,z),{u_height_factor:-Math.pow(2,I.overscaledZ)/z.tileSize/8})},ju=function(d){return{u_matrix:d}},yo=function(d,A,m,w){return n.extend(ju(d),pl(m,A,w))},lh=function(d,A){return{u_matrix:d,u_world:A}},Gu=function(d,A,m,w,I){return n.extend(yo(d,A,m,w),{u_world:I})},qd=function(d,A,m,w){var I,F,z=d.transform;if(w.paint.get("circle-pitch-alignment")==="map"){var W=Qn(m,1,z.zoom);I=!0,F=[W,W]}else I=!1,F=z.pixelsToGLUnits;return{u_camera_to_center_distance:z.cameraToCenterDistance,u_scale_with_map:+(w.paint.get("circle-pitch-scale")==="map"),u_matrix:d.translatePosMatrix(A.posMatrix,m,w.paint.get("circle-translate"),w.paint.get("circle-translate-anchor")),u_pitch_with_map:+I,u_device_pixel_ratio:n.browser.devicePixelRatio,u_extrude_scale:F}},zs=function(d,A,m){var w=Qn(m,1,A.zoom),I=Math.pow(2,A.zoom-m.tileID.overscaledZ),F=m.tileID.overscaleFactor();return{u_matrix:d,u_camera_to_center_distance:A.cameraToCenterDistance,u_pixels_to_tile_units:w,u_extrude_scale:[A.pixelsToGLUnits[0]/(w*I),A.pixelsToGLUnits[1]/(w*I)],u_overscale_factor:F}},mn=function(d,A,m){return{u_matrix:d,u_inv_matrix:A,u_camera_to_center_distance:m.cameraToCenterDistance,u_viewport_size:[m.width,m.height]}},We=function(d,A,m){return m===void 0&&(m=1),{u_matrix:d,u_color:A,u_overlay:0,u_overlay_scale:m}},Jn=function(d){return{u_matrix:d}},Xd=function(d,A,m,w){return{u_matrix:d,u_extrude_scale:Qn(A,1,m),u_intensity:w}},ch=function(d,A,m){var w=d.transform;return{u_matrix:Jv(d,A,m),u_ratio:1/Qn(A,1,w.zoom),u_device_pixel_ratio:n.browser.devicePixelRatio,u_units_to_pixels:[1/w.pixelsToGLUnits[0],1/w.pixelsToGLUnits[1]]}},Pi=function(d,A,m,w){return n.extend(ch(d,A,m),{u_image:0,u_image_height:w})},Sp=function(d,A,m,w){var I=d.transform,F=Re(A,I);return{u_matrix:Jv(d,A,m),u_texsize:A.imageAtlasTexture.size,u_ratio:1/Qn(A,1,I.zoom),u_device_pixel_ratio:n.browser.devicePixelRatio,u_image:0,u_scale:[F,w.fromScale,w.toScale],u_fade:w.t,u_units_to_pixels:[1/I.pixelsToGLUnits[0],1/I.pixelsToGLUnits[1]]}},_y=function(d,A,m,w,I){var F=d.lineAtlas,z=Re(A,d.transform),W=m.layout.get("line-cap")==="round",Q=F.getDash(w.from,W),ne=F.getDash(w.to,W),pe=Q.width*I.fromScale,Ae=ne.width*I.toScale;return n.extend(ch(d,A,m),{u_patternscale_a:[z/pe,-Q.height/2],u_patternscale_b:[z/Ae,-ne.height/2],u_sdfgamma:F.width/(256*Math.min(pe,Ae)*n.browser.devicePixelRatio)/2,u_image:0,u_tex_y_a:Q.y,u_tex_y_b:ne.y,u_mix:I.t})};function Re(d,A){return 1/Qn(d,1,A.tileZoom)}function Jv(d,A,m){return d.translatePosMatrix(A.tileID.posMatrix,A,m.paint.get("line-translate"),m.paint.get("line-translate-anchor"))}var xy=function(d,A,m,w,I){return{u_matrix:d,u_tl_parent:A,u_scale_parent:m,u_buffer_scale:1,u_fade_t:w.mix,u_opacity:w.opacity*I.paint.get("raster-opacity"),u_image0:0,u_image1:1,u_brightness_low:I.paint.get("raster-brightness-min"),u_brightness_high:I.paint.get("raster-brightness-max"),u_saturation_factor:(z=I.paint.get("raster-saturation"),z>0?1-1/(1.001-z):-z),u_contrast_factor:(F=I.paint.get("raster-contrast"),F>0?1/(1-F):1+F),u_spin_weights:$v(I.paint.get("raster-hue-rotate"))};var F,z};function $v(d){d*=Math.PI/180;var A=Math.sin(d),m=Math.cos(d);return[(2*m+1)/3,(-Math.sqrt(3)*A-m+1)/3,(Math.sqrt(3)*A-m+1)/3]}var Pp,of=function(d,A,m,w,I,F,z,W,Q,ne){var pe=I.transform;return{u_is_size_zoom_constant:+(d==="constant"||d==="source"),u_is_size_feature_constant:+(d==="constant"||d==="camera"),u_size_t:A?A.uSizeT:0,u_size:A?A.uSize:0,u_camera_to_center_distance:pe.cameraToCenterDistance,u_pitch:pe.pitch/360*2*Math.PI,u_rotate_symbol:+m,u_aspect_ratio:pe.width/pe.height,u_fade_change:I.options.fadeDuration?I.symbolFadeChange:1,u_matrix:F,u_label_plane_matrix:z,u_coord_matrix:W,u_is_text:+Q,u_pitch_with_map:+w,u_texsize:ne,u_texture:0}},fh=function(d,A,m,w,I,F,z,W,Q,ne,pe){var Ae=I.transform;return n.extend(of(d,A,m,w,I,F,z,W,Q,ne),{u_gamma_scale:w?Math.cos(Ae._pitch)*Ae.cameraToCenterDistance:1,u_device_pixel_ratio:n.browser.devicePixelRatio,u_is_halo:+pe})},hh=function(d,A,m,w,I,F,z,W,Q,ne){return n.extend(fh(d,A,m,w,I,F,z,W,!0,Q,!0),{u_texsize_icon:ne,u_texture_icon:1})},ph=function(d,A,m){return{u_matrix:d,u_opacity:A,u_color:m}},kl=function(d,A,m,w,I,F){return n.extend(function(z,W,Q,ne){var pe=Q.imageManager.getPattern(z.from.toString()),Ae=Q.imageManager.getPattern(z.to.toString()),ye=Q.imageManager.getPixelSize(),Ce=ye.width,Se=ye.height,Be=Math.pow(2,ne.tileID.overscaledZ),Te=ne.tileSize*Math.pow(2,Q.transform.tileZoom)/Be,ke=Te*(ne.tileID.canonical.x+ne.tileID.wrap*Be),qe=Te*ne.tileID.canonical.y;return{u_image:0,u_pattern_tl_a:pe.tl,u_pattern_br_a:pe.br,u_pattern_tl_b:Ae.tl,u_pattern_br_b:Ae.br,u_texsize:[Ce,Se],u_mix:W.t,u_pattern_size_a:pe.displaySize,u_pattern_size_b:Ae.displaySize,u_scale_a:W.fromScale,u_scale_b:W.toScale,u_tile_units_to_pixels:1/Qn(ne,1,Q.transform.tileZoom),u_pixel_coord_upper:[ke>>16,qe>>16],u_pixel_coord_lower:[65535&ke,65535&qe]}}(w,F,m,I),{u_matrix:d,u_opacity:A})},du={fillExtrusion:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_lightpos:new n.Uniform3f(d,A.u_lightpos),u_lightintensity:new n.Uniform1f(d,A.u_lightintensity),u_lightcolor:new n.Uniform3f(d,A.u_lightcolor),u_vertical_gradient:new n.Uniform1f(d,A.u_vertical_gradient),u_opacity:new n.Uniform1f(d,A.u_opacity)}},fillExtrusionPattern:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_lightpos:new n.Uniform3f(d,A.u_lightpos),u_lightintensity:new n.Uniform1f(d,A.u_lightintensity),u_lightcolor:new n.Uniform3f(d,A.u_lightcolor),u_vertical_gradient:new n.Uniform1f(d,A.u_vertical_gradient),u_height_factor:new n.Uniform1f(d,A.u_height_factor),u_image:new n.Uniform1i(d,A.u_image),u_texsize:new n.Uniform2f(d,A.u_texsize),u_pixel_coord_upper:new n.Uniform2f(d,A.u_pixel_coord_upper),u_pixel_coord_lower:new n.Uniform2f(d,A.u_pixel_coord_lower),u_scale:new n.Uniform3f(d,A.u_scale),u_fade:new n.Uniform1f(d,A.u_fade),u_opacity:new n.Uniform1f(d,A.u_opacity)}},fill:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix)}},fillPattern:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_image:new n.Uniform1i(d,A.u_image),u_texsize:new n.Uniform2f(d,A.u_texsize),u_pixel_coord_upper:new n.Uniform2f(d,A.u_pixel_coord_upper),u_pixel_coord_lower:new n.Uniform2f(d,A.u_pixel_coord_lower),u_scale:new n.Uniform3f(d,A.u_scale),u_fade:new n.Uniform1f(d,A.u_fade)}},fillOutline:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_world:new n.Uniform2f(d,A.u_world)}},fillOutlinePattern:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_world:new n.Uniform2f(d,A.u_world),u_image:new n.Uniform1i(d,A.u_image),u_texsize:new n.Uniform2f(d,A.u_texsize),u_pixel_coord_upper:new n.Uniform2f(d,A.u_pixel_coord_upper),u_pixel_coord_lower:new n.Uniform2f(d,A.u_pixel_coord_lower),u_scale:new n.Uniform3f(d,A.u_scale),u_fade:new n.Uniform1f(d,A.u_fade)}},circle:function(d,A){return{u_camera_to_center_distance:new n.Uniform1f(d,A.u_camera_to_center_distance),u_scale_with_map:new n.Uniform1i(d,A.u_scale_with_map),u_pitch_with_map:new n.Uniform1i(d,A.u_pitch_with_map),u_extrude_scale:new n.Uniform2f(d,A.u_extrude_scale),u_device_pixel_ratio:new n.Uniform1f(d,A.u_device_pixel_ratio),u_matrix:new n.UniformMatrix4f(d,A.u_matrix)}},collisionBox:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_camera_to_center_distance:new n.Uniform1f(d,A.u_camera_to_center_distance),u_pixels_to_tile_units:new n.Uniform1f(d,A.u_pixels_to_tile_units),u_extrude_scale:new n.Uniform2f(d,A.u_extrude_scale),u_overscale_factor:new n.Uniform1f(d,A.u_overscale_factor)}},collisionCircle:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_inv_matrix:new n.UniformMatrix4f(d,A.u_inv_matrix),u_camera_to_center_distance:new n.Uniform1f(d,A.u_camera_to_center_distance),u_viewport_size:new n.Uniform2f(d,A.u_viewport_size)}},debug:function(d,A){return{u_color:new n.UniformColor(d,A.u_color),u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_overlay:new n.Uniform1i(d,A.u_overlay),u_overlay_scale:new n.Uniform1f(d,A.u_overlay_scale)}},clippingMask:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix)}},heatmap:function(d,A){return{u_extrude_scale:new n.Uniform1f(d,A.u_extrude_scale),u_intensity:new n.Uniform1f(d,A.u_intensity),u_matrix:new n.UniformMatrix4f(d,A.u_matrix)}},heatmapTexture:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_world:new n.Uniform2f(d,A.u_world),u_image:new n.Uniform1i(d,A.u_image),u_color_ramp:new n.Uniform1i(d,A.u_color_ramp),u_opacity:new n.Uniform1f(d,A.u_opacity)}},hillshade:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_image:new n.Uniform1i(d,A.u_image),u_latrange:new n.Uniform2f(d,A.u_latrange),u_light:new n.Uniform2f(d,A.u_light),u_shadow:new n.UniformColor(d,A.u_shadow),u_highlight:new n.UniformColor(d,A.u_highlight),u_accent:new n.UniformColor(d,A.u_accent)}},hillshadePrepare:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_image:new n.Uniform1i(d,A.u_image),u_dimension:new n.Uniform2f(d,A.u_dimension),u_zoom:new n.Uniform1f(d,A.u_zoom),u_unpack:new n.Uniform4f(d,A.u_unpack)}},line:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_ratio:new n.Uniform1f(d,A.u_ratio),u_device_pixel_ratio:new n.Uniform1f(d,A.u_device_pixel_ratio),u_units_to_pixels:new n.Uniform2f(d,A.u_units_to_pixels)}},lineGradient:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_ratio:new n.Uniform1f(d,A.u_ratio),u_device_pixel_ratio:new n.Uniform1f(d,A.u_device_pixel_ratio),u_units_to_pixels:new n.Uniform2f(d,A.u_units_to_pixels),u_image:new n.Uniform1i(d,A.u_image),u_image_height:new n.Uniform1f(d,A.u_image_height)}},linePattern:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_texsize:new n.Uniform2f(d,A.u_texsize),u_ratio:new n.Uniform1f(d,A.u_ratio),u_device_pixel_ratio:new n.Uniform1f(d,A.u_device_pixel_ratio),u_image:new n.Uniform1i(d,A.u_image),u_units_to_pixels:new n.Uniform2f(d,A.u_units_to_pixels),u_scale:new n.Uniform3f(d,A.u_scale),u_fade:new n.Uniform1f(d,A.u_fade)}},lineSDF:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_ratio:new n.Uniform1f(d,A.u_ratio),u_device_pixel_ratio:new n.Uniform1f(d,A.u_device_pixel_ratio),u_units_to_pixels:new n.Uniform2f(d,A.u_units_to_pixels),u_patternscale_a:new n.Uniform2f(d,A.u_patternscale_a),u_patternscale_b:new n.Uniform2f(d,A.u_patternscale_b),u_sdfgamma:new n.Uniform1f(d,A.u_sdfgamma),u_image:new n.Uniform1i(d,A.u_image),u_tex_y_a:new n.Uniform1f(d,A.u_tex_y_a),u_tex_y_b:new n.Uniform1f(d,A.u_tex_y_b),u_mix:new n.Uniform1f(d,A.u_mix)}},raster:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_tl_parent:new n.Uniform2f(d,A.u_tl_parent),u_scale_parent:new n.Uniform1f(d,A.u_scale_parent),u_buffer_scale:new n.Uniform1f(d,A.u_buffer_scale),u_fade_t:new n.Uniform1f(d,A.u_fade_t),u_opacity:new n.Uniform1f(d,A.u_opacity),u_image0:new n.Uniform1i(d,A.u_image0),u_image1:new n.Uniform1i(d,A.u_image1),u_brightness_low:new n.Uniform1f(d,A.u_brightness_low),u_brightness_high:new n.Uniform1f(d,A.u_brightness_high),u_saturation_factor:new n.Uniform1f(d,A.u_saturation_factor),u_contrast_factor:new n.Uniform1f(d,A.u_contrast_factor),u_spin_weights:new n.Uniform3f(d,A.u_spin_weights)}},symbolIcon:function(d,A){return{u_is_size_zoom_constant:new n.Uniform1i(d,A.u_is_size_zoom_constant),u_is_size_feature_constant:new n.Uniform1i(d,A.u_is_size_feature_constant),u_size_t:new n.Uniform1f(d,A.u_size_t),u_size:new n.Uniform1f(d,A.u_size),u_camera_to_center_distance:new n.Uniform1f(d,A.u_camera_to_center_distance),u_pitch:new n.Uniform1f(d,A.u_pitch),u_rotate_symbol:new n.Uniform1i(d,A.u_rotate_symbol),u_aspect_ratio:new n.Uniform1f(d,A.u_aspect_ratio),u_fade_change:new n.Uniform1f(d,A.u_fade_change),u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_label_plane_matrix:new n.UniformMatrix4f(d,A.u_label_plane_matrix),u_coord_matrix:new n.UniformMatrix4f(d,A.u_coord_matrix),u_is_text:new n.Uniform1i(d,A.u_is_text),u_pitch_with_map:new n.Uniform1i(d,A.u_pitch_with_map),u_texsize:new n.Uniform2f(d,A.u_texsize),u_texture:new n.Uniform1i(d,A.u_texture)}},symbolSDF:function(d,A){return{u_is_size_zoom_constant:new n.Uniform1i(d,A.u_is_size_zoom_constant),u_is_size_feature_constant:new n.Uniform1i(d,A.u_is_size_feature_constant),u_size_t:new n.Uniform1f(d,A.u_size_t),u_size:new n.Uniform1f(d,A.u_size),u_camera_to_center_distance:new n.Uniform1f(d,A.u_camera_to_center_distance),u_pitch:new n.Uniform1f(d,A.u_pitch),u_rotate_symbol:new n.Uniform1i(d,A.u_rotate_symbol),u_aspect_ratio:new n.Uniform1f(d,A.u_aspect_ratio),u_fade_change:new n.Uniform1f(d,A.u_fade_change),u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_label_plane_matrix:new n.UniformMatrix4f(d,A.u_label_plane_matrix),u_coord_matrix:new n.UniformMatrix4f(d,A.u_coord_matrix),u_is_text:new n.Uniform1i(d,A.u_is_text),u_pitch_with_map:new n.Uniform1i(d,A.u_pitch_with_map),u_texsize:new n.Uniform2f(d,A.u_texsize),u_texture:new n.Uniform1i(d,A.u_texture),u_gamma_scale:new n.Uniform1f(d,A.u_gamma_scale),u_device_pixel_ratio:new n.Uniform1f(d,A.u_device_pixel_ratio),u_is_halo:new n.Uniform1i(d,A.u_is_halo)}},symbolTextAndIcon:function(d,A){return{u_is_size_zoom_constant:new n.Uniform1i(d,A.u_is_size_zoom_constant),u_is_size_feature_constant:new n.Uniform1i(d,A.u_is_size_feature_constant),u_size_t:new n.Uniform1f(d,A.u_size_t),u_size:new n.Uniform1f(d,A.u_size),u_camera_to_center_distance:new n.Uniform1f(d,A.u_camera_to_center_distance),u_pitch:new n.Uniform1f(d,A.u_pitch),u_rotate_symbol:new n.Uniform1i(d,A.u_rotate_symbol),u_aspect_ratio:new n.Uniform1f(d,A.u_aspect_ratio),u_fade_change:new n.Uniform1f(d,A.u_fade_change),u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_label_plane_matrix:new n.UniformMatrix4f(d,A.u_label_plane_matrix),u_coord_matrix:new n.UniformMatrix4f(d,A.u_coord_matrix),u_is_text:new n.Uniform1i(d,A.u_is_text),u_pitch_with_map:new n.Uniform1i(d,A.u_pitch_with_map),u_texsize:new n.Uniform2f(d,A.u_texsize),u_texsize_icon:new n.Uniform2f(d,A.u_texsize_icon),u_texture:new n.Uniform1i(d,A.u_texture),u_texture_icon:new n.Uniform1i(d,A.u_texture_icon),u_gamma_scale:new n.Uniform1f(d,A.u_gamma_scale),u_device_pixel_ratio:new n.Uniform1f(d,A.u_device_pixel_ratio),u_is_halo:new n.Uniform1i(d,A.u_is_halo)}},background:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_opacity:new n.Uniform1f(d,A.u_opacity),u_color:new n.UniformColor(d,A.u_color)}},backgroundPattern:function(d,A){return{u_matrix:new n.UniformMatrix4f(d,A.u_matrix),u_opacity:new n.Uniform1f(d,A.u_opacity),u_image:new n.Uniform1i(d,A.u_image),u_pattern_tl_a:new n.Uniform2f(d,A.u_pattern_tl_a),u_pattern_br_a:new n.Uniform2f(d,A.u_pattern_br_a),u_pattern_tl_b:new n.Uniform2f(d,A.u_pattern_tl_b),u_pattern_br_b:new n.Uniform2f(d,A.u_pattern_br_b),u_texsize:new n.Uniform2f(d,A.u_texsize),u_mix:new n.Uniform1f(d,A.u_mix),u_pattern_size_a:new n.Uniform2f(d,A.u_pattern_size_a),u_pattern_size_b:new n.Uniform2f(d,A.u_pattern_size_b),u_scale_a:new n.Uniform1f(d,A.u_scale_a),u_scale_b:new n.Uniform1f(d,A.u_scale_b),u_pixel_coord_upper:new n.Uniform2f(d,A.u_pixel_coord_upper),u_pixel_coord_lower:new n.Uniform2f(d,A.u_pixel_coord_lower),u_tile_units_to_pixels:new n.Uniform1f(d,A.u_tile_units_to_pixels)}}};function Yi(d,A,m,w,I,F,z){for(var W=d.context,Q=W.gl,ne=d.useProgram("collisionBox"),pe=[],Ae=0,ye=0,Ce=0;Ce<w.length;Ce++){var Se=w[Ce],Be=A.getTile(Se),Te=Be.getBucket(m);if(Te){var ke=Se.posMatrix;I[0]===0&&I[1]===0||(ke=d.translatePosMatrix(Se.posMatrix,Be,I,F));var qe=z?Te.textCollisionBox:Te.iconCollisionBox,tt=Te.collisionCircleArray;if(tt.length>0){var ht=n.create(),ut=ke;n.mul(ht,Te.placementInvProjMatrix,d.transform.glCoordMatrix),n.mul(ht,ht,Te.placementViewportMatrix),pe.push({circleArray:tt,circleOffset:ye,transform:ut,invTransform:ht}),ye=Ae+=tt.length/4}qe&&ne.draw(W,Q.LINES,_e.disabled,me.disabled,d.colorModeForRenderPass(),Ze.disabled,zs(ke,d.transform,Be),m.id,qe.layoutVertexBuffer,qe.indexBuffer,qe.segments,null,d.transform.zoom,null,null,qe.collisionVertexBuffer)}}if(z&&pe.length){var vt=d.useProgram("collisionCircle"),Et=new n.StructArrayLayout2f1f2i16;Et.resize(4*Ae),Et._trim();for(var Nt=0,Dt=0,rr=pe;Dt<rr.length;Dt+=1)for(var Rr=rr[Dt],Ur=0;Ur<Rr.circleArray.length/4;Ur++){var Fr=4*Ur,kn=Rr.circleArray[Fr+0],ir=Rr.circleArray[Fr+1],_r=Rr.circleArray[Fr+2],sn=Rr.circleArray[Fr+3];Et.emplace(Nt++,kn,ir,_r,sn,0),Et.emplace(Nt++,kn,ir,_r,sn,1),Et.emplace(Nt++,kn,ir,_r,sn,2),Et.emplace(Nt++,kn,ir,_r,sn,3)}(!Pp||Pp.length<2*Ae)&&(Pp=function(sa){var Oo=2*sa,oo=new n.StructArrayLayout3ui6;oo.resize(Oo),oo._trim();for(var Ki=0;Ki<Oo;Ki++){var Aa=6*Ki;oo.uint16[Aa+0]=4*Ki+0,oo.uint16[Aa+1]=4*Ki+1,oo.uint16[Aa+2]=4*Ki+2,oo.uint16[Aa+3]=4*Ki+2,oo.uint16[Aa+4]=4*Ki+3,oo.uint16[Aa+5]=4*Ki+0}return oo}(Ae));for(var Yr=W.createIndexBuffer(Pp,!0),Xr=W.createVertexBuffer(Et,n.collisionCircleLayout.members,!0),nn=0,Hr=pe;nn<Hr.length;nn+=1){var Gr=Hr[nn],Ba=mn(Gr.transform,Gr.invTransform,d.transform);vt.draw(W,Q.TRIANGLES,_e.disabled,me.disabled,d.colorModeForRenderPass(),Ze.disabled,Ba,m.id,Xr,Yr,n.SegmentVector.simpleSegment(0,2*Gr.circleOffset,Gr.circleArray.length,Gr.circleArray.length/2),null,d.transform.zoom,null,null,null)}Xr.destroy(),Yr.destroy()}}var mu=n.identity(new Float32Array(16));function eA(d,A,m,w,I,F){var z=n.getAnchorAlignment(d),W=-(z.horizontalAlign-.5)*A,Q=-(z.verticalAlign-.5)*m,ne=n.evaluateVariableOffset(d,w);return new n.Point((W/I+ne[0])*F,(Q/I+ne[1])*F)}function tA(d,A,m,w,I,F,z,W,Q,ne,pe){var Ae=d.text.placedSymbolArray,ye=d.text.dynamicLayoutVertexArray,Ce=d.icon.dynamicLayoutVertexArray,Se={};ye.clear();for(var Be=0;Be<Ae.length;Be++){var Te=Ae.get(Be),ke=Te.hidden||!Te.crossTileID||d.allowVerticalPlacement&&!Te.placedOrientation?null:w[Te.crossTileID];if(ke){var qe=new n.Point(Te.anchorX,Te.anchorY),tt=hn(qe,m?W:z),ht=dn(F.cameraToCenterDistance,tt.signedDistanceFromCamera),ut=I.evaluateSizeForFeature(d.textSizeData,ne,Te)*ht/n.ONE_EM;m&&(ut*=d.tilePixelRatio/Q);for(var vt=eA(ke.anchor,ke.width,ke.height,ke.textOffset,ke.textBoxScale,ut),Et=m?hn(qe.add(vt),z).point:tt.point.add(A?vt.rotate(-F.angle):vt),Nt=d.allowVerticalPlacement&&Te.placedOrientation===n.WritingMode.vertical?Math.PI/2:0,Dt=0;Dt<Te.numGlyphs;Dt++)n.addDynamicAttributes(ye,Et,Nt);pe&&Te.associatedIconIndex>=0&&(Se[Te.associatedIconIndex]={shiftedAnchor:Et,angle:Nt})}else eo(Te.numGlyphs,ye)}if(pe){Ce.clear();for(var rr=d.icon.placedSymbolArray,Rr=0;Rr<rr.length;Rr++){var Ur=rr.get(Rr);if(Ur.hidden)eo(Ur.numGlyphs,Ce);else{var Fr=Se[Rr];if(Fr)for(var kn=0;kn<Ur.numGlyphs;kn++)n.addDynamicAttributes(Ce,Fr.shiftedAnchor,Fr.angle);else eo(Ur.numGlyphs,Ce)}}d.icon.dynamicLayoutVertexBuffer.updateData(Ce)}d.text.dynamicLayoutVertexBuffer.updateData(ye)}function rA(d,A,m){return m.iconsInText&&A?"symbolTextAndIcon":d?"symbolSDF":"symbolIcon"}function Bl(d,A,m,w,I,F,z,W,Q,ne,pe,Ae){for(var ye=d.context,Ce=ye.gl,Se=d.transform,Be=W==="map",Te=Q==="map",ke=Be&&m.layout.get("symbol-placement")!=="point",qe=Be&&!Te&&!ke,tt=m.layout.get("symbol-sort-key").constantOr(1)!==void 0,ht=!1,ut=d.depthModeForSublayer(0,_e.ReadOnly),vt=m.layout.get("text-variable-anchor"),Et=[],Nt=0,Dt=w;Nt<Dt.length;Nt+=1){var rr=Dt[Nt],Rr=A.getTile(rr),Ur=Rr.getBucket(m);if(Ur){var Fr=I?Ur.text:Ur.icon;if(Fr&&Fr.segments.get().length){var kn=Fr.programConfigurations.get(m.id),ir=I||Ur.sdfIcons,_r=I?Ur.textSizeData:Ur.iconSizeData,sn=Te||Se.pitch!==0,Yr=d.useProgram(rA(ir,I,Ur),kn),Xr=n.evaluateSizeForZoom(_r,Se.zoom),nn=void 0,Hr=[0,0],Gr=void 0,Ba=void 0,sa=null,Oo=void 0;if(I)Gr=Rr.glyphAtlasTexture,Ba=Ce.LINEAR,nn=Rr.glyphAtlasTexture.size,Ur.iconsInText&&(Hr=Rr.imageAtlasTexture.size,sa=Rr.imageAtlasTexture,Oo=sn||d.options.rotating||d.options.zooming||_r.kind==="composite"||_r.kind==="camera"?Ce.LINEAR:Ce.NEAREST);else{var oo=m.layout.get("icon-size").constantOr(0)!==1||Ur.iconsNeedLinear;Gr=Rr.imageAtlasTexture,Ba=ir||d.options.rotating||d.options.zooming||oo||sn?Ce.LINEAR:Ce.NEAREST,nn=Rr.imageAtlasTexture.size}var Ki=Qn(Rr,1,d.transform.zoom),Aa=fi(rr.posMatrix,Te,Be,d.transform,Ki),Io=Pn(rr.posMatrix,Te,Be,d.transform,Ki),Qi=vt&&Ur.hasTextData(),un=m.layout.get("icon-text-fit")!=="none"&&Qi&&Ur.hasIconData();ke&&lc(Ur,rr.posMatrix,d,I,Aa,Io,Te,ne);var Ji=d.translatePosMatrix(rr.posMatrix,Rr,F,z),_u=ke||I&&vt||un?mu:Aa,Qo=d.translatePosMatrix(Io,Rr,F,z,!0),mf=ir&&m.paint.get(I?"text-halo-width":"icon-halo-width").constantOr(1)!==0,vf={program:Yr,buffers:Fr,uniformValues:ir?Ur.iconsInText?hh(_r.kind,Xr,qe,Te,d,Ji,_u,Qo,nn,Hr):fh(_r.kind,Xr,qe,Te,d,Ji,_u,Qo,I,nn,!0):of(_r.kind,Xr,qe,Te,d,Ji,_u,Qo,I,nn),atlasTexture:Gr,atlasTextureIcon:sa,atlasInterpolation:Ba,atlasInterpolationIcon:Oo,isSDF:ir,hasHalo:mf};if(tt&&Ur.canOverlap){ht=!0;for(var as=0,Vt=Fr.segments.get();as<Vt.length;as+=1){var dr=Vt[as];Et.push({segments:new n.SegmentVector([dr]),sortKey:dr.sortKey,state:vf})}}else Et.push({segments:Fr.segments,sortKey:0,state:vf})}}}ht&&Et.sort(function(os,g){return os.sortKey-g.sortKey});for(var xu=0,Nl=Et;xu<Nl.length;xu+=1){var Hs=Nl[xu],Ai=Hs.state;if(ye.activeTexture.set(Ce.TEXTURE0),Ai.atlasTexture.bind(Ai.atlasInterpolation,Ce.CLAMP_TO_EDGE),Ai.atlasTextureIcon&&(ye.activeTexture.set(Ce.TEXTURE1),Ai.atlasTextureIcon&&Ai.atlasTextureIcon.bind(Ai.atlasInterpolationIcon,Ce.CLAMP_TO_EDGE)),Ai.isSDF){var Wu=Ai.uniformValues;Ai.hasHalo&&(Wu.u_is_halo=1,dh(Ai.buffers,Hs.segments,m,d,Ai.program,ut,pe,Ae,Wu)),Wu.u_is_halo=0}dh(Ai.buffers,Hs.segments,m,d,Ai.program,ut,pe,Ae,Ai.uniformValues)}}function dh(d,A,m,w,I,F,z,W,Q){var ne=w.context;I.draw(ne,ne.gl.TRIANGLES,F,z,W,Ze.disabled,Q,m.id,d.layoutVertexBuffer,d.indexBuffer,A,m.paint,w.transform.zoom,d.programConfigurations.get(m.id),d.dynamicLayoutVertexBuffer,d.opacityVertexBuffer)}function Cp(d,A,m,w,I,F,z){var W,Q,ne,pe,Ae,ye=d.context.gl,Ce=m.paint.get("fill-pattern"),Se=Ce&&Ce.constantOr(1),Be=m.getCrossfadeParameters();z?(Q=Se&&!m.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline",W=ye.LINES):(Q=Se?"fillPattern":"fill",W=ye.TRIANGLES);for(var Te=0,ke=w;Te<ke.length;Te+=1){var qe=ke[Te],tt=A.getTile(qe);if(!Se||tt.patternsLoaded()){var ht=tt.getBucket(m);if(ht){var ut=ht.programConfigurations.get(m.id),vt=d.useProgram(Q,ut);Se&&(d.context.activeTexture.set(ye.TEXTURE0),tt.imageAtlasTexture.bind(ye.LINEAR,ye.CLAMP_TO_EDGE),ut.updatePaintBuffers(Be));var Et=Ce.constantOr(null);if(Et&&tt.imageAtlas){var Nt=tt.imageAtlas,Dt=Nt.patternPositions[Et.to.toString()],rr=Nt.patternPositions[Et.from.toString()];Dt&&rr&&ut.setConstantPatternPositions(Dt,rr)}var Rr=d.translatePosMatrix(qe.posMatrix,tt,m.paint.get("fill-translate"),m.paint.get("fill-translate-anchor"));if(z){pe=ht.indexBuffer2,Ae=ht.segments2;var Ur=[ye.drawingBufferWidth,ye.drawingBufferHeight];ne=Q==="fillOutlinePattern"&&Se?Gu(Rr,d,Be,tt,Ur):lh(Rr,Ur)}else pe=ht.indexBuffer,Ae=ht.segments,ne=Se?yo(Rr,d,Be,tt):ju(Rr);vt.draw(d.context,W,I,d.stencilModeForClipping(qe),F,Ze.disabled,ne,m.id,ht.layoutVertexBuffer,pe,Ae,m.paint,d.transform.zoom,ut)}}}}function ji(d,A,m,w,I,F,z){for(var W=d.context,Q=W.gl,ne=m.paint.get("fill-extrusion-pattern"),pe=ne.constantOr(1),Ae=m.getCrossfadeParameters(),ye=m.paint.get("fill-extrusion-opacity"),Ce=0,Se=w;Ce<Se.length;Ce+=1){var Be=Se[Ce],Te=A.getTile(Be),ke=Te.getBucket(m);if(ke){var qe=ke.programConfigurations.get(m.id),tt=d.useProgram(pe?"fillExtrusionPattern":"fillExtrusion",qe);pe&&(d.context.activeTexture.set(Q.TEXTURE0),Te.imageAtlasTexture.bind(Q.LINEAR,Q.CLAMP_TO_EDGE),qe.updatePaintBuffers(Ae));var ht=ne.constantOr(null);if(ht&&Te.imageAtlas){var ut=Te.imageAtlas,vt=ut.patternPositions[ht.to.toString()],Et=ut.patternPositions[ht.from.toString()];vt&&Et&&qe.setConstantPatternPositions(vt,Et)}var Nt=d.translatePosMatrix(Be.posMatrix,Te,m.paint.get("fill-extrusion-translate"),m.paint.get("fill-extrusion-translate-anchor")),Dt=m.paint.get("fill-extrusion-vertical-gradient"),rr=pe?dc(Nt,d,Dt,ye,Be,Ae,Te):Qv(Nt,d,Dt,ye);tt.draw(W,W.gl.TRIANGLES,I,F,z,Ze.backCCW,rr,m.id,ke.layoutVertexBuffer,ke.indexBuffer,ke.segments,m.paint,d.transform.zoom,qe)}}}function sf(d,A,m,w,I,F){var z=d.context,W=z.gl,Q=A.fbo;if(Q){var ne=d.useProgram("hillshade");z.activeTexture.set(W.TEXTURE0),W.bindTexture(W.TEXTURE_2D,Q.colorAttachment.get());var pe=function(Ae,ye,Ce){var Se=Ce.paint.get("hillshade-shadow-color"),Be=Ce.paint.get("hillshade-highlight-color"),Te=Ce.paint.get("hillshade-accent-color"),ke=Ce.paint.get("hillshade-illumination-direction")*(Math.PI/180);Ce.paint.get("hillshade-illumination-anchor")==="viewport"&&(ke-=Ae.transform.angle);var qe,tt,ht,ut=!Ae.options.moving;return{u_matrix:Ae.transform.calculatePosMatrix(ye.tileID.toUnwrapped(),ut),u_image:0,u_latrange:(qe=ye.tileID,tt=Math.pow(2,qe.canonical.z),ht=qe.canonical.y,[new n.MercatorCoordinate(0,ht/tt).toLngLat().lat,new n.MercatorCoordinate(0,(ht+1)/tt).toLngLat().lat]),u_light:[Ce.paint.get("hillshade-exaggeration"),ke],u_shadow:Se,u_highlight:Be,u_accent:Te}}(d,A,m);ne.draw(z,W.TRIANGLES,w,I,F,Ze.disabled,pe,m.id,d.rasterBoundsBuffer,d.quadTriangleIndexBuffer,d.rasterBoundsSegments)}}function nA(d,A,m,w,I,F){var z=d.context,W=z.gl,Q=A.dem;if(Q&&Q.data){var ne=Q.dim,pe=Q.stride,Ae=Q.getPixels();if(z.activeTexture.set(W.TEXTURE1),z.pixelStoreUnpackPremultiplyAlpha.set(!1),A.demTexture=A.demTexture||d.getTileTexture(pe),A.demTexture){var ye=A.demTexture;ye.update(Ae,{premultiply:!1}),ye.bind(W.NEAREST,W.CLAMP_TO_EDGE)}else A.demTexture=new n.Texture(z,Ae,W.RGBA,{premultiply:!1}),A.demTexture.bind(W.NEAREST,W.CLAMP_TO_EDGE);z.activeTexture.set(W.TEXTURE0);var Ce=A.fbo;if(!Ce){var Se=new n.Texture(z,{width:ne,height:ne,data:null},W.RGBA);Se.bind(W.LINEAR,W.CLAMP_TO_EDGE),(Ce=A.fbo=z.createFramebuffer(ne,ne,!0)).colorAttachment.set(Se.texture)}z.bindFramebuffer.set(Ce.framebuffer),z.viewport.set([0,0,ne,ne]),d.useProgram("hillshadePrepare").draw(z,W.TRIANGLES,w,I,F,Ze.disabled,function(Be,Te){var ke=Te.stride,qe=n.create();return n.ortho(qe,0,n.EXTENT,-n.EXTENT,0,0,1),n.translate(qe,qe,[0,-n.EXTENT,0]),{u_matrix:qe,u_image:1,u_dimension:[ke,ke],u_zoom:Be.overscaledZ,u_unpack:Te.getUnpackVector()}}(A.tileID,Q),m.id,d.rasterBoundsBuffer,d.quadTriangleIndexBuffer,d.rasterBoundsSegments),A.needsHillshadePrepare=!1}}function Mp(d,A,m,w,I){var F=w.paint.get("raster-fade-duration");if(F>0){var z=n.browser.now(),W=(z-d.timeAdded)/F,Q=A?(z-A.timeAdded)/F:-1,ne=m.getSource(),pe=I.coveringZoomLevel({tileSize:ne.tileSize,roundZoom:ne.roundZoom}),Ae=!A||Math.abs(A.tileID.overscaledZ-pe)>Math.abs(d.tileID.overscaledZ-pe),ye=Ae&&d.refreshedUponExpiration?1:n.clamp(Ae?W:1-Q,0,1);return d.refreshedUponExpiration&&W>=1&&(d.refreshedUponExpiration=!1),A?{opacity:1,mix:1-ye}:{opacity:ye,mix:0}}return{opacity:1,mix:0}}var Zd=new n.Color(1,0,0,1),iA=new n.Color(0,1,0,1),Yd=new n.Color(0,0,1,1),uf=new n.Color(1,0,1,1),mh=new n.Color(0,1,1,1);function Kd(d,A,m,w){lf(d,0,A+m/2,d.transform.width,m,w)}function Qd(d,A,m,w){lf(d,A-m/2,0,m,d.transform.height,w)}function lf(d,A,m,w,I,F){var z=d.context,W=z.gl;W.enable(W.SCISSOR_TEST),W.scissor(A*n.browser.devicePixelRatio,m*n.browser.devicePixelRatio,w*n.browser.devicePixelRatio,I*n.browser.devicePixelRatio),z.clear({color:F}),W.disable(W.SCISSOR_TEST)}function Jd(d,A,m){var w=d.context,I=w.gl,F=m.posMatrix,z=d.useProgram("debug"),W=_e.disabled,Q=me.disabled,ne=d.colorModeForRenderPass();w.activeTexture.set(I.TEXTURE0),d.emptyTexture.bind(I.LINEAR,I.CLAMP_TO_EDGE),z.draw(w,I.LINE_STRIP,W,Q,ne,Ze.disabled,We(F,n.Color.red),"$debug",d.debugBuffer,d.tileBorderIndexBuffer,d.debugSegments);var pe=A.getTileByID(m.key).latestRawTileData,Ae=Math.floor((pe&&pe.byteLength||0)/1024),ye=A.getTile(m).tileSize,Ce=512/Math.min(ye,512)*(m.overscaledZ/d.transform.zoom)*.5,Se=m.canonical.toString();m.overscaledZ!==m.canonical.z&&(Se+=" => "+m.overscaledZ),function(Be,Te){Be.initDebugOverlayCanvas();var ke=Be.debugOverlayCanvas,qe=Be.context.gl,tt=Be.debugOverlayCanvas.getContext("2d");tt.clearRect(0,0,ke.width,ke.height),tt.shadowColor="white",tt.shadowBlur=2,tt.lineWidth=1.5,tt.strokeStyle="white",tt.textBaseline="top",tt.font="bold 36px Open Sans, sans-serif",tt.fillText(Te,5,5),tt.strokeText(Te,5,5),Be.debugOverlayTexture.update(ke),Be.debugOverlayTexture.bind(qe.LINEAR,qe.CLAMP_TO_EDGE)}(d,Se+" "+Ae+"kb"),z.draw(w,I.TRIANGLES,W,Q,je.alphaBlended,Ze.disabled,We(F,n.Color.transparent,Ce),"$debug",d.debugBuffer,d.quadTriangleIndexBuffer,d.debugSegments)}var dl={symbol:function(d,A,m,w,I){if(d.renderPass==="translucent"){var F=me.disabled,z=d.colorModeForRenderPass();m.layout.get("text-variable-anchor")&&function(W,Q,ne,pe,Ae,ye,Ce){for(var Se=Q.transform,Be=Ae==="map",Te=ye==="map",ke=0,qe=W;ke<qe.length;ke+=1){var tt=qe[ke],ht=pe.getTile(tt),ut=ht.getBucket(ne);if(ut&&ut.text&&ut.text.segments.get().length){var vt=n.evaluateSizeForZoom(ut.textSizeData,Se.zoom),Et=Qn(ht,1,Q.transform.zoom),Nt=fi(tt.posMatrix,Te,Be,Q.transform,Et),Dt=ne.layout.get("icon-text-fit")!=="none"&&ut.hasIconData();if(vt){var rr=Math.pow(2,Se.zoom-ht.tileID.overscaledZ);tA(ut,Be,Te,Ce,n.symbolSize,Se,Nt,tt.posMatrix,rr,vt,Dt)}}}}(w,d,m,A,m.layout.get("text-rotation-alignment"),m.layout.get("text-pitch-alignment"),I),m.paint.get("icon-opacity").constantOr(1)!==0&&Bl(d,A,m,w,!1,m.paint.get("icon-translate"),m.paint.get("icon-translate-anchor"),m.layout.get("icon-rotation-alignment"),m.layout.get("icon-pitch-alignment"),m.layout.get("icon-keep-upright"),F,z),m.paint.get("text-opacity").constantOr(1)!==0&&Bl(d,A,m,w,!0,m.paint.get("text-translate"),m.paint.get("text-translate-anchor"),m.layout.get("text-rotation-alignment"),m.layout.get("text-pitch-alignment"),m.layout.get("text-keep-upright"),F,z),A.map.showCollisionBoxes&&(Yi(d,A,m,w,m.paint.get("text-translate"),m.paint.get("text-translate-anchor"),!0),Yi(d,A,m,w,m.paint.get("icon-translate"),m.paint.get("icon-translate-anchor"),!1))}},circle:function(d,A,m,w){if(d.renderPass==="translucent"){var I=m.paint.get("circle-opacity"),F=m.paint.get("circle-stroke-width"),z=m.paint.get("circle-stroke-opacity"),W=m.layout.get("circle-sort-key").constantOr(1)!==void 0;if(I.constantOr(1)!==0||F.constantOr(1)!==0&&z.constantOr(1)!==0){for(var Q=d.context,ne=Q.gl,pe=d.depthModeForSublayer(0,_e.ReadOnly),Ae=me.disabled,ye=d.colorModeForRenderPass(),Ce=[],Se=0;Se<w.length;Se++){var Be=w[Se],Te=A.getTile(Be),ke=Te.getBucket(m);if(ke){var qe=ke.programConfigurations.get(m.id),tt={programConfiguration:qe,program:d.useProgram("circle",qe),layoutVertexBuffer:ke.layoutVertexBuffer,indexBuffer:ke.indexBuffer,uniformValues:qd(d,Be,Te,m)};if(W)for(var ht=0,ut=ke.segments.get();ht<ut.length;ht+=1){var vt=ut[ht];Ce.push({segments:new n.SegmentVector([vt]),sortKey:vt.sortKey,state:tt})}else Ce.push({segments:ke.segments,sortKey:0,state:tt})}}W&&Ce.sort(function(Rr,Ur){return Rr.sortKey-Ur.sortKey});for(var Et=0,Nt=Ce;Et<Nt.length;Et+=1){var Dt=Nt[Et],rr=Dt.state;rr.program.draw(Q,ne.TRIANGLES,pe,Ae,ye,Ze.disabled,rr.uniformValues,m.id,rr.layoutVertexBuffer,rr.indexBuffer,Dt.segments,m.paint,d.transform.zoom,rr.programConfiguration)}}}},heatmap:function(d,A,m,w){if(m.paint.get("heatmap-opacity")!==0)if(d.renderPass==="offscreen"){var I=d.context,F=I.gl,z=me.disabled,W=new je([F.ONE,F.ONE],n.Color.transparent,[!0,!0,!0,!0]);(function(Ce,Se,Be){var Te=Ce.gl;Ce.activeTexture.set(Te.TEXTURE1),Ce.viewport.set([0,0,Se.width/4,Se.height/4]);var ke=Be.heatmapFbo;if(ke)Te.bindTexture(Te.TEXTURE_2D,ke.colorAttachment.get()),Ce.bindFramebuffer.set(ke.framebuffer);else{var qe=Te.createTexture();Te.bindTexture(Te.TEXTURE_2D,qe),Te.texParameteri(Te.TEXTURE_2D,Te.TEXTURE_WRAP_S,Te.CLAMP_TO_EDGE),Te.texParameteri(Te.TEXTURE_2D,Te.TEXTURE_WRAP_T,Te.CLAMP_TO_EDGE),Te.texParameteri(Te.TEXTURE_2D,Te.TEXTURE_MIN_FILTER,Te.LINEAR),Te.texParameteri(Te.TEXTURE_2D,Te.TEXTURE_MAG_FILTER,Te.LINEAR),ke=Be.heatmapFbo=Ce.createFramebuffer(Se.width/4,Se.height/4,!1),function(tt,ht,ut,vt){var Et=tt.gl;Et.texImage2D(Et.TEXTURE_2D,0,Et.RGBA,ht.width/4,ht.height/4,0,Et.RGBA,tt.extRenderToTextureHalfFloat?tt.extTextureHalfFloat.HALF_FLOAT_OES:Et.UNSIGNED_BYTE,null),vt.colorAttachment.set(ut)}(Ce,Se,qe,ke)}})(I,d,m),I.clear({color:n.Color.transparent});for(var Q=0;Q<w.length;Q++){var ne=w[Q];if(!A.hasRenderableParent(ne)){var pe=A.getTile(ne),Ae=pe.getBucket(m);if(Ae){var ye=Ae.programConfigurations.get(m.id);d.useProgram("heatmap",ye).draw(I,F.TRIANGLES,_e.disabled,z,W,Ze.disabled,Xd(ne.posMatrix,pe,d.transform.zoom,m.paint.get("heatmap-intensity")),m.id,Ae.layoutVertexBuffer,Ae.indexBuffer,Ae.segments,m.paint,d.transform.zoom,ye)}}}I.viewport.set([0,0,d.width,d.height])}else d.renderPass==="translucent"&&(d.context.setColorMode(d.colorModeForRenderPass()),function(Ce,Se){var Be=Ce.context,Te=Be.gl,ke=Se.heatmapFbo;if(ke){Be.activeTexture.set(Te.TEXTURE0),Te.bindTexture(Te.TEXTURE_2D,ke.colorAttachment.get()),Be.activeTexture.set(Te.TEXTURE1);var qe=Se.colorRampTexture;qe||(qe=Se.colorRampTexture=new n.Texture(Be,Se.colorRamp,Te.RGBA)),qe.bind(Te.LINEAR,Te.CLAMP_TO_EDGE),Ce.useProgram("heatmapTexture").draw(Be,Te.TRIANGLES,_e.disabled,me.disabled,Ce.colorModeForRenderPass(),Ze.disabled,function(tt,ht,ut,vt){var Et=n.create();n.ortho(Et,0,tt.width,tt.height,0,0,1);var Nt=tt.context.gl;return{u_matrix:Et,u_world:[Nt.drawingBufferWidth,Nt.drawingBufferHeight],u_image:0,u_color_ramp:1,u_opacity:ht.paint.get("heatmap-opacity")}}(Ce,Se),Se.id,Ce.viewportBuffer,Ce.quadTriangleIndexBuffer,Ce.viewportSegments,Se.paint,Ce.transform.zoom)}}(d,m))},line:function(d,A,m,w){if(d.renderPass==="translucent"){var I=m.paint.get("line-opacity"),F=m.paint.get("line-width");if(I.constantOr(1)!==0&&F.constantOr(1)!==0)for(var z=d.depthModeForSublayer(0,_e.ReadOnly),W=d.colorModeForRenderPass(),Q=m.paint.get("line-dasharray"),ne=m.paint.get("line-pattern"),pe=ne.constantOr(1),Ae=m.paint.get("line-gradient"),ye=m.getCrossfadeParameters(),Ce=pe?"linePattern":Q?"lineSDF":Ae?"lineGradient":"line",Se=d.context,Be=Se.gl,Te=!0,ke=0,qe=w;ke<qe.length;ke+=1){var tt=qe[ke],ht=A.getTile(tt);if(!pe||ht.patternsLoaded()){var ut=ht.getBucket(m);if(ut){var vt=ut.programConfigurations.get(m.id),Et=d.context.program.get(),Nt=d.useProgram(Ce,vt),Dt=Te||Nt.program!==Et,rr=ne.constantOr(null);if(rr&&ht.imageAtlas){var Rr=ht.imageAtlas,Ur=Rr.patternPositions[rr.to.toString()],Fr=Rr.patternPositions[rr.from.toString()];Ur&&Fr&&vt.setConstantPatternPositions(Ur,Fr)}var kn=pe?Sp(d,ht,m,ye):Q?_y(d,ht,m,Q,ye):Ae?Pi(d,ht,m,ut.lineClipsArray.length):ch(d,ht,m);if(pe)Se.activeTexture.set(Be.TEXTURE0),ht.imageAtlasTexture.bind(Be.LINEAR,Be.CLAMP_TO_EDGE),vt.updatePaintBuffers(ye);else if(Q&&(Dt||d.lineAtlas.dirty))Se.activeTexture.set(Be.TEXTURE0),d.lineAtlas.bind(Se);else if(Ae){var ir=ut.gradients[m.id],_r=ir.texture;if(m.gradientVersion!==ir.version){var sn=256;if(m.stepInterpolant){var Yr=A.getSource().maxzoom,Xr=tt.canonical.z===Yr?Math.ceil(1<<d.transform.maxZoom-tt.canonical.z):1;sn=n.clamp(n.nextPowerOfTwo(ut.maxLineLength/n.EXTENT*1024*Xr),256,Se.maxTextureSize)}ir.gradient=n.renderColorRamp({expression:m.gradientExpression(),evaluationKey:"lineProgress",resolution:sn,image:ir.gradient||void 0,clips:ut.lineClipsArray}),ir.texture?ir.texture.update(ir.gradient):ir.texture=new n.Texture(Se,ir.gradient,Be.RGBA),ir.version=m.gradientVersion,_r=ir.texture}Se.activeTexture.set(Be.TEXTURE0),_r.bind(m.stepInterpolant?Be.NEAREST:Be.LINEAR,Be.CLAMP_TO_EDGE)}Nt.draw(Se,Be.TRIANGLES,z,d.stencilModeForClipping(tt),W,Ze.disabled,kn,m.id,ut.layoutVertexBuffer,ut.indexBuffer,ut.segments,m.paint,d.transform.zoom,vt,ut.layoutVertexBuffer2),Te=!1}}}}},fill:function(d,A,m,w){var I=m.paint.get("fill-color"),F=m.paint.get("fill-opacity");if(F.constantOr(1)!==0){var z=d.colorModeForRenderPass(),W=m.paint.get("fill-pattern"),Q=d.opaquePassEnabledForLayer()&&!W.constantOr(1)&&I.constantOr(n.Color.transparent).a===1&&F.constantOr(0)===1?"opaque":"translucent";if(d.renderPass===Q){var ne=d.depthModeForSublayer(1,d.renderPass==="opaque"?_e.ReadWrite:_e.ReadOnly);Cp(d,A,m,w,ne,z,!1)}if(d.renderPass==="translucent"&&m.paint.get("fill-antialias")){var pe=d.depthModeForSublayer(m.getPaintProperty("fill-outline-color")?2:0,_e.ReadOnly);Cp(d,A,m,w,pe,z,!0)}}},"fill-extrusion":function(d,A,m,w){var I=m.paint.get("fill-extrusion-opacity");if(I!==0&&d.renderPass==="translucent"){var F=new _e(d.context.gl.LEQUAL,_e.ReadWrite,d.depthRangeFor3D);if(I!==1||m.paint.get("fill-extrusion-pattern").constantOr(1))ji(d,A,m,w,F,me.disabled,je.disabled),ji(d,A,m,w,F,d.stencilModeFor3D(),d.colorModeForRenderPass());else{var z=d.colorModeForRenderPass();ji(d,A,m,w,F,me.disabled,z)}}},hillshade:function(d,A,m,w){if(d.renderPass==="offscreen"||d.renderPass==="translucent"){for(var I=d.context,F=d.depthModeForSublayer(0,_e.ReadOnly),z=d.colorModeForRenderPass(),W=d.renderPass==="translucent"?d.stencilConfigForOverlap(w):[{},w],Q=W[0],ne=0,pe=W[1];ne<pe.length;ne+=1){var Ae=pe[ne],ye=A.getTile(Ae);ye.needsHillshadePrepare&&d.renderPass==="offscreen"?nA(d,ye,m,F,me.disabled,z):d.renderPass==="translucent"&&sf(d,ye,m,F,Q[Ae.overscaledZ],z)}I.viewport.set([0,0,d.width,d.height])}},raster:function(d,A,m,w){if(d.renderPass==="translucent"&&m.paint.get("raster-opacity")!==0&&w.length)for(var I=d.context,F=I.gl,z=A.getSource(),W=d.useProgram("raster"),Q=d.colorModeForRenderPass(),ne=z instanceof wt?[{},w]:d.stencilConfigForOverlap(w),pe=ne[0],Ae=ne[1],ye=Ae[Ae.length-1].overscaledZ,Ce=!d.options.moving,Se=0,Be=Ae;Se<Be.length;Se+=1){var Te=Be[Se],ke=d.depthModeForSublayer(Te.overscaledZ-ye,m.paint.get("raster-opacity")===1?_e.ReadWrite:_e.ReadOnly,F.LESS),qe=A.getTile(Te),tt=d.transform.calculatePosMatrix(Te.toUnwrapped(),Ce);qe.registerFadeDuration(m.paint.get("raster-fade-duration"));var ht=A.findLoadedParent(Te,0),ut=Mp(qe,ht,A,m,d.transform),vt=void 0,Et=void 0,Nt=m.paint.get("raster-resampling")==="nearest"?F.NEAREST:F.LINEAR;I.activeTexture.set(F.TEXTURE0),qe.texture.bind(Nt,F.CLAMP_TO_EDGE,F.LINEAR_MIPMAP_NEAREST),I.activeTexture.set(F.TEXTURE1),ht?(ht.texture.bind(Nt,F.CLAMP_TO_EDGE,F.LINEAR_MIPMAP_NEAREST),vt=Math.pow(2,ht.tileID.overscaledZ-qe.tileID.overscaledZ),Et=[qe.tileID.canonical.x*vt%1,qe.tileID.canonical.y*vt%1]):qe.texture.bind(Nt,F.CLAMP_TO_EDGE,F.LINEAR_MIPMAP_NEAREST);var Dt=xy(tt,Et||[0,0],vt||1,ut,m);z instanceof wt?W.draw(I,F.TRIANGLES,ke,me.disabled,Q,Ze.disabled,Dt,m.id,z.boundsBuffer,d.quadTriangleIndexBuffer,z.boundsSegments):W.draw(I,F.TRIANGLES,ke,pe[Te.overscaledZ],Q,Ze.disabled,Dt,m.id,d.rasterBoundsBuffer,d.quadTriangleIndexBuffer,d.rasterBoundsSegments)}},background:function(d,A,m){var w=m.paint.get("background-color"),I=m.paint.get("background-opacity");if(I!==0){var F=d.context,z=F.gl,W=d.transform,Q=W.tileSize,ne=m.paint.get("background-pattern");if(!d.isPatternMissing(ne)){var pe=!ne&&w.a===1&&I===1&&d.opaquePassEnabledForLayer()?"opaque":"translucent";if(d.renderPass===pe){var Ae=me.disabled,ye=d.depthModeForSublayer(0,pe==="opaque"?_e.ReadWrite:_e.ReadOnly),Ce=d.colorModeForRenderPass(),Se=d.useProgram(ne?"backgroundPattern":"background"),Be=W.coveringTiles({tileSize:Q});ne&&(F.activeTexture.set(z.TEXTURE0),d.imageManager.bind(d.context));for(var Te=m.getCrossfadeParameters(),ke=0,qe=Be;ke<qe.length;ke+=1){var tt=qe[ke],ht=d.transform.calculatePosMatrix(tt.toUnwrapped()),ut=ne?kl(ht,I,d,ne,{tileID:tt,tileSize:Q},Te):ph(ht,I,w);Se.draw(F,z.TRIANGLES,ye,Ae,Ce,Ze.disabled,ut,m.id,d.tileExtentBuffer,d.quadTriangleIndexBuffer,d.tileExtentSegments)}}}}},debug:function(d,A,m){for(var w=0;w<m.length;w++)Jd(d,A,m[w])},custom:function(d,A,m){var w=d.context,I=m.implementation;if(d.renderPass==="offscreen"){var F=I.prerender;F&&(d.setCustomLayerDefaults(),w.setColorMode(d.colorModeForRenderPass()),F.call(I,w.gl,d.transform.customLayerMatrix()),w.setDirty(),d.setBaseState())}else if(d.renderPass==="translucent"){d.setCustomLayerDefaults(),w.setColorMode(d.colorModeForRenderPass()),w.setStencilMode(me.disabled);var z=I.renderingMode==="3d"?new _e(d.context.gl.LEQUAL,_e.ReadWrite,d.depthRangeFor3D):d.depthModeForSublayer(0,_e.ReadOnly);w.setDepthMode(z),I.render(w.gl,d.transform.customLayerMatrix()),w.setDirty(),d.setBaseState(),w.bindFramebuffer.set(null)}}},Li=function(d,A){this.context=new ge(d),this.transform=A,this._tileTextures={},this.setup(),this.numSublayers=Oe.maxUnderzooming+Oe.maxOverzooming+1,this.depthEpsilon=1/Math.pow(2,16),this.crossTileSymbolIndex=new fc,this.gpuTimers={}};Li.prototype.resize=function(d,A){if(this.width=d*n.browser.devicePixelRatio,this.height=A*n.browser.devicePixelRatio,this.context.viewport.set([0,0,this.width,this.height]),this.style)for(var m=0,w=this.style._order;m<w.length;m+=1)this.style._layers[w[m]].resize()},Li.prototype.setup=function(){var d=this.context,A=new n.StructArrayLayout2i4;A.emplaceBack(0,0),A.emplaceBack(n.EXTENT,0),A.emplaceBack(0,n.EXTENT),A.emplaceBack(n.EXTENT,n.EXTENT),this.tileExtentBuffer=d.createVertexBuffer(A,ka.members),this.tileExtentSegments=n.SegmentVector.simpleSegment(0,0,4,2);var m=new n.StructArrayLayout2i4;m.emplaceBack(0,0),m.emplaceBack(n.EXTENT,0),m.emplaceBack(0,n.EXTENT),m.emplaceBack(n.EXTENT,n.EXTENT),this.debugBuffer=d.createVertexBuffer(m,ka.members),this.debugSegments=n.SegmentVector.simpleSegment(0,0,4,5);var w=new n.StructArrayLayout4i8;w.emplaceBack(0,0,0,0),w.emplaceBack(n.EXTENT,0,n.EXTENT,0),w.emplaceBack(0,n.EXTENT,0,n.EXTENT),w.emplaceBack(n.EXTENT,n.EXTENT,n.EXTENT,n.EXTENT),this.rasterBoundsBuffer=d.createVertexBuffer(w,Je.members),this.rasterBoundsSegments=n.SegmentVector.simpleSegment(0,0,4,2);var I=new n.StructArrayLayout2i4;I.emplaceBack(0,0),I.emplaceBack(1,0),I.emplaceBack(0,1),I.emplaceBack(1,1),this.viewportBuffer=d.createVertexBuffer(I,ka.members),this.viewportSegments=n.SegmentVector.simpleSegment(0,0,4,2);var F=new n.StructArrayLayout1ui2;F.emplaceBack(0),F.emplaceBack(1),F.emplaceBack(3),F.emplaceBack(2),F.emplaceBack(0),this.tileBorderIndexBuffer=d.createIndexBuffer(F);var z=new n.StructArrayLayout3ui6;z.emplaceBack(0,1,2),z.emplaceBack(2,1,3),this.quadTriangleIndexBuffer=d.createIndexBuffer(z),this.emptyTexture=new n.Texture(d,{width:1,height:1,data:new Uint8Array([0,0,0,0])},d.gl.RGBA);var W=this.context.gl;this.stencilClearMode=new me({func:W.ALWAYS,mask:0},0,255,W.ZERO,W.ZERO,W.ZERO)},Li.prototype.clearStencil=function(){var d=this.context,A=d.gl;this.nextStencilID=1,this.currentStencilSource=void 0;var m=n.create();n.ortho(m,0,this.width,this.height,0,0,1),n.scale(m,m,[A.drawingBufferWidth,A.drawingBufferHeight,0]),this.useProgram("clippingMask").draw(d,A.TRIANGLES,_e.disabled,this.stencilClearMode,je.disabled,Ze.disabled,Jn(m),"$clipping",this.viewportBuffer,this.quadTriangleIndexBuffer,this.viewportSegments)},Li.prototype._renderTileClippingMasks=function(d,A){if(this.currentStencilSource!==d.source&&d.isTileClipped()&&A&&A.length){this.currentStencilSource=d.source;var m=this.context,w=m.gl;this.nextStencilID+A.length>256&&this.clearStencil(),m.setColorMode(je.disabled),m.setDepthMode(_e.disabled);var I=this.useProgram("clippingMask");this._tileClippingMaskIDs={};for(var F=0,z=A;F<z.length;F+=1){var W=z[F],Q=this._tileClippingMaskIDs[W.key]=this.nextStencilID++;I.draw(m,w.TRIANGLES,_e.disabled,new me({func:w.ALWAYS,mask:0},Q,255,w.KEEP,w.KEEP,w.REPLACE),je.disabled,Ze.disabled,Jn(W.posMatrix),"$clipping",this.tileExtentBuffer,this.quadTriangleIndexBuffer,this.tileExtentSegments)}}},Li.prototype.stencilModeFor3D=function(){this.currentStencilSource=void 0,this.nextStencilID+1>256&&this.clearStencil();var d=this.nextStencilID++,A=this.context.gl;return new me({func:A.NOTEQUAL,mask:255},d,255,A.KEEP,A.KEEP,A.REPLACE)},Li.prototype.stencilModeForClipping=function(d){var A=this.context.gl;return new me({func:A.EQUAL,mask:255},this._tileClippingMaskIDs[d.key],0,A.KEEP,A.KEEP,A.REPLACE)},Li.prototype.stencilConfigForOverlap=function(d){var A,m=this.context.gl,w=d.sort(function(Q,ne){return ne.overscaledZ-Q.overscaledZ}),I=w[w.length-1].overscaledZ,F=w[0].overscaledZ-I+1;if(F>1){this.currentStencilSource=void 0,this.nextStencilID+F>256&&this.clearStencil();for(var z={},W=0;W<F;W++)z[W+I]=new me({func:m.GEQUAL,mask:255},W+this.nextStencilID,255,m.KEEP,m.KEEP,m.REPLACE);return this.nextStencilID+=F,[z,w]}return[(A={},A[I]=me.disabled,A),w]},Li.prototype.colorModeForRenderPass=function(){var d=this.context.gl;return this._showOverdrawInspector?new je([d.CONSTANT_COLOR,d.ONE],new n.Color(1/8,1/8,1/8,0),[!0,!0,!0,!0]):this.renderPass==="opaque"?je.unblended:je.alphaBlended},Li.prototype.depthModeForSublayer=function(d,A,m){if(!this.opaquePassEnabledForLayer())return _e.disabled;var w=1-((1+this.currentLayer)*this.numSublayers+d)*this.depthEpsilon;return new _e(m||this.context.gl.LEQUAL,A,[w,w])},Li.prototype.opaquePassEnabledForLayer=function(){return this.currentLayer<this.opaquePassCutoff},Li.prototype.render=function(d,A){var m=this;this.style=d,this.options=A,this.lineAtlas=d.lineAtlas,this.imageManager=d.imageManager,this.glyphManager=d.glyphManager,this.symbolFadeChange=d.placement.symbolFadeChange(n.browser.now()),this.imageManager.beginFrame();var w=this.style._order,I=this.style.sourceCaches;for(var F in I){var z=I[F];z.used&&z.prepare(this.context)}var W,Q,ne={},pe={},Ae={};for(var ye in I){var Ce=I[ye];ne[ye]=Ce.getVisibleCoordinates(),pe[ye]=ne[ye].slice().reverse(),Ae[ye]=Ce.getVisibleCoordinates(!0).reverse()}this.opaquePassCutoff=1/0;for(var Se=0;Se<w.length;Se++)if(this.style._layers[w[Se]].is3D()){this.opaquePassCutoff=Se;break}this.renderPass="offscreen";for(var Be=0,Te=w;Be<Te.length;Be+=1){var ke=this.style._layers[Te[Be]];if(ke.hasOffscreenPass()&&!ke.isHidden(this.transform.zoom)){var qe=pe[ke.source];(ke.type==="custom"||qe.length)&&this.renderLayer(this,I[ke.source],ke,qe)}}for(this.context.bindFramebuffer.set(null),this.context.clear({color:A.showOverdrawInspector?n.Color.black:n.Color.transparent,depth:1}),this.clearStencil(),this._showOverdrawInspector=A.showOverdrawInspector,this.depthRangeFor3D=[0,1-(d._order.length+2)*this.numSublayers*this.depthEpsilon],this.renderPass="opaque",this.currentLayer=w.length-1;this.currentLayer>=0;this.currentLayer--){var tt=this.style._layers[w[this.currentLayer]],ht=I[tt.source],ut=ne[tt.source];this._renderTileClippingMasks(tt,ut),this.renderLayer(this,ht,tt,ut)}for(this.renderPass="translucent",this.currentLayer=0;this.currentLayer<w.length;this.currentLayer++){var vt=this.style._layers[w[this.currentLayer]],Et=I[vt.source],Nt=(vt.type==="symbol"?Ae:pe)[vt.source];this._renderTileClippingMasks(vt,ne[vt.source]),this.renderLayer(this,Et,vt,Nt)}this.options.showTileBoundaries&&(n.values(this.style._layers).forEach(function(Dt){Dt.source&&!Dt.isHidden(m.transform.zoom)&&(Dt.source!==(Q&&Q.id)&&(Q=m.style.sourceCaches[Dt.source]),(!W||W.getSource().maxzoom<Q.getSource().maxzoom)&&(W=Q))}),W&&dl.debug(this,W,W.getVisibleCoordinates())),this.options.showPadding&&function(Dt){var rr=Dt.transform.padding;Kd(Dt,Dt.transform.height-(rr.top||0),3,Zd),Kd(Dt,rr.bottom||0,3,iA),Qd(Dt,rr.left||0,3,Yd),Qd(Dt,Dt.transform.width-(rr.right||0),3,uf);var Rr=Dt.transform.centerPoint;(function(Ur,Fr,kn,ir){lf(Ur,Fr-1,kn-10,2,20,ir),lf(Ur,Fr-10,kn-1,20,2,ir)})(Dt,Rr.x,Dt.transform.height-Rr.y,mh)}(this),this.context.setDefault()},Li.prototype.renderLayer=function(d,A,m,w){m.isHidden(this.transform.zoom)||(m.type==="background"||m.type==="custom"||w.length)&&(this.id=m.id,this.gpuTimingStart(m),dl[m.type](d,A,m,w,this.style.placement.variableOffsets),this.gpuTimingEnd())},Li.prototype.gpuTimingStart=function(d){if(this.options.gpuTiming){var A=this.context.extTimerQuery,m=this.gpuTimers[d.id];m||(m=this.gpuTimers[d.id]={calls:0,cpuTime:0,query:A.createQueryEXT()}),m.calls++,A.beginQueryEXT(A.TIME_ELAPSED_EXT,m.query)}},Li.prototype.gpuTimingEnd=function(){if(this.options.gpuTiming){var d=this.context.extTimerQuery;d.endQueryEXT(d.TIME_ELAPSED_EXT)}},Li.prototype.collectGpuTimers=function(){var d=this.gpuTimers;return this.gpuTimers={},d},Li.prototype.queryGpuTimers=function(d){var A={};for(var m in d){var w=d[m],I=this.context.extTimerQuery,F=I.getQueryObjectEXT(w.query,I.QUERY_RESULT_EXT)/1e6;I.deleteQueryEXT(w.query),A[m]=F}return A},Li.prototype.translatePosMatrix=function(d,A,m,w,I){if(!m[0]&&!m[1])return d;var F=I?w==="map"?this.transform.angle:0:w==="viewport"?-this.transform.angle:0;if(F){var z=Math.sin(F),W=Math.cos(F);m=[m[0]*W-m[1]*z,m[0]*z+m[1]*W]}var Q=[I?m[0]:Qn(A,m[0],this.transform.zoom),I?m[1]:Qn(A,m[1],this.transform.zoom),0],ne=new Float32Array(16);return n.translate(ne,d,Q),ne},Li.prototype.saveTileTexture=function(d){var A=this._tileTextures[d.size[0]];A?A.push(d):this._tileTextures[d.size[0]]=[d]},Li.prototype.getTileTexture=function(d){var A=this._tileTextures[d];return A&&A.length>0?A.pop():null},Li.prototype.isPatternMissing=function(d){if(!d)return!1;if(!d.from||!d.to)return!0;var A=this.imageManager.getPattern(d.from.toString()),m=this.imageManager.getPattern(d.to.toString());return!A||!m},Li.prototype.useProgram=function(d,A){this.cache=this.cache||{};var m=""+d+(A?A.cacheKey:"")+(this._showOverdrawInspector?"/overdraw":"");return this.cache[m]||(this.cache[m]=new Wn(this.context,d,da[d],A,du[d],this._showOverdrawInspector)),this.cache[m]},Li.prototype.setCustomLayerDefaults=function(){this.context.unbindVAO(),this.context.cullFace.setDefault(),this.context.activeTexture.setDefault(),this.context.pixelStoreUnpack.setDefault(),this.context.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.context.pixelStoreUnpackFlipY.setDefault()},Li.prototype.setBaseState=function(){var d=this.context.gl;this.context.cullFace.set(!1),this.context.viewport.set([0,0,this.width,this.height]),this.context.blendEquation.set(d.FUNC_ADD)},Li.prototype.initDebugOverlayCanvas=function(){this.debugOverlayCanvas==null&&(this.debugOverlayCanvas=n.window.document.createElement("canvas"),this.debugOverlayCanvas.width=512,this.debugOverlayCanvas.height=512,this.debugOverlayTexture=new n.Texture(this.context,this.debugOverlayCanvas,this.context.gl.RGBA))},Li.prototype.destroy=function(){this.emptyTexture.destroy(),this.debugOverlayTexture&&this.debugOverlayTexture.destroy()};var Op=function(d,A){this.points=d,this.planes=A};Op.fromInvProjectionMatrix=function(d,A,m){var w=Math.pow(2,m),I=[[-1,1,-1,1],[1,1,-1,1],[1,-1,-1,1],[-1,-1,-1,1],[-1,1,1,1],[1,1,1,1],[1,-1,1,1],[-1,-1,1,1]].map(function(z){return n.transformMat4([],z,d)}).map(function(z){return n.scale$1([],z,1/z[3]/A*w)}),F=[[0,1,2],[6,5,4],[0,3,7],[2,1,5],[3,2,6],[0,4,5]].map(function(z){var W=n.sub([],I[z[0]],I[z[1]]),Q=n.sub([],I[z[2]],I[z[1]]),ne=n.normalize([],n.cross([],W,Q)),pe=-n.dot(ne,I[z[1]]);return ne.concat(pe)});return new Op(I,F)};var mc=function(d,A){this.min=d,this.max=A,this.center=n.scale$2([],n.add([],this.min,this.max),.5)};mc.prototype.quadrant=function(d){for(var A=[d%2==0,d<2],m=n.clone$2(this.min),w=n.clone$2(this.max),I=0;I<A.length;I++)m[I]=A[I]?this.min[I]:this.center[I],w[I]=A[I]?this.center[I]:this.max[I];return w[2]=this.max[2],new mc(m,w)},mc.prototype.distanceX=function(d){return Math.max(Math.min(this.max[0],d[0]),this.min[0])-d[0]},mc.prototype.distanceY=function(d){return Math.max(Math.min(this.max[1],d[1]),this.min[1])-d[1]},mc.prototype.intersects=function(d){for(var A=[[this.min[0],this.min[1],0,1],[this.max[0],this.min[1],0,1],[this.max[0],this.max[1],0,1],[this.min[0],this.max[1],0,1]],m=!0,w=0;w<d.planes.length;w++){for(var I=d.planes[w],F=0,z=0;z<A.length;z++)F+=n.dot$1(I,A[z])>=0;if(F===0)return 0;F!==A.length&&(m=!1)}if(m)return 2;for(var W=0;W<3;W++){for(var Q=Number.MAX_VALUE,ne=-Number.MAX_VALUE,pe=0;pe<d.points.length;pe++){var Ae=d.points[pe][W]-this.min[W];Q=Math.min(Q,Ae),ne=Math.max(ne,Ae)}if(ne<0||Q>this.max[W]-this.min[W])return 0}return 1};var ma=function(d,A,m,w){if(d===void 0&&(d=0),A===void 0&&(A=0),m===void 0&&(m=0),w===void 0&&(w=0),isNaN(d)||d<0||isNaN(A)||A<0||isNaN(m)||m<0||isNaN(w)||w<0)throw new Error("Invalid value for edge-insets, top, bottom, left and right must all be numbers");this.top=d,this.bottom=A,this.left=m,this.right=w};ma.prototype.interpolate=function(d,A,m){return A.top!=null&&d.top!=null&&(this.top=n.number(d.top,A.top,m)),A.bottom!=null&&d.bottom!=null&&(this.bottom=n.number(d.bottom,A.bottom,m)),A.left!=null&&d.left!=null&&(this.left=n.number(d.left,A.left,m)),A.right!=null&&d.right!=null&&(this.right=n.number(d.right,A.right,m)),this},ma.prototype.getCenter=function(d,A){var m=n.clamp((this.left+d-this.right)/2,0,d),w=n.clamp((this.top+A-this.bottom)/2,0,A);return new n.Point(m,w)},ma.prototype.equals=function(d){return this.top===d.top&&this.bottom===d.bottom&&this.left===d.left&&this.right===d.right},ma.prototype.clone=function(){return new ma(this.top,this.bottom,this.left,this.right)},ma.prototype.toJSON=function(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}};var pn=function(d,A,m,w,I){this.tileSize=512,this.maxValidLatitude=85.051129,this._renderWorldCopies=I===void 0||I,this._minZoom=d||0,this._maxZoom=A||22,this._minPitch=m??0,this._maxPitch=w??60,this.setMaxBounds(),this.width=0,this.height=0,this._center=new n.LngLat(0,0),this.zoom=0,this.angle=0,this._fov=.6435011087932844,this._pitch=0,this._unmodified=!0,this._edgeInsets=new ma,this._posMatrixCache={},this._alignedPosMatrixCache={}},wn={minZoom:{configurable:!0},maxZoom:{configurable:!0},minPitch:{configurable:!0},maxPitch:{configurable:!0},renderWorldCopies:{configurable:!0},worldSize:{configurable:!0},centerOffset:{configurable:!0},size:{configurable:!0},bearing:{configurable:!0},pitch:{configurable:!0},fov:{configurable:!0},zoom:{configurable:!0},center:{configurable:!0},padding:{configurable:!0},centerPoint:{configurable:!0},unmodified:{configurable:!0},point:{configurable:!0}};pn.prototype.clone=function(){var d=new pn(this._minZoom,this._maxZoom,this._minPitch,this.maxPitch,this._renderWorldCopies);return d.tileSize=this.tileSize,d.latRange=this.latRange,d.width=this.width,d.height=this.height,d._center=this._center,d.zoom=this.zoom,d.angle=this.angle,d._fov=this._fov,d._pitch=this._pitch,d._unmodified=this._unmodified,d._edgeInsets=this._edgeInsets.clone(),d._calcMatrices(),d},wn.minZoom.get=function(){return this._minZoom},wn.minZoom.set=function(d){this._minZoom!==d&&(this._minZoom=d,this.zoom=Math.max(this.zoom,d))},wn.maxZoom.get=function(){return this._maxZoom},wn.maxZoom.set=function(d){this._maxZoom!==d&&(this._maxZoom=d,this.zoom=Math.min(this.zoom,d))},wn.minPitch.get=function(){return this._minPitch},wn.minPitch.set=function(d){this._minPitch!==d&&(this._minPitch=d,this.pitch=Math.max(this.pitch,d))},wn.maxPitch.get=function(){return this._maxPitch},wn.maxPitch.set=function(d){this._maxPitch!==d&&(this._maxPitch=d,this.pitch=Math.min(this.pitch,d))},wn.renderWorldCopies.get=function(){return this._renderWorldCopies},wn.renderWorldCopies.set=function(d){d===void 0?d=!0:d===null&&(d=!1),this._renderWorldCopies=d},wn.worldSize.get=function(){return this.tileSize*this.scale},wn.centerOffset.get=function(){return this.centerPoint._sub(this.size._div(2))},wn.size.get=function(){return new n.Point(this.width,this.height)},wn.bearing.get=function(){return-this.angle/Math.PI*180},wn.bearing.set=function(d){var A=-n.wrap(d,-180,180)*Math.PI/180;this.angle!==A&&(this._unmodified=!1,this.angle=A,this._calcMatrices(),this.rotationMatrix=n.create$2(),n.rotate(this.rotationMatrix,this.rotationMatrix,this.angle))},wn.pitch.get=function(){return this._pitch/Math.PI*180},wn.pitch.set=function(d){var A=n.clamp(d,this.minPitch,this.maxPitch)/180*Math.PI;this._pitch!==A&&(this._unmodified=!1,this._pitch=A,this._calcMatrices())},wn.fov.get=function(){return this._fov/Math.PI*180},wn.fov.set=function(d){d=Math.max(.01,Math.min(60,d)),this._fov!==d&&(this._unmodified=!1,this._fov=d/180*Math.PI,this._calcMatrices())},wn.zoom.get=function(){return this._zoom},wn.zoom.set=function(d){var A=Math.min(Math.max(d,this.minZoom),this.maxZoom);this._zoom!==A&&(this._unmodified=!1,this._zoom=A,this.scale=this.zoomScale(A),this.tileZoom=Math.floor(A),this.zoomFraction=A-this.tileZoom,this._constrain(),this._calcMatrices())},wn.center.get=function(){return this._center},wn.center.set=function(d){d.lat===this._center.lat&&d.lng===this._center.lng||(this._unmodified=!1,this._center=d,this._constrain(),this._calcMatrices())},wn.padding.get=function(){return this._edgeInsets.toJSON()},wn.padding.set=function(d){this._edgeInsets.equals(d)||(this._unmodified=!1,this._edgeInsets.interpolate(this._edgeInsets,d,1),this._calcMatrices())},wn.centerPoint.get=function(){return this._edgeInsets.getCenter(this.width,this.height)},pn.prototype.isPaddingEqual=function(d){return this._edgeInsets.equals(d)},pn.prototype.interpolatePadding=function(d,A,m){this._unmodified=!1,this._edgeInsets.interpolate(d,A,m),this._constrain(),this._calcMatrices()},pn.prototype.coveringZoomLevel=function(d){var A=(d.roundZoom?Math.round:Math.floor)(this.zoom+this.scaleZoom(this.tileSize/d.tileSize));return Math.max(0,A)},pn.prototype.getVisibleUnwrappedCoordinates=function(d){var A=[new n.UnwrappedTileID(0,d)];if(this._renderWorldCopies)for(var m=this.pointCoordinate(new n.Point(0,0)),w=this.pointCoordinate(new n.Point(this.width,0)),I=this.pointCoordinate(new n.Point(this.width,this.height)),F=this.pointCoordinate(new n.Point(0,this.height)),z=Math.floor(Math.min(m.x,w.x,I.x,F.x)),W=Math.floor(Math.max(m.x,w.x,I.x,F.x)),Q=z-1;Q<=W+1;Q++)Q!==0&&A.push(new n.UnwrappedTileID(Q,d));return A},pn.prototype.coveringTiles=function(d){var A=this.coveringZoomLevel(d),m=A;if(d.minzoom!==void 0&&A<d.minzoom)return[];d.maxzoom!==void 0&&A>d.maxzoom&&(A=d.maxzoom);var w=n.MercatorCoordinate.fromLngLat(this.center),I=Math.pow(2,A),F=[I*w.x,I*w.y,0],z=Op.fromInvProjectionMatrix(this.invProjMatrix,this.worldSize,A),W=d.minzoom||0;this.pitch<=60&&this._edgeInsets.top<.1&&(W=A);var Q=function(Dt){return{aabb:new mc([Dt*I,0,0],[(Dt+1)*I,I,0]),zoom:0,x:0,y:0,wrap:Dt,fullyVisible:!1}},ne=[],pe=[],Ae=A,ye=d.reparseOverscaled?m:A;if(this._renderWorldCopies)for(var Ce=1;Ce<=3;Ce++)ne.push(Q(-Ce)),ne.push(Q(Ce));for(ne.push(Q(0));ne.length>0;){var Se=ne.pop(),Be=Se.x,Te=Se.y,ke=Se.fullyVisible;if(!ke){var qe=Se.aabb.intersects(z);if(qe===0)continue;ke=qe===2}var tt=Se.aabb.distanceX(F),ht=Se.aabb.distanceY(F),ut=Math.max(Math.abs(tt),Math.abs(ht));if(Se.zoom===Ae||ut>3+(1<<Ae-Se.zoom)-2&&Se.zoom>=W)pe.push({tileID:new n.OverscaledTileID(Se.zoom===Ae?ye:Se.zoom,Se.wrap,Se.zoom,Be,Te),distanceSq:n.sqrLen([F[0]-.5-Be,F[1]-.5-Te])});else for(var vt=0;vt<4;vt++){var Et=(Be<<1)+vt%2,Nt=(Te<<1)+(vt>>1);ne.push({aabb:Se.aabb.quadrant(vt),zoom:Se.zoom+1,x:Et,y:Nt,wrap:Se.wrap,fullyVisible:ke})}}return pe.sort(function(Dt,rr){return Dt.distanceSq-rr.distanceSq}).map(function(Dt){return Dt.tileID})},pn.prototype.resize=function(d,A){this.width=d,this.height=A,this.pixelsToGLUnits=[2/d,-2/A],this._constrain(),this._calcMatrices()},wn.unmodified.get=function(){return this._unmodified},pn.prototype.zoomScale=function(d){return Math.pow(2,d)},pn.prototype.scaleZoom=function(d){return Math.log(d)/Math.LN2},pn.prototype.project=function(d){var A=n.clamp(d.lat,-this.maxValidLatitude,this.maxValidLatitude);return new n.Point(n.mercatorXfromLng(d.lng)*this.worldSize,n.mercatorYfromLat(A)*this.worldSize)},pn.prototype.unproject=function(d){return new n.MercatorCoordinate(d.x/this.worldSize,d.y/this.worldSize).toLngLat()},wn.point.get=function(){return this.project(this.center)},pn.prototype.setLocationAtPoint=function(d,A){var m=this.pointCoordinate(A),w=this.pointCoordinate(this.centerPoint),I=this.locationCoordinate(d),F=new n.MercatorCoordinate(I.x-(m.x-w.x),I.y-(m.y-w.y));this.center=this.coordinateLocation(F),this._renderWorldCopies&&(this.center=this.center.wrap())},pn.prototype.locationPoint=function(d){return this.coordinatePoint(this.locationCoordinate(d))},pn.prototype.pointLocation=function(d){return this.coordinateLocation(this.pointCoordinate(d))},pn.prototype.locationCoordinate=function(d){return n.MercatorCoordinate.fromLngLat(d)},pn.prototype.coordinateLocation=function(d){return d.toLngLat()},pn.prototype.pointCoordinate=function(d){var A=[d.x,d.y,0,1],m=[d.x,d.y,1,1];n.transformMat4(A,A,this.pixelMatrixInverse),n.transformMat4(m,m,this.pixelMatrixInverse);var w=A[3],I=m[3],F=A[1]/w,z=m[1]/I,W=A[2]/w,Q=m[2]/I,ne=W===Q?0:(0-W)/(Q-W);return new n.MercatorCoordinate(n.number(A[0]/w,m[0]/I,ne)/this.worldSize,n.number(F,z,ne)/this.worldSize)},pn.prototype.coordinatePoint=function(d){var A=[d.x*this.worldSize,d.y*this.worldSize,0,1];return n.transformMat4(A,A,this.pixelMatrix),new n.Point(A[0]/A[3],A[1]/A[3])},pn.prototype.getBounds=function(){return new n.LngLatBounds().extend(this.pointLocation(new n.Point(0,0))).extend(this.pointLocation(new n.Point(this.width,0))).extend(this.pointLocation(new n.Point(this.width,this.height))).extend(this.pointLocation(new n.Point(0,this.height)))},pn.prototype.getMaxBounds=function(){return this.latRange&&this.latRange.length===2&&this.lngRange&&this.lngRange.length===2?new n.LngLatBounds([this.lngRange[0],this.latRange[0]],[this.lngRange[1],this.latRange[1]]):null},pn.prototype.setMaxBounds=function(d){d?(this.lngRange=[d.getWest(),d.getEast()],this.latRange=[d.getSouth(),d.getNorth()],this._constrain()):(this.lngRange=null,this.latRange=[-this.maxValidLatitude,this.maxValidLatitude])},pn.prototype.calculatePosMatrix=function(d,A){A===void 0&&(A=!1);var m=d.key,w=A?this._alignedPosMatrixCache:this._posMatrixCache;if(w[m])return w[m];var I=d.canonical,F=this.worldSize/this.zoomScale(I.z),z=I.x+Math.pow(2,I.z)*d.wrap,W=n.identity(new Float64Array(16));return n.translate(W,W,[z*F,I.y*F,0]),n.scale(W,W,[F/n.EXTENT,F/n.EXTENT,1]),n.multiply(W,A?this.alignedProjMatrix:this.projMatrix,W),w[m]=new Float32Array(W),w[m]},pn.prototype.customLayerMatrix=function(){return this.mercatorMatrix.slice()},pn.prototype._constrain=function(){if(this.center&&this.width&&this.height&&!this._constraining){this._constraining=!0;var d,A,m,w,I=-90,F=90,z=-180,W=180,Q=this.size,ne=this._unmodified;if(this.latRange){var pe=this.latRange;I=n.mercatorYfromLat(pe[1])*this.worldSize,d=(F=n.mercatorYfromLat(pe[0])*this.worldSize)-I<Q.y?Q.y/(F-I):0}if(this.lngRange){var Ae=this.lngRange;z=n.mercatorXfromLng(Ae[0])*this.worldSize,A=(W=n.mercatorXfromLng(Ae[1])*this.worldSize)-z<Q.x?Q.x/(W-z):0}var ye=this.point,Ce=Math.max(A||0,d||0);if(Ce)return this.center=this.unproject(new n.Point(A?(W+z)/2:ye.x,d?(F+I)/2:ye.y)),this.zoom+=this.scaleZoom(Ce),this._unmodified=ne,void(this._constraining=!1);if(this.latRange){var Se=ye.y,Be=Q.y/2;Se-Be<I&&(w=I+Be),Se+Be>F&&(w=F-Be)}if(this.lngRange){var Te=ye.x,ke=Q.x/2;Te-ke<z&&(m=z+ke),Te+ke>W&&(m=W-ke)}m===void 0&&w===void 0||(this.center=this.unproject(new n.Point(m!==void 0?m:ye.x,w!==void 0?w:ye.y))),this._unmodified=ne,this._constraining=!1}},pn.prototype._calcMatrices=function(){if(this.height){var d=this.centerOffset;this.cameraToCenterDistance=.5/Math.tan(this._fov/2)*this.height;var A=Math.PI/2+this._pitch,m=this._fov*(.5+d.y/this.height),w=Math.sin(m)*this.cameraToCenterDistance/Math.sin(n.clamp(Math.PI-A-m,.01,Math.PI-.01)),I=this.point,F=I.x,z=I.y,W=1.01*(Math.cos(Math.PI/2-this._pitch)*w+this.cameraToCenterDistance),Q=this.height/50,ne=new Float64Array(16);n.perspective(ne,this._fov,this.width/this.height,Q,W),ne[8]=2*-d.x/this.width,ne[9]=2*d.y/this.height,n.scale(ne,ne,[1,-1,1]),n.translate(ne,ne,[0,0,-this.cameraToCenterDistance]),n.rotateX(ne,ne,this._pitch),n.rotateZ(ne,ne,this.angle),n.translate(ne,ne,[-F,-z,0]),this.mercatorMatrix=n.scale([],ne,[this.worldSize,this.worldSize,this.worldSize]),n.scale(ne,ne,[1,1,n.mercatorZfromAltitude(1,this.center.lat)*this.worldSize,1]),this.projMatrix=ne,this.invProjMatrix=n.invert([],this.projMatrix);var pe=this.width%2/2,Ae=this.height%2/2,ye=Math.cos(this.angle),Ce=Math.sin(this.angle),Se=F-Math.round(F)+ye*pe+Ce*Ae,Be=z-Math.round(z)+ye*Ae+Ce*pe,Te=new Float64Array(ne);if(n.translate(Te,Te,[Se>.5?Se-1:Se,Be>.5?Be-1:Be,0]),this.alignedProjMatrix=Te,ne=n.create(),n.scale(ne,ne,[this.width/2,-this.height/2,1]),n.translate(ne,ne,[1,-1,0]),this.labelPlaneMatrix=ne,ne=n.create(),n.scale(ne,ne,[1,-1,1]),n.translate(ne,ne,[-1,-1,0]),n.scale(ne,ne,[2/this.width,2/this.height,1]),this.glCoordMatrix=ne,this.pixelMatrix=n.multiply(new Float64Array(16),this.labelPlaneMatrix,this.projMatrix),!(ne=n.invert(new Float64Array(16),this.pixelMatrix)))throw new Error("failed to invert matrix");this.pixelMatrixInverse=ne,this._posMatrixCache={},this._alignedPosMatrixCache={}}},pn.prototype.maxPitchScaleFactor=function(){if(!this.pixelMatrixInverse)return 1;var d=this.pointCoordinate(new n.Point(0,0)),A=[d.x*this.worldSize,d.y*this.worldSize,0,1];return n.transformMat4(A,A,this.pixelMatrix)[3]/this.cameraToCenterDistance},pn.prototype.getCameraPoint=function(){var d=Math.tan(this._pitch)*(this.cameraToCenterDistance||1);return this.centerPoint.add(new n.Point(0,d))},pn.prototype.getCameraQueryGeometry=function(d){var A=this.getCameraPoint();if(d.length===1)return[d[0],A];for(var m=A.x,w=A.y,I=A.x,F=A.y,z=0,W=d;z<W.length;z+=1){var Q=W[z];m=Math.min(m,Q.x),w=Math.min(w,Q.y),I=Math.max(I,Q.x),F=Math.max(F,Q.y)}return[new n.Point(m,w),new n.Point(I,w),new n.Point(I,F),new n.Point(m,F),new n.Point(m,w)]},Object.defineProperties(pn.prototype,wn);var ns=function(d){var A,m,w,I;this._hashName=d&&encodeURIComponent(d),n.bindAll(["_getCurrentHash","_onHashChange","_updateHash"],this),this._updateHash=(A=this._updateHashUnthrottled.bind(this),m=!1,w=null,I=function(){w=null,m&&(A(),w=setTimeout(I,300),m=!1)},function(){return m=!0,w||I(),w})};ns.prototype.addTo=function(d){return this._map=d,n.window.addEventListener("hashchange",this._onHashChange,!1),this._map.on("moveend",this._updateHash),this},ns.prototype.remove=function(){return n.window.removeEventListener("hashchange",this._onHashChange,!1),this._map.off("moveend",this._updateHash),clearTimeout(this._updateHash()),delete this._map,this},ns.prototype.getHashString=function(d){var A=this._map.getCenter(),m=Math.round(100*this._map.getZoom())/100,w=Math.ceil((m*Math.LN2+Math.log(512/360/.5))/Math.LN10),I=Math.pow(10,w),F=Math.round(A.lng*I)/I,z=Math.round(A.lat*I)/I,W=this._map.getBearing(),Q=this._map.getPitch(),ne="";if(ne+=d?"/"+F+"/"+z+"/"+m:m+"/"+z+"/"+F,(W||Q)&&(ne+="/"+Math.round(10*W)/10),Q&&(ne+="/"+Math.round(Q)),this._hashName){var pe=this._hashName,Ae=!1,ye=n.window.location.hash.slice(1).split("&").map(function(Ce){var Se=Ce.split("=")[0];return Se===pe?(Ae=!0,Se+"="+ne):Ce}).filter(function(Ce){return Ce});return Ae||ye.push(pe+"="+ne),"#"+ye.join("&")}return"#"+ne},ns.prototype._getCurrentHash=function(){var d,A=this,m=n.window.location.hash.replace("#","");return this._hashName?(m.split("&").map(function(w){return w.split("=")}).forEach(function(w){w[0]===A._hashName&&(d=w)}),(d&&d[1]||"").split("/")):m.split("/")},ns.prototype._onHashChange=function(){var d=this._getCurrentHash();if(d.length>=3&&!d.some(function(m){return isNaN(m)})){var A=this._map.dragRotate.isEnabled()&&this._map.touchZoomRotate.isEnabled()?+(d[3]||0):this._map.getBearing();return this._map.jumpTo({center:[+d[2],+d[1]],zoom:+d[0],bearing:A,pitch:+(d[4]||0)}),!0}return!1},ns.prototype._updateHashUnthrottled=function(){var d=n.window.location.href.replace(/(#.+)?$/,this.getHashString());try{n.window.history.replaceState(n.window.history.state,null,d)}catch{}};var cf={linearity:.3,easing:n.bezier(0,0,.3,1)},ml=n.extend({deceleration:2500,maxSpeed:1400},cf),ff=n.extend({deceleration:20,maxSpeed:1400},cf),$d=n.extend({deceleration:1e3,maxSpeed:360},cf),Ip=n.extend({deceleration:1e3,maxSpeed:90},cf),vu=function(d){this._map=d,this.clear()};function hf(d,A){(!d.duration||d.duration<A.duration)&&(d.duration=A.duration,d.easing=A.easing)}function Vu(d,A,m){var w=m.maxSpeed,I=m.linearity,F=m.deceleration,z=n.clamp(d*I/(A/1e3),-w,w),W=Math.abs(z)/(F*I);return{easing:m.easing,duration:1e3*W,amount:z*(W/2)}}vu.prototype.clear=function(){this._inertiaBuffer=[]},vu.prototype.record=function(d){this._drainInertiaBuffer(),this._inertiaBuffer.push({time:n.browser.now(),settings:d})},vu.prototype._drainInertiaBuffer=function(){for(var d=this._inertiaBuffer,A=n.browser.now();d.length>0&&A-d[0].time>160;)d.shift()},vu.prototype._onMoveEnd=function(d){if(this._drainInertiaBuffer(),!(this._inertiaBuffer.length<2)){for(var A={zoom:0,bearing:0,pitch:0,pan:new n.Point(0,0),pinchAround:void 0,around:void 0},m=0,w=this._inertiaBuffer;m<w.length;m+=1){var I=w[m].settings;A.zoom+=I.zoomDelta||0,A.bearing+=I.bearingDelta||0,A.pitch+=I.pitchDelta||0,I.panDelta&&A.pan._add(I.panDelta),I.around&&(A.around=I.around),I.pinchAround&&(A.pinchAround=I.pinchAround)}var F=this._inertiaBuffer[this._inertiaBuffer.length-1].time-this._inertiaBuffer[0].time,z={};if(A.pan.mag()){var W=Vu(A.pan.mag(),F,n.extend({},ml,d||{}));z.offset=A.pan.mult(W.amount/A.pan.mag()),z.center=this._map.transform.center,hf(z,W)}if(A.zoom){var Q=Vu(A.zoom,F,ff);z.zoom=this._map.transform.zoom+Q.amount,hf(z,Q)}if(A.bearing){var ne=Vu(A.bearing,F,$d);z.bearing=this._map.transform.bearing+n.clamp(ne.amount,-179,179),hf(z,ne)}if(A.pitch){var pe=Vu(A.pitch,F,Ip);z.pitch=this._map.transform.pitch+pe.amount,hf(z,pe)}if(z.zoom||z.bearing){var Ae=A.pinchAround===void 0?A.around:A.pinchAround;z.around=Ae?this._map.unproject(Ae):this._map.getCenter()}return this.clear(),n.extend(z,{noMoveStart:!0})}};var oa=function(d){function A(w,I,F,z){z===void 0&&(z={});var W=o.mousePos(I.getCanvasContainer(),F),Q=I.unproject(W);d.call(this,w,n.extend({point:W,lngLat:Q,originalEvent:F},z)),this._defaultPrevented=!1,this.target=I}d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A;var m={defaultPrevented:{configurable:!0}};return A.prototype.preventDefault=function(){this._defaultPrevented=!0},m.defaultPrevented.get=function(){return this._defaultPrevented},Object.defineProperties(A.prototype,m),A}(n.Event),Au=function(d){function A(w,I,F){var z=w==="touchend"?F.changedTouches:F.touches,W=o.touchPos(I.getCanvasContainer(),z),Q=W.map(function(Ae){return I.unproject(Ae)}),ne=W.reduce(function(Ae,ye,Ce,Se){return Ae.add(ye.div(Se.length))},new n.Point(0,0)),pe=I.unproject(ne);d.call(this,w,{points:W,point:ne,lngLats:Q,lngLat:pe,originalEvent:F}),this._defaultPrevented=!1}d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A;var m={defaultPrevented:{configurable:!0}};return A.prototype.preventDefault=function(){this._defaultPrevented=!0},m.defaultPrevented.get=function(){return this._defaultPrevented},Object.defineProperties(A.prototype,m),A}(n.Event),vl=function(d){function A(w,I,F){d.call(this,w,{originalEvent:F}),this._defaultPrevented=!1}d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A;var m={defaultPrevented:{configurable:!0}};return A.prototype.preventDefault=function(){this._defaultPrevented=!0},m.defaultPrevented.get=function(){return this._defaultPrevented},Object.defineProperties(A.prototype,m),A}(n.Event),va=function(d,A){this._map=d,this._clickTolerance=A.clickTolerance};va.prototype.reset=function(){delete this._mousedownPos},va.prototype.wheel=function(d){return this._firePreventable(new vl(d.type,this._map,d))},va.prototype.mousedown=function(d,A){return this._mousedownPos=A,this._firePreventable(new oa(d.type,this._map,d))},va.prototype.mouseup=function(d){this._map.fire(new oa(d.type,this._map,d))},va.prototype.click=function(d,A){this._mousedownPos&&this._mousedownPos.dist(A)>=this._clickTolerance||this._map.fire(new oa(d.type,this._map,d))},va.prototype.dblclick=function(d){return this._firePreventable(new oa(d.type,this._map,d))},va.prototype.mouseover=function(d){this._map.fire(new oa(d.type,this._map,d))},va.prototype.mouseout=function(d){this._map.fire(new oa(d.type,this._map,d))},va.prototype.touchstart=function(d){return this._firePreventable(new Au(d.type,this._map,d))},va.prototype.touchmove=function(d){this._map.fire(new Au(d.type,this._map,d))},va.prototype.touchend=function(d){this._map.fire(new Au(d.type,this._map,d))},va.prototype.touchcancel=function(d){this._map.fire(new Au(d.type,this._map,d))},va.prototype._firePreventable=function(d){if(this._map.fire(d),d.defaultPrevented)return{}},va.prototype.isEnabled=function(){return!0},va.prototype.isActive=function(){return!1},va.prototype.enable=function(){},va.prototype.disable=function(){};var ur=function(d){this._map=d};ur.prototype.reset=function(){this._delayContextMenu=!1,delete this._contextMenuEvent},ur.prototype.mousemove=function(d){this._map.fire(new oa(d.type,this._map,d))},ur.prototype.mousedown=function(){this._delayContextMenu=!0},ur.prototype.mouseup=function(){this._delayContextMenu=!1,this._contextMenuEvent&&(this._map.fire(new oa("contextmenu",this._map,this._contextMenuEvent)),delete this._contextMenuEvent)},ur.prototype.contextmenu=function(d){this._delayContextMenu?this._contextMenuEvent=d:this._map.fire(new oa(d.type,this._map,d)),this._map.listens("contextmenu")&&d.preventDefault()},ur.prototype.isEnabled=function(){return!0},ur.prototype.isActive=function(){return!1},ur.prototype.enable=function(){},ur.prototype.disable=function(){};var Zo=function(d,A){this._map=d,this._el=d.getCanvasContainer(),this._container=d.getContainer(),this._clickTolerance=A.clickTolerance||1};function Rp(d,A){for(var m={},w=0;w<d.length;w++)m[d[w].identifier]=A[w];return m}Zo.prototype.isEnabled=function(){return!!this._enabled},Zo.prototype.isActive=function(){return!!this._active},Zo.prototype.enable=function(){this.isEnabled()||(this._enabled=!0)},Zo.prototype.disable=function(){this.isEnabled()&&(this._enabled=!1)},Zo.prototype.mousedown=function(d,A){this.isEnabled()&&d.shiftKey&&d.button===0&&(o.disableDrag(),this._startPos=this._lastPos=A,this._active=!0)},Zo.prototype.mousemoveWindow=function(d,A){if(this._active){var m=A;if(!(this._lastPos.equals(m)||!this._box&&m.dist(this._startPos)<this._clickTolerance)){var w=this._startPos;this._lastPos=m,this._box||(this._box=o.create("div","mapboxgl-boxzoom",this._container),this._container.classList.add("mapboxgl-crosshair"),this._fireEvent("boxzoomstart",d));var I=Math.min(w.x,m.x),F=Math.max(w.x,m.x),z=Math.min(w.y,m.y),W=Math.max(w.y,m.y);o.setTransform(this._box,"translate("+I+"px,"+z+"px)"),this._box.style.width=F-I+"px",this._box.style.height=W-z+"px"}}},Zo.prototype.mouseupWindow=function(d,A){var m=this;if(this._active&&d.button===0){var w=this._startPos,I=A;if(this.reset(),o.suppressClick(),w.x!==I.x||w.y!==I.y)return this._map.fire(new n.Event("boxzoomend",{originalEvent:d})),{cameraAnimation:function(F){return F.fitScreenCoordinates(w,I,m._map.getBearing(),{linear:!0})}};this._fireEvent("boxzoomcancel",d)}},Zo.prototype.keydown=function(d){this._active&&d.keyCode===27&&(this.reset(),this._fireEvent("boxzoomcancel",d))},Zo.prototype.blur=function(){this.reset()},Zo.prototype.reset=function(){this._active=!1,this._container.classList.remove("mapboxgl-crosshair"),this._box&&(o.remove(this._box),this._box=null),o.enableDrag(),delete this._startPos,delete this._lastPos},Zo.prototype._fireEvent=function(d,A){return this._map.fire(new n.Event(d,{originalEvent:A}))};var pf=function(d){this.reset(),this.numTouches=d.numTouches};pf.prototype.reset=function(){delete this.centroid,delete this.startTime,delete this.touches,this.aborted=!1},pf.prototype.touchstart=function(d,A,m){(this.centroid||m.length>this.numTouches)&&(this.aborted=!0),this.aborted||(this.startTime===void 0&&(this.startTime=d.timeStamp),m.length===this.numTouches&&(this.centroid=function(w){for(var I=new n.Point(0,0),F=0,z=w;F<z.length;F+=1)I._add(z[F]);return I.div(w.length)}(A),this.touches=Rp(m,A)))},pf.prototype.touchmove=function(d,A,m){if(!this.aborted&&this.centroid){var w=Rp(m,A);for(var I in this.touches){var F=w[I];(!F||F.dist(this.touches[I])>30)&&(this.aborted=!0)}}},pf.prototype.touchend=function(d,A,m){if((!this.centroid||d.timeStamp-this.startTime>500)&&(this.aborted=!0),m.length===0){var w=!this.aborted&&this.centroid;if(this.reset(),w)return w}};var eu=function(d){this.singleTap=new pf(d),this.numTaps=d.numTaps,this.reset()};eu.prototype.reset=function(){this.lastTime=1/0,delete this.lastTap,this.count=0,this.singleTap.reset()},eu.prototype.touchstart=function(d,A,m){this.singleTap.touchstart(d,A,m)},eu.prototype.touchmove=function(d,A,m){this.singleTap.touchmove(d,A,m)},eu.prototype.touchend=function(d,A,m){var w=this.singleTap.touchend(d,A,m);if(w){var I=d.timeStamp-this.lastTime<500,F=!this.lastTap||this.lastTap.dist(w)<30;if(I&&F||this.reset(),this.count++,this.lastTime=d.timeStamp,this.lastTap=w,this.count===this.numTaps)return this.reset(),w}};var bs=function(){this._zoomIn=new eu({numTouches:1,numTaps:2}),this._zoomOut=new eu({numTouches:2,numTaps:1}),this.reset()};bs.prototype.reset=function(){this._active=!1,this._zoomIn.reset(),this._zoomOut.reset()},bs.prototype.touchstart=function(d,A,m){this._zoomIn.touchstart(d,A,m),this._zoomOut.touchstart(d,A,m)},bs.prototype.touchmove=function(d,A,m){this._zoomIn.touchmove(d,A,m),this._zoomOut.touchmove(d,A,m)},bs.prototype.touchend=function(d,A,m){var w=this,I=this._zoomIn.touchend(d,A,m),F=this._zoomOut.touchend(d,A,m);return I?(this._active=!0,d.preventDefault(),setTimeout(function(){return w.reset()},0),{cameraAnimation:function(z){return z.easeTo({duration:300,zoom:z.getZoom()+1,around:z.unproject(I)},{originalEvent:d})}}):F?(this._active=!0,d.preventDefault(),setTimeout(function(){return w.reset()},0),{cameraAnimation:function(z){return z.easeTo({duration:300,zoom:z.getZoom()-1,around:z.unproject(F)},{originalEvent:d})}}):void 0},bs.prototype.touchcancel=function(){this.reset()},bs.prototype.enable=function(){this._enabled=!0},bs.prototype.disable=function(){this._enabled=!1,this.reset()},bs.prototype.isEnabled=function(){return this._enabled},bs.prototype.isActive=function(){return this._active};var em={0:1,2:2},qt=function(d){this.reset(),this._clickTolerance=d.clickTolerance||1};qt.prototype.blur=function(){this.reset()},qt.prototype.reset=function(){this._active=!1,this._moved=!1,delete this._lastPoint,delete this._eventButton},qt.prototype._correctButton=function(d,A){return!1},qt.prototype._move=function(d,A){return{}},qt.prototype.mousedown=function(d,A){if(!this._lastPoint){var m=o.mouseButton(d);this._correctButton(d,m)&&(this._lastPoint=A,this._eventButton=m)}},qt.prototype.mousemoveWindow=function(d,A){var m=this._lastPoint;if(m){if(d.preventDefault(),function(w,I){var F=em[I];return w.buttons===void 0||(w.buttons&F)!==F}(d,this._eventButton))this.reset();else if(this._moved||!(A.dist(m)<this._clickTolerance))return this._moved=!0,this._lastPoint=A,this._move(m,A)}},qt.prototype.mouseupWindow=function(d){this._lastPoint&&o.mouseButton(d)===this._eventButton&&(this._moved&&o.suppressClick(),this.reset())},qt.prototype.enable=function(){this._enabled=!0},qt.prototype.disable=function(){this._enabled=!1,this.reset()},qt.prototype.isEnabled=function(){return this._enabled},qt.prototype.isActive=function(){return this._active};var vc=function(d){function A(){d.apply(this,arguments)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype.mousedown=function(m,w){d.prototype.mousedown.call(this,m,w),this._lastPoint&&(this._active=!0)},A.prototype._correctButton=function(m,w){return w===0&&!m.ctrlKey},A.prototype._move=function(m,w){return{around:w,panDelta:w.sub(m)}},A}(qt),Lp=function(d){function A(){d.apply(this,arguments)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype._correctButton=function(m,w){return w===0&&m.ctrlKey||w===2},A.prototype._move=function(m,w){var I=.8*(w.x-m.x);if(I)return this._active=!0,{bearingDelta:I}},A.prototype.contextmenu=function(m){m.preventDefault()},A}(qt),kp=function(d){function A(){d.apply(this,arguments)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype._correctButton=function(m,w){return w===0&&m.ctrlKey||w===2},A.prototype._move=function(m,w){var I=-.5*(w.y-m.y);if(I)return this._active=!0,{pitchDelta:I}},A.prototype.contextmenu=function(m){m.preventDefault()},A}(qt),Us=function(d){this._minTouches=1,this._clickTolerance=d.clickTolerance||1,this.reset()};Us.prototype.reset=function(){this._active=!1,this._touches={},this._sum=new n.Point(0,0)},Us.prototype.touchstart=function(d,A,m){return this._calculateTransform(d,A,m)},Us.prototype.touchmove=function(d,A,m){if(this._active&&!(m.length<this._minTouches))return d.preventDefault(),this._calculateTransform(d,A,m)},Us.prototype.touchend=function(d,A,m){this._calculateTransform(d,A,m),this._active&&m.length<this._minTouches&&this.reset()},Us.prototype.touchcancel=function(){this.reset()},Us.prototype._calculateTransform=function(d,A,m){m.length>0&&(this._active=!0);var w=Rp(m,A),I=new n.Point(0,0),F=new n.Point(0,0),z=0;for(var W in w){var Q=w[W],ne=this._touches[W];ne&&(I._add(Q),F._add(Q.sub(ne)),z++,w[W]=Q)}if(this._touches=w,!(z<this._minTouches)&&F.mag()){var pe=F.div(z);if(this._sum._add(pe),!(this._sum.mag()<this._clickTolerance))return{around:I.div(z),panDelta:pe}}},Us.prototype.enable=function(){this._enabled=!0},Us.prototype.disable=function(){this._enabled=!1,this.reset()},Us.prototype.isEnabled=function(){return this._enabled},Us.prototype.isActive=function(){return this._active};var no=function(){this.reset()};function Bp(d,A,m){for(var w=0;w<d.length;w++)if(d[w].identifier===m)return A[w]}function vh(d,A){return Math.log(d/A)/Math.LN2}no.prototype.reset=function(){this._active=!1,delete this._firstTwoTouches},no.prototype._start=function(d){},no.prototype._move=function(d,A,m){return{}},no.prototype.touchstart=function(d,A,m){this._firstTwoTouches||m.length<2||(this._firstTwoTouches=[m[0].identifier,m[1].identifier],this._start([A[0],A[1]]))},no.prototype.touchmove=function(d,A,m){if(this._firstTwoTouches){d.preventDefault();var w=this._firstTwoTouches,I=w[1],F=Bp(m,A,w[0]),z=Bp(m,A,I);if(F&&z){var W=this._aroundCenter?null:F.add(z).div(2);return this._move([F,z],W,d)}}},no.prototype.touchend=function(d,A,m){if(this._firstTwoTouches){var w=this._firstTwoTouches,I=w[1],F=Bp(m,A,w[0]),z=Bp(m,A,I);F&&z||(this._active&&o.suppressClick(),this.reset())}},no.prototype.touchcancel=function(){this.reset()},no.prototype.enable=function(d){this._enabled=!0,this._aroundCenter=!!d&&d.around==="center"},no.prototype.disable=function(){this._enabled=!1,this.reset()},no.prototype.isEnabled=function(){return this._enabled},no.prototype.isActive=function(){return this._active};var is=function(d){function A(){d.apply(this,arguments)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype.reset=function(){d.prototype.reset.call(this),delete this._distance,delete this._startDistance},A.prototype._start=function(m){this._startDistance=this._distance=m[0].dist(m[1])},A.prototype._move=function(m,w){var I=this._distance;if(this._distance=m[0].dist(m[1]),this._active||!(Math.abs(vh(this._distance,this._startDistance))<.1))return this._active=!0,{zoomDelta:vh(this._distance,I),pinchAround:w}},A}(no);function js(d,A){return 180*d.angleWith(A)/Math.PI}var Ac=function(d){function A(){d.apply(this,arguments)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype.reset=function(){d.prototype.reset.call(this),delete this._minDiameter,delete this._startVector,delete this._vector},A.prototype._start=function(m){this._startVector=this._vector=m[0].sub(m[1]),this._minDiameter=m[0].dist(m[1])},A.prototype._move=function(m,w){var I=this._vector;if(this._vector=m[0].sub(m[1]),this._active||!this._isBelowThreshold(this._vector))return this._active=!0,{bearingDelta:js(this._vector,I),pinchAround:w}},A.prototype._isBelowThreshold=function(m){this._minDiameter=Math.min(this._minDiameter,m.mag());var w=25/(Math.PI*this._minDiameter)*360,I=js(m,this._startVector);return Math.abs(I)<w},A}(no);function Ah(d){return Math.abs(d.y)>Math.abs(d.x)}var gc=function(d){function A(){d.apply(this,arguments)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype.reset=function(){d.prototype.reset.call(this),this._valid=void 0,delete this._firstMove,delete this._lastPoints},A.prototype._start=function(m){this._lastPoints=m,Ah(m[0].sub(m[1]))&&(this._valid=!1)},A.prototype._move=function(m,w,I){var F=m[0].sub(this._lastPoints[0]),z=m[1].sub(this._lastPoints[1]);if(this._valid=this.gestureBeginsVertically(F,z,I.timeStamp),this._valid)return this._lastPoints=m,this._active=!0,{pitchDelta:(F.y+z.y)/2*-.5}},A.prototype.gestureBeginsVertically=function(m,w,I){if(this._valid!==void 0)return this._valid;var F=m.mag()>=2,z=w.mag()>=2;if(F||z){if(!F||!z)return this._firstMove===void 0&&(this._firstMove=I),I-this._firstMove<100&&void 0;var W=m.y>0==w.y>0;return Ah(m)&&Ah(w)&&W}},A}(no),tm={panStep:100,bearingStep:15,pitchStep:10},gu=function(){var d=tm;this._panStep=d.panStep,this._bearingStep=d.bearingStep,this._pitchStep=d.pitchStep,this._rotationDisabled=!1};function Gs(d){return d*(2-d)}gu.prototype.blur=function(){this.reset()},gu.prototype.reset=function(){this._active=!1},gu.prototype.keydown=function(d){var A=this;if(!(d.altKey||d.ctrlKey||d.metaKey)){var m=0,w=0,I=0,F=0,z=0;switch(d.keyCode){case 61:case 107:case 171:case 187:m=1;break;case 189:case 109:case 173:m=-1;break;case 37:d.shiftKey?w=-1:(d.preventDefault(),F=-1);break;case 39:d.shiftKey?w=1:(d.preventDefault(),F=1);break;case 38:d.shiftKey?I=1:(d.preventDefault(),z=-1);break;case 40:d.shiftKey?I=-1:(d.preventDefault(),z=1);break;default:return}return this._rotationDisabled&&(w=0,I=0),{cameraAnimation:function(W){var Q=W.getZoom();W.easeTo({duration:300,easeId:"keyboardHandler",easing:Gs,zoom:m?Math.round(Q)+m*(d.shiftKey?2:1):Q,bearing:W.getBearing()+w*A._bearingStep,pitch:W.getPitch()+I*A._pitchStep,offset:[-F*A._panStep,-z*A._panStep],center:W.getCenter()},{originalEvent:d})}}}},gu.prototype.enable=function(){this._enabled=!0},gu.prototype.disable=function(){this._enabled=!1,this.reset()},gu.prototype.isEnabled=function(){return this._enabled},gu.prototype.isActive=function(){return this._active},gu.prototype.disableRotation=function(){this._rotationDisabled=!0},gu.prototype.enableRotation=function(){this._rotationDisabled=!1};var xn=function(d,A){this._map=d,this._el=d.getCanvasContainer(),this._handler=A,this._delta=0,this._defaultZoomRate=.01,this._wheelZoomRate=1/450,n.bindAll(["_onTimeout"],this)};xn.prototype.setZoomRate=function(d){this._defaultZoomRate=d},xn.prototype.setWheelZoomRate=function(d){this._wheelZoomRate=d},xn.prototype.isEnabled=function(){return!!this._enabled},xn.prototype.isActive=function(){return!!this._active||this._finishTimeout!==void 0},xn.prototype.isZooming=function(){return!!this._zooming},xn.prototype.enable=function(d){this.isEnabled()||(this._enabled=!0,this._aroundCenter=d&&d.around==="center")},xn.prototype.disable=function(){this.isEnabled()&&(this._enabled=!1)},xn.prototype.wheel=function(d){if(this.isEnabled()){var A=d.deltaMode===n.window.WheelEvent.DOM_DELTA_LINE?40*d.deltaY:d.deltaY,m=n.browser.now(),w=m-(this._lastWheelEventTime||0);this._lastWheelEventTime=m,A!==0&&A%4.000244140625==0?this._type="wheel":A!==0&&Math.abs(A)<4?this._type="trackpad":w>400?(this._type=null,this._lastValue=A,this._timeout=setTimeout(this._onTimeout,40,d)):this._type||(this._type=Math.abs(w*A)<200?"trackpad":"wheel",this._timeout&&(clearTimeout(this._timeout),this._timeout=null,A+=this._lastValue)),d.shiftKey&&A&&(A/=4),this._type&&(this._lastWheelEvent=d,this._delta-=A,this._active||this._start(d)),d.preventDefault()}},xn.prototype._onTimeout=function(d){this._type="wheel",this._delta-=this._lastValue,this._active||this._start(d)},xn.prototype._start=function(d){if(this._delta){this._frameId&&(this._frameId=null),this._active=!0,this.isZooming()||(this._zooming=!0),this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout);var A=o.mousePos(this._el,d);this._around=n.LngLat.convert(this._aroundCenter?this._map.getCenter():this._map.unproject(A)),this._aroundPoint=this._map.transform.locationPoint(this._around),this._frameId||(this._frameId=!0,this._handler._triggerRenderFrame())}},xn.prototype.renderFrame=function(){var d=this;if(this._frameId&&(this._frameId=null,this.isActive())){var A=this._map.transform;if(this._delta!==0){var m=this._type==="wheel"&&Math.abs(this._delta)>4.000244140625?this._wheelZoomRate:this._defaultZoomRate,w=2/(1+Math.exp(-Math.abs(this._delta*m)));this._delta<0&&w!==0&&(w=1/w);var I=typeof this._targetZoom=="number"?A.zoomScale(this._targetZoom):A.scale;this._targetZoom=Math.min(A.maxZoom,Math.max(A.minZoom,A.scaleZoom(I*w))),this._type==="wheel"&&(this._startZoom=A.zoom,this._easing=this._smoothOutEasing(200)),this._delta=0}var F,z=typeof this._targetZoom=="number"?this._targetZoom:A.zoom,W=this._startZoom,Q=this._easing,ne=!1;if(this._type==="wheel"&&W&&Q){var pe=Math.min((n.browser.now()-this._lastWheelEventTime)/200,1),Ae=Q(pe);F=n.number(W,z,Ae),pe<1?this._frameId||(this._frameId=!0):ne=!0}else F=z,ne=!0;return this._active=!0,ne&&(this._active=!1,this._finishTimeout=setTimeout(function(){d._zooming=!1,d._handler._triggerRenderFrame(),delete d._targetZoom,delete d._finishTimeout},200)),{noInertia:!0,needsRenderFrame:!ne,zoomDelta:F-A.zoom,around:this._aroundPoint,originalEvent:this._lastWheelEvent}}},xn.prototype._smoothOutEasing=function(d){var A=n.ease;if(this._prevEase){var m=this._prevEase,w=(n.browser.now()-m.start)/m.duration,I=m.easing(w+.01)-m.easing(w),F=.27/Math.sqrt(I*I+1e-4)*.01,z=Math.sqrt(.0729-F*F);A=n.bezier(F,z,.25,1)}return this._prevEase={start:n.browser.now(),duration:d,easing:A},A},xn.prototype.blur=function(){this.reset()},xn.prototype.reset=function(){this._active=!1};var Hu=function(d,A){this._clickZoom=d,this._tapZoom=A};Hu.prototype.enable=function(){this._clickZoom.enable(),this._tapZoom.enable()},Hu.prototype.disable=function(){this._clickZoom.disable(),this._tapZoom.disable()},Hu.prototype.isEnabled=function(){return this._clickZoom.isEnabled()&&this._tapZoom.isEnabled()},Hu.prototype.isActive=function(){return this._clickZoom.isActive()||this._tapZoom.isActive()};var tu=function(){this.reset()};tu.prototype.reset=function(){this._active=!1},tu.prototype.blur=function(){this.reset()},tu.prototype.dblclick=function(d,A){return d.preventDefault(),{cameraAnimation:function(m){m.easeTo({duration:300,zoom:m.getZoom()+(d.shiftKey?-1:1),around:m.unproject(A)},{originalEvent:d})}}},tu.prototype.enable=function(){this._enabled=!0},tu.prototype.disable=function(){this._enabled=!1,this.reset()},tu.prototype.isEnabled=function(){return this._enabled},tu.prototype.isActive=function(){return this._active};var _o=function(){this._tap=new eu({numTouches:1,numTaps:1}),this.reset()};_o.prototype.reset=function(){this._active=!1,delete this._swipePoint,delete this._swipeTouch,delete this._tapTime,this._tap.reset()},_o.prototype.touchstart=function(d,A,m){this._swipePoint||(this._tapTime&&d.timeStamp-this._tapTime>500&&this.reset(),this._tapTime?m.length>0&&(this._swipePoint=A[0],this._swipeTouch=m[0].identifier):this._tap.touchstart(d,A,m))},_o.prototype.touchmove=function(d,A,m){if(this._tapTime){if(this._swipePoint){if(m[0].identifier!==this._swipeTouch)return;var w=A[0],I=w.y-this._swipePoint.y;return this._swipePoint=w,d.preventDefault(),this._active=!0,{zoomDelta:I/128}}}else this._tap.touchmove(d,A,m)},_o.prototype.touchend=function(d,A,m){this._tapTime?this._swipePoint&&m.length===0&&this.reset():this._tap.touchend(d,A,m)&&(this._tapTime=d.timeStamp)},_o.prototype.touchcancel=function(){this.reset()},_o.prototype.enable=function(){this._enabled=!0},_o.prototype.disable=function(){this._enabled=!1,this.reset()},_o.prototype.isEnabled=function(){return this._enabled},_o.prototype.isActive=function(){return this._active};var yc=function(d,A,m){this._el=d,this._mousePan=A,this._touchPan=m};yc.prototype.enable=function(d){this._inertiaOptions=d||{},this._mousePan.enable(),this._touchPan.enable(),this._el.classList.add("mapboxgl-touch-drag-pan")},yc.prototype.disable=function(){this._mousePan.disable(),this._touchPan.disable(),this._el.classList.remove("mapboxgl-touch-drag-pan")},yc.prototype.isEnabled=function(){return this._mousePan.isEnabled()&&this._touchPan.isEnabled()},yc.prototype.isActive=function(){return this._mousePan.isActive()||this._touchPan.isActive()};var Vs=function(d,A,m){this._pitchWithRotate=d.pitchWithRotate,this._mouseRotate=A,this._mousePitch=m};Vs.prototype.enable=function(){this._mouseRotate.enable(),this._pitchWithRotate&&this._mousePitch.enable()},Vs.prototype.disable=function(){this._mouseRotate.disable(),this._mousePitch.disable()},Vs.prototype.isEnabled=function(){return this._mouseRotate.isEnabled()&&(!this._pitchWithRotate||this._mousePitch.isEnabled())},Vs.prototype.isActive=function(){return this._mouseRotate.isActive()||this._mousePitch.isActive()};var yu=function(d,A,m,w){this._el=d,this._touchZoom=A,this._touchRotate=m,this._tapDragZoom=w,this._rotationDisabled=!1,this._enabled=!0};yu.prototype.enable=function(d){this._touchZoom.enable(d),this._rotationDisabled||this._touchRotate.enable(d),this._tapDragZoom.enable(),this._el.classList.add("mapboxgl-touch-zoom-rotate")},yu.prototype.disable=function(){this._touchZoom.disable(),this._touchRotate.disable(),this._tapDragZoom.disable(),this._el.classList.remove("mapboxgl-touch-zoom-rotate")},yu.prototype.isEnabled=function(){return this._touchZoom.isEnabled()&&(this._rotationDisabled||this._touchRotate.isEnabled())&&this._tapDragZoom.isEnabled()},yu.prototype.isActive=function(){return this._touchZoom.isActive()||this._touchRotate.isActive()||this._tapDragZoom.isActive()},yu.prototype.disableRotation=function(){this._rotationDisabled=!0,this._touchRotate.disable()},yu.prototype.enableRotation=function(){this._rotationDisabled=!1,this._touchZoom.isEnabled()&&this._touchRotate.enable()};var Yo=function(d){return d.zoom||d.drag||d.pitch||d.rotate},gh=function(d){function A(){d.apply(this,arguments)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A}(n.Event);function Ir(d){return d.panDelta&&d.panDelta.mag()||d.zoomDelta||d.bearingDelta||d.pitchDelta}var Ar=function(d,A){this._map=d,this._el=this._map.getCanvasContainer(),this._handlers=[],this._handlersById={},this._changes=[],this._inertia=new vu(d),this._bearingSnap=A.bearingSnap,this._previousActiveHandlers={},this._eventsInProgress={},this._addDefaultHandlers(A),n.bindAll(["handleEvent","handleWindowEvent"],this);var m=this._el;this._listeners=[[m,"touchstart",{passive:!0}],[m,"touchmove",{passive:!1}],[m,"touchend",void 0],[m,"touchcancel",void 0],[m,"mousedown",void 0],[m,"mousemove",void 0],[m,"mouseup",void 0],[n.window.document,"mousemove",{capture:!0}],[n.window.document,"mouseup",void 0],[m,"mouseover",void 0],[m,"mouseout",void 0],[m,"dblclick",void 0],[m,"click",void 0],[m,"keydown",{capture:!1}],[m,"keyup",void 0],[m,"wheel",{passive:!1}],[m,"contextmenu",void 0],[n.window,"blur",void 0]];for(var w=0,I=this._listeners;w<I.length;w+=1){var F=I[w],z=F[0];o.addEventListener(z,F[1],z===n.window.document?this.handleWindowEvent:this.handleEvent,F[2])}};Ar.prototype.destroy=function(){for(var d=0,A=this._listeners;d<A.length;d+=1){var m=A[d],w=m[0];o.removeEventListener(w,m[1],w===n.window.document?this.handleWindowEvent:this.handleEvent,m[2])}},Ar.prototype._addDefaultHandlers=function(d){var A=this._map,m=A.getCanvasContainer();this._add("mapEvent",new va(A,d));var w=A.boxZoom=new Zo(A,d);this._add("boxZoom",w);var I=new bs,F=new tu;A.doubleClickZoom=new Hu(F,I),this._add("tapZoom",I),this._add("clickZoom",F);var z=new _o;this._add("tapDragZoom",z);var W=A.touchPitch=new gc;this._add("touchPitch",W);var Q=new Lp(d),ne=new kp(d);A.dragRotate=new Vs(d,Q,ne),this._add("mouseRotate",Q,["mousePitch"]),this._add("mousePitch",ne,["mouseRotate"]);var pe=new vc(d),Ae=new Us(d);A.dragPan=new yc(m,pe,Ae),this._add("mousePan",pe),this._add("touchPan",Ae,["touchZoom","touchRotate"]);var ye=new Ac,Ce=new is;A.touchZoomRotate=new yu(m,Ce,ye,z),this._add("touchRotate",ye,["touchPan","touchZoom"]),this._add("touchZoom",Ce,["touchPan","touchRotate"]);var Se=A.scrollZoom=new xn(A,this);this._add("scrollZoom",Se,["mousePan"]);var Be=A.keyboard=new gu;this._add("keyboard",Be),this._add("blockableMapEvent",new ur(A));for(var Te=0,ke=["boxZoom","doubleClickZoom","tapDragZoom","touchPitch","dragRotate","dragPan","touchZoomRotate","scrollZoom","keyboard"];Te<ke.length;Te+=1){var qe=ke[Te];d.interactive&&d[qe]&&A[qe].enable(d[qe])}},Ar.prototype._add=function(d,A,m){this._handlers.push({handlerName:d,handler:A,allowed:m}),this._handlersById[d]=A},Ar.prototype.stop=function(d){if(!this._updatingCamera){for(var A=0,m=this._handlers;A<m.length;A+=1)m[A].handler.reset();this._inertia.clear(),this._fireEvents({},{},d),this._changes=[]}},Ar.prototype.isActive=function(){for(var d=0,A=this._handlers;d<A.length;d+=1)if(A[d].handler.isActive())return!0;return!1},Ar.prototype.isZooming=function(){return!!this._eventsInProgress.zoom||this._map.scrollZoom.isZooming()},Ar.prototype.isRotating=function(){return!!this._eventsInProgress.rotate},Ar.prototype.isMoving=function(){return Boolean(Yo(this._eventsInProgress))||this.isZooming()},Ar.prototype._blockedByActive=function(d,A,m){for(var w in d)if(w!==m&&(!A||A.indexOf(w)<0))return!0;return!1},Ar.prototype.handleWindowEvent=function(d){this.handleEvent(d,d.type+"Window")},Ar.prototype._getMapTouches=function(d){for(var A=[],m=0,w=d;m<w.length;m+=1){var I=w[m];this._el.contains(I.target)&&A.push(I)}return A},Ar.prototype.handleEvent=function(d,A){this._updatingCamera=!0;for(var m=d.type==="renderFrame"?void 0:d,w={needsRenderFrame:!1},I={},F={},z=d.touches?this._getMapTouches(d.touches):void 0,W=z?o.touchPos(this._el,z):o.mousePos(this._el,d),Q=0,ne=this._handlers;Q<ne.length;Q+=1){var pe=ne[Q],Ae=pe.handlerName,ye=pe.handler,Ce=pe.allowed;if(ye.isEnabled()){var Se=void 0;this._blockedByActive(F,Ce,Ae)?ye.reset():ye[A||d.type]&&(Se=ye[A||d.type](d,W,z),this.mergeHandlerResult(w,I,Se,Ae,m),Se&&Se.needsRenderFrame&&this._triggerRenderFrame()),(Se||ye.isActive())&&(F[Ae]=ye)}}var Be={};for(var Te in this._previousActiveHandlers)F[Te]||(Be[Te]=m);this._previousActiveHandlers=F,(Object.keys(Be).length||Ir(w))&&(this._changes.push([w,I,Be]),this._triggerRenderFrame()),(Object.keys(F).length||Ir(w))&&this._map._stop(!0),this._updatingCamera=!1;var ke=w.cameraAnimation;ke&&(this._inertia.clear(),this._fireEvents({},{},!0),this._changes=[],ke(this._map))},Ar.prototype.mergeHandlerResult=function(d,A,m,w,I){if(m){n.extend(d,m);var F={handlerName:w,originalEvent:m.originalEvent||I};m.zoomDelta!==void 0&&(A.zoom=F),m.panDelta!==void 0&&(A.drag=F),m.pitchDelta!==void 0&&(A.pitch=F),m.bearingDelta!==void 0&&(A.rotate=F)}},Ar.prototype._applyChanges=function(){for(var d={},A={},m={},w=0,I=this._changes;w<I.length;w+=1){var F=I[w],z=F[0],W=F[1],Q=F[2];z.panDelta&&(d.panDelta=(d.panDelta||new n.Point(0,0))._add(z.panDelta)),z.zoomDelta&&(d.zoomDelta=(d.zoomDelta||0)+z.zoomDelta),z.bearingDelta&&(d.bearingDelta=(d.bearingDelta||0)+z.bearingDelta),z.pitchDelta&&(d.pitchDelta=(d.pitchDelta||0)+z.pitchDelta),z.around!==void 0&&(d.around=z.around),z.pinchAround!==void 0&&(d.pinchAround=z.pinchAround),z.noInertia&&(d.noInertia=z.noInertia),n.extend(A,W),n.extend(m,Q)}this._updateMapTransform(d,A,m),this._changes=[]},Ar.prototype._updateMapTransform=function(d,A,m){var w=this._map,I=w.transform;if(!Ir(d))return this._fireEvents(A,m,!0);var F=d.panDelta,z=d.zoomDelta,W=d.bearingDelta,Q=d.pitchDelta,ne=d.around,pe=d.pinchAround;pe!==void 0&&(ne=pe),w._stop(!0),ne=ne||w.transform.centerPoint;var Ae=I.pointLocation(F?ne.sub(F):ne);W&&(I.bearing+=W),Q&&(I.pitch+=Q),z&&(I.zoom+=z),I.setLocationAtPoint(Ae,ne),this._map._update(),d.noInertia||this._inertia.record(d),this._fireEvents(A,m,!0)},Ar.prototype._fireEvents=function(d,A,m){var w=this,I=Yo(this._eventsInProgress),F=Yo(d),z={};for(var W in d)this._eventsInProgress[W]||(z[W+"start"]=d[W].originalEvent),this._eventsInProgress[W]=d[W];for(var Q in!I&&F&&this._fireEvent("movestart",F.originalEvent),z)this._fireEvent(Q,z[Q]);for(var ne in F&&this._fireEvent("move",F.originalEvent),d)this._fireEvent(ne,d[ne].originalEvent);var pe,Ae={};for(var ye in this._eventsInProgress){var Ce=this._eventsInProgress[ye],Se=Ce.handlerName,Be=Ce.originalEvent;this._handlersById[Se].isActive()||(delete this._eventsInProgress[ye],Ae[ye+"end"]=pe=A[Se]||Be)}for(var Te in Ae)this._fireEvent(Te,Ae[Te]);var ke=Yo(this._eventsInProgress);if(m&&(I||F)&&!ke){this._updatingCamera=!0;var qe=this._inertia._onMoveEnd(this._map.dragPan._inertiaOptions),tt=function(ht){return ht!==0&&-w._bearingSnap<ht&&ht<w._bearingSnap};qe?(tt(qe.bearing||this._map.getBearing())&&(qe.bearing=0),this._map.easeTo(qe,{originalEvent:pe})):(this._map.fire(new n.Event("moveend",{originalEvent:pe})),tt(this._map.getBearing())&&this._map.resetNorth()),this._updatingCamera=!1}},Ar.prototype._fireEvent=function(d,A){this._map.fire(new n.Event(d,A?{originalEvent:A}:{}))},Ar.prototype._requestFrame=function(){var d=this;return this._map.triggerRepaint(),this._map._renderTaskQueue.add(function(A){delete d._frameId,d.handleEvent(new gh("renderFrame",{timeStamp:A})),d._applyChanges()})},Ar.prototype._triggerRenderFrame=function(){this._frameId===void 0&&(this._frameId=this._requestFrame())};var Dp=function(d){function A(m,w){d.call(this),this._moving=!1,this._zooming=!1,this.transform=m,this._bearingSnap=w.bearingSnap,n.bindAll(["_renderFrameCallback"],this)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype.getCenter=function(){return new n.LngLat(this.transform.center.lng,this.transform.center.lat)},A.prototype.setCenter=function(m,w){return this.jumpTo({center:m},w)},A.prototype.panBy=function(m,w,I){return m=n.Point.convert(m).mult(-1),this.panTo(this.transform.center,n.extend({offset:m},w),I)},A.prototype.panTo=function(m,w,I){return this.easeTo(n.extend({center:m},w),I)},A.prototype.getZoom=function(){return this.transform.zoom},A.prototype.setZoom=function(m,w){return this.jumpTo({zoom:m},w),this},A.prototype.zoomTo=function(m,w,I){return this.easeTo(n.extend({zoom:m},w),I)},A.prototype.zoomIn=function(m,w){return this.zoomTo(this.getZoom()+1,m,w),this},A.prototype.zoomOut=function(m,w){return this.zoomTo(this.getZoom()-1,m,w),this},A.prototype.getBearing=function(){return this.transform.bearing},A.prototype.setBearing=function(m,w){return this.jumpTo({bearing:m},w),this},A.prototype.getPadding=function(){return this.transform.padding},A.prototype.setPadding=function(m,w){return this.jumpTo({padding:m},w),this},A.prototype.rotateTo=function(m,w,I){return this.easeTo(n.extend({bearing:m},w),I)},A.prototype.resetNorth=function(m,w){return this.rotateTo(0,n.extend({duration:1e3},m),w),this},A.prototype.resetNorthPitch=function(m,w){return this.easeTo(n.extend({bearing:0,pitch:0,duration:1e3},m),w),this},A.prototype.snapToNorth=function(m,w){return Math.abs(this.getBearing())<this._bearingSnap?this.resetNorth(m,w):this},A.prototype.getPitch=function(){return this.transform.pitch},A.prototype.setPitch=function(m,w){return this.jumpTo({pitch:m},w),this},A.prototype.cameraForBounds=function(m,w){m=n.LngLatBounds.convert(m);var I=w&&w.bearing||0;return this._cameraForBoxAndBearing(m.getNorthWest(),m.getSouthEast(),I,w)},A.prototype._cameraForBoxAndBearing=function(m,w,I,F){var z={top:0,bottom:0,right:0,left:0};if(typeof(F=n.extend({padding:z,offset:[0,0],maxZoom:this.transform.maxZoom},F)).padding=="number"){var W=F.padding;F.padding={top:W,bottom:W,right:W,left:W}}F.padding=n.extend(z,F.padding);var Q=this.transform,ne=Q.padding,pe=Q.project(n.LngLat.convert(m)),Ae=Q.project(n.LngLat.convert(w)),ye=pe.rotate(-I*Math.PI/180),Ce=Ae.rotate(-I*Math.PI/180),Se=new n.Point(Math.max(ye.x,Ce.x),Math.max(ye.y,Ce.y)),Be=new n.Point(Math.min(ye.x,Ce.x),Math.min(ye.y,Ce.y)),Te=Se.sub(Be),ke=(Q.width-(ne.left+ne.right+F.padding.left+F.padding.right))/Te.x,qe=(Q.height-(ne.top+ne.bottom+F.padding.top+F.padding.bottom))/Te.y;if(!(qe<0||ke<0)){var tt=Math.min(Q.scaleZoom(Q.scale*Math.min(ke,qe)),F.maxZoom),ht=typeof F.offset.x=="number"?new n.Point(F.offset.x,F.offset.y):n.Point.convert(F.offset),ut=new n.Point((F.padding.left-F.padding.right)/2,(F.padding.top-F.padding.bottom)/2).rotate(I*Math.PI/180),vt=ht.add(ut).mult(Q.scale/Q.zoomScale(tt));return{center:Q.unproject(pe.add(Ae).div(2).sub(vt)),zoom:tt,bearing:I}}n.warnOnce("Map cannot fit within canvas with the given bounds, padding, and/or offset.")},A.prototype.fitBounds=function(m,w,I){return this._fitInternal(this.cameraForBounds(m,w),w,I)},A.prototype.fitScreenCoordinates=function(m,w,I,F,z){return this._fitInternal(this._cameraForBoxAndBearing(this.transform.pointLocation(n.Point.convert(m)),this.transform.pointLocation(n.Point.convert(w)),I,F),F,z)},A.prototype._fitInternal=function(m,w,I){return m?(delete(w=n.extend(m,w)).padding,w.linear?this.easeTo(w,I):this.flyTo(w,I)):this},A.prototype.jumpTo=function(m,w){this.stop();var I=this.transform,F=!1,z=!1,W=!1;return"zoom"in m&&I.zoom!==+m.zoom&&(F=!0,I.zoom=+m.zoom),m.center!==void 0&&(I.center=n.LngLat.convert(m.center)),"bearing"in m&&I.bearing!==+m.bearing&&(z=!0,I.bearing=+m.bearing),"pitch"in m&&I.pitch!==+m.pitch&&(W=!0,I.pitch=+m.pitch),m.padding==null||I.isPaddingEqual(m.padding)||(I.padding=m.padding),this.fire(new n.Event("movestart",w)).fire(new n.Event("move",w)),F&&this.fire(new n.Event("zoomstart",w)).fire(new n.Event("zoom",w)).fire(new n.Event("zoomend",w)),z&&this.fire(new n.Event("rotatestart",w)).fire(new n.Event("rotate",w)).fire(new n.Event("rotateend",w)),W&&this.fire(new n.Event("pitchstart",w)).fire(new n.Event("pitch",w)).fire(new n.Event("pitchend",w)),this.fire(new n.Event("moveend",w))},A.prototype.easeTo=function(m,w){var I=this;this._stop(!1,m.easeId),((m=n.extend({offset:[0,0],duration:500,easing:n.ease},m)).animate===!1||!m.essential&&n.browser.prefersReducedMotion)&&(m.duration=0);var F=this.transform,z=this.getZoom(),W=this.getBearing(),Q=this.getPitch(),ne=this.getPadding(),pe="zoom"in m?+m.zoom:z,Ae="bearing"in m?this._normalizeBearing(m.bearing,W):W,ye="pitch"in m?+m.pitch:Q,Ce="padding"in m?m.padding:F.padding,Se=n.Point.convert(m.offset),Be=F.centerPoint.add(Se),Te=F.pointLocation(Be),ke=n.LngLat.convert(m.center||Te);this._normalizeCenter(ke);var qe,tt,ht=F.project(Te),ut=F.project(ke).sub(ht),vt=F.zoomScale(pe-z);m.around&&(qe=n.LngLat.convert(m.around),tt=F.locationPoint(qe));var Et={moving:this._moving,zooming:this._zooming,rotating:this._rotating,pitching:this._pitching};return this._zooming=this._zooming||pe!==z,this._rotating=this._rotating||W!==Ae,this._pitching=this._pitching||ye!==Q,this._padding=!F.isPaddingEqual(Ce),this._easeId=m.easeId,this._prepareEase(w,m.noMoveStart,Et),this._ease(function(Nt){if(I._zooming&&(F.zoom=n.number(z,pe,Nt)),I._rotating&&(F.bearing=n.number(W,Ae,Nt)),I._pitching&&(F.pitch=n.number(Q,ye,Nt)),I._padding&&(F.interpolatePadding(ne,Ce,Nt),Be=F.centerPoint.add(Se)),qe)F.setLocationAtPoint(qe,tt);else{var Dt=F.zoomScale(F.zoom-z),rr=pe>z?Math.min(2,vt):Math.max(.5,vt),Rr=Math.pow(rr,1-Nt),Ur=F.unproject(ht.add(ut.mult(Nt*Rr)).mult(Dt));F.setLocationAtPoint(F.renderWorldCopies?Ur.wrap():Ur,Be)}I._fireMoveEvents(w)},function(Nt){I._afterEase(w,Nt)},m),this},A.prototype._prepareEase=function(m,w,I){I===void 0&&(I={}),this._moving=!0,w||I.moving||this.fire(new n.Event("movestart",m)),this._zooming&&!I.zooming&&this.fire(new n.Event("zoomstart",m)),this._rotating&&!I.rotating&&this.fire(new n.Event("rotatestart",m)),this._pitching&&!I.pitching&&this.fire(new n.Event("pitchstart",m))},A.prototype._fireMoveEvents=function(m){this.fire(new n.Event("move",m)),this._zooming&&this.fire(new n.Event("zoom",m)),this._rotating&&this.fire(new n.Event("rotate",m)),this._pitching&&this.fire(new n.Event("pitch",m))},A.prototype._afterEase=function(m,w){if(!this._easeId||!w||this._easeId!==w){delete this._easeId;var I=this._zooming,F=this._rotating,z=this._pitching;this._moving=!1,this._zooming=!1,this._rotating=!1,this._pitching=!1,this._padding=!1,I&&this.fire(new n.Event("zoomend",m)),F&&this.fire(new n.Event("rotateend",m)),z&&this.fire(new n.Event("pitchend",m)),this.fire(new n.Event("moveend",m))}},A.prototype.flyTo=function(m,w){var I=this;if(!m.essential&&n.browser.prefersReducedMotion){var F=n.pick(m,["center","zoom","bearing","pitch","around"]);return this.jumpTo(F,w)}this.stop(),m=n.extend({offset:[0,0],speed:1.2,curve:1.42,easing:n.ease},m);var z=this.transform,W=this.getZoom(),Q=this.getBearing(),ne=this.getPitch(),pe=this.getPadding(),Ae="zoom"in m?n.clamp(+m.zoom,z.minZoom,z.maxZoom):W,ye="bearing"in m?this._normalizeBearing(m.bearing,Q):Q,Ce="pitch"in m?+m.pitch:ne,Se="padding"in m?m.padding:z.padding,Be=z.zoomScale(Ae-W),Te=n.Point.convert(m.offset),ke=z.centerPoint.add(Te),qe=z.pointLocation(ke),tt=n.LngLat.convert(m.center||qe);this._normalizeCenter(tt);var ht=z.project(qe),ut=z.project(tt).sub(ht),vt=m.curve,Et=Math.max(z.width,z.height),Nt=Et/Be,Dt=ut.mag();if("minZoom"in m){var rr=n.clamp(Math.min(m.minZoom,W,Ae),z.minZoom,z.maxZoom),Rr=Et/z.zoomScale(rr-W);vt=Math.sqrt(Rr/Dt*2)}var Ur=vt*vt;function Fr(Hr){var Gr=(Nt*Nt-Et*Et+(Hr?-1:1)*Ur*Ur*Dt*Dt)/(2*(Hr?Nt:Et)*Ur*Dt);return Math.log(Math.sqrt(Gr*Gr+1)-Gr)}function kn(Hr){return(Math.exp(Hr)-Math.exp(-Hr))/2}function ir(Hr){return(Math.exp(Hr)+Math.exp(-Hr))/2}var _r=Fr(0),sn=function(Hr){return ir(_r)/ir(_r+vt*Hr)},Yr=function(Hr){return Et*((ir(_r)*(kn(Gr=_r+vt*Hr)/ir(Gr))-kn(_r))/Ur)/Dt;var Gr},Xr=(Fr(1)-_r)/vt;if(Math.abs(Dt)<1e-6||!isFinite(Xr)){if(Math.abs(Et-Nt)<1e-6)return this.easeTo(m,w);var nn=Nt<Et?-1:1;Xr=Math.abs(Math.log(Nt/Et))/vt,Yr=function(){return 0},sn=function(Hr){return Math.exp(nn*vt*Hr)}}return m.duration="duration"in m?+m.duration:1e3*Xr/("screenSpeed"in m?+m.screenSpeed/vt:+m.speed),m.maxDuration&&m.duration>m.maxDuration&&(m.duration=0),this._zooming=!0,this._rotating=Q!==ye,this._pitching=Ce!==ne,this._padding=!z.isPaddingEqual(Se),this._prepareEase(w,!1),this._ease(function(Hr){var Gr=Hr*Xr,Ba=1/sn(Gr);z.zoom=Hr===1?Ae:W+z.scaleZoom(Ba),I._rotating&&(z.bearing=n.number(Q,ye,Hr)),I._pitching&&(z.pitch=n.number(ne,Ce,Hr)),I._padding&&(z.interpolatePadding(pe,Se,Hr),ke=z.centerPoint.add(Te));var sa=Hr===1?tt:z.unproject(ht.add(ut.mult(Yr(Gr))).mult(Ba));z.setLocationAtPoint(z.renderWorldCopies?sa.wrap():sa,ke),I._fireMoveEvents(w)},function(){return I._afterEase(w)},m),this},A.prototype.isEasing=function(){return!!this._easeFrameId},A.prototype.stop=function(){return this._stop()},A.prototype._stop=function(m,w){if(this._easeFrameId&&(this._cancelRenderFrame(this._easeFrameId),delete this._easeFrameId,delete this._onEaseFrame),this._onEaseEnd){var I=this._onEaseEnd;delete this._onEaseEnd,I.call(this,w)}if(!m){var F=this.handlers;F&&F.stop(!1)}return this},A.prototype._ease=function(m,w,I){I.animate===!1||I.duration===0?(m(1),w()):(this._easeStart=n.browser.now(),this._easeOptions=I,this._onEaseFrame=m,this._onEaseEnd=w,this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback))},A.prototype._renderFrameCallback=function(){var m=Math.min((n.browser.now()-this._easeStart)/this._easeOptions.duration,1);this._onEaseFrame(this._easeOptions.easing(m)),m<1?this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback):this.stop()},A.prototype._normalizeBearing=function(m,w){m=n.wrap(m,-180,180);var I=Math.abs(m-w);return Math.abs(m-360-w)<I&&(m-=360),Math.abs(m+360-w)<I&&(m+=360),m},A.prototype._normalizeCenter=function(m){var w=this.transform;if(w.renderWorldCopies&&!w.lngRange){var I=m.lng-w.center.lng;m.lng+=I>180?-360:I<-180?360:0}},A}(n.Evented),Ko=function(d){d===void 0&&(d={}),this.options=d,n.bindAll(["_toggleAttribution","_updateEditLink","_updateData","_updateCompact"],this)};Ko.prototype.getDefaultPosition=function(){return"bottom-right"},Ko.prototype.onAdd=function(d){var A=this.options&&this.options.compact;return this._map=d,this._container=o.create("div","mapboxgl-ctrl mapboxgl-ctrl-attrib"),this._compactButton=o.create("button","mapboxgl-ctrl-attrib-button",this._container),this._compactButton.addEventListener("click",this._toggleAttribution),this._setElementTitle(this._compactButton,"ToggleAttribution"),this._innerContainer=o.create("div","mapboxgl-ctrl-attrib-inner",this._container),this._innerContainer.setAttribute("role","list"),A&&this._container.classList.add("mapboxgl-compact"),this._updateAttributions(),this._updateEditLink(),this._map.on("styledata",this._updateData),this._map.on("sourcedata",this._updateData),this._map.on("moveend",this._updateEditLink),A===void 0&&(this._map.on("resize",this._updateCompact),this._updateCompact()),this._container},Ko.prototype.onRemove=function(){o.remove(this._container),this._map.off("styledata",this._updateData),this._map.off("sourcedata",this._updateData),this._map.off("moveend",this._updateEditLink),this._map.off("resize",this._updateCompact),this._map=void 0,this._attribHTML=void 0},Ko.prototype._setElementTitle=function(d,A){var m=this._map._getUIString("AttributionControl."+A);d.title=m,d.setAttribute("aria-label",m)},Ko.prototype._toggleAttribution=function(){this._container.classList.contains("mapboxgl-compact-show")?(this._container.classList.remove("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-pressed","false")):(this._container.classList.add("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-pressed","true"))},Ko.prototype._updateEditLink=function(){var d=this._editLink;d||(d=this._editLink=this._container.querySelector(".mapbox-improve-map"));var A=[{key:"owner",value:this.styleOwner},{key:"id",value:this.styleId},{key:"access_token",value:this._map._requestManager._customAccessToken||n.config.ACCESS_TOKEN}];if(d){var m=A.reduce(function(w,I,F){return I.value&&(w+=I.key+"="+I.value+(F<A.length-1?"&":"")),w},"?");d.href=n.config.FEEDBACK_URL+"/"+m+(this._map._hash?this._map._hash.getHashString(!0):""),d.rel="noopener nofollow",this._setElementTitle(d,"MapFeedback")}},Ko.prototype._updateData=function(d){!d||d.sourceDataType!=="metadata"&&d.sourceDataType!=="visibility"&&d.dataType!=="style"||(this._updateAttributions(),this._updateEditLink())},Ko.prototype._updateAttributions=function(){if(this._map.style){var d=[];if(this.options.customAttribution&&(Array.isArray(this.options.customAttribution)?d=d.concat(this.options.customAttribution.map(function(W){return typeof W!="string"?"":W})):typeof this.options.customAttribution=="string"&&d.push(this.options.customAttribution)),this._map.style.stylesheet){var A=this._map.style.stylesheet;this.styleOwner=A.owner,this.styleId=A.id}var m=this._map.style.sourceCaches;for(var w in m){var I=m[w];if(I.used){var F=I.getSource();F.attribution&&d.indexOf(F.attribution)<0&&d.push(F.attribution)}}d.sort(function(W,Q){return W.length-Q.length});var z=(d=d.filter(function(W,Q){for(var ne=Q+1;ne<d.length;ne++)if(d[ne].indexOf(W)>=0)return!1;return!0})).join(" | ");z!==this._attribHTML&&(this._attribHTML=z,d.length?(this._innerContainer.innerHTML=z,this._container.classList.remove("mapboxgl-attrib-empty")):this._container.classList.add("mapboxgl-attrib-empty"),this._editLink=null)}},Ko.prototype._updateCompact=function(){this._map.getCanvasContainer().offsetWidth<=640?this._container.classList.add("mapboxgl-compact"):this._container.classList.remove("mapboxgl-compact","mapboxgl-compact-show")};var ru=function(){n.bindAll(["_updateLogo"],this),n.bindAll(["_updateCompact"],this)};ru.prototype.onAdd=function(d){this._map=d,this._container=o.create("div","mapboxgl-ctrl");var A=o.create("a","mapboxgl-ctrl-logo");return A.target="_blank",A.rel="noopener nofollow",A.href="https://www.mapbox.com/",A.setAttribute("aria-label",this._map._getUIString("LogoControl.Title")),A.setAttribute("rel","noopener nofollow"),this._container.appendChild(A),this._container.style.display="none",this._map.on("sourcedata",this._updateLogo),this._updateLogo(),this._map.on("resize",this._updateCompact),this._updateCompact(),this._container},ru.prototype.onRemove=function(){o.remove(this._container),this._map.off("sourcedata",this._updateLogo),this._map.off("resize",this._updateCompact)},ru.prototype.getDefaultPosition=function(){return"bottom-left"},ru.prototype._updateLogo=function(d){d&&d.sourceDataType!=="metadata"||(this._container.style.display=this._logoRequired()?"block":"none")},ru.prototype._logoRequired=function(){if(this._map.style){var d=this._map.style.sourceCaches;for(var A in d)if(d[A].getSource().mapbox_logo)return!0;return!1}},ru.prototype._updateCompact=function(){var d=this._container.children;if(d.length){var A=d[0];this._map.getCanvasContainer().offsetWidth<250?A.classList.add("mapboxgl-compact"):A.classList.remove("mapboxgl-compact")}};var io=function(){this._queue=[],this._id=0,this._cleared=!1,this._currentlyRunning=!1};io.prototype.add=function(d){var A=++this._id;return this._queue.push({callback:d,id:A,cancelled:!1}),A},io.prototype.remove=function(d){for(var A=this._currentlyRunning,m=0,w=A?this._queue.concat(A):this._queue;m<w.length;m+=1){var I=w[m];if(I.id===d)return void(I.cancelled=!0)}},io.prototype.run=function(d){d===void 0&&(d=0);var A=this._currentlyRunning=this._queue;this._queue=[];for(var m=0,w=A;m<w.length;m+=1){var I=w[m];if(!I.cancelled&&(I.callback(d),this._cleared))break}this._cleared=!1,this._currentlyRunning=!1},io.prototype.clear=function(){this._currentlyRunning&&(this._cleared=!0),this._queue=[]};var nu={"AttributionControl.ToggleAttribution":"Toggle attribution","AttributionControl.MapFeedback":"Map feedback","FullscreenControl.Enter":"Enter fullscreen","FullscreenControl.Exit":"Exit fullscreen","GeolocateControl.FindMyLocation":"Find my location","GeolocateControl.LocationNotAvailable":"Location not available","LogoControl.Title":"Mapbox logo","NavigationControl.ResetBearing":"Reset bearing to north","NavigationControl.ZoomIn":"Zoom in","NavigationControl.ZoomOut":"Zoom out","ScaleControl.Feet":"ft","ScaleControl.Meters":"m","ScaleControl.Kilometers":"km","ScaleControl.Miles":"mi","ScaleControl.NauticalMiles":"nm"},rm=n.window.HTMLImageElement,Co=n.window.HTMLElement,rn=n.window.ImageBitmap,ao={center:[0,0],zoom:0,bearing:0,pitch:0,minZoom:-2,maxZoom:22,minPitch:0,maxPitch:60,interactive:!0,scrollZoom:!0,boxZoom:!0,dragRotate:!0,dragPan:!0,keyboard:!0,doubleClickZoom:!0,touchZoomRotate:!0,touchPitch:!0,bearingSnap:7,clickTolerance:3,pitchWithRotate:!0,hash:!1,attributionControl:!0,failIfMajorPerformanceCaveat:!1,preserveDrawingBuffer:!1,trackResize:!0,renderWorldCopies:!0,refreshExpiredTiles:!0,maxTileCacheSize:null,localIdeographFontFamily:"sans-serif",transformRequest:null,accessToken:null,fadeDuration:300,crossSourceCollisions:!0},aA=function(d){function A(w){var I=this;if((w=n.extend({},ao,w)).minZoom!=null&&w.maxZoom!=null&&w.minZoom>w.maxZoom)throw new Error("maxZoom must be greater than or equal to minZoom");if(w.minPitch!=null&&w.maxPitch!=null&&w.minPitch>w.maxPitch)throw new Error("maxPitch must be greater than or equal to minPitch");if(w.minPitch!=null&&w.minPitch<0)throw new Error("minPitch must be greater than or equal to 0");if(w.maxPitch!=null&&w.maxPitch>60)throw new Error("maxPitch must be less than or equal to 60");var F=new pn(w.minZoom,w.maxZoom,w.minPitch,w.maxPitch,w.renderWorldCopies);if(d.call(this,F,w),this._interactive=w.interactive,this._maxTileCacheSize=w.maxTileCacheSize,this._failIfMajorPerformanceCaveat=w.failIfMajorPerformanceCaveat,this._preserveDrawingBuffer=w.preserveDrawingBuffer,this._antialias=w.antialias,this._trackResize=w.trackResize,this._bearingSnap=w.bearingSnap,this._refreshExpiredTiles=w.refreshExpiredTiles,this._fadeDuration=w.fadeDuration,this._crossSourceCollisions=w.crossSourceCollisions,this._crossFadingFactor=1,this._collectResourceTiming=w.collectResourceTiming,this._renderTaskQueue=new io,this._controls=[],this._mapId=n.uniqueId(),this._locale=n.extend({},nu,w.locale),this._clickTolerance=w.clickTolerance,this._requestManager=new n.RequestManager(w.transformRequest,w.accessToken),typeof w.container=="string"){if(this._container=n.window.document.getElementById(w.container),!this._container)throw new Error("Container '"+w.container+"' not found.")}else{if(!(w.container instanceof Co))throw new Error("Invalid type: 'container' must be a String or HTMLElement.");this._container=w.container}if(w.maxBounds&&this.setMaxBounds(w.maxBounds),n.bindAll(["_onWindowOnline","_onWindowResize","_onMapScroll","_contextLost","_contextRestored"],this),this._setupContainer(),this._setupPainter(),this.painter===void 0)throw new Error("Failed to initialize WebGL.");this.on("move",function(){return I._update(!1)}),this.on("moveend",function(){return I._update(!1)}),this.on("zoom",function(){return I._update(!0)}),n.window!==void 0&&(n.window.addEventListener("online",this._onWindowOnline,!1),n.window.addEventListener("resize",this._onWindowResize,!1),n.window.addEventListener("orientationchange",this._onWindowResize,!1)),this.handlers=new Ar(this,w),this._hash=w.hash&&new ns(typeof w.hash=="string"&&w.hash||void 0).addTo(this),this._hash&&this._hash._onHashChange()||(this.jumpTo({center:w.center,zoom:w.zoom,bearing:w.bearing,pitch:w.pitch}),w.bounds&&(this.resize(),this.fitBounds(w.bounds,n.extend({},w.fitBoundsOptions,{duration:0})))),this.resize(),this._localIdeographFontFamily=w.localIdeographFontFamily,w.style&&this.setStyle(w.style,{localIdeographFontFamily:w.localIdeographFontFamily}),w.attributionControl&&this.addControl(new Ko({customAttribution:w.customAttribution})),this.addControl(new ru,w.logoPosition),this.on("style.load",function(){I.transform.unmodified&&I.jumpTo(I.style.stylesheet)}),this.on("data",function(z){I._update(z.dataType==="style"),I.fire(new n.Event(z.dataType+"data",z))}),this.on("dataloading",function(z){I.fire(new n.Event(z.dataType+"dataloading",z))})}d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A;var m={showTileBoundaries:{configurable:!0},showPadding:{configurable:!0},showCollisionBoxes:{configurable:!0},showOverdrawInspector:{configurable:!0},repaint:{configurable:!0},vertices:{configurable:!0},version:{configurable:!0}};return A.prototype._getMapId=function(){return this._mapId},A.prototype.addControl=function(w,I){if(I===void 0&&(I=w.getDefaultPosition?w.getDefaultPosition():"top-right"),!w||!w.onAdd)return this.fire(new n.ErrorEvent(new Error("Invalid argument to map.addControl(). Argument must be a control with onAdd and onRemove methods.")));var F=w.onAdd(this);this._controls.push(w);var z=this._controlPositions[I];return I.indexOf("bottom")!==-1?z.insertBefore(F,z.firstChild):z.appendChild(F),this},A.prototype.removeControl=function(w){if(!w||!w.onRemove)return this.fire(new n.ErrorEvent(new Error("Invalid argument to map.removeControl(). Argument must be a control with onAdd and onRemove methods.")));var I=this._controls.indexOf(w);return I>-1&&this._controls.splice(I,1),w.onRemove(this),this},A.prototype.hasControl=function(w){return this._controls.indexOf(w)>-1},A.prototype.resize=function(w){var I=this._containerDimensions(),F=I[0],z=I[1];if(F===this.transform.width&&z===this.transform.height)return this;this._resizeCanvas(F,z),this.transform.resize(F,z),this.painter.resize(F,z);var W=!this._moving;return W&&this.fire(new n.Event("movestart",w)).fire(new n.Event("move",w)),this.fire(new n.Event("resize",w)),W&&this.fire(new n.Event("moveend",w)),this},A.prototype.getBounds=function(){return this.transform.getBounds()},A.prototype.getMaxBounds=function(){return this.transform.getMaxBounds()},A.prototype.setMaxBounds=function(w){return this.transform.setMaxBounds(n.LngLatBounds.convert(w)),this._update()},A.prototype.setMinZoom=function(w){if((w=w??-2)>=-2&&w<=this.transform.maxZoom)return this.transform.minZoom=w,this._update(),this.getZoom()<w&&this.setZoom(w),this;throw new Error("minZoom must be between -2 and the current maxZoom, inclusive")},A.prototype.getMinZoom=function(){return this.transform.minZoom},A.prototype.setMaxZoom=function(w){if((w=w??22)>=this.transform.minZoom)return this.transform.maxZoom=w,this._update(),this.getZoom()>w&&this.setZoom(w),this;throw new Error("maxZoom must be greater than the current minZoom")},A.prototype.getMaxZoom=function(){return this.transform.maxZoom},A.prototype.setMinPitch=function(w){if((w=w??0)<0)throw new Error("minPitch must be greater than or equal to 0");if(w>=0&&w<=this.transform.maxPitch)return this.transform.minPitch=w,this._update(),this.getPitch()<w&&this.setPitch(w),this;throw new Error("minPitch must be between 0 and the current maxPitch, inclusive")},A.prototype.getMinPitch=function(){return this.transform.minPitch},A.prototype.setMaxPitch=function(w){if((w=w??60)>60)throw new Error("maxPitch must be less than or equal to 60");if(w>=this.transform.minPitch)return this.transform.maxPitch=w,this._update(),this.getPitch()>w&&this.setPitch(w),this;throw new Error("maxPitch must be greater than the current minPitch")},A.prototype.getMaxPitch=function(){return this.transform.maxPitch},A.prototype.getRenderWorldCopies=function(){return this.transform.renderWorldCopies},A.prototype.setRenderWorldCopies=function(w){return this.transform.renderWorldCopies=w,this._update()},A.prototype.project=function(w){return this.transform.locationPoint(n.LngLat.convert(w))},A.prototype.unproject=function(w){return this.transform.pointLocation(n.Point.convert(w))},A.prototype.isMoving=function(){return this._moving||this.handlers.isMoving()},A.prototype.isZooming=function(){return this._zooming||this.handlers.isZooming()},A.prototype.isRotating=function(){return this._rotating||this.handlers.isRotating()},A.prototype._createDelegatedListener=function(w,I,F){var z,W=this;if(w==="mouseenter"||w==="mouseover"){var Q=!1;return{layer:I,listener:F,delegates:{mousemove:function(pe){var Ae=W.getLayer(I)?W.queryRenderedFeatures(pe.point,{layers:[I]}):[];Ae.length?Q||(Q=!0,F.call(W,new oa(w,W,pe.originalEvent,{features:Ae}))):Q=!1},mouseout:function(){Q=!1}}}}if(w==="mouseleave"||w==="mouseout"){var ne=!1;return{layer:I,listener:F,delegates:{mousemove:function(pe){(W.getLayer(I)?W.queryRenderedFeatures(pe.point,{layers:[I]}):[]).length?ne=!0:ne&&(ne=!1,F.call(W,new oa(w,W,pe.originalEvent)))},mouseout:function(pe){ne&&(ne=!1,F.call(W,new oa(w,W,pe.originalEvent)))}}}}return{layer:I,listener:F,delegates:(z={},z[w]=function(pe){var Ae=W.getLayer(I)?W.queryRenderedFeatures(pe.point,{layers:[I]}):[];Ae.length&&(pe.features=Ae,F.call(W,pe),delete pe.features)},z)}},A.prototype.on=function(w,I,F){if(F===void 0)return d.prototype.on.call(this,w,I);var z=this._createDelegatedListener(w,I,F);for(var W in this._delegatedListeners=this._delegatedListeners||{},this._delegatedListeners[w]=this._delegatedListeners[w]||[],this._delegatedListeners[w].push(z),z.delegates)this.on(W,z.delegates[W]);return this},A.prototype.once=function(w,I,F){if(F===void 0)return d.prototype.once.call(this,w,I);var z=this._createDelegatedListener(w,I,F);for(var W in z.delegates)this.once(W,z.delegates[W]);return this},A.prototype.off=function(w,I,F){var z=this;return F===void 0?d.prototype.off.call(this,w,I):(this._delegatedListeners&&this._delegatedListeners[w]&&function(W){for(var Q=W[w],ne=0;ne<Q.length;ne++){var pe=Q[ne];if(pe.layer===I&&pe.listener===F){for(var Ae in pe.delegates)z.off(Ae,pe.delegates[Ae]);return Q.splice(ne,1),z}}}(this._delegatedListeners),this)},A.prototype.queryRenderedFeatures=function(w,I){if(!this.style)return[];var F;if(I!==void 0||w===void 0||w instanceof n.Point||Array.isArray(w)||(I=w,w=void 0),I=I||{},(w=w||[[0,0],[this.transform.width,this.transform.height]])instanceof n.Point||typeof w[0]=="number")F=[n.Point.convert(w)];else{var z=n.Point.convert(w[0]),W=n.Point.convert(w[1]);F=[z,new n.Point(W.x,z.y),W,new n.Point(z.x,W.y),z]}return this.style.queryRenderedFeatures(F,I,this.transform)},A.prototype.querySourceFeatures=function(w,I){return this.style.querySourceFeatures(w,I)},A.prototype.setStyle=function(w,I){return(I=n.extend({},{localIdeographFontFamily:this._localIdeographFontFamily},I)).diff!==!1&&I.localIdeographFontFamily===this._localIdeographFontFamily&&this.style&&w?(this._diffStyle(w,I),this):(this._localIdeographFontFamily=I.localIdeographFontFamily,this._updateStyle(w,I))},A.prototype._getUIString=function(w){var I=this._locale[w];if(I==null)throw new Error("Missing UI string '"+w+"'");return I},A.prototype._updateStyle=function(w,I){return this.style&&(this.style.setEventedParent(null),this.style._remove()),w?(this.style=new Ns(this,I||{}),this.style.setEventedParent(this,{style:this.style}),typeof w=="string"?this.style.loadURL(w):this.style.loadJSON(w),this):(delete this.style,this)},A.prototype._lazyInitEmptyStyle=function(){this.style||(this.style=new Ns(this,{}),this.style.setEventedParent(this,{style:this.style}),this.style.loadEmpty())},A.prototype._diffStyle=function(w,I){var F=this;if(typeof w=="string"){var z=this._requestManager.normalizeStyleURL(w),W=this._requestManager.transformRequest(z,n.ResourceType.Style);n.getJSON(W,function(Q,ne){Q?F.fire(new n.ErrorEvent(Q)):ne&&F._updateDiff(ne,I)})}else typeof w=="object"&&this._updateDiff(w,I)},A.prototype._updateDiff=function(w,I){try{this.style.setState(w)&&this._update(!0)}catch(F){n.warnOnce("Unable to perform style diff: "+(F.message||F.error||F)+". Rebuilding the style from scratch."),this._updateStyle(w,I)}},A.prototype.getStyle=function(){if(this.style)return this.style.serialize()},A.prototype.isStyleLoaded=function(){return this.style?this.style.loaded():n.warnOnce("There is no style added to the map.")},A.prototype.addSource=function(w,I){return this._lazyInitEmptyStyle(),this.style.addSource(w,I),this._update(!0)},A.prototype.isSourceLoaded=function(w){var I=this.style&&this.style.sourceCaches[w];if(I!==void 0)return I.loaded();this.fire(new n.ErrorEvent(new Error("There is no source with ID '"+w+"'")))},A.prototype.areTilesLoaded=function(){var w=this.style&&this.style.sourceCaches;for(var I in w){var F=w[I]._tiles;for(var z in F){var W=F[z];if(W.state!=="loaded"&&W.state!=="errored")return!1}}return!0},A.prototype.addSourceType=function(w,I,F){return this._lazyInitEmptyStyle(),this.style.addSourceType(w,I,F)},A.prototype.removeSource=function(w){return this.style.removeSource(w),this._update(!0)},A.prototype.getSource=function(w){return this.style.getSource(w)},A.prototype.addImage=function(w,I,F){F===void 0&&(F={});var z=F.pixelRatio;z===void 0&&(z=1);var W=F.sdf;W===void 0&&(W=!1);var Q=F.stretchX,ne=F.stretchY,pe=F.content;if(this._lazyInitEmptyStyle(),I instanceof rm||rn&&I instanceof rn){var Ae=n.browser.getImageData(I);this.style.addImage(w,{data:new n.RGBAImage({width:Ae.width,height:Ae.height},Ae.data),pixelRatio:z,stretchX:Q,stretchY:ne,content:pe,sdf:W,version:0})}else{if(I.width===void 0||I.height===void 0)return this.fire(new n.ErrorEvent(new Error("Invalid arguments to map.addImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")));var ye=I;this.style.addImage(w,{data:new n.RGBAImage({width:I.width,height:I.height},new Uint8Array(I.data)),pixelRatio:z,stretchX:Q,stretchY:ne,content:pe,sdf:W,version:0,userImage:ye}),ye.onAdd&&ye.onAdd(this,w)}},A.prototype.updateImage=function(w,I){var F=this.style.getImage(w);if(!F)return this.fire(new n.ErrorEvent(new Error("The map has no image with that id. If you are adding a new image use `map.addImage(...)` instead.")));var z=I instanceof rm||rn&&I instanceof rn?n.browser.getImageData(I):I,W=z.width,Q=z.height,ne=z.data;return W===void 0||Q===void 0?this.fire(new n.ErrorEvent(new Error("Invalid arguments to map.updateImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`"))):W!==F.data.width||Q!==F.data.height?this.fire(new n.ErrorEvent(new Error("The width and height of the updated image must be that same as the previous version of the image"))):(F.data.replace(ne,!(I instanceof rm||rn&&I instanceof rn)),void this.style.updateImage(w,F))},A.prototype.hasImage=function(w){return w?!!this.style.getImage(w):(this.fire(new n.ErrorEvent(new Error("Missing required image id"))),!1)},A.prototype.removeImage=function(w){this.style.removeImage(w)},A.prototype.loadImage=function(w,I){n.getImage(this._requestManager.transformRequest(w,n.ResourceType.Image),I)},A.prototype.listImages=function(){return this.style.listImages()},A.prototype.addLayer=function(w,I){return this._lazyInitEmptyStyle(),this.style.addLayer(w,I),this._update(!0)},A.prototype.moveLayer=function(w,I){return this.style.moveLayer(w,I),this._update(!0)},A.prototype.removeLayer=function(w){return this.style.removeLayer(w),this._update(!0)},A.prototype.getLayer=function(w){return this.style.getLayer(w)},A.prototype.setLayerZoomRange=function(w,I,F){return this.style.setLayerZoomRange(w,I,F),this._update(!0)},A.prototype.setFilter=function(w,I,F){return F===void 0&&(F={}),this.style.setFilter(w,I,F),this._update(!0)},A.prototype.getFilter=function(w){return this.style.getFilter(w)},A.prototype.setPaintProperty=function(w,I,F,z){return z===void 0&&(z={}),this.style.setPaintProperty(w,I,F,z),this._update(!0)},A.prototype.getPaintProperty=function(w,I){return this.style.getPaintProperty(w,I)},A.prototype.setLayoutProperty=function(w,I,F,z){return z===void 0&&(z={}),this.style.setLayoutProperty(w,I,F,z),this._update(!0)},A.prototype.getLayoutProperty=function(w,I){return this.style.getLayoutProperty(w,I)},A.prototype.setLight=function(w,I){return I===void 0&&(I={}),this._lazyInitEmptyStyle(),this.style.setLight(w,I),this._update(!0)},A.prototype.getLight=function(){return this.style.getLight()},A.prototype.setFeatureState=function(w,I){return this.style.setFeatureState(w,I),this._update()},A.prototype.removeFeatureState=function(w,I){return this.style.removeFeatureState(w,I),this._update()},A.prototype.getFeatureState=function(w){return this.style.getFeatureState(w)},A.prototype.getContainer=function(){return this._container},A.prototype.getCanvasContainer=function(){return this._canvasContainer},A.prototype.getCanvas=function(){return this._canvas},A.prototype._containerDimensions=function(){var w=0,I=0;return this._container&&(w=this._container.clientWidth||400,I=this._container.clientHeight||300),[w,I]},A.prototype._detectMissingCSS=function(){n.window.getComputedStyle(this._missingCSSCanary).getPropertyValue("background-color")!=="rgb(250, 128, 114)"&&n.warnOnce("This page appears to be missing CSS declarations for Mapbox GL JS, which may cause the map to display incorrectly. Please ensure your page includes mapbox-gl.css, as described in https://www.mapbox.com/mapbox-gl-js/api/.")},A.prototype._setupContainer=function(){var w=this._container;w.classList.add("mapboxgl-map"),(this._missingCSSCanary=o.create("div","mapboxgl-canary",w)).style.visibility="hidden",this._detectMissingCSS();var I=this._canvasContainer=o.create("div","mapboxgl-canvas-container",w);this._interactive&&I.classList.add("mapboxgl-interactive"),this._canvas=o.create("canvas","mapboxgl-canvas",I),this._canvas.addEventListener("webglcontextlost",this._contextLost,!1),this._canvas.addEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.setAttribute("tabindex","0"),this._canvas.setAttribute("aria-label","Map"),this._canvas.setAttribute("role","region");var F=this._containerDimensions();this._resizeCanvas(F[0],F[1]);var z=this._controlContainer=o.create("div","mapboxgl-control-container",w),W=this._controlPositions={};["top-left","top-right","bottom-left","bottom-right"].forEach(function(Q){W[Q]=o.create("div","mapboxgl-ctrl-"+Q,z)}),this._container.addEventListener("scroll",this._onMapScroll,!1)},A.prototype._resizeCanvas=function(w,I){var F=n.browser.devicePixelRatio||1;this._canvas.width=F*w,this._canvas.height=F*I,this._canvas.style.width=w+"px",this._canvas.style.height=I+"px"},A.prototype._setupPainter=function(){var w=n.extend({},a.webGLContextAttributes,{failIfMajorPerformanceCaveat:this._failIfMajorPerformanceCaveat,preserveDrawingBuffer:this._preserveDrawingBuffer,antialias:this._antialias||!1}),I=this._canvas.getContext("webgl",w)||this._canvas.getContext("experimental-webgl",w);I?(this.painter=new Li(I,this.transform),n.webpSupported.testSupport(I)):this.fire(new n.ErrorEvent(new Error("Failed to initialize WebGL")))},A.prototype._contextLost=function(w){w.preventDefault(),this._frame&&(this._frame.cancel(),this._frame=null),this.fire(new n.Event("webglcontextlost",{originalEvent:w}))},A.prototype._contextRestored=function(w){this._setupPainter(),this.resize(),this._update(),this.fire(new n.Event("webglcontextrestored",{originalEvent:w}))},A.prototype._onMapScroll=function(w){if(w.target===this._container)return this._container.scrollTop=0,this._container.scrollLeft=0,!1},A.prototype.loaded=function(){return!this._styleDirty&&!this._sourcesDirty&&!!this.style&&this.style.loaded()},A.prototype._update=function(w){return this.style?(this._styleDirty=this._styleDirty||w,this._sourcesDirty=!0,this.triggerRepaint(),this):this},A.prototype._requestRenderFrame=function(w){return this._update(),this._renderTaskQueue.add(w)},A.prototype._cancelRenderFrame=function(w){this._renderTaskQueue.remove(w)},A.prototype._render=function(w){var I,F=this,z=0,W=this.painter.context.extTimerQuery;if(this.listens("gpu-timing-frame")&&(I=W.createQueryEXT(),W.beginQueryEXT(W.TIME_ELAPSED_EXT,I),z=n.browser.now()),this.painter.context.setDirty(),this.painter.setBaseState(),this._renderTaskQueue.run(w),!this._removed){var Q=!1;if(this.style&&this._styleDirty){this._styleDirty=!1;var ne=this.transform.zoom,pe=n.browser.now();this.style.zoomHistory.update(ne,pe);var Ae=new n.EvaluationParameters(ne,{now:pe,fadeDuration:this._fadeDuration,zoomHistory:this.style.zoomHistory,transition:this.style.getTransition()}),ye=Ae.crossFadingFactor();ye===1&&ye===this._crossFadingFactor||(Q=!0,this._crossFadingFactor=ye),this.style.update(Ae)}if(this.style&&this._sourcesDirty&&(this._sourcesDirty=!1,this.style._updateSources(this.transform)),this._placementDirty=this.style&&this.style._updatePlacement(this.painter.transform,this.showCollisionBoxes,this._fadeDuration,this._crossSourceCollisions),this.painter.render(this.style,{showTileBoundaries:this.showTileBoundaries,showOverdrawInspector:this._showOverdrawInspector,rotating:this.isRotating(),zooming:this.isZooming(),moving:this.isMoving(),fadeDuration:this._fadeDuration,showPadding:this.showPadding,gpuTiming:!!this.listens("gpu-timing-layer")}),this.fire(new n.Event("render")),this.loaded()&&!this._loaded&&(this._loaded=!0,this.fire(new n.Event("load"))),this.style&&(this.style.hasTransitions()||Q)&&(this._styleDirty=!0),this.style&&!this._placementDirty&&this.style._releaseSymbolFadeTiles(),this.listens("gpu-timing-frame")){var Ce=n.browser.now()-z;W.endQueryEXT(W.TIME_ELAPSED_EXT,I),setTimeout(function(){var Te=W.getQueryObjectEXT(I,W.QUERY_RESULT_EXT)/1e6;W.deleteQueryEXT(I),F.fire(new n.Event("gpu-timing-frame",{cpuTime:Ce,gpuTime:Te}))},50)}if(this.listens("gpu-timing-layer")){var Se=this.painter.collectGpuTimers();setTimeout(function(){var Te=F.painter.queryGpuTimers(Se);F.fire(new n.Event("gpu-timing-layer",{layerTimes:Te}))},50)}var Be=this._sourcesDirty||this._styleDirty||this._placementDirty;return Be||this._repaint?this.triggerRepaint():!this.isMoving()&&this.loaded()&&this.fire(new n.Event("idle")),!this._loaded||this._fullyLoaded||Be||(this._fullyLoaded=!0),this}},A.prototype.remove=function(){this._hash&&this._hash.remove();for(var w=0,I=this._controls;w<I.length;w+=1)I[w].onRemove(this);this._controls=[],this._frame&&(this._frame.cancel(),this._frame=null),this._renderTaskQueue.clear(),this.painter.destroy(),this.handlers.destroy(),delete this.handlers,this.setStyle(null),n.window!==void 0&&(n.window.removeEventListener("resize",this._onWindowResize,!1),n.window.removeEventListener("orientationchange",this._onWindowResize,!1),n.window.removeEventListener("online",this._onWindowOnline,!1));var F=this.painter.context.gl.getExtension("WEBGL_lose_context");F&&F.loseContext(),_c(this._canvasContainer),_c(this._controlContainer),_c(this._missingCSSCanary),this._container.classList.remove("mapboxgl-map"),this._removed=!0,this.fire(new n.Event("remove"))},A.prototype.triggerRepaint=function(){var w=this;this.style&&!this._frame&&(this._frame=n.browser.frame(function(I){w._frame=null,w._render(I)}))},A.prototype._onWindowOnline=function(){this._update()},A.prototype._onWindowResize=function(w){this._trackResize&&this.resize({originalEvent:w})._update()},m.showTileBoundaries.get=function(){return!!this._showTileBoundaries},m.showTileBoundaries.set=function(w){this._showTileBoundaries!==w&&(this._showTileBoundaries=w,this._update())},m.showPadding.get=function(){return!!this._showPadding},m.showPadding.set=function(w){this._showPadding!==w&&(this._showPadding=w,this._update())},m.showCollisionBoxes.get=function(){return!!this._showCollisionBoxes},m.showCollisionBoxes.set=function(w){this._showCollisionBoxes!==w&&(this._showCollisionBoxes=w,w?this.style._generateCollisionBoxes():this._update())},m.showOverdrawInspector.get=function(){return!!this._showOverdrawInspector},m.showOverdrawInspector.set=function(w){this._showOverdrawInspector!==w&&(this._showOverdrawInspector=w,this._update())},m.repaint.get=function(){return!!this._repaint},m.repaint.set=function(w){this._repaint!==w&&(this._repaint=w,this.triggerRepaint())},m.vertices.get=function(){return!!this._vertices},m.vertices.set=function(w){this._vertices=w,this._update()},A.prototype._setCacheLimits=function(w,I){n.setCacheLimits(w,I)},m.version.get=function(){return n.version},Object.defineProperties(A.prototype,m),A}(Dp);function _c(d){d.parentNode&&d.parentNode.removeChild(d)}var nm={showCompass:!0,showZoom:!0,visualizePitch:!1},Al=function(d){var A=this;this.options=n.extend({},nm,d),this._container=o.create("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._container.addEventListener("contextmenu",function(m){return m.preventDefault()}),this.options.showZoom&&(n.bindAll(["_setButtonTitle","_updateZoomButtons"],this),this._zoomInButton=this._createButton("mapboxgl-ctrl-zoom-in",function(m){return A._map.zoomIn({},{originalEvent:m})}),o.create("span","mapboxgl-ctrl-icon",this._zoomInButton).setAttribute("aria-hidden",!0),this._zoomOutButton=this._createButton("mapboxgl-ctrl-zoom-out",function(m){return A._map.zoomOut({},{originalEvent:m})}),o.create("span","mapboxgl-ctrl-icon",this._zoomOutButton).setAttribute("aria-hidden",!0)),this.options.showCompass&&(n.bindAll(["_rotateCompassArrow"],this),this._compass=this._createButton("mapboxgl-ctrl-compass",function(m){A.options.visualizePitch?A._map.resetNorthPitch({},{originalEvent:m}):A._map.resetNorth({},{originalEvent:m})}),this._compassIcon=o.create("span","mapboxgl-ctrl-icon",this._compass),this._compassIcon.setAttribute("aria-hidden",!0))};Al.prototype._updateZoomButtons=function(){var d=this._map.getZoom(),A=d===this._map.getMaxZoom(),m=d===this._map.getMinZoom();this._zoomInButton.disabled=A,this._zoomOutButton.disabled=m,this._zoomInButton.setAttribute("aria-disabled",A.toString()),this._zoomOutButton.setAttribute("aria-disabled",m.toString())},Al.prototype._rotateCompassArrow=function(){var d=this.options.visualizePitch?"scale("+1/Math.pow(Math.cos(this._map.transform.pitch*(Math.PI/180)),.5)+") rotateX("+this._map.transform.pitch+"deg) rotateZ("+this._map.transform.angle*(180/Math.PI)+"deg)":"rotate("+this._map.transform.angle*(180/Math.PI)+"deg)";this._compassIcon.style.transform=d},Al.prototype.onAdd=function(d){return this._map=d,this.options.showZoom&&(this._setButtonTitle(this._zoomInButton,"ZoomIn"),this._setButtonTitle(this._zoomOutButton,"ZoomOut"),this._map.on("zoom",this._updateZoomButtons),this._updateZoomButtons()),this.options.showCompass&&(this._setButtonTitle(this._compass,"ResetBearing"),this.options.visualizePitch&&this._map.on("pitch",this._rotateCompassArrow),this._map.on("rotate",this._rotateCompassArrow),this._rotateCompassArrow(),this._handler=new ki(this._map,this._compass,this.options.visualizePitch)),this._container},Al.prototype.onRemove=function(){o.remove(this._container),this.options.showZoom&&this._map.off("zoom",this._updateZoomButtons),this.options.showCompass&&(this.options.visualizePitch&&this._map.off("pitch",this._rotateCompassArrow),this._map.off("rotate",this._rotateCompassArrow),this._handler.off(),delete this._handler),delete this._map},Al.prototype._createButton=function(d,A){var m=o.create("button",d,this._container);return m.type="button",m.addEventListener("click",A),m},Al.prototype._setButtonTitle=function(d,A){var m=this._map._getUIString("NavigationControl."+A);d.title=m,d.setAttribute("aria-label",m)};var ki=function(d,A,m){m===void 0&&(m=!1),this._clickTolerance=10,this.element=A,this.mouseRotate=new Lp({clickTolerance:d.dragRotate._mouseRotate._clickTolerance}),this.map=d,m&&(this.mousePitch=new kp({clickTolerance:d.dragRotate._mousePitch._clickTolerance})),n.bindAll(["mousedown","mousemove","mouseup","touchstart","touchmove","touchend","reset"],this),o.addEventListener(A,"mousedown",this.mousedown),o.addEventListener(A,"touchstart",this.touchstart,{passive:!1}),o.addEventListener(A,"touchmove",this.touchmove),o.addEventListener(A,"touchend",this.touchend),o.addEventListener(A,"touchcancel",this.reset)};function Dl(d,A,m){if(d=new n.LngLat(d.lng,d.lat),A){var w=new n.LngLat(d.lng-360,d.lat),I=new n.LngLat(d.lng+360,d.lat),F=m.locationPoint(d).distSqr(A);m.locationPoint(w).distSqr(A)<F?d=w:m.locationPoint(I).distSqr(A)<F&&(d=I)}for(;Math.abs(d.lng-m.center.lng)>180;){var z=m.locationPoint(d);if(z.x>=0&&z.y>=0&&z.x<=m.width&&z.y<=m.height)break;d.lng>m.center.lng?d.lng-=360:d.lng+=360}return d}ki.prototype.down=function(d,A){this.mouseRotate.mousedown(d,A),this.mousePitch&&this.mousePitch.mousedown(d,A),o.disableDrag()},ki.prototype.move=function(d,A){var m=this.map,w=this.mouseRotate.mousemoveWindow(d,A);if(w&&w.bearingDelta&&m.setBearing(m.getBearing()+w.bearingDelta),this.mousePitch){var I=this.mousePitch.mousemoveWindow(d,A);I&&I.pitchDelta&&m.setPitch(m.getPitch()+I.pitchDelta)}},ki.prototype.off=function(){var d=this.element;o.removeEventListener(d,"mousedown",this.mousedown),o.removeEventListener(d,"touchstart",this.touchstart,{passive:!1}),o.removeEventListener(d,"touchmove",this.touchmove),o.removeEventListener(d,"touchend",this.touchend),o.removeEventListener(d,"touchcancel",this.reset),this.offTemp()},ki.prototype.offTemp=function(){o.enableDrag(),o.removeEventListener(n.window,"mousemove",this.mousemove),o.removeEventListener(n.window,"mouseup",this.mouseup)},ki.prototype.mousedown=function(d){this.down(n.extend({},d,{ctrlKey:!0,preventDefault:function(){return d.preventDefault()}}),o.mousePos(this.element,d)),o.addEventListener(n.window,"mousemove",this.mousemove),o.addEventListener(n.window,"mouseup",this.mouseup)},ki.prototype.mousemove=function(d){this.move(d,o.mousePos(this.element,d))},ki.prototype.mouseup=function(d){this.mouseRotate.mouseupWindow(d),this.mousePitch&&this.mousePitch.mouseupWindow(d),this.offTemp()},ki.prototype.touchstart=function(d){d.targetTouches.length!==1?this.reset():(this._startPos=this._lastPos=o.touchPos(this.element,d.targetTouches)[0],this.down({type:"mousedown",button:0,ctrlKey:!0,preventDefault:function(){return d.preventDefault()}},this._startPos))},ki.prototype.touchmove=function(d){d.targetTouches.length!==1?this.reset():(this._lastPos=o.touchPos(this.element,d.targetTouches)[0],this.move({preventDefault:function(){return d.preventDefault()}},this._lastPos))},ki.prototype.touchend=function(d){d.targetTouches.length===0&&this._startPos&&this._lastPos&&this._startPos.dist(this._lastPos)<this._clickTolerance&&this.element.click(),this.reset()},ki.prototype.reset=function(){this.mouseRotate.reset(),this.mousePitch&&this.mousePitch.reset(),delete this._startPos,delete this._lastPos,this.offTemp()};var Mo={center:"translate(-50%,-50%)",top:"translate(-50%,0)","top-left":"translate(0,0)","top-right":"translate(-100%,0)",bottom:"translate(-50%,-100%)","bottom-left":"translate(0,-100%)","bottom-right":"translate(-100%,-100%)",left:"translate(0,-50%)",right:"translate(-100%,-50%)"};function Fp(d,A,m){var w=d.classList;for(var I in Mo)w.remove("mapboxgl-"+m+"-anchor-"+I);w.add("mapboxgl-"+m+"-anchor-"+A)}var Fl,yh=function(d){function A(m,w){if(d.call(this),(m instanceof n.window.HTMLElement||w)&&(m=n.extend({element:m},w)),n.bindAll(["_update","_onMove","_onUp","_addDragHandler","_onMapClick","_onKeyPress"],this),this._anchor=m&&m.anchor||"center",this._color=m&&m.color||"#3FB1CE",this._scale=m&&m.scale||1,this._draggable=m&&m.draggable||!1,this._clickTolerance=m&&m.clickTolerance||0,this._isDragging=!1,this._state="inactive",this._rotation=m&&m.rotation||0,this._rotationAlignment=m&&m.rotationAlignment||"auto",this._pitchAlignment=m&&m.pitchAlignment&&m.pitchAlignment!=="auto"?m.pitchAlignment:this._rotationAlignment,m&&m.element)this._element=m.element,this._offset=n.Point.convert(m&&m.offset||[0,0]);else{this._defaultMarker=!0,this._element=o.create("div"),this._element.setAttribute("aria-label","Map marker");var I=o.createNS("http://www.w3.org/2000/svg","svg");I.setAttributeNS(null,"display","block"),I.setAttributeNS(null,"height","41px"),I.setAttributeNS(null,"width","27px"),I.setAttributeNS(null,"viewBox","0 0 27 41");var F=o.createNS("http://www.w3.org/2000/svg","g");F.setAttributeNS(null,"stroke","none"),F.setAttributeNS(null,"stroke-width","1"),F.setAttributeNS(null,"fill","none"),F.setAttributeNS(null,"fill-rule","evenodd");var z=o.createNS("http://www.w3.org/2000/svg","g");z.setAttributeNS(null,"fill-rule","nonzero");var W=o.createNS("http://www.w3.org/2000/svg","g");W.setAttributeNS(null,"transform","translate(3.0, 29.0)"),W.setAttributeNS(null,"fill","#000000");for(var Q=0,ne=[{rx:"10.5",ry:"5.25002273"},{rx:"10.5",ry:"5.25002273"},{rx:"9.5",ry:"4.77275007"},{rx:"8.5",ry:"4.29549936"},{rx:"7.5",ry:"3.81822308"},{rx:"6.5",ry:"3.34094679"},{rx:"5.5",ry:"2.86367051"},{rx:"4.5",ry:"2.38636864"}];Q<ne.length;Q+=1){var pe=ne[Q],Ae=o.createNS("http://www.w3.org/2000/svg","ellipse");Ae.setAttributeNS(null,"opacity","0.04"),Ae.setAttributeNS(null,"cx","10.5"),Ae.setAttributeNS(null,"cy","5.80029008"),Ae.setAttributeNS(null,"rx",pe.rx),Ae.setAttributeNS(null,"ry",pe.ry),W.appendChild(Ae)}var ye=o.createNS("http://www.w3.org/2000/svg","g");ye.setAttributeNS(null,"fill",this._color);var Ce=o.createNS("http://www.w3.org/2000/svg","path");Ce.setAttributeNS(null,"d","M27,13.5 C27,19.074644 20.250001,27.000002 14.75,34.500002 C14.016665,35.500004 12.983335,35.500004 12.25,34.500002 C6.7499993,27.000002 0,19.222562 0,13.5 C0,6.0441559 6.0441559,0 13.5,0 C20.955844,0 27,6.0441559 27,13.5 Z"),ye.appendChild(Ce);var Se=o.createNS("http://www.w3.org/2000/svg","g");Se.setAttributeNS(null,"opacity","0.25"),Se.setAttributeNS(null,"fill","#000000");var Be=o.createNS("http://www.w3.org/2000/svg","path");Be.setAttributeNS(null,"d","M13.5,0 C6.0441559,0 0,6.0441559 0,13.5 C0,19.222562 6.7499993,27 12.25,34.5 C13,35.522727 14.016664,35.500004 14.75,34.5 C20.250001,27 27,19.074644 27,13.5 C27,6.0441559 20.955844,0 13.5,0 Z M13.5,1 C20.415404,1 26,6.584596 26,13.5 C26,15.898657 24.495584,19.181431 22.220703,22.738281 C19.945823,26.295132 16.705119,30.142167 13.943359,33.908203 C13.743445,34.180814 13.612715,34.322738 13.5,34.441406 C13.387285,34.322738 13.256555,34.180814 13.056641,33.908203 C10.284481,30.127985 7.4148684,26.314159 5.015625,22.773438 C2.6163816,19.232715 1,15.953538 1,13.5 C1,6.584596 6.584596,1 13.5,1 Z"),Se.appendChild(Be);var Te=o.createNS("http://www.w3.org/2000/svg","g");Te.setAttributeNS(null,"transform","translate(6.0, 7.0)"),Te.setAttributeNS(null,"fill","#FFFFFF");var ke=o.createNS("http://www.w3.org/2000/svg","g");ke.setAttributeNS(null,"transform","translate(8.0, 8.0)");var qe=o.createNS("http://www.w3.org/2000/svg","circle");qe.setAttributeNS(null,"fill","#000000"),qe.setAttributeNS(null,"opacity","0.25"),qe.setAttributeNS(null,"cx","5.5"),qe.setAttributeNS(null,"cy","5.5"),qe.setAttributeNS(null,"r","5.4999962");var tt=o.createNS("http://www.w3.org/2000/svg","circle");tt.setAttributeNS(null,"fill","#FFFFFF"),tt.setAttributeNS(null,"cx","5.5"),tt.setAttributeNS(null,"cy","5.5"),tt.setAttributeNS(null,"r","5.4999962"),ke.appendChild(qe),ke.appendChild(tt),z.appendChild(W),z.appendChild(ye),z.appendChild(Se),z.appendChild(Te),z.appendChild(ke),I.appendChild(z),I.setAttributeNS(null,"height",41*this._scale+"px"),I.setAttributeNS(null,"width",27*this._scale+"px"),this._element.appendChild(I),this._offset=n.Point.convert(m&&m.offset||[0,-14])}this._element.classList.add("mapboxgl-marker"),this._element.addEventListener("dragstart",function(ht){ht.preventDefault()}),this._element.addEventListener("mousedown",function(ht){ht.preventDefault()}),Fp(this._element,this._anchor,"marker"),this._popup=null}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype.addTo=function(m){return this.remove(),this._map=m,m.getCanvasContainer().appendChild(this._element),m.on("move",this._update),m.on("moveend",this._update),this.setDraggable(this._draggable),this._update(),this._map.on("click",this._onMapClick),this},A.prototype.remove=function(){return this._map&&(this._map.off("click",this._onMapClick),this._map.off("move",this._update),this._map.off("moveend",this._update),this._map.off("mousedown",this._addDragHandler),this._map.off("touchstart",this._addDragHandler),this._map.off("mouseup",this._onUp),this._map.off("touchend",this._onUp),this._map.off("mousemove",this._onMove),this._map.off("touchmove",this._onMove),delete this._map),o.remove(this._element),this._popup&&this._popup.remove(),this},A.prototype.getLngLat=function(){return this._lngLat},A.prototype.setLngLat=function(m){return this._lngLat=n.LngLat.convert(m),this._pos=null,this._popup&&this._popup.setLngLat(this._lngLat),this._update(),this},A.prototype.getElement=function(){return this._element},A.prototype.setPopup=function(m){if(this._popup&&(this._popup.remove(),this._popup=null,this._element.removeEventListener("keypress",this._onKeyPress),this._originalTabIndex||this._element.removeAttribute("tabindex")),m){if(!("offset"in m.options)){var w=Math.sqrt(Math.pow(13.5,2)/2);m.options.offset=this._defaultMarker?{top:[0,0],"top-left":[0,0],"top-right":[0,0],bottom:[0,-38.1],"bottom-left":[w,-1*(24.6+w)],"bottom-right":[-w,-1*(24.6+w)],left:[13.5,-24.6],right:[-13.5,-24.6]}:this._offset}this._popup=m,this._lngLat&&this._popup.setLngLat(this._lngLat),this._originalTabIndex=this._element.getAttribute("tabindex"),this._originalTabIndex||this._element.setAttribute("tabindex","0"),this._element.addEventListener("keypress",this._onKeyPress)}return this},A.prototype._onKeyPress=function(m){var w=m.code,I=m.charCode||m.keyCode;w!=="Space"&&w!=="Enter"&&I!==32&&I!==13||this.togglePopup()},A.prototype._onMapClick=function(m){var w=m.originalEvent.target,I=this._element;this._popup&&(w===I||I.contains(w))&&this.togglePopup()},A.prototype.getPopup=function(){return this._popup},A.prototype.togglePopup=function(){var m=this._popup;return m?(m.isOpen()?m.remove():m.addTo(this._map),this):this},A.prototype._update=function(m){if(this._map){this._map.transform.renderWorldCopies&&(this._lngLat=Dl(this._lngLat,this._pos,this._map.transform)),this._pos=this._map.project(this._lngLat)._add(this._offset);var w="";this._rotationAlignment==="viewport"||this._rotationAlignment==="auto"?w="rotateZ("+this._rotation+"deg)":this._rotationAlignment==="map"&&(w="rotateZ("+(this._rotation-this._map.getBearing())+"deg)");var I="";this._pitchAlignment==="viewport"||this._pitchAlignment==="auto"?I="rotateX(0deg)":this._pitchAlignment==="map"&&(I="rotateX("+this._map.getPitch()+"deg)"),m&&m.type!=="moveend"||(this._pos=this._pos.round()),o.setTransform(this._element,Mo[this._anchor]+" translate("+this._pos.x+"px, "+this._pos.y+"px) "+I+" "+w)}},A.prototype.getOffset=function(){return this._offset},A.prototype.setOffset=function(m){return this._offset=n.Point.convert(m),this._update(),this},A.prototype._onMove=function(m){if(!this._isDragging){var w=this._clickTolerance||this._map._clickTolerance;this._isDragging=m.point.dist(this._pointerdownPos)>=w}this._isDragging&&(this._pos=m.point.sub(this._positionDelta),this._lngLat=this._map.unproject(this._pos),this.setLngLat(this._lngLat),this._element.style.pointerEvents="none",this._state==="pending"&&(this._state="active",this.fire(new n.Event("dragstart"))),this.fire(new n.Event("drag")))},A.prototype._onUp=function(){this._element.style.pointerEvents="auto",this._positionDelta=null,this._pointerdownPos=null,this._isDragging=!1,this._map.off("mousemove",this._onMove),this._map.off("touchmove",this._onMove),this._state==="active"&&this.fire(new n.Event("dragend")),this._state="inactive"},A.prototype._addDragHandler=function(m){this._element.contains(m.originalEvent.target)&&(m.preventDefault(),this._positionDelta=m.point.sub(this._pos).add(this._offset),this._pointerdownPos=m.point,this._state="pending",this._map.on("mousemove",this._onMove),this._map.on("touchmove",this._onMove),this._map.once("mouseup",this._onUp),this._map.once("touchend",this._onUp))},A.prototype.setDraggable=function(m){return this._draggable=!!m,this._map&&(m?(this._map.on("mousedown",this._addDragHandler),this._map.on("touchstart",this._addDragHandler)):(this._map.off("mousedown",this._addDragHandler),this._map.off("touchstart",this._addDragHandler))),this},A.prototype.isDraggable=function(){return this._draggable},A.prototype.setRotation=function(m){return this._rotation=m||0,this._update(),this},A.prototype.getRotation=function(){return this._rotation},A.prototype.setRotationAlignment=function(m){return this._rotationAlignment=m||"auto",this._update(),this},A.prototype.getRotationAlignment=function(){return this._rotationAlignment},A.prototype.setPitchAlignment=function(m){return this._pitchAlignment=m&&m!=="auto"?m:this._rotationAlignment,this._update(),this},A.prototype.getPitchAlignment=function(){return this._pitchAlignment},A}(n.Evented),ws={positionOptions:{enableHighAccuracy:!1,maximumAge:0,timeout:6e3},fitBoundsOptions:{maxZoom:15},trackUserLocation:!1,showAccuracyCircle:!0,showUserLocation:!0},xc=0,gl=!1,bc=function(d){function A(m){d.call(this),this.options=n.extend({},ws,m),n.bindAll(["_onSuccess","_onError","_onZoom","_finish","_setupUI","_updateCamera","_updateMarker"],this)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype.onAdd=function(m){var w;return this._map=m,this._container=o.create("div","mapboxgl-ctrl mapboxgl-ctrl-group"),w=this._setupUI,Fl!==void 0?w(Fl):n.window.navigator.permissions!==void 0?n.window.navigator.permissions.query({name:"geolocation"}).then(function(I){w(Fl=I.state!=="denied")}):w(Fl=!!n.window.navigator.geolocation),this._container},A.prototype.onRemove=function(){this._geolocationWatchID!==void 0&&(n.window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0),this.options.showUserLocation&&this._userLocationDotMarker&&this._userLocationDotMarker.remove(),this.options.showAccuracyCircle&&this._accuracyCircleMarker&&this._accuracyCircleMarker.remove(),o.remove(this._container),this._map.off("zoom",this._onZoom),this._map=void 0,xc=0,gl=!1},A.prototype._isOutOfMapMaxBounds=function(m){var w=this._map.getMaxBounds(),I=m.coords;return w&&(I.longitude<w.getWest()||I.longitude>w.getEast()||I.latitude<w.getSouth()||I.latitude>w.getNorth())},A.prototype._setErrorState=function(){switch(this._watchState){case"WAITING_ACTIVE":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"ACTIVE_LOCK":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting");break;case"BACKGROUND":this._watchState="BACKGROUND_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting")}},A.prototype._onSuccess=function(m){if(this._map){if(this._isOutOfMapMaxBounds(m))return this._setErrorState(),this.fire(new n.Event("outofmaxbounds",m)),this._updateMarker(),void this._finish();if(this.options.trackUserLocation)switch(this._lastKnownPosition=m,this._watchState){case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"BACKGROUND":case"BACKGROUND_ERROR":this._watchState="BACKGROUND",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background")}this.options.showUserLocation&&this._watchState!=="OFF"&&this._updateMarker(m),this.options.trackUserLocation&&this._watchState!=="ACTIVE_LOCK"||this._updateCamera(m),this.options.showUserLocation&&this._dotElement.classList.remove("mapboxgl-user-location-dot-stale"),this.fire(new n.Event("geolocate",m)),this._finish()}},A.prototype._updateCamera=function(m){var w=new n.LngLat(m.coords.longitude,m.coords.latitude),I=m.coords.accuracy,F=this._map.getBearing(),z=n.extend({bearing:F},this.options.fitBoundsOptions);this._map.fitBounds(w.toBounds(I),z,{geolocateSource:!0})},A.prototype._updateMarker=function(m){if(m){var w=new n.LngLat(m.coords.longitude,m.coords.latitude);this._accuracyCircleMarker.setLngLat(w).addTo(this._map),this._userLocationDotMarker.setLngLat(w).addTo(this._map),this._accuracy=m.coords.accuracy,this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}else this._userLocationDotMarker.remove(),this._accuracyCircleMarker.remove()},A.prototype._updateCircleRadius=function(){var m=this._map._container.clientHeight/2,w=this._map.unproject([0,m]),I=this._map.unproject([1,m]),F=w.distanceTo(I),z=Math.ceil(2*this._accuracy/F);this._circleElement.style.width=z+"px",this._circleElement.style.height=z+"px"},A.prototype._onZoom=function(){this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()},A.prototype._onError=function(m){if(this._map){if(this.options.trackUserLocation)if(m.code===1){this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.disabled=!0;var w=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.title=w,this._geolocateButton.setAttribute("aria-label",w),this._geolocationWatchID!==void 0&&this._clearWatch()}else{if(m.code===3&&gl)return;this._setErrorState()}this._watchState!=="OFF"&&this.options.showUserLocation&&this._dotElement.classList.add("mapboxgl-user-location-dot-stale"),this.fire(new n.Event("error",m)),this._finish()}},A.prototype._finish=function(){this._timeoutId&&clearTimeout(this._timeoutId),this._timeoutId=void 0},A.prototype._setupUI=function(m){var w=this;if(this._container.addEventListener("contextmenu",function(z){return z.preventDefault()}),this._geolocateButton=o.create("button","mapboxgl-ctrl-geolocate",this._container),o.create("span","mapboxgl-ctrl-icon",this._geolocateButton).setAttribute("aria-hidden",!0),this._geolocateButton.type="button",m===!1){n.warnOnce("Geolocation support is not available so the GeolocateControl will be disabled.");var I=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.disabled=!0,this._geolocateButton.title=I,this._geolocateButton.setAttribute("aria-label",I)}else{var F=this._map._getUIString("GeolocateControl.FindMyLocation");this._geolocateButton.title=F,this._geolocateButton.setAttribute("aria-label",F)}this.options.trackUserLocation&&(this._geolocateButton.setAttribute("aria-pressed","false"),this._watchState="OFF"),this.options.showUserLocation&&(this._dotElement=o.create("div","mapboxgl-user-location-dot"),this._userLocationDotMarker=new yh(this._dotElement),this._circleElement=o.create("div","mapboxgl-user-location-accuracy-circle"),this._accuracyCircleMarker=new yh({element:this._circleElement,pitchAlignment:"map"}),this.options.trackUserLocation&&(this._watchState="OFF"),this._map.on("zoom",this._onZoom)),this._geolocateButton.addEventListener("click",this.trigger.bind(this)),this._setup=!0,this.options.trackUserLocation&&this._map.on("movestart",function(z){z.geolocateSource||w._watchState!=="ACTIVE_LOCK"||z.originalEvent&&z.originalEvent.type==="resize"||(w._watchState="BACKGROUND",w._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background"),w._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),w.fire(new n.Event("trackuserlocationend")))})},A.prototype.trigger=function(){if(!this._setup)return n.warnOnce("Geolocate control triggered before added to a map"),!1;if(this.options.trackUserLocation){switch(this._watchState){case"OFF":this._watchState="WAITING_ACTIVE",this.fire(new n.Event("trackuserlocationstart"));break;case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":case"BACKGROUND_ERROR":xc--,gl=!1,this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this.fire(new n.Event("trackuserlocationend"));break;case"BACKGROUND":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._lastKnownPosition&&this._updateCamera(this._lastKnownPosition),this.fire(new n.Event("trackuserlocationstart"))}switch(this._watchState){case"WAITING_ACTIVE":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_LOCK":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"BACKGROUND":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background");break;case"BACKGROUND_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error")}if(this._watchState==="OFF"&&this._geolocationWatchID!==void 0)this._clearWatch();else if(this._geolocationWatchID===void 0){var m;this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","true"),++xc>1?(m={maximumAge:6e5,timeout:0},gl=!0):(m=this.options.positionOptions,gl=!1),this._geolocationWatchID=n.window.navigator.geolocation.watchPosition(this._onSuccess,this._onError,m)}}else n.window.navigator.geolocation.getCurrentPosition(this._onSuccess,this._onError,this.options.positionOptions),this._timeoutId=setTimeout(this._finish,1e4);return!0},A.prototype._clearWatch=function(){n.window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0,this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","false"),this.options.showUserLocation&&this._updateMarker(null)},A}(n.Evented),Ts={maxWidth:100,unit:"metric"},Es=function(d){this.options=n.extend({},Ts,d),n.bindAll(["_onMove","setUnit"],this)};function Np(d,A,m){var w=m&&m.maxWidth||100,I=d._container.clientHeight/2,F=d.unproject([0,I]),z=d.unproject([w,I]),W=F.distanceTo(z);if(m&&m.unit==="imperial"){var Q=3.2808*W;Q>5280?yl(A,w,Q/5280,d._getUIString("ScaleControl.Miles")):yl(A,w,Q,d._getUIString("ScaleControl.Feet"))}else m&&m.unit==="nautical"?yl(A,w,W/1852,d._getUIString("ScaleControl.NauticalMiles")):W>=1e3?yl(A,w,W/1e3,d._getUIString("ScaleControl.Kilometers")):yl(A,w,W,d._getUIString("ScaleControl.Meters"))}function yl(d,A,m,w){var I,F,z,W=(I=m,(F=Math.pow(10,(""+Math.floor(I)).length-1))*(z=(z=I/F)>=10?10:z>=5?5:z>=3?3:z>=2?2:z>=1?1:function(Q){var ne=Math.pow(10,Math.ceil(-Math.log(Q)/Math.LN10));return Math.round(Q*ne)/ne}(z)));d.style.width=A*(W/m)+"px",d.innerHTML=W+" "+w}Es.prototype.getDefaultPosition=function(){return"bottom-left"},Es.prototype._onMove=function(){Np(this._map,this._container,this.options)},Es.prototype.onAdd=function(d){return this._map=d,this._container=o.create("div","mapboxgl-ctrl mapboxgl-ctrl-scale",d.getContainer()),this._map.on("move",this._onMove),this._onMove(),this._container},Es.prototype.onRemove=function(){o.remove(this._container),this._map.off("move",this._onMove),this._map=void 0},Es.prototype.setUnit=function(d){this.options.unit=d,Np(this._map,this._container,this.options)};var iu=function(d){this._fullscreen=!1,d&&d.container&&(d.container instanceof n.window.HTMLElement?this._container=d.container:n.warnOnce("Full screen control 'container' must be a DOM element.")),n.bindAll(["_onClickFullscreen","_changeIcon"],this),"onfullscreenchange"in n.window.document?this._fullscreenchange="fullscreenchange":"onmozfullscreenchange"in n.window.document?this._fullscreenchange="mozfullscreenchange":"onwebkitfullscreenchange"in n.window.document?this._fullscreenchange="webkitfullscreenchange":"onmsfullscreenchange"in n.window.document&&(this._fullscreenchange="MSFullscreenChange")};iu.prototype.onAdd=function(d){return this._map=d,this._container||(this._container=this._map.getContainer()),this._controlContainer=o.create("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._checkFullscreenSupport()?this._setupUI():(this._controlContainer.style.display="none",n.warnOnce("This device does not support fullscreen mode.")),this._controlContainer},iu.prototype.onRemove=function(){o.remove(this._controlContainer),this._map=null,n.window.document.removeEventListener(this._fullscreenchange,this._changeIcon)},iu.prototype._checkFullscreenSupport=function(){return!!(n.window.document.fullscreenEnabled||n.window.document.mozFullScreenEnabled||n.window.document.msFullscreenEnabled||n.window.document.webkitFullscreenEnabled)},iu.prototype._setupUI=function(){var d=this._fullscreenButton=o.create("button","mapboxgl-ctrl-fullscreen",this._controlContainer);o.create("span","mapboxgl-ctrl-icon",d).setAttribute("aria-hidden",!0),d.type="button",this._updateTitle(),this._fullscreenButton.addEventListener("click",this._onClickFullscreen),n.window.document.addEventListener(this._fullscreenchange,this._changeIcon)},iu.prototype._updateTitle=function(){var d=this._getTitle();this._fullscreenButton.setAttribute("aria-label",d),this._fullscreenButton.title=d},iu.prototype._getTitle=function(){return this._map._getUIString(this._isFullscreen()?"FullscreenControl.Exit":"FullscreenControl.Enter")},iu.prototype._isFullscreen=function(){return this._fullscreen},iu.prototype._changeIcon=function(){(n.window.document.fullscreenElement||n.window.document.mozFullScreenElement||n.window.document.webkitFullscreenElement||n.window.document.msFullscreenElement)===this._container!==this._fullscreen&&(this._fullscreen=!this._fullscreen,this._fullscreenButton.classList.toggle("mapboxgl-ctrl-shrink"),this._fullscreenButton.classList.toggle("mapboxgl-ctrl-fullscreen"),this._updateTitle())},iu.prototype._onClickFullscreen=function(){this._isFullscreen()?n.window.document.exitFullscreen?n.window.document.exitFullscreen():n.window.document.mozCancelFullScreen?n.window.document.mozCancelFullScreen():n.window.document.msExitFullscreen?n.window.document.msExitFullscreen():n.window.document.webkitCancelFullScreen&&n.window.document.webkitCancelFullScreen():this._container.requestFullscreen?this._container.requestFullscreen():this._container.mozRequestFullScreen?this._container.mozRequestFullScreen():this._container.msRequestFullscreen?this._container.msRequestFullscreen():this._container.webkitRequestFullscreen&&this._container.webkitRequestFullscreen()};var _h={closeButton:!0,closeOnClick:!0,focusAfterOpen:!0,className:"",maxWidth:"240px"},df=["a[href]","[tabindex]:not([tabindex='-1'])","[contenteditable]:not([contenteditable='false'])","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].join(", "),im=function(d){function A(m){d.call(this),this.options=n.extend(Object.create(_h),m),n.bindAll(["_update","_onClose","remove","_onMouseMove","_onMouseUp","_onDrag"],this)}return d&&(A.__proto__=d),(A.prototype=Object.create(d&&d.prototype)).constructor=A,A.prototype.addTo=function(m){return this._map&&this.remove(),this._map=m,this.options.closeOnClick&&this._map.on("click",this._onClose),this.options.closeOnMove&&this._map.on("move",this._onClose),this._map.on("remove",this.remove),this._update(),this._focusFirstElement(),this._trackPointer?(this._map.on("mousemove",this._onMouseMove),this._map.on("mouseup",this._onMouseUp),this._container&&this._container.classList.add("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.add("mapboxgl-track-pointer")):this._map.on("move",this._update),this.fire(new n.Event("open")),this},A.prototype.isOpen=function(){return!!this._map},A.prototype.remove=function(){return this._content&&o.remove(this._content),this._container&&(o.remove(this._container),delete this._container),this._map&&(this._map.off("move",this._update),this._map.off("move",this._onClose),this._map.off("click",this._onClose),this._map.off("remove",this.remove),this._map.off("mousemove",this._onMouseMove),this._map.off("mouseup",this._onMouseUp),this._map.off("drag",this._onDrag),delete this._map),this.fire(new n.Event("close")),this},A.prototype.getLngLat=function(){return this._lngLat},A.prototype.setLngLat=function(m){return this._lngLat=n.LngLat.convert(m),this._pos=null,this._trackPointer=!1,this._update(),this._map&&(this._map.on("move",this._update),this._map.off("mousemove",this._onMouseMove),this._container&&this._container.classList.remove("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.remove("mapboxgl-track-pointer")),this},A.prototype.trackPointer=function(){return this._trackPointer=!0,this._pos=null,this._update(),this._map&&(this._map.off("move",this._update),this._map.on("mousemove",this._onMouseMove),this._map.on("drag",this._onDrag),this._container&&this._container.classList.add("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.add("mapboxgl-track-pointer")),this},A.prototype.getElement=function(){return this._container},A.prototype.setText=function(m){return this.setDOMContent(n.window.document.createTextNode(m))},A.prototype.setHTML=function(m){var w,I=n.window.document.createDocumentFragment(),F=n.window.document.createElement("body");for(F.innerHTML=m;w=F.firstChild;)I.appendChild(w);return this.setDOMContent(I)},A.prototype.getMaxWidth=function(){return this._container&&this._container.style.maxWidth},A.prototype.setMaxWidth=function(m){return this.options.maxWidth=m,this._update(),this},A.prototype.setDOMContent=function(m){if(this._content)for(;this._content.hasChildNodes();)this._content.firstChild&&this._content.removeChild(this._content.firstChild);else this._content=o.create("div","mapboxgl-popup-content",this._container);return this._content.appendChild(m),this._createCloseButton(),this._update(),this._focusFirstElement(),this},A.prototype.addClassName=function(m){this._container&&this._container.classList.add(m)},A.prototype.removeClassName=function(m){this._container&&this._container.classList.remove(m)},A.prototype.setOffset=function(m){return this.options.offset=m,this._update(),this},A.prototype.toggleClassName=function(m){if(this._container)return this._container.classList.toggle(m)},A.prototype._createCloseButton=function(){this.options.closeButton&&(this._closeButton=o.create("button","mapboxgl-popup-close-button",this._content),this._closeButton.type="button",this._closeButton.setAttribute("aria-label","Close popup"),this._closeButton.innerHTML="×",this._closeButton.addEventListener("click",this._onClose))},A.prototype._onMouseUp=function(m){this._update(m.point)},A.prototype._onMouseMove=function(m){this._update(m.point)},A.prototype._onDrag=function(m){this._update(m.point)},A.prototype._update=function(m){var w=this;if(this._map&&(this._lngLat||this._trackPointer)&&this._content&&(this._container||(this._container=o.create("div","mapboxgl-popup",this._map.getContainer()),this._tip=o.create("div","mapboxgl-popup-tip",this._container),this._container.appendChild(this._content),this.options.className&&this.options.className.split(" ").forEach(function(Ae){return w._container.classList.add(Ae)}),this._trackPointer&&this._container.classList.add("mapboxgl-popup-track-pointer")),this.options.maxWidth&&this._container.style.maxWidth!==this.options.maxWidth&&(this._container.style.maxWidth=this.options.maxWidth),this._map.transform.renderWorldCopies&&!this._trackPointer&&(this._lngLat=Dl(this._lngLat,this._pos,this._map.transform)),!this._trackPointer||m)){var I=this._pos=this._trackPointer&&m?m:this._map.project(this._lngLat),F=this.options.anchor,z=function Ae(ye){if(ye){if(typeof ye=="number"){var Ce=Math.round(Math.sqrt(.5*Math.pow(ye,2)));return{center:new n.Point(0,0),top:new n.Point(0,ye),"top-left":new n.Point(Ce,Ce),"top-right":new n.Point(-Ce,Ce),bottom:new n.Point(0,-ye),"bottom-left":new n.Point(Ce,-Ce),"bottom-right":new n.Point(-Ce,-Ce),left:new n.Point(ye,0),right:new n.Point(-ye,0)}}if(ye instanceof n.Point||Array.isArray(ye)){var Se=n.Point.convert(ye);return{center:Se,top:Se,"top-left":Se,"top-right":Se,bottom:Se,"bottom-left":Se,"bottom-right":Se,left:Se,right:Se}}return{center:n.Point.convert(ye.center||[0,0]),top:n.Point.convert(ye.top||[0,0]),"top-left":n.Point.convert(ye["top-left"]||[0,0]),"top-right":n.Point.convert(ye["top-right"]||[0,0]),bottom:n.Point.convert(ye.bottom||[0,0]),"bottom-left":n.Point.convert(ye["bottom-left"]||[0,0]),"bottom-right":n.Point.convert(ye["bottom-right"]||[0,0]),left:n.Point.convert(ye.left||[0,0]),right:n.Point.convert(ye.right||[0,0])}}return Ae(new n.Point(0,0))}(this.options.offset);if(!F){var W,Q=this._container.offsetWidth,ne=this._container.offsetHeight;W=I.y+z.bottom.y<ne?["top"]:I.y>this._map.transform.height-ne?["bottom"]:[],I.x<Q/2?W.push("left"):I.x>this._map.transform.width-Q/2&&W.push("right"),F=W.length===0?"bottom":W.join("-")}var pe=I.add(z[F]).round();o.setTransform(this._container,Mo[F]+" translate("+pe.x+"px,"+pe.y+"px)"),Fp(this._container,F,"popup")}},A.prototype._focusFirstElement=function(){if(this.options.focusAfterOpen&&this._container){var m=this._container.querySelector(df);m&&m.focus()}},A.prototype._onClose=function(){this.remove()},A}(n.Evented),zp={version:n.version,supported:a,setRTLTextPlugin:n.setRTLTextPlugin,getRTLTextPluginStatus:n.getRTLTextPluginStatus,Map:aA,NavigationControl:Al,GeolocateControl:bc,AttributionControl:Ko,ScaleControl:Es,FullscreenControl:iu,Popup:im,Marker:yh,Style:Ns,LngLat:n.LngLat,LngLatBounds:n.LngLatBounds,Point:n.Point,MercatorCoordinate:n.MercatorCoordinate,Evented:n.Evented,config:n.config,prewarm:function(){At().acquire(dt)},clearPrewarmedResources:function(){var d=hr;d&&(d.isPreloaded()&&d.numActive()===1?(d.release(dt),hr=null):console.warn("Could not clear WebWorkers since there are active Map instances that still reference it. The pre-warmed WebWorker pool can only be cleared when all map instances have been removed with map.remove()"))},get accessToken(){return n.config.ACCESS_TOKEN},set accessToken(d){n.config.ACCESS_TOKEN=d},get baseApiUrl(){return n.config.API_URL},set baseApiUrl(d){n.config.API_URL=d},get workerCount(){return Ct.workerCount},set workerCount(d){Ct.workerCount=d},get maxParallelImageRequests(){return n.config.MAX_PARALLEL_IMAGE_REQUESTS},set maxParallelImageRequests(d){n.config.MAX_PARALLEL_IMAGE_REQUESTS=d},clearStorage:function(d){n.clearTileCache(d)},workerUrl:""};return zp}),e})});var S9=Jr((_tt,E9)=>{var LEe=Mt();function kEe(t,r){for(;!Object.prototype.hasOwnProperty.call(t,r)&&(t=LEe(t),t!==null););return t}E9.exports=kEe});var bn=Jr((xtt,ew)=>{var BEe=S9();function $2(t,r,e){return typeof Reflect<"u"&&Reflect.get?ew.exports=$2=Reflect.get:ew.exports=$2=function(n,a,o){var s=BEe(n,a);if(s){var u=Object.getOwnPropertyDescriptor(s,a);return u.get?u.get.call(o):u.value}},$2(t,r,e||t)}ew.exports=$2});var jK=Jr((tdt,VT)=>{(function(t,r,e,i){"use strict";var n=["","webkit","Moz","MS","ms","o"],a=r.createElement("div"),o="function",s=Math.round,u=Math.abs,c=Date.now;function h(he,xe,Ne){return setTimeout(V(he,Ne),xe)}function v(he,xe,Ne){return Array.isArray(he)?(b(he,Ne[xe],Ne),!0):!1}function b(he,xe,Ne){var ft;if(he)if(he.forEach)he.forEach(xe,Ne);else if(he.length!==i)for(ft=0;ft<he.length;)xe.call(Ne,he[ft],ft,he),ft++;else for(ft in he)he.hasOwnProperty(ft)&&xe.call(Ne,he[ft],ft,he)}function S(he,xe,Ne){var ft="DEPRECATED METHOD: "+xe+`
|
|
506
506
|
`+Ne+` AT
|
|
507
|
-
`;return function(){var jt=new Error("get-stack-trace"),Mr=jt&&jt.stack?jt.stack.replace(/^[^\(]+?[\n$]/gm,"").replace(/^\s+at\s+/gm,"").replace(/^Object.<anonymous>\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",Rn=t.console&&(t.console.warn||t.console.log);return Rn&&Rn.call(t.console,ft,Mr),he.apply(this,arguments)}}var M;typeof Object.assign!="function"?M=function(xe){if(xe===i||xe===null)throw new TypeError("Cannot convert undefined or null to object");for(var Ne=Object(xe),ft=1;ft<arguments.length;ft++){var jt=arguments[ft];if(jt!==i&&jt!==null)for(var Mr in jt)jt.hasOwnProperty(Mr)&&(Ne[Mr]=jt[Mr])}return Ne}:M=Object.assign;var k=S(function(xe,Ne,ft){for(var jt=Object.keys(Ne),Mr=0;Mr<jt.length;)(!ft||ft&&xe[jt[Mr]]===i)&&(xe[jt[Mr]]=Ne[jt[Mr]]),Mr++;return xe},"extend","Use `assign`."),N=S(function(xe,Ne){return k(xe,Ne,!0)},"merge","Use `assign`.");function j(he,xe,Ne){var ft=xe.prototype,jt;jt=he.prototype=Object.create(ft),jt.constructor=he,jt._super=ft,Ne&&M(jt,Ne)}function V(he,xe){return function(){return he.apply(xe,arguments)}}function H(he,xe){return typeof he==o?he.apply(xe&&xe[0]||i,xe):he}function X(he,xe){return he===i?xe:he}function Y(he,xe,Ne){b(le(xe),function(ft){he.addEventListener(ft,Ne,!1)})}function te(he,xe,Ne){b(le(xe),function(ft){he.removeEventListener(ft,Ne,!1)})}function se(he,xe){for(;he;){if(he==xe)return!0;he=he.parentNode}return!1}function ie(he,xe){return he.indexOf(xe)>-1}function le(he){return he.trim().split(/\s+/g)}function re(he,xe,Ne){if(he.indexOf&&!Ne)return he.indexOf(xe);for(var ft=0;ft<he.length;){if(Ne&&he[ft][Ne]==xe||!Ne&&he[ft]===xe)return ft;ft++}return-1}function we(he){return Array.prototype.slice.call(he,0)}function be(he,xe,Ne){for(var ft=[],jt=[],Mr=0;Mr<he.length;){var Rn=xe?he[Mr][xe]:he[Mr];re(jt,Rn)<0&&ft.push(he[Mr]),jt[Mr]=Rn,Mr++}return Ne&&(xe?ft=ft.sort(function(ro,Xo){return ro[xe]>Xo[xe]}):ft=ft.sort()),ft}function ze(he,xe){for(var Ne,ft,jt=xe[0].toUpperCase()+xe.slice(1),Mr=0;Mr<n.length;){if(Ne=n[Mr],ft=Ne?Ne+jt:xe,ft in he)return ft;Mr++}return i}var Fe=1;function Me(){return Fe++}function Ve(he){var xe=he.ownerDocument||he;return xe.defaultView||xe.parentWindow||t}var He=/mobile|tablet|ip(ad|hone|od)|android/i,ot="ontouchstart"in t,Je=ze(t,"PointerEvent")!==i,wt=ot&&He.test(navigator.userAgent),xt="touch",zt="pen",yt="mouse",pt="kinect",Pr=25,ar=1,or=2,fr=4,Gn=8,oi=1,wr=2,Qa=4,qi=8,Yn=16,Nn=wr|Qa,Xi=qi|Yn,Va=Nn|Xi,Ri=["x","y"],Wo=["clientX","clientY"];function ha(he,xe){var Ne=this;this.manager=he,this.callback=xe,this.element=he.element,this.target=he.options.inputTarget,this.domHandler=function(ft){H(he.options.enable,[he])&&Ne.handler(ft)},this.init()}ha.prototype={handler:function(){},init:function(){this.evEl&&Y(this.element,this.evEl,this.domHandler),this.evTarget&&Y(this.target,this.evTarget,this.domHandler),this.evWin&&Y(Ve(this.element),this.evWin,this.domHandler)},destroy:function(){this.evEl&&te(this.element,this.evEl,this.domHandler),this.evTarget&&te(this.target,this.evTarget,this.domHandler),this.evWin&&te(Ve(this.element),this.evWin,this.domHandler)}};function zi(he){var xe,Ne=he.options.inputClass;return Ne?xe=Ne:Je?xe=cl:wt?xe=Ze:ot?xe=St:xe=Nu,new xe(he,pa)}function pa(he,xe,Ne){var ft=Ne.pointers.length,jt=Ne.changedPointers.length,Mr=xe&ar&&ft-jt===0,Rn=xe&(fr|Gn)&&ft-jt===0;Ne.isFirst=!!Mr,Ne.isFinal=!!Rn,Mr&&(he.session={}),Ne.eventType=xe,Ja(he,Ne),he.emit("hammer.input",Ne),he.recognize(Ne),he.session.prevInput=Ne}function Ja(he,xe){var Ne=he.session,ft=xe.pointers,jt=ft.length;Ne.firstInput||(Ne.firstInput=yr(xe)),jt>1&&!Ne.firstMultiple?Ne.firstMultiple=yr(xe):jt===1&&(Ne.firstMultiple=!1);var Mr=Ne.firstInput,Rn=Ne.firstMultiple,to=Rn?Rn.center:Mr.center,ro=xe.center=Qr(ft);xe.timeStamp=c(),xe.deltaTime=xe.timeStamp-Mr.timeStamp,xe.angle=Ha(to,ro),xe.distance=Ra(to,ro),go(Ne,xe),xe.offsetDirection=Kn(xe.deltaX,xe.deltaY);var Xo=li(xe.deltaTime,xe.deltaX,xe.deltaY);xe.overallVelocityX=Xo.x,xe.overallVelocityY=Xo.y,xe.overallVelocity=u(Xo.x)>u(Xo.y)?Xo.x:Xo.y,xe.scale=Rn?So(Rn.pointers,ft):1,xe.rotation=Rn?Fs(Rn.pointers,ft):0,xe.maxPointers=Ne.prevInput?xe.pointers.length>Ne.prevInput.maxPointers?xe.pointers.length:Ne.prevInput.maxPointers:xe.pointers.length,vr(Ne,xe);var Js=he.element;se(xe.srcEvent.target,Js)&&(Js=xe.srcEvent.target),xe.target=Js}function go(he,xe){var Ne=xe.center,ft=he.offsetDelta||{},jt=he.prevDelta||{},Mr=he.prevInput||{};(xe.eventType===ar||Mr.eventType===fr)&&(jt=he.prevDelta={x:Mr.deltaX||0,y:Mr.deltaY||0},ft=he.offsetDelta={x:Ne.x,y:Ne.y}),xe.deltaX=jt.x+(Ne.x-ft.x),xe.deltaY=jt.y+(Ne.y-ft.y)}function vr(he,xe){var Ne=he.lastInterval||xe,ft=xe.timeStamp-Ne.timeStamp,jt,Mr,Rn,to;if(xe.eventType!=Gn&&(ft>Pr||Ne.velocity===i)){var ro=xe.deltaX-Ne.deltaX,Xo=xe.deltaY-Ne.deltaY,Js=li(ft,ro,Xo);Mr=Js.x,Rn=Js.y,jt=u(Js.x)>u(Js.y)?Js.x:Js.y,to=Kn(ro,Xo),he.lastInterval=xe}else jt=Ne.velocity,Mr=Ne.velocityX,Rn=Ne.velocityY,to=Ne.direction;xe.velocity=jt,xe.velocityX=Mr,xe.velocityY=Rn,xe.direction=to}function yr(he){for(var xe=[],Ne=0;Ne<he.pointers.length;)xe[Ne]={clientX:s(he.pointers[Ne].clientX),clientY:s(he.pointers[Ne].clientY)},Ne++;return{timeStamp:c(),pointers:xe,center:Qr(xe),deltaX:he.deltaX,deltaY:he.deltaY}}function Qr(he){var xe=he.length;if(xe===1)return{x:s(he[0].clientX),y:s(he[0].clientY)};for(var Ne=0,ft=0,jt=0;jt<xe;)Ne+=he[jt].clientX,ft+=he[jt].clientY,jt++;return{x:s(Ne/xe),y:s(ft/xe)}}function li(he,xe,Ne){return{x:xe/he||0,y:Ne/he||0}}function Kn(he,xe){return he===xe?oi:u(he)>=u(xe)?he<0?wr:Qa:xe<0?qi:Yn}function Ra(he,xe,Ne){Ne||(Ne=Ri);var ft=xe[Ne[0]]-he[Ne[0]],jt=xe[Ne[1]]-he[Ne[1]];return Math.sqrt(ft*ft+jt*jt)}function Ha(he,xe,Ne){Ne||(Ne=Ri);var ft=xe[Ne[0]]-he[Ne[0]],jt=xe[Ne[1]]-he[Ne[1]];return Math.atan2(jt,ft)*180/Math.PI}function Fs(he,xe){return Ha(xe[1],xe[0],Wo)+Ha(he[1],he[0],Wo)}function So(he,xe){return Ra(xe[0],xe[1],Wo)/Ra(he[0],he[1],Wo)}var Rl={mousedown:ar,mousemove:or,mouseup:fr},uc="mousedown",tf="mousemove mouseup";function Nu(){this.evEl=uc,this.evWin=tf,this.pressed=!1,ha.apply(this,arguments)}j(Nu,ha,{handler:function(xe){var Ne=Rl[xe.type];Ne&ar&&xe.button===0&&(this.pressed=!0),Ne&or&&xe.which!==1&&(Ne=fr),this.pressed&&(Ne&fr&&(this.pressed=!1),this.callback(this.manager,Ne,{pointers:[xe],changedPointers:[xe],pointerType:yt,srcEvent:xe}))}});var ll={pointerdown:ar,pointermove:or,pointerup:fr,pointercancel:Gn,pointerout:Gn},hu={2:xt,3:zt,4:yt,5:pt},Ks="pointerdown",zu="pointermove pointerup pointercancel";t.MSPointerEvent&&!t.PointerEvent&&(Ks="MSPointerDown",zu="MSPointerMove MSPointerUp MSPointerCancel");function cl(){this.evEl=Ks,this.evWin=zu,ha.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}j(cl,ha,{handler:function(xe){var Ne=this.store,ft=!1,jt=xe.type.toLowerCase().replace("ms",""),Mr=ll[jt],Rn=hu[xe.pointerType]||xe.pointerType,to=Rn==xt,ro=re(Ne,xe.pointerId,"pointerId");Mr&ar&&(xe.button===0||to)?ro<0&&(Ne.push(xe),ro=Ne.length-1):Mr&(fr|Gn)&&(ft=!0),!(ro<0)&&(Ne[ro]=xe,this.callback(this.manager,Mr,{pointers:Ne,changedPointers:[xe],pointerType:Rn,srcEvent:xe}),ft&&Ne.splice(ro,1))}});var Zi={touchstart:ar,touchmove:or,touchend:fr,touchcancel:Gn},ee="touchstart",oe="touchstart touchmove touchend touchcancel";function fe(){this.evTarget=ee,this.evWin=oe,this.started=!1,ha.apply(this,arguments)}j(fe,ha,{handler:function(xe){var Ne=Zi[xe.type];if(Ne===ar&&(this.started=!0),!!this.started){var ft=_e.call(this,xe,Ne);Ne&(fr|Gn)&&ft[0].length-ft[1].length===0&&(this.started=!1),this.callback(this.manager,Ne,{pointers:ft[0],changedPointers:ft[1],pointerType:xt,srcEvent:xe})}}});function _e(he,xe){var Ne=we(he.touches),ft=we(he.changedTouches);return xe&(fr|Gn)&&(Ne=be(Ne.concat(ft),"identifier",!0)),[Ne,ft]}var me={touchstart:ar,touchmove:or,touchend:fr,touchcancel:Gn},je="touchstart touchmove touchend touchcancel";function Ze(){this.evTarget=je,this.targetIds={},ha.apply(this,arguments)}j(Ze,ha,{handler:function(xe){var Ne=me[xe.type],ft=ge.call(this,xe,Ne);ft&&this.callback(this.manager,Ne,{pointers:ft[0],changedPointers:ft[1],pointerType:xt,srcEvent:xe})}});function ge(he,xe){var Ne=we(he.touches),ft=this.targetIds;if(xe&(ar|or)&&Ne.length===1)return ft[Ne[0].identifier]=!0,[Ne,Ne];var jt,Mr,Rn=we(he.changedTouches),to=[],ro=this.target;if(Mr=Ne.filter(function(Xo){return se(Xo.target,ro)}),xe===ar)for(jt=0;jt<Mr.length;)ft[Mr[jt].identifier]=!0,jt++;for(jt=0;jt<Rn.length;)ft[Rn[jt].identifier]&&to.push(Rn[jt]),xe&(fr|Gn)&&delete ft[Rn[jt].identifier],jt++;if(to.length)return[be(Mr.concat(to),"identifier",!0),to]}var Oe=2500,nt=25;function St(){ha.apply(this,arguments);var he=V(this.handler,this);this.touch=new Ze(this.manager,he),this.mouse=new Nu(this.manager,he),this.primaryTouch=null,this.lastTouches=[]}j(St,ha,{handler:function(xe,Ne,ft){var jt=ft.pointerType==xt,Mr=ft.pointerType==yt;if(!(Mr&&ft.sourceCapabilities&&ft.sourceCapabilities.firesTouchEvents)){if(jt)Ot.call(this,Ne,ft);else if(Mr&&Ct.call(this,ft))return;this.callback(xe,Ne,ft)}},destroy:function(){this.touch.destroy(),this.mouse.destroy()}});function Ot(he,xe){he&ar?(this.primaryTouch=xe.changedPointers[0].identifier,dt.call(this,xe)):he&(fr|Gn)&&dt.call(this,xe)}function dt(he){var xe=he.changedPointers[0];if(xe.identifier===this.primaryTouch){var Ne={x:xe.clientX,y:xe.clientY};this.lastTouches.push(Ne);var ft=this.lastTouches,jt=function(){var Mr=ft.indexOf(Ne);Mr>-1&&ft.splice(Mr,1)};setTimeout(jt,Oe)}}function Ct(he){for(var xe=he.srcEvent.clientX,Ne=he.srcEvent.clientY,ft=0;ft<this.lastTouches.length;ft++){var jt=this.lastTouches[ft],Mr=Math.abs(xe-jt.x),Rn=Math.abs(Ne-jt.y);if(Mr<=nt&&Rn<=nt)return!0}return!1}var hr=ze(a.style,"touchAction"),sr=hr!==i,At="compute",Jt="auto",Gt="manipulation",Ut="none",tn="pan-x",Xt="pan-y",An=Vn();function ri(he,xe){this.manager=he,this.set(xe)}ri.prototype={set:function(he){he==At&&(he=this.compute()),sr&&this.manager.element.style&&An[he]&&(this.manager.element.style[hr]=he),this.actions=he.toLowerCase().trim()},update:function(){this.set(this.manager.options.touchAction)},compute:function(){var he=[];return b(this.manager.recognizers,function(xe){H(xe.options.enable,[xe])&&(he=he.concat(xe.getTouchAction()))}),gn(he.join(" "))},preventDefaults:function(he){var xe=he.srcEvent,Ne=he.offsetDirection;if(this.manager.session.prevented){xe.preventDefault();return}var ft=this.actions,jt=ie(ft,Ut)&&!An[Ut],Mr=ie(ft,Xt)&&!An[Xt],Rn=ie(ft,tn)&&!An[tn];if(jt){var to=he.pointers.length===1,ro=he.distance<2,Xo=he.deltaTime<250;if(to&&ro&&Xo)return}if(!(Rn&&Mr)&&(jt||Mr&&Ne&Nn||Rn&&Ne&Xi))return this.preventSrc(xe)},preventSrc:function(he){this.manager.session.prevented=!0,he.preventDefault()}};function gn(he){if(ie(he,Ut))return Ut;var xe=ie(he,tn),Ne=ie(he,Xt);return xe&&Ne?Ut:xe||Ne?xe?tn:Xt:ie(he,Gt)?Gt:Jt}function Vn(){if(!sr)return!1;var he={},xe=t.CSS&&t.CSS.supports;return["auto","manipulation","pan-y","pan-x","pan-x pan-y","none"].forEach(function(Ne){he[Ne]=xe?t.CSS.supports("touch-action",Ne):!0}),he}var _n=1,Ii=2,In=4,fi=8,Pn=fi,hn=16,dn=32;function aa(he){this.options=M({},this.defaults,he||{}),this.id=Me(),this.manager=null,this.options.enable=X(this.options.enable,!0),this.state=_n,this.simultaneous={},this.requireFail=[]}aa.prototype={defaults:{},set:function(he){return M(this.options,he),this.manager&&this.manager.touchAction.update(),this},recognizeWith:function(he){if(v(he,"recognizeWith",this))return this;var xe=this.simultaneous;return he=$a(he,this),xe[he.id]||(xe[he.id]=he,he.recognizeWith(this)),this},dropRecognizeWith:function(he){return v(he,"dropRecognizeWith",this)?this:(he=$a(he,this),delete this.simultaneous[he.id],this)},requireFailure:function(he){if(v(he,"requireFailure",this))return this;var xe=this.requireFail;return he=$a(he,this),re(xe,he)===-1&&(xe.push(he),he.requireFailure(this)),this},dropRequireFailure:function(he){if(v(he,"dropRequireFailure",this))return this;he=$a(he,this);var xe=re(this.requireFail,he);return xe>-1&&this.requireFail.splice(xe,1),this},hasRequireFailures:function(){return this.requireFail.length>0},canRecognizeWith:function(he){return!!this.simultaneous[he.id]},emit:function(he){var xe=this,Ne=this.state;function ft(jt){xe.manager.emit(jt,he)}Ne<fi&&ft(xe.options.event+lc(Ne)),ft(xe.options.event),he.additionalEvent&&ft(he.additionalEvent),Ne>=fi&&ft(xe.options.event+lc(Ne))},tryEmit:function(he){if(this.canEmit())return this.emit(he);this.state=dn},canEmit:function(){for(var he=0;he<this.requireFail.length;){if(!(this.requireFail[he].state&(dn|_n)))return!1;he++}return!0},recognize:function(he){var xe=M({},he);if(!H(this.options.enable,[this,xe])){this.reset(),this.state=dn;return}this.state&(Pn|hn|dn)&&(this.state=_n),this.state=this.process(xe),this.state&(Ii|In|fi|hn)&&this.tryEmit(xe)},process:function(he){},getTouchAction:function(){},reset:function(){}};function lc(he){return he&hn?"cancel":he&fi?"end":he&In?"move":he&Ii?"start":""}function La(he){return he==Yn?"down":he==qi?"up":he==wr?"left":he==Qa?"right":""}function $a(he,xe){var Ne=xe.manager;return Ne?Ne.get(he):he}function _s(){aa.apply(this,arguments)}j(_s,aa,{defaults:{pointers:1},attrTest:function(he){var xe=this.options.pointers;return xe===0||he.pointers.length===xe},process:function(he){var xe=this.state,Ne=he.eventType,ft=xe&(Ii|In),jt=this.attrTest(he);return ft&&(Ne&Gn||!jt)?xe|hn:ft||jt?Ne&fr?xe|fi:xe&Ii?xe|In:Ii:dn}});function fl(){_s.apply(this,arguments),this.pX=null,this.pY=null}j(fl,_s,{defaults:{event:"pan",threshold:10,pointers:1,direction:Va},getTouchAction:function(){var he=this.options.direction,xe=[];return he&Nn&&xe.push(Xt),he&Xi&&xe.push(tn),xe},directionTest:function(he){var xe=this.options,Ne=!0,ft=he.distance,jt=he.direction,Mr=he.deltaX,Rn=he.deltaY;return jt&xe.direction||(xe.direction&Nn?(jt=Mr===0?oi:Mr<0?wr:Qa,Ne=Mr!=this.pX,ft=Math.abs(he.deltaX)):(jt=Rn===0?oi:Rn<0?qi:Yn,Ne=Rn!=this.pY,ft=Math.abs(he.deltaY))),he.direction=jt,Ne&&ft>xe.threshold&&jt&xe.direction},attrTest:function(he){return _s.prototype.attrTest.call(this,he)&&(this.state&Ii||!(this.state&Ii)&&this.directionTest(he))},emit:function(he){this.pX=he.deltaX,this.pY=he.deltaY;var xe=La(he.direction);xe&&(he.additionalEvent=this.options.event+xe),this._super.emit.call(this,he)}});function Ui(){_s.apply(this,arguments)}j(Ui,_s,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[Ut]},attrTest:function(he){return this._super.attrTest.call(this,he)&&(Math.abs(he.scale-1)>this.options.threshold||this.state&Ii)},emit:function(he){if(he.scale!==1){var xe=he.scale<1?"in":"out";he.additionalEvent=this.options.event+xe}this._super.emit.call(this,he)}});function Ll(){aa.apply(this,arguments),this._timer=null,this._input=null}j(Ll,aa,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return[Jt]},process:function(he){var xe=this.options,Ne=he.pointers.length===xe.pointers,ft=he.distance<xe.threshold,jt=he.deltaTime>xe.time;if(this._input=he,!ft||!Ne||he.eventType&(fr|Gn)&&!jt)this.reset();else if(he.eventType&ar)this.reset(),this._timer=h(function(){this.state=Pn,this.tryEmit()},xe.time,this);else if(he.eventType&fr)return Pn;return dn},reset:function(){clearTimeout(this._timer)},emit:function(he){this.state===Pn&&(he&&he.eventType&fr?this.manager.emit(this.options.event+"up",he):(this._input.timeStamp=c(),this.manager.emit(this.options.event,this._input)))}});function eo(){_s.apply(this,arguments)}j(eo,_s,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[Ut]},attrTest:function(he){return this._super.attrTest.call(this,he)&&(Math.abs(he.rotation)>this.options.threshold||this.state&Ii)}});function Ea(){_s.apply(this,arguments)}j(Ea,_s,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:Nn|Xi,pointers:1},getTouchAction:function(){return fl.prototype.getTouchAction.call(this)},attrTest:function(he){var xe=this.options.direction,Ne;return xe&(Nn|Xi)?Ne=he.overallVelocity:xe&Nn?Ne=he.overallVelocityX:xe&Xi&&(Ne=he.overallVelocityY),this._super.attrTest.call(this,he)&&xe&he.offsetDirection&&he.distance>this.options.threshold&&he.maxPointers==this.options.pointers&&u(Ne)>this.options.velocity&&he.eventType&fr},emit:function(he){var xe=La(he.offsetDirection);xe&&this.manager.emit(this.options.event+xe,he),this.manager.emit(this.options.event,he)}});function qo(){aa.apply(this,arguments),this.pTime=!1,this.pCenter=!1,this._timer=null,this._input=null,this.count=0}j(qo,aa,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[Gt]},process:function(he){var xe=this.options,Ne=he.pointers.length===xe.pointers,ft=he.distance<xe.threshold,jt=he.deltaTime<xe.time;if(this.reset(),he.eventType&ar&&this.count===0)return this.failTimeout();if(ft&&jt&&Ne){if(he.eventType!=fr)return this.failTimeout();var Mr=this.pTime?he.timeStamp-this.pTime<xe.interval:!0,Rn=!this.pCenter||Ra(this.pCenter,he.center)<xe.posThreshold;this.pTime=he.timeStamp,this.pCenter=he.center,!Rn||!Mr?this.count=1:this.count+=1,this._input=he;var to=this.count%xe.taps;if(to===0)return this.hasRequireFailures()?(this._timer=h(function(){this.state=Pn,this.tryEmit()},xe.interval,this),Ii):Pn}return dn},failTimeout:function(){return this._timer=h(function(){this.state=dn},this.options.interval,this),dn},reset:function(){clearTimeout(this._timer)},emit:function(){this.state==Pn&&(this._input.tapCount=this.count,this.manager.emit(this.options.event,this._input))}});function Qn(he,xe){return xe=xe||{},xe.recognizers=X(xe.recognizers,Qn.defaults.preset),new ah(he,xe)}Qn.VERSION="2.0.7",Qn.defaults={domEvents:!1,touchAction:At,enable:!0,inputTarget:null,inputClass:null,preset:[[eo,{enable:!1}],[Ui,{enable:!1},["rotate"]],[Ea,{direction:Nn}],[fl,{direction:Nn},["swipe"]],[qo],[qo,{event:"doubletap",taps:2},["tap"]],[Ll]],cssProps:{userSelect:"none",touchSelect:"none",touchCallout:"none",contentZooming:"none",userDrag:"none",tapHighlightColor:"rgba(0,0,0,0)"}};var Qs=1,ts=2;function ah(he,xe){this.options=M({},Qn.defaults,xe||{}),this.options.inputTarget=this.options.inputTarget||he,this.handlers={},this.session={},this.recognizers=[],this.oldCssProps={},this.element=he,this.input=zi(this),this.touchAction=new ri(this,this.options.touchAction),xs(this,!0),b(this.options.recognizers,function(Ne){var ft=this.add(new Ne[0](Ne[1]));Ne[2]&&ft.recognizeWith(Ne[2]),Ne[3]&&ft.requireFailure(Ne[3])},this)}ah.prototype={set:function(he){return M(this.options,he),he.touchAction&&this.touchAction.update(),he.inputTarget&&(this.input.destroy(),this.input.target=he.inputTarget,this.input.init()),this},stop:function(he){this.session.stopped=he?ts:Qs},recognize:function(he){var xe=this.session;if(!xe.stopped){this.touchAction.preventDefaults(he);var Ne,ft=this.recognizers,jt=xe.curRecognizer;(!jt||jt&&jt.state&Pn)&&(jt=xe.curRecognizer=null);for(var Mr=0;Mr<ft.length;)Ne=ft[Mr],xe.stopped!==ts&&(!jt||Ne==jt||Ne.canRecognizeWith(jt))?Ne.recognize(he):Ne.reset(),!jt&&Ne.state&(Ii|In|fi)&&(jt=xe.curRecognizer=Ne),Mr++}},get:function(he){if(he instanceof aa)return he;for(var xe=this.recognizers,Ne=0;Ne<xe.length;Ne++)if(xe[Ne].options.event==he)return xe[Ne];return null},add:function(he){if(v(he,"add",this))return this;var xe=this.get(he.options.event);return xe&&this.remove(xe),this.recognizers.push(he),he.manager=this,this.touchAction.update(),he},remove:function(he){if(v(he,"remove",this))return this;if(he=this.get(he),he){var xe=this.recognizers,Ne=re(xe,he);Ne!==-1&&(xe.splice(Ne,1),this.touchAction.update())}return this},on:function(he,xe){if(he!==i&&xe!==i){var Ne=this.handlers;return b(le(he),function(ft){Ne[ft]=Ne[ft]||[],Ne[ft].push(xe)}),this}},off:function(he,xe){if(he!==i){var Ne=this.handlers;return b(le(he),function(ft){xe?Ne[ft]&&Ne[ft].splice(re(Ne[ft],xe),1):delete Ne[ft]}),this}},emit:function(he,xe){this.options.domEvents&&Wv(he,xe);var Ne=this.handlers[he]&&this.handlers[he].slice();if(!(!Ne||!Ne.length)){xe.type=he,xe.preventDefault=function(){xe.srcEvent.preventDefault()};for(var ft=0;ft<Ne.length;)Ne[ft](xe),ft++}},destroy:function(){this.element&&xs(this,!1),this.handlers={},this.session={},this.input.destroy(),this.element=null}};function xs(he,xe){var Ne=he.element;if(Ne.style){var ft;b(he.options.cssProps,function(jt,Mr){ft=ze(Ne.style,Mr),xe?(he.oldCssProps[ft]=Ne.style[ft],Ne.style[ft]=jt):Ne.style[ft]=he.oldCssProps[ft]||""}),xe||(he.oldCssProps={})}}function Wv(he,xe){var Ne=r.createEvent("Event");Ne.initEvent(he,!0,!0),Ne.gesture=xe,xe.target.dispatchEvent(Ne)}M(Qn,{INPUT_START:ar,INPUT_MOVE:or,INPUT_END:fr,INPUT_CANCEL:Gn,STATE_POSSIBLE:_n,STATE_BEGAN:Ii,STATE_CHANGED:In,STATE_ENDED:fi,STATE_RECOGNIZED:Pn,STATE_CANCELLED:hn,STATE_FAILED:dn,DIRECTION_NONE:oi,DIRECTION_LEFT:wr,DIRECTION_RIGHT:Qa,DIRECTION_UP:qi,DIRECTION_DOWN:Yn,DIRECTION_HORIZONTAL:Nn,DIRECTION_VERTICAL:Xi,DIRECTION_ALL:Va,Manager:ah,Input:ha,TouchAction:ri,TouchInput:Ze,MouseInput:Nu,PointerEventInput:cl,TouchMouseInput:St,SingleTouchInput:fe,Recognizer:aa,AttrRecognizer:_s,Tap:qo,Pan:fl,Swipe:Ea,Pinch:Ui,Rotate:eo,Press:Ll,on:Y,off:te,each:b,merge:N,extend:k,assign:M,inherit:j,bindFn:V,prefixed:ze});var Uu=typeof t<"u"?t:typeof self<"u"?self:{};Uu.Hammer=Qn,typeof define=="function"&&define.amd?define(function(){return Qn}):typeof VT<"u"&&VT.exports?VT.exports=Qn:t[e]=Qn})(window,document,"Hammer")});var xte=Jr((e0t,_te)=>{function ake(t,r){if(t==null)return{};var e={},i=Object.keys(t),n,a;for(a=0;a<i.length;a++)n=i[a],!(r.indexOf(n)>=0)&&(e[n]=t[n]);return e}_te.exports=ake});var Ck=Jr((t0t,bte)=>{var oke=xte();function ske(t,r){if(t==null)return{};var e=oke(t,r),i,n;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(n=0;n<a.length;n++)i=a[n],!(r.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(e[i]=t[i])}return e}bte.exports=ske});var iie=Jr((y_t,rB)=>{"use strict";rB.exports=WE;rB.exports.default=WE;function WE(t,r,e){e=e||2;var i=r&&r.length,n=i?r[0]*e:t.length,a=tie(t,0,n,e,!0),o=[];if(!a||a.next===a.prev)return o;var s,u,c,h,v,b,S;if(i&&(a=jBe(t,r,a,e)),t.length>80*e){s=c=t[0],u=h=t[1];for(var M=e;M<n;M+=e)v=t[M],b=t[M+1],v<s&&(s=v),b<u&&(u=b),v>c&&(c=v),b>h&&(h=b);S=Math.max(c-s,h-u),S=S!==0?32767/S:0}return ex(a,o,e,s,u,S,0),o}function tie(t,r,e,i,n){var a,o;if(n===tB(t,r,e,i)>0)for(a=r;a<e;a+=i)o=eie(a,t[a],t[a+1],o);else for(a=e-i;a>=r;a-=i)o=eie(a,t[a],t[a+1],o);return o&&qE(o,o.next)&&(rx(o),o=o.next),o}function Km(t,r){if(!t)return t;r||(r=t);var e=t,i;do if(i=!1,!e.steiner&&(qE(e,e.next)||mo(e.prev,e,e.next)===0)){if(rx(e),e=r=e.prev,e===e.next)break;i=!0}else e=e.next;while(i||e!==r);return r}function ex(t,r,e,i,n,a,o){if(t){!o&&a&&qBe(t,i,n,a);for(var s=t,u,c;t.prev!==t.next;){if(u=t.prev,c=t.next,a?NBe(t,i,n,a):FBe(t)){r.push(u.i/e|0),r.push(t.i/e|0),r.push(c.i/e|0),rx(t),t=c.next,s=c.next;continue}if(t=c,t===s){o?o===1?(t=zBe(Km(t),r,e),ex(t,r,e,i,n,a,2)):o===2&&UBe(t,r,e,i,n,a):ex(Km(t),r,e,i,n,a,1);break}}}}function FBe(t){var r=t.prev,e=t,i=t.next;if(mo(r,e,i)>=0)return!1;for(var n=r.x,a=e.x,o=i.x,s=r.y,u=e.y,c=i.y,h=n<a?n<o?n:o:a<o?a:o,v=s<u?s<c?s:c:u<c?u:c,b=n>a?n>o?n:o:a>o?a:o,S=s>u?s>c?s:c:u>c?u:c,M=i.next;M!==r;){if(M.x>=h&&M.x<=b&&M.y>=v&&M.y<=S&&$g(n,s,a,u,o,c,M.x,M.y)&&mo(M.prev,M,M.next)>=0)return!1;M=M.next}return!0}function NBe(t,r,e,i){var n=t.prev,a=t,o=t.next;if(mo(n,a,o)>=0)return!1;for(var s=n.x,u=a.x,c=o.x,h=n.y,v=a.y,b=o.y,S=s<u?s<c?s:c:u<c?u:c,M=h<v?h<b?h:b:v<b?v:b,k=s>u?s>c?s:c:u>c?u:c,N=h>v?h>b?h:b:v>b?v:b,j=$k(S,M,r,e,i),V=$k(k,N,r,e,i),H=t.prevZ,X=t.nextZ;H&&H.z>=j&&X&&X.z<=V;){if(H.x>=S&&H.x<=k&&H.y>=M&&H.y<=N&&H!==n&&H!==o&&$g(s,h,u,v,c,b,H.x,H.y)&&mo(H.prev,H,H.next)>=0||(H=H.prevZ,X.x>=S&&X.x<=k&&X.y>=M&&X.y<=N&&X!==n&&X!==o&&$g(s,h,u,v,c,b,X.x,X.y)&&mo(X.prev,X,X.next)>=0))return!1;X=X.nextZ}for(;H&&H.z>=j;){if(H.x>=S&&H.x<=k&&H.y>=M&&H.y<=N&&H!==n&&H!==o&&$g(s,h,u,v,c,b,H.x,H.y)&&mo(H.prev,H,H.next)>=0)return!1;H=H.prevZ}for(;X&&X.z<=V;){if(X.x>=S&&X.x<=k&&X.y>=M&&X.y<=N&&X!==n&&X!==o&&$g(s,h,u,v,c,b,X.x,X.y)&&mo(X.prev,X,X.next)>=0)return!1;X=X.nextZ}return!0}function zBe(t,r,e){var i=t;do{var n=i.prev,a=i.next.next;!qE(n,a)&&rie(n,i,i.next,a)&&tx(n,a)&&tx(a,n)&&(r.push(n.i/e|0),r.push(i.i/e|0),r.push(a.i/e|0),rx(i),rx(i.next),i=t=a),i=i.next}while(i!==t);return Km(i)}function UBe(t,r,e,i,n,a){var o=t;do{for(var s=o.next.next;s!==o.prev;){if(o.i!==s.i&&YBe(o,s)){var u=nie(o,s);o=Km(o,o.next),u=Km(u,u.next),ex(o,r,e,i,n,a,0),ex(u,r,e,i,n,a,0);return}s=s.next}o=o.next}while(o!==t)}function jBe(t,r,e,i){var n=[],a,o,s,u,c;for(a=0,o=r.length;a<o;a++)s=r[a]*i,u=a<o-1?r[a+1]*i:t.length,c=tie(t,s,u,i,!1),c===c.next&&(c.steiner=!0),n.push(ZBe(c));for(n.sort(GBe),a=0;a<n.length;a++)e=VBe(n[a],e);return e}function GBe(t,r){return t.x-r.x}function VBe(t,r){var e=HBe(t,r);if(!e)return r;var i=nie(e,t);return Km(i,i.next),Km(e,e.next)}function HBe(t,r){var e=r,i=t.x,n=t.y,a=-1/0,o;do{if(n<=e.y&&n>=e.next.y&&e.next.y!==e.y){var s=e.x+(n-e.y)*(e.next.x-e.x)/(e.next.y-e.y);if(s<=i&&s>a&&(a=s,o=e.x<e.next.x?e:e.next,s===i))return o}e=e.next}while(e!==r);if(!o)return null;var u=o,c=o.x,h=o.y,v=1/0,b;e=o;do i>=e.x&&e.x>=c&&i!==e.x&&$g(n<h?i:a,n,c,h,n<h?a:i,n,e.x,e.y)&&(b=Math.abs(n-e.y)/(i-e.x),tx(e,t)&&(b<v||b===v&&(e.x>o.x||e.x===o.x&&WBe(o,e)))&&(o=e,v=b)),e=e.next;while(e!==u);return o}function WBe(t,r){return mo(t.prev,t,r.prev)<0&&mo(r.next,t,t.next)<0}function qBe(t,r,e,i){var n=t;do n.z===0&&(n.z=$k(n.x,n.y,r,e,i)),n.prevZ=n.prev,n.nextZ=n.next,n=n.next;while(n!==t);n.prevZ.nextZ=null,n.prevZ=null,XBe(n)}function XBe(t){var r,e,i,n,a,o,s,u,c=1;do{for(e=t,t=null,a=null,o=0;e;){for(o++,i=e,s=0,r=0;r<c&&(s++,i=i.nextZ,!!i);r++);for(u=c;s>0||u>0&&i;)s!==0&&(u===0||!i||e.z<=i.z)?(n=e,e=e.nextZ,s--):(n=i,i=i.nextZ,u--),a?a.nextZ=n:t=n,n.prevZ=a,a=n;e=i}a.nextZ=null,c*=2}while(o>1);return t}function $k(t,r,e,i,n){return t=(t-e)*n|0,r=(r-i)*n|0,t=(t|t<<8)&16711935,t=(t|t<<4)&252645135,t=(t|t<<2)&858993459,t=(t|t<<1)&1431655765,r=(r|r<<8)&16711935,r=(r|r<<4)&252645135,r=(r|r<<2)&858993459,r=(r|r<<1)&1431655765,t|r<<1}function ZBe(t){var r=t,e=t;do(r.x<e.x||r.x===e.x&&r.y<e.y)&&(e=r),r=r.next;while(r!==t);return e}function $g(t,r,e,i,n,a,o,s){return(n-o)*(r-s)>=(t-o)*(a-s)&&(t-o)*(i-s)>=(e-o)*(r-s)&&(e-o)*(a-s)>=(n-o)*(i-s)}function YBe(t,r){return t.next.i!==r.i&&t.prev.i!==r.i&&!KBe(t,r)&&(tx(t,r)&&tx(r,t)&&QBe(t,r)&&(mo(t.prev,t,r.prev)||mo(t,r.prev,r))||qE(t,r)&&mo(t.prev,t,t.next)>0&&mo(r.prev,r,r.next)>0)}function mo(t,r,e){return(r.y-t.y)*(e.x-r.x)-(r.x-t.x)*(e.y-r.y)}function qE(t,r){return t.x===r.x&&t.y===r.y}function rie(t,r,e,i){var n=HE(mo(t,r,e)),a=HE(mo(t,r,i)),o=HE(mo(e,i,t)),s=HE(mo(e,i,r));return!!(n!==a&&o!==s||n===0&&VE(t,e,r)||a===0&&VE(t,i,r)||o===0&&VE(e,t,i)||s===0&&VE(e,r,i))}function VE(t,r,e){return r.x<=Math.max(t.x,e.x)&&r.x>=Math.min(t.x,e.x)&&r.y<=Math.max(t.y,e.y)&&r.y>=Math.min(t.y,e.y)}function HE(t){return t>0?1:t<0?-1:0}function KBe(t,r){var e=t;do{if(e.i!==t.i&&e.next.i!==t.i&&e.i!==r.i&&e.next.i!==r.i&&rie(e,e.next,t,r))return!0;e=e.next}while(e!==t);return!1}function tx(t,r){return mo(t.prev,t,t.next)<0?mo(t,r,t.next)>=0&&mo(t,t.prev,r)>=0:mo(t,r,t.prev)<0||mo(t,t.next,r)<0}function QBe(t,r){var e=t,i=!1,n=(t.x+r.x)/2,a=(t.y+r.y)/2;do e.y>a!=e.next.y>a&&e.next.y!==e.y&&n<(e.next.x-e.x)*(a-e.y)/(e.next.y-e.y)+e.x&&(i=!i),e=e.next;while(e!==t);return i}function nie(t,r){var e=new eB(t.i,t.x,t.y),i=new eB(r.i,r.x,r.y),n=t.next,a=r.prev;return t.next=r,r.prev=t,e.next=n,n.prev=e,i.next=e,e.prev=i,a.next=i,i.prev=a,i}function eie(t,r,e,i){var n=new eB(t,r,e);return i?(n.next=i.next,n.prev=i,i.next.prev=n,i.next=n):(n.prev=n,n.next=n),n}function rx(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function eB(t,r,e){this.i=t,this.x=r,this.y=e,this.prev=null,this.next=null,this.z=0,this.prevZ=null,this.nextZ=null,this.steiner=!1}WE.deviation=function(t,r,e,i){var n=r&&r.length,a=n?r[0]*e:t.length,o=Math.abs(tB(t,0,a,e));if(n)for(var s=0,u=r.length;s<u;s++){var c=r[s]*e,h=s<u-1?r[s+1]*e:t.length;o-=Math.abs(tB(t,c,h,e))}var v=0;for(s=0;s<i.length;s+=3){var b=i[s]*e,S=i[s+1]*e,M=i[s+2]*e;v+=Math.abs((t[b]-t[M])*(t[S+1]-t[b+1])-(t[b]-t[S])*(t[M+1]-t[b+1]))}return o===0&&v===0?0:Math.abs((v-o)/o)};function tB(t,r,e,i){for(var n=0,a=r,o=e-i;a<e;a+=i)n+=(t[o]-t[a])*(t[a+1]+t[o+1]),o=a;return n}WE.flatten=function(t){for(var r=t[0][0].length,e={vertices:[],holes:[],dimensions:r},i=0,n=0;n<t.length;n++){for(var a=0;a<t[n].length;a++)for(var o=0;o<r;o++)e.vertices.push(t[n][a][o]);n>0&&(i+=t[n-1].length,e.holes.push(i))}return e}});var GB=Jr(Kh=>{"use strict";var dle=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",X4e=dle+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",mle="["+dle+"]["+X4e+"]*",Z4e=new RegExp("^"+mle+"$"),Y4e=function(r,e){for(var i=[],n=e.exec(r);n;){var a=[];a.startIndex=e.lastIndex-n[0].length;for(var o=n.length,s=0;s<o;s++)a.push(n[s]);i.push(a),n=e.exec(r)}return i},K4e=function(r){var e=Z4e.exec(r);return!(e===null||typeof e>"u")};Kh.isExist=function(t){return typeof t<"u"};Kh.isEmptyObject=function(t){return Object.keys(t).length===0};Kh.merge=function(t,r,e){if(r)for(var i=Object.keys(r),n=i.length,a=0;a<n;a++)e==="strict"?t[i[a]]=[r[i[a]]]:t[i[a]]=r[i[a]]};Kh.getValue=function(t){return Kh.isExist(t)?t:""};Kh.isName=K4e;Kh.getAllMatches=Y4e;Kh.nameRegexp=mle});var HB=Jr(_le=>{"use strict";var VB=GB(),Q4e={allowBooleanAttributes:!1,unpairedTags:[]};_le.validate=function(t,r){r=Object.assign({},Q4e,r);var e=[],i=!1,n=!1;t[0]==="\uFEFF"&&(t=t.substr(1));for(var a=0;a<t.length;a++)if(t[a]==="<"&&t[a+1]==="?"){if(a+=2,a=Ale(t,a),a.err)return a}else if(t[a]==="<"){var o=a;if(a++,t[a]==="!"){a=gle(t,a);continue}else{var s=!1;t[a]==="/"&&(s=!0,a++);for(var u="";a<t.length&&t[a]!==">"&&t[a]!==" "&&t[a]!==" "&&t[a]!==`
|
|
507
|
+
`;return function(){var jt=new Error("get-stack-trace"),Mr=jt&&jt.stack?jt.stack.replace(/^[^\(]+?[\n$]/gm,"").replace(/^\s+at\s+/gm,"").replace(/^Object.<anonymous>\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",Rn=t.console&&(t.console.warn||t.console.log);return Rn&&Rn.call(t.console,ft,Mr),he.apply(this,arguments)}}var M;typeof Object.assign!="function"?M=function(xe){if(xe===i||xe===null)throw new TypeError("Cannot convert undefined or null to object");for(var Ne=Object(xe),ft=1;ft<arguments.length;ft++){var jt=arguments[ft];if(jt!==i&&jt!==null)for(var Mr in jt)jt.hasOwnProperty(Mr)&&(Ne[Mr]=jt[Mr])}return Ne}:M=Object.assign;var k=S(function(xe,Ne,ft){for(var jt=Object.keys(Ne),Mr=0;Mr<jt.length;)(!ft||ft&&xe[jt[Mr]]===i)&&(xe[jt[Mr]]=Ne[jt[Mr]]),Mr++;return xe},"extend","Use `assign`."),N=S(function(xe,Ne){return k(xe,Ne,!0)},"merge","Use `assign`.");function j(he,xe,Ne){var ft=xe.prototype,jt;jt=he.prototype=Object.create(ft),jt.constructor=he,jt._super=ft,Ne&&M(jt,Ne)}function V(he,xe){return function(){return he.apply(xe,arguments)}}function H(he,xe){return typeof he==o?he.apply(xe&&xe[0]||i,xe):he}function X(he,xe){return he===i?xe:he}function Y(he,xe,Ne){b(le(xe),function(ft){he.addEventListener(ft,Ne,!1)})}function te(he,xe,Ne){b(le(xe),function(ft){he.removeEventListener(ft,Ne,!1)})}function se(he,xe){for(;he;){if(he==xe)return!0;he=he.parentNode}return!1}function ie(he,xe){return he.indexOf(xe)>-1}function le(he){return he.trim().split(/\s+/g)}function re(he,xe,Ne){if(he.indexOf&&!Ne)return he.indexOf(xe);for(var ft=0;ft<he.length;){if(Ne&&he[ft][Ne]==xe||!Ne&&he[ft]===xe)return ft;ft++}return-1}function we(he){return Array.prototype.slice.call(he,0)}function be(he,xe,Ne){for(var ft=[],jt=[],Mr=0;Mr<he.length;){var Rn=xe?he[Mr][xe]:he[Mr];re(jt,Rn)<0&&ft.push(he[Mr]),jt[Mr]=Rn,Mr++}return Ne&&(xe?ft=ft.sort(function(ro,Xo){return ro[xe]>Xo[xe]}):ft=ft.sort()),ft}function ze(he,xe){for(var Ne,ft,jt=xe[0].toUpperCase()+xe.slice(1),Mr=0;Mr<n.length;){if(Ne=n[Mr],ft=Ne?Ne+jt:xe,ft in he)return ft;Mr++}return i}var Fe=1;function Me(){return Fe++}function Ve(he){var xe=he.ownerDocument||he;return xe.defaultView||xe.parentWindow||t}var He=/mobile|tablet|ip(ad|hone|od)|android/i,ot="ontouchstart"in t,Je=ze(t,"PointerEvent")!==i,wt=ot&&He.test(navigator.userAgent),xt="touch",zt="pen",yt="mouse",pt="kinect",Pr=25,ar=1,or=2,fr=4,Gn=8,oi=1,wr=2,Qa=4,qi=8,Yn=16,Nn=wr|Qa,Xi=qi|Yn,Va=Nn|Xi,Ri=["x","y"],Wo=["clientX","clientY"];function ha(he,xe){var Ne=this;this.manager=he,this.callback=xe,this.element=he.element,this.target=he.options.inputTarget,this.domHandler=function(ft){H(he.options.enable,[he])&&Ne.handler(ft)},this.init()}ha.prototype={handler:function(){},init:function(){this.evEl&&Y(this.element,this.evEl,this.domHandler),this.evTarget&&Y(this.target,this.evTarget,this.domHandler),this.evWin&&Y(Ve(this.element),this.evWin,this.domHandler)},destroy:function(){this.evEl&&te(this.element,this.evEl,this.domHandler),this.evTarget&&te(this.target,this.evTarget,this.domHandler),this.evWin&&te(Ve(this.element),this.evWin,this.domHandler)}};function zi(he){var xe,Ne=he.options.inputClass;return Ne?xe=Ne:Je?xe=cl:wt?xe=Ze:ot?xe=St:xe=Nu,new xe(he,pa)}function pa(he,xe,Ne){var ft=Ne.pointers.length,jt=Ne.changedPointers.length,Mr=xe&ar&&ft-jt===0,Rn=xe&(fr|Gn)&&ft-jt===0;Ne.isFirst=!!Mr,Ne.isFinal=!!Rn,Mr&&(he.session={}),Ne.eventType=xe,Ja(he,Ne),he.emit("hammer.input",Ne),he.recognize(Ne),he.session.prevInput=Ne}function Ja(he,xe){var Ne=he.session,ft=xe.pointers,jt=ft.length;Ne.firstInput||(Ne.firstInput=yr(xe)),jt>1&&!Ne.firstMultiple?Ne.firstMultiple=yr(xe):jt===1&&(Ne.firstMultiple=!1);var Mr=Ne.firstInput,Rn=Ne.firstMultiple,to=Rn?Rn.center:Mr.center,ro=xe.center=Qr(ft);xe.timeStamp=c(),xe.deltaTime=xe.timeStamp-Mr.timeStamp,xe.angle=Ha(to,ro),xe.distance=Ra(to,ro),go(Ne,xe),xe.offsetDirection=Kn(xe.deltaX,xe.deltaY);var Xo=li(xe.deltaTime,xe.deltaX,xe.deltaY);xe.overallVelocityX=Xo.x,xe.overallVelocityY=Xo.y,xe.overallVelocity=u(Xo.x)>u(Xo.y)?Xo.x:Xo.y,xe.scale=Rn?So(Rn.pointers,ft):1,xe.rotation=Rn?Fs(Rn.pointers,ft):0,xe.maxPointers=Ne.prevInput?xe.pointers.length>Ne.prevInput.maxPointers?xe.pointers.length:Ne.prevInput.maxPointers:xe.pointers.length,vr(Ne,xe);var Js=he.element;se(xe.srcEvent.target,Js)&&(Js=xe.srcEvent.target),xe.target=Js}function go(he,xe){var Ne=xe.center,ft=he.offsetDelta||{},jt=he.prevDelta||{},Mr=he.prevInput||{};(xe.eventType===ar||Mr.eventType===fr)&&(jt=he.prevDelta={x:Mr.deltaX||0,y:Mr.deltaY||0},ft=he.offsetDelta={x:Ne.x,y:Ne.y}),xe.deltaX=jt.x+(Ne.x-ft.x),xe.deltaY=jt.y+(Ne.y-ft.y)}function vr(he,xe){var Ne=he.lastInterval||xe,ft=xe.timeStamp-Ne.timeStamp,jt,Mr,Rn,to;if(xe.eventType!=Gn&&(ft>Pr||Ne.velocity===i)){var ro=xe.deltaX-Ne.deltaX,Xo=xe.deltaY-Ne.deltaY,Js=li(ft,ro,Xo);Mr=Js.x,Rn=Js.y,jt=u(Js.x)>u(Js.y)?Js.x:Js.y,to=Kn(ro,Xo),he.lastInterval=xe}else jt=Ne.velocity,Mr=Ne.velocityX,Rn=Ne.velocityY,to=Ne.direction;xe.velocity=jt,xe.velocityX=Mr,xe.velocityY=Rn,xe.direction=to}function yr(he){for(var xe=[],Ne=0;Ne<he.pointers.length;)xe[Ne]={clientX:s(he.pointers[Ne].clientX),clientY:s(he.pointers[Ne].clientY)},Ne++;return{timeStamp:c(),pointers:xe,center:Qr(xe),deltaX:he.deltaX,deltaY:he.deltaY}}function Qr(he){var xe=he.length;if(xe===1)return{x:s(he[0].clientX),y:s(he[0].clientY)};for(var Ne=0,ft=0,jt=0;jt<xe;)Ne+=he[jt].clientX,ft+=he[jt].clientY,jt++;return{x:s(Ne/xe),y:s(ft/xe)}}function li(he,xe,Ne){return{x:xe/he||0,y:Ne/he||0}}function Kn(he,xe){return he===xe?oi:u(he)>=u(xe)?he<0?wr:Qa:xe<0?qi:Yn}function Ra(he,xe,Ne){Ne||(Ne=Ri);var ft=xe[Ne[0]]-he[Ne[0]],jt=xe[Ne[1]]-he[Ne[1]];return Math.sqrt(ft*ft+jt*jt)}function Ha(he,xe,Ne){Ne||(Ne=Ri);var ft=xe[Ne[0]]-he[Ne[0]],jt=xe[Ne[1]]-he[Ne[1]];return Math.atan2(jt,ft)*180/Math.PI}function Fs(he,xe){return Ha(xe[1],xe[0],Wo)+Ha(he[1],he[0],Wo)}function So(he,xe){return Ra(xe[0],xe[1],Wo)/Ra(he[0],he[1],Wo)}var Rl={mousedown:ar,mousemove:or,mouseup:fr},uc="mousedown",tf="mousemove mouseup";function Nu(){this.evEl=uc,this.evWin=tf,this.pressed=!1,ha.apply(this,arguments)}j(Nu,ha,{handler:function(xe){var Ne=Rl[xe.type];Ne&ar&&xe.button===0&&(this.pressed=!0),Ne&or&&xe.which!==1&&(Ne=fr),this.pressed&&(Ne&fr&&(this.pressed=!1),this.callback(this.manager,Ne,{pointers:[xe],changedPointers:[xe],pointerType:yt,srcEvent:xe}))}});var ll={pointerdown:ar,pointermove:or,pointerup:fr,pointercancel:Gn,pointerout:Gn},hu={2:xt,3:zt,4:yt,5:pt},Ks="pointerdown",zu="pointermove pointerup pointercancel";t.MSPointerEvent&&!t.PointerEvent&&(Ks="MSPointerDown",zu="MSPointerMove MSPointerUp MSPointerCancel");function cl(){this.evEl=Ks,this.evWin=zu,ha.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}j(cl,ha,{handler:function(xe){var Ne=this.store,ft=!1,jt=xe.type.toLowerCase().replace("ms",""),Mr=ll[jt],Rn=hu[xe.pointerType]||xe.pointerType,to=Rn==xt,ro=re(Ne,xe.pointerId,"pointerId");Mr&ar&&(xe.button===0||to)?ro<0&&(Ne.push(xe),ro=Ne.length-1):Mr&(fr|Gn)&&(ft=!0),!(ro<0)&&(Ne[ro]=xe,this.callback(this.manager,Mr,{pointers:Ne,changedPointers:[xe],pointerType:Rn,srcEvent:xe}),ft&&Ne.splice(ro,1))}});var Zi={touchstart:ar,touchmove:or,touchend:fr,touchcancel:Gn},ee="touchstart",oe="touchstart touchmove touchend touchcancel";function fe(){this.evTarget=ee,this.evWin=oe,this.started=!1,ha.apply(this,arguments)}j(fe,ha,{handler:function(xe){var Ne=Zi[xe.type];if(Ne===ar&&(this.started=!0),!!this.started){var ft=_e.call(this,xe,Ne);Ne&(fr|Gn)&&ft[0].length-ft[1].length===0&&(this.started=!1),this.callback(this.manager,Ne,{pointers:ft[0],changedPointers:ft[1],pointerType:xt,srcEvent:xe})}}});function _e(he,xe){var Ne=we(he.touches),ft=we(he.changedTouches);return xe&(fr|Gn)&&(Ne=be(Ne.concat(ft),"identifier",!0)),[Ne,ft]}var me={touchstart:ar,touchmove:or,touchend:fr,touchcancel:Gn},je="touchstart touchmove touchend touchcancel";function Ze(){this.evTarget=je,this.targetIds={},ha.apply(this,arguments)}j(Ze,ha,{handler:function(xe){var Ne=me[xe.type],ft=ge.call(this,xe,Ne);ft&&this.callback(this.manager,Ne,{pointers:ft[0],changedPointers:ft[1],pointerType:xt,srcEvent:xe})}});function ge(he,xe){var Ne=we(he.touches),ft=this.targetIds;if(xe&(ar|or)&&Ne.length===1)return ft[Ne[0].identifier]=!0,[Ne,Ne];var jt,Mr,Rn=we(he.changedTouches),to=[],ro=this.target;if(Mr=Ne.filter(function(Xo){return se(Xo.target,ro)}),xe===ar)for(jt=0;jt<Mr.length;)ft[Mr[jt].identifier]=!0,jt++;for(jt=0;jt<Rn.length;)ft[Rn[jt].identifier]&&to.push(Rn[jt]),xe&(fr|Gn)&&delete ft[Rn[jt].identifier],jt++;if(to.length)return[be(Mr.concat(to),"identifier",!0),to]}var Oe=2500,nt=25;function St(){ha.apply(this,arguments);var he=V(this.handler,this);this.touch=new Ze(this.manager,he),this.mouse=new Nu(this.manager,he),this.primaryTouch=null,this.lastTouches=[]}j(St,ha,{handler:function(xe,Ne,ft){var jt=ft.pointerType==xt,Mr=ft.pointerType==yt;if(!(Mr&&ft.sourceCapabilities&&ft.sourceCapabilities.firesTouchEvents)){if(jt)Ot.call(this,Ne,ft);else if(Mr&&Ct.call(this,ft))return;this.callback(xe,Ne,ft)}},destroy:function(){this.touch.destroy(),this.mouse.destroy()}});function Ot(he,xe){he&ar?(this.primaryTouch=xe.changedPointers[0].identifier,dt.call(this,xe)):he&(fr|Gn)&&dt.call(this,xe)}function dt(he){var xe=he.changedPointers[0];if(xe.identifier===this.primaryTouch){var Ne={x:xe.clientX,y:xe.clientY};this.lastTouches.push(Ne);var ft=this.lastTouches,jt=function(){var Mr=ft.indexOf(Ne);Mr>-1&&ft.splice(Mr,1)};setTimeout(jt,Oe)}}function Ct(he){for(var xe=he.srcEvent.clientX,Ne=he.srcEvent.clientY,ft=0;ft<this.lastTouches.length;ft++){var jt=this.lastTouches[ft],Mr=Math.abs(xe-jt.x),Rn=Math.abs(Ne-jt.y);if(Mr<=nt&&Rn<=nt)return!0}return!1}var hr=ze(a.style,"touchAction"),sr=hr!==i,At="compute",Jt="auto",Gt="manipulation",Ut="none",tn="pan-x",Xt="pan-y",An=Vn();function ri(he,xe){this.manager=he,this.set(xe)}ri.prototype={set:function(he){he==At&&(he=this.compute()),sr&&this.manager.element.style&&An[he]&&(this.manager.element.style[hr]=he),this.actions=he.toLowerCase().trim()},update:function(){this.set(this.manager.options.touchAction)},compute:function(){var he=[];return b(this.manager.recognizers,function(xe){H(xe.options.enable,[xe])&&(he=he.concat(xe.getTouchAction()))}),gn(he.join(" "))},preventDefaults:function(he){var xe=he.srcEvent,Ne=he.offsetDirection;if(this.manager.session.prevented){xe.preventDefault();return}var ft=this.actions,jt=ie(ft,Ut)&&!An[Ut],Mr=ie(ft,Xt)&&!An[Xt],Rn=ie(ft,tn)&&!An[tn];if(jt){var to=he.pointers.length===1,ro=he.distance<2,Xo=he.deltaTime<250;if(to&&ro&&Xo)return}if(!(Rn&&Mr)&&(jt||Mr&&Ne&Nn||Rn&&Ne&Xi))return this.preventSrc(xe)},preventSrc:function(he){this.manager.session.prevented=!0,he.preventDefault()}};function gn(he){if(ie(he,Ut))return Ut;var xe=ie(he,tn),Ne=ie(he,Xt);return xe&&Ne?Ut:xe||Ne?xe?tn:Xt:ie(he,Gt)?Gt:Jt}function Vn(){if(!sr)return!1;var he={},xe=t.CSS&&t.CSS.supports;return["auto","manipulation","pan-y","pan-x","pan-x pan-y","none"].forEach(function(Ne){he[Ne]=xe?t.CSS.supports("touch-action",Ne):!0}),he}var _n=1,Ii=2,In=4,fi=8,Pn=fi,hn=16,dn=32;function aa(he){this.options=M({},this.defaults,he||{}),this.id=Me(),this.manager=null,this.options.enable=X(this.options.enable,!0),this.state=_n,this.simultaneous={},this.requireFail=[]}aa.prototype={defaults:{},set:function(he){return M(this.options,he),this.manager&&this.manager.touchAction.update(),this},recognizeWith:function(he){if(v(he,"recognizeWith",this))return this;var xe=this.simultaneous;return he=$a(he,this),xe[he.id]||(xe[he.id]=he,he.recognizeWith(this)),this},dropRecognizeWith:function(he){return v(he,"dropRecognizeWith",this)?this:(he=$a(he,this),delete this.simultaneous[he.id],this)},requireFailure:function(he){if(v(he,"requireFailure",this))return this;var xe=this.requireFail;return he=$a(he,this),re(xe,he)===-1&&(xe.push(he),he.requireFailure(this)),this},dropRequireFailure:function(he){if(v(he,"dropRequireFailure",this))return this;he=$a(he,this);var xe=re(this.requireFail,he);return xe>-1&&this.requireFail.splice(xe,1),this},hasRequireFailures:function(){return this.requireFail.length>0},canRecognizeWith:function(he){return!!this.simultaneous[he.id]},emit:function(he){var xe=this,Ne=this.state;function ft(jt){xe.manager.emit(jt,he)}Ne<fi&&ft(xe.options.event+lc(Ne)),ft(xe.options.event),he.additionalEvent&&ft(he.additionalEvent),Ne>=fi&&ft(xe.options.event+lc(Ne))},tryEmit:function(he){if(this.canEmit())return this.emit(he);this.state=dn},canEmit:function(){for(var he=0;he<this.requireFail.length;){if(!(this.requireFail[he].state&(dn|_n)))return!1;he++}return!0},recognize:function(he){var xe=M({},he);if(!H(this.options.enable,[this,xe])){this.reset(),this.state=dn;return}this.state&(Pn|hn|dn)&&(this.state=_n),this.state=this.process(xe),this.state&(Ii|In|fi|hn)&&this.tryEmit(xe)},process:function(he){},getTouchAction:function(){},reset:function(){}};function lc(he){return he&hn?"cancel":he&fi?"end":he&In?"move":he&Ii?"start":""}function La(he){return he==Yn?"down":he==qi?"up":he==wr?"left":he==Qa?"right":""}function $a(he,xe){var Ne=xe.manager;return Ne?Ne.get(he):he}function _s(){aa.apply(this,arguments)}j(_s,aa,{defaults:{pointers:1},attrTest:function(he){var xe=this.options.pointers;return xe===0||he.pointers.length===xe},process:function(he){var xe=this.state,Ne=he.eventType,ft=xe&(Ii|In),jt=this.attrTest(he);return ft&&(Ne&Gn||!jt)?xe|hn:ft||jt?Ne&fr?xe|fi:xe&Ii?xe|In:Ii:dn}});function fl(){_s.apply(this,arguments),this.pX=null,this.pY=null}j(fl,_s,{defaults:{event:"pan",threshold:10,pointers:1,direction:Va},getTouchAction:function(){var he=this.options.direction,xe=[];return he&Nn&&xe.push(Xt),he&Xi&&xe.push(tn),xe},directionTest:function(he){var xe=this.options,Ne=!0,ft=he.distance,jt=he.direction,Mr=he.deltaX,Rn=he.deltaY;return jt&xe.direction||(xe.direction&Nn?(jt=Mr===0?oi:Mr<0?wr:Qa,Ne=Mr!=this.pX,ft=Math.abs(he.deltaX)):(jt=Rn===0?oi:Rn<0?qi:Yn,Ne=Rn!=this.pY,ft=Math.abs(he.deltaY))),he.direction=jt,Ne&&ft>xe.threshold&&jt&xe.direction},attrTest:function(he){return _s.prototype.attrTest.call(this,he)&&(this.state&Ii||!(this.state&Ii)&&this.directionTest(he))},emit:function(he){this.pX=he.deltaX,this.pY=he.deltaY;var xe=La(he.direction);xe&&(he.additionalEvent=this.options.event+xe),this._super.emit.call(this,he)}});function Ui(){_s.apply(this,arguments)}j(Ui,_s,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[Ut]},attrTest:function(he){return this._super.attrTest.call(this,he)&&(Math.abs(he.scale-1)>this.options.threshold||this.state&Ii)},emit:function(he){if(he.scale!==1){var xe=he.scale<1?"in":"out";he.additionalEvent=this.options.event+xe}this._super.emit.call(this,he)}});function Ll(){aa.apply(this,arguments),this._timer=null,this._input=null}j(Ll,aa,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return[Jt]},process:function(he){var xe=this.options,Ne=he.pointers.length===xe.pointers,ft=he.distance<xe.threshold,jt=he.deltaTime>xe.time;if(this._input=he,!ft||!Ne||he.eventType&(fr|Gn)&&!jt)this.reset();else if(he.eventType&ar)this.reset(),this._timer=h(function(){this.state=Pn,this.tryEmit()},xe.time,this);else if(he.eventType&fr)return Pn;return dn},reset:function(){clearTimeout(this._timer)},emit:function(he){this.state===Pn&&(he&&he.eventType&fr?this.manager.emit(this.options.event+"up",he):(this._input.timeStamp=c(),this.manager.emit(this.options.event,this._input)))}});function eo(){_s.apply(this,arguments)}j(eo,_s,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[Ut]},attrTest:function(he){return this._super.attrTest.call(this,he)&&(Math.abs(he.rotation)>this.options.threshold||this.state&Ii)}});function Ea(){_s.apply(this,arguments)}j(Ea,_s,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:Nn|Xi,pointers:1},getTouchAction:function(){return fl.prototype.getTouchAction.call(this)},attrTest:function(he){var xe=this.options.direction,Ne;return xe&(Nn|Xi)?Ne=he.overallVelocity:xe&Nn?Ne=he.overallVelocityX:xe&Xi&&(Ne=he.overallVelocityY),this._super.attrTest.call(this,he)&&xe&he.offsetDirection&&he.distance>this.options.threshold&&he.maxPointers==this.options.pointers&&u(Ne)>this.options.velocity&&he.eventType&fr},emit:function(he){var xe=La(he.offsetDirection);xe&&this.manager.emit(this.options.event+xe,he),this.manager.emit(this.options.event,he)}});function qo(){aa.apply(this,arguments),this.pTime=!1,this.pCenter=!1,this._timer=null,this._input=null,this.count=0}j(qo,aa,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[Gt]},process:function(he){var xe=this.options,Ne=he.pointers.length===xe.pointers,ft=he.distance<xe.threshold,jt=he.deltaTime<xe.time;if(this.reset(),he.eventType&ar&&this.count===0)return this.failTimeout();if(ft&&jt&&Ne){if(he.eventType!=fr)return this.failTimeout();var Mr=this.pTime?he.timeStamp-this.pTime<xe.interval:!0,Rn=!this.pCenter||Ra(this.pCenter,he.center)<xe.posThreshold;this.pTime=he.timeStamp,this.pCenter=he.center,!Rn||!Mr?this.count=1:this.count+=1,this._input=he;var to=this.count%xe.taps;if(to===0)return this.hasRequireFailures()?(this._timer=h(function(){this.state=Pn,this.tryEmit()},xe.interval,this),Ii):Pn}return dn},failTimeout:function(){return this._timer=h(function(){this.state=dn},this.options.interval,this),dn},reset:function(){clearTimeout(this._timer)},emit:function(){this.state==Pn&&(this._input.tapCount=this.count,this.manager.emit(this.options.event,this._input))}});function Qn(he,xe){return xe=xe||{},xe.recognizers=X(xe.recognizers,Qn.defaults.preset),new ah(he,xe)}Qn.VERSION="2.0.7",Qn.defaults={domEvents:!1,touchAction:At,enable:!0,inputTarget:null,inputClass:null,preset:[[eo,{enable:!1}],[Ui,{enable:!1},["rotate"]],[Ea,{direction:Nn}],[fl,{direction:Nn},["swipe"]],[qo],[qo,{event:"doubletap",taps:2},["tap"]],[Ll]],cssProps:{userSelect:"none",touchSelect:"none",touchCallout:"none",contentZooming:"none",userDrag:"none",tapHighlightColor:"rgba(0,0,0,0)"}};var Qs=1,ts=2;function ah(he,xe){this.options=M({},Qn.defaults,xe||{}),this.options.inputTarget=this.options.inputTarget||he,this.handlers={},this.session={},this.recognizers=[],this.oldCssProps={},this.element=he,this.input=zi(this),this.touchAction=new ri(this,this.options.touchAction),xs(this,!0),b(this.options.recognizers,function(Ne){var ft=this.add(new Ne[0](Ne[1]));Ne[2]&&ft.recognizeWith(Ne[2]),Ne[3]&&ft.requireFailure(Ne[3])},this)}ah.prototype={set:function(he){return M(this.options,he),he.touchAction&&this.touchAction.update(),he.inputTarget&&(this.input.destroy(),this.input.target=he.inputTarget,this.input.init()),this},stop:function(he){this.session.stopped=he?ts:Qs},recognize:function(he){var xe=this.session;if(!xe.stopped){this.touchAction.preventDefaults(he);var Ne,ft=this.recognizers,jt=xe.curRecognizer;(!jt||jt&&jt.state&Pn)&&(jt=xe.curRecognizer=null);for(var Mr=0;Mr<ft.length;)Ne=ft[Mr],xe.stopped!==ts&&(!jt||Ne==jt||Ne.canRecognizeWith(jt))?Ne.recognize(he):Ne.reset(),!jt&&Ne.state&(Ii|In|fi)&&(jt=xe.curRecognizer=Ne),Mr++}},get:function(he){if(he instanceof aa)return he;for(var xe=this.recognizers,Ne=0;Ne<xe.length;Ne++)if(xe[Ne].options.event==he)return xe[Ne];return null},add:function(he){if(v(he,"add",this))return this;var xe=this.get(he.options.event);return xe&&this.remove(xe),this.recognizers.push(he),he.manager=this,this.touchAction.update(),he},remove:function(he){if(v(he,"remove",this))return this;if(he=this.get(he),he){var xe=this.recognizers,Ne=re(xe,he);Ne!==-1&&(xe.splice(Ne,1),this.touchAction.update())}return this},on:function(he,xe){if(he!==i&&xe!==i){var Ne=this.handlers;return b(le(he),function(ft){Ne[ft]=Ne[ft]||[],Ne[ft].push(xe)}),this}},off:function(he,xe){if(he!==i){var Ne=this.handlers;return b(le(he),function(ft){xe?Ne[ft]&&Ne[ft].splice(re(Ne[ft],xe),1):delete Ne[ft]}),this}},emit:function(he,xe){this.options.domEvents&&Wv(he,xe);var Ne=this.handlers[he]&&this.handlers[he].slice();if(!(!Ne||!Ne.length)){xe.type=he,xe.preventDefault=function(){xe.srcEvent.preventDefault()};for(var ft=0;ft<Ne.length;)Ne[ft](xe),ft++}},destroy:function(){this.element&&xs(this,!1),this.handlers={},this.session={},this.input.destroy(),this.element=null}};function xs(he,xe){var Ne=he.element;if(Ne.style){var ft;b(he.options.cssProps,function(jt,Mr){ft=ze(Ne.style,Mr),xe?(he.oldCssProps[ft]=Ne.style[ft],Ne.style[ft]=jt):Ne.style[ft]=he.oldCssProps[ft]||""}),xe||(he.oldCssProps={})}}function Wv(he,xe){var Ne=r.createEvent("Event");Ne.initEvent(he,!0,!0),Ne.gesture=xe,xe.target.dispatchEvent(Ne)}M(Qn,{INPUT_START:ar,INPUT_MOVE:or,INPUT_END:fr,INPUT_CANCEL:Gn,STATE_POSSIBLE:_n,STATE_BEGAN:Ii,STATE_CHANGED:In,STATE_ENDED:fi,STATE_RECOGNIZED:Pn,STATE_CANCELLED:hn,STATE_FAILED:dn,DIRECTION_NONE:oi,DIRECTION_LEFT:wr,DIRECTION_RIGHT:Qa,DIRECTION_UP:qi,DIRECTION_DOWN:Yn,DIRECTION_HORIZONTAL:Nn,DIRECTION_VERTICAL:Xi,DIRECTION_ALL:Va,Manager:ah,Input:ha,TouchAction:ri,TouchInput:Ze,MouseInput:Nu,PointerEventInput:cl,TouchMouseInput:St,SingleTouchInput:fe,Recognizer:aa,AttrRecognizer:_s,Tap:qo,Pan:fl,Swipe:Ea,Pinch:Ui,Rotate:eo,Press:Ll,on:Y,off:te,each:b,merge:N,extend:k,assign:M,inherit:j,bindFn:V,prefixed:ze});var Uu=typeof t<"u"?t:typeof self<"u"?self:{};Uu.Hammer=Qn,i==="function"&&define.amd?define(function(){return Qn}):typeof VT<"u"&&VT.exports?VT.exports=Qn:t[e]=Qn})(window,document,"Hammer")});var xte=Jr((e0t,_te)=>{function ake(t,r){if(t==null)return{};var e={},i=Object.keys(t),n,a;for(a=0;a<i.length;a++)n=i[a],!(r.indexOf(n)>=0)&&(e[n]=t[n]);return e}_te.exports=ake});var Ck=Jr((t0t,bte)=>{var oke=xte();function ske(t,r){if(t==null)return{};var e=oke(t,r),i,n;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(n=0;n<a.length;n++)i=a[n],!(r.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(e[i]=t[i])}return e}bte.exports=ske});var iie=Jr((y_t,rB)=>{"use strict";rB.exports=WE;rB.exports.default=WE;function WE(t,r,e){e=e||2;var i=r&&r.length,n=i?r[0]*e:t.length,a=tie(t,0,n,e,!0),o=[];if(!a||a.next===a.prev)return o;var s,u,c,h,v,b,S;if(i&&(a=jBe(t,r,a,e)),t.length>80*e){s=c=t[0],u=h=t[1];for(var M=e;M<n;M+=e)v=t[M],b=t[M+1],v<s&&(s=v),b<u&&(u=b),v>c&&(c=v),b>h&&(h=b);S=Math.max(c-s,h-u),S=S!==0?32767/S:0}return ex(a,o,e,s,u,S,0),o}function tie(t,r,e,i,n){var a,o;if(n===tB(t,r,e,i)>0)for(a=r;a<e;a+=i)o=eie(a,t[a],t[a+1],o);else for(a=e-i;a>=r;a-=i)o=eie(a,t[a],t[a+1],o);return o&&qE(o,o.next)&&(rx(o),o=o.next),o}function Km(t,r){if(!t)return t;r||(r=t);var e=t,i;do if(i=!1,!e.steiner&&(qE(e,e.next)||mo(e.prev,e,e.next)===0)){if(rx(e),e=r=e.prev,e===e.next)break;i=!0}else e=e.next;while(i||e!==r);return r}function ex(t,r,e,i,n,a,o){if(t){!o&&a&&qBe(t,i,n,a);for(var s=t,u,c;t.prev!==t.next;){if(u=t.prev,c=t.next,a?NBe(t,i,n,a):FBe(t)){r.push(u.i/e|0),r.push(t.i/e|0),r.push(c.i/e|0),rx(t),t=c.next,s=c.next;continue}if(t=c,t===s){o?o===1?(t=zBe(Km(t),r,e),ex(t,r,e,i,n,a,2)):o===2&&UBe(t,r,e,i,n,a):ex(Km(t),r,e,i,n,a,1);break}}}}function FBe(t){var r=t.prev,e=t,i=t.next;if(mo(r,e,i)>=0)return!1;for(var n=r.x,a=e.x,o=i.x,s=r.y,u=e.y,c=i.y,h=n<a?n<o?n:o:a<o?a:o,v=s<u?s<c?s:c:u<c?u:c,b=n>a?n>o?n:o:a>o?a:o,S=s>u?s>c?s:c:u>c?u:c,M=i.next;M!==r;){if(M.x>=h&&M.x<=b&&M.y>=v&&M.y<=S&&$g(n,s,a,u,o,c,M.x,M.y)&&mo(M.prev,M,M.next)>=0)return!1;M=M.next}return!0}function NBe(t,r,e,i){var n=t.prev,a=t,o=t.next;if(mo(n,a,o)>=0)return!1;for(var s=n.x,u=a.x,c=o.x,h=n.y,v=a.y,b=o.y,S=s<u?s<c?s:c:u<c?u:c,M=h<v?h<b?h:b:v<b?v:b,k=s>u?s>c?s:c:u>c?u:c,N=h>v?h>b?h:b:v>b?v:b,j=$k(S,M,r,e,i),V=$k(k,N,r,e,i),H=t.prevZ,X=t.nextZ;H&&H.z>=j&&X&&X.z<=V;){if(H.x>=S&&H.x<=k&&H.y>=M&&H.y<=N&&H!==n&&H!==o&&$g(s,h,u,v,c,b,H.x,H.y)&&mo(H.prev,H,H.next)>=0||(H=H.prevZ,X.x>=S&&X.x<=k&&X.y>=M&&X.y<=N&&X!==n&&X!==o&&$g(s,h,u,v,c,b,X.x,X.y)&&mo(X.prev,X,X.next)>=0))return!1;X=X.nextZ}for(;H&&H.z>=j;){if(H.x>=S&&H.x<=k&&H.y>=M&&H.y<=N&&H!==n&&H!==o&&$g(s,h,u,v,c,b,H.x,H.y)&&mo(H.prev,H,H.next)>=0)return!1;H=H.prevZ}for(;X&&X.z<=V;){if(X.x>=S&&X.x<=k&&X.y>=M&&X.y<=N&&X!==n&&X!==o&&$g(s,h,u,v,c,b,X.x,X.y)&&mo(X.prev,X,X.next)>=0)return!1;X=X.nextZ}return!0}function zBe(t,r,e){var i=t;do{var n=i.prev,a=i.next.next;!qE(n,a)&&rie(n,i,i.next,a)&&tx(n,a)&&tx(a,n)&&(r.push(n.i/e|0),r.push(i.i/e|0),r.push(a.i/e|0),rx(i),rx(i.next),i=t=a),i=i.next}while(i!==t);return Km(i)}function UBe(t,r,e,i,n,a){var o=t;do{for(var s=o.next.next;s!==o.prev;){if(o.i!==s.i&&YBe(o,s)){var u=nie(o,s);o=Km(o,o.next),u=Km(u,u.next),ex(o,r,e,i,n,a,0),ex(u,r,e,i,n,a,0);return}s=s.next}o=o.next}while(o!==t)}function jBe(t,r,e,i){var n=[],a,o,s,u,c;for(a=0,o=r.length;a<o;a++)s=r[a]*i,u=a<o-1?r[a+1]*i:t.length,c=tie(t,s,u,i,!1),c===c.next&&(c.steiner=!0),n.push(ZBe(c));for(n.sort(GBe),a=0;a<n.length;a++)e=VBe(n[a],e);return e}function GBe(t,r){return t.x-r.x}function VBe(t,r){var e=HBe(t,r);if(!e)return r;var i=nie(e,t);return Km(i,i.next),Km(e,e.next)}function HBe(t,r){var e=r,i=t.x,n=t.y,a=-1/0,o;do{if(n<=e.y&&n>=e.next.y&&e.next.y!==e.y){var s=e.x+(n-e.y)*(e.next.x-e.x)/(e.next.y-e.y);if(s<=i&&s>a&&(a=s,o=e.x<e.next.x?e:e.next,s===i))return o}e=e.next}while(e!==r);if(!o)return null;var u=o,c=o.x,h=o.y,v=1/0,b;e=o;do i>=e.x&&e.x>=c&&i!==e.x&&$g(n<h?i:a,n,c,h,n<h?a:i,n,e.x,e.y)&&(b=Math.abs(n-e.y)/(i-e.x),tx(e,t)&&(b<v||b===v&&(e.x>o.x||e.x===o.x&&WBe(o,e)))&&(o=e,v=b)),e=e.next;while(e!==u);return o}function WBe(t,r){return mo(t.prev,t,r.prev)<0&&mo(r.next,t,t.next)<0}function qBe(t,r,e,i){var n=t;do n.z===0&&(n.z=$k(n.x,n.y,r,e,i)),n.prevZ=n.prev,n.nextZ=n.next,n=n.next;while(n!==t);n.prevZ.nextZ=null,n.prevZ=null,XBe(n)}function XBe(t){var r,e,i,n,a,o,s,u,c=1;do{for(e=t,t=null,a=null,o=0;e;){for(o++,i=e,s=0,r=0;r<c&&(s++,i=i.nextZ,!!i);r++);for(u=c;s>0||u>0&&i;)s!==0&&(u===0||!i||e.z<=i.z)?(n=e,e=e.nextZ,s--):(n=i,i=i.nextZ,u--),a?a.nextZ=n:t=n,n.prevZ=a,a=n;e=i}a.nextZ=null,c*=2}while(o>1);return t}function $k(t,r,e,i,n){return t=(t-e)*n|0,r=(r-i)*n|0,t=(t|t<<8)&16711935,t=(t|t<<4)&252645135,t=(t|t<<2)&858993459,t=(t|t<<1)&1431655765,r=(r|r<<8)&16711935,r=(r|r<<4)&252645135,r=(r|r<<2)&858993459,r=(r|r<<1)&1431655765,t|r<<1}function ZBe(t){var r=t,e=t;do(r.x<e.x||r.x===e.x&&r.y<e.y)&&(e=r),r=r.next;while(r!==t);return e}function $g(t,r,e,i,n,a,o,s){return(n-o)*(r-s)>=(t-o)*(a-s)&&(t-o)*(i-s)>=(e-o)*(r-s)&&(e-o)*(a-s)>=(n-o)*(i-s)}function YBe(t,r){return t.next.i!==r.i&&t.prev.i!==r.i&&!KBe(t,r)&&(tx(t,r)&&tx(r,t)&&QBe(t,r)&&(mo(t.prev,t,r.prev)||mo(t,r.prev,r))||qE(t,r)&&mo(t.prev,t,t.next)>0&&mo(r.prev,r,r.next)>0)}function mo(t,r,e){return(r.y-t.y)*(e.x-r.x)-(r.x-t.x)*(e.y-r.y)}function qE(t,r){return t.x===r.x&&t.y===r.y}function rie(t,r,e,i){var n=HE(mo(t,r,e)),a=HE(mo(t,r,i)),o=HE(mo(e,i,t)),s=HE(mo(e,i,r));return!!(n!==a&&o!==s||n===0&&VE(t,e,r)||a===0&&VE(t,i,r)||o===0&&VE(e,t,i)||s===0&&VE(e,r,i))}function VE(t,r,e){return r.x<=Math.max(t.x,e.x)&&r.x>=Math.min(t.x,e.x)&&r.y<=Math.max(t.y,e.y)&&r.y>=Math.min(t.y,e.y)}function HE(t){return t>0?1:t<0?-1:0}function KBe(t,r){var e=t;do{if(e.i!==t.i&&e.next.i!==t.i&&e.i!==r.i&&e.next.i!==r.i&&rie(e,e.next,t,r))return!0;e=e.next}while(e!==t);return!1}function tx(t,r){return mo(t.prev,t,t.next)<0?mo(t,r,t.next)>=0&&mo(t,t.prev,r)>=0:mo(t,r,t.prev)<0||mo(t,t.next,r)<0}function QBe(t,r){var e=t,i=!1,n=(t.x+r.x)/2,a=(t.y+r.y)/2;do e.y>a!=e.next.y>a&&e.next.y!==e.y&&n<(e.next.x-e.x)*(a-e.y)/(e.next.y-e.y)+e.x&&(i=!i),e=e.next;while(e!==t);return i}function nie(t,r){var e=new eB(t.i,t.x,t.y),i=new eB(r.i,r.x,r.y),n=t.next,a=r.prev;return t.next=r,r.prev=t,e.next=n,n.prev=e,i.next=e,e.prev=i,a.next=i,i.prev=a,i}function eie(t,r,e,i){var n=new eB(t,r,e);return i?(n.next=i.next,n.prev=i,i.next.prev=n,i.next=n):(n.prev=n,n.next=n),n}function rx(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function eB(t,r,e){this.i=t,this.x=r,this.y=e,this.prev=null,this.next=null,this.z=0,this.prevZ=null,this.nextZ=null,this.steiner=!1}WE.deviation=function(t,r,e,i){var n=r&&r.length,a=n?r[0]*e:t.length,o=Math.abs(tB(t,0,a,e));if(n)for(var s=0,u=r.length;s<u;s++){var c=r[s]*e,h=s<u-1?r[s+1]*e:t.length;o-=Math.abs(tB(t,c,h,e))}var v=0;for(s=0;s<i.length;s+=3){var b=i[s]*e,S=i[s+1]*e,M=i[s+2]*e;v+=Math.abs((t[b]-t[M])*(t[S+1]-t[b+1])-(t[b]-t[S])*(t[M+1]-t[b+1]))}return o===0&&v===0?0:Math.abs((v-o)/o)};function tB(t,r,e,i){for(var n=0,a=r,o=e-i;a<e;a+=i)n+=(t[o]-t[a])*(t[a+1]+t[o+1]),o=a;return n}WE.flatten=function(t){for(var r=t[0][0].length,e={vertices:[],holes:[],dimensions:r},i=0,n=0;n<t.length;n++){for(var a=0;a<t[n].length;a++)for(var o=0;o<r;o++)e.vertices.push(t[n][a][o]);n>0&&(i+=t[n-1].length,e.holes.push(i))}return e}});var GB=Jr(Kh=>{"use strict";var dle=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",X4e=dle+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",mle="["+dle+"]["+X4e+"]*",Z4e=new RegExp("^"+mle+"$"),Y4e=function(r,e){for(var i=[],n=e.exec(r);n;){var a=[];a.startIndex=e.lastIndex-n[0].length;for(var o=n.length,s=0;s<o;s++)a.push(n[s]);i.push(a),n=e.exec(r)}return i},K4e=function(r){var e=Z4e.exec(r);return!(e===null||typeof e>"u")};Kh.isExist=function(t){return typeof t<"u"};Kh.isEmptyObject=function(t){return Object.keys(t).length===0};Kh.merge=function(t,r,e){if(r)for(var i=Object.keys(r),n=i.length,a=0;a<n;a++)e==="strict"?t[i[a]]=[r[i[a]]]:t[i[a]]=r[i[a]]};Kh.getValue=function(t){return Kh.isExist(t)?t:""};Kh.isName=K4e;Kh.getAllMatches=Y4e;Kh.nameRegexp=mle});var HB=Jr(_le=>{"use strict";var VB=GB(),Q4e={allowBooleanAttributes:!1,unpairedTags:[]};_le.validate=function(t,r){r=Object.assign({},Q4e,r);var e=[],i=!1,n=!1;t[0]==="\uFEFF"&&(t=t.substr(1));for(var a=0;a<t.length;a++)if(t[a]==="<"&&t[a+1]==="?"){if(a+=2,a=Ale(t,a),a.err)return a}else if(t[a]==="<"){var o=a;if(a++,t[a]==="!"){a=gle(t,a);continue}else{var s=!1;t[a]==="/"&&(s=!0,a++);for(var u="";a<t.length&&t[a]!==">"&&t[a]!==" "&&t[a]!==" "&&t[a]!==`
|
|
508
508
|
`&&t[a]!=="\r";a++)u+=t[a];if(u=u.trim(),u[u.length-1]==="/"&&(u=u.substring(0,u.length-1),a--),!aNe(u)){var c=void 0;return u.trim().length===0?c="Invalid space after '<'.":c="Tag '"+u+"' is an invalid name.",es("InvalidTag",c,rl(t,a))}var h=eNe(t,a);if(h===!1)return es("InvalidAttr","Attributes for '"+u+"' have open quote.",rl(t,a));var v=h.value;if(a=h.index,v[v.length-1]==="/"){var b=a-v.length;v=v.substring(0,v.length-1);var S=yle(v,r);if(S===!0)i=!0;else return es(S.err.code,S.err.msg,rl(t,b+S.err.line))}else if(s)if(h.tagClosed){if(v.trim().length>0)return es("InvalidTag","Closing tag '"+u+"' can't have attributes or invalid starting.",rl(t,o));var M=e.pop();if(u!==M.tagName){var k=rl(t,M.tagStartPos);return es("InvalidTag","Expected closing tag '"+M.tagName+"' (opened in line "+k.line+", col "+k.col+") instead of closing tag '"+u+"'.",rl(t,o))}e.length==0&&(n=!0)}else return es("InvalidTag","Closing tag '"+u+"' doesn't have proper closing.",rl(t,a));else{var N=yle(v,r);if(N!==!0)return es(N.err.code,N.err.msg,rl(t,a-v.length+N.err.line));if(n===!0)return es("InvalidXml","Multiple possible root nodes found.",rl(t,a));r.unpairedTags.indexOf(u)!==-1||e.push({tagName:u,tagStartPos:o}),i=!0}for(a++;a<t.length;a++)if(t[a]==="<")if(t[a+1]==="!"){a++,a=gle(t,a);continue}else if(t[a+1]==="?"){if(a=Ale(t,++a),a.err)return a}else break;else if(t[a]==="&"){var j=nNe(t,a);if(j==-1)return es("InvalidChar","char '&' is not expected.",rl(t,a));a=j}else if(n===!0&&!vle(t[a]))return es("InvalidXml","Extra text at the end",rl(t,a));t[a]==="<"&&a--}}else{if(vle(t[a]))continue;return es("InvalidChar","char '"+t[a]+"' is not expected.",rl(t,a))}if(i){if(e.length==1)return es("InvalidTag","Unclosed tag '"+e[0].tagName+"'.",rl(t,e[0].tagStartPos));if(e.length>0)return es("InvalidXml","Invalid '"+JSON.stringify(e.map(function(V){return V.tagName}),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return es("InvalidXml","Start tag expected.",1);return!0};function vle(t){return t===" "||t===" "||t===`
|
|
509
509
|
`||t==="\r"}function Ale(t,r){for(var e=r;r<t.length;r++)if(t[r]=="?"||t[r]==" "){var i=t.substr(e,r-e);if(r>5&&i==="xml")return es("InvalidXml","XML declaration allowed only at the start of the document.",rl(t,r));if(t[r]=="?"&&t[r+1]==">"){r++;break}else continue}return r}function gle(t,r){if(t.length>r+5&&t[r+1]==="-"&&t[r+2]==="-"){for(r+=3;r<t.length;r++)if(t[r]==="-"&&t[r+1]==="-"&&t[r+2]===">"){r+=2;break}}else if(t.length>r+8&&t[r+1]==="D"&&t[r+2]==="O"&&t[r+3]==="C"&&t[r+4]==="T"&&t[r+5]==="Y"&&t[r+6]==="P"&&t[r+7]==="E"){var e=1;for(r+=8;r<t.length;r++)if(t[r]==="<")e++;else if(t[r]===">"&&(e--,e===0))break}else if(t.length>r+9&&t[r+1]==="["&&t[r+2]==="C"&&t[r+3]==="D"&&t[r+4]==="A"&&t[r+5]==="T"&&t[r+6]==="A"&&t[r+7]==="["){for(r+=8;r<t.length;r++)if(t[r]==="]"&&t[r+1]==="]"&&t[r+2]===">"){r+=2;break}}return r}var J4e='"',$4e="'";function eNe(t,r){for(var e="",i="",n=!1;r<t.length;r++){if(t[r]===J4e||t[r]===$4e)i===""?i=t[r]:i!==t[r]||(i="");else if(t[r]===">"&&i===""){n=!0;break}e+=t[r]}return i!==""?!1:{value:e,index:r,tagClosed:n}}var tNe=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function yle(t,r){for(var e=VB.getAllMatches(t,tNe),i={},n=0;n<e.length;n++){if(e[n][1].length===0)return es("InvalidAttr","Attribute '"+e[n][2]+"' has no space in starting.",wx(e[n]));if(e[n][3]!==void 0&&e[n][4]===void 0)return es("InvalidAttr","Attribute '"+e[n][2]+"' is without value.",wx(e[n]));if(e[n][3]===void 0&&!r.allowBooleanAttributes)return es("InvalidAttr","boolean attribute '"+e[n][2]+"' is not allowed.",wx(e[n]));var a=e[n][2];if(!iNe(a))return es("InvalidAttr","Attribute '"+a+"' is an invalid name.",wx(e[n]));if(!i.hasOwnProperty(a))i[a]=1;else return es("InvalidAttr","Attribute '"+a+"' is repeated.",wx(e[n]))}return!0}function rNe(t,r){var e=/\d/;for(t[r]==="x"&&(r++,e=/[\da-fA-F]/);r<t.length;r++){if(t[r]===";")return r;if(!t[r].match(e))break}return-1}function nNe(t,r){if(r++,t[r]===";")return-1;if(t[r]==="#")return r++,rNe(t,r);for(var e=0;r<t.length;r++,e++)if(!(t[r].match(/\w/)&&e<20)){if(t[r]===";")break;return-1}return r}function es(t,r,e){return{err:{code:t,msg:r,line:e.line||e,col:e.col}}}function iNe(t){return VB.isName(t)}function aNe(t){return VB.isName(t)}function rl(t,r){var e=t.substring(0,r).split(/\r?\n/);return{line:e.length,col:e[e.length-1].length+1}}function wx(t){return t.startIndex+t[1].length}});var ble=Jr(WB=>{var xle={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(r,e){return e},attributeValueProcessor:function(r,e){return e},stopNodes:[],alwaysCreateTextNode:!1,isArray:function(){return!1},commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1},oNe=function(r){return Object.assign({},xle,r)};WB.buildOptions=oNe;WB.defaultOptions=xle});var Sle=Jr((Y2t,Ele)=>{"use strict";var Tx=C(Ke()),wle=C(Ge()),Tle=C(Ye()),sNe=function(){function t(r){(0,wle.default)(this,t),this.tagname=r,this.child=[],this[":@"]={}}return(0,Tle.default)(t,[{key:"add",value:function(e,i){e==="__proto__"&&(e="#__proto__"),this.child.push((0,Tx.default)({},e,i))}},{key:"addChild",value:function(e){if(e.tagname==="__proto__"&&(e.tagname="#__proto__"),e[":@"]&&Object.keys(e[":@"]).length>0){var i;this.child.push((i={},(0,Tx.default)(i,e.tagname,e.child),(0,Tx.default)(i,":@",e[":@"]),i))}else this.child.push((0,Tx.default)({},e.tagname,e.child))}}]),t}();Ele.exports=sNe});var Cle=Jr((K2t,Ple)=>{function uNe(t,r){var e={};if(t[r+3]==="O"&&t[r+4]==="C"&&t[r+5]==="T"&&t[r+6]==="Y"&&t[r+7]==="P"&&t[r+8]==="E"){r=r+9;for(var i=1,n=!1,a=!1,o=!1,s="";r<t.length;r++)if(t[r]==="<"&&!o){if(n&&t[r+1]==="!"&&t[r+2]==="E"&&t[r+3]==="N"&&t[r+4]==="T"&&t[r+5]==="I"&&t[r+6]==="T"&&t[r+7]==="Y")r+=7,a=!0;else if(n&&t[r+1]==="!"&&t[r+2]==="E"&&t[r+3]==="L"&&t[r+4]==="E"&&t[r+5]==="M"&&t[r+6]==="E"&&t[r+7]==="N"&&t[r+8]==="T")r+=8;else if(n&&t[r+1]==="!"&&t[r+2]==="A"&&t[r+3]==="T"&&t[r+4]==="T"&&t[r+5]==="L"&&t[r+6]==="I"&&t[r+7]==="S"&&t[r+8]==="T")r+=8;else if(n&&t[r+1]==="!"&&t[r+2]==="N"&&t[r+3]==="O"&&t[r+4]==="T"&&t[r+5]==="A"&&t[r+6]==="T"&&t[r+7]==="I"&&t[r+8]==="O"&&t[r+9]==="N")r+=9;else if(t[r+1]==="!"&&t[r+2]==="-"&&t[r+3]==="-")o=!0;else throw new Error("Invalid DOCTYPE");i++,s=""}else if(t[r]===">"){if(o?t[r-1]==="-"&&t[r-2]==="-"&&(o=!1,i--):(a&&(cNe(s,e),a=!1),i--),i===0)break}else t[r]==="["?n=!0:s+=t[r];if(i!==0)throw new Error("Unclosed DOCTYPE")}else throw new Error("Invalid Tag instead of DOCTYPE");return{entities:e,i:r}}var lNe=RegExp(`^\\s([a-zA-z0-0]+)[ ](['"])([^&]+)\\2`);function cNe(t,r){var e=lNe.exec(t);e&&(r[e[1]]={regx:RegExp("&".concat(e[1],";"),"g"),val:e[3]})}Ple.exports=uNe});var Ole=Jr((Q2t,Mle)=>{var fNe=/^[-+]?0x[a-fA-F0-9]+$/,hNe=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;!Number.parseInt&&window.parseInt&&(Number.parseInt=window.parseInt);!Number.parseFloat&&window.parseFloat&&(Number.parseFloat=window.parseFloat);var pNe={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};function dNe(t,r={}){if(r=Object.assign({},pNe,r),!t||typeof t!="string")return t;let e=t.trim();if(r.skipLike!==void 0&&r.skipLike.test(e))return t;if(r.hex&&fNe.test(e))return Number.parseInt(e,16);{let i=hNe.exec(e);if(i){let n=i[1],a=i[2],o=mNe(i[3]),s=i[4]||i[6];if(!r.leadingZeros&&a.length>0&&n&&e[2]!==".")return t;if(!r.leadingZeros&&a.length>0&&!n&&e[1]!==".")return t;{let u=Number(e),c=""+u;return c.search(/[eE]/)!==-1||s?r.eNotation?u:t:e.indexOf(".")!==-1?c==="0"&&o===""||c===o||n&&c==="-"+o?u:t:a?o===c||n+o===c?u:t:e===c||e===n+c?u:t}}else return t}}function mNe(t){return t&&t.indexOf(".")!==-1&&(t=t.replace(/0+$/,""),t==="."?t="0":t[0]==="."?t="0"+t:t[t.length-1]==="."&&(t=t.substr(0,t.length-1))),t}Mle.exports=dNe});var Lle=Jr(($2t,Rle)=>{"use strict";var qB=C(Ke()),Sx=C(Xn()),Ile=C(Ge()),YB=GB(),Ex=Sle(),vNe=Cle(),ANe=Ole(),J2t="<((!\\[CDATA\\[([\\s\\S]*?)(]]>))|((NAME:)?(NAME))([^>]*)>|((\\/)(NAME)\\s*>))([^<]*)".replace(/NAME/g,YB.nameRegexp),gNe=function t(r){(0,Ile.default)(this,t),this.options=r,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"\xA2"},pound:{regex:/&(pound|#163);/g,val:"\xA3"},yen:{regex:/&(yen|#165);/g,val:"\xA5"},euro:{regex:/&(euro|#8364);/g,val:"\u20AC"},copyright:{regex:/&(copy|#169);/g,val:"\xA9"},reg:{regex:/&(reg|#174);/g,val:"\xAE"},inr:{regex:/&(inr|#8377);/g,val:"\u20B9"}},this.addExternalEntities=yNe,this.parseXml=TNe,this.parseTextData=_Ne,this.resolveNameSpace=xNe,this.buildAttributesMap=wNe,this.isItStopNode=PNe,this.replaceEntitiesValue=ENe,this.readStopNodeData=MNe,this.saveTextToParentTag=SNe};function yNe(t){for(var r=Object.keys(t),e=0;e<r.length;e++){var i=r[e];this.lastEntities[i]={regex:new RegExp("&"+i+";","g"),val:t[i]}}}function _Ne(t,r,e,i,n,a,o){if(t!==void 0&&(this.options.trimValues&&!i&&(t=t.trim()),t.length>0)){o||(t=this.replaceEntitiesValue(t));var s=this.options.tagValueProcessor(r,t,e,n,a);if(s==null)return t;if((0,Sx.default)(s)!==(0,Sx.default)(t)||s!==t)return s;if(this.options.trimValues)return ZB(t,this.options.parseTagValue,this.options.numberParseOptions);var u=t.trim();return u===t?ZB(t,this.options.parseTagValue,this.options.numberParseOptions):t}}function xNe(t){if(this.options.removeNSPrefix){var r=t.split(":"),e=t.charAt(0)==="/"?"/":"";if(r[0]==="xmlns")return"";r.length===2&&(t=e+r[1])}return t}var bNe=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function wNe(t,r){if(!this.options.ignoreAttributes&&typeof t=="string"){for(var e=YB.getAllMatches(t,bNe),i=e.length,n={},a=0;a<i;a++){var o=this.resolveNameSpace(e[a][1]),s=e[a][4],u=this.options.attributeNamePrefix+o;if(o.length)if(this.options.transformAttributeName&&(u=this.options.transformAttributeName(u)),u==="__proto__"&&(u="#__proto__"),s!==void 0){this.options.trimValues&&(s=s.trim()),s=this.replaceEntitiesValue(s);var c=this.options.attributeValueProcessor(o,s,r);c==null?n[u]=s:(0,Sx.default)(c)!==(0,Sx.default)(s)||c!==s?n[u]=c:n[u]=ZB(s,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(n[u]=!0)}if(!Object.keys(n).length)return;if(this.options.attributesGroupName){var h={};return h[this.options.attributesGroupName]=n,h}return n}}var TNe=function(r){r=r.replace(/\r\n?/g,`
|
|
510
510
|
`);for(var e=new Ex("!xml"),i=e,n="",a="",o=0;o<r.length;o++){var s=r[o];if(s==="<")if(r[o+1]==="/"){var u=uv(r,">",o,"Closing Tag is not closed."),c=r.substring(o+2,u).trim();if(this.options.removeNSPrefix){var h=c.indexOf(":");h!==-1&&(c=c.substr(h+1))}this.options.transformTagName&&(c=this.options.transformTagName(c)),i&&(n=this.saveTextToParentTag(n,i,a)),a=a.substr(0,a.lastIndexOf(".")),i=this.tagsNodeStack.pop(),n="",o=u}else if(r[o+1]==="?"){var v=XB(r,o,!1,"?>");if(!v)throw new Error("Pi Tag is not closed.");if(n=this.saveTextToParentTag(n,i,a),!(this.options.ignoreDeclaration&&v.tagName==="?xml"||this.options.ignorePiTags)){var b=new Ex(v.tagName);b.add(this.options.textNodeName,""),v.tagName!==v.tagExp&&v.attrExpPresent&&(b[":@"]=this.buildAttributesMap(v.tagExp,a)),i.addChild(b)}o=v.closeIndex+1}else if(r.substr(o+1,3)==="!--"){var S=uv(r,"-->",o+4,"Comment is not closed.");if(this.options.commentPropName){var M=r.substring(o+4,S-2);n=this.saveTextToParentTag(n,i,a),i.add(this.options.commentPropName,[(0,qB.default)({},this.options.textNodeName,M)])}o=S}else if(r.substr(o+1,2)==="!D"){var k=vNe(r,o);this.docTypeEntities=k.entities,o=k.i}else if(r.substr(o+1,2)==="!["){var N=uv(r,"]]>",o,"CDATA is not closed.")-2,j=r.substring(o+9,N);if(n=this.saveTextToParentTag(n,i,a),this.options.cdataPropName)i.add(this.options.cdataPropName,[(0,qB.default)({},this.options.textNodeName,j)]);else{var V=this.parseTextData(j,i.tagname,a,!0,!1,!0);V==null&&(V=""),i.add(this.options.textNodeName,V)}o=N+2}else{var H=XB(r,o,this.options.removeNSPrefix),X=H.tagName,Y=H.tagExp,te=H.attrExpPresent,se=H.closeIndex;this.options.transformTagName&&(X=this.options.transformTagName(X)),i&&n&&i.tagname!=="!xml"&&(n=this.saveTextToParentTag(n,i,a,!1)),X!==e.tagname&&(a+=a?"."+X:X);var ie=i;if(ie&&this.options.unpairedTags.indexOf(ie.tagname)!==-1&&(i=this.tagsNodeStack.pop()),this.isItStopNode(this.options.stopNodes,a,X)){var le="";if(Y.length>0&&Y.lastIndexOf("/")===Y.length-1)o=H.closeIndex;else if(this.options.unpairedTags.indexOf(X)!==-1)o=H.closeIndex;else{var re=this.readStopNodeData(r,X,se+1);if(!re)throw new Error("Unexpected end of ".concat(X));o=re.i,le=re.tagContent}var we=new Ex(X);X!==Y&&te&&(we[":@"]=this.buildAttributesMap(Y,a)),le&&(le=this.parseTextData(le,X,a,!0,te,!0,!0)),a=a.substr(0,a.lastIndexOf(".")),we.add(this.options.textNodeName,le),i.addChild(we)}else{if(Y.length>0&&Y.lastIndexOf("/")===Y.length-1){X[X.length-1]==="/"?(X=X.substr(0,X.length-1),Y=X):Y=Y.substr(0,Y.length-1),this.options.transformTagName&&(X=this.options.transformTagName(X));var be=new Ex(X);X!==Y&&te&&(be[":@"]=this.buildAttributesMap(Y,a)),a=a.substr(0,a.lastIndexOf(".")),i.addChild(be)}else{var ze=new Ex(X);this.tagsNodeStack.push(i),X!==Y&&te&&(ze[":@"]=this.buildAttributesMap(Y,a)),i.addChild(ze),i=ze}n="",o=se}}else n+=r[o]}return e.child},ENe=function(r){if(this.options.processEntities){for(var e in this.docTypeEntities){var i=this.docTypeEntities[e];r=r.replace(i.regx,i.val)}for(var n in this.lastEntities){var a=this.lastEntities[n];r=r.replace(a.regex,a.val)}if(this.options.htmlEntities)for(var o in this.htmlEntities){var s=this.htmlEntities[o];r=r.replace(s.regex,s.val)}r=r.replace(this.ampEntity.regex,this.ampEntity.val)}return r};function SNe(t,r,e,i){return t&&(i===void 0&&(i=Object.keys(r.child).length===0),t=this.parseTextData(t,r.tagname,e,!1,r[":@"]?Object.keys(r[":@"]).length!==0:!1,i),t!==void 0&&t!==""&&r.add(this.options.textNodeName,t),t=""),t}function PNe(t,r,e){var i="*."+e;for(var n in t){var a=t[n];if(i===a||r===a)return!0}return!1}function CNe(t,r){for(var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:">",i,n="",a=r;a<t.length;a++){var o=t[a];if(i)o===i&&(i="");else if(o==='"'||o==="'")i=o;else if(o===e[0])if(e[1]){if(t[a+1]===e[1])return{data:n,index:a}}else return{data:n,index:a};else o===" "&&(o=" ");n+=o}}function uv(t,r,e,i){var n=t.indexOf(r,e);if(n===-1)throw new Error(i);return n+r.length-1}function XB(t,r,e){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:">",n=CNe(t,r+1,i);if(n){var a=n.data,o=n.index,s=a.search(/\s/),u=a,c=!0;if(s!==-1&&(u=a.substr(0,s).replace(/\s\s*$/,""),a=a.substr(s+1)),e){var h=u.indexOf(":");h!==-1&&(u=u.substr(h+1),c=u!==n.data.substr(h+1))}return{tagName:u,tagExp:a,closeIndex:o,attrExpPresent:c}}}function MNe(t,r,e){for(var i=e,n=1;e<t.length;e++)if(t[e]==="<")if(t[e+1]==="/"){var a=uv(t,">",e,"".concat(r," is not closed")),o=t.substring(e+2,a).trim();if(o===r&&(n--,n===0))return{tagContent:t.substring(i,e),i:a};e=a}else if(t[e+1]==="?"){var s=uv(t,"?>",e+1,"StopNode is not closed.");e=s}else if(t.substr(e+1,3)==="!--"){var u=uv(t,"-->",e+3,"StopNode is not closed.");e=u}else if(t.substr(e+1,2)==="!["){var c=uv(t,"]]>",e,"StopNode is not closed.")-2;e=c}else{var h=XB(t,e,">");if(h){var v=h&&h.tagName;v===r&&h.tagExp[h.tagExp.length-1]!=="/"&&n++,e=h.closeIndex}}}function ZB(t,r,e){if(r&&typeof t=="string"){var i=t.trim();return i==="true"?!0:i==="false"?!1:ANe(t,e)}else return YB.isExist(t)?t:""}Rle.exports=gNe});var Dle=Jr(Ble=>{"use strict";function ONe(t,r){return kle(t,r)}function kle(t,r,e){for(var i,n={},a=0;a<t.length;a++){var o=t[a],s=INe(o),u="";if(e===void 0?u=s:u=e+"."+s,s===r.textNodeName)i===void 0?i=o[s]:i+=""+o[s];else{if(s===void 0)continue;if(o[s]){var c=kle(o[s],r,u),h=LNe(c,r);o[":@"]?RNe(c,o[":@"],u,r):Object.keys(c).length===1&&c[r.textNodeName]!==void 0&&!r.alwaysCreateTextNode?c=c[r.textNodeName]:Object.keys(c).length===0&&(r.alwaysCreateTextNode?c[r.textNodeName]="":c=""),n[s]!==void 0&&n.hasOwnProperty(s)?(Array.isArray(n[s])||(n[s]=[n[s]]),n[s].push(c)):r.isArray(s,u,h)?n[s]=[c]:n[s]=c}}}return typeof i=="string"?i.length>0&&(n[r.textNodeName]=i):i!==void 0&&(n[r.textNodeName]=i),n}function INe(t){for(var r=Object.keys(t),e=0;e<r.length;e++){var i=r[e];if(i!==":@")return i}}function RNe(t,r,e,i){if(r)for(var n=Object.keys(r),a=n.length,o=0;o<a;o++){var s=n[o];i.isArray(s,e+"."+s,!0,!0)?t[s]=[r[s]]:t[s]=r[s]}}function LNe(t,r){var e=Object.keys(t).length;return!!(e===0||e===1&&t[r.textNodeName])}Ble.prettify=ONe});var Ule=Jr((twt,zle)=>{var Fle=C(Ge()),Nle=C(Ye()),kNe=ble(),BNe=kNe.buildOptions,DNe=Lle(),FNe=Dle(),NNe=FNe.prettify,zNe=HB(),UNe=function(){function t(r){(0,Fle.default)(this,t),this.externalEntities={},this.options=BNe(r)}return(0,Nle.default)(t,[{key:"parse",value:function(e,i){if(typeof e!="string")if(e.toString)e=e.toString();else throw new Error("XML data is accepted in String or Bytes[] form.");if(i){i===!0&&(i={});var n=zNe.validate(e,i);if(n!==!0)throw Error("".concat(n.err.msg,":").concat(n.err.line,":").concat(n.err.col))}var a=new DNe(this.options);a.addExternalEntities(this.externalEntities);var o=a.parseXml(e);return this.options.preserveOrder||o===void 0?o:NNe(o,this.options)}},{key:"addEntity",value:function(e,i){if(i.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(e.indexOf("&")!==-1||e.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'");if(i==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[e]=i}}]),t}();zle.exports=UNe});var Wle=Jr((rwt,Hle)=>{var jNe=`
|
|
511
511
|
`;function GNe(t,r){var e="";return r.format&&r.indentBy.length>0&&(e=jNe),Gle(t,r,"",e)}function Gle(t,r,e,i){for(var n="",a=!1,o=0;o<t.length;o++){var s=t[o],u=VNe(s),c="";if(e.length===0?c=u:c="".concat(e,".").concat(u),u===r.textNodeName){var h=s[u];HNe(c,r)||(h=r.tagValueProcessor(u,h),h=Vle(h,r)),a&&(n+=i),n+=h,a=!1;continue}else if(u===r.cdataPropName){a&&(n+=i),n+="<![CDATA[".concat(s[u][0][r.textNodeName],"]]>"),a=!1;continue}else if(u===r.commentPropName){n+=i+"<!--".concat(s[u][0][r.textNodeName],"-->"),a=!0;continue}else if(u[0]==="?"){var v=jle(s[":@"],r),b=u==="?xml"?"":i,S=s[u][0][r.textNodeName];S=S.length!==0?" "+S:"",n+=b+"<".concat(u).concat(S).concat(v,"?>"),a=!0;continue}var M=i;M!==""&&(M+=r.indentBy);var k=jle(s[":@"],r),N=i+"<".concat(u).concat(k),j=Gle(s[u],r,c,M);r.unpairedTags.indexOf(u)!==-1?r.suppressUnpairedNode?n+=N+">":n+=N+"/>":(!j||j.length===0)&&r.suppressEmptyNode?n+=N+"/>":j&&j.endsWith(">")?n+=N+">".concat(j).concat(i,"</").concat(u,">"):(n+=N+">",j&&i!==""&&(j.includes("/>")||j.includes("</"))?n+=i+r.indentBy+j+i:n+=j,n+="</".concat(u,">")),a=!0}return n}function VNe(t){for(var r=Object.keys(t),e=0;e<r.length;e++){var i=r[e];if(i!==":@")return i}}function jle(t,r){var e="";if(t&&!r.ignoreAttributes)for(var i in t){var n=r.attributeValueProcessor(i,t[i]);n=Vle(n,r),n===!0&&r.suppressBooleanAttributes?e+=" ".concat(i.substr(r.attributeNamePrefix.length)):e+=" ".concat(i.substr(r.attributeNamePrefix.length),'="').concat(n,'"')}return e}function HNe(t,r){t=t.substr(0,t.length-r.textNodeName.length-1);var e=t.substr(t.lastIndexOf(".")+1);for(var i in r.stopNodes)if(r.stopNodes[i]===t||r.stopNodes[i]==="*."+e)return!0;return!1}function Vle(t,r){if(t&&t.length>0&&r.processEntities)for(var e=0;e<r.entities.length;e++){var i=r.entities[e];t=t.replace(i.regex,i.val)}return t}Hle.exports=GNe});var Zle=Jr((nwt,Xle)=>{"use strict";var KB=C(Xn()),qle=C(Ke()),WNe=Wle(),qNe={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(r,e){return e},attributeValueProcessor:function(r,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[]};function Ed(t){this.options=Object.assign({},qNe,t),this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=YNe),this.processTextOrObjNode=XNe,this.options.format?(this.indentate=ZNe,this.tagEndChar=`>
|
|
512
512
|
`,this.newLine=`
|
|
513
513
|
`):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}Ed.prototype.build=function(t){return this.options.preserveOrder?WNe(t,this.options):(Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t=(0,qle.default)({},this.options.arrayNodeName,t)),this.j2x(t,0).val)};Ed.prototype.j2x=function(t,r){var e="",i="";for(var n in t)if(!(typeof t[n]>"u"))if(t[n]===null)n[0]==="?"?i+=this.indentate(r)+"<"+n+"?"+this.tagEndChar:i+=this.indentate(r)+"<"+n+"/"+this.tagEndChar;else if(t[n]instanceof Date)i+=this.buildTextValNode(t[n],n,"",r);else if((0,KB.default)(t[n])!=="object"){var a=this.isAttribute(n);if(a)e+=this.buildAttrPairStr(a,""+t[n]);else if(n===this.options.textNodeName){var o=this.options.tagValueProcessor(n,""+t[n]);i+=this.replaceEntitiesValue(o)}else i+=this.buildTextValNode(t[n],n,"",r)}else if(Array.isArray(t[n]))for(var s=t[n].length,u=0;u<s;u++){var c=t[n][u];typeof c>"u"||(c===null?n[0]==="?"?i+=this.indentate(r)+"<"+n+"?"+this.tagEndChar:i+=this.indentate(r)+"<"+n+"/"+this.tagEndChar:(0,KB.default)(c)==="object"?i+=this.processTextOrObjNode(c,n,r):i+=this.buildTextValNode(c,n,"",r))}else if(this.options.attributesGroupName&&n===this.options.attributesGroupName)for(var h=Object.keys(t[n]),v=h.length,b=0;b<v;b++)e+=this.buildAttrPairStr(h[b],""+t[n][h[b]]);else i+=this.processTextOrObjNode(t[n],n,r);return{attrStr:e,val:i}};Ed.prototype.buildAttrPairStr=function(t,r){return r=this.options.attributeValueProcessor(t,""+r),r=this.replaceEntitiesValue(r),this.options.suppressBooleanAttributes&&r==="true"?" "+t:" "+t+'="'+r+'"'};function XNe(t,r,e){var i=this.j2x(t,e+1);return t[this.options.textNodeName]!==void 0&&Object.keys(t).length===1?this.buildTextValNode(t[this.options.textNodeName],r,i.attrStr,e):this.buildObjectNode(i.val,r,i.attrStr,e)}Ed.prototype.buildObjectNode=function(t,r,e,i){if(t==="")return r[0]==="?"?this.indentate(i)+"<"+r+e+"?"+this.tagEndChar:this.indentate(i)+"<"+r+e+this.closeTag(r)+this.tagEndChar;var n="</"+r+this.tagEndChar,a="";return r[0]==="?"&&(a="?",n=""),e&&t.indexOf("<")===-1?this.indentate(i)+"<"+r+e+a+">"+t+n:this.options.commentPropName!==!1&&r===this.options.commentPropName&&a.length===0?this.indentate(i)+"<!--".concat(t,"-->")+this.newLine:this.indentate(i)+"<"+r+e+a+this.tagEndChar+t+this.indentate(i)+n};Ed.prototype.closeTag=function(t){var r="";return this.options.unpairedTags.indexOf(t)!==-1?this.options.suppressUnpairedNode||(r="/"):this.options.suppressEmptyNode?r="/":r="></".concat(t),r};Ed.prototype.buildTextValNode=function(t,r,e,i){if(this.options.cdataPropName!==!1&&r===this.options.cdataPropName)return this.indentate(i)+"<![CDATA[".concat(t,"]]>")+this.newLine;if(this.options.commentPropName!==!1&&r===this.options.commentPropName)return this.indentate(i)+"<!--".concat(t,"-->")+this.newLine;if(r[0]==="?")return this.indentate(i)+"<"+r+e+"?"+this.tagEndChar;var n=this.options.tagValueProcessor(r,t);return n=this.replaceEntitiesValue(n),n===""?this.indentate(i)+"<"+r+e+this.closeTag(r)+this.tagEndChar:this.indentate(i)+"<"+r+e+">"+n+"</"+r+this.tagEndChar};Ed.prototype.replaceEntitiesValue=function(t){if(t&&t.length>0&&this.options.processEntities)for(var r=0;r<this.options.entities.length;r++){var e=this.options.entities[r];t=t.replace(e.regex,e.val)}return t};function ZNe(t){return this.options.indentBy.repeat(t)}function YNe(t){return t.startsWith(this.options.attributeNamePrefix)?t.substr(this.attrPrefixLen):!1}Xle.exports=Ed});var Kle=Jr((iwt,Yle)=>{"use strict";var KNe=HB(),QNe=Ule(),JNe=Zle();Yle.exports={XMLParser:QNe,XMLValidator:KNe,XMLBuilder:JNe}});var FD=Jr((She,Gx)=>{(function(t,r){typeof define=="function"&&define.amd?define([],r):typeof s2=="function"&&typeof Gx=="object"&&Gx&&Gx.exports?Gx.exports=r():(t.dcodeIO=t.dcodeIO||{}).Long=r()})(She,function(){"use strict";function t(le,re,we){this.low=le|0,this.high=re|0,this.unsigned=!!we}t.prototype.__isLong__,Object.defineProperty(t.prototype,"__isLong__",{value:!0,enumerable:!1,configurable:!1});function r(le){return(le&&le.__isLong__)===!0}t.isLong=r;var e={},i={};function n(le,re){var we,be,ze;return re?(le>>>=0,(ze=0<=le&&le<256)&&(be=i[le],be)?be:(we=o(le,(le|0)<0?-1:0,!0),ze&&(i[le]=we),we)):(le|=0,(ze=-128<=le&&le<128)&&(be=e[le],be)?be:(we=o(le,le<0?-1:0,!1),ze&&(e[le]=we),we))}t.fromInt=n;function a(le,re){if(isNaN(le)||!isFinite(le))return re?j:N;if(re){if(le<0)return j;if(le>=S)return te}else{if(le<=-M)return se;if(le+1>=M)return Y}return le<0?a(-le,re).neg():o(le%b|0,le/b|0,re)}t.fromNumber=a;function o(le,re,we){return new t(le,re,we)}t.fromBits=o;var s=Math.pow;function u(le,re,we){if(le.length===0)throw Error("empty string");if(le==="NaN"||le==="Infinity"||le==="+Infinity"||le==="-Infinity")return N;if(typeof re=="number"?(we=re,re=!1):re=!!re,we=we||10,we<2||36<we)throw RangeError("radix");var be;if((be=le.indexOf("-"))>0)throw Error("interior hyphen");if(be===0)return u(le.substring(1),re,we).neg();for(var ze=a(s(we,8)),Fe=N,Me=0;Me<le.length;Me+=8){var Ve=Math.min(8,le.length-Me),He=parseInt(le.substring(Me,Me+Ve),we);if(Ve<8){var ot=a(s(we,Ve));Fe=Fe.mul(ot).add(a(He))}else Fe=Fe.mul(ze),Fe=Fe.add(a(He))}return Fe.unsigned=re,Fe}t.fromString=u;function c(le){return le instanceof t?le:typeof le=="number"?a(le):typeof le=="string"?u(le):o(le.low,le.high,le.unsigned)}t.fromValue=c;var h=1<<16,v=1<<24,b=h*h,S=b*b,M=S/2,k=n(v),N=n(0);t.ZERO=N;var j=n(0,!0);t.UZERO=j;var V=n(1);t.ONE=V;var H=n(1,!0);t.UONE=H;var X=n(-1);t.NEG_ONE=X;var Y=o(-1,2147483647,!1);t.MAX_VALUE=Y;var te=o(-1,-1,!0);t.MAX_UNSIGNED_VALUE=te;var se=o(0,-2147483648,!1);t.MIN_VALUE=se;var ie=t.prototype;return ie.toInt=function(){return this.unsigned?this.low>>>0:this.low},ie.toNumber=function(){return this.unsigned?(this.high>>>0)*b+(this.low>>>0):this.high*b+(this.low>>>0)},ie.toString=function(re){if(re=re||10,re<2||36<re)throw RangeError("radix");if(this.isZero())return"0";if(this.isNegative())if(this.eq(se)){var we=a(re),be=this.div(we),ze=be.mul(we).sub(this);return be.toString(re)+ze.toInt().toString(re)}else return"-"+this.neg().toString(re);for(var Fe=a(s(re,6),this.unsigned),Me=this,Ve="";;){var He=Me.div(Fe),ot=Me.sub(He.mul(Fe)).toInt()>>>0,Je=ot.toString(re);if(Me=He,Me.isZero())return Je+Ve;for(;Je.length<6;)Je="0"+Je;Ve=""+Je+Ve}},ie.getHighBits=function(){return this.high},ie.getHighBitsUnsigned=function(){return this.high>>>0},ie.getLowBits=function(){return this.low},ie.getLowBitsUnsigned=function(){return this.low>>>0},ie.getNumBitsAbs=function(){if(this.isNegative())return this.eq(se)?64:this.neg().getNumBitsAbs();for(var re=this.high!=0?this.high:this.low,we=31;we>0&&!(re&1<<we);we--);return this.high!=0?we+33:we+1},ie.isZero=function(){return this.high===0&&this.low===0},ie.isNegative=function(){return!this.unsigned&&this.high<0},ie.isPositive=function(){return this.unsigned||this.high>=0},ie.isOdd=function(){return(this.low&1)===1},ie.isEven=function(){return(this.low&1)===0},ie.equals=function(re){return r(re)||(re=c(re)),this.unsigned!==re.unsigned&&this.high>>>31===1&&re.high>>>31===1?!1:this.high===re.high&&this.low===re.low},ie.eq=ie.equals,ie.notEquals=function(re){return!this.eq(re)},ie.neq=ie.notEquals,ie.lessThan=function(re){return this.comp(re)<0},ie.lt=ie.lessThan,ie.lessThanOrEqual=function(re){return this.comp(re)<=0},ie.lte=ie.lessThanOrEqual,ie.greaterThan=function(re){return this.comp(re)>0},ie.gt=ie.greaterThan,ie.greaterThanOrEqual=function(re){return this.comp(re)>=0},ie.gte=ie.greaterThanOrEqual,ie.compare=function(re){if(r(re)||(re=c(re)),this.eq(re))return 0;var we=this.isNegative(),be=re.isNegative();return we&&!be?-1:!we&&be?1:this.unsigned?re.high>>>0>this.high>>>0||re.high===this.high&&re.low>>>0>this.low>>>0?-1:1:this.sub(re).isNegative()?-1:1},ie.comp=ie.compare,ie.negate=function(){return!this.unsigned&&this.eq(se)?se:this.not().add(V)},ie.neg=ie.negate,ie.add=function(re){r(re)||(re=c(re));var we=this.high>>>16,be=this.high&65535,ze=this.low>>>16,Fe=this.low&65535,Me=re.high>>>16,Ve=re.high&65535,He=re.low>>>16,ot=re.low&65535,Je=0,wt=0,xt=0,zt=0;return zt+=Fe+ot,xt+=zt>>>16,zt&=65535,xt+=ze+He,wt+=xt>>>16,xt&=65535,wt+=be+Ve,Je+=wt>>>16,wt&=65535,Je+=we+Me,Je&=65535,o(xt<<16|zt,Je<<16|wt,this.unsigned)},ie.subtract=function(re){return r(re)||(re=c(re)),this.add(re.neg())},ie.sub=ie.subtract,ie.multiply=function(re){if(this.isZero()||(r(re)||(re=c(re)),re.isZero()))return N;if(this.eq(se))return re.isOdd()?se:N;if(re.eq(se))return this.isOdd()?se:N;if(this.isNegative())return re.isNegative()?this.neg().mul(re.neg()):this.neg().mul(re).neg();if(re.isNegative())return this.mul(re.neg()).neg();if(this.lt(k)&&re.lt(k))return a(this.toNumber()*re.toNumber(),this.unsigned);var we=this.high>>>16,be=this.high&65535,ze=this.low>>>16,Fe=this.low&65535,Me=re.high>>>16,Ve=re.high&65535,He=re.low>>>16,ot=re.low&65535,Je=0,wt=0,xt=0,zt=0;return zt+=Fe*ot,xt+=zt>>>16,zt&=65535,xt+=ze*ot,wt+=xt>>>16,xt&=65535,xt+=Fe*He,wt+=xt>>>16,xt&=65535,wt+=be*ot,Je+=wt>>>16,wt&=65535,wt+=ze*He,Je+=wt>>>16,wt&=65535,wt+=Fe*Ve,Je+=wt>>>16,wt&=65535,Je+=we*ot+be*He+ze*Ve+Fe*Me,Je&=65535,o(xt<<16|zt,Je<<16|wt,this.unsigned)},ie.mul=ie.multiply,ie.divide=function(re){if(r(re)||(re=c(re)),re.isZero())throw Error("division by zero");if(this.isZero())return this.unsigned?j:N;var we,be,ze;if(this.unsigned){if(re.unsigned||(re=re.toUnsigned()),re.gt(this))return j;if(re.gt(this.shru(1)))return H;ze=j}else{if(this.eq(se)){if(re.eq(V)||re.eq(X))return se;if(re.eq(se))return V;var Fe=this.shr(1);return we=Fe.div(re).shl(1),we.eq(N)?re.isNegative()?V:X:(be=this.sub(re.mul(we)),ze=we.add(be.div(re)),ze)}else if(re.eq(se))return this.unsigned?j:N;if(this.isNegative())return re.isNegative()?this.neg().div(re.neg()):this.neg().div(re).neg();if(re.isNegative())return this.div(re.neg()).neg();ze=N}for(be=this;be.gte(re);){we=Math.max(1,Math.floor(be.toNumber()/re.toNumber()));for(var Me=Math.ceil(Math.log(we)/Math.LN2),Ve=Me<=48?1:s(2,Me-48),He=a(we),ot=He.mul(re);ot.isNegative()||ot.gt(be);)we-=Ve,He=a(we,this.unsigned),ot=He.mul(re);He.isZero()&&(He=V),ze=ze.add(He),be=be.sub(ot)}return ze},ie.div=ie.divide,ie.modulo=function(re){return r(re)||(re=c(re)),this.sub(this.div(re).mul(re))},ie.mod=ie.modulo,ie.not=function(){return o(~this.low,~this.high,this.unsigned)},ie.and=function(re){return r(re)||(re=c(re)),o(this.low&re.low,this.high&re.high,this.unsigned)},ie.or=function(re){return r(re)||(re=c(re)),o(this.low|re.low,this.high|re.high,this.unsigned)},ie.xor=function(re){return r(re)||(re=c(re)),o(this.low^re.low,this.high^re.high,this.unsigned)},ie.shiftLeft=function(re){return r(re)&&(re=re.toInt()),(re&=63)===0?this:re<32?o(this.low<<re,this.high<<re|this.low>>>32-re,this.unsigned):o(0,this.low<<re-32,this.unsigned)},ie.shl=ie.shiftLeft,ie.shiftRight=function(re){return r(re)&&(re=re.toInt()),(re&=63)===0?this:re<32?o(this.low>>>re|this.high<<32-re,this.high>>re,this.unsigned):o(this.high>>re-32,this.high>=0?0:-1,this.unsigned)},ie.shr=ie.shiftRight,ie.shiftRightUnsigned=function(re){if(r(re)&&(re=re.toInt()),re&=63,re===0)return this;var we=this.high;if(re<32){var be=this.low;return o(be>>>re|we<<32-re,we>>>re,this.unsigned)}else return re===32?o(we,0,this.unsigned):o(we>>>re-32,0,this.unsigned)},ie.shru=ie.shiftRightUnsigned,ie.toSigned=function(){return this.unsigned?o(this.low,this.high,!1):this},ie.toUnsigned=function(){return this.unsigned?this:o(this.low,this.high,!0)},ie.toBytes=function(le){return le?this.toBytesLE():this.toBytesBE()},ie.toBytesLE=function(){var le=this.high,re=this.low;return[re&255,re>>>8&255,re>>>16&255,re>>>24&255,le&255,le>>>8&255,le>>>16&255,le>>>24&255]},ie.toBytesBE=function(){var le=this.high,re=this.low;return[le>>>24&255,le>>>16&255,le>>>8&255,le&255,re>>>24&255,re>>>16&255,re>>>8&255,re&255]},t})});var _ye=Jr(E8=>{E8.read=function(t,r,e,i,n){var a,o,s=n*8-i-1,u=(1<<s)-1,c=u>>1,h=-7,v=e?n-1:0,b=e?-1:1,S=t[r+v];for(v+=b,a=S&(1<<-h)-1,S>>=-h,h+=s;h>0;a=a*256+t[r+v],v+=b,h-=8);for(o=a&(1<<-h)-1,a>>=-h,h+=i;h>0;o=o*256+t[r+v],v+=b,h-=8);if(a===0)a=1-c;else{if(a===u)return o?NaN:(S?-1:1)*(1/0);o=o+Math.pow(2,i),a=a-c}return(S?-1:1)*o*Math.pow(2,a-i)};E8.write=function(t,r,e,i,n,a){var o,s,u,c=a*8-n-1,h=(1<<c)-1,v=h>>1,b=n===23?Math.pow(2,-24)-Math.pow(2,-77):0,S=i?0:a-1,M=i?1:-1,k=r<0||r===0&&1/r<0?1:0;for(r=Math.abs(r),isNaN(r)||r===1/0?(s=isNaN(r)?1:0,o=h):(o=Math.floor(Math.log(r)/Math.LN2),r*(u=Math.pow(2,-o))<1&&(o--,u*=2),o+v>=1?r+=b/u:r+=b*Math.pow(2,1-v),r*u>=2&&(o++,u/=2),o+v>=h?(s=0,o=h):o+v>=1?(s=(r*u-1)*Math.pow(2,n),o=o+v):(s=r*Math.pow(2,v-1)*Math.pow(2,n),o=0));n>=8;t[e+S]=s&255,S+=M,s/=256,n-=8);for(o=o<<n|s,c+=n;c>0;t[e+S]=o&255,S+=M,o/=256,c-=8);t[e+S-M]|=k*128}});var Sye=Jr((u8t,Eye)=>{"use strict";Eye.exports=Ni;var MC=_ye();function Ni(t){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(t)?t:new Uint8Array(t||0),this.pos=0,this.type=0,this.length=this.buf.length}Ni.Varint=0;Ni.Fixed64=1;Ni.Bytes=2;Ni.Fixed32=5;var S8=(1<<16)*(1<<16),xye=1/S8,sWe=12,Tye=typeof TextDecoder>"u"?null:new TextDecoder("utf8");Ni.prototype={destroy:function(){this.buf=null},readFields:function(t,r,e){for(e=e||this.length;this.pos<e;){var i=this.readVarint(),n=i>>3,a=this.pos;this.type=i&7,t(n,r,this),this.pos===a&&this.skip(i)}return r},readMessage:function(t,r){return this.readFields(t,r,this.readVarint()+this.pos)},readFixed32:function(){var t=OC(this.buf,this.pos);return this.pos+=4,t},readSFixed32:function(){var t=wye(this.buf,this.pos);return this.pos+=4,t},readFixed64:function(){var t=OC(this.buf,this.pos)+OC(this.buf,this.pos+4)*S8;return this.pos+=8,t},readSFixed64:function(){var t=OC(this.buf,this.pos)+wye(this.buf,this.pos+4)*S8;return this.pos+=8,t},readFloat:function(){var t=MC.read(this.buf,this.pos,!0,23,4);return this.pos+=4,t},readDouble:function(){var t=MC.read(this.buf,this.pos,!0,52,8);return this.pos+=8,t},readVarint:function(t){var r=this.buf,e,i;return i=r[this.pos++],e=i&127,i<128||(i=r[this.pos++],e|=(i&127)<<7,i<128)||(i=r[this.pos++],e|=(i&127)<<14,i<128)||(i=r[this.pos++],e|=(i&127)<<21,i<128)?e:(i=r[this.pos],e|=(i&15)<<28,uWe(e,t,this))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var t=this.readVarint();return t%2===1?(t+1)/-2:t/2},readBoolean:function(){return Boolean(this.readVarint())},readString:function(){var t=this.readVarint()+this.pos,r=this.pos;return this.pos=t,t-r>=sWe&&Tye?bWe(this.buf,r,t):xWe(this.buf,r,t)},readBytes:function(){var t=this.readVarint()+this.pos,r=this.buf.subarray(this.pos,t);return this.pos=t,r},readPackedVarint:function(t,r){if(this.type!==Ni.Bytes)return t.push(this.readVarint(r));var e=bp(this);for(t=t||[];this.pos<e;)t.push(this.readVarint(r));return t},readPackedSVarint:function(t){if(this.type!==Ni.Bytes)return t.push(this.readSVarint());var r=bp(this);for(t=t||[];this.pos<r;)t.push(this.readSVarint());return t},readPackedBoolean:function(t){if(this.type!==Ni.Bytes)return t.push(this.readBoolean());var r=bp(this);for(t=t||[];this.pos<r;)t.push(this.readBoolean());return t},readPackedFloat:function(t){if(this.type!==Ni.Bytes)return t.push(this.readFloat());var r=bp(this);for(t=t||[];this.pos<r;)t.push(this.readFloat());return t},readPackedDouble:function(t){if(this.type!==Ni.Bytes)return t.push(this.readDouble());var r=bp(this);for(t=t||[];this.pos<r;)t.push(this.readDouble());return t},readPackedFixed32:function(t){if(this.type!==Ni.Bytes)return t.push(this.readFixed32());var r=bp(this);for(t=t||[];this.pos<r;)t.push(this.readFixed32());return t},readPackedSFixed32:function(t){if(this.type!==Ni.Bytes)return t.push(this.readSFixed32());var r=bp(this);for(t=t||[];this.pos<r;)t.push(this.readSFixed32());return t},readPackedFixed64:function(t){if(this.type!==Ni.Bytes)return t.push(this.readFixed64());var r=bp(this);for(t=t||[];this.pos<r;)t.push(this.readFixed64());return t},readPackedSFixed64:function(t){if(this.type!==Ni.Bytes)return t.push(this.readSFixed64());var r=bp(this);for(t=t||[];this.pos<r;)t.push(this.readSFixed64());return t},skip:function(t){var r=t&7;if(r===Ni.Varint)for(;this.buf[this.pos++]>127;);else if(r===Ni.Bytes)this.pos=this.readVarint()+this.pos;else if(r===Ni.Fixed32)this.pos+=4;else if(r===Ni.Fixed64)this.pos+=8;else throw new Error("Unimplemented type: "+r)},writeTag:function(t,r){this.writeVarint(t<<3|r)},realloc:function(t){for(var r=this.length||16;r<this.pos+t;)r*=2;if(r!==this.length){var e=new Uint8Array(r);e.set(this.buf),this.buf=e,this.length=r}},finish:function(){return this.length=this.pos,this.pos=0,this.buf.subarray(0,this.length)},writeFixed32:function(t){this.realloc(4),ly(this.buf,t,this.pos),this.pos+=4},writeSFixed32:function(t){this.realloc(4),ly(this.buf,t,this.pos),this.pos+=4},writeFixed64:function(t){this.realloc(8),ly(this.buf,t&-1,this.pos),ly(this.buf,Math.floor(t*xye),this.pos+4),this.pos+=8},writeSFixed64:function(t){this.realloc(8),ly(this.buf,t&-1,this.pos),ly(this.buf,Math.floor(t*xye),this.pos+4),this.pos+=8},writeVarint:function(t){if(t=+t||0,t>268435455||t<0){lWe(t,this);return}this.realloc(4),this.buf[this.pos++]=t&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=(t>>>=7)&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=(t>>>=7)&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=t>>>7&127)))},writeSVarint:function(t){this.writeVarint(t<0?-t*2-1:t*2)},writeBoolean:function(t){this.writeVarint(Boolean(t))},writeString:function(t){t=String(t),this.realloc(t.length*4),this.pos++;var r=this.pos;this.pos=wWe(this.buf,t,this.pos);var e=this.pos-r;e>=128&&bye(r,e,this),this.pos=r-1,this.writeVarint(e),this.pos+=e},writeFloat:function(t){this.realloc(4),MC.write(this.buf,t,this.pos,!0,23,4),this.pos+=4},writeDouble:function(t){this.realloc(8),MC.write(this.buf,t,this.pos,!0,52,8),this.pos+=8},writeBytes:function(t){var r=t.length;this.writeVarint(r),this.realloc(r);for(var e=0;e<r;e++)this.buf[this.pos++]=t[e]},writeRawMessage:function(t,r){this.pos++;var e=this.pos;t(r,this);var i=this.pos-e;i>=128&&bye(e,i,this),this.pos=e-1,this.writeVarint(i),this.pos+=i},writeMessage:function(t,r,e){this.writeTag(t,Ni.Bytes),this.writeRawMessage(r,e)},writePackedVarint:function(t,r){r.length&&this.writeMessage(t,hWe,r)},writePackedSVarint:function(t,r){r.length&&this.writeMessage(t,pWe,r)},writePackedBoolean:function(t,r){r.length&&this.writeMessage(t,vWe,r)},writePackedFloat:function(t,r){r.length&&this.writeMessage(t,dWe,r)},writePackedDouble:function(t,r){r.length&&this.writeMessage(t,mWe,r)},writePackedFixed32:function(t,r){r.length&&this.writeMessage(t,AWe,r)},writePackedSFixed32:function(t,r){r.length&&this.writeMessage(t,gWe,r)},writePackedFixed64:function(t,r){r.length&&this.writeMessage(t,yWe,r)},writePackedSFixed64:function(t,r){r.length&&this.writeMessage(t,_We,r)},writeBytesField:function(t,r){this.writeTag(t,Ni.Bytes),this.writeBytes(r)},writeFixed32Field:function(t,r){this.writeTag(t,Ni.Fixed32),this.writeFixed32(r)},writeSFixed32Field:function(t,r){this.writeTag(t,Ni.Fixed32),this.writeSFixed32(r)},writeFixed64Field:function(t,r){this.writeTag(t,Ni.Fixed64),this.writeFixed64(r)},writeSFixed64Field:function(t,r){this.writeTag(t,Ni.Fixed64),this.writeSFixed64(r)},writeVarintField:function(t,r){this.writeTag(t,Ni.Varint),this.writeVarint(r)},writeSVarintField:function(t,r){this.writeTag(t,Ni.Varint),this.writeSVarint(r)},writeStringField:function(t,r){this.writeTag(t,Ni.Bytes),this.writeString(r)},writeFloatField:function(t,r){this.writeTag(t,Ni.Fixed32),this.writeFloat(r)},writeDoubleField:function(t,r){this.writeTag(t,Ni.Fixed64),this.writeDouble(r)},writeBooleanField:function(t,r){this.writeVarintField(t,Boolean(r))}};function uWe(t,r,e){var i=e.buf,n,a;if(a=i[e.pos++],n=(a&112)>>4,a<128||(a=i[e.pos++],n|=(a&127)<<3,a<128)||(a=i[e.pos++],n|=(a&127)<<10,a<128)||(a=i[e.pos++],n|=(a&127)<<17,a<128)||(a=i[e.pos++],n|=(a&127)<<24,a<128)||(a=i[e.pos++],n|=(a&1)<<31,a<128))return uy(t,n,r);throw new Error("Expected varint not more than 10 bytes")}function bp(t){return t.type===Ni.Bytes?t.readVarint()+t.pos:t.pos+1}function uy(t,r,e){return e?r*4294967296+(t>>>0):(r>>>0)*4294967296+(t>>>0)}function lWe(t,r){var e,i;if(t>=0?(e=t%4294967296|0,i=t/4294967296|0):(e=~(-t%4294967296),i=~(-t/4294967296),e^4294967295?e=e+1|0:(e=0,i=i+1|0)),t>=18446744073709552e3||t<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");r.realloc(10),cWe(e,i,r),fWe(i,r)}function cWe(t,r,e){e.buf[e.pos++]=t&127|128,t>>>=7,e.buf[e.pos++]=t&127|128,t>>>=7,e.buf[e.pos++]=t&127|128,t>>>=7,e.buf[e.pos++]=t&127|128,t>>>=7,e.buf[e.pos]=t&127}function fWe(t,r){var e=(t&7)<<4;r.buf[r.pos++]|=e|((t>>>=3)?128:0),t&&(r.buf[r.pos++]=t&127|((t>>>=7)?128:0),t&&(r.buf[r.pos++]=t&127|((t>>>=7)?128:0),t&&(r.buf[r.pos++]=t&127|((t>>>=7)?128:0),t&&(r.buf[r.pos++]=t&127|((t>>>=7)?128:0),t&&(r.buf[r.pos++]=t&127)))))}function bye(t,r,e){var i=r<=16383?1:r<=2097151?2:r<=268435455?3:Math.floor(Math.log(r)/(Math.LN2*7));e.realloc(i);for(var n=e.pos-1;n>=t;n--)e.buf[n+i]=e.buf[n]}function hWe(t,r){for(var e=0;e<t.length;e++)r.writeVarint(t[e])}function pWe(t,r){for(var e=0;e<t.length;e++)r.writeSVarint(t[e])}function dWe(t,r){for(var e=0;e<t.length;e++)r.writeFloat(t[e])}function mWe(t,r){for(var e=0;e<t.length;e++)r.writeDouble(t[e])}function vWe(t,r){for(var e=0;e<t.length;e++)r.writeBoolean(t[e])}function AWe(t,r){for(var e=0;e<t.length;e++)r.writeFixed32(t[e])}function gWe(t,r){for(var e=0;e<t.length;e++)r.writeSFixed32(t[e])}function yWe(t,r){for(var e=0;e<t.length;e++)r.writeFixed64(t[e])}function _We(t,r){for(var e=0;e<t.length;e++)r.writeSFixed64(t[e])}function OC(t,r){return(t[r]|t[r+1]<<8|t[r+2]<<16)+t[r+3]*16777216}function ly(t,r,e){t[e]=r,t[e+1]=r>>>8,t[e+2]=r>>>16,t[e+3]=r>>>24}function wye(t,r){return(t[r]|t[r+1]<<8|t[r+2]<<16)+(t[r+3]<<24)}function xWe(t,r,e){for(var i="",n=r;n<e;){var a=t[n],o=null,s=a>239?4:a>223?3:a>191?2:1;if(n+s>e)break;var u,c,h;s===1?a<128&&(o=a):s===2?(u=t[n+1],(u&192)===128&&(o=(a&31)<<6|u&63,o<=127&&(o=null))):s===3?(u=t[n+1],c=t[n+2],(u&192)===128&&(c&192)===128&&(o=(a&15)<<12|(u&63)<<6|c&63,(o<=2047||o>=55296&&o<=57343)&&(o=null))):s===4&&(u=t[n+1],c=t[n+2],h=t[n+3],(u&192)===128&&(c&192)===128&&(h&192)===128&&(o=(a&15)<<18|(u&63)<<12|(c&63)<<6|h&63,(o<=65535||o>=1114112)&&(o=null))),o===null?(o=65533,s=1):o>65535&&(o-=65536,i+=String.fromCharCode(o>>>10&1023|55296),o=56320|o&1023),i+=String.fromCharCode(o),n+=s}return i}function bWe(t,r,e){return Tye.decode(t.subarray(r,e))}function wWe(t,r,e){for(var i=0,n,a;i<r.length;i++){if(n=r.charCodeAt(i),n>55295&&n<57344)if(a)if(n<56320){t[e++]=239,t[e++]=191,t[e++]=189,a=n;continue}else n=a-55296<<10|n-56320|65536,a=null;else{n>56319||i+1===r.length?(t[e++]=239,t[e++]=191,t[e++]=189):a=n;continue}else a&&(t[e++]=239,t[e++]=191,t[e++]=189,a=null);n<128?t[e++]=n:(n<2048?t[e++]=n>>6|192:(n<65536?t[e++]=n>>12|224:(t[e++]=n>>18|240,t[e++]=n>>12&63|128),t[e++]=n>>6&63|128),t[e++]=n&63|128)}return e}});var F_e=Jr((Tb,FC)=>{(function(t){"use strict";var r="Compound",e="Identifier",i="MemberExpression",n="Literal",a="ThisExpression",o="CallExpression",s="UnaryExpression",u="BinaryExpression",c="LogicalExpression",h="ConditionalExpression",v="ArrayExpression",b=46,S=44,M=39,k=34,N=40,j=41,V=91,H=93,X=63,Y=59,te=58,se=function(yt,pt){var Pr=new Error(yt+" at character "+pt);throw Pr.index=pt,Pr.description=yt,Pr},ie=!0,le={"-":ie,"!":ie,"~":ie,"+":ie},re={"||":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":10,"/":10,"%":10},we=function(yt){var pt=0,Pr;for(var ar in yt)(Pr=ar.length)>pt&&yt.hasOwnProperty(ar)&&(pt=Pr);return pt},be=we(le),ze=we(re),Fe={true:!0,false:!1,null:null},Me="this",Ve=function(yt){return re[yt]||0},He=function(yt,pt,Pr){var ar=yt==="||"||yt==="&&"?c:u;return{type:ar,operator:yt,left:pt,right:Pr}},ot=function(yt){return yt>=48&&yt<=57},Je=function(yt){return yt===36||yt===95||yt>=65&&yt<=90||yt>=97&&yt<=122||yt>=128&&!re[String.fromCharCode(yt)]},wt=function(yt){return yt===36||yt===95||yt>=65&&yt<=90||yt>=97&&yt<=122||yt>=48&&yt<=57||yt>=128&&!re[String.fromCharCode(yt)]},xt=function(yt){for(var pt=0,Pr=yt.charAt,ar=yt.charCodeAt,or=function(vr){return Pr.call(yt,vr)},fr=function(vr){return ar.call(yt,vr)},Gn=yt.length,oi=function(){for(var vr=fr(pt);vr===32||vr===9||vr===10||vr===13;)vr=fr(++pt)},wr=function(){var vr=qi(),yr,Qr;if(oi(),fr(pt)===X){if(pt++,yr=wr(),yr||se("Expected expression",pt),oi(),fr(pt)===te)return pt++,Qr=wr(),Qr||se("Expected expression",pt),{type:h,test:vr,consequent:yr,alternate:Qr};se("Expected :",pt)}else return vr},Qa=function(){oi();for(var vr,yr=yt.substr(pt,ze),Qr=yr.length;Qr>0;){if(re.hasOwnProperty(yr)&&(!Je(fr(pt))||pt+yr.length<yt.length&&!wt(fr(pt+yr.length))))return pt+=Qr,yr;yr=yr.substr(0,--Qr)}return!1},qi=function(){var vr,yr,Qr,li,Kn,Ra,Ha,Fs,So;if(Ha=Yn(),Qr=Qa(),!Qr)return Ha;for(Ra={value:Qr,prec:Ve(Qr)},Fs=Yn(),Fs||se("Expected expression after "+Qr,pt),Kn=[Ha,Ra,Fs];(Qr=Qa())&&(li=Ve(Qr),li!==0);){for(Ra={value:Qr,prec:li};Kn.length>2&&li<=Kn[Kn.length-2].prec;)Fs=Kn.pop(),Qr=Kn.pop().value,Ha=Kn.pop(),yr=He(Qr,Ha,Fs),Kn.push(yr);yr=Yn(),yr||se("Expected expression after "+Qr,pt),Kn.push(Ra,yr)}for(So=Kn.length-1,yr=Kn[So];So>1;)yr=He(Kn[So-1].value,Kn[So-2],yr),So-=2;return yr},Yn=function(){var vr,yr,Qr;if(oi(),vr=fr(pt),ot(vr)||vr===b)return Nn();if(vr===M||vr===k)return Xi();if(vr===V)return zi();for(yr=yt.substr(pt,be),Qr=yr.length;Qr>0;){if(le.hasOwnProperty(yr)&&(!Je(fr(pt))||pt+yr.length<yt.length&&!wt(fr(pt+yr.length))))return pt+=Qr,{type:s,operator:yr,argument:Yn(),prefix:!0};yr=yr.substr(0,--Qr)}return Je(vr)||vr===N?Wo():!1},Nn=function(){for(var vr="",yr,Qr;ot(fr(pt));)vr+=or(pt++);if(fr(pt)===b)for(vr+=or(pt++);ot(fr(pt));)vr+=or(pt++);if(yr=or(pt),yr==="e"||yr==="E"){for(vr+=or(pt++),yr=or(pt),(yr==="+"||yr==="-")&&(vr+=or(pt++));ot(fr(pt));)vr+=or(pt++);ot(fr(pt-1))||se("Expected exponent ("+vr+or(pt)+")",pt)}return Qr=fr(pt),Je(Qr)?se("Variable names cannot start with a number ("+vr+or(pt)+")",pt):Qr===b&&se("Unexpected period",pt),{type:n,value:parseFloat(vr),raw:vr}},Xi=function(){for(var vr="",yr=or(pt++),Qr=!1,li;pt<Gn;)if(li=or(pt++),li===yr){Qr=!0;break}else if(li==="\\")switch(li=or(pt++),li){case"n":vr+=`
|
|
514
|
-
`;break;case"r":vr+="\r";break;case"t":vr+=" ";break;case"b":vr+="\b";break;case"f":vr+="\f";break;case"v":vr+="\v";break;default:vr+=li}else vr+=li;return Qr||se('Unclosed quote after "'+vr+'"',pt),{type:n,value:vr,raw:yr+vr+yr}},Va=function(){var vr=fr(pt),yr=pt,Qr;for(Je(vr)?pt++:se("Unexpected "+or(pt),pt);pt<Gn&&(vr=fr(pt),wt(vr));)pt++;return Qr=yt.slice(yr,pt),Fe.hasOwnProperty(Qr)?{type:n,value:Fe[Qr],raw:Qr}:Qr===Me?{type:a}:{type:e,name:Qr}},Ri=function(vr){for(var yr,Qr=[],li,Kn=!1;pt<Gn;)if(oi(),yr=fr(pt),yr===vr){Kn=!0,pt++;break}else yr===S?pt++:(li=wr(),(!li||li.type===r)&&se("Expected comma",pt),Qr.push(li));return Kn||se("Expected "+String.fromCharCode(vr),pt),Qr},Wo=function(){var vr,yr;for(vr=fr(pt),vr===N?yr=ha():yr=Va(),oi(),vr=fr(pt);vr===b||vr===V||vr===N;)pt++,vr===b?(oi(),yr={type:i,computed:!1,object:yr,property:Va()}):vr===V?(yr={type:i,computed:!0,object:yr,property:wr()},oi(),vr=fr(pt),vr!==H&&se("Unclosed [",pt),pt++):vr===N&&(yr={type:o,arguments:Ri(j),callee:yr}),oi(),vr=fr(pt);return yr},ha=function(){pt++;var vr=wr();if(oi(),fr(pt)===j)return pt++,vr;se("Unclosed (",pt)},zi=function(){return pt++,{type:v,elements:Ri(H)}},pa=[],Ja,go;pt<Gn;)Ja=fr(pt),Ja===Y||Ja===S?pt++:(go=wr())?pa.push(go):pt<Gn&&se('Unexpected "'+or(pt)+'"',pt);return pa.length===1?pa[0]:{type:r,body:pa}};if(xt.version="0.3.4",xt.toString=function(){return"JavaScript Expression Parser (JSEP) v"+xt.version},xt.addUnaryOp=function(yt){return be=Math.max(yt.length,be),le[yt]=ie,this},xt.addBinaryOp=function(yt,pt){return ze=Math.max(yt.length,ze),re[yt]=pt,this},xt.addLiteral=function(yt,pt){return Fe[yt]=pt,this},xt.removeUnaryOp=function(yt){return delete le[yt],yt.length===be&&(be=we(le)),this},xt.removeAllUnaryOps=function(){return le={},be=0,this},xt.removeBinaryOp=function(yt){return delete re[yt],yt.length===ze&&(ze=we(re)),this},xt.removeAllBinaryOps=function(){return re={},ze=0,this},xt.removeLiteral=function(yt){return delete Fe[yt],this},xt.removeAllLiterals=function(){return Fe={},this},typeof Tb>"u"){var zt=t.jsep;t.jsep=xt,xt.noConflict=function(){return t.jsep===xt&&(t.jsep=zt),xt}}else typeof FC<"u"&&FC.exports?Tb=FC.exports=xt:Tb.parse=xt})(Tb)});var H_e=Jr((x6t,V_e)=>{var j8=F_e(),NC={"||":function(t,r){return t||r},"&&":function(t,r){return t&&r},"|":function(t,r){return t|r},"^":function(t,r){return t^r},"&":function(t,r){return t&r},"==":function(t,r){return t==r},"!=":function(t,r){return t!=r},"===":function(t,r){return t===r},"!==":function(t,r){return t!==r},"<":function(t,r){return t<r},">":function(t,r){return t>r},"<=":function(t,r){return t<=r},">=":function(t,r){return t>=r},"<<":function(t,r){return t<<r},">>":function(t,r){return t>>r},">>>":function(t,r){return t>>>r},"+":function(t,r){return t+r},"-":function(t,r){return t-r},"*":function(t,r){return t*r},"/":function(t,r){return t/r},"%":function(t,r){return t%r}},G_e={"-":function(t){return-t},"+":function(t){return+t},"~":function(t){return~t},"!":function(t){return!t}};function N_e(t,r){return t.map(function(e){return Bs(e,r)})}async function z_e(t,r){return await Promise.all(t.map(i=>Ds(i,r)))}function U_e(t,r){let e=Bs(t.object,r);return t.computed?[e,e[Bs(t.property,r)]]:[e,e[t.property.name]]}async function j_e(t,r){let e=await Ds(t.object,r);return t.computed?[e,e[await Ds(t.property,r)]]:[e,e[t.property.name]]}function Bs(t,r){switch(t.type){case"ArrayExpression":return N_e(t.elements,r);case"BinaryExpression":return NC[t.operator](Bs(t.left,r),Bs(t.right,r));case"CallExpression":let e,i,n;return t.callee.type==="MemberExpression"?(n=U_e(t.callee,r),e=n[0],i=n[1]):i=Bs(t.callee,r),typeof i!="function"?void 0:i.apply(e,N_e(t.arguments,r));case"ConditionalExpression":return Bs(t.test,r)?Bs(t.consequent,r):Bs(t.alternate,r);case"Identifier":return r[t.name];case"Literal":return t.value;case"LogicalExpression":return t.operator==="||"?Bs(t.left,r)||Bs(t.right,r):t.operator==="&&"?Bs(t.left,r)&&Bs(t.right,r):NC[t.operator](Bs(t.left,r),Bs(t.right,r));case"MemberExpression":return U_e(t,r)[1];case"ThisExpression":return r;case"UnaryExpression":return G_e[t.operator](Bs(t.argument,r));default:return}}async function Ds(t,r){switch(t.type){case"ArrayExpression":return await z_e(t.elements,r);case"BinaryExpression":{let[a,o]=await Promise.all([Ds(t.left,r),Ds(t.right,r)]);return NC[t.operator](a,o)}case"CallExpression":let e,i,n;return t.callee.type==="MemberExpression"?(n=await j_e(t.callee,r),e=n[0],i=n[1]):i=await Ds(t.callee,r),typeof i!="function"?void 0:await i.apply(e,await z_e(t.arguments,r));case"ConditionalExpression":return await Ds(t.test,r)?await Ds(t.consequent,r):await Ds(t.alternate,r);case"Identifier":return r[t.name];case"Literal":return t.value;case"LogicalExpression":{if(t.operator==="||")return await Ds(t.left,r)||await Ds(t.right,r);if(t.operator==="&&")return await Ds(t.left,r)&&await Ds(t.right,r);let[a,o]=await Promise.all([Ds(t.left,r),Ds(t.right,r)]);return NC[t.operator](a,o)}case"MemberExpression":return(await j_e(t,r))[1];case"ThisExpression":return r;case"UnaryExpression":return G_e[t.operator](await Ds(t.argument,r));default:return}}function Aqe(t){return Bs.bind(null,j8(t))}function gqe(t){return Ds.bind(null,j8(t))}V_e.exports={parse:j8,eval:Bs,evalAsync:Ds,compile:Aqe,compileAsync:gqe}});var d1e=Jr((s5t,p1e)=>{"use strict";var Cqe="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";p1e.exports=Cqe});var g1e=Jr((u5t,A1e)=>{"use strict";var Mqe=d1e();function m1e(){}function v1e(){}v1e.resetWarningCache=m1e;A1e.exports=function(){function t(i,n,a,o,s,u){if(u!==Mqe){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}t.isRequired=t;function r(){return t}var e={array:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:r,element:t,elementType:t,instanceOf:r,node:t,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:v1e,resetWarningCache:m1e};return e.PropTypes=e,e}});var _1e=Jr((f5t,y1e)=>{y1e.exports=g1e()();var l5t,c5t});var XC=Jr((H5t,z1e)=>{z1e.exports=typeof s2=="function"?XC():null});var tXe={};Yu(tXe,{JupyterTransportModel:()=>Y1e,JupyterTransportView:()=>nxe,MODULE_NAME:()=>Xy,MODULE_VERSION:()=>qy,createDeck:()=>HC,initPlayground:()=>WC,jupyterTransport:()=>qC,updateDeck:()=>k1e});var qy="8.9.0",Xy="@deck.gl/jupyter-widget";var R1e=C(Ke());var gU=C(Xn()),yU=C(Ke()),XM=C(Vr()),t_=C(zr());var oz=C(Ke()),sz=C(Ge()),uz=C(Ye());function ve(t,r,e){return r in t?Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[r]=e,t}var z5=C(Ge()),U5=C(Ye());var N5=100,j5=function(){function t(r,e){if((0,z5.default)(this,t),ve(this,"schema",void 0),ve(this,"options",void 0),ve(this,"length",0),ve(this,"rows",null),ve(this,"cursor",0),ve(this,"_headers",[]),this.options=e,this.schema=r,!Array.isArray(r)){this._headers=[];for(var i in r)this._headers[r[i].index]=r[i].name}}return(0,U5.default)(t,[{key:"rowCount",value:function(){return this.length}},{key:"addArrayRow",value:function(e,i){Number.isFinite(i)&&(this.cursor=i),this.rows=this.rows||new Array(N5),this.rows[this.length]=e,this.length++}},{key:"addObjectRow",value:function(e,i){Number.isFinite(i)&&(this.cursor=i),this.rows=this.rows||new Array(N5),this.rows[this.length]=e,this.length++}},{key:"getBatch",value:function(){var e=this.rows;if(!e)return null;e=e.slice(0,this.length),this.rows=null;var i={shape:this.options.shape,batchType:"data",data:e,length:this.length,schema:this.schema,cursor:this.cursor};return i}}]),t}();var V5=C(Ge()),H5=C(Ye());function Zy(t,r){if(!t)throw new Error("null row");if(!r)throw new Error("no headers");for(var e={},i=0;i<r.length;i++)e[r[i]]=t[i];return e}function Yy(t,r){if(!t)throw new Error("null row");if(!r)throw new Error("no headers");for(var e=new Array(r.length),i=0;i<r.length;i++)e[i]=t[r[i]];return e}var G5=100,W5=function(){function t(r,e){if((0,V5.default)(this,t),ve(this,"schema",void 0),ve(this,"options",void 0),ve(this,"length",0),ve(this,"objectRows",null),ve(this,"arrayRows",null),ve(this,"cursor",0),ve(this,"_headers",[]),this.options=e,this.schema=r,!Array.isArray(r)){this._headers=[];for(var i in r)this._headers[r[i].index]=r[i].name}}return(0,H5.default)(t,[{key:"rowCount",value:function(){return this.length}},{key:"addArrayRow",value:function(e,i){switch(Number.isFinite(i)&&(this.cursor=i),this.options.shape){case"object-row-table":var n=Zy(e,this._headers);this.addObjectRow(n,i);break;case"array-row-table":this.arrayRows=this.arrayRows||new Array(G5),this.arrayRows[this.length]=e,this.length++;break}}},{key:"addObjectRow",value:function(e,i){switch(Number.isFinite(i)&&(this.cursor=i),this.options.shape){case"array-row-table":var n=Yy(e,this._headers);this.addArrayRow(n,i);break;case"object-row-table":this.objectRows=this.objectRows||new Array(G5),this.objectRows[this.length]=e,this.length++;break}}},{key:"getBatch",value:function(){var e=this.arrayRows||this.objectRows;return e?(e=e.slice(0,this.length),this.arrayRows=null,this.objectRows=null,{shape:this.options.shape,batchType:"data",data:e,length:this.length,schema:this.schema,cursor:this.cursor}):null}}]),t}();var $5=C(Kr()),ez=C(Ge()),tz=C(Ye());var Gbe=100,rz=function(){function t(r,e){(0,ez.default)(this,t),ve(this,"schema",void 0),ve(this,"length",0),ve(this,"allocated",0),ve(this,"columns",{}),this.schema=r,this._reallocateColumns()}return(0,tz.default)(t,[{key:"rowCount",value:function(){return this.length}},{key:"addArrayRow",value:function(e){this._reallocateColumns();var i=0;for(var n in this.columns)this.columns[n][this.length]=e[i++];this.length++}},{key:"addObjectRow",value:function(e){this._reallocateColumns();for(var i in e)this.columns[i][this.length]=e[i];this.length++}},{key:"getBatch",value:function(){this._pruneColumns();var e=Array.isArray(this.schema)?this.columns:{};if(!Array.isArray(this.schema))for(var i in this.schema){var n=this.schema[i];e[n.name]=this.columns[n.index]}this.columns={};var a={shape:"columnar-table",batchType:"data",data:e,schema:this.schema,length:this.length};return a}},{key:"_reallocateColumns",value:function(){if(!(this.length<this.allocated)){this.allocated=this.allocated>0?this.allocated*=2:Gbe,this.columns={};for(var e in this.schema){var i=this.schema[e],n=i.type||Float32Array,a=this.columns[i.index];if(a&&ArrayBuffer.isView(a)){var o=new n(this.allocated);o.set(a),this.columns[i.index]=o}else a?(a.length=this.allocated,this.columns[i.index]=a):this.columns[i.index]=new n(this.allocated)}}}},{key:"_pruneColumns",value:function(){for(var e=0,i=Object.entries(this.columns);e<i.length;e++){var n=(0,$5.default)(i[e],2),a=n[0],o=n[1];this.columns[a]=o.slice(0,this.length)}}}]),t}();function nz(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function iz(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?nz(Object(e),!0).forEach(function(i){(0,oz.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):nz(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}var Vbe={shape:"array-row-table",batchSize:"auto",batchDebounceMs:0,limit:0,_limitMB:0},az="TableBatchBuilder",c2=function(){function t(r,e){(0,sz.default)(this,t),ve(this,"schema",void 0),ve(this,"options",void 0),ve(this,"aggregator",null),ve(this,"batchCount",0),ve(this,"bytesUsed",0),ve(this,"isChunkComplete",!1),ve(this,"lastBatchEmittedMs",Date.now()),ve(this,"totalLength",0),ve(this,"totalBytes",0),ve(this,"rowBytes",0),this.schema=r,this.options=iz(iz({},Vbe),e)}return(0,uz.default)(t,[{key:"limitReached",value:function(){var e,i;return!!(Boolean((e=this.options)===null||e===void 0?void 0:e.limit)&&this.totalLength>=this.options.limit||Boolean((i=this.options)===null||i===void 0?void 0:i._limitMB)&&this.totalBytes/1e6>=this.options._limitMB)}},{key:"addRow",value:function(e){this.limitReached()||(this.totalLength++,this.rowBytes=this.rowBytes||this._estimateRowMB(e),this.totalBytes+=this.rowBytes,Array.isArray(e)?this.addArrayRow(e):this.addObjectRow(e))}},{key:"addArrayRow",value:function(e){if(!this.aggregator){var i=this._getTableBatchType();this.aggregator=new i(this.schema,this.options)}this.aggregator.addArrayRow(e)}},{key:"addObjectRow",value:function(e){if(!this.aggregator){var i=this._getTableBatchType();this.aggregator=new i(this.schema,this.options)}this.aggregator.addObjectRow(e)}},{key:"chunkComplete",value:function(e){e instanceof ArrayBuffer&&(this.bytesUsed+=e.byteLength),typeof e=="string"&&(this.bytesUsed+=e.length),this.isChunkComplete=!0}},{key:"getFullBatch",value:function(e){return this._isFull()?this._getBatch(e):null}},{key:"getFinalBatch",value:function(e){return this._getBatch(e)}},{key:"_estimateRowMB",value:function(e){return Array.isArray(e)?e.length*8:Object.keys(e).length*8}},{key:"_isFull",value:function(){if(!this.aggregator||this.aggregator.rowCount()===0)return!1;if(this.options.batchSize==="auto"){if(!this.isChunkComplete)return!1}else if(this.options.batchSize>this.aggregator.rowCount())return!1;return this.options.batchDebounceMs>Date.now()-this.lastBatchEmittedMs?!1:(this.isChunkComplete=!1,this.lastBatchEmittedMs=Date.now(),!0)}},{key:"_getBatch",value:function(e){if(!this.aggregator)return null;e!=null&&e.bytesUsed&&(this.bytesUsed=e.bytesUsed);var i=this.aggregator.getBatch();return i.count=this.batchCount,i.bytesUsed=this.bytesUsed,Object.assign(i,e),this.batchCount++,this.aggregator=null,i}},{key:"_getTableBatchType",value:function(){switch(this.options.shape){case"row-table":return j5;case"array-row-table":case"object-row-table":return W5;case"columnar-table":return rz;case"arrow-table":if(!t.ArrowBatch)throw new Error(az);return t.ArrowBatch;default:throw new Error(az)}}}]),t}();ve(c2,"ArrowBatch",void 0);function Ph(t){for(var r=1/0,e=1/0,i=1/0,n=-1/0,a=-1/0,o=-1/0,s=t.POSITION?t.POSITION.value:[],u=s&&s.length,c=0;c<u;c+=3){var h=s[c],v=s[c+1],b=s[c+2];r=h<r?h:r,e=v<e?v:e,i=b<i?b:i,n=h>n?h:n,a=v>a?v:a,o=b>o?b:o}return[[r,e,i],[n,a,o]]}var EM=C(Ms()),yz=C(Ge()),_z=C(Ye());function vz(t,r){if(!t)throw new Error(r||"loader assertion failed.")}function SM(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=Qbe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
514
|
+
`;break;case"r":vr+="\r";break;case"t":vr+=" ";break;case"b":vr+="\b";break;case"f":vr+="\f";break;case"v":vr+="\v";break;default:vr+=li}else vr+=li;return Qr||se('Unclosed quote after "'+vr+'"',pt),{type:n,value:vr,raw:yr+vr+yr}},Va=function(){var vr=fr(pt),yr=pt,Qr;for(Je(vr)?pt++:se("Unexpected "+or(pt),pt);pt<Gn&&(vr=fr(pt),wt(vr));)pt++;return Qr=yt.slice(yr,pt),Fe.hasOwnProperty(Qr)?{type:n,value:Fe[Qr],raw:Qr}:Qr===Me?{type:a}:{type:e,name:Qr}},Ri=function(vr){for(var yr,Qr=[],li,Kn=!1;pt<Gn;)if(oi(),yr=fr(pt),yr===vr){Kn=!0,pt++;break}else yr===S?pt++:(li=wr(),(!li||li.type===r)&&se("Expected comma",pt),Qr.push(li));return Kn||se("Expected "+String.fromCharCode(vr),pt),Qr},Wo=function(){var vr,yr;for(vr=fr(pt),vr===N?yr=ha():yr=Va(),oi(),vr=fr(pt);vr===b||vr===V||vr===N;)pt++,vr===b?(oi(),yr={type:i,computed:!1,object:yr,property:Va()}):vr===V?(yr={type:i,computed:!0,object:yr,property:wr()},oi(),vr=fr(pt),vr!==H&&se("Unclosed [",pt),pt++):vr===N&&(yr={type:o,arguments:Ri(j),callee:yr}),oi(),vr=fr(pt);return yr},ha=function(){pt++;var vr=wr();if(oi(),fr(pt)===j)return pt++,vr;se("Unclosed (",pt)},zi=function(){return pt++,{type:v,elements:Ri(H)}},pa=[],Ja,go;pt<Gn;)Ja=fr(pt),Ja===Y||Ja===S?pt++:(go=wr())?pa.push(go):pt<Gn&&se('Unexpected "'+or(pt)+'"',pt);return pa.length===1?pa[0]:{type:r,body:pa}};if(xt.version="0.3.4",xt.toString=function(){return"JavaScript Expression Parser (JSEP) v"+xt.version},xt.addUnaryOp=function(yt){return be=Math.max(yt.length,be),le[yt]=ie,this},xt.addBinaryOp=function(yt,pt){return ze=Math.max(yt.length,ze),re[yt]=pt,this},xt.addLiteral=function(yt,pt){return Fe[yt]=pt,this},xt.removeUnaryOp=function(yt){return delete le[yt],yt.length===be&&(be=we(le)),this},xt.removeAllUnaryOps=function(){return le={},be=0,this},xt.removeBinaryOp=function(yt){return delete re[yt],yt.length===ze&&(ze=we(re)),this},xt.removeAllBinaryOps=function(){return re={},ze=0,this},xt.removeLiteral=function(yt){return delete Fe[yt],this},xt.removeAllLiterals=function(){return Fe={},this},typeof Tb>"u"){var zt=t.jsep;t.jsep=xt,xt.noConflict=function(){return t.jsep===xt&&(t.jsep=zt),xt}}else typeof FC<"u"&&FC.exports?Tb=FC.exports=xt:Tb.parse=xt})(Tb)});var H_e=Jr((x6t,V_e)=>{var j8=F_e(),NC={"||":function(t,r){return t||r},"&&":function(t,r){return t&&r},"|":function(t,r){return t|r},"^":function(t,r){return t^r},"&":function(t,r){return t&r},"==":function(t,r){return t==r},"!=":function(t,r){return t!=r},"===":function(t,r){return t===r},"!==":function(t,r){return t!==r},"<":function(t,r){return t<r},">":function(t,r){return t>r},"<=":function(t,r){return t<=r},">=":function(t,r){return t>=r},"<<":function(t,r){return t<<r},">>":function(t,r){return t>>r},">>>":function(t,r){return t>>>r},"+":function(t,r){return t+r},"-":function(t,r){return t-r},"*":function(t,r){return t*r},"/":function(t,r){return t/r},"%":function(t,r){return t%r}},G_e={"-":function(t){return-t},"+":function(t){return+t},"~":function(t){return~t},"!":function(t){return!t}};function N_e(t,r){return t.map(function(e){return Bs(e,r)})}async function z_e(t,r){return await Promise.all(t.map(i=>Ds(i,r)))}function U_e(t,r){let e=Bs(t.object,r);return t.computed?[e,e[Bs(t.property,r)]]:[e,e[t.property.name]]}async function j_e(t,r){let e=await Ds(t.object,r);return t.computed?[e,e[await Ds(t.property,r)]]:[e,e[t.property.name]]}function Bs(t,r){switch(t.type){case"ArrayExpression":return N_e(t.elements,r);case"BinaryExpression":return NC[t.operator](Bs(t.left,r),Bs(t.right,r));case"CallExpression":let e,i,n;return t.callee.type==="MemberExpression"?(n=U_e(t.callee,r),e=n[0],i=n[1]):i=Bs(t.callee,r),typeof i!="function"?void 0:i.apply(e,N_e(t.arguments,r));case"ConditionalExpression":return Bs(t.test,r)?Bs(t.consequent,r):Bs(t.alternate,r);case"Identifier":return r[t.name];case"Literal":return t.value;case"LogicalExpression":return t.operator==="||"?Bs(t.left,r)||Bs(t.right,r):t.operator==="&&"?Bs(t.left,r)&&Bs(t.right,r):NC[t.operator](Bs(t.left,r),Bs(t.right,r));case"MemberExpression":return U_e(t,r)[1];case"ThisExpression":return r;case"UnaryExpression":return G_e[t.operator](Bs(t.argument,r));default:return}}async function Ds(t,r){switch(t.type){case"ArrayExpression":return await z_e(t.elements,r);case"BinaryExpression":{let[a,o]=await Promise.all([Ds(t.left,r),Ds(t.right,r)]);return NC[t.operator](a,o)}case"CallExpression":let e,i,n;return t.callee.type==="MemberExpression"?(n=await j_e(t.callee,r),e=n[0],i=n[1]):i=await Ds(t.callee,r),typeof i!="function"?void 0:await i.apply(e,await z_e(t.arguments,r));case"ConditionalExpression":return await Ds(t.test,r)?await Ds(t.consequent,r):await Ds(t.alternate,r);case"Identifier":return r[t.name];case"Literal":return t.value;case"LogicalExpression":{if(t.operator==="||")return await Ds(t.left,r)||await Ds(t.right,r);if(t.operator==="&&")return await Ds(t.left,r)&&await Ds(t.right,r);let[a,o]=await Promise.all([Ds(t.left,r),Ds(t.right,r)]);return NC[t.operator](a,o)}case"MemberExpression":return(await j_e(t,r))[1];case"ThisExpression":return r;case"UnaryExpression":return G_e[t.operator](await Ds(t.argument,r));default:return}}function Aqe(t){return Bs.bind(null,j8(t))}function gqe(t){return Ds.bind(null,j8(t))}V_e.exports={parse:j8,eval:Bs,evalAsync:Ds,compile:Aqe,compileAsync:gqe}});var d1e=Jr((s5t,p1e)=>{"use strict";var Cqe="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";p1e.exports=Cqe});var g1e=Jr((u5t,A1e)=>{"use strict";var Mqe=d1e();function m1e(){}function v1e(){}v1e.resetWarningCache=m1e;A1e.exports=function(){function t(i,n,a,o,s,u){if(u!==Mqe){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}t.isRequired=t;function r(){return t}var e={array:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:r,element:t,elementType:t,instanceOf:r,node:t,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:v1e,resetWarningCache:m1e};return e.PropTypes=e,e}});var _1e=Jr((f5t,y1e)=>{y1e.exports=g1e()();var l5t,c5t});var XC=Jr((H5t,z1e)=>{z1e.exports=typeof s2=="function"?XC():null});var tXe={};Yu(tXe,{JupyterTransportModel:()=>Y1e,JupyterTransportView:()=>nxe,MODULE_NAME:()=>Xy,MODULE_VERSION:()=>qy,createDeck:()=>HC,initPlayground:()=>WC,jupyterTransport:()=>qC,updateDeck:()=>k1e});var qy="8.9.1",Xy="@deck.gl/jupyter-widget";var R1e=C(Ke());var gU=C(Xn()),yU=C(Ke()),XM=C(Vr()),t_=C(zr());var oz=C(Ke()),sz=C(Ge()),uz=C(Ye());function ve(t,r,e){return r in t?Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[r]=e,t}var z5=C(Ge()),U5=C(Ye());var N5=100,j5=function(){function t(r,e){if((0,z5.default)(this,t),ve(this,"schema",void 0),ve(this,"options",void 0),ve(this,"length",0),ve(this,"rows",null),ve(this,"cursor",0),ve(this,"_headers",[]),this.options=e,this.schema=r,!Array.isArray(r)){this._headers=[];for(var i in r)this._headers[r[i].index]=r[i].name}}return(0,U5.default)(t,[{key:"rowCount",value:function(){return this.length}},{key:"addArrayRow",value:function(e,i){Number.isFinite(i)&&(this.cursor=i),this.rows=this.rows||new Array(N5),this.rows[this.length]=e,this.length++}},{key:"addObjectRow",value:function(e,i){Number.isFinite(i)&&(this.cursor=i),this.rows=this.rows||new Array(N5),this.rows[this.length]=e,this.length++}},{key:"getBatch",value:function(){var e=this.rows;if(!e)return null;e=e.slice(0,this.length),this.rows=null;var i={shape:this.options.shape,batchType:"data",data:e,length:this.length,schema:this.schema,cursor:this.cursor};return i}}]),t}();var V5=C(Ge()),H5=C(Ye());function Zy(t,r){if(!t)throw new Error("null row");if(!r)throw new Error("no headers");for(var e={},i=0;i<r.length;i++)e[r[i]]=t[i];return e}function Yy(t,r){if(!t)throw new Error("null row");if(!r)throw new Error("no headers");for(var e=new Array(r.length),i=0;i<r.length;i++)e[i]=t[r[i]];return e}var G5=100,W5=function(){function t(r,e){if((0,V5.default)(this,t),ve(this,"schema",void 0),ve(this,"options",void 0),ve(this,"length",0),ve(this,"objectRows",null),ve(this,"arrayRows",null),ve(this,"cursor",0),ve(this,"_headers",[]),this.options=e,this.schema=r,!Array.isArray(r)){this._headers=[];for(var i in r)this._headers[r[i].index]=r[i].name}}return(0,H5.default)(t,[{key:"rowCount",value:function(){return this.length}},{key:"addArrayRow",value:function(e,i){switch(Number.isFinite(i)&&(this.cursor=i),this.options.shape){case"object-row-table":var n=Zy(e,this._headers);this.addObjectRow(n,i);break;case"array-row-table":this.arrayRows=this.arrayRows||new Array(G5),this.arrayRows[this.length]=e,this.length++;break}}},{key:"addObjectRow",value:function(e,i){switch(Number.isFinite(i)&&(this.cursor=i),this.options.shape){case"array-row-table":var n=Yy(e,this._headers);this.addArrayRow(n,i);break;case"object-row-table":this.objectRows=this.objectRows||new Array(G5),this.objectRows[this.length]=e,this.length++;break}}},{key:"getBatch",value:function(){var e=this.arrayRows||this.objectRows;return e?(e=e.slice(0,this.length),this.arrayRows=null,this.objectRows=null,{shape:this.options.shape,batchType:"data",data:e,length:this.length,schema:this.schema,cursor:this.cursor}):null}}]),t}();var $5=C(Kr()),ez=C(Ge()),tz=C(Ye());var Gbe=100,rz=function(){function t(r,e){(0,ez.default)(this,t),ve(this,"schema",void 0),ve(this,"length",0),ve(this,"allocated",0),ve(this,"columns",{}),this.schema=r,this._reallocateColumns()}return(0,tz.default)(t,[{key:"rowCount",value:function(){return this.length}},{key:"addArrayRow",value:function(e){this._reallocateColumns();var i=0;for(var n in this.columns)this.columns[n][this.length]=e[i++];this.length++}},{key:"addObjectRow",value:function(e){this._reallocateColumns();for(var i in e)this.columns[i][this.length]=e[i];this.length++}},{key:"getBatch",value:function(){this._pruneColumns();var e=Array.isArray(this.schema)?this.columns:{};if(!Array.isArray(this.schema))for(var i in this.schema){var n=this.schema[i];e[n.name]=this.columns[n.index]}this.columns={};var a={shape:"columnar-table",batchType:"data",data:e,schema:this.schema,length:this.length};return a}},{key:"_reallocateColumns",value:function(){if(!(this.length<this.allocated)){this.allocated=this.allocated>0?this.allocated*=2:Gbe,this.columns={};for(var e in this.schema){var i=this.schema[e],n=i.type||Float32Array,a=this.columns[i.index];if(a&&ArrayBuffer.isView(a)){var o=new n(this.allocated);o.set(a),this.columns[i.index]=o}else a?(a.length=this.allocated,this.columns[i.index]=a):this.columns[i.index]=new n(this.allocated)}}}},{key:"_pruneColumns",value:function(){for(var e=0,i=Object.entries(this.columns);e<i.length;e++){var n=(0,$5.default)(i[e],2),a=n[0],o=n[1];this.columns[a]=o.slice(0,this.length)}}}]),t}();function nz(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function iz(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?nz(Object(e),!0).forEach(function(i){(0,oz.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):nz(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}var Vbe={shape:"array-row-table",batchSize:"auto",batchDebounceMs:0,limit:0,_limitMB:0},az="TableBatchBuilder",c2=function(){function t(r,e){(0,sz.default)(this,t),ve(this,"schema",void 0),ve(this,"options",void 0),ve(this,"aggregator",null),ve(this,"batchCount",0),ve(this,"bytesUsed",0),ve(this,"isChunkComplete",!1),ve(this,"lastBatchEmittedMs",Date.now()),ve(this,"totalLength",0),ve(this,"totalBytes",0),ve(this,"rowBytes",0),this.schema=r,this.options=iz(iz({},Vbe),e)}return(0,uz.default)(t,[{key:"limitReached",value:function(){var e,i;return!!(Boolean((e=this.options)===null||e===void 0?void 0:e.limit)&&this.totalLength>=this.options.limit||Boolean((i=this.options)===null||i===void 0?void 0:i._limitMB)&&this.totalBytes/1e6>=this.options._limitMB)}},{key:"addRow",value:function(e){this.limitReached()||(this.totalLength++,this.rowBytes=this.rowBytes||this._estimateRowMB(e),this.totalBytes+=this.rowBytes,Array.isArray(e)?this.addArrayRow(e):this.addObjectRow(e))}},{key:"addArrayRow",value:function(e){if(!this.aggregator){var i=this._getTableBatchType();this.aggregator=new i(this.schema,this.options)}this.aggregator.addArrayRow(e)}},{key:"addObjectRow",value:function(e){if(!this.aggregator){var i=this._getTableBatchType();this.aggregator=new i(this.schema,this.options)}this.aggregator.addObjectRow(e)}},{key:"chunkComplete",value:function(e){e instanceof ArrayBuffer&&(this.bytesUsed+=e.byteLength),typeof e=="string"&&(this.bytesUsed+=e.length),this.isChunkComplete=!0}},{key:"getFullBatch",value:function(e){return this._isFull()?this._getBatch(e):null}},{key:"getFinalBatch",value:function(e){return this._getBatch(e)}},{key:"_estimateRowMB",value:function(e){return Array.isArray(e)?e.length*8:Object.keys(e).length*8}},{key:"_isFull",value:function(){if(!this.aggregator||this.aggregator.rowCount()===0)return!1;if(this.options.batchSize==="auto"){if(!this.isChunkComplete)return!1}else if(this.options.batchSize>this.aggregator.rowCount())return!1;return this.options.batchDebounceMs>Date.now()-this.lastBatchEmittedMs?!1:(this.isChunkComplete=!1,this.lastBatchEmittedMs=Date.now(),!0)}},{key:"_getBatch",value:function(e){if(!this.aggregator)return null;e!=null&&e.bytesUsed&&(this.bytesUsed=e.bytesUsed);var i=this.aggregator.getBatch();return i.count=this.batchCount,i.bytesUsed=this.bytesUsed,Object.assign(i,e),this.batchCount++,this.aggregator=null,i}},{key:"_getTableBatchType",value:function(){switch(this.options.shape){case"row-table":return j5;case"array-row-table":case"object-row-table":return W5;case"columnar-table":return rz;case"arrow-table":if(!t.ArrowBatch)throw new Error(az);return t.ArrowBatch;default:throw new Error(az)}}}]),t}();ve(c2,"ArrowBatch",void 0);function Ph(t){for(var r=1/0,e=1/0,i=1/0,n=-1/0,a=-1/0,o=-1/0,s=t.POSITION?t.POSITION.value:[],u=s&&s.length,c=0;c<u;c+=3){var h=s[c],v=s[c+1],b=s[c+2];r=h<r?h:r,e=v<e?v:e,i=b<i?b:i,n=h>n?h:n,a=v>a?v:a,o=b>o?b:o}return[[r,e,i],[n,a,o]]}var EM=C(Ms()),yz=C(Ge()),_z=C(Ye());function vz(t,r){if(!t)throw new Error(r||"loader assertion failed.")}function SM(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=Qbe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
515
515
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function Qbe(t,r){if(t){if(typeof t=="string")return Az(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return Az(t,r)}}function Az(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}var Ky=function(){function t(r,e){(0,yz.default)(this,t),ve(this,"fields",void 0),ve(this,"metadata",void 0),vz(Array.isArray(r)),Jbe(r),this.fields=r,this.metadata=e||new Map}return(0,_z.default)(t,[{key:"compareTo",value:function(e){if(this.metadata!==e.metadata||this.fields.length!==e.fields.length)return!1;for(var i=0;i<this.fields.length;++i)if(!this.fields[i].compareTo(e.fields[i]))return!1;return!0}},{key:"select",value:function(){for(var e=Object.create(null),i=arguments.length,n=new Array(i),a=0;a<i;a++)n[a]=arguments[a];for(var o=0,s=n;o<s.length;o++){var u=s[o];e[u]=!0}var c=this.fields.filter(function(h){return e[h.name]});return new t(c,this.metadata)}},{key:"selectAt",value:function(){for(var e=this,i=arguments.length,n=new Array(i),a=0;a<i;a++)n[a]=arguments[a];var o=n.map(function(s){return e.fields[s]}).filter(Boolean);return new t(o,this.metadata)}},{key:"assign",value:function(e){var i,n=this.metadata;if(e instanceof t){var a=e;i=a.fields,n=gz(gz(new Map,this.metadata),a.metadata)}else i=e;var o=Object.create(null),s=SM(this.fields),u;try{for(s.s();!(u=s.n()).done;){var c=u.value;o[c.name]=c}}catch(M){s.e(M)}finally{s.f()}var h=SM(i),v;try{for(h.s();!(v=h.n()).done;){var b=v.value;o[b.name]=b}}catch(M){h.e(M)}finally{h.f()}var S=Object.values(o);return new t(S,n)}}]),t}();function Jbe(t){var r={},e=SM(t),i;try{for(e.s();!(i=e.n()).done;){var n=i.value;r[n.name]&&console.warn("Schema: duplicated field name",n.name,n),r[n.name]=!0}}catch(a){e.e(a)}finally{e.f()}}function gz(t,r){return new Map([].concat((0,EM.default)(t||new Map),(0,EM.default)(r||new Map)))}var xz=C(Ge()),bz=C(Ye());var Qy=function(){function t(r,e){(0,xz.default)(this,t);var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:new Map;ve(this,"name",void 0),ve(this,"type",void 0),ve(this,"nullable",void 0),ve(this,"metadata",void 0),this.name=r,this.type=e,this.nullable=i,this.metadata=n}return(0,bz.default)(t,[{key:"typeId",get:function(){return this.type&&this.type.typeId}},{key:"clone",value:function(){return new t(this.name,this.type,this.nullable,this.metadata)}},{key:"compareTo",value:function(e){return this.name===e.name&&this.type===e.type&&this.nullable===e.nullable&&this.metadata===e.metadata}},{key:"toString",value:function(){return"".concat(this.type).concat(this.nullable?", nullable":"").concat(this.metadata?", metadata: ".concat(this.metadata):"")}}]),t}();var _l=C($r()),xi=C(It()),Sz=C(Rt()),IM=C(Mt()),di=C(Ge()),Ku=C(Ye());var _i;(function(t){t[t.NONE=0]="NONE",t[t.Null=1]="Null",t[t.Int=2]="Int",t[t.Float=3]="Float",t[t.Binary=4]="Binary",t[t.Utf8=5]="Utf8",t[t.Bool=6]="Bool",t[t.Decimal=7]="Decimal",t[t.Date=8]="Date",t[t.Time=9]="Time",t[t.Timestamp=10]="Timestamp",t[t.Interval=11]="Interval",t[t.List=12]="List",t[t.Struct=13]="Struct",t[t.Union=14]="Union",t[t.FixedSizeBinary=15]="FixedSizeBinary",t[t.FixedSizeList=16]="FixedSizeList",t[t.Map=17]="Map",t[t.Dictionary=-1]="Dictionary",t[t.Int8=-2]="Int8",t[t.Int16=-3]="Int16",t[t.Int32=-4]="Int32",t[t.Int64=-5]="Int64",t[t.Uint8=-6]="Uint8",t[t.Uint16=-7]="Uint16",t[t.Uint32=-8]="Uint32",t[t.Uint64=-9]="Uint64",t[t.Float16=-10]="Float16",t[t.Float32=-11]="Float32",t[t.Float64=-12]="Float64",t[t.DateDay=-13]="DateDay",t[t.DateMillisecond=-14]="DateMillisecond",t[t.TimestampSecond=-15]="TimestampSecond",t[t.TimestampMillisecond=-16]="TimestampMillisecond",t[t.TimestampMicrosecond=-17]="TimestampMicrosecond",t[t.TimestampNanosecond=-18]="TimestampNanosecond",t[t.TimeSecond=-19]="TimeSecond",t[t.TimeMillisecond=-20]="TimeMillisecond",t[t.TimeMicrosecond=-21]="TimeMicrosecond",t[t.TimeNanosecond=-22]="TimeNanosecond",t[t.DenseUnion=-23]="DenseUnion",t[t.SparseUnion=-24]="SparseUnion",t[t.IntervalDayTime=-25]="IntervalDayTime",t[t.IntervalYearMonth=-26]="IntervalYearMonth"})(_i||(_i={}));function Mi(t){var r=a2e();return function(){var i=(0,IM.default)(t),n;if(r){var a=(0,IM.default)(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return(0,Sz.default)(this,n)}}function a2e(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var Pz,Cz,Mz,Oz,Iz,Rz,Lz,kz,Qu=function(){function t(){(0,di.default)(this,t)}return(0,Ku.default)(t,[{key:"typeId",get:function(){return _i.NONE}},{key:"compareTo",value:function(e){return this===e}}],[{key:"isNull",value:function(e){return e&&e.typeId===_i.Null}},{key:"isInt",value:function(e){return e&&e.typeId===_i.Int}},{key:"isFloat",value:function(e){return e&&e.typeId===_i.Float}},{key:"isBinary",value:function(e){return e&&e.typeId===_i.Binary}},{key:"isUtf8",value:function(e){return e&&e.typeId===_i.Utf8}},{key:"isBool",value:function(e){return e&&e.typeId===_i.Bool}},{key:"isDecimal",value:function(e){return e&&e.typeId===_i.Decimal}},{key:"isDate",value:function(e){return e&&e.typeId===_i.Date}},{key:"isTime",value:function(e){return e&&e.typeId===_i.Time}},{key:"isTimestamp",value:function(e){return e&&e.typeId===_i.Timestamp}},{key:"isInterval",value:function(e){return e&&e.typeId===_i.Interval}},{key:"isList",value:function(e){return e&&e.typeId===_i.List}},{key:"isStruct",value:function(e){return e&&e.typeId===_i.Struct}},{key:"isUnion",value:function(e){return e&&e.typeId===_i.Union}},{key:"isFixedSizeBinary",value:function(e){return e&&e.typeId===_i.FixedSizeBinary}},{key:"isFixedSizeList",value:function(e){return e&&e.typeId===_i.FixedSizeList}},{key:"isMap",value:function(e){return e&&e.typeId===_i.Map}},{key:"isDictionary",value:function(e){return e&&e.typeId===_i.Dictionary}}]),t}(),Bz=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(){return(0,di.default)(this,i),e.apply(this,arguments)}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Null}},{key:r,get:function(){return"Null"}},{key:"toString",value:function(){return"Null"}}]),i}(Qu,Symbol.toStringTag),Dz=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(){return(0,di.default)(this,i),e.apply(this,arguments)}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Bool}},{key:r,get:function(){return"Bool"}},{key:"toString",value:function(){return"Bool"}}]),i}(Qu,Symbol.toStringTag);Pz=Symbol.toStringTag;var wf=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(n,a){var o;return(0,di.default)(this,i),o=e.call(this),ve((0,_l.default)(o),"isSigned",void 0),ve((0,_l.default)(o),"bitWidth",void 0),o.isSigned=n,o.bitWidth=a,o}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Int}},{key:r,get:function(){return"Int"}},{key:"toString",value:function(){return"".concat(this.isSigned?"I":"Ui","nt").concat(this.bitWidth)}}]),i}(Qu,Pz),h2=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,!0,8)}return e}(wf),p2=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,!0,16)}return e}(wf),d2=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,!0,32)}return e}(wf),Fz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,!0,64)}return e}(wf),m2=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,!1,8)}return e}(wf),v2=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,!1,16)}return e}(wf),A2=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,!1,32)}return e}(wf),Nz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,!1,64)}return e}(wf),RM={HALF:16,SINGLE:32,DOUBLE:64};Cz=Symbol.toStringTag;var Jy=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(n){var a;return(0,di.default)(this,i),a=e.call(this),ve((0,_l.default)(a),"precision",void 0),a.precision=n,a}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Float}},{key:r,get:function(){return"Float"}},{key:"toString",value:function(){return"Float".concat(this.precision)}}]),i}(Qu,Cz),zz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,RM.HALF)}return e}(Jy),g2=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,RM.SINGLE)}return e}(Jy),y2=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,RM.DOUBLE)}return e}(Jy),Uz=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(){return(0,di.default)(this,i),e.call(this)}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Binary}},{key:"toString",value:function(){return"Binary"}},{key:r,get:function(){return"Binary"}}]),i}(Qu,Symbol.toStringTag),jz=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(){return(0,di.default)(this,i),e.apply(this,arguments)}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Utf8}},{key:r,get:function(){return"Utf8"}},{key:"toString",value:function(){return"Utf8"}}]),i}(Qu,Symbol.toStringTag),LM={DAY:0,MILLISECOND:1};Mz=Symbol.toStringTag;var _2=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(n){var a;return(0,di.default)(this,i),a=e.call(this),ve((0,_l.default)(a),"unit",void 0),a.unit=n,a}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Date}},{key:r,get:function(){return"Date"}},{key:"toString",value:function(){return"Date".concat((this.unit+1)*32,"<").concat(LM[this.unit],">")}}]),i}(Qu,Mz),Gz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,LM.DAY)}return e}(_2),Vz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,LM.MILLISECOND)}return e}(_2),Vp={SECOND:1,MILLISECOND:1e3,MICROSECOND:1e6,NANOSECOND:1e9};Oz=Symbol.toStringTag;var x2=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(n,a){var o;return(0,di.default)(this,i),o=e.call(this),ve((0,_l.default)(o),"unit",void 0),ve((0,_l.default)(o),"bitWidth",void 0),o.unit=n,o.bitWidth=a,o}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Time}},{key:"toString",value:function(){return"Time".concat(this.bitWidth,"<").concat(Vp[this.unit],">")}},{key:r,get:function(){return"Time"}}]),i}(Qu,Oz),Hz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,Vp.SECOND,32)}return e}(x2),Wz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,Vp.MILLISECOND,32)}return e}(x2);Iz=Symbol.toStringTag;var RA=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(n){var a;(0,di.default)(this,i);var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;return a=e.call(this),ve((0,_l.default)(a),"unit",void 0),ve((0,_l.default)(a),"timezone",void 0),a.unit=n,a.timezone=o,a}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Timestamp}},{key:r,get:function(){return"Timestamp"}},{key:"toString",value:function(){return"Timestamp<".concat(Vp[this.unit]).concat(this.timezone?", ".concat(this.timezone):"",">")}}]),i}(Qu,Iz),qz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){(0,di.default)(this,e);var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null;return r.call(this,Vp.SECOND,i)}return e}(RA),Xz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){(0,di.default)(this,e);var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null;return r.call(this,Vp.MILLISECOND,i)}return e}(RA),Zz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){(0,di.default)(this,e);var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null;return r.call(this,Vp.MICROSECOND,i)}return e}(RA),Yz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){(0,di.default)(this,e);var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null;return r.call(this,Vp.NANOSECOND,i)}return e}(RA),kM={DAY_TIME:0,YEAR_MONTH:1};Rz=Symbol.toStringTag;var b2=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(n){var a;return(0,di.default)(this,i),a=e.call(this),ve((0,_l.default)(a),"unit",void 0),a.unit=n,a}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Interval}},{key:r,get:function(){return"Interval"}},{key:"toString",value:function(){return"Interval<".concat(kM[this.unit],">")}}]),i}(Qu,Rz),Kz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,kM.DAY_TIME)}return e}(b2),Qz=function(t){(0,xi.default)(e,t);var r=Mi(e);function e(){return(0,di.default)(this,e),r.call(this,kM.YEAR_MONTH)}return e}(b2);Lz=Symbol.toStringTag;var w2=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(n,a){var o;return(0,di.default)(this,i),o=e.call(this),ve((0,_l.default)(o),"listSize",void 0),ve((0,_l.default)(o),"children",void 0),o.listSize=n,o.children=[a],o}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.FixedSizeList}},{key:"valueType",get:function(){return this.children[0].type}},{key:"valueField",get:function(){return this.children[0]}},{key:r,get:function(){return"FixedSizeList"}},{key:"toString",value:function(){return"FixedSizeList[".concat(this.listSize,"]<").concat(this.valueType,">")}}]),i}(Qu,Lz);kz=Symbol.toStringTag;var Jz=function(t,r){(0,xi.default)(i,t);var e=Mi(i);function i(n){var a;return(0,di.default)(this,i),a=e.call(this),ve((0,_l.default)(a),"children",void 0),a.children=n,a}return(0,Ku.default)(i,[{key:"typeId",get:function(){return _i.Struct}},{key:"toString",value:function(){return"Struct<{".concat(this.children.map(function(a){return"".concat(a.name,":").concat(a.type)}).join(", "),"}>")}},{key:r,get:function(){return"Struct"}}]),i}(Qu,kz);function $z(t){switch(t.constructor){case Int8Array:return new h2;case Uint8Array:return new m2;case Int16Array:return new p2;case Uint16Array:return new v2;case Int32Array:return new d2;case Uint32Array:return new A2;case Float32Array:return new g2;case Float64Array:return new y2;default:throw new Error("array type not supported")}}function BM(t,r,e){var i=$z(r.value),n=e||eU(r),a=new Qy(t,new w2(r.size,new Qy("value",i)),!1,n);return a}function eU(t){var r=new Map;return"byteOffset"in t&&r.set("byteOffset",t.byteOffset.toString(10)),"byteStride"in t&&r.set("byteStride",t.byteStride.toString(10)),"normalized"in t&&r.set("normalized",t.normalized.toString()),r}var p2e=C(Vr()),UM=C(Ge()),jM=C(Ye()),aU=C(It()),oU=C(Rt()),zM=C(Mt()),sU=C(nU()),d2e=C(zr());function m2e(t){var r=v2e();return function(){var i=(0,zM.default)(t),n;if(r){var a=(0,zM.default)(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return(0,oU.default)(this,n)}}function v2e(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var uU,iU=function(t){(0,aU.default)(e,t);var r=m2e(e);function e(){return(0,UM.default)(this,e),r.apply(this,arguments)}return(0,jM.default)(e,[{key:"enqueue",value:function(n){return this.push(n)}},{key:"dequeue",value:function(){return this.shift()}}]),e}((0,sU.default)(Array));uU=Symbol.asyncIterator;var GM=function(t){function r(){(0,UM.default)(this,r),ve(this,"_values",void 0),ve(this,"_settlers",void 0),ve(this,"_closed",void 0),this._values=new iU,this._settlers=new iU,this._closed=!1}return(0,jM.default)(r,[{key:"close",value:function(){for(;this._settlers.length>0;)this._settlers.dequeue().resolve({done:!0});this._closed=!0}},{key:t,value:function(){return this}},{key:"enqueue",value:function(i){if(this._closed)throw new Error("Closed");if(this._settlers.length>0){if(this._values.length>0)throw new Error("Illegal internal state");var n=this._settlers.dequeue();i instanceof Error?n.reject(i):n.resolve({value:i})}else this._values.enqueue(i)}},{key:"next",value:function(){var i=this;if(this._values.length>0){var n=this._values.dequeue();return n instanceof Error?Promise.reject(n):Promise.resolve({value:n})}if(this._closed){if(this._settlers.length>0)throw new Error("Illegal internal state");return Promise.resolve({done:!0})}return new Promise(function(a,o){i._settlers.enqueue({resolve:a,reject:o})})}}]),r}(uU);var fm=C(Xn());var lU="\uFEFF",Tf={parse:A2e,unparse:g2e,RECORD_SEP:String.fromCharCode(30),UNIT_SEP:String.fromCharCode(31),BYTE_ORDER_MARK:lU,BAD_DELIMITERS:["\r",`
|
|
516
516
|
`,'"',lU],WORKERS_SUPPORTED:!1,NODE_STREAM_INPUT:1,LocalChunkSize:1024*1024*10,RemoteChunkSize:1024*1024*5,DefaultDelimiter:",",Parser:VM,ParserHandle:fU,ChunkStreamer:cU,StringStreamer:LA},kA=Tf;function A2e(t,r,e){r=r||{};var i=r.dynamicTyping||!1;if(wu(i)&&(r.dynamicTypingFunction=i,i={}),r.dynamicTyping=i,r.transform=wu(r.transform)?r.transform:!1,r.worker&&Tf.WORKERS_SUPPORTED){var n=newWorker();n.userStep=r.step,n.userChunk=r.chunk,n.userComplete=r.complete,n.userError=r.error,r.step=wu(r.step),r.chunk=wu(r.chunk),r.complete=wu(r.complete),r.error=wu(r.error),delete r.worker,n.postMessage({input:t,config:r,workerId:n.id});return}var a=null;return typeof t=="string"&&(a=new LA(r)),a||(a=new e(r)),a.stream(t)}function g2e(t,r){var e=!1,i=!0,n=",",a=`\r
|
|
517
517
|
`,o='"',s=o+o,u=!1,c=null;v();var h=new RegExp($y(o),"g");if(typeof t=="string"&&(t=JSON.parse(t)),Array.isArray(t)){if(!t.length||Array.isArray(t[0]))return S(null,t,u);if((0,fm.default)(t[0])==="object")return S(c||b(t[0]),t,u)}else if((0,fm.default)(t)==="object")return typeof t.data=="string"&&(t.data=JSON.parse(t.data)),Array.isArray(t.data)&&(t.fields||(t.fields=t.meta&&t.meta.fields),t.fields||(t.fields=Array.isArray(t.data[0])?t.fields:b(t.data[0])),!Array.isArray(t.data[0])&&(0,fm.default)(t.data[0])!=="object"&&(t.data=[t.data])),S(t.fields||[],t.data||[],u);throw new Error("Unable to serialize unrecognized input");function v(){if((0,fm.default)(r)==="object"){if(typeof r.delimiter=="string"&&!Tf.BAD_DELIMITERS.filter(function(N){return r.delimiter.indexOf(N)!==-1}).length&&(n=r.delimiter),(typeof r.quotes=="boolean"||Array.isArray(r.quotes))&&(e=r.quotes),(typeof r.skipEmptyLines=="boolean"||typeof r.skipEmptyLines=="string")&&(u=r.skipEmptyLines),typeof r.newline=="string"&&(a=r.newline),typeof r.quoteChar=="string"&&(o=r.quoteChar),typeof r.header=="boolean"&&(i=r.header),Array.isArray(r.columns)){if(r.columns.length===0)throw new Error("Option columns is empty");c=r.columns}r.escapeChar!==void 0&&(s=r.escapeChar+o)}}function b(N){if((0,fm.default)(N)!=="object")return[];var j=[];for(var V in N)j.push(V);return j}function S(N,j,V){var H="";typeof N=="string"&&(N=JSON.parse(N)),typeof j=="string"&&(j=JSON.parse(j));var X=Array.isArray(N)&&N.length>0,Y=!Array.isArray(j[0]);if(X&&i){for(var te=0;te<N.length;te++)te>0&&(H+=n),H+=M(N[te],te);j.length>0&&(H+=a)}for(var se=0;se<j.length;se++){var ie=X?N.length:j[se].length,le=!1,re=X?Object.keys(j[se]).length===0:j[se].length===0;if(V&&!X&&(le=V==="greedy"?j[se].join("").trim()==="":j[se].length===1&&j[se][0].length===0),V==="greedy"&&X){for(var we=[],be=0;be<ie;be++){var ze=Y?N[be]:be;we.push(j[se][ze])}le=we.join("").trim()===""}if(!le){for(var Fe=0;Fe<ie;Fe++){Fe>0&&!re&&(H+=n);var Me=X&&Y?N[Fe]:Fe;H+=M(j[se][Me],Fe)}se<j.length-1&&(!V||ie>0&&!re)&&(H+=a)}}return H}function M(N,j){if(typeof N>"u"||N===null)return"";if(N.constructor===Date)return JSON.stringify(N).slice(1,25);N=N.toString().replace(h,s);var V=typeof e=="boolean"&&e||Array.isArray(e)&&e[j]||k(N,Tf.BAD_DELIMITERS)||N.indexOf(n)>-1||N.charAt(0)===" "||N.charAt(N.length-1)===" ";return V?o+N+o:N}function k(N,j){for(var V=0;V<j.length;V++)if(N.indexOf(j[V])>-1)return!0;return!1}}function cU(t){this._handle=null,this._finished=!1,this._completed=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},r.call(this,t),this.parseChunk=function(e,i){if(this.isFirstChunk&&wu(this._config.beforeFirstChunk)){var n=this._config.beforeFirstChunk(e);n!==void 0&&(e=n)}this.isFirstChunk=!1;var a=this._partialLine+e;this._partialLine="";var o=this._handle.parse(a,this._baseIndex,!this._finished);if(!(this._handle.paused()||this._handle.aborted())){var s=o.meta.cursor;this._finished||(this._partialLine=a.substring(s-this._baseIndex),this._baseIndex=s),o&&o.data&&(this._rowCount+=o.data.length);var u=this._finished||this._config.preview&&this._rowCount>=this._config.preview;if(wu(this._config.chunk)&&!i){if(this._config.chunk(o,this._handle),this._handle.paused()||this._handle.aborted())return;o=void 0,this._completeResults=void 0}return!this._config.step&&!this._config.chunk&&(this._completeResults.data=this._completeResults.data.concat(o.data),this._completeResults.errors=this._completeResults.errors.concat(o.errors),this._completeResults.meta=o.meta),!this._completed&&u&&wu(this._config.complete)&&(!o||!o.meta.aborted)&&(this._config.complete(this._completeResults,this._input),this._completed=!0),!u&&(!o||!o.meta.paused)&&this._nextChunk(),o}},this._sendError=function(e){wu(this._config.error)&&this._config.error(e)};function r(e){var i=HM(e);i.chunkSize=parseInt(i.chunkSize),!e.step&&!e.chunk&&(i.chunkSize=null),this._handle=new fU(i),this._handle.streamer=this,this._config=i}}function LA(t){t=t||{},cU.call(this,t);var r;this.stream=function(e){return r=e,this._nextChunk()},this._nextChunk=function(){if(!this._finished){var e=this._config.chunkSize,i=e?r.substr(0,e):r;return r=e?r.substr(e):"",this._finished=!r,this.parseChunk(i)}}}LA.prototype=Object.create(LA.prototype);LA.prototype.constructor=LA;function fU(t){var r=/^\s*-?(\d*\.?\d+|\d+\.?\d*)(e[-+]?\d+)?\s*$/i,e=/(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))/,i=this,n=0,a=0,o,s,u=!1,c=!1,h,v=[],b={data:[],errors:[],meta:{}};if(wu(t.step)){var S=t.step;t.step=function(ie){if(b=ie,N())k();else{if(k(),!b.data||b.data.length===0)return;n+=ie.data.length,t.preview&&n>t.preview?s.abort():S(b,i)}}}this.parse=function(ie,le,re){var we=t.quoteChar||'"';if(t.newline||(t.newline=te(ie,we)),h=!1,t.delimiter)wu(t.delimiter)&&(t.delimiter=t.delimiter(ie),b.meta.delimiter=t.delimiter);else{var be=Y(ie,t.newline,t.skipEmptyLines,t.comments,t.delimitersToGuess);be.successful?t.delimiter=be.bestDelimiter:(h=!0,t.delimiter=Tf.DefaultDelimiter),b.meta.delimiter=t.delimiter}var ze=HM(t);return t.preview&&t.header&&ze.preview++,o=ie,s=new VM(ze),b=s.parse(o,le,re),k(),u?{meta:{paused:!0}}:b||{meta:{paused:!1}}},this.paused=function(){return u},this.pause=function(){u=!0,s.abort(),o=o.substr(s.getCharIndex())},this.resume=function(){u=!1,i.streamer.parseChunk(o,!0)},this.aborted=function(){return c},this.abort=function(){c=!0,s.abort(),b.meta.aborted=!0,wu(t.complete)&&t.complete(b),o=""};function M(ie){return t.skipEmptyLines==="greedy"?ie.join("").trim()==="":ie.length===1&&ie[0].length===0}function k(){if(b&&h&&(se("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+Tf.DefaultDelimiter+"'"),h=!1),t.skipEmptyLines)for(var ie=0;ie<b.data.length;ie++)M(b.data[ie])&&b.data.splice(ie--,1);return N()&&j(),X()}function N(){return t.header&&v.length===0}function j(){if(!b)return;function ie(re){wu(t.transformHeader)&&(re=t.transformHeader(re)),v.push(re)}if(Array.isArray(b.data[0])){for(var le=0;N()&&le<b.data.length;le++)b.data[le].forEach(ie);b.data.splice(0,1)}else b.data.forEach(ie)}function V(ie){return t.dynamicTypingFunction&&t.dynamicTyping[ie]===void 0&&(t.dynamicTyping[ie]=t.dynamicTypingFunction(ie)),(t.dynamicTyping[ie]||t.dynamicTyping)===!0}function H(ie,le){return V(ie)?le==="true"||le==="TRUE"?!0:le==="false"||le==="FALSE"?!1:r.test(le)?parseFloat(le):e.test(le)?new Date(le):le===""?null:le:le}function X(){if(!b||!b.data||!t.header&&!t.dynamicTyping&&!t.transform)return b;function ie(re,we){var be=t.header?{}:[],ze;for(ze=0;ze<re.length;ze++){var Fe=ze,Me=re[ze];t.header&&(Fe=ze>=v.length?"__parsed_extra":v[ze]),t.transform&&(Me=t.transform(Me,Fe)),Me=H(Fe,Me),Fe==="__parsed_extra"?(be[Fe]=be[Fe]||[],be[Fe].push(Me)):be[Fe]=Me}return t.header&&(ze>v.length?se("FieldMismatch","TooManyFields","Too many fields: expected "+v.length+" fields but parsed "+ze,a+we):ze<v.length&&se("FieldMismatch","TooFewFields","Too few fields: expected "+v.length+" fields but parsed "+ze,a+we)),be}var le=1;return!b.data[0]||Array.isArray(b.data[0])?(b.data=b.data.map(ie),le=b.data.length):b.data=ie(b.data,0),t.header&&b.meta&&(b.meta.fields=v),a+=le,b}function Y(ie,le,re,we,be){var ze,Fe,Me;be=be||[","," ","|",";",Tf.RECORD_SEP,Tf.UNIT_SEP];for(var Ve=0;Ve<be.length;Ve++){var He=be[Ve],ot=0,Je=0,wt=0;Me=void 0;for(var xt=new VM({comments:we,delimiter:He,newline:le,preview:10}).parse(ie),zt=0;zt<xt.data.length;zt++){if(re&&M(xt.data[zt])){wt++;continue}var yt=xt.data[zt].length;if(Je+=yt,typeof Me>"u"){Me=0;continue}else yt>1&&(ot+=Math.abs(yt-Me),Me=yt)}xt.data.length>0&&(Je/=xt.data.length-wt),(typeof Fe>"u"||ot>Fe)&&Je>1.99&&(Fe=ot,ze=He)}return t.delimiter=ze,{successful:!!ze,bestDelimiter:ze}}function te(ie,le){ie=ie.substr(0,1024*1024);var re=new RegExp($y(le)+"([^]*?)"+$y(le),"gm");ie=ie.replace(re,"");var we=ie.split("\r"),be=ie.split(`
|
|
@@ -528,12 +528,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
528
528
|
throw error;
|
|
529
529
|
}`)}var NU=C(Xn());function QM(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,e=arguments.length>2?arguments[2]:void 0,i=e||new Set;if(t){if(FU(t))i.add(t);else if(FU(t.buffer))i.add(t.buffer);else if(!ArrayBuffer.isView(t)){if(r&&(0,NU.default)(t)==="object")for(var n in t)QM(t[n],r,i)}}return e===void 0?Array.from(i):[]}function FU(t){return t?t instanceof ArrayBuffer||typeof MessagePort<"u"&&t instanceof MessagePort||typeof ImageBitmap<"u"&&t instanceof ImageBitmap||typeof OffscreenCanvas<"u"&&t instanceof OffscreenCanvas:!1}var JM=function(){},n_=function(){function t(r){(0,zU.default)(this,t),ve(this,"name",void 0),ve(this,"source",void 0),ve(this,"url",void 0),ve(this,"terminated",!1),ve(this,"worker",void 0),ve(this,"onMessage",void 0),ve(this,"onError",void 0),ve(this,"_loadableURL","");var e=r.name,i=r.source,n=r.url;Os(i||n),this.name=e,this.source=i,this.url=n,this.onMessage=JM,this.onError=function(a){return console.log(a)},this.worker=Tu?this._createBrowserWorker():this._createNodeWorker()}return(0,UU.default)(t,[{key:"destroy",value:function(){this.onMessage=JM,this.onError=JM,this.worker.terminate(),this.terminated=!0}},{key:"isRunning",get:function(){return Boolean(this.onMessage)}},{key:"postMessage",value:function(e,i){i=i||QM(e),this.worker.postMessage(e,i)}},{key:"_getErrorFromErrorEvent",value:function(e){var i="Failed to load ";return i+="worker ".concat(this.name," from ").concat(this.url,". "),e.message&&(i+="".concat(e.message," in ")),e.lineno&&(i+=":".concat(e.lineno,":").concat(e.colno)),new Error(i)}},{key:"_createBrowserWorker",value:function(){var e=this;this._loadableURL=BU({source:this.source,url:this.url});var i=new Worker(this._loadableURL,{name:this.name});return i.onmessage=function(n){n.data?e.onMessage(n.data):e.onError(new Error("No data received"))},i.onerror=function(n){e.onError(e._getErrorFromErrorEvent(n)),e.terminated=!0},i.onmessageerror=function(n){return console.error(n)},i}},{key:"_createNodeWorker",value:function(){var e=this,i;if(this.url){var n=this.url.includes(":/")||this.url.startsWith("/"),a=n?this.url:"./".concat(this.url);i=new S2(a,{eval:!1})}else if(this.source)i=new S2(this.source,{eval:!0});else throw new Error("no worker");return i.on("message",function(o){e.onMessage(o)}),i.on("error",function(o){e.onError(o)}),i.on("exit",function(o){}),i}}],[{key:"isSupported",value:function(){return typeof Worker<"u"&&Tu||typeof S2<"u"&&!Tu}}]),t}();var KU=C(Ke()),QU=C(Ge()),JU=C(Ye());var $M=C(Vr()),VU=C(Ke()),HU=C(Ge()),WU=C(Ye()),i_=C(zr());function jU(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function GU(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?jU(Object(e),!0).forEach(function(i){(0,VU.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):jU(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}var qU=function(){function t(r){(0,HU.default)(this,t),ve(this,"name","unnamed"),ve(this,"source",void 0),ve(this,"url",void 0),ve(this,"maxConcurrency",1),ve(this,"maxMobileConcurrency",1),ve(this,"onDebug",function(){}),ve(this,"reuseWorkers",!0),ve(this,"props",{}),ve(this,"jobQueue",[]),ve(this,"idleQueue",[]),ve(this,"count",0),ve(this,"isDestroyed",!1),this.source=r.source,this.url=r.url,this.setProps(r)}return(0,WU.default)(t,[{key:"destroy",value:function(){this.idleQueue.forEach(function(e){return e.destroy()}),this.isDestroyed=!0}},{key:"setProps",value:function(e){this.props=GU(GU({},this.props),e),e.name!==void 0&&(this.name=e.name),e.maxConcurrency!==void 0&&(this.maxConcurrency=e.maxConcurrency),e.maxMobileConcurrency!==void 0&&(this.maxMobileConcurrency=e.maxMobileConcurrency),e.reuseWorkers!==void 0&&(this.reuseWorkers=e.reuseWorkers),e.onDebug!==void 0&&(this.onDebug=e.onDebug)}},{key:"startJob",value:function(){var r=(0,$M.default)(i_.default.mark(function i(n){var a=this,o,s,u,c=arguments;return i_.default.wrap(function(v){for(;;)switch(v.prev=v.next){case 0:return o=c.length>1&&c[1]!==void 0?c[1]:function(b,S,M){return b.done(M)},s=c.length>2&&c[2]!==void 0?c[2]:function(b,S){return b.error(S)},u=new Promise(function(b){return a.jobQueue.push({name:n,onMessage:o,onError:s,onStart:b}),a}),this._startQueuedJob(),v.next=6,u;case 6:return v.abrupt("return",v.sent);case 7:case"end":return v.stop()}},i,this)}));function e(i){return r.apply(this,arguments)}return e}()},{key:"_startQueuedJob",value:function(){var r=(0,$M.default)(i_.default.mark(function i(){var n,a,o;return i_.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:if(this.jobQueue.length){u.next=2;break}return u.abrupt("return");case 2:if(n=this._getAvailableWorker(),n){u.next=5;break}return u.abrupt("return");case 5:if(a=this.jobQueue.shift(),!a){u.next=18;break}return this.onDebug({message:"Starting job",name:a.name,workerThread:n,backlog:this.jobQueue.length}),o=new RU(a.name,n),n.onMessage=function(c){return a.onMessage(o,c.type,c.payload)},n.onError=function(c){return a.onError(o,c)},a.onStart(o),u.prev=12,u.next=15,o.result;case 15:return u.prev=15,this.returnWorkerToQueue(n),u.finish(15);case 18:case"end":return u.stop()}},i,this,[[12,,15,18]])}));function e(){return r.apply(this,arguments)}return e}()},{key:"returnWorkerToQueue",value:function(e){var i=this.isDestroyed||!this.reuseWorkers||this.count>this._getMaxConcurrency();i?(e.destroy(),this.count--):this.idleQueue.push(e),this.isDestroyed||this._startQueuedJob()}},{key:"_getAvailableWorker",value:function(){if(this.idleQueue.length>0)return this.idleQueue.shift()||null;if(this.count<this._getMaxConcurrency()){this.count++;var e="".concat(this.name.toLowerCase()," (#").concat(this.count," of ").concat(this.maxConcurrency,")");return new n_({name:e,source:this.source,url:this.url})}return null}},{key:"_getMaxConcurrency",value:function(){return MU?this.maxMobileConcurrency:this.maxConcurrency}}],[{key:"isSupported",value:function(){return n_.isSupported()}}]),t}();function XU(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=I2e(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
530
530
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function I2e(t,r){if(t){if(typeof t=="string")return ZU(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return ZU(t,r)}}function ZU(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}function YU(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function eO(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?YU(Object(e),!0).forEach(function(i){(0,KU.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):YU(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}var R2e={maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:!0,onDebug:function(){}},a_=function(){function t(r){(0,QU.default)(this,t),ve(this,"props",void 0),ve(this,"workerPools",new Map),this.props=eO({},R2e),this.setProps(r),this.workerPools=new Map}return(0,JU.default)(t,[{key:"destroy",value:function(){var e=XU(this.workerPools.values()),i;try{for(e.s();!(i=e.n()).done;){var n=i.value;n.destroy()}}catch(a){e.e(a)}finally{e.f()}this.workerPools=new Map}},{key:"setProps",value:function(e){this.props=eO(eO({},this.props),e);var i=XU(this.workerPools.values()),n;try{for(i.s();!(n=i.n()).done;){var a=n.value;a.setProps(this._getWorkerPoolProps())}}catch(o){i.e(o)}finally{i.f()}}},{key:"getWorkerPool",value:function(e){var i=e.name,n=e.source,a=e.url,o=this.workerPools.get(i);return o||(o=new qU({name:i,source:n,url:a}),o.setProps(this._getWorkerPoolProps()),this.workerPools.set(i,o)),o}},{key:"_getWorkerPoolProps",value:function(){return{maxConcurrency:this.props.maxConcurrency,maxMobileConcurrency:this.props.maxMobileConcurrency,reuseWorkers:this.props.reuseWorkers,onDebug:this.props.onDebug}}}],[{key:"isSupported",value:function(){return n_.isSupported()}},{key:"getWorkerFarm",value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return t._workerFarm=t._workerFarm||new t({}),t._workerFarm.setProps(e),t._workerFarm}}]),t}();ve(a_,"_workerFarm",void 0);var L2e="latest";function tO(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},e=r[t.id]||{},i="".concat(t.id,"-worker.js"),n=e.workerUrl;if(!n&&t.id==="compression"&&(n=r.workerUrl),r._workerType==="test"&&(n="modules/".concat(t.module,"/dist/").concat(i)),!n){var a=t.version;a==="latest"&&(a=L2e);var o=a?"@".concat(a):"";n="https://unpkg.com/@loaders.gl/".concat(t.module).concat(o,"/dist/").concat(i)}return Os(n),n}function rO(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:EU;Os(t,"no worker provided");var e=t.version;return!(!r||!e)}var oO=C(Vr()),o_=C(zr());var hm=C($U());var k2e="3.3.1",nO={};function Cf(t){return iO.apply(this,arguments)}function iO(){return iO=(0,oO.default)(o_.default.mark(function t(r){var e,i,n=arguments;return o_.default.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:return e=n.length>1&&n[1]!==void 0?n[1]:null,i=n.length>2&&n[2]!==void 0?n[2]:{},e&&(r=ej(r,e,i)),nO[r]=nO[r]||B2e(r),o.next=6,nO[r];case 6:return o.abrupt("return",o.sent);case 7:case"end":return o.stop()}},t)})),iO.apply(this,arguments)}function ej(t,r,e){if(t.startsWith("http"))return t;var i=e.modules||{};return i[t]?i[t]:Tu?e.CDN?(Os(e.CDN.startsWith("http")),"".concat(e.CDN,"/").concat(r,"@").concat(k2e,"/dist/libs/").concat(t)):r_?"../src/libs/".concat(t):"modules/".concat(r,"/src/libs/").concat(t):"modules/".concat(r,"/dist/libs/").concat(t)}function B2e(t){return aO.apply(this,arguments)}function aO(){return aO=(0,oO.default)(o_.default.mark(function t(r){var e,i,n;return o_.default.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(!r.endsWith("wasm")){o.next=7;break}return o.next=3,fetch(r);case 3:return e=o.sent,o.next=6,e.arrayBuffer();case 6:return o.abrupt("return",o.sent);case 7:if(Tu){o.next=20;break}if(o.prev=8,o.t0=hm&&hm.requireFromFile,!o.t0){o.next=14;break}return o.next=13,hm.requireFromFile(r);case 13:o.t0=o.sent;case 14:return o.abrupt("return",o.t0);case 17:return o.prev=17,o.t1=o.catch(8),o.abrupt("return",null);case 20:if(!r_){o.next=22;break}return o.abrupt("return",importScripts(r));case 22:return o.next=24,fetch(r);case 24:return i=o.sent,o.next=27,i.text();case 27:return n=o.sent,o.abrupt("return",D2e(n,r));case 29:case"end":return o.stop()}},t,null,[[8,17]])})),aO.apply(this,arguments)}function D2e(t,r){if(!Tu)return hm.requireFromString&&hm.requireFromString(t,r);if(r_)return eval.call(CU,t),null;var e=document.createElement("script");e.id=r;try{e.appendChild(document.createTextNode(t))}catch{e.text=t}return document.body.appendChild(e),null}var lO=C(Vr()),s_=C(zr());function cO(t,r){return!a_.isSupported()||!Tu&&!(r!=null&&r._nodeWorkers)?!1:t.worker&&r?.worker}function fO(t,r,e,i,n){return sO.apply(this,arguments)}function sO(){return sO=(0,lO.default)(s_.default.mark(function t(r,e,i,n,a){var o,s,u,c,h,v;return s_.default.wrap(function(S){for(;;)switch(S.prev=S.next){case 0:return o=r.id,s=tO(r,i),u=a_.getWorkerFarm(i),c=u.getWorkerPool({name:o,url:s}),i=JSON.parse(JSON.stringify(i)),n=JSON.parse(JSON.stringify(n||{})),S.next=8,c.startJob("process-on-worker",F2e.bind(null,a));case 8:return h=S.sent,h.postMessage("process",{input:e,options:i,context:n}),S.next=12,h.result;case 12:return v=S.sent,S.next=15,v.result;case 15:return S.abrupt("return",S.sent);case 16:case"end":return S.stop()}},t)})),sO.apply(this,arguments)}function F2e(t,r,e,i){return uO.apply(this,arguments)}function uO(){return uO=(0,lO.default)(s_.default.mark(function t(r,e,i,n){var a,o,s,u,c;return s_.default.wrap(function(v){for(;;)switch(v.prev=v.next){case 0:v.t0=i,v.next=v.t0==="done"?3:v.t0==="error"?5:v.t0==="process"?7:20;break;case 3:return e.done(n),v.abrupt("break",21);case 5:return e.error(new Error(n.error)),v.abrupt("break",21);case 7:return a=n.id,o=n.input,s=n.options,v.prev=8,v.next=11,r(o,s);case 11:u=v.sent,e.postMessage("done",{id:a,result:u}),v.next=19;break;case 15:v.prev=15,v.t1=v.catch(8),c=v.t1 instanceof Error?v.t1.message:"unknown error",e.postMessage("error",{id:a,error:c});case 19:return v.abrupt("break",21);case 20:console.warn("parse-with-worker unknown message ".concat(i));case 21:case"end":return v.stop()}},t,null,[[8,15]])})),uO.apply(this,arguments)}function rj(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:5;if(typeof t=="string")return t.slice(0,r);if(ArrayBuffer.isView(t))return tj(t.buffer,t.byteOffset,r);if(t instanceof ArrayBuffer){var e=0;return tj(t,e,r)}return""}function tj(t,r,e){if(t.byteLength<=r+e)return"";for(var i=new DataView(t),n="",a=0;a<e;a++)n+=String.fromCharCode(i.getUint8(r+a));return n}function hO(t){try{return JSON.parse(t)}catch{throw new Error('Failed to parse JSON from data starting with "'.concat(rj(t),'"'))}}function N2e(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=z2e(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
531
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function z2e(t,r){if(t){if(typeof t=="string")return nj(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return nj(t,r)}}function nj(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}function pO(t,r,e){if(e=e||t.byteLength,t.byteLength<e||r.byteLength<e)return!1;for(var i=new Uint8Array(t),n=new Uint8Array(r),a=0;a<i.length;++a)if(i[a]!==n[a])return!1;return!0}function dO(){for(var t=arguments.length,r=new Array(t),e=0;e<t;e++)r[e]=arguments[e];var i=r.map(function(h){return h instanceof ArrayBuffer?new Uint8Array(h):h}),n=i.reduce(function(h,v){return h+v.byteLength},0),a=new Uint8Array(n),o=0,s=N2e(i),u;try{for(s.s();!(u=s.n()).done;){var c=u.value;a.set(c,o),o+=c.byteLength}}catch(h){s.e(h)}finally{s.f()}return a.buffer}function u_(){for(var t=arguments.length,r=new Array(t),e=0;e<t;e++)r[e]=arguments[e];var i=r,n=i&&i.length>1&&i[0].constructor||null;if(!n)throw new Error('"concatenateTypedArrays" - incorrect quantity of arguments or arguments have incompatible data types');for(var a=i.reduce(function(v,b){return v+b.length},0),o=new n(a),s=0,u=0,c=i;u<c.length;u++){var h=c[u];o.set(h,s),s+=h.length}return o}function pm(t,r,e){var i=e!==void 0?new Uint8Array(t).subarray(r,r+e):new Uint8Array(t).subarray(r),n=new Uint8Array(i);return n.buffer}function Hp(t,r){return Un(t>=0),Un(r>0),t+(r-1)&~(r-1)}function mO(t,r,e){var i;if(t instanceof ArrayBuffer)i=new Uint8Array(t);else{var n=t.byteOffset,a=t.byteLength;i=new Uint8Array(t.buffer||t.arrayBuffer,n,a)}return r.set(i,e),e+Hp(i.byteLength,4)}var lj=C(Vr()),cj=C(e_()),yO=C(zr());function xO(t){return _O.apply(this,arguments)}function _O(){return _O=(0,lj.default)(yO.default.mark(function t(r){var e,i,n,a,o,s,u;return yO.default.wrap(function(h){for(;;)switch(h.prev=h.next){case 0:e=[],i=!1,n=!1,h.prev=3,o=(0,cj.default)(r);case 5:return h.next=7,o.next();case 7:if(!(i=!(s=h.sent).done)){h.next=13;break}u=s.value,e.push(u);case 10:i=!1,h.next=5;break;case 13:h.next=19;break;case 15:h.prev=15,h.t0=h.catch(3),n=!0,a=h.t0;case 19:if(h.prev=19,h.prev=20,!(i&&o.return!=null)){h.next=24;break}return h.next=24,o.return();case 24:if(h.prev=24,!n){h.next=27;break}throw a;case 27:return h.finish(24);case 28:return h.finish(19);case 29:return h.abrupt("return",dO.apply(void 0,e));case 30:case"end":return h.stop()}},t,null,[[3,15,19,29],[20,,24,28]])})),_O.apply(this,arguments)}var Aj=C(Ke()),gj=C(Ge()),yj=C(Ye());var pj=C(Ge()),dj=C(Ye());var fj=C(Ge()),hj=C(Ye());function c_(){var t;if(typeof window<"u"&&window.performance)t=window.performance.now();else if(typeof process<"u"&&process.hrtime){var r=process.hrtime();t=r[0]*1e3+r[1]/1e6}else t=Date.now();return t}var P2=function(){function t(r,e){(0,fj.default)(this,t),ve(this,"name",void 0),ve(this,"type",void 0),ve(this,"sampleSize",1),ve(this,"time",void 0),ve(this,"count",void 0),ve(this,"samples",void 0),ve(this,"lastTiming",void 0),ve(this,"lastSampleTime",void 0),ve(this,"lastSampleCount",void 0),ve(this,"_count",0),ve(this,"_time",0),ve(this,"_samples",0),ve(this,"_startTime",0),ve(this,"_timerPending",!1),this.name=r,this.type=e,this.reset()}return(0,hj.default)(t,[{key:"setSampleSize",value:function(e){return this.sampleSize=e,this}},{key:"incrementCount",value:function(){return this.addCount(1),this}},{key:"decrementCount",value:function(){return this.subtractCount(1),this}},{key:"addCount",value:function(e){return this._count+=e,this._samples++,this._checkSampling(),this}},{key:"subtractCount",value:function(e){return this._count-=e,this._samples++,this._checkSampling(),this}},{key:"addTime",value:function(e){return this._time+=e,this.lastTiming=e,this._samples++,this._checkSampling(),this}},{key:"timeStart",value:function(){return this._startTime=c_(),this._timerPending=!0,this}},{key:"timeEnd",value:function(){return this._timerPending?(this.addTime(c_()-this._startTime),this._timerPending=!1,this._checkSampling(),this):this}},{key:"getSampleAverageCount",value:function(){return this.sampleSize>0?this.lastSampleCount/this.sampleSize:0}},{key:"getSampleAverageTime",value:function(){return this.sampleSize>0?this.lastSampleTime/this.sampleSize:0}},{key:"getSampleHz",value:function(){return this.lastSampleTime>0?this.sampleSize/(this.lastSampleTime/1e3):0}},{key:"getAverageCount",value:function(){return this.samples>0?this.count/this.samples:0}},{key:"getAverageTime",value:function(){return this.samples>0?this.time/this.samples:0}},{key:"getHz",value:function(){return this.time>0?this.samples/(this.time/1e3):0}},{key:"reset",value:function(){return this.time=0,this.count=0,this.samples=0,this.lastTiming=0,this.lastSampleTime=0,this.lastSampleCount=0,this._count=0,this._time=0,this._samples=0,this._startTime=0,this._timerPending=!1,this}},{key:"_checkSampling",value:function(){this._samples===this.sampleSize&&(this.lastSampleTime=this._time,this.lastSampleCount=this._count,this.count+=this._count,this.time+=this._time,this.samples+=this._samples,this._time=0,this._count=0,this._samples=0)}}]),t}();var Pc=function(){function t(r){(0,pj.default)(this,t),ve(this,"id",void 0),ve(this,"stats",{}),this.id=r.id,this.stats={},this._initializeStats(r.stats),Object.seal(this)}return(0,dj.default)(t,[{key:"get",value:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"count";return this._getOrCreate({name:e,type:i})}},{key:"size",get:function(){return Object.keys(this.stats).length}},{key:"reset",value:function(){for(var e in this.stats)this.stats[e].reset();return this}},{key:"forEach",value:function(e){for(var i in this.stats)e(this.stats[i])}},{key:"getTable",value:function(){var e={};return this.forEach(function(i){e[i.name]={time:i.time||0,count:i.count||0,average:i.getAverageTime()||0,hz:i.getHz()||0}}),e}},{key:"_initializeStats",value:function(){var e=this,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];i.forEach(function(n){return e._getOrCreate(n)})}},{key:"_getOrCreate",value:function(e){if(!e||!e.name)return null;var i=e.name,n=e.type;return this.stats[i]||(e instanceof P2?this.stats[i]=e:this.stats[i]=new P2(i,n)),this.stats[i]}}]),t}();function mj(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function vj(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?mj(Object(e),!0).forEach(function(i){(0,Aj.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):mj(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}var q2e="Queued Requests",X2e="Active Requests",Z2e="Cancelled Requests",Y2e="Queued Requests Ever",K2e="Active Requests Ever",Q2e={id:"request-scheduler",throttleRequests:!0,maxRequests:6},f_=function(){function t(){(0,gj.default)(this,t);var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ve(this,"props",void 0),ve(this,"stats",void 0),ve(this,"activeRequestCount",0),ve(this,"requestQueue",[]),ve(this,"requestMap",new Map),ve(this,"deferredUpdate",null),this.props=vj(vj({},Q2e),r),this.stats=new Pc({id:this.props.id}),this.stats.get(q2e),this.stats.get(X2e),this.stats.get(Z2e),this.stats.get(Y2e),this.stats.get(K2e)}return(0,yj.default)(t,[{key:"scheduleRequest",value:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:function(){return 0};if(!this.props.throttleRequests)return Promise.resolve({done:function(){}});if(this.requestMap.has(e))return this.requestMap.get(e);var n={handle:e,priority:0,getPriority:i},a=new Promise(function(o){return n.resolve=o,n});return this.requestQueue.push(n),this.requestMap.set(e,a),this._issueNewRequests(),a}},{key:"_issueRequest",value:function(e){var i=this,n=e.handle,a=e.resolve,o=!1,s=function(){o||(o=!0,i.requestMap.delete(n),i.activeRequestCount--,i._issueNewRequests())};return this.activeRequestCount++,a?a({done:s}):Promise.resolve({done:s})}},{key:"_issueNewRequests",value:function(){var e=this;this.deferredUpdate||(this.deferredUpdate=setTimeout(function(){return e._issueNewRequestsAsync()},0))}},{key:"_issueNewRequestsAsync",value:function(){this.deferredUpdate=null;var e=Math.max(this.props.maxRequests-this.activeRequestCount,0);if(e!==0){this._updateAllRequests();for(var i=0;i<e;++i){var n=this.requestQueue.shift();n&&this._issueRequest(n)}}}},{key:"_updateAllRequests",value:function(){for(var e=this.requestQueue,i=0;i<e.length;++i){var n=e[i];this._updateRequest(n)||(e.splice(i,1),this.requestMap.delete(n.handle),i--)}e.sort(function(a,o){return a.priority-o.priority})}},{key:"_updateRequest",value:function(e){return e.priority=e.getPriority(e.handle),e.priority<0?(e.resolve(null),!1):!0}}]),t}();var J2e="",_j={};function bO(t){for(var r in _j)if(t.startsWith(r)){var e=_j[r];t=t.replace(r,e)}return!t.startsWith("http://")&&!t.startsWith("https://")&&(t="".concat(J2e).concat(t)),t}var wO=C(Xn()),TO=C(xj());function bj(t){return t&&(0,wO.default)(t)==="object"&&t.isBuffer}function C2(t){if(bj(t))return TO.toArrayBuffer(t);if(t instanceof ArrayBuffer)return t;if(ArrayBuffer.isView(t))return t.byteOffset===0&&t.byteLength===t.buffer.byteLength?t.buffer:t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength);if(typeof t=="string"){var r=t,e=new TextEncoder().encode(r);return e.buffer}if(t&&(0,wO.default)(t)==="object"&&t._toArrayBuffer)return t._toArrayBuffer();throw new Error("toArrayBuffer")}var Wp={};Yu(Wp,{dirname:()=>ewe,filename:()=>$2e,join:()=>twe});function $2e(t){var r=t&&t.lastIndexOf("/");return r>=0?t.substr(r+1):""}function ewe(t){var r=t&&t.lastIndexOf("/");return r>=0?t.substr(0,r):""}function twe(){for(var t=arguments.length,r=new Array(t),e=0;e<t;e++)r[e]=arguments[e];var i="/";return r=r.map(function(n,a){return a&&(n=n.replace(new RegExp("^".concat(i)),"")),a!==r.length-1&&(n=n.replace(new RegExp("".concat(i,"$")),"")),n}),r.join(i)}var p_=C(Vr()),Ch=C(zr());var EO=C(Xn()),rwe=function(r){return typeof r=="boolean"},h_=function(r){return typeof r=="function"},DA=function(r){return r!==null&&(0,EO.default)(r)==="object"},SO=function(r){return DA(r)&&r.constructor==={}.constructor};var wj=function(r){return r&&typeof r[Symbol.iterator]=="function"},Tj=function(r){return r&&typeof r[Symbol.asyncIterator]=="function"};var Cc=function(r){return typeof Response<"u"&&r instanceof Response||r&&r.arrayBuffer&&r.text&&r.json};var Mc=function(r){return typeof Blob<"u"&&r instanceof Blob},Ej=function(r){return r&&(0,EO.default)(r)==="object"&&r.isBuffer};var nwe=function(r){return typeof ReadableStream<"u"&&r instanceof ReadableStream||DA(r)&&h_(r.tee)&&h_(r.cancel)&&h_(r.getReader)};var iwe=function(r){return DA(r)&&h_(r.read)&&h_(r.pipe)&&rwe(r.readable)},M2=function(r){return nwe(r)||iwe(r)};var awe=/^data:([-\w.]+\/[-\w.+]+)(;|,)/,owe=/^([-\w.]+\/[-\w.+]+)/;function Sj(t){var r=owe.exec(t);return r?r[1]:t}function PO(t){var r=awe.exec(t);return r?r[1]:""}var swe=/\?.*/;function dm(t){if(Cc(t)){var r=CO(t.url||""),e=t.headers.get("content-type")||"";return{url:r,type:Sj(e)||PO(r)}}return Mc(t)?{url:CO(t.name||""),type:t.type||""}:typeof t=="string"?{url:CO(t),type:PO(t)}:{url:"",type:""}}function Pj(t){return Cc(t)?t.headers["content-length"]||-1:Mc(t)?t.size:typeof t=="string"?t.length:t instanceof ArrayBuffer||ArrayBuffer.isView(t)?t.byteLength:-1}function CO(t){return t.replace(swe,"")}function O2(t){return MO.apply(this,arguments)}function MO(){return MO=(0,p_.default)(Ch.default.mark(function t(r){var e,i,n,a,o,s,u;return Ch.default.wrap(function(h){for(;;)switch(h.prev=h.next){case 0:if(!Cc(r)){h.next=2;break}return h.abrupt("return",r);case 2:return e={},i=Pj(r),i>=0&&(e["content-length"]=String(i)),n=dm(r),a=n.url,o=n.type,o&&(e["content-type"]=o),h.next=9,lwe(r);case 9:return s=h.sent,s&&(e["x-first-bytes"]=s),typeof r=="string"&&(r=new TextEncoder().encode(r)),u=new Response(r,{headers:e}),Object.defineProperty(u,"url",{value:a}),h.abrupt("return",u);case 15:case"end":return h.stop()}},t)})),MO.apply(this,arguments)}function Cj(t){return OO.apply(this,arguments)}function OO(){return OO=(0,p_.default)(Ch.default.mark(function t(r){var e;return Ch.default.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:if(r.ok){n.next=5;break}return n.next=3,uwe(r);case 3:throw e=n.sent,new Error(e);case 5:case"end":return n.stop()}},t)})),OO.apply(this,arguments)}function uwe(t){return IO.apply(this,arguments)}function IO(){return IO=(0,p_.default)(Ch.default.mark(function t(r){var e,i,n;return Ch.default.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(e="Failed to fetch resource ".concat(r.url," (").concat(r.status,"): "),o.prev=1,i=r.headers.get("Content-Type"),n=r.statusText,!i.includes("application/json")){o.next=11;break}return o.t0=n,o.t1=" ",o.next=9,r.text();case 9:o.t2=o.sent,n=o.t0+=o.t1.concat.call(o.t1,o.t2);case 11:e+=n,e=e.length>60?"".concat(e.slice(0,60),"..."):e,o.next=17;break;case 15:o.prev=15,o.t3=o.catch(1);case 17:return o.abrupt("return",e);case 18:case"end":return o.stop()}},t,null,[[1,15]])})),IO.apply(this,arguments)}function lwe(t){return RO.apply(this,arguments)}function RO(){return RO=(0,p_.default)(Ch.default.mark(function t(r){var e,i,n,a;return Ch.default.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:if(e=5,typeof r!="string"){s.next=3;break}return s.abrupt("return","data:,".concat(r.slice(0,e)));case 3:if(!(r instanceof Blob)){s.next=8;break}return i=r.slice(0,5),s.next=7,new Promise(function(u){var c=new FileReader;c.onload=function(h){var v;return u(h==null||(v=h.target)===null||v===void 0?void 0:v.result)},c.readAsDataURL(i)});case 7:return s.abrupt("return",s.sent);case 8:if(!(r instanceof ArrayBuffer)){s.next=12;break}return n=r.slice(0,e),a=cwe(n),s.abrupt("return","data:base64,".concat(a));case 12:return s.abrupt("return",null);case 13:case"end":return s.stop()}},t)})),RO.apply(this,arguments)}function cwe(t){for(var r="",e=new Uint8Array(t),i=0;i<e.byteLength;i++)r+=String.fromCharCode(e[i]);return btoa(r)}function FA(t,r){return kO.apply(this,arguments)}function kO(){return kO=(0,Mj.default)(LO.default.mark(function t(r,e){var i;return LO.default.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if(typeof r!="string"){a.next=7;break}return r=bO(r),i=e,e!=null&&e.fetch&&typeof e?.fetch!="function"&&(i=e.fetch),a.next=6,fetch(r,i);case 6:return a.abrupt("return",a.sent);case 7:return a.next=9,O2(r);case 9:return a.abrupt("return",a.sent);case 10:case"end":return a.stop()}},t)})),kO.apply(this,arguments)}var tG=C(Ke());var DO=C(Ge()),FO=C(Ye());var B2=C(Xn()),m_=C(Ms()),Hj=C(Ke()),Wj=C(Ge()),qj=C(Ye());var Oj=C(Xn());var I2=C(Xn());function d_(t){if(typeof window<"u"&&(0,I2.default)(window.process)==="object"&&window.process.type==="renderer"||typeof process<"u"&&(0,I2.default)(process.versions)==="object"&&Boolean(process.versions.electron))return!0;var r=(typeof navigator>"u"?"undefined":(0,I2.default)(navigator))==="object"&&typeof navigator.userAgent=="string"&&navigator.userAgent,e=t||r;return!!(e&&e.indexOf("Electron")>=0)}function ls(){var t=(typeof process>"u"?"undefined":(0,Oj.default)(process))==="object"&&String(process)==="[object process]"&&!process.browser;return!t||d_()}var Ij=C(Xn()),qp={self:typeof self<"u"&&self,window:typeof window<"u"&&window,global:typeof global<"u"&&global,document:typeof document<"u"&&document,process:(typeof process>"u"?"undefined":(0,Ij.default)(process))==="object"&&process};var fwe=qp.self||qp.window||qp.global,NA=qp.window||qp.self||qp.global,hwe=qp.document||{},mm=qp.process||{};var R2="8.9.0",BKe=ls();var BO=globalThis;function zA(t){if(!t&&!ls())return"Node";if(d_(t))return"Electron";var r=typeof navigator<"u"?navigator:{},e=t||r.userAgent||"";if(e.indexOf("Edge")>-1)return"Edge";var i=e.indexOf("MSIE ")!==-1,n=e.indexOf("Trident/")!==-1;return i||n?"IE":BO.chrome?"Chrome":BO.safari?"Safari":BO.mozInnerScreenX?"Firefox":"Unknown"}var Rj=C(Ge()),Lj=C(Ye());function pwe(t){try{var r=window[t],e="__storage_test__";return r.setItem(e,e),r.removeItem(e),r}catch{return null}}var kj=function(){function t(r){(0,Rj.default)(this,t);var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"sessionStorage";ve(this,"storage",void 0),ve(this,"id",void 0),ve(this,"config",{}),this.storage=pwe(i),this.id=r,this.config={},Object.assign(this.config,e),this._loadConfiguration()}return(0,Lj.default)(t,[{key:"getConfiguration",value:function(){return this.config}},{key:"setConfiguration",value:function(e){return this.config={},this.updateConfiguration(e)}},{key:"updateConfiguration",value:function(e){if(Object.assign(this.config,e),this.storage){var i=JSON.stringify(this.config);this.storage.setItem(this.id,i)}return this}},{key:"_loadConfiguration",value:function(){var e={};if(this.storage){var i=this.storage.getItem(this.id);e=i?JSON.parse(i):{}}return Object.assign(this.config,e),this}}]),t}();function Bj(t){var r;return t<10?r="".concat(t.toFixed(2),"ms"):t<100?r="".concat(t.toFixed(1),"ms"):t<1e3?r="".concat(t.toFixed(0),"ms"):r="".concat((t/1e3).toFixed(2),"s"),r}function Dj(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:8,e=Math.max(r-t.length,0);return"".concat(" ".repeat(e)).concat(t)}function L2(t,r,e){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:600,n=t.src.replace(/\(/g,"%28").replace(/\)/g,"%29");t.width>i&&(e=Math.min(e,i/t.width));var a=t.width*e,o=t.height*e,s=["font-size:1px;","padding:".concat(Math.floor(o/2),"px ").concat(Math.floor(a/2),"px;"),"line-height:".concat(o,"px;"),"background:url(".concat(n,");"),"background-size:".concat(a,"px ").concat(o,"px;"),"color:transparent;"].join("");return["".concat(r," %c+"),s]}var k2;(function(t){t[t.BLACK=30]="BLACK",t[t.RED=31]="RED",t[t.GREEN=32]="GREEN",t[t.YELLOW=33]="YELLOW",t[t.BLUE=34]="BLUE",t[t.MAGENTA=35]="MAGENTA",t[t.CYAN=36]="CYAN",t[t.WHITE=37]="WHITE",t[t.BRIGHT_BLACK=90]="BRIGHT_BLACK",t[t.BRIGHT_RED=91]="BRIGHT_RED",t[t.BRIGHT_GREEN=92]="BRIGHT_GREEN",t[t.BRIGHT_YELLOW=93]="BRIGHT_YELLOW",t[t.BRIGHT_BLUE=94]="BRIGHT_BLUE",t[t.BRIGHT_MAGENTA=95]="BRIGHT_MAGENTA",t[t.BRIGHT_CYAN=96]="BRIGHT_CYAN",t[t.BRIGHT_WHITE=97]="BRIGHT_WHITE"})(k2||(k2={}));function Fj(t){return typeof t=="string"?k2[t.toUpperCase()]||k2.WHITE:t}function Nj(t,r,e){return!ls&&typeof t=="string"&&(r&&(r=Fj(r),t="\x1B[".concat(r,"m").concat(t,"\x1B[39m")),e&&(r=Fj(e),t="\x1B[".concat(e+10,"m").concat(t,"\x1B[49m"))),t}function dwe(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=mwe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
531
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function z2e(t,r){if(t){if(typeof t=="string")return nj(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return nj(t,r)}}function nj(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}function pO(t,r,e){if(e=e||t.byteLength,t.byteLength<e||r.byteLength<e)return!1;for(var i=new Uint8Array(t),n=new Uint8Array(r),a=0;a<i.length;++a)if(i[a]!==n[a])return!1;return!0}function dO(){for(var t=arguments.length,r=new Array(t),e=0;e<t;e++)r[e]=arguments[e];var i=r.map(function(h){return h instanceof ArrayBuffer?new Uint8Array(h):h}),n=i.reduce(function(h,v){return h+v.byteLength},0),a=new Uint8Array(n),o=0,s=N2e(i),u;try{for(s.s();!(u=s.n()).done;){var c=u.value;a.set(c,o),o+=c.byteLength}}catch(h){s.e(h)}finally{s.f()}return a.buffer}function u_(){for(var t=arguments.length,r=new Array(t),e=0;e<t;e++)r[e]=arguments[e];var i=r,n=i&&i.length>1&&i[0].constructor||null;if(!n)throw new Error('"concatenateTypedArrays" - incorrect quantity of arguments or arguments have incompatible data types');for(var a=i.reduce(function(v,b){return v+b.length},0),o=new n(a),s=0,u=0,c=i;u<c.length;u++){var h=c[u];o.set(h,s),s+=h.length}return o}function pm(t,r,e){var i=e!==void 0?new Uint8Array(t).subarray(r,r+e):new Uint8Array(t).subarray(r),n=new Uint8Array(i);return n.buffer}function Hp(t,r){return Un(t>=0),Un(r>0),t+(r-1)&~(r-1)}function mO(t,r,e){var i;if(t instanceof ArrayBuffer)i=new Uint8Array(t);else{var n=t.byteOffset,a=t.byteLength;i=new Uint8Array(t.buffer||t.arrayBuffer,n,a)}return r.set(i,e),e+Hp(i.byteLength,4)}var lj=C(Vr()),cj=C(e_()),yO=C(zr());function xO(t){return _O.apply(this,arguments)}function _O(){return _O=(0,lj.default)(yO.default.mark(function t(r){var e,i,n,a,o,s,u;return yO.default.wrap(function(h){for(;;)switch(h.prev=h.next){case 0:e=[],i=!1,n=!1,h.prev=3,o=(0,cj.default)(r);case 5:return h.next=7,o.next();case 7:if(!(i=!(s=h.sent).done)){h.next=13;break}u=s.value,e.push(u);case 10:i=!1,h.next=5;break;case 13:h.next=19;break;case 15:h.prev=15,h.t0=h.catch(3),n=!0,a=h.t0;case 19:if(h.prev=19,h.prev=20,!(i&&o.return!=null)){h.next=24;break}return h.next=24,o.return();case 24:if(h.prev=24,!n){h.next=27;break}throw a;case 27:return h.finish(24);case 28:return h.finish(19);case 29:return h.abrupt("return",dO.apply(void 0,e));case 30:case"end":return h.stop()}},t,null,[[3,15,19,29],[20,,24,28]])})),_O.apply(this,arguments)}var Aj=C(Ke()),gj=C(Ge()),yj=C(Ye());var pj=C(Ge()),dj=C(Ye());var fj=C(Ge()),hj=C(Ye());function c_(){var t;if(typeof window<"u"&&window.performance)t=window.performance.now();else if(typeof process<"u"&&process.hrtime){var r=process.hrtime();t=r[0]*1e3+r[1]/1e6}else t=Date.now();return t}var P2=function(){function t(r,e){(0,fj.default)(this,t),ve(this,"name",void 0),ve(this,"type",void 0),ve(this,"sampleSize",1),ve(this,"time",void 0),ve(this,"count",void 0),ve(this,"samples",void 0),ve(this,"lastTiming",void 0),ve(this,"lastSampleTime",void 0),ve(this,"lastSampleCount",void 0),ve(this,"_count",0),ve(this,"_time",0),ve(this,"_samples",0),ve(this,"_startTime",0),ve(this,"_timerPending",!1),this.name=r,this.type=e,this.reset()}return(0,hj.default)(t,[{key:"setSampleSize",value:function(e){return this.sampleSize=e,this}},{key:"incrementCount",value:function(){return this.addCount(1),this}},{key:"decrementCount",value:function(){return this.subtractCount(1),this}},{key:"addCount",value:function(e){return this._count+=e,this._samples++,this._checkSampling(),this}},{key:"subtractCount",value:function(e){return this._count-=e,this._samples++,this._checkSampling(),this}},{key:"addTime",value:function(e){return this._time+=e,this.lastTiming=e,this._samples++,this._checkSampling(),this}},{key:"timeStart",value:function(){return this._startTime=c_(),this._timerPending=!0,this}},{key:"timeEnd",value:function(){return this._timerPending?(this.addTime(c_()-this._startTime),this._timerPending=!1,this._checkSampling(),this):this}},{key:"getSampleAverageCount",value:function(){return this.sampleSize>0?this.lastSampleCount/this.sampleSize:0}},{key:"getSampleAverageTime",value:function(){return this.sampleSize>0?this.lastSampleTime/this.sampleSize:0}},{key:"getSampleHz",value:function(){return this.lastSampleTime>0?this.sampleSize/(this.lastSampleTime/1e3):0}},{key:"getAverageCount",value:function(){return this.samples>0?this.count/this.samples:0}},{key:"getAverageTime",value:function(){return this.samples>0?this.time/this.samples:0}},{key:"getHz",value:function(){return this.time>0?this.samples/(this.time/1e3):0}},{key:"reset",value:function(){return this.time=0,this.count=0,this.samples=0,this.lastTiming=0,this.lastSampleTime=0,this.lastSampleCount=0,this._count=0,this._time=0,this._samples=0,this._startTime=0,this._timerPending=!1,this}},{key:"_checkSampling",value:function(){this._samples===this.sampleSize&&(this.lastSampleTime=this._time,this.lastSampleCount=this._count,this.count+=this._count,this.time+=this._time,this.samples+=this._samples,this._time=0,this._count=0,this._samples=0)}}]),t}();var Pc=function(){function t(r){(0,pj.default)(this,t),ve(this,"id",void 0),ve(this,"stats",{}),this.id=r.id,this.stats={},this._initializeStats(r.stats),Object.seal(this)}return(0,dj.default)(t,[{key:"get",value:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"count";return this._getOrCreate({name:e,type:i})}},{key:"size",get:function(){return Object.keys(this.stats).length}},{key:"reset",value:function(){for(var e in this.stats)this.stats[e].reset();return this}},{key:"forEach",value:function(e){for(var i in this.stats)e(this.stats[i])}},{key:"getTable",value:function(){var e={};return this.forEach(function(i){e[i.name]={time:i.time||0,count:i.count||0,average:i.getAverageTime()||0,hz:i.getHz()||0}}),e}},{key:"_initializeStats",value:function(){var e=this,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];i.forEach(function(n){return e._getOrCreate(n)})}},{key:"_getOrCreate",value:function(e){if(!e||!e.name)return null;var i=e.name,n=e.type;return this.stats[i]||(e instanceof P2?this.stats[i]=e:this.stats[i]=new P2(i,n)),this.stats[i]}}]),t}();function mj(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function vj(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?mj(Object(e),!0).forEach(function(i){(0,Aj.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):mj(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}var q2e="Queued Requests",X2e="Active Requests",Z2e="Cancelled Requests",Y2e="Queued Requests Ever",K2e="Active Requests Ever",Q2e={id:"request-scheduler",throttleRequests:!0,maxRequests:6},f_=function(){function t(){(0,gj.default)(this,t);var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ve(this,"props",void 0),ve(this,"stats",void 0),ve(this,"activeRequestCount",0),ve(this,"requestQueue",[]),ve(this,"requestMap",new Map),ve(this,"deferredUpdate",null),this.props=vj(vj({},Q2e),r),this.stats=new Pc({id:this.props.id}),this.stats.get(q2e),this.stats.get(X2e),this.stats.get(Z2e),this.stats.get(Y2e),this.stats.get(K2e)}return(0,yj.default)(t,[{key:"scheduleRequest",value:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:function(){return 0};if(!this.props.throttleRequests)return Promise.resolve({done:function(){}});if(this.requestMap.has(e))return this.requestMap.get(e);var n={handle:e,priority:0,getPriority:i},a=new Promise(function(o){return n.resolve=o,n});return this.requestQueue.push(n),this.requestMap.set(e,a),this._issueNewRequests(),a}},{key:"_issueRequest",value:function(e){var i=this,n=e.handle,a=e.resolve,o=!1,s=function(){o||(o=!0,i.requestMap.delete(n),i.activeRequestCount--,i._issueNewRequests())};return this.activeRequestCount++,a?a({done:s}):Promise.resolve({done:s})}},{key:"_issueNewRequests",value:function(){var e=this;this.deferredUpdate||(this.deferredUpdate=setTimeout(function(){return e._issueNewRequestsAsync()},0))}},{key:"_issueNewRequestsAsync",value:function(){this.deferredUpdate=null;var e=Math.max(this.props.maxRequests-this.activeRequestCount,0);if(e!==0){this._updateAllRequests();for(var i=0;i<e;++i){var n=this.requestQueue.shift();n&&this._issueRequest(n)}}}},{key:"_updateAllRequests",value:function(){for(var e=this.requestQueue,i=0;i<e.length;++i){var n=e[i];this._updateRequest(n)||(e.splice(i,1),this.requestMap.delete(n.handle),i--)}e.sort(function(a,o){return a.priority-o.priority})}},{key:"_updateRequest",value:function(e){return e.priority=e.getPriority(e.handle),e.priority<0?(e.resolve(null),!1):!0}}]),t}();var J2e="",_j={};function bO(t){for(var r in _j)if(t.startsWith(r)){var e=_j[r];t=t.replace(r,e)}return!t.startsWith("http://")&&!t.startsWith("https://")&&(t="".concat(J2e).concat(t)),t}var wO=C(Xn()),TO=C(xj());function bj(t){return t&&(0,wO.default)(t)==="object"&&t.isBuffer}function C2(t){if(bj(t))return TO.toArrayBuffer(t);if(t instanceof ArrayBuffer)return t;if(ArrayBuffer.isView(t))return t.byteOffset===0&&t.byteLength===t.buffer.byteLength?t.buffer:t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength);if(typeof t=="string"){var r=t,e=new TextEncoder().encode(r);return e.buffer}if(t&&(0,wO.default)(t)==="object"&&t._toArrayBuffer)return t._toArrayBuffer();throw new Error("toArrayBuffer")}var Wp={};Yu(Wp,{dirname:()=>ewe,filename:()=>$2e,join:()=>twe});function $2e(t){var r=t&&t.lastIndexOf("/");return r>=0?t.substr(r+1):""}function ewe(t){var r=t&&t.lastIndexOf("/");return r>=0?t.substr(0,r):""}function twe(){for(var t=arguments.length,r=new Array(t),e=0;e<t;e++)r[e]=arguments[e];var i="/";return r=r.map(function(n,a){return a&&(n=n.replace(new RegExp("^".concat(i)),"")),a!==r.length-1&&(n=n.replace(new RegExp("".concat(i,"$")),"")),n}),r.join(i)}var p_=C(Vr()),Ch=C(zr());var EO=C(Xn()),rwe=function(r){return typeof r=="boolean"},h_=function(r){return typeof r=="function"},DA=function(r){return r!==null&&(0,EO.default)(r)==="object"},SO=function(r){return DA(r)&&r.constructor==={}.constructor};var wj=function(r){return r&&typeof r[Symbol.iterator]=="function"},Tj=function(r){return r&&typeof r[Symbol.asyncIterator]=="function"};var Cc=function(r){return typeof Response<"u"&&r instanceof Response||r&&r.arrayBuffer&&r.text&&r.json};var Mc=function(r){return typeof Blob<"u"&&r instanceof Blob},Ej=function(r){return r&&(0,EO.default)(r)==="object"&&r.isBuffer};var nwe=function(r){return typeof ReadableStream<"u"&&r instanceof ReadableStream||DA(r)&&h_(r.tee)&&h_(r.cancel)&&h_(r.getReader)};var iwe=function(r){return DA(r)&&h_(r.read)&&h_(r.pipe)&&rwe(r.readable)},M2=function(r){return nwe(r)||iwe(r)};var awe=/^data:([-\w.]+\/[-\w.+]+)(;|,)/,owe=/^([-\w.]+\/[-\w.+]+)/;function Sj(t){var r=owe.exec(t);return r?r[1]:t}function PO(t){var r=awe.exec(t);return r?r[1]:""}var swe=/\?.*/;function dm(t){if(Cc(t)){var r=CO(t.url||""),e=t.headers.get("content-type")||"";return{url:r,type:Sj(e)||PO(r)}}return Mc(t)?{url:CO(t.name||""),type:t.type||""}:typeof t=="string"?{url:CO(t),type:PO(t)}:{url:"",type:""}}function Pj(t){return Cc(t)?t.headers["content-length"]||-1:Mc(t)?t.size:typeof t=="string"?t.length:t instanceof ArrayBuffer||ArrayBuffer.isView(t)?t.byteLength:-1}function CO(t){return t.replace(swe,"")}function O2(t){return MO.apply(this,arguments)}function MO(){return MO=(0,p_.default)(Ch.default.mark(function t(r){var e,i,n,a,o,s,u;return Ch.default.wrap(function(h){for(;;)switch(h.prev=h.next){case 0:if(!Cc(r)){h.next=2;break}return h.abrupt("return",r);case 2:return e={},i=Pj(r),i>=0&&(e["content-length"]=String(i)),n=dm(r),a=n.url,o=n.type,o&&(e["content-type"]=o),h.next=9,lwe(r);case 9:return s=h.sent,s&&(e["x-first-bytes"]=s),typeof r=="string"&&(r=new TextEncoder().encode(r)),u=new Response(r,{headers:e}),Object.defineProperty(u,"url",{value:a}),h.abrupt("return",u);case 15:case"end":return h.stop()}},t)})),MO.apply(this,arguments)}function Cj(t){return OO.apply(this,arguments)}function OO(){return OO=(0,p_.default)(Ch.default.mark(function t(r){var e;return Ch.default.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:if(r.ok){n.next=5;break}return n.next=3,uwe(r);case 3:throw e=n.sent,new Error(e);case 5:case"end":return n.stop()}},t)})),OO.apply(this,arguments)}function uwe(t){return IO.apply(this,arguments)}function IO(){return IO=(0,p_.default)(Ch.default.mark(function t(r){var e,i,n;return Ch.default.wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(e="Failed to fetch resource ".concat(r.url," (").concat(r.status,"): "),o.prev=1,i=r.headers.get("Content-Type"),n=r.statusText,!i.includes("application/json")){o.next=11;break}return o.t0=n,o.t1=" ",o.next=9,r.text();case 9:o.t2=o.sent,n=o.t0+=o.t1.concat.call(o.t1,o.t2);case 11:e+=n,e=e.length>60?"".concat(e.slice(0,60),"..."):e,o.next=17;break;case 15:o.prev=15,o.t3=o.catch(1);case 17:return o.abrupt("return",e);case 18:case"end":return o.stop()}},t,null,[[1,15]])})),IO.apply(this,arguments)}function lwe(t){return RO.apply(this,arguments)}function RO(){return RO=(0,p_.default)(Ch.default.mark(function t(r){var e,i,n,a;return Ch.default.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:if(e=5,typeof r!="string"){s.next=3;break}return s.abrupt("return","data:,".concat(r.slice(0,e)));case 3:if(!(r instanceof Blob)){s.next=8;break}return i=r.slice(0,5),s.next=7,new Promise(function(u){var c=new FileReader;c.onload=function(h){var v;return u(h==null||(v=h.target)===null||v===void 0?void 0:v.result)},c.readAsDataURL(i)});case 7:return s.abrupt("return",s.sent);case 8:if(!(r instanceof ArrayBuffer)){s.next=12;break}return n=r.slice(0,e),a=cwe(n),s.abrupt("return","data:base64,".concat(a));case 12:return s.abrupt("return",null);case 13:case"end":return s.stop()}},t)})),RO.apply(this,arguments)}function cwe(t){for(var r="",e=new Uint8Array(t),i=0;i<e.byteLength;i++)r+=String.fromCharCode(e[i]);return btoa(r)}function FA(t,r){return kO.apply(this,arguments)}function kO(){return kO=(0,Mj.default)(LO.default.mark(function t(r,e){var i;return LO.default.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if(typeof r!="string"){a.next=7;break}return r=bO(r),i=e,e!=null&&e.fetch&&typeof e?.fetch!="function"&&(i=e.fetch),a.next=6,fetch(r,i);case 6:return a.abrupt("return",a.sent);case 7:return a.next=9,O2(r);case 9:return a.abrupt("return",a.sent);case 10:case"end":return a.stop()}},t)})),kO.apply(this,arguments)}var tG=C(Ke());var DO=C(Ge()),FO=C(Ye());var B2=C(Xn()),m_=C(Ms()),Hj=C(Ke()),Wj=C(Ge()),qj=C(Ye());var Oj=C(Xn());var I2=C(Xn());function d_(t){if(typeof window<"u"&&(0,I2.default)(window.process)==="object"&&window.process.type==="renderer"||typeof process<"u"&&(0,I2.default)(process.versions)==="object"&&Boolean(process.versions.electron))return!0;var r=(typeof navigator>"u"?"undefined":(0,I2.default)(navigator))==="object"&&typeof navigator.userAgent=="string"&&navigator.userAgent,e=t||r;return!!(e&&e.indexOf("Electron")>=0)}function ls(){var t=(typeof process>"u"?"undefined":(0,Oj.default)(process))==="object"&&String(process)==="[object process]"&&!process.browser;return!t||d_()}var Ij=C(Xn()),qp={self:typeof self<"u"&&self,window:typeof window<"u"&&window,global:typeof global<"u"&&global,document:typeof document<"u"&&document,process:(typeof process>"u"?"undefined":(0,Ij.default)(process))==="object"&&process};var fwe=qp.self||qp.window||qp.global,NA=qp.window||qp.self||qp.global,hwe=qp.document||{},mm=qp.process||{};var R2="8.9.1",BKe=ls();var BO=globalThis;function zA(t){if(!t&&!ls())return"Node";if(d_(t))return"Electron";var r=typeof navigator<"u"?navigator:{},e=t||r.userAgent||"";if(e.indexOf("Edge")>-1)return"Edge";var i=e.indexOf("MSIE ")!==-1,n=e.indexOf("Trident/")!==-1;return i||n?"IE":BO.chrome?"Chrome":BO.safari?"Safari":BO.mozInnerScreenX?"Firefox":"Unknown"}var Rj=C(Ge()),Lj=C(Ye());function pwe(t){try{var r=window[t],e="__storage_test__";return r.setItem(e,e),r.removeItem(e),r}catch{return null}}var kj=function(){function t(r){(0,Rj.default)(this,t);var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"sessionStorage";ve(this,"storage",void 0),ve(this,"id",void 0),ve(this,"config",{}),this.storage=pwe(i),this.id=r,this.config={},Object.assign(this.config,e),this._loadConfiguration()}return(0,Lj.default)(t,[{key:"getConfiguration",value:function(){return this.config}},{key:"setConfiguration",value:function(e){return this.config={},this.updateConfiguration(e)}},{key:"updateConfiguration",value:function(e){if(Object.assign(this.config,e),this.storage){var i=JSON.stringify(this.config);this.storage.setItem(this.id,i)}return this}},{key:"_loadConfiguration",value:function(){var e={};if(this.storage){var i=this.storage.getItem(this.id);e=i?JSON.parse(i):{}}return Object.assign(this.config,e),this}}]),t}();function Bj(t){var r;return t<10?r="".concat(t.toFixed(2),"ms"):t<100?r="".concat(t.toFixed(1),"ms"):t<1e3?r="".concat(t.toFixed(0),"ms"):r="".concat((t/1e3).toFixed(2),"s"),r}function Dj(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:8,e=Math.max(r-t.length,0);return"".concat(" ".repeat(e)).concat(t)}function L2(t,r,e){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:600,n=t.src.replace(/\(/g,"%28").replace(/\)/g,"%29");t.width>i&&(e=Math.min(e,i/t.width));var a=t.width*e,o=t.height*e,s=["font-size:1px;","padding:".concat(Math.floor(o/2),"px ").concat(Math.floor(a/2),"px;"),"line-height:".concat(o,"px;"),"background:url(".concat(n,");"),"background-size:".concat(a,"px ").concat(o,"px;"),"color:transparent;"].join("");return["".concat(r," %c+"),s]}var k2;(function(t){t[t.BLACK=30]="BLACK",t[t.RED=31]="RED",t[t.GREEN=32]="GREEN",t[t.YELLOW=33]="YELLOW",t[t.BLUE=34]="BLUE",t[t.MAGENTA=35]="MAGENTA",t[t.CYAN=36]="CYAN",t[t.WHITE=37]="WHITE",t[t.BRIGHT_BLACK=90]="BRIGHT_BLACK",t[t.BRIGHT_RED=91]="BRIGHT_RED",t[t.BRIGHT_GREEN=92]="BRIGHT_GREEN",t[t.BRIGHT_YELLOW=93]="BRIGHT_YELLOW",t[t.BRIGHT_BLUE=94]="BRIGHT_BLUE",t[t.BRIGHT_MAGENTA=95]="BRIGHT_MAGENTA",t[t.BRIGHT_CYAN=96]="BRIGHT_CYAN",t[t.BRIGHT_WHITE=97]="BRIGHT_WHITE"})(k2||(k2={}));function Fj(t){return typeof t=="string"?k2[t.toUpperCase()]||k2.WHITE:t}function Nj(t,r,e){return!ls&&typeof t=="string"&&(r&&(r=Fj(r),t="\x1B[".concat(r,"m").concat(t,"\x1B[39m")),e&&(r=Fj(e),t="\x1B[".concat(e+10,"m").concat(t,"\x1B[49m"))),t}function dwe(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=mwe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
532
532
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function mwe(t,r){if(t){if(typeof t=="string")return zj(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return zj(t,r)}}function zj(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}function Uj(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:["constructor"],e=Object.getPrototypeOf(t),i=Object.getOwnPropertyNames(e),n=dwe(i),a;try{var o=function(){var u=a.value;typeof t[u]=="function"&&(r.find(function(c){return u===c})||(t[u]=t[u].bind(t)))};for(n.s();!(a=n.n()).done;)o()}catch(s){n.e(s)}finally{n.f()}}function UA(t,r){if(!t)throw new Error(r||"Assertion failed")}function vm(){var t;if(ls&&"performance"in NA){var r,e;t=NA===null||NA===void 0||(r=NA.performance)===null||r===void 0||(e=r.now)===null||e===void 0?void 0:e.call(r)}else if("hrtime"in mm){var i,n=mm===null||mm===void 0||(i=mm.hrtime)===null||i===void 0?void 0:i.call(mm);t=n[0]*1e3+n[1]/1e6}else t=Date.now();return t}var jA={debug:ls&&console.debug||console.log,log:console.log,info:console.info,warn:console.warn,error:console.error},vwe={enabled:!0,level:0};function Ul(){}var jj={},Gj={once:!0},jl=function(){function t(){(0,Wj.default)(this,t);var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{id:""},e=r.id;ve(this,"id",void 0),ve(this,"VERSION",R2),ve(this,"_startTs",vm()),ve(this,"_deltaTs",vm()),ve(this,"_storage",void 0),ve(this,"userData",{}),ve(this,"LOG_THROTTLE_TIMEOUT",0),this.id=e,this._storage=new kj("__probe-".concat(this.id,"__"),vwe),this.userData={},this.timeStamp("".concat(this.id," started")),Uj(this),Object.seal(this)}return(0,qj.default)(t,[{key:"level",get:function(){return this.getLevel()},set:function(e){this.setLevel(e)}},{key:"isEnabled",value:function(){return this._storage.config.enabled}},{key:"getLevel",value:function(){return this._storage.config.level}},{key:"getTotal",value:function(){return Number((vm()-this._startTs).toPrecision(10))}},{key:"getDelta",value:function(){return Number((vm()-this._deltaTs).toPrecision(10))}},{key:"priority",get:function(){return this.level},set:function(e){this.level=e}},{key:"getPriority",value:function(){return this.level}},{key:"enable",value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return this._storage.updateConfiguration({enabled:e}),this}},{key:"setLevel",value:function(e){return this._storage.updateConfiguration({level:e}),this}},{key:"get",value:function(e){return this._storage.config[e]}},{key:"set",value:function(e,i){this._storage.updateConfiguration((0,Hj.default)({},e,i))}},{key:"settings",value:function(){console.table?console.table(this._storage.config):console.log(this._storage.config)}},{key:"assert",value:function(e,i){UA(e,i)}},{key:"warn",value:function(e){return this._getLogFunction(0,e,jA.warn,arguments,Gj)}},{key:"error",value:function(e){return this._getLogFunction(0,e,jA.error,arguments)}},{key:"deprecated",value:function(e,i){return this.warn("`".concat(e,"` is deprecated and will be removed in a later version. Use `").concat(i,"` instead"))}},{key:"removed",value:function(e,i){return this.error("`".concat(e,"` has been removed. Use `").concat(i,"` instead"))}},{key:"probe",value:function(e,i){return this._getLogFunction(e,i,jA.log,arguments,{time:!0,once:!0})}},{key:"log",value:function(e,i){return this._getLogFunction(e,i,jA.debug,arguments)}},{key:"info",value:function(e,i){return this._getLogFunction(e,i,console.info,arguments)}},{key:"once",value:function(e,i){for(var n=arguments.length,a=new Array(n>2?n-2:0),o=2;o<n;o++)a[o-2]=arguments[o];return this._getLogFunction(e,i,jA.debug||jA.info,arguments,Gj)}},{key:"table",value:function(e,i,n){return i?this._getLogFunction(e,i,console.table||Ul,n&&[n],{tag:_we(i)}):Ul}},{key:"image",value:function(e){var i=e.logLevel,n=e.priority,a=e.image,o=e.message,s=o===void 0?"":o,u=e.scale,c=u===void 0?1:u;return this._shouldLog(i||n)?ls?ywe({image:a,message:s,scale:c}):gwe({image:a,message:s,scale:c}):Ul}},{key:"time",value:function(e,i){return this._getLogFunction(e,i,console.time?console.time:console.info)}},{key:"timeEnd",value:function(e,i){return this._getLogFunction(e,i,console.timeEnd?console.timeEnd:console.info)}},{key:"timeStamp",value:function(e,i){return this._getLogFunction(e,i,console.timeStamp||Ul)}},{key:"group",value:function(e,i){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{collapsed:!1},a=Vj({logLevel:e,message:i,opts:n}),o=n.collapsed;return a.method=(o?console.groupCollapsed:console.group)||console.info,this._getLogFunction(a)}},{key:"groupCollapsed",value:function(e,i){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.group(e,i,Object.assign({},n,{collapsed:!0}))}},{key:"groupEnd",value:function(e){return this._getLogFunction(e,"",console.groupEnd||Ul)}},{key:"withGroup",value:function(e,i,n){this.group(e,i)();try{n()}finally{this.groupEnd(e)()}}},{key:"trace",value:function(){console.trace&&console.trace()}},{key:"_shouldLog",value:function(e){return this.isEnabled()&&this.getLevel()>=Xj(e)}},{key:"_getLogFunction",value:function(e,i,n,a,o){if(this._shouldLog(e)){var s;o=Vj({logLevel:e,message:i,args:a,opts:o}),n=n||o.method,UA(n),o.total=this.getTotal(),o.delta=this.getDelta(),this._deltaTs=vm();var u=o.tag||o.message;if(o.once)if(!jj[u])jj[u]=vm();else return Ul;return i=Awe(this.id,o.message,o),(s=n).bind.apply(s,[console,i].concat((0,m_.default)(o.args)))}return Ul}}]),t}();ve(jl,"VERSION",R2);function Xj(t){if(!t)return 0;var r;switch((0,B2.default)(t)){case"number":r=t;break;case"object":r=t.logLevel||t.priority||0;break;default:return 0}return UA(Number.isFinite(r)&&r>=0),r}function Vj(t){var r=t.logLevel,e=t.message;t.logLevel=Xj(r);for(var i=t.args?Array.from(t.args):[];i.length&&i.shift()!==e;);switch((0,B2.default)(r)){case"string":case"function":e!==void 0&&i.unshift(e),t.message=r;break;case"object":Object.assign(t,r);break;default:}typeof t.message=="function"&&(t.message=t.message());var n=(0,B2.default)(t.message);return UA(n==="string"||n==="object"),Object.assign(t,{args:i},t.opts)}function Awe(t,r,e){if(typeof r=="string"){var i=e.time?Dj(Bj(e.total)):"";r=e.time?"".concat(t,": ").concat(i," ").concat(r):"".concat(t,": ").concat(r),r=Nj(r,e.color,e.background)}return r}function gwe(t){var r=t.image,e=t.message,i=e===void 0?"":e,n=t.scale,a=n===void 0?1:n,o=null;try{o=module.require("asciify-image")}catch{}return o?function(){return o(r,{fit:"box",width:"".concat(Math.round(80*a),"%")}).then(function(s){return console.log(s)})}:Ul}function ywe(t){var r=t.image,e=t.message,i=e===void 0?"":e,n=t.scale,a=n===void 0?1:n;if(typeof r=="string"){var o=new Image;return o.onload=function(){var h,v=L2(o,i,a);(h=console).log.apply(h,(0,m_.default)(v))},o.src=r,Ul}var s=r.nodeName||"";if(s.toLowerCase()==="img"){var u;return(u=console).log.apply(u,(0,m_.default)(L2(r,i,a))),Ul}if(s.toLowerCase()==="canvas"){var c=new Image;return c.onload=function(){var h;return(h=console).log.apply(h,(0,m_.default)(L2(c,i,a)))},c.src=r.toDataURL(),Ul}return Ul}function _we(t){for(var r in t)for(var e in t[r])return e||"untitled";return"empty"}var dQe=new jl({id:"@probe.gl/log"});var NO=new jl({id:"loaders.gl"}),Zj=function(){function t(){(0,DO.default)(this,t)}return(0,FO.default)(t,[{key:"log",value:function(){return function(){}}},{key:"info",value:function(){return function(){}}},{key:"warn",value:function(){return function(){}}},{key:"error",value:function(){return function(){}}}]),t}(),Yj=function(){function t(){(0,DO.default)(this,t),ve(this,"console",void 0),this.console=console}return(0,FO.default)(t,[{key:"log",value:function(){for(var e,i=arguments.length,n=new Array(i),a=0;a<i;a++)n[a]=arguments[a];return(e=this.console.log).bind.apply(e,[this.console].concat(n))}},{key:"info",value:function(){for(var e,i=arguments.length,n=new Array(i),a=0;a<i;a++)n[a]=arguments[a];return(e=this.console.info).bind.apply(e,[this.console].concat(n))}},{key:"warn",value:function(){for(var e,i=arguments.length,n=new Array(i),a=0;a<i;a++)n[a]=arguments[a];return(e=this.console.warn).bind.apply(e,[this.console].concat(n))}},{key:"error",value:function(){for(var e,i=arguments.length,n=new Array(i),a=0;a<i;a++)n[a]=arguments[a];return(e=this.console.error).bind.apply(e,[this.console].concat(n))}}]),t}();var zO={fetch:null,mimeType:void 0,nothrow:!1,log:new Yj,CDN:"https://unpkg.com/@loaders.gl",worker:!0,maxConcurrency:3,maxMobileConcurrency:1,reuseWorkers:Sc,_nodeWorkers:!1,_workerType:"",limit:0,_limitMB:0,batchSize:"auto",batchDebounceMs:0,metadata:!1,transforms:[]},Kj={throws:"nothrow",dataType:"(no longer used)",uri:"baseUri",method:"fetch.method",headers:"fetch.headers",body:"fetch.body",mode:"fetch.mode",credentials:"fetch.credentials",cache:"fetch.cache",redirect:"fetch.redirect",referrer:"fetch.referrer",referrerPolicy:"fetch.referrerPolicy",integrity:"fetch.integrity",keepalive:"fetch.keepalive",signal:"fetch.signal"};function rG(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=xwe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
533
533
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function xwe(t,r){if(t){if(typeof t=="string")return Qj(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return Qj(t,r)}}function Qj(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}function Jj(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function D2(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?Jj(Object(e),!0).forEach(function(i){(0,tG.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):Jj(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}function UO(){globalThis.loaders=globalThis.loaders||{};var t=globalThis.loaders;return t._state=t._state||{},t._state}var nG=function(){var r=UO();return r.globalOptions=r.globalOptions||D2({},zO),r.globalOptions};function iG(t,r,e,i){return e=e||[],e=Array.isArray(e)?e:[e],bwe(t,e),Twe(r,t,i)}function F2(t,r){var e=nG(),i=t||e;return typeof i.fetch=="function"?i.fetch:DA(i.fetch)?function(n){return FA(n,i)}:r!=null&&r.fetch?r?.fetch:FA}function bwe(t,r){$j(t,null,zO,Kj,r);var e=rG(r),i;try{for(e.s();!(i=e.n()).done;){var n=i.value,a=t&&t[n.id]||{},o=n.options&&n.options[n.id]||{},s=n.deprecatedOptions&&n.deprecatedOptions[n.id]||{};$j(a,n.id,o,s,r)}}catch(u){e.e(u)}finally{e.f()}}function $j(t,r,e,i,n){var a=r||"Top level",o=r?"".concat(r,"."):"";for(var s in t){var u=!r&&DA(t[s]),c=s==="baseUri"&&!r,h=s==="workerUrl"&&r;if(!(s in e)&&!c&&!h){if(s in i)NO.warn("".concat(a," loader option '").concat(o).concat(s,"' no longer supported, use '").concat(i[s],"'"))();else if(!u){var v=wwe(s,n);NO.warn("".concat(a," loader option '").concat(o).concat(s,"' not recognized. ").concat(v))()}}}}function wwe(t,r){var e=t.toLowerCase(),i="",n=rG(r),a;try{for(n.s();!(a=n.n()).done;){var o=a.value;for(var s in o.options){if(t===s)return"Did you mean '".concat(o.id,".").concat(s,"'?");var u=s.toLowerCase(),c=e.startsWith(u)||u.startsWith(e);c&&(i=i||"Did you mean '".concat(o.id,".").concat(s,"'?"))}}}catch(h){n.e(h)}finally{n.f()}return i}function Twe(t,r,e){var i=t.options||{},n=D2({},i);return Ewe(n,e),n.log===null&&(n.log=new Zj),eG(n,nG()),eG(n,r),n}function eG(t,r){for(var e in r)if(e in r){var i=r[e];SO(i)&&SO(t[e])?t[e]=D2(D2({},t[e]),r[e]):t[e]=r[e]}}function Ewe(t,r){r&&!("baseUri"in t)&&(t.baseUri=r)}var oG=C(Ke());function aG(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function N2(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?aG(Object(e),!0).forEach(function(i){(0,oG.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):aG(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}function v_(t){var r;if(!t)return!1;Array.isArray(t)&&(t=t[0]);var e=Array.isArray((r=t)===null||r===void 0?void 0:r.extensions);return e}function A_(t){var r,e;Un(t,"null loader"),Un(v_(t),"invalid loader");var i;return Array.isArray(t)&&(i=t[1],t=t[0],t=N2(N2({},t),{},{options:N2(N2({},t.options),i)})),((r=t)!==null&&r!==void 0&&r.parseTextSync||(e=t)!==null&&e!==void 0&&e.parseText)&&(t.text=!0),t.text||(t.binary=!0),t}function Swe(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=Pwe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
534
534
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function Pwe(t,r){if(t){if(typeof t=="string")return sG(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return sG(t,r)}}function sG(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}var uG=function(){var r=UO();return r.loaderRegistry=r.loaderRegistry||[],r.loaderRegistry};function Am(t){var r=uG();t=Array.isArray(t)?t:[t];var e=Swe(t),i;try{var n=function(){var o=i.value,s=A_(o);r.find(function(u){return s===u})||r.unshift(s)};for(e.s();!(i=e.n()).done;)n()}catch(a){e.e(a)}finally{e.f()}}function lG(){return uG()}var vG=C(Ke()),AG=C(Xn()),gG=C(Ms()),yG=C(Vr()),GO=C(zr());var cG=new jl({id:"loaders.gl"});function fG(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function hG(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?fG(Object(e),!0).forEach(function(i){(0,vG.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):fG(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}function g_(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=Cwe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
535
535
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function Cwe(t,r){if(t){if(typeof t=="string")return pG(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return pG(t,r)}}function pG(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}var Mwe=/\.([^.]+)$/;function _G(t){return VO.apply(this,arguments)}function VO(){return VO=(0,yG.default)(GO.default.mark(function t(r){var e,i,n,a,o=arguments;return GO.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:if(e=o.length>1&&o[1]!==void 0?o[1]:[],i=o.length>2?o[2]:void 0,n=o.length>3?o[3]:void 0,xG(r)){u.next=5;break}return u.abrupt("return",null);case 5:if(a=dG(r,e,hG(hG({},i),{},{nothrow:!0}),n),!a){u.next=8;break}return u.abrupt("return",a);case 8:if(!Mc(r)){u.next=13;break}return u.next=11,r.slice(0,10).arrayBuffer();case 11:r=u.sent,a=dG(r,e,i,n);case 13:if(!(!a&&!(i!=null&&i.nothrow))){u.next=15;break}throw new Error(bG(r));case 15:return u.abrupt("return",a);case 16:case"end":return u.stop()}},t)})),VO.apply(this,arguments)}function dG(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],e=arguments.length>2?arguments[2]:void 0,i=arguments.length>3?arguments[3]:void 0;if(!xG(t))return null;if(r&&!Array.isArray(r))return A_(r);var n=[];if(r&&(n=n.concat(r)),!(e!=null&&e.ignoreRegisteredLoaders)){var a;(a=n).push.apply(a,(0,gG.default)(lG()))}Iwe(n);var o=Owe(t,n,e,i);if(!o&&!(e!=null&&e.nothrow))throw new Error(bG(t));return o}function Owe(t,r,e,i){var n=dm(t),a=n.url,o=n.type,s=a||i?.url,u=null,c="";if(e!=null&&e.mimeType&&(u=jO(r,e?.mimeType),c="match forced by supplied MIME type ".concat(e?.mimeType)),u=u||Rwe(r,s),c=c||(u?"matched url ".concat(s):""),u=u||jO(r,o),c=c||(u?"matched MIME type ".concat(o):""),u=u||kwe(r,t),c=c||(u?"matched initial data ".concat(wG(t)):""),u=u||jO(r,e?.fallbackMimeType),c=c||(u?"matched fallback MIME type ".concat(o):""),c){var h;cG.log(1,"selectLoader selected ".concat((h=u)===null||h===void 0?void 0:h.name,": ").concat(c,"."))}return u}function xG(t){return!(t instanceof Response&&t.status===204)}function bG(t){var r=dm(t),e=r.url,i=r.type,n="No valid loader found (";n+=e?"".concat(Wp.filename(e),", "):"no url provided, ",n+="MIME type: ".concat(i?'"'.concat(i,'"'):"not provided",", ");var a=t?wG(t):"";return n+=a?' first bytes: "'.concat(a,'"'):"first bytes: not available",n+=")",n}function Iwe(t){var r=g_(t),e;try{for(r.s();!(e=r.n()).done;){var i=e.value;A_(i)}}catch(n){r.e(n)}finally{r.f()}}function Rwe(t,r){var e=r&&Mwe.exec(r),i=e&&e[1];return i?Lwe(t,i):null}function Lwe(t,r){r=r.toLowerCase();var e=g_(t),i;try{for(e.s();!(i=e.n()).done;){var n=i.value,a=g_(n.extensions),o;try{for(a.s();!(o=a.n()).done;){var s=o.value;if(s.toLowerCase()===r)return n}}catch(u){a.e(u)}finally{a.f()}}}catch(u){e.e(u)}finally{e.f()}return null}function jO(t,r){var e=g_(t),i;try{for(e.s();!(i=e.n()).done;){var n=i.value;if(n.mimeTypes&&n.mimeTypes.includes(r)||r==="application/x.".concat(n.id))return n}}catch(a){e.e(a)}finally{e.f()}return null}function kwe(t,r){if(!r)return null;var e=g_(t),i;try{for(e.s();!(i=e.n()).done;){var n=i.value;if(typeof r=="string"){if(Bwe(r,n))return n}else if(ArrayBuffer.isView(r)){if(mG(r.buffer,r.byteOffset,n))return n}else if(r instanceof ArrayBuffer){var a=0;if(mG(r,a,n))return n}}}catch(o){e.e(o)}finally{e.f()}return null}function Bwe(t,r){if(r.testText)return r.testText(t);var e=Array.isArray(r.tests)?r.tests:[r.tests];return e.some(function(i){return t.startsWith(i)})}function mG(t,r,e){var i=Array.isArray(e.tests)?e.tests:[e.tests];return i.some(function(n){return Dwe(t,r,e,n)})}function Dwe(t,r,e,i){if(i instanceof ArrayBuffer)return pO(i,t,i.byteLength);switch((0,AG.default)(i)){case"function":return i(t,e);case"string":var n=HO(t,r,i.length);return i===n;default:return!1}}function wG(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:5;if(typeof t=="string")return t.slice(0,r);if(ArrayBuffer.isView(t))return HO(t.buffer,t.byteOffset,r);if(t instanceof ArrayBuffer){var e=0;return HO(t,e,r)}return""}function HO(t,r,e){if(t.byteLength<r+e)return"";for(var i=new DataView(t),n="",a=0;a<e;a++)n+=String.fromCharCode(i.getUint8(r+a));return n}var DG=C(Xn()),oI=C(Vr()),__=C(zr());var MG=C(Vr()),tI=C(zr());var WO=C(zr()),Fwe=WO.default.mark(qO),Nwe=256*1024;function qO(t,r){var e,i,n,a,o;return WO.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:e=r?.chunkSize||Nwe,i=0,n=new TextEncoder;case 3:if(!(i<t.length)){u.next=11;break}return a=Math.min(t.length-i,e),o=t.slice(i,i+a),i+=a,u.next=9,n.encode(o);case 9:u.next=3;break;case 11:case"end":return u.stop()}},Fwe)}var XO=C(zr()),zwe=XO.default.mark(ZO),Uwe=256*1024;function ZO(t){var r,e,i,n,a,o,s,u,c=arguments;return XO.default.wrap(function(v){for(;;)switch(v.prev=v.next){case 0:r=c.length>1&&c[1]!==void 0?c[1]:{},e=r.chunkSize,i=e===void 0?Uwe:e,n=0;case 3:if(!(n<t.byteLength)){v.next=14;break}return a=Math.min(t.byteLength-n,i),o=new ArrayBuffer(a),s=new Uint8Array(t,n,a),u=new Uint8Array(o),u.set(s),n+=a,v.next=12,o;case 12:v.next=3;break;case 14:case"end":return v.stop()}},zwe)}var TG=C(AO()),EG=C(gO()),YO=C(zr()),jwe=1024*1024;function SG(t,r){return KO.apply(this,arguments)}function KO(){return KO=(0,EG.default)(YO.default.mark(function t(r,e){var i,n,a,o;return YO.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:i=e?.chunkSize||jwe,n=0;case 2:if(!(n<r.size)){u.next=12;break}return a=n+i,u.next=6,(0,TG.default)(r.slice(n,a).arrayBuffer());case 6:return o=u.sent,n=a,u.next=10,o;case 10:u.next=2;break;case 12:case"end":return u.stop()}},t)})),KO.apply(this,arguments)}var PG=C(e_()),z2=C(AO()),$O=C(gO()),y_=C(zr());function eI(t,r){return Sc?Gwe(t,r):Vwe(t,r)}function Gwe(t,r){return QO.apply(this,arguments)}function QO(){return QO=(0,$O.default)(y_.default.mark(function t(r,e){var i,n,a,o,s,u;return y_.default.wrap(function(h){for(;;)switch(h.prev=h.next){case 0:i=r.getReader(),h.prev=1;case 2:return a=n||i.read(),e!=null&&e._streamReadAhead&&(n=i.read()),h.next=7,(0,z2.default)(a);case 7:if(o=h.sent,s=o.done,u=o.value,!s){h.next=12;break}return h.abrupt("return");case 12:return h.next=14,C2(u);case 14:h.next=2;break;case 16:h.next=21;break;case 18:h.prev=18,h.t0=h.catch(1),i.releaseLock();case 21:case"end":return h.stop()}},t,null,[[1,18]])})),QO.apply(this,arguments)}function Vwe(t,r){return JO.apply(this,arguments)}function JO(){return JO=(0,$O.default)(y_.default.mark(function t(r,e){var i,n,a,o,s,u;return y_.default.wrap(function(h){for(;;)switch(h.prev=h.next){case 0:i=!1,n=!1,h.prev=2,o=(0,PG.default)(r);case 4:return h.next=6,(0,z2.default)(o.next());case 6:if(!(i=!(s=h.sent).done)){h.next=13;break}return u=s.value,h.next=10,C2(u);case 10:i=!1,h.next=4;break;case 13:h.next=19;break;case 15:h.prev=15,h.t0=h.catch(2),n=!0,a=h.t0;case 19:if(h.prev=19,h.prev=20,!(i&&o.return!=null)){h.next=24;break}return h.next=24,(0,z2.default)(o.return());case 24:if(h.prev=24,!n){h.next=27;break}throw a;case 27:return h.finish(24);case 28:return h.finish(19);case 29:case"end":return h.stop()}},t,null,[[2,15,19,29],[20,,24,28]])})),JO.apply(this,arguments)}function CG(t,r){if(typeof t=="string")return qO(t,r);if(t instanceof ArrayBuffer)return ZO(t,r);if(Mc(t))return SG(t,r);if(M2(t))return eI(t,r);if(Cc(t)){var e=t;return eI(e.body,r)}throw new Error("makeIterator")}var OG="Cannot convert supplied data type";function Hwe(t,r,e){if(r.text&&typeof t=="string")return t;if(Ej(t)&&(t=t.buffer),t instanceof ArrayBuffer){var i=t;if(r.text&&!r.binary){var n=new TextDecoder("utf8");return n.decode(i)}return i}if(ArrayBuffer.isView(t)){if(r.text&&!r.binary){var a=new TextDecoder("utf8");return a.decode(t)}var o=t.buffer,s=t.byteLength||t.length;return(t.byteOffset!==0||s!==o.byteLength)&&(o=o.slice(t.byteOffset,t.byteOffset+s)),o}throw new Error(OG)}function IG(t,r,e){return rI.apply(this,arguments)}function rI(){return rI=(0,MG.default)(tI.default.mark(function t(r,e,i){var n,a;return tI.default.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:if(n=r instanceof ArrayBuffer||ArrayBuffer.isView(r),!(typeof r=="string"||n)){s.next=3;break}return s.abrupt("return",Hwe(r,e,i));case 3:if(!Mc(r)){s.next=7;break}return s.next=6,O2(r);case 6:r=s.sent;case 7:if(!Cc(r)){s.next=21;break}return a=r,s.next=11,Cj(a);case 11:if(!e.binary){s.next=17;break}return s.next=14,a.arrayBuffer();case 14:s.t0=s.sent,s.next=20;break;case 17:return s.next=19,a.text();case 19:s.t0=s.sent;case 20:return s.abrupt("return",s.t0);case 21:if(M2(r)&&(r=CG(r,i)),!(wj(r)||Tj(r))){s.next=24;break}return s.abrupt("return",xO(r));case 24:throw new Error(OG);case 25:case"end":return s.stop()}},t)})),rI.apply(this,arguments)}var nI=C(Ms()),LG=C(Ke());function RG(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function Wwe(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?RG(Object(e),!0).forEach(function(i){(0,LG.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):RG(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}function kG(t,r){var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null;if(e)return e;var i=Wwe({fetch:F2(r,t)},t);return Array.isArray(i.loaders)||(i.loaders=null),i}function BG(t,r){if(!r&&t&&!Array.isArray(t))return t;var e;if(t&&(e=Array.isArray(t)?t:[t]),r&&r.loaders){var i=Array.isArray(r.loaders)?r.loaders:[r.loaders];e=e?[].concat((0,nI.default)(e),(0,nI.default)(i)):i}return e&&e.length?e:null}function gm(t,r,e,i){return iI.apply(this,arguments)}function iI(){return iI=(0,oI.default)(__.default.mark(function t(r,e,i,n){var a,o,s,u,c;return __.default.wrap(function(v){for(;;)switch(v.prev=v.next){case 0:return Os(!n||(0,DG.default)(n)==="object"),e&&!Array.isArray(e)&&!v_(e)&&(n=void 0,i=e,e=void 0),v.next=4,r;case 4:return r=v.sent,i=i||{},a=dm(r),o=a.url,s=e,u=BG(s,n),v.next=11,_G(r,u,i);case 11:if(c=v.sent,c){v.next=14;break}return v.abrupt("return",null);case 14:return i=iG(i,c,u,o),n=kG({url:o,parse:gm,loaders:u},i,n),v.next=18,qwe(c,r,i,n);case 18:return v.abrupt("return",v.sent);case 19:case"end":return v.stop()}},t)})),iI.apply(this,arguments)}function qwe(t,r,e,i){return aI.apply(this,arguments)}function aI(){return aI=(0,oI.default)(__.default.mark(function t(r,e,i,n){var a,o,s,u,c,h,v,b;return __.default.wrap(function(M){for(;;)switch(M.prev=M.next){case 0:return rO(r),Cc(e)&&(a=e,o=a.ok,s=a.redirected,u=a.status,c=a.statusText,h=a.type,v=a.url,b=Object.fromEntries(a.headers.entries()),n.response={headers:b,ok:o,redirected:s,status:u,statusText:c,type:h,url:v}),M.next=4,IG(e,r,i);case 4:if(e=M.sent,!(r.parseTextSync&&typeof e=="string")){M.next=8;break}return i.dataType="text",M.abrupt("return",r.parseTextSync(e,i,n,r));case 8:if(!cO(r,i)){M.next=12;break}return M.next=11,fO(r,e,i,n,gm);case 11:return M.abrupt("return",M.sent);case 12:if(!(r.parseText&&typeof e=="string")){M.next=16;break}return M.next=15,r.parseText(e,i,n,r);case 15:return M.abrupt("return",M.sent);case 16:if(!r.parse){M.next=20;break}return M.next=19,r.parse(e,i,n,r);case 19:return M.abrupt("return",M.sent);case 20:throw Os(!r.parseSync),new Error("".concat(r.id," loader - no parser found and worker is disabled"));case 22:case"end":return M.stop()}},t)})),aI.apply(this,arguments)}var FG=C(Vr()),sI=C(zr());function Jo(t,r,e,i){return uI.apply(this,arguments)}function uI(){return uI=(0,FG.default)(sI.default.mark(function t(r,e,i,n){var a,o;return sI.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:if(!Array.isArray(e)&&!v_(e)&&(n=void 0,i=e,e=void 0),a=F2(i),o=r,typeof r!="string"){u.next=7;break}return u.next=6,a(r);case 6:o=u.sent;case 7:if(!Mc(r)){u.next=11;break}return u.next=10,a(r);case 10:o=u.sent;case 11:return u.next=13,gm(o,e,i);case 13:return u.abrupt("return",u.sent);case 14:case"end":return u.stop()}},t)})),uI.apply(this,arguments)}var NG={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,DOUBLE:5130,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};var HG=C(Ms());function zG(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=Xwe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
536
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function Xwe(t,r){if(t){if(typeof t=="string")return UG(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return UG(t,r)}}function UG(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}var jG,GG,WG={fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif',display:"flex",flex:"wrap",maxWidth:"500px",flexDirection:"column",zIndex:2};function U2(){return document.createElement("div")}function Zwe(t){if(!t.picked)return null;if(t.object===jG)return GG;var r={html:Kwe(t.object),style:WG};return GG=r,jG=t.object,r}var Ywe=new Set(["position","index"]);function Kwe(t){var r=U2();for(var e in t)if(!Ywe.has(e)){var i=U2();i.className="header",i.textContent=e;var n=U2();n.className="value",n.textContent=Jwe(t[e]);var a=U2();Qwe(a,i,n),a.appendChild(i),a.appendChild(n),r.appendChild(a)}return r.innerHTML}function Qwe(t,r,e){Object.assign(r.style,{fontWeight:700,marginRight:"10px",flex:"1 1 0%"}),Object.assign(e.style,{flex:"none",maxWidth:"250px",overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"}),Object.assign(t.style,{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"stretch"})}function Jwe(t){var r;if(Array.isArray(t)&&t.length>4)r="Array<".concat(t.length,">");else if(typeof t=="string")r=t;else if(typeof t=="number")r=String(t);else try{r=JSON.stringify(t)}catch{r="<Non-Serializable Object>"}var e=50;return r.length>e&&(r=r.slice(0,e)),r}function VG(t,r){var e,i=t,n="properties",a=/{[^}]*}/g,o=function(N){return N.replace(/[{}]/g,"")},s=(0,HG.default)(new Set(t.match(a).map(o))),u=zG(s),c;try{for(u.s();!(c=u.n()).done;){var h=c.value;if(h.includes(".")){e=r;var v=h.split("."),b=zG(v),S;try{for(b.s();!(S=b.n()).done;){var M=S.value;if(e.hasOwnProperty(M))e=e[M];else{e=void 0;break}}}catch(k){b.e(k)}finally{b.f()}}else r.hasOwnProperty(h)?e=r[h]:r[n]&&r[n].hasOwnProperty(h)?e=r[n][h]:e=void 0;i=i.replaceAll("{".concat(h,"}"),e)}}catch(k){u.e(k)}finally{u.f()}return i}function lI(t){return t?t.html||t.text?function(r){if(!r.picked)return null;var e={style:t.style||WG};return t.html?e.html=VG(t.html,r.object):e.text=VG(t.text,r.object),e}:Zwe:null}function qG(t){var r=document.createElement("link");r.type="text/css",r.rel="stylesheet",r.href=t,document.getElementsByTagName("head")[0].appendChild(r)}function XG(t,r){var e=document.createElement("div");return e.style.width=Number.isFinite(t)?"".concat(t,"px"):t,e.style.height="".concat(r,"px"),e.style.position="relative",e}var YG=C(ZG()),$we="https://api.tiles.mapbox.com/mapbox-gl-js/v1.13.2/mapbox-gl.css",hI=YG.default;function KG(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:$we;qG(t)}function QG(){for(var t=["mapboxgl-missing-css"],r=0,e=t;r<e.length;r++){var i=e[r],n=document.getElementsByClassName(i)[0];n&&n.style&&(n.style.display="none")}}var pI={};function JG(t){if(!pI[t]){var r=document.createElement("script");r.type="text/javascript",r.src=t;var e=document.querySelector("head");e.appendChild(r),pI[t]=new Promise(function(i){r.onload=i})}return pI[t]}var hV=C(Ke());var $G="3.3.1";var sV=C(Vr()),CI=C(zr());var eTe=globalThis._parseImageNode,dI=typeof Image<"u",mI=typeof ImageBitmap<"u",tTe=Boolean(eTe),vI=Sc?!0:tTe;function eV(t){switch(t){case"auto":return mI||dI||vI;case"imagebitmap":return mI;case"image":return dI;case"data":return vI;default:throw new Error("@loaders.gl/images: image ".concat(t," not supported in this environment"))}}function tV(){if(mI)return"imagebitmap";if(dI)return"image";if(vI)return"data";throw new Error("Install '@loaders.gl/polyfills' to parse images under Node.js")}var rV=C(Xn());function rTe(t){var r=nTe(t);if(!r)throw new Error("Not an image");return r}function nV(t){switch(rTe(t)){case"data":return t;case"image":case"imagebitmap":var r=document.createElement("canvas"),e=r.getContext("2d");if(!e)throw new Error("getImageData");return r.width=t.width,r.height=t.height,e.drawImage(t,0,0),e.getImageData(0,0,t.width,t.height);default:throw new Error("getImageData")}}function nTe(t){return typeof ImageBitmap<"u"&&t instanceof ImageBitmap?"imagebitmap":typeof Image<"u"&&t instanceof Image?"image":t&&(0,rV.default)(t)==="object"&&t.data&&t.width&&t.height?"data":null}var _I=C(Vr()),x_=C(zr());var iTe=/^data:image\/svg\+xml/,aTe=/\.svg((\?|#).*)?$/;function j2(t){return t&&(iTe.test(t)||aTe.test(t))}function iV(t,r){if(j2(r)){var e=new TextDecoder,i=e.decode(t);try{typeof unescape=="function"&&typeof encodeURIComponent=="function"&&(i=unescape(encodeURIComponent(i)))}catch(a){throw new Error(a.message)}var n="data:image/svg+xml;base64,".concat(btoa(i));return n}return AI(t,r)}function AI(t,r){if(j2(r))throw new Error("SVG cannot be parsed directly to imagebitmap");return new Blob([new Uint8Array(t)])}function b_(t,r,e){return gI.apply(this,arguments)}function gI(){return gI=(0,_I.default)(x_.default.mark(function t(r,e,i){var n,a,o;return x_.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return n=iV(r,i),a=self.URL||self.webkitURL,o=typeof n!="string"&&a.createObjectURL(n),u.prev=3,u.next=6,oTe(o||n,e);case 6:return u.abrupt("return",u.sent);case 7:return u.prev=7,o&&a.revokeObjectURL(o),u.finish(7);case 10:case"end":return u.stop()}},t,null,[[3,,7,10]])})),gI.apply(this,arguments)}function oTe(t,r){return yI.apply(this,arguments)}function yI(){return yI=(0,_I.default)(x_.default.mark(function t(r,e){var i;return x_.default.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if(i=new Image,i.src=r,!(e.image&&e.image.decode&&i.decode)){a.next=6;break}return a.next=5,i.decode();case 5:return a.abrupt("return",i);case 6:return a.next=8,new Promise(function(o,s){try{i.onload=function(){return o(i)},i.onerror=function(u){return s(new Error("Could not load image ".concat(r,": ").concat(u)))}}catch(u){s(u)}});case 8:return a.abrupt("return",a.sent);case 9:case"end":return a.stop()}},t)})),yI.apply(this,arguments)}var wI=C(Vr()),w_=C(zr());var sTe={},aV=!0;function TI(t,r,e){return xI.apply(this,arguments)}function xI(){return xI=(0,wI.default)(w_.default.mark(function t(r,e,i){var n,a,o;return w_.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:if(!j2(i)){u.next=7;break}return u.next=3,b_(r,e,i);case 3:a=u.sent,n=a,u.next=8;break;case 7:n=AI(r,i);case 8:return o=e&&e.imagebitmap,u.next=11,uTe(n,o);case 11:return u.abrupt("return",u.sent);case 12:case"end":return u.stop()}},t)})),xI.apply(this,arguments)}function uTe(t){return bI.apply(this,arguments)}function bI(){return bI=(0,wI.default)(w_.default.mark(function t(r){var e,i=arguments;return w_.default.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if(e=i.length>1&&i[1]!==void 0?i[1]:null,(lTe(e)||!aV)&&(e=null),!e){a.next=13;break}return a.prev=3,a.next=6,createImageBitmap(r,e);case 6:return a.abrupt("return",a.sent);case 9:a.prev=9,a.t0=a.catch(3),console.warn(a.t0),aV=!1;case 13:return a.next=15,createImageBitmap(r);case 15:return a.abrupt("return",a.sent);case 16:case"end":return a.stop()}},t,null,[[3,9]])})),bI.apply(this,arguments)}function lTe(t){for(var r in t||sTe)return!1;return!0}var oV=C(Vr()),EI=C(zr());var Mf=!1,T_=!0;function ym(t){var r=E_(t);return cTe(r)||pTe(r)||fTe(r)||hTe(r)}function cTe(t){var r=E_(t),e=r.byteLength>=24&&r.getUint32(0,Mf)===2303741511;return e?{mimeType:"image/png",width:r.getUint32(16,Mf),height:r.getUint32(20,Mf)}:null}function fTe(t){var r=E_(t),e=r.byteLength>=10&&r.getUint32(0,Mf)===1195984440;return e?{mimeType:"image/gif",width:r.getUint16(6,T_),height:r.getUint16(8,T_)}:null}function hTe(t){var r=E_(t),e=r.byteLength>=14&&r.getUint16(0,Mf)===16973&&r.getUint32(2,T_)===r.byteLength;return e?{mimeType:"image/bmp",width:r.getUint32(18,T_),height:r.getUint32(22,T_)}:null}function pTe(t){var r=E_(t),e=r.byteLength>=3&&r.getUint16(0,Mf)===65496&&r.getUint8(2)===255;if(!e)return null;for(var i=dTe(),n=i.tableMarkers,a=i.sofMarkers,o=2;o+9<r.byteLength;){var s=r.getUint16(o,Mf);if(a.has(s))return{mimeType:"image/jpeg",height:r.getUint16(o+5,Mf),width:r.getUint16(o+7,Mf)};if(!n.has(s))return null;o+=2,o+=r.getUint16(o,Mf)}return null}function dTe(){for(var t=new Set([65499,65476,65484,65501,65534]),r=65504;r<65520;++r)t.add(r);var e=new Set([65472,65473,65474,65475,65477,65478,65479,65481,65482,65483,65485,65486,65487,65502]);return{tableMarkers:t,sofMarkers:e}}function E_(t){if(t instanceof DataView)return t;if(ArrayBuffer.isView(t))return new DataView(t.buffer);if(t instanceof ArrayBuffer)return new DataView(t);throw new Error("toDataView")}function PI(t,r){return SI.apply(this,arguments)}function SI(){return SI=(0,oV.default)(EI.default.mark(function t(r,e){var i,n,a;return EI.default.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:return i=ym(r)||{},n=i.mimeType,a=globalThis._parseImageNode,Un(a),s.next=5,a(r,n);case 5:return s.abrupt("return",s.sent);case 6:case"end":return s.stop()}},t)})),SI.apply(this,arguments)}function OI(t,r,e){return MI.apply(this,arguments)}function MI(){return MI=(0,sV.default)(CI.default.mark(function t(r,e,i){var n,a,o,s,u,c;return CI.default.wrap(function(v){for(;;)switch(v.prev=v.next){case 0:e=e||{},n=e.image||{},a=n.type||"auto",o=i||{},s=o.url,u=mTe(a),v.t0=u,v.next=v.t0==="imagebitmap"?8:v.t0==="image"?12:v.t0==="data"?16:20;break;case 8:return v.next=10,TI(r,e,s);case 10:return c=v.sent,v.abrupt("break",21);case 12:return v.next=14,b_(r,e,s);case 14:return c=v.sent,v.abrupt("break",21);case 16:return v.next=18,PI(r,e);case 18:return c=v.sent,v.abrupt("break",21);case 20:Un(!1);case 21:return a==="data"&&(c=nV(c)),v.abrupt("return",c);case 23:case"end":return v.stop()}},t)})),MI.apply(this,arguments)}function mTe(t){switch(t){case"auto":case"data":return tV();default:return eV(t),t}}var vTe=["png","jpg","jpeg","gif","webp","bmp","ico","svg"],ATe=["image/png","image/jpeg","image/gif","image/webp","image/bmp","image/vnd.microsoft.icon","image/svg+xml"],gTe={image:{type:"auto",decode:!0}},Oc={id:"image",module:"images",name:"Images",version:$G,mimeTypes:ATe,extensions:vTe,parse:OI,tests:[function(t){return Boolean(ym(new DataView(t)))}],options:gTe};var yTe=["image/png","image/jpeg","image/gif"],II={};function RI(t){return II[t]===void 0&&(II[t]=_Te(t)),II[t]}function _Te(t){switch(t){case"image/webp":return xTe();case"image/svg":return Sc;default:if(!Sc){var r=globalThis._parseImageNode;return Boolean(r)&&yTe.includes(t)}return!0}}function xTe(){if(!Sc)return!1;try{var t=document.createElement("canvas");return t.toDataURL("image/webp").indexOf("data:image/webp")===0}catch{return!1}}var Bt=new jl({id:"deck"});var LI={};function uV(t){LI=t}function wo(t,r,e,i){Bt.level>0&&LI[t]&&LI[t].call(null,r,e,i)}function bTe(t){var r=t[0],e=t[t.length-1];return r==="{"&&e==="}"||r==="["&&e==="]"}var lV={id:"JSON",name:"JSON",module:"",version:"",options:{},extensions:["json","geojson"],mimeTypes:["application/json","application/geo+json"],testText:bTe,parseTextSync:JSON.parse};function cV(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function fV(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?cV(Object(e),!0).forEach(function(i){(0,hV.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):cV(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}function wTe(){var t="8.9.0",r=globalThis.deck&&globalThis.deck.VERSION;if(r&&r!==t)throw new Error("deck.gl - multiple versions detected: ".concat(r," vs ").concat(t));return r||(Bt.log(1,"deck.gl ".concat(t))(),globalThis.deck=fV(fV({},globalThis.deck),{},{VERSION:t,version:t,log:Bt,_registerLoggers:uV}),Am([lV,[Oc,{imagebitmap:{premultiplyAlpha:"none"}}]])),t}var G2=wTe();var Er={DEFAULT:-1,LNGLAT:1,METER_OFFSETS:2,LNGLAT_OFFSETS:3,CARTESIAN:0};Object.defineProperty(Er,"IDENTITY",{get:function(){return Bt.deprecated("COORDINATE_SYSTEM.IDENTITY","COORDINATE_SYSTEM.CARTESIAN")(),0}});var au={WEB_MERCATOR:1,GLOBE:2,WEB_MERCATOR_AUTO_OFFSET:4,IDENTITY:0},za={common:0,meters:1,pixels:2},kI={click:{handler:"onClick"},panstart:{handler:"onDragStart"},panmove:{handler:"onDrag"},panend:{handler:"onDragEnd"}},pV={DRAW:"draw",MASK:"mask",TERRAIN:"terrain"};var aZ=C(Ge()),oZ=C(Ye()),Sl=C(Ke());var er=new jl({id:"luma.gl"});function Bo(t,r){if(!t)throw new Error(r||"luma.gl: assertion failed.")}var TTe="Invalid WebGLRenderingContext";var ETe="Requires WebGL2";function Mh(t){return typeof WebGLRenderingContext<"u"&&t instanceof WebGLRenderingContext||typeof WebGL2RenderingContext<"u"&&t instanceof WebGL2RenderingContext?!0:Boolean(t&&Number.isFinite(t._version))}function kr(t){return typeof WebGL2RenderingContext<"u"&&t instanceof WebGL2RenderingContext?!0:Boolean(t&&t._version===2)}function BI(t){return kr(t)?t:null}function Oh(t){return Bo(Mh(t),TTe),t}function Ca(t){return Bo(kr(t),ETe),t}var S_={};function STe(t){globalThis.console&&globalThis.console.error&&globalThis.console.error(t)}function PTe(t){globalThis.console&&globalThis.console.log&&globalThis.console.log(t)}function CTe(t,r){S_[t]=!0,r!==void 0&&STe(r)}function MTe(t){var r=t.getError;t.getError=function(){var i;do i=r.apply(t),i!==0&&(S_[i]=!0);while(i!==0);for(i in S_)if(S_[i])return delete S_[i],parseInt(i,10);return 0}}var P_=function t(r){var e=r.gl;this.ext=r,this.isAlive=!0,this.hasBeenBound=!1,this.elementArrayBuffer=null,this.attribs=new Array(r.maxVertexAttribs);for(var i=0;i<this.attribs.length;i++){var n=new t.VertexAttrib(e);this.attribs[i]=n}this.maxAttrib=0};P_.VertexAttrib=function(r){this.enabled=!1,this.buffer=null,this.size=4,this.type=5126,this.normalized=!1,this.stride=16,this.offset=0,this.cached="",this.recache()};P_.VertexAttrib.prototype.recache=function(){this.cached=[this.size,this.type,this.normalized,this.stride,this.offset].join(":")};var _m=function(r){var e=this;this.gl=r,MTe(r);var i=this.original={getParameter:r.getParameter,enableVertexAttribArray:r.enableVertexAttribArray,disableVertexAttribArray:r.disableVertexAttribArray,bindBuffer:r.bindBuffer,getVertexAttrib:r.getVertexAttrib,vertexAttribPointer:r.vertexAttribPointer};r.getParameter=function(a){return a===e.VERTEX_ARRAY_BINDING_OES?e.currentVertexArrayObject===e.defaultVertexArrayObject?null:e.currentVertexArrayObject:i.getParameter.apply(this,arguments)},r.enableVertexAttribArray=function(a){var o=e.currentVertexArrayObject;o.maxAttrib=Math.max(o.maxAttrib,a);var s=o.attribs[a];return s.enabled=!0,i.enableVertexAttribArray.apply(this,arguments)},r.disableVertexAttribArray=function(a){var o=e.currentVertexArrayObject;o.maxAttrib=Math.max(o.maxAttrib,a);var s=o.attribs[a];return s.enabled=!1,i.disableVertexAttribArray.apply(this,arguments)},r.bindBuffer=function(a,o){switch(a){case 34962:e.currentArrayBuffer=o;break;case 34963:e.currentVertexArrayObject.elementArrayBuffer=o;break;default:}return i.bindBuffer.apply(this,arguments)},r.getVertexAttrib=function(a,o){var s=e.currentVertexArrayObject,u=s.attribs[a];switch(o){case 34975:return u.buffer;case 34338:return u.enabled;case 34339:return u.size;case 34340:return u.stride;case 34341:return u.type;case 34922:return u.normalized;default:return i.getVertexAttrib.apply(this,arguments)}},r.vertexAttribPointer=function(a,o,s,u,c,h){var v=e.currentVertexArrayObject;v.maxAttrib=Math.max(v.maxAttrib,a);var b=v.attribs[a];return b.buffer=e.currentArrayBuffer,b.size=o,b.type=s,b.normalized=u,b.stride=c,b.offset=h,b.recache(),i.vertexAttribPointer.apply(this,arguments)},r.instrumentExtension&&r.instrumentExtension(this,"OES_vertex_array_object"),r.canvas&&r.canvas.addEventListener("webglcontextrestored",function(){PTe("OESVertexArrayObject emulation library context restored"),e.reset_()},!0),this.reset_()};_m.prototype.VERTEX_ARRAY_BINDING_OES=34229;_m.prototype.reset_=function(){var r=this.vertexArrayObjects!==void 0;if(r)for(var e=0;e<this.vertexArrayObjects.length;++e)this.vertexArrayObjects.isAlive=!1;var i=this.gl;this.maxVertexAttribs=i.getParameter(34921),this.defaultVertexArrayObject=new P_(this),this.currentVertexArrayObject=null,this.currentArrayBuffer=null,this.vertexArrayObjects=[this.defaultVertexArrayObject],this.bindVertexArrayOES(null)};_m.prototype.createVertexArrayOES=function(){var r=new P_(this);return this.vertexArrayObjects.push(r),r};_m.prototype.deleteVertexArrayOES=function(r){r.isAlive=!1,this.vertexArrayObjects.splice(this.vertexArrayObjects.indexOf(r),1),this.currentVertexArrayObject===r&&this.bindVertexArrayOES(null)};_m.prototype.isVertexArrayOES=function(r){return!!(r&&r instanceof P_&&r.hasBeenBound&&r.ext===this)};_m.prototype.bindVertexArrayOES=function(r){var e=this.gl;if(r&&!r.isAlive){CTe(1282,"bindVertexArrayOES: attempt to bind deleted arrayObject");return}var i=this.original,n=this.currentVertexArrayObject;this.currentVertexArrayObject=r||this.defaultVertexArrayObject,this.currentVertexArrayObject.hasBeenBound=!0;var a=this.currentVertexArrayObject;if(n!==a){(!n||a.elementArrayBuffer!==n.elementArrayBuffer)&&i.bindBuffer.call(e,34963,a.elementArrayBuffer);for(var o=this.currentArrayBuffer,s=Math.max(n?n.maxAttrib:0,a.maxAttrib),u=0;u<=s;u++){var c=a.attribs[u],h=n?n.attribs[u]:null;if((!n||c.enabled!==h.enabled)&&(c.enabled?i.enableVertexAttribArray.call(e,u):i.disableVertexAttribArray.call(e,u)),c.enabled){var v=!1;(!n||c.buffer!==h.buffer)&&(o!==c.buffer&&(i.bindBuffer.call(e,34962,c.buffer),o=c.buffer),v=!0),(v||c.cached!==h.cached)&&i.vertexAttribPointer.call(e,u,c.size,c.type,c.normalized,c.stride,c.offset)}}this.currentArrayBuffer!==o&&i.bindBuffer.call(e,34962,this.currentArrayBuffer)}};function dV(t){if(typeof t.createVertexArray!="function"){var r=t.getSupportedExtensions;t.getSupportedExtensions=function(){var n=r.call(this)||[];return n.indexOf("OES_vertex_array_object")<0&&n.push("OES_vertex_array_object"),n};var e=t.getExtension;t.getExtension=function(n){var a=e.call(this,n);return a||(n!=="OES_vertex_array_object"?null:(t.__OESVertexArrayObject||(this.__OESVertexArrayObject=new _m(this)),this.__OESVertexArrayObject))}}}var C_=C(Ke());var ii=C(Ke());var ti,mV="OES_element_index",vV="WEBGL_draw_buffers",OTe="EXT_disjoint_timer_query",ITe="EXT_disjoint_timer_query_webgl2",RTe="EXT_texture_filter_anisotropic",AV="WEBGL_debug_renderer_info",LTe=35723,kTe=4352,BTe=36795,DTe=34047,FTe=37445,NTe=37446,Ma=function(r){return kr(r)?void 0:0},zTe=(ti={},(0,ii.default)(ti,3074,function(r){return kr(r)?void 0:36064}),(0,ii.default)(ti,LTe,function(t){return kr(t)?void 0:kTe}),(0,ii.default)(ti,35977,Ma),(0,ii.default)(ti,32937,Ma),(0,ii.default)(ti,BTe,function(t,r){var e=kr(t)?t.getExtension(ITe):t.getExtension(OTe);return e&&e.GPU_DISJOINT_EXT?r(e.GPU_DISJOINT_EXT):0}),(0,ii.default)(ti,FTe,function(t,r){var e=t.getExtension(AV);return r(e&&e.UNMASKED_VENDOR_WEBGL||7936)}),(0,ii.default)(ti,NTe,function(t,r){var e=t.getExtension(AV);return r(e&&e.UNMASKED_RENDERER_WEBGL||7937)}),(0,ii.default)(ti,DTe,function(t,r){var e=t.luma.extensions[RTe];return e?r(e.MAX_TEXTURE_MAX_ANISOTROPY_EXT):1}),(0,ii.default)(ti,32883,Ma),(0,ii.default)(ti,35071,Ma),(0,ii.default)(ti,37447,Ma),(0,ii.default)(ti,36063,function(r,e){if(!kr(r)){var i=r.getExtension(vV);return i?e(i.MAX_COLOR_ATTACHMENTS_WEBGL):0}}),(0,ii.default)(ti,35379,Ma),(0,ii.default)(ti,35374,Ma),(0,ii.default)(ti,35377,Ma),(0,ii.default)(ti,34852,function(r){if(!kr(r)){var e=r.getExtension(vV);return e?e.MAX_DRAW_BUFFERS_WEBGL:0}}),(0,ii.default)(ti,36203,function(r){return r.getExtension(mV)?2147483647:65535}),(0,ii.default)(ti,33001,function(r){return r.getExtension(mV)?16777216:65535}),(0,ii.default)(ti,33e3,function(r){return 16777216}),(0,ii.default)(ti,37157,Ma),(0,ii.default)(ti,35373,Ma),(0,ii.default)(ti,35657,Ma),(0,ii.default)(ti,36183,Ma),(0,ii.default)(ti,37137,Ma),(0,ii.default)(ti,34045,Ma),(0,ii.default)(ti,35978,Ma),(0,ii.default)(ti,35979,Ma),(0,ii.default)(ti,35968,Ma),(0,ii.default)(ti,35376,Ma),(0,ii.default)(ti,35375,Ma),(0,ii.default)(ti,35659,Ma),(0,ii.default)(ti,37154,Ma),(0,ii.default)(ti,35371,Ma),(0,ii.default)(ti,35658,Ma),(0,ii.default)(ti,35076,Ma),(0,ii.default)(ti,35077,Ma),(0,ii.default)(ti,35380,Ma),ti);function gV(t,r,e){var i=zTe[e],n=typeof i=="function"?i(t,r,e):i,a=n!==void 0?n:r(e);return a}var GA,UTe="OES_vertex_array_object",yV="ANGLE_instanced_arrays",jTe="WEBGL_draw_buffers",GTe="EXT_disjoint_timer_query",VTe="EXT_texture_filter_anisotropic",HTe="VertexArray requires WebGL2 or OES_vertex_array_object extension";function WTe(t,r){return{webgl2:kr(t),ext:t.getExtension(r)}}var DI=(GA={},(0,C_.default)(GA,UTe,{meta:{suffix:"OES"},createVertexArray:function(){Bo(!1,HTe)},deleteVertexArray:function(){},bindVertexArray:function(){},isVertexArray:function(){return!1}}),(0,C_.default)(GA,yV,{meta:{suffix:"ANGLE"},vertexAttribDivisor:function(r,e){Bo(e===0,"WebGL instanced rendering not supported")},drawElementsInstanced:function(){},drawArraysInstanced:function(){}}),(0,C_.default)(GA,jTe,{meta:{suffix:"WEBGL"},drawBuffers:function(){Bo(!1)}}),(0,C_.default)(GA,GTe,{meta:{suffix:"EXT"},createQuery:function(){Bo(!1)},deleteQuery:function(){Bo(!1)},beginQuery:function(){Bo(!1)},endQuery:function(){},getQuery:function(r,e){return this.getQueryObject(r,e)},getQueryParameter:function(r,e){return this.getQueryObject(r,e)},getQueryObject:function(){}}),GA),V2={readBuffer:function(r,e,i){kr(r)&&e(i)},getVertexAttrib:function(r,e,i,n){var a=WTe(r,yV),o=a.webgl2,s=a.ext,u;switch(n){case 35069:u=o?void 0:!1;break;case 35070:u=!o&&!s?0:void 0;break;default:}return u!==void 0?u:e(i,n)},getProgramParameter:function(r,e,i,n){if(!kr(r))switch(n){case 35967:return 35981;case 35971:return 0;case 35382:return 0;default:}return e(i,n)},getInternalformatParameter:function(r,e,i,n,a){if(!kr(r))switch(a){case 32937:return new Int32Array([0]);default:}return r.getInternalformatParameter(i,n,a)},getTexParameter:function(r,e,i,n){switch(n){case 34046:var a=r.luma.extensions,o=a[VTe];n=o&&o.TEXTURE_MAX_ANISOTROPY_EXT||34046;break;default:}return e(i,n)},getParameter:gV,hint:function(r,e,i,n){return e(i,n)}};function xV(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=qTe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
536
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function Xwe(t,r){if(t){if(typeof t=="string")return UG(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return UG(t,r)}}function UG(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}var jG,GG,WG={fontFamily:'"Helvetica Neue", Helvetica, Arial, sans-serif',display:"flex",flex:"wrap",maxWidth:"500px",flexDirection:"column",zIndex:2};function U2(){return document.createElement("div")}function Zwe(t){if(!t.picked)return null;if(t.object===jG)return GG;var r={html:Kwe(t.object),style:WG};return GG=r,jG=t.object,r}var Ywe=new Set(["position","index"]);function Kwe(t){var r=U2();for(var e in t)if(!Ywe.has(e)){var i=U2();i.className="header",i.textContent=e;var n=U2();n.className="value",n.textContent=Jwe(t[e]);var a=U2();Qwe(a,i,n),a.appendChild(i),a.appendChild(n),r.appendChild(a)}return r.innerHTML}function Qwe(t,r,e){Object.assign(r.style,{fontWeight:700,marginRight:"10px",flex:"1 1 0%"}),Object.assign(e.style,{flex:"none",maxWidth:"250px",overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"}),Object.assign(t.style,{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"stretch"})}function Jwe(t){var r;if(Array.isArray(t)&&t.length>4)r="Array<".concat(t.length,">");else if(typeof t=="string")r=t;else if(typeof t=="number")r=String(t);else try{r=JSON.stringify(t)}catch{r="<Non-Serializable Object>"}var e=50;return r.length>e&&(r=r.slice(0,e)),r}function VG(t,r){var e,i=t,n="properties",a=/{[^}]*}/g,o=function(N){return N.replace(/[{}]/g,"")},s=(0,HG.default)(new Set(t.match(a).map(o))),u=zG(s),c;try{for(u.s();!(c=u.n()).done;){var h=c.value;if(h.includes(".")){e=r;var v=h.split("."),b=zG(v),S;try{for(b.s();!(S=b.n()).done;){var M=S.value;if(e.hasOwnProperty(M))e=e[M];else{e=void 0;break}}}catch(k){b.e(k)}finally{b.f()}}else r.hasOwnProperty(h)?e=r[h]:r[n]&&r[n].hasOwnProperty(h)?e=r[n][h]:e=void 0;i=i.replaceAll("{".concat(h,"}"),e)}}catch(k){u.e(k)}finally{u.f()}return i}function lI(t){return t?t.html||t.text?function(r){if(!r.picked)return null;var e={style:t.style||WG};return t.html?e.html=VG(t.html,r.object):e.text=VG(t.text,r.object),e}:Zwe:null}function qG(t){var r=document.createElement("link");r.type="text/css",r.rel="stylesheet",r.href=t,document.getElementsByTagName("head")[0].appendChild(r)}function XG(t,r){var e=document.createElement("div");return e.style.width=Number.isFinite(t)?"".concat(t,"px"):t,e.style.height="".concat(r,"px"),e.style.position="relative",e}var YG=C(ZG()),$we="https://api.tiles.mapbox.com/mapbox-gl-js/v1.13.2/mapbox-gl.css",hI=YG.default;function KG(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:$we;qG(t)}function QG(){for(var t=["mapboxgl-missing-css"],r=0,e=t;r<e.length;r++){var i=e[r],n=document.getElementsByClassName(i)[0];n&&n.style&&(n.style.display="none")}}var pI={};function JG(t){if(!pI[t]){var r=document.createElement("script");r.type="text/javascript",r.src=t;var e=document.querySelector("head");e.appendChild(r),pI[t]=new Promise(function(i){r.onload=i})}return pI[t]}var hV=C(Ke());var $G="3.3.1";var sV=C(Vr()),CI=C(zr());var eTe=globalThis._parseImageNode,dI=typeof Image<"u",mI=typeof ImageBitmap<"u",tTe=Boolean(eTe),vI=Sc?!0:tTe;function eV(t){switch(t){case"auto":return mI||dI||vI;case"imagebitmap":return mI;case"image":return dI;case"data":return vI;default:throw new Error("@loaders.gl/images: image ".concat(t," not supported in this environment"))}}function tV(){if(mI)return"imagebitmap";if(dI)return"image";if(vI)return"data";throw new Error("Install '@loaders.gl/polyfills' to parse images under Node.js")}var rV=C(Xn());function rTe(t){var r=nTe(t);if(!r)throw new Error("Not an image");return r}function nV(t){switch(rTe(t)){case"data":return t;case"image":case"imagebitmap":var r=document.createElement("canvas"),e=r.getContext("2d");if(!e)throw new Error("getImageData");return r.width=t.width,r.height=t.height,e.drawImage(t,0,0),e.getImageData(0,0,t.width,t.height);default:throw new Error("getImageData")}}function nTe(t){return typeof ImageBitmap<"u"&&t instanceof ImageBitmap?"imagebitmap":typeof Image<"u"&&t instanceof Image?"image":t&&(0,rV.default)(t)==="object"&&t.data&&t.width&&t.height?"data":null}var _I=C(Vr()),x_=C(zr());var iTe=/^data:image\/svg\+xml/,aTe=/\.svg((\?|#).*)?$/;function j2(t){return t&&(iTe.test(t)||aTe.test(t))}function iV(t,r){if(j2(r)){var e=new TextDecoder,i=e.decode(t);try{typeof unescape=="function"&&typeof encodeURIComponent=="function"&&(i=unescape(encodeURIComponent(i)))}catch(a){throw new Error(a.message)}var n="data:image/svg+xml;base64,".concat(btoa(i));return n}return AI(t,r)}function AI(t,r){if(j2(r))throw new Error("SVG cannot be parsed directly to imagebitmap");return new Blob([new Uint8Array(t)])}function b_(t,r,e){return gI.apply(this,arguments)}function gI(){return gI=(0,_I.default)(x_.default.mark(function t(r,e,i){var n,a,o;return x_.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return n=iV(r,i),a=self.URL||self.webkitURL,o=typeof n!="string"&&a.createObjectURL(n),u.prev=3,u.next=6,oTe(o||n,e);case 6:return u.abrupt("return",u.sent);case 7:return u.prev=7,o&&a.revokeObjectURL(o),u.finish(7);case 10:case"end":return u.stop()}},t,null,[[3,,7,10]])})),gI.apply(this,arguments)}function oTe(t,r){return yI.apply(this,arguments)}function yI(){return yI=(0,_I.default)(x_.default.mark(function t(r,e){var i;return x_.default.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if(i=new Image,i.src=r,!(e.image&&e.image.decode&&i.decode)){a.next=6;break}return a.next=5,i.decode();case 5:return a.abrupt("return",i);case 6:return a.next=8,new Promise(function(o,s){try{i.onload=function(){return o(i)},i.onerror=function(u){return s(new Error("Could not load image ".concat(r,": ").concat(u)))}}catch(u){s(u)}});case 8:return a.abrupt("return",a.sent);case 9:case"end":return a.stop()}},t)})),yI.apply(this,arguments)}var wI=C(Vr()),w_=C(zr());var sTe={},aV=!0;function TI(t,r,e){return xI.apply(this,arguments)}function xI(){return xI=(0,wI.default)(w_.default.mark(function t(r,e,i){var n,a,o;return w_.default.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:if(!j2(i)){u.next=7;break}return u.next=3,b_(r,e,i);case 3:a=u.sent,n=a,u.next=8;break;case 7:n=AI(r,i);case 8:return o=e&&e.imagebitmap,u.next=11,uTe(n,o);case 11:return u.abrupt("return",u.sent);case 12:case"end":return u.stop()}},t)})),xI.apply(this,arguments)}function uTe(t){return bI.apply(this,arguments)}function bI(){return bI=(0,wI.default)(w_.default.mark(function t(r){var e,i=arguments;return w_.default.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:if(e=i.length>1&&i[1]!==void 0?i[1]:null,(lTe(e)||!aV)&&(e=null),!e){a.next=13;break}return a.prev=3,a.next=6,createImageBitmap(r,e);case 6:return a.abrupt("return",a.sent);case 9:a.prev=9,a.t0=a.catch(3),console.warn(a.t0),aV=!1;case 13:return a.next=15,createImageBitmap(r);case 15:return a.abrupt("return",a.sent);case 16:case"end":return a.stop()}},t,null,[[3,9]])})),bI.apply(this,arguments)}function lTe(t){for(var r in t||sTe)return!1;return!0}var oV=C(Vr()),EI=C(zr());var Mf=!1,T_=!0;function ym(t){var r=E_(t);return cTe(r)||pTe(r)||fTe(r)||hTe(r)}function cTe(t){var r=E_(t),e=r.byteLength>=24&&r.getUint32(0,Mf)===2303741511;return e?{mimeType:"image/png",width:r.getUint32(16,Mf),height:r.getUint32(20,Mf)}:null}function fTe(t){var r=E_(t),e=r.byteLength>=10&&r.getUint32(0,Mf)===1195984440;return e?{mimeType:"image/gif",width:r.getUint16(6,T_),height:r.getUint16(8,T_)}:null}function hTe(t){var r=E_(t),e=r.byteLength>=14&&r.getUint16(0,Mf)===16973&&r.getUint32(2,T_)===r.byteLength;return e?{mimeType:"image/bmp",width:r.getUint32(18,T_),height:r.getUint32(22,T_)}:null}function pTe(t){var r=E_(t),e=r.byteLength>=3&&r.getUint16(0,Mf)===65496&&r.getUint8(2)===255;if(!e)return null;for(var i=dTe(),n=i.tableMarkers,a=i.sofMarkers,o=2;o+9<r.byteLength;){var s=r.getUint16(o,Mf);if(a.has(s))return{mimeType:"image/jpeg",height:r.getUint16(o+5,Mf),width:r.getUint16(o+7,Mf)};if(!n.has(s))return null;o+=2,o+=r.getUint16(o,Mf)}return null}function dTe(){for(var t=new Set([65499,65476,65484,65501,65534]),r=65504;r<65520;++r)t.add(r);var e=new Set([65472,65473,65474,65475,65477,65478,65479,65481,65482,65483,65485,65486,65487,65502]);return{tableMarkers:t,sofMarkers:e}}function E_(t){if(t instanceof DataView)return t;if(ArrayBuffer.isView(t))return new DataView(t.buffer);if(t instanceof ArrayBuffer)return new DataView(t);throw new Error("toDataView")}function PI(t,r){return SI.apply(this,arguments)}function SI(){return SI=(0,oV.default)(EI.default.mark(function t(r,e){var i,n,a;return EI.default.wrap(function(s){for(;;)switch(s.prev=s.next){case 0:return i=ym(r)||{},n=i.mimeType,a=globalThis._parseImageNode,Un(a),s.next=5,a(r,n);case 5:return s.abrupt("return",s.sent);case 6:case"end":return s.stop()}},t)})),SI.apply(this,arguments)}function OI(t,r,e){return MI.apply(this,arguments)}function MI(){return MI=(0,sV.default)(CI.default.mark(function t(r,e,i){var n,a,o,s,u,c;return CI.default.wrap(function(v){for(;;)switch(v.prev=v.next){case 0:e=e||{},n=e.image||{},a=n.type||"auto",o=i||{},s=o.url,u=mTe(a),v.t0=u,v.next=v.t0==="imagebitmap"?8:v.t0==="image"?12:v.t0==="data"?16:20;break;case 8:return v.next=10,TI(r,e,s);case 10:return c=v.sent,v.abrupt("break",21);case 12:return v.next=14,b_(r,e,s);case 14:return c=v.sent,v.abrupt("break",21);case 16:return v.next=18,PI(r,e);case 18:return c=v.sent,v.abrupt("break",21);case 20:Un(!1);case 21:return a==="data"&&(c=nV(c)),v.abrupt("return",c);case 23:case"end":return v.stop()}},t)})),MI.apply(this,arguments)}function mTe(t){switch(t){case"auto":case"data":return tV();default:return eV(t),t}}var vTe=["png","jpg","jpeg","gif","webp","bmp","ico","svg"],ATe=["image/png","image/jpeg","image/gif","image/webp","image/bmp","image/vnd.microsoft.icon","image/svg+xml"],gTe={image:{type:"auto",decode:!0}},Oc={id:"image",module:"images",name:"Images",version:$G,mimeTypes:ATe,extensions:vTe,parse:OI,tests:[function(t){return Boolean(ym(new DataView(t)))}],options:gTe};var yTe=["image/png","image/jpeg","image/gif"],II={};function RI(t){return II[t]===void 0&&(II[t]=_Te(t)),II[t]}function _Te(t){switch(t){case"image/webp":return xTe();case"image/svg":return Sc;default:if(!Sc){var r=globalThis._parseImageNode;return Boolean(r)&&yTe.includes(t)}return!0}}function xTe(){if(!Sc)return!1;try{var t=document.createElement("canvas");return t.toDataURL("image/webp").indexOf("data:image/webp")===0}catch{return!1}}var Bt=new jl({id:"deck"});var LI={};function uV(t){LI=t}function wo(t,r,e,i){Bt.level>0&&LI[t]&&LI[t].call(null,r,e,i)}function bTe(t){var r=t[0],e=t[t.length-1];return r==="{"&&e==="}"||r==="["&&e==="]"}var lV={id:"JSON",name:"JSON",module:"",version:"",options:{},extensions:["json","geojson"],mimeTypes:["application/json","application/geo+json"],testText:bTe,parseTextSync:JSON.parse};function cV(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),e.push.apply(e,i)}return e}function fV(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?cV(Object(e),!0).forEach(function(i){(0,hV.default)(t,i,e[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):cV(Object(e)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(e,i))})}return t}function wTe(){var t="8.9.1",r=globalThis.deck&&globalThis.deck.VERSION;if(r&&r!==t)throw new Error("deck.gl - multiple versions detected: ".concat(r," vs ").concat(t));return r||(Bt.log(1,"deck.gl ".concat(t))(),globalThis.deck=fV(fV({},globalThis.deck),{},{VERSION:t,version:t,log:Bt,_registerLoggers:uV}),Am([lV,[Oc,{imagebitmap:{premultiplyAlpha:"none"}}]])),t}var G2=wTe();var Er={DEFAULT:-1,LNGLAT:1,METER_OFFSETS:2,LNGLAT_OFFSETS:3,CARTESIAN:0};Object.defineProperty(Er,"IDENTITY",{get:function(){return Bt.deprecated("COORDINATE_SYSTEM.IDENTITY","COORDINATE_SYSTEM.CARTESIAN")(),0}});var au={WEB_MERCATOR:1,GLOBE:2,WEB_MERCATOR_AUTO_OFFSET:4,IDENTITY:0},za={common:0,meters:1,pixels:2},kI={click:{handler:"onClick"},panstart:{handler:"onDragStart"},panmove:{handler:"onDrag"},panend:{handler:"onDragEnd"}},pV={DRAW:"draw",MASK:"mask",TERRAIN:"terrain"};var aZ=C(Ge()),oZ=C(Ye()),Sl=C(Ke());var er=new jl({id:"luma.gl"});function Bo(t,r){if(!t)throw new Error(r||"luma.gl: assertion failed.")}var TTe="Invalid WebGLRenderingContext";var ETe="Requires WebGL2";function Mh(t){return typeof WebGLRenderingContext<"u"&&t instanceof WebGLRenderingContext||typeof WebGL2RenderingContext<"u"&&t instanceof WebGL2RenderingContext?!0:Boolean(t&&Number.isFinite(t._version))}function kr(t){return typeof WebGL2RenderingContext<"u"&&t instanceof WebGL2RenderingContext?!0:Boolean(t&&t._version===2)}function BI(t){return kr(t)?t:null}function Oh(t){return Bo(Mh(t),TTe),t}function Ca(t){return Bo(kr(t),ETe),t}var S_={};function STe(t){globalThis.console&&globalThis.console.error&&globalThis.console.error(t)}function PTe(t){globalThis.console&&globalThis.console.log&&globalThis.console.log(t)}function CTe(t,r){S_[t]=!0,r!==void 0&&STe(r)}function MTe(t){var r=t.getError;t.getError=function(){var i;do i=r.apply(t),i!==0&&(S_[i]=!0);while(i!==0);for(i in S_)if(S_[i])return delete S_[i],parseInt(i,10);return 0}}var P_=function t(r){var e=r.gl;this.ext=r,this.isAlive=!0,this.hasBeenBound=!1,this.elementArrayBuffer=null,this.attribs=new Array(r.maxVertexAttribs);for(var i=0;i<this.attribs.length;i++){var n=new t.VertexAttrib(e);this.attribs[i]=n}this.maxAttrib=0};P_.VertexAttrib=function(r){this.enabled=!1,this.buffer=null,this.size=4,this.type=5126,this.normalized=!1,this.stride=16,this.offset=0,this.cached="",this.recache()};P_.VertexAttrib.prototype.recache=function(){this.cached=[this.size,this.type,this.normalized,this.stride,this.offset].join(":")};var _m=function(r){var e=this;this.gl=r,MTe(r);var i=this.original={getParameter:r.getParameter,enableVertexAttribArray:r.enableVertexAttribArray,disableVertexAttribArray:r.disableVertexAttribArray,bindBuffer:r.bindBuffer,getVertexAttrib:r.getVertexAttrib,vertexAttribPointer:r.vertexAttribPointer};r.getParameter=function(a){return a===e.VERTEX_ARRAY_BINDING_OES?e.currentVertexArrayObject===e.defaultVertexArrayObject?null:e.currentVertexArrayObject:i.getParameter.apply(this,arguments)},r.enableVertexAttribArray=function(a){var o=e.currentVertexArrayObject;o.maxAttrib=Math.max(o.maxAttrib,a);var s=o.attribs[a];return s.enabled=!0,i.enableVertexAttribArray.apply(this,arguments)},r.disableVertexAttribArray=function(a){var o=e.currentVertexArrayObject;o.maxAttrib=Math.max(o.maxAttrib,a);var s=o.attribs[a];return s.enabled=!1,i.disableVertexAttribArray.apply(this,arguments)},r.bindBuffer=function(a,o){switch(a){case 34962:e.currentArrayBuffer=o;break;case 34963:e.currentVertexArrayObject.elementArrayBuffer=o;break;default:}return i.bindBuffer.apply(this,arguments)},r.getVertexAttrib=function(a,o){var s=e.currentVertexArrayObject,u=s.attribs[a];switch(o){case 34975:return u.buffer;case 34338:return u.enabled;case 34339:return u.size;case 34340:return u.stride;case 34341:return u.type;case 34922:return u.normalized;default:return i.getVertexAttrib.apply(this,arguments)}},r.vertexAttribPointer=function(a,o,s,u,c,h){var v=e.currentVertexArrayObject;v.maxAttrib=Math.max(v.maxAttrib,a);var b=v.attribs[a];return b.buffer=e.currentArrayBuffer,b.size=o,b.type=s,b.normalized=u,b.stride=c,b.offset=h,b.recache(),i.vertexAttribPointer.apply(this,arguments)},r.instrumentExtension&&r.instrumentExtension(this,"OES_vertex_array_object"),r.canvas&&r.canvas.addEventListener("webglcontextrestored",function(){PTe("OESVertexArrayObject emulation library context restored"),e.reset_()},!0),this.reset_()};_m.prototype.VERTEX_ARRAY_BINDING_OES=34229;_m.prototype.reset_=function(){var r=this.vertexArrayObjects!==void 0;if(r)for(var e=0;e<this.vertexArrayObjects.length;++e)this.vertexArrayObjects.isAlive=!1;var i=this.gl;this.maxVertexAttribs=i.getParameter(34921),this.defaultVertexArrayObject=new P_(this),this.currentVertexArrayObject=null,this.currentArrayBuffer=null,this.vertexArrayObjects=[this.defaultVertexArrayObject],this.bindVertexArrayOES(null)};_m.prototype.createVertexArrayOES=function(){var r=new P_(this);return this.vertexArrayObjects.push(r),r};_m.prototype.deleteVertexArrayOES=function(r){r.isAlive=!1,this.vertexArrayObjects.splice(this.vertexArrayObjects.indexOf(r),1),this.currentVertexArrayObject===r&&this.bindVertexArrayOES(null)};_m.prototype.isVertexArrayOES=function(r){return!!(r&&r instanceof P_&&r.hasBeenBound&&r.ext===this)};_m.prototype.bindVertexArrayOES=function(r){var e=this.gl;if(r&&!r.isAlive){CTe(1282,"bindVertexArrayOES: attempt to bind deleted arrayObject");return}var i=this.original,n=this.currentVertexArrayObject;this.currentVertexArrayObject=r||this.defaultVertexArrayObject,this.currentVertexArrayObject.hasBeenBound=!0;var a=this.currentVertexArrayObject;if(n!==a){(!n||a.elementArrayBuffer!==n.elementArrayBuffer)&&i.bindBuffer.call(e,34963,a.elementArrayBuffer);for(var o=this.currentArrayBuffer,s=Math.max(n?n.maxAttrib:0,a.maxAttrib),u=0;u<=s;u++){var c=a.attribs[u],h=n?n.attribs[u]:null;if((!n||c.enabled!==h.enabled)&&(c.enabled?i.enableVertexAttribArray.call(e,u):i.disableVertexAttribArray.call(e,u)),c.enabled){var v=!1;(!n||c.buffer!==h.buffer)&&(o!==c.buffer&&(i.bindBuffer.call(e,34962,c.buffer),o=c.buffer),v=!0),(v||c.cached!==h.cached)&&i.vertexAttribPointer.call(e,u,c.size,c.type,c.normalized,c.stride,c.offset)}}this.currentArrayBuffer!==o&&i.bindBuffer.call(e,34962,this.currentArrayBuffer)}};function dV(t){if(typeof t.createVertexArray!="function"){var r=t.getSupportedExtensions;t.getSupportedExtensions=function(){var n=r.call(this)||[];return n.indexOf("OES_vertex_array_object")<0&&n.push("OES_vertex_array_object"),n};var e=t.getExtension;t.getExtension=function(n){var a=e.call(this,n);return a||(n!=="OES_vertex_array_object"?null:(t.__OESVertexArrayObject||(this.__OESVertexArrayObject=new _m(this)),this.__OESVertexArrayObject))}}}var C_=C(Ke());var ii=C(Ke());var ti,mV="OES_element_index",vV="WEBGL_draw_buffers",OTe="EXT_disjoint_timer_query",ITe="EXT_disjoint_timer_query_webgl2",RTe="EXT_texture_filter_anisotropic",AV="WEBGL_debug_renderer_info",LTe=35723,kTe=4352,BTe=36795,DTe=34047,FTe=37445,NTe=37446,Ma=function(r){return kr(r)?void 0:0},zTe=(ti={},(0,ii.default)(ti,3074,function(r){return kr(r)?void 0:36064}),(0,ii.default)(ti,LTe,function(t){return kr(t)?void 0:kTe}),(0,ii.default)(ti,35977,Ma),(0,ii.default)(ti,32937,Ma),(0,ii.default)(ti,BTe,function(t,r){var e=kr(t)?t.getExtension(ITe):t.getExtension(OTe);return e&&e.GPU_DISJOINT_EXT?r(e.GPU_DISJOINT_EXT):0}),(0,ii.default)(ti,FTe,function(t,r){var e=t.getExtension(AV);return r(e&&e.UNMASKED_VENDOR_WEBGL||7936)}),(0,ii.default)(ti,NTe,function(t,r){var e=t.getExtension(AV);return r(e&&e.UNMASKED_RENDERER_WEBGL||7937)}),(0,ii.default)(ti,DTe,function(t,r){var e=t.luma.extensions[RTe];return e?r(e.MAX_TEXTURE_MAX_ANISOTROPY_EXT):1}),(0,ii.default)(ti,32883,Ma),(0,ii.default)(ti,35071,Ma),(0,ii.default)(ti,37447,Ma),(0,ii.default)(ti,36063,function(r,e){if(!kr(r)){var i=r.getExtension(vV);return i?e(i.MAX_COLOR_ATTACHMENTS_WEBGL):0}}),(0,ii.default)(ti,35379,Ma),(0,ii.default)(ti,35374,Ma),(0,ii.default)(ti,35377,Ma),(0,ii.default)(ti,34852,function(r){if(!kr(r)){var e=r.getExtension(vV);return e?e.MAX_DRAW_BUFFERS_WEBGL:0}}),(0,ii.default)(ti,36203,function(r){return r.getExtension(mV)?2147483647:65535}),(0,ii.default)(ti,33001,function(r){return r.getExtension(mV)?16777216:65535}),(0,ii.default)(ti,33e3,function(r){return 16777216}),(0,ii.default)(ti,37157,Ma),(0,ii.default)(ti,35373,Ma),(0,ii.default)(ti,35657,Ma),(0,ii.default)(ti,36183,Ma),(0,ii.default)(ti,37137,Ma),(0,ii.default)(ti,34045,Ma),(0,ii.default)(ti,35978,Ma),(0,ii.default)(ti,35979,Ma),(0,ii.default)(ti,35968,Ma),(0,ii.default)(ti,35376,Ma),(0,ii.default)(ti,35375,Ma),(0,ii.default)(ti,35659,Ma),(0,ii.default)(ti,37154,Ma),(0,ii.default)(ti,35371,Ma),(0,ii.default)(ti,35658,Ma),(0,ii.default)(ti,35076,Ma),(0,ii.default)(ti,35077,Ma),(0,ii.default)(ti,35380,Ma),ti);function gV(t,r,e){var i=zTe[e],n=typeof i=="function"?i(t,r,e):i,a=n!==void 0?n:r(e);return a}var GA,UTe="OES_vertex_array_object",yV="ANGLE_instanced_arrays",jTe="WEBGL_draw_buffers",GTe="EXT_disjoint_timer_query",VTe="EXT_texture_filter_anisotropic",HTe="VertexArray requires WebGL2 or OES_vertex_array_object extension";function WTe(t,r){return{webgl2:kr(t),ext:t.getExtension(r)}}var DI=(GA={},(0,C_.default)(GA,UTe,{meta:{suffix:"OES"},createVertexArray:function(){Bo(!1,HTe)},deleteVertexArray:function(){},bindVertexArray:function(){},isVertexArray:function(){return!1}}),(0,C_.default)(GA,yV,{meta:{suffix:"ANGLE"},vertexAttribDivisor:function(r,e){Bo(e===0,"WebGL instanced rendering not supported")},drawElementsInstanced:function(){},drawArraysInstanced:function(){}}),(0,C_.default)(GA,jTe,{meta:{suffix:"WEBGL"},drawBuffers:function(){Bo(!1)}}),(0,C_.default)(GA,GTe,{meta:{suffix:"EXT"},createQuery:function(){Bo(!1)},deleteQuery:function(){Bo(!1)},beginQuery:function(){Bo(!1)},endQuery:function(){},getQuery:function(r,e){return this.getQueryObject(r,e)},getQueryParameter:function(r,e){return this.getQueryObject(r,e)},getQueryObject:function(){}}),GA),V2={readBuffer:function(r,e,i){kr(r)&&e(i)},getVertexAttrib:function(r,e,i,n){var a=WTe(r,yV),o=a.webgl2,s=a.ext,u;switch(n){case 35069:u=o?void 0:!1;break;case 35070:u=!o&&!s?0:void 0;break;default:}return u!==void 0?u:e(i,n)},getProgramParameter:function(r,e,i,n){if(!kr(r))switch(n){case 35967:return 35981;case 35971:return 0;case 35382:return 0;default:}return e(i,n)},getInternalformatParameter:function(r,e,i,n,a){if(!kr(r))switch(a){case 32937:return new Int32Array([0]);default:}return r.getInternalformatParameter(i,n,a)},getTexParameter:function(r,e,i,n){switch(n){case 34046:var a=r.luma.extensions,o=a[VTe];n=o&&o.TEXTURE_MAX_ANISOTROPY_EXT||34046;break;default:}return e(i,n)},getParameter:gV,hint:function(r,e,i,n){return e(i,n)}};function xV(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=qTe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
537
537
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function qTe(t,r){if(t){if(typeof t=="string")return _V(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return _V(t,r)}}function _V(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}function bV(t){t.luma=t.luma||{};var r=t.luma;return r.polyfilled||(dV(t),XTe(t),YTe(t,DI),ZTe(t,{target:r,target2:t}),r.polyfilled=!0),t}globalThis.polyfillContext=bV;function XTe(t){t.luma.extensions={};var r=t.getSupportedExtensions()||[],e=xV(r),i;try{for(e.s();!(i=e.n()).done;){var n=i.value;t.luma[n]=t.getExtension(n)}}catch(a){e.e(a)}finally{e.f()}}function ZTe(t,r){var e=r.target,i=r.target2;Object.keys(V2).forEach(function(n){if(typeof V2[n]=="function"){var a=t[n]?t[n].bind(t):function(){},o=V2[n].bind(null,t,a);e[n]=o,i[n]=o}})}function YTe(t,r){var e=xV(Object.getOwnPropertyNames(r)),i;try{for(e.s();!(i=e.n()).done;){var n=i.value;n!=="overrides"&&KTe(t,{extension:n,target:t.luma,target2:t})}}catch(a){e.e(a)}finally{e.f()}}function KTe(t,r){var e=r.extension,i=r.target,n=r.target2,a=DI[e];Bo(a);for(var o=a.meta,s=o===void 0?{}:o,u=s.suffix,c=u===void 0?"":u,h=t.getExtension(e),v=function(){var k=S[b],N="".concat(k).concat(c),j=null;k==="meta"||typeof t[k]=="function"||(h&&typeof h[N]=="function"?j=function(){return h[N].apply(h,arguments)}:typeof a[k]=="function"&&(j=a[k].bind(i))),j&&(i[k]=j,n[k]=j)},b=0,S=Object.keys(a);b<S.length;b++)v()}var H2=C(Kr()),co=C(Ms()),Xe=C(Ke());var Wr,Zt,Gl,O_=(Wr={},(0,Xe.default)(Wr,3042,!1),(0,Xe.default)(Wr,32773,new Float32Array([0,0,0,0])),(0,Xe.default)(Wr,32777,32774),(0,Xe.default)(Wr,34877,32774),(0,Xe.default)(Wr,32969,1),(0,Xe.default)(Wr,32968,0),(0,Xe.default)(Wr,32971,1),(0,Xe.default)(Wr,32970,0),(0,Xe.default)(Wr,3106,new Float32Array([0,0,0,0])),(0,Xe.default)(Wr,3107,[!0,!0,!0,!0]),(0,Xe.default)(Wr,2884,!1),(0,Xe.default)(Wr,2885,1029),(0,Xe.default)(Wr,2929,!1),(0,Xe.default)(Wr,2931,1),(0,Xe.default)(Wr,2932,513),(0,Xe.default)(Wr,2928,new Float32Array([0,1])),(0,Xe.default)(Wr,2930,!0),(0,Xe.default)(Wr,3024,!0),(0,Xe.default)(Wr,36006,null),(0,Xe.default)(Wr,2886,2305),(0,Xe.default)(Wr,33170,4352),(0,Xe.default)(Wr,2849,1),(0,Xe.default)(Wr,32823,!1),(0,Xe.default)(Wr,32824,0),(0,Xe.default)(Wr,10752,0),(0,Xe.default)(Wr,32938,1),(0,Xe.default)(Wr,32939,!1),(0,Xe.default)(Wr,3089,!1),(0,Xe.default)(Wr,3088,new Int32Array([0,0,1024,1024])),(0,Xe.default)(Wr,2960,!1),(0,Xe.default)(Wr,2961,0),(0,Xe.default)(Wr,2968,4294967295),(0,Xe.default)(Wr,36005,4294967295),(0,Xe.default)(Wr,2962,519),(0,Xe.default)(Wr,2967,0),(0,Xe.default)(Wr,2963,4294967295),(0,Xe.default)(Wr,34816,519),(0,Xe.default)(Wr,36003,0),(0,Xe.default)(Wr,36004,4294967295),(0,Xe.default)(Wr,2964,7680),(0,Xe.default)(Wr,2965,7680),(0,Xe.default)(Wr,2966,7680),(0,Xe.default)(Wr,34817,7680),(0,Xe.default)(Wr,34818,7680),(0,Xe.default)(Wr,34819,7680),(0,Xe.default)(Wr,2978,[0,0,1024,1024]),(0,Xe.default)(Wr,3333,4),(0,Xe.default)(Wr,3317,4),(0,Xe.default)(Wr,37440,!1),(0,Xe.default)(Wr,37441,!1),(0,Xe.default)(Wr,37443,37444),(0,Xe.default)(Wr,35723,4352),(0,Xe.default)(Wr,36010,null),(0,Xe.default)(Wr,35977,!1),(0,Xe.default)(Wr,3330,0),(0,Xe.default)(Wr,3332,0),(0,Xe.default)(Wr,3331,0),(0,Xe.default)(Wr,3314,0),(0,Xe.default)(Wr,32878,0),(0,Xe.default)(Wr,3316,0),(0,Xe.default)(Wr,3315,0),(0,Xe.default)(Wr,32877,0),Wr),Xp=function(r,e,i){return e?r.enable(i):r.disable(i)},wV=function(r,e,i){return r.hint(i,e)},xl=function(r,e,i){return r.pixelStorei(i,e)},QTe=function(r,e){var i=kr(r)?36009:36160;return r.bindFramebuffer(i,e)},JTe=function(r,e){return r.bindFramebuffer(36008,e)};function M_(t){return Array.isArray(t)||ArrayBuffer.isView(t)}var TV=(Zt={},(0,Xe.default)(Zt,3042,Xp),(0,Xe.default)(Zt,32773,function(r,e){return r.blendColor.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,32777,"blendEquation"),(0,Xe.default)(Zt,34877,"blendEquation"),(0,Xe.default)(Zt,32969,"blendFunc"),(0,Xe.default)(Zt,32968,"blendFunc"),(0,Xe.default)(Zt,32971,"blendFunc"),(0,Xe.default)(Zt,32970,"blendFunc"),(0,Xe.default)(Zt,3106,function(r,e){return r.clearColor.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,3107,function(r,e){return r.colorMask.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,2884,Xp),(0,Xe.default)(Zt,2885,function(r,e){return r.cullFace(e)}),(0,Xe.default)(Zt,2929,Xp),(0,Xe.default)(Zt,2931,function(r,e){return r.clearDepth(e)}),(0,Xe.default)(Zt,2932,function(r,e){return r.depthFunc(e)}),(0,Xe.default)(Zt,2928,function(r,e){return r.depthRange.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,2930,function(r,e){return r.depthMask(e)}),(0,Xe.default)(Zt,3024,Xp),(0,Xe.default)(Zt,35723,wV),(0,Xe.default)(Zt,36006,QTe),(0,Xe.default)(Zt,2886,function(r,e){return r.frontFace(e)}),(0,Xe.default)(Zt,33170,wV),(0,Xe.default)(Zt,2849,function(r,e){return r.lineWidth(e)}),(0,Xe.default)(Zt,32823,Xp),(0,Xe.default)(Zt,32824,"polygonOffset"),(0,Xe.default)(Zt,10752,"polygonOffset"),(0,Xe.default)(Zt,35977,Xp),(0,Xe.default)(Zt,32938,"sampleCoverage"),(0,Xe.default)(Zt,32939,"sampleCoverage"),(0,Xe.default)(Zt,3089,Xp),(0,Xe.default)(Zt,3088,function(r,e){return r.scissor.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,2960,Xp),(0,Xe.default)(Zt,2961,function(r,e){return r.clearStencil(e)}),(0,Xe.default)(Zt,2968,function(r,e){return r.stencilMaskSeparate(1028,e)}),(0,Xe.default)(Zt,36005,function(r,e){return r.stencilMaskSeparate(1029,e)}),(0,Xe.default)(Zt,2962,"stencilFuncFront"),(0,Xe.default)(Zt,2967,"stencilFuncFront"),(0,Xe.default)(Zt,2963,"stencilFuncFront"),(0,Xe.default)(Zt,34816,"stencilFuncBack"),(0,Xe.default)(Zt,36003,"stencilFuncBack"),(0,Xe.default)(Zt,36004,"stencilFuncBack"),(0,Xe.default)(Zt,2964,"stencilOpFront"),(0,Xe.default)(Zt,2965,"stencilOpFront"),(0,Xe.default)(Zt,2966,"stencilOpFront"),(0,Xe.default)(Zt,34817,"stencilOpBack"),(0,Xe.default)(Zt,34818,"stencilOpBack"),(0,Xe.default)(Zt,34819,"stencilOpBack"),(0,Xe.default)(Zt,2978,function(r,e){return r.viewport.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,3333,xl),(0,Xe.default)(Zt,3317,xl),(0,Xe.default)(Zt,37440,xl),(0,Xe.default)(Zt,37441,xl),(0,Xe.default)(Zt,37443,xl),(0,Xe.default)(Zt,3330,xl),(0,Xe.default)(Zt,3332,xl),(0,Xe.default)(Zt,3331,xl),(0,Xe.default)(Zt,36010,JTe),(0,Xe.default)(Zt,3314,xl),(0,Xe.default)(Zt,32878,xl),(0,Xe.default)(Zt,3316,xl),(0,Xe.default)(Zt,3315,xl),(0,Xe.default)(Zt,32877,xl),(0,Xe.default)(Zt,"framebuffer",function(r,e){var i=e&&"handle"in e?e.handle:e;return r.bindFramebuffer(36160,i)}),(0,Xe.default)(Zt,"blend",function(r,e){return e?r.enable(3042):r.disable(3042)}),(0,Xe.default)(Zt,"blendColor",function(r,e){return r.blendColor.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"blendEquation",function(r,e){e=M_(e)?e:[e,e],r.blendEquationSeparate.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"blendFunc",function(r,e){e=M_(e)&&e.length===2?[].concat((0,co.default)(e),(0,co.default)(e)):e,r.blendFuncSeparate.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"clearColor",function(r,e){return r.clearColor.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"clearDepth",function(r,e){return r.clearDepth(e)}),(0,Xe.default)(Zt,"clearStencil",function(r,e){return r.clearStencil(e)}),(0,Xe.default)(Zt,"colorMask",function(r,e){return r.colorMask.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"cull",function(r,e){return e?r.enable(2884):r.disable(2884)}),(0,Xe.default)(Zt,"cullFace",function(r,e){return r.cullFace(e)}),(0,Xe.default)(Zt,"depthTest",function(r,e){return e?r.enable(2929):r.disable(2929)}),(0,Xe.default)(Zt,"depthFunc",function(r,e){return r.depthFunc(e)}),(0,Xe.default)(Zt,"depthMask",function(r,e){return r.depthMask(e)}),(0,Xe.default)(Zt,"depthRange",function(r,e){return r.depthRange.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"dither",function(r,e){return e?r.enable(3024):r.disable(3024)}),(0,Xe.default)(Zt,"derivativeHint",function(r,e){r.hint(35723,e)}),(0,Xe.default)(Zt,"frontFace",function(r,e){return r.frontFace(e)}),(0,Xe.default)(Zt,"mipmapHint",function(r,e){return r.hint(33170,e)}),(0,Xe.default)(Zt,"lineWidth",function(r,e){return r.lineWidth(e)}),(0,Xe.default)(Zt,"polygonOffsetFill",function(r,e){return e?r.enable(32823):r.disable(32823)}),(0,Xe.default)(Zt,"polygonOffset",function(r,e){return r.polygonOffset.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"sampleCoverage",function(r,e){return r.sampleCoverage.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"scissorTest",function(r,e){return e?r.enable(3089):r.disable(3089)}),(0,Xe.default)(Zt,"scissor",function(r,e){return r.scissor.apply(r,(0,co.default)(e))}),(0,Xe.default)(Zt,"stencilTest",function(r,e){return e?r.enable(2960):r.disable(2960)}),(0,Xe.default)(Zt,"stencilMask",function(r,e){e=M_(e)?e:[e,e];var i=e,n=(0,H2.default)(i,2),a=n[0],o=n[1];r.stencilMaskSeparate(1028,a),r.stencilMaskSeparate(1029,o)}),(0,Xe.default)(Zt,"stencilFunc",function(r,e){e=M_(e)&&e.length===3?[].concat((0,co.default)(e),(0,co.default)(e)):e;var i=e,n=(0,H2.default)(i,6),a=n[0],o=n[1],s=n[2],u=n[3],c=n[4],h=n[5];r.stencilFuncSeparate(1028,a,o,s),r.stencilFuncSeparate(1029,u,c,h)}),(0,Xe.default)(Zt,"stencilOp",function(r,e){e=M_(e)&&e.length===3?[].concat((0,co.default)(e),(0,co.default)(e)):e;var i=e,n=(0,H2.default)(i,6),a=n[0],o=n[1],s=n[2],u=n[3],c=n[4],h=n[5];r.stencilOpSeparate(1028,a,o,s),r.stencilOpSeparate(1029,u,c,h)}),(0,Xe.default)(Zt,"viewport",function(r,e){return r.viewport.apply(r,(0,co.default)(e))}),Zt);function To(t,r,e){return r[t]!==void 0?r[t]:e[t]}var EV={blendEquation:function(r,e,i){return r.blendEquationSeparate(To(32777,e,i),To(34877,e,i))},blendFunc:function(r,e,i){return r.blendFuncSeparate(To(32969,e,i),To(32968,e,i),To(32971,e,i),To(32970,e,i))},polygonOffset:function(r,e,i){return r.polygonOffset(To(32824,e,i),To(10752,e,i))},sampleCoverage:function(r,e,i){return r.sampleCoverage(To(32938,e,i),To(32939,e,i))},stencilFuncFront:function(r,e,i){return r.stencilFuncSeparate(1028,To(2962,e,i),To(2967,e,i),To(2963,e,i))},stencilFuncBack:function(r,e,i){return r.stencilFuncSeparate(1029,To(34816,e,i),To(36003,e,i),To(36004,e,i))},stencilOpFront:function(r,e,i){return r.stencilOpSeparate(1028,To(2964,e,i),To(2965,e,i),To(2966,e,i))},stencilOpBack:function(r,e,i){return r.stencilOpSeparate(1029,To(34817,e,i),To(34818,e,i),To(34819,e,i))}},FI={enable:function(r,e){return r((0,Xe.default)({},e,!0))},disable:function(r,e){return r((0,Xe.default)({},e,!1))},pixelStorei:function(r,e,i){return r((0,Xe.default)({},e,i))},hint:function(r,e,i){return r((0,Xe.default)({},e,i))},bindFramebuffer:function(r,e,i){var n;switch(e){case 36160:return r((n={},(0,Xe.default)(n,36006,i),(0,Xe.default)(n,36010,i),n));case 36009:return r((0,Xe.default)({},36006,i));case 36008:return r((0,Xe.default)({},36010,i));default:return null}},blendColor:function(r,e,i,n,a){return r((0,Xe.default)({},32773,new Float32Array([e,i,n,a])))},blendEquation:function(r,e){var i;return r((i={},(0,Xe.default)(i,32777,e),(0,Xe.default)(i,34877,e),i))},blendEquationSeparate:function(r,e,i){var n;return r((n={},(0,Xe.default)(n,32777,e),(0,Xe.default)(n,34877,i),n))},blendFunc:function(r,e,i){var n;return r((n={},(0,Xe.default)(n,32969,e),(0,Xe.default)(n,32968,i),(0,Xe.default)(n,32971,e),(0,Xe.default)(n,32970,i),n))},blendFuncSeparate:function(r,e,i,n,a){var o;return r((o={},(0,Xe.default)(o,32969,e),(0,Xe.default)(o,32968,i),(0,Xe.default)(o,32971,n),(0,Xe.default)(o,32970,a),o))},clearColor:function(r,e,i,n,a){return r((0,Xe.default)({},3106,new Float32Array([e,i,n,a])))},clearDepth:function(r,e){return r((0,Xe.default)({},2931,e))},clearStencil:function(r,e){return r((0,Xe.default)({},2961,e))},colorMask:function(r,e,i,n,a){return r((0,Xe.default)({},3107,[e,i,n,a]))},cullFace:function(r,e){return r((0,Xe.default)({},2885,e))},depthFunc:function(r,e){return r((0,Xe.default)({},2932,e))},depthRange:function(r,e,i){return r((0,Xe.default)({},2928,new Float32Array([e,i])))},depthMask:function(r,e){return r((0,Xe.default)({},2930,e))},frontFace:function(r,e){return r((0,Xe.default)({},2886,e))},lineWidth:function(r,e){return r((0,Xe.default)({},2849,e))},polygonOffset:function(r,e,i){var n;return r((n={},(0,Xe.default)(n,32824,e),(0,Xe.default)(n,10752,i),n))},sampleCoverage:function(r,e,i){var n;return r((n={},(0,Xe.default)(n,32938,e),(0,Xe.default)(n,32939,i),n))},scissor:function(r,e,i,n,a){return r((0,Xe.default)({},3088,new Int32Array([e,i,n,a])))},stencilMask:function(r,e){var i;return r((i={},(0,Xe.default)(i,2968,e),(0,Xe.default)(i,36005,e),i))},stencilMaskSeparate:function(r,e,i){return r((0,Xe.default)({},e===1028?2968:36005,i))},stencilFunc:function(r,e,i,n){var a;return r((a={},(0,Xe.default)(a,2962,e),(0,Xe.default)(a,2967,i),(0,Xe.default)(a,2963,n),(0,Xe.default)(a,34816,e),(0,Xe.default)(a,36003,i),(0,Xe.default)(a,36004,n),a))},stencilFuncSeparate:function(r,e,i,n,a){var o;return r((o={},(0,Xe.default)(o,e===1028?2962:34816,i),(0,Xe.default)(o,e===1028?2967:36003,n),(0,Xe.default)(o,e===1028?2963:36004,a),o))},stencilOp:function(r,e,i,n){var a;return r((a={},(0,Xe.default)(a,2964,e),(0,Xe.default)(a,2965,i),(0,Xe.default)(a,2966,n),(0,Xe.default)(a,34817,e),(0,Xe.default)(a,34818,i),(0,Xe.default)(a,34819,n),a))},stencilOpSeparate:function(r,e,i,n,a){var o;return r((o={},(0,Xe.default)(o,e===1028?2964:34817,i),(0,Xe.default)(o,e===1028?2965:34818,n),(0,Xe.default)(o,e===1028?2966:34819,a),o))},viewport:function(r,e,i,n,a){return r((0,Xe.default)({},2978,[e,i,n,a]))}},Of=function(r,e){return r.isEnabled(e)},NI=(Gl={},(0,Xe.default)(Gl,3042,Of),(0,Xe.default)(Gl,2884,Of),(0,Xe.default)(Gl,2929,Of),(0,Xe.default)(Gl,3024,Of),(0,Xe.default)(Gl,32823,Of),(0,Xe.default)(Gl,32926,Of),(0,Xe.default)(Gl,32928,Of),(0,Xe.default)(Gl,3089,Of),(0,Xe.default)(Gl,2960,Of),(0,Xe.default)(Gl,35977,Of),Gl);var CV=C(Ge()),MV=C(Ye());function zI(t){for(var r in t)return!1;return!0}function SV(t,r){if(t===r)return!0;var e=Array.isArray(t)||ArrayBuffer.isView(t),i=Array.isArray(r)||ArrayBuffer.isView(r);if(e&&i&&t.length===r.length){for(var n=0;n<t.length;++n)if(t[n]!==r[n])return!1;return!0}return!1}function PV(t,r){var e=t[r].bind(t);t[r]=function(){var n=arguments.length<=0?void 0:arguments[0];return n in t.state.cache&&t.state.enable?t.state.cache[n]:e.apply(void 0,arguments)},Object.defineProperty(t[r],"name",{value:"".concat(r,"-from-cache"),configurable:!1})}function $Te(t,r,e){var i=t[r].bind(t);t[r]=function(){for(var a=arguments.length,o=new Array(a),s=0;s<a;s++)o[s]=arguments[s];var u=e.apply(void 0,[t.state._updateCache].concat(o)),c=u.valueChanged,h=u.oldValue;return c&&i.apply(void 0,o),h},Object.defineProperty(t[r],"name",{value:"".concat(r,"-to-cache"),configurable:!1})}function eEe(t){var r=t.useProgram.bind(t);t.useProgram=function(i){t.state.program!==i&&(r(i),t.state.program=i)}}var tEe=function(){function t(r){(0,CV.default)(this,t);var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=e.copyState,n=i===void 0?!1:i,a=e.log,o=a===void 0?function(){}:a;this.gl=r,this.program=null,this.stateStack=[],this.enable=!0,this.cache=n?If(r):Object.assign({},O_),this.log=o,this._updateCache=this._updateCache.bind(this),Object.seal(this)}return(0,MV.default)(t,[{key:"push",value:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.stateStack.push({})}},{key:"pop",value:function(){Bo(this.stateStack.length>0);var e=this.stateStack[this.stateStack.length-1];Do(this.gl,e),this.stateStack.pop()}},{key:"_updateCache",value:function(e){var i=!1,n,a=this.stateStack.length>0&&this.stateStack[this.stateStack.length-1];for(var o in e){Bo(o!==void 0);var s=e[o],u=this.cache[o];SV(s,u)||(i=!0,n=u,a&&!(o in a)&&(a[o]=u),this.cache[o]=s)}return{valueChanged:i,oldValue:n}}}]),t}();function W2(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},e=r.enable,i=e===void 0?!0:e,n=r.copyState;if(Bo(n!==void 0),!t.state){var a=globalThis.polyfillContext;a&&a(t),t.state=new tEe(t,{copyState:n}),eEe(t);for(var o in FI){var s=FI[o];$Te(t,o,s)}PV(t,"getParameter"),PV(t,"isEnabled")}return t.state.enable=i,t}function UI(t){t.state||W2(t,{copyState:!1}),t.state.push()}function q2(t){Bo(t.state),t.state.pop()}function rEe(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=nEe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
538
538
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){e=e.call(t)},n:function(){var c=e.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&e.return!=null&&e.return()}finally{if(o)throw s}}}}function nEe(t,r){if(t){if(typeof t=="string")return OV(t,r);var e=Object.prototype.toString.call(t).slice(8,-1);if(e==="Object"&&t.constructor&&(e=t.constructor.name),e==="Map"||e==="Set")return Array.from(t);if(e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return OV(t,r)}}function OV(t,r){(r==null||r>t.length)&&(r=t.length);for(var e=0,i=new Array(r);e<r;e++)i[e]=t[e];return i}function Do(t,r){if(Bo(Mh(t),"setParameters requires a WebGL context"),!zI(r)){var e={};for(var i in r){var n=Number(i),a=TV[i];a&&(typeof a=="string"?e[a]=!0:a(t,r[i],n))}var o=t.state&&t.state.cache;if(o)for(var s in e){var u=EV[s];u(t,r,o)}}}function If(t,r){if(r=r||O_,typeof r=="number"){var e=r,i=NI[e];return i?i(t,e):t.getParameter(e)}var n=Array.isArray(r)?r:Object.keys(r),a={},o=rEe(n),s;try{for(o.s();!(s=o.n()).done;){var u=s.value,c=NI[u];a[u]=c?c(t,Number(u)):t.getParameter(Number(u))}}catch(h){o.e(h)}finally{o.f()}return a}function X2(t){Do(t,O_)}function mi(t,r,e){if(zI(r))return e(t);var i=r.nocatch,n=i===void 0?!0:i;UI(t),Do(t,r);var a;if(n)a=e(t),q2(t);else try{a=e(t)}finally{q2(t)}return a}function Eu(t){var r=t.luma;if(t.canvas&&r){var e=r.canvasSizeInfo.clientWidth;return e?t.drawingBufferWidth/e:1}return 1}function VA(t,r){var e=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,i=Eu(t),n=t.drawingBufferWidth,a=t.drawingBufferHeight;return iEe(r,i,n,a,e)}function LV(t){var r=typeof window>"u"?1:window.devicePixelRatio||1;return Number.isFinite(t)?t<=0?1:t:t?r:1}function iEe(t,r,e,i,n){var a=IV(t[0],r,e),o=RV(t[1],r,i,n),s=IV(t[0]+1,r,e),u=s===e-1?s:s-1;s=RV(t[1]+1,r,i,n);var c;return n?(s=s===0?s:s+1,c=o,o=s):c=s===i-1?s:s-1,{x:a,y:o,width:Math.max(u-a+1,1),height:Math.max(c-o+1,1)}}function IV(t,r,e){var i=Math.min(Math.round(t*r),e-1);return i}function RV(t,r,e,i){return i?Math.max(0,e-1-Math.round(t*r)):Math.min(Math.round(t*r),e-1)}var jI=ls(),aEe=jI&&typeof document<"u",kV={webgl2:!0,webgl1:!0,throwOnError:!0,manageState:!0,canvas:null,debug:!1,width:800,height:600};function HA(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Bo(jI,`createGLContext only available in the browser.
|
|
539
539
|
Create your own headless context or use 'createHeadlessContext' from @luma.gl/test-utils`),t=Object.assign({},kV,t);var r=t,e=r.width,i=r.height;function n(c){if(t.throwOnError)throw new Error(c);return console.error(c),null}t.onError=n;var a,o=t,s=o.canvas,u=sEe({canvas:s,width:e,height:i,onError:n});return a=oEe(u,t),a?(a=Ih(a,t),uEe(a),a):null}function Ih(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!t||t._instrumented)return t;t._version=t._version||lEe(t),t.luma=t.luma||{},t.luma.canvasSizeInfo=t.luma.canvasSizeInfo||{},r=Object.assign({},kV,r);var e=r,i=e.manageState,n=e.debug;return i&&W2(t,{copyState:!1,log:function(){for(var o=arguments.length,s=new Array(o),u=0;u<o;u++)s[u]=arguments[u];return er.log.apply(er,[1].concat(s))()}}),jI&&n&&(globalThis.makeDebugContext?(t=globalThis.makeDebugContext(t,r),er.level=Math.max(er.level,1)):er.warn('WebGL debug mode not activated. import "@luma.gl/debug" to enable.')()),t._instrumented=!0,t}function BV(t){var r=t.getParameter(7936),e=t.getParameter(7937),i=t.getExtension("WEBGL_debug_renderer_info"),n=i&&t.getParameter(i.UNMASKED_VENDOR_WEBGL||7936),a=i&&t.getParameter(i.UNMASKED_RENDERER_WEBGL||7937);return{vendor:n||r,renderer:a||e,vendorMasked:r,rendererMasked:e,version:t.getParameter(7938),shadingLanguageVersion:t.getParameter(35724)}}function GI(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t.canvas){var e=LV(r.useDevicePixels);cEe(t,e,r);return}var i=t.getExtension("STACKGL_resize_drawingbuffer");i&&"width"in r&&"height"in r&&i.resize(r.width,r.height)}function oEe(t,r){var e=r.onError,i=null,n=function(v){return i=v.statusMessage||i};t.addEventListener("webglcontextcreationerror",n,!1);var a=r.webgl1,o=a===void 0?!0:a,s=r.webgl2,u=s===void 0?!0:s,c=null;return u&&(c=c||t.getContext("webgl2",r),c=c||t.getContext("experimental-webgl2",r)),o&&(c=c||t.getContext("webgl",r),c=c||t.getContext("experimental-webgl",r)),t.removeEventListener("webglcontextcreationerror",n,!1),c?(r.onContextLost&&t.addEventListener("webglcontextlost",r.onContextLost,!1),r.onContextRestored&&t.addEventListener("webglcontextrestored",r.onContextRestored,!1),c):e("Failed to create ".concat(u&&!o?"WebGL2":"WebGL"," context: ").concat(i||"Unknown error"))}function sEe(t){var r=t.canvas,e=t.width,i=e===void 0?800:e,n=t.height,a=n===void 0?600:n,o=t.onError,s;if(typeof r=="string"){var u=aEe&&document.readyState==="complete";u||o("createGLContext called on canvas '".concat(r,"' before page was loaded")),s=document.getElementById(r)}else r?s=r:(s=document.createElement("canvas"),s.id="lumagl-canvas",s.style.width=Number.isFinite(i)?"".concat(i,"px"):"100%",s.style.height=Number.isFinite(a)?"".concat(a,"px"):"100%",document.body.insertBefore(s,document.body.firstChild));return s}function uEe(t){var r=kr(t)?"WebGL2":"WebGL1",e=BV(t),i=e?"(".concat(e.vendor,",").concat(e.renderer,")"):"",n=t.debug?" debug":"";er.info(1,"".concat(r).concat(n," context ").concat(i))()}function lEe(t){return typeof WebGL2RenderingContext<"u"&&t instanceof WebGL2RenderingContext?2:1}function cEe(t,r,e){var i="width"in e?e.width:t.canvas.clientWidth,n="height"in e?e.height:t.canvas.clientHeight;(!i||!n)&&(er.log(1,"Canvas clientWidth/clientHeight is 0")(),r=1,i=t.canvas.width||1,n=t.canvas.height||1),t.luma=t.luma||{},t.luma.canvasSizeInfo=t.luma.canvasSizeInfo||{};var a=t.luma.canvasSizeInfo;if(a.clientWidth!==i||a.clientHeight!==n||a.devicePixelRatio!==r){var o=r,s=Math.floor(i*o),u=Math.floor(n*o);t.canvas.width=s,t.canvas.height=u,(t.drawingBufferWidth!==s||t.drawingBufferHeight!==u)&&(er.warn("Device pixel ratio clamped")(),o=Math.min(t.drawingBufferWidth/i,t.drawingBufferHeight/n),t.canvas.width=Math.floor(i*o),t.canvas.height=Math.floor(n*o)),Object.assign(t.luma.canvasSizeInfo,{clientWidth:i,clientHeight:n,devicePixelRatio:r})}}var DV=C(Ge()),FV=C(Ye());var I_="8.5.16",fEe="set luma.log.level=1 (or higher) to trace rendering",VI=function(){function t(){(0,DV.default)(this,t),this.stats=new Map}return(0,FV.default)(t,[{key:"get",value:function(e){return this.stats.has(e)||this.stats.set(e,new Pc({id:e})),this.stats.get(e)}}]),t}(),Vl=new VI;if(globalThis.luma&&globalThis.luma.VERSION!==I_)throw new Error("luma.gl - multiple VERSIONs detected: ".concat(globalThis.luma.VERSION," vs ").concat(I_));globalThis.luma||(ls()&&er.log(1,"luma.gl ".concat(I_," - ").concat(fEe))(),globalThis.luma=globalThis.luma||{VERSION:I_,version:I_,log:er,stats:Vl,globals:{modules:{},nodeIO:{}}});var yet=globalThis.luma;function HI(t){return typeof window<"u"&&window.requestAnimationFrame?window.requestAnimationFrame(t):setTimeout(t,1e3/60)}function WI(t){return typeof window<"u"&&window.cancelAnimationFrame?window.cancelAnimationFrame(t):clearTimeout(t)}var J9=C(Ke());var l9=C(Ge()),c9=C(Ye()),f9=C($r()),h9=C(It()),p9=C(Rt()),KI=C(Mt());var n9=C(Kr()),i9=C(Ge()),a9=C(Ye()),o9=C(It()),s9=C(Rt()),YI=C(Mt());var zV=C(Ge()),UV=C(Ye());function kt(t,r){if(!t)throw new Error(r||"luma.gl: assertion failed.")}function Z2(t,r){if(typeof r!="string")return r;var e=Number(r);if(!isNaN(e))return e;r=r.replace(/^.*\./,"");var i=t[r];return kt(i!==void 0,"Accessing undefined constant GL.".concat(r)),i}function Hl(t,r){r=Number(r);for(var e in t)if(t[e]===r)return"GL.".concat(e);return String(r)}var qI={};function bi(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"id";qI[t]=qI[t]||1;var r=qI[t]++;return"".concat(t,"-").concat(r)}function XI(t){return kt(typeof t=="number","Input must be a number"),t&&(t&t-1)===0}function Rf(t){var r=!0;for(var e in t){r=!1;break}return r}function Y2(t,r,e,i){var n="See luma.gl ".concat(e," Upgrade Guide at https://luma.gl/docs/upgrade-guide"),a=Object.getPrototypeOf(t);i.forEach(function(o){a.methodName||(a[o]=function(){throw er.removed("Calling removed method ".concat(r,".").concat(o,": "),n)(),new Error(o)})})}function hEe(t,r){var e=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!e){if(Array.isArray(t)||(e=pEe(t))||r&&t&&typeof t.length=="number"){e&&(t=e);var i=0,n=function(){};return{s:n,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(c){throw c},f:n}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|