@arcgis/core 5.1.0-next.47 → 5.1.0-next.49

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 (133) hide show
  1. package/assets/esri/core/workers/RemoteClient.js +1 -1
  2. package/assets/esri/core/workers/chunks/{521a671182b0f79e3624.js → 193775b3b7de8f5dc578.js} +1 -1
  3. package/assets/esri/core/workers/chunks/{c0ecb68387e342dddf58.js → 25509953f19fbc4949a1.js} +1 -1
  4. package/assets/esri/core/workers/chunks/2669a7195f1de21a9cf3.js +1 -0
  5. package/assets/esri/core/workers/chunks/330da3828eefd8d72d3f.js +1 -0
  6. package/assets/esri/core/workers/chunks/36425d29aaa5852cb41d.js +1 -0
  7. package/assets/esri/core/workers/chunks/440a650ed0867a16f559.js +1 -0
  8. package/assets/esri/core/workers/chunks/{aa367ca7f8326fd67881.js → 4afddb66242438b38df0.js} +1 -1
  9. package/assets/esri/core/workers/chunks/5344919fc6e8050450f1.js +1 -0
  10. package/assets/esri/core/workers/chunks/53c149bca42595b7dd1e.js +1 -0
  11. package/assets/esri/core/workers/chunks/{6afdaa6c4555c467dca7.js → 54420b66fd53d6e19ba5.js} +1 -1
  12. package/assets/esri/core/workers/chunks/74814678942a47fd48fb.js +1 -0
  13. package/assets/esri/core/workers/chunks/797bf402489b3677a5f7.js +1 -0
  14. package/assets/esri/core/workers/chunks/{5c830cce32710d70dfa6.js → 7dba4121cdd20dbc4b20.js} +1 -1
  15. package/assets/esri/core/workers/chunks/947a715b608c8affd812.js +1 -0
  16. package/assets/esri/core/workers/chunks/{867c0cd99a005a3d8e08.js → 9f7b5749f3ceca8d5978.js} +12 -9
  17. package/assets/esri/core/workers/chunks/aa69cbaa38b49677ddff.js +1 -0
  18. package/assets/esri/core/workers/chunks/{beb53b372d356800f333.js → ab414a60808ea05a63e6.js} +1 -1
  19. package/assets/esri/core/workers/chunks/b98dd9fc9a7e3ff6bd49.js +1 -0
  20. package/assets/esri/core/workers/chunks/cb8c17daec7055bf99cc.js +1 -0
  21. package/assets/esri/core/workers/chunks/{a9f35127c3f5bf42036b.js → de359f89e03da18999fc.js} +1 -1
  22. package/chunks/Fog.glsl.js +3 -3
  23. package/chunks/GlowComposition.glsl.js +5 -3
  24. package/config.js +1 -1
  25. package/core/has.js +1 -1
  26. package/core/workers/Connection.js +1 -1
  27. package/core/workers/WorkerHandle.js +1 -1
  28. package/core/workers/workers.js +1 -1
  29. package/geometry/support/curves/bezierCurveUtils.js +1 -1
  30. package/kernel.js +1 -1
  31. package/layers/Lyr3DWorkerHandle.js +1 -1
  32. package/layers/OrientedImageryLayer.d.ts +152 -0
  33. package/layers/graphics/data/QueryEngineResult.js +1 -1
  34. package/layers/mixins/ArcGISCachedService.js +1 -1
  35. package/layers/mixins/ArcGISMapService.js +1 -1
  36. package/layers/support/RasterJobHandler.js +1 -1
  37. package/layers/support/layerUtils.js +1 -1
  38. package/package.json +1 -1
  39. package/smartMapping/statistics/support/statsWorker.js +1 -1
  40. package/support/revision.js +1 -1
  41. package/time/TimeExtent.d.ts +34 -0
  42. package/time/TimeInterval.d.ts +15 -0
  43. package/views/2d/engine/vectorTiles/TileHandler.js +1 -1
  44. package/views/2d/engine/vectorTiles/TileHandler3D.js +1 -1
  45. package/views/2d/engine/vectorTiles/TileManager.js +1 -1
  46. package/views/2d/engine/vectorTiles/VTLPainter3D.js +1 -1
  47. package/views/2d/engine/vectorTiles/VectorTile.js +1 -1
  48. package/views/2d/engine/vectorTiles/VectorTileContainer.js +1 -1
  49. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/vector-tiles/VTLShaderCircle.js +1 -1
  50. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/vector-tiles/VTLShaderFill.js +1 -1
  51. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/vector-tiles/VTLShaderIcon.js +1 -1
  52. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/vector-tiles/VTLShaderLine.js +1 -1
  53. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/vector-tiles/VTLShaderText.js +1 -1
  54. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueCircle.js +1 -1
  55. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueFill.js +1 -1
  56. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueLine.js +1 -1
  57. package/views/2d/engine/webgl/shaderGraph/techniques/vectorTiles/VTLTechniqueSymbol.js +1 -1
  58. package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
  59. package/views/2d/engine/webgl/util/Fader.js +2 -0
  60. package/views/2d/layers/VectorTileLayerView2D.js +1 -1
  61. package/views/3d/analysis/AreaMeasurement/support/AreaMeasurementVisualization.js +1 -1
  62. package/views/3d/analysis/Dimension/LengthDimensionSubTool.js +1 -1
  63. package/views/3d/analysis/DirectLineMeasurement/DirectLineMeasurementVisualization.js +1 -1
  64. package/views/3d/analysis/Slice/SliceTool.js +1 -1
  65. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillVisualization.js +1 -1
  66. package/views/3d/interactive/visualElements/ExtendedLineVisualElement.js +1 -1
  67. package/views/3d/interactive/visualElements/LineVisualElement.js +1 -1
  68. package/views/3d/interactive/visualElements/MeasurementAreaVisualElement.js +1 -1
  69. package/views/3d/interactive/visualElements/OutlineVisualElement.js +1 -1
  70. package/views/3d/interactive/visualElements/RightAngleQuadVisualElement.js +1 -1
  71. package/views/3d/layers/FlowSubView3D.js +1 -1
  72. package/views/3d/layers/GaussianSplatLayerView3D.js +1 -1
  73. package/views/3d/layers/SceneLayerWorkerHandle.js +1 -1
  74. package/views/3d/layers/graphics/Graphics3DLineSymbolLayer.js +1 -1
  75. package/views/3d/layers/graphics/Graphics3DPolygonFillSymbolLayer.js +1 -1
  76. package/views/3d/layers/i3s/Intersector.js +1 -1
  77. package/views/3d/layers/support/patternUtils.js +1 -1
  78. package/views/3d/support/gaussianSplatting/GaussianSplatDataStore.js +1 -1
  79. package/views/3d/support/gaussianSplatting/GaussianSplatFadeHelper.js +1 -1
  80. package/views/3d/support/gaussianSplatting/GaussianSplatFadeTexture.js +1 -1
  81. package/views/3d/support/gaussianSplatting/GaussianSplatOrderTexture.js +1 -1
  82. package/views/3d/support/gaussianSplatting/GaussianSplatTextureAtlas.js +1 -1
  83. package/views/3d/terrain/TerrainRenderer.js +1 -1
  84. package/views/3d/webgl-engine/collections/Component/Material/ComponentTechnique.js +1 -1
  85. package/views/3d/webgl-engine/core/renderPasses/RenderPassManager.js +1 -1
  86. package/views/3d/webgl-engine/effects/fog/Fog.glsl.js +1 -1
  87. package/views/3d/webgl-engine/effects/fog/Fog.js +1 -1
  88. package/views/3d/webgl-engine/effects/fog/FogTechniqueConfiguration.js +1 -1
  89. package/views/3d/webgl-engine/effects/glow/GlowComposition.glsl.js +1 -1
  90. package/views/3d/webgl-engine/effects/glow/GlowRenderNode.js +1 -1
  91. package/views/3d/webgl-engine/lib/BindParameters.js +1 -1
  92. package/views/3d/webgl-engine/lib/OrderIndependentTransparency.js +1 -1
  93. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  94. package/views/3d/webgl-engine/lib/intersectorUtilsConversions.js +1 -1
  95. package/views/3d/webgl-engine/materials/ColorMaterial.js +1 -1
  96. package/views/3d/webgl-engine/materials/DefaultMaterial.js +1 -1
  97. package/views/3d/webgl-engine/materials/PathMaterial.js +1 -1
  98. package/views/3d/webgl-engine/materials/PathTechnique.js +1 -1
  99. package/views/3d/webgl-engine/materials/PathTechniqueConfiguration.js +1 -1
  100. package/views/3d/webgl-engine/materials/PatternMaterial.js +1 -1
  101. package/views/3d/webgl-engine/materials/PolygonOffset.js +2 -0
  102. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  103. package/views/3d/webgl-engine/materials/SlicePlaneMaterial.js +1 -1
  104. package/views/3d/webgl-engine/materials/TriangleMaterial.js +1 -1
  105. package/views/3d/webgl-engine/materials/TriangleTechniqueConfiguration.js +1 -1
  106. package/views/3d/webgl-engine/shaders/ColorMaterialTechnique.js +1 -1
  107. package/views/3d/webgl-engine/shaders/DefaultMaterialTechniqueConfiguration.js +1 -1
  108. package/views/3d/webgl-engine/shaders/Dithering.glsl.js +4 -0
  109. package/views/3d/webgl-engine/shaders/HUDMaterialTechnique.js +1 -1
  110. package/views/3d/webgl-engine/shaders/OutputColorHighlightOLID.glsl.js +11 -10
  111. package/views/3d/webgl-engine/shaders/PatternTechnique.js +1 -1
  112. package/views/3d/webgl-engine/shaders/RibbonLineTechnique.js +1 -1
  113. package/views/3d/webgl-engine/shaders/RibbonLineTechniqueConfiguration.js +1 -1
  114. package/views/3d/webgl-engine/shaders/ShadedColorMaterialTechnique.js +1 -1
  115. package/views/3d/webgl-engine/shaders/ShadedColorMaterialTechniqueConfiguration.js +1 -1
  116. package/views/SceneView.d.ts +2 -1
  117. package/views/SceneView.js +1 -1
  118. package/views/draw/plugins/FreehandSegmentPlugin.js +1 -1
  119. package/views/support/LayerViewManager.js +1 -1
  120. package/views/types.d.ts +33 -2
  121. package/widgets/Sketch/support/PluginManager.js +1 -1
  122. package/assets/esri/core/workers/chunks/0601c316da0256a60538.js +0 -1
  123. package/assets/esri/core/workers/chunks/13d55e3c9aea04116eaa.js +0 -1
  124. package/assets/esri/core/workers/chunks/1a6a77902dd8c84e059a.js +0 -1
  125. package/assets/esri/core/workers/chunks/54c1d31e1efab765ee7a.js +0 -1
  126. package/assets/esri/core/workers/chunks/5b515b5741733bcb4645.js +0 -1
  127. package/assets/esri/core/workers/chunks/7f07f490c6fcc794c8d9.js +0 -1
  128. package/assets/esri/core/workers/chunks/970d971551e42f7ae08d.js +0 -1
  129. package/assets/esri/core/workers/chunks/abcb39ad1e2d54710766.js +0 -1
  130. package/assets/esri/core/workers/chunks/c2aa3b1344b42a904234.js +0 -1
  131. package/assets/esri/core/workers/chunks/cf5e4cf9b1aa37eeb6b0.js +0 -1
  132. package/assets/esri/core/workers/chunks/e63046a9567d84228644.js +0 -1
  133. package/assets/esri/core/workers/chunks/f4ec2dcdc4bbf7dbcc94.js +0 -1
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[91,1775,3354,6061,6312,8125],{61691(e,t,n){n.d(t,{G:()=>r});class r{*[Symbol.iterator](){let e=this.next();for(;e;)yield e,e=this.next()}}},76061(e,t,n){n.d(t,{S:()=>i});var r=n(61691);class i extends r.G{constructor(e){super(),this.m_iGeom=-1,this.m_aGeoms=e?e.slice():[]}next(){if(this.m_iGeom<this.m_aGeoms.length-1){const e=this.m_aGeoms[++this.m_iGeom];return this.m_aGeoms[this.m_iGeom]=null,e}return null}tock(){return!1}getGeometryID(){return this.m_iGeom}getRank(){return 1}}},65708(e,t,n){n.d(t,{a:()=>o,e:()=>s});var r=n(86211),i=n(78125);function s(e,t={}){const{unit:n}=t;let s=(0,i.fromGeometry)(e).calculateArea2D();if(s&&n){const t=(0,i.getSpatialReference)(e);if(t.isGeographic)throw new Error("Unable to convert from an angular area unit to a linear area unit.");const o=(0,r.B5)(t);o!==n&&(o?s=(0,r.oU)(s,o,n):(s=Math.sqrt(s),s*=(0,r.GA)(t),s**=2,s=(0,r.oU)(s,"square-meters",n)))}return s}const o=Object.freeze(Object.defineProperty({__proto__:null,execute:s,supportsCurves:!0},Symbol.toStringTag,{value:"Module"}))},49590(e,t,n){n.d(t,{e:()=>p,g:()=>f,l:()=>h});var r=n(86211),i=n(86742),s=n(5808);let o,a,l,c;function u(){return!!o&&(0,i.s1)()}async function h(){if(!u()){const[e]=await Promise.all([Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(3299),n.e(1550)]).then(n.bind(n,78125)),(0,i.Hh)()]);o=e.fromGeometry,a=e.fromSpatialReference,l=e.getSpatialReference,c=(0,i.fz)()}}function p(e,t={}){const{curveType:n="geodesic",unit:c}=t,u=l(e);let h=(0,i.g7)(o(e),a(u),s.O[n]);return h&&c&&(h=(0,r.oU)(h,"square-meters",c)),h}const f=Object.freeze(Object.defineProperty({__proto__:null,execute:p,isLoaded:u,load:h,get supportsCurves(){return c}},Symbol.toStringTag,{value:"Module"}))},27749(e,t,n){n.d(t,{e:()=>f,g:()=>d,l:()=>p});var r=n(86211),i=n(77085),s=n(5808);let o,a,l,c,u;function h(){return!!o&&(0,i.s1)()}async function p(){if(!h()){const[e]=await Promise.all([Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(3299),n.e(1666)]).then(n.bind(n,78125)),(0,i.Hh)()]);o=e.fromGeometry,a=e.fromSpatialReference,l=e.getSpatialReference,c=e.toGeometry,u=(0,i.fz)()}}function f(e,t,n={}){const{curveType:u="geodesic",unit:h}=n;h&&(t=(0,r.oU)(t,h,"meters"));const p=l(e);return c((0,i.g7)(o(e),t,a(p),s.O[u]),p)}const d=Object.freeze(Object.defineProperty({__proto__:null,execute:f,executeMany:function(e,t,n={}){const{curveType:u="geodesic",unit:h}=n;h&&(t=(0,r.oU)(t,h,"meters"));const p=e.map(o),f=l(e);return(0,i.zo)(p,t,a(f),s.O[u]).map(e=>c(e,f))},isLoaded:h,load:p,get supportsCurves(){return u}},Symbol.toStringTag,{value:"Module"}))},39663(e,t,n){n.d(t,{e:()=>p,g:()=>f,l:()=>h});var r=n(86211),i=n(35223),s=n(5808);let o,a,l,c;function u(){return!!o&&(0,i.s1)()}async function h(){if(!u()){const[e]=await Promise.all([Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(3299),n.e(1550)]).then(n.bind(n,78125)),(0,i.Hh)()]);o=e.fromGeometry,a=e.fromSpatialReference,l=e.getSpatialReference,c=(0,i.fz)()}}function p(e,t={}){const{curveType:n="geodesic",unit:c}=t,u=l(e);let h=(0,i.g7)(o(e),a(u),s.O[n]);return h&&c&&(h=(0,r.oU)(h,"meters",c)),h}const f=Object.freeze(Object.defineProperty({__proto__:null,execute:p,isLoaded:u,load:h,get supportsCurves(){return c}},Symbol.toStringTag,{value:"Module"}))},7817(e,t,n){n.d(t,{e:()=>s,l:()=>a,s:()=>o});var r=n(86211),i=n(78125);function s(e,t={}){const{unit:n}=t;let s=(0,i.fromGeometry)(e).calculateLength2D();if(s&&n){const t=(0,i.getSpatialReference)(e);s=(0,r.PQ)(s,t,n)}return s}const o=!0,a=Object.freeze(Object.defineProperty({__proto__:null,execute:s,supportsCurves:o},Symbol.toStringTag,{value:"Module"}))},10222(e,t,n){n.d(t,{e:()=>s,s:()=>a});var r=n(81150),i=n(78125);function s(e){const t=(0,i.getSpatialReference)(e);return(0,i.toGeometry)((0,r.g7)((0,i.fromGeometry)(e),(0,i.fromSpatialReference)(t),!1),t)}const o=(0,r.fz)(),a=Object.freeze(Object.defineProperty({__proto__:null,execute:s,executeMany:function(e){const t=e.map(i.fromGeometry),n=(0,i.getSpatialReference)(e);return(0,r.zo)(t,(0,i.fromSpatialReference)(n),!1).map(e=>(0,i.toGeometry)(e,n))},isSimple:function(e){return(0,r.Pg)((0,i.fromGeometry)(e),(0,i.fromSpatialReference)((0,i.getSpatialReference)(e)),!1)},supportsCurves:o},Symbol.toStringTag,{value:"Module"}))},73354(e,t,n){n.d(t,{a:()=>p,b:()=>l,c:()=>a,d:()=>s,e:()=>f,f:()=>h,l:()=>u,n:()=>d,t:()=>o});var r=n(40876),i=(n(44208),n(72727));function s(e,t,n){o(e.typedBuffer,t.typedBuffer,n,e.typedBufferStride,t.typedBufferStride)}function o(e,t,n,r=3,s=r){const o=(0,i.k)(e.length,r,3),a=(0,i.k)(t.length,s,3),l=Math.min(o,a),c=n[0],u=n[1],h=n[2],p=n[4],f=n[5],d=n[6],m=n[8],g=n[9],y=n[10],v=n[12],w=n[13],M=n[14];let x=0,C=0;for(let n=0;n<l;n++){const n=t[x],i=t[x+1],o=t[x+2];e[C]=c*n+p*i+m*o+v,e[C+1]=u*n+f*i+g*o+w,e[C+2]=h*n+d*i+y*o+M,x+=s,C+=r}return e}function a(e,t,n){l(e.typedBuffer,t.typedBuffer,n,e.typedBufferStride,t.typedBufferStride)}function l(e,t,n,r=3,s=r){const o=(0,i.k)(e.length,r,3),a=(0,i.k)(t.length,s,3),l=Math.min(o,a),c=n[0],u=n[1],h=n[2],p=n[3],f=n[4],d=n[5],m=n[6],g=n[7],y=n[8];let v=0,w=0;for(let n=0;n<l;n++){const n=t[v],i=t[v+1],o=t[v+2];e[w]=c*n+p*i+m*o,e[w+1]=u*n+f*i+g*o,e[w+2]=h*n+d*i+y*o,v+=s,w+=r}}function c(e,t,n,r=3,i=r){const s=Math.min(e.length/r,t.length/i);let o=0,a=0;for(let l=0;l<s;l++)e[a]=n*t[o],e[a+1]=n*t[o+1],e[a+2]=n*t[o+2],o+=i,a+=r;return e}function u(e,t,n,r){h(e.typedBuffer,t.typedBuffer,n,r,e.typedBufferStride,t.typedBufferStride)}function h(e,t,n,i,s=3,o=s){const a=Math.min(e.length/s,t.length/o);let l=0,c=0;const u=1/r.Tf;for(let r=0;r<a;r++)e[c]=i*(n*t[l])**u,e[c+1]=i*(n*t[l+1])**u,e[c+2]=i*(n*t[l+2])**u,l+=o,c+=s}function p(e,t,n,r=3,s=r){const o=(0,i.k)(e.length,r,3),a=(0,i.k)(t.length,s,3),l=Math.min(o,a);let c=0,u=0;for(let i=0;i<l;i++)e[u]=t[c]+n[0],e[u+1]=t[c+1]+n[1],e[u+2]=t[c+2]+n[2],c+=s,u+=r;return e}function f(e,t){d(e.typedBuffer,t.typedBuffer,e.typedBufferStride,t.typedBufferStride)}function d(e,t,n=3,r=n){const i=Math.min(e.length/n,t.length/r);let s=0,o=0;for(let a=0;a<i;a++){const i=t[s],a=t[s+1],l=t[s+2],c=i*i+a*a+l*l;if(c>0){const t=1/Math.sqrt(c);e[o]=t*i,e[o+1]=t*a,e[o+2]=t*l}s+=r,o+=n}}Object.freeze(Object.defineProperty({__proto__:null,linearToSRGB:h,linearToSRGBView:u,normalize:d,normalizeView:f,scale:c,scaleView:function(e,t,n){c(e.typedBuffer,t.typedBuffer,n,e.typedBufferStride,t.typedBufferStride)},shiftRight:function(e,t,n){const r=Math.min(e.count,t.count),i=e.typedBuffer,s=e.typedBufferStride,o=t.typedBuffer,a=t.typedBufferStride;let l=0,c=0;for(let e=0;e<r;e++)i[c]=o[l]>>n,i[c+1]=o[l+1]>>n,i[c+2]=o[l+2]>>n,l+=a,c+=s},transformMat3:l,transformMat3View:a,transformMat4:o,transformMat4View:s,translate:p},Symbol.toStringTag,{value:"Module"}))},69540(e,t,n){n.d(t,{OU:()=>u,Pw:()=>h});var r=n(5482),i=n(69622),s=(n(44208),n(4718)),o=(n(53966),n(97768)),a=n(88620),l=n(64108);const c=Symbol("ClonableMixin"),u=e=>{var t;const n=e;let i=class extends n{constructor(){super(...arguments),this[t]=!0}static{t=c}clone(e){const t=(0,a.oY)(this);(0,o.Lw)(t,"unable to clone instance of non-accessor class");const n=t.metadata,r=t.store,i={},l=new Map;for(const t in n){const o=n[t],a=r?.originOf(t),c=o.clonable;if(o.readOnly||!1===c||7!==a&&0!==a&&5!==a&&4!==a)continue;const u=this[t];let h=null;if("function"==typeof c)h=c(u,e);else if("reference"===c)h=u;else if(h=(0,s.TU)(u,e),null!=u&&null==h)continue;0===a?l.set(t,h):i[t]=h}const c=new(0,Object.getPrototypeOf(this).constructor)(i);if(l.size){const e=(0,a.oY)(c)?.store;if(e)for(const[t,n]of l)e.set(t,n,0)}return c}};return i=(0,r.Cg)([(0,l.$)("esri.core.Clonable")],i),i},h=u(i.A)},4902(e,t,n){n.d(t,{s:()=>o});var r=n(5482),i=n(64108);let s=0;const o=e=>{const t=e;let n=class extends t{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:Date.now().toString(16)+"-object-"+s++})}};return n=(0,r.Cg)([(0,i.$)("esri.core.Identifiable")],n),n};o(class{})},82534(e,t,n){function r(){return[0,0,0,1]}function i(e){return[e[0],e[1],e[2],e[3]]}n.d(t,{o8:()=>i,vt:()=>r,zK:()=>s});const s=[0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:s,clone:i,create:r,fromValues:function(e,t,n,r){return[e,t,n,r]}},Symbol.toStringTag,{value:"Module"}))},48163(e,t,n){function r(){return[0,0]}function i(e){return[e[0],e[1]]}function s(e,t){return[e,t]}function o(){return s(1,1)}function a(){return s(1,0)}function l(){return s(0,1)}n.d(t,{Un:()=>c,fA:()=>s,o8:()=>i,vt:()=>r});const c=o(),u=a(),h=l();Object.freeze(Object.defineProperty({__proto__:null,ONES:c,UNIT_X:u,UNIT_Y:h,ZEROS:[0,0],clone:i,create:r,freeze:function(e,t){return[e,t]},fromArray:function(e,t=[0,0]){const n=Math.min(2,e.length);for(let r=0;r<n;++r)t[r]=e[r];return t},fromValues:s,ones:o,unitX:a,unitY:l,zeros:function(){return[0,0]}},Symbol.toStringTag,{value:"Module"}))},35522(e,t,n){n.d(t,{$A:()=>_,Bw:()=>s,C:()=>o,Cc:()=>A,DI:()=>C,Il:()=>k,Io:()=>v,Ln:()=>y,Om:()=>T,Qr:()=>h,Re:()=>c,S8:()=>b,T9:()=>m,WQ:()=>l,Z0:()=>S,_S:()=>f,aI:()=>O,ei:()=>R,gL:()=>P,hG:()=>w,hZ:()=>a,hs:()=>g,jb:()=>D,jk:()=>d,lo:()=>L,lw:()=>u,m3:()=>M,oW:()=>I,t2:()=>Z,tn:()=>p,uE:()=>U,xg:()=>N,ze:()=>x});var r=n(51850),i=n(34304);function s(e){const t=e[0],n=e[1],r=e[2];return Math.sqrt(t*t+n*n+r*r)}function o(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function a(e,t,n,r){return e[0]=t,e[1]=n,e[2]=r,e}function l(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e[2]=t[2]+n[2],e}function c(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e[2]=t[2]-n[2],e}function u(e,t,n){return e[0]=t[0]*n[0],e[1]=t[1]*n[1],e[2]=t[2]*n[2],e}function h(e,t,n){return e[0]=t[0]/n[0],e[1]=t[1]/n[1],e[2]=t[2]/n[2],e}function p(e,t){return e[0]=Math.abs(t[0]),e[1]=Math.abs(t[1]),e[2]=Math.abs(t[2]),e}function f(e,t){return e[0]=Math.sign(t[0]),e[1]=Math.sign(t[1]),e[2]=Math.sign(t[2]),e}function d(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e[2]=Math.min(t[2],n[2]),e}function m(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e[2]=Math.max(t[2],n[2]),e}function g(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e}function y(e,t,n,r){return e[0]=t[0]+n[0]*r,e[1]=t[1]+n[1]*r,e[2]=t[2]+n[2]*r,e}function v(e,t){const n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2];return Math.sqrt(n*n+r*r+i*i)}function w(e,t){const n=t[0]-e[0],r=t[1]-e[1],i=t[2]-e[2];return n*n+r*r+i*i}function M(e){const t=e[0],n=e[1],r=e[2];return t*t+n*n+r*r}function x(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e}function C(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e}function b(e,t){const n=t[0],r=t[1],i=t[2];let s=n*n+r*r+i*i;return s>0&&(s=1/Math.sqrt(s),e[0]=t[0]*s,e[1]=t[1]*s,e[2]=t[2]*s),e}function T(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function _(e,t,n){const r=t[0],i=t[1],s=t[2],o=n[0],a=n[1],l=n[2];return e[0]=i*l-s*a,e[1]=s*o-r*l,e[2]=r*a-i*o,e}function A(e,t,n,r){const i=t[0],s=t[1],o=t[2];return e[0]=i+r*(n[0]-i),e[1]=s+r*(n[1]-s),e[2]=o+r*(n[2]-o),e}function S(e,t,n){const r=t[0],i=t[1],s=t[2];return e[0]=n[0]*r+n[4]*i+n[8]*s+n[12],e[1]=n[1]*r+n[5]*i+n[9]*s+n[13],e[2]=n[2]*r+n[6]*i+n[10]*s+n[14],e}function R(e,t,n){const r=t[0],i=t[1],s=t[2];return e[0]=r*n[0]+i*n[3]+s*n[6],e[1]=r*n[1]+i*n[4]+s*n[7],e[2]=r*n[2]+i*n[5]+s*n[8],e}function P(e,t,n){const r=n[0],i=n[1],s=n[2],o=n[3],a=t[0],l=t[1],c=t[2],u=i*c-s*l,h=s*a-r*c,p=r*l-i*a,f=i*p-s*h,d=s*u-r*p,m=r*h-i*u,g=2*o;return e[0]=a+u*g+2*f,e[1]=l+h*g+2*d,e[2]=c+p*g+2*m,e}const z=(0,r.vt)(),E=(0,r.vt)();function Z(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]}function O(e,t){if(e===t)return!0;const n=e[0],r=e[1],s=e[2],o=t[0],a=t[1],l=t[2],c=(0,i.FD)();return Math.abs(n-o)<=c*Math.max(1,Math.abs(n),Math.abs(o))&&Math.abs(r-a)<=c*Math.max(1,Math.abs(r),Math.abs(a))&&Math.abs(s-l)<=c*Math.max(1,Math.abs(s),Math.abs(l))}function I(e,t,n){const r=n[0]-t[0],i=n[1]-t[1],s=n[2]-t[2];let o=r*r+i*i+s*s;return o>0?(o=1/Math.sqrt(o),e[0]=r*o,e[1]=i*o,e[2]=s*o,e):(e[0]=0,e[1]=0,e[2]=0,e)}const D=c,V=u,j=h,N=v,L=w,k=s,U=M;Object.freeze(Object.defineProperty({__proto__:null,abs:p,add:l,angle:function(e,t){b(z,e),b(E,t);const n=T(z,E);return n>1?0:n<-1?Math.PI:Math.acos(n)},bezier:function(e,t,n,r,i,s){const o=1-s,a=o*o,l=s*s,c=a*o,u=3*s*a,h=3*l*o,p=l*s;return e[0]=t[0]*c+n[0]*u+r[0]*h+i[0]*p,e[1]=t[1]*c+n[1]*u+r[1]*h+i[1]*p,e[2]=t[2]*c+n[2]*u+r[2]*h+i[2]*p,e},ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e},clamp:function(e,t=0,n=1){return e[0]=Math.min(Math.max(e[0],t),n),e[1]=Math.min(Math.max(e[1],t),n),e[2]=Math.min(Math.max(e[2],t),n),e},copy:o,cross:_,crossAndNormalize:function(e,t,n){const r=t[0],i=t[1],s=t[2],o=n[0],a=n[1],l=n[2],c=i*l-s*a,u=s*o-r*l,h=r*a-i*o,p=Math.sqrt(c*c+u*u+h*h);return e[0]=c/p,e[1]=u/p,e[2]=h/p,e},direction:I,dist:N,distance:v,div:j,divide:h,dot:T,equals:O,exactEquals:Z,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e},hermite:function(e,t,n,r,i,s){const o=s*s,a=o*(2*s-3)+1,l=o*(s-2)+s,c=o*(s-1),u=o*(3-2*s);return e[0]=t[0]*a+n[0]*l+r[0]*c+i[0]*u,e[1]=t[1]*a+n[1]*l+r[1]*c+i[1]*u,e[2]=t[2]*a+n[2]*l+r[2]*c+i[2]*u,e},inverse:C,len:k,length:s,lerp:A,max:m,min:d,mul:V,multiply:u,negate:x,normalize:b,random:function(e,t=1){const n=i.Ov,r=2*n()*Math.PI,s=2*n()-1,o=Math.sqrt(1-s*s)*t;return e[0]=Math.cos(r)*o,e[1]=Math.sin(r)*o,e[2]=s*t,e},rotateX:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[0],s[1]=i[1]*Math.cos(r)-i[2]*Math.sin(r),s[2]=i[1]*Math.sin(r)+i[2]*Math.cos(r),e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},rotateY:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[2]*Math.sin(r)+i[0]*Math.cos(r),s[1]=i[1],s[2]=i[2]*Math.cos(r)-i[0]*Math.sin(r),e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},rotateZ:function(e,t,n,r){const i=[],s=[];return i[0]=t[0]-n[0],i[1]=t[1]-n[1],i[2]=t[2]-n[2],s[0]=i[0]*Math.cos(r)-i[1]*Math.sin(r),s[1]=i[0]*Math.sin(r)+i[1]*Math.cos(r),s[2]=i[2],e[0]=s[0]+n[0],e[1]=s[1]+n[1],e[2]=s[2]+n[2],e},round:function(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e},scale:g,scaleAndAdd:y,set:a,sign:f,sqrDist:L,sqrLen:U,squaredDistance:w,squaredLength:M,str:function(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"},sub:D,subtract:c,transformMat3:R,transformMat4:S,transformQuat:P},Symbol.toStringTag,{value:"Module"}))},17799(e,t,n){n.d(t,{T9:()=>a,d_:()=>i,gT:()=>s});var r=n(86211);function i(e,t){return{type:(0,r.t$)(t),value:e,unit:t}}function s(e,t){return{type:(0,r.t$)(t),value:e,unit:t}}function o(e,t,n="arithmetic"){return{type:(0,r.t$)(t),value:e,unit:t,rotationType:n}}function a(e,t){return null==e?t:null==t||e.value>(0,r.oU)(t.value,t.unit,e.unit)?e:t}i(0,"meters"),s(0,"square-meters"),o(0,"radians"),o(0,"degrees"),o(0,"degrees","geographic")},36708(e,t,n){n.d(t,{C_:()=>p,OH:()=>m,Vh:()=>g,on:()=>h,pc:()=>y,wB:()=>l,z7:()=>c});var r=n(37955),i=n(36563),s=n(97768),o=n(17676),a=n(14012);function l(e,t,n={}){return u(e,t,n,f)}function c(e,t,n={}){return u(e,t,n,d)}function u(e,t,n={},r){let i=null;const o=n.once?(e,n)=>{r(e)&&((0,s.xt)(i),t(e,n))}:(e,n)=>{r(e)&&t(e,n)};if(i=(0,a.Cn)(e,o,n.sync,n.equals),n.initial){const t=e();o(t,t)}return i}function h(e,t,n,o={}){let a=null,c=null,u=null;function h(){a&&c&&(c.remove(),o.onListenerRemove?.(a),a=null,c=null)}function p(e){o.once&&o.once&&(0,s.xt)(u),n(e)}const f=l(e,(e,n)=>{h(),(0,r.wb)(e)&&(a=e,c=(0,r.on)(e,t,p),o.onListenerAdd?.(e))},{sync:o.sync,initial:!0});return u=(0,i.hA)(()=>{f.remove(),h()}),u}function p(e,t){return function(e,t,n){if((0,o.G4)(n))return Promise.reject((0,o.NK)());const r=e();if(t?.(r))return Promise.resolve(r);let a=null;function l(){a=(0,s.xt)(a)}return new Promise((r,s)=>{a=(0,i.vE)([(0,o.u7)(n,()=>{l(),s((0,o.NK)())}),u(e,e=>{l(),r(e)},{sync:!1,once:!0},t??f)])})}(e,d,t)}function f(e){return!0}function d(e){return!!e}n(80559);const m={sync:!0},g={initial:!0},y={sync:!0,initial:!0}},35982(e,t,n){n.d(t,{B:()=>l});var r=n(4576),i=n(36563),s=n(53966),o=n(17676),a=n(83027);class l{constructor(e,t,n,r,i={}){this._mainMethod=t,this._transferLists=n,this._listeners=[],this._promise=(0,a.h)(e,{...i,schedule:r}).then(e=>{if(void 0===this._thread){this._thread=e,this._promise=null,i.hasInitialize&&this.broadcast({},"initialize");for(const e of this._listeners)this._connectListener(e)}else e.close()}),this._promise.catch(t=>s.A.getLogger("esri.core.workers.WorkerHandle").error(`Failed to initialize ${e} worker: ${t}`))}on(e,t){const n={removed:!1,eventName:e,callback:t,threadHandle:null};return this._listeners.push(n),this._connectListener(n),(0,i.hA)(()=>{n.removed=!0,(0,r.TF)(this._listeners,n),this._thread&&null!=n.threadHandle&&n.threadHandle.remove()})}[Symbol.dispose](){this.destroy()}destroy(){this._thread&&(this._thread.close(),this._thread=null),this._promise=null,this._listeners.length=0,this._transferLists={}}invoke(e,t,n){return this.invokeMethod(this._mainMethod,e,t,n)}invokeMethod(e,t,n,r){if(this._thread){const i=this._transferLists[e],s=i?i(t):[];return this._thread.invoke(e,t,{transferList:s,signal:n,jobPriority:r})}return this._promise?this._promise.then(()=>((0,o.Te)(n),this.invokeMethod(e,t,n))):Promise.reject(null)}broadcast(e,t){return this._thread?Promise.all(this._thread.broadcast(t,e)).then(c):this._promise?this._promise.then(()=>this.broadcast(e,t)):Promise.reject()}get promise(){return this._promise}_connectListener(e){this._thread&&this._thread.on(e.eventName,e.callback).then(t=>{e.removed||(e.threadHandle=t)})}}function c(){}},87992(e,t,n){n.d(t,{JR:()=>_,ME:()=>C,MY:()=>A,NO:()=>x,Nh:()=>T,V2:()=>E,_s:()=>Z,e6:()=>I,gh:()=>b,tr:()=>V,uX:()=>g});var r=n(5482),i=n(69397),s=n(16930),o=(n(70328),n(19419)),a=n(60408),l=n(21325),c=n(513),u=n(50954),h=n(79567),p=n(52006),f=n(49663),d=n(46068),m=n(92722);class g{constructor({type:e,spatialReference:t,vertexCount:n,vertexXY:r,vertexZ:i,vertexM:s,partCount:o,partOffsets:a,partFlags:l,segmentFlags:c,segmentIndices:u,segmentParams:h,segmentCountArc:p,segmentCountBezier:f}){this.segmentCountArc=0,this.segmentCountBezier=0,this.type=e,this.spatialReference=t,this.vertexCount=n,this.vertexXY=r,this.vertexZ=i,this.vertexM=s,this.partCount=o,this.partOffsets=a,this.partFlags=l,this.segmentFlags=c,this.segmentIndices=u,this.segmentParams=h,this.segmentCountArc=p,this.segmentCountBezier=f}get segmentParamCount(){return 10*this.segmentCountArc+4*this.segmentCountBezier}get segmentCountLine(){const{segmentCount:e,segmentCountArc:t,segmentCountBezier:n}=this;return e&&e-t-n}get segmentCount(){return"polyline"===this.type?this.vertexCount-this.partCount:"polygon"===this.type?this.vertexCount:0}get hasZ(){return null!=this.vertexZ}get hasM(){return null!=this.vertexM}hasCurves(){return null!=this.segmentFlags}isMultipart(){return"polyline"===this.type||"polygon"===this.type}get usedMemory(){function e(e){return e?i.Ul+e.byteLength:0}return e(this.vertexXY)+e(this.vertexZ)+e(this.vertexM)+e(this.partOffsets)+e(this.partFlags)+e(this.segmentFlags)+e(this.segmentIndices)+e(this.segmentParams)}clone(){const{type:e,vertexCount:t,partCount:n,hasZ:r,hasM:i,segmentCountArc:s,segmentCountBezier:o}=this,a=E(e,t,n,r,i,this.hasCurves(),s,o);a.spatialReference=this.spatialReference;const{vertexXY:l,vertexZ:c,vertexM:u}=this;if(a.vertexXY.set(l.subarray(0,2*t),0),a.vertexZ?.set(c.subarray(0,t),0),a.vertexM?.set(u.subarray(0,t),0),this.isMultipart()){const{partOffsets:e,partFlags:t}=this;a.partFlags.set(t.subarray(0,n+1)),a.partOffsets.set(e.subarray(0,n+1))}if(this.hasCurves()){const{segmentFlags:e,segmentIndices:n,segmentParams:r,segmentParamCount:i}=this;a.segmentFlags.set(e.subarray(0,t),0),a.segmentIndices.set(n.subarray(0,t),0),a.segmentParams.set(r.subarray(0,i),0)}return a}equals(e){return this.equalsWithinTolerance(e,0)}equalsWithinTolerance(e,t){if(null==e)return!1;if(this===e)return!0;if(!(0,l.aI)(this.spatialReference,e.spatialReference))return!1;if(this.vertexCount!==e.vertexCount||this.partCount!==e.partCount)return!1;if(this.hasZ!==e.hasZ||this.hasM!==e.hasM)return!1;if(this.hasCurves()!==e.hasCurves()||this.segmentCountArc!==e.segmentCountArc||this.segmentCountBezier!==e.segmentCountBezier)return!1;const n=0===t?(e,t)=>e!==t||isNaN(e)!==isNaN(t):(e,n)=>Math.abs(e-n)>t||isNaN(e)!==isNaN(n);for(let t=0;t<this.vertexCount;++t)if(n(this.vertexXY[2*t],e.vertexXY[2*t])||n(this.vertexXY[2*t+1],e.vertexXY[2*t+1]))return!1;if(this.hasZ)for(let t=0;t<this.vertexCount;++t)if(n(this.vertexZ[t],e.vertexZ[t]))return!1;if(this.hasM)for(let t=0;t<this.vertexCount;++t)if(n(this.vertexM[t],e.vertexM[t]))return!1;for(let t=0;t<this.partCount;++t)if(this.partFlags[t]!==e.partFlags[t]||this.partOffsets[t]!==e.partOffsets[t])return!1;if(this.hasCurves()){for(let t=0;t<this.vertexCount;++t)if(this.segmentFlags[t]!==e.segmentFlags[t]||this.segmentIndices[t]!==e.segmentIndices[t])return!1;for(let t=0;t<this.segmentParamCount;++t)if(n(this.segmentParams[t],e.segmentParams[t]))return!1}return!0}get parts(){return this.isMultipart()?new y(this):[][Symbol.iterator]()}}class y{constructor(e){this.geometry=e,this.value=new v(e)}get done(){return this.value.index>=this.geometry.partCount}next(){return++this.value.index,this}[Symbol.iterator](){return this}}class v{constructor(e){this.geometry=e,this.index=-1,this._readVertex=P(e),this._segments=new w(this)}get segments(){return this._segments.reset(),this._segments}get startVertex(){return this._readVertex(this.geometry.partOffsets[this.index])}get vertexCount(){const e=this.geometry.partOffsets;return e[this.index+1]-e[this.index]}}class w{constructor(e){this._part=e,this._partStart=0,this._partEnd=0,this._isPolygon="polygon"===e.geometry.type,this.value=new M(e.geometry)}get done(){return this.value.indexOfStartVertex>this._partEnd}next(){++this.value.indexOfStartVertex;const e=this.value.indexOfStartVertex>=this._partEnd;return this.value.indexOfEndVertex=e&&this._isPolygon?this._partStart:this.value.indexOfStartVertex+1,this}[Symbol.iterator](){return this}reset(){const{index:e}=this._part,t=this._part.geometry.partOffsets;this._partStart=t[e],this._partEnd=t[e+1]-(this._isPolygon?1:2),this.value.indexOfStartVertex=this._partStart-1}}class M{constructor(e){this.geometry=e,this.indexOfStartVertex=-1,this.indexOfEndVertex=-1,this._readVertex=P(e)}get xStart(){return this.geometry.vertexXY[2*this.indexOfStartVertex]}get yStart(){return this.geometry.vertexXY[2*this.indexOfStartVertex+1]}get zStart(){return this.geometry.vertexZ[this.indexOfStartVertex]}get mStart(){return this.geometry.vertexM[this.indexOfStartVertex]}get xEnd(){return this.geometry.vertexXY[2*this.indexOfEndVertex]}get yEnd(){return this.geometry.vertexXY[2*this.indexOfEndVertex+1]}get zEnd(){return this.geometry.vertexZ[this.indexOfEndVertex]}get mEnd(){return this.geometry.vertexM[this.indexOfEndVertex]}get start(){return this._readVertex(this.indexOfStartVertex)}get end(){return this._readVertex(this.indexOfEndVertex)}get curve(){const e=this.geometry.segmentFlags?.[this.indexOfStartVertex]??1;if(1===e)return this.end;const t=this.geometry.segmentParams;let n=this.geometry.segmentIndices[this.indexOfStartVertex];if(2===e){const e=t[n++],r=t[n++],i=t[n++],s=t[n++];return{b:[this.end,[e,r],[i,s]]}}const r=t[n++],i=t[n++],s=t[n++],o=t[n++],a=t[n++],l=t[n++];n++,n++;const c=t[n++],u=t[n++];if(!Boolean(4&r)&&1===s)return{c:[this.end,[c,u]]};const h=2&r?0:1,p=1&r?0:1;return{a:[this.end,[a,l],h,p,o,i,s]}}}function x(e,t){const n={stack:[],error:void 0,hasError:!1};try{return t??=(0,o.Ie)(),(0,r.mS)(n,new S(e,["vertexZ","vertexM","spatialReference"]),!1),(0,o.bx)(t,function(e){let t;const{vertexCount:n,vertexXY:i,vertexZ:s,vertexM:a}=e,l=R(e);if(e.hasCurves()){const n={stack:[],error:void 0,hasError:!1};try{(0,r.mS)(n,new S(e,["vertexZ","vertexM"]),!1);const i=(0,o.Ie)();for(const t of e.parts){let e=t.startVertex;for(const{curve:n}of t.segments)(0,h.e)(i,e,n),e=(0,p.yP)(n)}const[s,a,c,u]=i;t={xmin:s,ymin:a,xmax:c,ymax:u,spatialReference:l}}catch(e){n.error=e,n.hasError=!0}finally{(0,r.hk)(n)}}else{let e,r,s,o;e=r=1/0,s=o=-1/0;for(let t=0;t<n;++t){const n=i[2*t],a=i[2*t+1];e=Math.min(e,n),s=Math.max(s,n),r=Math.min(r,a),o=Math.max(o,a)}t={xmin:e,ymin:r,xmax:s,ymax:o,spatialReference:l}}if(s){let e=1/0,n=-1/0;for(const t of s)e=Math.min(e,t),n=Math.max(n,t);t.zmin=e,t.zmax=n}if(a){let e=1/0,n=-1/0;for(const t of a)e=Math.min(e,t),n=Math.max(n,t);t.mmin=e,t.mmax=n}return t}(e)),t}catch(e){n.error=e,n.hasError=!0}finally{(0,r.hk)(n)}}function C(e){let t,n,r;if((0,a.fT)(e)){r="point";const{x:i,y:s,z:o,m:a}=e,l=[i,s];null!=o&&l.push(o),null!=a&&l.push(a),n=[[l]],t=1}else(0,a.U9)(e)?(r="multipoint",n=[e.points],t=e.points.length):(0,a.Rg)(e)?(r="polyline",n=e.curvePaths??e.paths,t=n.reduce((e,t)=>e+t.length,0)):(r="polygon",n=e.curveRings??e.rings,t=n.reduce((e,t)=>(0===t.length||(e+=t.length,z(t[0],(0,p.yP)(t.at(-1)))&&--e),e),0));const i=E(r,t,r.includes("point")?0:n.length,(0,a.Pv)(e),(0,a.W0)(e),(0,p.Ed)(e)),{hasZ:s,hasM:o,vertexXY:l,vertexZ:c,vertexM:u}=i;function h(e){l[2*d]=e[0],l[2*d+1]=e[1],s&&(c[d]=e[2]),o&&(u[d]=e[f]),++d}i.spatialReference=e.spatialReference??void 0;const f=i.hasZ?3:2;let d=0;if(!i.isMultipart()){if(!s&&!o){for(const[e,t]of n[0])l[2*d]=e,l[2*d+1]=t,++d;return i}for(const e of n[0])h(e);return i}const m="polygon"===r,{partOffsets:g}=i;let y=0;if(!i.hasCurves()){for(const e of n){if(g[y++]=d,0===e.length)continue;let t=e.length;if(m&&z(e[0],e.at(-1))&&--t,s||o)for(let n=0;n<t;++n)h(e[n]);else for(let n=0;n<t;++n){const[t,r]=e[n];l[2*d]=t,l[2*d+1]=r,++d}}return g[y]=d,i}function v(e){const t=w+e;if(t<=(i.segmentParams?.length??0))return;let n=t*j;n=20*Math.ceil(n/20);const r=i.segmentParams;i.segmentParams=new Float64Array(n),null!=r&&i.segmentParams.set(r)}let w=0;for(const e of n){if(i.partOffsets[y++]=d,0===e.length)continue;const t=e[0];let n=t;for(let t=1;t<e.length;++t){const r=e[t];h(n);const s=d-1;(0,p.wY)(r)?(v(10),++i.segmentCountArc,w=Z(n,r,i,s,w),n=r.a[0]):(0,p.DA)(r)?(v(10),++i.segmentCountArc,w=O(n,r,i,s,w),n=r.a[0]):(0,p.aO)(r)?(v(10),++i.segmentCountArc,w=I(n,r,i,s,w),n=r.c[0]):(0,p.n1)(r)?(v(4),++i.segmentCountBezier,w=V(0,r,i,s,w),n=r.b[0]):n=r}m&&z(t,n)||h(n)}return i.partOffsets[y]=d,i}function b(e){const t=P(e),{vertexCount:n,partCount:r,hasZ:i,hasM:s}=e,o=R(e);if("point"===e.type){const[t,n]=e.vertexXY,r=e.vertexZ?.[0],i=e.vertexM?.[0];return{x:t,y:n,z:r,m:i,spatialReference:o}}let a=0;if("multipoint"===e.type){const e=[];for(;a<n;)e.push(t(a++));return{points:e,spatialReference:o,hasZ:i,hasM:s}}const l="polygon"===e.type;if(!e.hasCurves()){const n=new Array;for(let i=0;i<r;++i){const r=e.partOffsets[i+1],s=new Array;for(;a<r;)s.push(t(a++));l&&s.length>0&&s.push(s[0]),n.push(s)}return l?{rings:n,hasZ:i,hasM:s,spatialReference:o}:{paths:n,hasZ:i,hasM:s,spatialReference:o}}const c=new Array;for(const{segments:t,startVertex:n}of e.parts){const e=[n];for(const{curve:n}of t)e.push(n);c.push(e)}return l?{rings:[],curveRings:c,hasZ:i,hasM:s,spatialReference:o}:{paths:[],curvePaths:c,hasZ:i,hasM:s,spatialReference:o}}function T(e,{lengths:t,coords:n,hasZ:r,hasM:i},s){const o=e.includes("point")?0:t.length,a="polygon"===e,l="point"===e?1:t.reduce((e,t)=>e+t,0)-(a?o:0);r??=!1,i??=!1;const c=E(e,l,o,r,i,!1,0,0);if(c.spatialReference=s??void 0,!c.isMultipart()){for(let e=0,t=0;e<l;++e)c.vertexXY[2*e]=n[t++],c.vertexXY[2*e+1]=n[t++],r&&(c.vertexZ[e]=n[t++]),i&&(c.vertexM[e]=n[t++]);return c}const u=2+Number(r)+Number(i);let h=0,p=0;c.partOffsets[0]=0;for(const e of t){const t=c.partOffsets[p],s=t+e-Number(a);c.partOffsets[++p]=s;for(let e=t;e<s;++e)c.vertexXY[2*e]=n[h++],c.vertexXY[2*e+1]=n[h++],r&&(c.vertexZ[e]=n[h++]),i&&(c.vertexM[e]=n[h++]);a&&(h+=u)}return c}function _({type:e,vertexCount:t,vertexXY:n,vertexZ:r,vertexM:i,partCount:s,partOffsets:o,hasZ:a,hasM:l}){const c=new m.A([],[],a,l);s=Math.max(s,1);const u="polygon"===e;let h=0;for(let e=0;e<s;++e){const s=o?.[e+1]??t,p=c.coords.length;for(let e=h;e<s;++e)c.coords.push(n[2*e],n[2*e+1]),a&&c.coords.push(r[e]),l&&c.coords.push(i[e]);if(u){const e=h;c.coords.push(n[2*e],n[2*e+1]),a&&c.coords.push(r[e]),l&&c.coords.push(i[e])}c.lengths.push((c.coords.length-p)/c.stride),h=s}return"point"===e&&(c.lengths.length=0),c}function A(e,t){return"getSpatialReference"in e&&(t=function(e){if(null==e)return;const t=e.getText()||void 0,n=e.isCustomWkid()?0:e.getOldID();if(n<=0)return{wkt:t};let r=e.getLatestID();(r<=0||r===n)&&(r=void 0);const i=e.getVCS();if(null==i)return{wkid:n,latestWkid:r,wkt:t};const s=i.isCustomWkid()?0:i.getOldID();if(s<=0)return{wkt:t};let o=e.getLatestVerticalID();return(o<=0||o===s)&&(o=void 0),{wkid:n,wkt:t,latestWkid:r,vcsWkid:s,latestVcsWkid:o}}(e.getSpatialReference()),e=e.getGeometry()),new g({...e.toFlatGeometry(),spatialReference:t})}class S{constructor(e,t){this.target=e,this.keys=t,this.oldValues=t.map(t=>e[t]);for(const n of t)e[n]=void 0}[Symbol.dispose](){this.keys.map((e,t)=>{this.target[e]=this.oldValues[t]})}}function R({spatialReference:e}){return e instanceof s.A?e.toJSON():e}function P({vertexXY:e,vertexZ:t,vertexM:n}){return t?n?r=>[e[2*r],e[2*r+1],t[r],n[r]]:n=>[e[2*n],e[2*n+1],t[n]]:n?t=>[e[2*t],e[2*t+1],n[t]]:t=>[e[2*t],e[2*t+1]]}function z(e,t){return e.every((e,n)=>e===t[n])}function E(e,t,n,r,i,s,o,a){o??=0,a??=0;const l=new g({type:e,vertexCount:t,vertexXY:null,vertexZ:void 0,vertexM:void 0,partCount:n,partOffsets:void 0,partFlags:void 0,segmentFlags:void 0,segmentIndices:void 0,segmentParams:void 0,segmentCountArc:o,segmentCountBezier:a});let c=2*Float64Array.BYTES_PER_ELEMENT*t;r&&(c+=Float64Array.BYTES_PER_ELEMENT*t),i&&(c+=Float64Array.BYTES_PER_ELEMENT*t),l.isMultipart()&&(c+=(n+1)*Int32Array.BYTES_PER_ELEMENT,c+=(n+1)*Int8Array.BYTES_PER_ELEMENT),s&&(c+=t*Int8Array.BYTES_PER_ELEMENT,c+=t*Int32Array.BYTES_PER_ELEMENT,c+=l.segmentParamCount*Float64Array.BYTES_PER_ELEMENT);const u=new ArrayBuffer(c);let h=0;return l.vertexXY=new Float64Array(u,h,2*t),h+=l.vertexXY.byteLength,r&&(l.vertexZ=new Float64Array(u,h,t),h+=l.vertexZ.byteLength),i&&(l.vertexM=new Float64Array(u,h,t),h+=l.vertexM.byteLength),s&&(l.segmentParams=new Float64Array(u,h,l.segmentParamCount),h+=l.segmentParams.byteLength,l.segmentIndices=new Int32Array(u,h,t),l.segmentIndices.fill(N),h+=l.segmentIndices.byteLength),l.isMultipart()&&(l.partOffsets=new Int32Array(u,h,n+1),h+=l.partOffsets.byteLength,l.partFlags=new Int8Array(u,h,n+1),h+=l.partFlags.byteLength,"polygon"===l.type&&l.partFlags.subarray(0,n).fill(1)),s&&(l.segmentFlags=new Int8Array(u,h,t),l.segmentFlags.fill(1),h+=l.segmentFlags.byteLength),l}function Z(e,t,{segmentFlags:n,segmentIndices:r,segmentParams:i},s,o){n[s]=4,r[s]=o;const[a,[l,c],u,h,p,f,m]=t.a;let g=4;h||(g|=1),u||(g|=2);const y=(0,d.SW)(e,t),[v,w]=(0,d.Uk)(y,.5);return i[o++]=g,i[o++]=f,i[o++]=m,i[o++]=p,i[o++]=l,i[o++]=c,i[o++]=y.u2-y.u1,i[o++]=y.u1,i[o++]=v,i[o++]=w,o}function O(e,t,{segmentFlags:n,segmentIndices:r,segmentParams:i},s,o){n[s]=4,r[s]=o;const a=(0,f.i)(e,t);return D(a,4,...(0,c.mq)(a,.5),i,o)}function I(e,t,{segmentFlags:n,segmentIndices:r,segmentParams:i},s,o){return n[s]=4,r[s]=o,D((0,u.pM)(e,t),0,...t.c[1],i,o)}function D(e,t,n,r,i,s){const{cx:o,cy:a,thetaStart:l,thetaEnd:c,radius:u}=e;return l>c||(t|=1),Math.abs(c-l)<=Math.PI||(t|=2),i[s++]=t,i[s++]=u,i[s++]=1,i[s++]=0,i[s++]=o,i[s++]=a,i[s++]=c-l,i[s++]=l,i[s++]=n,i[s++]=r,s}function V(e,{b:[t,[n,r],[i,s]]},{segmentFlags:o,segmentIndices:a,segmentParams:l},c,u){return o[c]=2,a[c]=u,l[u++]=n,l[u++]=r,l[u++]=i,l[u++]=s,u}const j=1.61803,N=-1},54239(e,t,n){n.d(t,{A:()=>g});var r,i=n(5482),s=n(4576),o=n(66552),a=n(25482),l=n(86211),c=n(67076),u=n(91429),h=n(43937),p=n(36005);const f=(0,o.O)()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),d=f.jsonValues.slice();(0,s.Xy)(d,"orthometric");const m=(0,o.O)()({meter:"meters",foot:"feet","us-foot":"us-feet","clarke-foot":"clarke-feet","clarke-yard":"clarke-yards","clarke-link":"clarke-links","sears-yard":"sears-yards","sears-foot":"sears-feet","sears-chain":"sears-chains","benoit-1895-b-chain":"benoit-1895-b-chains","indian-yard":"indian-yards","indian-1937-yard":"indian-1937-yards","gold-coast-foot":"gold-coast-feet","sears-1922-truncated-chain":"sears-1922-truncated-chains","50-kilometers":"50-kilometers","150-kilometers":"150-kilometers"});let g=r=class extends a.o{constructor(e){super(e),this.heightModel="gravity-related-height",this.heightUnit="meters",this.vertCRS=null}writeHeightModel(e,t,n){return f.write(e,t,n)}readHeightModel(e,t,n){return f.read(e)||(n?.messages&&n.messages.push(function(e,t){return new c.A("height-model:unsupported",`Height model of value '${e}' is not supported`,t)}(e,{context:n})),null)}readHeightUnit(e,t,n){return m.read(e)||(n?.messages&&n.messages.push(y(e,{context:n})),null)}readHeightUnitService(e,t,n){return(0,l.LA)(e)||m.read(e)||(n?.messages&&n.messages.push(y(e,{context:n})),null)}readVertCRS(e,t){return t.vertCRS||t.ellipsoid||t.geoid}clone(){return new r({heightModel:this.heightModel,heightUnit:this.heightUnit,vertCRS:this.vertCRS})}equals(e){return!!e&&(this===e||this.heightModel===e.heightModel&&this.heightUnit===e.heightUnit&&this.vertCRS===e.vertCRS)}static deriveUnitFromSR(e,t){const n=(0,l.k1)(t);return new r({heightModel:e.heightModel,heightUnit:n??void 0,vertCRS:e.vertCRS})}write(e,t){return t={origin:"web-scene",...t},super.write(e,t)}static fromJSON(e){if(!e)return null;const t=new r;return t.read(e,{origin:"web-scene"}),t}};function y(e,t){return new c.A("height-unit:unsupported",`Height unit of value '${e}' is not supported`,t)}(0,i.Cg)([(0,u.MZ)({type:f.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:d,default:"ellipsoidal",write:{isRequired:!0}}}}})],g.prototype,"heightModel",void 0),(0,i.Cg)([(0,h.K)("web-scene","heightModel")],g.prototype,"writeHeightModel",null),(0,i.Cg)([(0,p.w)(["web-scene","service"],"heightModel")],g.prototype,"readHeightModel",null),(0,i.Cg)([(0,u.MZ)({type:m.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:m.jsonValues,write:{writer:m.write,isRequired:!0}}}}})],g.prototype,"heightUnit",void 0),(0,i.Cg)([(0,p.w)("web-scene","heightUnit")],g.prototype,"readHeightUnit",null),(0,i.Cg)([(0,p.w)("service","heightUnit")],g.prototype,"readHeightUnitService",null),(0,i.Cg)([(0,u.MZ)({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],g.prototype,"vertCRS",void 0),(0,i.Cg)([(0,p.w)("service","vertCRS",["vertCRS","ellipsoid","geoid"])],g.prototype,"readVertCRS",null),g=r=(0,i.Cg)([(0,u.$K)("esri.geometry.HeightModelInfo")],g)},86742(e,t,n){n.d(t,{Hh:()=>o,fz:()=>l,g7:()=>a,s1:()=>s});var r=n(83290);let i;function s(){return!!i&&(0,r.i)()}async function o(){if(!s()){const[e,t]=await Promise.all([Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(6859),n.e(6558)]).then(n.bind(n,6558)),Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(6061)]).then(n.bind(n,15756)).then(e=>e.aP).then(({injectPe:e})=>e),(0,r.l)()]);i=new e.OperatorGeodeticArea,t(r.p)}}function a(e,t,n){return i.execute(e,t,n,null)}function l(){return i.supportsCurves()}},77085(e,t,n){n.d(t,{Hh:()=>a,fz:()=>u,g7:()=>l,s1:()=>o,zo:()=>c});var r=n(76061),i=n(83290);let s;function o(){return!!s&&(0,i.i)()}async function a(){if(!o()){const[e,t]=await Promise.all([Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(1088)]).then(n.bind(n,31088)),Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756)]).then(n.bind(n,15756)).then(e=>e.aP).then(({injectPe:e})=>e),(0,i.l)()]);s=new e.OperatorGeodeticDensifyByLength,t(i.p)}}function l(e,t,n,r){return s.execute(e,t,n,r,null)}function c(e,t,n,i){const o=s.executeMany(new r.S(e),t,n,i,null);return Array.from(o)}function u(){return s.supportsCurves()}},35223(e,t,n){n.d(t,{Hh:()=>o,fz:()=>l,g7:()=>a,s1:()=>s});var r=n(83290);let i;function s(){return!!i&&(0,r.i)()}async function o(){if(!s()){const[e,t]=await Promise.all([Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(4167)]).then(n.bind(n,28879)),Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(6061)]).then(n.bind(n,15756)).then(e=>e.aP).then(({injectPe:e})=>e),(0,r.l)()]);i=new e.OperatorGeodeticLength,t(r.p)}}function a(e,t,n){return i.execute(e,t,n,null)}function l(){return i.supportsCurves()}},4144(e,t,n){n.d(t,{Hh:()=>a,fz:()=>u,g7:()=>l,s1:()=>o,zo:()=>c});var r=n(76061),i=n(83290);let s;function o(){return!!s&&(0,i.i)()}async function a(){if(!o()){const[e,t]=await Promise.all([Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(9192)]).then(n.bind(n,9192)),Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756)]).then(n.bind(n,15756)).then(e=>e.aP).then(({injectPe:e})=>e),(0,i.l)()]);s=new e.OperatorProject,t(i.p)}}function l(e,t){return s.execute(e,t,null)}function c(e,t){const n=s.executeMany(new r.S(e),t,null);return Array.from(n)}function u(){return s.supportsCurves()}},81150(e,t,n){n.d(t,{Pg:()=>l,fz:()=>c,g7:()=>o,zo:()=>a});var r=n(76061),i=(n(55537),n(88885),n(15756));n(95213);const s=new i.f;function o(e,t,n){return s.execute(e,t,n,null)}function a(e,t,n){const i=s.executeMany(new r.S(e),t,n,null);return Array.from(i)}function l(e,t,n){return s.isSimpleAsFeature(e,t,n,null,null)}function c(){return s.supportsCurves()}},83276(e,t,n){n.r(t),n.d(t,{execute:()=>f,executeMany:()=>d,isLoaded:()=>h,load:()=>p,supportsCurves:()=>u});var r=n(4144),i=n(17499);let s,o,a,l,c,u;function h(){return!!s&&(0,r.s1)()}async function p(){if(!h()){const[e,t]=await Promise.all([Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(3299),n.e(1666)]).then(n.bind(n,78125)),Promise.all([n.e(3661),n.e(1878),n.e(8885),n.e(5756),n.e(6129)]).then(n.bind(n,86129)),(0,r.Hh)()]);s=e.fromGeometry,o=e.fromSpatialReference,a=e.getSpatialReference,l=e.toGeometry,c=t.createProjectionTransformation,u=(0,r.fz)()}}function f(e,t,n){const u=a(e),h=c(o(u),o(t),n),p=l((0,r.g7)(s(e),h),t);return!n?.zConversionDisabled&&p?.hasZ&&(0,i.gw)([p],u,t),p}function d(e,t,n){const u=e.map(s),h=a(e),p=c(o(h),o(t),n),f=(0,r.zo)(u,p).map(e=>l(e,t));return!n?.zConversionDisabled&&f&&(0,i.gw)(f,h,t),f}},78125(e,t,n){n.r(t),n.d(t,{fromExtent:()=>g,fromGeometry:()=>m,fromMultipoint:()=>y,fromPoint:()=>v,fromPolygon:()=>w,fromPolyline:()=>M,fromPolylineUsingImportOperator:()=>x,fromSpatialReference:()=>C,getSpatialReference:()=>d,toExtent:()=>T,toGeometry:()=>b,toMultipoint:()=>_,toPoint:()=>A,toPolygon:()=>S,toPolyline:()=>R});var r=n(83661),i=(n(79187),n(55537)),s=n(95213),o=n(88885),a=n(5443),l=n(48526),c=n(86738),u=n(39829),h=n(82799),p=(n(90293),n(83299));const f="_gxVersion";function d(e){return Array.isArray(e)?e[0].spatialReference:e.spatialReference}function m(e){switch(e.type){case"point":return v(e);case"multipoint":return y(e);case"polyline":return M(e);case"polygon":return w(e);case"extent":return g(e);default:throw new Error(`Unsupported geometry type: ${e.type}`)}}function g(e){if(!e.getCacheValue(f)){const t=new s.E;t.setCoords(e.xmin,e.ymin,e.xmax,e.ymax),e.hasM&&t.setInterval(2,0,e.mmin,e.mmax),e.hasZ&&t.setInterval(1,0,e.zmin,e.zmax),e.setCacheValue(f,t)}return e.getCacheValue(f)}function y(e){if(!e.getCacheValue(f)){const t=new o.M,n=new s.P,r=e.points,i=e.hasM,a=e.hasZ,l=a?3:2;for(let e=0,s=r.length;e<s;e++){const s=r[e];n.setXYCoords(s[0],s[1]),a&&n.setZ(s[2]??0),i&&n.setM(s[l]??NaN),t.add(n)}e.setCacheValue(f,t)}return e.getCacheValue(f)}function v(e){if(!e.getCacheValue(f)){const t=new s.P;t.setXYCoords(e.x,e.y),e.hasM&&t.setM(e.m),e.hasZ&&t.setZ(e.z),e.setCacheValue(f,t)}return e.getCacheValue(f)}function w(e){if(!e.getCacheValue(f)){const{curveRings:t,hasM:n,hasZ:r,rings:i}=e,s=(0,p.fromGeometryToGXGeometry)({curveRings:t,hasM:n,hasZ:r,rings:i});e.setCacheValue(f,s)}return e.getCacheValue(f)}function M(e){if(!e.getCacheValue(f)){const{curvePaths:t,hasM:n,hasZ:r,paths:i}=e,s=(0,p.fromGeometryToGXGeometry)({curvePaths:t,hasM:n,hasZ:r,paths:i});e.setCacheValue(f,s)}return e.getCacheValue(f)}function x(e){if(!e.getCacheValue(f)){const{curvePaths:t,hasM:n,hasZ:r,paths:i}=e,s=(0,p.fromGeometryToGXGeometryUsingImportOperator)({curvePaths:t,hasM:n,hasZ:r,paths:i});e.setCacheValue(f,s)}return e.getCacheValue(f)}function C(e){return(0,p.fromSpatialReference)(e)}function b(e,t){if(e)switch(e.getGeometryType()){case i.G.enumPoint:return A(e,t);case i.G.enumEnvelope:return T(e,t);case i.G.enumMultiPoint:return _(e,t);case i.G.enumPolyline:return R(e,t);case i.G.enumPolygon:return S(e,t)}return null}function T(e,t){if(e.isEmpty())return null;const n=new a.A({xmin:e.getXMin(),ymin:e.getYMin(),xmax:e.getXMax(),ymax:e.getYMax(),spatialReference:t}),r=e.getDescription();if(r.hasM()){const t=e.queryInterval(2,0);n.mmin=t.vmin,n.mmax=t.vmax}if(r.hasZ()){const t=e.queryInterval(1,0);n.zmin=t.vmin,n.zmax=t.vmax}return n.setCacheValue(f,e),n}function _(e,t){if(e.isEmpty())return null;const n=e.getDescription(),r=n.hasM(),i=n.hasZ(),o=[],a=new s.P;for(let t=0,n=e.getPointCount();t<n;t++){e.getPointByVal(t,a);const n=[a.getX(),a.getY()];i&&n.push(a.getZ()),r&&n.push(a.getM()),o.push(n)}const c=new l.A({hasM:r,hasZ:i,points:o,spatialReference:t});return c.setCacheValue(f,e),c}function A(e,t){if(e instanceof r.P)return new c.A({x:e.x,y:e.y,spatialReference:t});if(e.isEmpty())return null;const n=new c.A({x:e.getX(),y:e.getY(),spatialReference:t}),i=e.getDescription();return i.hasM()&&(n.m=e.getM()),i.hasZ()&&(n.z=e.getZ()),n.setCacheValue(f,e),n}function S(e,t){if(e.isEmpty())return null;const n=u.A.fromJSON({...(0,p.toGeometry)(e,null),spatialReference:t});return n.setCacheValue(f,e),n}function R(e,t){if(e.isEmpty())return null;const n=h.A.fromJSON({...(0,p.toGeometry)(e,null),spatialReference:t});return n.setCacheValue(f,e),n}},5808(e,t,n){n.d(t,{O:()=>r});const r={geodesic:0,loxodrome:1,"great-elliptic":2,"normal-section":3,"shape-preserving":4}},17499(e,t,n){n.d(t,{gw:()=>o});var r=n(49186),i=n(60408),s=n(62815);function o(e,t,n){let r;for(const o of e)if(o&&(0,i.Pv)(o)&&!("vertexAttributes"in o)){if(!r){null==t.vcsWkid&&null==n.vcsWkid||l(t,n);const e="type"in o?o.type:(0,i.$B)(o);if(r=(0,s.N)(e,t,n),!r)return}r(o)}}class a extends r.A{constructor(){super("projection:z-unsupported","projection of z values is unsupported between different vertical coordinate systems")}}function l({vcsWkid:e},{vcsWkid:t}){if((e??null)!==(t??null))throw new a}},72727(e,t,n){function r(e,t,n){if(t<=0)return 0;const r=e-n;return r<0?0:Math.floor(r/t)+1}n.d(t,{k:()=>r}),n(53966)},27921(e,t,n){n.d(t,{$Q:()=>M,C:()=>a,Cr:()=>u,O_:()=>c,Qj:()=>l,T7:()=>v,Tj:()=>w,lU:()=>h,mN:()=>x,vE:()=>C,vt:()=>o});var r=n(34727),i=n(35522),s=n(51850);function o(e=b){return[e[0],e[1],e[2],e[3]]}function a(e,t){return function(e,t,n,r,i=o()){return i[0]=e,i[1]=t,i[2]=n,i[3]=r,i}(t[0],t[1],t[2],t[3],e)}function l(e){return e}function c(e,t,n){const r=t[0]*t[0]+t[1]*t[1]+t[2]*t[2],i=Math.abs(r-1)>1e-5&&r>1e-12?1/Math.sqrt(r):1;return n[0]=t[0]*i,n[1]=t[1]*i,n[2]=t[2]*i,n[3]=-(n[0]*e[0]+n[1]*e[1]+n[2]*e[2]),n}function u(e,t,n,r=o()){const i=n[0]-t[0],s=n[1]-t[1],a=n[2]-t[2],l=e[0]-t[0],c=e[1]-t[1],u=e[2]-t[2],h=s*u-a*c,p=a*l-i*u,f=i*c-s*l,d=h*h+p*p+f*f,m=Math.abs(d-1)>1e-5&&d>1e-12?1/Math.sqrt(d):1;return r[0]=h*m,r[1]=p*m,r[2]=f*m,r[3]=-(r[0]*e[0]+r[1]*e[1]+r[2]*e[2]),r}function h(e,t,n,r=0,s=Math.floor(n*(1/3)),o=Math.floor(n*(2/3))){if(n<3)return!1;t(f,r);let a=s,l=!1;for(;a<n-1&&!l;)t(d,a),a++,l=!(0,i.t2)(f,d);if(!l)return!1;for(a=Math.max(a,o),l=!1;a<n&&!l;)t(m,a),a++,(0,i.Re)(g,f,d),(0,i.S8)(g,g),(0,i.Re)(y,d,m),(0,i.S8)(y,y),l=!(0,i.t2)(f,m)&&!(0,i.t2)(d,m)&&Math.abs((0,i.Om)(g,y))<p;return l?(u(f,d,m,e),!0):(0!==r||1!==s||2!==o)&&h(e,t,n,0,1,2)}n(78955),n(44280),n(32114),n(32728);const p=.99619469809,f=(0,s.vt)(),d=(0,s.vt)(),m=(0,s.vt)(),g=(0,s.vt)(),y=(0,s.vt)();function v(e,t,n){return function(e){return 0===e||1===e}(C(e,t.origin,t.vector,0,n))}function w(e,t){return x(e,t)>=0}function M(e,t){const n=(0,i.Om)(e,t.ray.direction),r=-x(e,t.ray.origin);if(r<0&&n>=0)return!1;if(n>-1e-6&&n<1e-6)return r>0;if((r<0||n<0)&&!(r<0&&n<0))return!0;const s=r/n;return n>0?s<t.c1&&(t.c1=s):s>t.c0&&(t.c0=s),t.c0<=t.c1}function x(e,t){return(0,i.Om)(e,t)+e[3]}function C(e,t,n,s,o){const a=(0,i.Om)(e,n),l=x(e,t);if(0===a)return l>=0?2:3;let c=-l/a;return 1&s&&(c=(0,r.qE)(c,0,1)),!(4&s)&&c<0||!(8&s)&&c>1?l>=0?2:3:((0,i.WQ)(o,t,(0,i.hs)(o,n,c)),l>=0?0:1)}const b=[0,0,1,0]},44280(e,t,n){n.d(t,{g7:()=>a,gr:()=>o});var r=n(34727),i=n(35522),s=n(51850);function o(e,t){return(0,i.Om)(e,t)/(0,i.Bw)(e)}function a(e,t){const n=(0,i.Om)(e,t)/((0,i.Bw)(e)*(0,i.Bw)(t));return-(0,r.XM)(n)}(0,s.vt)(),(0,s.vt)()},32114(e,t,n){n.d(t,{Rc:()=>f,J8:()=>d,rq:()=>h,Km:()=>p}),n(44208);var r=n(26390),i=n(29242),s=n(9093),o=n(82534),a=n(48163),l=n(51850),c=n(91829);class u{constructor(e){this._create=e,this._items=new Array,this._itemsPtr=0}get(){return 0===this._itemsPtr&&(0,r.d)(()=>this._reset()),this._itemsPtr>=this._items.length&&this._items.push(this._create()),this._items[this._itemsPtr++]}_reset(){const e=2*this._itemsPtr;this._items.length>e&&(this._items.length=e),this._itemsPtr=0}static createVec2f64(){return new u(a.vt)}static createVec3f64(){return new u(l.vt)}static createVec4f64(){return new u(c.vt)}static createMat3f64(){return new u(i.vt)}static createMat4f64(){return new u(s.vt)}static createQuatf64(){return new u(o.vt)}get test(){}}u.createVec2f64();const h=u.createVec3f64(),p=u.createVec4f64(),f=(u.createMat3f64(),u.createMat4f64()),d=u.createQuatf64()},62369(e,t,n){n.r(t),n.d(t,{default:()=>L});var r=n(5482),i=n(11254),s=n(49186),o=n(97768),a=n(25728),l=n(17676),c=n(84952),u=n(91429),h=n(54239),p=n(4146),f=n(89186),d=n(18768),m=n(16131),g=n(8303),y=n(10873),v=n(87378),w=n(35982);class M extends w.B{constructor(e=null){super("LercWorker","_decode",{_decode:e=>[e.buffer]},e,{strategy:"dedicated"}),this.schedule=e,this.ref=0}decode(e,t,n){return e&&0!==e.byteLength?this.invoke({buffer:e,options:t},n):Promise.resolve(null)}release(){--this.ref<=0&&(x.forEach((e,t)=>{e===this&&x.delete(t)}),this.destroy())}}const x=new Map;var C=n(34727),b=n(19419),T=(n(44208),n(86211)),_=n(5443),A=n(86738),S=n(16930),R=n(21325),P=n(28735),z=n(91806),E=n(87045);class Z{constructor(e){const t=Z.checkUnsupported(e);if(null!=t)throw t;const n=e;this.spatialReference=n.spatialReference,this._isWebMercator=this.spatialReference.isWebMercator,this._isGCS=(0,R.EA)(this.spatialReference),this.origin=[n.origin.x,n.origin.y],this.pixelSize=n.size[0],this.dpi=n.dpi;const r=n.lods.reduce((e,t)=>(t.level<e.minLod.level&&(e.minLod=t),e.max=Math.max(e.max,t.level),e),{minLod:n.lods[0],max:-1/0}),i=r.minLod,s=2**i.level;let o=i.resolution*s,a=i.scale*s;this.levels=new Array(r.max+1);for(let e=0;e<this.levels.length;e++)this.levels[e]={resolution:o,scale:a,tileSize:[o*n.size[0],o*n.size[1]]},o/=2,a/=2}clone(){return new Z(this.toTileInfo())}toTileInfo(){return new E.A({dpi:this.dpi,origin:new A.A({x:this.origin[0],y:this.origin[1],spatialReference:this.spatialReference}),size:[this.pixelSize,this.pixelSize],spatialReference:this.spatialReference,lods:this.levels.map((e,t)=>new z.A({level:t,scale:e.scale,resolution:e.resolution}))})}getExtent(e,t,n,r){const i=this.levels[e],s=i.tileSize[0],o=i.tileSize[1];r[0]=this.origin[0]+n*s,r[2]=this.origin[0]+(n+1)*s,r[3]=this.origin[1]-t*o,r[1]=this.origin[1]-(t+1)*o}convertExtentToRadians(e,t){this._isWebMercator?(t[0]=(0,P.yw)(e[0]),t[1]=(0,P.jg)(e[1]),t[2]=(0,P.yw)(e[2]),t[3]=(0,P.jg)(e[3])):this._isGCS&&(t[0]=(0,C.kU)(e[0]),t[1]=(0,C.kU)(e[1]),t[2]=(0,C.kU)(e[2]),t[3]=(0,C.kU)(e[3]))}getExtentGeometry(e,t,n,r=new _.A){return this.getExtent(e,t,n,O),r.spatialReference=this.spatialReference,r.xmin=O[0],r.ymin=O[1],r.xmax=O[2],r.ymax=O[3],r.zmin=void 0,r.zmax=void 0,r}ensureMaxLod(e){if(null==e)return!1;let t=!1;for(;this.levels.length<=e;){const{resolution:e,scale:n}=this.levels[this.levels.length-1],r=e/2*this.pixelSize;this.levels.push({resolution:e/2,scale:n/2,tileSize:[r,r]}),t=!0}return t}capMaxLod(e){this.levels.length>e+1&&(this.levels.length=e+1)}getMaxLod(){return this.levels.length-1}scaleAtLevel(e){return this.levels[0].scale/2**e}levelAtScale(e){const t=this.levels[0].scale;return e>=t?0:Math.log(t/e)*Math.LOG2E}resolutionAtLevel(e){return this.levels[0].resolution/2**e}compatibleWith(e,t=1/0){if(Z.checkUnsupported(e))return!1;const n=new Z(e);if(!n.spatialReference.equals(this.spatialReference))return!1;if(n.pixelSize!==this.pixelSize)return!1;const r=Math.min(this.levels.length-1,n.levels.length-1,t),i=this.levels[r].resolution;let s=.5*i;return!(!(0,C.Sp)(n.origin[0],this.origin[0],s)||!(0,C.Sp)(n.origin[1],this.origin[1],s))&&(s=.5*i/2**r/this.pixelSize*12,(0,C.Sp)(i,n.levels[r].resolution,s))}rootTilesInExtent(e,t=null,n=1/0){const r=new Array,i=this.levels[0].tileSize;if(null==e||0===i[0]||0===i[1])return r;Z.computeRowColExtent(e,i,this.origin,O);let s=O[1],o=O[3],a=O[0],l=O[2];const c=l-a,u=o-s;if(c*u>n){const e=Math.floor(Math.sqrt(n));u>e&&(s=s+Math.floor(.5*u)-Math.floor(.5*e),o=s+e),c>e&&(a=a+Math.floor(.5*c)-Math.floor(.5*e),l=a+e)}for(let e=s;e<o;e++)for(let t=a;t<l;t++)r.push([0,e,t]);return null!=t&&(t[0]=this.origin[0]+a*i[0],t[1]=this.origin[1]-o*i[1],t[2]=this.origin[0]+l*i[0],t[3]=this.origin[1]-s*i[1]),r}static computeRowColExtent(e,t,n,r){const i=.001*(e[2]-e[0]+(e[3]-e[1]));r[0]=Math.max(0,Math.floor((e[0]+i-n[0])/t[0])),r[2]=Math.max(0,Math.ceil((e[2]-i-n[0])/t[0])),r[1]=Math.max(0,Math.floor((n[1]-e[3]+i)/t[1])),r[3]=Math.max(0,Math.ceil((n[1]-e[1]-i)/t[1]))}static isPowerOfTwo(e){const t=e.lods,n=t[0].resolution*2**t[0].level;return!t.some(e=>!(0,C.b6)(e.resolution,n/2**e.level))}static hasGapInLevels(e){const t=e.lods.map(e=>e.level);t.sort((e,t)=>e-t);for(let e=1;e<t.length;e++)if(t[e]!==t[0]+e)return!0;return!1}static tileSizeSupported(e){const t=e.size[1];return t===e.size[0]&&!(t&t-1)&&t>=128&&t<=512}static hasOriginPerLODs(e){const t=e.origin;return e.lods.some(e=>null!=e.origin&&(e.origin[0]!==t.x||e.origin[1]!==t.y))}static getMissingTileInfoError(){return new s.A("tilingscheme:tile-info-missing","Tiling scheme must have tiling information")}static checkUnsupported(e){return null==e?new s.A("tilingscheme:tile-info-missing","Tiling scheme must have tiling information"):e.lods.length<1?new s.A("tilingscheme:generic","Tiling scheme must have at least one level"):Z.isPowerOfTwo(e)?Z.hasGapInLevels(e)?new s.A("tilingscheme:gaps","Tiling scheme levels must not have gaps between min and max level"):Z.tileSizeSupported(e)?Z.hasOriginPerLODs(e)?new s.A("tilingscheme:multiple-origin","Tiling scheme levels must not have their own origin"):null:new s.A("tilingscheme:tile-size","Tiles must be square and size must be one of [128, 256, 512]"):new s.A("tilingscheme:power-of-two","Tiling scheme must be power of two")}static fromExtent(e,t){const n=e[2]-e[0],r=e[3]-e[1],i=(0,T.GA)(t),s=1.2*Math.max(n,r),o=s/256,a=o*i*(96/.0254),l=new Z(new E.A({size:[256,256],origin:new A.A({x:e[0]-.5*(s-n),y:e[3]+.5*(s-r)}),lods:[new z.A({level:0,resolution:o,scale:a})],spatialReference:t}));return l.ensureMaxLod(20),l}static makeWebMercatorAuxiliarySphere(e){const t=new Z(Z.WebMercatorAuxiliarySphereTileInfo);return t.ensureMaxLod(e),t}static makeGCSWithTileSize(e,t=256,n=16){const r=256/t,i=new Z(new E.A({size:[t,t],origin:new A.A({x:-180,y:90,spatialReference:e}),spatialReference:e,lods:[new z.A({level:0,resolution:.703125*r,scale:295497598.570834*r})]}));return i.ensureMaxLod(n),i}static{this.WebMercatorAuxiliarySphereTileInfo=new E.A({size:[256,256],origin:new A.A({x:-20037508.342787,y:20037508.342787,spatialReference:S.A.WebMercator}),spatialReference:S.A.WebMercator,lods:[new z.A({level:0,resolution:156543.03392800014,scale:591657527.591555})]})}static{this.WebMercatorAuxiliarySphere=Z.makeWebMercatorAuxiliarySphere(19)}get test(){}}const O=(0,b.vt)(),I=(0,C.$8)(C.pq/10),D=(0,b.vt)();Z.WebMercatorAuxiliarySphere.getExtent(0,0,0,D),(0,b.vt)([-180,-90,180,90]);var V=n(36005);let j=class extends((0,f.f)((0,d.b)((0,m.q)((0,g.A)((0,a.M)(p.A)))))){constructor(...e){super(...e),this.capabilities={operations:{supportsTileMap:!1}},this.copyright=null,this.heightModelInfo=null,this.path=null,this.minScale=void 0,this.maxScale=void 0,this.opacity=1,this.operationalLayerType="ArcGISTiledElevationServiceLayer",this.sourceJSON=null,this.type="elevation",this.url=null,this.version=null,this._lercDecoder=function(e=null){let t=x.get(e);return t||(null!=e?(t=new M(t=>e.immediate.schedule(t)),x.set(e,t)):(t=new M,x.set(null,t))),++t.ref,t}()}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}destroy(){this._lercDecoder=(0,o.Gz)(this._lercDecoder)}readCapabilities(e,t){const n=t.capabilities&&t.capabilities.split(",").map(e=>e.toLowerCase().trim());return n?{operations:{supportsTileMap:n.includes("tilemap")}}:{operations:{supportsTileMap:!1}}}readVersion(e,t){let n=t.currentVersion;return n||(n=9.3),n}load(e){const t=null!=e?e.signal:null;return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Image Service"],supportsData:!1,validateItem:e=>{if(e.typeKeywords)for(let t=0;t<e.typeKeywords.length;t++)if("elevation 3d layer"===e.typeKeywords[t].toLowerCase())return!0;throw new s.A("portal:invalid-layer-item-type","Invalid layer item type '${type}', expected '${expectedType}' ",{type:"Image Service",expectedType:"Image Service Elevation 3D Layer"})}},e).catch(l.QP).then(()=>this._fetchImageService(t))),Promise.resolve(this)}fetchTile(e,t,n,r){const s=r?.signal,o={responseType:"array-buffer",signal:s},a={noDataValue:r?.noDataValue,returnFileInfo:!0};return this.load().then(()=>this._fetchTileAvailability(e,t,n,r)).then(()=>(0,i.A)(this.getTileUrl(e,t,n),o)).then(e=>this._lercDecoder.decode(e.data,a,s)).then(e=>new v.A(e?new v.A({values:e.pixelData,width:e.width,height:e.height,noDataValue:e.noDataValue}):{values:[],width:0,height:0,noDataValue:r?.noDataValue??I}))}getTileUrl(e,t,n){const r=!this.capabilities.operations.supportsTileMap&&this.supportsBlankTile,i=(0,c.x0)({...this.parsedUrl.query,blankTile:!r&&null});return`${this.parsedUrl.path}/tile/${e}/${t}/${n}${i?"?"+i:""}`}async queryElevation(e,t){const{query:r}=await n.e(91).then(n.bind(n,90091));return(0,l.Te)(t),r(this,e,t)}async createElevationSampler(e,t){const{createSampler:r}=await n.e(91).then(n.bind(n,90091));return(0,l.Te)(t),r(this,e,t)}_fetchTileAvailability(e,t,n,r){return this.tilemapCache?this.tilemapCache.fetchAvailability(e,t,n,r):Promise.resolve("unknown")}async _fetchImageService(e){if(this.sourceJSON)return this.sourceJSON;const t={query:{f:"json",...this.parsedUrl.query},responseType:"json",signal:e},n=await(0,i.A)(this.parsedUrl.path,t);n.ssl&&(this.url=this.url?.replace(/^http:/i,"https:")),this.sourceJSON=n.data,this.read(n.data,{origin:"service",url:this.parsedUrl})}get hasOverriddenFetchTile(){return!this.fetchTile[N]}};(0,r.Cg)([(0,u.MZ)({readOnly:!0})],j.prototype,"capabilities",void 0),(0,r.Cg)([(0,V.w)("service","capabilities",["capabilities"])],j.prototype,"readCapabilities",null),(0,r.Cg)([(0,u.MZ)({json:{read:{source:"copyrightText"}}})],j.prototype,"copyright",void 0),(0,r.Cg)([(0,u.MZ)({readOnly:!0,type:h.A})],j.prototype,"heightModelInfo",void 0),(0,r.Cg)([(0,u.MZ)({type:String,json:{origins:{"web-scene":{read:!0,write:!0}},read:!1}})],j.prototype,"path",void 0),(0,r.Cg)([(0,u.MZ)({type:["show","hide"]})],j.prototype,"listMode",void 0),(0,r.Cg)([(0,u.MZ)({json:{read:!1,write:!1,origins:{service:{read:!1,write:!1},"portal-item":{read:!1,write:!1},"web-document":{read:!1,write:!1}}},readOnly:!0})],j.prototype,"minScale",void 0),(0,r.Cg)([(0,u.MZ)({json:{read:!1,write:!1,origins:{service:{read:!1,write:!1},"portal-item":{read:!1,write:!1},"web-document":{read:!1,write:!1}}},readOnly:!0})],j.prototype,"maxScale",void 0),(0,r.Cg)([(0,u.MZ)({json:{read:!1,write:!1,origins:{"web-document":{read:!1,write:!1}}}})],j.prototype,"opacity",void 0),(0,r.Cg)([(0,u.MZ)({type:["ArcGISTiledElevationServiceLayer"]})],j.prototype,"operationalLayerType",void 0),(0,r.Cg)([(0,u.MZ)()],j.prototype,"sourceJSON",void 0),(0,r.Cg)([(0,u.MZ)({json:{read:!1},value:"elevation",readOnly:!0})],j.prototype,"type",void 0),(0,r.Cg)([(0,u.MZ)(y.OZ)],j.prototype,"url",void 0),(0,r.Cg)([(0,u.MZ)()],j.prototype,"version",void 0),(0,r.Cg)([(0,V.w)("version",["currentVersion"])],j.prototype,"readVersion",null),j=(0,r.Cg)([(0,u.$K)("esri.layers.ElevationLayer")],j);const N=Symbol("default-fetch-tile");j.prototype.fetchTile[N]=!0;const L=j},4146(e,t,n){n.d(t,{A:()=>v});var r=n(5482),i=n(11254),s=n(49186),o=n(65529),a=n(4902),l=n(92474),c=n(53966),u=n(17676),h=n(84952),p=n(91429),f=n(5443),d=n(16930),m=n(92602),g=n(79677);let y=0,v=class extends((0,o.Zt)((0,a.s)(l.x_))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new f.A(-180,-90,180,90,d.A.WGS84),this.id=Date.now().toString(16)+"-layer-"+y++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.persistenceEnabled=!1,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=d.A.WGS84,this.title=null,this.type=null,this.url=null,this.visibilityTimeExtent=null,this.visible=!0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e;return(await Promise.all([n.e(812),n.e(7982)]).then(n.bind(n,27982))).fromUrl(t)}static fromPortalItem(e){return async function(e){const t="portalItem"in e?e:{portalItem:e},{fromItem:r}=await Promise.all([n.e(812),n.e(5613),n.e(5710)]).then(n.bind(n,45613));try{return await r(t)}catch(e){const n=t?.portalItem,r=n?.id||"unset",i=n?.portal?.url||m.A.portalUrl;throw c.A.getLogger("esri.layers.support.fromPortalItem").error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+i+"', id: '"+r+"')",e),e}}(e)}initialize(){this.when().catch(e=>{(0,u.zf)(e)||c.A.getLogger(this).error("#load()",`Failed to load layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}')`,{error:e})})}destroy(){const{parent:e}=this;e&&(this.parent=null,e.removeChildLayer?.(this))}get effectiveVisible(){return this.visible&&(this.parent?.effectiveVisible??!0)}get hasAttributionData(){return null!=this.attributionDataUrl}get loaded(){return super.loaded}removeFromParent(){const{parent:e}=this;e&&(e.removeChildLayer?.(this),this.parent=null)}get parsedUrl(){return(0,h.An)(this.url)}createLayerView(e,t){return Promise.reject(new s.A("layer:create-layer-view","Layer does not support creating a layer view"))}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,i.A)(e,{query:{f:"json"},responseType:"json"})).data;throw new s.A("layer:no-attribution-data","Layer does not have attribution data")}};(0,r.Cg)([(0,p.MZ)({type:String})],v.prototype,"attributionDataUrl",void 0),(0,r.Cg)([(0,p.MZ)({readOnly:!0})],v.prototype,"effectiveVisible",null),(0,r.Cg)([(0,p.MZ)({type:f.A})],v.prototype,"fullExtent",void 0),(0,r.Cg)([(0,p.MZ)({readOnly:!0})],v.prototype,"hasAttributionData",null),(0,r.Cg)([(0,p.MZ)({type:String,clonable:!1})],v.prototype,"id",void 0),(0,r.Cg)([(0,p.MZ)({type:Boolean,nonNullable:!0})],v.prototype,"legendEnabled",void 0),(0,r.Cg)([(0,p.MZ)({type:["show","hide","hide-children"]})],v.prototype,"listMode",void 0),(0,r.Cg)([(0,p.MZ)({type:Number,range:{min:0,max:1},nonNullable:!0})],v.prototype,"opacity",void 0),(0,r.Cg)([(0,p.MZ)({clonable:!1})],v.prototype,"parent",void 0),(0,r.Cg)([(0,p.MZ)({readOnly:!0})],v.prototype,"parsedUrl",null),(0,r.Cg)([(0,p.MZ)({type:Boolean,readOnly:!0})],v.prototype,"persistenceEnabled",void 0),(0,r.Cg)([(0,p.MZ)({type:Boolean})],v.prototype,"popupEnabled",void 0),(0,r.Cg)([(0,p.MZ)({type:Boolean})],v.prototype,"attributionVisible",void 0),(0,r.Cg)([(0,p.MZ)({type:d.A})],v.prototype,"spatialReference",void 0),(0,r.Cg)([(0,p.MZ)({type:String})],v.prototype,"title",void 0),(0,r.Cg)([(0,p.MZ)({readOnly:!0,json:{read:!1}})],v.prototype,"type",void 0),(0,r.Cg)([(0,p.MZ)()],v.prototype,"url",void 0),(0,r.Cg)([(0,p.MZ)({type:g.A})],v.prototype,"visibilityTimeExtent",void 0),(0,r.Cg)([(0,p.MZ)({type:Boolean,nonNullable:!0})],v.prototype,"visible",void 0),v=(0,r.Cg)([(0,p.$K)("esri.layers.Layer")],v)},92722(e,t,n){n.d(t,{A:()=>i});var r=n(69397);class i{constructor(e=[],t=[],n=!1,r=!1){this.lengths=e??[],this.coords=t??[],this.hasZ=n,this.hasM=r}static fromJSON({lengths:e,coords:t,hasZ:n,hasM:r}){return new i(e,t,n||!1,r||!1)}static fromRect([e,t,n,r]){const s=n-e,o=r-t;return new i([5],[e,t,s,0,0,o,-s,0,0,-o])}get isPoint(){return 0===this.lengths.length&&this.coords.length>=2}get maxLength(){return Math.max(...this.lengths)}get size(){return this.isPoint?1:this.lengths.reduce((e,t)=>e+t,0)}get usedMemory(){return 64+(0,r.Qf)(this.lengths,this.coords)}get stride(){return 2+(this.hasZ?1:0)+(this.hasM?1:0)}area(){if(this.isPoint)return 0;let e=0,t=0;for(const n of this.lengths){if(n<3)continue;const{stride:r}=this;let i=this.coords[r*t],s=this.coords[r*t+1];for(let o=1;o<n;o+=1){const n=r*(t+o),a=this.coords[n],l=this.coords[n+1];e+=-.5*(a-i)*(l+s),i=a,s=l}t+=n}return e}forEachVertex(e){let t=0;if(this.isPoint)return e(this.coords[0],this.coords[1]);const{stride:n}=this;for(const r of this.lengths){for(let i=0;i<r;i++){const r=n*(t+i);e(this.coords[r],this.coords[r+1])}t+=r}}deltaDecode(){const e=this.clone(),{coords:t,lengths:n}=e;let r=0;const{stride:i}=this;for(const e of n){for(let n=1;n<e;n++){const e=i*(r+n);t[e]+=t[e-i],t[e+1]+=t[e+1-i]}r+=e}return e}clone(e){if(this.isPoint)return new i([],Array.from(this.coords.slice(0,this.stride)),this.hasZ,this.hasM);const t=Array.from(this.lengths),{stride:n,size:r}=this,s=this.coords.slice(0,r*n);return e?(e.set(s),new i(t,e)):new i(t,Array.from(s),this.hasZ,this.hasM)}justXY(){const{stride:e,size:t}=this;if(2===e)return this;const n=new Array(t*e);for(let t=0,r=0;t<n.length;t+=e)n[r++]=this.coords[t],n[r++]=this.coords[t+1];return new i(this.lengths,n,!1,!1)}}},63490(e,t,n){n.d(t,{E1:()=>c,Mr:()=>l,TH:()=>a});var r=n(5482),i=n(69540),s=n(25482),o=n(91429);let a=class extends((0,i.OU)(s.o)){constructor(){super(...arguments),this.url=null}};(0,r.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],a.prototype,"lod",void 0),(0,r.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],a.prototype,"rasterFunction",void 0),(0,r.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],a.prototype,"url",void 0),a=(0,r.Cg)([(0,o.$K)("esri.layers.orientedImagery.core.ElevationSourceDefinitions.ElevationSource")],a);let l=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.constantElevation=null}};(0,r.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],l.prototype,"constantElevation",void 0),l=(0,r.Cg)([(0,o.$K)("esri.layers.orientedImagery.core.ElevationSourceDefinitions.ConstantElevation")],l);const c=e=>null!=e&&"number"==typeof e.constantElevation},23281(e,t,n){n.d(t,{eR:()=>C,Qv:()=>P,fs:()=>_,Yp:()=>z,RR:()=>b,l6:()=>T});var r=n(66552),i=(n(86211),n(28735),n(5482)),s=n(69540),o=n(25482),a=n(91429),l=n(69622),c=n(21325);let u=class extends l.A{set horizontalWKID(e){e?(0,c.fn)({wkid:+e})?this._set("horizontalWKID",+e):this._set("horizontalWKID",e):this._set("horizontalWKID",null)}set verticalWKID(e){e?this._set("verticalWKID",isFinite(e)&&(0,c.fn)({wkid:+e})?+e:null):this._set("verticalWKID",null)}get isAdvanced(){const{affineTransformations:e,focalLength:t,principalOffsetPoint:n,radialDistortionCoefficients:r,tangentialDistortionCoefficients:i}=this;return e?.length>1&&!Number.isNaN(t)&&n?.length>1&&r?.length>1&&i?.length>1}};(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"affineTransformations",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"focalLength",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"principalOffsetPoint",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"radialDistortionCoefficients",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"tangentialDistortionCoefficients",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"horizontalWKID",null),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"verticalWKID",null),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"x",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"y",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"z",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"type",void 0),u=(0,i.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientation")],u);const h=u;let p=class extends((0,s.OU)((0,o.T)(h))){constructor(){super(...arguments),this.type=1}toString(){const{type:e,horizontalWKID:t,verticalWKID:n,x:r,y:i,z:s,heading:o,pitch:a,roll:l,affineTransformations:c,focalLength:u,principalOffsetPoint:h,radialDistortionCoefficients:p,tangentialDistortionCoefficients:f}=this,d=[e,t,n,r,i,s,o,a,l];return this.isAdvanced&&(c?.forEach(e=>d.push(e)),d.push(u),h?.forEach(e=>d.push(e)),p?.forEach(e=>d.push(e)),f?.forEach(e=>d.push(e))),d.map(e=>Number.isNaN(e)?"":e).join("|")}};(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],p.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],p.prototype,"affineTransformations",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],p.prototype,"focalLength",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],p.prototype,"principalOffsetPoint",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],p.prototype,"radialDistortionCoefficients",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],p.prototype,"tangentialDistortionCoefficients",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],p.prototype,"heading",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],p.prototype,"pitch",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],p.prototype,"roll",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],p.prototype,"x",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],p.prototype,"y",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],p.prototype,"z",void 0),p=(0,i.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientationHPR")],p);const f=p;let d=class extends((0,s.OU)((0,o.T)(h))){constructor(){super(...arguments),this.type=4}toString(){const{type:e,latitude:t,longitude:n,ellipsoidRadius:r,squaredEccentricity:i,properties:s}=this,o=`${s}`.split("|");return o.splice(1,1),`${e}|${t}|${n}|${r}|${i}|${o.join("|")}`}};(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0},type:Number})],d.prototype,"latitude",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0},type:Number})],d.prototype,"longitude",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0},type:Number})],d.prototype,"ellipsoidRadius",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0},type:Number})],d.prototype,"squaredEccentricity",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"properties",void 0),d=(0,i.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientationLTP")],d);const m=d;let g=class extends((0,s.OU)((0,o.T)(h))){constructor(){super(...arguments),this.type=2}toString(){const{type:e,horizontalWKID:t,verticalWKID:n,x:r,y:i,z:s,omega:o,phi:a,kappa:l,affineTransformations:c,focalLength:u,principalOffsetPoint:h,radialDistortionCoefficients:p,tangentialDistortionCoefficients:f}=this,d=[e,t,n,r,i,s,o,a,l];return this.isAdvanced&&(c?.forEach(e=>d.push(e)),d.push(u),h?.forEach(e=>d.push(e)),p?.forEach(e=>d.push(e)),f?.forEach(e=>d.push(e))),d.map(e=>isNaN(e)?"":e).join("|")}};(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],g.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],g.prototype,"affineTransformations",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"focalLength",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],g.prototype,"principalOffsetPoint",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],g.prototype,"radialDistortionCoefficients",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],g.prototype,"tangentialDistortionCoefficients",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"omega",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"phi",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"kappa",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"x",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"y",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],g.prototype,"z",void 0),g=(0,i.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientationOPK")],g);const y=g;let v=class extends((0,s.OU)((0,o.T)(h))){constructor(){super(...arguments),this.type=3}get isAdvanced(){const{affineTransformations:e,focalLength:t,principalOffsetPoint:n,radialDistortionCoefficients:r,tangentialDistortionCoefficients:i}=this;return e?.length>1||!Number.isNaN(t)||n?.length>1||r?.length>1||i?.length>1}toString(){const{type:e,horizontalWKID:t,verticalWKID:n,x:r,y:i,z:s,yaw:o,pitch:a,roll:l,affineTransformations:c,focalLength:u,principalOffsetPoint:h,radialDistortionCoefficients:p,tangentialDistortionCoefficients:f}=this,d=[e,t,n,r,i,s,o,a,l];return this.isAdvanced&&(c?.forEach(e=>d.push(e)),d.push(u),h?.forEach(e=>d.push(e)),h?.forEach(e=>d.push(e)),p?.forEach(e=>d.push(e)),f?.forEach(e=>d.push(e))),d.map(e=>Number.isNaN(e)?"":e).join("|")}};(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],v.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],v.prototype,"affineTransformations",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"focalLength",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],v.prototype,"principalOffsetPoint",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],v.prototype,"radialDistortionCoefficients",void 0),(0,i.Cg)([(0,a.MZ)({type:[Number],json:{write:!0}})],v.prototype,"tangentialDistortionCoefficients",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"yaw",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"pitch",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"roll",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"x",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"y",void 0),(0,i.Cg)([(0,a.MZ)({type:Number,json:{write:!0}})],v.prototype,"z",void 0),v=(0,i.Cg)([(0,a.$K)("esri.layers.orientedImagery.core.CameraOrientationYPR")],v);const w=v,M=new Map;M.set("2",{desc:"Using Omega Phi Kappa",constructor:y}),M.set("1",{desc:"Using Heading, Pitch and Roll",constructor:f}),M.set("3",{desc:"Using Yaw, Pitch and Roll",constructor:w}),M.set("4",{desc:"Using Local Tangent Plane",constructor:m});var x=n(63490);function C(e,t,n){return e?(0,x.E1)(e)?new x.Mr(e):function(e,t,n){let{url:r}=e;return r?(r=function(e,t,n){return t&&(e=`${t}${e}`),n&&(e+=`${n}`),e}(r,t,n),new x.TH({...e,url:r})):null}(e,t,n):e}const b=new r.J({Minutes:"minutes",Hours:"hours",Days:"days",Weeks:"weeks",Months:"months",Years:"years"}),T=new r.J({Feet:"feet",Meter:"meter"}),_=new r.J({360:"360",Horizontal:"horizontal",Inspection:"inspection",Nadir:"nadir",Oblique:"oblique",Terrestrial360Video:"terrestrial-360-video",TerrestrialFrameVideo:"terrestrial-frame-video",Aerial360Video:"aerial-360-video",AerialFrameVideo:"aerial-frame-video","":null}),A=new Map;A.set("1",function(e){const[t,n,r,i,s,o,a,l,c,u,h,p,f,d,m,g,y,v,w,M,x,C]=e.slice(1);return{horizontalWKID:t,verticalWKID:n,x:r,y:i,z:s,heading:o,pitch:a,roll:l,...R([c,u,h,p,f,d],[g,y],[v,w,M],[x,C],m)}}),A.set("3",function(e){const[t,n,r,i,s,o,a,l,c,u,h,p,f,d,m,g,y,v,w,M,x,C]=e.slice(1);return{horizontalWKID:t,verticalWKID:n,x:r,y:i,z:s,yaw:o,pitch:a,roll:l,...R([c,u,h,p,f,d],[g,y],[v,w,M],[x,C],m)}}),A.set("2",function(e){const[t,n,r,i,s,o,a,l,c,u,h,p,f,d,m,g,y,v,w,M,x,C]=e.slice(1);return{horizontalWKID:t,verticalWKID:n,x:r,y:i,z:s,omega:o,phi:a,kappa:l,...R([c,u,h,p,f,d],[g,y],[v,w,M],[x,C],m)}}),A.set("4",function(e){const[t,n,r,i,s,...o]=e.slice(1),a=A.get(s),l=M.get(s)?.constructor;return a&&l?{latitude:t,longitude:n,ellipsoidRadius:r,squaredEccentricity:i,properties:new l(a([s,"",...o]))}:null});const S=e=>{const t=e.map(e=>parseFloat(e)).filter(e=>!isNaN(e));if(t.length===e.length)return t};function R(e,t,n,r,i){const s=S(e),o=S(t),a=S(n),l=S(r);return{affineTransformations:6===s?.length?s:void 0,focalLength:6===s?.length?parseFloat(i):void 0,principalOffsetPoint:2!==o?.length?[0,0]:o,radialDistortionCoefficients:3!==a?.length?[0,0,0]:a,tangentialDistortionCoefficients:2!==l?.length?[0,0]:l}}function P(e){return Array.isArray(e)&&e?.length>5&&!e.some(isNaN)}function z(e){for(e=e.slice(0,8);e.length<8;)e.push(0);return e}},90091(e,t,n){n.d(t,{createSampler:()=>P,query:()=>R});var r=n(60999),i=n(49186),s=n(97768),o=n(17676),a=n(86211),l=n(91218),c=n(19419),u=n(4576),h=n(72802);class p{constructor(e,t){this.layer=e,this.parameters=t}}class f extends p{constructor(e,t,n){super(e,n),this.outSpatialReference=t,this.type="geometry"}selectTilesAtLOD(e){if(e<0)this.geometry.coordinates.forEach(e=>e.tile=null);else{const{tileInfo:t,tilemapCache:n}=this.layer,r=g(t,n)[e].level;this.geometry.coordinates.forEach(e=>e.tile=t.tileAt(r,e.x,e.y))}}allElevationTilesFetched(){return!this.geometry.coordinates.some(e=>!e.elevationTile)}clearElevationTiles(){for(const e of this.geometry.coordinates)e.elevationTile!==this.outsideExtentTile&&(e.elevationTile=null)}populateElevationTiles(e){for(const t of this.geometry.coordinates)!t.elevationTile&&t.tile?.id&&(t.elevationTile=e[t.tile.id])}remapTiles(e){for(const t of this.geometry.coordinates){const n=t.tile?.id;t.tile=n?e[n]:null}}getTilesToFetch(){return(0,u.Am)(this.geometry.coordinates.filter(({tile:e,elevationTile:t})=>e?.id&&!t),(e,t)=>e.tile?.id===t.tile?.id).map(({tile:e})=>e)}forEachTileToFetch(e){for(const t of this.geometry.coordinates)t.tile&&!t.elevationTile&&e(t.tile,()=>t.tile=null)}}class d extends p{constructor(e,t,n,r){super(e,n),this.maskExtents=r,this.type="extent",this.elevationTiles=[],this._candidateTiles=[],this._fetchedCandidates=new Set,this.extent=t.clone().intersection(e.fullExtent)}selectTilesAtLOD(e,t){const n=this._maximumLodForRequests(t),r=Math.min(n,e);r<0?this._candidateTiles.length=0:this._selectCandidateTilesCoveringExtentAt(r)}_maximumLodForRequests(e){const{tileInfo:t,tilemapCache:n}=this.layer,r=g(t,n);if(!e)return r.length-1;const i=this.extent;if(null==i)return-1;for(let n=r.length-1;n>=0;n--){const s=r[n],o=s.resolution*t.size[0],a=s.resolution*t.size[1];if(Math.ceil(i.width/o)*Math.ceil(i.height/a)<=e)return n}return-1}allElevationTilesFetched(){return this._candidateTiles.length===this.elevationTiles.length}clearElevationTiles(){this.elevationTiles.length=0,this._fetchedCandidates.clear()}populateElevationTiles(e){for(const t of this._candidateTiles){const n=t.id&&e[t.id];n&&(this._fetchedCandidates.add(t),this.elevationTiles.push(n))}}remapTiles(e){this._candidateTiles=y(this._candidateTiles.map(t=>e[t.id]))}getTilesToFetch(){return this._candidateTiles}forEachTileToFetch(e,t){const n=this._candidateTiles;this._candidateTiles=[],n.forEach(n=>{if(this._fetchedCandidates.has(n))return void t?.(n);let r=!1;e(n,()=>r=!0),r?t?.(n):this._candidateTiles.push(n)}),this._candidateTiles=y(this._candidateTiles,t)}_selectCandidateTilesCoveringExtentAt(e){this._candidateTiles.length=0;const t=this.extent;if(null==t)return;const{tileInfo:n,tilemapCache:r}=this.layer,i=g(n,r)[e],s=n.tileAt(i.level,t.xmin,t.ymin),o=s.extent,a=i.resolution*n.size[0],l=i.resolution*n.size[1],c=Math.ceil((t.xmax-o[0])/a),u=Math.ceil((t.ymax-o[1])/l);for(let e=0;e<u;e++)for(let t=0;t<c;t++){const r=new h.U(s.level,s.row-e,s.col+t);n.updateTileInfo(r),this._tileIsMasked(r)||this._candidateTiles.push(r)}}_tileIsMasked(e){return this.maskExtents?.some(t=>(0,c.gR)(t,e.extent))??!1}}function m(e){return null!=e?.tileInfo}function g(e,t){const n=e.lods;if(m(t)){const{effectiveMinLOD:e,effectiveMaxLOD:r}=t;return n.filter(t=>t.level>=e&&t.level<=r)}return n}function y(e,t){const n={},r=[];for(const i of e){const e=i.id;e&&!n[e]?(n[e]=i,r.push(i)):t?.(i)}const i=r.sort((e,t)=>e.level-t.level);return i.filter((e,n)=>{for(let r=0;r<n;r++){const n=i[r].extent;if(n&&(0,c.gR)(n,e.extent))return t?.(e),!1}return!0})}class v{constructor(e,t){this.data=e,this.safeWidth=.99999999*(e.width-1),this.dx=(e.width-1)/(t[2]-t[0]),this.dy=(e.width-1)/(t[3]-t[1]),this.x0=t[0],this.y1=t[3]}}class w{constructor(e,t=null){if(this.key=e,null!=t){const n=e.extent;this._samplerData=new v(t,n)}}get zmin(){return null!=this._samplerData?this._samplerData.data.minValue:0}get zmax(){return null!=this._samplerData?this._samplerData.data.maxValue:0}get hasNoDataValues(){return!!this._samplerData?.data.hasNoDataValues}sample(e,t){if(null==this._samplerData)return;const{safeWidth:n,data:r,dx:i,dy:s,y1:o,x0:a}=this._samplerData,{width:l,values:c,noDataValue:u}=r,h=M(s*(o-t),0,n),p=M(i*(e-a),0,n),f=Math.floor(h),d=Math.floor(p),m=f*l+d,g=m+l,y=c[m],v=c[g],w=c[m+1],x=c[g+1];if(y!==u&&v!==u&&w!==u&&x!==u){const e=p-d,t=y+(w-y)*e;return t+(v+(x-v)*e-t)*(h-f)}}}function M(e,t,n){return e<t?t:e>n?n:e}var x=n(87378),C=n(48526),b=n(86738),T=n(82799);class _{constructor(e){this.geometry=e,this.spatialReference=e.spatialReference}export(){return this._exporter(this.coordinates,this.spatialReference)}clone(e){const t=new _(this.geometry);return t.spatialReference=this.spatialReference,t.coordinates=e??this.coordinates.map(e=>e.clone()),t._exporter=this._exporter,t}async project(e,t){if(this.spatialReference.equals(e))return this.clone();await(0,l.initializeProjection)([{source:this.spatialReference,dest:e}],{signal:t});const n=new C.A({spatialReference:this.spatialReference,points:this.coordinates.map(e=>[e.x,e.y])}),r=(0,l.project)(n,e);if(!r)return null;const i=this.coordinates.map((e,t)=>{const n=e.clone(),i=r.points[t];return n.x=i[0],n.y=i[1],n}),s=this.clone(i);return s.spatialReference=e,s}projectSync(e){if(this.spatialReference.equals(e))return this.clone();const t=new C.A({spatialReference:this.spatialReference,points:this.coordinates.map(e=>[e.x,e.y])}),n=(0,l.project)(t,e);if(!n)return null;const r=this.coordinates.map((e,t)=>{const r=e.clone(),i=n.points[t];return r.x=i[0],r.y=i[1],r}),i=this.clone(r);return i.spatialReference=e,i}static fromGeometry(e){const t=new _(e);if(e instanceof _)return t.coordinates=e.coordinates.map(e=>e.clone()),t._exporter=(t,n)=>{const r=e.clone(t);return r.spatialReference=n,r},t;switch(e.type){case"point":{const n=e,{hasZ:r,hasM:i}=n;return t.coordinates=r&&i?[new A(n.x,n.y,n.z,n.m)]:r?[new A(n.x,n.y,n.z)]:i?[new A(n.x,n.y,null,n.m)]:[new A(n.x,n.y)],t._exporter=(t,n)=>e.hasM?new b.A(t[0].x,t[0].y,t[0].z,t[0].m,n):new b.A(t[0].x,t[0].y,t[0].z,n),t}case"multipoint":{const n=e,{hasZ:r,hasM:i}=n;return t.coordinates=r&&i?n.points.map(e=>new A(e[0],e[1],e[2],e[3])):r?n.points.map(e=>new A(e[0],e[1],e[2])):i?n.points.map(e=>new A(e[0],e[1],null,e[2])):n.points.map(e=>new A(e[0],e[1])),t._exporter=(t,n)=>e.hasM?new C.A({points:t.map(e=>[e.x,e.y,e.z??0,e.m??0]),hasZ:!0,hasM:!0,spatialReference:n}):new C.A({points:t.map(e=>[e.x,e.y,e.z??0]),spatialReference:n}),t}case"polyline":{const n=e,r=[],i=[],{hasZ:s,hasM:o}=e;let a=0;for(const e of n.paths)if(i.push([a,a+e.length]),a+=e.length,s&&o)for(const t of e)r.push(new A(t[0],t[1],t[2],t[3]));else if(s)for(const t of e)r.push(new A(t[0],t[1],t[2]));else if(o)for(const t of e)r.push(new A(t[0],t[1],null,t[2]));else for(const t of e)r.push(new A(t[0],t[1]));return t.coordinates=r,t._exporter=(t,n)=>{const r=e.hasM?t.map(e=>[e.x,e.y,e.z??0,e.m??0]):t.map(e=>[e.x,e.y,e.z??0]),s=i.map(e=>r.slice(e[0],e[1]));return new T.A({paths:s,hasM:e.hasM,hasZ:!0,spatialReference:n})},t}}}}class A{constructor(e,t,n=null,r=null,i=null,s=null){this.x=e,this.y=t,this.z=n,this.m=r,this.tile=i,this.elevationTile=s}clone(){return new A(this.x,this.y,this.z,this.m)}}var S=n(1555);async function R(e,t,n){if(!e)throw new i.A(N,"Elevation queries require an elevation layer to fetch tiles from");if(!t||!(t instanceof _)&&"point"!==t.type&&"multipoint"!==t.type&&"polyline"!==t.type)throw new i.A("elevation-query:invalid-geometry","Only point, polyline and multipoint geometries can be used to query elevation");const r={...V,...n},o=r.signal;if("integrated-mesh-3dtiles"===e.type){const i=_.fromGeometry(t);if(e.queryElevationCallback&&e.replacesTerrain){const s=12.9*(n?.minDemResolution||0)+.71,a=await e.queryElevationCallback(i,{signal:o,maxGeometricError:s}),l=i.coordinates.map(()=>({demResolution:1,source:e})),c=await a.project(t.spatialReference,o);if(c){if(void 0!==r.noDataValue&&r.noDataValue!==Number.MAX_VALUE)for(const e of c.coordinates)e.z===Number.MAX_VALUE&&(e.z=r.noDataValue);return{geometry:c.export(),noDataValue:r.noDataValue??Number.MAX_VALUE,sampleInfo:l}}}const s=i.coordinates.map(()=>({demResolution:-1,source:e}));return{geometry:i.export(),noDataValue:Number.MAX_VALUE,sampleInfo:s}}const c=new f(e,t.spatialReference,r);return await e.load({signal:o}),await async function(e,t,n){let r;const s=e.layer.tileInfo.spatialReference;if(t instanceof _?r=await t.project(s,n):(await(0,l.initializeProjection)([{source:t.spatialReference,dest:s}],{signal:n}),r=(0,l.project)(t,s)),!r)throw new i.A("elevation-query:spatial-reference-mismatch",`Cannot query elevation in '${t.spatialReference.wkid}' on an elevation service in '${s.wkid}'`);e.geometry=_.fromGeometry(r)}(c,t,o),await Z(c,o),await j(c,o),function(e){e.geometry.coordinates.forEach(t=>{const n=t.elevationTile;let r=e.parameters.noDataValue;if(n){const e=n.sample(t.x,t.y);null==e?t.elevationTile=null:r=e}t.z=r})}(c),async function(e,t){const n=await e.geometry.project(e.outSpatialReference,t);(0,s.Lw)(n);const r={geometry:n.export(),noDataValue:e.parameters.noDataValue};return e.parameters.returnSampleInfo&&(r.sampleInfo=function(e){const t=e.layer.tileInfo,n=(0,a.GA)(t.spatialReference);return e.geometry.coordinates.map(r=>{let i=-1;return r.elevationTile&&r.elevationTile!==e.outsideExtentTile&&(i=t.lodAt(r.elevationTile.key.level).resolution*n),{demResolution:i,source:-1===i?void 0:e.layer}})}(e)),e.geometry.coordinates.forEach(e=>{e.tile=null,e.elevationTile=null}),r}(c,o)}async function P(e,t,n){if(e=Array.isArray(e)?e:[e],0===(e=n?.ignoreInvisibleLayers?e.filter(e=>e.visible):e.slice()).length)throw new i.A(N,"Elevation queries require at least one elevation layer to fetch tiles from");if(!t||"extent"!==t.type)throw new i.A("elevation-query:invalid-extent","Invalid or undefined extent");const r={...V,...n,returnSampleInfo:!0},s=z(e[e.length-1],t,r);return 1===e.length?s:E(e,t,await s,r)}async function z(e,t,n,r){const i=n.signal;await e.load({signal:i});const s=t.spatialReference,o=e.tileInfo.spatialReference;s.equals(o)||(await(0,l.initializeProjection)([{source:s,dest:o}],{signal:i}),t=(0,l.project)(t,o));const a=new d(e,t,n,r);await Z(a,i),await j(a,i);const c=a.elevationTiles,u=a.layer.tileInfo,h=a.parameters.noDataValue;return new S.C({noDataValue:h,tiles:c,tileInfo:u})}async function E(e,t,n,r){if(e.pop(),!e.length)return n;const i=n.samplers.filter(e=>!e.tile.hasNoDataValues).map(e=>(0,c.VY)(e.extent)),s=await z(e[e.length-1],t,r,i);if(0===s.samplers.length)return n;const o=n.samplers.concat(s.samplers),a=r.noDataValue;return E(e,t,new S.C({samplers:o,noDataValue:a}),r)}async function Z(e,t){"geometry"===e.type&&function(e){if(null==e.layer.fullExtent)return;const t=new w(new h.U(-1,-1,-1));t.sample=()=>e.parameters.noDataValue,e.outsideExtentTile=t;const n=e.layer.fullExtent;e.geometry.coordinates.forEach(e=>{const r=e.x,i=e.y;(r<n.xmin||r>n.xmax||i<n.ymin||i>n.ymax)&&(e.elevationTile=t)})}(e);const n=e.parameters.demResolution;if("number"==typeof n)!function(e,t){const n=function(e,t){const{tileInfo:n,tilemapCache:r}=e.layer,i=t/(0,a.GA)(n.spatialReference),s=g(n,r);let o=s[0],l=0;for(let e=1;e<s.length;e++){const t=s[e];Math.abs(t.resolution-i)<Math.abs(o.resolution-i)&&(o=t,l=e)}return l}(e,t);e.selectTilesAtLOD(n)}(e,n);else if("finest-contiguous"===n)await async function(e,t){const{tileInfo:n,tilemapCache:r}=e.layer,i=D(n,r,e.parameters.minDemResolution);await O(e,i,t)}(e,t);else{if("auto"!==n)throw new i.A("elevation-query:invalid-dem-resolution",`Invalid dem resolution value '${n}', expected a number, "finest-contiguous" or "auto"`);await async function(e,t){(function(e){const{tileInfo:t,tilemapCache:n}=e.layer,r=D(t,n,e.parameters.minDemResolution);e.selectTilesAtLOD(r,e.parameters.maximumAutoTileRequests)})(e),function(e){const t=e.layer.tileInfo;let n=0;const r={},i=e=>{null!=e.id&&(e.id in r?r[e.id]++:(r[e.id]=1,n++))},s=e=>{if(null==e.id)return;const t=r[e.id];1===t?(delete r[e.id],n--):r[e.id]=t-1};e.forEachTileToFetch(i,s);let o=!0;for(;o&&(o=!1,e.forEachTileToFetch(r=>{n<=e.parameters.maximumAutoTileRequests||(s(r),t.upsampleTile(r)&&(o=!0),i(r))},s),o););}(e);const n=e.layer.tilemapCache;if(!n||m(n))return I(e,t);const i=e.getTilesToFetch(),s={},a=i.map(async e=>{const i=new h.U(0,0,0),a=await(0,r.Ke)(n.fetchAvailabilityUpsample(e.level,e.row,e.col,i,{signal:t}));!1!==a.ok?null!=e.id&&(s[e.id]=i):(0,o.QP)(a.error)});await(0,o.qr)(Promise.all(a),t),e.remapTiles(s)}(e,t)}}async function O(e,t,n){const r=e.layer;if(e.selectTilesAtLOD(t),t<0)return;const s=r.tilemapCache,a=e.getTilesToFetch();try{if(s&&!m(s))await(0,o.qr)(Promise.all(a.map(e=>s.fetchAvailability(e.level,e.row,e.col,{signal:n}))),n);else if(await j(e,n),!e.allElevationTilesFetched())throw e.clearElevationTiles(),new i.A("elevation-query:has-unavailable-tiles","Some elevation tiles are unavailable")}catch(r){(0,o.QP)(r),await O(e,t-1,n)}}async function I(e,t){const n=e.layer.tileInfo;await j(e,t);let r=!1;e.forEachTileToFetch((e,t)=>{n.upsampleTile(e)?r=!0:t()}),r&&await I(e,t)}function D(e,t,n=0){const r=g(e,t);let i=r.length-1;if(n>0){const t=n/(0,a.GA)(e.spatialReference),s=r.findIndex(e=>e.resolution<t);0===s?i=0:s>0&&(i=s-1)}return i}const V={maximumAutoTileRequests:20,noDataValue:0,returnSampleInfo:!1,demResolution:"auto",minDemResolution:0,signal:null};async function j(e,t){const n=e.getTilesToFetch(),r={},i=e.parameters.cache,s=e.parameters.noDataValue,a={noDataValue:s,signal:t},l=n.map(async t=>{if(null==t.id)return;const n=`${e.layer.uid}:${t.id}:${s}`,o=i?.get(n),l=o??x.A.from(await e.layer.fetchTile(t.level,t.row,t.col,a));i?.put(n,l),r[t.id]=new w(t,l)});await(0,o.qr)(Promise.allSettled(l),t),e.populateElevationTiles(r)}const N="elevation-query:invalid-layer"},87378(e,t,n){n.d(t,{A:()=>a});var r,i=n(34275),s=n(56507);const o=Symbol("ElevationTileDataClass");class a{static{r=o}constructor({values:e,width:t,height:n,noDataValue:s}){this[r]=!0,this._hasNoDataValues=null,this._minValue=null,this._maxValue=null,this.values=(0,i.vZ)(e)?e:new Float32Array(e),this.width=t,this.height=n,this.noDataValue=s}get hasNoDataValues(){if(null==this._hasNoDataValues){const e=this.noDataValue;this._hasNoDataValues=this.values.includes(e)}return this._hasNoDataValues}get minValue(){return this._ensureBounds(),this._minValue}get maxValue(){return this._ensureBounds(),this._maxValue}get usedMemory(){return this.values.byteLength+256}_ensureBounds(){if(null!=this._minValue)return;const{noDataValue:e,values:t}=this;let n=1/0,r=-1/0,i=!0;for(const s of t)s===e?this._hasNoDataValues=!0:(n=s<n?s:n,r=s>r?s:r,i=!1);i?(this._minValue=0,this._maxValue=0):(this._minValue=n,this._maxValue=r>-3e38?r:0)}static{this.from=(0,s.qf)(a)}}},1555(e,t,n){n.d(t,{C:()=>d});var r=n(5482),i=n(53966),s=n(86211),o=n(91429),a=n(16930),l=n(19419),c=n(65529),u=n(86738),h=n(28735);let p=class extends c.nJ{queryElevation(e){const t=this.projectIfRequired(e,this.spatialReference);if(!t)return null;switch(e.type){case"point":return function(e,t,n){return e.hasZ=!0,e.z=n.elevationAt(t.x,t.y),e}(e,t,this);case"polyline":return function(e,t,n){f.spatialReference=t.spatialReference;const r=e.hasM&&!e.hasZ;for(let i=0;i<e.paths.length;i++){const s=e.paths[i],o=t.paths[i];for(let e=0;e<s.length;e++){const t=s[e],i=o[e];f.x=i[0],f.y=i[1],r&&(t[3]=t[2]),t[2]=n.elevationAt(f.x,f.y)}}return e.hasZ=!0,e}(e,t,this);case"multipoint":return function(e,t,n){f.spatialReference=t.spatialReference;const r=e.hasM&&!e.hasZ;for(let i=0;i<e.points.length;i++){const s=e.points[i],o=t.points[i];f.x=o[0],f.y=o[1],r&&(s[3]=s[2]),s[2]=n.elevationAt(f.x,f.y)}return e.hasZ=!0,e}(e,t,this);default:return null}}projectIfRequired(e,t){if(null==e)return null;const n=e.spatialReference;if(n.equals(t))return e;const r=(0,h.Cv)(e,t);return r||i.A.getLogger(this).error(`Cannot project geometry spatial reference (wkid:${n.wkid}) to elevation sampler spatial reference (wkid:${t.wkid})`),r}};p=(0,r.Cg)([(0,o.$K)("esri.layers.support.ElevationSampler")],p);const f=new u.A;let d=class extends p{get spatialReference(){return this.extent.spatialReference}constructor(e){const t=e.noDataValue,n="tiles"in e?e.tiles.map(n=>new m({tile:n,tileInfo:e.tileInfo,noDataValue:t})):e.samplers;super({noDataValue:t,samplers:n});const r=n[0];if(r){this.extent=r.extent.clone();const{min:e,max:t}=r.demResolution;this.demResolution={min:e,max:t};for(let e=1;e<n.length;e++){const t=n[e];this.extent.union(t.extent),this.demResolution.min=Math.min(this.demResolution.min,t.demResolution.min),this.demResolution.max=Math.max(this.demResolution.max,t.demResolution.max)}}else{const t="tileInfo"in e?e.tileInfo:null;this.extent=(0,l.w1)((0,l.vt)(),t?.spatialReference??a.A.WGS84),this.demResolution={min:0,max:0}}}elevationAt(e,t){let n;for(const r of this.samplers)if(r.containsAt(e,t)&&(n=r.elevationAt(e,t),n!==r.noDataValue))return n;return null!=n?n:(i.A.getLogger(this).warn("#elevationAt()",`Point used to sample elevation (${e}, ${t}) is outside of the sampler`),this.noDataValue)}};(0,r.Cg)([(0,o.MZ)({constructOnly:!0})],d.prototype,"noDataValue",void 0),(0,r.Cg)([(0,o.MZ)({constructOnly:!0})],d.prototype,"samplers",void 0),d=(0,r.Cg)([(0,o.$K)("esri.layers.support.TileElevationSampler")],d);let m=class extends p{get spatialReference(){return this.extent.spatialReference}constructor(e){super(e);const t=e.tile.key.extent;this.extent=(0,l.w1)(t,e.tileInfo.spatialReference),this.extent.zmin=e.tile.zmin,this.extent.zmax=e.tile.zmax;const n=(0,s.GA)(e.tileInfo.spatialReference),r=e.tileInfo.lodAt(e.tile.key.level).resolution*n;this.demResolution={min:r,max:r}}contains(e){const t=this.projectIfRequired(e,this.spatialReference);return null!=t&&this.containsAt(t.x,t.y)}containsAt(e,t){return(0,l.Rj)(this.tile.key.extent,e,t)}elevationAt(e,t){return this.containsAt(e,t)?this.tile.sample(e,t)??this.noDataValue:this.noDataValue}};(0,r.Cg)([(0,o.MZ)({constructOnly:!0})],m.prototype,"tile",void 0),(0,r.Cg)([(0,o.MZ)({constructOnly:!0})],m.prototype,"noDataValue",void 0),(0,r.Cg)([(0,o.MZ)({constructOnly:!0})],m.prototype,"tileInfo",void 0),m=(0,r.Cg)([(0,o.$K)("esri.layers.support.TileElevationSampler.SingleTileElevationSampler")],m)},77548(e,t,n){n.d(t,{Gh:()=>S,tk:()=>C,BR:()=>x,p2:()=>w,qd:()=>b,wI:()=>M,G$:()=>_,$x:()=>T,Ov:()=>m,UC:()=>h,W_:()=>g,OP:()=>A,TU:()=>d,XX:()=>f,jy:()=>y});var r=n(70333),i=n(11254),s=n(7762),o=(n(84952),n(36563)),a=n(36708),l=n(4146);const c=new WeakMap;function u(e){return!e.destroyed&&(c.has(e)||e.addHandles([(0,a.wB)(()=>{const{parent:t}=e;return!!(t&&t instanceof l.A)&&("catalog-dynamic-group"===t.type||u(t))},t=>c.set(e,t),a.pc),(0,o.hA)(()=>c.delete(e))]),c.get(e))}function h(e){return null!=e&&"object"==typeof e&&"type"in e&&"knowledge-graph-sublayer"===e.type}function p(e){const t=e.parent;return function(e){return null!=e&&"type"in e&&"group"===e.type}(t)&&t.tables.includes(e)}n(16215);const f={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};function d(e){const t=e?.type;return"building-scene"===t||"integrated-mesh"===t||"point-cloud"===t||"scene"===t}function m(e){return"feature"===e?.type&&!e.url&&"memory"===e.source?.type}function g(e){const t=e?.type;return("feature"===t||"subtype-group"===t||"oriented-imagery"===t)&&"feature-layer"===e?.source?.type}function y(e){return function(e){return null!=e&&"object"==typeof e&&"type"in e&&"feature"===e.type}(e)&&function(e){return"feature"===e?.type&&"feature-layer"===e.source?.type}(e)}function v(e){const t=e?.type;return"binning"===t||"cluster"===t}function w(e,t){if(!y(e))return;const n=t?.graphic,r=e.featureReduction;if(n){if(n.isAggregate){const e=n.origin;return e&&"featureReductionProvider"in e&&r?v(r)?r:null:void 0}return e}return t?.checkFeatureReduction&&r?v(r)?r:null:e}async function M(e,t){const n=r.id?.findServerInfo(e);if(null!=n?.currentVersion)return n.owningSystemUrl||null;const s=e.toLowerCase().indexOf("/rest/services");if(-1===s)return null;const o=`${e.slice(0,s)}/rest/info`,a=null!=t?t.signal:null,{data:l}=await(0,i.A)(o,{query:{f:"json"},responseType:"json",signal:a});return l?.owningSystemUrl||null}function x(e){return function(e){if(!("capabilities"in e))return!1;switch(e.type){case"catalog":case"catalog-footprint":case"csv":case"feature":case"geojson":case"imagery":case"knowledge-graph-sublayer":case"ogc-feature":case"oriented-imagery":case"scene":case"sublayer":case"subtype-group":case"subtype-sublayer":case"wfs":return!0;default:return!1}}(e)?"effectiveCapabilities"in e?e.effectiveCapabilities:e.capabilities:null}function C(e){return!!function(e){if(!("editingEnabled"in e))return!1;switch(e.type){case"csv":case"feature":case"geojson":case"oriented-imagery":case"scene":case"subtype-group":case"subtype-sublayer":case"knowledge-graph-sublayer":return!0;default:return!1}}(e)&&("effectiveEditingEnabled"in e?e.effectiveEditingEnabled:e.editingEnabled)}function b(e){const t=new s.A;for(const n of e.allLayers.concat(e.allTables))u(n)||p(n)||("charts"in n&&t.push(n),"subtype-group"===n.type&&t.push(...n.sublayers));return t}function T(e,t){return null}function _(e){return null}function A(e){return!e||"Feature Service"===e.type&&!e.sourceUrl}function S(e,t){if(!t||!A(e))return;const n=(e.url,null);n&&(e.url=n)}},38969(e,t,n){n.d(t,{i:()=>i});var r=n(37955);function i(e,t){return new Promise((n,i)=>{e.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA?n():(t((0,r.Oo)(e,"canplay",n)),t((0,r.Oo)(e,"error",i)))})}},73133(e,t,n){n.d(t,{j:()=>r});const r=(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:"unknown"})},7861(e,t,n){n.d(t,{L:()=>i});var r=n(11254);async function i(e,t){return(await(0,r.A)(e,{responseType:"json",query:{f:"json",...t?.customParameters,token:t?.apiKey}})).data}},16215(e,t,n){n.d(t,{S:()=>i,Y:()=>r});const r=Symbol("BasemapInstance");function i(e){return null!=e&&"object"==typeof e&&r in e}},79677(e,t,n){n.d(t,{A:()=>p});var r,i=n(5482),s=n(25482),o=n(88930),a=n(91429),l=n(98623),c=n(10184),u=n(36005),h=n(43937);let p=class extends s.o{static{r=this}static get allTime(){return f}static get empty(){return d}static fromArray(e){return new r({start:null!=e[0]?new Date(e[0]):e[0],end:null!=e[1]?new Date(e[1]):e[1]})}constructor(e){super(e),this.end=null,this.start=null}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?.getTime()??null}get isAllTime(){return this.equals(r.allTime)}get isEmpty(){return this.equals(r.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?.getTime()??null}clone(){return new r({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=this.start?.getTime()??this.start,n=this.end?.getTime()??this.end,r=e.start?.getTime()??e.start,i=e.end?.getTime()??e.end;return t===r&&n===i}expandTo(e,t=l.qU){if(this.isEmpty||this.isAllTime||"unknown"===e)return this.clone();let n=this.start;n&&(n=(0,o.lL)(n,new c.A({value:1,unit:e}),t));let i=this.end;if(i){const n=(0,o.lL)(i,new c.A({value:1,unit:e}),t);i=i.getTime()===n.getTime()?n:(0,o.S1)(n,1,e,t)}return new r({start:n,end:i})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return r.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=this.start?.getTime()??-1/0,n=this.end?.getTime()??1/0,i=e.start?.getTime()??-1/0,s=e.end?.getTime()??1/0;let o,a;return i>=t&&i<=n?o=i:t>=i&&t<=s&&(o=t),n>=i&&n<=s?a=n:s>=t&&s<=n&&(a=s),null==o||null==a||isNaN(o)||isNaN(a)?r.empty:new r({start:o===-1/0?null:new Date(o),end:a===1/0?null:new Date(a)})}offset(e,t,n=l.qU){if(this.isEmpty||this.isAllTime||"unknown"===t)return this.clone();const i=new r,{start:s,end:a}=this;return null!=s&&(i.start=(0,o.S1)(s,e,t,n)),null!=a&&(i.end=(0,o.S1)(a,e,t,n)),i}toArray(){return this.isEmpty?[void 0,void 0]:[this.start?.getTime()??null,this.end?.getTime()??null]}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return f.clone();const t=null!=this.start&&null!=e.start?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,n=null!=this.end&&null!=e.end?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new r({start:t,end:n})}};(0,i.Cg)([(0,a.MZ)({type:Date,json:{write:{allowNull:!0}}})],p.prototype,"end",void 0),(0,i.Cg)([(0,u.w)("end")],p.prototype,"readEnd",null),(0,i.Cg)([(0,h.K)("end")],p.prototype,"writeEnd",null),(0,i.Cg)([(0,a.MZ)({readOnly:!0,json:{read:!1}})],p.prototype,"isAllTime",null),(0,i.Cg)([(0,a.MZ)({readOnly:!0,json:{read:!1}})],p.prototype,"isEmpty",null),(0,i.Cg)([(0,a.MZ)({type:Date,json:{write:{allowNull:!0}}})],p.prototype,"start",void 0),(0,i.Cg)([(0,u.w)("start")],p.prototype,"readStart",null),(0,i.Cg)([(0,h.K)("start")],p.prototype,"writeStart",null),p=r=(0,i.Cg)([(0,a.$K)("esri.time.TimeExtent")],p);const f=new p,d=new p({start:void 0,end:void 0})},10184(e,t,n){n.d(t,{A:()=>u});var r=n(5482),i=n(69540),s=n(25482),o=n(88930),a=n(91429),l=n(73133),c=n(93223);let u=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,r.Cg)([(0,c.e)(l.j,{nonNullable:!0})],u.prototype,"unit",void 0),(0,r.Cg)([(0,a.MZ)({type:Number,json:{write:!0},nonNullable:!0})],u.prototype,"value",void 0),u=(0,r.Cg)([(0,a.$K)("esri.time.TimeInterval")],u)},32728(e,t,n){n.d(t,{YH:()=>o,nu:()=>a,wp:()=>s}),n(34727);var r=n(35522),i=n(51850);function s(e,t){const n=Math.sqrt(t[0]*t[0]+t[4]*t[4]+t[8]*t[8]),i=Math.sqrt(t[1]*t[1]+t[5]*t[5]+t[9]*t[9]),s=Math.sqrt(t[2]*t[2]+t[6]*t[6]+t[10]*t[10]);return(0,r.hZ)(e,n,i,s),e}function o(e,t,n){n=n||e;const i=(0,r.Om)(e,t);(0,r.hZ)(n,e[0]-i*t[0],e[1]-i*t[1],e[2]-i*t[2]),(0,r.S8)(n,n)}function a(e,t,n,s=(0,i.vt)()){const o=(0,r.Bw)(e),a=(0,r.Bw)(t),u=(0,r.Om)(e,t)/(o*a);if(u<.9999999999999999){const i=Math.acos(u),h=((1-n)*o+n*a)/Math.sin(i),p=h/o*Math.sin((1-n)*i),f=h/a*Math.sin(n*i);return(0,r.hs)(l,e,p),(0,r.hs)(c,t,f),(0,r.WQ)(s,l,c)}return(0,r.Cc)(s,e,t,n)}(0,i.vt)(),(0,i.vt)(),(0,i.vt)();const l=(0,i.vt)(),c=(0,i.vt)()},68747(e,t,n){n.r(t),n.d(t,{generateCombinationsPanoramicWorker:()=>T,generateCombinationsWorker:()=>b});var r=n(34727),i=n(17676);n(17799),n(69052),n(799),n(86211),n(18047),new Map,n(77690),n(29242),n(51850),n(37585),n(35522);var s=n(49186);n(56507),n(86738),n(39829),n(82799),n(16930),n(34403),n(21325),n(91218),n(65708),n(49590),n(27749),n(39663),n(7817),n(10222),n(4576),n(63490),n(6800),n(87811);var o=n(53966),a=(n(44208),n(27921),n(5443));n(83276),n(19419),n(62369),n(87772),n(23281),n(90091),n(87378),n(22796),n(1555),n(87045),n(72802),n(7861);const l=[1920,1080],c={xmin:-150,ymin:1,xmax:20,ymax:80,spatialReference:{wkid:4326}},u=.001;new a.A({xmin:c.xmin+u,ymin:c.ymin+u,xmax:c.xmax-u,ymax:c.ymax-u,spatialReference:c.spatialReference}),(0,r.KJ)(Math.acos(.05));var h=n(5482),p=n(97768),f=n(61893),d=n(10107),m=n(64108);let g=class extends f.Z{constructor(e){super(e),this.autoLoad=!1,this.customParameters=null,this.datasetFormat=null,this.url=null,this.rotation=null}destroy(){this._cache=(0,p.pR)(this._cache)}get layer(){return this._cache}get size(){if(!this._cache?.loaded||!this._cache.serviceRasterInfo)return;const{serviceRasterInfo:e}=this._cache;return[e.width,e.height]}async load(e){if(this._cache?.loaded)return await this._cache.load(e),{layer:this._cache,size:this.size};const{url:t,customParameters:r}=this;let s=this.datasetFormat;if(!t)throw new Error("URL is required to load NonPanoramicMedia.");const a=await n.e(7835).then(n.bind(n,97835));if((0,i.Te)(e),s||(s=a.guessExtensionFromURI(t)),!s){try{s=await a.getDatasetFormat(t)}catch(e){o.A.getLogger(this).warn("non-panoramic-media:dataset-format",e)}(0,i.Te)(e)}s??="UNKNOWN FORMAT",this.datasetFormat=s;const l=(await Promise.all([n.e(7373),n.e(9235),n.e(3500),n.e(1003),n.e(2806),n.e(561)]).then(n.bind(n,90561))).default;(0,i.Te)(e),this._cache=new l({url:t,ioConfig:{skipExtensions:["aux.xml","jgw"],skipMapInfo:!0,datasetFormat:s},customParameters:r??void 0});const c=this._cache.load(e);return this.addResolvingPromise(c),await c,(0,i.Te)(e),{layer:this._cache,size:this.size}}};(0,h.Cg)([(0,d.MZ)()],g.prototype,"_cache",void 0),(0,h.Cg)([(0,d.MZ)()],g.prototype,"autoLoad",void 0),(0,h.Cg)([(0,d.MZ)()],g.prototype,"customParameters",void 0),(0,h.Cg)([(0,d.MZ)()],g.prototype,"datasetFormat",void 0),(0,h.Cg)([(0,d.MZ)()],g.prototype,"url",void 0),(0,h.Cg)([(0,d.MZ)()],g.prototype,"layer",null),(0,h.Cg)([(0,d.MZ)()],g.prototype,"rotation",void 0),(0,h.Cg)([(0,d.MZ)()],g.prototype,"size",null),g=(0,h.Cg)([(0,m.$)("esri.widgets.OrientedImageryViewer.support.NonPanoramicMedia")],g);var y=n(37955),v=n(38969);class w extends s.A{constructor(e,t,n){super(e,t,n),this.name="unknown",this.name=e}}const M=new Set(["JPG","JPEG","TIFF","TIF","MRF"]),x=new Set(["MRF","TIFF","TIF"]);let C=class extends f.Z{constructor(e){super(e),this._size=[0,0],this._cache=null,this.autoLoad=!1,this.cameraHeading=null,this.extension=null,this.imagePyramid=null,this.type="image",this.uiStrings={}}destroy(){this._cache=null}get horizonPitch(){const{matrix:e}=this;return e?(0,r.KJ)(Math.asin(-e[6])):0}get horizonRoll(){const{matrix:e}=this;return e?(0,r.KJ)(Math.atan(e[7]/e[8])):0}get horizonYaw(){const{matrix:e,cameraHeading:t}=this;return e?(0,r.KJ)(Math.atan2(e[3],e[0])):t?-t:0}get size(){return this._size}async load(e){const{guessExtensionFromURI:t}=await n.e(7835).then(n.bind(n,97835));if((0,i.Te)(e),"video"===this.type)return this.loadVideoMesh(e);let r=this.extension;if(r||(r=t(this.url)),!r||!M.has(r))throw new w("unsupported-format",this.uiStrings["unsupported-format"]??"Unsupported image format: {extension}",{datasetFormat:r??"UNKNOWN FORMAT"});return x.has(r)?this.loadOptimizedImageMesh(e):this.loadImageMesh(e)}async loadOptimizedImageMesh(e){const{loadMeshes:t,loadPyramid:r,loadRaster:s}=await Promise.all([n.e(6860),n.e(36),n.e(3494)]).then(n.bind(n,21060)),o=await s(this.url,e);(0,i.Te)(e),this.imagePyramid=await r(o,{pitch:this.horizonPitch,yaw:this.horizonYaw,roll:this.horizonRoll},e),(0,i.Te)(e);const a=this.imagePyramid.getLowResolutionTiles(),l=await t(a,e);return(0,i.Te)(e),this._size=this.imagePyramid.imageSize,{meshOrMeshes:l,size:this._size,tileKeys:a?.map(e=>e.key)}}async loadVideoMesh(e){const{createImageSphere:t}=await Promise.all([n.e(6860),n.e(36),n.e(3494)]).then(n.bind(n,21060));if((0,i.Te)(e),this._cache){const n=await t({data:this._cache,horizonPitch:this.horizonPitch,horizonRoll:this.horizonRoll,horizonYaw:this.horizonYaw}).load(e);return(0,i.Te)(e),{meshOrMeshes:n,size:this._size}}const r=await this._resolveMedia(e);(0,i.Te)(e),this._cache=r.media,this._size=[...l];const s=await t({data:this._cache,horizonPitch:this.horizonPitch,horizonRoll:this.horizonRoll,horizonYaw:this.horizonYaw}).load(e);return(0,i.Te)(e),{meshOrMeshes:s,size:this._size}}async loadImageMesh(e){const{createImageSphere:t}=await Promise.all([n.e(6860),n.e(36),n.e(3494)]).then(n.bind(n,21060));if((0,i.Te)(e),this._cache){const n=await t({data:this._cache,horizonPitch:this.horizonPitch,horizonRoll:this.horizonRoll,horizonYaw:this.horizonYaw}).load(e);return(0,i.Te)(e),{meshOrMeshes:n,size:this._size}}const r=await this._resolveMedia(e);(0,i.Te)(e),this._cache=r.media;const s=r.mesh;return this._size=[r.media.width,r.media.height],{meshOrMeshes:s,size:this._size}}async _resolveMedia(e){const t=Promise.withResolvers(),r=(0,i.u7)(e?.signal,t.resolve),s="video"===this.type?document.createElement("video"):document.createElement("img");s.crossOrigin="anonymous",s.src=this.url;let o=null;const a="video"===this.type?(0,v.i)(s,this.addHandles):await new Promise((e,t)=>{o=[(0,y.on)(s,"error",e=>{t(e)}),(0,y.on)(s,"load",e)]}).finally(()=>{o?.forEach(e=>e.remove()),o=null}),l=Promise.race([a,t.promise]);this.addResolvingPromise(l);try{await l}finally{r?.remove()}(0,i.Te)(e);const c=s;if(!c)throw new w("unknown","Could not load media",{url:this.url});const{createImageSphere:u}=await Promise.all([n.e(6860),n.e(36),n.e(3494)]).then(n.bind(n,21060));(0,i.Te)(e);const h=await u({data:s,horizonPitch:this.horizonPitch,horizonRoll:this.horizonRoll,horizonYaw:this.horizonYaw}).load(e);return(0,i.Te)(e),{media:c,mesh:h}}};function b(e){return function(e,t){const{cameraPitch:n,cameraRoll:r,cameraLocation:i}=e,{x:s,y:o,z:a,spatialReference:l}=i;if(t.every(e=>0===e)||!t||!t.length||!l)throw new Error("Invalid parameters");const[c,u,,h,p]=t,f=[-h,0,h],d=[-p,0,p],m=[-c,0,c],g=[-u,0,u],y=[];for(const t of f)for(const i of d)for(const c of m)for(const u of m)for(const h of g){const p={...e};p.cameraPitch=n+t,p.cameraRoll=r+i,p.cameraLocation={x:s+c,y:o+u,z:a?a+h:0,spatialReference:{wkid:l.wkid}},y.push(p)}return y}(e.imageToWorldProps,e.accuracyParameters)}function T(e){return function(e,t){const{cameraHeading:n,cameraLocation:r}=e,{x:i,y:s,z:o,spatialReference:a}=r;if(!t||t.every(e=>0===e)||!t.length||!a)throw new Error("Invalid parameters");const[l,c,u]=t,h=u>0?[-u,0,u]:[],p=l>0?[-l,0,l]:[],f=c>0?[-c,0,c]:[],d=[];for(const t of h)for(const r of p)for(const l of p)for(const c of f){const u={...e};u.cameraHeading=n+t,u.cameraLocation={x:i+r,y:s+l,z:o?o+c:0,spatialReference:{wkid:a.wkid}},d.push(u)}return d}(e.imageToWorldProps,e.accuracyParameters)}(0,h.Cg)([(0,d.MZ)()],C.prototype,"_size",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"autoLoad",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"cameraHeading",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"extension",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"horizonPitch",null),(0,h.Cg)([(0,d.MZ)()],C.prototype,"horizonRoll",null),(0,h.Cg)([(0,d.MZ)()],C.prototype,"horizonYaw",null),(0,h.Cg)([(0,d.MZ)()],C.prototype,"id",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"imagePyramid",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"matrix",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"size",null),(0,h.Cg)([(0,d.MZ)()],C.prototype,"type",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"uiStrings",void 0),(0,h.Cg)([(0,d.MZ)()],C.prototype,"url",void 0),C=(0,h.Cg)([(0,m.$)("esri.widgets.PanoramicViewer.support.PanoramicMedia")],C),n(9093),n(91829),n(58083),n(79258),n(73354),n(28208),n(28735)},28208(e,t,n){n.d(t,{NU:()=>a,ZH:()=>s,vK:()=>o});var r=n(86738),i=n(16930);const s=new r.A({x:0,y:0,z:0,spatialReference:i.A.WebMercator}),o=1e3,a=.3515625}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7451],{38961(e,t,r){r.d(t,{A:()=>p});var i=r(5482),s=r(7762),n=r(36708),o=r(10107),a=r(64108),l=r(80559);let u=class extends s.A{constructor(e){super(e),this.getCollections=null}initialize(){this.addHandles((0,l.fm)(()=>this._refresh(),n.OH))}destroy(){this.getCollections=null}_refresh(){const e=this.getCollections?.();if(null==e)return void this.removeAll();let t=0;for(const r of e)null!=r&&(t=this._processCollection(t,r));this.splice(t)}_createNewInstance(e){return new s.A(e)}_processCollection(e,t){if(!t)return e;const r=this.itemFilterFunction??(e=>!!e);for(const i of t)if(i){if(r(i)){const t=this.indexOf(i,e);t>=0?t!==e&&this.reorder(i,e):this.add(i,e),++e}if(this.getChildrenFunction){const t=this.getChildrenFunction(i);if(Array.isArray(t))for(const r of t)e=this._processCollection(e,r);else e=this._processCollection(e,t)}}return e}};(0,i.Cg)([(0,o.MZ)()],u.prototype,"getCollections",void 0),(0,i.Cg)([(0,o.MZ)()],u.prototype,"getChildrenFunction",void 0),(0,i.Cg)([(0,o.MZ)()],u.prototype,"itemFilterFunction",void 0),u=(0,i.Cg)([(0,a.$)("esri.core.CollectionFlattener")],u);const p=u},46140(e,t,r){r.d(t,{A:()=>s});var i=r(49186);class s{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}toString(){return`${this.major}.${this.minor}`}validate(e){if(this.major!==e.major){const t=this._context&&this._context+":",r=this._context&&this._context+" ";throw new i.A(t+"unsupported-version",`Required major ${r}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new s(this.major,this.minor,this._context)}static parse(e,t=""){const[r,n]=e.split("."),o=/^\s*\d+\s*$/;if(!r?.match||!o.test(r))throw new i.A((t&&t+":")+"invalid-version","Expected major version to be a number, but got '${version}'",{version:e});if(!n?.match||!o.test(n))throw new i.A((t&&t+":")+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:e});const a=parseInt(r,10),l=parseInt(n,10);return new s(a,l,t)}}},6797(e,t,r){r.d(t,{Ui:()=>d});var i=r(69622),s=r(7762),n=r(88620);const o=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function a(e){return e instanceof i.A}function l(e){return e instanceof s.A?Object.keys(e.items):a(e)?(0,n.oY)(e).keys():e?Object.keys(e):[]}function u(e,t){return e instanceof s.A?e.items[t]:e[t]}function p(e){return e?e.declaredClass:null}function c(e,t){const r=e.diff;if(r&&"function"==typeof r)return r(e,t);const i=l(e),s=l(t);if(0===i.length&&0===s.length)return;if(!i.length||!s.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};const n=s.filter(e=>!i.includes(e)),d=i.filter(e=>!s.includes(e)),y=i.filter(r=>s.includes(r)&&u(e,r)!==u(t,r)).concat(n,d).sort(),h=p(e);if(h&&o.has(h)&&y.length)return{type:"complete",oldValue:e,newValue:t};let f;const m=a(e)&&a(t);for(const i of y){const s=u(e,i),n=u(t,i);let o;if((m||"function"!=typeof s&&"function"!=typeof n)&&s!==n&&(null!=s||null!=n)){if(r&&r[i]&&"function"==typeof r[i])o=r[i]?.(s,n);else if(s instanceof Date&&n instanceof Date){if(s.getTime()===n.getTime())continue;o={type:"complete",oldValue:s,newValue:n}}else o="object"==typeof s&&"object"==typeof n&&p(s)===p(n)?c(s,n):{type:"complete",oldValue:s,newValue:n};null!=o&&(null!=f?f.diff[i]=o:f={type:"partial",diff:{[i]:o}})}}return f}function d(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&p(e)!==p(t)?{type:"complete",oldValue:e,newValue:t}:c(e,t)}},81583(e,t,r){r.d(t,{L:()=>a,g:()=>o});var i=r(60999),s=r(7762),n=r(92474);async function o(e,t){return await e.load(),a(e,t)}async function a(e,t){const r=[],o=(...e)=>{for(const t of e)null!=t&&(Array.isArray(t)?o(...t):s.A.isCollection(t)?t.forEach(e=>o(e)):(0,n.Zm)(t)&&r.push(t))};t(o);let a=null;if(await(0,i.Tj)(r,async e=>{const t=await(0,i.Ke)(function(e){return"loadAll"in e&&"function"==typeof e.loadAll}(e)?e.loadAll():e.load());!1!==t.ok||a||(a=t)}),a)throw a.error;return e}},62815(e,t,r){r.d(t,{N:()=>a,d:()=>l});var i=r(86211),s=r(73941),n=r(21325),o=r(52006);function a(e,t,r){const i=l(t,r);if(1!==i)switch(e){case"point":case"esriGeometryPoint":return e=>function(e,t){null!=e?.z&&(e.z*=t)}(e,i);case"polyline":case"esriGeometryPolyline":return e=>function(e,t){if(e){if(e.curvePaths)for(const r of e.curvePaths)for(const e of r){const r=(0,o.yP)(e);r.length>2&&(r[2]*=t)}if(e.paths)for(const r of e.paths)for(const e of r)e.length>2&&(e[2]*=t)}}(e,i);case"polygon":case"esriGeometryPolygon":return e=>function(e,t){if(e){if(e.curveRings)for(const r of e.curveRings)for(const e of r){const r=(0,o.yP)(e);r.length>2&&(r[2]*=t)}if(e.rings)for(const r of e.rings)for(const e of r)e.length>2&&(e[2]*=t)}}(e,i);case"multipoint":case"esriGeometryMultipoint":return e=>function(e,t){if(e)for(const r of e.points)r.length>2&&(r[2]*=t)}(e,i);case"extent":case"esriGeometryEnvelope":return e=>function(e,t){e&&null!=e.zmin&&null!=e.zmax&&(e.zmin*=t,e.zmax*=t)}(e,i);default:return}}function l(e,t){return null==e||null==t||(e.vcsWkid??null)!==(t.vcsWkid??null)||(0,n.aI)(e,t)||(0,s.xP)(e)||(0,s.xP)(t)?1:(0,i.G9)(e)/(0,i.G9)(t)}},64314(e,t,r){r.d(t,{A:()=>C});var i=r(5482),s=r(69622),n=r(49186),o=r(44208),a=r(17676),l=r(84952),u=r(91429),p=r(21325),c=r(20557),d=r(2272),y=r(65615),h=r(20615),f=r(74910),m=r(78286),g=r(99199),b=r(62815),w=r(63746);class v{constructor(e){this._options=e,this.featureSet={features:[]},this.parseOnly=null,this._transformInPlace=null,this._transformInPlaceXY=null,this._finishVertex=v._finishVertexNonPoint,this._attributesClass=null,this._previousX=0,this._previousY=0,this._point=null,this._lengths=null,this._vertex=[],this._part=null,this._parts=null,this._i=0}queryGeometryType(){return this.featureSet.queryGeometryType}queryGeometry(){return this.featureSet.queryGeometry}idField(e){"string"==typeof e&&(this.featureSet.objectIdFieldName=e)}finish(){this._options.applyTransform&&(this.featureSet.transform=null);const{spatialReference:e,features:t}=this.featureSet;if(e)for(const{geometry:r}of t)r&&(r.spatialReference=e)}feature(){this._attributesClass??=(0,w._7)(this.featureSet.fields?.map(e=>e.name)??[]),this.featureSet.features.push({attributes:new this._attributesClass}),this._options.applyTransform&&this._setVertexTransformer()}centroid([e,t]){this.featureSet.features.at(-1).centroid={x:e,y:t}}geometry(e,t,r){this._previousX=this._previousY=0,this._lengths=r;let i,{hasZ:s,hasM:n}=this.featureSet;switch(s??=!1,n??=!1,this._i=0,this._vertex=[0,0],s&&this._vertex.push(0),n&&this._vertex.push(0),this._finishVertex=v._finishVertexNonPoint,t){case"esriGeometryPoint":this._point={x:0,y:0},i=this._point,this._finishVertex=s?n?v._finishVertexPointXYZM:v._finishVertexPointXYZ:n?v._finishVertexPointXYM:v._finishVertexPointXY;break;case"esriGeometryMultipoint":i={points:[],hasZ:s,hasM:n},this._part=i.points,this._parts=[];break;case"esriGeometryPolyline":i={paths:[],hasZ:s,hasM:n},this._parts=i.paths,this._part=[];break;case"esriGeometryPolygon":i={rings:[],hasZ:s,hasM:n},this._parts=i.rings,this._part=[]}1===e?(this.featureSet.queryGeometry=i,this.featureSet.queryGeometryType=t,this._options.applyTransform||this._setVertexTransformer()):this.featureSet.features.at(-1).geometry=i}coord(e){const t=this._vertex;t[this._i++]=e,this._i<t.length||(this._i=0,this._transformInPlace&&(t[0]+=this._previousX,t[1]+=this._previousY,[this._previousX,this._previousY]=t,this._transformInPlace(t)),this._finishVertex(this))}curvedGeometry(e,t,r,i){let s,{hasZ:n,hasM:o}=this.featureSet;switch(n??=!1,o??=!1,e){case"esriGeometryPoint":case"esriGeometryMultipoint":throw new Error(`Curved ${e} does not make sense`);case"esriGeometryPolyline":s={paths:[],curvePaths:[],hasZ:n,hasM:o},this._parts=s.curvePaths,this._part=[];break;case"esriGeometryPolygon":s={rings:[],curveRings:[],hasZ:n,hasM:o},this._parts=s.curveRings,this._part=[]}this.featureSet.features.at(-1).geometry=s}startCurvedPart(e){this._part.push(this._transform(e))}finishCurvedPart(e){this._parts.push(this._part),this._part=[]}lineSegment(e,t){this._part.push(this._transform(t))}bezierSegment(e,t,r,i){this._part.push({b:[this._transform(t),this._transformXY(r),this._transformXY(i)]})}circularArcSegment(e,t,r){this._part.push({c:[this._transform(t),this._transformXY(r)]})}ellipticArcSegment(e,t,r,i,s,n,o,a){this._part.push({a:[this._transform(t),this._transformXY(r),i,s,n,o,a]})}static _finishVertexPointXY({_point:e,_vertex:t}){[e.x,e.y]=t}static _finishVertexPointXYZ({_point:e,_vertex:t}){[e.x,e.y,e.z]=t}static _finishVertexPointXYM({_point:e,_vertex:t}){[e.x,e.y,e.m]=t}static _finishVertexPointXYZM({_point:e,_vertex:t}){[e.x,e.y,e.z,e.m]=t}static _finishVertexNonPoint(e){const{_part:t,_parts:r,_lengths:i,_vertex:s}=e;t.push([...s]),t.length<i[r.length]||(e._previousX=e._previousY=0,e._part=[],r.push(t))}_setVertexTransformer(){const{sourceSpatialReference:e}=this._options,{spatialReference:t,hasZ:r,transform:i}=this.featureSet,s=r?(0,b.d)(e,t):1;this._transformInPlace??=(0,w.Mv)(this.featureSet,s),this._transformInPlaceXY??=(0,w.Mv)({transform:i})}_transform(e){const t=[...e];return this._transformInPlace?.(t),t}_transformXY(e){const t=[e[0],e[1]];return this._transformInPlaceXY?.(t),t}}var S=r(80893),_=r(22671),I=r(61956);async function x(e,t,r,i){const s=(0,d.Dl)(e),n={...r},o=I.A.from(t),a=!o.quantizationParameters;return await(0,S.IJ)(s,o,new v({sourceSpatialReference:o.sourceSpatialReference,applyTransform:a}),n,i)}let C=class extends s.A{constructor(e){super(e),this.dynamicDataSource=null,this.fieldsIndex=null,this.gdbVersion=null,this.infoFor3D=null,this.pbfSupported=!1,this.pbfSupportedWithCurves=!1,this.queryAttachmentsSupported=!1,this.relativeTimeBinWindow=0,this.sourceSpatialReference=null,this.uniqueIdFields=null,this.url=null}get parsedUrl(){return(0,l.An)(this.url)}async execute(e,t){const r=await this.executeJSON(e,t);return this.featureSetFromJSON(e,r,t)}async executeJSON(e,t){const r=this._normalizeQuery(e),i=null!=e.outStatistics?.[0],s=(0,o.A)("featurelayer-pbf-statistics");let n;if(this.pbfSupported&&(!i||s)&&(!e.returnTrueCurves||this.pbfSupportedWithCurves))try{n=await x(this.url,r,t,{uniqueIdFields:this.uniqueIdFields})}catch(e){if("query:parsing-pbf"!==e.name)throw e;this.pbfSupported=!1}return n??=await(0,g.e)(this.url,r,t,{uniqueIdFields:this.uniqueIdFields}),this._normalizeFields(n.fields),n}async featureSetFromJSON(e,t,i){if(!this._queryGet3DObjectFormat(e)||null==this.infoFor3D||!t.features)return _.A.fromJSON(t);const{meshFeatureSetFromJSON:s}=await(0,a.qr)(Promise.all([r.e(6860),r.e(36),r.e(8366)]).then(r.bind(r,40050)),i);return s(e,this.infoFor3D,t)}executeForCount(e,t){return(0,h.I)(this.url,this._normalizeQuery(e),t,{uniqueIdFields:this.uniqueIdFields})}executeForExtent(e,t){return(0,f.L)(this.url,this._normalizeQuery(e),t)}executeForIds(e,t){return(0,m.V)(this.url,this._normalizeQuery(e),t,{uniqueIdFields:this.uniqueIdFields})}async executeRelationshipQuery(e,t){const[{default:i},{executeRelationshipQuery:s}]=await(0,a.qr)(Promise.all([Promise.resolve().then(r.bind(r,26591)),r.e(1763).then(r.bind(r,71763))]),t);let n=i.from(e);return(this.gdbVersion||this.dynamicDataSource)&&(n=n.clone(),n.gdbVersion=n.gdbVersion||this.gdbVersion,n.dynamicDataSource=n.dynamicDataSource||this.dynamicDataSource),s(this.url,n,t)}async executeRelationshipQueryForCount(e,t){const[{default:i},{executeRelationshipQueryForCount:s}]=await(0,a.qr)(Promise.all([Promise.resolve().then(r.bind(r,26591)),r.e(1763).then(r.bind(r,71763))]),t);let n=i.from(e);return(this.gdbVersion||this.dynamicDataSource)&&(n=n.clone(),n.gdbVersion=n.gdbVersion||this.gdbVersion,n.dynamicDataSource=n.dynamicDataSource||this.dynamicDataSource),s(this.url,n,t)}async executeAttachmentQuery(e,t){const{executeAttachmentQuery:i,fetchAttachments:s,processAttachmentQueryResult:n}=await(0,a.qr)(r.e(9239).then(r.bind(r,9239)),t),o=(0,d.Dl)(this.url);return n(o,await(this.queryAttachmentsSupported?i(o,e,t):s(o,e,t)))}async executeAttributeBinsQuery(e,t){const{executeAttributeBinsQuery:i}=await(0,a.qr)(r.e(3103).then(r.bind(r,33103)),t);return i(this.parsedUrl,e,t)}async executePivotQuery(e,t){const{executePivotQuery:i}=await(0,a.qr)(r.e(566).then(r.bind(r,80566)),t);return i(this.parsedUrl,e,t)}async executeTopFeaturesQuery(e,t){const{executeTopFeaturesQuery:i}=await(0,a.qr)(r.e(1273).then(r.bind(r,11273)),t);return i(this.parsedUrl,e,this.sourceSpatialReference,t)}async executeForTopIds(e,t){const{executeForTopIds:i}=await(0,a.qr)(r.e(1277).then(r.bind(r,21277)),t);return i(this.parsedUrl,e,t)}async executeForTopExtents(e,t){const{executeForTopExtents:i}=await(0,a.qr)(r.e(8018).then(r.bind(r,8018)),t);return i(this.parsedUrl,e,t)}async executeForTopCount(e,t){const{executeForTopCount:i}=await(0,a.qr)(r.e(980).then(r.bind(r,10980)),t);return i(this.parsedUrl,e,t)}_normalizeQuery(e){let t=I.A.from(e);t.sourceSpatialReference=t.sourceSpatialReference||this.sourceSpatialReference,(this.gdbVersion||this.dynamicDataSource)&&(t=t===e?t.clone():t,t.gdbVersion=e.gdbVersion||this.gdbVersion,t.dynamicDataSource=e.dynamicDataSource?y.A.from(e.dynamicDataSource):this.dynamicDataSource);const{infoFor3D:r}=this,i=this._queryGet3DObjectFormat(e);if(null!=r&&i){if(t=t===e?t.clone():t,t.formatOf3DObjects=i,t.outSpatialReference&&!(0,p.aI)(t.outSpatialReference,this.sourceSpatialReference))throw new n.A("query:unsupported-out-spatial-reference","3D object feature services do not support projection of geometries");if(null==t.outFields||!t.outFields.includes("*")){t=t===e?t.clone():t,null==t.outFields&&(t.outFields=[]);const{originX:i,originY:s,originZ:n,translationX:o,translationY:a,translationZ:l,scaleX:u,scaleY:p,scaleZ:c,rotationX:d,rotationY:y,rotationZ:h,rotationDeg:f}=r.transformFieldRoles;t.outFields.push(i,s,n,o,a,l,u,p,c,d,y,h,f)}}return t}_normalizeFields(e){if(null!=this.fieldsIndex&&null!=e)for(const t of e){const e=this.fieldsIndex.get(t.name);e&&Object.assign(t,e.toJSON())}}_queryGet3DObjectFormat({returnGeometry:e,multipatchOption:t,outStatistics:r}){return!0!==e||"xyFootprint"===t||r?null:(0,c.Hz)(this.infoFor3D)}};(0,i.Cg)([(0,u.MZ)({type:y.A})],C.prototype,"dynamicDataSource",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"fieldsIndex",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"gdbVersion",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"infoFor3D",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],C.prototype,"parsedUrl",null),(0,i.Cg)([(0,u.MZ)()],C.prototype,"pbfSupported",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"pbfSupportedWithCurves",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"queryAttachmentsSupported",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"relativeTimeBinWindow",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"sourceSpatialReference",void 0),(0,i.Cg)([(0,u.MZ)()],C.prototype,"uniqueIdFields",void 0),(0,i.Cg)([(0,u.MZ)({type:String})],C.prototype,"url",void 0),C=(0,i.Cg)([(0,u.$K)("esri.layers.graphics.sources.support.QueryTask")],C)},52136(e,t,r){r.d(t,{p:()=>n});var i=r(5482),s=r(91429);const n=e=>{const t=e;let r=class extends t{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,i.Cg)([(0,s.MZ)({type:String})],r.prototype,"apiKey",null),r=(0,i.Cg)([(0,s.$K)("esri.layers.mixins.APIKeyMixin")],r),r}},98534(e,t,r){r.d(t,{V:()=>m});var i=r(5482),s=r(11254),n=r(91869),o=r(17676),a=r(84952),l=r(46140),u=r(91429),p=r(5443),c=r(16930),d=r(60694),y=r(10873),h=r(10407),f=r(36005);const m=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.capabilities=void 0,this.copyright=null,this.fullExtent=null,this.legendEnabled=!0,this.spatialReference=null,this.version=void 0,this._allLayersAndTablesMap=null}readCapabilities(e,t){const r=t.capabilities&&t.capabilities.split(",").map(e=>e.toLowerCase().trim());if(!r)return{operations:{supportsExportMap:!1,supportsExportTiles:!1,supportsIdentify:!1,supportsQuery:!1,supportsTileMap:!1},exportMap:null,exportTiles:null};const i=this.type,s="tile"!==i&&!!t.supportsDynamicLayers,n=r.includes("query"),o=r.includes("map"),a=!!t.exportTilesAllowed,u=r.includes("tilemap"),p=r.includes("data"),c="tile"!==i&&(!t.tileInfo||s),d="tile"!==i&&(!t.tileInfo||s),y="tile"!==i,h="tile"!==i&&s&&t.currentVersion>=11.1,f=t.cimVersion?l.A.parse(t.cimVersion):null,m=f?.greaterEqual(1,4)??!1,g=f?.greaterEqual(2,0)??!1;return{operations:{supportsExportMap:o,supportsExportTiles:a,supportsIdentify:n,supportsQuery:p,supportsTileMap:u},exportMap:o?{supportsArcadeExpressionForLabeling:m,supportsCIMSymbols:g,supportsDynamicLayers:s,supportsSublayerOrderBy:h,supportsSublayerDefinitionExpression:d,supportsSublayerVisibility:c,supportsSublayersChanges:y}:null,exportTiles:a?{maxExportTilesCount:+t.maxExportTilesCount}:null}}readVersion(e,t){let r=t.currentVersion;return r||(r=t.hasOwnProperty("capabilities")||t.hasOwnProperty("tables")?10:t.hasOwnProperty("supportedImageFormatTypes")?9.31:9.3),r}async fetchRelatedService(e){const t=this.portalItem;if(!t||!(0,h.bK)(t))return null;this._relatedFeatureServicePromise||(this._relatedFeatureServicePromise=t.fetchRelatedItems({relationshipType:"Service2Service",direction:"reverse"},e).then(e=>e.find(e=>"Feature Service"===e.type)??null,()=>null));const r=await this._relatedFeatureServicePromise;return(0,o.Te)(e),r?{itemId:r.id,url:r.url}:null}async fetchSublayerInfo(e,t){const{source:r}=e;if(this?.portalItem&&"tile"===this.type&&"map-layer"===r?.type&&(0,h.bK)(this.portalItem)&&e.originIdOf("url")<2){const i=await this.fetchRelatedService(t);i&&(e.url=(0,a.fj)(i.url,r.mapLayerId.toString()),e.layerItemId=i.itemId)}const{url:i}=e;let n;if("data-layer"===r.type)n=(await(0,s.A)(i,{responseType:"json",query:{f:"json",...this.customParameters,token:this.apiKey},...t})).data;else{let s=e.id;"map-layer"===r?.type&&(s=r.mapLayerId);try{n=(await this.fetchAllLayersAndTables(t)).get(s)}catch{}if(i&&e.originIdOf("url")>2)try{const e=await this._fetchAllLayersAndTablesFromService(i),t=(0,d.qg)(i)?.sublayer??r.mapLayerId,s=structuredClone(e.get(t));if(null!=s){const e=["drawingInfo","maxScale","minScale","name"];for(const t of e)delete s[t];n={...n,...s}}}catch{}}return n}async fetchAllLayersAndTables(e){return this._fetchAllLayersAndTablesFromService(this.parsedUrl?.path,e)}async _fetchAllLayersAndTablesFromService(e,t){await this.load(t),this._allLayersAndTablesMap||=new Map;const r=(0,d.qg)(e),i=(0,n.tE)(this._allLayersAndTablesMap,r?.url.path,()=>(0,s.A)((0,a.fj)(r?.url.path,"/layers"),{responseType:"json",query:{f:"json",...this.customParameters,token:this.apiKey}}).then(e=>{const t=new Map,{layers:r,tables:i}=e.data,s=[...r??[],...i??[]];for(const e of s)t.set(e.id,e);return{result:t}},e=>({error:e}))),l=await i;if((0,o.Te)(t),"result"in l)return l.result;throw l.error}};return(0,i.Cg)([(0,u.MZ)({readOnly:!0})],r.prototype,"capabilities",void 0),(0,i.Cg)([(0,f.w)("service","capabilities",["capabilities","cimVersion","currentVersion","exportTilesAllowed","maxExportTilesCount","supportsDynamicLayers","tileInfo"])],r.prototype,"readCapabilities",null),(0,i.Cg)([(0,u.MZ)({json:{read:{source:"copyrightText"}}})],r.prototype,"copyright",void 0),(0,i.Cg)([(0,u.MZ)({type:p.A})],r.prototype,"fullExtent",void 0),(0,i.Cg)([(0,u.MZ)(y.id)],r.prototype,"id",void 0),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{origins:{service:{read:{enabled:!1}}},read:{source:"showLegend"},write:{target:"showLegend"}}})],r.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,u.MZ)(y.M6)],r.prototype,"popupEnabled",void 0),(0,i.Cg)([(0,u.MZ)({type:c.A})],r.prototype,"spatialReference",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],r.prototype,"version",void 0),(0,i.Cg)([(0,f.w)("service","version",["currentVersion","capabilities","tables","supportedImageFormatTypes"])],r.prototype,"readVersion",null),r=(0,i.Cg)([(0,u.$K)("esri.layers.mixins.ArcGISMapService")],r),r}},32756(e,t,r){r.d(t,{Rr:()=>a,fY:()=>u,ne:()=>l});var i=r(5482),s=r(93637),n=r(91429),o=r(91880);function a(e,t,r){if(!e)return null;const i=e.find(e=>!!e.field);if(!i)return null;const s=new o.A;return s.read(i,r),[s]}const l={type:[o.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:a},write:{writer:function(e,t,r,i){const n=e.find(e=>!!e.field);n&&(0,s.sM)(r,[n.toJSON()],t)}}}},u=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,i.Cg)([(0,n.MZ)(l)],r.prototype,"orderBy",void 0),r=(0,i.Cg)([(0,n.$K)("esri.layers.mixins.OrderedLayer")],r),r}},91921(e,t,r){r.d(t,{I:()=>m});var i=r(5482),s=r(7762),n=r(38961),o=r(49186),a=r(53966),l=r(36708),u=r(91429),p=r(35666),c=r(88620),d=r(15775),y=r(63389);const h=s.A.ofType(d.A);function f(e,t){e&&e.forEach(e=>{t(e),e.sublayers&&e.sublayers.length&&f(e.sublayers,t)})}const m=e=>{const t=e;let r=class extends t{constructor(...e){super(...e),this.allSublayers=new n.A({getCollections:()=>[this.sublayers],getChildrenFunction:e=>e.sublayers}),this.sublayersSourceJSON={2:{},3:{},4:{},5:{},6:{}},this.subtables=null,this.addHandles([(0,l.wB)(()=>this.sublayers,(e,t)=>this._handleSublayersChange(e,t),l.OH),(0,l.wB)(()=>this.subtables,(e,t)=>this._handleSublayersChange(e,t),l.OH)])}destroy(){this.allSublayers.destroy()}readSublayers(e,t){if(!t||!e)return;const{sublayersSourceJSON:r}=this,i=(0,p.aB)(t.origin);if(i<2)return;if(r[i]={context:t,visibleLayers:e.visibleLayers||r[i].visibleLayers,layers:e.layers||r[i].layers},i>2)return;this._set("serviceSublayers",this.createSublayersForOrigin("service").sublayers);const{sublayers:s,origin:n}=this.createSublayersForOrigin("web-document"),o=(0,c.oY)(this);o.setDefaultOrigin(n),this._set("sublayers",new h(s)),o.setDefaultOrigin("user")}findSublayerById(e){return this.allSublayers.find(t=>t.id===e)}createServiceSublayers(){return this.createSublayersForOrigin("service").sublayers}createSublayersForOrigin(e){let t;const r=(0,p.aB)("web-document"===e?"web-map":e);let i=2,s=this.sublayersSourceJSON[2].layers,n=this.sublayersSourceJSON[2].context,o=null;const a=[3,4,5].filter(e=>e<=r);for(const e of a){const t=this.sublayersSourceJSON[e];(0,y._X)(t.layers)&&(i=e,s=t.layers,n=t.context,t.visibleLayers&&(o={visibleLayers:t.visibleLayers,context:t.context}))}const l=[3,4,5].filter(e=>e>i&&e<=r);let u=null;for(const e of l){const{layers:r,visibleLayers:i,context:s}=this.sublayersSourceJSON[e];r&&(u={layers:r,context:s},t??=e),i&&(o={visibleLayers:i,context:s})}const c=function(e,t){const r=[],i={};return e?(e.forEach(e=>{const s=new d.A;if(s.read(e,t),i[s.id]=s,null!=e.parentLayerId&&-1!==e.parentLayerId){const t=i[e.parentLayerId];t.sublayers||(t.sublayers=[]),t.sublayers.unshift(s)}else r.unshift(s)}),r):r}(s,n),m=new Map,g=new Set;if(u)for(const e of u.layers)m.set(e.id,e);if(o?.visibleLayers)for(const e of o.visibleLayers)g.add(e);return f(c,e=>{u&&e.read(m.get(e.id),u.context),o&&e.read({defaultVisibility:g.has(e.id)},o.context)}),{origin:(0,p.OL)(i),originWithPartialOverrides:t?(0,p.OL)(t):null,sublayers:new h({items:c})}}read(e,t){super.read(e,t),this.readSublayers(e,t)}_handleSublayersChange(e,t){t&&(t.forEach(e=>{e.parent=null,e.layer=null}),this.removeHandles("sublayers-owner")),e&&(e.forEach(e=>{e.parent=this,e.layer=this}),this.addHandles([e.on("after-add",({item:e})=>{e.parent=this,e.layer=this}),e.on("after-remove",({item:e})=>{e.parent=null,e.layer=null})],"sublayers-owner"),"tile"===this.type&&this.addHandles(e.on("before-changes",e=>{a.A.getLogger("esri.layers.TileLayer").error(new o.A("tilelayer:sublayers-non-modifiable","Sublayer can't be added, moved, or removed from the layer's sublayers",{layer:this})),e.preventDefault()}),"sublayers-owner"))}};return(0,i.Cg)([(0,u.MZ)({readOnly:!0})],r.prototype,"allSublayers",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0,type:s.A.ofType(d.A)})],r.prototype,"serviceSublayers",void 0),(0,i.Cg)([(0,u.MZ)({value:null,type:h,json:{read:!1,write:{allowNull:!0,ignoreOrigin:!0}}})],r.prototype,"sublayers",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],r.prototype,"sublayersSourceJSON",void 0),(0,i.Cg)([(0,u.MZ)({type:h,json:{read:{source:"tables"}}})],r.prototype,"subtables",void 0),r=(0,i.Cg)([(0,u.$K)("esri.layers.mixins.SublayersOwner")],r),r}},28032(e,t,r){r.d(t,{A:()=>l});var i=r(5482),s=r(69540),n=r(25482),o=r(91429),a=r(56400);let l=class extends((0,s.OU)(n.o)){constructor(e){super(e),this.creatorField=null,this.creationDateField=null,this.editorField=null,this.editDateField=null,this.realm=null,this.timeZone=null}};(0,i.Cg)([(0,o.MZ)()],l.prototype,"creatorField",void 0),(0,i.Cg)([(0,o.MZ)()],l.prototype,"creationDateField",void 0),(0,i.Cg)([(0,o.MZ)()],l.prototype,"editorField",void 0),(0,i.Cg)([(0,o.MZ)()],l.prototype,"editDateField",void 0),(0,i.Cg)([(0,o.MZ)()],l.prototype,"realm",void 0),(0,i.Cg)([(0,o.MZ)((0,a.P6)("dateFieldsTimeReference",!0))],l.prototype,"timeZone",void 0),l=(0,i.Cg)([(0,o.$K)("esri.layers.support.EditFieldsInfo")],l)},29005(e,t,r){r.d(t,{A:()=>u});var i=r(5482),s=r(69540),n=r(66552),o=r(25482),a=r(91429);const l=new n.J({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let u=class extends((0,s.OU)(o.o)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"name",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"description",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:l.read,write:l.write}})],u.prototype,"drawingTool",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"prototype",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],u.prototype,"thumbnail",void 0),u=(0,i.Cg)([(0,a.$K)("esri.layers.support.FeatureTemplate")],u)},33143(e,t,r){r.d(t,{A:()=>c});var i=r(5482),s=r(69540),n=r(25482),o=r(91429),a=r(8631),l=r(29005),u=r(36005),p=r(43937);let c=class extends((0,s.OU)(n.o)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,a.r)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,i.Cg)([(0,o.MZ)({json:{write:!0}})],c.prototype,"id",void 0),(0,i.Cg)([(0,o.MZ)({json:{write:!0}})],c.prototype,"name",void 0),(0,i.Cg)([(0,o.MZ)({json:{write:!0}})],c.prototype,"domains",void 0),(0,i.Cg)([(0,u.w)("domains")],c.prototype,"readDomains",null),(0,i.Cg)([(0,p.K)("domains")],c.prototype,"writeDomains",null),(0,i.Cg)([(0,o.MZ)({type:[l.A],json:{write:!0}})],c.prototype,"templates",void 0),c=(0,i.Cg)([(0,o.$K)("esri.layers.support.FeatureType")],c)},37352(e,t,r){r.d(t,{A:()=>l});var i,s=r(5482),n=r(7762),o=r(25482),a=r(91429);let l=i=class extends o.o{constructor(e){super(e),this.floorField=null,this.viewAllMode=!1,this.viewAllLevelIds=new n.A}clone(){return new i({floorField:this.floorField,viewAllMode:this.viewAllMode,viewAllLevelIds:this.viewAllLevelIds})}};(0,s.Cg)([(0,a.MZ)({type:String,json:{write:{isRequired:!0}}})],l.prototype,"floorField",void 0),(0,s.Cg)([(0,a.MZ)({json:{read:!1,write:!1}})],l.prototype,"viewAllMode",void 0),(0,s.Cg)([(0,a.MZ)({json:{read:!1,write:!1}})],l.prototype,"viewAllLevelIds",void 0),l=i=(0,s.Cg)([(0,a.$K)("esri.layers.support.LayerFloorInfo")],l)},91880(e,t,r){r.d(t,{A:()=>u});var i,s=r(5482),n=r(66552),o=r(25482),a=r(91429);const l=new n.J({asc:"ascending",desc:"descending"});let u=class extends o.o{static{i=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new i({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,s.Cg)([(0,a.MZ)({type:String,json:{write:!0}})],u.prototype,"field",void 0),(0,s.Cg)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],u.prototype,"valueExpression",void 0),(0,s.Cg)([(0,a.MZ)({type:l.apiValues,json:{type:l.jsonValues,read:l.read,write:l.write}})],u.prototype,"order",void 0),u=i=(0,s.Cg)([(0,a.$K)("esri.layers.support.OrderByInfo")],u)},45067(e,t,r){r.d(t,{A:()=>p});var i=r(5482),s=r(69540),n=r(66552),o=r(25482),a=r(91429);const l=new n.J({esriRelCardinalityOneToOne:"one-to-one",esriRelCardinalityOneToMany:"one-to-many",esriRelCardinalityManyToMany:"many-to-many"}),u=new n.J({esriRelRoleOrigin:"origin",esriRelRoleDestination:"destination"});let p=class extends((0,s.OU)(o.o)){constructor(e){super(e),this.cardinality=null,this.catalogId=null,this.composite=null,this.id=null,this.keyField=null,this.keyFieldInRelationshipTable=null,this.name=null,this.relatedTableId=null,this.relationshipTableId=null,this.role=null}};(0,i.Cg)([(0,a.MZ)({json:{read:l.read,write:l.write}})],p.prototype,"cardinality",void 0),(0,i.Cg)([(0,a.MZ)({json:{name:"catalogID"}})],p.prototype,"catalogId",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],p.prototype,"composite",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],p.prototype,"id",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],p.prototype,"keyField",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],p.prototype,"keyFieldInRelationshipTable",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],p.prototype,"name",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],p.prototype,"relatedTableId",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],p.prototype,"relationshipTableId",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:u.read,write:u.write}})],p.prototype,"role",void 0),p=(0,i.Cg)([(0,a.$K)("esri.layers.support.Relationship")],p)},15775(e,t,r){r.d(t,{A:()=>de});var i=r(5482),s=r(37838),n=r(11254),o=r(7762),a=r(49186),l=r(44208),u=r(4902),p=r(4718),c=r(92474),d=r(53966),y=r(25728),h=r(39516),f=r(84952),m=r(91429),g=r(56507),b=r(35666),w=r(88620),v=r(5443),S=r(16930),_=r(50498),I=r(89808),x=r(99959);const C=Symbol("isMapImageGraphicOriginSymbol");var A;class F extends x.A{get[(A=C,I.Q)](){return this.layer}constructor(e,t){super(),this[A]=!0,this.type="map-image",this.layer=e,this.sublayer=t}get id(){return`${this.layer.id}:__${this.sublayer.id}__`}}const T=Symbol("isTileGraphicOriginSymbol");var M;class O extends x.A{get[(M=T,I.Q)](){return this.layer}constructor(e,t){super(),this[M]=!0,this.type="tile",this.layer=e,this.sublayer=t}get id(){return`${this.layer.id}:__${this.sublayer.id}__`}}var D,P=r(64314),Z=r(32756),j=r(28032),q=r(15426),E=r(33143),L=r(20437),R=r(95466),V=r(30524),N=r(46499),$=r(39383),k=r(37352),B=r(91880),z=r(45067),J=r(6666),Q=r(41214),G=r(2272),K=r(65615),Y=r(93849),U=r(54546),X=r(61956),W=r(30291),H=r(33910),ee=r(43440),te=r(36005),re=r(43937);function ie(e){return"esriSMS"===e?.type}function se(e,t,r){const i=r.minimumWritableOrigin||r.origin;return!!i&&e.originIdOf(t)>=(0,b.aB)(i)}function ne(e,t,r){const i=se(this,t,r);return{ignoreOrigin:!0,allowNull:i,enabled:!!r&&"map-image"===r.layer?.type&&(r.writeSublayerStructure||i)}}function oe(e,t,r){return{enabled:!!r&&"tile"===r.layer?.type&&(se(this,t,r)||this._isOverridden(t))}}function ae(e,t,r){return{ignoreOrigin:!0,enabled:r&&r.writeSublayerStructure||!1}}function le(e,t,r){return{ignoreOrigin:!0,enabled:!!r?.writeSublayerStructure&&this.originIdOf(t)>2}}function ue(e,t,r){return{ignoreOrigin:!0,enabled:!!r&&(r.writeSublayerStructure||se(this,t,r))}}let pe=0;const ce=new Set(["layer","parent","loaded","loadStatus","loadError","loadWarnings"]);let de=class extends((0,y.M)((0,u.s)(c.x_))){static{D=this}constructor(e){super(e),this.attributeTableTemplate=null,this.capabilities=void 0,this.editFieldsInfo=null,this.maxScaleRange={minScale:0,maxScale:0},this.fields=null,this.fullExtent=null,this.geometryType=null,this.globalIdField=null,this.isTable=!1,this.legendEnabled=!0,this.objectIdField=null,this.parent=null,this.popupEnabled=!0,this.popupTemplate=null,this.relationships=null,this.sourceJSON=null,this.spatialReference=null,this.title=null,this.typeIdField=null,this.type="sublayer",this.types=null,this.uniqueIdFields=null,this._lastParsedUrl=null}async load(e){return this.addResolvingPromise(this.reload(e)),this}readCapabilities(e,t){t=t.layerDefinition||t;const{attachment:r,operations:{supportsQuery:i,supportsQueryAttachments:s},query:{supportsFormatPBF:n,supportsOrderBy:o,supportsPagination:a,relativeTimeBinWindow:l},data:{supportsAttachment:u},queryRelated:p}=(0,J.S$)(t,this.url);return{attachment:{supportsOrderByFields:r?.supportsOrderByFields??!1,supportsResize:r?.supportsResize??!1,supportsTypeWildcard:r?.supportsTypeWildcard??!1},exportMap:{supportsModification:!!t.canModifyLayer},operations:{supportsQuery:i,supportsQueryAttachments:s},data:{supportsAttachment:u},query:{relativeTimeBinWindow:l,supportsFormatPBF:n,supportsOrderBy:o,supportsPagination:a},queryRelated:p}}get defaultPopupTemplate(){return this.createPopupTemplate()}set definitionExpression(e){this._setAndNotifyLayer("definitionExpression",e)}get effectiveScaleRange(){const{minScale:e,maxScale:t}=this;return{minScale:e,maxScale:t}}readMaxScaleRange(e,t){return{minScale:(t=t.layerDefinition||t).minScale??0,maxScale:t.maxScale??0}}get fieldsIndex(){return new R.A(this.fields||[])}set floorInfo(e){this._setAndNotifyLayer("floorInfo",e)}readGlobalIdFieldFromService(e,t){if((t=t.layerDefinition||t).globalIdField)return t.globalIdField;if(t.fields)for(const e of t.fields)if("esriFieldTypeGlobalID"===e.type)return e.name}get graphicOrigin(){if(!this.layer)return null;switch(this.layer.type){case"tile":return new O(this.layer,this);case"map-image":return new F(this.layer,this)}}get id(){return this._get("id")??pe++}set id(e){this._get("id")!==e&&(!1!==this.layer?.capabilities?.exportMap?.supportsDynamicLayers?this._set("id",e):this._logLockedError("id","capability not available 'layer.capabilities.exportMap.supportsDynamicLayers'"))}readIsTable(e,t){return"Table"===t.type}set labelingInfo(e){this._setAndNotifyLayer("labelingInfo",e)}writeLabelingInfo(e,t,r,i){e&&e.length&&(t.layerDefinition={drawingInfo:{labelingInfo:e.map(e=>e.write({},i))}})}set labelsVisible(e){this._setAndNotifyLayer("labelsVisible",e)}set layer(e){this._set("layer",e),this.sublayers?.forEach(t=>t.layer=e)}set listMode(e){this._set("listMode",e)}set minScale(e){this._setAndNotifyLayer("minScale",e)}readMinScale(e,t){return t.minScale||t.layerDefinition?.minScale||0}set maxScale(e){this._setAndNotifyLayer("maxScale",e)}readMaxScale(e,t){return t.maxScale||t.layerDefinition?.maxScale||0}readObjectIdFieldFromService(e,t){if((t=t.layerDefinition||t).objectIdField)return t.objectIdField;const r=t.fields?.find(e=>"esriFieldTypeOID"===e.type);return r?.name}set opacity(e){this._setAndNotifyLayer("opacity",e)}readOpacity(e,t){const{layerDefinition:r}=t;return 1-.01*(r?.transparency??r?.drawingInfo?.transparency??0)}writeOpacity(e,t,r,i){t.layerDefinition={drawingInfo:{transparency:100-100*e}}}set orderBy(e){this._setAndNotifyLayer("orderBy",e)}writeParent(e,t){this.parent&&this.parent!==this.layer?t.parentLayerId=(0,g.Vr)(this.parent.id):t.parentLayerId=-1}get queryTask(){if(!this.layer)return null;const{capabilities:e,fieldsIndex:t,layer:r,uniqueIdFields:i,url:s}=this,{spatialReference:n}=r,o="gdbVersion"in r?r.gdbVersion:void 0,a=(0,l.A)("featurelayer-pbf")&&e?.query.supportsFormatPBF;return new P.A({fieldsIndex:t,gdbVersion:o,pbfSupported:a,queryAttachmentsSupported:e?.operations?.supportsQueryAttachments??!1,relativeTimeBinWindow:e?.query?.relativeTimeBinWindow??0,sourceSpatialReference:n,uniqueIdFields:i,url:s})}set renderer(e){if((0,V.yp)(e,this.fieldsIndex),e)for(const t of e.symbols)if((0,H.wk)(t)){d.A.getLogger(this).warn("Sublayer renderer should use 2D symbols");break}this._setAndNotifyLayer("renderer",e)}get source(){return this._get("source")||new Y.A({mapLayerId:this.id})}set source(e){this._setAndNotifyLayer("source",e)}get sublayers(){return this._get("sublayers")}set sublayers(e){this._handleSublayersChange(e,this._get("sublayers")),this._set("sublayers",e)}castSublayers(e){return(0,g.dp)(o.A.ofType(D),e)}writeSublayers(e,t,r){this.sublayers?.length&&(t[r]=this.sublayers.map(e=>e.id).toArray().reverse())}readTitle(e,t){return t.layerDefinition?.name??t.name}readTypeIdField(e,t){let r=(t=t.layerDefinition||t).typeIdField;if(r&&t.fields){r=r.toLowerCase();const e=t.fields.find(e=>e.name.toLowerCase()===r);e&&(r=e.name)}return r}readUniqueIdFields(e,t){return t.layerDefinition?.uniqueIdInfo?.OIDFieldContainsHashValue?t.layerDefinition.uniqueIdInfo.fields:null}get url(){const e=this.layer?.parsedUrl??this._lastParsedUrl,t=this.source;if(!e)return null;if(this._lastParsedUrl=e,"map-layer"===t?.type)return`${e.path}/${t.mapLayerId}`;const r={layer:JSON.stringify({source:this.source})};return`${e.path}/dynamicLayer?${(0,f.x0)(r)}`}set url(e){this._overrideIfSome("url",e)}set visible(e){this._setAndNotifyLayer("visible",e)}writeVisible(e,t,r,i){t[r]=this.getAtOrigin("defaultVisibility","service")||e}clone(){const{store:e}=(0,w.oY)(this),t=new D;return(0,w.oY)(t).store=e.clone(ce),this.commitProperty("url"),t._lastParsedUrl=this._lastParsedUrl,t}createPopupTemplate(e){return(0,W.tn)(this,e)}createQuery(){return new X.A({returnGeometry:!0,where:this.definitionExpression||"1=1"})}async createFeatureLayer(){if(this.sublayers)return null;const e=(await Promise.all([r.e(7632),r.e(9953),r.e(1017),r.e(6606),r.e(9784),r.e(7609),r.e(7694)]).then(r.bind(r,29784))).default,{layer:t,url:i}=this;let s;if(i&&this.originIdOf("url")>2)s=new e({url:i});else{if(!t?.parsedUrl)throw new a.A("createFeatureLayer:missing-information","Cannot create a FeatureLayer without a url or a parent layer");{const r=t.parsedUrl;s=new e({url:r.path}),r&&this.source&&("map-layer"===this.source.type?s.layerId=this.source.mapLayerId:s.dynamicDataSource=this.source)}}return null!=t?.refreshInterval&&(s.refreshInterval=t.refreshInterval),this.definitionExpression&&(s.definitionExpression=this.definitionExpression),this.floorInfo&&(s.floorInfo=(0,p.o8)(this.floorInfo)),this.originIdOf("labelingInfo")>2&&(s.labelingInfo=(0,p.o8)(this.labelingInfo)),this.originIdOf("labelsVisible")>0&&(s.labelsVisible=this.labelsVisible),this.originIdOf("legendEnabled")>0&&(s.legendEnabled=this.legendEnabled),this.originIdOf("visible")>0&&(s.visible=this.visible),this.originIdOf("minScale")>0&&(s.minScale=this.minScale),this.originIdOf("maxScale")>0&&(s.maxScale=this.maxScale),this.originIdOf("opacity")>0&&(s.opacity=this.opacity),this.originIdOf("popupTemplate")>0&&(s.popupTemplate=(0,p.o8)(this.popupTemplate)),this.originIdOf("renderer")>2&&(s.renderer=(0,p.o8)(this.renderer)),"data-layer"===this.source?.type&&(s.dynamicDataSource=this.source.clone()),this.originIdOf("title")>0&&(s.title=this.title),"map-image"===t?.type&&t.originIdOf("customParameters")>0&&(s.customParameters=t.customParameters),"tile"===t?.type&&t.originIdOf("customParameters")>0&&(s.customParameters=t.customParameters),s}getField(e){return this.fieldsIndex.get(e)}getFeatureType(e){return(0,q.xd)(this.types,this.typeIdField,e)}getFieldDomain(e,t){const r=t?.feature,i=this.getFeatureType(r);if(i){const t=i.domains&&i.domains[e];if(t&&"inherited"!==t.type)return t}return this._getLayerDomain(e)}async queryAttachments(e,t){await this.load();let r=U.A.from(e);const i=this.capabilities;if(!i?.data?.supportsAttachment)throw new a.A("queryAttachments:not-supported","this layer doesn't support attachments");const{attachmentTypes:s,objectIds:n,globalIds:o,num:l,size:u,start:p,where:c}=r;if(!i?.operations?.supportsQueryAttachments&&(s?.length>0||o?.length>0||u?.length>0||l||p||c))throw new a.A("queryAttachments:option-not-supported","when 'capabilities.operations.supportsQueryAttachments' is false, only objectIds is supported",r);if(!(n?.length||o?.length||c))throw new a.A("queryAttachments:invalid-query","'objectIds', 'globalIds', or 'where' are required to perform attachment query",r);return!i?.attachment?.supportsOrderByFields&&r.orderByFields?.length&&(r=r.clone(),r.orderByFields=null),this.queryTask.executeAttachmentQuery(r,t)}async queryFeatureCount(e=this.createQuery(),t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new a.A("queryFeatureCount:not-supported","this layer doesn't support queries.");if(!this.url)throw new a.A("queryFeatureCount:not-supported","this layer has no url.");const r=this.layer?.apiKey;return await this.queryTask.executeForCount(e,{...t,query:{...this.layer?.customParameters,token:r}})}async queryFeatures(e=this.createQuery(),t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new a.A("queryFeatures:not-supported","this layer doesn't support queries.");if(!this.url)throw new a.A("queryFeatures:not-supported","this layer has no url.");const r=await this.queryTask.execute(e,{...t,query:{...this.layer?.customParameters,token:this.layer?.apiKey}});if(r?.features){const e=this.graphicOrigin;for(const t of r.features)t.sourceLayer=this,t.origin=e}return r}async queryObjectIds(e=this.createQuery(),t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new a.A("queryObjectIds:not-supported","this layer doesn't support queries.");if(!this.url)throw new a.A("queryObjectIds:not-supported","this layer has no url.");const r=this.layer?.apiKey;return await this.queryTask.executeForIds(e,{...t,query:{...this.layer?.customParameters,token:r}})}async queryRelatedFeatures(e,t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new a.A("queryRelatedFeatures:not-supported","this layer doesn't support queries.");if(!this.url)throw new a.A("queryRelatedFeatures:not-supported","this layer has no url.");const r=this.layer?.apiKey;return await this.queryTask.executeRelationshipQuery(e,{...t,query:{...this.layer?.customParameters,token:r}})}async queryRelatedFeaturesCount(e,t){if(await this.load(),!this.capabilities.operations.supportsQuery)throw new a.A("queryRelatedFeaturesCount:not-supported","this layer doesn't support queries.");if(!this.capabilities.queryRelated.supportsCount)throw new a.A("queryRelatedFeaturesCount:not-supported","this layer doesn't support query related counts.");if(!this.url)throw new a.A("queryRelatedFeaturesCount:not-supported","this layer has no url.");const r=this.layer?.apiKey;return await this.queryTask.executeRelationshipQueryForCount(e,{...t,query:{...this.layer?.customParameters,token:r}})}async reload(e){if("not-loaded"===this.loadStatus)return this.load(e).then(()=>{});const{layer:t,url:r}=this;if(!t&&!r)throw new a.A("sublayer:missing-layer","Sublayer can't be loaded without being part of a layer",{sublayer:this});const i=t?await t.fetchSublayerInfo(this,e):(await(0,n.A)(r,{query:{f:"json"},...e})).data;i&&(this.sourceJSON={...this.sourceJSON,...i},this.read({layerDefinition:i},{origin:"service",layer:t,url:(0,G.Dl)(r)}))}toExportImageJSON(e){const t={id:this.id,source:this.source?.toJSON()||{mapLayerId:this.id,type:"mapLayer"}},r=(0,h.mA)(e,this.definitionExpression);null!=r&&(t.definitionExpression=r);const i=["renderer","labelingInfo","opacity","labelsVisible"].reduce((e,t)=>(e[t]=this.originIdOf(t),e),{}),s=Object.keys(i).some(e=>i[e]>2);if(s){const e=t.drawingInfo={};if(i.renderer>2&&(e.renderer=this.renderer?this.renderer.toJSON():null),i.labelsVisible>2&&(e.showLabels=this.labelsVisible),this.labelsVisible&&i.labelingInfo>2)if(this.labelingInfo){!this.loaded&&this.labelingInfo?.some(e=>!e.labelPlacement)&&d.A.getLogger(this).warnOnce(`A Sublayer (title: ${this.title}, id: ${this.id}) has an undefined 'labelPlacement' and so labels cannot be displayed. Either define a valid 'labelPlacement' or call Sublayer.load() to use a default value based on geometry type.`,{sublayer:this});let t=this.labelingInfo;null!=this.geometryType&&(t=(0,$.z)(this.labelingInfo,_.gy.toJSON(this.geometryType))),e.showLabels=!0,e.labelingInfo=t.filter(e=>e.labelPlacement).map(e=>e.toJSON({origin:"service",layer:this.layer}))}else e.showLabels=!1;i.opacity>2&&(e.transparency=100-100*this.opacity),this._assignDefaultSymbolColors(e.renderer)}return(this.layer?.capabilities?.exportMap?.supportsSublayerOrderBy??!1)&&this.originIdOf("orderBy")>2&&(t.orderBy=this.orderBy?.map(e=>e.toJSON())??null),t}_assignDefaultSymbolColors(e){this._forEachSimpleMarkerSymbols(e,e=>{e.color||"esriSMSX"!==e.style&&"esriSMSCross"!==e.style||(e.outline?.color?e.color=e.outline.color:e.color=[0,0,0,0])})}_forEachSimpleMarkerSymbols(e,t){if(e){const r=("uniqueValueInfos"in e?e.uniqueValueInfos:"classBreakInfos"in e?e.classBreakInfos:null)??[];for(const e of r)ie(e.symbol)&&t(e.symbol);"symbol"in e&&ie(e.symbol)&&t(e.symbol),"defaultSymbol"in e&&ie(e.defaultSymbol)&&t(e.defaultSymbol)}}_setAndNotifyLayer(e,t){const r=this.layer,i=this._get(e);let s,n;switch(e){case"definitionExpression":case"floorInfo":s="supportsSublayerDefinitionExpression";break;case"minScale":case"maxScale":case"visible":s="supportsSublayerVisibility";break;case"labelingInfo":case"labelsVisible":case"opacity":case"renderer":case"source":s="supportsDynamicLayers",n="supportsModification";break;case"orderBy":s="supportsSublayerOrderBy",n="supportsModification"}const o=(0,w.oY)(this).getDefaultOrigin();if("service"!==o){if(s&&!1===this.layer?.capabilities?.exportMap?.[s])return void this._logLockedError(e,`capability not available 'layer.capabilities.exportMap.${s}'`);if(n&&!1===this.capabilities?.exportMap[n])return void this._logLockedError(e,`capability not available 'capabilities.exportMap.${n}'`)}"source"!==e||"not-loaded"===this.loadStatus?(this._set(e,t),"service"!==o&&i!==t&&r?.emit&&r.emit("sublayer-update",{propertyName:e,target:this})):this._logLockedError(e,"'source' can't be changed after calling sublayer.load()")}_handleSublayersChange(e,t){t&&(t.forEach(e=>{e.parent=null,e.layer=null}),this.removeAllHandles()),e&&(e.forEach(e=>{e.parent=this,e.layer=this.layer}),this.addHandles([e.on("after-add",({item:e})=>{e.parent=this,e.layer=this.layer}),e.on("after-remove",({item:e})=>{e.parent=null,e.layer=null}),e.on("before-changes",e=>{(this.layer?.capabilities?.exportMap?.supportsSublayersChanges??1)||(d.A.getLogger(this).error(new a.A("sublayer:sublayers-non-modifiable","Sublayer can't be added, moved, or removed from the layer's sublayers",{sublayer:this,layer:this.layer})),e.preventDefault())})]))}_logLockedError(e,t){const{layer:r,declaredClass:i}=this;d.A.getLogger(i).error(new a.A("sublayer:locked",`Property '${String(e)}' can't be changed on Sublayer from the layer '${r?.id}'`,{reason:t,sublayer:this,layer:r}))}_getLayerDomain(e){return this.fieldsIndex.get(e)?.domain??null}static{this.test={isMapImageLayerOverridePolicy:e=>e===le||e===ae||e===ne,isTileImageLayerOverridePolicy:e=>e===oe}}};(0,i.Cg)([(0,m.MZ)({type:ee.A,json:{name:"attributeTableInfo",write:{overridePolicy:ne},origins:{"web-scene":{write:!1}}}})],de.prototype,"attributeTableTemplate",void 0),(0,i.Cg)([(0,m.MZ)({readOnly:!0})],de.prototype,"capabilities",void 0),(0,i.Cg)([(0,te.w)("service","capabilities",["layerDefinition.canModifyLayer","layerDefinition.capabilities"])],de.prototype,"readCapabilities",null),(0,i.Cg)([(0,m.MZ)()],de.prototype,"defaultPopupTemplate",null),(0,i.Cg)([(0,m.MZ)({type:String,value:null,json:{name:"layerDefinition.definitionExpression",write:{allowNull:!0,overridePolicy:ne}}})],de.prototype,"definitionExpression",null),(0,i.Cg)([(0,m.MZ)({readOnly:!0,type:j.A,json:{origins:{service:{read:{source:"layerDefinition.editFieldsInfo"}}}}})],de.prototype,"editFieldsInfo",void 0),(0,i.Cg)([(0,m.MZ)({readOnly:!0})],de.prototype,"effectiveScaleRange",null),(0,i.Cg)([(0,te.w)("service","maxScaleRange",["minScale","maxScale"])],de.prototype,"readMaxScaleRange",null),(0,i.Cg)([(0,m.MZ)({type:[L.A],json:{origins:{service:{read:{source:"layerDefinition.fields"}}}}})],de.prototype,"fields",void 0),(0,i.Cg)([(0,m.MZ)({readOnly:!0})],de.prototype,"fieldsIndex",null),(0,i.Cg)([(0,m.MZ)({type:k.A,value:null,json:{name:"layerDefinition.floorInfo",read:{source:"layerDefinition.floorInfo"},write:{target:"layerDefinition.floorInfo",overridePolicy:ne},origins:{"web-scene":{read:!1,write:!1}}}})],de.prototype,"floorInfo",null),(0,i.Cg)([(0,m.MZ)({type:v.A,json:{read:{source:"layerDefinition.extent"}}})],de.prototype,"fullExtent",void 0),(0,i.Cg)([(0,m.MZ)({type:_.gy.apiValues,json:{origins:{service:{name:"layerDefinition.geometryType",read:{reader:_.gy.read}}}}})],de.prototype,"geometryType",void 0),(0,i.Cg)([(0,m.MZ)({type:String})],de.prototype,"globalIdField",void 0),(0,i.Cg)([(0,te.w)("service","globalIdField",["layerDefinition.globalIdField","layerDefinition.fields"])],de.prototype,"readGlobalIdFieldFromService",null),(0,i.Cg)([(0,m.MZ)({readOnly:!0})],de.prototype,"graphicOrigin",null),(0,i.Cg)([(0,m.MZ)({type:g.jz,json:{write:{ignoreOrigin:!0}}})],de.prototype,"id",null),(0,i.Cg)([(0,m.MZ)({readOnly:!0})],de.prototype,"isTable",void 0),(0,i.Cg)([(0,te.w)("service","isTable",["type"])],de.prototype,"readIsTable",null),(0,i.Cg)([(0,m.MZ)({value:null,type:[N.A],json:{read:{source:"layerDefinition.drawingInfo.labelingInfo"},write:{target:"layerDefinition.drawingInfo.labelingInfo",overridePolicy:le}}})],de.prototype,"labelingInfo",null),(0,i.Cg)([(0,re.K)("labelingInfo")],de.prototype,"writeLabelingInfo",null),(0,i.Cg)([(0,m.MZ)({type:Boolean,value:!0,json:{read:{source:"layerDefinition.drawingInfo.showLabels"},write:{target:"layerDefinition.drawingInfo.showLabels",overridePolicy:ae}}})],de.prototype,"labelsVisible",null),(0,i.Cg)([(0,m.MZ)({value:null})],de.prototype,"layer",null),(0,i.Cg)([(0,m.MZ)({type:String,json:{write:{overridePolicy:oe}}})],de.prototype,"layerItemId",void 0),(0,i.Cg)([(0,m.MZ)({type:Boolean,value:!0,json:{origins:{service:{read:{enabled:!1}}},read:{source:"showLegend"},write:{target:"showLegend",overridePolicy:ue}}})],de.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,m.MZ)({type:["show","hide","hide-children"],value:"show",json:{read:!1,write:!1,origins:{"web-scene":{read:!0,write:!0}}}})],de.prototype,"listMode",null),(0,i.Cg)([(0,m.MZ)({type:Number,value:0,json:{write:{overridePolicy:ae}}})],de.prototype,"minScale",null),(0,i.Cg)([(0,te.w)("minScale",["minScale","layerDefinition.minScale"])],de.prototype,"readMinScale",null),(0,i.Cg)([(0,m.MZ)({type:Number,value:0,json:{write:{overridePolicy:ae}}})],de.prototype,"maxScale",null),(0,i.Cg)([(0,te.w)("maxScale",["maxScale","layerDefinition.maxScale"])],de.prototype,"readMaxScale",null),(0,i.Cg)([(0,m.MZ)()],de.prototype,"objectIdField",void 0),(0,i.Cg)([(0,te.w)("service","objectIdField",["layerDefinition.objectIdField","layerDefinition.fields"])],de.prototype,"readObjectIdFieldFromService",null),(0,i.Cg)([(0,m.MZ)({type:Number,value:1,json:{write:{target:"layerDefinition.drawingInfo.transparency",overridePolicy:ae}}})],de.prototype,"opacity",null),(0,i.Cg)([(0,te.w)("opacity",["layerDefinition.drawingInfo.transparency","layerDefinition.transparency"])],de.prototype,"readOpacity",null),(0,i.Cg)([(0,re.K)("opacity")],de.prototype,"writeOpacity",null),(0,i.Cg)([(0,m.MZ)({value:null,type:[B.A],json:{name:"layerDefinition.orderBy",read:{reader:Z.Rr},write:{overridePolicy:ne},origins:{"web-scene":{read:!1,write:!1}}}})],de.prototype,"orderBy",null),(0,i.Cg)([(0,m.MZ)({json:{type:g.jz,write:{target:"parentLayerId",writerEnsuresNonNull:!0,overridePolicy:ae}}})],de.prototype,"parent",void 0),(0,i.Cg)([(0,re.K)("parent")],de.prototype,"writeParent",null),(0,i.Cg)([(0,m.MZ)({type:Boolean,value:!0,json:{read:{source:"disablePopup",reader:(e,t)=>!t.disablePopup},write:{target:"disablePopup",overridePolicy:ue,writer(e,t,r){t[r]=!e}}}})],de.prototype,"popupEnabled",void 0),(0,i.Cg)([(0,m.MZ)({type:s.A,json:{read:{source:"popupInfo"},write:{target:"popupInfo",overridePolicy:ue}}})],de.prototype,"popupTemplate",void 0),(0,i.Cg)([(0,m.MZ)({readOnly:!0})],de.prototype,"queryTask",null),(0,i.Cg)([(0,m.MZ)({type:[z.A],readOnly:!0,json:{origins:{service:{read:{source:"layerDefinition.relationships"}}}}})],de.prototype,"relationships",void 0),(0,i.Cg)([(0,m.MZ)({types:Q.Hg,value:null,json:{name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:le},origins:{"web-scene":{types:Q.XJ,name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:le}}}}})],de.prototype,"renderer",null),(0,i.Cg)([(0,m.MZ)({types:{key:"type",base:null,typeMap:{"data-layer":K.A,"map-layer":Y.A}},cast(e){if(e){if("mapLayerId"in e)return(0,g.PZ)(Y.A,e);if("dataSource"in e)return(0,g.PZ)(K.A,e)}return e},json:{name:"layerDefinition.source",write:{overridePolicy:ae}}})],de.prototype,"source",null),(0,i.Cg)([(0,m.MZ)()],de.prototype,"sourceJSON",void 0),(0,i.Cg)([(0,m.MZ)({type:S.A,json:{origins:{service:{read:{source:"layerDefinition.extent.spatialReference"}}}}})],de.prototype,"spatialReference",void 0),(0,i.Cg)([(0,m.MZ)({value:null,json:{type:[g.jz],write:{target:"subLayerIds",allowNull:!0,overridePolicy:ae}}})],de.prototype,"sublayers",null),(0,i.Cg)([(0,m.wg)("sublayers")],de.prototype,"castSublayers",null),(0,i.Cg)([(0,re.K)("sublayers")],de.prototype,"writeSublayers",null),(0,i.Cg)([(0,m.MZ)({type:String,json:{name:"name",write:{overridePolicy:ue}}})],de.prototype,"title",void 0),(0,i.Cg)([(0,te.w)("service","title",["name","layerDefinition.name"])],de.prototype,"readTitle",null),(0,i.Cg)([(0,m.MZ)({type:String})],de.prototype,"typeIdField",void 0),(0,i.Cg)([(0,m.MZ)({json:{read:!1},readOnly:!0,value:"sublayer"})],de.prototype,"type",void 0),(0,i.Cg)([(0,te.w)("typeIdField",["layerDefinition.typeIdField"])],de.prototype,"readTypeIdField",null),(0,i.Cg)([(0,m.MZ)({type:[E.A],json:{origins:{service:{read:{source:"layerDefinition.types"}}}}})],de.prototype,"types",void 0),(0,i.Cg)([(0,m.MZ)({type:[String],readOnly:!0})],de.prototype,"uniqueIdFields",void 0),(0,i.Cg)([(0,te.w)("service","uniqueIdFields",["layerDefinition.uniqueIdInfo.OIDFieldContainsHashValue","layerDefinition.uniqueIdInfo.fields"])],de.prototype,"readUniqueIdFields",null),(0,i.Cg)([(0,m.MZ)({type:String,json:{name:"layerUrl",write:{overridePolicy:oe}}})],de.prototype,"url",null),(0,i.Cg)([(0,m.MZ)({type:Boolean,value:!0,json:{read:{source:"defaultVisibility"},write:{target:"defaultVisibility",overridePolicy:ae}}})],de.prototype,"visible",null),(0,i.Cg)([(0,re.K)("visible")],de.prototype,"writeVisible",null),de=D=(0,i.Cg)([(0,m.$K)("esri.layers.support.Sublayer")],de)},33446(e,t,r){r.d(t,{C:()=>o,m:()=>n});var i=r(49186),s=r(17676);async function n(e,t,r){let n;try{n=await createImageBitmap(e)}catch(e){throw new i.A("request:server",`Unable to load ${t}`,{url:t,error:e})}return(0,s.Te)(r),n}async function o(e,t,r,n,o){let a;try{a=await createImageBitmap(e)}catch(e){throw new i.A("request:server",`Unable to load tile ${t}/${r}/${n}`,{error:e,level:t,row:r,col:n})}return(0,s.Te)(o),a}},32730(e,t,r){r.d(t,{BI:()=>y,D3:()=>c,XJ:()=>d,lc:()=>p,mX:()=>f,rU:()=>h,tH:()=>v});var i=r(799);const s="__begin__",n="__end__",o=new RegExp(s,"ig"),a=new RegExp(n,"ig"),l=new RegExp("^"+s,"i"),u=new RegExp(n+"$","i");function p(e){return e.replaceAll(new RegExp("\\[","g"),"{").replaceAll(new RegExp("\\]","g"),"}")}function c(e){return e.replaceAll(new RegExp("\\{","g"),"[").replaceAll(new RegExp("\\}","g"),"]")}function d(e){const t={expression:"",type:"none"};return e.labelExpressionInfo?e.labelExpressionInfo.value?(t.expression=e.labelExpressionInfo.value,t.type="conventional"):e.labelExpressionInfo.expression&&(t.expression=e.labelExpressionInfo.expression,t.type="arcade"):null!=e.labelExpression&&(t.expression=p(e.labelExpression),t.type="conventional"),t}function y(e){const t=d(e);if(!t)return null;switch(t.type){case"conventional":return f(t.expression);case"arcade":return t.expression}return null}function h(e){const t=d(e);if(!t)return null;switch(t.type){case"conventional":return function(e){const t=e?.match(m);return t?.[1].trim()||null}(t.expression);case"arcade":return v(t.expression)}return null}function f(e){let t;return e?(t=(0,i.HC)(e,e=>s+'$feature["'+e+'"]'+n),t=l.test(t)?t.replace(l,""):'"'+t,t=u.test(t)?t.replace(u,""):t+'"',t=t.replaceAll(o,'" + ').replaceAll(a,' + "')):t='""',t}const m=/^\s*\{([^}]+)\}\s*$/i,g=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,w=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function v(e){if(!e)return null;let t=g.exec(e)||b.exec(e);return t?t[1]||t[3]:(t=w.exec(e),t?t[2]:null)}},63389(e,t,r){function i(e,t,r){const i=t.flatten(({sublayers:e})=>e).length;return i!==e.length||!!e.some(e=>e.originIdOf("minScale")>r||e.originIdOf("maxScale")>r||e.originIdOf("renderer")>r||e.originIdOf("labelingInfo")>r||e.originIdOf("opacity")>r||e.originIdOf("labelsVisible")>r||e.originIdOf("source")>r)||!n(e,t)}function s(e,t,r){return!!e.some(e=>{const t=e.source,i=!t||"map-layer"===t.type&&t.mapLayerId===e.id&&(null==t.gdbVersion||t.gdbVersion===r);e.commitProperty("renderer"),e.commitProperty("labelingInfo"),e.commitProperty("opacity"),e.commitProperty("labelsVisible"),e.commitProperty("orderBy");const s=e.layer?.capabilities?.exportMap?.supportsSublayerOrderBy??!1;return!i||e.originIdOf("renderer")>2||e.originIdOf("labelingInfo")>2||e.originIdOf("opacity")>2||e.originIdOf("labelsVisible")>2||s&&e.originIdOf("orderBy")>2})||!n(e,t)}function n(e,t){if(!e?.length||null==t)return!0;const r=t.slice().reverse().flatten(({sublayers:e})=>e&&e.toArray().reverse()).map(e=>e.id).toArray();if(e.length>r.length)return!1;let i=0;const s=r.length;for(const{id:t}of e){for(;i<s&&r[i]!==t;)i++;if(i>=s)return!1}return!0}function o(e){return!!e&&e.some(e=>null!=e.minScale||null!=e.layerDefinition?.minScale)}r.d(t,{Sk:()=>s,Zx:()=>i,_X:()=>o})},73681(e,t,r){r.d(t,{n:()=>l});var i=r(49186),s=r(53966),n=r(46140),o=r(95466),a=r(55674);class l{static async from(e,t,r){const o=e.dictionary_version?n.A.parse(e.dictionary_version):null,p=new Set(e.itemsNames),c={};if(t)for(const e in t)c[e]=t[e];if(e.authoringInfo.configuration)for(const t of e.authoringInfo.configuration)c.hasOwnProperty(t.name)||(c[t.name]=t.value);const d=new Set(e.authoringInfo.symbol);for(const e of Object.keys(r))d.delete(e);d.size&&s.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:d});const y=await(0,a.xR)(e.expression,null,c);if(!y)throw new i.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");const h=!o||!o.greaterEqual(4,0);h&&s.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:o});const f=new u(r,h);return new l(h,p,y,f)}constructor(e,t,r,i){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=i}get itemNames(){return this._itemNames}evaluate(e,t,r,i){try{return this._reader.bind(e,r,i),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){s.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new o.A(e);const t=e.map(e=>({...e,type:"esriFieldTypeString"}));return new o.A(t)}}class u extends a.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){const t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);const t=this._getField(e);return null==t||null==this._boundTarget.attributes[t.name]?"":""+this._boundTarget.attributes[t.name]}}},61760(e,t,r){r.d(t,{PU:()=>o,YW:()=>l,ex:()=>s,hv:()=>a,zp:()=>n}),r(34727);var i=r(90629);r(78955),r(91829);const s=2.4;function n(e){return(0,i.PN)(e*s)}function o(e){return(0,i.Lz)(e)/s}function a(e,t,r){const i=Math.sqrt(e**2+t**2)/r;return i>1?0:3/(Math.PI*r**2)*(1-i**2)**2}function l(e){return"function"==typeof e?e:e?t=>+t[e]:()=>1}},20615(e,t,r){r.d(t,{I:()=>o});var i=r(2272),s=r(80893),n=r(61956);function o(e,t,r,o){return(0,s.gW)((0,i.Dl)(e),n.A.from(t),r,o)}},74910(e,t,r){r.d(t,{L:()=>a});var i=r(5443),s=r(2272),n=r(80893),o=r(61956);async function a(e,t,r){const a=(0,s.Dl)(e),l=await(0,n.Jf)(a,o.A.from(t),{...r}),u=l.extent;return!u||isNaN(u.xmin)||isNaN(u.ymin)||isNaN(u.xmax)||isNaN(u.ymax)?{count:l.count,extent:null}:{count:l.count,extent:i.A.fromJSON(u)}}},78286(e,t,r){r.d(t,{V:()=>o});var i=r(2272),s=r(80893),n=r(61956);async function o(e,t,r,o){const a=(0,i.Dl)(e),l=await(0,s.Pk)(a,n.A.from(t),r,o);return l.objectIds??function(e){if(e)return function(e){return!Array.isArray(e[0])}(e)?e:e.map(e=>JSON.stringify(e))}(l.uniqueIds)??[]}},99199(e,t,r){r.d(t,{e:()=>l,s:()=>a});var i=r(2272),s=r(80893),n=r(22671),o=r(61956);async function a(e,t,r,i){const s=await l(e,t,r,i);return n.A.fromJSON(s)}function l(e,t,r,n){const a=(0,i.Dl)(e),l={...r},u=o.A.from(t);return(0,s.eW)(a,u,u.sourceSpatialReference,l,n)}},63746(e,t,r){function i(e){return class{constructor(){for(const t of e)this[t]=null}}}function s(e,t=1){const{transform:r,hasZ:i,hasM:s}=e;if(null==r)return i&&1!==t?e=>{e[2]*=t}:null;const[n,o]=function(e,t,r,i){let{scale:s,translate:n,originPosition:o}=e;return"upperLeft"===o&&(s=s.map((e,t)=>1===t?-e:e)),t&&(s=s.map((e,t)=>2===t?e*i:e),n=n.map((e,t)=>2===t?e*i:e)),!t&&r&&(s=s.filter((e,t)=>2!==t),n=n.filter((e,t)=>2!==t)),[s,n]}(r,i,s,t),a=e.hasZ?3:2;return e=>{for(let t=0;t<e.length&&(t!==a||0!==e[t]);++t)e[t]=e[t]*n[t]+o[t]}}r.d(t,{Mv:()=>s,_7:()=>i}),r(53966)},58501(e,t,r){r.d(t,{q:()=>s});var i=r(62815);function s(e,t,r){if(!r?.features||!r.hasZ)return;const s=(0,i.N)(r.geometryType,t,e.outSpatialReference);if(s)for(const e of r.features)s(e.geometry)}},41366(e,t,r){r.d(t,{K:()=>c,Q:()=>l});var i=r(5482),s=r(66552),n=r(53966),o=r(91429),a=r(93223);const l=(0,s.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),u="percent-of-total",p="field",c=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.normalizationField=null,this.normalizationMaxValue=null,this.normalizationMinValue=null,this.normalizationTotal=null}get normalizationType(){let e=this._get("normalizationType");const t=!!this.normalizationField,r=null!=this.normalizationTotal;return t||r?(e=t&&p||r&&u||null,t&&r&&n.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):e!==p&&e!==u||(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,i.Cg)([(0,o.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],r.prototype,"normalizationField",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],r.prototype,"normalizationMaxValue",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],r.prototype,"normalizationMinValue",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],r.prototype,"normalizationTotal",void 0),(0,i.Cg)([(0,a.e)(l,{name:"parameters.normalizationType"})],r.prototype,"normalizationType",null),r=(0,i.Cg)([(0,o.$K)("esri.rest.support.NormalizationBinParametersMixin")],r),r}},55674(e,t,r){r.d(t,{Ad:()=>y,Gj:()=>m,QY:()=>d,lL:()=>g,xR:()=>h});var i=r(66131),s=r(49186),n=(r(44208),r(44729)),o=r(15032),a=r(65864),l=r(95466),u=r(43668),p=r(98623);const c=["geometry","scale","timeProperties"];function d(e,t){if(null!=t)for(const r of c)t.hasArcadeDependency(r)&&e.add(r);return e}function y(e,t){return f.create(e,t,null,["$feature","$view"])}function h(e,t,r){return f.create(e,t,r,["$feature","$view","$config"])}class f{static async create(e,t,r,i){const{arcade:n,Dictionary:o}=await(0,u.l)();let a;try{a=n.parseScript(e)}catch(t){throw new s.A("arcade-bad-expression","Failed to parse arcade script",{script:e,error:t})}const l=n.scriptUsesGeometryEngine(a);l&&await n.enableGeometrySupport(),await n.loadDependentModules(new Set,a,null,!1,l);const p={vars:i.reduce((e,t)=>({...e,[t]:null}),{}),spatialReference:t,useAsync:!1},c=n.compileScript(a,p);let d=null;null!=r&&(d=new o(r),d.immutable=!0);const y=new o;return y.immutable=!1,y.setField("scale",0),new f(e,n,a,c,t,y,d,o)}constructor(e,t,r,i,s,n,o,a){this.script=e,this._arcade=t,this._syntaxTree=r,this._compiled=i,this._spatialReference=s,this._viewDict=n,this._configDict=o,this._dictionaryCtor=a,this._dependencies=new Map,this._featureReader=new m,this._dependencies.set("geometry",t.scriptTouchesGeometry(this._syntaxTree)),this._dependencies.set("scale",this._arcade.referencesMember(this._syntaxTree,"scale")),this._dependencies.set("timeProperties",this._arcade.scriptUsesViewProperties(this._syntaxTree,["timeProperties"]))}evaluate(e,t){const r=t.$view?.timeZone;if(t.$view){let e;if(this._viewDict.setField("scale",t.$view.scale),null!=t.$view.timeProperties){const{currentStart:s,currentEnd:n}=t.$view.timeProperties;e=new this._dictionaryCtor({currentStart:null!=s?null!=r?i.lY.epochToArcadeDate(s,r):i.lY.unknownEpochToArcadeDate(s):void 0,currentEnd:null!=n?null!=r?i.lY.epochToArcadeDate(n,r):i.lY.unknownEpochToArcadeDate(n):void 0,startIncluded:!0,endIncluded:!0})}this._viewDict.setField("timeProperties",e)}return this._compiled({vars:{$view:this._viewDict,$config:this._configDict,$feature:e},spatialReference:this._spatialReference,timeZone:r})}repurposeFeature(e,t){return this._featureReader.bind(e,t,this._spatialReference),this._featureReader}references(e){return this._dependencies.get(e)??!1}}class m{constructor(){this._boundTarget=null,this._boundSchema={fields:null,fieldsIndex:null,spatialReference:null,get geometryType(){return null},get objectIdField(){return null}},this.arcadeDeclaredClass="esri.arcade.Feature",this._contextTimeZone=null}bind(e,t,r){const i=t??new l.A(g(e.attributes));this._boundTarget=e,this._boundSchema.fields=i.fields,this._boundSchema.fieldsIndex=i,this._boundSchema.spatialReference=r}_getField(e){return this._boundSchema.fieldsIndex.get(e)}get contextTimeZone(){return this._contextTimeZone}set contextTimeZone(e){this._contextTimeZone=e}readArcadeFeature(){return this}hasField(e){return this._boundSchema.fieldsIndex.has(e)}geometry(){if("fromJSON"in this._boundTarget)return this._boundTarget.geometry;const e=(0,a.rS)(this._boundTarget.geometry);if(e){if(!this._boundSchema.spatialReference)throw new Error("InternalError: Expected spatial reference to be defined");e.spatialReference=this._boundSchema.spatialReference}return e}_hasGeometry(){return null!=this._boundTarget.geometry}isUnknownDateTimeField(e){return this._boundSchema.fieldsIndex.getTimeZone(e)===p.L5}field(e,t=!0){const r=this._getField(e);if(r){const t=this._boundTarget.attributes[r.name];if(null==t)return null;switch(r.type){case"date-only":case"esriFieldTypeDateOnly":return n.n.fromReader(t);case"time-only":case"esriFieldTypeTimeOnly":return o.k.fromReader(t);case"esriFieldTypeTimestampOffset":case"timestamp-offset":return i.lY.fromReaderAsTimeStampOffset(t);case"date":case"esriFieldTypeDate":return this.isUnknownDateTimeField(e)?i.lY.unknownEpochToArcadeDate(t):i.lY.epochToArcadeDate(t,this.contextTimeZone??p.qU);default:return t}}if(t)throw new Error(`Field ${e} does not exist`);return null}setField(e,t){throw new Error("Unable to update feature attribute values, feature is readonly")}keys(){return this._boundSchema.fieldsIndex.fields.map(e=>e.name)}isEmpty(){return this._boundSchema.fields.length<=0&&!this._hasGeometry()}castToText(e=!1){return JSON.stringify(this._boundTarget)}gdbVersion(){return null}fullSchema(){return this._boundSchema}castAsJson(e=null){return{attributes:this._boundTarget.attributes,geometry:!0===e?.keepGeometryType?this.geometry():this.geometry()?.toJSON()??null}}castAsJsonAsync(e=null,t=null){return Promise.resolve(this.castAsJson(t))}}function g(e){const t=[];for(const r in e)t.push({name:r,alias:r,type:"string"==typeof e[r]?"esriFieldTypeString":"esriFieldTypeDouble"});return t}}}]);