@arcgis/core 4.32.0-next.20241021 → 4.32.0-next.20241022

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.
Files changed (95) hide show
  1. package/applications/MapViewer/templateUtils.d.ts +4 -0
  2. package/applications/MapViewer/templateUtils.js +5 -0
  3. package/assets/esri/core/workers/RemoteClient.js +1 -1
  4. package/assets/esri/core/workers/chunks/{1ba1d9c867ec6a492af9.js → 0f3912bca9fe25eea75c.js} +1 -1
  5. package/assets/esri/core/workers/chunks/{842ebde78db9bfcaf07b.js → 1678d1d0ecb9b2af69a8.js} +1 -1
  6. package/assets/esri/core/workers/chunks/1d16ca7791f64dd7c7fb.js +1 -0
  7. package/assets/esri/core/workers/chunks/{b292758308dfac4ba8ee.js → 2d8aa31dc96bbd014036.js} +1 -1
  8. package/assets/esri/core/workers/chunks/{88bd9e023764da377aa7.js → 2ee26f77d8e8c15a51ea.js} +1 -1
  9. package/assets/esri/core/workers/chunks/{53f648321c5fde26bfe4.js → 319e06888467f9f460ab.js} +1 -1
  10. package/assets/esri/core/workers/chunks/{303f39b9b7bd33109df8.js → 587df97288a83721d251.js} +1 -1
  11. package/assets/esri/core/workers/chunks/5caa02a7a85d05e253b4.js +1 -0
  12. package/assets/esri/core/workers/chunks/5cfecb320e1dcd258b2e.js +1 -0
  13. package/assets/esri/core/workers/chunks/67018ef25736f0722f6e.js +1 -0
  14. package/assets/esri/core/workers/chunks/{03eba36affe6ed1f5a11.js → 757fe331381da1b7edad.js} +2 -2
  15. package/assets/esri/core/workers/chunks/772cc80923d5e2c6436d.js +1 -0
  16. package/assets/esri/core/workers/chunks/89f74819ac1b5884c149.js +1 -0
  17. package/assets/esri/core/workers/chunks/92b2d81ef16877341f97.js +1 -0
  18. package/assets/esri/core/workers/chunks/{e6e77cbdeb99d90caad1.js → 97f62fad6d416a666319.js} +1 -1
  19. package/assets/esri/core/workers/chunks/{63719f892a7d1025c7d3.js → b42c1ab7579a3c464f72.js} +1 -1
  20. package/assets/esri/core/workers/chunks/{c71304c88fce556340ef.js → c859f73b57a764e99b02.js} +1 -1
  21. package/assets/esri/core/workers/chunks/e71fa25ed45bae5a1adb.js +320 -0
  22. package/core/MemCache.js +1 -1
  23. package/core/MemCachePool.js +1 -1
  24. package/geometry/Mesh.js +1 -1
  25. package/geometry/support/MeshVertexAttributes.js +1 -1
  26. package/interfaces.d.ts +128 -0
  27. package/layers/LinkChartLayer.js +1 -1
  28. package/layers/SceneLayer.js +1 -1
  29. package/layers/knowledgeGraph/supportUtils.js +1 -1
  30. package/layers/support/ElevationQueryTileCache.js +1 -1
  31. package/layers/support/ElevationTileData.js +1 -1
  32. package/layers/support/mediaUtils.js +1 -1
  33. package/layers/support/rasterFunctions/ClipFunction.js +1 -1
  34. package/layers/support/rasterFunctions/clipUtils.js +1 -1
  35. package/layers/support/rasterFunctions/localUtils.js +1 -1
  36. package/linkChart/LinkChartProperties.js +1 -1
  37. package/package.json +1 -1
  38. package/smartMapping/raster/renderers/classBreaks.js +1 -1
  39. package/smartMapping/raster/renderers/rgb.js +1 -1
  40. package/smartMapping/raster/renderers/stretch.js +1 -1
  41. package/smartMapping/raster/support/adapters/ImageryTileLayerAdapter.js +1 -1
  42. package/smartMapping/raster/support/adapters/RasterLayerAdapter.js +1 -1
  43. package/smartMapping/renderers/support/rendererUtils.d.ts +4 -0
  44. package/support/revision.js +1 -1
  45. package/views/2d/engine/vectorTiles/RenderBucket.js +1 -1
  46. package/views/2d/engine/vectorTiles/TileHandler3D.js +1 -1
  47. package/views/2d/engine/vectorTiles/VectorTile.js +1 -1
  48. package/views/2d/grid/GridView2D.js +1 -1
  49. package/views/2d/layers/FeatureLayerView2D.js +1 -1
  50. package/views/3d/camera/constraintUtils/tilt.js +1 -1
  51. package/views/3d/glTF/loader.js +1 -1
  52. package/views/3d/layers/I3SMeshView3D.js +1 -1
  53. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  54. package/views/3d/layers/PointCloudLayerView3D.js +1 -1
  55. package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
  56. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  57. package/views/3d/layers/graphics/Graphics3DSymbol.js +1 -1
  58. package/views/3d/layers/graphics/Graphics3DWebStyleSymbol.js +1 -1
  59. package/views/3d/layers/graphics/ObjectResourceCache.js +1 -1
  60. package/views/3d/layers/graphics/wosrLoader.js +1 -1
  61. package/views/3d/layers/i3s/CachedMeshData.js +5 -0
  62. package/views/3d/layers/i3s/I3SClientNodeLoader.js +1 -1
  63. package/views/3d/layers/i3s/I3SOverrides.js +1 -1
  64. package/views/3d/layers/i3s/PointRenderer.js +1 -1
  65. package/views/3d/layers/support/FeatureTile.js +1 -1
  66. package/views/3d/layers/support/FeatureTileFetcher3D.js +1 -1
  67. package/views/3d/support/buffer/InterleavedLayout.js +1 -1
  68. package/views/3d/terrain/Tile.js +1 -1
  69. package/views/3d/terrain/TileTexture.js +1 -1
  70. package/views/3d/webgl/ManagedFBO.js +1 -1
  71. package/views/3d/webgl/ManagedFBOAttachment.js +1 -1
  72. package/views/3d/webgl-engine/core/FBOCache.js +1 -1
  73. package/views/3d/webgl-engine/core/FBOPool.js +1 -1
  74. package/views/3d/webgl-engine/core/shaderLibrary/output/OutputHighlight.glsl.js +1 -1
  75. package/views/3d/webgl-engine/lib/edgeRendering/EdgeView.js +1 -1
  76. package/views/3d/webgl-engine/materials/ProceduralTextureRepository.js +1 -1
  77. package/views/3d/webgl-engine/materials/renderers/MergedRenderer.js +1 -1
  78. package/views/webgl/Texture.js +1 -1
  79. package/views/webgl/VertexArrayObject.js +1 -1
  80. package/webdoc/support/webdocSaveUtils.js +1 -1
  81. package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
  82. package/widgets/FeatureTable/Grid/GridViewModel.js +1 -1
  83. package/widgets/FeatureTable/support/columnUtils.js +1 -1
  84. package/widgets/FeatureTable/support/tableUtils.js +1 -1
  85. package/widgets/FeatureTable/support/templateUtils.js +5 -0
  86. package/widgets/support/GridControls/GridControlsViewModel.js +1 -1
  87. package/widgets/support/GridControls.js +1 -1
  88. package/assets/esri/core/workers/chunks/0c40cac18711f79f0a7d.js +0 -1
  89. package/assets/esri/core/workers/chunks/1a97f98facfc62a9fc69.js +0 -1
  90. package/assets/esri/core/workers/chunks/1fc064e37d030e449d5e.js +0 -1
  91. package/assets/esri/core/workers/chunks/77d129134c2a66cd86d8.js +0 -1
  92. package/assets/esri/core/workers/chunks/92ce57cb12d9a7a3699e.js +0 -1
  93. package/assets/esri/core/workers/chunks/a5675c989d00b7400f98.js +0 -1
  94. package/assets/esri/core/workers/chunks/c06c5c815b5e37717fa1.js +0 -1
  95. package/assets/esri/core/workers/chunks/ce8c1208916f54af7e68.js +0 -320
@@ -479,7 +479,7 @@ fragHighlight = combinedHighlight;
479
479
  }
480
480
  bool isHighlightOccluded() {
481
481
  float sceneDepth = texelFetch(depthTexture, ivec2(gl_FragCoord.xy), 0).x;
482
- return gl_FragCoord.z > sceneDepth + 5e-5;
482
+ return gl_FragCoord.z > sceneDepth + 5e-7;
483
483
  }
