@arcgis/core 4.34.0-next.29 → 4.34.0-next.30

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 (130) hide show
  1. package/Map.js +1 -1
  2. package/assets/esri/core/workers/RemoteClient.js +1 -1
  3. package/assets/esri/core/workers/chunks/0260b33daf48fc207880.js +1 -0
  4. package/assets/esri/core/workers/chunks/{f469224c6e4804fd835a.js → 140efe4735605258ecc9.js} +1 -1
  5. package/assets/esri/core/workers/chunks/173c5b8fa1ac7aa6e072.js +1 -0
  6. package/assets/esri/core/workers/chunks/1aa6719be3afbdc7c880.js +1 -0
  7. package/assets/esri/core/workers/chunks/{8552fdb3230f4dd082c6.js → 20a96c17d1a117dfdf77.js} +1 -1
  8. package/assets/esri/core/workers/chunks/28e04ef3575f164f611a.js +1 -0
  9. package/assets/esri/core/workers/chunks/{2173012af606ac4cdf87.js → 2a695b50a384c45ace9a.js} +1 -1
  10. package/assets/esri/core/workers/chunks/{cf635f7ca998dd33d947.js → 439ce953a25b2776cb7f.js} +1 -1
  11. package/assets/esri/core/workers/chunks/{ecdbbfebca1fcef567bb.js → 4e267a813e8b10d10b3b.js} +9 -9
  12. package/assets/esri/core/workers/chunks/7099ff8dc699fedea931.js +1 -0
  13. package/assets/esri/core/workers/chunks/{e89698fc404379627349.js → 949dc266ac6f3505d357.js} +1 -1
  14. package/assets/esri/core/workers/chunks/{0aba41e0ee0a591b254b.js → 971b16677b66c16fb6b9.js} +1 -1
  15. package/assets/esri/core/workers/chunks/a809042fdce7ced2a415.js +1 -0
  16. package/assets/esri/core/workers/chunks/{16d82cbec34bc434efcd.js → a82d7e2eecfe654a65de.js} +1 -1
  17. package/assets/esri/core/workers/chunks/{27e089acb1cc76758b0a.js → ac30cf2f9a94597f7665.js} +8 -8
  18. package/assets/esri/core/workers/chunks/{ec4428250dbd807df0bd.js → c50c2f014e8567870686.js} +1 -1
  19. package/assets/esri/core/workers/chunks/{ce3a1ac43e8579db65cd.js → c854c3bb4440fd942c12.js} +1 -1
  20. package/assets/esri/core/workers/chunks/{9cbed3b43d7aadc7e627.js → ca88859fc69fcb4568c0.js} +1 -1
  21. package/assets/esri/core/workers/chunks/e7209654ecdfde926272.js +1 -0
  22. package/assets/esri/core/workers/chunks/e82b1f91465d569012c4.js +1 -0
  23. package/assets/esri/core/workers/chunks/e9311386f58f3cb95c22.js +1 -0
  24. package/assets/esri/core/workers/chunks/{45485d8f0b0e0e0a6365.js → efec0f496491a0647051.js} +1 -1
  25. package/chunks/RealisticTree.glsl.js +6 -6
  26. package/colorUtils.js +1 -1
  27. package/config.js +1 -1
  28. package/core/Evented.js +1 -1
  29. package/interfaces.d.ts +2 -2
  30. package/kernel.js +1 -1
  31. package/layers/CatalogLayer.js +1 -1
  32. package/layers/FeatureLayer.js +1 -1
  33. package/layers/GeoJSONLayer.js +1 -1
  34. package/layers/GraphicsLayer.js +1 -1
  35. package/layers/OGCFeatureLayer.js +1 -1
  36. package/layers/SceneLayer.js +1 -1
  37. package/layers/SubtypeGroupLayer.js +1 -1
  38. package/layers/graphics/data/FeatureStore.js +1 -1
  39. package/layers/graphics/dehydratedPoint.js +1 -1
  40. package/layers/knowledgeGraph/KnowledgeGraphSublayer.js +1 -1
  41. package/layers/mixins/SublayersOwner.js +1 -1
  42. package/layers/support/LayerContingentValuesCache.js +1 -1
  43. package/networks/UtilityNetwork.js +1 -1
  44. package/package.json +1 -1
  45. package/portal/support/layersLoader.js +1 -1
  46. package/rest/networks/support/CircuitTraceResult.js +1 -1
  47. package/support/revision.js +1 -1
  48. package/views/2d/engine/ManagedCanvas.js +1 -1
  49. package/views/2d/engine/imagery/RasterTileContainer.js +1 -1
  50. package/views/2d/engine/webgl/Profiler.js +1 -1
  51. package/views/2d/engine/webgl/shaderGraph/techniques/raster/RasterColorizerTechnique.js +1 -1
  52. package/views/2d/engine/webgl/shaderGraph/techniques/raster/processor/ReprojectTechnique.js +1 -1
  53. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/BaseRasterColorizerShader.js +1 -1
  54. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/math.js +1 -1
  55. package/views/2d/layers/ImageryTileLayerView2D.js +1 -1
  56. package/views/2d/layers/features/FeatureSourceEventLog.js +1 -1
  57. package/views/2d/layers/features/processor/AAggregateStrategy.js +1 -1
  58. package/views/2d/layers/features/sources/strategies/StreamLoadStrategy.js +1 -1
  59. package/views/2d/layers/features/sources/strategies/chunks/SourceChunkStore.js +1 -1
  60. package/views/2d/layers/imagery/ImageryTileView2D.js +1 -1
  61. package/views/2d/support/hitTestUtils.js +1 -1
  62. package/views/3d/analysis/LineOfSight/LineOfSightController.js +1 -1
  63. package/views/3d/analysis/VolumeMeasurement/CutFillVolumeMeasurementController.js +1 -1
  64. package/views/3d/analysis/VolumeMeasurement/CutFillVolumeMeasurementVisualization.js +5 -0
  65. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementConfiguration.js +5 -0
  66. package/views/3d/analysis/VolumeMeasurementAnalysisView3D.js +1 -1
  67. package/views/3d/interactive/editingTools/manipulations/MoveXYAxisManipulation.js +1 -1
  68. package/views/3d/interactive/editingTools/manipulations/MoveZManipulation.js +1 -1
  69. package/views/3d/interactive/editingTools/move/MoveTool3D.js +1 -1
  70. package/views/3d/interactive/editingTools/reshape/ReshapeOperation.js +1 -1
  71. package/views/3d/interactive/editingTools/reshape/ReshapeTool3D.js +1 -1
  72. package/views/3d/interactive/editingTools/transform/ExtentTransformTool.js +1 -1
  73. package/views/3d/interactive/editingTools/transform/ScaleRotateTransform.js +1 -1
  74. package/views/3d/interactive/editingTools/transform/TransformTool3D.js +1 -1
  75. package/views/3d/interactive/visualElements/OutlineVisualElement.js +1 -1
  76. package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
  77. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  78. package/views/3d/layers/graphics/Graphics3DElevationAlignment.js +1 -1
  79. package/views/3d/layers/graphics/Graphics3DFeatureStore.js +1 -1
  80. package/views/3d/layers/graphics/Graphics3DSymbol.js +1 -1
  81. package/views/3d/layers/graphics/Graphics3DSymbolLayer.js +1 -1
  82. package/views/3d/layers/graphics/pipeline/featureSet/TiledFeatureStore.js +1 -1
  83. package/views/3d/layers/i3s/I3SIndex.js +1 -1
  84. package/views/3d/layers/i3s/I3SQueryFeatureStore.js +1 -1
  85. package/views/3d/layers/i3s/LayerElevationProvider.js +1 -1
  86. package/views/3d/layers/support/HeatmapFeatureProcessor.js +1 -1
  87. package/views/3d/layers/support/StageLayerElevationProvider.js +1 -1
  88. package/views/3d/state/ViewState.js +1 -1
  89. package/views/3d/support/CombinedElevationProvider.js +1 -1
  90. package/views/3d/support/pointsOfInterest/ContentGeometryUpdates.js +1 -1
  91. package/views/3d/support/pointsOfInterest/SurfaceGeometryUpdates.js +1 -1
  92. package/views/3d/terrain/OverlayRenderer.js +1 -1
  93. package/views/3d/terrain/TerrainSurface.js +1 -1
  94. package/views/3d/webgl-engine/lib/BoundingInfo.js +1 -1
  95. package/views/3d/webgl-engine/lib/ChangeSet.js +1 -1
  96. package/views/3d/webgl-engine/lib/Geometry.js +1 -1
  97. package/views/3d/webgl-engine/lib/RenderGeometry.js +1 -1
  98. package/views/3d/webgl-engine/lib/SortedRenderGeometryRenderer.js +1 -1
  99. package/views/3d/webgl-engine/lib/TextTextureAtlas.js +1 -1
  100. package/views/3d/webgl-engine/lib/Texture.js +1 -1
  101. package/views/3d/webgl-engine/lib/TextureRepository.js +1 -1
  102. package/views/3d/webgl-engine/lib/WebGLLayer.js +1 -1
  103. package/views/3d/webgl-engine/lib/lodRendering/InstanceData.js +1 -1
  104. package/views/3d/webgl-engine/lib/rendererUtils.js +1 -1
  105. package/views/3d/webgl-engine/materials/renderers/MergedRenderer.js +1 -1
  106. package/views/DOMContainer.js +1 -1
  107. package/views/Viewport2DMixin.js +1 -1
  108. package/views/draw/DrawManipulator.js +1 -1
  109. package/views/draw/DrawOperation.js +1 -1
  110. package/views/interactive/snapping/SnappingManager.js +1 -1
  111. package/views/interactive/snapping/featureSources/FeatureCollectionSnappingSource.js +1 -1
  112. package/views/layers/FeatureLayerView.js +1 -1
  113. package/views/layers/support/editableLayerViews.js +1 -1
  114. package/views/support/Scheduler.js +1 -1
  115. package/widgets/Editor/EditorViewModel.js +1 -1
  116. package/widgets/Editor/workflowUtils.js +1 -1
  117. package/widgets/Feature/support/arcadeFeatureUtils.js +1 -1
  118. package/widgets/FeatureForm/FeatureFormViewModel.js +1 -1
  119. package/widgets/Search/SearchViewModel.js +1 -1
  120. package/widgets/support/GeolocationPositioning.js +1 -1
  121. package/widgets/support/UtilityNetworkAssociations/FeatureUtilityNetworkAssociationsViewModel.js +1 -1
  122. package/assets/esri/core/workers/chunks/230e7b817ae16505ccf0.js +0 -1
  123. package/assets/esri/core/workers/chunks/450a7ebe2535a55c5193.js +0 -1
  124. package/assets/esri/core/workers/chunks/4599f5cebbafddb6720e.js +0 -1
  125. package/assets/esri/core/workers/chunks/676fec273f2f660a614d.js +0 -1
  126. package/assets/esri/core/workers/chunks/6aced8e446beceefaf2c.js +0 -1
  127. package/assets/esri/core/workers/chunks/9f459805a6698708830a.js +0 -1
  128. package/assets/esri/core/workers/chunks/a4104b21f2b282dfb14f.js +0 -1
  129. package/assets/esri/core/workers/chunks/cab3199d37411c8ed074.js +0 -1
  130. package/assets/esri/core/workers/chunks/fbfe2195ba87d18bc37a.js +0 -1
