@arcgis/core 4.24.0 → 4.24.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/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{aa14e999e03ccb770455.js → dd51b8f77fd9472c2e54.js} +1 -1
- package/assets/esri/core/workers/chunks/{6a02a75e935af0fc2b2b.js → de5c5c216a804becdaf6.js} +1 -1
- package/assets/esri/core/workers/chunks/{e5c8584ae764892c324d.js → ed1bb19480397d388fe9.js} +1 -1
- package/assets/esri/themes/base/widgets/_SnappingControls.scss +4 -0
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_ar.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_bg.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_bs.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_ca.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_cs.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_da.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_de.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_el.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_es.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_et.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_fi.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_fr.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_he.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_hr.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_hu.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_id.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_it.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_ja.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_ko.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_lt.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_lv.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_nb.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_nl.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_pl.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_pt-BR.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_pt-PT.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_ro.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_ru.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_sk.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_sl.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_sr.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_sv.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_th.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_tr.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_uk.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_vi.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_zh-CN.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_zh-HK.json +1 -1
- package/assets/esri/widgets/BasemapToggle/t9n/BasemapToggle_zh-TW.json +1 -1
- package/config.js +1 -1
- package/package.json +1 -1
- package/support/revision.js +1 -1
- package/views/2d/engine/webgl/WorldExtentClipRenderer.js +1 -1
- package/views/3d/terrain/TileCompositor.js +1 -1
- package/views/webgl/context-util.js +1 -1
- package/widgets/Editor/UpdateWorkflow.js +1 -1
- package/widgets/FeatureForm/FeatureFormViewModel.js +1 -1
- package/widgets/FeatureForm/InputField.js +1 -1
- package/widgets/support/SnappingControls/SnappingControlsViewModel.js +1 -1
- package/widgets/support/SnappingControls/SnappingLayerListViewModel.js +1 -1
- package/widgets/support/SnappingControls/SnappingListItem.js +1 -1
|
@@ -976,4 +976,4 @@ const vec4 RGBA_2_FLOAT_FACTORS = vec4(
|
|
|
976
976
|
);
|
|
977
977
|
float rgba2float(vec4 rgba) {
|
|
978
978
|
return dot(rgba, RGBA_2_FLOAT_FACTORS);
|
|
979
|
-
}`)}},93669:(e,t,r)=>{r.d(t,{h:()=>f,S:()=>m});var i=r(52138),n=r(10937),o=r(17896),a=r(65617),s=r(70582),l=r(172),c=r(79884),u=r(67498);class d extends c.x{constructor(e,t){super(e,"mat4",u.P.Draw,((r,i,n)=>r.setUniformMatrix4fv(e,t(i,n))))}}var h=r(8319);function f(e,t){t.instancedDoublePrecision?e.constants.add("cameraPosition","vec3",a.Z):e.uniforms.add(new s.B("cameraPosition",((e,t)=>(0,o.s)(g,t.camera.viewInverseTransposeMatrix[3]-e.origin[0],t.camera.viewInverseTransposeMatrix[7]-e.origin[1],t.camera.viewInverseTransposeMatrix[11]-e.origin[2]))))}function m(e,t){if(e.vertex.uniforms.add(new h.g("proj",((e,t)=>t.camera.projectionMatrix))),t.instancedDoublePrecision){const t=(e,t)=>(0,o.s)(g,t.camera.viewInverseTransposeMatrix[3],t.camera.viewInverseTransposeMatrix[7],t.camera.viewInverseTransposeMatrix[11]);e.vertex.uniforms.add(new h.g("view",((e,r)=>(0,i.j)(p,r.camera.viewMatrix,t(e,r)))));const r=new l.J("localOrigin",t);return e.vertex.uniforms.add(r),r}e.vertex.uniforms.add(new d("view",((e,t)=>(0,i.j)(p,t.camera.viewMatrix,e.origin))));const r=new s.B("localOrigin",(e=>e.origin));return e.vertex.uniforms.add(r),r}const p=(0,n.c)(),g=(0,a.c)()},19693:(e,t,r)=>{r.d(t,{A:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"vec2",n.P.Pass,((r,i,n)=>r.setUniform2fv(e,t(i,n))))}}},70582:(e,t,r)=>{r.d(t,{B:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"vec3",n.P.Draw,((r,i,n)=>r.setUniform3fv(e,t(i,n))))}}},172:(e,t,r)=>{r.d(t,{J:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"vec3",n.P.Pass,((r,i,n)=>r.setUniform3fv(e,t(i,n))))}}},71250:(e,t,r)=>{r.d(t,{N:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"vec4",n.P.Pass,((r,i,n)=>r.setUniform4fv(e,t(i,n))))}}},21437:(e,t,r)=>{r.d(t,{p:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"float",n.P.Pass,((r,i,n)=>r.setUniform1f(e,t(i,n))))}}},15736:(e,t,r)=>{r.d(t,{_:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"int",n.P.Pass,((r,i,n)=>r.setUniform1i(e,t(i,n))))}}},52114:(e,t,r)=>{r.d(t,{j:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"mat3",n.P.Draw,((r,i,n)=>r.setUniformMatrix3fv(e,t(i,n))))}}},19850:(e,t,r)=>{r.d(t,{c:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"mat3",n.P.Pass,((r,i,n)=>r.setUniformMatrix3fv(e,t(i,n))))}}},8319:(e,t,r)=>{r.d(t,{g:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"mat4",n.P.Pass,((r,i,n)=>r.setUniformMatrix4fv(e,t(i,n))))}}},85594:(e,t,r)=>{r.d(t,{B:()=>n});var i=r(79884);class n extends i.x{constructor(e){super(e,"mat4")}}},33680:(e,t,r)=>{r.d(t,{kG:()=>l});var i=r(20102),n=r(92604),o=r(70586);const a=n.Z.getLogger("esri.views.3d.webgl-engine.core.shaderModules.shaderBuilder");class s{constructor(){this.includedModules=new Map}include(e,t){if(this.includedModules.has(e)){const r=this.includedModules.get(e);if(r!==t){a.error("Trying to include shader module multiple times with different sets of options.");const t=new Set;for(const i of Object.keys(r))r[i]!==e[i]&&t.add(i);for(const i of Object.keys(e))r[i]!==e[i]&&t.add(i);t.forEach((t=>console.error(` ${t}: current ${r[t]} new ${e[t]}`)))}}else this.includedModules.set(e,t),e(this.builder,t)}}class l extends s{constructor(){super(...arguments),this.vertex=new d,this.fragment=new d,this.attributes=new h,this.varyings=new f,this.extensions=new m,this.constants=new p}get fragmentUniforms(){return this.fragment.uniforms.entries}get builder(){return this}generate(e){const t=this.extensions.generateSource(e),r=this.attributes.generateSource(e),i=this.varyings.generateSource(),n="vertex"===e?this.vertex:this.fragment,o=n.uniforms.generateSource(),a=n.code.generateSource(),s="vertex"===e?_:g,l=this.constants.generateSource().concat(n.constants.generateSource());return`\n${t.join("\n")}\n\n${s}\n\n${l.join("\n")}\n\n${o.join("\n")}\n\n${r.join("\n")}\n\n${i.join("\n")}\n\n${a.join("\n")}`}generateBind(e,t){const r=new Map;this.vertex.uniforms.entries.forEach((t=>{const i=t.bind[e];(0,o.pC)(i)&&r.set(t.name,i)})),this.fragment.uniforms.entries.forEach((t=>{const i=t.bind[e];(0,o.pC)(i)&&r.set(t.name,i)}));const i=Array.from(r.values()),n=i.length;return(e,r)=>{for(let o=0;o<n;++o)i[o](t,e,r)}}}class c{constructor(){this._entries=new Map}add(e){if(!Array.isArray(e))return this._add(e);for(const t of e)this._add(t)}_add(e){if(this._entries.has(e.name)&&!this._entries.get(e.name).equals(e))throw new i.Z(`Duplicate uniform name ${e.name} for different uniform type`);this._entries.set(e.name,e)}generateSource(){return Array.from(this._entries.values()).map((e=>(0,o.pC)(e.arraySize)?`uniform ${e.type} ${e.name}[${e.arraySize}];`:`uniform ${e.type} ${e.name};`))}get entries(){return Array.from(this._entries.values())}}class u{constructor(){this._entries=new Array}add(e){this._entries.push(e)}generateSource(){return this._entries}}class d extends s{constructor(){super(...arguments),this.uniforms=new c,this.code=new u,this.constants=new p}get builder(){return this}}class h{constructor(){this._entries=new Array}add(e,t){this._entries.push([e,t])}generateSource(e){return"fragment"===e?[]:this._entries.map((e=>`attribute ${e[1]} ${e[0]};`))}}class f{constructor(){this._entries=new Array}add(e,t){this._entries.push([e,t])}generateSource(){return this._entries.map((e=>`varying ${e[1]} ${e[0]};`))}}class m{constructor(){this._entries=new Set}add(e){this._entries.add(e)}generateSource(e){const t="vertex"===e?m.ALLOWLIST_VERTEX:m.ALLOWLIST_FRAGMENT;return Array.from(this._entries).filter((e=>t.includes(e))).map((e=>`#extension ${e} : enable`))}}m.ALLOWLIST_FRAGMENT=["GL_EXT_shader_texture_lod","GL_OES_standard_derivatives"],m.ALLOWLIST_VERTEX=[];class p{constructor(){this._entries=new Set}add(e,t,r){let i="ERROR_CONSTRUCTOR_STRING";switch(t){case"float":i=p._numberToFloatStr(r);break;case"int":i=p._numberToIntStr(r);break;case"bool":i=r.toString();break;case"vec2":i=`vec2(${p._numberToFloatStr(r[0])}, ${p._numberToFloatStr(r[1])})`;break;case"vec3":i=`vec3(${p._numberToFloatStr(r[0])}, ${p._numberToFloatStr(r[1])}, ${p._numberToFloatStr(r[2])})`;break;case"vec4":i=`vec4(${p._numberToFloatStr(r[0])}, ${p._numberToFloatStr(r[1])}, ${p._numberToFloatStr(r[2])}, ${p._numberToFloatStr(r[3])})`;break;case"ivec2":i=`ivec2(${p._numberToIntStr(r[0])}, ${p._numberToIntStr(r[1])})`;break;case"ivec3":i=`ivec3(${p._numberToIntStr(r[0])}, ${p._numberToIntStr(r[1])}, ${p._numberToIntStr(r[2])})`;break;case"ivec4":i=`ivec4(${p._numberToIntStr(r[0])}, ${p._numberToIntStr(r[1])}, ${p._numberToIntStr(r[2])}, ${p._numberToIntStr(r[3])})`;break;case"mat2":case"mat3":case"mat4":i=`${t}(${Array.prototype.map.call(r,(e=>p._numberToFloatStr(e))).join(", ")})`}return this._entries.add(`const ${t} ${e} = ${i};`),this}static _numberToIntStr(e){return e.toFixed(0)}static _numberToFloatStr(e){return Number.isInteger(e)?e.toFixed(1):e.toString()}generateSource(){return Array.from(this._entries)}}const g="#ifdef GL_FRAGMENT_PRECISION_HIGH\n precision highp float;\n precision highp sampler2D;\n#else\n precision mediump float;\n precision mediump sampler2D;\n#endif",_="precision highp float;\nprecision highp sampler2D;"},46826:(e,t,r)=>{r.d(t,{F:()=>u});var i=r(70586),n=r(4307),o=r(97323),a=r(79884),s=r(67498);class l extends a.x{constructor(e,t){super(e,"vec2",s.P.Draw,((r,i,n)=>r.setUniform2fv(e,t(i,n))))}}class c extends a.x{constructor(e,t){super(e,"sampler2D",s.P.Draw,((r,i,n)=>r.bindTexture(e,t(i,n))))}}function u(e,t,r){const a=[new c(e,t)];if(r){const r=e+"Size";a.push(new l(r,((e,r)=>{const a=t(e,r);return(0,i.pC)(a)?(0,n.a)(d,a.descriptor.width,a.descriptor.height):o.Z})))}return a}const d=(0,o.a)()},98069:(e,t,r)=>{r.d(t,{A:()=>c,J:()=>u});var i=r(70586),n=r(4307),o=r(97323),a=r(19693),s=r(79884),l=r(67498);class c extends s.x{constructor(e,t){super(e,"sampler2D",l.P.Pass,((r,i,n)=>r.bindTexture(e,t(i,n))))}}function u(e,t,r){const s=[new c(e,t)];if(r){const r=e+"Size";s.push(new a.A(r,((e,r)=>{const a=t(e,r);return(0,i.pC)(a)?(0,n.a)(d,a.descriptor.width,a.descriptor.height):o.Z})))}return s}const d=(0,o.a)()},79884:(e,t,r)=>{r.d(t,{x:()=>o});var i=r(70586),n=r(67498);class o{constructor(e,t,r,o,a=null){this.name=e,this.type=t,this.arraySize=a,this.bind={[n.P.Pass]:null,[n.P.Draw]:null},(0,i.pC)(r)&&(0,i.pC)(o)&&(this.bind[r]=o)}equals(e){return this.type===e.type&&this.name===e.name&&this.arraySize===e.arraySize}}},74709:(e,t,r)=>{r.d(t,{H:()=>n,K:()=>i});class i{}function n(e,...t){let r="";for(let i=0;i<t.length;i++)r+=e[i]+t[i];return r+=e[e.length-1],r}!function(e){e.int=function(e){return Math.round(e).toString()},e.float=function(e){return e.toPrecision(8)}}(n||(n={}))},67498:(e,t,r)=>{var i;r.d(t,{P:()=>i}),function(e){e[e.Pass=0]="Pass",e[e.Draw=1]="Draw"}(i||(i={}))},17662:(e,t,r)=>{r.d(t,{c:()=>n});var i=r(99001);class n{constructor(){this.id=(0,i.D)()}unload(){}}},4726:(e,t,r)=>{var i;r.d(t,{U:()=>i}),function(e){e[e.Layer=0]="Layer",e[e.Object=1]="Object",e[e.Geometry=2]="Geometry",e[e.Material=3]="Material",e[e.Texture=4]="Texture",e[e.COUNT=5]="COUNT"}(i||(i={}))},83475:(e,t,r)=>{r.d(t,{i:()=>n});var i=r(35065);const n=new Map([[i.T.POSITION,0],[i.T.NORMAL,1],[i.T.UV0,2],[i.T.COLOR,3],[i.T.SIZE,4],[i.T.TANGENT,4],[i.T.AUXPOS1,5],[i.T.SYMBOLCOLOR,5],[i.T.AUXPOS2,6],[i.T.FEATUREATTRIBUTE,6],[i.T.INSTANCEFEATUREATTRIBUTE,6],[i.T.INSTANCECOLOR,7],[i.T.MODEL,8],[i.T.MODELNORMAL,12],[i.T.MODELORIGINHI,11],[i.T.MODELORIGINLO,15]])},60537:(e,t,r)=>{r.d(t,{F:()=>s});var i=r(70586),n=r(95330),o=r(74709),a=r(47026);class s extends class{constructor(e){this._material=e.material,this._techniqueRepository=e.techniqueRep,this._output=e.output}dispose(){this._techniqueRepository.release(this._technique)}get technique(){return this._technique}ensureTechnique(e,t,r=this._output){return this._technique=this._techniqueRepository.releaseAndAcquire(e,this._material.getConfiguration(r,t),this._technique),this._technique}ensureResources(e){return a.Rw.LOADED}}{constructor(e){super(e),this._numLoading=0,this._disposed=!1,this._textureRepository=e.textureRep,this._textureId=e.textureId,this._acquire(e.textureId,(e=>this._texture=e)),this._acquire(e.normalTextureId,(e=>this._textureNormal=e)),this._acquire(e.emissiveTextureId,(e=>this._textureEmissive=e)),this._acquire(e.occlusionTextureId,(e=>this._textureOcclusion=e)),this._acquire(e.metallicRoughnessTextureId,(e=>this._textureMetallicRoughness=e))}dispose(){this._texture=(0,i.RY)(this._texture),this._textureNormal=(0,i.RY)(this._textureNormal),this._textureEmissive=(0,i.RY)(this._textureEmissive),this._textureOcclusion=(0,i.RY)(this._textureOcclusion),this._textureMetallicRoughness=(0,i.RY)(this._textureMetallicRoughness),this._disposed=!0}ensureResources(e){return 0===this._numLoading?a.Rw.LOADED:a.Rw.LOADING}get textureBindParameters(){return new l((0,i.pC)(this._texture)?this._texture.glTexture:null,(0,i.pC)(this._textureNormal)?this._textureNormal.glTexture:null,(0,i.pC)(this._textureEmissive)?this._textureEmissive.glTexture:null,(0,i.pC)(this._textureOcclusion)?this._textureOcclusion.glTexture:null,(0,i.pC)(this._textureMetallicRoughness)?this._textureMetallicRoughness.glTexture:null)}updateTexture(e){((0,i.Wi)(this._texture)||e!==this._texture.id)&&(this._texture=(0,i.RY)(this._texture),this._textureId=e,this._acquire(this._textureId,(e=>this._texture=e)))}_acquire(e,t){if((0,i.Wi)(e))return void t(null);const r=this._textureRepository.acquire(e);if((0,n.y8)(r))return++this._numLoading,void r.then((e=>{if(this._disposed)return(0,i.RY)(e),void t(null);t(e)})).finally((()=>--this._numLoading));t(r)}}class l extends o.K{constructor(e=null,t=null,r=null,i=null,n=null){super(),this.texture=e,this.textureNormal=t,this.textureEmissive=r,this.textureOcclusion=i,this.textureMetallicRoughness=n}}},82791:(e,t,r)=>{r.d(t,{F5:()=>u,yD:()=>i});var i,n,o=r(70586),a=(r(74709),r(17662)),s=r(4726),l=r(83475),c=r(37782);class u extends a.c{constructor(e,t){super(),this.type=s.U.Material,this.supportsEdges=!1,this._visible=!0,this._renderPriority=0,this._insertOrder=0,this._vertexAttributeLocations=l.i,this._parameters=(0,c.Uf)(e,t),this.validateParameters(this._parameters)}dispose(){}get parameters(){return this._parameters}update(e){return!1}setParameters(e,t=!0){(0,c.LO)(this._parameters,e)&&(this.validateParameters(this._parameters),t&&this.parametersChanged())}validateParameters(e){}get visible(){return this._visible}set visible(e){e!==this._visible&&(this._visible=e,this.parametersChanged())}shouldRender(e){return this.isVisible()&&this.isVisibleInPass(e.pass)&&0!=(this.renderOccluded&e.renderOccludedMask)}isVisibleInPass(e){return!0}get renderOccluded(){return this.parameters.renderOccluded}get renderPriority(){return this._renderPriority}set renderPriority(e){e!==this._renderPriority&&(this._renderPriority=e,this.parametersChanged())}get insertOrder(){return this._insertOrder}set insertOrder(e){e!==this._insertOrder&&(this._insertOrder=e,this.parametersChanged())}get vertexAttributeLocations(){return this._vertexAttributeLocations}isVisible(){return this._visible}parametersChanged(){(0,o.pC)(this.repository)&&this.repository.materialChanged(this)}}(n=i||(i={}))[n.Occlude=1]="Occlude",n[n.Transparent=2]="Transparent",n[n.OccludeAndTransparent=4]="OccludeAndTransparent",n[n.OccludeAndTransparentStencil=8]="OccludeAndTransparentStencil",n[n.Opaque=16]="Opaque"},11726:(e,t,r)=>{r.d(t,{hu:()=>n,yK:()=>o}),r(97323),r(98766),(0,r(88669).c)();class i{constructor(e){this.message=e}toString(){return`AssertException: ${this.message}`}}function n(e,t){if(!e)throw t=t||"assert",console.log(new Error(t).stack),new i(t)}function o(e,t,r,i){let n,o=(r[0]-e[0])/t[0],a=(i[0]-e[0])/t[0];o>a&&(n=o,o=a,a=n);let s=(r[1]-e[1])/t[1],l=(i[1]-e[1])/t[1];if(s>l&&(n=s,s=l,l=n),o>l||s>a)return!1;s>o&&(o=s),l<a&&(a=l);let c=(r[2]-e[2])/t[2],u=(i[2]-e[2])/t[2];return c>u&&(n=c,c=u,u=n),!(o>u||c>a||(u<a&&(a=u),a<0))}},35065:(e,t,r)=>{var i;r.d(t,{T:()=>i}),function(e){e.POSITION="position",e.NORMAL="normal",e.UV0="uv0",e.AUXPOS1="auxpos1",e.AUXPOS2="auxpos2",e.MAPPOS="mapPos",e.COLOR="color",e.SYMBOLCOLOR="symbolColor",e.SIZE="size",e.TANGENT="tangent",e.OFFSET="offset",e.SUBDIVISIONFACTOR="subdivisionFactor",e.COLORFEATUREATTRIBUTE="colorFeatureAttribute",e.SIZEFEATUREATTRIBUTE="sizeFeatureAttribute",e.OPACITYFEATUREATTRIBUTE="opacityFeatureAttribute",e.DISTANCETOSTART="distanceToStart",e.UVMAPSPACE="uvMapSpace",e.BOUNDINGRECT="boundingRect",e.UVREGION="uvRegion",e.NORMALCOMPRESSED="normalCompressed",e.PROFILERIGHT="profileRight",e.PROFILEUP="profileUp",e.PROFILEVERTEXANDNORMAL="profileVertexAndNormal",e.FEATUREVALUE="featureValue",e.MODELORIGINHI="modelOriginHi",e.MODELORIGINLO="modelOriginLo",e.MODEL="model",e.MODELNORMAL="modelNormal",e.INSTANCECOLOR="instanceColor",e.INSTANCEFEATUREATTRIBUTE="instanceFeatureAttribute",e.LOCALTRANSFORM="localTransform",e.GLOBALTRANSFORM="globalTransform",e.BOUNDINGSPHERE="boundingSphere",e.MODELORIGIN="modelOrigin",e.MODELSCALEFACTORS="modelScaleFactors",e.FEATUREATTRIBUTE="featureAttribute",e.STATE="state",e.LODLEVEL="lodLevel",e.POSITION0="position0",e.POSITION1="position1",e.NORMALA="normalA",e.NORMALB="normalB",e.COMPONENTINDEX="componentIndex",e.VARIANTOFFSET="variantOffset",e.VARIANTSTROKE="variantStroke",e.VARIANTEXTENSION="variantExtension",e.U8PADDING="u8padding",e.U16PADDING="u16padding",e.SIDENESS="sideness",e.START="start",e.END="end",e.UP="up",e.EXTRUDE="extrude"}(i||(i={}))},47026:(e,t,r)=>{var i,n,o,a,s,l,c,u,d,h,f,m,p,g;r.d(t,{Am:()=>a,CE:()=>f,Gv:()=>n,JJ:()=>p,MX:()=>h,Rw:()=>l,Vr:()=>i,hU:()=>c}),function(e){e[e.None=0]="None",e[e.Front=1]="Front",e[e.Back=2]="Back",e[e.COUNT=3]="COUNT"}(i||(i={})),function(e){e[e.Less=0]="Less",e[e.Lequal=1]="Lequal",e[e.COUNT=2]="COUNT"}(n||(n={})),function(e){e[e.NONE=0]="NONE",e[e.SMAA=1]="SMAA"}(o||(o={})),function(e){e[e.Color=0]="Color",e[e.Alpha=1]="Alpha",e[e.FrontFace=2]="FrontFace",e[e.NONE=3]="NONE",e[e.COUNT=4]="COUNT"}(a||(a={})),function(e){e[e.BACKGROUND=0]="BACKGROUND",e[e.UPDATE=1]="UPDATE"}(s||(s={})),function(e){e[e.NOT_LOADED=0]="NOT_LOADED",e[e.LOADING=1]="LOADING",e[e.LOADED=2]="LOADED"}(l||(l={})),function(e){e[e.IntegratedMeshMaskExcluded=1]="IntegratedMeshMaskExcluded",e[e.OutlineVisualElementMask=2]="OutlineVisualElementMask"}(c||(c={})),function(e){e[e.ASYNC=0]="ASYNC",e[e.SYNC=1]="SYNC"}(u||(u={})),function(e){e[e.Highlight=0]="Highlight",e[e.MaskOccludee=1]="MaskOccludee",e[e.COUNT=2]="COUNT"}(d||(d={})),function(e){e[e.Triangle=0]="Triangle",e[e.Point=1]="Point",e[e.Line=2]="Line"}(h||(h={})),function(e){e[e.STRETCH=1]="STRETCH",e[e.PAD=2]="PAD"}(f||(f={})),function(e){e[e.CHANGED=0]="CHANGED",e[e.UNCHANGED=1]="UNCHANGED"}(m||(m={})),function(e){e[e.Blend=0]="Blend",e[e.Opaque=1]="Opaque",e[e.Mask=2]="Mask",e[e.MaskBlend=3]="MaskBlend",e[e.COUNT=4]="COUNT"}(p||(p={})),function(e){e[e.OFF=0]="OFF",e[e.ON=1]="ON"}(g||(g={}))},9749:(e,t,r)=>{r.d(t,{V:()=>n}),r(17896);var i=r(65617);r(22021),(0,i.c)();const n=.4;(0,i.c)()},37782:(e,t,r)=>{r.d(t,{FZ:()=>w,Uf:()=>M,Bw:()=>g,LO:()=>R,Hx:()=>S});var i=r(67676),n=r(22021),o=r(70586),a=r(17896),s=r(65617),l=r(60437),c=r(47026);function u(e,t){return Math.max((0,n.t7)(e*t.scale,e,t.factor),function(e,t){return 0===e?t.minPixelSize:t.minPixelSize*(1+2*t.paddingPixels/e)}(e,t))}r(64822),(0,n.Vl)(10),(0,n.Vl)(12),(0,n.Vl)(70),(0,n.Vl)(40);const d={scale:0,factor:0,minPixelSize:0,paddingPixels:0};var h=r(11726),f=r(35065),m=(r(52138),r(13598));r(9820),new Float64Array(3),new Float32Array(6),(0,m.c)();const p=(0,l.Ue)();function g(e,t,r,i,n,a,s){if(!function(e){return!!(0,o.pC)(e)&&!e.visible}(t))if(e.boundingInfo){(0,h.hu)(e.primitiveType===c.MX.Triangle);const t=r.tolerance;v(e.boundingInfo,i,n,t,a,s)}else{const t=e.indices.get(f.T.POSITION),r=e.vertexAttributes.get(f.T.POSITION);x(i,n,0,t.length/3,t,r,void 0,a,s)}}const _=(0,s.c)();function v(e,t,r,i,n,s){if((0,o.Wi)(e))return;const c=function(e,t,r){return(0,a.s)(r,1/(t[0]-e[0]),1/(t[1]-e[1]),1/(t[2]-e[2]))}(t,r,_);if((0,l.op)(p,e.getBBMin()),(0,l.Tn)(p,e.getBBMax()),(0,o.pC)(n)&&n.applyToAabb(p),function(e,t,r,i){return function(e,t,r,i,n){const o=(e[0]-i-t[0])*r[0],a=(e[3]+i-t[0])*r[0];let s=Math.min(o,a),l=Math.max(o,a);const c=(e[1]-i-t[1])*r[1],u=(e[4]+i-t[1])*r[1];if(l=Math.min(l,Math.max(c,u)),l<0)return!1;if(s=Math.max(s,Math.min(c,u)),s>l)return!1;const d=(e[2]-i-t[2])*r[2],h=(e[5]+i-t[2])*r[2];return l=Math.min(l,Math.max(d,h)),!(l<0)&&(s=Math.max(s,Math.min(d,h)),!(s>l)&&s<1/0)}(e,t,r,i)}(p,t,c,i)){const{primitiveIndices:o,indices:a,position:l}=e,c=o?o.length:a.length/3;if(c>y){const o=e.getChildren();if(void 0!==o){for(let e=0;e<8;++e)void 0!==o[e]&&v(o[e],t,r,i,n,s);return}}x(t,r,0,c,a,l,o,n,s)}}const T=(0,s.c)();function x(e,t,r,i,n,a,s,l,c){if(s)return function(e,t,r,i,n,a,s,l,c){const u=a.data,d=a.stride||a.size,h=e[0],f=e[1],m=e[2],p=t[0]-h,g=t[1]-f,_=t[2]-m;for(let e=r;e<i;++e){const t=s[e];let r=3*t,i=d*n[r++],a=u[i++],v=u[i++],x=u[i];i=d*n[r++];let b=u[i++],A=u[i++],S=u[i];i=d*n[r];let M=u[i++],R=u[i++],C=u[i];(0,o.pC)(l)&&([a,v,x]=l.applyToVertex(a,v,x,e),[b,A,S]=l.applyToVertex(b,A,S,e),[M,R,C]=l.applyToVertex(M,R,C,e));const w=b-a,y=A-v,O=S-x,P=M-a,N=R-v,I=C-x,D=g*I-N*_,L=_*P-I*p,F=p*N-P*g,H=w*D+y*L+O*F;if(Math.abs(H)<=Number.EPSILON)continue;const B=h-a,U=f-v,z=m-x,G=B*D+U*L+z*F;if(H>0){if(G<0||G>H)continue}else if(G>0||G<H)continue;const V=U*O-y*z,W=z*w-O*B,q=B*y-w*U,k=p*V+g*W+_*q;if(H>0){if(k<0||G+k>H)continue}else if(k>0||G+k<H)continue;const $=(P*V+N*W+I*q)/H;$>=0&&c($,E(w,y,O,P,N,I,T),t,!1)}}(e,t,r,i,n,a,s,l,c);const u=a.data,d=a.stride||a.size,h=e[0],f=e[1],m=e[2],p=t[0]-h,g=t[1]-f,_=t[2]-m;for(let e=r,t=3*r;e<i;++e){let r=d*n[t++],i=u[r++],a=u[r++],s=u[r];r=d*n[t++];let v=u[r++],x=u[r++],b=u[r];r=d*n[t++];let A=u[r++],S=u[r++],M=u[r];(0,o.pC)(l)&&([i,a,s]=l.applyToVertex(i,a,s,e),[v,x,b]=l.applyToVertex(v,x,b,e),[A,S,M]=l.applyToVertex(A,S,M,e));const R=v-i,C=x-a,w=b-s,y=A-i,O=S-a,P=M-s,N=g*P-O*_,I=_*y-P*p,D=p*O-y*g,L=R*N+C*I+w*D;if(Math.abs(L)<=Number.EPSILON)continue;const F=h-i,H=f-a,B=m-s,U=F*N+H*I+B*D;if(L>0){if(U<0||U>L)continue}else if(U>0||U<L)continue;const z=H*w-C*B,G=B*R-w*F,V=F*C-R*H,W=p*z+g*G+_*V;if(L>0){if(W<0||U+W>L)continue}else if(W>0||U+W<L)continue;const q=(y*z+O*G+P*V)/L;q>=0&&c(q,E(R,C,w,y,O,P,T),e,!1)}}const b=(0,s.c)(),A=(0,s.c)();function E(e,t,r,i,n,o,s){return(0,a.s)(b,e,t,r),(0,a.s)(A,i,n,o),(0,a.f)(s,b,A),(0,a.n)(s,s),s}function S(e,t,r,i,a){let s=(r.screenLength||0)*e.pixelRatio;(0,o.pC)(a)&&(s=function(e,t,r,i){return u(e,function(e,t,r){const i=r.parameters,n=r.paddingPixelsOverride;return d.scale=Math.min(i.divisor/(t-i.offset),1),d.factor=function(e){return Math.abs(e*e*e)}(e),d.minPixelSize=i.minPixelSize,d.paddingPixels=n,d}(t,r,i))}(s,i,t,a));const l=s*Math.tan(.5*e.fovY)/(.5*e.fullHeight);return(0,n.uZ)(l*t,r.minWorldLength||0,null!=r.maxWorldLength?r.maxWorldLength:1/0)}function M(e,t){const r=t?M(t):{};for(const t in e){let i=e[t];i&&i.forEach&&(i=C(i)),null==i&&t in r||(r[t]=i)}return r}function R(e,t){let r=!1;for(const n in t){const o=t[n];void 0!==o&&(Array.isArray(o)?null===e[n]?(e[n]=o.slice(),r=!0):(0,i.Vx)(e[n],o)&&(r=!0):e[n]!==o&&(r=!0,e[n]=o))}return r}function C(e){const t=[];return e.forEach((e=>t.push(e))),t}const w={multiply:1,ignore:2,replace:3,tint:4},y=1e3},64822:(e,t,r)=>{var i;r.d(t,{JY:()=>i}),function(e){e[e.Global=1]="Global",e[e.Local=2]="Local"}(i||(i={}))},75656:(e,t,r)=>{r.d(t,{x:()=>c}),r(80442);var i=r(22021),n=r(70586),o=r(49300),a=r(54738),s=r(35371),l=r(46314);class c{constructor(e,t,r=null){if(this._context=e,this.type="texture",this._glName=null,this._descriptor=void 0,this._samplingModeDirty=!1,this._wrapModeDirty=!1,this._wasImmutablyAllocated=!1,e.instanceCounter.increment(s._g.Texture,this),this._descriptor={target:s.No.TEXTURE_2D,samplingMode:s.cw.LINEAR,wrapMode:s.e8.REPEAT,flipped:!1,hasMipmap:!1,isOpaque:!1,unpackAlignment:4,preMultiplyAlpha:!1,isImmutable:!1,...t},e.type!==a.zO.WEBGL2&&(this._descriptor.isImmutable&&(this._descriptor.isImmutable=!1),h(this._descriptor.target)))throw new Error("3D and array textures are not supported in WebGL1");this._descriptor.target===s.No.TEXTURE_CUBE_MAP?this._setDataCubeMap(r):this.setData(r)}get glName(){return this._glName}get descriptor(){return this._descriptor}get isDirty(){return this._samplingModeDirty||this._wrapModeDirty}dispose(){this._context.gl&&this._glName&&(this._context.unbindTexture(this),this._context.gl.deleteTexture(this._glName),this._glName=null,this._context.instanceCounter.decrement(s._g.Texture,this))}release(){this.dispose()}resize(e,t){const r=this._descriptor;if(r.width!==e||r.height!==t){if(this._wasImmutablyAllocated)throw new Error("Immutable textures can't be resized!");r.width=e,r.height=t,this._descriptor.target===s.No.TEXTURE_CUBE_MAP?this._setDataCubeMap(null):this.setData(null)}}_setDataCubeMap(e=null){for(let t=s.No.TEXTURE_CUBE_MAP_POSITIVE_X;t<=s.No.TEXTURE_CUBE_MAP_NEGATIVE_Z;t++)this._setData(e,t)}setData(e){this._setData(e)}_setData(e,t){if(!this._context||!this._context.gl)return;const r=this._context.gl;this._glName||(this._glName=r.createTexture()),void 0===e&&(e=null);const i=this._descriptor;t??(t=i.target);const a=h(t);null===e&&(i.width=i.width||4,i.height=i.height||4,a&&(i.depth=i.depth??1));const m=this._context.bindTexture(this,c.TEXTURE_UNIT_FOR_UPDATES);this._context.setActiveTexture(c.TEXTURE_UNIT_FOR_UPDATES),c._validateTexture(this._context,i),this._configurePixelStorage();const p=i.pixelFormat;let g=i.internalFormat?i.internalFormat:this._deriveInternalFormat(p,i.dataType);if(d(e)){let n=e.width,s=e.height;const l=1;e instanceof HTMLVideoElement&&(n=e.videoWidth,s=e.videoHeight),i.width&&i.height,a&&i.depth,i.isImmutable&&!this._wasImmutablyAllocated&&this._texStorage(t,g,i.hasMipmap,n,s,l),this._texImage(t,0,g,n,s,l,e),(0,o.zu)(r),i.hasMipmap&&this.generateMipmap(),void 0===i.width&&(i.width=n),void 0===i.height&&(i.height=s),a&&void 0===i.depth&&(i.depth=l)}else{const{width:c,height:d,depth:h}=i;if(null!=c&&null!=d||console.error("Width and height must be specified!"),a&&null==h&&console.error("Depth must be specified!"),i.isImmutable&&!this._wasImmutablyAllocated&&this._texStorage(t,g,i.hasMipmap,c,d,h),r.DEPTH24_STENCIL8&&g===r.DEPTH_STENCIL&&(g=r.DEPTH24_STENCIL8),u(e)){const n=e.levels,o=f(t,c,d,h),a=Math.min(o-1,n.length-1);(0,l.Z)(r)?r.texParameteri(i.target,r.TEXTURE_MAX_LEVEL,a):i.hasMipmap=i.hasMipmap&&o===n.length;const u=g;if(!function(e){return e in s.q_}(u))throw new Error("Attempting to use compressed data with an umcompressed format!");this._forEachMipmapLevel(((e,r,i,o)=>{const a=n[Math.min(e,n.length-1)];this._compressedTexImage(t,e,u,r,i,o,a)}),a)}else(0,n.pC)(e)?(this._texImage(t,0,g,c,d,h,e),(0,o.zu)(r),i.hasMipmap&&this.generateMipmap()):this._forEachMipmapLevel(((e,i,n,a)=>{this._texImage(t,e,g,i,n,a,null),(0,o.zu)(r)}))}c._applySamplingMode(r,this._descriptor),c._applyWrapMode(r,this._descriptor),c._applyAnisotropicFilteringParameters(this._context,this._descriptor),(0,o.zu)(r),this._context.bindTexture(m,c.TEXTURE_UNIT_FOR_UPDATES)}updateData(e,t,r,i,n,o){o||console.error("An attempt to use uninitialized data!"),this._glName||console.error("An attempt to update uninitialized texture!");const a=this._context.gl,s=this._descriptor,{pixelFormat:l,internalFormat:h,dataType:f,isImmutable:m,target:p}=s;if(m&&!this._wasImmutablyAllocated)throw new Error("Cannot update immutable texture before allocation!");const g=this._context.bindTexture(this,c.TEXTURE_UNIT_FOR_UPDATES);(t<0||r<0||i>s.width||n>s.height||t+i>s.width||r+n>s.height)&&console.error("An attempt to update out of bounds of the texture!"),this._configurePixelStorage(),d(o)?a.texSubImage2D(p,e,t,r,l,f,o):u(o)?a.compressedTexSubImage2D(p,e,t,r,i,n,h,o.levels[e]):a.texSubImage2D(p,e,t,r,i,n,l,f,o),this._context.bindTexture(g,c.TEXTURE_UNIT_FOR_UPDATES)}updateData3D(e,t,r,i,n,o,a,s){s||console.error("An attempt to use uninitialized data!"),this._glName||console.error("An attempt to update uninitialized texture!");const d=this._context.gl;if(!(0,l.Z)(d))throw new Error("3D textures are not supported in WebGL1");const f=this._descriptor,{pixelFormat:m,dataType:p,isImmutable:g,target:_,internalFormat:v}=f;if(g&&!this._wasImmutablyAllocated)throw new Error("Cannot update immutable texture before allocation!");h(_)||console.warn("Attempting to set 3D texture data on a non-3D texture");const T=this._context.bindTexture(this,c.TEXTURE_UNIT_FOR_UPDATES);if(this._context.setActiveTexture(c.TEXTURE_UNIT_FOR_UPDATES),(t<0||r<0||i<0||n>f.width||o>f.height||a>f.depth||t+n>f.width||r+o>f.height||i+a>f.depth)&&console.error("An attempt to update out of bounds of the texture!"),this._configurePixelStorage(),u(s))s=s.levels[e],d.compressedTexSubImage3D(_,e,t,r,i,n,o,a,v,s);else{const l=s;d.texSubImage3D(_,e,t,r,i,n,o,a,m,p,l)}this._context.bindTexture(T,c.TEXTURE_UNIT_FOR_UPDATES)}generateMipmap(){const e=this._descriptor;if(!e.hasMipmap){if(this._wasImmutablyAllocated)throw new Error("Cannot add mipmaps to immutable texture after allocation");e.hasMipmap=!0,this._samplingModeDirty=!0,c._validateTexture(this._context,e)}e.samplingMode===s.cw.LINEAR?(this._samplingModeDirty=!0,e.samplingMode=s.cw.LINEAR_MIPMAP_NEAREST):e.samplingMode===s.cw.NEAREST&&(this._samplingModeDirty=!0,e.samplingMode=s.cw.NEAREST_MIPMAP_NEAREST);const t=this._context.bindTexture(this,c.TEXTURE_UNIT_FOR_UPDATES);this._context.setActiveTexture(c.TEXTURE_UNIT_FOR_UPDATES),this._context.gl.generateMipmap(e.target),this._context.bindTexture(t,c.TEXTURE_UNIT_FOR_UPDATES)}setSamplingMode(e){e!==this._descriptor.samplingMode&&(this._descriptor.samplingMode=e,this._samplingModeDirty=!0)}setWrapMode(e){e!==this._descriptor.wrapMode&&(this._descriptor.wrapMode=e,c._validateTexture(this._context,this._descriptor),this._wrapModeDirty=!0)}applyChanges(){const e=this._context.gl,t=this._descriptor;this._samplingModeDirty&&(c._applySamplingMode(e,t),this._samplingModeDirty=!1),this._wrapModeDirty&&(c._applyWrapMode(e,t),this._wrapModeDirty=!1)}_deriveInternalFormat(e,t){if(this._context.type===a.zO.WEBGL1)return e;switch(t){case s.Br.FLOAT:switch(e){case s.VI.RGBA:return s.lP.RGBA32F;case s.VI.RGB:return s.lP.RGB32F;default:throw new Error("Unable to derive format")}case s.Br.UNSIGNED_BYTE:switch(e){case s.VI.RGBA:return s.lP.RGBA8;case s.VI.RGB:return s.lP.RGB8}default:return e}}_configurePixelStorage(){const e=this._context.gl,{unpackAlignment:t,flipped:r,preMultiplyAlpha:i}=this._descriptor;e.pixelStorei(e.UNPACK_ALIGNMENT,t),e.pixelStorei(e.UNPACK_FLIP_Y_WEBGL,r?1:0),e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,i?1:0)}_texStorage(e,t,r,i,n,o){const a=this._context.gl;if(!(0,l.Z)(a))throw new Error("Immutable textures are not supported in WebGL1");if(!function(e){return e in s.lP}(t))throw new Error("Immutable textures must have a sized internal format");if(!this._descriptor.isImmutable)return;const c=r?f(e,i,n,o):1;h(e)?a.texStorage3D(e,c,t,i,n,o):a.texStorage2D(e,c,t,i,n),this._wasImmutablyAllocated=!0}_texImage(e,t,r,i,o,s,l){const c=this._context.gl;let u=null;const f=this._context.type===a.zO.WEBGL2,m=h(e),{isImmutable:p,pixelFormat:g,dataType:_}=this._descriptor;if(f&&(u=c),f||!d(l))if(p){if((0,n.pC)(l)){const r=l;m?u.texSubImage3D(e,t,0,0,0,i,o,s,g,_,r):c.texSubImage2D(e,t,0,0,i,o,g,_,r)}}else{const a=(0,n.Wg)(l);m?u.texImage3D(e,t,r,i,o,s,0,g,_,a):c.texImage2D(e,t,r,i,o,0,g,_,a)}else c.texImage2D(e,0,r,g,_,l)}_compressedTexImage(e,t,r,i,o,s,l){const c=this._context.gl;let u=null;const d=h(e),f=this._descriptor.isImmutable;if(d){if(this._context.type!==a.zO.WEBGL2)throw new Error("3D textures are not supported in WebGL1");u=c}f?(0,n.pC)(l)&&(d?u.compressedTexSubImage3D(e,t,0,0,0,i,o,s,r,l):c.compressedTexSubImage2D(e,t,0,0,i,o,r,l)):d?u.compressedTexImage3D(e,t,r,i,o,s,0,l):c.compressedTexImage2D(e,t,r,i,o,0,l)}_forEachMipmapLevel(e,t=1/0){let{width:r,height:i,depth:n,hasMipmap:o,target:a}=this._descriptor;const l=a===s.No.TEXTURE_3D;for(let a=0;e(a,r,i,n),o&&(1!==r||1!==i||l&&1!==n)&&!(a>=t);++a)r=Math.max(1,r>>1),i=Math.max(1,i>>1),l&&(n=Math.max(1,n>>1))}static _validateTexture(e,t){(t.width<0||t.height<0||t.depth<0)&&console.error("Negative dimension parameters are not allowed!");const r=(0,l.Z)(e.gl),n=(0,i.wt)(t.width)&&(0,i.wt)(t.height);r||!t.isImmutable&&!h(t.target)||console.error("Immutable and 3D-like textures are not supported in WebGL1!"),r||n||("number"==typeof t.wrapMode?t.wrapMode!==s.e8.CLAMP_TO_EDGE&&console.error("Non-power-of-two textures must have a wrap mode of CLAMP_TO_EDGE!"):t.wrapMode.s===s.e8.CLAMP_TO_EDGE&&t.wrapMode.t===s.e8.CLAMP_TO_EDGE||console.error("Non-power-of-two textures must have a wrap mode of CLAMP_TO_EDGE!"),t.hasMipmap&&console.error("Mipmapping requires power-of-two textures!"))}static _applySamplingMode(e,t){let r=t.samplingMode,i=t.samplingMode;r===s.cw.LINEAR_MIPMAP_NEAREST||r===s.cw.LINEAR_MIPMAP_LINEAR?(r=s.cw.LINEAR,t.hasMipmap||(i=s.cw.LINEAR)):r!==s.cw.NEAREST_MIPMAP_NEAREST&&r!==s.cw.NEAREST_MIPMAP_LINEAR||(r=s.cw.NEAREST,t.hasMipmap||(i=s.cw.NEAREST)),e.texParameteri(t.target,e.TEXTURE_MAG_FILTER,r),e.texParameteri(t.target,e.TEXTURE_MIN_FILTER,i)}static _applyWrapMode(e,t){"number"==typeof t.wrapMode?(e.texParameteri(t.target,e.TEXTURE_WRAP_S,t.wrapMode),e.texParameteri(t.target,e.TEXTURE_WRAP_T,t.wrapMode)):(e.texParameteri(t.target,e.TEXTURE_WRAP_S,t.wrapMode.s),e.texParameteri(t.target,e.TEXTURE_WRAP_T,t.wrapMode.t))}static _applyAnisotropicFilteringParameters(e,t){const r=e.capabilities.textureFilterAnisotropic;r&&e.gl.texParameterf(t.target,r.TEXTURE_MAX_ANISOTROPY,t.maxAnisotropy??1)}}function u(e){return(0,n.pC)(e)&&"type"in e&&"compressed"===e.type}function d(e){return(0,n.pC)(e)&&!u(e)&&!function(e){return(0,n.pC)(e)&&"byteLength"in e}(e)}function h(e){return e===s.No.TEXTURE_3D||e===s.No.TEXTURE_2D_ARRAY}function f(e,t,r,i=1){let n=Math.max(t,r);return e===s.No.TEXTURE_3D&&(n=Math.max(n,i)),Math.round(Math.log(n)/Math.LN2)+1}c.TEXTURE_UNIT_FOR_UPDATES=0},21968:(e,t,r)=>{r.d(t,{G:()=>i});class i{constructor(e,t,r,i,n,o=!1,a=0){this.name=e,this.count=t,this.type=r,this.offset=i,this.stride=n,this.normalized=o,this.divisor=a}}},46314:(e,t,r)=>{function i(e){return window.WebGL2RenderingContext&&e instanceof window.WebGL2RenderingContext}r.d(t,{Z:()=>i})},49300:(e,t,r)=>{r.d(t,{CG:()=>l,hZ:()=>s,zu:()=>c});var i=r(20102),n=r(80442);const o=r(92604).Z.getLogger("esri/views/webgl"),a=!!(0,n.Z)("enable-feature:webgl-debug");function s(){return a}function l(){return a}function c(e){if(s()){const t=e.getError();if(t){const r=function(e,t){switch(t){case e.INVALID_ENUM:return"Invalid Enum. An unacceptable value has been specified for an enumerated argument.";case e.INVALID_VALUE:return"Invalid Value. A numeric argument is out of range.";case e.INVALID_OPERATION:return"Invalid Operation. The specified command is not allowed for the current state.";case e.INVALID_FRAMEBUFFER_OPERATION:return"Invalid Framebuffer operation. The currently bound framebuffer is not framebuffer complete when trying to render to or to read from it.";case e.OUT_OF_MEMORY:return"Out of memory. Not enough memory is left to execute the command.";case e.CONTEXT_LOST_WEBGL:return"WebGL context has been lost";default:return"Unknown error"}}(e,t),n=(new Error).stack;o.error(new i.Z("webgl-error","WebGL error occured",{message:r,stack:n}))}}}},54738:(e,t,r)=>{r.d(t,{Sh:()=>a,kr:()=>s,zO:()=>i});var i,n,o=r(80442);function a(e){const t=(0,o.Z)("esri-force-webgl");if(t===i.WEBGL1||t===i.WEBGL2)return[t];switch(e){case"2d":case"3d":return[i.WEBGL2,i.WEBGL1]}}function s(e,t,r={}){const n=t===i.WEBGL1?["webgl","experimental-webgl","webkit-3d","moz-webgl"]:["webgl2"];let o=null;for(const t of n){try{o=e.getContext(t,r)}catch(e){}if(o)break}return o}(n=i||(i={}))[n.WEBGL1=1]="WEBGL1",n[n.WEBGL2=2]="WEBGL2"},9820:(e,t,r)=>{function i(e,t){const r=e.length;for(let i=0;i<r;++i)o[0]=e[i],t[i]=o[0];return t}function n(e,t){const r=e.length;for(let i=0;i<r;++i)o[0]=e[i],o[1]=e[i]-o[0],t[i]=o[1];return t}r.d(t,{GB:()=>n,U8:()=>i});const o=new Float32Array(2)}}]);
|
|
979
|
+
}`)}},93669:(e,t,r)=>{r.d(t,{h:()=>f,S:()=>m});var i=r(52138),n=r(10937),o=r(17896),a=r(65617),s=r(70582),l=r(172),c=r(79884),u=r(67498);class d extends c.x{constructor(e,t){super(e,"mat4",u.P.Draw,((r,i,n)=>r.setUniformMatrix4fv(e,t(i,n))))}}var h=r(8319);function f(e,t){t.instancedDoublePrecision?e.constants.add("cameraPosition","vec3",a.Z):e.uniforms.add(new s.B("cameraPosition",((e,t)=>(0,o.s)(g,t.camera.viewInverseTransposeMatrix[3]-e.origin[0],t.camera.viewInverseTransposeMatrix[7]-e.origin[1],t.camera.viewInverseTransposeMatrix[11]-e.origin[2]))))}function m(e,t){if(e.vertex.uniforms.add(new h.g("proj",((e,t)=>t.camera.projectionMatrix))),t.instancedDoublePrecision){const t=(e,t)=>(0,o.s)(g,t.camera.viewInverseTransposeMatrix[3],t.camera.viewInverseTransposeMatrix[7],t.camera.viewInverseTransposeMatrix[11]);e.vertex.uniforms.add(new h.g("view",((e,r)=>(0,i.j)(p,r.camera.viewMatrix,t(e,r)))));const r=new l.J("localOrigin",t);return e.vertex.uniforms.add(r),r}e.vertex.uniforms.add(new d("view",((e,t)=>(0,i.j)(p,t.camera.viewMatrix,e.origin))));const r=new s.B("localOrigin",(e=>e.origin));return e.vertex.uniforms.add(r),r}const p=(0,n.c)(),g=(0,a.c)()},19693:(e,t,r)=>{r.d(t,{A:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"vec2",n.P.Pass,((r,i,n)=>r.setUniform2fv(e,t(i,n))))}}},70582:(e,t,r)=>{r.d(t,{B:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"vec3",n.P.Draw,((r,i,n)=>r.setUniform3fv(e,t(i,n))))}}},172:(e,t,r)=>{r.d(t,{J:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"vec3",n.P.Pass,((r,i,n)=>r.setUniform3fv(e,t(i,n))))}}},71250:(e,t,r)=>{r.d(t,{N:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"vec4",n.P.Pass,((r,i,n)=>r.setUniform4fv(e,t(i,n))))}}},21437:(e,t,r)=>{r.d(t,{p:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"float",n.P.Pass,((r,i,n)=>r.setUniform1f(e,t(i,n))))}}},15736:(e,t,r)=>{r.d(t,{_:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"int",n.P.Pass,((r,i,n)=>r.setUniform1i(e,t(i,n))))}}},52114:(e,t,r)=>{r.d(t,{j:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"mat3",n.P.Draw,((r,i,n)=>r.setUniformMatrix3fv(e,t(i,n))))}}},19850:(e,t,r)=>{r.d(t,{c:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"mat3",n.P.Pass,((r,i,n)=>r.setUniformMatrix3fv(e,t(i,n))))}}},8319:(e,t,r)=>{r.d(t,{g:()=>o});var i=r(79884),n=r(67498);class o extends i.x{constructor(e,t){super(e,"mat4",n.P.Pass,((r,i,n)=>r.setUniformMatrix4fv(e,t(i,n))))}}},85594:(e,t,r)=>{r.d(t,{B:()=>n});var i=r(79884);class n extends i.x{constructor(e){super(e,"mat4")}}},33680:(e,t,r)=>{r.d(t,{kG:()=>l});var i=r(20102),n=r(92604),o=r(70586);const a=n.Z.getLogger("esri.views.3d.webgl-engine.core.shaderModules.shaderBuilder");class s{constructor(){this.includedModules=new Map}include(e,t){if(this.includedModules.has(e)){const r=this.includedModules.get(e);if(r!==t){a.error("Trying to include shader module multiple times with different sets of options.");const t=new Set;for(const i of Object.keys(r))r[i]!==e[i]&&t.add(i);for(const i of Object.keys(e))r[i]!==e[i]&&t.add(i);t.forEach((t=>console.error(` ${t}: current ${r[t]} new ${e[t]}`)))}}else this.includedModules.set(e,t),e(this.builder,t)}}class l extends s{constructor(){super(...arguments),this.vertex=new d,this.fragment=new d,this.attributes=new h,this.varyings=new f,this.extensions=new m,this.constants=new p}get fragmentUniforms(){return this.fragment.uniforms.entries}get builder(){return this}generate(e){const t=this.extensions.generateSource(e),r=this.attributes.generateSource(e),i=this.varyings.generateSource(),n="vertex"===e?this.vertex:this.fragment,o=n.uniforms.generateSource(),a=n.code.generateSource(),s="vertex"===e?_:g,l=this.constants.generateSource().concat(n.constants.generateSource());return`\n${t.join("\n")}\n\n${s}\n\n${l.join("\n")}\n\n${o.join("\n")}\n\n${r.join("\n")}\n\n${i.join("\n")}\n\n${a.join("\n")}`}generateBind(e,t){const r=new Map;this.vertex.uniforms.entries.forEach((t=>{const i=t.bind[e];(0,o.pC)(i)&&r.set(t.name,i)})),this.fragment.uniforms.entries.forEach((t=>{const i=t.bind[e];(0,o.pC)(i)&&r.set(t.name,i)}));const i=Array.from(r.values()),n=i.length;return(e,r)=>{for(let o=0;o<n;++o)i[o](t,e,r)}}}class c{constructor(){this._entries=new Map}add(e){if(!Array.isArray(e))return this._add(e);for(const t of e)this._add(t)}_add(e){if(this._entries.has(e.name)&&!this._entries.get(e.name).equals(e))throw new i.Z(`Duplicate uniform name ${e.name} for different uniform type`);this._entries.set(e.name,e)}generateSource(){return Array.from(this._entries.values()).map((e=>(0,o.pC)(e.arraySize)?`uniform ${e.type} ${e.name}[${e.arraySize}];`:`uniform ${e.type} ${e.name};`))}get entries(){return Array.from(this._entries.values())}}class u{constructor(){this._entries=new Array}add(e){this._entries.push(e)}generateSource(){return this._entries}}class d extends s{constructor(){super(...arguments),this.uniforms=new c,this.code=new u,this.constants=new p}get builder(){return this}}class h{constructor(){this._entries=new Array}add(e,t){this._entries.push([e,t])}generateSource(e){return"fragment"===e?[]:this._entries.map((e=>`attribute ${e[1]} ${e[0]};`))}}class f{constructor(){this._entries=new Array}add(e,t){this._entries.push([e,t])}generateSource(){return this._entries.map((e=>`varying ${e[1]} ${e[0]};`))}}class m{constructor(){this._entries=new Set}add(e){this._entries.add(e)}generateSource(e){const t="vertex"===e?m.ALLOWLIST_VERTEX:m.ALLOWLIST_FRAGMENT;return Array.from(this._entries).filter((e=>t.includes(e))).map((e=>`#extension ${e} : enable`))}}m.ALLOWLIST_FRAGMENT=["GL_EXT_shader_texture_lod","GL_OES_standard_derivatives"],m.ALLOWLIST_VERTEX=[];class p{constructor(){this._entries=new Set}add(e,t,r){let i="ERROR_CONSTRUCTOR_STRING";switch(t){case"float":i=p._numberToFloatStr(r);break;case"int":i=p._numberToIntStr(r);break;case"bool":i=r.toString();break;case"vec2":i=`vec2(${p._numberToFloatStr(r[0])}, ${p._numberToFloatStr(r[1])})`;break;case"vec3":i=`vec3(${p._numberToFloatStr(r[0])}, ${p._numberToFloatStr(r[1])}, ${p._numberToFloatStr(r[2])})`;break;case"vec4":i=`vec4(${p._numberToFloatStr(r[0])}, ${p._numberToFloatStr(r[1])}, ${p._numberToFloatStr(r[2])}, ${p._numberToFloatStr(r[3])})`;break;case"ivec2":i=`ivec2(${p._numberToIntStr(r[0])}, ${p._numberToIntStr(r[1])})`;break;case"ivec3":i=`ivec3(${p._numberToIntStr(r[0])}, ${p._numberToIntStr(r[1])}, ${p._numberToIntStr(r[2])})`;break;case"ivec4":i=`ivec4(${p._numberToIntStr(r[0])}, ${p._numberToIntStr(r[1])}, ${p._numberToIntStr(r[2])}, ${p._numberToIntStr(r[3])})`;break;case"mat2":case"mat3":case"mat4":i=`${t}(${Array.prototype.map.call(r,(e=>p._numberToFloatStr(e))).join(", ")})`}return this._entries.add(`const ${t} ${e} = ${i};`),this}static _numberToIntStr(e){return e.toFixed(0)}static _numberToFloatStr(e){return Number.isInteger(e)?e.toFixed(1):e.toString()}generateSource(){return Array.from(this._entries)}}const g="#ifdef GL_FRAGMENT_PRECISION_HIGH\n precision highp float;\n precision highp sampler2D;\n#else\n precision mediump float;\n precision mediump sampler2D;\n#endif",_="precision highp float;\nprecision highp sampler2D;"},46826:(e,t,r)=>{r.d(t,{F:()=>u});var i=r(70586),n=r(4307),o=r(97323),a=r(79884),s=r(67498);class l extends a.x{constructor(e,t){super(e,"vec2",s.P.Draw,((r,i,n)=>r.setUniform2fv(e,t(i,n))))}}class c extends a.x{constructor(e,t){super(e,"sampler2D",s.P.Draw,((r,i,n)=>r.bindTexture(e,t(i,n))))}}function u(e,t,r){const a=[new c(e,t)];if(r){const r=e+"Size";a.push(new l(r,((e,r)=>{const a=t(e,r);return(0,i.pC)(a)?(0,n.a)(d,a.descriptor.width,a.descriptor.height):o.Z})))}return a}const d=(0,o.a)()},98069:(e,t,r)=>{r.d(t,{A:()=>c,J:()=>u});var i=r(70586),n=r(4307),o=r(97323),a=r(19693),s=r(79884),l=r(67498);class c extends s.x{constructor(e,t){super(e,"sampler2D",l.P.Pass,((r,i,n)=>r.bindTexture(e,t(i,n))))}}function u(e,t,r){const s=[new c(e,t)];if(r){const r=e+"Size";s.push(new a.A(r,((e,r)=>{const a=t(e,r);return(0,i.pC)(a)?(0,n.a)(d,a.descriptor.width,a.descriptor.height):o.Z})))}return s}const d=(0,o.a)()},79884:(e,t,r)=>{r.d(t,{x:()=>o});var i=r(70586),n=r(67498);class o{constructor(e,t,r,o,a=null){this.name=e,this.type=t,this.arraySize=a,this.bind={[n.P.Pass]:null,[n.P.Draw]:null},(0,i.pC)(r)&&(0,i.pC)(o)&&(this.bind[r]=o)}equals(e){return this.type===e.type&&this.name===e.name&&this.arraySize===e.arraySize}}},74709:(e,t,r)=>{r.d(t,{H:()=>n,K:()=>i});class i{}function n(e,...t){let r="";for(let i=0;i<t.length;i++)r+=e[i]+t[i];return r+=e[e.length-1],r}!function(e){e.int=function(e){return Math.round(e).toString()},e.float=function(e){return e.toPrecision(8)}}(n||(n={}))},67498:(e,t,r)=>{var i;r.d(t,{P:()=>i}),function(e){e[e.Pass=0]="Pass",e[e.Draw=1]="Draw"}(i||(i={}))},17662:(e,t,r)=>{r.d(t,{c:()=>n});var i=r(99001);class n{constructor(){this.id=(0,i.D)()}unload(){}}},4726:(e,t,r)=>{var i;r.d(t,{U:()=>i}),function(e){e[e.Layer=0]="Layer",e[e.Object=1]="Object",e[e.Geometry=2]="Geometry",e[e.Material=3]="Material",e[e.Texture=4]="Texture",e[e.COUNT=5]="COUNT"}(i||(i={}))},83475:(e,t,r)=>{r.d(t,{i:()=>n});var i=r(35065);const n=new Map([[i.T.POSITION,0],[i.T.NORMAL,1],[i.T.UV0,2],[i.T.COLOR,3],[i.T.SIZE,4],[i.T.TANGENT,4],[i.T.AUXPOS1,5],[i.T.SYMBOLCOLOR,5],[i.T.AUXPOS2,6],[i.T.FEATUREATTRIBUTE,6],[i.T.INSTANCEFEATUREATTRIBUTE,6],[i.T.INSTANCECOLOR,7],[i.T.MODEL,8],[i.T.MODELNORMAL,12],[i.T.MODELORIGINHI,11],[i.T.MODELORIGINLO,15]])},60537:(e,t,r)=>{r.d(t,{F:()=>s});var i=r(70586),n=r(95330),o=r(74709),a=r(47026);class s extends class{constructor(e){this._material=e.material,this._techniqueRepository=e.techniqueRep,this._output=e.output}dispose(){this._techniqueRepository.release(this._technique)}get technique(){return this._technique}ensureTechnique(e,t,r=this._output){return this._technique=this._techniqueRepository.releaseAndAcquire(e,this._material.getConfiguration(r,t),this._technique),this._technique}ensureResources(e){return a.Rw.LOADED}}{constructor(e){super(e),this._numLoading=0,this._disposed=!1,this._textureRepository=e.textureRep,this._textureId=e.textureId,this._acquire(e.textureId,(e=>this._texture=e)),this._acquire(e.normalTextureId,(e=>this._textureNormal=e)),this._acquire(e.emissiveTextureId,(e=>this._textureEmissive=e)),this._acquire(e.occlusionTextureId,(e=>this._textureOcclusion=e)),this._acquire(e.metallicRoughnessTextureId,(e=>this._textureMetallicRoughness=e))}dispose(){this._texture=(0,i.RY)(this._texture),this._textureNormal=(0,i.RY)(this._textureNormal),this._textureEmissive=(0,i.RY)(this._textureEmissive),this._textureOcclusion=(0,i.RY)(this._textureOcclusion),this._textureMetallicRoughness=(0,i.RY)(this._textureMetallicRoughness),this._disposed=!0}ensureResources(e){return 0===this._numLoading?a.Rw.LOADED:a.Rw.LOADING}get textureBindParameters(){return new l((0,i.pC)(this._texture)?this._texture.glTexture:null,(0,i.pC)(this._textureNormal)?this._textureNormal.glTexture:null,(0,i.pC)(this._textureEmissive)?this._textureEmissive.glTexture:null,(0,i.pC)(this._textureOcclusion)?this._textureOcclusion.glTexture:null,(0,i.pC)(this._textureMetallicRoughness)?this._textureMetallicRoughness.glTexture:null)}updateTexture(e){((0,i.Wi)(this._texture)||e!==this._texture.id)&&(this._texture=(0,i.RY)(this._texture),this._textureId=e,this._acquire(this._textureId,(e=>this._texture=e)))}_acquire(e,t){if((0,i.Wi)(e))return void t(null);const r=this._textureRepository.acquire(e);if((0,n.y8)(r))return++this._numLoading,void r.then((e=>{if(this._disposed)return(0,i.RY)(e),void t(null);t(e)})).finally((()=>--this._numLoading));t(r)}}class l extends o.K{constructor(e=null,t=null,r=null,i=null,n=null){super(),this.texture=e,this.textureNormal=t,this.textureEmissive=r,this.textureOcclusion=i,this.textureMetallicRoughness=n}}},82791:(e,t,r)=>{r.d(t,{F5:()=>u,yD:()=>i});var i,n,o=r(70586),a=(r(74709),r(17662)),s=r(4726),l=r(83475),c=r(37782);class u extends a.c{constructor(e,t){super(),this.type=s.U.Material,this.supportsEdges=!1,this._visible=!0,this._renderPriority=0,this._insertOrder=0,this._vertexAttributeLocations=l.i,this._parameters=(0,c.Uf)(e,t),this.validateParameters(this._parameters)}dispose(){}get parameters(){return this._parameters}update(e){return!1}setParameters(e,t=!0){(0,c.LO)(this._parameters,e)&&(this.validateParameters(this._parameters),t&&this.parametersChanged())}validateParameters(e){}get visible(){return this._visible}set visible(e){e!==this._visible&&(this._visible=e,this.parametersChanged())}shouldRender(e){return this.isVisible()&&this.isVisibleInPass(e.pass)&&0!=(this.renderOccluded&e.renderOccludedMask)}isVisibleInPass(e){return!0}get renderOccluded(){return this.parameters.renderOccluded}get renderPriority(){return this._renderPriority}set renderPriority(e){e!==this._renderPriority&&(this._renderPriority=e,this.parametersChanged())}get insertOrder(){return this._insertOrder}set insertOrder(e){e!==this._insertOrder&&(this._insertOrder=e,this.parametersChanged())}get vertexAttributeLocations(){return this._vertexAttributeLocations}isVisible(){return this._visible}parametersChanged(){(0,o.pC)(this.repository)&&this.repository.materialChanged(this)}}(n=i||(i={}))[n.Occlude=1]="Occlude",n[n.Transparent=2]="Transparent",n[n.OccludeAndTransparent=4]="OccludeAndTransparent",n[n.OccludeAndTransparentStencil=8]="OccludeAndTransparentStencil",n[n.Opaque=16]="Opaque"},11726:(e,t,r)=>{r.d(t,{hu:()=>n,yK:()=>o}),r(97323),r(98766),(0,r(88669).c)();class i{constructor(e){this.message=e}toString(){return`AssertException: ${this.message}`}}function n(e,t){if(!e)throw t=t||"assert",console.log(new Error(t).stack),new i(t)}function o(e,t,r,i){let n,o=(r[0]-e[0])/t[0],a=(i[0]-e[0])/t[0];o>a&&(n=o,o=a,a=n);let s=(r[1]-e[1])/t[1],l=(i[1]-e[1])/t[1];if(s>l&&(n=s,s=l,l=n),o>l||s>a)return!1;s>o&&(o=s),l<a&&(a=l);let c=(r[2]-e[2])/t[2],u=(i[2]-e[2])/t[2];return c>u&&(n=c,c=u,u=n),!(o>u||c>a||(u<a&&(a=u),a<0))}},35065:(e,t,r)=>{var i;r.d(t,{T:()=>i}),function(e){e.POSITION="position",e.NORMAL="normal",e.UV0="uv0",e.AUXPOS1="auxpos1",e.AUXPOS2="auxpos2",e.MAPPOS="mapPos",e.COLOR="color",e.SYMBOLCOLOR="symbolColor",e.SIZE="size",e.TANGENT="tangent",e.OFFSET="offset",e.SUBDIVISIONFACTOR="subdivisionFactor",e.COLORFEATUREATTRIBUTE="colorFeatureAttribute",e.SIZEFEATUREATTRIBUTE="sizeFeatureAttribute",e.OPACITYFEATUREATTRIBUTE="opacityFeatureAttribute",e.DISTANCETOSTART="distanceToStart",e.UVMAPSPACE="uvMapSpace",e.BOUNDINGRECT="boundingRect",e.UVREGION="uvRegion",e.NORMALCOMPRESSED="normalCompressed",e.PROFILERIGHT="profileRight",e.PROFILEUP="profileUp",e.PROFILEVERTEXANDNORMAL="profileVertexAndNormal",e.FEATUREVALUE="featureValue",e.MODELORIGINHI="modelOriginHi",e.MODELORIGINLO="modelOriginLo",e.MODEL="model",e.MODELNORMAL="modelNormal",e.INSTANCECOLOR="instanceColor",e.INSTANCEFEATUREATTRIBUTE="instanceFeatureAttribute",e.LOCALTRANSFORM="localTransform",e.GLOBALTRANSFORM="globalTransform",e.BOUNDINGSPHERE="boundingSphere",e.MODELORIGIN="modelOrigin",e.MODELSCALEFACTORS="modelScaleFactors",e.FEATUREATTRIBUTE="featureAttribute",e.STATE="state",e.LODLEVEL="lodLevel",e.POSITION0="position0",e.POSITION1="position1",e.NORMALA="normalA",e.NORMALB="normalB",e.COMPONENTINDEX="componentIndex",e.VARIANTOFFSET="variantOffset",e.VARIANTSTROKE="variantStroke",e.VARIANTEXTENSION="variantExtension",e.U8PADDING="u8padding",e.U16PADDING="u16padding",e.SIDENESS="sideness",e.START="start",e.END="end",e.UP="up",e.EXTRUDE="extrude"}(i||(i={}))},47026:(e,t,r)=>{var i,n,o,a,s,l,c,u,d,h,f,m,p,g;r.d(t,{Am:()=>a,CE:()=>f,Gv:()=>n,JJ:()=>p,MX:()=>h,Rw:()=>l,Vr:()=>i,hU:()=>c}),function(e){e[e.None=0]="None",e[e.Front=1]="Front",e[e.Back=2]="Back",e[e.COUNT=3]="COUNT"}(i||(i={})),function(e){e[e.Less=0]="Less",e[e.Lequal=1]="Lequal",e[e.COUNT=2]="COUNT"}(n||(n={})),function(e){e[e.NONE=0]="NONE",e[e.SMAA=1]="SMAA"}(o||(o={})),function(e){e[e.Color=0]="Color",e[e.Alpha=1]="Alpha",e[e.FrontFace=2]="FrontFace",e[e.NONE=3]="NONE",e[e.COUNT=4]="COUNT"}(a||(a={})),function(e){e[e.BACKGROUND=0]="BACKGROUND",e[e.UPDATE=1]="UPDATE"}(s||(s={})),function(e){e[e.NOT_LOADED=0]="NOT_LOADED",e[e.LOADING=1]="LOADING",e[e.LOADED=2]="LOADED"}(l||(l={})),function(e){e[e.IntegratedMeshMaskExcluded=1]="IntegratedMeshMaskExcluded",e[e.OutlineVisualElementMask=2]="OutlineVisualElementMask"}(c||(c={})),function(e){e[e.ASYNC=0]="ASYNC",e[e.SYNC=1]="SYNC"}(u||(u={})),function(e){e[e.Highlight=0]="Highlight",e[e.MaskOccludee=1]="MaskOccludee",e[e.COUNT=2]="COUNT"}(d||(d={})),function(e){e[e.Triangle=0]="Triangle",e[e.Point=1]="Point",e[e.Line=2]="Line"}(h||(h={})),function(e){e[e.STRETCH=1]="STRETCH",e[e.PAD=2]="PAD"}(f||(f={})),function(e){e[e.CHANGED=0]="CHANGED",e[e.UNCHANGED=1]="UNCHANGED"}(m||(m={})),function(e){e[e.Blend=0]="Blend",e[e.Opaque=1]="Opaque",e[e.Mask=2]="Mask",e[e.MaskBlend=3]="MaskBlend",e[e.COUNT=4]="COUNT"}(p||(p={})),function(e){e[e.OFF=0]="OFF",e[e.ON=1]="ON"}(g||(g={}))},9749:(e,t,r)=>{r.d(t,{V:()=>n}),r(17896);var i=r(65617);r(22021),(0,i.c)();const n=.4;(0,i.c)()},37782:(e,t,r)=>{r.d(t,{FZ:()=>w,Uf:()=>M,Bw:()=>g,LO:()=>R,Hx:()=>S});var i=r(67676),n=r(22021),o=r(70586),a=r(17896),s=r(65617),l=r(60437),c=r(47026);function u(e,t){return Math.max((0,n.t7)(e*t.scale,e,t.factor),function(e,t){return 0===e?t.minPixelSize:t.minPixelSize*(1+2*t.paddingPixels/e)}(e,t))}r(64822),(0,n.Vl)(10),(0,n.Vl)(12),(0,n.Vl)(70),(0,n.Vl)(40);const d={scale:0,factor:0,minPixelSize:0,paddingPixels:0};var h=r(11726),f=r(35065),m=(r(52138),r(13598));r(9820),new Float64Array(3),new Float32Array(6),(0,m.c)();const p=(0,l.Ue)();function g(e,t,r,i,n,a,s){if(!function(e){return!!(0,o.pC)(e)&&!e.visible}(t))if(e.boundingInfo){(0,h.hu)(e.primitiveType===c.MX.Triangle);const t=r.tolerance;v(e.boundingInfo,i,n,t,a,s)}else{const t=e.indices.get(f.T.POSITION),r=e.vertexAttributes.get(f.T.POSITION);x(i,n,0,t.length/3,t,r,void 0,a,s)}}const _=(0,s.c)();function v(e,t,r,i,n,s){if((0,o.Wi)(e))return;const c=function(e,t,r){return(0,a.s)(r,1/(t[0]-e[0]),1/(t[1]-e[1]),1/(t[2]-e[2]))}(t,r,_);if((0,l.op)(p,e.getBBMin()),(0,l.Tn)(p,e.getBBMax()),(0,o.pC)(n)&&n.applyToAabb(p),function(e,t,r,i){return function(e,t,r,i,n){const o=(e[0]-i-t[0])*r[0],a=(e[3]+i-t[0])*r[0];let s=Math.min(o,a),l=Math.max(o,a);const c=(e[1]-i-t[1])*r[1],u=(e[4]+i-t[1])*r[1];if(l=Math.min(l,Math.max(c,u)),l<0)return!1;if(s=Math.max(s,Math.min(c,u)),s>l)return!1;const d=(e[2]-i-t[2])*r[2],h=(e[5]+i-t[2])*r[2];return l=Math.min(l,Math.max(d,h)),!(l<0)&&(s=Math.max(s,Math.min(d,h)),!(s>l)&&s<1/0)}(e,t,r,i)}(p,t,c,i)){const{primitiveIndices:o,indices:a,position:l}=e,c=o?o.length:a.length/3;if(c>y){const o=e.getChildren();if(void 0!==o){for(let e=0;e<8;++e)void 0!==o[e]&&v(o[e],t,r,i,n,s);return}}x(t,r,0,c,a,l,o,n,s)}}const T=(0,s.c)();function x(e,t,r,i,n,a,s,l,c){if(s)return function(e,t,r,i,n,a,s,l,c){const u=a.data,d=a.stride||a.size,h=e[0],f=e[1],m=e[2],p=t[0]-h,g=t[1]-f,_=t[2]-m;for(let e=r;e<i;++e){const t=s[e];let r=3*t,i=d*n[r++],a=u[i++],v=u[i++],x=u[i];i=d*n[r++];let b=u[i++],A=u[i++],S=u[i];i=d*n[r];let M=u[i++],R=u[i++],C=u[i];(0,o.pC)(l)&&([a,v,x]=l.applyToVertex(a,v,x,e),[b,A,S]=l.applyToVertex(b,A,S,e),[M,R,C]=l.applyToVertex(M,R,C,e));const w=b-a,y=A-v,O=S-x,P=M-a,N=R-v,I=C-x,D=g*I-N*_,L=_*P-I*p,F=p*N-P*g,H=w*D+y*L+O*F;if(Math.abs(H)<=Number.EPSILON)continue;const B=h-a,U=f-v,z=m-x,G=B*D+U*L+z*F;if(H>0){if(G<0||G>H)continue}else if(G>0||G<H)continue;const V=U*O-y*z,W=z*w-O*B,q=B*y-w*U,k=p*V+g*W+_*q;if(H>0){if(k<0||G+k>H)continue}else if(k>0||G+k<H)continue;const $=(P*V+N*W+I*q)/H;$>=0&&c($,E(w,y,O,P,N,I,T),t,!1)}}(e,t,r,i,n,a,s,l,c);const u=a.data,d=a.stride||a.size,h=e[0],f=e[1],m=e[2],p=t[0]-h,g=t[1]-f,_=t[2]-m;for(let e=r,t=3*r;e<i;++e){let r=d*n[t++],i=u[r++],a=u[r++],s=u[r];r=d*n[t++];let v=u[r++],x=u[r++],b=u[r];r=d*n[t++];let A=u[r++],S=u[r++],M=u[r];(0,o.pC)(l)&&([i,a,s]=l.applyToVertex(i,a,s,e),[v,x,b]=l.applyToVertex(v,x,b,e),[A,S,M]=l.applyToVertex(A,S,M,e));const R=v-i,C=x-a,w=b-s,y=A-i,O=S-a,P=M-s,N=g*P-O*_,I=_*y-P*p,D=p*O-y*g,L=R*N+C*I+w*D;if(Math.abs(L)<=Number.EPSILON)continue;const F=h-i,H=f-a,B=m-s,U=F*N+H*I+B*D;if(L>0){if(U<0||U>L)continue}else if(U>0||U<L)continue;const z=H*w-C*B,G=B*R-w*F,V=F*C-R*H,W=p*z+g*G+_*V;if(L>0){if(W<0||U+W>L)continue}else if(W>0||U+W<L)continue;const q=(y*z+O*G+P*V)/L;q>=0&&c(q,E(R,C,w,y,O,P,T),e,!1)}}const b=(0,s.c)(),A=(0,s.c)();function E(e,t,r,i,n,o,s){return(0,a.s)(b,e,t,r),(0,a.s)(A,i,n,o),(0,a.f)(s,b,A),(0,a.n)(s,s),s}function S(e,t,r,i,a){let s=(r.screenLength||0)*e.pixelRatio;(0,o.pC)(a)&&(s=function(e,t,r,i){return u(e,function(e,t,r){const i=r.parameters,n=r.paddingPixelsOverride;return d.scale=Math.min(i.divisor/(t-i.offset),1),d.factor=function(e){return Math.abs(e*e*e)}(e),d.minPixelSize=i.minPixelSize,d.paddingPixels=n,d}(t,r,i))}(s,i,t,a));const l=s*Math.tan(.5*e.fovY)/(.5*e.fullHeight);return(0,n.uZ)(l*t,r.minWorldLength||0,null!=r.maxWorldLength?r.maxWorldLength:1/0)}function M(e,t){const r=t?M(t):{};for(const t in e){let i=e[t];i&&i.forEach&&(i=C(i)),null==i&&t in r||(r[t]=i)}return r}function R(e,t){let r=!1;for(const n in t){const o=t[n];void 0!==o&&(Array.isArray(o)?null===e[n]?(e[n]=o.slice(),r=!0):(0,i.Vx)(e[n],o)&&(r=!0):e[n]!==o&&(r=!0,e[n]=o))}return r}function C(e){const t=[];return e.forEach((e=>t.push(e))),t}const w={multiply:1,ignore:2,replace:3,tint:4},y=1e3},64822:(e,t,r)=>{var i;r.d(t,{JY:()=>i}),function(e){e[e.Global=1]="Global",e[e.Local=2]="Local"}(i||(i={}))},75656:(e,t,r)=>{r.d(t,{x:()=>c}),r(80442);var i=r(22021),n=r(70586),o=r(49300),a=r(54738),s=r(35371),l=r(46314);class c{constructor(e,t,r=null){if(this._context=e,this.type="texture",this._glName=null,this._descriptor=void 0,this._samplingModeDirty=!1,this._wrapModeDirty=!1,this._wasImmutablyAllocated=!1,e.instanceCounter.increment(s._g.Texture,this),this._descriptor={target:s.No.TEXTURE_2D,samplingMode:s.cw.LINEAR,wrapMode:s.e8.REPEAT,flipped:!1,hasMipmap:!1,isOpaque:!1,unpackAlignment:4,preMultiplyAlpha:!1,isImmutable:!1,...t},e.type!==a.zO.WEBGL2&&(this._descriptor.isImmutable&&(this._descriptor.isImmutable=!1),h(this._descriptor.target)))throw new Error("3D and array textures are not supported in WebGL1");this._descriptor.target===s.No.TEXTURE_CUBE_MAP?this._setDataCubeMap(r):this.setData(r)}get glName(){return this._glName}get descriptor(){return this._descriptor}get isDirty(){return this._samplingModeDirty||this._wrapModeDirty}dispose(){this._context.gl&&this._glName&&(this._context.unbindTexture(this),this._context.gl.deleteTexture(this._glName),this._glName=null,this._context.instanceCounter.decrement(s._g.Texture,this))}release(){this.dispose()}resize(e,t){const r=this._descriptor;if(r.width!==e||r.height!==t){if(this._wasImmutablyAllocated)throw new Error("Immutable textures can't be resized!");r.width=e,r.height=t,this._descriptor.target===s.No.TEXTURE_CUBE_MAP?this._setDataCubeMap(null):this.setData(null)}}_setDataCubeMap(e=null){for(let t=s.No.TEXTURE_CUBE_MAP_POSITIVE_X;t<=s.No.TEXTURE_CUBE_MAP_NEGATIVE_Z;t++)this._setData(e,t)}setData(e){this._setData(e)}_setData(e,t){if(!this._context||!this._context.gl)return;const r=this._context.gl;this._glName||(this._glName=r.createTexture()),void 0===e&&(e=null);const i=this._descriptor;t??(t=i.target);const a=h(t);null===e&&(i.width=i.width||4,i.height=i.height||4,a&&(i.depth=i.depth??1));const m=this._context.bindTexture(this,c.TEXTURE_UNIT_FOR_UPDATES);this._context.setActiveTexture(c.TEXTURE_UNIT_FOR_UPDATES),c._validateTexture(this._context,i),this._configurePixelStorage();const p=i.pixelFormat;let g=i.internalFormat?i.internalFormat:this._deriveInternalFormat(p,i.dataType);if(d(e)){let n=e.width,s=e.height;const l=1;e instanceof HTMLVideoElement&&(n=e.videoWidth,s=e.videoHeight),i.width&&i.height,a&&i.depth,i.isImmutable&&!this._wasImmutablyAllocated&&this._texStorage(t,g,i.hasMipmap,n,s,l),this._texImage(t,0,g,n,s,l,e),(0,o.zu)(r),i.hasMipmap&&this.generateMipmap(),void 0===i.width&&(i.width=n),void 0===i.height&&(i.height=s),a&&void 0===i.depth&&(i.depth=l)}else{const{width:c,height:d,depth:h}=i;if(null!=c&&null!=d||console.error("Width and height must be specified!"),a&&null==h&&console.error("Depth must be specified!"),i.isImmutable&&!this._wasImmutablyAllocated&&this._texStorage(t,g,i.hasMipmap,c,d,h),r.DEPTH24_STENCIL8&&g===r.DEPTH_STENCIL&&(g=r.DEPTH24_STENCIL8),u(e)){const n=e.levels,o=f(t,c,d,h),a=Math.min(o-1,n.length-1);(0,l.Z)(r)?r.texParameteri(i.target,r.TEXTURE_MAX_LEVEL,a):i.hasMipmap=i.hasMipmap&&o===n.length;const u=g;if(!function(e){return e in s.q_}(u))throw new Error("Attempting to use compressed data with an umcompressed format!");this._forEachMipmapLevel(((e,r,i,o)=>{const a=n[Math.min(e,n.length-1)];this._compressedTexImage(t,e,u,r,i,o,a)}),a)}else(0,n.pC)(e)?(this._texImage(t,0,g,c,d,h,e),(0,o.zu)(r),i.hasMipmap&&this.generateMipmap()):this._forEachMipmapLevel(((e,i,n,a)=>{this._texImage(t,e,g,i,n,a,null),(0,o.zu)(r)}))}c._applySamplingMode(r,this._descriptor),c._applyWrapMode(r,this._descriptor),c._applyAnisotropicFilteringParameters(this._context,this._descriptor),(0,o.zu)(r),this._context.bindTexture(m,c.TEXTURE_UNIT_FOR_UPDATES)}updateData(e,t,r,i,n,o){o||console.error("An attempt to use uninitialized data!"),this._glName||console.error("An attempt to update uninitialized texture!");const a=this._context.gl,s=this._descriptor,{pixelFormat:l,internalFormat:h,dataType:f,isImmutable:m,target:p}=s;if(m&&!this._wasImmutablyAllocated)throw new Error("Cannot update immutable texture before allocation!");const g=this._context.bindTexture(this,c.TEXTURE_UNIT_FOR_UPDATES);(t<0||r<0||i>s.width||n>s.height||t+i>s.width||r+n>s.height)&&console.error("An attempt to update out of bounds of the texture!"),this._configurePixelStorage(),d(o)?a.texSubImage2D(p,e,t,r,l,f,o):u(o)?a.compressedTexSubImage2D(p,e,t,r,i,n,h,o.levels[e]):a.texSubImage2D(p,e,t,r,i,n,l,f,o),this._context.bindTexture(g,c.TEXTURE_UNIT_FOR_UPDATES)}updateData3D(e,t,r,i,n,o,a,s){s||console.error("An attempt to use uninitialized data!"),this._glName||console.error("An attempt to update uninitialized texture!");const d=this._context.gl;if(!(0,l.Z)(d))throw new Error("3D textures are not supported in WebGL1");const f=this._descriptor,{pixelFormat:m,dataType:p,isImmutable:g,target:_,internalFormat:v}=f;if(g&&!this._wasImmutablyAllocated)throw new Error("Cannot update immutable texture before allocation!");h(_)||console.warn("Attempting to set 3D texture data on a non-3D texture");const T=this._context.bindTexture(this,c.TEXTURE_UNIT_FOR_UPDATES);if(this._context.setActiveTexture(c.TEXTURE_UNIT_FOR_UPDATES),(t<0||r<0||i<0||n>f.width||o>f.height||a>f.depth||t+n>f.width||r+o>f.height||i+a>f.depth)&&console.error("An attempt to update out of bounds of the texture!"),this._configurePixelStorage(),u(s))s=s.levels[e],d.compressedTexSubImage3D(_,e,t,r,i,n,o,a,v,s);else{const l=s;d.texSubImage3D(_,e,t,r,i,n,o,a,m,p,l)}this._context.bindTexture(T,c.TEXTURE_UNIT_FOR_UPDATES)}generateMipmap(){const e=this._descriptor;if(!e.hasMipmap){if(this._wasImmutablyAllocated)throw new Error("Cannot add mipmaps to immutable texture after allocation");e.hasMipmap=!0,this._samplingModeDirty=!0,c._validateTexture(this._context,e)}e.samplingMode===s.cw.LINEAR?(this._samplingModeDirty=!0,e.samplingMode=s.cw.LINEAR_MIPMAP_NEAREST):e.samplingMode===s.cw.NEAREST&&(this._samplingModeDirty=!0,e.samplingMode=s.cw.NEAREST_MIPMAP_NEAREST);const t=this._context.bindTexture(this,c.TEXTURE_UNIT_FOR_UPDATES);this._context.setActiveTexture(c.TEXTURE_UNIT_FOR_UPDATES),this._context.gl.generateMipmap(e.target),this._context.bindTexture(t,c.TEXTURE_UNIT_FOR_UPDATES)}setSamplingMode(e){e!==this._descriptor.samplingMode&&(this._descriptor.samplingMode=e,this._samplingModeDirty=!0)}setWrapMode(e){e!==this._descriptor.wrapMode&&(this._descriptor.wrapMode=e,c._validateTexture(this._context,this._descriptor),this._wrapModeDirty=!0)}applyChanges(){const e=this._context.gl,t=this._descriptor;this._samplingModeDirty&&(c._applySamplingMode(e,t),this._samplingModeDirty=!1),this._wrapModeDirty&&(c._applyWrapMode(e,t),this._wrapModeDirty=!1)}_deriveInternalFormat(e,t){if(this._context.type===a.zO.WEBGL1)return e;switch(t){case s.Br.FLOAT:switch(e){case s.VI.RGBA:return s.lP.RGBA32F;case s.VI.RGB:return s.lP.RGB32F;default:throw new Error("Unable to derive format")}case s.Br.UNSIGNED_BYTE:switch(e){case s.VI.RGBA:return s.lP.RGBA8;case s.VI.RGB:return s.lP.RGB8}default:return e}}_configurePixelStorage(){const e=this._context.gl,{unpackAlignment:t,flipped:r,preMultiplyAlpha:i}=this._descriptor;e.pixelStorei(e.UNPACK_ALIGNMENT,t),e.pixelStorei(e.UNPACK_FLIP_Y_WEBGL,r?1:0),e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,i?1:0)}_texStorage(e,t,r,i,n,o){const a=this._context.gl;if(!(0,l.Z)(a))throw new Error("Immutable textures are not supported in WebGL1");if(!function(e){return e in s.lP}(t))throw new Error("Immutable textures must have a sized internal format");if(!this._descriptor.isImmutable)return;const c=r?f(e,i,n,o):1;h(e)?a.texStorage3D(e,c,t,i,n,o):a.texStorage2D(e,c,t,i,n),this._wasImmutablyAllocated=!0}_texImage(e,t,r,i,o,s,l){const c=this._context.gl;let u=null;const f=this._context.type===a.zO.WEBGL2,m=h(e),{isImmutable:p,pixelFormat:g,dataType:_}=this._descriptor;if(f&&(u=c),f||!d(l))if(p){if((0,n.pC)(l)){const r=l;m?u.texSubImage3D(e,t,0,0,0,i,o,s,g,_,r):c.texSubImage2D(e,t,0,0,i,o,g,_,r)}}else{const a=(0,n.Wg)(l);m?u.texImage3D(e,t,r,i,o,s,0,g,_,a):c.texImage2D(e,t,r,i,o,0,g,_,a)}else c.texImage2D(e,0,r,g,_,l)}_compressedTexImage(e,t,r,i,o,s,l){const c=this._context.gl;let u=null;const d=h(e),f=this._descriptor.isImmutable;if(d){if(this._context.type!==a.zO.WEBGL2)throw new Error("3D textures are not supported in WebGL1");u=c}f?(0,n.pC)(l)&&(d?u.compressedTexSubImage3D(e,t,0,0,0,i,o,s,r,l):c.compressedTexSubImage2D(e,t,0,0,i,o,r,l)):d?u.compressedTexImage3D(e,t,r,i,o,s,0,l):c.compressedTexImage2D(e,t,r,i,o,0,l)}_forEachMipmapLevel(e,t=1/0){let{width:r,height:i,depth:n,hasMipmap:o,target:a}=this._descriptor;const l=a===s.No.TEXTURE_3D;for(let a=0;e(a,r,i,n),o&&(1!==r||1!==i||l&&1!==n)&&!(a>=t);++a)r=Math.max(1,r>>1),i=Math.max(1,i>>1),l&&(n=Math.max(1,n>>1))}static _validateTexture(e,t){(t.width<0||t.height<0||t.depth<0)&&console.error("Negative dimension parameters are not allowed!");const r=(0,l.Z)(e.gl),n=(0,i.wt)(t.width)&&(0,i.wt)(t.height);r||!t.isImmutable&&!h(t.target)||console.error("Immutable and 3D-like textures are not supported in WebGL1!"),r||n||("number"==typeof t.wrapMode?t.wrapMode!==s.e8.CLAMP_TO_EDGE&&console.error("Non-power-of-two textures must have a wrap mode of CLAMP_TO_EDGE!"):t.wrapMode.s===s.e8.CLAMP_TO_EDGE&&t.wrapMode.t===s.e8.CLAMP_TO_EDGE||console.error("Non-power-of-two textures must have a wrap mode of CLAMP_TO_EDGE!"),t.hasMipmap&&console.error("Mipmapping requires power-of-two textures!"))}static _applySamplingMode(e,t){let r=t.samplingMode,i=t.samplingMode;r===s.cw.LINEAR_MIPMAP_NEAREST||r===s.cw.LINEAR_MIPMAP_LINEAR?(r=s.cw.LINEAR,t.hasMipmap||(i=s.cw.LINEAR)):r!==s.cw.NEAREST_MIPMAP_NEAREST&&r!==s.cw.NEAREST_MIPMAP_LINEAR||(r=s.cw.NEAREST,t.hasMipmap||(i=s.cw.NEAREST)),e.texParameteri(t.target,e.TEXTURE_MAG_FILTER,r),e.texParameteri(t.target,e.TEXTURE_MIN_FILTER,i)}static _applyWrapMode(e,t){"number"==typeof t.wrapMode?(e.texParameteri(t.target,e.TEXTURE_WRAP_S,t.wrapMode),e.texParameteri(t.target,e.TEXTURE_WRAP_T,t.wrapMode)):(e.texParameteri(t.target,e.TEXTURE_WRAP_S,t.wrapMode.s),e.texParameteri(t.target,e.TEXTURE_WRAP_T,t.wrapMode.t))}static _applyAnisotropicFilteringParameters(e,t){const r=e.capabilities.textureFilterAnisotropic;r&&e.gl.texParameterf(t.target,r.TEXTURE_MAX_ANISOTROPY,t.maxAnisotropy??1)}}function u(e){return(0,n.pC)(e)&&"type"in e&&"compressed"===e.type}function d(e){return(0,n.pC)(e)&&!u(e)&&!function(e){return(0,n.pC)(e)&&"byteLength"in e}(e)}function h(e){return e===s.No.TEXTURE_3D||e===s.No.TEXTURE_2D_ARRAY}function f(e,t,r,i=1){let n=Math.max(t,r);return e===s.No.TEXTURE_3D&&(n=Math.max(n,i)),Math.round(Math.log(n)/Math.LN2)+1}c.TEXTURE_UNIT_FOR_UPDATES=0},21968:(e,t,r)=>{r.d(t,{G:()=>i});class i{constructor(e,t,r,i,n,o=!1,a=0){this.name=e,this.count=t,this.type=r,this.offset=i,this.stride=n,this.normalized=o,this.divisor=a}}},46314:(e,t,r)=>{function i(e){return window.WebGL2RenderingContext&&e instanceof window.WebGL2RenderingContext}r.d(t,{Z:()=>i})},49300:(e,t,r)=>{r.d(t,{CG:()=>l,hZ:()=>s,zu:()=>c});var i=r(20102),n=r(80442);const o=r(92604).Z.getLogger("esri/views/webgl"),a=!!(0,n.Z)("enable-feature:webgl-debug");function s(){return a}function l(){return a}function c(e){if(s()){const t=e.getError();if(t){const r=function(e,t){switch(t){case e.INVALID_ENUM:return"Invalid Enum. An unacceptable value has been specified for an enumerated argument.";case e.INVALID_VALUE:return"Invalid Value. A numeric argument is out of range.";case e.INVALID_OPERATION:return"Invalid Operation. The specified command is not allowed for the current state.";case e.INVALID_FRAMEBUFFER_OPERATION:return"Invalid Framebuffer operation. The currently bound framebuffer is not framebuffer complete when trying to render to or to read from it.";case e.OUT_OF_MEMORY:return"Out of memory. Not enough memory is left to execute the command.";case e.CONTEXT_LOST_WEBGL:return"WebGL context has been lost";default:return"Unknown error"}}(e,t),n=(new Error).stack;o.error(new i.Z("webgl-error","WebGL error occured",{message:r,stack:n}))}}}},54738:(e,t,r)=>{r.d(t,{Sh:()=>a,kr:()=>s,zO:()=>i});var i,n,o=r(80442);function a(e){const t=(0,o.Z)("esri-force-webgl");if(t===i.WEBGL1||t===i.WEBGL2)return[t];switch(e){case"2d":return(0,o.Z)("mac")?[i.WEBGL1,i.WEBGL2]:[i.WEBGL2,i.WEBGL1];case"3d":return[i.WEBGL2,i.WEBGL1]}}function s(e,t,r={}){const n=t===i.WEBGL1?["webgl","experimental-webgl","webkit-3d","moz-webgl"]:["webgl2"];let o=null;for(const t of n){try{o=e.getContext(t,r)}catch(e){}if(o)break}return o}(n=i||(i={}))[n.WEBGL1=1]="WEBGL1",n[n.WEBGL2=2]="WEBGL2"},9820:(e,t,r)=>{function i(e,t){const r=e.length;for(let i=0;i<r;++i)o[0]=e[i],t[i]=o[0];return t}function n(e,t){const r=e.length;for(let i=0;i<r;++i)o[0]=e[i],o[1]=e[i]-o[0],t[i]=o[1];return t}r.d(t,{GB:()=>n,U8:()=>i});const o=new Float32Array(2)}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4109],{10699:(e,t,r)=>{r.d(t,{IG:()=>l});var s=r(43697),i=r(52011);let o=0;const l=e=>{let t=class extends e{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:Date.now().toString(16)+"-object-"+o++})}};return t=(0,s._)([(0,i.j)("esri.core.Identifiable")],t),t};let n=class extends(l(class{})){};n=(0,s._)([(0,i.j)("esri.core.Identifiable")],n)},16453:(e,t,r)=>{r.d(t,{R:()=>v,w:()=>S});var s=r(43697),i=r(15923),o=r(70586),l=r(41103),n=r(22974),a=r(31263);class u{constructor(){this._propertyOriginMap=new Map,this._originStores=new Array(a.kk),this._values=new Map,this.multipleOriginsSupported=!0}clone(e){const t=new u,r=this._originStores[a.s3.DEFAULTS];r&&r.forEach(((e,r)=>{t.set(r,(0,n.d9)(e),a.s3.DEFAULTS)}));for(let r=a.s3.SERVICE;r<a.kk;r++){const s=this._originStores[r];s&&s.forEach(((s,i)=>{e&&e.has(i)||t.set(i,(0,n.d9)(s),r)}))}return t}get(e,t){const r=void 0===t?this._values:this._originStores[t];return r?r.get(e):void 0}keys(e){const t=null==e?this._values:this._originStores[e];return t?[...t.keys()]:[]}set(e,t,r=a.s3.USER){let s=this._originStores[r];if(s||(s=new Map,this._originStores[r]=s),s.set(e,t),!this._values.has(e)||(0,o.j0)(this._propertyOriginMap.get(e))<=r){const s=this._values.get(e);return this._values.set(e,t),this._propertyOriginMap.set(e,r),s!==t}return!1}delete(e,t=a.s3.USER){const r=this._originStores[t];if(!r)return;const s=r.get(e);if(r.delete(e),this._values.has(e)&&this._propertyOriginMap.get(e)===t){this._values.delete(e);for(let r=t-1;r>=0;r--){const t=this._originStores[r];if(t&&t.has(e)){this._values.set(e,t.get(e)),this._propertyOriginMap.set(e,r);break}}}return s}has(e,t){const r=void 0===t?this._values:this._originStores[t];return!!r&&r.has(e)}revert(e,t){for(;t>0&&!this.has(e,t);)--t;const r=this._originStores[t],s=r&&r.get(e),i=this._values.get(e);return this._values.set(e,s),this._propertyOriginMap.set(e,t),i!==s}originOf(e){return this._propertyOriginMap.get(e)||a.s3.DEFAULTS}forEach(e){this._values.forEach(e)}}var p=r(50549),c=r(1153),h=r(52011);const d=e=>{let t=class extends e{constructor(...e){super(...e);const t=(0,o.j0)((0,c.vw)(this)),r=t.store,s=new u;t.store=s,(0,l.M)(t,r,s)}read(e,t){(0,p.i)(this,e,t)}getAtOrigin(e,t){const r=y(this),s=(0,a.M9)(t);if("string"==typeof e)return r.get(e,s);const i={};return e.forEach((e=>{i[e]=r.get(e,s)})),i}originOf(e){return(0,a.x3)(this.originIdOf(e))}originIdOf(e){return y(this).originOf(e)}revert(e,t){const r=y(this),s=(0,a.M9)(t),i=(0,c.vw)(this);let o;o="string"==typeof e?"*"===e?r.keys(s):[e]:e,o.forEach((e=>{i.invalidate(e),r.revert(e,s),i.commit(e)}))}};return t=(0,s._)([(0,h.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],t),t};function y(e){return(0,c.vw)(e).store}let f=class extends(d(i.Z)){};f=(0,s._)([(0,h.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],f);var m=r(76169);const g=e=>{let t=class extends e{constructor(...e){super(...e)}clear(e,t="user"){return _(this).delete(e,(0,a.M9)(t))}write(e={},t){return(0,m.c)(this,e=e||{},t),e}setAtOrigin(e,t,r){(0,c.vw)(this).setAtOrigin(e,t,(0,a.M9)(r))}removeOrigin(e){const t=_(this),r=(0,a.M9)(e),s=t.keys(r);for(const e of s)t.originOf(e)===r&&t.set(e,t.get(e,r),a.s3.USER)}updateOrigin(e,t){const r=_(this),s=(0,a.M9)(t),i=this.get(e);for(let t=s+1;t<a.kk;++t)r.delete(e,t);r.set(e,i,s)}toJSON(e){return this.write({},e)}};return t=(0,s._)([(0,h.j)("esri.core.WriteableMultiOriginJSONSupport")],t),t.prototype.toJSON.isDefaultToJSON=!0,t};function _(e){return(0,c.vw)(e).store}const v=e=>{let t=class extends(g(d(e))){constructor(...e){super(...e)}};return t=(0,s._)([(0,h.j)("esri.core.MultiOriginJSONSupport")],t),t};let S=class extends(v(i.Z)){};S=(0,s._)([(0,h.j)("esri.core.MultiOriginJSONSupport")],S)},87085:(e,t,r)=>{r.d(t,{Z:()=>S});var s=r(43697),i=(r(66577),r(3172)),o=r(20102),l=r(32448),n=r(10699),a=r(83379),u=r(92604),p=r(95330),c=r(17452),h=r(5600),d=(r(67676),r(80442),r(75215),r(52011)),y=r(68773);const f=u.Z.getLogger("esri.layers.support.fromPortalItem");var m=r(6570),g=r(82971);let _=0,v=class extends(l.Z.EventedMixin((0,n.IG)(a.Z))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new m.Z(-180,-90,180,90,g.Z.WGS84),this.id=Date.now().toString(16)+"-layer-"+_++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=g.Z.WGS84,this.title=null,this.type=null,this.url=null,this.visible=!0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e;return(await r.e(3529).then(r.bind(r,63529))).fromUrl(t)}static fromPortalItem(e){return async function(e){const t="portalItem"in e?e:{portalItem:e},s=await Promise.all([r.e(4547),r.e(8008)]).then(r.bind(r,28008));try{return await s.fromItem(t)}catch(e){const r=t&&t.portalItem,s=r&&r.id||"unset",i=r&&r.portal&&r.portal.url||y.Z.portalUrl;throw f.error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+i+"', id: '"+s+"')",e),e}}(e)}initialize(){this.when().catch((e=>{(0,p.D_)(e)||u.Z.getLogger(this.declaredClass).error("#load()",`Failed to load layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}')`,{error:e})}))}destroy(){if(this.parent){const e=this,t=this.parent;"layers"in t&&t.layers.includes(e)?t.layers.remove(e):"tables"in t&&t.tables.includes(e)?t.tables.remove(e):"baseLayers"in t&&t.baseLayers.includes(e)?t.baseLayers.remove(e):"baseLayers"in t&&t.referenceLayers.includes(e)&&t.referenceLayers.remove(e)}}get hasAttributionData(){return null!=this.attributionDataUrl}get parsedUrl(){const e=this.url;return e?(0,c.mN)(e):null}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,i.default)(e,{query:{f:"json"},responseType:"json"})).data;throw new o.Z("layer:no-attribution-data","Layer does not have attribution data")}};(0,s._)([(0,h.Cb)({type:String})],v.prototype,"attributionDataUrl",void 0),(0,s._)([(0,h.Cb)({type:m.Z})],v.prototype,"fullExtent",void 0),(0,s._)([(0,h.Cb)({readOnly:!0})],v.prototype,"hasAttributionData",null),(0,s._)([(0,h.Cb)({type:String,clonable:!1})],v.prototype,"id",void 0),(0,s._)([(0,h.Cb)({type:Boolean,nonNullable:!0})],v.prototype,"legendEnabled",void 0),(0,s._)([(0,h.Cb)({type:["show","hide","hide-children"]})],v.prototype,"listMode",void 0),(0,s._)([(0,h.Cb)({type:Number,range:{min:0,max:1},nonNullable:!0})],v.prototype,"opacity",void 0),(0,s._)([(0,h.Cb)({clonable:!1})],v.prototype,"parent",void 0),(0,s._)([(0,h.Cb)({readOnly:!0})],v.prototype,"parsedUrl",null),(0,s._)([(0,h.Cb)({type:Boolean})],v.prototype,"popupEnabled",void 0),(0,s._)([(0,h.Cb)({type:Boolean})],v.prototype,"attributionVisible",void 0),(0,s._)([(0,h.Cb)({type:g.Z})],v.prototype,"spatialReference",void 0),(0,s._)([(0,h.Cb)({type:String})],v.prototype,"title",void 0),(0,s._)([(0,h.Cb)({readOnly:!0,json:{read:!1}})],v.prototype,"type",void 0),(0,s._)([(0,h.Cb)()],v.prototype,"url",void 0),(0,s._)([(0,h.Cb)({type:Boolean,nonNullable:!0})],v.prototype,"visible",void 0),v=(0,s._)([(0,d.j)("esri.layers.Layer")],v);const S=v},24109:(e,t,r)=>{r.r(t),r.d(t,{default:()=>ue});var s=r(43697),i=r(3172),o=r(20102),l=r(22974),n=r(70586),a=r(16453),u=r(95330),p=r(17452),c=r(5600),h=(r(75215),r(71715)),d=r(52011),y=r(30556),f=r(6570),m=r(82971),g=r(87085),_=r(54295),v=r(46486),S=r(17287),w=r(71612),b=r(17017),A=r(38009),x=r(16859),E=r(72965);let C=null;const I=r(92604).Z.getLogger("esri.layers.support.SpriteSource");class U{constructor(e,t,r,s){this.baseURL=e,this.devicePixelRatio=t,this.maxTextureSize=r,this._spriteImageFormat=s,this._isRetina=!1,this._spritesData={},this.image=null,this.width=null,this.height=null,this.loadStatus="not-loaded"}get spriteNames(){const e=[];for(const t in this._spritesData)e.push(t);return e.sort(),e}getSpriteInfo(e){return this._spritesData[e]}async load(e){if(this.baseURL){this.loadStatus="loading";try{await this._loadSprites(e),this.loadStatus="loaded"}catch{this.loadStatus="failed"}}else this.loadStatus="failed"}_loadSprites(e){this._isRetina=this.devicePixelRatio>1.15;const t=(0,p.mN)(this.baseURL),r=t.query?"?"+(0,p.B7)(t.query):"",s=this._isRetina?"@2x":"",l=`${t.path}${s}.${this._spriteImageFormat}${r}`,n=`${t.path}${s}.json${r}`;return Promise.all([(0,i.default)(n,e),(0,i.default)(l,{responseType:"image",...e})]).then((([e,r])=>{const s=Object.keys(e.data);if(!s||0===s.length||1===s.length&&"_ssl"===s[0]||!r||!r.data)return this._spritesData=this.image=null,this.width=this.height=0,null;this._spritesData=e.data;const i=r.data,l=Math.max(this.maxTextureSize,4096);if(i.width>l||i.height>l){const e=`Sprite resource for style ${t.path} is bigger than the maximum allowed of ${l} pixels}`;throw I.error(e),new o.Z("SpriteSource",e)}this.width=i.width,this.height=i.height;const n=document.createElement("canvas"),a=n.getContext("2d");n.width=i.width,n.height=i.height,a.drawImage(i,0,0,i.width,i.height);const u=a.getImageData(0,0,i.width,i.height),p=new Uint8Array(u.data);let c;for(let e=0;e<p.length;e+=4)c=p[e+3]/255,p[e]=p[e]*c,p[e+1]=p[e+1]*c,p[e+2]=p[e+2]*c;this.image=p}))}}var O=r(11145),T=r(68773),L=r(45322),B=r(56608),R=r(55415);class M{constructor(e){this.url=e}async fetchTileIndex(){return this._tileIndexPromise||(this._tileIndexPromise=(0,i.default)(this.url).then((e=>e.data.index))),this._tileIndexPromise}async dataKey(e,t){const r=await this.fetchTileIndex();return(0,u.k_)(t),this._getIndexedDataKey(r,e)}_getIndexedDataKey(e,t){const r=[t];if(t.level<0||t.row<0||t.col<0||t.row>>t.level>0||t.col>>t.level>0)return null;let s=t;for(;0!==s.level;)s=new R.Z(s.level-1,s.row>>1,s.col>>1,s.world),r.push(s);let i,o,l=e,n=r.pop();if(1===l)return n;for(;r.length;)if(i=r.pop(),o=(1&i.col)+((1&i.row)<<1),l){if(0===l[o]){n=null;break}if(1===l[o]){n=i;break}n=i,l=l[o]}return n}}class P{constructor(e,t){this._tilemap=e,this._tileIndexUrl=t}async fetchTileIndex(e){return this._tileIndexPromise||(this._tileIndexPromise=(0,i.default)(this._tileIndexUrl,{query:{...e?.query}}).then((e=>e.data.index))),this._tileIndexPromise}dataKey(e,t){const{level:r,row:s,col:i}=e,o=new R.Z(e);return this._tilemap.fetchAvailabilityUpsample(r,s,i,o,t).then((()=>(o.world=e.world,o))).catch((e=>{if((0,u.D_)(e))throw e;return null}))}}const D=new Map;class j{constructor(e,t,r){this.tilemap=null,this.tileInfo=null,this.capabilities=null,this.fullExtent=null,this.name=e,this.sourceUrl=t;const s=(0,p.mN)(this.sourceUrl),i=(0,l.d9)(r),o=i.tiles;if(s)for(let e=0;e<o.length;e++){const t=(0,p.mN)(o[e]);t&&((0,p.YP)(t.path)||(t.path=(0,p.v_)(s.path,t.path)),o[e]=(0,p.fl)(t.path,{...s.query,...t.query}))}this.tileServers=o;const n=r.capabilities&&r.capabilities.split(",").map((e=>e.toLowerCase().trim())),a=!0===r?.exportTilesAllowed,u=!0===n?.includes("tilemap"),c=a&&r.hasOwnProperty("maxExportTilesCount")?r.maxExportTilesCount:0;this.capabilities={operations:{supportsExportTiles:a,supportsTileMap:u},exportTiles:a?{maxExportTilesCount:+c}:null},this.tileInfo=(0,L.d)(i.tileInfo,i,null,{ignoreMinMaxLOD:!0});const h=r.tileMap?(0,p.fl)((0,p.v_)(s.path,r.tileMap),s.query):null;u?(this.type="vector-tile",this.tilemap=new P(new B.y({layer:{parsedUrl:s,tileInfo:this.tileInfo,type:"vector-tile",tileServers:this.tileServers}}),h)):h&&(this.tilemap=new M(h)),this.fullExtent=f.Z.fromJSON(r.fullExtent)}destroy(){}async getRefKey(e,t){return this.tilemap?.dataKey(e,t)??e}requestTile(e,t,r,s){return function(e,t,r,s,o){return function(e,t){const r=D.get(e);if(r)return r.then((e=>(0,l.d9)(e)));const s=(0,i.default)(e,{responseType:"array-buffer",...t}).then((({data:t})=>(D.delete(e),t))).catch((t=>{throw D.delete(e),t}));return D.set(e,s),s}(e.replace(/\{z\}/gi,t.toString()).replace(/\{y\}/gi,r.toString()).replace(/\{x\}/gi,s.toString()),o)}(this.tileServers[t%this.tileServers.length],e,t,r,s)}isCompatibleWith(e){const t=this.tileInfo,r=e.tileInfo;if(!t.spatialReference.equals(r.spatialReference))return!1;if(!t.origin.equals(r.origin))return!1;if(Math.round(t.dpi)!==Math.round(r.dpi))return!1;const s=t.lods,i=r.lods,o=Math.min(s.length,i.length);for(let e=0;e<o;e++){const t=s[e],r=i[e];if(t.level!==r.level||Math.round(t.scale)!==Math.round(r.scale))return!1}return!0}}const k=T.Z.defaults&&T.Z.defaults.io.corsEnabledServers;function N(e){if(!e)return;const t=(0,p.P$)(e);k&&!k.includes(t)&&k.push(t)}function F(...e){let t;for(let r=0;r<e.length;++r)if((0,p.oC)(e[r])){if(t){const s=t.split("://")[0];t=s+":"+e[r].trim()}}else t=(0,p.YP)(e[r])?e[r]:(0,p.v_)(t,e[r]);return(0,p.Qj)(t)}async function G(e,t,r,s,o){let l,n,a;if((0,u.k_)(o),"string"==typeof r){const e=(0,p.Fv)(r);N(e),a=await(0,i.default)(e,{...o,responseType:"json",query:{f:"json",...o?.query}}),a.ssl&&(l&&(l=l.replace(/^http:/i,"https:")),n&&(n=n.replace(/^http:/i,"https:"))),l=e,n=e}else a={data:r},l=r.jsonUrl||null,n=s;const c=a.data;if(W(c))return e.styleUrl=l||null,async function(e,t,r,s){const i=r?(0,p.Yd)(r):(0,p.L)();e.styleBase=i,e.style=t,e.styleUrl&&N(e.styleUrl),t["sprite-format"]&&"webp"===t["sprite-format"].toLowerCase()&&(e.spriteFormat="webp");const o=[];if(t.sources&&t.sources.esri){const r=t.sources.esri;r.url?await G(e,"esri",F(i,r.url),void 0,s):o.push(G(e,"esri",r,i,s))}for(const r of Object.keys(t.sources))"esri"!==r&&"vector"===t.sources[r].type&&(t.sources[r].url?o.push(G(e,r,F(i,t.sources[r].url),void 0,s)):t.sources[r].tiles&&o.push(G(e,r,t.sources[r],i,s)));await Promise.all(o)}(e,c,n,o);if(function(e){return!W(e)}(c))return e.sourceUrl?Z(e,c,n,!1,t,o):(e.sourceUrl=l||null,Z(e,c,n,!0,t,o));throw new Error("You must specify the URL or the JSON for a service or for a style.")}function W(e){return!!e.sources}async function Z(e,t,r,s,i,o){const l=r?(0,p.Qj)(r)+"/":(0,p.L)(),n=function(e,t){if(e.hasOwnProperty("tileInfo"))return e;const r={xmin:-20037507.067161843,ymin:-20037507.067161843,xmax:20037507.067161843,ymax:20037507.067161843,spatialReference:{wkid:102100}};let s=78271.51696400007,i=295828763.7957775;const o=[],l=e.hasOwnProperty("minzoom")?+e.minzoom:0,n=e.hasOwnProperty("maxzoom")?+e.maxzoom:22;for(let e=0;e<=n;e++)e>=l&&o.push({level:e,scale:i,resolution:s}),s/=2,i/=2;for(const r of e.tiles)N(F(t,r));return{capabilities:"TilesOnly",initialExtent:r,fullExtent:r,minScale:0,maxScale:0,tiles:e.tiles,tileInfo:{rows:512,cols:512,dpi:96,format:"pbf",origin:{x:-20037508.342787,y:20037508.342787},lods:o,spatialReference:{wkid:102100}}}}(t,l),a=new j(i,(0,p.fl)(l,o?.query),n);if(!s&&e.primarySourceName in e.sourceNameToSource){const t=e.sourceNameToSource[e.primarySourceName];if(!t.isCompatibleWith(a))return;null!=a.fullExtent&&(null!=t.fullExtent?t.fullExtent.union(a.fullExtent):t.fullExtent=a.fullExtent.clone()),t.tileInfo.lods.length<a.tileInfo.lods.length&&(t.tileInfo=a.tileInfo)}if(s?(e.sourceBase=l,e.source=t,e.validatedSource=n,e.primarySourceName=i,e.sourceUrl&&N(e.sourceUrl)):N(l),e.sourceNameToSource[i]=a,!e.style){if(null==t.defaultStyles)throw new Error;return"string"==typeof t.defaultStyles?G(e,"",F(l,t.defaultStyles,"root.json"),void 0,o):G(e,"",t.defaultStyles,F(l,"root.json"),o)}}var $=r(33516);const V=/^https:\/\/([a-z\d-]+)(\.maps([^.]*))?\.arcgis\.com/i,q={devext:{customBaseUrl:"mapsdevext.arcgis.com",portalHostname:"devext.arcgis.com"},qaext:{customBaseUrl:"mapsqa.arcgis.com",portalHostname:"qaext.arcgis.com"},www:{customBaseUrl:"maps.arcgis.com",portalHostname:"www.arcgis.com"}};function z(e){const t=e?.match(V);if(!t)return null;const[,r,s,i]=t;if(!r)return null;let o=null,l=null,n=null;const{devext:a,qaext:u,www:p}=q;if(s)if(o=r,i)switch(i.toLowerCase()){case"devext":({customBaseUrl:l,portalHostname:n}=a);break;case"qa":({customBaseUrl:l,portalHostname:n}=u);break;default:return null}else({customBaseUrl:l,portalHostname:n}=p);else switch(r.toLowerCase()){case"devext":({customBaseUrl:l,portalHostname:n}=a);break;case"qaext":({customBaseUrl:l,portalHostname:n}=u);break;case"www":({customBaseUrl:l,portalHostname:n}=p);break;default:return null}return{customBaseUrl:l,isPortal:!1,portalHostname:n,urlKey:o}}var K=r(25929);const H=1e-6;function Q(e,t){if(e===t)return!0;if(!e&&null!=t)return!1;if(null!=e&&!t)return!1;if(!e.spatialReference.equals(t.spatialReference)||e.dpi!==t.dpi)return!1;const r=e.origin,s=t.origin;if(Math.abs(r.x-s.x)>=H||Math.abs(r.y-s.y)>=H)return!1;let i,o;e.lods[0].scale>t.lods[0].scale?(i=e,o=t):(o=e,i=t);for(let e=i.lods[0].scale;e>=o.lods[o.lods.length-1].scale-H;e/=2)if(Math.abs(e-o.lods[0].scale)<H)return!0;return!1}function J(e,t){if(e===t)return e;if(!e&&null!=t)return t;if(null!=e&&!t)return e;const r=e.size[0],s=e.format,i=e.dpi,o={x:e.origin.x,y:e.origin.y},l=e.spatialReference.toJSON(),n=e.lods[0].scale>t.lods[0].scale?e.lods[0]:t.lods[0],a=e.lods[e.lods.length-1].scale<=t.lods[t.lods.length-1].scale?e.lods[e.lods.length-1]:t.lods[t.lods.length-1],u=n.scale,p=n.resolution,c=a.scale,h=[];let d=u,y=p,f=0;for(;d>c;)h.push({level:f,resolution:y,scale:d}),f++,d/=2,y/=2;return new O.Z({size:[r,r],dpi:i,format:s||"pbf",origin:o,lods:h,spatialReference:l})}var X=r(51785),Y=r(54738);let ee,te;function re(e){const t=(0,Y.Sh)(e);for(;t.length>1;){const e=se(t.shift());if(e.available)return e}return se(t.shift())}function se(e){switch(e){case Y.zO.WEBGL1:return ee||(ee=function(){const e=new oe,t=ne(Y.zO.WEBGL1,e);return(0,n.Wi)(t)||(e.supportsElementIndexUint=null!==t.getExtension("OES_element_index_uint"),e.supportsStandardDerivatives=null!==t.getExtension("OES_standard_derivatives"),e.supportsInstancedArrays=null!==t.getExtension("ANGLE_instanced_arrays"),e.supportsTextureFloat=null!==t.getExtension("OES_texture_float"),e.supportsTextureHalfFloat=null!==t.getExtension("OES_texture_half_float"),e.supportsColorBufferFloat=null!==t.getExtension("WEBGL_color_buffer_float"),e.supportsColorBufferFloatBlend=null!==t.getExtension("EXT_float_blend"),e.supportsColorBufferHalfFloat=null!==t.getExtension("EXT_color_buffer_half_float")),e}()),ee;case Y.zO.WEBGL2:return te||(te=function(){const e=new le,t=ne(Y.zO.WEBGL2,e);return(0,n.Wi)(t)||(e.supportsColorBufferFloat=null!==t.getExtension("EXT_color_buffer_float"),e.supportsColorBufferFloatBlend=null!==t.getExtension("EXT_float_blend"),e.supportsColorBufferHalfFloat=e.supportsColorBufferFloat||null!==t.getExtension("EXT_color_buffer_half_float")),e}()),te}}class ie{constructor(){this.available=!1,this.majorPerformanceCaveat=!1,this.maxTextureSize=0,this.supportsVertexShaderSamplers=!1,this.supportsHighPrecisionFragment=!1,this.supportsElementIndexUint=!1,this.supportsStandardDerivatives=!1,this.supportsInstancedArrays=!1,this.supportsTextureFloat=!1,this.supportsTextureHalfFloat=!1,this.supportsColorBufferFloat=!1,this.supportsColorBufferFloatBlend=!1,this.supportsColorBufferHalfFloat=!1}}class oe extends ie{constructor(){super(...arguments),this.type=Y.zO.WEBGL1}}class le extends ie{constructor(){super(...arguments),this.type=Y.zO.WEBGL2,this.supportsElementIndexUint=!0,this.supportsStandardDerivatives=!0,this.supportsInstancedArrays=!0,this.supportsTextureFloat=!0,this.supportsTextureHalfFloat=!0}}function ne(e,t){if(e===Y.zO.WEBGL1&&void 0===typeof WebGLRenderingContext||e===Y.zO.WEBGL2&&void 0===typeof WebGL2RenderingContext)return null;const r=document.createElement("canvas");if(!r)return null;let s=(0,Y.kr)(r,e,{failIfMajorPerformanceCaveat:!0});if((0,n.Wi)(s)&&(s=(0,Y.kr)(r,e),(0,n.pC)(s)&&(t.majorPerformanceCaveat=!0)),(0,n.Wi)(s))return s;if(e===Y.zO.WEBGL1){const e=s.getParameter(s.VERSION)?.match(/^WebGL\s+([\d.]*)/);if(e){const r=parseFloat(e[1]);t.available=r>=.94}}else t.available=!0;t.maxTextureSize=s.getParameter(s.MAX_TEXTURE_SIZE),t.supportsVertexShaderSamplers=s.getParameter(s.MAX_VERTEX_TEXTURE_IMAGE_UNITS)>0;const i=s.getShaderPrecisionFormat(s.FRAGMENT_SHADER,s.HIGH_FLOAT);return i&&(t.supportsHighPrecisionFragment=i.precision>0),s}let ae=class extends((0,w.h)((0,E.M)((0,v.Z)((0,S.Y)((0,A.q)((0,x.I)((0,b.N)((0,_.V)((0,a.R)(g.Z)))))))))){constructor(...e){super(...e),this._spriteSourceMap=new Map,this.currentStyleInfo=null,this.style=null,this.isReference=null,this.operationalLayerType="VectorTileLayer",this.type="vector-tile",this.url=null,this.symbolCollisionBoxesVisible=!1,this.path=null}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}destroy(){if(this.sourceNameToSource)for(const e of Object.values(this.sourceNameToSource))e?.destroy();this._spriteSourceMap.clear()}async prefetchResources(e){await this.loadSpriteSource(globalThis.devicePixelRatio||1,e)}load(e){const t=this.loadFromPortal({supportedTypes:["Vector Tile Service"],supportsData:!1},e).catch(u.r9).then((async()=>{if(!this.portalItem||!this.portalItem.id)return;const t=`${this.portalItem.itemUrl}/resources/styles/root.json`;(await(0,i.default)(t,{...e,query:{f:"json",...this.customParameters,token:this.apiKey}})).data&&this.read({url:t},(0,$.h)(this.portalItem))})).catch(u.r9).then((()=>this._loadStyle(e)));return this.addResolvingPromise(t),Promise.resolve(this)}get attributionDataUrl(){const e=this.currentStyleInfo,t=e&&e.serviceUrl&&(0,p.mN)(e.serviceUrl);if(!t)return null;const r=this._getDefaultAttribution(t.path);return r?(0,p.fl)(r,{...this.customParameters,token:this.apiKey}):null}get capabilities(){const e=this.primarySource;return e?e.capabilities:{operations:{supportsExportTiles:!1,supportsTileMap:!1},exportTiles:null}}get fullExtent(){return this.primarySource?.fullExtent||null}get parsedUrl(){return this.serviceUrl?(0,p.mN)(this.serviceUrl):null}get serviceUrl(){return this.currentStyleInfo&&this.currentStyleInfo.serviceUrl||null}get spatialReference(){return this.tileInfo&&this.tileInfo.spatialReference||null}get styleUrl(){return this.currentStyleInfo&&this.currentStyleInfo.styleUrl||null}writeStyleUrl(e,t){e&&(0,p.oC)(e)&&(e=`https:${e}`);const r=(0,n.Wg)(z(e));t.styleUrl=(0,K.e)(e,r)}get tileInfo(){const e=[];for(const t in this.sourceNameToSource)e.push(this.sourceNameToSource[t]);let t=this.primarySource?.tileInfo||new O.Z;if(e.length>1)for(let r=0;r<e.length;r++)Q(t,e[r].tileInfo)&&(t=J(t,e[r].tileInfo));return t}readVersion(e,t){return t.version?parseFloat(t.version):parseFloat(t.currentVersion)}async loadSpriteSource(e=1,t){if(!this._spriteSourceMap.has(e)){const r=re("2d").maxTextureSize,s=this.currentStyleInfo?.spriteUrl?(0,p.fl)(this.currentStyleInfo.spriteUrl,{...this.customParameters,token:this.apiKey}):null,i=new U(s,e,r,this.currentStyleInfo.spriteFormat);await i.load(t),this._spriteSourceMap.set(e,i)}return this._spriteSourceMap.get(e)}async setSpriteSource(e,t="png",r=1,s){const i=re("2d").maxTextureSize,o=e?(0,p.fl)(e,{...this.customParameters,token:this.apiKey}):null;if(!o)return null;const l=new U(o,r,i,t);try{return await l.load(s),this._spriteSourceMap.clear(),this._spriteSourceMap.set(r,l),this.currentStyleInfo.spriteUrl=o,this.emit("spriteSource-change",{spriteSource:l}),l}catch(e){(0,u.r9)(e)}return null}async loadStyle(e,t){const r=e||this.style||this.url;return this._loadingTask&&"string"==typeof r&&this.url===r||(this._loadingTask?.abort(),this._loadingTask=(0,u.vr)((e=>(this._spriteSourceMap.clear(),this._getSourceAndStyle(r,{signal:e}))),t)),this._loadingTask.promise}getStyleLayerId(e){return this.styleRepository.getStyleLayerId(e)}getStyleLayerIndex(e){return this.styleRepository.getStyleLayerIndex(e)}getPaintProperties(e){return(0,l.d9)(this.styleRepository.getPaintProperties(e))}setPaintProperties(e,t){const r=this.styleRepository.isPainterDataDriven(e);this.styleRepository.setPaintProperties(e,t);const s=this.styleRepository.isPainterDataDriven(e);this.emit("paint-change",{layer:e,paint:t,isDataDriven:r||s})}getStyleLayer(e){return(0,l.d9)(this.styleRepository.getStyleLayer(e))}setStyleLayer(e,t){this.styleRepository.setStyleLayer(e,t),this.emit("style-layer-change",{layer:e,index:t})}deleteStyleLayer(e){this.styleRepository.deleteStyleLayer(e),this.emit("delete-style-layer",{layer:e})}getLayoutProperties(e){return(0,l.d9)(this.styleRepository.getLayoutProperties(e))}setLayoutProperties(e,t){this.styleRepository.setLayoutProperties(e,t),this.emit("layout-change",{layer:e,layout:t})}setStyleLayerVisibility(e,t){this.styleRepository.setStyleLayerVisibility(e,t),this.emit("style-layer-visibility-change",{layer:e,visibility:t})}getStyleLayerVisibility(e){return this.styleRepository.getStyleLayerVisibility(e)}write(e,t){return t?.origin&&!this.styleUrl?(t.messages&&t.messages.push(new o.Z("vectortilelayer:unsupported",`VectorTileLayer (${this.title}, ${this.id}) with style defined by JSON only are not supported`,{layer:this})),null):super.write(e,t)}getTileUrl(e,t,r){return null}async _getSourceAndStyle(e,t){if(!e)throw new Error("invalid style!");const r=await async function(e,t){const r={source:null,sourceBase:null,sourceUrl:null,validatedSource:null,style:null,styleBase:null,styleUrl:null,sourceNameToSource:{},primarySourceName:"",spriteFormat:"png"},[s,i]="string"==typeof e?[e,null]:[null,e.jsonUrl];await G(r,"esri",e,i,t);const o={layerDefinition:r.validatedSource,url:s,serviceUrl:r.sourceUrl,style:r.style,styleUrl:r.styleUrl,spriteUrl:r.style.sprite&&F(r.styleBase,r.style.sprite),spriteFormat:r.spriteFormat,glyphsUrl:r.style.glyphs&&F(r.styleBase,r.style.glyphs),sourceNameToSource:r.sourceNameToSource,primarySourceName:r.primarySourceName};return N(o.spriteUrl),N(o.glyphsUrl),o}(e,{...t,query:{...this.customParameters,token:this.apiKey}});"webp"===r.spriteFormat&&(await function(e){if(C)return C;const t={lossy:"UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA",lossless:"UklGRhoAAABXRUJQVlA4TA0AAAAvAAAAEAcQERGIiP4HAA==",alpha:"UklGRkoAAABXRUJQVlA4WAoAAAAQAAAAAAAAAAAAQUxQSAwAAAARBxAR/Q9ERP8DAABWUDggGAAAABQBAJ0BKgEAAQAAAP4AAA3AAP7mtQAAAA==",animation:"UklGRlIAAABXRUJQVlA4WAoAAAASAAAAAAAAAAAAQU5JTQYAAAD/////AABBTk1GJgAAAAAAAAAAAAAAAAAAAGQAAABWUDhMDQAAAC8AAAAQBxAREYiI/gcA"};return C=new Promise((e=>{const r=new Image;r.onload=()=>{r.onload=r.onerror=null,e(r.width>0&&r.height>0)},r.onerror=()=>{r.onload=r.onerror=null,e(!1)},r.src="data:image/webp;base64,"+t.lossy})),C}()||(r.spriteFormat="png")),this._set("currentStyleInfo",{...r}),"string"==typeof e?(this.url=e,this.style=null):(this.url=null,this.style=e),this._set("sourceNameToSource",r.sourceNameToSource),this._set("primarySource",r.sourceNameToSource[r.primarySourceName]),this._set("styleRepository",new X.Z(r.style)),this.read(r.layerDefinition,{origin:"service"}),this.emit("load-style")}_getDefaultAttribution(e){const t=e.match(/^https?:\/\/(?:basemaps|basemapsbeta|basemapsdev)(?:-api)?\.arcgis\.com(\/[^\/]+)?\/arcgis\/rest\/services\/([^\/]+(\/[^\/]+)*)\/vectortileserver/i),r=["OpenStreetMap_v2","OpenStreetMap_Daylight_v2","OpenStreetMap_Export_v2","OpenStreetMap_FTS_v2","OpenStreetMap_GCS_v2","World_Basemap","World_Basemap_v2","World_Basemap_Export_v2","World_Basemap_GCS_v2","World_Basemap_WGS84","World_Contours_v2"];if(!t)return;const s=t[2]&&t[2].toLowerCase();if(!s)return;const i=t[1]||"";for(const e of r)if(e.toLowerCase().includes(s))return(0,p.Fv)(`//static.arcgis.com/attribution/Vector${i}/${e}`)}async _loadStyle(e){return this._loadingTask?.promise??this.loadStyle(null,e)}};(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"attributionDataUrl",null),(0,s._)([(0,c.Cb)({type:["show","hide"]})],ae.prototype,"listMode",void 0),(0,s._)([(0,c.Cb)({json:{read:!0,write:!0}})],ae.prototype,"blendMode",void 0),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],ae.prototype,"capabilities",null),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"currentStyleInfo",void 0),(0,s._)([(0,c.Cb)({json:{read:!1},readOnly:!0,type:f.Z})],ae.prototype,"fullExtent",null),(0,s._)([(0,c.Cb)()],ae.prototype,"style",void 0),(0,s._)([(0,c.Cb)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],ae.prototype,"isReference",void 0),(0,s._)([(0,c.Cb)({type:["VectorTileLayer"]})],ae.prototype,"operationalLayerType",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"parsedUrl",null),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"serviceUrl",null),(0,s._)([(0,c.Cb)({type:m.Z,readOnly:!0})],ae.prototype,"spatialReference",null),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"styleRepository",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"sourceNameToSource",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"primarySource",void 0),(0,s._)([(0,c.Cb)({type:String,readOnly:!0,json:{write:{ignoreOrigin:!0},origins:{"web-document":{write:{ignoreOrigin:!0,isRequired:!0}}}}})],ae.prototype,"styleUrl",null),(0,s._)([(0,y.c)(["portal-item","web-document"],"styleUrl")],ae.prototype,"writeStyleUrl",null),(0,s._)([(0,c.Cb)({json:{read:!1,origins:{service:{read:!1}}},readOnly:!0,type:O.Z})],ae.prototype,"tileInfo",null),(0,s._)([(0,c.Cb)({json:{read:!1},readOnly:!0,value:"vector-tile"})],ae.prototype,"type",void 0),(0,s._)([(0,c.Cb)({json:{origins:{"web-document":{read:{source:"styleUrl"}},"portal-item":{read:{source:"url"}}},write:!1,read:!1}})],ae.prototype,"url",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"version",void 0),(0,s._)([(0,h.r)("version",["version","currentVersion"])],ae.prototype,"readVersion",null),(0,s._)([(0,c.Cb)({type:Boolean})],ae.prototype,"symbolCollisionBoxesVisible",void 0),(0,s._)([(0,c.Cb)({type:String,json:{origins:{"web-scene":{read:!0,write:!0}},read:!1}})],ae.prototype,"path",void 0),ae=(0,s._)([(0,d.j)("esri.layers.VectorTileLayer")],ae);const ue=ae},54295:(e,t,r)=>{r.d(t,{V:()=>l});var s=r(43697),i=r(5600),o=(r(67676),r(80442),r(75215),r(52011));const l=e=>{let t=class extends e{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,s._)([(0,i.Cb)({type:String})],t.prototype,"apiKey",null),t=(0,s._)([(0,o.j)("esri.layers.mixins.APIKeyMixin")],t),t}},46486:(e,t,r)=>{r.d(t,{Z:()=>p});var s=r(43697),i=(r(66577),r(5600)),o=(r(67676),r(80442),r(75215),r(71715)),l=r(52011),n=r(45322),a=r(56608),u=r(82971);const p=e=>{let t=class extends e{constructor(){super(...arguments),this.copyright=null,this.minScale=0,this.maxScale=0,this.spatialReference=null,this.tileInfo=null,this.tilemapCache=null}readMinScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}readMaxScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}get supportsBlankTile(){return this.version>=10.2}readTilemapCache(e,t){return t.capabilities&&t.capabilities.includes("Tilemap")?new a.y({layer:this}):null}};return(0,s._)([(0,i.Cb)({json:{read:{source:"copyrightText"}}})],t.prototype,"copyright",void 0),(0,s._)([(0,i.Cb)()],t.prototype,"minScale",void 0),(0,s._)([(0,o.r)("service","minScale")],t.prototype,"readMinScale",null),(0,s._)([(0,i.Cb)()],t.prototype,"maxScale",void 0),(0,s._)([(0,o.r)("service","maxScale")],t.prototype,"readMaxScale",null),(0,s._)([(0,i.Cb)({type:u.Z})],t.prototype,"spatialReference",void 0),(0,s._)([(0,i.Cb)({readOnly:!0})],t.prototype,"supportsBlankTile",null),(0,s._)([(0,i.Cb)(n.h)],t.prototype,"tileInfo",void 0),(0,s._)([(0,i.Cb)()],t.prototype,"tilemapCache",void 0),(0,s._)([(0,o.r)("service","tilemapCache",["capabilities"])],t.prototype,"readTilemapCache",null),(0,s._)([(0,i.Cb)()],t.prototype,"version",void 0),t=(0,s._)([(0,l.j)("esri.layers.mixins.ArcGISCachedService")],t),t}},17287:(e,t,r)=>{r.d(t,{Y:()=>u});var s=r(43697),i=r(92604),o=r(70586),l=r(5600),n=(r(67676),r(80442),r(75215),r(52011)),a=r(66677);const u=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,a.Qc)(this.url);if((0,o.pC)(e)&&e.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,a.Nm)(e,i.Z.getLogger(this.declaredClass)))}};return(0,s._)([(0,l.Cb)()],t.prototype,"title",null),(0,s._)([(0,l.Cb)({type:String})],t.prototype,"url",null),t=(0,s._)([(0,n.j)("esri.layers.mixins.ArcGISService")],t),t}},17017:(e,t,r)=>{r.d(t,{N:()=>l});var s=r(43697),i=r(5600),o=(r(67676),r(80442),r(75215),r(52011));const l=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,s._)([(0,i.Cb)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,s._)([(0,o.j)("esri.layers.mixins.CustomParametersMixin")],t),t}},33516:(e,t,r)=>{r.d(t,{Y:()=>l,h:()=>o});var s=r(17452),i=r(65587);function o(e){return{origin:"portal-item",url:(0,s.mN)(e.itemUrl),portal:e.portal||i.Z.getDefault(),portalItem:e,readResourcePaths:[]}}function l(e){return{origin:"portal-item",messages:[],writtenProperties:[],url:e.itemUrl?(0,s.mN)(e.itemUrl):null,portal:e.portal||i.Z.getDefault(),portalItem:e}}},55415:(e,t,r)=>{r.d(t,{Z:()=>i});var s=r(71143);class i{constructor(e,t,r,s){this.set(e,t,r,s)}static getId(e,t,r,s){return"object"==typeof e?`${e.level}/${e.row}/${e.col}/${e.world}`:`${e}/${t}/${r}/${s}`}get key(){return this}get id(){return this.toString()}set id(e){this.set(e)}get hash(){const e=4095&this.row,t=4095&this.col,r=63&this.level;return(3&this.world)<<30|t<<22|e<<8|r}acquire(e,t,r,s){this.set(e,t,r,s)}contains(e){const t=e.level-this.level;return this.row===e.row>>t&&this.col===e.col>>t&&this.world===e.world}equals(e){return this.level===e.level&&this.row===e.row&&this.col===e.col&&this.world===e.world}clone(){return new i(this)}release(){this.level=0,this.row=0,this.col=0,this.world=0}set(e,t,r,s){if(null==e)this.level=0,this.row=0,this.col=0,this.world=0;else if("object"==typeof e)this.level=e.level||0,this.row=e.row||0,this.col=e.col||0,this.world=e.world||0;else if("string"==typeof e){const[t,r,s,i]=e.split("/");this.level=parseFloat(t),this.row=parseFloat(r),this.col=parseFloat(s),this.world=parseFloat(i)}else this.level=+e,this.row=+t,this.col=+r,this.world=+s||0;return this}toString(){return`${this.level}/${this.row}/${this.col}/${this.world}`}getParentKey(){return this.level<=0?null:new i(this.level-1,this.row>>1,this.col>>1,this.world)}getChildKeys(){const e=this.level+1,t=this.row<<1,r=this.col<<1,s=this.world;return[new i(e,t,r,s),new i(e,t,r+1,s),new i(e,t+1,r,s),new i(e,t+1,r+1,s)]}compareRowMajor(e){return this.row<e.row?-1:this.row>e.row?1:this.col<e.col?-1:this.col>e.col?1:0}}i.pool=new s.Z(i,null,null,25,50)},54738:(e,t,r)=>{r.d(t,{Sh:()=>l,kr:()=>n,zO:()=>s});var s,i,o=r(80442);function l(e){const t=(0,o.Z)("esri-force-webgl");if(t===s.WEBGL1||t===s.WEBGL2)return[t];switch(e){case"2d":case"3d":return[s.WEBGL2,s.WEBGL1]}}function n(e,t,r={}){const i=t===s.WEBGL1?["webgl","experimental-webgl","webkit-3d","moz-webgl"]:["webgl2"];let o=null;for(const t of i){try{o=e.getContext(t,r)}catch(e){}if(o)break}return o}(i=s||(s={}))[i.WEBGL1=1]="WEBGL1",i[i.WEBGL2=2]="WEBGL2"}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4109],{10699:(e,t,r)=>{r.d(t,{IG:()=>l});var s=r(43697),i=r(52011);let o=0;const l=e=>{let t=class extends e{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:Date.now().toString(16)+"-object-"+o++})}};return t=(0,s._)([(0,i.j)("esri.core.Identifiable")],t),t};let n=class extends(l(class{})){};n=(0,s._)([(0,i.j)("esri.core.Identifiable")],n)},16453:(e,t,r)=>{r.d(t,{R:()=>v,w:()=>S});var s=r(43697),i=r(15923),o=r(70586),l=r(41103),n=r(22974),a=r(31263);class u{constructor(){this._propertyOriginMap=new Map,this._originStores=new Array(a.kk),this._values=new Map,this.multipleOriginsSupported=!0}clone(e){const t=new u,r=this._originStores[a.s3.DEFAULTS];r&&r.forEach(((e,r)=>{t.set(r,(0,n.d9)(e),a.s3.DEFAULTS)}));for(let r=a.s3.SERVICE;r<a.kk;r++){const s=this._originStores[r];s&&s.forEach(((s,i)=>{e&&e.has(i)||t.set(i,(0,n.d9)(s),r)}))}return t}get(e,t){const r=void 0===t?this._values:this._originStores[t];return r?r.get(e):void 0}keys(e){const t=null==e?this._values:this._originStores[e];return t?[...t.keys()]:[]}set(e,t,r=a.s3.USER){let s=this._originStores[r];if(s||(s=new Map,this._originStores[r]=s),s.set(e,t),!this._values.has(e)||(0,o.j0)(this._propertyOriginMap.get(e))<=r){const s=this._values.get(e);return this._values.set(e,t),this._propertyOriginMap.set(e,r),s!==t}return!1}delete(e,t=a.s3.USER){const r=this._originStores[t];if(!r)return;const s=r.get(e);if(r.delete(e),this._values.has(e)&&this._propertyOriginMap.get(e)===t){this._values.delete(e);for(let r=t-1;r>=0;r--){const t=this._originStores[r];if(t&&t.has(e)){this._values.set(e,t.get(e)),this._propertyOriginMap.set(e,r);break}}}return s}has(e,t){const r=void 0===t?this._values:this._originStores[t];return!!r&&r.has(e)}revert(e,t){for(;t>0&&!this.has(e,t);)--t;const r=this._originStores[t],s=r&&r.get(e),i=this._values.get(e);return this._values.set(e,s),this._propertyOriginMap.set(e,t),i!==s}originOf(e){return this._propertyOriginMap.get(e)||a.s3.DEFAULTS}forEach(e){this._values.forEach(e)}}var p=r(50549),c=r(1153),h=r(52011);const d=e=>{let t=class extends e{constructor(...e){super(...e);const t=(0,o.j0)((0,c.vw)(this)),r=t.store,s=new u;t.store=s,(0,l.M)(t,r,s)}read(e,t){(0,p.i)(this,e,t)}getAtOrigin(e,t){const r=y(this),s=(0,a.M9)(t);if("string"==typeof e)return r.get(e,s);const i={};return e.forEach((e=>{i[e]=r.get(e,s)})),i}originOf(e){return(0,a.x3)(this.originIdOf(e))}originIdOf(e){return y(this).originOf(e)}revert(e,t){const r=y(this),s=(0,a.M9)(t),i=(0,c.vw)(this);let o;o="string"==typeof e?"*"===e?r.keys(s):[e]:e,o.forEach((e=>{i.invalidate(e),r.revert(e,s),i.commit(e)}))}};return t=(0,s._)([(0,h.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],t),t};function y(e){return(0,c.vw)(e).store}let f=class extends(d(i.Z)){};f=(0,s._)([(0,h.j)("esri.core.ReadOnlyMultiOriginJSONSupport")],f);var m=r(76169);const g=e=>{let t=class extends e{constructor(...e){super(...e)}clear(e,t="user"){return _(this).delete(e,(0,a.M9)(t))}write(e={},t){return(0,m.c)(this,e=e||{},t),e}setAtOrigin(e,t,r){(0,c.vw)(this).setAtOrigin(e,t,(0,a.M9)(r))}removeOrigin(e){const t=_(this),r=(0,a.M9)(e),s=t.keys(r);for(const e of s)t.originOf(e)===r&&t.set(e,t.get(e,r),a.s3.USER)}updateOrigin(e,t){const r=_(this),s=(0,a.M9)(t),i=this.get(e);for(let t=s+1;t<a.kk;++t)r.delete(e,t);r.set(e,i,s)}toJSON(e){return this.write({},e)}};return t=(0,s._)([(0,h.j)("esri.core.WriteableMultiOriginJSONSupport")],t),t.prototype.toJSON.isDefaultToJSON=!0,t};function _(e){return(0,c.vw)(e).store}const v=e=>{let t=class extends(g(d(e))){constructor(...e){super(...e)}};return t=(0,s._)([(0,h.j)("esri.core.MultiOriginJSONSupport")],t),t};let S=class extends(v(i.Z)){};S=(0,s._)([(0,h.j)("esri.core.MultiOriginJSONSupport")],S)},87085:(e,t,r)=>{r.d(t,{Z:()=>S});var s=r(43697),i=(r(66577),r(3172)),o=r(20102),l=r(32448),n=r(10699),a=r(83379),u=r(92604),p=r(95330),c=r(17452),h=r(5600),d=(r(67676),r(80442),r(75215),r(52011)),y=r(68773);const f=u.Z.getLogger("esri.layers.support.fromPortalItem");var m=r(6570),g=r(82971);let _=0,v=class extends(l.Z.EventedMixin((0,n.IG)(a.Z))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new m.Z(-180,-90,180,90,g.Z.WGS84),this.id=Date.now().toString(16)+"-layer-"+_++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=g.Z.WGS84,this.title=null,this.type=null,this.url=null,this.visible=!0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e;return(await r.e(3529).then(r.bind(r,63529))).fromUrl(t)}static fromPortalItem(e){return async function(e){const t="portalItem"in e?e:{portalItem:e},s=await Promise.all([r.e(4547),r.e(8008)]).then(r.bind(r,28008));try{return await s.fromItem(t)}catch(e){const r=t&&t.portalItem,s=r&&r.id||"unset",i=r&&r.portal&&r.portal.url||y.Z.portalUrl;throw f.error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+i+"', id: '"+s+"')",e),e}}(e)}initialize(){this.when().catch((e=>{(0,p.D_)(e)||u.Z.getLogger(this.declaredClass).error("#load()",`Failed to load layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}')`,{error:e})}))}destroy(){if(this.parent){const e=this,t=this.parent;"layers"in t&&t.layers.includes(e)?t.layers.remove(e):"tables"in t&&t.tables.includes(e)?t.tables.remove(e):"baseLayers"in t&&t.baseLayers.includes(e)?t.baseLayers.remove(e):"baseLayers"in t&&t.referenceLayers.includes(e)&&t.referenceLayers.remove(e)}}get hasAttributionData(){return null!=this.attributionDataUrl}get parsedUrl(){const e=this.url;return e?(0,c.mN)(e):null}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,i.default)(e,{query:{f:"json"},responseType:"json"})).data;throw new o.Z("layer:no-attribution-data","Layer does not have attribution data")}};(0,s._)([(0,h.Cb)({type:String})],v.prototype,"attributionDataUrl",void 0),(0,s._)([(0,h.Cb)({type:m.Z})],v.prototype,"fullExtent",void 0),(0,s._)([(0,h.Cb)({readOnly:!0})],v.prototype,"hasAttributionData",null),(0,s._)([(0,h.Cb)({type:String,clonable:!1})],v.prototype,"id",void 0),(0,s._)([(0,h.Cb)({type:Boolean,nonNullable:!0})],v.prototype,"legendEnabled",void 0),(0,s._)([(0,h.Cb)({type:["show","hide","hide-children"]})],v.prototype,"listMode",void 0),(0,s._)([(0,h.Cb)({type:Number,range:{min:0,max:1},nonNullable:!0})],v.prototype,"opacity",void 0),(0,s._)([(0,h.Cb)({clonable:!1})],v.prototype,"parent",void 0),(0,s._)([(0,h.Cb)({readOnly:!0})],v.prototype,"parsedUrl",null),(0,s._)([(0,h.Cb)({type:Boolean})],v.prototype,"popupEnabled",void 0),(0,s._)([(0,h.Cb)({type:Boolean})],v.prototype,"attributionVisible",void 0),(0,s._)([(0,h.Cb)({type:g.Z})],v.prototype,"spatialReference",void 0),(0,s._)([(0,h.Cb)({type:String})],v.prototype,"title",void 0),(0,s._)([(0,h.Cb)({readOnly:!0,json:{read:!1}})],v.prototype,"type",void 0),(0,s._)([(0,h.Cb)()],v.prototype,"url",void 0),(0,s._)([(0,h.Cb)({type:Boolean,nonNullable:!0})],v.prototype,"visible",void 0),v=(0,s._)([(0,d.j)("esri.layers.Layer")],v);const S=v},24109:(e,t,r)=>{r.r(t),r.d(t,{default:()=>ue});var s=r(43697),i=r(3172),o=r(20102),l=r(22974),n=r(70586),a=r(16453),u=r(95330),p=r(17452),c=r(5600),h=(r(75215),r(71715)),d=r(52011),y=r(30556),f=r(6570),m=r(82971),g=r(87085),_=r(54295),v=r(46486),S=r(17287),w=r(71612),b=r(17017),A=r(38009),x=r(16859),E=r(72965);let C=null;const I=r(92604).Z.getLogger("esri.layers.support.SpriteSource");class U{constructor(e,t,r,s){this.baseURL=e,this.devicePixelRatio=t,this.maxTextureSize=r,this._spriteImageFormat=s,this._isRetina=!1,this._spritesData={},this.image=null,this.width=null,this.height=null,this.loadStatus="not-loaded"}get spriteNames(){const e=[];for(const t in this._spritesData)e.push(t);return e.sort(),e}getSpriteInfo(e){return this._spritesData[e]}async load(e){if(this.baseURL){this.loadStatus="loading";try{await this._loadSprites(e),this.loadStatus="loaded"}catch{this.loadStatus="failed"}}else this.loadStatus="failed"}_loadSprites(e){this._isRetina=this.devicePixelRatio>1.15;const t=(0,p.mN)(this.baseURL),r=t.query?"?"+(0,p.B7)(t.query):"",s=this._isRetina?"@2x":"",l=`${t.path}${s}.${this._spriteImageFormat}${r}`,n=`${t.path}${s}.json${r}`;return Promise.all([(0,i.default)(n,e),(0,i.default)(l,{responseType:"image",...e})]).then((([e,r])=>{const s=Object.keys(e.data);if(!s||0===s.length||1===s.length&&"_ssl"===s[0]||!r||!r.data)return this._spritesData=this.image=null,this.width=this.height=0,null;this._spritesData=e.data;const i=r.data,l=Math.max(this.maxTextureSize,4096);if(i.width>l||i.height>l){const e=`Sprite resource for style ${t.path} is bigger than the maximum allowed of ${l} pixels}`;throw I.error(e),new o.Z("SpriteSource",e)}this.width=i.width,this.height=i.height;const n=document.createElement("canvas"),a=n.getContext("2d");n.width=i.width,n.height=i.height,a.drawImage(i,0,0,i.width,i.height);const u=a.getImageData(0,0,i.width,i.height),p=new Uint8Array(u.data);let c;for(let e=0;e<p.length;e+=4)c=p[e+3]/255,p[e]=p[e]*c,p[e+1]=p[e+1]*c,p[e+2]=p[e+2]*c;this.image=p}))}}var O=r(11145),T=r(68773),L=r(45322),B=r(56608),R=r(55415);class M{constructor(e){this.url=e}async fetchTileIndex(){return this._tileIndexPromise||(this._tileIndexPromise=(0,i.default)(this.url).then((e=>e.data.index))),this._tileIndexPromise}async dataKey(e,t){const r=await this.fetchTileIndex();return(0,u.k_)(t),this._getIndexedDataKey(r,e)}_getIndexedDataKey(e,t){const r=[t];if(t.level<0||t.row<0||t.col<0||t.row>>t.level>0||t.col>>t.level>0)return null;let s=t;for(;0!==s.level;)s=new R.Z(s.level-1,s.row>>1,s.col>>1,s.world),r.push(s);let i,o,l=e,n=r.pop();if(1===l)return n;for(;r.length;)if(i=r.pop(),o=(1&i.col)+((1&i.row)<<1),l){if(0===l[o]){n=null;break}if(1===l[o]){n=i;break}n=i,l=l[o]}return n}}class P{constructor(e,t){this._tilemap=e,this._tileIndexUrl=t}async fetchTileIndex(e){return this._tileIndexPromise||(this._tileIndexPromise=(0,i.default)(this._tileIndexUrl,{query:{...e?.query}}).then((e=>e.data.index))),this._tileIndexPromise}dataKey(e,t){const{level:r,row:s,col:i}=e,o=new R.Z(e);return this._tilemap.fetchAvailabilityUpsample(r,s,i,o,t).then((()=>(o.world=e.world,o))).catch((e=>{if((0,u.D_)(e))throw e;return null}))}}const D=new Map;class j{constructor(e,t,r){this.tilemap=null,this.tileInfo=null,this.capabilities=null,this.fullExtent=null,this.name=e,this.sourceUrl=t;const s=(0,p.mN)(this.sourceUrl),i=(0,l.d9)(r),o=i.tiles;if(s)for(let e=0;e<o.length;e++){const t=(0,p.mN)(o[e]);t&&((0,p.YP)(t.path)||(t.path=(0,p.v_)(s.path,t.path)),o[e]=(0,p.fl)(t.path,{...s.query,...t.query}))}this.tileServers=o;const n=r.capabilities&&r.capabilities.split(",").map((e=>e.toLowerCase().trim())),a=!0===r?.exportTilesAllowed,u=!0===n?.includes("tilemap"),c=a&&r.hasOwnProperty("maxExportTilesCount")?r.maxExportTilesCount:0;this.capabilities={operations:{supportsExportTiles:a,supportsTileMap:u},exportTiles:a?{maxExportTilesCount:+c}:null},this.tileInfo=(0,L.d)(i.tileInfo,i,null,{ignoreMinMaxLOD:!0});const h=r.tileMap?(0,p.fl)((0,p.v_)(s.path,r.tileMap),s.query):null;u?(this.type="vector-tile",this.tilemap=new P(new B.y({layer:{parsedUrl:s,tileInfo:this.tileInfo,type:"vector-tile",tileServers:this.tileServers}}),h)):h&&(this.tilemap=new M(h)),this.fullExtent=f.Z.fromJSON(r.fullExtent)}destroy(){}async getRefKey(e,t){return this.tilemap?.dataKey(e,t)??e}requestTile(e,t,r,s){return function(e,t,r,s,o){return function(e,t){const r=D.get(e);if(r)return r.then((e=>(0,l.d9)(e)));const s=(0,i.default)(e,{responseType:"array-buffer",...t}).then((({data:t})=>(D.delete(e),t))).catch((t=>{throw D.delete(e),t}));return D.set(e,s),s}(e.replace(/\{z\}/gi,t.toString()).replace(/\{y\}/gi,r.toString()).replace(/\{x\}/gi,s.toString()),o)}(this.tileServers[t%this.tileServers.length],e,t,r,s)}isCompatibleWith(e){const t=this.tileInfo,r=e.tileInfo;if(!t.spatialReference.equals(r.spatialReference))return!1;if(!t.origin.equals(r.origin))return!1;if(Math.round(t.dpi)!==Math.round(r.dpi))return!1;const s=t.lods,i=r.lods,o=Math.min(s.length,i.length);for(let e=0;e<o;e++){const t=s[e],r=i[e];if(t.level!==r.level||Math.round(t.scale)!==Math.round(r.scale))return!1}return!0}}const k=T.Z.defaults&&T.Z.defaults.io.corsEnabledServers;function N(e){if(!e)return;const t=(0,p.P$)(e);k&&!k.includes(t)&&k.push(t)}function G(...e){let t;for(let r=0;r<e.length;++r)if((0,p.oC)(e[r])){if(t){const s=t.split("://")[0];t=s+":"+e[r].trim()}}else t=(0,p.YP)(e[r])?e[r]:(0,p.v_)(t,e[r]);return(0,p.Qj)(t)}async function W(e,t,r,s,o){let l,n,a;if((0,u.k_)(o),"string"==typeof r){const e=(0,p.Fv)(r);N(e),a=await(0,i.default)(e,{...o,responseType:"json",query:{f:"json",...o?.query}}),a.ssl&&(l&&(l=l.replace(/^http:/i,"https:")),n&&(n=n.replace(/^http:/i,"https:"))),l=e,n=e}else a={data:r},l=r.jsonUrl||null,n=s;const c=a.data;if(F(c))return e.styleUrl=l||null,async function(e,t,r,s){const i=r?(0,p.Yd)(r):(0,p.L)();e.styleBase=i,e.style=t,e.styleUrl&&N(e.styleUrl),t["sprite-format"]&&"webp"===t["sprite-format"].toLowerCase()&&(e.spriteFormat="webp");const o=[];if(t.sources&&t.sources.esri){const r=t.sources.esri;r.url?await W(e,"esri",G(i,r.url),void 0,s):o.push(W(e,"esri",r,i,s))}for(const r of Object.keys(t.sources))"esri"!==r&&"vector"===t.sources[r].type&&(t.sources[r].url?o.push(W(e,r,G(i,t.sources[r].url),void 0,s)):t.sources[r].tiles&&o.push(W(e,r,t.sources[r],i,s)));await Promise.all(o)}(e,c,n,o);if(function(e){return!F(e)}(c))return e.sourceUrl?Z(e,c,n,!1,t,o):(e.sourceUrl=l||null,Z(e,c,n,!0,t,o));throw new Error("You must specify the URL or the JSON for a service or for a style.")}function F(e){return!!e.sources}async function Z(e,t,r,s,i,o){const l=r?(0,p.Qj)(r)+"/":(0,p.L)(),n=function(e,t){if(e.hasOwnProperty("tileInfo"))return e;const r={xmin:-20037507.067161843,ymin:-20037507.067161843,xmax:20037507.067161843,ymax:20037507.067161843,spatialReference:{wkid:102100}};let s=78271.51696400007,i=295828763.7957775;const o=[],l=e.hasOwnProperty("minzoom")?+e.minzoom:0,n=e.hasOwnProperty("maxzoom")?+e.maxzoom:22;for(let e=0;e<=n;e++)e>=l&&o.push({level:e,scale:i,resolution:s}),s/=2,i/=2;for(const r of e.tiles)N(G(t,r));return{capabilities:"TilesOnly",initialExtent:r,fullExtent:r,minScale:0,maxScale:0,tiles:e.tiles,tileInfo:{rows:512,cols:512,dpi:96,format:"pbf",origin:{x:-20037508.342787,y:20037508.342787},lods:o,spatialReference:{wkid:102100}}}}(t,l),a=new j(i,(0,p.fl)(l,o?.query),n);if(!s&&e.primarySourceName in e.sourceNameToSource){const t=e.sourceNameToSource[e.primarySourceName];if(!t.isCompatibleWith(a))return;null!=a.fullExtent&&(null!=t.fullExtent?t.fullExtent.union(a.fullExtent):t.fullExtent=a.fullExtent.clone()),t.tileInfo.lods.length<a.tileInfo.lods.length&&(t.tileInfo=a.tileInfo)}if(s?(e.sourceBase=l,e.source=t,e.validatedSource=n,e.primarySourceName=i,e.sourceUrl&&N(e.sourceUrl)):N(l),e.sourceNameToSource[i]=a,!e.style){if(null==t.defaultStyles)throw new Error;return"string"==typeof t.defaultStyles?W(e,"",G(l,t.defaultStyles,"root.json"),void 0,o):W(e,"",t.defaultStyles,G(l,"root.json"),o)}}var $=r(33516);const V=/^https:\/\/([a-z\d-]+)(\.maps([^.]*))?\.arcgis\.com/i,q={devext:{customBaseUrl:"mapsdevext.arcgis.com",portalHostname:"devext.arcgis.com"},qaext:{customBaseUrl:"mapsqa.arcgis.com",portalHostname:"qaext.arcgis.com"},www:{customBaseUrl:"maps.arcgis.com",portalHostname:"www.arcgis.com"}};function z(e){const t=e?.match(V);if(!t)return null;const[,r,s,i]=t;if(!r)return null;let o=null,l=null,n=null;const{devext:a,qaext:u,www:p}=q;if(s)if(o=r,i)switch(i.toLowerCase()){case"devext":({customBaseUrl:l,portalHostname:n}=a);break;case"qa":({customBaseUrl:l,portalHostname:n}=u);break;default:return null}else({customBaseUrl:l,portalHostname:n}=p);else switch(r.toLowerCase()){case"devext":({customBaseUrl:l,portalHostname:n}=a);break;case"qaext":({customBaseUrl:l,portalHostname:n}=u);break;case"www":({customBaseUrl:l,portalHostname:n}=p);break;default:return null}return{customBaseUrl:l,isPortal:!1,portalHostname:n,urlKey:o}}var K=r(25929);const H=1e-6;function Q(e,t){if(e===t)return!0;if(!e&&null!=t)return!1;if(null!=e&&!t)return!1;if(!e.spatialReference.equals(t.spatialReference)||e.dpi!==t.dpi)return!1;const r=e.origin,s=t.origin;if(Math.abs(r.x-s.x)>=H||Math.abs(r.y-s.y)>=H)return!1;let i,o;e.lods[0].scale>t.lods[0].scale?(i=e,o=t):(o=e,i=t);for(let e=i.lods[0].scale;e>=o.lods[o.lods.length-1].scale-H;e/=2)if(Math.abs(e-o.lods[0].scale)<H)return!0;return!1}function J(e,t){if(e===t)return e;if(!e&&null!=t)return t;if(null!=e&&!t)return e;const r=e.size[0],s=e.format,i=e.dpi,o={x:e.origin.x,y:e.origin.y},l=e.spatialReference.toJSON(),n=e.lods[0].scale>t.lods[0].scale?e.lods[0]:t.lods[0],a=e.lods[e.lods.length-1].scale<=t.lods[t.lods.length-1].scale?e.lods[e.lods.length-1]:t.lods[t.lods.length-1],u=n.scale,p=n.resolution,c=a.scale,h=[];let d=u,y=p,f=0;for(;d>c;)h.push({level:f,resolution:y,scale:d}),f++,d/=2,y/=2;return new O.Z({size:[r,r],dpi:i,format:s||"pbf",origin:o,lods:h,spatialReference:l})}var X=r(51785),Y=r(54738);let ee,te;function re(e){const t=(0,Y.Sh)(e);for(;t.length>1;){const e=se(t.shift());if(e.available)return e}return se(t.shift())}function se(e){switch(e){case Y.zO.WEBGL1:return ee||(ee=function(){const e=new oe,t=ne(Y.zO.WEBGL1,e);return(0,n.Wi)(t)||(e.supportsElementIndexUint=null!==t.getExtension("OES_element_index_uint"),e.supportsStandardDerivatives=null!==t.getExtension("OES_standard_derivatives"),e.supportsInstancedArrays=null!==t.getExtension("ANGLE_instanced_arrays"),e.supportsTextureFloat=null!==t.getExtension("OES_texture_float"),e.supportsTextureHalfFloat=null!==t.getExtension("OES_texture_half_float"),e.supportsColorBufferFloat=null!==t.getExtension("WEBGL_color_buffer_float"),e.supportsColorBufferFloatBlend=null!==t.getExtension("EXT_float_blend"),e.supportsColorBufferHalfFloat=null!==t.getExtension("EXT_color_buffer_half_float")),e}()),ee;case Y.zO.WEBGL2:return te||(te=function(){const e=new le,t=ne(Y.zO.WEBGL2,e);return(0,n.Wi)(t)||(e.supportsColorBufferFloat=null!==t.getExtension("EXT_color_buffer_float"),e.supportsColorBufferFloatBlend=null!==t.getExtension("EXT_float_blend"),e.supportsColorBufferHalfFloat=e.supportsColorBufferFloat||null!==t.getExtension("EXT_color_buffer_half_float")),e}()),te}}class ie{constructor(){this.available=!1,this.majorPerformanceCaveat=!1,this.maxTextureSize=0,this.supportsVertexShaderSamplers=!1,this.supportsHighPrecisionFragment=!1,this.supportsElementIndexUint=!1,this.supportsStandardDerivatives=!1,this.supportsInstancedArrays=!1,this.supportsTextureFloat=!1,this.supportsTextureHalfFloat=!1,this.supportsColorBufferFloat=!1,this.supportsColorBufferFloatBlend=!1,this.supportsColorBufferHalfFloat=!1}}class oe extends ie{constructor(){super(...arguments),this.type=Y.zO.WEBGL1}}class le extends ie{constructor(){super(...arguments),this.type=Y.zO.WEBGL2,this.supportsElementIndexUint=!0,this.supportsStandardDerivatives=!0,this.supportsInstancedArrays=!0,this.supportsTextureFloat=!0,this.supportsTextureHalfFloat=!0}}function ne(e,t){if(e===Y.zO.WEBGL1&&void 0===typeof WebGLRenderingContext||e===Y.zO.WEBGL2&&void 0===typeof WebGL2RenderingContext)return null;const r=document.createElement("canvas");if(!r)return null;let s=(0,Y.kr)(r,e,{failIfMajorPerformanceCaveat:!0});if((0,n.Wi)(s)&&(s=(0,Y.kr)(r,e),(0,n.pC)(s)&&(t.majorPerformanceCaveat=!0)),(0,n.Wi)(s))return s;if(e===Y.zO.WEBGL1){const e=s.getParameter(s.VERSION)?.match(/^WebGL\s+([\d.]*)/);if(e){const r=parseFloat(e[1]);t.available=r>=.94}}else t.available=!0;t.maxTextureSize=s.getParameter(s.MAX_TEXTURE_SIZE),t.supportsVertexShaderSamplers=s.getParameter(s.MAX_VERTEX_TEXTURE_IMAGE_UNITS)>0;const i=s.getShaderPrecisionFormat(s.FRAGMENT_SHADER,s.HIGH_FLOAT);return i&&(t.supportsHighPrecisionFragment=i.precision>0),s}let ae=class extends((0,w.h)((0,E.M)((0,v.Z)((0,S.Y)((0,A.q)((0,x.I)((0,b.N)((0,_.V)((0,a.R)(g.Z)))))))))){constructor(...e){super(...e),this._spriteSourceMap=new Map,this.currentStyleInfo=null,this.style=null,this.isReference=null,this.operationalLayerType="VectorTileLayer",this.type="vector-tile",this.url=null,this.symbolCollisionBoxesVisible=!1,this.path=null}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}destroy(){if(this.sourceNameToSource)for(const e of Object.values(this.sourceNameToSource))e?.destroy();this._spriteSourceMap.clear()}async prefetchResources(e){await this.loadSpriteSource(globalThis.devicePixelRatio||1,e)}load(e){const t=this.loadFromPortal({supportedTypes:["Vector Tile Service"],supportsData:!1},e).catch(u.r9).then((async()=>{if(!this.portalItem||!this.portalItem.id)return;const t=`${this.portalItem.itemUrl}/resources/styles/root.json`;(await(0,i.default)(t,{...e,query:{f:"json",...this.customParameters,token:this.apiKey}})).data&&this.read({url:t},(0,$.h)(this.portalItem))})).catch(u.r9).then((()=>this._loadStyle(e)));return this.addResolvingPromise(t),Promise.resolve(this)}get attributionDataUrl(){const e=this.currentStyleInfo,t=e&&e.serviceUrl&&(0,p.mN)(e.serviceUrl);if(!t)return null;const r=this._getDefaultAttribution(t.path);return r?(0,p.fl)(r,{...this.customParameters,token:this.apiKey}):null}get capabilities(){const e=this.primarySource;return e?e.capabilities:{operations:{supportsExportTiles:!1,supportsTileMap:!1},exportTiles:null}}get fullExtent(){return this.primarySource?.fullExtent||null}get parsedUrl(){return this.serviceUrl?(0,p.mN)(this.serviceUrl):null}get serviceUrl(){return this.currentStyleInfo&&this.currentStyleInfo.serviceUrl||null}get spatialReference(){return this.tileInfo&&this.tileInfo.spatialReference||null}get styleUrl(){return this.currentStyleInfo&&this.currentStyleInfo.styleUrl||null}writeStyleUrl(e,t){e&&(0,p.oC)(e)&&(e=`https:${e}`);const r=(0,n.Wg)(z(e));t.styleUrl=(0,K.e)(e,r)}get tileInfo(){const e=[];for(const t in this.sourceNameToSource)e.push(this.sourceNameToSource[t]);let t=this.primarySource?.tileInfo||new O.Z;if(e.length>1)for(let r=0;r<e.length;r++)Q(t,e[r].tileInfo)&&(t=J(t,e[r].tileInfo));return t}readVersion(e,t){return t.version?parseFloat(t.version):parseFloat(t.currentVersion)}async loadSpriteSource(e=1,t){if(!this._spriteSourceMap.has(e)){const r=re("2d").maxTextureSize,s=this.currentStyleInfo?.spriteUrl?(0,p.fl)(this.currentStyleInfo.spriteUrl,{...this.customParameters,token:this.apiKey}):null,i=new U(s,e,r,this.currentStyleInfo.spriteFormat);await i.load(t),this._spriteSourceMap.set(e,i)}return this._spriteSourceMap.get(e)}async setSpriteSource(e,t="png",r=1,s){const i=re("2d").maxTextureSize,o=e?(0,p.fl)(e,{...this.customParameters,token:this.apiKey}):null;if(!o)return null;const l=new U(o,r,i,t);try{return await l.load(s),this._spriteSourceMap.clear(),this._spriteSourceMap.set(r,l),this.currentStyleInfo.spriteUrl=o,this.emit("spriteSource-change",{spriteSource:l}),l}catch(e){(0,u.r9)(e)}return null}async loadStyle(e,t){const r=e||this.style||this.url;return this._loadingTask&&"string"==typeof r&&this.url===r||(this._loadingTask?.abort(),this._loadingTask=(0,u.vr)((e=>(this._spriteSourceMap.clear(),this._getSourceAndStyle(r,{signal:e}))),t)),this._loadingTask.promise}getStyleLayerId(e){return this.styleRepository.getStyleLayerId(e)}getStyleLayerIndex(e){return this.styleRepository.getStyleLayerIndex(e)}getPaintProperties(e){return(0,l.d9)(this.styleRepository.getPaintProperties(e))}setPaintProperties(e,t){const r=this.styleRepository.isPainterDataDriven(e);this.styleRepository.setPaintProperties(e,t);const s=this.styleRepository.isPainterDataDriven(e);this.emit("paint-change",{layer:e,paint:t,isDataDriven:r||s})}getStyleLayer(e){return(0,l.d9)(this.styleRepository.getStyleLayer(e))}setStyleLayer(e,t){this.styleRepository.setStyleLayer(e,t),this.emit("style-layer-change",{layer:e,index:t})}deleteStyleLayer(e){this.styleRepository.deleteStyleLayer(e),this.emit("delete-style-layer",{layer:e})}getLayoutProperties(e){return(0,l.d9)(this.styleRepository.getLayoutProperties(e))}setLayoutProperties(e,t){this.styleRepository.setLayoutProperties(e,t),this.emit("layout-change",{layer:e,layout:t})}setStyleLayerVisibility(e,t){this.styleRepository.setStyleLayerVisibility(e,t),this.emit("style-layer-visibility-change",{layer:e,visibility:t})}getStyleLayerVisibility(e){return this.styleRepository.getStyleLayerVisibility(e)}write(e,t){return t?.origin&&!this.styleUrl?(t.messages&&t.messages.push(new o.Z("vectortilelayer:unsupported",`VectorTileLayer (${this.title}, ${this.id}) with style defined by JSON only are not supported`,{layer:this})),null):super.write(e,t)}getTileUrl(e,t,r){return null}async _getSourceAndStyle(e,t){if(!e)throw new Error("invalid style!");const r=await async function(e,t){const r={source:null,sourceBase:null,sourceUrl:null,validatedSource:null,style:null,styleBase:null,styleUrl:null,sourceNameToSource:{},primarySourceName:"",spriteFormat:"png"},[s,i]="string"==typeof e?[e,null]:[null,e.jsonUrl];await W(r,"esri",e,i,t);const o={layerDefinition:r.validatedSource,url:s,serviceUrl:r.sourceUrl,style:r.style,styleUrl:r.styleUrl,spriteUrl:r.style.sprite&&G(r.styleBase,r.style.sprite),spriteFormat:r.spriteFormat,glyphsUrl:r.style.glyphs&&G(r.styleBase,r.style.glyphs),sourceNameToSource:r.sourceNameToSource,primarySourceName:r.primarySourceName};return N(o.spriteUrl),N(o.glyphsUrl),o}(e,{...t,query:{...this.customParameters,token:this.apiKey}});"webp"===r.spriteFormat&&(await function(e){if(C)return C;const t={lossy:"UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA",lossless:"UklGRhoAAABXRUJQVlA4TA0AAAAvAAAAEAcQERGIiP4HAA==",alpha:"UklGRkoAAABXRUJQVlA4WAoAAAAQAAAAAAAAAAAAQUxQSAwAAAARBxAR/Q9ERP8DAABWUDggGAAAABQBAJ0BKgEAAQAAAP4AAA3AAP7mtQAAAA==",animation:"UklGRlIAAABXRUJQVlA4WAoAAAASAAAAAAAAAAAAQU5JTQYAAAD/////AABBTk1GJgAAAAAAAAAAAAAAAAAAAGQAAABWUDhMDQAAAC8AAAAQBxAREYiI/gcA"};return C=new Promise((e=>{const r=new Image;r.onload=()=>{r.onload=r.onerror=null,e(r.width>0&&r.height>0)},r.onerror=()=>{r.onload=r.onerror=null,e(!1)},r.src="data:image/webp;base64,"+t.lossy})),C}()||(r.spriteFormat="png")),this._set("currentStyleInfo",{...r}),"string"==typeof e?(this.url=e,this.style=null):(this.url=null,this.style=e),this._set("sourceNameToSource",r.sourceNameToSource),this._set("primarySource",r.sourceNameToSource[r.primarySourceName]),this._set("styleRepository",new X.Z(r.style)),this.read(r.layerDefinition,{origin:"service"}),this.emit("load-style")}_getDefaultAttribution(e){const t=e.match(/^https?:\/\/(?:basemaps|basemapsbeta|basemapsdev)(?:-api)?\.arcgis\.com(\/[^\/]+)?\/arcgis\/rest\/services\/([^\/]+(\/[^\/]+)*)\/vectortileserver/i),r=["OpenStreetMap_v2","OpenStreetMap_Daylight_v2","OpenStreetMap_Export_v2","OpenStreetMap_FTS_v2","OpenStreetMap_GCS_v2","World_Basemap","World_Basemap_v2","World_Basemap_Export_v2","World_Basemap_GCS_v2","World_Basemap_WGS84","World_Contours_v2"];if(!t)return;const s=t[2]&&t[2].toLowerCase();if(!s)return;const i=t[1]||"";for(const e of r)if(e.toLowerCase().includes(s))return(0,p.Fv)(`//static.arcgis.com/attribution/Vector${i}/${e}`)}async _loadStyle(e){return this._loadingTask?.promise??this.loadStyle(null,e)}};(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"attributionDataUrl",null),(0,s._)([(0,c.Cb)({type:["show","hide"]})],ae.prototype,"listMode",void 0),(0,s._)([(0,c.Cb)({json:{read:!0,write:!0}})],ae.prototype,"blendMode",void 0),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],ae.prototype,"capabilities",null),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"currentStyleInfo",void 0),(0,s._)([(0,c.Cb)({json:{read:!1},readOnly:!0,type:f.Z})],ae.prototype,"fullExtent",null),(0,s._)([(0,c.Cb)()],ae.prototype,"style",void 0),(0,s._)([(0,c.Cb)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],ae.prototype,"isReference",void 0),(0,s._)([(0,c.Cb)({type:["VectorTileLayer"]})],ae.prototype,"operationalLayerType",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"parsedUrl",null),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"serviceUrl",null),(0,s._)([(0,c.Cb)({type:m.Z,readOnly:!0})],ae.prototype,"spatialReference",null),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"styleRepository",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"sourceNameToSource",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"primarySource",void 0),(0,s._)([(0,c.Cb)({type:String,readOnly:!0,json:{write:{ignoreOrigin:!0},origins:{"web-document":{write:{ignoreOrigin:!0,isRequired:!0}}}}})],ae.prototype,"styleUrl",null),(0,s._)([(0,y.c)(["portal-item","web-document"],"styleUrl")],ae.prototype,"writeStyleUrl",null),(0,s._)([(0,c.Cb)({json:{read:!1,origins:{service:{read:!1}}},readOnly:!0,type:O.Z})],ae.prototype,"tileInfo",null),(0,s._)([(0,c.Cb)({json:{read:!1},readOnly:!0,value:"vector-tile"})],ae.prototype,"type",void 0),(0,s._)([(0,c.Cb)({json:{origins:{"web-document":{read:{source:"styleUrl"}},"portal-item":{read:{source:"url"}}},write:!1,read:!1}})],ae.prototype,"url",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ae.prototype,"version",void 0),(0,s._)([(0,h.r)("version",["version","currentVersion"])],ae.prototype,"readVersion",null),(0,s._)([(0,c.Cb)({type:Boolean})],ae.prototype,"symbolCollisionBoxesVisible",void 0),(0,s._)([(0,c.Cb)({type:String,json:{origins:{"web-scene":{read:!0,write:!0}},read:!1}})],ae.prototype,"path",void 0),ae=(0,s._)([(0,d.j)("esri.layers.VectorTileLayer")],ae);const ue=ae},54295:(e,t,r)=>{r.d(t,{V:()=>l});var s=r(43697),i=r(5600),o=(r(67676),r(80442),r(75215),r(52011));const l=e=>{let t=class extends e{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,s._)([(0,i.Cb)({type:String})],t.prototype,"apiKey",null),t=(0,s._)([(0,o.j)("esri.layers.mixins.APIKeyMixin")],t),t}},46486:(e,t,r)=>{r.d(t,{Z:()=>p});var s=r(43697),i=(r(66577),r(5600)),o=(r(67676),r(80442),r(75215),r(71715)),l=r(52011),n=r(45322),a=r(56608),u=r(82971);const p=e=>{let t=class extends e{constructor(){super(...arguments),this.copyright=null,this.minScale=0,this.maxScale=0,this.spatialReference=null,this.tileInfo=null,this.tilemapCache=null}readMinScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}readMaxScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}get supportsBlankTile(){return this.version>=10.2}readTilemapCache(e,t){return t.capabilities&&t.capabilities.includes("Tilemap")?new a.y({layer:this}):null}};return(0,s._)([(0,i.Cb)({json:{read:{source:"copyrightText"}}})],t.prototype,"copyright",void 0),(0,s._)([(0,i.Cb)()],t.prototype,"minScale",void 0),(0,s._)([(0,o.r)("service","minScale")],t.prototype,"readMinScale",null),(0,s._)([(0,i.Cb)()],t.prototype,"maxScale",void 0),(0,s._)([(0,o.r)("service","maxScale")],t.prototype,"readMaxScale",null),(0,s._)([(0,i.Cb)({type:u.Z})],t.prototype,"spatialReference",void 0),(0,s._)([(0,i.Cb)({readOnly:!0})],t.prototype,"supportsBlankTile",null),(0,s._)([(0,i.Cb)(n.h)],t.prototype,"tileInfo",void 0),(0,s._)([(0,i.Cb)()],t.prototype,"tilemapCache",void 0),(0,s._)([(0,o.r)("service","tilemapCache",["capabilities"])],t.prototype,"readTilemapCache",null),(0,s._)([(0,i.Cb)()],t.prototype,"version",void 0),t=(0,s._)([(0,l.j)("esri.layers.mixins.ArcGISCachedService")],t),t}},17287:(e,t,r)=>{r.d(t,{Y:()=>u});var s=r(43697),i=r(92604),o=r(70586),l=r(5600),n=(r(67676),r(80442),r(75215),r(52011)),a=r(66677);const u=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,a.Qc)(this.url);if((0,o.pC)(e)&&e.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,a.Nm)(e,i.Z.getLogger(this.declaredClass)))}};return(0,s._)([(0,l.Cb)()],t.prototype,"title",null),(0,s._)([(0,l.Cb)({type:String})],t.prototype,"url",null),t=(0,s._)([(0,n.j)("esri.layers.mixins.ArcGISService")],t),t}},17017:(e,t,r)=>{r.d(t,{N:()=>l});var s=r(43697),i=r(5600),o=(r(67676),r(80442),r(75215),r(52011));const l=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,s._)([(0,i.Cb)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,s._)([(0,o.j)("esri.layers.mixins.CustomParametersMixin")],t),t}},33516:(e,t,r)=>{r.d(t,{Y:()=>l,h:()=>o});var s=r(17452),i=r(65587);function o(e){return{origin:"portal-item",url:(0,s.mN)(e.itemUrl),portal:e.portal||i.Z.getDefault(),portalItem:e,readResourcePaths:[]}}function l(e){return{origin:"portal-item",messages:[],writtenProperties:[],url:e.itemUrl?(0,s.mN)(e.itemUrl):null,portal:e.portal||i.Z.getDefault(),portalItem:e}}},55415:(e,t,r)=>{r.d(t,{Z:()=>i});var s=r(71143);class i{constructor(e,t,r,s){this.set(e,t,r,s)}static getId(e,t,r,s){return"object"==typeof e?`${e.level}/${e.row}/${e.col}/${e.world}`:`${e}/${t}/${r}/${s}`}get key(){return this}get id(){return this.toString()}set id(e){this.set(e)}get hash(){const e=4095&this.row,t=4095&this.col,r=63&this.level;return(3&this.world)<<30|t<<22|e<<8|r}acquire(e,t,r,s){this.set(e,t,r,s)}contains(e){const t=e.level-this.level;return this.row===e.row>>t&&this.col===e.col>>t&&this.world===e.world}equals(e){return this.level===e.level&&this.row===e.row&&this.col===e.col&&this.world===e.world}clone(){return new i(this)}release(){this.level=0,this.row=0,this.col=0,this.world=0}set(e,t,r,s){if(null==e)this.level=0,this.row=0,this.col=0,this.world=0;else if("object"==typeof e)this.level=e.level||0,this.row=e.row||0,this.col=e.col||0,this.world=e.world||0;else if("string"==typeof e){const[t,r,s,i]=e.split("/");this.level=parseFloat(t),this.row=parseFloat(r),this.col=parseFloat(s),this.world=parseFloat(i)}else this.level=+e,this.row=+t,this.col=+r,this.world=+s||0;return this}toString(){return`${this.level}/${this.row}/${this.col}/${this.world}`}getParentKey(){return this.level<=0?null:new i(this.level-1,this.row>>1,this.col>>1,this.world)}getChildKeys(){const e=this.level+1,t=this.row<<1,r=this.col<<1,s=this.world;return[new i(e,t,r,s),new i(e,t,r+1,s),new i(e,t+1,r,s),new i(e,t+1,r+1,s)]}compareRowMajor(e){return this.row<e.row?-1:this.row>e.row?1:this.col<e.col?-1:this.col>e.col?1:0}}i.pool=new s.Z(i,null,null,25,50)},54738:(e,t,r)=>{r.d(t,{Sh:()=>l,kr:()=>n,zO:()=>s});var s,i,o=r(80442);function l(e){const t=(0,o.Z)("esri-force-webgl");if(t===s.WEBGL1||t===s.WEBGL2)return[t];switch(e){case"2d":return(0,o.Z)("mac")?[s.WEBGL1,s.WEBGL2]:[s.WEBGL2,s.WEBGL1];case"3d":return[s.WEBGL2,s.WEBGL1]}}function n(e,t,r={}){const i=t===s.WEBGL1?["webgl","experimental-webgl","webkit-3d","moz-webgl"]:["webgl2"];let o=null;for(const t of i){try{o=e.getContext(t,r)}catch(e){}if(o)break}return o}(i=s||(s={}))[i.WEBGL1=1]="WEBGL1",i[i.WEBGL2=2]="WEBGL2"}}]);
|