484
484
  void calculateOcclusionAndOutputHighlight() {
485
485
  outputHighlight(isHighlightOccluded());
@@ -985,4 +985,4 @@ return applyScreenSizePerspectiveScaleFactorVec2(size, screenSizePerspectiveScal
985
985
  calculateOcclusionAndOutputHighlight();
986
986
  ${(0,c.If)(r,"outputObjectAndLayerIdColor();")}
987
987
  }
988
- `)}},36421:(e,t,r)=>{var i;r.d(t,{p:()=>i}),function(e){e[e.Texture=0]="Texture",e[e.RenderBuffer=1]="RenderBuffer"}(i||(i={}))},21231:(e,t,r)=>{r.d(t,{g:()=>l});var i=r(49186),o=(r(44208),r(94656)),n=r(63907),a=r(36421),s=r(67171);class c extends s.R{constructor(e,t){switch(super(),this.context=e,Object.assign(this,t),this.internalFormat){case n.H0.R16F:case n.H0.R16I:case n.H0.R16UI:case n.H0.R32F:case n.H0.R32I:case n.H0.R32UI:case n.H0.R8_SNORM:case n.H0.R8:case n.H0.R8I:case n.H0.R8UI:this.pixelFormat=n.Ab.RED}}static validate(e,t){return new c(e,t)}}let l=class e{constructor(e,t=null,r=null){if(this.type=a.p.Texture,this._glName=null,this._samplingModeDirty=!1,this._wrapModeDirty=!1,this._wasImmutablyAllocated=!1,"context"in e)this._descriptor=e,r=t;else{const r=c.validate(e,t);if(!r)throw new i.A("Texture descriptor invalid");this._descriptor=r}this._descriptor.target===n.Ap.TEXTURE_CUBE_MAP?this._setDataCubeMap(r):this.setData(r)}get glName(){return this._glName}get descriptor(){return this._descriptor}get usedMemory(){return(0,s.e)(this._descriptor)}get isDirty(){return this._samplingModeDirty||this._wrapModeDirty}dispose(){this._glName&&this._descriptor.context.instanceCounter.decrement(n.vt.Texture,this),this._descriptor.context.gl&&this._glName&&(this._descriptor.context.unbindTexture(this),this._descriptor.context.gl.deleteTexture(this._glName),this._glName=null)}release(){this.dispose()}resize(e,t){const r=this._descriptor;if(r.width!==e||r.height!==t){if(this._wasImmutablyAllocated)throw new i.A("Immutable textures can't be resized!");r.width=e,r.height=t,this._descriptor.target===n.Ap.TEXTURE_CUBE_MAP?this._setDataCubeMap(null):this.setData(null)}}_setDataCubeMap(e=null){for(let t=n.Ap.TEXTURE_CUBE_MAP_POSITIVE_X;t<=n.Ap.TEXTURE_CUBE_MAP_NEGATIVE_Z;t++)this._setData(e,t)}setData(e){this._setData(e)}_setData(t,r){const a=this._descriptor.context?.gl;if(!a)return;(0,o.Y2)(a),this._glName||(this._glName=a.createTexture(),this._glName&&this._descriptor.context.instanceCounter.increment(n.vt.Texture,this));const s=this._descriptor,c=r??s.target,l=p(c),v=this._descriptor.context.bindTexture(this,e.TEXTURE_UNIT_FOR_UPDATES);this._descriptor.context.setActiveTexture(e.TEXTURE_UNIT_FOR_UPDATES),d(s),this._configurePixelStorage(),(0,o.Y2)(a);const _=this._deriveInternalFormat();if(f(t)){let e="width"in t?t.width:t.codedWidth,r="height"in t?t.height:t.codedHeight;const i=1;t instanceof HTMLVideoElement&&(e=t.videoWidth,r=t.videoHeight),s.width&&s.height,l&&s.depth,s.isImmutable&&!this._wasImmutablyAllocated&&this._texStorage(c,_,s.hasMipmap,e,r,i),this._texImage(c,0,_,e,r,i,t),(0,o.Y2)(a),s.hasMipmap&&(this.generateMipmap(),(0,o.Y2)(a)),s.width||(s.width=e),s.height||(s.height=r),l&&!s.depth&&(s.depth=i)}else{const{width:e,height:r,depth:d}=s;if(null==e||null==r)throw new i.A("Width and height must be specified!");if(l&&null==d)throw new i.A("Depth must be specified!");if(s.isImmutable&&!this._wasImmutablyAllocated&&this._texStorage(c,_,s.hasMipmap,e,r,d),m(t)){const o=t.levels,l=g(c,e,r,d),u=Math.min(l-1,o.length-1);a.texParameteri(s.target,this._descriptor.context.gl.TEXTURE_MAX_LEVEL,u);const h=_;if(!(h in n.CQ))throw new i.A("Attempting to use compressed data with an uncompressed format!");this._forEachMipmapLevel(((e,t,r,i)=>{const n=o[Math.min(e,o.length-1)];this._compressedTexImage(c,e,h,t,r,i,n)}),u)}else this._texImage(c,0,_,e,r,d,t),(0,o.Y2)(a),s.hasMipmap&&this.generateMipmap()}u(a,this._descriptor),h(a,this._descriptor),function(e,t){const r=e.capabilities.textureFilterAnisotropic;r&&e.gl.texParameterf(t.target,r.TEXTURE_MAX_ANISOTROPY,t.maxAnisotropy??1)}(this._descriptor.context,this._descriptor),(0,o.Y2)(a),this._descriptor.context.bindTexture(v,e.TEXTURE_UNIT_FOR_UPDATES)}updateData(t,r,o,n,a,s,c=0){s||console.error("An attempt to use uninitialized data!"),this._glName||console.error("An attempt to update uninitialized texture!");const l=this._descriptor,d=this._deriveInternalFormat(),{context:u,pixelFormat:h,dataType:p,target:g,isImmutable:v}=l;if(v&&!this._wasImmutablyAllocated)throw new i.A("Cannot update immutable texture before allocation!");const _=u.bindTexture(this,e.TEXTURE_UNIT_FOR_UPDATES,!0);(r<0||o<0||r+n>l.width||o+a>l.height)&&console.error("An attempt to update out of bounds of the texture!"),this._configurePixelStorage();const{gl:T}=u;c&&T.pixelStorei(T.UNPACK_SKIP_ROWS,c),f(s)?T.texSubImage2D(g,t,r,o,n,a,h,p,s):m(s)?T.compressedTexSubImage2D(g,t,r,o,n,a,d,s.levels[t]):T.texSubImage2D(g,t,r,o,n,a,h,p,s),c&&T.pixelStorei(T.UNPACK_SKIP_ROWS,0),u.bindTexture(_,e.TEXTURE_UNIT_FOR_UPDATES)}updateData3D(t,r,o,n,a,s,c,l){l||console.error("An attempt to use uninitialized data!"),this._glName||console.error("An attempt to update uninitialized texture!");const d=this._descriptor,u=this._deriveInternalFormat(),{context:h,pixelFormat:f,dataType:g,isImmutable:v,target:_}=d;if(v&&!this._wasImmutablyAllocated)throw new i.A("Cannot update immutable texture before allocation!");p(_)||console.warn("Attempting to set 3D texture data on a non-3D texture");const T=h.bindTexture(this,e.TEXTURE_UNIT_FOR_UPDATES);h.setActiveTexture(e.TEXTURE_UNIT_FOR_UPDATES),(r<0||o<0||n<0||r+a>d.width||o+s>d.height||n+c>d.depth)&&console.error("An attempt to update out of bounds of the texture!"),this._configurePixelStorage();const{gl:x}=h;if(m(l))l=l.levels[t],x.compressedTexSubImage3D(_,t,r,o,n,a,s,c,u,l);else{const e=l;x.texSubImage3D(_,t,r,o,n,a,s,c,f,g,e)}h.bindTexture(T,e.TEXTURE_UNIT_FOR_UPDATES)}generateMipmap(){const t=this._descriptor;if(!t.hasMipmap){if(this._wasImmutablyAllocated)throw new i.A("Cannot add mipmaps to immutable texture after allocation");t.hasMipmap=!0,this._samplingModeDirty=!0,d(t)}t.samplingMode===n.Cj.LINEAR?(this._samplingModeDirty=!0,t.samplingMode=n.Cj.LINEAR_MIPMAP_NEAREST):t.samplingMode===n.Cj.NEAREST&&(this._samplingModeDirty=!0,t.samplingMode=n.Cj.NEAREST_MIPMAP_NEAREST);const r=this._descriptor.context.bindTexture(this,e.TEXTURE_UNIT_FOR_UPDATES);this._descriptor.context.setActiveTexture(e.TEXTURE_UNIT_FOR_UPDATES),this._descriptor.context.gl.generateMipmap(t.target),this._descriptor.context.bindTexture(r,e.TEXTURE_UNIT_FOR_UPDATES)}clearMipmap(){const e=this._descriptor;if(e.hasMipmap){if(this._wasImmutablyAllocated)throw new i.A("Cannot delete mipmaps to immutable texture after allocation");e.hasMipmap=!1,this._samplingModeDirty=!0,d(e)}e.samplingMode===n.Cj.LINEAR_MIPMAP_NEAREST?(this._samplingModeDirty=!0,e.samplingMode=n.Cj.LINEAR):e.samplingMode===n.Cj.NEAREST_MIPMAP_NEAREST&&(this._samplingModeDirty=!0,e.samplingMode=n.Cj.NEAREST)}setSamplingMode(e){e!==this._descriptor.samplingMode&&(this._descriptor.samplingMode=e,this._samplingModeDirty=!0)}setWrapMode(e){e!==this._descriptor.wrapMode&&(this._descriptor.wrapMode=e,d(this._descriptor),this._wrapModeDirty=!0)}applyChanges(){const e=this._descriptor,t=e.context.gl;this._samplingModeDirty&&(u(t,e),this._samplingModeDirty=!1),this._wrapModeDirty&&(h(t,e),this._wrapModeDirty=!1)}_deriveInternalFormat(){if(null!=this._descriptor.internalFormat)return this._descriptor.internalFormat===n.Ab.DEPTH_STENCIL&&(this._descriptor.internalFormat=n.Ab.DEPTH24_STENCIL8),this._descriptor.internalFormat;switch(this._descriptor.dataType){case n.ld.FLOAT:switch(this._descriptor.pixelFormat){case n.Ab.RGBA:return this._descriptor.internalFormat=n.H0.RGBA32F;case n.Ab.RGB:return this._descriptor.internalFormat=n.H0.RGB32F;default:throw new i.A("Unable to derive format")}case n.ld.UNSIGNED_BYTE:switch(this._descriptor.pixelFormat){case n.Ab.RGBA:return this._descriptor.internalFormat=n.H0.RGBA8;case n.Ab.RGB:return this._descriptor.internalFormat=n.H0.RGB8}}return this._descriptor.internalFormat=this._descriptor.pixelFormat===n.Ab.DEPTH_STENCIL?n.Ab.DEPTH24_STENCIL8:this._descriptor.pixelFormat}_configurePixelStorage(){const e=this._descriptor.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,o,a,s){const{gl:c}=this._descriptor.context;if(!(t in n.H0))throw new i.A("Immutable textures must have a sized internal format");if(!this._descriptor.isImmutable)return;const l=r?g(e,o,a,s):1;if(p(e)){if(null==s)throw new i.A("Missing depth dimension for 3D texture upload");c.texStorage3D(e,l,t,o,a,s)}else c.texStorage2D(e,l,t,o,a);this._wasImmutablyAllocated=!0}_texImage(e,t,r,o,n,a,s){const c=this._descriptor.context.gl,l=p(e),{isImmutable:d,pixelFormat:u,dataType:h}=this._descriptor;if(d){if(null!=s){const r=s;if(l){if(null==a)throw new i.A("Missing depth dimension for 3D texture upload");c.texSubImage3D(e,t,0,0,0,o,n,a,u,h,r)}else c.texSubImage2D(e,t,0,0,o,n,u,h,r)}}else{const d=s;if(l){if(null==a)throw new i.A("Missing depth dimension for 3D texture upload");c.texImage3D(e,t,r,o,n,a,0,u,h,d)}else c.texImage2D(e,t,r,o,n,0,u,h,d)}}_compressedTexImage(e,t,r,o,n,a,s){const c=this._descriptor.context.gl,l=p(e);if(this._descriptor.isImmutable){if(null!=s)if(l){if(null==a)throw new i.A("Missing depth dimension for 3D texture upload");c.compressedTexSubImage3D(e,t,0,0,0,o,n,a,r,s)}else c.compressedTexSubImage2D(e,t,0,0,o,n,r,s)}else if(l){if(null==a)throw new i.A("Missing depth dimension for 3D texture upload");c.compressedTexImage3D(e,t,r,o,n,a,0,s)}else c.compressedTexImage2D(e,t,r,o,n,0,s)}_forEachMipmapLevel(e,t=1/0){let{width:r,height:o,depth:a,hasMipmap:s,target:c}=this._descriptor;const l=c===n.Ap.TEXTURE_3D;if(null==r||null==o||l&&null==a)throw new i.A("Missing texture dimensions for mipmap calculation");for(let i=0;e(i,r,o,a),s&&(1!==r||1!==o||l&&1!==a)&&!(i>=t);++i)r=Math.max(1,r>>1),o=Math.max(1,o>>1),l&&(a=Math.max(1,a>>1))}};function d(e){(null!=e.width&&e.width<0||null!=e.height&&e.height<0||null!=e.depth&&e.depth<0)&&console.error("Negative dimension parameters are not allowed!")}function u(e,t){let r=t.samplingMode,i=t.samplingMode;r===n.Cj.LINEAR_MIPMAP_NEAREST||r===n.Cj.LINEAR_MIPMAP_LINEAR?(r=n.Cj.LINEAR,t.hasMipmap||(i=n.Cj.LINEAR)):r!==n.Cj.NEAREST_MIPMAP_NEAREST&&r!==n.Cj.NEAREST_MIPMAP_LINEAR||(r=n.Cj.NEAREST,t.hasMipmap||(i=n.Cj.NEAREST)),e.texParameteri(t.target,e.TEXTURE_MAG_FILTER,r),e.texParameteri(t.target,e.TEXTURE_MIN_FILTER,i)}function h(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))}function m(e){return null!=e&&"type"in e&&"compressed"===e.type}function f(e){return null!=e&&!m(e)&&!function(e){return null!=e&&"byteLength"in e}(e)}function p(e){return e===n.Ap.TEXTURE_3D||e===n.Ap.TEXTURE_2D_ARRAY}function g(e,t,r,i=1){let o=Math.max(t,r);return e===n.Ap.TEXTURE_3D&&(o=Math.max(o,i)),Math.round(Math.log(o)/Math.LN2)+1}l.TEXTURE_UNIT_FOR_UPDATES=0},67171:(e,t,r)=>{r.d(t,{R:()=>n,e:()=>a});var i=r(63907),o=r(42293);class n{constructor(e=0,t=e){this.width=e,this.height=t,this.target=i.Ap.TEXTURE_2D,this.pixelFormat=i.Ab.RGBA,this.dataType=i.ld.UNSIGNED_BYTE,this.samplingMode=i.Cj.LINEAR,this.wrapMode=i.pF.REPEAT,this.maxAnisotropy=1,this.flipped=!1,this.hasMipmap=!1,this.isOpaque=!1,this.unpackAlignment=4,this.preMultiplyAlpha=!1,this.depth=1,this.isImmutable=!1}}function a(e){return e.width<=0||e.height<=0?0:Math.round(e.width*e.height*(e.hasMipmap?4/3:1)*(null==e.internalFormat?4:(0,o.IB)(e.internalFormat)))}},42293:(e,t,r)=>{r.d(t,{Hi:()=>c,IB:()=>l,yu:()=>s}),r(44208);var i=r(94656),o=r(63907),n=r(62298);function a(e){const t=e.gl;switch(t.getError()){case t.NO_ERROR:return null;case t.INVALID_ENUM:return"An unacceptable value has been specified for an enumerated argument";case t.INVALID_VALUE:return"An unacceptable value has been specified for an argument";case t.INVALID_OPERATION:return"The specified command is not allowed for the current state";case t.INVALID_FRAMEBUFFER_OPERATION:return"The currently bound framebuffer is not framebuffer complete";case t.OUT_OF_MEMORY:return"Not enough memory is left to execute the command";case t.CONTEXT_LOST_WEBGL:return"WebGL context is lost"}return"Unknown error"}function s(e,t,r,o,s=0){const c=e.gl;e.bindBuffer(r);for(const r of o){const o=t.get(r.name);if(null==o){console.warn(`There is no location for vertex attribute '${r.name}' defined.`);continue}const l=s*r.stride;if(r.count<=4)c.vertexAttribPointer(o,r.count,r.type,r.normalized,r.stride,r.offset+l),c.enableVertexAttribArray(o),r.divisor>0&&e.gl.vertexAttribDivisor(o,r.divisor);else if(9===r.count)for(let t=0;t<3;t++)c.vertexAttribPointer(o+t,3,r.type,r.normalized,r.stride,r.offset+12*t+l),c.enableVertexAttribArray(o+t),r.divisor>0&&e.gl.vertexAttribDivisor(o+t,r.divisor);else if(16===r.count)for(let t=0;t<4;t++)c.vertexAttribPointer(o+t,4,r.type,r.normalized,r.stride,r.offset+16*t+l),c.enableVertexAttribArray(o+t),r.divisor>0&&e.gl?.vertexAttribDivisor(o+t,r.divisor);else console.error("Unsupported vertex attribute element count: "+r.count);if((0,i.en)()){const t=a(e),i=(0,n._)(r.type),o=r.offset,s=Math.round(i/o)!==i/o?`. Offset not a multiple of stride. DataType requires ${i} bytes, but descriptor has an offset of ${o}`:"";t&&console.error(`Unable to bind vertex attribute "${r.name}" with baseInstanceOffset ${l}${s}:`,t,r)}}}function c(e,t,r,i){const n=e.gl;e.bindBuffer(r);for(const r of i){const i=t.get(r.name);if(r.count<=4)n.disableVertexAttribArray(i),r.divisor&&r.divisor>0&&e.gl?.vertexAttribDivisor(i,0);else if(9===r.count)for(let t=0;t<3;t++)n.disableVertexAttribArray(i+t),r.divisor&&r.divisor>0&&e.gl?.vertexAttribDivisor(i+t,0);else if(16===r.count)for(let t=0;t<4;t++)n.disableVertexAttribArray(i+t),r.divisor&&r.divisor>0&&e.gl?.vertexAttribDivisor(i+t,0);else console.error("Unsupported vertex attribute element count: "+r.count)}e.unbindBuffer(o.NZ.ARRAY_BUFFER)}function l(e){switch(e){case o.Ab.ALPHA:case o.Ab.LUMINANCE:case o.Ab.RED:case o.Ab.RED_INTEGER:case o.H0.R8:case o.H0.R8I:case o.H0.R8UI:case o.H0.R8_SNORM:case o.yQ.STENCIL_INDEX8:return 1;case o.Ab.LUMINANCE_ALPHA:case o.Ab.RG:case o.Ab.RG_INTEGER:case o.H0.RGBA4:case o.H0.R16F:case o.H0.R16I:case o.H0.R16UI:case o.H0.RG8:case o.H0.RG8I:case o.H0.RG8UI:case o.H0.RG8_SNORM:case o.H0.RGB565:case o.H0.RGB5_A1:case o.yQ.DEPTH_COMPONENT16:return 2;case o.Ab.DEPTH_COMPONENT:case o.Ab.RGB:case o.Ab.RGB_INTEGER:case o.H0.RGB8:case o.H0.RGB8I:case o.H0.RGB8UI:case o.H0.RGB8_SNORM:case o.H0.SRGB8:case o.yQ.DEPTH_COMPONENT24:return 3;case o.Ab.DEPTH_STENCIL:case o.Ab.DEPTH24_STENCIL8:case o.Ab.RGBA:case o.Ab.RGBA_INTEGER:case o.H0.RGBA8:case o.H0.R32F:case o.H0.R11F_G11F_B10F:case o.H0.RG16F:case o.H0.R32I:case o.H0.R32UI:case o.H0.RG16I:case o.H0.RG16UI:case o.H0.RGBA8I:case o.H0.RGBA8UI:case o.H0.RGBA8_SNORM:case o.H0.SRGB8_ALPHA8:case o.H0.RGB9_E5:case o.H0.RGB10_A2UI:case o.H0.RGB10_A2:case o.yQ.DEPTH_STENCIL:case o.yQ.DEPTH_COMPONENT32F:case o.yQ.DEPTH24_STENCIL8:return 4;case o.yQ.DEPTH32F_STENCIL8:return 5;case o.H0.RGB16F:case o.H0.RGB16I:case o.H0.RGB16UI:return 6;case o.H0.RG32F:case o.H0.RG32I:case o.H0.RG32UI:case o.H0.RGBA16F:case o.H0.RGBA16I:case o.H0.RGBA16UI:return 8;case o.H0.RGB32F:case o.H0.RGB32I:case o.H0.RGB32UI:return 12;case o.H0.RGBA32F:case o.H0.RGBA32I:case o.H0.RGBA32UI:return 16;case o.CQ.COMPRESSED_RGB_S3TC_DXT1_EXT:case o.CQ.COMPRESSED_RGBA_S3TC_DXT1_EXT:return.5;case o.CQ.COMPRESSED_RGBA_S3TC_DXT3_EXT:case o.CQ.COMPRESSED_RGBA_S3TC_DXT5_EXT:return 1;case o.CQ.COMPRESSED_R11_EAC:case o.CQ.COMPRESSED_SIGNED_R11_EAC:case o.CQ.COMPRESSED_RGB8_ETC2:case o.CQ.COMPRESSED_SRGB8_ETC2:case o.CQ.COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2:case o.CQ.COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2:return.5;case o.CQ.COMPRESSED_RG11_EAC:case o.CQ.COMPRESSED_SIGNED_RG11_EAC:case o.CQ.COMPRESSED_RGBA8_ETC2_EAC:case o.CQ.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC:return 1}return 0}},94656:(e,t,r)=>{r.d(t,{Xc:()=>l,Y2:()=>d,en:()=>c});var i=r(49186),o=r(44208),n=r(53966);const a=()=>n.A.getLogger("esri.views.webgl.checkWebGLError"),s=!!(0,o.A)("enable-feature:webgl-debug");function c(){return s}function l(){return s}function d(e){if(c()){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),o=(new Error).stack;a().error(new i.A("webgl-error","WebGL error occurred",{message:r,stack:o}))}}}},28449:(e,t,r)=>{function i(e,t,r){for(let i=0;i<r;++i)t[2*i]=e[i],t[2*i+1]=e[i]-t[2*i]}function o(e,t){const r=e.length;for(let i=0;i<r;++i)a[0]=e[i],t[i]=a[0];return t}function n(e,t){const r=e.length;for(let i=0;i<r;++i)a[0]=e[i],a[1]=e[i]-a[0],t[i]=a[1];return t}r.d(t,{Zo:()=>o,jA:()=>n,jS:()=>i});const a=new Float32Array(2)},62298:(e,t,r)=>{r.d(t,{_:()=>o});var i=r(63907);function o(e){switch(e){case i.pe.BYTE:case i.pe.UNSIGNED_BYTE:return 1;case i.pe.SHORT:case i.pe.UNSIGNED_SHORT:case i.pe.HALF_FLOAT:return 2;case i.pe.FLOAT:case i.pe.INT:case i.pe.UNSIGNED_INT:return 4}}},90644:(e,t,r)=>{r.d(t,{Ey:()=>b,Ky:()=>c,Os:()=>s,Uy:()=>h,Xt:()=>u,kn:()=>m,p3:()=>a});var i=r(89192),o=r(63907);function n(e,t,r=o.Tb.ADD,i=[0,0,0,0]){return{srcRgb:e,srcAlpha:e,dstRgb:t,dstAlpha:t,opRgb:r,opAlpha:r,color:{r:i[0],g:i[1],b:i[2],a:i[3]}}}function a(e,t,r,i,n=o.Tb.ADD,a=o.Tb.ADD,s=[0,0,0,0]){return{srcRgb:e,srcAlpha:t,dstRgb:r,dstAlpha:i,opRgb:n,opAlpha:a,color:{r:s[0],g:s[1],b:s[2],a:s[3]}}}n(o.dn.ZERO,o.dn.ONE_MINUS_SRC_ALPHA),n(o.dn.ONE,o.dn.ZERO),n(o.dn.ONE,o.dn.ONE);const s=n(o.dn.ONE,o.dn.ONE_MINUS_SRC_ALPHA),c=a(o.dn.SRC_ALPHA,o.dn.ONE,o.dn.ONE_MINUS_SRC_ALPHA,o.dn.ONE_MINUS_SRC_ALPHA),l={face:o.Y7.BACK,mode:o.Ac.CCW},d={face:o.Y7.FRONT,mode:o.Ac.CCW},u=e=>e===i.s2.Back?l:e===i.s2.Front?d:null,h={zNear:0,zFar:1},m={r:!0,g:!0,b:!0,a:!0};function f(e){return C.intern(e)}function p(e){return I.intern(e)}function g(e){return O.intern(e)}function v(e){return y.intern(e)}function _(e){return L.intern(e)}function T(e){return D.intern(e)}function x(e){return G.intern(e)}function A(e){return U.intern(e)}function E(e){return V.intern(e)}function b(e){return j.intern(e)}class S{constructor(e,t){this._makeKey=e,this._makeRef=t,this._interns=new Map}intern(e){if(!e)return null;const t=this._makeKey(e),r=this._interns;return r.has(t)||r.set(t,this._makeRef(e)),r.get(t)??null}}function M(e){return"["+e.join(",")+"]"}const C=new S(R,(e=>({__tag:"Blending",...e})));function R(e){return e?M([e.srcRgb,e.srcAlpha,e.dstRgb,e.dstAlpha,e.opRgb,e.opAlpha,e.color.r,e.color.g,e.color.b,e.color.a]):null}const I=new S(w,(e=>({__tag:"Culling",...e})));function w(e){return e?M([e.face,e.mode]):null}const O=new S(N,(e=>({__tag:"PolygonOffset",...e})));function N(e){return e?M([e.factor,e.units]):null}const y=new S(P,(e=>({__tag:"DepthTest",...e})));function P(e){return e?M([e.func]):null}const L=new S(H,(e=>({__tag:"StencilTest",...e})));function H(e){return e?M([e.function.func,e.function.ref,e.function.mask,e.operation.fail,e.operation.zFail,e.operation.zPass]):null}const D=new S(F,(e=>({__tag:"DepthWrite",...e})));function F(e){return e?M([e.zNear,e.zFar]):null}const G=new S(B,(e=>({__tag:"ColorWrite",...e})));function B(e){return e?M([e.r,e.g,e.b,e.a]):null}const U=new S(z,(e=>({__tag:"StencilWrite",...e})));function z(e){return e?M([e.mask]):null}const V=new S(W,(e=>({__tag:"DrawBuffers",...e})));function W(e){return e?M(e.buffers):null}const j=new S((function(e){return e?M([R(e.blending),w(e.culling),N(e.polygonOffset),P(e.depthTest),H(e.stencilTest),F(e.depthWrite),B(e.colorWrite),z(e.stencilWrite),W(e.drawBuffers)]):null}),(e=>({blending:f(e.blending),culling:p(e.culling),polygonOffset:g(e.polygonOffset),depthTest:v(e.depthTest),stencilTest:_(e.stencilTest),depthWrite:T(e.depthWrite),colorWrite:x(e.colorWrite),stencilWrite:A(e.stencilWrite),drawBuffers:E(e.drawBuffers)})))}}]);
988
+ `)}},36421:(e,t,r)=>{var i;r.d(t,{p:()=>i}),function(e){e[e.Texture=0]="Texture",e[e.RenderBuffer=1]="RenderBuffer"}(i||(i={}))},21231:(e,t,r)=>{r.d(t,{g:()=>l});var i=r(49186),o=(r(44208),r(94656)),n=r(63907),a=r(36421),s=r(67171);class c extends s.R{constructor(e,t){switch(super(),this.context=e,Object.assign(this,t),this.internalFormat){case n.H0.R16F:case n.H0.R16I:case n.H0.R16UI:case n.H0.R32F:case n.H0.R32I:case n.H0.R32UI:case n.H0.R8_SNORM:case n.H0.R8:case n.H0.R8I:case n.H0.R8UI:this.pixelFormat=n.Ab.RED}}static validate(e,t){return new c(e,t)}}let l=class e{constructor(e,t=null,r=null){if(this.type=a.p.Texture,this._glName=null,this._samplingModeDirty=!1,this._wrapModeDirty=!1,this._wasImmutablyAllocated=!1,"context"in e)this._descriptor=e,r=t;else{const r=c.validate(e,t);if(!r)throw new i.A("Texture descriptor invalid");this._descriptor=r}this._descriptor.target===n.Ap.TEXTURE_CUBE_MAP?this._setDataCubeMap(r):this.setData(r)}get glName(){return this._glName}get descriptor(){return this._descriptor}get usedMemory(){return(0,s.e)(this._descriptor)}get cachedMemory(){return this.usedMemory}get isDirty(){return this._samplingModeDirty||this._wrapModeDirty}dispose(){this._glName&&this._descriptor.context.instanceCounter.decrement(n.vt.Texture,this),this._descriptor.context.gl&&this._glName&&(this._descriptor.context.unbindTexture(this),this._descriptor.context.gl.deleteTexture(this._glName),this._glName=null)}release(){this.dispose()}resize(e,t){const r=this._descriptor;if(r.width!==e||r.height!==t){if(this._wasImmutablyAllocated)throw new i.A("Immutable textures can't be resized!");r.width=e,r.height=t,this._descriptor.target===n.Ap.TEXTURE_CUBE_MAP?this._setDataCubeMap(null):this.setData(null)}}_setDataCubeMap(e=null){for(let t=n.Ap.TEXTURE_CUBE_MAP_POSITIVE_X;t<=n.Ap.TEXTURE_CUBE_MAP_NEGATIVE_Z;t++)this._setData(e,t)}setData(e){this._setData(e)}_setData(t,r){const a=this._descriptor.context?.gl;if(!a)return;(0,o.Y2)(a),this._glName||(this._glName=a.createTexture(),this._glName&&this._descriptor.context.instanceCounter.increment(n.vt.Texture,this));const s=this._descriptor,c=r??s.target,l=p(c),v=this._descriptor.context.bindTexture(this,e.TEXTURE_UNIT_FOR_UPDATES);this._descriptor.context.setActiveTexture(e.TEXTURE_UNIT_FOR_UPDATES),d(s),this._configurePixelStorage(),(0,o.Y2)(a);const _=this._deriveInternalFormat();if(f(t)){let e="width"in t?t.width:t.codedWidth,r="height"in t?t.height:t.codedHeight;const i=1;t instanceof HTMLVideoElement&&(e=t.videoWidth,r=t.videoHeight),s.width&&s.height,l&&s.depth,s.isImmutable&&!this._wasImmutablyAllocated&&this._texStorage(c,_,s.hasMipmap,e,r,i),this._texImage(c,0,_,e,r,i,t),(0,o.Y2)(a),s.hasMipmap&&(this.generateMipmap(),(0,o.Y2)(a)),s.width||(s.width=e),s.height||(s.height=r),l&&!s.depth&&(s.depth=i)}else{const{width:e,height:r,depth:d}=s;if(null==e||null==r)throw new i.A("Width and height must be specified!");if(l&&null==d)throw new i.A("Depth must be specified!");if(s.isImmutable&&!this._wasImmutablyAllocated&&this._texStorage(c,_,s.hasMipmap,e,r,d),m(t)){const o=t.levels,l=g(c,e,r,d),u=Math.min(l-1,o.length-1);a.texParameteri(s.target,this._descriptor.context.gl.TEXTURE_MAX_LEVEL,u);const h=_;if(!(h in n.CQ))throw new i.A("Attempting to use compressed data with an uncompressed format!");this._forEachMipmapLevel(((e,t,r,i)=>{const n=o[Math.min(e,o.length-1)];this._compressedTexImage(c,e,h,t,r,i,n)}),u)}else this._texImage(c,0,_,e,r,d,t),(0,o.Y2)(a),s.hasMipmap&&this.generateMipmap()}u(a,this._descriptor),h(a,this._descriptor),function(e,t){const r=e.capabilities.textureFilterAnisotropic;r&&e.gl.texParameterf(t.target,r.TEXTURE_MAX_ANISOTROPY,t.maxAnisotropy??1)}(this._descriptor.context,this._descriptor),(0,o.Y2)(a),this._descriptor.context.bindTexture(v,e.TEXTURE_UNIT_FOR_UPDATES)}updateData(t,r,o,n,a,s,c=0){s||console.error("An attempt to use uninitialized data!"),this._glName||console.error("An attempt to update uninitialized texture!");const l=this._descriptor,d=this._deriveInternalFormat(),{context:u,pixelFormat:h,dataType:p,target:g,isImmutable:v}=l;if(v&&!this._wasImmutablyAllocated)throw new i.A("Cannot update immutable texture before allocation!");const _=u.bindTexture(this,e.TEXTURE_UNIT_FOR_UPDATES,!0);(r<0||o<0||r+n>l.width||o+a>l.height)&&console.error("An attempt to update out of bounds of the texture!"),this._configurePixelStorage();const{gl:T}=u;c&&T.pixelStorei(T.UNPACK_SKIP_ROWS,c),f(s)?T.texSubImage2D(g,t,r,o,n,a,h,p,s):m(s)?T.compressedTexSubImage2D(g,t,r,o,n,a,d,s.levels[t]):T.texSubImage2D(g,t,r,o,n,a,h,p,s),c&&T.pixelStorei(T.UNPACK_SKIP_ROWS,0),u.bindTexture(_,e.TEXTURE_UNIT_FOR_UPDATES)}updateData3D(t,r,o,n,a,s,c,l){l||console.error("An attempt to use uninitialized data!"),this._glName||console.error("An attempt to update uninitialized texture!");const d=this._descriptor,u=this._deriveInternalFormat(),{context:h,pixelFormat:f,dataType:g,isImmutable:v,target:_}=d;if(v&&!this._wasImmutablyAllocated)throw new i.A("Cannot update immutable texture before allocation!");p(_)||console.warn("Attempting to set 3D texture data on a non-3D texture");const T=h.bindTexture(this,e.TEXTURE_UNIT_FOR_UPDATES);h.setActiveTexture(e.TEXTURE_UNIT_FOR_UPDATES),(r<0||o<0||n<0||r+a>d.width||o+s>d.height||n+c>d.depth)&&console.error("An attempt to update out of bounds of the texture!"),this._configurePixelStorage();const{gl:x}=h;if(m(l))l=l.levels[t],x.compressedTexSubImage3D(_,t,r,o,n,a,s,c,u,l);else{const e=l;x.texSubImage3D(_,t,r,o,n,a,s,c,f,g,e)}h.bindTexture(T,e.TEXTURE_UNIT_FOR_UPDATES)}generateMipmap(){const t=this._descriptor;if(!t.hasMipmap){if(this._wasImmutablyAllocated)throw new i.A("Cannot add mipmaps to immutable texture after allocation");t.hasMipmap=!0,this._samplingModeDirty=!0,d(t)}t.samplingMode===n.Cj.LINEAR?(this._samplingModeDirty=!0,t.samplingMode=n.Cj.LINEAR_MIPMAP_NEAREST):t.samplingMode===n.Cj.NEAREST&&(this._samplingModeDirty=!0,t.samplingMode=n.Cj.NEAREST_MIPMAP_NEAREST);const r=this._descriptor.context.bindTexture(this,e.TEXTURE_UNIT_FOR_UPDATES);this._descriptor.context.setActiveTexture(e.TEXTURE_UNIT_FOR_UPDATES),this._descriptor.context.gl.generateMipmap(t.target),this._descriptor.context.bindTexture(r,e.TEXTURE_UNIT_FOR_UPDATES)}clearMipmap(){const e=this._descriptor;if(e.hasMipmap){if(this._wasImmutablyAllocated)throw new i.A("Cannot delete mipmaps to immutable texture after allocation");e.hasMipmap=!1,this._samplingModeDirty=!0,d(e)}e.samplingMode===n.Cj.LINEAR_MIPMAP_NEAREST?(this._samplingModeDirty=!0,e.samplingMode=n.Cj.LINEAR):e.samplingMode===n.Cj.NEAREST_MIPMAP_NEAREST&&(this._samplingModeDirty=!0,e.samplingMode=n.Cj.NEAREST)}setSamplingMode(e){e!==this._descriptor.samplingMode&&(this._descriptor.samplingMode=e,this._samplingModeDirty=!0)}setWrapMode(e){e!==this._descriptor.wrapMode&&(this._descriptor.wrapMode=e,d(this._descriptor),this._wrapModeDirty=!0)}applyChanges(){const e=this._descriptor,t=e.context.gl;this._samplingModeDirty&&(u(t,e),this._samplingModeDirty=!1),this._wrapModeDirty&&(h(t,e),this._wrapModeDirty=!1)}_deriveInternalFormat(){if(null!=this._descriptor.internalFormat)return this._descriptor.internalFormat===n.Ab.DEPTH_STENCIL&&(this._descriptor.internalFormat=n.Ab.DEPTH24_STENCIL8),this._descriptor.internalFormat;switch(this._descriptor.dataType){case n.ld.FLOAT:switch(this._descriptor.pixelFormat){case n.Ab.RGBA:return this._descriptor.internalFormat=n.H0.RGBA32F;case n.Ab.RGB:return this._descriptor.internalFormat=n.H0.RGB32F;default:throw new i.A("Unable to derive format")}case n.ld.UNSIGNED_BYTE:switch(this._descriptor.pixelFormat){case n.Ab.RGBA:return this._descriptor.internalFormat=n.H0.RGBA8;case n.Ab.RGB:return this._descriptor.internalFormat=n.H0.RGB8}}return this._descriptor.internalFormat=this._descriptor.pixelFormat===n.Ab.DEPTH_STENCIL?n.Ab.DEPTH24_STENCIL8:this._descriptor.pixelFormat}_configurePixelStorage(){const e=this._descriptor.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,o,a,s){const{gl:c}=this._descriptor.context;if(!(t in n.H0))throw new i.A("Immutable textures must have a sized internal format");if(!this._descriptor.isImmutable)return;const l=r?g(e,o,a,s):1;if(p(e)){if(null==s)throw new i.A("Missing depth dimension for 3D texture upload");c.texStorage3D(e,l,t,o,a,s)}else c.texStorage2D(e,l,t,o,a);this._wasImmutablyAllocated=!0}_texImage(e,t,r,o,n,a,s){const c=this._descriptor.context.gl,l=p(e),{isImmutable:d,pixelFormat:u,dataType:h}=this._descriptor;if(d){if(null!=s){const r=s;if(l){if(null==a)throw new i.A("Missing depth dimension for 3D texture upload");c.texSubImage3D(e,t,0,0,0,o,n,a,u,h,r)}else c.texSubImage2D(e,t,0,0,o,n,u,h,r)}}else{const d=s;if(l){if(null==a)throw new i.A("Missing depth dimension for 3D texture upload");c.texImage3D(e,t,r,o,n,a,0,u,h,d)}else c.texImage2D(e,t,r,o,n,0,u,h,d)}}_compressedTexImage(e,t,r,o,n,a,s){const c=this._descriptor.context.gl,l=p(e);if(this._descriptor.isImmutable){if(null!=s)if(l){if(null==a)throw new i.A("Missing depth dimension for 3D texture upload");c.compressedTexSubImage3D(e,t,0,0,0,o,n,a,r,s)}else c.compressedTexSubImage2D(e,t,0,0,o,n,r,s)}else if(l){if(null==a)throw new i.A("Missing depth dimension for 3D texture upload");c.compressedTexImage3D(e,t,r,o,n,a,0,s)}else c.compressedTexImage2D(e,t,r,o,n,0,s)}_forEachMipmapLevel(e,t=1/0){let{width:r,height:o,depth:a,hasMipmap:s,target:c}=this._descriptor;const l=c===n.Ap.TEXTURE_3D;if(null==r||null==o||l&&null==a)throw new i.A("Missing texture dimensions for mipmap calculation");for(let i=0;e(i,r,o,a),s&&(1!==r||1!==o||l&&1!==a)&&!(i>=t);++i)r=Math.max(1,r>>1),o=Math.max(1,o>>1),l&&(a=Math.max(1,a>>1))}};function d(e){(null!=e.width&&e.width<0||null!=e.height&&e.height<0||null!=e.depth&&e.depth<0)&&console.error("Negative dimension parameters are not allowed!")}function u(e,t){let r=t.samplingMode,i=t.samplingMode;r===n.Cj.LINEAR_MIPMAP_NEAREST||r===n.Cj.LINEAR_MIPMAP_LINEAR?(r=n.Cj.LINEAR,t.hasMipmap||(i=n.Cj.LINEAR)):r!==n.Cj.NEAREST_MIPMAP_NEAREST&&r!==n.Cj.NEAREST_MIPMAP_LINEAR||(r=n.Cj.NEAREST,t.hasMipmap||(i=n.Cj.NEAREST)),e.texParameteri(t.target,e.TEXTURE_MAG_FILTER,r),e.texParameteri(t.target,e.TEXTURE_MIN_FILTER,i)}function h(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))}function m(e){return null!=e&&"type"in e&&"compressed"===e.type}function f(e){return null!=e&&!m(e)&&!function(e){return null!=e&&"byteLength"in e}(e)}function p(e){return e===n.Ap.TEXTURE_3D||e===n.Ap.TEXTURE_2D_ARRAY}function g(e,t,r,i=1){let o=Math.max(t,r);return e===n.Ap.TEXTURE_3D&&(o=Math.max(o,i)),Math.round(Math.log(o)/Math.LN2)+1}l.TEXTURE_UNIT_FOR_UPDATES=0},67171:(e,t,r)=>{r.d(t,{R:()=>n,e:()=>a});var i=r(63907),o=r(42293);class n{constructor(e=0,t=e){this.width=e,this.height=t,this.target=i.Ap.TEXTURE_2D,this.pixelFormat=i.Ab.RGBA,this.dataType=i.ld.UNSIGNED_BYTE,this.samplingMode=i.Cj.LINEAR,this.wrapMode=i.pF.REPEAT,this.maxAnisotropy=1,this.flipped=!1,this.hasMipmap=!1,this.isOpaque=!1,this.unpackAlignment=4,this.preMultiplyAlpha=!1,this.depth=1,this.isImmutable=!1}}function a(e){return e.width<=0||e.height<=0?0:Math.round(e.width*e.height*(e.hasMipmap?4/3:1)*(null==e.internalFormat?4:(0,o.IB)(e.internalFormat)))}},42293:(e,t,r)=>{r.d(t,{Hi:()=>c,IB:()=>l,yu:()=>s}),r(44208);var i=r(94656),o=r(63907),n=r(62298);function a(e){const t=e.gl;switch(t.getError()){case t.NO_ERROR:return null;case t.INVALID_ENUM:return"An unacceptable value has been specified for an enumerated argument";case t.INVALID_VALUE:return"An unacceptable value has been specified for an argument";case t.INVALID_OPERATION:return"The specified command is not allowed for the current state";case t.INVALID_FRAMEBUFFER_OPERATION:return"The currently bound framebuffer is not framebuffer complete";case t.OUT_OF_MEMORY:return"Not enough memory is left to execute the command";case t.CONTEXT_LOST_WEBGL:return"WebGL context is lost"}return"Unknown error"}function s(e,t,r,o,s=0){const c=e.gl;e.bindBuffer(r);for(const r of o){const o=t.get(r.name);if(null==o){console.warn(`There is no location for vertex attribute '${r.name}' defined.`);continue}const l=s*r.stride;if(r.count<=4)c.vertexAttribPointer(o,r.count,r.type,r.normalized,r.stride,r.offset+l),c.enableVertexAttribArray(o),r.divisor>0&&e.gl.vertexAttribDivisor(o,r.divisor);else if(9===r.count)for(let t=0;t<3;t++)c.vertexAttribPointer(o+t,3,r.type,r.normalized,r.stride,r.offset+12*t+l),c.enableVertexAttribArray(o+t),r.divisor>0&&e.gl.vertexAttribDivisor(o+t,r.divisor);else if(16===r.count)for(let t=0;t<4;t++)c.vertexAttribPointer(o+t,4,r.type,r.normalized,r.stride,r.offset+16*t+l),c.enableVertexAttribArray(o+t),r.divisor>0&&e.gl?.vertexAttribDivisor(o+t,r.divisor);else console.error("Unsupported vertex attribute element count: "+r.count);if((0,i.en)()){const t=a(e),i=(0,n._)(r.type),o=r.offset,s=Math.round(i/o)!==i/o?`. Offset not a multiple of stride. DataType requires ${i} bytes, but descriptor has an offset of ${o}`:"";t&&console.error(`Unable to bind vertex attribute "${r.name}" with baseInstanceOffset ${l}${s}:`,t,r)}}}function c(e,t,r,i){const n=e.gl;e.bindBuffer(r);for(const r of i){const i=t.get(r.name);if(r.count<=4)n.disableVertexAttribArray(i),r.divisor&&r.divisor>0&&e.gl?.vertexAttribDivisor(i,0);else if(9===r.count)for(let t=0;t<3;t++)n.disableVertexAttribArray(i+t),r.divisor&&r.divisor>0&&e.gl?.vertexAttribDivisor(i+t,0);else if(16===r.count)for(let t=0;t<4;t++)n.disableVertexAttribArray(i+t),r.divisor&&r.divisor>0&&e.gl?.vertexAttribDivisor(i+t,0);else console.error("Unsupported vertex attribute element count: "+r.count)}e.unbindBuffer(o.NZ.ARRAY_BUFFER)}function l(e){switch(e){case o.Ab.ALPHA:case o.Ab.LUMINANCE:case o.Ab.RED:case o.Ab.RED_INTEGER:case o.H0.R8:case o.H0.R8I:case o.H0.R8UI:case o.H0.R8_SNORM:case o.yQ.STENCIL_INDEX8:return 1;case o.Ab.LUMINANCE_ALPHA:case o.Ab.RG:case o.Ab.RG_INTEGER:case o.H0.RGBA4:case o.H0.R16F:case o.H0.R16I:case o.H0.R16UI:case o.H0.RG8:case o.H0.RG8I:case o.H0.RG8UI:case o.H0.RG8_SNORM:case o.H0.RGB565:case o.H0.RGB5_A1:case o.yQ.DEPTH_COMPONENT16:return 2;case o.Ab.DEPTH_COMPONENT:case o.Ab.RGB:case o.Ab.RGB_INTEGER:case o.H0.RGB8:case o.H0.RGB8I:case o.H0.RGB8UI:case o.H0.RGB8_SNORM:case o.H0.SRGB8:case o.yQ.DEPTH_COMPONENT24:return 3;case o.Ab.DEPTH_STENCIL:case o.Ab.DEPTH24_STENCIL8:case o.Ab.RGBA:case o.Ab.RGBA_INTEGER:case o.H0.RGBA8:case o.H0.R32F:case o.H0.R11F_G11F_B10F:case o.H0.RG16F:case o.H0.R32I:case o.H0.R32UI:case o.H0.RG16I:case o.H0.RG16UI:case o.H0.RGBA8I:case o.H0.RGBA8UI:case o.H0.RGBA8_SNORM:case o.H0.SRGB8_ALPHA8:case o.H0.RGB9_E5:case o.H0.RGB10_A2UI:case o.H0.RGB10_A2:case o.yQ.DEPTH_STENCIL:case o.yQ.DEPTH_COMPONENT32F:case o.yQ.DEPTH24_STENCIL8:return 4;case o.yQ.DEPTH32F_STENCIL8:return 5;case o.H0.RGB16F:case o.H0.RGB16I:case o.H0.RGB16UI:return 6;case o.H0.RG32F:case o.H0.RG32I:case o.H0.RG32UI:case o.H0.RGBA16F:case o.H0.RGBA16I:case o.H0.RGBA16UI:return 8;case o.H0.RGB32F:case o.H0.RGB32I:case o.H0.RGB32UI:return 12;case o.H0.RGBA32F:case o.H0.RGBA32I:case o.H0.RGBA32UI:return 16;case o.CQ.COMPRESSED_RGB_S3TC_DXT1_EXT:case o.CQ.COMPRESSED_RGBA_S3TC_DXT1_EXT:return.5;case o.CQ.COMPRESSED_RGBA_S3TC_DXT3_EXT:case o.CQ.COMPRESSED_RGBA_S3TC_DXT5_EXT:return 1;case o.CQ.COMPRESSED_R11_EAC:case o.CQ.COMPRESSED_SIGNED_R11_EAC:case o.CQ.COMPRESSED_RGB8_ETC2:case o.CQ.COMPRESSED_SRGB8_ETC2:case o.CQ.COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2:case o.CQ.COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2:return.5;case o.CQ.COMPRESSED_RG11_EAC:case o.CQ.COMPRESSED_SIGNED_RG11_EAC:case o.CQ.COMPRESSED_RGBA8_ETC2_EAC:case o.CQ.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC:return 1}return 0}},94656:(e,t,r)=>{r.d(t,{Xc:()=>l,Y2:()=>d,en:()=>c});var i=r(49186),o=r(44208),n=r(53966);const a=()=>n.A.getLogger("esri.views.webgl.checkWebGLError"),s=!!(0,o.A)("enable-feature:webgl-debug");function c(){return s}function l(){return s}function d(e){if(c()){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),o=(new Error).stack;a().error(new i.A("webgl-error","WebGL error occurred",{message:r,stack:o}))}}}},28449:(e,t,r)=>{function i(e,t,r){for(let i=0;i<r;++i)t[2*i]=e[i],t[2*i+1]=e[i]-t[2*i]}function o(e,t){const r=e.length;for(let i=0;i<r;++i)a[0]=e[i],t[i]=a[0];return t}function n(e,t){const r=e.length;for(let i=0;i<r;++i)a[0]=e[i],a[1]=e[i]-a[0],t[i]=a[1];return t}r.d(t,{Zo:()=>o,jA:()=>n,jS:()=>i});const a=new Float32Array(2)},62298:(e,t,r)=>{r.d(t,{_:()=>o});var i=r(63907);function o(e){switch(e){case i.pe.BYTE:case i.pe.UNSIGNED_BYTE:return 1;case i.pe.SHORT:case i.pe.UNSIGNED_SHORT:case i.pe.HALF_FLOAT:return 2;case i.pe.FLOAT:case i.pe.INT:case i.pe.UNSIGNED_INT:return 4}}},90644:(e,t,r)=>{r.d(t,{Ey:()=>b,Ky:()=>c,Os:()=>s,Uy:()=>h,Xt:()=>u,kn:()=>m,p3:()=>a});var i=r(89192),o=r(63907);function n(e,t,r=o.Tb.ADD,i=[0,0,0,0]){return{srcRgb:e,srcAlpha:e,dstRgb:t,dstAlpha:t,opRgb:r,opAlpha:r,color:{r:i[0],g:i[1],b:i[2],a:i[3]}}}function a(e,t,r,i,n=o.Tb.ADD,a=o.Tb.ADD,s=[0,0,0,0]){return{srcRgb:e,srcAlpha:t,dstRgb:r,dstAlpha:i,opRgb:n,opAlpha:a,color:{r:s[0],g:s[1],b:s[2],a:s[3]}}}n(o.dn.ZERO,o.dn.ONE_MINUS_SRC_ALPHA),n(o.dn.ONE,o.dn.ZERO),n(o.dn.ONE,o.dn.ONE);const s=n(o.dn.ONE,o.dn.ONE_MINUS_SRC_ALPHA),c=a(o.dn.SRC_ALPHA,o.dn.ONE,o.dn.ONE_MINUS_SRC_ALPHA,o.dn.ONE_MINUS_SRC_ALPHA),l={face:o.Y7.BACK,mode:o.Ac.CCW},d={face:o.Y7.FRONT,mode:o.Ac.CCW},u=e=>e===i.s2.Back?l:e===i.s2.Front?d:null,h={zNear:0,zFar:1},m={r:!0,g:!0,b:!0,a:!0};function f(e){return C.intern(e)}function p(e){return I.intern(e)}function g(e){return O.intern(e)}function v(e){return y.intern(e)}function _(e){return L.intern(e)}function T(e){return D.intern(e)}function x(e){return G.intern(e)}function A(e){return U.intern(e)}function E(e){return V.intern(e)}function b(e){return j.intern(e)}class S{constructor(e,t){this._makeKey=e,this._makeRef=t,this._interns=new Map}intern(e){if(!e)return null;const t=this._makeKey(e),r=this._interns;return r.has(t)||r.set(t,this._makeRef(e)),r.get(t)??null}}function M(e){return"["+e.join(",")+"]"}const C=new S(R,(e=>({__tag:"Blending",...e})));function R(e){return e?M([e.srcRgb,e.srcAlpha,e.dstRgb,e.dstAlpha,e.opRgb,e.opAlpha,e.color.r,e.color.g,e.color.b,e.color.a]):null}const I=new S(w,(e=>({__tag:"Culling",...e})));function w(e){return e?M([e.face,e.mode]):null}const O=new S(N,(e=>({__tag:"PolygonOffset",...e})));function N(e){return e?M([e.factor,e.units]):null}const y=new S(P,(e=>({__tag:"DepthTest",...e})));function P(e){return e?M([e.func]):null}const L=new S(H,(e=>({__tag:"StencilTest",...e})));function H(e){return e?M([e.function.func,e.function.ref,e.function.mask,e.operation.fail,e.operation.zFail,e.operation.zPass]):null}const D=new S(F,(e=>({__tag:"DepthWrite",...e})));function F(e){return e?M([e.zNear,e.zFar]):null}const G=new S(B,(e=>({__tag:"ColorWrite",...e})));function B(e){return e?M([e.r,e.g,e.b,e.a]):null}const U=new S(z,(e=>({__tag:"StencilWrite",...e})));function z(e){return e?M([e.mask]):null}const V=new S(W,(e=>({__tag:"DrawBuffers",...e})));function W(e){return e?M(e.buffers):null}const j=new S((function(e){return e?M([R(e.blending),w(e.culling),N(e.polygonOffset),P(e.depthTest),H(e.stencilTest),F(e.depthWrite),B(e.colorWrite),z(e.stencilWrite),W(e.drawBuffers)]):null}),(e=>({blending:f(e.blending),culling:p(e.culling),polygonOffset:g(e.polygonOffset),depthTest:v(e.depthTest),stencilTest:_(e.stencilTest),depthWrite:T(e.depthWrite),colorWrite:x(e.colorWrite),stencilWrite:A(e.stencilWrite),drawBuffers:E(e.drawBuffers)})))}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8943],{9775:(e,t,s)=>{s.d(t,{A:()=>i});var r=s(62788),n=s(95488);class i{constructor(e=e=>e.values().next().value){this._peeker=e,this._observable=new n.I,this._items=new Set}get length(){return(0,r.gc)(this._observable),this._items.size}clear(){0!==this.length&&(this._items.clear(),this._observable.notify())}last(){if(0===this.length)return;let e;for(e of this._items);return e}peek(){if(0!==this.length)return this._peeker(this._items)}push(e){this.contains(e)||(this._items.add(e),this._observable.notify())}contains(e){return(0,r.gc)(this._observable),this._items.has(e)}pop(){if(0===this.length)return;const e=this.peek();return this._items.delete(e),this._observable.notify(),e}popLast(){if(0===this.length)return;const e=this.last();return this._items.delete(e),this._observable.notify(),e}remove(e){this.contains(e)&&(this._items.delete(e),this._observable.notify())}filter(e){const t=this.length;return this._items.forEach((t=>{e(t)||this._items.delete(t)})),t!==this._items.size&&this._observable.notify(),this}*[Symbol.iterator](){(0,r.gc)(this._observable),yield*this._items}}},75503:(e,t,s)=>{s.d(t,{E:()=>v,w:()=>o});var r=s(4576),n=(s(44208),s(3694)),i=s(11006);class o{constructor(e=9,t){this._compareMinX=p,this._compareMinY=h,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),w.prune(),T.prune(),I.prune(),E.prune()}all(e){a(this._data,e)}search(e,t){let s=this._data;const r=this._toBBox;if(_(e,s))for(w.clear();s;){for(let n=0,i=s.children.length;n<i;n++){const i=s.children[n],o=s.leaf?r(i):i;_(e,o)&&(s.leaf?t(i):g(e,o)?a(i,t):w.push(i))}s=w.pop()}}collides(e){let t=this._data;const s=this._toBBox;if(!_(e,t))return!1;for(w.clear();t;){for(let r=0,n=t.children.length;r<n;r++){const n=t.children[r],i=t.leaf?s(n):n;if(_(e,i)){if(t.leaf||g(e,i))return!0;w.push(n)}}t=w.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,s=e.length;t<s;t++)this.insert(e[t]);return this}let t=this._build(e.slice(),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new A([]),this}remove(e){if(!e)return this;let t,s=this._data,n=null,i=0,o=!1;const a=this._toBBox(e);for(I.clear(),E.clear();s||I.length>0;){if(s||(s=I.pop(),n=I.data[I.length-1],i=E.pop()??0,o=!0),s.leaf&&(t=(0,r.qh)(s.children,e,s.children.length,s.indexHint),-1!==t))return s.children.splice(t,1),I.push(s),this._condense(I),this;o||s.leaf||!g(s,a)?n?(i++,s=n.children[i],o=!1):s=null:(I.push(s),E.push(i),i=0,n=s,s=s.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,s,r){const n=s-t+1;let i=this._maxEntries;if(n<=i){const r=new A(e.slice(t,s+1));return l(r,this._toBBox),r}r||(r=Math.ceil(Math.log(n)/Math.log(i)),i=Math.ceil(n/i**(r-1)));const o=new x([]);o.height=r;const a=Math.ceil(n/i),d=a*Math.ceil(Math.sqrt(i));b(e,t,s,d,this._compareMinX);for(let n=t;n<=s;n+=d){const t=Math.min(n+d-1,s);b(e,n,t,a,this._compareMinY);for(let s=n;s<=t;s+=a){const n=Math.min(s+a-1,t);o.children.push(this._build(e,s,n,r-1))}}return l(o,this._toBBox),o}_insert(e,t,s){const r=this._toBBox,n=s?e:r(e);I.clear();const i=function(e,t,s,r){for(;r.push(t),!0!==t.leaf&&r.length-1!==s;){let s,r=1/0,n=1/0;for(let i=0,o=t.children.length;i<o;i++){const o=t.children[i],a=c(o),l=m(e,o)-a;l<n?(n=l,r=a<r?a:r,s=o):l===n&&a<r&&(r=a,s=o)}t=s||t.children[0]}return t}(n,this._data,t,I);for(i.children.push(e),u(i,n);t>=0&&I.data[t].children.length>this._maxEntries;)this._split(I,t),t--;!function(e,t,s){for(let r=s;r>=0;r--)u(t.data[r],e)}(n,I,t)}_split(e,t){const s=e.data[t],r=s.children.length,n=this._minEntries;this._chooseSplitAxis(s,n,r);const i=this._chooseSplitIndex(s,n,r);if(!i)return;const o=s.children.splice(i,s.children.length-i),a=s.leaf?new A(o):new x(o);a.height=s.height,l(s,this._toBBox),l(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(s,a)}_splitRoot(e,t){this._data=new x([e,t]),this._data.height=e.height+1,l(this._data,this._toBBox)}_chooseSplitIndex(e,t,s){let r,n,i;r=n=1/0;for(let o=t;o<=s-t;o++){const t=d(e,0,o,this._toBBox),a=d(e,o,s,this._toBBox),l=f(t,a),u=c(t)+c(a);l<r?(r=l,i=o,n=u<n?u:n):l===r&&u<n&&(n=u,i=o)}return i}_chooseSplitAxis(e,t,s){const r=e.leaf?this._compareMinX:p,n=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,s,r)<this._allDistMargin(e,t,s,n)&&e.children.sort(r)}_allDistMargin(e,t,s,r){e.children.sort(r);const n=this._toBBox,i=d(e,0,t,n),o=d(e,s-t,s,n);let a=y(i)+y(o);for(let r=t;r<s-t;r++){const t=e.children[r];u(i,e.leaf?n(t):t),a+=y(i)}for(let r=s-t-1;r>=t;r--){const t=e.children[r];u(o,e.leaf?n(t):t),a+=y(o)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const s=e.data[t];if(0===s.children.length)if(t>0){const n=e.data[t-1],i=n.children;i.splice((0,r.qh)(i,s,i.length,n.indexHint),1)}else this.clear();else l(s,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function a(e,t){let s=e;for(T.clear();s;){if(!0===s.leaf)for(const e of s.children)t(e);else T.pushArray(s.children);s=T.pop()??null}}function l(e,t){d(e,0,e.children.length,t,e)}function d(e,t,s,r,n){n||(n=new A([])),n.minX=1/0,n.minY=1/0,n.maxX=-1/0,n.maxY=-1/0;for(let i,o=t;o<s;o++)i=e.children[o],u(n,e.leaf?r(i):i);return n}function u(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function p(e,t){return e.minX-t.minX}function h(e,t){return e.minY-t.minY}function c(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function y(e){return e.maxX-e.minX+(e.maxY-e.minY)}function m(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function f(e,t){const s=Math.max(e.minX,t.minX),r=Math.max(e.minY,t.minY),n=Math.min(e.maxX,t.maxX),i=Math.min(e.maxY,t.maxY);return Math.max(0,n-s)*Math.max(0,i-r)}function g(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function _(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function b(e,t,s,r,n){const o=[t,s];for(;o.length;){const t=o.pop(),s=o.pop();if(t-s<=r)continue;const a=s+Math.ceil((t-s)/r/2)*r;(0,i.q)(e,a,s,t,n),o.push(s,a,a,t)}}const w=new n.A,T=new n.A,I=new n.A,E=new n.A({deallocator:void 0});class v{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class M extends v{constructor(){super(...arguments),this.height=1,this.indexHint=new r.vW}}class A extends M{constructor(e){super(),this.children=e,this.leaf=!0}}class x extends M{constructor(e){super(),this.children=e,this.leaf=!1}}},10382:(e,t,s)=>{s.d(t,{A:()=>d});var r=s(36563),n=(s(44208),s(74887)),i=s(9775),o=s(72457),a=s(52268),l=s(61322);class d{constructor(){this._inUseClients=new Array,this._clients=new Array,this._clientPromises=new Array,this._ongoingJobsQueue=new i.A}destroy(){this.close()}get closed(){return!this._clients?.length}open(e,t){return new Promise(((s,r)=>{let i=!0;const o=e=>{(0,n.Te)(t.signal),i&&(i=!1,e())};this._clients.length=e.length,this._clientPromises.length=e.length,this._inUseClients.length=e.length;for(let i=0;i<e.length;++i){const a=e[i];(0,n.$X)(a)?this._clientPromises[i]=a.then((e=>(this._clients[i]=new l.default(e,t,this._ongoingJobsQueue),o(s),this._clients[i])),(()=>(o(r),null))):(this._clients[i]=new l.default(a,t,this._ongoingJobsQueue),this._clientPromises[i]=Promise.resolve(this._clients[i]),o(s))}}))}broadcast(e,t,s){const r=new Array(this._clientPromises.length);for(let n=0;n<this._clientPromises.length;++n){const i=this._clientPromises[n];r[n]=i.then((r=>r?.invoke(e,t,s)))}return r}close(){let e;for(;e=this._ongoingJobsQueue.pop();)e.resolver.reject((0,n.NK)(`Worker closing, aborting job calling '${e.methodName}'`));for(const e of this._clientPromises)e.then((e=>e?.close()));this._clients.length=0,this._clientPromises.length=0,this._inUseClients.length=0,(0,o.h)(this)}invoke(e,t,s){return this.apply(e,[t],s)}apply(e,t,s){const r=(0,n.Tw)();this._ongoingJobsQueue.push({methodName:e,data:t,invokeOptions:s,resolver:r});for(let e=0;e<this._clientPromises.length;e++){const t=this._clients[e];t?t.jobAdded():this._clientPromises[e].then((e=>e?.jobAdded()))}return r.promise}createInvokeProxy(e){return(0,a.L)(this,e)}on(e,t){return Promise.all(this._clientPromises).then((()=>(0,r.vE)(this._clients.map((s=>s.on(e,t))))))}openPorts(){return new Promise((e=>{const t=new Array(this._clientPromises.length);let s=t.length;for(let r=0;r<this._clientPromises.length;++r)this._clientPromises[r].then((n=>{n&&(t[r]=n.openPort()),0==--s&&e(t)}))}))}get test(){}}},72457:(e,t,s)=>{s.d(t,{h:()=>i,k:()=>n});const r=new FinalizationRegistry((e=>{e.close()}));function n(e,t){r.register(e,t,t)}function i(e){r.unregister(e)}},29953:(e,t,s)=>{s.d(t,{ho:()=>$});var r=s(49186),n=s(44208),i=s(74887),o=s(10382),a=s(72457),l=s(61322),d=s(53966),u=s(97768),p=s(78888),h=s(84952);const c={async request(e,t){const s=e.options,r=s.responseType;s.signal=t?.signal,s.responseType="native"===r||"native-request-init"===r?"native-request-init":r&&["blob","json","text"].includes(r)&&(0,h.sC)(e.url)?.after?r:"array-buffer";const n=await(0,p.A)(e.url,s),i={data:n.data,httpStatus:n.httpStatus,ssl:n.ssl};switch(n.requestOptions?.responseType){case"native-request-init":return delete i.data.signal,i;case"blob":i.data=await i.data.arrayBuffer();break;case"json":i.data=(new TextEncoder).encode(JSON.stringify(i.data)).buffer;break;case"text":i.data=(new TextEncoder).encode(i.data).buffer}return{result:i,transferList:[i.data]}}};var y=s(8341),m=s(2741),f=s(92602),g=(s(47566),s(70333));const _={};var b=s(26390);class w{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...s)=>e[t](...s)}))}}class T{constructor(){this._dispatcher=new w,this._workerPostMessage({type:y.Go.HANDSHAKE})}terminate(){}get onmessage(){return this._onmessageHandler}set onmessage(e){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler),this._onmessageHandler=e,e&&this.addEventListener("message",e)}get onmessageerror(){return this._onmessageerrorHandler}set onmessageerror(e){this._onmessageerrorHandler&&this.removeEventListener("messageerror",this._onmessageerrorHandler),this._onmessageerrorHandler=e,e&&this.addEventListener("messageerror",e)}get onerror(){return this._onerrorHandler}set onerror(e){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler),this._onerrorHandler=e,e&&this.addEventListener("error",e)}postMessage(e){(0,b.d)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,s){this._dispatcher.addEventListener(e,t,s)}removeEventListener(e,t,s){this._dispatcher.removeEventListener(e,t,s)}_workerPostMessage(e){(0,b.d)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,y.VI)(e);if(t&&t.type===y.Go.OPEN){const{modulePath:e,jobId:s}=t;let r=await l.default.loadWorker(e);r||(r=await import(e));const n=l.default.connect(r);this._workerPostMessage({type:y.Go.OPENED,jobId:s,data:n})}}}var I=s(73444),E=s(18357);const v=()=>d.A.getLogger("esri.core.workers.workerFactory"),{HANDSHAKE:M}=y.Go;let A,x;const S="Failed to create Worker. Fallback to execute module in main thread";async function N(e){return new Promise((t=>{function s(n){const i=(0,y.VI)(n);i&&i.type===M&&(e.removeEventListener("message",s),e.removeEventListener("error",r),t(e))}function r(t){t.preventDefault(),e.removeEventListener("message",s),e.removeEventListener("error",r),v().warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new T).addEventListener("message",s),e.addEventListener("error",r)}e.addEventListener("message",s),e.addEventListener("error",r)}))}let k=0;const{ABORT:L,INVOKE:R,OPEN:C,OPENED:D,RESPONSE:O}=y.Go;class B{static async create(e){const t=await async function(){if(!(0,n.A)("esri-workers"))return N(new T);if(!A&&!x)try{const e='let globalId=0;const outgoing=new Map,configuration={CONFIGURATION};self.esriConfig=configuration.esriConfig;const workerPath=self.esriConfig.workers.workerPath,HANDSHAKE=0,OPEN=1,OPENED=2,RESPONSE=3,INVOKE=4,ABORT=5;function createAbortError(){const e=new Error("Aborted");return e.name="AbortError",e}function receiveMessage(e){return e&&e.data?"string"==typeof e.data?JSON.parse(e.data):e.data:null}function invokeStaticMessage(e,o,r){const t=r&&r.signal,n=globalId++;let s=null;return new Promise(((r,i)=>{if(t){if(t.aborted)return i(createAbortError());s=()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:5,jobId:n}),i(createAbortError()))},t.addEventListener("abort",s)}outgoing.set(n,{resolve:r,reject:i}),self.postMessage({type:4,jobId:n,methodName:e,abortable:null!=t,data:o})})).finally((()=>{t&&t.removeEventListener("abort",s)}))}let workerRevisionChecked=!1;function checkWorkerRevision(e){if(!workerRevisionChecked&&e.kernelInfo){workerRevisionChecked=!0;const{revision:o,fullVersion:r}=configuration.kernelInfo,{revision:t,fullVersion:n,version:s}=e.kernelInfo;esriConfig.assetsPath!==esriConfig.defaultAssetsPath&&o!==t&&console.warn(`Version mismatch detected between ArcGIS Maps SDK for JavaScript modules and assets. For more information visit https://bit.ly/3QnsuSo.\nModules version: ${r}\nAssets version: ${n??s}\nAssets path: ${esriConfig.assetsPath}`)}}function messageHandler(e){const o=receiveMessage(e);if(!o)return;const r=o.jobId;switch(o.type){case 1:let n;function t(e){const o=n.connect(e);self.postMessage({type:2,jobId:r,data:o},[o])}"function"==typeof define&&define.amd?require([workerPath],(e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||new Promise((e=>{require([o.modulePath],e)})))).then(t)})):"System"in self&&"function"==typeof System.import?System.import(workerPath).then((e=>(n=e.default,checkWorkerRevision(n),n.loadWorker(o.modulePath)))).then((e=>e||System.import(o.modulePath))).then(t):esriConfig.workers.useDynamicImport?import(workerPath).then((e=>{n=e.default||e,checkWorkerRevision(n),n.loadWorker(o.modulePath).then((e=>e||import(o.modulePath))).then(t)})):(self.RemoteClient||importScripts(workerPath),n=self.RemoteClient.default||self.RemoteClient,checkWorkerRevision(n),n.loadWorker(o.modulePath).then(t));break;case 3:if(outgoing.has(r)){const s=outgoing.get(r);outgoing.delete(r),o.error?s.reject(JSON.parse(o.error)):s.resolve(o.data)}}}self.dojoConfig=configuration.loaderConfig,esriConfig.workers.loaderUrl&&(self.importScripts(esriConfig.workers.loaderUrl),"function"==typeof require&&"function"==typeof require.config&&require.config(configuration.loaderConfig)),self.addEventListener("message",messageHandler),self.postMessage({type:0});'.split("{CONFIGURATION}").join(function(){let e;if(null!=f.A.default){const t={...f.A};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(f.A));e.assetsPath=(0,h.s2)(e.assetsPath),e.defaultAssetsPath=e.defaultAssetsPath?(0,h.s2)(e.defaultAssetsPath):void 0,e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,I.JK)(),e.has={"esri-csp-restrictions":(0,n.A)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,n.A)("esri-2d-update-debug"),"esri-2d-log-updating":(0,n.A)("esri-2d-log-updating"),"featurelayer-pbf":(0,n.A)("featurelayer-pbf"),"featurelayer-fast-triangulation-enabled":(0,n.A)("featurelayer-fast-triangulation-enabled"),"featurelayer-simplify-thresholds":(0,n.A)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,n.A)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,n.A)("featurelayer-simplify-mobile-factor"),"featurelayer-query-max-depth":(0,n.A)("featurelayer-query-max-depth"),"featurelayer-query-pausing-enabled":(0,n.A)("featurelayer-query-pausing-enabled"),"featurelayer-snapshot-enabled":(0,n.A)("featurelayer-snapshot-enabled"),"esri-atomics":(0,n.A)("esri-atomics"),"esri-shared-array-buffer":(0,n.A)("esri-shared-array-buffer"),"esri-tiles-debug":(0,n.A)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,n.A)("esri-workers-arraybuffer-transfer"),"feature-polyline-generalization-factor":(0,n.A)("feature-polyline-generalization-factor"),"host-webworker":1},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,h.s2)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,h.s2)(e.workers.workerPath):e.workers.workerPath=(0,h.s2)((0,m.s)("esri/core/workers/RemoteClient.js")),e.workers.useDynamicImport=!1;const t=f.A.workers.loaderConfig,s=function(e){const t={async:e.async,isDebug:e.isDebug,locale:e.locale,baseUrl:e.baseUrl,has:{...e.has},map:{...e.map},packages:e.packages?.slice()||[],paths:{..._.paths,...e.paths}};return e.hasOwnProperty("async")||(t.async=!0),e.hasOwnProperty("isDebug")||(t.isDebug=!1),e.baseUrl||(t.baseUrl=_.baseUrl),t}({baseUrl:t?.baseUrl,locale:(0,I.JK)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...t?.has},map:{...t?.map},paths:{...t?.paths},packages:t?.packages||[]}),r={buildDate:E.$,fullVersion:g.ol,revision:E.u};return JSON.stringify({esriConfig:e,loaderConfig:s,kernelInfo:r})}());A=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){x=e||{}}let e;if(A)try{e=new Worker(A,{name:"esri-worker-"+k++})}catch(t){v().warn(S,x),e=new T}else v().warn(S,x),e=new T;return N(e)}();return new B(t,e)}constructor(e,t){this._outJobs=new Map,this._inJobs=new Map,this.worker=e,this.id=t,e.addEventListener("message",this._onMessage.bind(this)),e.addEventListener("error",(e=>{e.preventDefault(),d.A.getLogger("esri.core.workers.WorkerOwner").error(e)}))}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:s}=t,r=(0,y.Jc)();return new Promise(((t,n)=>{const o={resolve:t,reject:n,abortHandle:(0,i.NY)(s,(()=>{this._outJobs.delete(r),this._post({type:L,jobId:r})}))};this._outJobs.set(r,o),this._post({type:C,jobId:r,modulePath:e})}))}_onMessage(e){const t=(0,y.VI)(e);if(t)switch(t.type){case D:this._onOpenedMessage(t);break;case O:this._onResponseMessage(t);break;case L:this._onAbortMessage(t);break;case R:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,s=e.jobId,r=t.get(s);r&&(r.controller&&r.controller.abort(),t.delete(s))}_onInvokeMessage(e){const{methodName:t,jobId:s,data:r,abortable:n}=e,o=n?new AbortController:null,a=this._inJobs,l=c[t];let d;try{if("function"!=typeof l)throw new TypeError(`${t} is not a function`);d=l.call(null,r,{signal:o?o.signal:null})}catch(e){return void this._post({type:O,jobId:s,error:(0,y.mF)(e)})}(0,i.$X)(d)?(a.set(s,{controller:o,promise:d}),d.then((e=>{a.has(s)&&(a.delete(s),this._post({type:O,jobId:s},e))}),(e=>{a.has(s)&&(a.delete(s),e||(e={message:"Error encountered at method"+t}),(0,i.zf)(e)||this._post({type:O,jobId:s,error:(0,y.mF)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:O,jobId:s},d)}_onOpenedMessage(e){const{jobId:t,data:s}=e,r=this._outJobs.get(t);r&&(this._outJobs.delete(t),(0,u.xt)(r.abortHandle),r.resolve(s))}_onResponseMessage(e){const{jobId:t,error:s,data:n}=e,i=this._outJobs.get(t);i&&(this._outJobs.delete(t),(0,u.xt)(i.abortHandle),s?i.reject(r.A.fromJSON(JSON.parse(s))):i.resolve(n))}_post(e,t,s){return(0,y.u1)(this.worker,e,t,s)}}const F=(0,n.A)("host-browser")?Math.min(navigator.hardwareConcurrency-1,(0,n.A)("workers-pool-size")??8):0;let j=(0,n.A)("esri-mobile")?Math.min(F,3):F;j||(j=(0,n.A)("safari")&&(0,n.A)("mac")?7:2);let P=0;const q=[];async function G(e,t){const s=new o.A,{registryTarget:r,...n}=t;return await s.open(e,n),r&&(0,a.k)(r,s),s}async function $(e,t={}){if("string"!=typeof e)throw new r.A("workers:undefined-module","modulePath is missing");let s=t.strategy||"distributed";if((0,n.A)("host-webworker")&&!(0,n.A)("esri-workers")&&(s="local"),"local"===s){let s=await l.default.loadWorker(e);s||(s=await import(e)),(0,i.Te)(t.signal);const r=t.client||s;return G([l.default.connect(s,t.schedule)],{...t,client:r})}if(await async function(){if(U)return U;Z=new AbortController;const e=[];for(let t=0;t<j;t++){const s=B.create(t).then((e=>(q[t]=e,e)));e.push(s)}return U=Promise.all(e),U}(),(0,i.Te)(t.signal),"dedicated"===s){const s=P++%j;return G([await q[s].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const s=Math.min(t.maxNumWorkers,j);if(s<j){const r=new Array(s);for(let n=0;n<s;++n){const s=P++%j;r[n]=q[s].open(e,t)}return G(r,t)}}return G(q.map((s=>s.open(e,t))),t)}let Z,U=null},43334:(e,t,s)=>{s.d(t,{N3:()=>i,Om:()=>n});var r=s(92722);class n{constructor(e=null,t={},s,r){this.geometry=e,this.attributes=t,this.centroid=s,this.objectId=r,this.displayId=0,this.geohashX=0,this.geohashY=0}static fromJSON(e,t){const s=e.geometry?r.A.fromJSON(e.geometry):null,i=e.centroid?r.A.fromJSON(e.centroid):null,o=e.attributes[t];return new n(s,e.attributes,i,o)}weakClone(){const e=new n(this.geometry,this.attributes,this.centroid,this.objectId);return e.displayId=this.displayId,e.geohashX=this.geohashX,e.geohashY=this.geohashY,e}clone(){const e=this.geometry?.clone(),t=new n(e,{...this.attributes},this.centroid?.clone(),this.objectId);return t.displayId=this.displayId,t.geohashX=this.geohashX,t.geohashY=this.geohashY,t}}function i(e){return!!e.geometry?.coords?.length}},58512:(e,t,s)=>{s.d(t,{A:()=>r});class r{constructor(){this.objectIdFieldName=null,this.globalIdFieldName=null,this.geohashFieldName=null,this.geometryProperties=null,this.geometryType=null,this.spatialReference=null,this.hasZ=!1,this.hasM=!1,this.features=[],this.fields=[],this.transform=null,this.exceededTransferLimit=!1,this.uniqueIdField=null,this.queryGeometryType=null,this.queryGeometry=null}weakClone(){const e=new r;return e.objectIdFieldName=this.objectIdFieldName,e.globalIdFieldName=this.globalIdFieldName,e.geohashFieldName=this.geohashFieldName,e.geometryProperties=this.geometryProperties,e.geometryType=this.geometryType,e.spatialReference=this.spatialReference,e.hasZ=this.hasZ,e.hasM=this.hasM,e.features=this.features,e.fields=this.fields,e.transform=this.transform,e.exceededTransferLimit=this.exceededTransferLimit,e.uniqueIdField=this.uniqueIdField,e.queryGeometry=this.queryGeometry,e.queryGeometryType=this.queryGeometryType,e}}},92722:(e,t,s)=>{s.d(t,{A:()=>r});class r{constructor(e=[],t=[]){this.lengths=e??[],this.coords=t??[]}static fromJSON(e){return new r(e.lengths,e.coords)}static fromRect(e){const[t,s,n,i]=e,o=n-t,a=i-s;return new r([5],[t,s,o,0,0,a,-o,0,0,-a])}get isPoint(){return 0===this.lengths.length}get maxLength(){return Math.max(...this.lengths)}get size(){return this.lengths.reduce(((e,t)=>e+t))}forEachVertex(e){let t=0;this.lengths.length||e(this.coords[0],this.coords[1]);for(let s=0;s<this.lengths.length;s++){const r=this.lengths[s];for(let s=0;s<r;s++)e(this.coords[2*(s+t)],this.coords[2*(s+t)+1]);t+=r}}deltaDecode(){const e=this.clone(),{coords:t,lengths:s}=e;let r=0;for(const e of s){for(let s=1;s<e;s++)t[2*(r+s)]+=t[2*(r+s)-2],t[2*(r+s)+1]+=t[2*(r+s)-1];r+=e}return e}clone(e){if(0===this.lengths.length)return new r([],[this.coords[0],this.coords[1]]);const t=2*(0===this.lengths.length?1:this.lengths.reduce(((e,t)=>e+t))),s=this.coords.slice(0,t);return e?(e.set(s),new r(this.lengths,e)):new r(Array.from(this.lengths),Array.from(s))}}},6518:(e,t,s)=>{s.d(t,{F:()=>a});var r=s(44208),n=s(75503),i=s(19419);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new n.w(9,(0,r.A)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((s,r)=>{e[t++]=r})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,i.Ie)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,s){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,s)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},83221:(e,t,s)=>{s.d(t,{A:()=>y});var r=s(4576),n=s(49186),i=s(65529),o=s(53966),a=s(70328),l=s(19419),d=s(90708),u=s(6518),p=s(51441),h=s(37730);const c=(0,a.vt)();class y{constructor(e){this.geometryInfo=e,this._boundsStore=new u.F,this._featuresById=new Map,this.events=new i.A,this.featureAdapter=h.T}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach((t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,s,r,n]=this.fullBounds;return{xmin:t,ymin:s,xmax:r,ymax:n,spatialReference:(0,p.ag)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map((e=>this._upsert(e)));return this._emitChanged(),t.filter(r.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const s of e){const e=this._boundsStore.get(s.objectId);e&&t((0,a.Jt)(c,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const s=this._featuresById.get(t);let r;if(s?(e.displayId=s.displayId,r=this._boundsStore.get(t),this._boundsStore.delete(t)):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);r=(0,d.jQ)(null!=r?r:(0,l.vt)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=r&&this._boundsStore.set(t,r),this._featuresById.set(t,e)}_upsert(e){const t=e?.objectId;if(null==t)return o.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const s=this._featuresById.get(t);if(!s)return this._add(e),e;const{geometry:r,attributes:i}=e;for(const e in i)s.attributes[e]=i[e];return r&&(s.geometry=r,this._boundsStore.set(t,(0,d.jQ)((0,l.vt)(),r,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),s}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._boundsStore.delete(t),this._featuresById.delete(t),e}}},37730:(e,t,s)=>{s.d(t,{T:()=>o});var r=s(27647),n=s(43334),i=s(92722);const o={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new n.Om(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>(null==e.centroid&&(e.centroid=(0,r.Q)(new i.A,e.geometry,t.hasZ,t.hasM)),e.centroid)}},64714:(e,t,s)=>{s.d(t,{F0:()=>l,Vx:()=>p,e2:()=>c,f:()=>y});var r=s(44208),n=s(4718),i=s(99352),o=s(4071),a=s(93470);function l(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?a.Cb:"esriGeometryPolyline"===e?a.yM:a.WR}}}const d=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function p(e,t){if((0,r.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let s=`this${h(t)} = null;`;for(const t in e)s+=`this${h(t)} = ${JSON.stringify(e[t])};`;const r=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${s};\n }\n }\n `)();return()=>new r}catch(s){return()=>({[t]:null,...e})}}function h(e){return d.test(e)?`.${e}`:`["${e}"]`}function c(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,n.o8)(e)}}]}function y(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:i.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryBins:o.$,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},89270:(e,t,s)=>{var r;s.d(t,{x:()=>r}),function(e){e.MULTIPLIER="multiplier",e.ABSOLUTE="absoluteValue"}(r||(r={}))},80340:(e,t,s)=>{s.d(t,{P:()=>T});var r=s(90237),n=(s(59456),s(69622)),i=s(49186),o=s(53966),a=s(91869),l=s(39516),d=s(10107),u=(s(44208),s(87811),s(40608)),p=s(39829),h=s(57251),c=s(21325),y=s(85342),m=s(69860),f=s(45654),g=s(71402),_=s(42538),b=s(61956),w=s(5443);let T=class extends n.A{constructor(e){super(e),this._processingCacheUpdatesLookup=new Map,this.knowledgeGraph=null,this.inclusionModeDefinition={generateAllSublayers:!0,namedTypeDefinitions:new Map},this.entityTypeNames=new Set,this.relationshipTypeNames=new Set,this.geographicLookup=new Map,this.sublayerCaches=new Map,this.nodeConnectionsLookup=new Map,this.relationshipConnectionsLookup=new Map,this.memberIdTypeLookup=new Map;const t=new Map;e.knowledgeGraph.dataModel.entityTypes?.forEach((s=>{s.name&&(t.set(s.name,"entity"),this._processingCacheUpdatesLookup.set(s.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.entityTypeNames.add(s.name),s.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(s.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.knowledgeGraph.dataModel.relationshipTypes?.forEach((s=>{s.name&&(t.set(s.name,"relationship"),this._processingCacheUpdatesLookup.set(s.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.relationshipTypeNames.add(s.name),s.properties?.forEach((e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(s.name,{name:e.name??"",geometryType:e.geometryType})})))})),e.inclusionModeDefinition?.namedTypeDefinitions.forEach(((s,r)=>{if("entity"===t.get(r))this.entityTypeNames.add(r);else{if("relationship"!==t.get(r))return o.A.getLogger(this).warn(`A named type, ${r}, was in the inclusion list that wasn't in the data model and will be removed`),void e.inclusionModeDefinition?.namedTypeDefinitions.delete(r);this.relationshipTypeNames.add(r)}const n=new Map;s.members?.forEach((e=>{(0,a.tE)(this.memberIdTypeLookup,e.id,(()=>new Set)).add(r);const t=this.getById(e.id);t&&n.set(e.id,t)})),this.sublayerCaches.set(r,n)}))}addToLayer(e){e.forEach((({typeName:e,id:t})=>{if(!this.inclusionModeDefinition)throw new i.A("knowledge-graph:layer-data-manager","You cannot add to a layer's exclusion list if it was not created with an exclusion list originally");if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){if(this.inclusionModeDefinition.namedTypeDefinitions.has(e)){const s=this.inclusionModeDefinition.namedTypeDefinitions.get(e);s.members||(s.members=new Map),s.members.set(t,{id:t}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}else{const s=new Map;s.set(t,{id:t}),this.inclusionModeDefinition.namedTypeDefinitions.set(e,{useAllData:!1,members:s}),(0,a.tE)(this.memberIdTypeLookup,t,(()=>new Set)).add(e)}}))}getById(e){return m.A.getInstance().readFromStoreById(e)}async getData(e,t,s){if(t.objectType.name&&this.inclusionModeDefinition?.namedTypeDefinitions&&this.inclusionModeDefinition.namedTypeDefinitions.size>0&&!this.inclusionModeDefinition.namedTypeDefinitions.has(t.objectType.name))return[];let r;if(r=e||new b.A({where:"1=1",outFields:["*"]}),"link-chart"===t.parentCompositeLayer.type){const e=t.parentCompositeLayer,s=this._processingCacheUpdatesLookup.get(t.objectType.name??""),n=r.outFields;n&&1===n.length&&n[0]===y.dr&&"1=1"===r.where||await Promise.all(s??[]);const i=this.sublayerCaches.has(t.objectType.name??"")?Array.from(this.sublayerCaches.get(t.objectType.name)?.values()):[],o=[];return i.forEach((s=>{if(this.relationshipTypeNames.has(t.objectType.name)){s.geometry=e.relationshipLinkChartDiagramLookup.get(s.attributes[t.objectIdField]);const r=this.memberIdTypeLookup.get(s.attributes[y.Cz]),n=this.memberIdTypeLookup.get(s.attributes[y.KQ]),i=this._isEndEntitySpatial(r,s,y.Cz),o=this._isEndEntitySpatial(n,s,y.KQ);s.attributes[y.BL]=Number(i&&o)}else{s.geometry=e.entityLinkChartDiagramLookup.get(s.attributes[t.objectIdField]);const r=this.geographicLookup.get(t.objectType.name);r&&s.attributes[r.name]?s.attributes[y.BL]=1:s.attributes[y.BL]=0}s.attributes[y.T1]=s.geometry,o.push(s)})),o}return this.retrieveDataFromService(r,t,s)}async getConnectedRecordIds(e,t){const s=[];let r="";const n=this._getNamedTypeIdMapFromNodeIds(e);if(t&&0!==t?.length){for(const e of t)r=r+e+"|";r=r.slice(0,-1)}const i={},a=[];for(const[e,s]of n){const n=`${e}_ids`;i[n]=s,t&&0!==t?.length?a.push(`MATCH (n:${e}) WHERE id(n) IN $${n} WITH n MATCH (n)-[r:${r}]-(m) RETURN id(r), type(r), id(m), labels(m)[0]`):a.push(`MATCH (n:${e}) WHERE id(n) IN $${n} WITH n MATCH (n)-[r]-(m) RETURN id(r), type(r), id(m), labels(m)[0]`)}if(!a.length)return s;const l=a.join(" UNION "),d=(await(0,g.executeQueryStreaming)(this.knowledgeGraph,new _.A({openCypherQuery:l,bindParameters:i}))).resultRowsStream.getReader();try{for(;;){const{done:e,value:t}=await d.read();if(e)break;for(let e=0;e<t.length;e++){const r=t[e];s.push({id:r[0],typeName:r[1]}),s.push({id:r[2],typeName:r[3]})}}}catch(e){if("AbortError"!==e.name)throw e;o.A.getLogger(this).info("Request aborted as expected")}return s}async getRelationshipsBetweenNodes(e,t){const s=this._getNamedTypeIdMapFromNodeIds(e);if(0===s.size)return[];const r={relationshipExclusionIds:t,possibleConnectionEntityIds:e},n=[];for(const[e,t]of s.entries()){const s=`${e}_ids`;r[s]=t,n.push(`MATCH (n:${e}) WHERE id(n) IN $${s} WITH n MATCH (n)-[r]->(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const i=n.join(" UNION "),a=[],l=(await(0,g.executeQueryStreaming)(this.knowledgeGraph,new _.A({openCypherQuery:i,bindParameters:r}))).resultRowsStream.getReader();try{for(;;){const{done:e,value:t}=await l.read();if(e)break;for(let e=0;e<t.length;e++){const s=t[e];a.push({id:s[0],typeName:s[1]})}}}catch(e){if("AbortError"!==e.name)throw e;o.A.getLogger(this).info("Request aborted as expected")}return a}async getRelationshipsFromNodes(e,t,s){const r=this._getNamedTypeIdMapFromNodeIds(e);if(0===r.size||0===t.length)return[];const n={relationshipExclusionIds:s,possibleConnectionEntityIds:t},i=[];for(const[e,t]of r.entries()){const s=`${e}_ids`;n[s]=t,i.push(`MATCH (n:${e}) WHERE id(n) IN $${s} WITH n MATCH (n)-[r]-(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const a=i.join(" UNION "),l=new Map,d=(await(0,g.executeQueryStreaming)(this.knowledgeGraph,new _.A({openCypherQuery:a,bindParameters:n}))).resultRowsStream.getReader();try{for(;;){const{done:e,value:t}=await d.read();if(e)break;for(let e=0;e<t.length;e++){const s=t[e];let r=l.get(s[1]);r||(r=new Set,l.set(s[1],r)),r.add(s[0])}}}catch(e){if("AbortError"!==e.name)throw e;o.A.getLogger(this).info("Request aborted as expected")}const u=[];for(const[e,t]of l)for(const s of t)u.push({id:s,typeName:e});return u}async refreshCacheContent(e,t,s,r=!0){const n=m.A.getInstance(),o=[],l=new Map,d=new Map;this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&d.set(e.name,e)})),this.knowledgeGraph.dataModel.relationshipTypes?.forEach((e=>{e.name&&d.set(e.name,e)})),e||this.inclusionModeDefinition?e?e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const t of this.memberIdTypeLookup.get(e))l.has(t)?l.get(t)?.push(e):l.set(t,[e])})):this.inclusionModeDefinition?.namedTypeDefinitions?.forEach(((e,t)=>{e.useAllData?l.set(t,null):e.members&&e.members.forEach((e=>{l.has(t)&&null!==l.get(t)?l.get(t)?.push(e.id):l.set(t,[e.id])}))})):(this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&l.set(e.name,null)})),this.knowledgeGraph.dataModel.entityTypes?.forEach((e=>{e.name&&l.set(e.name,null)})));for(const[e,u]of l){const l=new Promise((o=>{(async()=>{const o=new Set,l=[];let p,h="",c=!1;if(t||d.get(e)?.properties?.forEach((e=>{e.name&&o.add(e.name)})),s&&this.geographicLookup.has(e)){const t=this.geographicLookup.get(e)?.name;t&&o.add(t)}if(this.entityTypeNames.has(e))h=`MATCH (n:${e}) ${u?"WHERE id(n) IN $ids ":""}return ID(n)`,o.forEach((e=>{h+=`, n.${e}`,l.push(e)}));else{if(!this.relationshipTypeNames.has(e))throw new i.A("knowledge-graph:layer-data-manager",`The graph type of ${e} could not be determined. Was this type set in the KG data model and inclusion definition?`);c=!0,h=`MATCH ()-[n:${e}]->() ${u?"WHERE id(n) IN $ids ":""}return ID(n), id(startNode(n)), id(endNode(n))`,o.forEach((e=>{h+=`, n.${e}`,l.push(e)}))}p=new _.A(u?{openCypherQuery:h,bindParameters:{ids:u}}:{openCypherQuery:h});const m=(await(0,g.executeQueryStreaming)(this.knowledgeGraph,p)).resultRowsStream.getReader();for(;;){const{done:t,value:s}=await m.read();if(t)break;const i=[];for(let e=0;e<s.length;e++){const t=s[e];let r=0,n=0;const o={properties:{}};for(o.id=t[r],r++,n++,c&&(o.originId=t[r],r++,n++,o.destinationId=t[r],r++,n++,(0,a.tE)(this.nodeConnectionsLookup,o.originId,(()=>new Set)).add(o.id),(0,a.tE)(this.nodeConnectionsLookup,o.destinationId,(()=>new Set)).add(o.id),(0,a.tE)(this.relationshipConnectionsLookup,o.id,(()=>[o.originId,o.destinationId])));r<t.length;r++)o.properties[l[r-n]]=t[r];i.push(o)}const o=n.writeToStore(i,y.dr,this.geographicLookup.get(e)?.name);this.sublayerCaches.has(e)||this.sublayerCaches.set(e,new Map),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.has(e)&&this.inclusionModeDefinition?.namedTypeDefinitions.set(e,{useAllData:!1,members:new Map}),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members&&(this.inclusionModeDefinition.namedTypeDefinitions.get(e).members=new Map);const d=this.sublayerCaches.get(e);o.forEach((t=>{d?.set(t.attributes[y.dr],t),r&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.has(t.attributes[y.dr])&&(this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.set(t.attributes[y.dr],{id:t.attributes[y.dr]}),(0,a.tE)(this.memberIdTypeLookup,t.attributes[y.dr],(()=>new Set)).add(e))}))}})().then((()=>{o(null)}))}));o.push(l),this._processingCacheUpdatesLookup.get(e)?.push(l)}await Promise.all(o)}removeFromLayer(e){const t=new Set,s=new Set(e.map((e=>e.id)));for(const s of e)t.add(s.typeName),1===this.memberIdTypeLookup.get(s.id)?.size?this.memberIdTypeLookup.delete(s.id):this.memberIdTypeLookup.get(s.id)?.delete(s.typeName),this.inclusionModeDefinition?.namedTypeDefinitions.forEach(((e,t)=>{t===s.typeName&&e.members?.has(s.id)&&e.members.delete(s.id)}));t.forEach((e=>{this.sublayerCaches.get(e)?.forEach(((t,r)=>{s.has(r)&&this.sublayerCaches.get(e)?.delete(r)}))}))}async retrieveDataFromService(e,t,s){const r=m.A.getInstance(),n=new Set,o=[];let a,d="",u=[];const b="relationship"===t.graphType,T=this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData,I=t.parentCompositeLayer.sublayerIdsCache.get(t.objectType.name);let E=!T&&I?Array.from(I).sort():null;if(this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData)this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData&&null!=e.objectIds&&(E=e.objectIds);else if(null!=e.objectIds&&E&&E.length>0){const t=e.objectIds;e.objectIds=E.filter((e=>t.includes(e)))}else if(null!=e.objectIds)E=e.objectIds;else{if(this.inclusionModeDefinition?.namedTypeDefinitions.has(t.objectType.name)&&(!this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members||this.inclusionModeDefinition.namedTypeDefinitions.get(t.objectType.name)?.members?.size<1))return e.objectIds=[],[];e.objectIds=E}if(null!=e.outFields){const s=e.outFields;s.includes("*")?t.fields.forEach((e=>{n.add(e.name)})):s.forEach((e=>{e!==y.dr&&e!==t.geometryFieldName&&n.add(e)}))}if(null!=e.geometry){const s=e.geometry;let r;const u=t.parentCompositeLayer.dataManager.knowledgeGraph.serviceDefinition,y=u?.spatialReference,m=u?.serviceCapabilities?.geometryCapabilities;let g=m?.geometryMaxBoundingRectangleSizeX,T=m?.geometryMaxBoundingRectangleSizeY;if("point"===s.type){let e=s;e.spatialReference?.isWGS84||(await(0,h.initializeProjection)(e.spatialReference,c.KK),e=(0,h.project)(e,c.KK)),r=new w.A({spatialReference:c.KK,xmin:e.x-1e-4,ymin:e.y-1e-4,xmax:e.x+1e-4,ymax:e.y+1e-4})}else s?.extent?.spatialReference&&!s.spatialReference?.isWGS84?(await(0,h.initializeProjection)(s.extent.spatialReference,c.KK),r=(0,h.project)(s.extent,c.KK)):r=s.extent;if(g&&T&&y){if(4326!==y.wkid){const e=new w.A({spatialReference:y,xmax:g,ymax:T}),t=(0,h.project)(e,c.KK);g=t.xmax,T=t.ymax}if(r.xmax-r.xmin>g)throw new i.A("knowledge-graph:layer-data-manager",`Extent x bounds should be within ${g}° latitude, limit exceeded`);if(r.ymax-r.ymin>T)throw new i.A("knowledge-graph:layer-data-manager",`Extent y bounds should be within ${T}° longitude, limit exceeded`)}if(null!=e.where&&"1=1"!==e.where){const s=await(0,l.G)(e.where.toUpperCase(),t.fieldsIndex);t.fields.forEach((e=>{s.fieldNames.includes(e.name)&&n.add(e.name)}))}d=b?`Match ()-[n:${t.objectType.name}]->() WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n), id(startNode(r)), id(endNode(r))`:`Match (n:${t.objectType.name}) WHERE esri.graph.ST_Intersects($param_filter_geom, n.${t.geometryFieldName}) return ID(n)`,t.geometryFieldName&&n.add(t.geometryFieldName),n.forEach((e=>{d+=`, n.${e}`,o.push(e)})),a=new _.A({openCypherQuery:d,bindParameters:{param_filter_geom:new p.A({rings:(0,f.DX)(r)})}})}else{let s="";if(null!=e.where&&"1=1"!==e.where){const r=await(0,l.G)(e.where,t.fieldsIndex);t.fields.forEach((e=>{r.fieldNames.includes(e.name)&&n.add(e.name)}));const i=new Set(["column-reference","string","number","binary-expression"]),o=new Set(["=","<","<=","<>",">",">=","AND","OR","LIKE"]);let a=!1;const d=e=>{if("column-reference"===e.type)return`n.${e.column}`;if("string"===e.type)return`'${e.value}'`;if("number"===e.type)return`${e.value}`;if("binary-expression"===e.type&&i.has(e.left.type)&&i.has(e.right.type)&&o.has(e.operator))return`${d(e.left)} ${e.operator} ${d(e.right)}`;if("binary-expression"===e.type&&"LIKE"===e.operator){let t="";if("function"===e.left.type&&"column-reference"===e.left.args.value[0].type)t+=`lower(n.${e.left.args.value[0].column})`;else{if("column-reference"!==e.left.type)return a=!0,"";t+=`lower(n.${e.left.column})`}if(t+=" CONTAINS (","string"!==e.right.type)return a=!0,"";{let s=e.right.value;"%"===s.charAt(0)&&(s=s.slice(1)),"%"===s.charAt(s.length-1)&&(s=s.slice(0,-1)),t+=`'${s.toLowerCase()}')`}return t}return a=!0,""};s=d(r.parseTree),a&&(s="")}let r="";r=b?`Match ()-[n:${t.objectType.name}]->()`:`Match (n:${t.objectType.name})`;let i=!1;E&&(i=!0,r+=" WHERE ID(n) IN $ids"),s&&(r+=i?" AND":" WHERE",r+=` ${s}`),r+=" return ID(n)",b&&(r+=", id(startNode(n)), id(endNode(n))"),e.returnGeometry&&t.geometryFieldName&&n.add(t.geometryFieldName),n.forEach((e=>{r+=`, n.${e}`,o.push(e)})),a=new _.A(E?{openCypherQuery:r,bindParameters:{ids:E}}:{openCypherQuery:r})}const v=(await(0,g.executeQueryStreaming)(t.parentCompositeLayer.dataManager.knowledgeGraph,a,s)).resultRowsStream.getReader();for(;;){const{done:e,value:s}=await v.read();if(e)break;const n=[];for(let e=0;e<s.length;e++){const t=s[e];let r=0,i=0;const a={properties:{}};for(a.id=t[r],r++,i++,b&&(a.originId=t[r],r++,i++,a.destinationId=t[r],r++,i++);r<t.length;r++)a.properties[o[r-i]]=t[r];n.push(a)}u=u.concat(r.writeToStore(n,y.dr,t.parentCompositeLayer.dataManager.geographicLookup.get(t.objectType.name)?.name))}return u}_isEndEntitySpatial(e,t,s){for(const r of e??[])if(this.entityTypeNames.has(r)){const e=this.geographicLookup.get(r),n=e&&this.sublayerCaches.get(r)?.get(t.attributes[s]);if(e&&n?.attributes[e.name])return!0}return!1}_getNamedTypeIdMapFromNodeIds(e){const t=new Map;return e.forEach((e=>{if(this.memberIdTypeLookup.has(e))for(const s of this.memberIdTypeLookup.get(e)){if(!this.entityTypeNames.has(s))return;t.has(s)?t.get(s)?.push(e):t.set(s,[e])}})),t}};(0,r._)([(0,d.MZ)()],T.prototype,"knowledgeGraph",void 0),(0,r._)([(0,d.MZ)()],T.prototype,"inclusionModeDefinition",void 0),(0,r._)([(0,d.MZ)()],T.prototype,"entityTypeNames",void 0),(0,r._)([(0,d.MZ)()],T.prototype,"relationshipTypeNames",void 0),(0,r._)([(0,d.MZ)()],T.prototype,"geographicLookup",void 0),(0,r._)([(0,d.MZ)()],T.prototype,"sublayerCaches",void 0),(0,r._)([(0,d.MZ)()],T.prototype,"nodeConnectionsLookup",void 0),(0,r._)([(0,d.MZ)()],T.prototype,"relationshipConnectionsLookup",void 0),(0,r._)([(0,d.MZ)()],T.prototype,"memberIdTypeLookup",void 0),T=(0,r._)([(0,u.$)("esri.layers.knowledgeGraph.KnowledgeGraphLayerDataManager")],T)},70643:(e,t,s)=>{s.d(t,{A:()=>V});var r=s(90237),n=(s(59456),s(13874)),i=(s(86162),s(94409),s(65345),s(42980),s(20917),s(92438),s(96576),s(93618),s(65494)),o=s(15036),a=s(4718),l=s(92071),d=(s(29953),s(10107)),u=(s(44208),s(53966),s(40608)),p=s(43937),h=s(35666),c=s(57251),y=s(16930),m=s(21325),f=s(4146),g=s(83221),_=s(88856),b=s(64714);s(87811);const w=(0,s(17036).p)(),T=e=>{let t=class extends e{constructor(){super(...arguments),this.fields=[],this.fieldsIndex=null}};return(0,r._)([(0,d.MZ)(w.fields)],t.prototype,"fields",void 0),(0,r._)([(0,d.MZ)(w.fieldsIndex)],t.prototype,"fieldsIndex",void 0),t=(0,r._)([(0,u.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayerBase")],t),t};var I=s(85342),E=s(63074),v=s(87718),M=s(76294),A=s(32756),x=s(54310),S=s(25036),N=s(82935),k=s(10873),L=s(13213),R=s(20437),C=s(30524),D=s(81457),O=s(39383),B=s(96184),F=s(22671),j=s(61956),P=s(30291),q=s(61322),G=s(5443),$=s(39829),Z=s(82799),U=s(86738),H=s(50498);function Y(e){if(!e.json)return e;e.json.write=Q(e.json.write);const t=e.json.origins;if(!t)return e;let s;for(s in t){const e=t[s];e&&(e.write=Q(e.write))}return e}function Q(e){return"object"==typeof e&&e?(!1!==e.enabled&&(e.overridePolicy=function(e){const{target:t,writer:s,overridePolicy:r,...n}=e;return function(e,t){const s=J.call(this,e,t);return s.enabled?{...n,...s}:s}}(e)),e):!0===e?z():e}function z(){return{overridePolicy:J}}function J(e,t){const s=!!this.geometryType;let r={enabled:s};return s&&(r={...r,...W.call(this,e,t)}),r}function W(e,t){return{ignoreOrigin:this.originIdOf(t)>h.Gr.DEFAULTS}}let X=class extends(T((0,M.J)((0,v.F)((0,E.dM)((0,A.f)((0,N.e)((0,S.j)((0,x.J)((0,l.P)(f.A)))))))))){constructor(e){super(e),this.blendMode="normal",this.capabilities=(0,b.f)(!1,!1),this.charts=null,this.definitionExpression=null,this.displayField="",this.effect=null,this.elevationInfo=null,this.featureEffect=null,this.graphType=null,this.labelsVisible=!0,this.labelingInfo=null,this.layerType=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.objectIdField=I.dr,this.objectType=null,this.opacity=1,this.orderBy=null,this.parent=null,this.parentCompositeLayer=null,this.persistenceEnabled=!0,this.popupEnabled=!0,this.popupTemplate=null,this.refreshInterval=0,this.source={openPorts:()=>this.load().then((()=>{const e=new MessageChannel;return new q.default(e.port1,{channel:e,client:{queryFeatures:(e,t={})=>{const s=j.A.fromJSON(e);return this.queryFeaturesJSON(s,t)}}}),[e.port2]}))},this.type="knowledge-graph-sublayer",this.useViewTime=!0,this.visible=!0}get defaultPopupTemplate(){return this.createPopupTemplate()}set featureReduction(e){const t=this._normalizeFeatureReduction(e);this._set("featureReduction",t)}get fields(){const e=[];return this.objectType?.properties?.forEach((t=>{const s="esriFieldTypeOID"===t.fieldType?"esriFieldTypeInteger":t.fieldType;e.push(R.A.fromJSON({name:t.name,type:s,alias:t.alias,defaultValue:t.defaultValue,editable:t.editable,nullable:t.nullable}))})),e.push(R.A.fromJSON({name:this.objectIdField,type:"esriFieldTypeString",alias:this.objectIdField,editable:!1}),R.A.fromJSON({name:I.M1,type:"esriFieldTypeInteger",alias:I.M1,editable:!1}),R.A.fromJSON({name:I.BL,type:"esriFieldTypeInteger",alias:I.BL,editable:!1})),e}get geometryType(){if("link-chart"===this.parentCompositeLayer?.type)return"relationship"===this.graphType?"polyline":"point";const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.geometryType;return t&&"esriGeometryNull"!==t?H.g.fromJSON(t):null}get geometryFieldName(){if("link-chart"===this.parentCompositeLayer?.type)return I.T1;const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name);return e?.name??null}get graphTypeName(){return this.objectType?.name}get hasM(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,s=t?this.objectType?.properties?.[t]:null;return s?.hasM??!1}get hasZ(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,s=t?this.objectType?.properties?.[t]:null;return s?.hasZ??!1}set renderer(e){(0,C.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){return this._isOverridden("renderer")?this._get("renderer"):"link-chart"===this.parentCompositeLayer?.type?"relationship"===this.graphType?(0,i.r)((0,b.F0)(H.g.toJSON("polyline")).renderer):(0,i.r)((0,b.F0)(H.g.toJSON("point")).renderer):(0,i.r)((0,b.F0)(H.g.toJSON(this.geometryType)).renderer)}get spatialReference(){return this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel?.spatialReference??y.A.WGS84}set timeInfo(e){this._set("timeInfo",e)}get title(){return this._isOverridden("title")?this._get("title"):this.graphTypeName}set title(e){this._set("title",e)}writeTitle(e,t){t.title=e??"Layer"}createPopupTemplate(e){return(0,P.tn)(this,e)}createQuery(){return new j.A({where:"1=1",outFields:["*"]})}getField(e){for(let t=0;t<this.fields.length;t++)if(this.fields[t].name===e)return this.fields[t];return null}getFieldDomain(e,t){return null}async queryFeatures(e,t){const{resolvedQuery:s,queryEngine:r}=await this._setupQueryObjects(e),n=F.A.fromJSON(await r.executeQuery(s.toJSON(),t?.signal));return n.features.forEach((e=>{e.sourceLayer=this})),n}async queryFeaturesJSON(e,t){const{resolvedQuery:s,queryEngine:r}=await this._setupQueryObjects(e);return await r.executeQuery(s.toJSON(),t?.signal)}async queryFeatureCount(e,t){const{resolvedQuery:s,queryEngine:r}=await this._setupQueryObjects(e);return r.executeQueryForCount(s.toJSON(),t?.signal)}async queryExtent(e={},t){const s={...e,returnGeometry:!0},{resolvedQuery:r,queryEngine:n}=await this._setupQueryObjects(s),i=await n.executeQueryForExtent(r.toJSON(),t?.signal);let o;return o=null!=i.extent?.xmin&&null!=i.extent?.xmax&&null!=i.extent?.ymin&&null!=i.extent?.ymax?new G.A(i.extent):new G.A,{count:i.count,extent:o}}async queryObjectIds(e,t){const s=j.A.from(e);let r;if("link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)r=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(s,this,t);r=this.loadQueryEngine(e)}return r.executeQueryForIds(s.toJSON(),t?.signal)}loadQueryEngine(e){const t=new g.A({geometryType:H.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ}),s=new _.d({fieldsIndex:this.fieldsIndex.toJSON(),geometryType:H.g.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ,objectIdField:this.objectIdField,spatialReference:this.spatialReference.toJSON(),timeInfo:this.timeInfo?.toJSON(),featureStore:t});return s.featureStore.addMany(e),s}async refreshCachedQueryEngine(){const e=await this.parentCompositeLayer.dataManager.getData(new j.A({where:"1=1",outFields:[I.dr]}),this);this._cachedQueryEngine=this.loadQueryEngine(e)}load(e){return this.addResolvingPromise(this.parent.load(e).then((()=>{(0,C.sv)(this.timeInfo,this.fieldsIndex)}))),Promise.resolve(this)}async _setupQueryObjects(e,t){const s=j.A.from(e),r=s.geometry;let n;if(r&&!r.spatialReference?.isWGS84&&(await(0,c.initializeProjection)(r.spatialReference,m.KK),s.geometry=(0,c.project)(r instanceof $.A||r instanceof Z.A||r instanceof U.A?r:r.extent,m.KK)),"link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)n=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(s,this,t);n=this.loadQueryEngine(e)}return{resolvedQuery:s,queryEngine:n}}};(0,r._)([(0,d.MZ)(Y((0,a.o8)(E.sU)))],X.prototype,"blendMode",void 0),(0,r._)([(0,d.MZ)()],X.prototype,"capabilities",void 0),(0,r._)([(0,d.MZ)({json:{origins:{"web-scene":{write:!1}},write:z()}})],X.prototype,"charts",void 0),(0,r._)([(0,d.MZ)({readOnly:!0})],X.prototype,"defaultPopupTemplate",null),(0,r._)([(0,d.MZ)({type:String,json:{origins:{service:{read:!1}},name:"layerDefinition.definitionExpression",write:{ignoreOrigin:!0}}})],X.prototype,"definitionExpression",void 0),(0,r._)([(0,d.MZ)()],X.prototype,"displayField",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(E.LF)))],X.prototype,"effect",void 0),(0,r._)([(0,d.MZ)()],X.prototype,"elevationInfo",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(v.Y)))],X.prototype,"featureEffect",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(L.d)))],X.prototype,"featureReduction",null),(0,r._)([(0,d.MZ)()],X.prototype,"fields",null),(0,r._)([(0,d.MZ)()],X.prototype,"geometryType",null),(0,r._)([(0,d.MZ)()],X.prototype,"geometryFieldName",null),(0,r._)([(0,d.MZ)({type:["entity","relationship"],nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],X.prototype,"graphType",void 0),(0,r._)([(0,d.MZ)({type:String,nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],X.prototype,"graphTypeName",null),(0,r._)([(0,d.MZ)()],X.prototype,"hasM",null),(0,r._)([(0,d.MZ)()],X.prototype,"hasZ",null),(0,r._)([(0,d.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],X.prototype,"id",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(k.kF)))],X.prototype,"labelsVisible",void 0),(0,r._)([(0,d.MZ)({type:[D.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:O.w,write:z()}})],X.prototype,"labelingInfo",void 0),(0,r._)([(0,d.MZ)({readOnly:!0,json:{read:!1,write:{writer(e,t){switch(this.parentCompositeLayer.type){case"link-chart":t.layerType="LinkChartSubLayer";break;case"knowledge-graph":t.layerType=this.geometryType?"KnowledgeGraphSubLayer":"KnowledgeGraphSubTable"}},isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],X.prototype,"layerType",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(k.fV)))],X.prototype,"legendEnabled",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(k.hG)))],X.prototype,"maxScale",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(k.hn)))],X.prototype,"minScale",void 0),(0,r._)([(0,d.MZ)()],X.prototype,"objectIdField",void 0),(0,r._)([(0,d.MZ)()],X.prototype,"objectType",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(k.ke)))],X.prototype,"opacity",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(A.n)))],X.prototype,"orderBy",void 0),(0,r._)([(0,d.MZ)({clonable:!1})],X.prototype,"parent",void 0),(0,r._)([(0,d.MZ)()],X.prototype,"parentCompositeLayer",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(k.M6)))],X.prototype,"popupEnabled",void 0),(0,r._)([(0,d.MZ)({type:n.A,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],X.prototype,"popupTemplate",void 0),(0,r._)([(0,d.MZ)({type:Number,json:{write:{overridePolicy:W}}})],X.prototype,"refreshInterval",void 0),(0,r._)([(0,d.MZ)({types:o.H,json:{name:"layerDefinition.drawingInfo.renderer",write:z()}})],X.prototype,"renderer",null),(0,r._)([(0,d.MZ)()],X.prototype,"source",void 0),(0,r._)([(0,d.MZ)()],X.prototype,"spatialReference",null),(0,r._)([(0,d.MZ)({type:B.A,json:{name:"layerDefinition.timeInfo",write:!0,origins:{"web-document":{name:"layerDefinition.timeInfo",read:!0,write:!0},"portal-item":{name:"layerDefinition.timeInfo",read:!0,write:!0}}}})],X.prototype,"timeInfo",null),(0,r._)([(0,d.MZ)({type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],X.prototype,"title",null),(0,r._)([(0,p.K)("title")],X.prototype,"writeTitle",null),(0,r._)([(0,d.MZ)({json:{read:!1}})],X.prototype,"type",void 0),(0,r._)([(0,d.MZ)(Y((0,a.o8)(N.B)))],X.prototype,"useViewTime",void 0),(0,r._)([(0,d.MZ)({type:Boolean,json:{name:"visibility",write:z()}})],X.prototype,"visible",void 0),X=(0,r._)([(0,u.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayer")],X);const V=X},69860:(e,t,s)=>{s.d(t,{A:()=>a}),s(59456);var r=s(90708),n=s(43334),i=s(85342),o=s(65864);class a{constructor(){this._featureLookup=new Map}static getInstance(){return a.instance||(a.instance=new a),a.instance}static resetInstance(){a.instance&&(a.instance=null)}deleteFromStore(e){e.forEach((e=>{this._featureLookup.delete(e)}))}readFromStoreByList(e){const t=[];return e.forEach((e=>{const s=this.readFromStoreById(e);s&&t.push(s)})),t}readFromStoreById(e){return this._featureLookup.get(e)??null}writeToStore(e,t,s){const a=[];return e.forEach((e=>{if(!e?.id)return;e.properties||(e.properties=[]);let l,d=null;if(s&&e.properties[s]&&(d=(0,r.Ux)(e.properties[s])),"originId"in e&&"destinationId"in e&&(e.properties[i.Cz]=e.originId,e.properties[i.KQ]=e.destinationId),e.properties[t]=e.id,e.id&&this._featureLookup.has(e.id)&&this._featureLookup.get(e.id).attributes){const r=this._featureLookup.get(e.id),i=JSON.parse(JSON.stringify(Object.assign(r.attributes,e.properties)));s&&e.properties[s]&&(i[s]=(0,o.rS)(e.properties[s])),l=new n.Om(d?JSON.parse(JSON.stringify(d)):r?.geometry?JSON.parse(JSON.stringify(r.geometry)):null,i,null,e.properties[t])}else l=new n.Om(d?JSON.parse(JSON.stringify(d)):null,e.properties,null,e.properties[t]);this._featureLookup.set(`${e.typeName?`${e.typeName}__${e.id}`:e.id}`,l),a.push(l)})),a}}},85342:(e,t,s)=>{s.d(t,{BL:()=>d,Cz:()=>i,KQ:()=>o,M1:()=>l,T1:()=>a,dr:()=>n,qN:()=>h});var r=s(71402);const n="ESRI__ID",i="ESRI__OriginID",o="ESRI__DestID",a="ESRI__LayoutGeometry",l="ESRI__AggregationCount",d="LC.ESRI__IsSpatial",u={initializeLayersFromClientData:async(e,t)=>{if(t||(t=[...e.layers,...e.tables].map((e=>e.graphTypeName))),0===t?.length)return;const s=new Map;for(const r of t)s.set(r,p(e,r));const n=await(0,r.fetchClientDataAtKeys)(e.dataManager.knowledgeGraph,Array.from(s.values()));for(const t of[...e.layers,...e.tables]){const s=t.objectType.name;if(null===s)continue;const r=n.get(p(e,s));if(r){const e=JSON.parse(r);null===e||"object"!=typeof e||e.hasOwnProperty("showLabels")||(e.showLabels=!1),t.read(e,{origin:"service"})}}}},p=(e,t)=>"knowledge-graph"===e.type?`${t}/Map`:`${t}/LinkChart/LinkChartSubLayer`;async function h(e,t){return u.initializeLayersFromClientData(e,t)}},45654:(e,t,s)=>{s.d(t,{fz:()=>H,k1:()=>U,DX:()=>F,_s:()=>P,aq:()=>j,Y1:()=>Y,fe:()=>q}),s(59456),s(52106);var r,n=s(78888),i=(s(61147),s(49186)),o=s(91869),a=(s(94194),s(90708),s(92722)),l=s(89270),d=(s(85342),s(69860),s(8460),s(71402)),u=s(42538),p=s(16930);class h{constructor(){this.version="",this.queryResult=new c}}class c{constructor(){this.featureResult=new y}}class y{constructor(){this.objectIdFieldName="",this.uniqueIdField=new m,this.globalIdFieldName="",this.geohashFieldName="",this.geometryProperties=new f,this.geometryType=null,this.spatialReference=new p.A,this.exceededTransferLimit=!1,this.hasZ=!1,this.hasM=!1,this.transform=new g,this.fields=[],this.fieldNameToAttributeIndexMap={},this.values=[],this.features=[],this.geometryFields=[]}}class m{constructor(){this.name="",this.isSystemMaintained=!1}}class f{constructor(){this.shapeAreaFieldName="",this.shapeLengthFieldName="",this.units=""}}class g{constructor(){this.quantizeOriginPosition="upperLeft",this.scale=new _,this.translate=new b}}class _{constructor(){this.xScale=0,this.yScale=0,this.mScale=0,this.zScale=0}}class b{constructor(){this.xTranslate=0,this.yTranslate=0,this.mTranslate=0,this.zTranslate=0}}class w{constructor(){this.name="",this.fieldType="esriFieldTypeString",this.alias="",this.sqlType="sqlTypeVarchar",this.domain="",this.defaultValue=""}}class T{constructor(){this.attributes=[],this.compressedGeometry=new I,this.centroid=new I,this.aggregateGeometries=[]}}class I{constructor(){this.geometryType=null,this.lengths=[],this.coords=[]}}!function(e){e.ELEMENTUID="ELEMENTUID",e.TYPENAME="TYPENAME"}(r||(r={}));const E=[r.ELEMENTUID,r.TYPENAME];var v,M;!function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME"}(v||(v={})),function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME",e[e.FROMUID=2]="FROMUID",e[e.TOUID=3]="TOUID"}(M||(M={}));var A,x,S,N,k,L=s(45724),R=s(35448);function C(e){const t=new h;t.version=e.version;const s=e.get_query_result();if(0!==s.results_type.value)throw new Error("Got a non-feature collection type");const r=s.get_feature_result(),n=t.queryResult.featureResult;n.objectIdFieldName=r.objectid_field_name,n.exceededTransferLimit=r.exceeded_transfer_limit,n.hasM=r.has_m,n.hasZ=r.has_z,n.geometryType=R.bV[r.geometry_type.value],n.globalIdFieldName=r.globalid_field_name,n.geohashFieldName=r.geohash_field_name;const i=n.uniqueIdField,o=r.unique_id_field;i.name=o.name,i.isSystemMaintained=o.isSystemMaintained;const a=n.geometryProperties,l=r.geometry_properties;a.shapeAreaFieldName=l.shapeAreaFieldName,a.shapeLengthFieldName=l.shapeLengthFieldName,a.units=l.units;const d=n.spatialReference,u=r.spatial_reference;d.wkid=u.wkid,d.latestWkid=u.latestWkid,d.vcsWkid=u.vcsWkid,d.latestVcsWkid=u.latestVcsWkid,d.wkt=u.wkt,n.transform=function(e){const t=new g;t.quantizeOriginPosition=x[e.quantizeOriginPosition.value];const s=t.scale,r=e.scale;s.xScale=r.xScale,s.yScale=r.yScale,s.mScale=r.mScale,s.zScale=r.zScale;const n=t.translate,i=e.translate;return n.xTranslate=i.xTranslate,n.yTranslate=i.yTranslate,n.mTranslate=i.mTranslate,n.zTranslate=i.zTranslate,t}(r.transform);const p=n.fields,c=n.fieldNameToAttributeIndexMap,y=r.fields,m=y.size();for(let e=0;e<m;e++){const t=y.get(e),s=O(t);p.push(s),c[s.name]=e,t.delete()}y.delete();const f=n.values,_=r.values_count();for(let e=0;e<_;e++)f.push(r.get_value_at(e));const b=n.features,w=r.features,I=w.size();if(I>0)for(const e of E)if(void 0===c[e])throw new Error(`Feature collection missing required attribute: ${e}`);for(let e=0;e<I;e++){const t=new T,s=w.get(e),r=t.attributes,n=s.attributes_count();for(let e=0;e<n;e++)r.push(s.get_attribute_at(e));const i=s.get_compressed_geometry();i&&(t.compressedGeometry=D(i),t.centroid=D(s.get_centroid()));const o=t.aggregateGeometries,a=s.aggregate_geometries,l=a.size();for(let e=0;e<l;e++){const t=a.get(e),s=D(t);o.push(s),t.delete()}a.delete(),b.push(t),s.delete()}w.delete();const v=n.geometryFields,M=r.geometry_fields,A=M.size();for(let e=0;e<A;e++){const t=M.get(e),s=B(t);v.push(s),t.delete()}return M.delete(),t}function D(e){const t=new I;t.geometryType=R.bV[e.geometry_type.value];const s=[],r=[];for(let t=0;t<e.lengths.length;t++)s.push(e.lengths[t]);for(let t=0;t<e.coords.length;t++)r.push(e.coords[t]);return t.lengths=s,t.coords=r,t}function O(e){const t=new w;return t.name=e.name,t.alias=e.alias,t.fieldType=R.r5[e.field_type.value],t.sqlType=S[e.sql_type.value],t.domain=e.domain,t.defaultValue=e.default_value,t}function B(e){const t=O(e);return t.geometryType=R.bV[e.geometry_type.value],t}function F(e){if(!e.spatialReference.isWGS84)throw new i.A("knowledge-graph:layer-support-utils","The extentToInBoundsRings function only supports WGS84 spatial references.");return e.clone().normalize().map((e=>[[e.xmin,e.ymin],[e.xmin,e.ymax],[e.xmax,e.ymax],[e.xmax,e.ymin],[e.xmin,e.ymin]]))}async function j(e,t){const s=[],r=function(e,t){const s=new Map;if(t.dataModel?.relationshipTypes)for(const e of t.dataModel.relationshipTypes)e.name&&s.set(e.name,[]);for(const t of e)s.has(t.typeName)&&s.get(t.typeName)?.push(t.id);return s}(e,t),n={},i=[];for(const[e,t]of r){if(t.length<1)continue;const s=`${e}_ids`;n[s]=t,i.push(`MATCH (n)-[r:${e}]->(m) WHERE id(r) in $${s} RETURN id(n), labels(n)[0], id(m), labels(m)[0]`)}if(0===i.length)return[];const o=i.join(" UNION "),a=new u.A({openCypherQuery:o,bindParameters:n}),l=(await(0,d.executeQueryStreaming)(t,a)).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await l.read();if(e)break;for(const e of t)s.push({id:e[0],typeName:e[1]}),s.push({id:e[2],typeName:e[3]})}return s}async function P(e,t){t??=!1;const s={generateAllSublayers:t,namedTypeDefinitions:new Map};return await async function(e){const t=await(0,n.A)(e,{responseType:"array-buffer"}),s=await t.data;return async function(e){const t=new((await(0,L.I)()).MapOfObjectIdentifierSetsDecoder),s=t.decode(new Uint8Array(e)),r=new Map;if(0!==s.error_code)throw new i.A("knowledge-graph:layer-support-utils",s.error_message);const n=t.get_map_of_identifier_sets(),o=n.keys,a=o.size();for(let e=0;e<a;e++){const t=o.get(e),s=n.query_identifier_set(t),a=[];if(s.id_array_type.value===N.GLOBALID_ARRAY){const e=s.get_globalid_array(),t=e.count();for(let s=0;s<t;s++)a.push(e.get_globalid_at(s))}else if(s.id_array_type.value===N.IDENTIFIER_ARRAY){const e=s.get_identifier_array(),t=e.count();for(let s=0;s<t;s++)a.push(e.get_identifier_at(s).toString())}else if(s.id_array_type.value===N.STRING_ARRAY){const e=s.get_string_array(),t=e.count();for(let s=0;s<t;s++)a.push(e.get_string_at(s))}else{if(s.id_array_type.value!==N.OID_ARRAY)throw new i.A("knowledge-graph:layer-support-utils","Tried to encode an unexpected ID Array type.");{const e=s.get_oid_array(),t=e.count();for(let s=0;s<t;s++)a.push(e.get_objectid_at(s).toString())}}r.set(t,a)}return t.delete(),r}(new Uint8Array(s))}(e).then((e=>{!function(e,t){for(const[s,r]of e){const e=(0,o.tE)(t.namedTypeDefinitions,s,(()=>({useAllData:!1,members:new Map})));for(const t of r)e.members.has(t)||e.members.set(t,{id:t})}}(e,s)})),s}async function q(e){const t=await(0,L.I)(),s=new t.MapOfObjectIdentifierSets;!function(e,t,s){for(const[r,n]of s.namedTypeDefinitions){if(!n.members||n.useAllData)continue;const s=n.members.keys();let i=!1,o=!0;const a=new t.ObjectIdArray,l=new t.StringArray,d=new t.GlobalIdArray,u=new t.IdentifierArray,p=new t.ObjectIdentifierSet;for(const e of s)o&&(i=!isNaN(Number(e)),o=!1),i?a.add_objectid(Number(e)):(l.add_string(e),d.add_globalid(e)),u.add_identifier(e);p.set_oid_array(a),p.set_string_array(l),p.set_globalid_array(d),p.set_identifier_array(u),a.delete(),l.delete(),d.delete(),u.delete(),e.put_identifier_set(r,p),p.delete()}}(s,t,e);const r=new t.MapOfObjectIdentifierSetsEncoder;try{r.set_map_of_identifier_sets(s),r.encode();const e=r.get_encoding_result();if(0!==e.error.error_code)throw new i.A("knowledge-graph:layer-support-utils",e.error.error_message);const t=structuredClone(e.get_byte_buffer());return r.delete(),t}finally{s.delete()}}async function G(e){const t=await(0,n.A)(e,{responseType:"array-buffer"});return async function(e){const t=new((await(0,L.I)()).FeatureCollectionDecoder),s=t.decode(new Uint8Array(e));if(0!==s.error_code)throw new i.A("knowledge-graph:layer-support-utils",s.error_message);const r=C(t.get_feature_collection());return t.delete(),r}(await t.data)}function $(e,t){if(!e?.queryResult?.featureResult)return t;const s=e.queryResult.featureResult.fieldNameToAttributeIndexMap;for(const n of e.queryResult.featureResult.features){const e=n.attributes[s[r.TYPENAME]],i=(0,o.tE)(t.namedTypeDefinitions,e,(()=>({useAllData:!1,members:new Map}))),l=n.attributes[s[r.ELEMENTUID]];if(n.compressedGeometry?.coords?.length>0){let e=n.compressedGeometry.lengths;"esriGeometryPoint"===n.compressedGeometry.geometryType&&(e=[]),i.members.set(l,{id:l,linkChartLocation:new a.A(e,n.compressedGeometry.coords)})}else i.members.set(l,{id:l})}return t}(k=A||(A={}))[k.featureResult=0]="featureResult",k[k.countResult=1]="countResult",k[k.idsResult=2]="idsResult",function(e){e[e.upperLeft=0]="upperLeft",e[e.lowerLeft=1]="lowerLeft"}(x||(x={})),function(e){e[e.sqlTypeBigInt=0]="sqlTypeBigInt",e[e.sqlTypeBinary=1]="sqlTypeBinary",e[e.sqlTypeBit=2]="sqlTypeBit",e[e.sqlTypeChar=3]="sqlTypeChar",e[e.sqlTypeDate=4]="sqlTypeDate",e[e.sqlTypeDecimal=5]="sqlTypeDecimal",e[e.sqlTypeDouble=6]="sqlTypeDouble",e[e.sqlTypeFloat=7]="sqlTypeFloat",e[e.sqlTypeGeometry=8]="sqlTypeGeometry",e[e.sqlTypeGUID=9]="sqlTypeGUID",e[e.sqlTypeInteger=10]="sqlTypeInteger",e[e.sqlTypeLongNVarchar=11]="sqlTypeLongNVarchar",e[e.sqlTypeLongVarbinary=12]="sqlTypeLongVarbinary",e[e.sqlTypeLongVarchar=13]="sqlTypeLongVarchar",e[e.sqlTypeNChar=14]="sqlTypeNChar",e[e.sqlTypeNVarChar=15]="sqlTypeNVarChar",e[e.sqlTypeOther=16]="sqlTypeOther",e[e.sqlTypeReal=17]="sqlTypeReal",e[e.sqlTypeSmallInt=18]="sqlTypeSmallInt",e[e.sqlTypeSqlXml=19]="sqlTypeSqlXml",e[e.sqlTypeTime=20]="sqlTypeTime",e[e.sqlTypeTimestamp=21]="sqlTypeTimestamp",e[e.sqlTypeTimestamp2=22]="sqlTypeTimestamp2",e[e.sqlTypeTinyInt=23]="sqlTypeTinyInt",e[e.sqlTypeVarbinary=24]="sqlTypeVarbinary",e[e.sqlTypeVarchar=25]="sqlTypeVarchar"}(S||(S={})),function(e){e[e.OID_ARRAY=0]="OID_ARRAY",e[e.GLOBALID_ARRAY=1]="GLOBALID_ARRAY",e[e.STRING_ARRAY=2]="STRING_ARRAY",e[e.IDENTIFIER_ARRAY=3]="IDENTIFIER_ARRAY"}(N||(N={})),s(40863),s(82799),s(94985),s(39829),s(68249),s(86738);const Z={"basic-grid":"SIMPLE","geographic-organic-standard":"GEOGRAPHIC","hierarchical-bottom-to-top":"HIERARCHICAL","hierarchical-top-to-bottom":"HIERARCHICAL","organic-community":"COMMUNITY","organic-fusiform":"FORCE_DIRECTED","organic-leaf-circle":"FORCE_DIRECTED","organic-standard":"FORCE_DIRECTED","radial-node-centric":"RADIAL_TREE","radial-root-centric":"RADIAL_TREE","tree-bottom-to-top":"SMART_TREE","tree-left-to-right":"SMART_TREE","tree-right-to-left":"SMART_TREE","tree-top-to-bottom":"SMART_TREE","chronological-mono-timeline":"CHRONOLOGICAL_SINGLE","chronological-multi-timeline":"CHRONOLOGICAL_MULTIPLE"},U=e=>Z[e],H=(e,t)=>{const s=e?.chronologicalLayoutSettings,r=e?.organicLayoutSettings;return{chronologicalLayoutSettings:null!==s?s:void 0,organicLayoutSettings:r?{idealEdgeLengthType:"absolute-value"===r.idealEdgeLengthType?l.x.ABSOLUTE:l.x.MULTIPLIER,repulsionRadiusMultiplier:r.autoRepulsionRadius?void 0:r.repulsionRadiusMultiplier,idealEdgeLength:null==r.idealEdgeLengthType?void 0:"absolute-value"===r.idealEdgeLengthType?r.absoluteIdealEdgeLength:r.multiplicativeIdealEdgeLength,computationBudgetTime:t}:void 0}},Y={fetchAndConvertSerializedLinkChart:e=>async function(e){const t=[],s={generateAllSublayers:!1,namedTypeDefinitions:new Map};return e.entitiesUrl&&t.push(G(e.entitiesUrl).then((e=>{$(e,s)}))),e.relationshipsUrl&&t.push(G(e.relationshipsUrl).then((e=>{$(e,s)}))),await Promise.all(t),s}(e)}},32756:(e,t,s)=>{s.d(t,{f:()=>d,n:()=>l});var r=s(90237),n=s(93637),i=s(10107),o=(s(44208),s(53966),s(87811),s(40608)),a=s(91880);const l={type:[a.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:function(e,t,s){if(!e)return null;const r=e.find((e=>!!e.field));if(!r)return null;const n=new a.A;return n.read(r,s),[n]}},write:{writer:function(e,t,s,r){const i=e.find((e=>!!e.field));i&&(0,n.sM)(s,[i.toJSON()],t)}}}},d=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,r._)([(0,i.MZ)(l)],t.prototype,"orderBy",void 0),t=(0,r._)([(0,o.$)("esri.layers.mixins.OrderedLayer")],t),t}},91880:(e,t,s)=>{s.d(t,{A:()=>p});var r,n=s(90237),i=s(66552),o=s(25482),a=s(10107),l=(s(44208),s(53966),s(87811),s(40608));const d=new i.J({asc:"ascending",desc:"descending"});let u=r=class extends o.oY{constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new r({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,n._)([(0,a.MZ)({type:String,json:{write:!0}})],u.prototype,"field",void 0),(0,n._)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],u.prototype,"valueExpression",void 0),(0,n._)([(0,a.MZ)({type:d.apiValues,json:{type:d.jsonValues,read:d.read,write:d.write}})],u.prototype,"order",void 0),u=r=(0,n._)([(0,l.$)("esri.layers.support.OrderByInfo")],u);const p=u},4071:(e,t,s)=>{s.d(t,{$:()=>r,P:()=>n});const r={supportsDate:!1,supportsFixedInterval:!1,supportsAutoInterval:!1,supportsFixedBoundaries:!1,supportedStatistics:void 0},n={analytics:{supportsCacheHint:!1},attachment:{supportsContentType:!1,supportsExifInfo:!1,supportsKeywords:!1,supportsName:!1,supportsSize:!1,supportsCacheHint:!1,supportsResize:!1},data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:!1},editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsAsyncApplyEdits:!1,zDefault:void 0},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryBins:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryBins:r,query:{maxRecordCount:0,maxRecordCountFactor:0,standardMaxRecordCount:0,supportsCacheHint:!1,supportsCentroid:!1,supportsCompactGeometry:!1,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsSqlExpression:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsStatistics:!1,tileMaxRecordCount:0}}},8460:(e,t,s)=>{s.d(t,{$C:()=>m,Hh:()=>o,J:()=>l,Tu:()=>c,Wg:()=>y,Xq:()=>g,i6:()=>_,pM:()=>h,tx:()=>a,vJ:()=>f});var r=s(2741);let n,i=null;function o(){return n||(n=s.e(3666).then(s.bind(s,3666)).then((e=>e.l)).then((({default:e})=>e({locateFile:e=>(0,r.s)(`esri/libs/linkchartlayout/${e}`)}))).then((e=>{!function(e){i=e}(e)})),n)}var a,l,d,u,p,h,c,y,m,f,g,_,b,w;function T(e){const t=Object.keys(d).filter((e=>isNaN(parseInt(e,10)))).indexOf(e.timeDirection),s=Object.keys(u).filter((e=>isNaN(parseInt(e,10)))).indexOf(e.eventsTicksVisualization);return{timeDirection:{value:t>-1?t:d.right},timeBannerUTCOffsetInMinutes:e.timeBannerUTCOffsetInMinutes,eventsTicksVisualization:{value:s>-1?s:u.startAndEnd},showDurationLineForNonZeroDurationEntityEvents:e.showDurationLineForNonZeroDurationEntityEvents,durationLineWidth:e.durationLineWidth,entityPositionAtDurationRatio:e.entityPositionAtDurationRatio,showNonZeroDurationIntervalBounds:e.showNonZeroDurationIntervalBounds,separateTimeOverlaps:e.separateTimeOverlaps,separateTimelineOverlaps:e.separateTimelineOverlaps,moveFirstBends:e.moveFirstBends,secondBendRatio:e.secondBendRatio,lineSeparationMultiplier:e.lineSeparationMultiplier,spaceSeparatedLinesEvenly:e.spaceSeparatedLinesEvenly,useBezierCurves:e.useBezierCurves,separatedLineShapeRatio:e.separatedLineShapeRatio}}function I(e,t,s,r,n,o){const a=s.length,l=n.length,d=Float64Array.BYTES_PER_ELEMENT,u=Uint32Array.BYTES_PER_ELEMENT,p=Uint8Array.BYTES_PER_ELEMENT,h=16+a*(p+2*d)+l*(2*u),c=i._malloc(h);try{const p=c+16-c%16,h=p+a*d,y=h+a*d,m=y+l*u,f=m+l*u,g=()=>[i.HEAPF64.subarray(p>>3,(p>>3)+a),i.HEAPF64.subarray(h>>3,(h>>3)+a),i.HEAPU32.subarray(y>>2,(y>>2)+l),i.HEAPU32.subarray(m>>2,(m>>2)+l),i.HEAPU8.subarray(f,f+a)],[_,b,w,T,I]=g();_.set(s),b.set(r),w.set(n),T.set(o),I.set(t);let E=e(a,f,p,h,l,y,m),v=null,M=null;if(E){const e=i.getLayoutLinksTypes(),t=i.getLayoutLinksVerticesEndIndices(),s=i.getLayoutLinksVertices(),r=i.countLayoutLinksVertices();!l||e&&t?r&&!s?E=!1:(v={types:new Uint8Array(i.HEAPU8.subarray(e,e+l)),vertexEndIndex:new Uint32Array(i.HEAPU32.subarray(t>>2,(t>>2)+l)),vertices:new Float64Array(i.HEAPF64.subarray(s>>3,(s>>3)+2*r))},M=i.getAuxiliaryGraphicElements()):E=!1}const[A,x,S,N,k]=g();return s.set(A),r.set(x),n.set(S),o.set(N),t.set(k),{success:E,links:v,graphics:M}}finally{i._free(c),i.cleanupLayout()}}(p=a||(a={}))[p.None=0]="None",p[p.IsMovable=1]="IsMovable",p[p.IsGeographic=2]="IsGeographic",p[p.IsRoot=4]="IsRoot",p[p.IsOld=8]="IsOld",function(e){e[e.Regular=0]="Regular",e[e.Curved=1]="Curved",e[e.Recursive=2]="Recursive"}(l||(l={})),function(e){e[e.right=0]="right",e[e.left=1]="left",e[e.top=2]="top",e[e.bottom=3]="bottom"}(d||(d={})),function(e){e[e.none=0]="none",e[e.startOnly=1]="startOnly",e[e.startAndEnd=2]="startAndEnd"}(u||(u={})),function(e){e.getMinIdealEdgeLength=function(){return i.getMinIdealEdgeLength()},e.apply=function(e,t,s,r,n,o=2,a=1,l=-1){return I(((e,t,s,r,n,d,u)=>i.applyForceDirectedLayout(e,t,s,r,n,d,u,o,a,l)),e,t,s,r,n)}}(h||(h={})),function(e){e.apply=function(e,t,s,r,n,o=2,a=1,l=-1){return I(((e,t,s,r,n,d,u)=>i.applyCommunityLayout(e,t,s,r,n,d,u,o,a,l)),e,t,s,r,n)}}(c||(c={})),function(e){e.apply=function(e,t,s,r,n){return I(i.applySimpleLayout,e,t,s,r,n)}}(y||(y={})),function(e){e.apply=function(e,t,s,r,n){return I(i.applyHierarchicalLayout,e,t,s,r,n)}}(m||(m={})),function(e){e.apply=function(e,t,s,r,n){return I(i.applyRadialTreeLayout,e,t,s,r,n)}}(f||(f={})),function(e){e.apply=function(e,t,s,r,n){return I(i.applySmartTreeLayout,e,t,s,r,n)}}(g||(g={})),function(e){e.apply=function(e,t,s,r,n,o,a,l,p,h,c){const y={timeDirection:d.right,timeBannerUTCOffsetInMinutes:0,eventsTicksVisualization:u.startAndEnd,showDurationLineForNonZeroDurationEntityEvents:!0,durationLineWidth:5,entityPositionAtDurationRatio:1,showNonZeroDurationIntervalBounds:!1,separateTimeOverlaps:!0,separateTimelineOverlaps:!0,moveFirstBends:!0,secondBendRatio:.3,lineSeparationMultiplier:1,spaceSeparatedLinesEvenly:!1,useBezierCurves:!1,separatedLineShapeRatio:0};return I(((e,t,s,o,a,d,u)=>{if(r.length!==e)return!1;if(n.length!==e)return!1;if(l.length!==a)return!1;if(p.length!==a)return!1;const m=Float64Array.BYTES_PER_ELEMENT,f=16,g=i._malloc(f+e*m),_=i._malloc(f+e*m),b=i._malloc(f+a*m),w=i._malloc(f+a*m),I=g+f-g%f,E=_+f-_%f,v=b+f-b%f,M=w+f-w%f;try{i.HEAPF64.subarray(I>>3,(I>>3)+e).set(r),i.HEAPF64.subarray(E>>3,(E>>3)+e).set(n),i.HEAPF64.subarray(v>>3,(v>>3)+a).set(l),i.HEAPF64.subarray(M>>3,(M>>3)+a).set(p);const m=T(Object.assign(y,c));return i.applyChronologicalLayout(e,t,s,o,I,E,a,d,u,v,M,h,m)}finally{i._free(g),i._free(_),i._free(b),i._free(w)}}),e,t,s,o,a)}}(_||(_={})),function(e){e[e.Undirected=0]="Undirected",e[e.Directed=1]="Directed",e[e.Reversed=2]="Reversed"}(b||(b={})),function(e){e[e.ByCC_Raw=0]="ByCC_Raw",e[e.ByCC_NormalizeGlobally=1]="ByCC_NormalizeGlobally",e[e.ByCC_NormalizeByCC=2]="ByCC_NormalizeByCC"}(w||(w={}))},25927:(e,t,s)=>{s.d(t,{A:()=>d});var r=s(90237),n=(s(59456),s(10107)),i=(s(44208),s(53966),s(87811),s(40608)),o=s(54238),a=s(86738);let l=class extends o.A{constructor(e){super(e),this.layoutGeometry=null}};(0,r._)([(0,n.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.Entity")],l);const d=l},54238:(e,t,s)=>{s.d(t,{A:()=>l});var r=s(90237),n=s(10107),i=(s(44208),s(53966),s(87811),s(40608)),o=s(77901);let a=class extends o.A{constructor(e){super(e),this.typeName=null,this.id=null}};(0,r._)([(0,n.MZ)({type:String,json:{write:!0}})],a.prototype,"typeName",void 0),(0,r._)([(0,n.MZ)({type:String,json:{write:!0}})],a.prototype,"id",void 0),a=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphNamedObject")],a);const l=a},77901:(e,t,s)=>{s.d(t,{A:()=>l});var r=s(90237),n=s(25482),i=s(10107),o=(s(44208),s(53966),s(87811),s(40608));let a=class extends n.oY{constructor(e){super(e),this.properties=null}};(0,r._)([(0,i.MZ)({json:{write:!0}})],a.prototype,"properties",void 0),a=(0,r._)([(0,o.$)("esri.rest.knowledgeGraph.GraphObject")],a);const l=a},42538:(e,t,s)=>{s.d(t,{A:()=>u});var r=s(90237),n=s(10107),i=(s(44208),s(53966),s(87811),s(40608)),o=s(69622);let a=class extends o.A{constructor(e){super(e),this.openCypherQuery=""}};(0,r._)([(0,n.MZ)()],a.prototype,"openCypherQuery",void 0),a=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQuery")],a);const l=a;let d=class extends l{constructor(e){super(e),this.bindParameters=null,this.bindGeometryQuantizationParameters=null,this.outputQuantizationParameters=null,this.outputSpatialReference=null,this.provenanceBehavior=null}};(0,r._)([(0,n.MZ)()],d.prototype,"bindParameters",void 0),(0,r._)([(0,n.MZ)()],d.prototype,"bindGeometryQuantizationParameters",void 0),(0,r._)([(0,n.MZ)()],d.prototype,"outputQuantizationParameters",void 0),(0,r._)([(0,n.MZ)()],d.prototype,"outputSpatialReference",void 0),(0,r._)([(0,n.MZ)()],d.prototype,"provenanceBehavior",void 0),d=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.GraphQueryStreaming")],d);const u=d},40662:(e,t,s)=>{s.d(t,{A:()=>a});var r=s(90237),n=(s(53966),s(44208),s(87811),s(49186),s(40608)),i=s(77901);let o=class extends i.A{constructor(e){super(e)}};o=(0,r._)([(0,n.$)("esri.rest.knowledgeGraph.ObjectValue")],o);const a=o},42095:(e,t,s)=>{s.d(t,{A:()=>d});var r=s(90237),n=s(25482),i=s(10107),o=(s(44208),s(53966),s(87811),s(40608)),a=s(77901);let l=class extends n.oY{constructor(e){super(e),this.path=null}};(0,r._)([(0,i.MZ)({type:[a.A],json:{write:!0}})],l.prototype,"path",void 0),l=(0,r._)([(0,o.$)("esri.rest.knowledgeGraph.Path")],l);const d=l},23150:(e,t,s)=>{s.d(t,{A:()=>d});var r=s(90237),n=(s(59456),s(10107)),i=(s(44208),s(53966),s(87811),s(40608)),o=s(54238),a=s(82799);let l=class extends o.A{constructor(e){super(e),this.originId=null,this.destinationId=null,this.layoutGeometry=null}};(0,r._)([(0,n.MZ)({type:String,json:{write:!0}})],l.prototype,"originId",void 0),(0,r._)([(0,n.MZ)({type:String,json:{write:!0}})],l.prototype,"destinationId",void 0),(0,r._)([(0,n.MZ)({type:a.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,r._)([(0,i.$)("esri.rest.knowledgeGraph.Relationship")],l);const d=l}}]);