@@ -264,7 +264,7 @@ return dpDummy * hiD + loD;
264
264
  vec3 shadedColor = evaluateSceneLightingPBR(shadingNormal, albedo, shadow, 1.0 - ssao, additionalLight, shadingParams.viewDirection, normalGround, mrr, emission, additionalAmbientIrradiance);`:H.H`vec3 shadedColor = evaluateSceneLighting(shadingNormal, albedo, shadow, 1.0 - ssao, additionalLight);`}
265
265
  vec4 finalColor = vec4(shadedColor, opacity_);
266
266
  outputColorHighlightOID(finalColor, vpos, albedo ${(0,H.If)(X,", snow")});
267
- `),t}const j=Object.freeze(Object.defineProperty({__proto__:null,build:V},Symbol.toStringTag,{value:"Module"}))},29920:(e,t,r)=>{r.d(t,{j:()=>s});var i=r(15142),n=r(38954),o=r(51850),a=r(620);class s{constructor(e,t,r){this.primitiveIndices=e,this._numIndexPerPrimitive=t,this.position=r,this._children=void 0,(0,a.vA)(e.length>=1),(0,a.vA)(3===r.size||4===r.size);const{data:i,size:s,indices:l}=r;(0,a.vA)(l.length%this._numIndexPerPrimitive===0),(0,a.vA)(l.length>=e.length*this._numIndexPerPrimitive);const d=e.length;let u=s*l[this._numIndexPerPrimitive*e[0]];c.clear(),c.push(u);const h=(0,o.fA)(i[u],i[u+1],i[u+2]),m=(0,o.o8)(h);for(let t=0;t<d;++t){const r=this._numIndexPerPrimitive*e[t];for(let e=0;e<this._numIndexPerPrimitive;++e){u=s*l[r+e],c.push(u);let t=i[u];h[0]=Math.min(t,h[0]),m[0]=Math.max(t,m[0]),t=i[u+1],h[1]=Math.min(t,h[1]),m[1]=Math.max(t,m[1]),t=i[u+2],h[2]=Math.min(t,h[2]),m[2]=Math.max(t,m[2])}}this.bbMin=h,this.bbMax=m;const p=(0,n.m)((0,o.vt)(),this.bbMin,this.bbMax,.5);this.radius=.5*Math.max(Math.max(m[0]-h[0],m[1]-h[1]),m[2]-h[2]);let f=this.radius*this.radius;for(let e=0;e<c.length;++e){u=c.at(e);const t=i[u]-p[0],r=i[u+1]-p[1],n=i[u+2]-p[2],o=t*t+r*r+n*n;if(o<=f)continue;const a=Math.sqrt(o),s=.5*(a-this.radius);this.radius=this.radius+s,f=this.radius*this.radius;const l=s/a;p[0]+=t*l,p[1]+=r*l,p[2]+=n*l}this.center=p,c.clear()}getChildren(){if(this._children||(0,n.s)(this.bbMin,this.bbMax)<=1)return this._children;const e=(0,n.m)((0,o.vt)(),this.bbMin,this.bbMax,.5),t=this.primitiveIndices.length,r=new Uint8Array(t),i=new Array(8);for(let e=0;e<8;++e)i[e]=0;const{data:a,size:c,indices:l}=this.position;for(let n=0;n<t;++n){let t=0;const o=this._numIndexPerPrimitive*this.primitiveIndices[n];let s=c*l[o],d=a[s],u=a[s+1],h=a[s+2];for(let e=1;e<this._numIndexPerPrimitive;++e){s=c*l[o+e];const t=a[s],r=a[s+1],i=a[s+2];t<d&&(d=t),r<u&&(u=r),i<h&&(h=i)}d<e[0]&&(t|=1),u<e[1]&&(t|=2),h<e[2]&&(t|=4),r[n]=t,++i[t]}let d=0;for(let e=0;e<8;++e)i[e]>0&&++d;if(d<2)return;const u=new Array(8);for(let e=0;e<8;++e)u[e]=i[e]>0?new Uint32Array(i[e]):void 0;for(let e=0;e<8;++e)i[e]=0;for(let e=0;e<t;++e){const t=r[e];u[t][i[t]++]=this.primitiveIndices[e]}this._children=new Array;for(let e=0;e<8;++e)void 0!==u[e]&&this._children.push(new s(u[e],this._numIndexPerPrimitive,this.position));return this._children}static prune(){c.prune()}}const c=new i.A({deallocator:null})},31821:(e,t,r)=>{function i(e,...t){let r="";for(let i=0;i<t.length;i++)r+=e[i]+t[i];return r+=e[e.length-1],r}function n(e,t,r=""){return e?t:r}r.d(t,{H:()=>i,If:()=>n}),function(e){e.int=function(e){return Math.round(e).toString()},e.float=function(e){return e.toPrecision(8)}}(i||(i={}))},32680:(e,t,r)=>{r.d(t,{M:()=>n});var i=r(31821);function n(e){e.vertex.code.add(i.H`vec4 offsetBackfacingClipPosition(vec4 posClip, vec3 posWorld, vec3 normalWorld, vec3 camPosWorld) {
267
+ `),t}const j=Object.freeze(Object.defineProperty({__proto__:null,build:V},Symbol.toStringTag,{value:"Module"}))},29920:(e,t,r)=>{r.d(t,{j:()=>s});var i=r(15142),n=r(38954),o=r(51850),a=r(620);class s{get center(){return(0,o.fA)(this._data[0],this._data[1],this._data[2])}get radius(){return this._data[3]}get bbMin(){return(0,o.fA)(this._data[4],this._data[5],this._data[6])}get bbMax(){return(0,o.fA)(this._data[7],this._data[8],this._data[9])}constructor(e,t,r){this.primitiveIndices=e,this._numIndexPerPrimitive=t,this.position=r,this._data=[.1,0,0,0,0,0,0,0,0,0],this._children=void 0,(0,a.vA)(e.length>=1),(0,a.vA)(3===r.size||4===r.size);const{data:i,size:s,indices:l}=r;(0,a.vA)(l.length%this._numIndexPerPrimitive===0),(0,a.vA)(l.length>=e.length*this._numIndexPerPrimitive);const d=e.length;let u=s*l[this._numIndexPerPrimitive*e[0]];c.clear(),c.push(u);const h=(0,o.fA)(i[u],i[u+1],i[u+2]),m=(0,o.o8)(h);for(let t=0;t<d;++t){const r=this._numIndexPerPrimitive*e[t];for(let e=0;e<this._numIndexPerPrimitive;++e){u=s*l[r+e],c.push(u);let t=i[u];h[0]=Math.min(t,h[0]),m[0]=Math.max(t,m[0]),t=i[u+1],h[1]=Math.min(t,h[1]),m[1]=Math.max(t,m[1]),t=i[u+2],h[2]=Math.min(t,h[2]),m[2]=Math.max(t,m[2])}}for(let e=0;e<3;++e)this._data[4+e]=h[e],this._data[7+e]=m[e];const p=(0,n.m)((0,o.vt)(),this.bbMin,this.bbMax,.5);let f=.5*Math.max(Math.max(m[0]-h[0],m[1]-h[1]),m[2]-h[2]),v=f*f;for(let e=0;e<c.length;++e){u=c.at(e);const t=i[u]-p[0],r=i[u+1]-p[1],n=i[u+2]-p[2],o=t*t+r*r+n*n;if(o<=v)continue;const a=Math.sqrt(o),s=.5*(a-f);f+=s,v=f*f;const l=s/a;p[0]+=t*l,p[1]+=r*l,p[2]+=n*l}this._data[3]=f;for(let e=0;e<3;++e)this._data[0+e]=p[e];c.clear()}getChildren(){if(this._children||(0,n.s)(this.bbMin,this.bbMax)<=1)return this._children;const e=(0,n.m)((0,o.vt)(),this.bbMin,this.bbMax,.5),t=this.primitiveIndices.length,r=new Uint8Array(t),i=new Array(8);for(let e=0;e<8;++e)i[e]=0;const{data:a,size:c,indices:l}=this.position;for(let n=0;n<t;++n){let t=0;const o=this._numIndexPerPrimitive*this.primitiveIndices[n];let s=c*l[o],d=a[s],u=a[s+1],h=a[s+2];for(let e=1;e<this._numIndexPerPrimitive;++e){s=c*l[o+e];const t=a[s],r=a[s+1],i=a[s+2];t<d&&(d=t),r<u&&(u=r),i<h&&(h=i)}d<e[0]&&(t|=1),u<e[1]&&(t|=2),h<e[2]&&(t|=4),r[n]=t,++i[t]}let d=0;for(let e=0;e<8;++e)i[e]>0&&++d;if(d<2)return;const u=new Array(8);for(let e=0;e<8;++e)u[e]=i[e]>0?new Uint32Array(i[e]):void 0;for(let e=0;e<8;++e)i[e]=0;for(let e=0;e<t;++e){const t=r[e];u[t][i[t]++]=this.primitiveIndices[e]}this._children=new Array;for(let e=0;e<8;++e)void 0!==u[e]&&this._children.push(new s(u[e],this._numIndexPerPrimitive,this.position));return this._children}static prune(){c.prune()}}const c=new i.A({deallocator:null})},31821:(e,t,r)=>{function i(e,...t){let r="";for(let i=0;i<t.length;i++)r+=e[i]+t[i];return r+=e[e.length-1],r}function n(e,t,r=""){return e?t:r}r.d(t,{H:()=>i,If:()=>n}),function(e){e.int=function(e){return Math.round(e).toString()},e.float=function(e){return e.toPrecision(8)}}(i||(i={}))},32680:(e,t,r)=>{r.d(t,{M:()=>n});var i=r(31821);function n(e){e.vertex.code.add(i.H`vec4 offsetBackfacingClipPosition(vec4 posClip, vec3 posWorld, vec3 normalWorld, vec3 camPosWorld) {
268
268
  vec3 camToVert = posWorld - camPosWorld;
269
269
  bool isBackface = dot(camToVert, normalWorld) > 0.0;
270
270
  if (isBackface) {
@@ -521,7 +521,7 @@ return MaskedColor(color, isnan(color));
521
521
  return (-z - nearFar[0]) / (nearFar[1] - nearFar[0]);
522
522
  }`)}function l(e,t){const{vertex:r}=e;switch(t.output){case 0:case 1:if(t.receiveShadows)return a(e),void r.code.add(o.H`void forwardLinearDepth() { linearDepth = gl_Position.w; }`);break;case 4:case 5:case 6:case 7:return e.include(i.em,t),a(e),s(e),c(e),void r.code.add(o.H`void forwardLinearDepth() {
523
523
  linearDepth = calculateLinearDepth(nearFar, vPosition_view.z);
524
- }`)}r.code.add(o.H`void forwardLinearDepth() {}`)}},47286:(e,t,r)=>{r.d(t,{G:()=>n});var i=r(74333);class n extends i.n{constructor(e,t,r){super(e,"vec2",1,(i,n,o)=>i.setUniform2fv(e,t(n,o),r))}}},48833:(e,t,r)=>{r.d(t,{g:()=>G}),r(44208);var i=r(49186),n=r(65529),o=r(97768),a=r(74887),s=r(34275),c=r(24326),l=r(84952),d=r(38969),u=r(99677),h=r(56058),m=r(2741);let p;var f=r(63907),v=r(76284),g=r(42293);let _=null,x=null;async function b(){return null==x&&(p??=(async()=>{const e=await r.e(9321).then(r.bind(r,49321)),t=await e.default({locateFile:e=>(0,m.s)(`esri/libs/basisu/${e}`)});return t.initializeBasis(),t})(),x=p,_=await x),x}function w(e,t){if(null==_)return e.byteLength;const r=new _.BasisFile(new Uint8Array(e)),i=T(r)?M(r.getNumLevels(0),r.getHasAlpha(),r.getImageWidth(0,0),r.getImageHeight(0,0),t):0;return r.close(),r.delete(),i}function y(e,t){if(null==_)return e.byteLength;const r=new _.KTX2File(new Uint8Array(e)),i=C(r)?M(r.getLevels(),r.getHasAlpha(),r.getWidth(),r.getHeight(),t):0;return r.close(),r.delete(),i}function M(e,t,r,i,n){const o=(0,g.IB)(t?f.CQ.COMPRESSED_RGBA8_ETC2_EAC:f.CQ.COMPRESSED_RGB8_ETC2),a=n&&e>1?(4**e-1)/(3*4**(e-1)):1;return Math.ceil(r*i*o*a)}function T(e){return e.getNumImages()>=1&&!e.isUASTC()}function C(e){return e.getFaces()>=1&&e.isETC1S()}function S(e,t,r,i,n,o,a,s){const{compressedTextureETC:c,compressedTextureS3TC:l}=e.capabilities,[d,u]=c?i?[1,f.CQ.COMPRESSED_RGBA8_ETC2_EAC]:[0,f.CQ.COMPRESSED_RGB8_ETC2]:l?i?[3,f.CQ.COMPRESSED_RGBA_S3TC_DXT5_EXT]:[2,f.CQ.COMPRESSED_RGB_S3TC_DXT1_EXT]:[13,6408],h=t.hasMipmap?r:Math.min(1,r),m=[];for(let e=0;e<h;e++)m.push(new Uint8Array(a(e,d))),s(e,d,m[e]);return t.internalFormat=u,t.hasMipmap=m.length>1,t.samplingMode=t.hasMipmap?9987:9729,t.width=n,t.height=o,new v.g(e,t,{type:"compressed",levels:m})}var E=r(53966);const A=()=>E.A.getLogger("esri.views.3d.webgl-engine.lib.DDSUtil");function R(e){return e.charCodeAt(0)+(e.charCodeAt(1)<<8)+(e.charCodeAt(2)<<16)+(e.charCodeAt(3)<<24)}const I=R("DXT1"),P=R("DXT3"),F=R("DXT5");function O(e,t){const r=new Int32Array(e.buffer,e.byteOffset,31);if(542327876!==r[0])return A().error("Invalid magic number in DDS header"),null;if(!(4&r[20]))return A().error("Unsupported format, must contain a FourCC code"),null;const i=r[21];let n,o;switch(i){case I:n=8,o=f.CQ.COMPRESSED_RGB_S3TC_DXT1_EXT;break;case P:n=16,o=f.CQ.COMPRESSED_RGBA_S3TC_DXT3_EXT;break;case F:n=16,o=f.CQ.COMPRESSED_RGBA_S3TC_DXT5_EXT;break;default:return A().error("Unsupported FourCC code:",function(e){return String.fromCharCode(255&e,e>>8&255,e>>16&255,e>>24&255)}(i)),null}let a=1,s=r[4],c=r[3];(3&s||3&c)&&(A().warn("Rounding up compressed texture size to nearest multiple of 4."),s=s+3&-4,c=c+3&-4);const l=s,d=c;let u,h;131072&r[2]&&!1!==t&&(a=Math.max(1,r[7]));let m=e.byteOffset+r[1]+4;const p=[];for(let t=0;t<a;++t)h=(s+3>>2)*(c+3>>2)*n,u=new Uint8Array(e.buffer,m,h),p.push(u),m+=h,s=Math.max(1,s>>1),c=Math.max(1,c>>1);return{textureData:{type:"compressed",levels:p},internalFormat:o,width:l,height:d}}function D(e,t){return t=16*Math.floor(t/16),Math.min(16*Math.round(e/16),t)}function H(e,t){const[r,i]=function({width:e,height:t},{maxPreferredTexturePixels:r,maxTextureSize:i}){const n=Math.max(e,t),o=e*t;if(n<=i&&o<=r)return[e,t];const a=Math.min(Math.sqrt(r/o),i/n);return[D(Math.round(e*a),i),D(Math.round(t*a),i)]}(e,t);return e.width===r&&e.height===i?e:N(e,r,i)}function N(e,t,r){if(e instanceof ImageData)return N(function(e){const t=document.createElement("canvas");t.width=e.width,t.height=e.height;const r=t.getContext("2d");if(null==r)throw new i.A("texture:context-failed","Failed to create 2d context from HTMLCanvasElement");return r.putImageData(e,0,0),t}(e),t,r);const n=document.createElement("canvas");return n.width=t,n.height=r,n.getContext("2d").drawImage(e,0,0,n.width,n.height),n}var L=r(620),B=r(67171);class G{constructor(e,t){this._data=e,this.id=(0,c.c)(),this.events=new n.A,this._parameters={...U,...t},this._startPreload(e)}dispose(){this.unload(),this._data=this.update=void 0}_startPreload(e){e instanceof HTMLVideoElement?(this.update=t=>this._update(e,t),this._startPreloadVideoElement(e)):e instanceof HTMLImageElement&&this._startPreloadImageElement(e)}_startPreloadVideoElement(e){if(!((0,l.w8)(e.src)||"auto"===e.preload&&e.crossOrigin)&&(e.preload="auto",e.crossOrigin="anonymous",e.src=e.src,e.paused&&e.autoplay)){const t=[];(0,d.i)(e,e=>t.push(e)).then(()=>{e.play()}).finally(()=>t.forEach(e=>e.remove()))}}_startPreloadImageElement(e){(0,l.DB)(e.src)||(0,l.w8)(e.src)||e.crossOrigin||(e.crossOrigin="anonymous",e.src=e.src)}_createDescriptor(e){const t=new B.R;return t.wrapMode=this._parameters.wrap??10497,t.flipped=!this._parameters.noUnpackFlip,t.samplingMode=this._parameters.mipmap?9987:9729,t.hasMipmap=!!this._parameters.mipmap,t.preMultiplyAlpha=!!this._parameters.preMultiplyAlpha,t.maxAnisotropy=this._parameters.maxAnisotropy??(this._parameters.mipmap?e.parameters.maxMaxAnisotropy:1),t}get glTexture(){return this._glTexture??this._emptyTexture}get loaded(){return null!=this._glTexture}get usedMemory(){return this._glTexture?.usedMemory||function(e,t){if(null==e)return 0;if((0,s.mw)(e)||(0,s.mg)(e))return"image/ktx2"===t.encoding?y(e,!!t.mipmap):"image/x.basis"===t.encoding?w(e,!!t.mipmap):e.byteLength;const{width:r,height:i}=e instanceof Image||e instanceof ImageData||e instanceof HTMLCanvasElement||e instanceof HTMLVideoElement?z(e):t;return(t.mipmap?4/3:1)*r*i*(t.components||4)||0}(this._data,this._parameters)}load(e){if(this._loadingPromise)return this._loadingPromise;if(this._glTexture)return this._glTexture;const t=this._data;return null==t?(this._glTexture=new v.g(e,this._createDescriptor(e),null),this._glTexture):(this._emptyTexture=e.emptyTexture,this._parameters.reloadable||(this._data=void 0),"string"==typeof t?this._loadFromURL(e,t):t instanceof Image?this._loadFromImageElement(e,t):t instanceof HTMLVideoElement?this._loadFromVideoElement(e,t):t instanceof ImageData||t instanceof HTMLCanvasElement?this._loadFromImage(e,t):(0,s.mg)(t)&&"image/vnd-ms.dds"===this._parameters.encoding?this._loadFromDDSData(e,t):(0,s.mw)(t)&&"image/vnd-ms.dds"===this._parameters.encoding?this._loadFromDDSData(e,new Uint8Array(t)):((0,s.mw)(t)||(0,s.mg)(t))&&"image/ktx2"===this._parameters.encoding?this._loadFromKTX2(e,t):((0,s.mw)(t)||(0,s.mg)(t))&&"image/x.basis"===this._parameters.encoding?this._loadFromBasis(e,t):(0,s.mg)(t)?this._loadFromPixelData(e,t):(0,s.mw)(t)?this._loadFromPixelData(e,new Uint8Array(t)):null)}_update(e,t){return null==this._glTexture||e.readyState<HTMLMediaElement.HAVE_CURRENT_DATA||t===e.currentTime?t:(this._glTexture.setData(e),this._glTexture.descriptor.hasMipmap&&this._glTexture.generateMipmap(),this._parameters.updateCallback&&this._parameters.updateCallback(),e.currentTime)}_loadFromDDSData(e,t){return this._glTexture=function(e,t,r){const i=O(r,t.hasMipmap??!1);if(null==i)throw new Error("DDS texture data is null");const{textureData:n,internalFormat:o,width:a,height:s}=i;return t.samplingMode=n.levels.length>1?9987:9729,t.hasMipmap=n.levels.length>1,t.internalFormat=o,t.width=a,t.height=s,new v.g(e,t,n)}(e,this._createDescriptor(e),t),this._emptyTexture=null,this._glTexture}_loadFromKTX2(e,t){return this._loadAsync(()=>async function(e,t,r){null==_&&(_=await b());const i=new _.KTX2File(new Uint8Array(r));if(!C(i))return null;i.startTranscoding();const n=S(e,t,i.getLevels(),i.getHasAlpha(),i.getWidth(),i.getHeight(),(e,t)=>i.getImageTranscodedSizeInBytes(e,0,0,t),(e,t,r)=>i.transcodeImage(r,e,0,0,t,0,-1,-1));return i.close(),i.delete(),n}(e,this._createDescriptor(e),t).then(e=>(this._glTexture=e,e)))}_loadFromBasis(e,t){return this._loadAsync(()=>async function(e,t,r){null==_&&(_=await b());const i=new _.BasisFile(new Uint8Array(r));if(!T(i))return null;i.startTranscoding();const n=S(e,t,i.getNumLevels(0),i.getHasAlpha(),i.getImageWidth(0,0),i.getImageHeight(0,0),(e,t)=>i.getImageTranscodedSizeInBytes(0,e,t),(e,t,r)=>i.transcodeImage(r,0,e,t,0,0));return i.close(),i.delete(),n}(e,this._createDescriptor(e),t).then(e=>(this._glTexture=e,e)))}_loadFromPixelData(e,t){(0,L.vA)(this._parameters.width>0&&this._parameters.height>0);const r=this._createDescriptor(e);return r.pixelFormat=1===this._parameters.components?6409:3===this._parameters.components?6407:6408,6407!==r.pixelFormat&&6408!==r.pixelFormat||(r.compress=this._parameters.compressionOptions),r.width=this._parameters.width??0,r.height=this._parameters.height??0,this._glTexture=new v.g(e,r,t),this._glTexture}_loadFromURL(e,t){return this._loadAsync(async r=>{const i=await(0,u.D)(t,{signal:r});return(0,a.Te)(r),this._loadFromImage(e,i)})}_loadFromImageElement(e,t){return t.complete?this._loadFromImage(e,t):this._loadAsync(async r=>{const i=await(0,h.Sx)(t,t.src,!1,r);return(0,a.Te)(r),this._loadFromImage(e,i)})}_loadFromVideoElement(e,t){return t.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA?this._loadFromImage(e,t):this._loadFromVideoElementAsync(e,t)}_loadFromVideoElementAsync(e,t){return this._loadAsync(r=>new Promise((n,s)=>{const c=()=>{t.removeEventListener("loadeddata",l),t.removeEventListener("error",d),(0,o.xt)(u)},l=()=>{t.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA&&(c(),n(this._loadFromImage(e,t)))},d=e=>{c(),s(e||new i.A("texture:load-error","Failed to load video"))};t.addEventListener("loadeddata",l),t.addEventListener("error",d);const u=(0,a.u7)(r,()=>d((0,a.NK)()))}))}_loadFromImage(e,t){let r=t;r instanceof HTMLVideoElement||(r=H(r,e.parameters));const i=z(r);this._parameters.width=i.width,this._parameters.height=i.height;const n=this._createDescriptor(e);return n.pixelFormat=3===this._parameters.components?6407:6408,n.width=i.width,n.height=i.height,n.compress=this._parameters.compressionOptions,this._glTexture=new v.g(e,n,r),this._emptyTexture=null,this.events.emit("loaded"),this._glTexture}_loadAsync(e){const t=new AbortController;this._loadingController=t;const r=e(t.signal);this._loadingPromise=r;const i=()=>{this._loadingController===t&&(this._loadingController=null),this._loadingPromise===r&&(this._loadingPromise=null),this._emptyTexture=null};return r.then(i,i),r}unload(){if(this._glTexture=(0,o.WD)(this._glTexture),this._emptyTexture=null,null!=this._loadingController){const e=this._loadingController;this._loadingController=null,this._loadingPromise=null,e.abort()}this.events.emit("unloaded")}get parameters(){return this._parameters}}function z(e){return e instanceof HTMLVideoElement?{width:e.videoWidth,height:e.videoHeight}:e}const U={wrap:{s:10497,t:10497},mipmap:!0,noUnpackFlip:!1,preMultiplyAlpha:!1}},49255:(e,t,r)=>{function i(e){return 4===e||5===e||6===e||7===e}function n(e){return function(e){return function(e){return s(e)||a(e)}(e)||d(e)}(e)||3===e}function o(e){return function(e){return l(e)||d(e)}(e)||3===e}function a(e){return 8===e||9===e}function s(e){return 0===e}function c(e){return s(e)||u(e)}function l(e){return c(e)||a(e)}function d(e){return 2===e}function u(e){return 1===e}function h(e){switch(e){case 2:case 4:case 5:case 6:case 7:return!0}return!1}r.d(t,{LG:()=>u,Mb:()=>l,PJ:()=>i,RN:()=>c,Vg:()=>h,XY:()=>n,iq:()=>o})},49718:(e,t,r)=>{r(51850),r(6867).i},49788:(e,t,r)=>{r.d(t,{Q:()=>i});const i=1/255.5},51406:(e,t,r)=>{r.d(t,{MU:()=>c,O1:()=>l,QM:()=>d,Sx:()=>s,q2:()=>a});var i=r(29242),n=r(31821),o=r(35644);function a(e,t){t.hasColorTextureTransform?(e.varyings.add("colorUV","vec2"),e.vertex.uniforms.add(new o.k("colorTextureTransformMatrix",e=>e.colorTextureTransformMatrix??i.zK)).code.add(n.H`void forwardColorUV(){
524
+ }`)}r.code.add(o.H`void forwardLinearDepth() {}`)}},47286:(e,t,r)=>{r.d(t,{G:()=>n});var i=r(74333);class n extends i.n{constructor(e,t,r){super(e,"vec2",1,(i,n,o)=>i.setUniform2fv(e,t(n,o),r))}}},48833:(e,t,r)=>{r.d(t,{g:()=>G}),r(44208);var i=r(49186),n=r(65529),o=r(97768),a=r(74887),s=r(34275),c=r(24326),l=r(84952),d=r(38969),u=r(99677),h=r(56058),m=r(2741);let p;var f=r(63907),v=r(76284),g=r(42293);let _=null,x=null;async function b(){return null==x&&(p??=(async()=>{const e=await r.e(9321).then(r.bind(r,49321)),t=await e.default({locateFile:e=>(0,m.s)(`esri/libs/basisu/${e}`)});return t.initializeBasis(),t})(),x=p,_=await x),x}function w(e,t){if(null==_)return e.byteLength;const r=new _.BasisFile(new Uint8Array(e)),i=T(r)?M(r.getNumLevels(0),r.getHasAlpha(),r.getImageWidth(0,0),r.getImageHeight(0,0),t):0;return r.close(),r.delete(),i}function y(e,t){if(null==_)return e.byteLength;const r=new _.KTX2File(new Uint8Array(e)),i=C(r)?M(r.getLevels(),r.getHasAlpha(),r.getWidth(),r.getHeight(),t):0;return r.close(),r.delete(),i}function M(e,t,r,i,n){const o=(0,g.IB)(t?f.CQ.COMPRESSED_RGBA8_ETC2_EAC:f.CQ.COMPRESSED_RGB8_ETC2),a=n&&e>1?(4**e-1)/(3*4**(e-1)):1;return Math.ceil(r*i*o*a)}function T(e){return e.getNumImages()>=1&&!e.isUASTC()}function C(e){return e.getFaces()>=1&&e.isETC1S()}function S(e,t,r,i,n,o,a,s){const{compressedTextureETC:c,compressedTextureS3TC:l}=e.capabilities,[d,u]=c?i?[1,f.CQ.COMPRESSED_RGBA8_ETC2_EAC]:[0,f.CQ.COMPRESSED_RGB8_ETC2]:l?i?[3,f.CQ.COMPRESSED_RGBA_S3TC_DXT5_EXT]:[2,f.CQ.COMPRESSED_RGB_S3TC_DXT1_EXT]:[13,6408],h=t.hasMipmap?r:Math.min(1,r),m=[];for(let e=0;e<h;e++)m.push(new Uint8Array(a(e,d))),s(e,d,m[e]);return t.internalFormat=u,t.hasMipmap=m.length>1,t.samplingMode=t.hasMipmap?9987:9729,t.width=n,t.height=o,new v.g(e,t,{type:"compressed",levels:m})}var E=r(53966);const A=()=>E.A.getLogger("esri.views.3d.webgl-engine.lib.DDSUtil");function R(e){return e.charCodeAt(0)+(e.charCodeAt(1)<<8)+(e.charCodeAt(2)<<16)+(e.charCodeAt(3)<<24)}const I=R("DXT1"),P=R("DXT3"),F=R("DXT5");function O(e,t){const r=new Int32Array(e.buffer,e.byteOffset,31);if(542327876!==r[0])return A().error("Invalid magic number in DDS header"),null;if(!(4&r[20]))return A().error("Unsupported format, must contain a FourCC code"),null;const i=r[21];let n,o;switch(i){case I:n=8,o=f.CQ.COMPRESSED_RGB_S3TC_DXT1_EXT;break;case P:n=16,o=f.CQ.COMPRESSED_RGBA_S3TC_DXT3_EXT;break;case F:n=16,o=f.CQ.COMPRESSED_RGBA_S3TC_DXT5_EXT;break;default:return A().error("Unsupported FourCC code:",function(e){return String.fromCharCode(255&e,e>>8&255,e>>16&255,e>>24&255)}(i)),null}let a=1,s=r[4],c=r[3];(3&s||3&c)&&(A().warn("Rounding up compressed texture size to nearest multiple of 4."),s=s+3&-4,c=c+3&-4);const l=s,d=c;let u,h;131072&r[2]&&!1!==t&&(a=Math.max(1,r[7]));let m=e.byteOffset+r[1]+4;const p=[];for(let t=0;t<a;++t)h=(s+3>>2)*(c+3>>2)*n,u=new Uint8Array(e.buffer,m,h),p.push(u),m+=h,s=Math.max(1,s>>1),c=Math.max(1,c>>1);return{textureData:{type:"compressed",levels:p},internalFormat:o,width:l,height:d}}function D(e,t){return t=16*Math.floor(t/16),Math.min(16*Math.round(e/16),t)}function H(e,t){const[r,i]=function({width:e,height:t},{maxPreferredTexturePixels:r,maxTextureSize:i}){const n=Math.max(e,t),o=e*t;if(n<=i&&o<=r)return[e,t];const a=Math.min(Math.sqrt(r/o),i/n);return[D(Math.round(e*a),i),D(Math.round(t*a),i)]}(e,t);return e.width===r&&e.height===i?e:N(e,r,i)}function N(e,t,r){if(e instanceof ImageData)return N(function(e){const t=document.createElement("canvas");t.width=e.width,t.height=e.height;const r=t.getContext("2d");if(null==r)throw new i.A("texture:context-failed","Failed to create 2d context from HTMLCanvasElement");return r.putImageData(e,0,0),t}(e),t,r);const n=document.createElement("canvas");return n.width=t,n.height=r,n.getContext("2d").drawImage(e,0,0,n.width,n.height),n}var L=r(620),B=r(67171);class G{constructor(e,t){this._data=e,this.id=(0,c.c)(),this.events=new n.A.EventEmitter,this._parameters={...U,...t},this._startPreload(e)}dispose(){this.unload(),this._data=this.update=void 0}_startPreload(e){e instanceof HTMLVideoElement?(this.update=t=>this._update(e,t),this._startPreloadVideoElement(e)):e instanceof HTMLImageElement&&this._startPreloadImageElement(e)}_startPreloadVideoElement(e){if(!((0,l.w8)(e.src)||"auto"===e.preload&&e.crossOrigin)&&(e.preload="auto",e.crossOrigin="anonymous",e.src=e.src,e.paused&&e.autoplay)){const t=[];(0,d.i)(e,e=>t.push(e)).then(()=>{e.play()}).finally(()=>t.forEach(e=>e.remove()))}}_startPreloadImageElement(e){(0,l.DB)(e.src)||(0,l.w8)(e.src)||e.crossOrigin||(e.crossOrigin="anonymous",e.src=e.src)}_createDescriptor(e){const t=new B.R;return t.wrapMode=this._parameters.wrap??10497,t.flipped=!this._parameters.noUnpackFlip,t.samplingMode=this._parameters.mipmap?9987:9729,t.hasMipmap=!!this._parameters.mipmap,t.preMultiplyAlpha=!!this._parameters.preMultiplyAlpha,t.maxAnisotropy=this._parameters.maxAnisotropy??(this._parameters.mipmap?e.parameters.maxMaxAnisotropy:1),t}get glTexture(){return this._glTexture??this._emptyTexture}get loaded(){return null!=this._glTexture}get usedMemory(){return this._glTexture?.usedMemory||function(e,t){if(null==e)return 0;if((0,s.mw)(e)||(0,s.mg)(e))return"image/ktx2"===t.encoding?y(e,!!t.mipmap):"image/x.basis"===t.encoding?w(e,!!t.mipmap):e.byteLength;const{width:r,height:i}=e instanceof Image||e instanceof ImageData||e instanceof HTMLCanvasElement||e instanceof HTMLVideoElement?z(e):t;return(t.mipmap?4/3:1)*r*i*(t.components||4)||0}(this._data,this._parameters)}load(e){if(this._loadingPromise)return this._loadingPromise;if(this._glTexture)return this._glTexture;const t=this._data;return null==t?(this._glTexture=new v.g(e,this._createDescriptor(e),null),this._glTexture):(this._emptyTexture=e.emptyTexture,this._parameters.reloadable||(this._data=void 0),"string"==typeof t?this._loadFromURL(e,t):t instanceof Image?this._loadFromImageElement(e,t):t instanceof HTMLVideoElement?this._loadFromVideoElement(e,t):t instanceof ImageData||t instanceof HTMLCanvasElement?this._loadFromImage(e,t):(0,s.mg)(t)&&"image/vnd-ms.dds"===this._parameters.encoding?this._loadFromDDSData(e,t):(0,s.mw)(t)&&"image/vnd-ms.dds"===this._parameters.encoding?this._loadFromDDSData(e,new Uint8Array(t)):((0,s.mw)(t)||(0,s.mg)(t))&&"image/ktx2"===this._parameters.encoding?this._loadFromKTX2(e,t):((0,s.mw)(t)||(0,s.mg)(t))&&"image/x.basis"===this._parameters.encoding?this._loadFromBasis(e,t):(0,s.mg)(t)?this._loadFromPixelData(e,t):(0,s.mw)(t)?this._loadFromPixelData(e,new Uint8Array(t)):null)}_update(e,t){return null==this._glTexture||e.readyState<HTMLMediaElement.HAVE_CURRENT_DATA||t===e.currentTime?t:(this._glTexture.setData(e),this._glTexture.descriptor.hasMipmap&&this._glTexture.generateMipmap(),this._parameters.updateCallback&&this._parameters.updateCallback(),e.currentTime)}_loadFromDDSData(e,t){return this._glTexture=function(e,t,r){const i=O(r,t.hasMipmap??!1);if(null==i)throw new Error("DDS texture data is null");const{textureData:n,internalFormat:o,width:a,height:s}=i;return t.samplingMode=n.levels.length>1?9987:9729,t.hasMipmap=n.levels.length>1,t.internalFormat=o,t.width=a,t.height=s,new v.g(e,t,n)}(e,this._createDescriptor(e),t),this._emptyTexture=null,this._glTexture}_loadFromKTX2(e,t){return this._loadAsync(()=>async function(e,t,r){null==_&&(_=await b());const i=new _.KTX2File(new Uint8Array(r));if(!C(i))return null;i.startTranscoding();const n=S(e,t,i.getLevels(),i.getHasAlpha(),i.getWidth(),i.getHeight(),(e,t)=>i.getImageTranscodedSizeInBytes(e,0,0,t),(e,t,r)=>i.transcodeImage(r,e,0,0,t,0,-1,-1));return i.close(),i.delete(),n}(e,this._createDescriptor(e),t).then(e=>(this._glTexture=e,e)))}_loadFromBasis(e,t){return this._loadAsync(()=>async function(e,t,r){null==_&&(_=await b());const i=new _.BasisFile(new Uint8Array(r));if(!T(i))return null;i.startTranscoding();const n=S(e,t,i.getNumLevels(0),i.getHasAlpha(),i.getImageWidth(0,0),i.getImageHeight(0,0),(e,t)=>i.getImageTranscodedSizeInBytes(0,e,t),(e,t,r)=>i.transcodeImage(r,0,e,t,0,0));return i.close(),i.delete(),n}(e,this._createDescriptor(e),t).then(e=>(this._glTexture=e,e)))}_loadFromPixelData(e,t){(0,L.vA)(this._parameters.width>0&&this._parameters.height>0);const r=this._createDescriptor(e);return r.pixelFormat=1===this._parameters.components?6409:3===this._parameters.components?6407:6408,6407!==r.pixelFormat&&6408!==r.pixelFormat||(r.compress=this._parameters.compressionOptions),r.width=this._parameters.width??0,r.height=this._parameters.height??0,this._glTexture=new v.g(e,r,t),this._glTexture}_loadFromURL(e,t){return this._loadAsync(async r=>{const i=await(0,u.D)(t,{signal:r});return(0,a.Te)(r),this._loadFromImage(e,i)})}_loadFromImageElement(e,t){return t.complete?this._loadFromImage(e,t):this._loadAsync(async r=>{const i=await(0,h.Sx)(t,t.src,!1,r);return(0,a.Te)(r),this._loadFromImage(e,i)})}_loadFromVideoElement(e,t){return t.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA?this._loadFromImage(e,t):this._loadFromVideoElementAsync(e,t)}_loadFromVideoElementAsync(e,t){return this._loadAsync(r=>new Promise((n,s)=>{const c=()=>{t.removeEventListener("loadeddata",l),t.removeEventListener("error",d),(0,o.xt)(u)},l=()=>{t.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA&&(c(),n(this._loadFromImage(e,t)))},d=e=>{c(),s(e||new i.A("texture:load-error","Failed to load video"))};t.addEventListener("loadeddata",l),t.addEventListener("error",d);const u=(0,a.u7)(r,()=>d((0,a.NK)()))}))}_loadFromImage(e,t){let r=t;r instanceof HTMLVideoElement||(r=H(r,e.parameters));const i=z(r);this._parameters.width=i.width,this._parameters.height=i.height;const n=this._createDescriptor(e);return n.pixelFormat=3===this._parameters.components?6407:6408,n.width=i.width,n.height=i.height,n.compress=this._parameters.compressionOptions,this._glTexture=new v.g(e,n,r),this._emptyTexture=null,this.events.emit("loaded"),this._glTexture}_loadAsync(e){const t=new AbortController;this._loadingController=t;const r=e(t.signal);this._loadingPromise=r;const i=()=>{this._loadingController===t&&(this._loadingController=null),this._loadingPromise===r&&(this._loadingPromise=null),this._emptyTexture=null};return r.then(i,i),r}unload(){if(this._glTexture=(0,o.WD)(this._glTexture),this._emptyTexture=null,null!=this._loadingController){const e=this._loadingController;this._loadingController=null,this._loadingPromise=null,e.abort()}this.events.emit("unloaded")}get parameters(){return this._parameters}}function z(e){return e instanceof HTMLVideoElement?{width:e.videoWidth,height:e.videoHeight}:e}const U={wrap:{s:10497,t:10497},mipmap:!0,noUnpackFlip:!1,preMultiplyAlpha:!1}},49255:(e,t,r)=>{function i(e){return 4===e||5===e||6===e||7===e}function n(e){return function(e){return function(e){return s(e)||a(e)}(e)||d(e)}(e)||3===e}function o(e){return function(e){return l(e)||d(e)}(e)||3===e}function a(e){return 8===e||9===e}function s(e){return 0===e}function c(e){return s(e)||u(e)}function l(e){return c(e)||a(e)}function d(e){return 2===e}function u(e){return 1===e}function h(e){switch(e){case 2:case 4:case 5:case 6:case 7:return!0}return!1}r.d(t,{LG:()=>u,Mb:()=>l,PJ:()=>i,RN:()=>c,Vg:()=>h,XY:()=>n,iq:()=>o})},49718:(e,t,r)=>{r(51850),r(6867).i},49788:(e,t,r)=>{r.d(t,{Q:()=>i});const i=1/255.5},51406:(e,t,r)=>{r.d(t,{MU:()=>c,O1:()=>l,QM:()=>d,Sx:()=>s,q2:()=>a});var i=r(29242),n=r(31821),o=r(35644);function a(e,t){t.hasColorTextureTransform?(e.varyings.add("colorUV","vec2"),e.vertex.uniforms.add(new o.k("colorTextureTransformMatrix",e=>e.colorTextureTransformMatrix??i.zK)).code.add(n.H`void forwardColorUV(){
525
525
  colorUV = (colorTextureTransformMatrix * vec3(vuv0, 1.0)).xy;
526
526
  }`)):e.vertex.code.add(n.H`void forwardColorUV(){}`)}function s(e,t){t.hasNormalTextureTransform&&0!==t.textureCoordinateType?(e.varyings.add("normalUV","vec2"),e.vertex.uniforms.add(new o.k("normalTextureTransformMatrix",e=>e.normalTextureTransformMatrix??i.zK)).code.add(n.H`void forwardNormalUV(){
527
527
  normalUV = (normalTextureTransformMatrix * vec3(vuv0, 1.0)).xy;
@@ -564,7 +564,7 @@ return applyScreenSizePerspectiveScaleFactorVec2(size, screenSizePerspectiveScal
564
564
  }`)}function c(e){e.uniforms.add(new o.t("screenSizePerspective",e=>d(e.screenSizePerspective)))}function l(e){e.uniforms.add(new o.t("screenSizePerspectiveAlignment",e=>d(e.screenSizePerspectiveAlignment||e.screenSizePerspective)))}function d(e){return(0,i.i)(u,e.parameters.divisor,e.parameters.offset,e.minScaleFactor)}const u=(0,n.vt)()},53466:(e,t,r)=>{r.d(t,{U:()=>o});var i=r(21818),n=r(31821);function o(e,t){switch(t.textureCoordinateType){case 1:return e.attributes.add("uv0","vec2"),e.varyings.add("vuv0","vec2"),void e.vertex.code.add(n.H`void forwardTextureCoordinates() { vuv0 = uv0; }`);case 2:return e.attributes.add("uv0","vec2"),e.attributes.add("uvRegion","vec4"),e.varyings.add("vuv0","vec2"),e.varyings.add("vuvRegion","vec4"),void e.vertex.code.add(n.H`void forwardTextureCoordinates() {
565
565
  vuv0 = uv0;
566
566
  vuvRegion = uvRegion;
567
- }`);default:(0,i.Xb)(t.textureCoordinateType);case 0:return void e.vertex.code.add(n.H`void forwardTextureCoordinates() {}`);case 3:return}}},57323:(e,t,r)=>{r.d(t,{R:()=>B,b:()=>L});var i=r(46686),n=r(32680),o=r(49255),a=r(76591),s=r(76597),c=r(24321),l=r(60864),d=r(43519),u=r(96336),h=r(71955),m=r(53466),p=r(92700),f=r(35640),v=r(40261),g=r(14527),_=r(89390),x=r(98619),b=r(22393),w=r(59469),y=r(39168),M=r(96598),T=r(42398),C=r(58614),S=r(27950),E=r(25178),A=r(33079),R=r(71988),I=r(20304),P=r(31821),F=r(63761),O=r(43616),D=r(59744),H=r(14113),N=r(49788);function L(e){const t=new H.N5,{attributes:r,vertex:L,fragment:B,varyings:G}=t,{output:z,offsetBackfaces:U,pbrMode:V,snowCover:j,spherical:W,hasBloom:k}=e,$=1===V||2===V;if((0,E.NB)(L,e),r.add("position","vec3"),G.add("vpos","vec3",{invariant:!0}),t.include(T.A,e),t.include(l.B,e),t.include(f.Ge,e),t.include(M.Z,e),(0,o.RN)(z)&&((0,E.yu)(t.vertex,e),t.include(u.Y,e),t.include(s.d,e),U&&t.include(n.M),G.add("vNormalWorld","vec3"),G.add("localvpos","vec3",{invariant:!0}),t.include(m.U,e),t.include(i.oD,e),t.include(h.K,e),t.include(c.v,e),t.include(p.c,e),L.include(d.WD),L.include(d.oF),L.uniforms.add(new R.E("externalColor",e=>e.externalColor,{supportsNaN:!0})),G.add("vcolorExt","vec4"),L.main.add(P.H`
567
+ }`);default:(0,i.Xb)(t.textureCoordinateType);case 0:return void e.vertex.code.add(n.H`void forwardTextureCoordinates() {}`);case 3:return}}},57323:(e,t,r)=>{r.d(t,{R:()=>B,b:()=>L});var i=r(46686),n=r(32680),o=r(49255),a=r(76591),s=r(76597),c=r(24321),l=r(60864),d=r(43519),u=r(96336),h=r(71955),m=r(53466),p=r(92700),f=r(35640),v=r(40261),g=r(14527),_=r(89390),x=r(98619),b=r(22393),w=r(59469),y=r(39168),M=r(96598),T=r(42398),C=r(58614),S=r(27950),E=r(25178),A=r(33079),R=r(71988),I=r(20304),P=r(31821),F=r(63761),O=r(43616),D=r(59744),H=r(14113),N=r(49788);function L(e){const t=new H.N5,{attributes:r,vertex:L,fragment:B,varyings:G}=t,{output:z,offsetBackfaces:U,pbrMode:V,snowCover:j,spherical:W,hasBloom:k}=e,$=1===V||2===V;if((0,E.NB)(L,e),r.add("position","vec3"),G.add("vpos","vec3",{invariant:!0}),t.include(T.A,e),t.include(l.B,e),t.include(f.Ge,e),t.include(M.Z,e),!(0,o.RN)(z))return t.include(v.E,e),t;(0,E.yu)(t.vertex,e),t.include(u.Y,e),t.include(s.d,e),U&&t.include(n.M),G.add("vNormalWorld","vec3"),G.add("localvpos","vec3",{invariant:!0}),t.include(m.U,e),t.include(i.oD,e),t.include(h.K,e),t.include(c.v,e),t.include(p.c,e),L.include(d.WD),L.include(d.oF),L.uniforms.add(new R.E("externalColor",e=>e.externalColor,{supportsNaN:!0})),G.add("vcolorExt","vec4"),L.main.add(P.H`
568
568
  forwardNormalizedVertexColor();
569
569
 
570
570
  MaskedColor maskedColorExt =
@@ -588,11 +588,11 @@ vuvRegion = uvRegion;
588
588
 
589
589
  gl_Position = alphaCut ? vec4(1e38, 1e38, 1e38, 1.0) :
590
590
  ${(0,P.If)(U,"offsetBackfacingClipPosition(basePosition, vpos, vNormalWorld, cameraPosition);","basePosition;")}
591
- `)),(0,o.RN)(z)){const{hasColorTexture:r,hasColorTextureTransform:i,receiveShadows:n}=e;t.include(_.kA,e),B.include(g.n,e),t.include(C.S,e),t.include(e.instancedDoublePrecision?y.G:y.Bz,e),B.include(a.HQ,e),t.include(D.z,e),(0,E.yu)(B,e),(0,x.Gc)(B),(0,_.a8)(B),(0,_.eU)(B),B.uniforms.add(L.uniforms.get("localOrigin"),L.uniforms.get("view"),new A.t("ambient",e=>e.ambient),new A.t("diffuse",e=>e.diffuse),new I.m("opacity",e=>e.opacity),new I.m("layerOpacity",e=>e.layerOpacity)),r&&B.uniforms.add(new F.N("tex",e=>e.texture)),t.include(w._,e),B.include(b.c,e),B.include(S.N),(0,x.O4)(B),B.main.add(P.H`
591
+ `);const{hasColorTexture:q,hasColorTextureTransform:Z,receiveShadows:Y}=e;return t.include(_.kA,e),B.include(g.n,e),t.include(C.S,e),t.include(e.instancedDoublePrecision?y.G:y.Bz,e),B.include(a.HQ,e),t.include(D.z,e),(0,E.yu)(B,e),(0,x.Gc)(B),(0,_.a8)(B),(0,_.eU)(B),B.uniforms.add(L.uniforms.get("localOrigin"),L.uniforms.get("view"),new A.t("ambient",e=>e.ambient),new A.t("diffuse",e=>e.diffuse),new I.m("opacity",e=>e.opacity),new I.m("layerOpacity",e=>e.layerOpacity)),q&&B.uniforms.add(new F.N("tex",e=>e.texture)),t.include(w._,e),B.include(b.c,e),B.include(S.N),(0,x.O4)(B),B.main.add(P.H`
592
592
  discardBySlice(vpos);
593
593
  discardByTerrainDepth();
594
- vec4 texColor = ${r?`texture(tex, ${i?"colorUV":"vuv0"})`:" vec4(1.0)"};
595
- ${(0,P.If)(r,`${(0,P.If)(e.textureAlphaPremultiplied,"texColor.rgb /= texColor.a;")}\n discardOrAdjustAlpha(texColor);`)}
594
+ vec4 texColor = ${q?`texture(tex, ${Z?"colorUV":"vuv0"})`:" vec4(1.0)"};
595
+ ${(0,P.If)(q,`${(0,P.If)(e.textureAlphaPremultiplied,"texColor.rgb /= texColor.a;")}\n discardOrAdjustAlpha(texColor);`)}
596
596
  vec3 viewDirection = normalize(vpos - cameraPosition);
597
597
  applyPBRFactors();
598
598
  float ssao = evaluateAmbientOcclusionInverse();
@@ -600,7 +600,7 @@ vuvRegion = uvRegion;
600
600
 
601
601
  float additionalAmbientScale = additionalDirectedAmbientLight(vpos + localOrigin);
602
602
  vec3 additionalLight = ssao * mainLightIntensity * additionalAmbientScale * ambientBoostFactor * lightingGlobalFactor;
603
- float shadow = ${n?"max(lightingGlobalFactor * (1.0 - additionalAmbientScale), readShadowMap(vpos, linearDepth))":W?"lightingGlobalFactor * (1.0 - additionalAmbientScale)":"0.0"};
603
+ float shadow = ${Y?"max(lightingGlobalFactor * (1.0 - additionalAmbientScale), readShadowMap(vpos, linearDepth))":W?"lightingGlobalFactor * (1.0 - additionalAmbientScale)":"0.0"};
604
604
  vec3 matColor = max(ambient, diffuse);
605
605
  ${e.hasVertexColors?P.H`vec3 albedo = mixExternalColor(vColor.rgb * matColor, texColor.rgb, vcolorExt.rgb, colorMixMode);
606
606
  float opacity_ = layerOpacity * mixExternalOpacity(vColor.a * opacity, texColor.a, vcolorExt.a, opacityMixMode);`:P.H`vec3 albedo = mixExternalColor(matColor, texColor.rgb, vcolorExt.rgb, colorMixMode);
@@ -621,7 +621,7 @@ vuvRegion = uvRegion;
621
621
  vec4 emission = ${j||k?"vec4(0.0)":"getEmissions(albedo)"};
622
622
  vec3 shadedColor = evaluateSceneLightingPBR(shadingNormal, albedo, shadow, 1.0 - ssao, additionalLight, viewDirection, normalGround, mrr, emission, additionalAmbientIrradiance);`:P.H`vec3 shadedColor = evaluateSceneLighting(shadingNormal, albedo, shadow, 1.0 - ssao, additionalLight);`}
623
623
  vec4 finalColor = vec4(shadedColor, opacity_);
624
- outputColorHighlightOID(finalColor, vpos, albedo ${(0,P.If)(j,", 1.0")});`)}return t.include(v.E,e),t}const B=Object.freeze(Object.defineProperty({__proto__:null,build:L},Symbol.toStringTag,{value:"Module"}))},57917:(e,t,r)=>{r.d(t,{S:()=>o});var i=r(34275),n=r(20498);function o(e){if(e.length<i.y9)return Array.from(e);if(Array.isArray(e))return Float64Array.from(e);if(!("BYTES_PER_ELEMENT"in e))return Array.from(e);switch(e.BYTES_PER_ELEMENT){case 1:return Uint8Array.from(e);case 2:return(0,i.LW)(e)?(0,n.pX)().from(e):(0,i.jq)(e)?Uint16Array.from(e):Int16Array.from(e);case 4:return Float32Array.from(e);default:return Float64Array.from(e)}}},58614:(e,t,r)=>{r.d(t,{S:()=>a}),r(28421);var i=r(20304),n=r(31821),o=r(49788);function a(e,t){!function(e,t,r){const i=e.fragment,a=t.alphaDiscardMode,s=0===a;2!==a&&3!==a||i.uniforms.add(r),i.code.add(n.H`
624
+ outputColorHighlightOID(finalColor, vpos, albedo ${(0,P.If)(j,", 1.0")});`),t}const B=Object.freeze(Object.defineProperty({__proto__:null,build:L},Symbol.toStringTag,{value:"Module"}))},57917:(e,t,r)=>{r.d(t,{S:()=>o});var i=r(34275),n=r(20498);function o(e){if(e.length<i.y9)return Array.from(e);if(Array.isArray(e))return Float64Array.from(e);if(!("BYTES_PER_ELEMENT"in e))return Array.from(e);switch(e.BYTES_PER_ELEMENT){case 1:return Uint8Array.from(e);case 2:return(0,i.LW)(e)?(0,n.pX)().from(e):(0,i.jq)(e)?Uint16Array.from(e):Int16Array.from(e);case 4:return Float32Array.from(e);default:return Float64Array.from(e)}}},58614:(e,t,r)=>{r.d(t,{S:()=>a}),r(28421);var i=r(20304),n=r(31821),o=r(49788);function a(e,t){!function(e,t,r){const i=e.fragment,a=t.alphaDiscardMode,s=0===a;2!==a&&3!==a||i.uniforms.add(r),i.code.add(n.H`
625
625
  void discardOrAdjustAlpha(inout vec4 color) {
626
626
  ${1===a?"color.a = 1.0;":`if (color.a < ${s?n.H.float(o.Q):"textureAlphaCutoff"}) {\n discard;\n } ${(0,n.If)(2===a,"else { color.a = 1.0; }")}`}
627
627
  }
@@ -808,7 +808,7 @@ rawNormal.xy = (normalRotation * vec3(rawNormal.x, rawNormal.y, 1.0)).xy;`),r.co
808
808
  }`))}},78662:(e,t,r)=>{r.d(t,{Gd:()=>c,VC:()=>l}),r(44208);var i=r(34727),n=(r(77690),r(29242),r(58083),r(9093)),o=r(38954),a=r(51850),s=(r(87317),r(91829),r(31756),r(26857),r(16943),r(65786));class c extends s.Y{constructor(e){super(),this.vvSize=e?.size??null,this.vvColor=e?.color??null,this.vvOpacity=e?.opacity??null}}function l(e,t,r){if(!t.vvSize)return(0,o.i)(e,1,1,1),e;if(Number.isNaN(r[0]))return(0,o.c)(e,t.vvSize.fallback);for(let n=0;n<3;++n){const o=t.vvSize.offset[n]+r[0]*t.vvSize.factor[n];e[n]=(0,i.qE)(o,t.vvSize.minSize[n],t.vvSize.maxSize[n])}return e}(0,n.vt)(),(0,a.vt)(),(0,n.vt)()},82048:(e,t,r)=>{r.d(t,{c:()=>n});var i=r(31821);function n(e,t=!0){e.attributes.add("position","vec2"),t&&e.varyings.add("uv","vec2"),e.vertex.main.add(i.H`
809
809
  gl_Position = vec4(position, 0.0, 1.0);
810
810
  ${t?i.H`uv = position * 0.5 + vec2(0.5);`:""}
811
- `)}},82919:(e,t,r)=>{r.d(t,{DV:()=>g,C:()=>f,vt:()=>m,Qy:()=>p,ui:()=>v,ST:()=>b,bU:()=>w,pw:()=>x,m7:()=>_,c8:()=>M});var i=r(4341),n=r(58083),o=r(38954),a=r(51850),s=r(87317),c=r(91829),l=r(71351);function d(e){return e?{ray:(0,l.vt)(e.ray),c0:e.c0,c1:e.c1}:{ray:(0,l.vt)(),c0:0,c1:Number.MAX_VALUE}}new i.I(()=>d());var u=r(27921),h=r(32114);function m(e){return e?[(0,u.vt)(e[0]),(0,u.vt)(e[1]),(0,u.vt)(e[2]),(0,u.vt)(e[3]),(0,u.vt)(e[4]),(0,u.vt)(e[5])]:[(0,u.vt)(),(0,u.vt)(),(0,u.vt)(),(0,u.vt)(),(0,u.vt)(),(0,u.vt)()]}function p(){return[(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)()]}function f(e,t){for(let r=0;r<T;r++)(0,u.C)(e[r],t[r]);return e}function v(e,t,r,i=A){const a=(0,n.lw)(h.Rc.get(),t,e);(0,n.B8)(a,a);for(let e=0;e<C;++e){const t=(0,s.t)(h.Km.get(),S[e],a);(0,o.i)(i[e],t[0]/t[3],t[1]/t[3],t[2]/t[3])}g(r,i)}function g(e,t){(0,u.Cr)(t[4],t[0],t[3],e[0]),(0,u.Cr)(t[1],t[5],t[6],e[1]),(0,u.Cr)(t[4],t[5],t[1],e[2]),(0,u.Cr)(t[3],t[2],t[6],e[3]),(0,u.Cr)(t[0],t[1],t[2],e[4]),(0,u.Cr)(t[5],t[4],t[7],e[5])}function _(e,t){for(let r=0;r<T;r++){const i=e[r];if(i[0]*t[0]+i[1]*t[1]+i[2]*t[2]+i[3]>=t[3])return!1}return!0}function x(e,t){return y(e,function(e,t=d()){return(0,l.C)(e,t.ray),t.c0=0,t.c1=Number.MAX_VALUE,t}(t,E.get()))}function b(e,t,r){return y(e,function(e,t,r=d()){const i=(0,o.l)(e.vector);return(0,l.fA)(e.origin,t,r.ray),r.c0=0,r.c1=i,r}(t,r,E.get()))}function w(e,t){for(let r=0;r<T;r++)if((0,u.mN)(e[r],t)>0)return!1;return!0}function y(e,t){for(let r=0;r<T;r++)if(!(0,u.$Q)(e[r],t))return!1;return!0}const M={bottom:[5,1,0,4],near:[0,1,2,3],far:[5,4,7,6],right:[1,5,6,2],left:[4,0,3,7],top:[7,3,2,6]},T=6,C=8,S=[(0,c.fA)(-1,-1,-1,1),(0,c.fA)(1,-1,-1,1),(0,c.fA)(1,1,-1,1),(0,c.fA)(-1,1,-1,1),(0,c.fA)(-1,-1,1,1),(0,c.fA)(1,-1,1,1),(0,c.fA)(1,1,1,1),(0,c.fA)(-1,1,1,1)],E=new i.I(d),A=p()},87170:(e,t,r)=>{r.d(t,{V:()=>M});var i=r(24326),n=r(9093),o=r(38954),a=r(97146),s=r(57917),c=r(29920),l=r(51850),d=r(4341),u=r(11964);function h(e,t,r){return(0,o.d)(m,t,e),(0,o.d)(p,r,e),.5*(0,o.l)((0,o.h)(m,m,p))}r(32114),new d.I(u.vt),new d.I(()=>function(e){return e?{p0:(0,l.o8)(e.p0),p1:(0,l.o8)(e.p1),p2:(0,l.o8)(e.p2)}:{p0:(0,l.vt)(),p1:(0,l.vt)(),p2:(0,l.vt)()}}());const m=(0,l.vt)(),p=(0,l.vt)(),f=(0,l.vt)(),v=(0,l.vt)(),g=(0,l.vt)(),_=(0,l.vt)();class x{constructor(){this.uid=(0,i.c)()}}class b extends x{constructor(e){super(),this.highlightName=e,this.channel=0}}var w=r(620),y=r(94656);class M{constructor(e,t,r=null,n=0,o=null,s=-1){this.material=e,this.mapPositions=r,this.type=n,this.objectAndLayerIdColor=o,this.edgeIndicesLength=s,this.highlights=new Set,this._highlightOptionsCounts=new Map,this.id=(0,i.c)(),this.visible=!0,this._attributes=new Map,this._boundingInfo=null;for(const[e,r]of t)this._attributes.set(e,{...r,indices:(0,a.Dg)(r.indices)}),"position"===e&&(this.edgeIndicesLength=this.edgeIndicesLength<0?this._attributes.get(e).indices.length:this.edgeIndicesLength)}instantiate(e={}){const t=new M(e.material||this.material,[],this.mapPositions,this.type,this.objectAndLayerIdColor,this.edgeIndicesLength);return this._attributes.forEach((e,r)=>{e.exclusive=!1,t._attributes.set(r,e)}),t._boundingInfo=this._boundingInfo,t.transformation=e.transformation||this.transformation,t}get attributes(){return this._attributes}getMutableAttribute(e){let t=this._attributes.get(e);return t&&!t.exclusive&&(t={...t,exclusive:!0,data:(0,s.S)(t.data)},this._attributes.set(e,t)),t}setAttributeData(e,t){const r=this._attributes.get(e);r?this._attributes.set(e,{...r,exclusive:!0,data:t}):(0,y.en)()&&console.warn(`Setting undefined attribute ${e} data`)}get indexCount(){const e=this._attributes.values().next().value?.indices;return e?.length??0}get faceCount(){return this.indexCount/3}get boundingInfo(){return this._boundingInfo??=this._calculateBoundingInfo(),this._boundingInfo}computeAttachmentOrigin(e){return!!(0===this.type?this._computeAttachmentOriginTriangles(e):2===this.type?this._computeAttachmentOriginLines(e):this._computeAttachmentOriginPoints(e))&&(null!=this._transformation&&(0,o.t)(e,e,this._transformation),!0)}_computeAttachmentOriginTriangles(e){return function(e,t){if(!e)return!1;const{size:r,data:i,indices:n}=e;(0,o.i)(t,0,0,0),(0,o.i)(_,0,0,0);let a=0,s=0;for(let e=0;e<n.length-2;e+=3){const c=n[e]*r,l=n[e+1]*r,d=n[e+2]*r;(0,o.i)(f,i[c],i[c+1],i[c+2]),(0,o.i)(v,i[l],i[l+1],i[l+2]),(0,o.i)(g,i[d],i[d+1],i[d+2]);const u=h(f,v,g);u?((0,o.f)(f,f,v),(0,o.f)(f,f,g),(0,o.g)(f,f,1/3*u),(0,o.f)(t,t,f),a+=u):((0,o.f)(_,_,f),(0,o.f)(_,_,v),(0,o.f)(_,_,g),s+=3)}return!(0===s&&0===a||(0!==a?((0,o.g)(t,t,1/a),0):0===s||((0,o.g)(t,_,1/s),0)))}(this.attributes.get("position"),e)}_computeAttachmentOriginLines(e){const t=this.attributes.get("position");return function(e,t,r){if(!e)return!1;(0,o.i)(r,0,0,0),(0,o.i)(_,0,0,0);let i=0,n=0;const{size:a,data:s,indices:c}=e,l=c.length-1,d=l+(t?2:0);for(let e=0;e<d;e+=2){const t=e<l?e+1:0,d=c[e<l?e:l]*a,u=c[t]*a;f[0]=s[d],f[1]=s[d+1],f[2]=s[d+2],v[0]=s[u],v[1]=s[u+1],v[2]=s[u+2],(0,o.g)(f,(0,o.f)(f,f,v),.5);const h=(0,o.F)(f,v);h>0?((0,o.f)(r,r,(0,o.g)(f,f,h)),i+=h):0===i&&((0,o.f)(_,_,f),n++)}return 0!==i?((0,o.g)(r,r,1/i),!0):0!==n&&((0,o.g)(r,_,1/n),!0)}(t,function(e,t){return!(!("isClosed"in e)||!e.isClosed)&&t.indices.length>2}(this.material.parameters,t),e)}_computeAttachmentOriginPoints(e){return function(e,t){if(!e)return!1;const{size:r,data:i,indices:n}=e;(0,o.i)(t,0,0,0);let a=-1,s=0;for(let e=0;e<n.length;e++){const o=n[e]*r;a!==o&&(t[0]+=i[o],t[1]+=i[o+1],t[2]+=i[o+2],s++),a=o}return s>1&&(0,o.g)(t,t,1/s),s>0}(this.attributes.get("position"),e)}invalidateBoundingInfo(){this._boundingInfo=null}_calculateBoundingInfo(){const e=this.attributes.get("position");if(!e||0===e.indices.length)return null;const t=0===this.type?3:1;(0,w.vA)(e.indices.length%t===0,"Indexing error: "+e.indices.length+" not divisible by "+t);const r=(0,a.tM)(e.indices.length/t);return new c.j(r,t,e)}get transformation(){return this._transformation??n.zK}set transformation(e){this._transformation=e&&e!==n.zK?(0,n.o8)(e):null}get highlightNames(){return this._highlightOptionsCounts}get hasHighlights(){return this._highlightOptionsCounts.size>0}foreachHighlightOptions(e){this._highlightOptionsCounts.forEach((t,r)=>e(r))}allocateIdAndHighlight(e){const t=new b(e);return this.addHighlight(t)}addHighlight(e){this.highlights.add(e);const{highlightName:t}=e,r=(this._highlightOptionsCounts.get(t)??0)+1;return this._highlightOptionsCounts.set(t,r),e}removeHighlight(e){if(this.highlights.delete(e)){const{highlightName:t}=e,r=this._highlightOptionsCounts.get(t)??0;r<=1?this._highlightOptionsCounts.delete(t):this._highlightOptionsCounts.set(t,r-1)}}}},88076:(e,t,r)=>{r.d(t,{$U:()=>ie,fs:()=>oe,ty:()=>ae});var i=r(38954),n=r(51850),o=r(1843),a=r(49255),s=r(16943),c=r(25634),l=r(11725),d=r(33524),u=r(70328),h=r(620);class m{constructor(e=!1,t=!0){this.isVerticalRay=e,this.normalRequired=t}}const p=(0,u.vt)();function f(e,t,r,n,o,a){if(!e.visible)return;const s=(0,i.a)(A,n,r),c=(e,t,r)=>{a(e,r,t)},l=new m(!1,t.options.normalRequired);if(e.boundingInfo){(0,h.vA)(0===e.type);const i=t.tolerance;g(e.boundingInfo,r,s,i,o,l,c)}else{const t=e.attributes.get("position"),n=t.indices;!function(e,t,r,n,o,a,s,c,l,d){const u=t,h=R,m=Math.abs(u[0]),p=Math.abs(u[1]),f=Math.abs(u[2]),v=m>=p?m>=f?0:2:p>=f?1:2,g=v,_=u[g]<0?2:1,y=(v+_)%3,T=(v+(3-_))%3,C=u[y]/u[g],S=u[T]/u[g],E=1/u[g],A=x,I=b,P=w,{normalRequired:F}=l;for(let t=r;t<n;++t){const r=3*t,n=s*o[r];(0,i.i)(h[0],a[n+0],a[n+1],a[n+2]);const l=s*o[r+1];(0,i.i)(h[1],a[l+0],a[l+1],a[l+2]);const u=s*o[r+2];(0,i.i)(h[2],a[u+0],a[u+1],a[u+2]),c&&((0,i.c)(h[0],c.applyToVertex(h[0][0],h[0][1],h[0][2],t)),(0,i.c)(h[1],c.applyToVertex(h[1][0],h[1][1],h[1][2],t)),(0,i.c)(h[2],c.applyToVertex(h[2][0],h[2][1],h[2][2],t))),(0,i.a)(A,h[0],e),(0,i.a)(I,h[1],e),(0,i.a)(P,h[2],e);const m=A[y]-C*A[g],p=A[T]-S*A[g],f=I[y]-C*I[g],v=I[T]-S*I[g],_=P[y]-C*P[g],x=P[T]-S*P[g],b=_*v-x*f,w=m*x-p*_,R=f*p-v*m;if((b<0||w<0||R<0)&&(b>0||w>0||R>0))continue;const O=b+w+R;if(0===O)continue;const D=b*(E*A[g])+w*(E*I[g])+R*(E*P[g]);if(D*Math.sign(O)<0)continue;const H=D/O;H>=0&&d(H,t,F?M(h):null)}}(r,s,0,n.length/3,n,t.data,t.stride,o,l,c)}}const v=(0,n.vt)();function g(e,t,r,n,o,a,s){if(null==e)return;const c=function(e,t){return(0,i.i)(t,1/e[0],1/e[1],1/e[2])}(r,v);if((0,u.Ne)(p,e.bbMin),(0,u.vI)(p,e.bbMax),null!=o&&o.applyToAabb(p),function(e,t,r,i){return function(e,t,r,i){const n=(e[0]-i-t[0])*r[0],o=(e[3]+i-t[0])*r[0];let a=Math.min(n,o),s=Math.max(n,o);const c=(e[1]-i-t[1])*r[1],l=(e[4]+i-t[1])*r[1];if(s=Math.min(s,Math.max(c,l)),s<0)return!1;if(a=Math.max(a,Math.min(c,l)),a>s)return!1;const d=(e[2]-i-t[2])*r[2],u=(e[5]+i-t[2])*r[2];return s=Math.min(s,Math.max(d,u)),!(s<0)&&(a=Math.max(a,Math.min(d,u)),!(a>s)&&a<1/0)}(e,t,r,i)}(p,t,c,n)){const{primitiveIndices:i,position:c}=e,l=i?i.length:c.indices.length/3;if(l>S){const i=e.getChildren();if(void 0!==i){for(const e of i)g(e,t,r,n,o,a,s);return}}!function(e,t,r,i,n,o,a,s,c,l,d){const u=e[0],h=e[1],m=e[2],p=t[0],f=t[1],v=t[2],{normalRequired:g}=l;for(let e=0;e<i;++e){const t=s[e],r=3*t,i=a*n[r];let l=o[i],x=o[i+1],b=o[i+2];const w=a*n[r+1];let M=o[w],T=o[w+1],C=o[w+2];const S=a*n[r+2];let A=o[S],R=o[S+1],I=o[S+2];null!=c&&([l,x,b]=c.applyToVertex(l,x,b,e),[M,T,C]=c.applyToVertex(M,T,C,e),[A,R,I]=c.applyToVertex(A,R,I,e));const P=M-l,F=T-x,O=C-b,D=A-l,H=R-x,N=I-b,L=f*N-H*v,B=v*D-N*p,G=p*H-D*f,z=P*L+F*B+O*G;if(Math.abs(z)<=E)continue;const U=u-l,V=h-x,j=m-b,W=U*L+V*B+j*G;if(z>0){if(W<0||W>z)continue}else if(W>0||W<z)continue;const k=V*O-F*j,$=j*P-O*U,q=U*F-P*V,Z=p*k+f*$+v*q;if(z>0){if(Z<0||W+Z>z)continue}else if(Z>0||W+Z<z)continue;const Y=(D*k+H*$+N*q)/z;Y>=0&&d(Y,t,g?y(P,F,O,D,H,N,_):null)}}(t,r,0,l,c.indices,c.data,c.stride,i,o,a,s)}}const _=(0,n.vt)();const x=(0,n.vt)(),b=(0,n.vt)(),w=(0,n.vt)();function y(e,t,r,n,o,a,s){return(0,i.i)(T,e,t,r),(0,i.i)(C,n,o,a),(0,i.h)(s,T,C),(0,i.n)(s,s),s}function M(e){return(0,i.a)(T,e[1],e[0]),(0,i.a)(C,e[2],e[0]),(0,i.h)(_,T,C),(0,i.n)(_,_),_}const T=(0,n.vt)(),C=(0,n.vt)(),S=1e3,E=1e-7,A=(0,n.vt)(),R=[(0,n.vt)(),(0,n.vt)(),(0,n.vt)()];var I=r(16396),P=r(13030),F=r(59907);class O{constructor(e){this.vertexBufferLayout=e}elementCount(e){return e.get("position").indices.length}write(e,t,r,i,n,o){return(0,F.SA)(r,i,this.vertexBufferLayout,e,t,n,o)}intersect(e,t,r,n,o,a,s){const c=this.vertexBufferLayout.createView(e).getField("position",P.xs);if(null==c)return;const l=(0,i.a)(D,a,o),d=c.count/3,u=n.options.normalRequired;!function(e,t,r,i,n,o,a,s){const c=e[0],l=e[1],d=e[2],u=t[0],h=t[1],m=t[2];for(let e=0;e<i;++e){const t=3*e,r=t+1,i=t+2,p=o*t,f=n[p],v=n[p+1],g=n[p+2],x=o*r,b=o*i,w=n[x]-f,M=n[x+1]-v,T=n[x+2]-g,C=n[b]-f,S=n[b+1]-v,A=n[b+2]-g,R=h*A-S*m,I=m*C-A*u,P=u*S-C*h,F=w*R+M*I+T*P;if(Math.abs(F)<=E)continue;const O=c-f,D=l-v,H=d-g,N=O*R+D*I+H*P;if(F>0){if(N<0||N>F)continue}else if(N>0||N<F)continue;const L=D*T-M*H,B=H*w-T*O,G=O*M-w*D,z=u*L+h*B+m*G;if(F>0){if(z<0||N+z>F)continue}else if(z>0||N+z<F)continue;const U=(C*L+S*B+A*G)/F;U>=0&&s(U,e,a?y(w,M,T,C,S,A,_):null)}}(o,l,0,d,c.typedBuffer,c.typedBufferStride,u,(e,t,r)=>{s(e,r,t)})}}const D=(0,n.vt)();var H=r(43616),N=r(91829),L=r(72824),B=r(97220),G=r(98958);const z={mask:255},U={function:{func:519,ref:2,mask:2},operation:{fail:7680,zFail:7680,zPass:0}},V={function:{func:519,ref:2,mask:2},operation:{fail:7680,zFail:7680,zPass:7681}};var j=r(74810),W=r(28491),k=r(90644),$=r(49788);class q extends L.Zo{constructor(){super(...arguments),this.isSchematic=!1,this.usePBR=!1,this.mrrFactors=j.mb,this.hasVertexColors=!1,this.hasSymbolColors=!1,this.doubleSided=!1,this.doubleSidedType="normal",this.cullFace=2,this.isInstanced=!1,this.hasInstancedColor=!1,this.instanceColorEncodesAlphaIgnore=!1,this.emissiveStrength=0,this.emissiveSource=1,this.emissiveBaseColor=n.uY,this.instancedDoublePrecision=!1,this.normalType=0,this.receiveShadows=!0,this.receiveAmbientOcclusion=!0,this.castShadows=!0,this.ambient=(0,n.CN)(.2,.2,.2),this.diffuse=(0,n.CN)(.8,.8,.8),this.externalColor=(0,N.fA)(1,1,1,1),this.colorMixMode="multiply",this.opacity=1,this.layerOpacity=1,this.origin=(0,n.vt)(),this.hasSlicePlane=!1,this.offsetTransparentBackfaces=!1,this.vvSize=null,this.vvColor=null,this.vvOpacity=null,this.vvSymbolAnchor=null,this.vvSymbolRotationMatrix=null,this.modelTransformation=null,this.drivenOpacity=!1,this.writeDepth=!0,this.customDepthTest=0,this.textureAlphaMode=0,this.textureAlphaCutoff=$.Q,this.textureAlphaPremultiplied=!1,this.renderOccluded=1,this.isDecoration=!1}}L.gy;class Z extends G.w{constructor(e,t,i=new B.$(W.D,()=>r.e(5141).then(r.bind(r,5141)))){super(e,t,i),this.type="DefaultMaterialTechnique"}_makePipeline(e,t){const{oitPass:r,output:i,transparent:n,cullFace:o,customDepthTest:s,hasOccludees:c}=e;return(0,k.Ey)({blending:(0,a.RN)(i)&&n?(0,d.Yf)(r):null,culling:X(e)?(0,k.Xt)(o):null,depthTest:{func:(0,d.K_)(r,Y(s))},depthWrite:(0,d.z5)(e),drawBuffers:(0,G.L)(i,(0,d.m6)(r,i)),colorWrite:k.kn,stencilWrite:c?z:null,stencilTest:c?t?V:U:null,polygonOffset:(0,d.mE)(e)})}initializePipeline(e){return this._occludeePipelineState=this._makePipeline(e,!0),this._makePipeline(e,!1)}getPipeline(e){return e?this._occludeePipelineState:super.getPipeline()}}function Y(e){return 1===e?515:513}function X(e){return 0!==e.cullFace||!e.hasSlicePlane&&!e.transparent&&!e.doubleSidedMode}var J=r(31635),K=r(51976),Q=r(35256);class ee extends Q.E{constructor(e){super(),this.spherical=e,this.alphaDiscardMode=1,this.doubleSidedMode=0,this.pbrMode=0,this.cullFace=0,this.normalType=0,this.customDepthTest=0,this.emissionSource=0,this.hasVertexColors=!1,this.hasSymbolColors=!1,this.hasVerticalOffset=!1,this.hasColorTexture=!1,this.hasMetallicRoughnessTexture=!1,this.hasOcclusionTexture=!1,this.hasNormalTexture=!1,this.hasScreenSizePerspective=!1,this.hasVertexTangents=!1,this.hasOccludees=!1,this.instancedDoublePrecision=!1,this.hasModelTransformation=!1,this.offsetBackfaces=!1,this.vvSize=!1,this.vvColor=!1,this.receiveShadows=!1,this.receiveAmbientOcclusion=!1,this.textureAlphaPremultiplied=!1,this.instanced=!1,this.instancedColor=!1,this.writeDepth=!0,this.transparent=!1,this.enableOffset=!0,this.terrainDepthTest=!1,this.cullAboveTerrain=!1,this.snowCover=!1,this.hasBloom=!1,this.hasColorTextureTransform=!1,this.hasEmissionTextureTransform=!1,this.hasNormalTextureTransform=!1,this.hasOcclusionTextureTransform=!1,this.hasMetallicRoughnessTextureTransform=!1,this.occlusionPass=!1,this.hasVvInstancing=!0,this.useCustomDTRExponentForWater=!1,this.useFillLights=!0,this.draped=!1}get textureCoordinateType(){return this.hasColorTexture||this.hasMetallicRoughnessTexture||3===this.emissionSource||this.hasOcclusionTexture||this.hasNormalTexture?1:0}get objectAndLayerIdColorInstanced(){return this.instanced}get discardInvisibleFragments(){return this.transparent}}(0,J.Cg)([(0,K.W)({count:4})],ee.prototype,"alphaDiscardMode",void 0),(0,J.Cg)([(0,K.W)({count:3})],ee.prototype,"doubleSidedMode",void 0),(0,J.Cg)([(0,K.W)({count:7})],ee.prototype,"pbrMode",void 0),(0,J.Cg)([(0,K.W)({count:3})],ee.prototype,"cullFace",void 0),(0,J.Cg)([(0,K.W)({count:3})],ee.prototype,"normalType",void 0),(0,J.Cg)([(0,K.W)({count:2})],ee.prototype,"customDepthTest",void 0),(0,J.Cg)([(0,K.W)({count:4})],ee.prototype,"emissionSource",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasVertexColors",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasSymbolColors",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasVerticalOffset",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasColorTexture",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasMetallicRoughnessTexture",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasOcclusionTexture",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasNormalTexture",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasScreenSizePerspective",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasVertexTangents",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasOccludees",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"instancedDoublePrecision",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasModelTransformation",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"offsetBackfaces",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"vvSize",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"vvColor",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"receiveShadows",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"receiveAmbientOcclusion",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"textureAlphaPremultiplied",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"instanced",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"instancedColor",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"writeDepth",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"transparent",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"enableOffset",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"terrainDepthTest",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"cullAboveTerrain",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"snowCover",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasBloom",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasColorTextureTransform",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasEmissionTextureTransform",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasNormalTextureTransform",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasOcclusionTextureTransform",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasMetallicRoughnessTextureTransform",void 0);var te=r(57323);class re extends Z{constructor(e,t){super(e,t,new B.$(te.R,()=>r.e(9933).then(r.bind(r,39933)))),this.type="RealisticTreeTechnique"}}class ie extends l.i{constructor(e,t){super(e,oe),this.materialType="default",this.supportsEdges=!0,this.intersectDraped=void 0,this.produces=new Map([[2,e=>((0,a.iq)(e)||(0,a.PJ)(e))&&!this.transparent],[4,e=>((0,a.iq)(e)||(0,a.PJ)(e))&&this.transparent&&this.parameters.writeDepth],[7,e=>((0,a.XY)(e)||(0,a.PJ)(e))&&this.transparent&&!this.parameters.writeDepth]]),this._vertexBufferLayout=function(e){const t=(0,o.BP)().vec3f("position");return 1===e.normalType?t.vec2i16("normalCompressed",{glNormalized:!0}):t.vec3f("normal"),e.hasVertexTangents&&t.vec4f("tangent"),(e.textureId||e.normalTextureId||e.metallicRoughnessTextureId||e.emissiveTextureId||e.occlusionTextureId)&&t.vec2f16("uv0"),e.hasVertexColors&&t.vec4u8("color"),e.hasSymbolColors&&t.vec4u8("symbolColor"),(0,s.E)()&&t.vec4u8("objectAndLayerIdColor"),t}(this.parameters),this._configuration=new ee(t.spherical)}isVisibleForOutput(e){return 4!==e&&6!==e&&5!==e||this.parameters.castShadows}get visible(){const{layerOpacity:e,colorMixMode:t,opacity:r,externalColor:i}=this.parameters;return e*("replace"===t?1:r)*("ignore"===t||isNaN(i[3])?1:i[3])>=$.Q}get _hasEmissiveBase(){return!!this.parameters.emissiveTextureId||!(0,i.q)(this.parameters.emissiveBaseColor,n.uY)}get hasEmissions(){return this.parameters.emissiveStrength>0&&(0===this.parameters.emissiveSource&&this._hasEmissiveBase||1===this.parameters.emissiveSource)}getConfiguration(e,t){const{parameters:r,_configuration:i}=this,{treeRendering:n,doubleSided:o,doubleSidedType:s}=r;return super.getConfiguration(e,t,this._configuration),i.hasNormalTexture=!n&&!!r.normalTextureId,i.hasColorTexture=!!r.textureId,i.hasVertexTangents=!n&&r.hasVertexTangents,i.instanced=r.isInstanced,i.instancedDoublePrecision=r.instancedDoublePrecision,i.vvSize=!!r.vvSize,i.hasVerticalOffset=null!=r.verticalOffset,i.hasScreenSizePerspective=null!=r.screenSizePerspective,i.hasSlicePlane=r.hasSlicePlane,i.alphaDiscardMode=r.textureAlphaMode,i.normalType=n?0:r.normalType,i.transparent=this.transparent,i.writeDepth=r.writeDepth,i.customDepthTest=r.customDepthTest??0,i.hasOccludees=t.hasOccludees,i.cullFace=r.hasSlicePlane?0:r.cullFace,i.cullAboveTerrain=t.cullAboveTerrain,i.hasModelTransformation=!n&&null!=r.modelTransformation,i.hasVertexColors=r.hasVertexColors,i.hasSymbolColors=r.hasSymbolColors,i.doubleSidedMode=n?2:o&&"normal"===s?1:o&&"winding-order"===s?2:0,i.instancedColor=r.hasInstancedColor,(0,a.RN)(e)?(i.terrainDepthTest=t.terrainDepthTest,i.receiveShadows=r.receiveShadows,i.receiveAmbientOcclusion=r.receiveAmbientOcclusion&&null!=t.ssao):(i.terrainDepthTest=!1,i.receiveShadows=i.receiveAmbientOcclusion=!1),i.vvColor=!!r.vvColor,i.textureAlphaPremultiplied=!!r.textureAlphaPremultiplied,i.pbrMode=r.usePBR?r.isSchematic?2:1:0,i.hasMetallicRoughnessTexture=!n&&!!r.metallicRoughnessTextureId,i.emissionSource=n?0:null!=r.emissiveTextureId&&0===r.emissiveSource?3:r.usePBR?0===r.emissiveSource?2:1:0,i.hasOcclusionTexture=!n&&!!r.occlusionTextureId,i.offsetBackfaces=!(!this.transparent||!r.offsetTransparentBackfaces),i.oitPass=t.oitPass,i.enableOffset=t.camera.relativeElevation<d.xt,i.snowCover=t.snowCover,i.hasBloom=(0,a.LG)(e),i.hasColorTextureTransform=!!r.colorTextureTransformMatrix,i.hasNormalTextureTransform=!!r.normalTextureTransformMatrix,i.hasEmissionTextureTransform=!!r.emissiveTextureTransformMatrix,i.hasOcclusionTextureTransform=!!r.occlusionTextureTransformMatrix,i.hasMetallicRoughnessTextureTransform=!!r.metallicRoughnessTextureTransformMatrix,i}intersect(e,t,r,n,o,a){if(null!=this.parameters.verticalOffset){const e=r.camera;(0,i.i)(he,t[12],t[13],t[14]);let a=null;switch(r.viewingMode){case 1:a=(0,i.n)(de,he);break;case 2:a=(0,i.c)(de,le)}let s=0;const c=(0,i.d)(me,he,e.eye),l=(0,i.l)(c),d=(0,i.g)(c,c,1/l);let u=null;this.parameters.screenSizePerspective&&(u=(0,i.e)(a,d)),s+=(0,H.kE)(e,l,this.parameters.verticalOffset,u??0,this.parameters.screenSizePerspective),(0,i.g)(a,a,s),(0,i.o)(ue,a,r.transform.inverseRotation),n=(0,i.d)(se,n,ue),o=(0,i.d)(ce,o,ue)}f(e,r,n,o,(0,I.ou)(r.verticalOffset),a)}createGLMaterial(e){return new ne(e)}createBufferWriter(){return new O(this._vertexBufferLayout)}get transparent(){return ae(this.parameters)}}class ne extends c.m8{constructor(e){super({...e,...e.material.parameters})}beginSlot(e){this._material.setParameters({receiveShadows:e.shadowMap.enabled});const t=this._material.parameters;this.updateTexture(t.textureId);const r=e.camera.viewInverseTransposeMatrix;return(0,i.i)(t.origin,r[3],r[7],r[11]),this._material.setParameters(this.textureBindParameters),this.getTechnique(t.treeRendering?re:Z,e)}}class oe extends q{constructor(){super(...arguments),this.treeRendering=!1,this.hasVertexTangents=!1}}function ae(e){const{drivenOpacity:t,opacity:r,externalColor:i,layerOpacity:n,texture:o,textureId:a,textureAlphaMode:s,colorMixMode:c}=e,l=i[3];return t||r<1&&"replace"!==c||l<1&&"ignore"!==c||n<1||(null!=o||null!=a)&&1!==s&&2!==s&&"replace"!==c}const se=(0,n.vt)(),ce=(0,n.vt)(),le=(0,n.fA)(0,0,1),de=(0,n.vt)(),ue=(0,n.vt)(),he=(0,n.vt)(),me=(0,n.vt)()},89390:(e,t,r)=>{r.d(t,{kA:()=>C,a8:()=>M,eU:()=>T});var i=r(40876),n=(r(44208),r(38954)),o=r(51850),a=r(87317),s=r(91829),c=r(23205),l=r(14314),d=r(31821);function u(e,t){const r=e.fragment,i=void 0!==t.lightingSphericalHarmonicsOrder?t.lightingSphericalHarmonicsOrder:2;0===i?(r.uniforms.add(new c.d("lightingAmbientSH0",({lighting:e})=>(0,n.i)(h,e.sh.r[0],e.sh.g[0],e.sh.b[0]))),r.code.add(d.H`vec3 calculateAmbientIrradiance(vec3 normal, float ambientOcclusion) {
811
+ `)}},82919:(e,t,r)=>{r.d(t,{DV:()=>g,C:()=>f,vt:()=>m,Qy:()=>p,ui:()=>v,ST:()=>b,bU:()=>w,pw:()=>x,m7:()=>_,c8:()=>M});var i=r(4341),n=r(58083),o=r(38954),a=r(51850),s=r(87317),c=r(91829),l=r(71351);function d(e){return e?{ray:(0,l.vt)(e.ray),c0:e.c0,c1:e.c1}:{ray:(0,l.vt)(),c0:0,c1:Number.MAX_VALUE}}new i.I(()=>d());var u=r(27921),h=r(32114);function m(e){return e?[(0,u.vt)(e[0]),(0,u.vt)(e[1]),(0,u.vt)(e[2]),(0,u.vt)(e[3]),(0,u.vt)(e[4]),(0,u.vt)(e[5])]:[(0,u.vt)(),(0,u.vt)(),(0,u.vt)(),(0,u.vt)(),(0,u.vt)(),(0,u.vt)()]}function p(){return[(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)(),(0,a.vt)()]}function f(e,t){for(let r=0;r<T;r++)(0,u.C)(e[r],t[r]);return e}function v(e,t,r,i=A){const a=(0,n.lw)(h.Rc.get(),t,e);(0,n.B8)(a,a);for(let e=0;e<C;++e){const t=(0,s.t)(h.Km.get(),S[e],a);(0,o.i)(i[e],t[0]/t[3],t[1]/t[3],t[2]/t[3])}g(r,i)}function g(e,t){(0,u.Cr)(t[4],t[0],t[3],e[0]),(0,u.Cr)(t[1],t[5],t[6],e[1]),(0,u.Cr)(t[4],t[5],t[1],e[2]),(0,u.Cr)(t[3],t[2],t[6],e[3]),(0,u.Cr)(t[0],t[1],t[2],e[4]),(0,u.Cr)(t[5],t[4],t[7],e[5])}function _(e,t){for(let r=0;r<T;r++){const i=e[r];if(i[0]*t[0]+i[1]*t[1]+i[2]*t[2]+i[3]>=t[3])return!1}return!0}function x(e,t){return y(e,function(e,t=d()){return(0,l.C)(e,t.ray),t.c0=0,t.c1=Number.MAX_VALUE,t}(t,E.get()))}function b(e,t,r){return y(e,function(e,t,r=d()){const i=(0,o.l)(e.vector);return(0,l.fA)(e.origin,t,r.ray),r.c0=0,r.c1=i,r}(t,r,E.get()))}function w(e,t){for(let r=0;r<T;r++)if((0,u.mN)(e[r],t)>0)return!1;return!0}function y(e,t){for(let r=0;r<T;r++)if(!(0,u.$Q)(e[r],t))return!1;return!0}const M={bottom:[5,1,0,4],near:[0,1,2,3],far:[5,4,7,6],right:[1,5,6,2],left:[4,0,3,7],top:[7,3,2,6]},T=6,C=8,S=[(0,c.fA)(-1,-1,-1,1),(0,c.fA)(1,-1,-1,1),(0,c.fA)(1,1,-1,1),(0,c.fA)(-1,1,-1,1),(0,c.fA)(-1,-1,1,1),(0,c.fA)(1,-1,1,1),(0,c.fA)(1,1,1,1),(0,c.fA)(-1,1,1,1)],E=new i.I(d),A=p()},87170:(e,t,r)=>{r.d(t,{V:()=>M});var i=r(24326),n=r(9093),o=r(38954),a=r(97146),s=r(57917),c=r(29920),l=r(51850),d=r(4341),u=r(11964);function h(e,t,r){return(0,o.d)(m,t,e),(0,o.d)(p,r,e),.5*(0,o.l)((0,o.h)(m,m,p))}r(32114),new d.I(u.vt),new d.I(()=>function(e){return e?{p0:(0,l.o8)(e.p0),p1:(0,l.o8)(e.p1),p2:(0,l.o8)(e.p2)}:{p0:(0,l.vt)(),p1:(0,l.vt)(),p2:(0,l.vt)()}}());const m=(0,l.vt)(),p=(0,l.vt)(),f=(0,l.vt)(),v=(0,l.vt)(),g=(0,l.vt)(),_=(0,l.vt)();class x{constructor(){this.uid=(0,i.c)()}}class b extends x{constructor(e){super(),this.highlightName=e,this.channel=0}}var w=r(620),y=r(94656);class M{constructor(e,t,r=null,n=0,o=null,s=-1){this.material=e,this.mapPositions=r,this.type=n,this.objectAndLayerIdColor=o,this.edgeIndicesLength=s,this._highlights=null,this._highlightOptionsCounts=null,this.id=(0,i.c)(),this.visible=!0,this._attributes=new Map,this._boundingInfo=null;for(const[e,r]of t)this._attributes.set(e,{...r,indices:(0,a.Dg)(r.indices)}),"position"===e&&(this.edgeIndicesLength=this.edgeIndicesLength<0?this._attributes.get(e).indices.length:this.edgeIndicesLength)}instantiate(e={}){const t=new M(e.material||this.material,[],this.mapPositions,this.type,this.objectAndLayerIdColor,this.edgeIndicesLength);return this._attributes.forEach((e,r)=>{e.exclusive=!1,t._attributes.set(r,e)}),t._boundingInfo=this._boundingInfo,t.transformation=e.transformation||this.transformation,t}get attributes(){return this._attributes}getMutableAttribute(e){let t=this._attributes.get(e);return t&&!t.exclusive&&(t={...t,exclusive:!0,data:(0,s.S)(t.data)},this._attributes.set(e,t)),t}setAttributeData(e,t){const r=this._attributes.get(e);r?this._attributes.set(e,{...r,exclusive:!0,data:t}):(0,y.en)()&&console.warn(`Setting undefined attribute ${e} data`)}get indexCount(){const e=this._attributes.values().next().value?.indices;return e?.length??0}get faceCount(){return this.indexCount/3}get boundingInfo(){return this._boundingInfo??=this._calculateBoundingInfo(),this._boundingInfo}computeAttachmentOrigin(e){return!!(0===this.type?this._computeAttachmentOriginTriangles(e):2===this.type?this._computeAttachmentOriginLines(e):this._computeAttachmentOriginPoints(e))&&(null!=this._transformation&&(0,o.t)(e,e,this._transformation),!0)}_computeAttachmentOriginTriangles(e){return function(e,t){if(!e)return!1;const{size:r,data:i,indices:n}=e;(0,o.i)(t,0,0,0),(0,o.i)(_,0,0,0);let a=0,s=0;for(let e=0;e<n.length-2;e+=3){const c=n[e]*r,l=n[e+1]*r,d=n[e+2]*r;(0,o.i)(f,i[c],i[c+1],i[c+2]),(0,o.i)(v,i[l],i[l+1],i[l+2]),(0,o.i)(g,i[d],i[d+1],i[d+2]);const u=h(f,v,g);u?((0,o.f)(f,f,v),(0,o.f)(f,f,g),(0,o.g)(f,f,1/3*u),(0,o.f)(t,t,f),a+=u):((0,o.f)(_,_,f),(0,o.f)(_,_,v),(0,o.f)(_,_,g),s+=3)}return!(0===s&&0===a||(0!==a?((0,o.g)(t,t,1/a),0):0===s||((0,o.g)(t,_,1/s),0)))}(this.attributes.get("position"),e)}_computeAttachmentOriginLines(e){const t=this.attributes.get("position");return function(e,t,r){if(!e)return!1;(0,o.i)(r,0,0,0),(0,o.i)(_,0,0,0);let i=0,n=0;const{size:a,data:s,indices:c}=e,l=c.length-1,d=l+(t?2:0);for(let e=0;e<d;e+=2){const t=e<l?e+1:0,d=c[e<l?e:l]*a,u=c[t]*a;f[0]=s[d],f[1]=s[d+1],f[2]=s[d+2],v[0]=s[u],v[1]=s[u+1],v[2]=s[u+2],(0,o.g)(f,(0,o.f)(f,f,v),.5);const h=(0,o.F)(f,v);h>0?((0,o.f)(r,r,(0,o.g)(f,f,h)),i+=h):0===i&&((0,o.f)(_,_,f),n++)}return 0!==i?((0,o.g)(r,r,1/i),!0):0!==n&&((0,o.g)(r,_,1/n),!0)}(t,function(e,t){return!(!("isClosed"in e)||!e.isClosed)&&t.indices.length>2}(this.material.parameters,t),e)}_computeAttachmentOriginPoints(e){return function(e,t){if(!e)return!1;const{size:r,data:i,indices:n}=e;(0,o.i)(t,0,0,0);let a=-1,s=0;for(let e=0;e<n.length;e++){const o=n[e]*r;a!==o&&(t[0]+=i[o],t[1]+=i[o+1],t[2]+=i[o+2],s++),a=o}return s>1&&(0,o.g)(t,t,1/s),s>0}(this.attributes.get("position"),e)}invalidateBoundingInfo(){this._boundingInfo=null}_calculateBoundingInfo(){const e=this.attributes.get("position");if(!e||0===e.indices.length)return null;const t=0===this.type?3:1;(0,w.vA)(e.indices.length%t===0,"Indexing error: "+e.indices.length+" not divisible by "+t);const r=(0,a.tM)(e.indices.length/t);return new c.j(r,t,e)}get transformation(){return this._transformation??n.zK}set transformation(e){this._transformation=e&&e!==n.zK?(0,n.o8)(e):null}get highlights(){return this._highlights||T}get hasHighlights(){return(this._highlightOptionsCounts?.size??0)>0}foreachHighlightOptions(e){this._highlightOptionsCounts?.forEach((t,r)=>e(r))}allocateIdAndHighlight(e){const t=new b(e);return this.addHighlight(t)}addHighlight(e){this._ensureHighlights().add(e);const{highlightName:t}=e,r=(this._highlightOptionsCounts?.get(t)??0)+1;return this._ensureHighlightOptionsCounts().set(t,r),e}_ensureHighlights(){let e=this._highlights;return e||(e=new Set,this._highlights=e),e}_ensureHighlightOptionsCounts(){let e=this._highlightOptionsCounts;return e||(e=new Map,this._highlightOptionsCounts=e),e}removeHighlight(e){if(this._highlights?.delete(e)){const{highlightName:t}=e,r=this._highlightOptionsCounts?.get(t)??0;r<=1?this._highlightOptionsCounts?.delete(t):this._ensureHighlightOptionsCounts().set(t,r-1)}}}const T=new Set},88076:(e,t,r)=>{r.d(t,{$U:()=>ie,fs:()=>oe,ty:()=>ae});var i=r(38954),n=r(51850),o=r(1843),a=r(49255),s=r(16943),c=r(25634),l=r(11725),d=r(33524),u=r(70328),h=r(620);class m{constructor(e=!1,t=!0){this.isVerticalRay=e,this.normalRequired=t}}const p=(0,u.vt)();function f(e,t,r,n,o,a){if(!e.visible)return;const s=(0,i.a)(A,n,r),c=(e,t,r)=>{a(e,r,t)},l=new m(!1,t.options.normalRequired);if(e.boundingInfo){(0,h.vA)(0===e.type);const i=t.tolerance;g(e.boundingInfo,r,s,i,o,l,c)}else{const t=e.attributes.get("position"),n=t.indices;!function(e,t,r,n,o,a,s,c,l,d){const u=t,h=R,m=Math.abs(u[0]),p=Math.abs(u[1]),f=Math.abs(u[2]),v=m>=p?m>=f?0:2:p>=f?1:2,g=v,_=u[g]<0?2:1,y=(v+_)%3,T=(v+(3-_))%3,C=u[y]/u[g],S=u[T]/u[g],E=1/u[g],A=x,I=b,P=w,{normalRequired:F}=l;for(let t=r;t<n;++t){const r=3*t,n=s*o[r];(0,i.i)(h[0],a[n+0],a[n+1],a[n+2]);const l=s*o[r+1];(0,i.i)(h[1],a[l+0],a[l+1],a[l+2]);const u=s*o[r+2];(0,i.i)(h[2],a[u+0],a[u+1],a[u+2]),c&&((0,i.c)(h[0],c.applyToVertex(h[0][0],h[0][1],h[0][2],t)),(0,i.c)(h[1],c.applyToVertex(h[1][0],h[1][1],h[1][2],t)),(0,i.c)(h[2],c.applyToVertex(h[2][0],h[2][1],h[2][2],t))),(0,i.a)(A,h[0],e),(0,i.a)(I,h[1],e),(0,i.a)(P,h[2],e);const m=A[y]-C*A[g],p=A[T]-S*A[g],f=I[y]-C*I[g],v=I[T]-S*I[g],_=P[y]-C*P[g],x=P[T]-S*P[g],b=_*v-x*f,w=m*x-p*_,R=f*p-v*m;if((b<0||w<0||R<0)&&(b>0||w>0||R>0))continue;const O=b+w+R;if(0===O)continue;const D=b*(E*A[g])+w*(E*I[g])+R*(E*P[g]);if(D*Math.sign(O)<0)continue;const H=D/O;H>=0&&d(H,t,F?M(h):null)}}(r,s,0,n.length/3,n,t.data,t.stride,o,l,c)}}const v=(0,n.vt)();function g(e,t,r,n,o,a,s){if(null==e)return;const c=function(e,t){return(0,i.i)(t,1/e[0],1/e[1],1/e[2])}(r,v);if((0,u.Ne)(p,e.bbMin),(0,u.vI)(p,e.bbMax),null!=o&&o.applyToAabb(p),function(e,t,r,i){return function(e,t,r,i){const n=(e[0]-i-t[0])*r[0],o=(e[3]+i-t[0])*r[0];let a=Math.min(n,o),s=Math.max(n,o);const c=(e[1]-i-t[1])*r[1],l=(e[4]+i-t[1])*r[1];if(s=Math.min(s,Math.max(c,l)),s<0)return!1;if(a=Math.max(a,Math.min(c,l)),a>s)return!1;const d=(e[2]-i-t[2])*r[2],u=(e[5]+i-t[2])*r[2];return s=Math.min(s,Math.max(d,u)),!(s<0)&&(a=Math.max(a,Math.min(d,u)),!(a>s)&&a<1/0)}(e,t,r,i)}(p,t,c,n)){const{primitiveIndices:i,position:c}=e,l=i?i.length:c.indices.length/3;if(l>S){const i=e.getChildren();if(void 0!==i){for(const e of i)g(e,t,r,n,o,a,s);return}}!function(e,t,r,i,n,o,a,s,c,l,d){const u=e[0],h=e[1],m=e[2],p=t[0],f=t[1],v=t[2],{normalRequired:g}=l;for(let e=0;e<i;++e){const t=s[e],r=3*t,i=a*n[r];let l=o[i],x=o[i+1],b=o[i+2];const w=a*n[r+1];let M=o[w],T=o[w+1],C=o[w+2];const S=a*n[r+2];let A=o[S],R=o[S+1],I=o[S+2];null!=c&&([l,x,b]=c.applyToVertex(l,x,b,e),[M,T,C]=c.applyToVertex(M,T,C,e),[A,R,I]=c.applyToVertex(A,R,I,e));const P=M-l,F=T-x,O=C-b,D=A-l,H=R-x,N=I-b,L=f*N-H*v,B=v*D-N*p,G=p*H-D*f,z=P*L+F*B+O*G;if(Math.abs(z)<=E)continue;const U=u-l,V=h-x,j=m-b,W=U*L+V*B+j*G;if(z>0){if(W<0||W>z)continue}else if(W>0||W<z)continue;const k=V*O-F*j,$=j*P-O*U,q=U*F-P*V,Z=p*k+f*$+v*q;if(z>0){if(Z<0||W+Z>z)continue}else if(Z>0||W+Z<z)continue;const Y=(D*k+H*$+N*q)/z;Y>=0&&d(Y,t,g?y(P,F,O,D,H,N,_):null)}}(t,r,0,l,c.indices,c.data,c.stride,i,o,a,s)}}const _=(0,n.vt)();const x=(0,n.vt)(),b=(0,n.vt)(),w=(0,n.vt)();function y(e,t,r,n,o,a,s){return(0,i.i)(T,e,t,r),(0,i.i)(C,n,o,a),(0,i.h)(s,T,C),(0,i.n)(s,s),s}function M(e){return(0,i.a)(T,e[1],e[0]),(0,i.a)(C,e[2],e[0]),(0,i.h)(_,T,C),(0,i.n)(_,_),_}const T=(0,n.vt)(),C=(0,n.vt)(),S=1e3,E=1e-7,A=(0,n.vt)(),R=[(0,n.vt)(),(0,n.vt)(),(0,n.vt)()];var I=r(16396),P=r(13030),F=r(59907);class O{constructor(e){this.vertexBufferLayout=e}elementCount(e){return e.get("position").indices.length}write(e,t,r,i,n,o){return(0,F.SA)(r,i,this.vertexBufferLayout,e,t,n,o)}intersect(e,t,r,n,o,a,s){const c=this.vertexBufferLayout.createView(e).getField("position",P.xs);if(null==c)return;const l=(0,i.a)(D,a,o),d=c.count/3,u=n.options.normalRequired;!function(e,t,r,i,n,o,a,s){const c=e[0],l=e[1],d=e[2],u=t[0],h=t[1],m=t[2];for(let e=0;e<i;++e){const t=3*e,r=t+1,i=t+2,p=o*t,f=n[p],v=n[p+1],g=n[p+2],x=o*r,b=o*i,w=n[x]-f,M=n[x+1]-v,T=n[x+2]-g,C=n[b]-f,S=n[b+1]-v,A=n[b+2]-g,R=h*A-S*m,I=m*C-A*u,P=u*S-C*h,F=w*R+M*I+T*P;if(Math.abs(F)<=E)continue;const O=c-f,D=l-v,H=d-g,N=O*R+D*I+H*P;if(F>0){if(N<0||N>F)continue}else if(N>0||N<F)continue;const L=D*T-M*H,B=H*w-T*O,G=O*M-w*D,z=u*L+h*B+m*G;if(F>0){if(z<0||N+z>F)continue}else if(z>0||N+z<F)continue;const U=(C*L+S*B+A*G)/F;U>=0&&s(U,e,a?y(w,M,T,C,S,A,_):null)}}(o,l,0,d,c.typedBuffer,c.typedBufferStride,u,(e,t,r)=>{s(e,r,t)})}}const D=(0,n.vt)();var H=r(43616),N=r(91829),L=r(72824),B=r(97220),G=r(98958);const z={mask:255},U={function:{func:519,ref:2,mask:2},operation:{fail:7680,zFail:7680,zPass:0}},V={function:{func:519,ref:2,mask:2},operation:{fail:7680,zFail:7680,zPass:7681}};var j=r(74810),W=r(28491),k=r(90644),$=r(49788);class q extends L.Zo{constructor(){super(...arguments),this.isSchematic=!1,this.usePBR=!1,this.mrrFactors=j.mb,this.hasVertexColors=!1,this.hasSymbolColors=!1,this.doubleSided=!1,this.doubleSidedType="normal",this.cullFace=2,this.isInstanced=!1,this.hasInstancedColor=!1,this.instanceColorEncodesAlphaIgnore=!1,this.emissiveStrength=0,this.emissiveSource=1,this.emissiveBaseColor=n.uY,this.instancedDoublePrecision=!1,this.normalType=0,this.receiveShadows=!0,this.receiveAmbientOcclusion=!0,this.castShadows=!0,this.ambient=(0,n.CN)(.2,.2,.2),this.diffuse=(0,n.CN)(.8,.8,.8),this.externalColor=(0,N.fA)(1,1,1,1),this.colorMixMode="multiply",this.opacity=1,this.layerOpacity=1,this.origin=(0,n.vt)(),this.hasSlicePlane=!1,this.offsetTransparentBackfaces=!1,this.vvSize=null,this.vvColor=null,this.vvOpacity=null,this.vvSymbolAnchor=null,this.vvSymbolRotationMatrix=null,this.modelTransformation=null,this.drivenOpacity=!1,this.writeDepth=!0,this.customDepthTest=0,this.textureAlphaMode=0,this.textureAlphaCutoff=$.Q,this.textureAlphaPremultiplied=!1,this.renderOccluded=1,this.isDecoration=!1}}L.gy;class Z extends G.w{constructor(e,t,i=new B.$(W.D,()=>r.e(5141).then(r.bind(r,5141)))){super(e,t,i),this.type="DefaultMaterialTechnique"}_makePipeline(e,t){const{oitPass:r,output:i,transparent:n,cullFace:o,customDepthTest:s,hasOccludees:c}=e;return(0,k.Ey)({blending:(0,a.RN)(i)&&n?(0,d.Yf)(r):null,culling:X(e)?(0,k.Xt)(o):null,depthTest:{func:(0,d.K_)(r,Y(s))},depthWrite:(0,d.z5)(e),drawBuffers:(0,G.L)(i,(0,d.m6)(r,i)),colorWrite:k.kn,stencilWrite:c?z:null,stencilTest:c?t?V:U:null,polygonOffset:(0,d.mE)(e)})}initializePipeline(e){return this._occludeePipelineState=this._makePipeline(e,!0),this._makePipeline(e,!1)}getPipeline(e){return e?this._occludeePipelineState:super.getPipeline()}}function Y(e){return 1===e?515:513}function X(e){return 0!==e.cullFace||!e.hasSlicePlane&&!e.transparent&&!e.doubleSidedMode}var J=r(31635),K=r(51976),Q=r(35256);class ee extends Q.E{constructor(e){super(),this.spherical=e,this.alphaDiscardMode=1,this.doubleSidedMode=0,this.pbrMode=0,this.cullFace=0,this.normalType=0,this.customDepthTest=0,this.emissionSource=0,this.hasVertexColors=!1,this.hasSymbolColors=!1,this.hasVerticalOffset=!1,this.hasColorTexture=!1,this.hasMetallicRoughnessTexture=!1,this.hasOcclusionTexture=!1,this.hasNormalTexture=!1,this.hasScreenSizePerspective=!1,this.hasVertexTangents=!1,this.hasOccludees=!1,this.instancedDoublePrecision=!1,this.hasModelTransformation=!1,this.offsetBackfaces=!1,this.vvSize=!1,this.vvColor=!1,this.receiveShadows=!1,this.receiveAmbientOcclusion=!1,this.textureAlphaPremultiplied=!1,this.instanced=!1,this.instancedColor=!1,this.writeDepth=!0,this.transparent=!1,this.enableOffset=!0,this.terrainDepthTest=!1,this.cullAboveTerrain=!1,this.snowCover=!1,this.hasBloom=!1,this.hasColorTextureTransform=!1,this.hasEmissionTextureTransform=!1,this.hasNormalTextureTransform=!1,this.hasOcclusionTextureTransform=!1,this.hasMetallicRoughnessTextureTransform=!1,this.occlusionPass=!1,this.hasVvInstancing=!0,this.useCustomDTRExponentForWater=!1,this.useFillLights=!0,this.draped=!1}get textureCoordinateType(){return this.hasColorTexture||this.hasMetallicRoughnessTexture||3===this.emissionSource||this.hasOcclusionTexture||this.hasNormalTexture?1:0}get objectAndLayerIdColorInstanced(){return this.instanced}get discardInvisibleFragments(){return this.transparent}}(0,J.Cg)([(0,K.W)({count:4})],ee.prototype,"alphaDiscardMode",void 0),(0,J.Cg)([(0,K.W)({count:3})],ee.prototype,"doubleSidedMode",void 0),(0,J.Cg)([(0,K.W)({count:7})],ee.prototype,"pbrMode",void 0),(0,J.Cg)([(0,K.W)({count:3})],ee.prototype,"cullFace",void 0),(0,J.Cg)([(0,K.W)({count:3})],ee.prototype,"normalType",void 0),(0,J.Cg)([(0,K.W)({count:2})],ee.prototype,"customDepthTest",void 0),(0,J.Cg)([(0,K.W)({count:4})],ee.prototype,"emissionSource",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasVertexColors",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasSymbolColors",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasVerticalOffset",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasColorTexture",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasMetallicRoughnessTexture",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasOcclusionTexture",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasNormalTexture",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasScreenSizePerspective",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasVertexTangents",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasOccludees",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"instancedDoublePrecision",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasModelTransformation",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"offsetBackfaces",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"vvSize",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"vvColor",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"receiveShadows",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"receiveAmbientOcclusion",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"textureAlphaPremultiplied",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"instanced",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"instancedColor",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"writeDepth",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"transparent",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"enableOffset",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"terrainDepthTest",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"cullAboveTerrain",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"snowCover",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasBloom",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasColorTextureTransform",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasEmissionTextureTransform",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasNormalTextureTransform",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasOcclusionTextureTransform",void 0),(0,J.Cg)([(0,K.W)()],ee.prototype,"hasMetallicRoughnessTextureTransform",void 0);var te=r(57323);class re extends Z{constructor(e,t){super(e,t,new B.$(te.R,()=>r.e(9933).then(r.bind(r,39933)))),this.type="RealisticTreeTechnique"}}class ie extends l.i{constructor(e,t){super(e,oe),this.materialType="default",this.supportsEdges=!0,this.intersectDraped=void 0,this.produces=new Map([[2,e=>((0,a.iq)(e)||(0,a.PJ)(e))&&!this.transparent],[4,e=>((0,a.iq)(e)||(0,a.PJ)(e))&&this.transparent&&this.parameters.writeDepth],[7,e=>((0,a.XY)(e)||(0,a.PJ)(e))&&this.transparent&&!this.parameters.writeDepth]]),this._vertexBufferLayout=function(e){const t=(0,o.BP)().vec3f("position");return 1===e.normalType?t.vec2i16("normalCompressed",{glNormalized:!0}):t.vec3f("normal"),e.hasVertexTangents&&t.vec4f("tangent"),(e.textureId||e.normalTextureId||e.metallicRoughnessTextureId||e.emissiveTextureId||e.occlusionTextureId)&&t.vec2f16("uv0"),e.hasVertexColors&&t.vec4u8("color"),e.hasSymbolColors&&t.vec4u8("symbolColor"),(0,s.E)()&&t.vec4u8("objectAndLayerIdColor"),t}(this.parameters),this._configuration=new ee(t.spherical)}isVisibleForOutput(e){return 4!==e&&6!==e&&5!==e||this.parameters.castShadows}get visible(){const{layerOpacity:e,colorMixMode:t,opacity:r,externalColor:i}=this.parameters;return e*("replace"===t?1:r)*("ignore"===t||isNaN(i[3])?1:i[3])>=$.Q}get _hasEmissiveBase(){return!!this.parameters.emissiveTextureId||!(0,i.q)(this.parameters.emissiveBaseColor,n.uY)}get hasEmissions(){return this.parameters.emissiveStrength>0&&(0===this.parameters.emissiveSource&&this._hasEmissiveBase||1===this.parameters.emissiveSource)}getConfiguration(e,t){const{parameters:r,_configuration:i}=this,{treeRendering:n,doubleSided:o,doubleSidedType:s}=r;return super.getConfiguration(e,t,this._configuration),i.hasNormalTexture=!n&&!!r.normalTextureId,i.hasColorTexture=!!r.textureId,i.hasVertexTangents=!n&&r.hasVertexTangents,i.instanced=r.isInstanced,i.instancedDoublePrecision=r.instancedDoublePrecision,i.vvSize=!!r.vvSize,i.hasVerticalOffset=null!=r.verticalOffset,i.hasScreenSizePerspective=null!=r.screenSizePerspective,i.hasSlicePlane=r.hasSlicePlane,i.alphaDiscardMode=r.textureAlphaMode,i.normalType=n?0:r.normalType,i.transparent=this.transparent,i.writeDepth=r.writeDepth,i.customDepthTest=r.customDepthTest??0,i.hasOccludees=t.hasOccludees,i.cullFace=r.hasSlicePlane?0:r.cullFace,i.cullAboveTerrain=t.cullAboveTerrain,i.hasModelTransformation=!n&&null!=r.modelTransformation,i.hasVertexColors=r.hasVertexColors,i.hasSymbolColors=r.hasSymbolColors,i.doubleSidedMode=n?2:o&&"normal"===s?1:o&&"winding-order"===s?2:0,i.instancedColor=r.hasInstancedColor,(0,a.RN)(e)?(i.terrainDepthTest=t.terrainDepthTest,i.receiveShadows=r.receiveShadows,i.receiveAmbientOcclusion=r.receiveAmbientOcclusion&&null!=t.ssao):(i.terrainDepthTest=!1,i.receiveShadows=i.receiveAmbientOcclusion=!1),i.vvColor=!!r.vvColor,i.textureAlphaPremultiplied=!!r.textureAlphaPremultiplied,i.pbrMode=r.usePBR?r.isSchematic?2:1:0,i.hasMetallicRoughnessTexture=!n&&!!r.metallicRoughnessTextureId,i.emissionSource=n?0:null!=r.emissiveTextureId&&0===r.emissiveSource?3:r.usePBR?0===r.emissiveSource?2:1:0,i.hasOcclusionTexture=!n&&!!r.occlusionTextureId,i.offsetBackfaces=!(!this.transparent||!r.offsetTransparentBackfaces),i.oitPass=t.oitPass,i.enableOffset=t.camera.relativeElevation<d.xt,i.snowCover=t.snowCover,i.hasBloom=(0,a.LG)(e),i.hasColorTextureTransform=!!r.colorTextureTransformMatrix,i.hasNormalTextureTransform=!!r.normalTextureTransformMatrix,i.hasEmissionTextureTransform=!!r.emissiveTextureTransformMatrix,i.hasOcclusionTextureTransform=!!r.occlusionTextureTransformMatrix,i.hasMetallicRoughnessTextureTransform=!!r.metallicRoughnessTextureTransformMatrix,i}intersect(e,t,r,n,o,a){if(null!=this.parameters.verticalOffset){const e=r.camera;(0,i.i)(he,t[12],t[13],t[14]);let a=null;switch(r.viewingMode){case 1:a=(0,i.n)(de,he);break;case 2:a=(0,i.c)(de,le)}let s=0;const c=(0,i.d)(me,he,e.eye),l=(0,i.l)(c),d=(0,i.g)(c,c,1/l);let u=null;this.parameters.screenSizePerspective&&(u=(0,i.e)(a,d)),s+=(0,H.kE)(e,l,this.parameters.verticalOffset,u??0,this.parameters.screenSizePerspective),(0,i.g)(a,a,s),(0,i.o)(ue,a,r.transform.inverseRotation),n=(0,i.d)(se,n,ue),o=(0,i.d)(ce,o,ue)}f(e,r,n,o,(0,I.ou)(r.verticalOffset),a)}createGLMaterial(e){return new ne(e)}createBufferWriter(){return new O(this._vertexBufferLayout)}get transparent(){return ae(this.parameters)}}class ne extends c.m8{constructor(e){super({...e,...e.material.parameters})}beginSlot(e){this._material.setParameters({receiveShadows:e.shadowMap.enabled});const t=this._material.parameters;this.updateTexture(t.textureId);const r=e.camera.viewInverseTransposeMatrix;return(0,i.i)(t.origin,r[3],r[7],r[11]),this._material.setParameters(this.textureBindParameters),this.getTechnique(t.treeRendering?re:Z,e)}}class oe extends q{constructor(){super(...arguments),this.treeRendering=!1,this.hasVertexTangents=!1}}function ae(e){const{drivenOpacity:t,opacity:r,externalColor:i,layerOpacity:n,texture:o,textureId:a,textureAlphaMode:s,colorMixMode:c}=e,l=i[3];return t||r<1&&"replace"!==c||l<1&&"ignore"!==c||n<1||(null!=o||null!=a)&&1!==s&&2!==s&&"replace"!==c}const se=(0,n.vt)(),ce=(0,n.vt)(),le=(0,n.fA)(0,0,1),de=(0,n.vt)(),ue=(0,n.vt)(),he=(0,n.vt)(),me=(0,n.vt)()},89390:(e,t,r)=>{r.d(t,{kA:()=>C,a8:()=>M,eU:()=>T});var i=r(40876),n=(r(44208),r(38954)),o=r(51850),a=r(87317),s=r(91829),c=r(23205),l=r(14314),d=r(31821);function u(e,t){const r=e.fragment,i=void 0!==t.lightingSphericalHarmonicsOrder?t.lightingSphericalHarmonicsOrder:2;0===i?(r.uniforms.add(new c.d("lightingAmbientSH0",({lighting:e})=>(0,n.i)(h,e.sh.r[0],e.sh.g[0],e.sh.b[0]))),r.code.add(d.H`vec3 calculateAmbientIrradiance(vec3 normal, float ambientOcclusion) {
812
812
  vec3 ambientLight = 0.282095 * lightingAmbientSH0;
813
813
  return ambientLight * (1.0 - ambientOcclusion);
814
814
  }`)):1===i?(r.uniforms.add(new l.I("lightingAmbientSH_R",({lighting:e})=>(0,a.s)(m,e.sh.r[0],e.sh.r[1],e.sh.r[2],e.sh.r[3])),new l.I("lightingAmbientSH_G",({lighting:e})=>(0,a.s)(m,e.sh.g[0],e.sh.g[1],e.sh.g[2],e.sh.g[3])),new l.I("lightingAmbientSH_B",({lighting:e})=>(0,a.s)(m,e.sh.b[0],e.sh.b[1],e.sh.b[2],e.sh.b[3]))),r.code.add(d.H`vec3 calculateAmbientIrradiance(vec3 normal, float ambientOcclusion) {
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2083],{6455:(e,t,n)=>{n.d(t,{FJ:()=>b,Dp:()=>w,KV:()=>T});var i=n(31635),r=n(93637),o=n(10107),s=(n(44208),n(53966),n(87811),n(40608)),a=n(89317),l=n(69540),u=n(7762),d=n(25482),p=n(43937),c=n(83960),h=n(13069);const y={write:{overridePolicy:(e,t,n)=>({enabled:!n||"scale"===n.filterMode})}};let m=class extends(l.A.ClonableMixin(d.A)){constructor(e){super(e),this.id=(0,h.lk)(),this.maxScale=0,this.minScale=0,this.title="",this.where=null}};(0,i.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],m.prototype,"id",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:y})],m.prototype,"maxScale",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:y})],m.prototype,"minScale",void 0),(0,i.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],m.prototype,"title",void 0),(0,i.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],m.prototype,"where",void 0),m=(0,i.Cg)([(0,s.$)("esri.layers.support.DisplayFilter")],m);var f=n(41560);let g=class extends(l.A.ClonableMixin(d.A)){constructor(e){super(e),this.activeFilterId=null,this.filters=new(u.A.ofType(m)),this.mode="manual"}writeFilters(e,t,n,i){const r=e.toArray();"scale"===this.mode&&r.sort((e,t)=>{const n=(0,c.oW)(t.minScale,e.minScale),i=e.maxScale-t.maxScale;return 0===n?i:n}),t[n]=r.map(e=>e.toJSON(i))}write(e,t){return super.write(e,(0,f.mW)(this,t))}};(0,i.Cg)([(0,o.MZ)({type:String,json:{write:{overridePolicy:(e,t,n)=>({enabled:"manual"===n.filterMode,isRequired:!0})}}})],g.prototype,"activeFilterId",void 0),(0,i.Cg)([(0,o.MZ)({type:u.A.ofType(m),nonNullable:!0,json:{write:!0}})],g.prototype,"filters",void 0),(0,i.Cg)([(0,p.K)("filters")],g.prototype,"writeFilters",null),(0,i.Cg)([(0,o.MZ)({type:["manual","scale"],nonNullable:!0,json:{name:"filterMode",write:!0}})],g.prototype,"mode",void 0),g=(0,i.Cg)([(0,s.$)("esri.layers.support.DisplayFilterInfo")],g);const b=e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.displayFilterEnabled=!0,this.displayFilterInfo=null}};return(0,i.Cg)([(0,o.MZ)(w)],n.prototype,"displayFilterEnabled",void 0),(0,i.Cg)([(0,o.MZ)(T)],n.prototype,"displayFilterInfo",void 0),n=(0,i.Cg)([(0,s.$)("esri.layers.mixins.DisplayFilteredLayer")],n),n},w={type:Boolean,json:{name:"layerDefinition.disableDisplayFilter",read:{reader:e=>!e},write:{layerContainerTypes:a.K,writer(e,t,n){(0,r.sM)(n,!e,t)}},origins:{"web-scene":{write:!1,read:!1}}}},T={type:g,json:{name:"layerDefinition.displayFilterInfo",write:{enabled:!0,allowNull:!0,layerContainerTypes:a.K},origins:{"web-scene":{write:!1,read:!1}}}}},6518:(e,t,n)=>{n.d(t,{F:()=>a});var i=n(44208),r=n(75503),o=n(19419);const s={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 r.wq(9,(0,i.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((n,i)=>{e[t++]=i}),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,o.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,n){(function(e){s.minX=e[0],s.minY=e[1],s.maxX=e[2],s.maxY=e[3]})(t),e.search(s,n)}(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()))}}},8460:(e,t,n)=>{n.d(t,{$C:()=>m,Hh:()=>s,Tu:()=>h,Wg:()=>y,Xq:()=>g,i6:()=>b,pM:()=>c,vJ:()=>f});var i=n(2741);let r,o=null;function s(){return r||(r=n.e(3666).then(n.bind(n,3666)).then(e=>e.l).then(({default:e})=>e({locateFile:e=>(0,i.s)(`esri/libs/linkchartlayout/${e}`)})).then(e=>{!function(e){o=e}(e)}),r)}var a,l;(l=a||(a={}))[l.right=0]="right",l[l.left=1]="left",l[l.top=2]="top",l[l.bottom=3]="bottom";const u={none:0,"start-only":1,"start-and-end":2};function d(e){const t={timeDirection:"right",timeBannerUTCOffsetInMinutes:0,eventsTicksVisualization:"start-and-end",showDurationLineForNonZeroDurationEntityEvents:!0,durationLineWidth:5,entityPositionAtDurationRatio:1,showNonZeroDurationIntervalBounds:!1,separateTimeOverlaps:!0,separateTimelineOverlaps:!0,moveFirstBends:!0,secondBendRatio:.3,lineSeparationMultiplier:1,spaceSeparatedLinesEvenly:!1,useBezierCurves:!1,separatedLineShapeRatio:0,...e?.toJSON()??{},eventsTicksVisualization:e?.eventsTicksVisualization??"start-and-end"};return{...t,timeDirection:{value:a[t.timeDirection]??a.right},eventsTicksVisualization:{value:u[t.eventsTicksVisualization]??u["start-and-end"]}}}function p(e,t,n,i,r,s){const a=n.length,l=r.length,u=Float64Array.BYTES_PER_ELEMENT,d=Uint32Array.BYTES_PER_ELEMENT,p=Uint8Array.BYTES_PER_ELEMENT,c=16+a*(p+2*u)+l*(2*d),h=o._malloc(c);try{const p=h+16-h%16,c=p+a*u,y=c+a*u,m=y+l*d,f=m+l*d,g=()=>[o.HEAPF64.subarray(p>>3,(p>>3)+a),o.HEAPF64.subarray(c>>3,(c>>3)+a),o.HEAPU32.subarray(y>>2,(y>>2)+l),o.HEAPU32.subarray(m>>2,(m>>2)+l),o.HEAPU8.subarray(f,f+a)],[b,w,T,I,M]=g();b.set(n),w.set(i),T.set(r),I.set(s),M.set(t);const _=e(a,f,p,c,l,y,m);let C=null,v=null;if(0===_.value){const e=o.getLayoutLinksTypes(),t=o.getLayoutLinksVerticesEndIndices(),n=o.getLayoutLinksVertices(),i=o.countLayoutLinksVertices();!l||e&&t?i&&!n?_.value=1:(C={types:new Uint8Array(o.HEAPU8.subarray(e,e+l)),vertexEndIndex:new Uint32Array(o.HEAPU32.subarray(t>>2,(t>>2)+l)),vertices:new Float64Array(o.HEAPF64.subarray(n>>3,(n>>3)+2*i))},v=o.getAuxiliaryGraphicElements()):_.value=1}const[x,E,A,S,N]=g();return n.set(x),i.set(E),r.set(A),s.set(S),t.set(N),{status:_.value,links:C,graphics:v}}finally{o._free(h),o.cleanupLayout()}}var c,h,y,m,f,g,b;!function(e){e.getMinIdealEdgeLength=function(){return o.getMinIdealEdgeLength()},e.apply=function(e,t,n,i,r,s,a=2,l=1,u=-1){return p((t,n,i,r,s,d,p)=>o.applyForceDirectedLayout(e,t,n,i,r,s,d,p,a,l,u),t,n,i,r,s)}}(c||(c={})),function(e){e.apply=function(e,t,n,i,r,s,a=2,l=1,u=-1){return p((t,n,i,r,s,d,p)=>o.applyCommunityLayout(e,t,n,i,r,s,d,p,a,l,u),t,n,i,r,s)}}(h||(h={})),function(e){e.apply=function(e,t,n,i,r,s){return p((t,n,i,r,s,a,l)=>o.applySimpleLayout(e,t,n,i,r,s,a,l),t,n,i,r,s)}}(y||(y={})),function(e){e.apply=function(e,t,n,i,r,s){return p((t,n,i,r,s,a,l)=>o.applyHierarchicalLayout(e,t,n,i,r,s,a,l),t,n,i,r,s)}}(m||(m={})),function(e){e.apply=function(e,t,n,i,r,s){return p((t,n,i,r,s,a,l)=>o.applyRadialTreeLayout(e,t,n,i,r,s,a,l),t,n,i,r,s)}}(f||(f={})),function(e){e.apply=function(e,t,n,i,r,s){return p((t,n,i,r,s,a,l)=>o.applySmartTreeLayout(e,t,n,i,r,s,a,l),t,n,i,r,s)}}(g||(g={})),function(e){e.apply=function(e,t,n,i,r,s,a,l,u,c,h,y){return p((t,n,i,a,l,p,m)=>{if(r.length!==t)return{value:1};if(s.length!==t)return{value:1};if(u.length!==l)return{value:1};if(c.length!==l)return{value:1};const f=Float64Array.BYTES_PER_ELEMENT,g=16,b=o._malloc(g+t*f),w=o._malloc(g+t*f),T=o._malloc(g+l*f),I=o._malloc(g+l*f),M=b+g-b%g,_=w+g-w%g,C=T+g-T%g,v=I+g-I%g;try{return o.HEAPF64.subarray(M>>3,(M>>3)+t).set(r),o.HEAPF64.subarray(_>>3,(_>>3)+t).set(s),o.HEAPF64.subarray(C>>3,(C>>3)+l).set(u),o.HEAPF64.subarray(v>>3,(v>>3)+l).set(c),o.applyChronologicalLayout(e,t,n,i,a,M,_,l,p,m,C,v,h,d(y))}finally{o._free(b),o._free(w),o._free(T),o._free(I)}},t,n,i,a,l)}}(b||(b={}))},15375:(e,t,n)=>{n.d(t,{BL:()=>l,Cz:()=>r,KQ:()=>o,M1:()=>a,T1:()=>s,dr:()=>i});const i="ESRI__ID",r="ESRI__OriginID",o="ESRI__DestID",s="ESRI__LayoutGeometry",a="ESRI__AggregationCount",l="LC.ESRI__IsSpatial"},17036:(e,t,n)=>{n.d(t,{p:()=>l});var i=n(44208),r=n(53966),o=n(20437),s=n(95466),a=n(30524);function l(){return{fields:{type:[o.A],value:null,set:function(e){if(e&&(0,i.A)("big-integer-warning-enabled")){const t=e.filter(e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8);if(t.length){const e=t.map(e=>`'${e.name}'`).join(", ");r.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${Number.MAX_SAFE_INTEGER} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return s.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){const e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(const t of e){const n=this.fieldsIndex?.has(t);n||r.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,a.DB)(this.fieldsIndex,e)}}}}},23150:(e,t,n)=>{n.d(t,{A:()=>l});var i=n(31635),r=n(10107),o=(n(44208),n(53966),n(87811),n(40608)),s=n(82799),a=n(54238);let l=class extends a.A{constructor(e){super(e),this.originId=null,this.destinationId=null,this.layoutGeometry=null}};(0,i.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],l.prototype,"originId",void 0),(0,i.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],l.prototype,"destinationId",void 0),(0,i.Cg)([(0,r.MZ)({type:s.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,i.Cg)([(0,o.$)("esri.rest.knowledgeGraph.Relationship")],l)},25927:(e,t,n)=>{n.d(t,{A:()=>l});var i=n(31635),r=n(10107),o=(n(44208),n(53966),n(87811),n(40608)),s=n(86738),a=n(54238);let l=class extends a.A{constructor(e){super(e),this.layoutGeometry=null}};(0,i.Cg)([(0,r.MZ)({type:s.A,json:{write:!0}})],l.prototype,"layoutGeometry",void 0),l=(0,i.Cg)([(0,o.$)("esri.rest.knowledgeGraph.Entity")],l)},26253:(e,t,n)=>{n.d(t,{T:()=>p});var i=n(31635),r=n(69540),o=n(25482),s=n(88930),a=n(10107),l=(n(44208),n(53966),n(87811),n(93223)),u=n(40608),d=n(73133);let p=class extends(r.A.ClonableMixin(o.A)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,s.t)(this.value,this.unit,"milliseconds")}};(0,i.Cg)([(0,l.e)(d.j,{nonNullable:!0})],p.prototype,"unit",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0},nonNullable:!0})],p.prototype,"value",void 0),p=(0,i.Cg)([(0,u.$)("esri.time.TimeInterval")],p)},30504:(e,t,n)=>{n.d(t,{k5:()=>u,aq:()=>l,Wq:()=>d}),n(52106);var i=n(49186),r=(n(86738),n(39829),n(82799),n(94194),n(69860),n(8460),n(66552));(0,r.O)()({none:"none",startAndEnd:"start-and-end",startOnly:"start-only"}),(0,r.O)()({absoluteValue:"absolute-value",multiplier:"multiplier"});const o=new Map([["basic-grid","basic-grid"],["geographic-organic-standard","geographic-organic-standard"],["hierarchical-bottom-to-top","hierarchical-bottom-to-top"],["hierarchical-top-to-bottom","hierarchical-bottom-to-top"],["organic-community","organic-community"],["organic-fusiform","organic-standard"],["organic-leaf-circle","organic-standard"],["organic-standard","organic-standard"],["radial-node-centric","radial-root-centric"],["radial-root-centric","radial-root-centric"],["tree-bottom-to-top","tree-left-to-right"],["tree-left-to-right","tree-left-to-right"],["tree-right-to-left","tree-left-to-right"],["tree-top-to-bottom","tree-left-to-right"],["chronological-mono-timeline","chronological-mono-timeline"],["chronological-multi-timeline","chronological-multi-timeline"]]);var s=n(62568),a=n(42538);async function l(e,t,n){const i=[],r=function(e,t){const n=new Map;if(t.dataModel?.relationshipTypes)for(const e of t.dataModel.relationshipTypes)e.name&&n.set(e.name,[]);for(const t of e)n.has(t.typeName)&&n.get(t.typeName)?.push(t.id);return n}(e,t),o={},l=[];for(const[e,t]of r){if(t.length<1)continue;const n=`${e}_ids`;o[n]=t,l.push(`MATCH (n)-[r:${e}]->(m) WHERE id(r) in $${n} RETURN id(n), labels(n)[0], id(m), labels(m)[0]`)}if(0===l.length)return[];const u=l.join(" UNION "),d=new a.A({openCypherQuery:u,bindParameters:o}),p=(await(0,s.executeQueryStreaming)(t,d,n?.requestOptions)).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await p.read();if(e)break;for(const e of t)i.push({id:e[0],typeName:e[1]}),i.push({id:e[2],typeName:e[3]})}return i}n(40863),n(94985),n(68249);const u=e=>o.get(e)??"radial-root-centric";function d(e){if(!e.spatialReference.isWGS84)throw new i.A("knowledge-graph:layer-support-utils","The utilsExtentToInBoundsRings 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]])}},37531:(e,t,n)=>{n.d(t,{dt:()=>c,GG:()=>g,UQ:()=>f,Sx:()=>d});var i=n(68197),r=n(60999),o=(n(44208),n(51850)),s=(n(76369),n(62046)),a=(n(2741),n(78888),n(66344));new Map([["dash",[4,3]],["dashdot",[4,3,1,3]],["dot",[1,3]],["longdash",[8,3]],["longdashdot",[8,3,1,3]],["longdashdotdot",[8,3,1,3,1,3]],["shortdash",[4,1]],["shortdashdot",[4,1,1,1]],["shortdashdotdot",[4,1,1,1,1,1]],["shortdot",[1,1]],["solid",[]]]),new a.q(1e3),new i.A([128,128,128]);var l=n(28975),u=n(33910);function d(e,t){if(!e)return null;let n=null;return(0,u.wk)(e)?n=function(e){const t=e.symbolLayers;if(!t)return null;let n=null;return t.forEach(e=>{"object"===e.type&&e.resource?.href||(n="water"===e.type?e.color:e.material?e.material.color:null)}),n?new i.A(n):null}(e):(0,u.$y)(e)&&(n="cim"===e.type?(0,s.Nk)(e):e.color?new i.A(e.color):null),n?p(n,t):null}function p(e,t){if(null==t||null==e)return e;const n=e.toRgba();return n[3]=n[3]*t,new i.A(n)}function c(e,t,n){e&&(t||null!=n)&&(t&&(t=new i.A(t)),(0,u.wk)(e)?function(e,t,n){const r=e.symbolLayers;if(!r)return;const o=(e,r=!1)=>{let o=t??e??null;return null!=n?.override&&(!o&&r&&(o=new i.A([255,255,255])),o&&(o.a=n.override)),p(o,n?.add)};r.forEach(e=>{if("water"===e.type)return void(e.color=p(e.color,n?.add));const t=null!=e.material?e.material.color:null,i=o(t,"icon"===e.type&&null!=e.resource?.href);null==e.material?e.material=new l.N({color:i}):e.material.color=i,"outline"in e&&e.outline?.color&&null!=n?.add&&(e.outline.color=p(e.outline.color,n.add)),"marker"in e&&null!=e.marker&&(e.marker.color=o(e.marker.color))})}(e,t,n):(0,u.$y)(e)&&function(e,t,n){t=t??e.color,null!=n?.override&&t&&(t.a=n.override),t&&(e.color=p(t,n?.add)),"outline"in e&&e.outline?.color&&(e.outline.color=p(e.outline.color,n?.add))}(e,t,n))}function h(e){for(const t of e)if("number"==typeof t)return t;return null}function y(e,t,n){for(let i=0;i<3;i++){const r=e[i];switch(r){case"symbol-value":{const e=n[i];return null!=e?e/t[i]:1}case"proportional":break;default:if(r&&t[i])return r/t[i]}}return null}function m(e,t,n,i){switch(e){case"proportional":return n*i;case"symbol-value":return null!=t?t:n;default:return e}}async function f(e,t){if(e&&t)return(0,u.wk)(e)?async function(e,t){const i=e.symbolLayers;i&&await(0,r.jJ)(i,async e=>async function(e,t){switch(e.type){case"extrude":!function(e,t){const n=t[2];"number"==typeof n&&(e.size=n)}(e,t);break;case"icon":case"line":case"text":!function(e,t){const n=h(t);null!=n&&(e.size=n)}(e,t);break;case"path":!function(e,t){const n=y(t,o.Un,[e.width,void 0,e.height]);null!=n&&(e.width=m(t[0],e.width,1,n),e.height=m(t[2],e.height,1,n))}(e,t);break;case"object":await async function(e,t){const{resourceSize:i,symbolSize:r}=await async function(e){const{computeObjectLayerResourceSize:t}=await n.e(5404).then(n.bind(n,95404)),i=await t(e,10),{width:r,height:o,depth:s}=e,a=[r,s,o];let l=1;for(let e=0;e<3;e++){const t=a[e];if(null!=t){l=t/i[e];break}}for(let e=0;e<3;e++)null==a[e]&&(a[e]=i[e]*l);return{resourceSize:i,symbolSize:a}}(e),o=y(t,i,r);null!=o&&(e.width=m(t[0],r[0],i[0],o),e.depth=m(t[1],r[1],i[1],o),e.height=m(t[2],r[2],i[2],o))}(e,t)}}(e,t))}(e,t):void((0,u.$y)(e)&&function(e,t){const n=h(t);if(null!=n)switch(e.type){case"simple-marker":e.size=n;break;case"picture-marker":{const t=e.width/e.height;t>1?(e.width=n,e.height=n*t):(e.width=n*t,e.height=n);break}case"simple-line":e.width=n;break;case"text":e.font.size=n}}(e,t))}function g(e,t,n){if(e&&null!=t)if((0,u.wk)(e)){const i=e.symbolLayers;i&&i.forEach(e=>{if("object"===e.type)switch(n){case"tilt":e.tilt=(e.tilt??0)+t;break;case"roll":e.roll=(e.roll??0)+t;break;default:e.heading=(e.heading??0)+t}"icon"===e.type&&(e.angle+=t)})}else(0,u.$y)(e)&&("simple-marker"!==e.type&&"picture-marker"!==e.type&&"text"!==e.type||(e.angle+=t))}},37730:(e,t,n)=>{n.d(t,{T:()=>r});var i=n(43334);const r={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new i.Om(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>e.ensureCentroid(t)}},40662:(e,t,n)=>{n.d(t,{A:()=>s});var i=n(31635),r=(n(53966),n(44208),n(87811),n(49186),n(40608)),o=n(77901);let s=class extends o.A{constructor(e){super(e)}};s=(0,i.Cg)([(0,r.$)("esri.rest.knowledgeGraph.ObjectValue")],s)},42095:(e,t,n)=>{n.d(t,{A:()=>l});var i=n(31635),r=n(25482),o=n(10107),s=(n(44208),n(53966),n(87811),n(40608)),a=n(77901);let l=class extends r.A{constructor(e){super(e),this.path=[]}};(0,i.Cg)([(0,o.MZ)({type:[a.A],json:{write:!0}})],l.prototype,"path",void 0),l=(0,i.Cg)([(0,s.$)("esri.rest.knowledgeGraph.Path")],l)},42538:(e,t,n)=>{n.d(t,{A:()=>u});var i=n(31635),r=n(10107),o=(n(44208),n(53966),n(87811),n(40608)),s=n(16930),a=n(69622);let l=class extends a.A{constructor(e){super(e),this.openCypherQuery=""}};(0,i.Cg)([(0,r.MZ)()],l.prototype,"openCypherQuery",void 0),l=(0,i.Cg)([(0,o.$)("esri.rest.knowledgeGraph.GraphQuery")],l);let u=class extends l{constructor(e){super(e),this.bindParameters=null,this.bindGeometryQuantizationParameters=null,this.outputQuantizationParameters=null,this.outputSpatialReference=null,this.provenanceBehavior=null}};(0,i.Cg)([(0,r.MZ)()],u.prototype,"bindParameters",void 0),(0,i.Cg)([(0,r.MZ)()],u.prototype,"bindGeometryQuantizationParameters",void 0),(0,i.Cg)([(0,r.MZ)()],u.prototype,"outputQuantizationParameters",void 0),(0,i.Cg)([(0,r.MZ)({type:s.A})],u.prototype,"outputSpatialReference",void 0),(0,i.Cg)([(0,r.MZ)()],u.prototype,"provenanceBehavior",void 0),u=(0,i.Cg)([(0,o.$)("esri.rest.knowledgeGraph.GraphQueryStreaming")],u)},54238:(e,t,n)=>{n.d(t,{A:()=>a});var i=n(31635),r=n(10107),o=(n(44208),n(53966),n(87811),n(40608)),s=n(77901);let a=class extends s.A{constructor(e){super(e),this.typeName=null,this.id=null}};(0,i.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],a.prototype,"typeName",void 0),(0,i.Cg)([(0,r.MZ)({type:String,json:{write:!0}})],a.prototype,"id",void 0),a=(0,i.Cg)([(0,o.$)("esri.rest.knowledgeGraph.GraphNamedObject")],a)},62046:(e,t,n)=>{n.d(t,{Fe:()=>d,Nk:()=>o});var i=n(68197),r=n(93397);function o(e){const t=[];return s((0,r.lW)(e),t),t.length?new i.A((0,r.e6)(t[0])):null}function s(e,t){if(!e)return;let n;n="CIMTextSymbol"===e.type?e.symbol:e;const i="CIMPolygonSymbol"===e.type;if(n?.symbolLayers)for(const e of n.symbolLayers)if(!(e.colorLocked||i&&((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))))switch(e.type){case"CIMPictureMarker":case"CIMPictureStroke":case"CIMPictureFill":e.tintColor&&a(t,e.tintColor);break;case"CIMVectorMarker":e.markerGraphics?.forEach(e=>{s(e.symbol,t)});break;case"CIMSolidStroke":case"CIMSolidFill":a(t,e.color);break;case"CIMGradientFill":l(t,e);break;case"CIMHatchFill":s(e.lineSymbol,t)}}function a(e,t){for(const n of e)if(n.join(".")===t.join("."))return;e.push(t)}function l(e,t){const n=t.colorRamp?.type;switch(n){case"CIMMultipartColorRamp":t.colorRamp.colorRamps?.forEach(t=>{"CIMLinearContinuousColorRamp"===t.type&&u(e,t)});break;case"CIMLinearContinuousColorRamp":case"CIMPolarContinuousColorRamp":u(e,t.colorRamp)}}function u(e,t){t&&(t.fromColor&&a(e,t.fromColor),t.toColor&&a(e,t.toColor))}function d(e,t,n){t instanceof i.A||(t=new i.A(t));const o=(0,r.lW)(e);o&&p(o,t,n)}function p(e,t,n){if(!e)return;let i;i="CIMTextSymbol"===e.type?e.symbol:e;const o="CIMPolygonSymbol"===i?.type;if(i?.symbolLayers)for(const e of i.symbolLayers){if(e.colorLocked)continue;if(o)if(n){const{layersToColor:t}=n;if(((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))&&"fill"===t||(0,r.jn)(e)&&"outline"===t)continue}else if((0,r.mA)(e)||(0,r.MM)(e)&&e.markerPlacement&&(0,r.zr)(e.markerPlacement))continue;const i=t.toArray();switch(e.type){case"CIMPictureMarker":case"CIMPictureStroke":case"CIMPictureFill":e.tintColor=i;break;case"CIMVectorMarker":e.markerGraphics?.forEach(e=>{p(e.symbol,t,n)});break;case"CIMSolidStroke":case"CIMSolidFill":e.color=i;break;case"CIMGradientFill":c(e,t);break;case"CIMHatchFill":p(e.lineSymbol,t,n)}}}function c(e,t){const n=e.colorRamp?.type;switch(n){case"CIMMultipartColorRamp":e.colorRamp.colorRamps?.forEach(e=>{"CIMLinearContinuousColorRamp"===e.type&&h(e,t)});break;case"CIMLinearContinuousColorRamp":case"CIMPolarContinuousColorRamp":h(e.colorRamp,t)}}function h(e,t){if(e&&(e.fromColor&&(e.fromColor=t.toArray()),e.toColor)){const n=t.clone();n.a=0,e.toColor=n.toArray()}}},64714:(e,t,n)=>{n.d(t,{F0:()=>a,Vx:()=>d,e2:()=>c,f:()=>h});var i=n(44208),r=n(4718),o=n(99352),s=n(93470);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?s.Cb:"esriGeometryPolyline"===e?s.yM:s.WR}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function d(e,t){if((0,i.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let n=`this${p(t)} = null;`;for(const t in e)n+=`this${p(t)} = ${JSON.stringify(e[t])};`;const i=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${n};\n }\n }\n `)();return()=>new i}catch(n){return()=>({[t]:null,...e})}}function p(e){return l.test(e)?`.${e}`:`["${e}"]`}function c(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,r.o8)(e)}}]}function h(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:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:o.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:o.P,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}}}},67996:(e,t,n)=>{n.d(t,{cZ:()=>k,XW:()=>j,fe:()=>L});var i=n(78888),r=n(49186),o=n(91869),s=(n(90708),n(92722)),a=n(16930);class l{constructor(){this.version="",this.queryResult=new u}}class u{constructor(){this.featureResult=new d}}class d{constructor(){this.objectIdFieldName="",this.uniqueIdField=new p,this.globalIdFieldName="",this.geohashFieldName="",this.geometryProperties=new c,this.geometryType=null,this.spatialReference=new a.A,this.exceededTransferLimit=!1,this.hasZ=!1,this.hasM=!1,this.transform=new h,this.fields=[],this.fieldNameToAttributeIndexMap={},this.values=[],this.features=[],this.geometryFields=[]}}class p{constructor(){this.name="",this.isSystemMaintained=!1}}class c{constructor(){this.shapeAreaFieldName="",this.shapeLengthFieldName="",this.units=""}}class h{constructor(){this.quantizeOriginPosition="upperLeft",this.scale=new y,this.translate=new m}}class y{constructor(){this.xScale=0,this.yScale=0,this.mScale=0,this.zScale=0}}class m{constructor(){this.xTranslate=0,this.yTranslate=0,this.mTranslate=0,this.zTranslate=0}}class f{constructor(){this.name="",this.fieldType="esriFieldTypeString",this.alias="",this.sqlType="sqlTypeVarchar",this.domain="",this.defaultValue=""}}class g{constructor(){this.attributes=[],this.compressedGeometry=new b,this.centroid=new b,this.aggregateGeometries=[]}}class b{constructor(){this.geometryType=null,this.lengths=[],this.coords=[]}}const w=["ELEMENTUID","TYPENAME"];var T,I,M;(M=T||(T={}))[M.ELEMENTUID=0]="ELEMENTUID",M[M.TYPENAME=1]="TYPENAME",function(e){e[e.ELEMENTUID=0]="ELEMENTUID",e[e.TYPENAME=1]="TYPENAME",e[e.FROMUID=2]="FROMUID",e[e.TOUID=3]="TOUID"}(I||(I={}));var _,C,v=n(45724),x=n(35448);function E(e){const t=new b;t.geometryType=x.bV[e.geometry_type.value];const n=[],i=[];for(let t=0;t<e.lengths.length;t++)n.push(e.lengths[t]);for(let t=0;t<e.coords.length;t++)i.push(e.coords[t]);return t.lengths=n,t.coords=i,t}function A(e){const t=new f;return t.name=e.name,t.alias=e.alias,t.fieldType=x.r5[e.field_type.value],t.sqlType=C[e.sql_type.value],t.domain=e.domain,t.defaultValue=e.default_value,t}function S(e){const t=A(e);return t.geometryType=x.bV[e.geometry_type.value],t}function N(e){const t=new h;t.quantizeOriginPosition=_[e.quantizeOriginPosition.value];const n=t.scale,i=e.scale;n.xScale=i.xScale,n.yScale=i.yScale,n.mScale=i.mScale,n.zScale=i.zScale;const r=t.translate,o=e.translate;return r.xTranslate=o.xTranslate,r.yTranslate=o.yTranslate,r.mTranslate=o.mTranslate,r.zTranslate=o.zTranslate,t}async function k(e,t){t??=!1;const n={generateAllSublayers:t,namedTypeDefinitions:new Map};return await async function(e){const t=await(0,i.A)(e,{responseType:"array-buffer"}),n=await t.data;return async function(e){const t=new((await(0,v.I)()).MapOfObjectIdentifierSetsDecoder),n=t.decode(new Uint8Array(e)),i=new Map;if(0!==n.error_code)throw new r.A("knowledge-graph:layer-support-utils",n.error_message);const o=t.get_map_of_identifier_sets(),s=o.keys,a=s.size();for(let e=0;e<a;e++){const t=s.get(e),n=o.query_identifier_set(t),a=[];if(1===n.id_array_type.value){const e=n.get_globalid_array(),t=e.count();for(let n=0;n<t;n++)a.push(e.get_globalid_at(n))}else if(3===n.id_array_type.value){const e=n.get_identifier_array(),t=e.count();for(let n=0;n<t;n++)a.push(e.get_identifier_at(n).toString())}else if(2===n.id_array_type.value){const e=n.get_string_array(),t=e.count();for(let n=0;n<t;n++)a.push(e.get_string_at(n))}else{if(0!==n.id_array_type.value)throw new r.A("knowledge-graph:layer-support-utils","Tried to encode an unexpected ID Array type.");{const e=n.get_oid_array(),t=e.count();for(let n=0;n<t;n++)a.push(e.get_objectid_at(n).toString())}}i.set(t,a)}return t.delete(),i}(new Uint8Array(n))}(e).then(e=>{!function(e,t){for(const[n,i]of e){const e=(0,o.tE)(t.namedTypeDefinitions,n,()=>({useAllData:!1,members:new Map}));for(const t of i)e.members.has(t)||e.members.set(t,{id:t})}}(e,n)}),n}async function L(e){const t=await(0,v.I)(),n=new t.MapOfObjectIdentifierSets;!function(e,t,n){for(const[i,r]of n.namedTypeDefinitions){if(!r.members||r.useAllData)continue;const n=r.members.keys();let o=!1,s=!0;const a=new t.ObjectIdArray,l=new t.StringArray,u=new t.GlobalIdArray,d=new t.IdentifierArray,p=new t.ObjectIdentifierSet;for(const e of n)s&&(o=!isNaN(Number(e)),s=!1),o?a.add_objectid(Number(e)):(l.add_string(e),u.add_globalid(e)),d.add_identifier(e);p.set_oid_array(a),p.set_string_array(l),p.set_globalid_array(u),p.set_identifier_array(d),a.delete(),l.delete(),u.delete(),d.delete(),e.put_identifier_set(i,p),p.delete()}}(n,t,e);const i=new t.MapOfObjectIdentifierSetsEncoder;try{i.set_map_of_identifier_sets(n),i.encode();const e=i.get_encoding_result();if(0!==e.error.error_code)throw new r.A("knowledge-graph:layer-support-utils",e.error.error_message);const t=structuredClone(e.get_byte_buffer());return i.delete(),t}finally{n.delete()}}async function F(e){const t=await(0,i.A)(e,{responseType:"array-buffer"});return async function(e){const t=new((await(0,v.I)()).FeatureCollectionDecoder),n=t.decode(new Uint8Array(e));if(0!==n.error_code)throw new r.A("knowledge-graph:layer-support-utils",n.error_message);const i=function(e){const t=new l;t.version=e.version;const n=e.get_query_result();if(0!==n.results_type.value)throw new Error("Got a non-feature collection type");const i=n.get_feature_result(),r=t.queryResult.featureResult;r.objectIdFieldName=i.objectid_field_name,r.exceededTransferLimit=i.exceeded_transfer_limit,r.hasM=i.has_m,r.hasZ=i.has_z,r.geometryType=x.bV[i.geometry_type.value],r.globalIdFieldName=i.globalid_field_name,r.geohashFieldName=i.geohash_field_name;const o=r.uniqueIdField,s=i.unique_id_field;o.name=s.name,o.isSystemMaintained=s.isSystemMaintained;const a=r.geometryProperties,u=i.geometry_properties;a.shapeAreaFieldName=u.shapeAreaFieldName,a.shapeLengthFieldName=u.shapeLengthFieldName,a.units=u.units;const d=r.spatialReference,p=i.spatial_reference;d.wkid=p.wkid,d.latestWkid=p.latestWkid,d.vcsWkid=p.vcsWkid,d.latestVcsWkid=p.latestVcsWkid,d.wkt=p.wkt,r.transform=N(i.transform);const c=r.fields,h=r.fieldNameToAttributeIndexMap,y=i.fields,m=y.size();for(let e=0;e<m;e++){const t=y.get(e),n=A(t);c.push(n),h[n.name]=e,t.delete()}y.delete();const f=r.values,b=i.values_count();for(let e=0;e<b;e++)f.push(i.get_value_at(e));const T=r.features,I=i.features,M=I.size();if(M>0)for(const e of w)if(void 0===h[e])throw new Error(`Feature collection missing required attribute: ${e}`);for(let e=0;e<M;e++){const t=new g,n=I.get(e),i=t.attributes,r=n.attributes_count();for(let e=0;e<r;e++)i.push(n.get_attribute_at(e));const o=n.get_compressed_geometry();o&&(t.compressedGeometry=E(o),t.centroid=E(n.get_centroid()));const s=t.aggregateGeometries,a=n.aggregate_geometries,l=a.size();for(let e=0;e<l;e++){const t=a.get(e),n=E(t);s.push(n),t.delete()}a.delete(),T.push(t),n.delete()}I.delete();const _=r.geometryFields,C=i.geometry_fields,v=C.size();for(let e=0;e<v;e++){const t=C.get(e),n=S(t);_.push(n),t.delete()}return C.delete(),t}(t.get_feature_collection());return t.delete(),i}(await t.data)}function D(e,t){if(!e?.queryResult?.featureResult)return t;const n=e.queryResult.featureResult.fieldNameToAttributeIndexMap;for(const i of e.queryResult.featureResult.features){const e=i.attributes[n.TYPENAME],r=(0,o.tE)(t.namedTypeDefinitions,e,()=>({useAllData:!1,members:new Map})),a=i.attributes[n.ELEMENTUID];if(i.compressedGeometry?.coords?.length>0){let e=i.compressedGeometry.lengths;"esriGeometryPoint"===i.compressedGeometry.geometryType&&(e=[]),r.members.set(a,{id:a,linkChartLocation:new s.A(e,i.compressedGeometry.coords)})}else r.members.set(a,{id:a})}return t}!function(e){e[e.upperLeft=0]="upperLeft",e[e.lowerLeft=1]="lowerLeft"}(_||(_={})),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"}(C||(C={}));const j={fetchAndConvertSerializedLinkChart:e=>async function(e){const t=[],n={generateAllSublayers:!1,namedTypeDefinitions:new Map};return e.entitiesUrl&&t.push(F(e.entitiesUrl).then(e=>{D(e,n)})),e.relationshipsUrl&&t.push(F(e.relationshipsUrl).then(e=>{D(e,n)})),await Promise.all(t),n}(e)}},69860:(e,t,n)=>{n.d(t,{A:()=>a});var i=n(65864),r=n(90708),o=n(43334),s=n(15375);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 n=this.readFromStoreById(e);n&&t.push(n)}),t}readFromStoreById(e){return this._featureLookup.get(e)??null}writeToStore(e,t,n){const a=[];return e.forEach(e=>{if(!e?.id)return;e.properties||(e.properties=[]);let l,u=null;if(n&&e.properties[n]&&(u=(0,r.Ux)(e.properties[n])),"originId"in e&&"destinationId"in e&&(e.properties[s.Cz]=e.originId,e.properties[s.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),s=JSON.parse(JSON.stringify(Object.assign(r.attributes,e.properties)));n&&e.properties[n]&&(s[n]=(0,i.rS)(e.properties[n])),l=new o.Om(u?JSON.parse(JSON.stringify(u)):r?.geometry?JSON.parse(JSON.stringify(r.geometry)):null,s,null,e.properties[t])}else l=new o.Om(u?JSON.parse(JSON.stringify(u)):null,e.properties,null,e.properties[t]);this._featureLookup.set(`${e.typeName?`${e.typeName}__${e.id}`:e.id}`,l),a.push(l)}),a}}},70643:(e,t,n)=>{n.d(t,{A:()=>te});var i=n(31635),r=n(13874),o=n(4718),s=n(53966),a=n(92071),l=(n(29953),n(10107)),u=(n(44208),n(40608)),d=n(43937),p=n(5443),c=n(86738),h=n(39829),y=n(82799),m=n(98988),f=n(16930),g=n(21325),b=n(50498),w=n(4146),T=n(83221),I=n(95422),M=n(64714),_=n(15375);n(87811);const C=(0,n(17036).p)(),v=e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.fields=[],this.fieldsIndex=null}};return(0,i.Cg)([(0,l.MZ)(C.fields)],n.prototype,"fields",void 0),(0,i.Cg)([(0,l.MZ)(C.fieldsIndex)],n.prototype,"fieldsIndex",void 0),n=(0,i.Cg)([(0,u.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayerBase")],n),n};var x=n(85342),E=n(63074),A=n(6455),S=n(87718),N=n(76294),k=n(32756),L=n(54310),F=n(25036),D=n(82935),j=n(10873),R=n(13213),B=n(20437),O=n(30524),Z=n(46499),$=n(39383),q=n(96184),P=n(96576),G=n(65494),U=n(41214),z=n(22671),Y=n(61956),Q=n(30291),H=n(37531),X=n(61322);function V(e){if(!e.json)return e;e.json.write=W(e.json.write);const t=e.json.origins;if(!t)return e;let n;for(n in t){const e=t[n];e&&(e.write=W(e.write))}return e}function W(e){return"object"==typeof e&&e?(!1!==e.enabled&&(e.overridePolicy=function(e){const{target:t,writer:n,overridePolicy:i,...r}=e;return function(e,t){const n=K.call(this,e,t);return n.enabled?{...r,...n}:n}}(e)),e):!0===e?J():e}function J(){return{overridePolicy:K}}function K(e,t){const n=!!this.geometryType;let i={enabled:n};return n&&(i={...i,...ee.call(this,e,t)}),i}function ee(e,t){return{ignoreOrigin:this.originIdOf(t)>0}}let te=class extends(v((0,A.FJ)((0,N.J)((0,S.F)((0,E.dM)((0,k.fY)((0,D.e)((0,F.j)((0,L.J)((0,a.P)(w.A))))))))))){constructor(e){super(e),this.blendMode="normal",this.capabilities=(0,M.f)(!1,!0),this.charts=null,this.definitionExpression=null,this.displayField="",this.displayFilterEnabled=!0,this.displayFilterInfo=null,this.effect=null,this.elevationInfo=null,this.featureEffect=null,this.graphType=null,this.labelsVisible=!0,this.layerType=null,this.legendEnabled=!0,this.maxScale=0,this.minScale=0,this.objectIdField=_.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 X.default(e.port1,{channel:e,client:{queryFeatures:(e,t={})=>{const n=Y.A.fromJSON(e);return this.queryFeaturesJSON(n,t)}}}),[e.port2]})},this.type="knowledge-graph-sublayer",this.useViewTime=!0,this.visible=!0}get userHasUpdateItemPrivileges(){return!!this.parent?.userHasUpdateItemPrivileges}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 n="esriFieldTypeOID"===t.fieldType?"esriFieldTypeInteger":t.fieldType;e.push(B.A.fromJSON({name:t.name,type:n,alias:t.alias,defaultValue:t.defaultValue,editable:t.editable,nullable:t.nullable}))}),e.push(B.A.fromJSON({name:this.objectIdField,type:"esriFieldTypeString",alias:this.objectIdField,editable:!1}),B.A.fromJSON({name:_.M1,type:"esriFieldTypeInteger",alias:_.M1,editable:!1}),B.A.fromJSON({name:_.BL,type:"esriFieldTypeInteger",alias:_.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?b.gy.fromJSON(t):null}get geometryFieldName(){if("link-chart"===this.parentCompositeLayer?.type)return _.T1;const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name);return e?.name??null}get graphTypeName(){return this.objectType?.name}set graphTypeName(e){this._set("graphTypeName",e)}get hasM(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,n=t?this.objectType?.properties?.[t]:null;return n?.hasM??!1}get hasZ(){const e=this.parentCompositeLayer?.dataManager.geographicLookup.get(this.objectType?.name),t=e?.name,n=t?this.objectType?.properties?.[t]:null;return n?.hasZ??!1}set labelingInfo(e){this._set("labelingInfo",e)}get labelingInfo(){if(this._isOverridden("labelingInfo"))return this._get("labelingInfo");if(!this.objectType||!this.parentCompositeLayer||!this.graphTypeName)return null;const e=this.objectType.properties?(0,x.MY)(this.objectType.properties):"ESRI__ID";return"link-chart"===this.parentCompositeLayer.type?(0,x.iW)(this.graphType,this.graphTypeName,e):(0,x.e$)(this.graphTypeName,this.geometryType,e)}set renderer(e){(0,O.yp)(e,this.fieldsIndex),this._set("renderer",e)}get renderer(){if(this._isOverridden("renderer"))return this._get("renderer");const e=this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel,t=[...e?.entityTypes??[],...e?.relationshipTypes??[]].map(e=>e.name).indexOf(this.graphTypeName),n=(0,x.Td)(t);if("link-chart"===this.parentCompositeLayer?.type){if("relationship"===this.graphType)return new P.A({type:"simple",symbol:(0,x.UT)(n)});const e=(0,G.r)((0,M.F0)(b.gy.toJSON("point")).renderer);return(0,H.dt)(e.symbol,n),e}const i=(0,G.r)((0,M.F0)(b.gy.toJSON(this.geometryType)).renderer);return(0,H.dt)(i.symbol,n),i}get spatialReference(){return this.parentCompositeLayer?.dataManager?.knowledgeGraph?.dataModel?.spatialReference??f.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,Q.tn)(this,e)}createQuery(){return new Y.A({where:"1=1",outFields:["*"]})}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){return null}async queryFeatures(e,t){await this.load();const{resolvedQuery:n,queryEngine:i}=await this._setupQueryObjects(e),r=z.A.fromJSON(await i.executeQuery(n.toJSON(),t?.signal));return r.features.forEach(e=>{e.sourceLayer=this}),r}async queryFeaturesJSON(e,t){await this.load();const{resolvedQuery:n,queryEngine:i}=await this._setupQueryObjects(e);return await i.executeQuery(n.toJSON(),t?.signal)}async queryFeatureCount(e,t){await this.load();const{resolvedQuery:n,queryEngine:i}=await this._setupQueryObjects(e);return i.executeQueryForCount(n.toJSON(),t?.signal)}async queryExtent(e={},t){await this.load();const n={...e,returnGeometry:!0},{resolvedQuery:i,queryEngine:r}=await this._setupQueryObjects(n),o=await r.executeQueryForExtent(i.toJSON(),t?.signal);let s;return s=null!=o.extent?.xmin&&null!=o.extent?.xmax&&null!=o.extent?.ymin&&null!=o.extent?.ymax?new p.A(o.extent):new p.A,{count:o.count,extent:s}}async queryObjectIds(e,t){await this.load();const n=Y.A.from(e);let i;if("link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)i=this._cachedQueryEngine;else{const e=await this.parentCompositeLayer.dataManager.getData(n,this,t);i=this.loadQueryEngine(e)}return await i.executeQueryForIds(n.toJSON(),t?.signal)}loadQueryEngine(e){const t=new T.A({geometryType:b.gy.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ}),n=new I.do({fieldsIndex:this.fieldsIndex.toJSON(),geometryType:b.gy.toJSON(this.geometryType),hasM:this.hasM,hasZ:this.hasZ,featureIdInfo:{type:"object-id",fieldName:this.objectIdField},spatialReference:this.spatialReference.toJSON(),timeInfo:this.timeInfo?.toJSON(),featureStore:t});return n.featureStore.addMany(e),n}async refreshCachedQueryEngine(){const e=await this.parentCompositeLayer.dataManager.getData(new Y.A({where:"1=1",outFields:[_.dr]}),this);this._cachedQueryEngine=this.loadQueryEngine(e)}load(e){return this.addResolvingPromise(this.parent.load(e).then(()=>(0,O.sv)(this.timeInfo,this.fieldsIndex))),Promise.resolve(this)}async _setupQueryObjects(e,t){const n=Y.A.from(e),i=n.geometry;if(i&&!i.spatialReference?.isWGS84&&(await(0,m.initializeProjection)(i.spatialReference,g.KK),n.geometry=(0,m.project)(i instanceof h.A||i instanceof y.A||i instanceof c.A?i:i.extent,g.KK)),"link-chart"===this.parentCompositeLayer.type&&this._cachedQueryEngine)return{resolvedQuery:n,queryEngine:this._cachedQueryEngine};const r=await this.parentCompositeLayer.dataManager.getData(n,this,t);return{resolvedQuery:n,queryEngine:this.loadQueryEngine(r)}}};(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(E.sU)))],te.prototype,"blendMode",void 0),(0,i.Cg)([(0,l.MZ)()],te.prototype,"capabilities",void 0),(0,i.Cg)([(0,l.MZ)({readOnly:!0})],te.prototype,"userHasUpdateItemPrivileges",null),(0,i.Cg)([(0,l.MZ)({json:{origins:{"web-scene":{write:!1}},write:J()}})],te.prototype,"charts",void 0),(0,i.Cg)([(0,l.MZ)({readOnly:!0})],te.prototype,"defaultPopupTemplate",null),(0,i.Cg)([(0,l.MZ)({type:String,json:{origins:{service:{read:!1}},name:"layerDefinition.definitionExpression",write:{ignoreOrigin:!0}}})],te.prototype,"definitionExpression",void 0),(0,i.Cg)([(0,l.MZ)()],te.prototype,"displayField",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(A.Dp)))],te.prototype,"displayFilterEnabled",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(A.KV)))],te.prototype,"displayFilterInfo",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(E.LF)))],te.prototype,"effect",void 0),(0,i.Cg)([(0,l.MZ)()],te.prototype,"elevationInfo",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(S.Y)))],te.prototype,"featureEffect",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(R.d)))],te.prototype,"featureReduction",null),(0,i.Cg)([(0,l.MZ)()],te.prototype,"fields",null),(0,i.Cg)([(0,l.MZ)()],te.prototype,"geometryType",null),(0,i.Cg)([(0,l.MZ)()],te.prototype,"geometryFieldName",null),(0,i.Cg)([(0,l.MZ)({type:["entity","relationship"],nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],te.prototype,"graphType",void 0),(0,i.Cg)([(0,l.MZ)({type:String,nonNullable:!0,json:{write:{isRequired:!0,ignoreOrigin:!0}}})],te.prototype,"graphTypeName",null),(0,i.Cg)([(0,l.MZ)()],te.prototype,"hasM",null),(0,i.Cg)([(0,l.MZ)()],te.prototype,"hasZ",null),(0,i.Cg)([(0,l.MZ)({type:String,json:{origins:{service:{read:!1},"portal-item":{read:!1}},write:{ignoreOrigin:!0}}})],te.prototype,"id",void 0),(0,i.Cg)([(0,l.MZ)({type:Boolean,value:!0,nonNullable:!0,json:{name:"showLabels",default:!1,write:{overridePolicy(){return{enabled:!!this.geometryType,alwaysWriteDefaults:!0,ignoreOrigin:!0}}}}})],te.prototype,"labelsVisible",void 0),(0,i.Cg)([(0,l.MZ)({type:[Z.A],json:{name:"layerDefinition.drawingInfo.labelingInfo",read:function(e,t,n){const i=[["ESRI__AGGREGATION_COUNT",_.M1],["ESRI__ORIGIN_ID",_.Cz],["ESRI__DESTINATION_ID",_.KQ],["ESRI__LAYOUT_GEOMETRY",_.T1]];try{for(const t of e)for(const[e,n]of i)t.labelExpression=t.labelExpression?.replaceAll(e,n),t.labelExpressionInfo?.expression&&(t.labelExpressionInfo.expression=t.labelExpressionInfo.expression.replaceAll(e,n))}catch(e){s.A.getLogger(this).warn("Error updating labelingInfo",e)}return(0,$.w)(e,t,n)},write:J()}})],te.prototype,"labelingInfo",null),(0,i.Cg)([(0,l.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}}})],te.prototype,"layerType",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(j.fV)))],te.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(j.hG)))],te.prototype,"maxScale",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(j.hn)))],te.prototype,"minScale",void 0),(0,i.Cg)([(0,l.MZ)()],te.prototype,"objectIdField",void 0),(0,i.Cg)([(0,l.MZ)()],te.prototype,"objectType",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(j.ke)))],te.prototype,"opacity",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(k.ne)))],te.prototype,"orderBy",void 0),(0,i.Cg)([(0,l.MZ)({clonable:!1})],te.prototype,"parent",void 0),(0,i.Cg)([(0,l.MZ)()],te.prototype,"parentCompositeLayer",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(j.M6)))],te.prototype,"popupEnabled",void 0),(0,i.Cg)([(0,l.MZ)({type:r.A,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],te.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,l.MZ)({type:Number,json:{write:{overridePolicy:ee}}})],te.prototype,"refreshInterval",void 0),(0,i.Cg)([(0,l.MZ)({types:U.Hg,json:{name:"layerDefinition.drawingInfo.renderer",write:J()}})],te.prototype,"renderer",null),(0,i.Cg)([(0,l.MZ)()],te.prototype,"source",void 0),(0,i.Cg)([(0,l.MZ)()],te.prototype,"spatialReference",null),(0,i.Cg)([(0,l.MZ)({type:q.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}}}})],te.prototype,"timeInfo",null),(0,i.Cg)([(0,l.MZ)({type:String,json:{write:{isRequired:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}})],te.prototype,"title",null),(0,i.Cg)([(0,d.K)("title")],te.prototype,"writeTitle",null),(0,i.Cg)([(0,l.MZ)({json:{read:!1}})],te.prototype,"type",void 0),(0,i.Cg)([(0,l.MZ)(V((0,o.o8)(D.B)))],te.prototype,"useViewTime",void 0),(0,i.Cg)([(0,l.MZ)({type:Boolean,json:{name:"visibility",write:J()}})],te.prototype,"visible",void 0),te=(0,i.Cg)([(0,u.$)("esri.layers.knowledgeGraph.KnowledgeGraphSublayer")],te)},73133:(e,t,n)=>{n.d(t,{j:()=>i});const i=(0,n(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},75503:(e,t,n)=>{n.d(t,{EC:()=>v,wq:()=>a});var i=n(4576),r=n(21818),o=(n(44208),n(15142)),s=n(11006);class a{constructor(e=9,t){this._compareMinX=c,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(),I.prune(),M.prune(),_.prune(),C.prune()}all(e){l(this._data,e)}search(e,t){let n=this._data;const i=this._toBBox;if(w(e,n))for(I.clear();n;){for(let r=0,o=n.children.length;r<o;r++){const o=n.children[r],s=n.leaf?i(o):o;w(e,s)&&(n.leaf?t(o):b(e,s)?l(o,t):I.push(o))}n=I.pop()}}collides(e){let t=this._data;const n=this._toBBox;if(!w(e,t))return!1;for(I.clear();t;){for(let i=0,r=t.children.length;i<r;i++){const r=t.children[i],o=t.leaf?n(r):r;if(w(e,o)){if(t.leaf||b(e,o))return!0;I.push(r)}}t=I.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,n=e.length;t<n;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 E([]),this}remove(e){if(!e)return this;let t,n=this._data,o=null,s=0,a=!1;const l=this._toBBox(e);for(_.clear(),C.clear();n||_.length>0;){if(n||(n=_.pop(),o=_.data[_.length-1],s=C.pop()??0,a=!0),n.leaf&&(t=(0,i.qh)(n.children,(0,r.zI)(e),n.children.length,n.indexHint),-1!==t))return n.children.splice(t,1),_.push(n),this._condense(_),this;a||n.leaf||!b(n,l)?o?(s++,n=o.children[s],a=!1):n=null:(_.push(n),C.push(s),s=0,o=n,n=n.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_build(e,t,n,i){const r=n-t+1;let o=this._maxEntries;if(r<=o){const i=new E(e.slice(t,n+1));return u(i,this._toBBox),i}i||(i=Math.ceil(Math.log(r)/Math.log(o)),o=Math.ceil(r/o**(i-1)));const s=new A([]);s.height=i;const a=Math.ceil(r/o),l=a*Math.ceil(Math.sqrt(o));T(e,t,n,l,this._compareMinX);for(let r=t;r<=n;r+=l){const t=Math.min(r+l-1,n);T(e,r,t,a,this._compareMinY);for(let n=r;n<=t;n+=a){const r=Math.min(n+a-1,t);s.children.push(this._build(e,n,r,i-1))}}return u(s,this._toBBox),s}_insert(e,t,n){const i=this._toBBox,r=n?e:i(e);_.clear();const o=function(e,t,n,i){for(;i.push(t),!0!==t.leaf&&i.length-1!==n;){let n,i=1/0,r=1/0;for(let o=0,s=t.children.length;o<s;o++){const s=t.children[o],a=y(s),l=f(e,s)-a;l<r?(r=l,i=a<i?a:i,n=s):l===r&&a<i&&(i=a,n=s)}t=n||t.children[0]}return t}(r,this._data,t,_);for(o.children.push(e),p(o,r);t>=0&&_.data[t].children.length>this._maxEntries;)this._split(_,t),t--;!function(e,t,n){for(let i=n;i>=0;i--)p(t.data[i],e)}(r,_,t)}_split(e,t){const n=e.data[t],i=n.children.length,r=this._minEntries;this._chooseSplitAxis(n,r,i);const o=this._chooseSplitIndex(n,r,i);if(!o)return;const s=n.children.splice(o,n.children.length-o),a=n.leaf?new E(s):new A(s);a.height=n.height,u(n,this._toBBox),u(a,this._toBBox),t?e.data[t-1].children.push(a):this._splitRoot(n,a)}_splitRoot(e,t){this._data=new A([e,t]),this._data.height=e.height+1,u(this._data,this._toBBox)}_chooseSplitIndex(e,t,n){let i,r,o;i=r=1/0;for(let s=t;s<=n-t;s++){const t=d(e,0,s,this._toBBox),a=d(e,s,n,this._toBBox),l=g(t,a),u=y(t)+y(a);l<i?(i=l,o=s,r=u<r?u:r):l===i&&u<r&&(r=u,o=s)}return o}_chooseSplitAxis(e,t,n){const i=e.leaf?this._compareMinX:c,r=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,n,i)<this._allDistMargin(e,t,n,r)&&e.children.sort(i)}_allDistMargin(e,t,n,i){e.children.sort(i);const r=this._toBBox,o=d(e,0,t,r),s=d(e,n-t,n,r);let a=m(o)+m(s);for(let i=t;i<n-t;i++){const t=e.children[i];p(o,e.leaf?r(t):t),a+=m(o)}for(let i=n-t-1;i>=t;i--){const t=e.children[i];p(s,e.leaf?r(t):t),a+=m(s)}return a}_condense(e){for(let t=e.length-1;t>=0;t--){const n=e.data[t];if(0===n.children.length)if(t>0){const r=e.data[t-1],o=r.children;o.splice((0,i.qh)(o,n,o.length,r.indexHint),1)}else this.clear();else u(n,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 l(e,t){let n=e;for(M.clear();n;){if(!0===n.leaf)for(const e of n.children)t((0,r.zI)(e));else M.pushArray(n.children);n=M.pop()??null}}function u(e,t){d(e,0,e.children.length,t,e)}function d(e,t,n,i,r){r||(r=new E([])),r.minX=1/0,r.minY=1/0,r.maxX=-1/0,r.maxY=-1/0;for(let o,s=t;s<n;s++)o=e.children[s],p(r,e.leaf?i(o):o);return r}function p(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 c(e,t){return e.minX-t.minX}function h(e,t){return e.minY-t.minY}function y(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function m(e){return e.maxX-e.minX+(e.maxY-e.minY)}function f(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 g(e,t){const n=Math.max(e.minX,t.minX),i=Math.max(e.minY,t.minY),r=Math.min(e.maxX,t.maxX),o=Math.min(e.maxY,t.maxY);return Math.max(0,r-n)*Math.max(0,o-i)}function b(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function w(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function T(e,t,n,i,r){const o=[t,n];for(;o.length;){const t=o.pop(),n=o.pop();if(t-n<=i)continue;const a=n+Math.ceil((t-n)/i/2)*i;(0,s.q)(e,a,n,t,r),o.push(n,a,a,t)}}const I=new o.A,M=new o.A,_=new o.A,C=new o.A({deallocator:void 0});class v{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class x extends v{constructor(){super(...arguments),this.height=1,this.indexHint=new i.vW}}class E extends x{constructor(e){super(),this.children=e,this.leaf=!0}}class A extends x{constructor(e){super(),this.children=e,this.leaf=!1}}},77901:(e,t,n)=>{n.d(t,{A:()=>a});var i=n(31635),r=n(25482),o=n(10107),s=(n(44208),n(53966),n(87811),n(40608));let a=class extends r.A{constructor(e){super(e),this.properties=null}};(0,i.Cg)([(0,o.MZ)({json:{write:!0}})],a.prototype,"properties",void 0),a=(0,i.Cg)([(0,s.$)("esri.rest.knowledgeGraph.GraphObject")],a)},80340:(e,t,n)=>{n.d(t,{P:()=>M});var i=n(31635),r=n(69622),o=n(49186),s=n(53966),a=n(91869),l=n(74887),u=n(39516),d=n(10107),p=(n(44208),n(87811),n(40608)),c=n(5443),h=n(39829),y=n(98988),m=n(21325),f=n(15375),g=n(69860),b=n(30504),w=n(62568),T=n(42538),I=n(61956);let M=class extends r.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(n=>{n.name&&(t.set(n.name,"entity"),this._processingCacheUpdatesLookup.set(n.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.entityTypeNames.add(n.name),n.properties?.forEach(e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(n.name,{name:e.name??"",geometryType:e.geometryType})}))}),e.knowledgeGraph.dataModel.relationshipTypes?.forEach(n=>{n.name&&(t.set(n.name,"relationship"),this._processingCacheUpdatesLookup.set(n.name,[]),e.inclusionModeDefinition&&!e.inclusionModeDefinition?.generateAllSublayers||this.relationshipTypeNames.add(n.name),n.properties?.forEach(e=>{e.geometryType&&"esriGeometryNull"!==e.geometryType&&this.geographicLookup.set(n.name,{name:e.name??"",geometryType:e.geometryType})}))}),e.inclusionModeDefinition?.namedTypeDefinitions.forEach((n,i)=>{if("entity"===t.get(i))this.entityTypeNames.add(i);else{if("relationship"!==t.get(i))return s.A.getLogger(this).warn(`A named type, ${i}, was in the inclusion list that wasn't in the data model and will be removed`),void e.inclusionModeDefinition?.namedTypeDefinitions.delete(i);this.relationshipTypeNames.add(i)}const r=new Map;n.members?.forEach(e=>{(0,a.tE)(this.memberIdTypeLookup,e.id,()=>new Set).add(i);const t=this.getById(e.id);t&&r.set(e.id,t)}),this.sublayerCaches.set(i,r)})}addToLayer(e){e.forEach(({typeName:e,id:t})=>{if(!this.inclusionModeDefinition)throw new o.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 n=this.inclusionModeDefinition.namedTypeDefinitions.get(e);n.members||(n.members=new Map),n.members.set(t,{id:t}),(0,a.tE)(this.memberIdTypeLookup,t,()=>new Set).add(e)}}else{const n=new Map;n.set(t,{id:t}),this.inclusionModeDefinition.namedTypeDefinitions.set(e,{useAllData:!1,members:n}),(0,a.tE)(this.memberIdTypeLookup,t,()=>new Set).add(e)}})}getById(e){return g.A.getInstance().readFromStoreById(e)}async getData(e,t,n){if(t.objectType.name&&this.inclusionModeDefinition?.namedTypeDefinitions&&this.inclusionModeDefinition.namedTypeDefinitions.size>0&&!this.inclusionModeDefinition.namedTypeDefinitions.has(t.objectType.name))return[];let i;if(i=e||new I.A({where:"1=1",outFields:["*"]}),"link-chart"===t.parentCompositeLayer.type){const e=t.parentCompositeLayer,n=this._processingCacheUpdatesLookup.get(t.objectType.name??""),r=i.outFields;r&&1===r.length&&r[0]===f.dr&&"1=1"===i.where||await Promise.all(n??[]);const o=this.sublayerCaches.has(t.objectType.name??"")?Array.from(this.sublayerCaches.get(t.objectType.name)?.values()):[],s=[];return o.forEach(n=>{if(this.relationshipTypeNames.has(t.objectType.name)){n.geometry=e.relationshipLinkChartDiagramLookup.get(n.attributes[t.objectIdField]);const i=this.memberIdTypeLookup.get(n.attributes[f.Cz]),r=this.memberIdTypeLookup.get(n.attributes[f.KQ]),o=this._isEndEntitySpatial(i,n,f.Cz),s=this._isEndEntitySpatial(r,n,f.KQ);n.attributes[f.BL]=Number(o&&s)}else{n.geometry=e.entityLinkChartDiagramLookup.get(n.attributes[t.objectIdField]);const i=this.geographicLookup.get(t.objectType.name);i&&n.attributes[i.name]?n.attributes[f.BL]=1:n.attributes[f.BL]=0}n.attributes[f.T1]=n.geometry,s.push(n)}),s}return this.retrieveDataFromService(i,t,n)}async getConnectedRecordIds(e,t,n){const i=[];let r="";const o=this._getNamedTypeIdMapFromNodeIds(e);if(t&&0!==t?.length){for(const e of t)r=r+e+"|";r=r.slice(0,-1)}const s={},a=[];for(const[e,n]of o){const i=`${e}_ids`;s[i]=n,t&&0!==t?.length?a.push(`MATCH (n:${e}) WHERE id(n) IN $${i} 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 $${i} WITH n MATCH (n)-[r]-(m) RETURN id(r), type(r), id(m), labels(m)[0]`)}if(!a.length)return i;const l=a.join(" UNION "),u=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,new T.A({openCypherQuery:l,bindParameters:s}),{signal:n?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await u.read();if(e)break;for(let e=0;e<t.length;e++){const n=t[e];i.push({id:n[0],typeName:n[1]}),i.push({id:n[2],typeName:n[3]})}}return i}async getRelationshipsBetweenNodes(e,t,n){const i=this._getNamedTypeIdMapFromNodeIds(e);if(0===i.size)return[];const r={relationshipExclusionIds:t,possibleConnectionEntityIds:e},o=[];for(const[e,t]of i.entries()){const n=`${e}_ids`;r[n]=t,o.push(`MATCH (n:${e}) WHERE id(n) IN $${n} WITH n MATCH (n)-[r]->(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const s=o.join(" UNION "),a=[],l=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,new T.A({openCypherQuery:s,bindParameters:r}),{signal:n?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await l.read();if(e)break;for(let e=0;e<t.length;e++){const n=t[e];a.push({id:n[0],typeName:n[1]})}}return a}async getRelationshipsFromNodes(e,t,n,i){const r=this._getNamedTypeIdMapFromNodeIds(e);if(0===r.size||0===t.length)return[];const o={relationshipExclusionIds:n,possibleConnectionEntityIds:t},s=[];for(const[e,t]of r.entries()){const n=`${e}_ids`;o[n]=t,s.push(`MATCH (n:${e}) WHERE id(n) IN $${n} WITH n MATCH (n)-[r]-(m) WHERE id(m) IN $possibleConnectionEntityIds AND NOT id(r) IN $relationshipExclusionIds RETURN id(r), type(r)`)}const a=s.join(" UNION "),l=new Map,u=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,new T.A({openCypherQuery:a,bindParameters:o}),{signal:i?.signal})).resultRowsStream.getReader();for(;;){const{done:e,value:t}=await u.read();if(e)break;for(let e=0;e<t.length;e++){const n=t[e];let i=l.get(n[1]);i||(i=new Set,l.set(n[1],i)),i.add(n[0])}}const d=[];for(const[e,t]of l)for(const n of t)d.push({id:n,typeName:e});return d}async refreshCacheContent(e,t,n,i=!0,r){const s=g.A.getInstance(),u=[],d=new Map,p=new Map;this.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&p.set(e.name,e)}),this.knowledgeGraph.dataModel.relationshipTypes?.forEach(e=>{e.name&&p.set(e.name,e)}),e||this.inclusionModeDefinition?e?e.forEach(e=>{if(this.memberIdTypeLookup.has(e))for(const t of this.memberIdTypeLookup.get(e))d.has(t)?d.get(t)?.push(e):d.set(t,[e])}):this.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{e.useAllData?d.set(t,null):e.members&&e.members.forEach(e=>{d.has(t)&&null!==d.get(t)?d.get(t)?.push(e.id):d.set(t,[e.id])})}):(this.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&d.set(e.name,null)}),this.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&d.set(e.name,null)}));for(const[e,l]of d){const d=new Set(l),c=new Promise((u,c)=>{(async()=>{const u=new Set,c=[];let h,y="",m=!1;if(t||p.get(e)?.properties?.forEach(e=>{e.name&&u.add(e.name)}),n&&this.geographicLookup.has(e)){const t=this.geographicLookup.get(e)?.name;t&&u.add(t)}if(this.entityTypeNames.has(e))y=`MATCH (n:${e}) ${l?"WHERE id(n) IN $ids ":""}return ID(n)`,u.forEach(e=>{y+=`, n.${e}`,c.push(e)});else{if(!this.relationshipTypeNames.has(e))throw new o.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?`);m=!0,y=`MATCH ()-[n:${e}]->() ${l?"WHERE id(n) IN $ids ":""}return ID(n), id(startNode(n)), id(endNode(n))`,u.forEach(e=>{y+=`, n.${e}`,c.push(e)})}h=new T.A(l?{openCypherQuery:y,bindParameters:{ids:l}}:{openCypherQuery:y});const g=(await(0,w.executeQueryStreaming)(this.knowledgeGraph,h,{signal:r?.signal})).resultRowsStream.getReader();for(;;){const{done:t,value:n}=await g.read();if(t)break;const r=[];for(let e=0;e<n.length;e++){const t=n[e];let i=0,o=0;const s={properties:{}};for(s.id=t[i],i++,o++,m&&(s.originId=t[i],i++,o++,s.destinationId=t[i],i++,o++,(0,a.tE)(this.nodeConnectionsLookup,s.originId,()=>new Set).add(s.id),(0,a.tE)(this.nodeConnectionsLookup,s.destinationId,()=>new Set).add(s.id),(0,a.tE)(this.relationshipConnectionsLookup,s.id,()=>[s.originId,s.destinationId]));i<t.length;i++)s.properties[c[i-o]]=t[i];d.delete(s.id),r.push(s)}const o=s.writeToStore(r,f.dr,this.geographicLookup.get(e)?.name);this.sublayerCaches.has(e)||this.sublayerCaches.set(e,new Map),i&&!this.inclusionModeDefinition?.namedTypeDefinitions.has(e)&&this.inclusionModeDefinition?.namedTypeDefinitions.set(e,{useAllData:!1,members:new Map}),i&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members&&(this.inclusionModeDefinition.namedTypeDefinitions.get(e).members=new Map);const l=this.sublayerCaches.get(e);o.forEach(t=>{l?.set(t.attributes[f.dr],t),i&&!this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.has(t.attributes[f.dr])&&(this.inclusionModeDefinition?.namedTypeDefinitions.get(e).members.set(t.attributes[f.dr],{id:t.attributes[f.dr]}),(0,a.tE)(this.memberIdTypeLookup,t.attributes[f.dr],()=>new Set).add(e))})}const b=this.inclusionModeDefinition?.namedTypeDefinitions.get(e);if(b)for(const e of d)b.members?.delete(e)})().then(()=>{u(null)}).catch(e=>{"AbortError"===e.name?u(null):c(e)})});u.push(c),this._processingCacheUpdatesLookup.get(e)?.push(c)}if(await Promise.all(u),r?.signal?.aborted)throw(0,l.NK)()}removeFromLayer(e){const t=new Set,n=new Set(e.map(e=>e.id));for(const n of e)t.add(n.typeName),1===this.memberIdTypeLookup.get(n.id)?.size?this.memberIdTypeLookup.delete(n.id):this.memberIdTypeLookup.get(n.id)?.delete(n.typeName),this.inclusionModeDefinition?.namedTypeDefinitions.forEach((e,t)=>{t===n.typeName&&e.members?.has(n.id)&&e.members.delete(n.id)});t.forEach(e=>{this.sublayerCaches.get(e)?.forEach((t,i)=>{n.has(i)&&this.sublayerCaches.get(e)?.delete(i)})})}async retrieveDataFromService(e,t,n){const i=g.A.getInstance(),r=new Set,s=[];let a,l="",d=[];const p="relationship"===t.graphType,I=this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData,M=t.parentCompositeLayer.sublayerIdsCache.get(t.objectType.name);let _=!I&&M?Array.from(M).sort():null;if(this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData)this.inclusionModeDefinition?.namedTypeDefinitions?.get(t.objectType.name)?.useAllData&&null!=e.objectIds&&(_=e.objectIds);else if(null!=e.objectIds&&_&&_.length>0){const t=e.objectIds;e.objectIds=_.filter(e=>t.includes(e))}else if(null!=e.objectIds)_=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=_}if(null!=e.outFields){const n=e.outFields;n.includes("*")?t.fields.forEach(e=>{r.add(e.name)}):n.forEach(e=>{e!==f.dr&&e!==t.geometryFieldName&&r.add(e)})}if(null!=e.geometry){const n=e.geometry;let i;const d=t.parentCompositeLayer.dataManager.knowledgeGraph.serviceDefinition,f=d?.spatialReference,g=d?.serviceCapabilities?.geometryCapabilities;let w=g?.geometryMaxBoundingRectangleSizeX,I=g?.geometryMaxBoundingRectangleSizeY;if("point"===n.type){let e=n;e.spatialReference?.isWGS84||(await(0,y.initializeProjection)(e.spatialReference,m.KK),e=(0,y.project)(e,m.KK)),i=new c.A({spatialReference:m.KK,xmin:e.x-1e-4,ymin:e.y-1e-4,xmax:e.x+1e-4,ymax:e.y+1e-4})}else n?.extent?.spatialReference&&!n.spatialReference?.isWGS84?(await(0,y.initializeProjection)(n.extent.spatialReference,m.KK),i=(0,y.project)(n.extent,m.KK)):i=n.extent;if(w&&I&&f){if(4326!==f.wkid){const e=new c.A({spatialReference:f,xmax:w,ymax:I}),t=(0,y.project)(e,m.KK);w=t.xmax,I=t.ymax}if(i.xmax-i.xmin>w)throw new o.A("knowledge-graph:layer-data-manager",`Extent x bounds should be within ${w}° latitude, limit exceeded`);if(i.ymax-i.ymin>I)throw new o.A("knowledge-graph:layer-data-manager",`Extent y bounds should be within ${I}° longitude, limit exceeded`)}if(null!=e.where&&"1=1"!==e.where){const n=await(0,u.GP)(e.where.toUpperCase(),t.fieldsIndex);t.fields.forEach(e=>{n.fieldNames.includes(e.name)&&r.add(e.name)})}l=p?`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&&r.add(t.geometryFieldName),r.forEach(e=>{l+=`, n.${e}`,s.push(e)}),a=new T.A({openCypherQuery:l,bindParameters:{param_filter_geom:new h.A({rings:(0,b.Wq)(i)})}})}else{let n="";if(null!=e.where&&"1=1"!==e.where){const i=await(0,u.GP)(e.where,t.fieldsIndex);t.fields.forEach(e=>{i.fieldNames.includes(e.name)&&r.add(e.name)});const o=new Set(["column-reference","string","number","binary-expression"]),s=new Set(["=","<","<=","<>",">",">=","AND","OR","LIKE"]);let a=!1;const l=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&&o.has(e.left.type)&&o.has(e.right.type)&&s.has(e.operator))return`${l(e.left)} ${e.operator} ${l(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 n=e.right.value;"%"===n.charAt(0)&&(n=n.slice(1)),"%"===n.charAt(n.length-1)&&(n=n.slice(0,-1)),t+=`'${n.toLowerCase()}')`}return t}return a=!0,""};n=l(i.parseTree),a&&(n="")}let i="";i=p?`Match ()-[n:${t.objectType.name}]->()`:`Match (n:${t.objectType.name})`;let o=!1;_&&(o=!0,i+=" WHERE ID(n) IN $ids"),n&&(i+=o?" AND":" WHERE",i+=` ${n}`),i+=" return ID(n)",p&&(i+=", id(startNode(n)), id(endNode(n))"),e.returnGeometry&&t.geometryFieldName&&r.add(t.geometryFieldName),r.forEach(e=>{i+=`, n.${e}`,s.push(e)}),a=new T.A(_?{openCypherQuery:i,bindParameters:{ids:_}}:{openCypherQuery:i})}const C=(await(0,w.executeQueryStreaming)(t.parentCompositeLayer.dataManager.knowledgeGraph,a,n)).resultRowsStream.getReader();for(;;){const{done:e,value:n}=await C.read();if(e)break;const r=[];for(let e=0;e<n.length;e++){const t=n[e];let i=0,o=0;const a={properties:{}};for(a.id=t[i],i++,o++,p&&(a.originId=t[i],i++,o++,a.destinationId=t[i],i++,o++);i<t.length;i++)a.properties[s[i-o]]=t[i];r.push(a)}d=d.concat(i.writeToStore(r,f.dr,t.parentCompositeLayer.dataManager.geographicLookup.get(t.objectType.name)?.name))}return d}_isEndEntitySpatial(e,t,n){for(const i of e??[])if(this.entityTypeNames.has(i)){const e=this.geographicLookup.get(i),r=e&&this.sublayerCaches.get(i)?.get(t.attributes[n]);if(e&&r?.attributes[e.name])return!0}return!1}_getNamedTypeIdMapFromNodeIds(e){const t=new Map;return e.forEach(e=>{if(this.memberIdTypeLookup.has(e))for(const n of this.memberIdTypeLookup.get(e)){if(!this.entityTypeNames.has(n))return;t.has(n)?t.get(n)?.push(e):t.set(n,[e])}}),t}};(0,i.Cg)([(0,d.MZ)()],M.prototype,"knowledgeGraph",void 0),(0,i.Cg)([(0,d.MZ)()],M.prototype,"inclusionModeDefinition",void 0),(0,i.Cg)([(0,d.MZ)()],M.prototype,"entityTypeNames",void 0),(0,i.Cg)([(0,d.MZ)()],M.prototype,"relationshipTypeNames",void 0),(0,i.Cg)([(0,d.MZ)()],M.prototype,"geographicLookup",void 0),(0,i.Cg)([(0,d.MZ)()],M.prototype,"sublayerCaches",void 0),(0,i.Cg)([(0,d.MZ)()],M.prototype,"nodeConnectionsLookup",void 0),(0,i.Cg)([(0,d.MZ)()],M.prototype,"relationshipConnectionsLookup",void 0),(0,i.Cg)([(0,d.MZ)()],M.prototype,"memberIdTypeLookup",void 0),M=(0,i.Cg)([(0,p.$)("esri.layers.knowledgeGraph.KnowledgeGraphLayerDataManager")],M)},82935:(e,t,n)=>{n.d(t,{B:()=>h,e:()=>y});var i=n(31635),r=n(10107),o=(n(44208),n(53966),n(87811),n(36005)),s=n(40608),a=n(89317),l=n(30524),u=n(96184),d=n(73133),p=n(64272),c=n(26253);const h={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:a.K}}},y=e=>{const t=e;let n=class extends t{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const n=t.timeInfo.exportOptions;if(!n)return null;const i=n.timeOffset,r=d.j.fromJSON(n.timeOffsetUnits);return i&&r?new c.T({value:i,unit:r}):null}set timeInfo(e){(0,l.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,i.Cg)([(0,r.MZ)({type:p.T,json:{write:!1}})],n.prototype,"timeExtent",void 0),(0,i.Cg)([(0,r.MZ)({type:c.T})],n.prototype,"timeOffset",void 0),(0,i.Cg)([(0,o.w)("service","timeOffset",["timeInfo.exportOptions"])],n.prototype,"readOffset",null),(0,i.Cg)([(0,r.MZ)({value:null,type:u.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],n.prototype,"timeInfo",null),(0,i.Cg)([(0,r.MZ)(h)],n.prototype,"useViewTime",void 0),n=(0,i.Cg)([(0,s.$)("esri.layers.mixins.TemporalLayer")],n),n}},83221:(e,t,n)=>{n.d(t,{A:()=>y});var i=n(4576),r=n(49186),o=n(65529),s=n(53966),a=n(70328),l=n(19419),u=n(90708),d=n(6518),p=n(51441),c=n(37730);const h=(0,a.vt)();class y{constructor(e){this.geometryInfo=e,this._boundsStore=new d.F,this._featuresById=new Map,this._usedMemory=0,this.events=new o.A.EventEmitter,this.featureAdapter=c.T}get usedMemory(){return this._usedMemory}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,n,i,r]=this.fullBounds;return{xmin:t,ymin:n,xmax:i,ymax:r,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(i.Ru)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged(),this._usedMemory=0}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 n of e){const e=this._boundsStore.get(n.objectId);e&&t((0,a.Jt)(h,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 s.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new r.A("featurestore:invalid-feature","feature id is missing",{feature:e}));const n=this._featuresById.get(t);let i;if(n?(e.displayId=n.displayId,i=this._boundsStore.get(t),this._boundsStore.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(n)??0):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);i=(0,u.jQ)(null!=i?i:(0,l.vt)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=i&&this._boundsStore.set(t,i),this._featuresById.set(t,e),this._usedMemory+=this.estimateFeatureUsedMemory?.(e)??0}_upsert(e){const t=e?.objectId;if(null==t)return s.A.getLogger("esri.layers.graphics.data.FeatureStore").error(new r.A("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const n=this._featuresById.get(t);if(!n)return this._add(e),e;this._usedMemory-=this.estimateFeatureUsedMemory?.(n)??0;const{geometry:i,attributes:o}=e;for(const e in o)n.attributes[e]=o[e];return i&&(n.geometry=i,this._boundsStore.set(t,(0,u.jQ)((0,l.vt)(),i,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),this._usedMemory+=this.estimateFeatureUsedMemory?.(n)??0,n}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._boundsStore.delete(t),this._featuresById.delete(t),this._usedMemory-=this.estimateFeatureUsedMemory?.(e)??0,e}}},83960:(e,t,n)=>{n.d(t,{X_:()=>s,oW:()=>l,zx:()=>a});var i=n(34727),r=n(83047);const o=96;function s(e,t){const n=t||e.extent,i=e.width,s=(0,r.GA)(n?.spatialReference);return n&&i?n.width/i*s*r.dy*o:0}function a(e,t,n){return function(e,t){return 0===t||(0,i.Sp)(e,t)||e<t}(e,t)&&function(e,t){return 0===t||(0,i.Sp)(e,t)||e>t}(e,n)}function l(e,t){return(0,i.Sp)(e,t)?0:(e||Number.POSITIVE_INFINITY)>(t||Number.POSITIVE_INFINITY)?1:-1}},85342:(e,t,n)=>{n.d(t,{MY:()=>f,Td:()=>y,UT:()=>m,e$:()=>b,iW:()=>g,qN:()=>p});var i=n(68197),r=n(46499),o=n(73913),s=n(62568),a=n(40863),l=n(68249);const u={initializeLayersFromClientData:async(e,t,n)=>{if(t||(t=[...e.layers,...e.tables].map(e=>e.graphTypeName)),0===t?.length)return;const i=new Map;for(const n of t)i.set(n,d(e,n));const r=await(0,s.fetchClientDataAtKeys)(e.dataManager.knowledgeGraph,Array.from(i.values()),{requestOptions:{signal:n?.signal}});for(const t of[...e.layers,...e.tables]){const n=t.objectType.name;if(null==n)continue;const i=r.get(d(e,n));if(i){const e=JSON.parse(i);null===e||"object"!=typeof e||e.hasOwnProperty("showLabels")||(e.showLabels=!1),t.read(e,{origin:"service"})}}}},d=(e,t)=>"knowledge-graph"===e.type?`${t}/Map`:`${t}/LinkChart/LinkChartSubLayer`;async function p(e,t,n){return u.initializeLayersFromClientData(e,t,n)}const c=["#4a0932","#b31515","#18382e","#a64f1b","#102432","#8c213f","#ed9310","#2c6954","#144d59","#ffc730","#75351e","#454f4b","#78b1c2","#191921","#8f8f82","#9be0c0","#dbb658","#87b051","#11495c","#c43541","#9c5596","#44498b","#ad9d63","#86afb3","#5c98ca","#b0bfa2","#73241f","#b86b53","#d9d78c","#3e756d","#f260a1","#a0d17d","#c27c30","#eb82eb","#ffdf3c","#ffb259","#ab52b3","#3cccb4","#0095ba","#d92b30"],h="#8f8f82";function y(e){return e<0||e>=c.length?new i.A(h):new i.A(c[e])}function m(e){const t=e.toArray();return new a.A({data:{type:"CIMSymbolReference",symbol:{type:"CIMLineSymbol",symbolLayers:[{type:"CIMSolidStroke",enable:!0,style:"solid",width:.75,color:t},{type:"CIMVectorMarker",enable:!0,size:6,markerPlacement:{type:"CIMMarkerPlacementOnLine",angleToLine:!0,relativeTo:"LineMiddle"},frame:{xmin:-10,ymin:-5,xmax:0,ymax:5},markerGraphics:[{type:"CIMMarkerGraphic",geometry:{rings:[[[-12,-3.47],[-12,3.6],[1.96,-.03],[-12,-3.47]]]},symbol:{type:"CIMPolygonSymbol",symbolLayers:[{type:"CIMSolidFill",enable:!0,color:t}]}}]}]}}})}function f(e){let t="ESRI__ID",n=4;for(const i of e)if(i.name){if("name"===i.name.toLowerCase()){t=i.name;break}i.name.toLowerCase().includes("name")?(t=i.name,n=2):"esriFieldTypeString"===i.fieldType&&n>3&&(t=i.name,n=3)}return t}function g(e,t,n){const i={color:[80,80,80],haloColor:[255,255,255],haloSize:.7,font:{size:10,weight:"normal"}},s=new r.A({labelExpressionInfo:new o.A({expression:"ESRI__ID"===n?`${t}`:`$feature.${n}`}),labelPlacement:"above-center",symbol:new l.A(i)}),a=new r.A({labelExpressionInfo:new o.A({expression:`'${t}' + IIf($feature.ESRI__AggregationCount>1, ' (' + $feature.ESRI__AggregationCount + ')', '')`}),labelPlacement:"center-along",labelPosition:"parallel",repeatLabel:!1,symbol:new l.A({...i,yoffset:"12px"})});return"entity"===e?[s]:[a]}function b(e,t,n){const i={color:[255,255,255],haloColor:[0,0,0],haloSize:.7,font:{size:10,weight:"bold"}},s="ESRI__ID"===n?`${e}`:`$feature.${n}`;return"point"===t?[new r.A({labelExpressionInfo:new o.A({expression:s}),labelPlacement:"above-center",symbol:new l.A(i)})]:"polyline"===t?[new r.A({labelExpressionInfo:new o.A({expression:s}),labelPlacement:"center-along",repeatLabel:!0,symbol:new l.A(i)})]:"polygon"===t?[new r.A({labelExpressionInfo:new o.A({expression:s}),labelPlacement:"always-horizontal",symbol:new l.A(i)})]:null}},96184:(e,t,n)=>{n.d(t,{A:()=>y});var i=n(31635),r=n(69540),o=n(25482),s=n(10107),a=(n(44208),n(53966),n(87811),n(36005)),l=n(40608),u=n(43937),d=n(64272),p=n(26253),c=n(56400);function h(e,t){return p.T.fromJSON({value:e,unit:t})}let y=class extends(r.A.ClonableMixin(o.A)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?d.T.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?h(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?h(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,i.Cg)([(0,s.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],y.prototype,"cumulative",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"endField",void 0),(0,i.Cg)([(0,s.MZ)({type:d.T,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"fullTimeExtent",void 0),(0,i.Cg)([(0,a.w)("fullTimeExtent",["timeExtent"])],y.prototype,"readFullTimeExtent",null),(0,i.Cg)([(0,u.K)("fullTimeExtent")],y.prototype,"writeFullTimeExtent",null),(0,i.Cg)([(0,s.MZ)({type:Boolean,json:{write:!0}})],y.prototype,"hasLiveData",void 0),(0,i.Cg)([(0,s.MZ)({type:p.T,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"interval",void 0),(0,i.Cg)([(0,a.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],y.prototype,"readInterval",null),(0,i.Cg)([(0,u.K)("interval")],y.prototype,"writeInterval",null),(0,i.Cg)([(0,s.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],y.prototype,"startField",void 0),(0,i.Cg)([(0,s.MZ)((0,c.P6)("timeReference",!0))],y.prototype,"timeZone",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],y.prototype,"trackIdField",void 0),(0,i.Cg)([(0,s.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],y.prototype,"useTime",void 0),(0,i.Cg)([(0,s.MZ)({type:[Date],json:{read:!1}})],y.prototype,"stops",void 0),y=(0,i.Cg)([(0,l.$)("esri.layers.support.TimeInfo")],y)}}]);