@arcgis/core 4.22.0-next.20211129 → 4.22.0-next.20211130

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 (283) hide show
  1. package/arcade/functions/geometry.js +1 -1
  2. package/assets/esri/core/workers/RemoteClient.js +1 -1
  3. package/assets/esri/core/workers/chunks/0277e223fd84f3fc5501.js +1 -0
  4. package/assets/esri/core/workers/chunks/058955b87ce2aa1b1809.js +1 -0
  5. package/assets/esri/core/workers/chunks/{8cf9f06a7efee8eabdd1.js → 09426d106b3189de8b6f.js} +1 -1
  6. package/assets/esri/core/workers/chunks/0a5b9fdfa77c0e690503.js +1 -0
  7. package/assets/esri/core/workers/chunks/23af0b02208e20d5c07e.js +1 -0
  8. package/assets/esri/core/workers/chunks/320d655fcd7fe1966145.js +1 -0
  9. package/assets/esri/core/workers/chunks/362339272cf5adcf9e4b.js +1 -0
  10. package/assets/esri/core/workers/chunks/3bea6fa573a4daece0ed.js +1 -0
  11. package/assets/esri/core/workers/chunks/44145763617ea985cce4.js +1 -0
  12. package/assets/esri/core/workers/chunks/{7becae4fffb0090a380c.js → 4417dfcb2ba50ac9f199.js} +1 -1
  13. package/assets/esri/core/workers/chunks/489147cf21d55f47d0e6.js +1 -0
  14. package/assets/esri/core/workers/chunks/52aa3b44bddb10caa343.js +1 -0
  15. package/assets/esri/core/workers/chunks/{7eca3800807b2cd3fda0.js → 5cb2588d14e09af0801d.js} +1 -1
  16. package/assets/esri/core/workers/chunks/{1229554d2f1fae96edda.js → 5f19c284cfcd5a4569df.js} +1 -1
  17. package/assets/esri/core/workers/chunks/5f2718cd77cbd5ba7920.js +1 -0
  18. package/assets/esri/core/workers/chunks/6210b23872c362f51b12.js +1 -0
  19. package/assets/esri/core/workers/chunks/{dc972cefa5a0e9a679a2.js → 64be18169516a9a488f4.js} +1 -1
  20. package/assets/esri/core/workers/chunks/6a1ce00bcb689ea95bcb.js +1 -0
  21. package/assets/esri/core/workers/chunks/6b2a6bf7f6b87f2cc894.js +1 -0
  22. package/assets/esri/core/workers/chunks/7d032d4ee9a91709aaa3.js +1 -0
  23. package/assets/esri/core/workers/chunks/8bc4ea821be16a752226.js +1 -0
  24. package/assets/esri/core/workers/chunks/901da7d32c04a6e4ea41.js +1 -0
  25. package/assets/esri/core/workers/chunks/96a62dc1e07f3ef20a30.js +1 -0
  26. package/assets/esri/core/workers/chunks/b6b46f8e6a7d8d3cef50.js +1 -0
  27. package/assets/esri/core/workers/chunks/bc0b85bc1e5116836ba4.js +1 -0
  28. package/assets/esri/core/workers/chunks/bd5f358d83148a97fc7a.js +1 -0
  29. package/assets/esri/core/workers/chunks/deba37055be7c2d7da26.js +1 -0
  30. package/assets/esri/core/workers/chunks/e02a3d456525e76ddb60.js +1 -0
  31. package/assets/esri/core/workers/chunks/{90a5a3e4b38f1f466955.js → f3da8b797c8e1fcb1c21.js} +1 -1
  32. package/assets/esri/core/workers/chunks/f85d95d1b2c4446257f1.js +1 -0
  33. package/assets/esri/themes/base/widgets/_FeatureForm.scss +6 -10
  34. package/assets/esri/themes/dark/main.css +1 -1
  35. package/assets/esri/themes/dark-blue/main.css +1 -1
  36. package/assets/esri/themes/dark-green/main.css +1 -1
  37. package/assets/esri/themes/dark-purple/main.css +1 -1
  38. package/assets/esri/themes/dark-red/main.css +1 -1
  39. package/assets/esri/themes/light/main.css +1 -1
  40. package/assets/esri/themes/light/view.css +1 -1
  41. package/assets/esri/themes/light-blue/main.css +1 -1
  42. package/assets/esri/themes/light-green/main.css +1 -1
  43. package/assets/esri/themes/light-purple/main.css +1 -1
  44. package/assets/esri/themes/light-red/main.css +1 -1
  45. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_ar.json +1 -1
  46. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_bg.json +1 -1
  47. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_bs.json +1 -1
  48. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_ca.json +1 -1
  49. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_cs.json +1 -1
  50. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_da.json +1 -1
  51. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_de.json +1 -1
  52. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_el.json +1 -1
  53. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_es.json +1 -1
  54. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_et.json +1 -1
  55. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_fi.json +1 -1
  56. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_fr.json +1 -1
  57. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_he.json +1 -1
  58. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_hr.json +1 -1
  59. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_hu.json +1 -1
  60. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_id.json +1 -1
  61. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_it.json +1 -1
  62. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_ja.json +1 -1
  63. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_ko.json +1 -1
  64. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_lt.json +1 -1
  65. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_lv.json +1 -1
  66. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_nb.json +1 -1
  67. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_nl.json +1 -1
  68. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_pl.json +1 -1
  69. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_pt-BR.json +1 -1
  70. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_pt-PT.json +1 -1
  71. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_ro.json +1 -1
  72. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_ru.json +1 -1
  73. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_sk.json +1 -1
  74. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_sl.json +1 -1
  75. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_sr.json +1 -1
  76. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_sv.json +1 -1
  77. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_th.json +1 -1
  78. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_tr.json +1 -1
  79. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_uk.json +1 -1
  80. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_vi.json +1 -1
  81. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_zh-CN.json +1 -1
  82. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_zh-HK.json +1 -1
  83. package/assets/esri/widgets/Bookmarks/t9n/Bookmarks_zh-TW.json +1 -1
  84. package/assets/esri/widgets/Compass/t9n/Compass_ar.json +1 -1
  85. package/assets/esri/widgets/Compass/t9n/Compass_bg.json +1 -1
  86. package/assets/esri/widgets/Compass/t9n/Compass_bs.json +1 -1
  87. package/assets/esri/widgets/Compass/t9n/Compass_ca.json +1 -1
  88. package/assets/esri/widgets/Compass/t9n/Compass_cs.json +1 -1
  89. package/assets/esri/widgets/Compass/t9n/Compass_da.json +1 -1
  90. package/assets/esri/widgets/Compass/t9n/Compass_de.json +1 -1
  91. package/assets/esri/widgets/Compass/t9n/Compass_el.json +1 -1
  92. package/assets/esri/widgets/Compass/t9n/Compass_es.json +1 -1
  93. package/assets/esri/widgets/Compass/t9n/Compass_et.json +1 -1
  94. package/assets/esri/widgets/Compass/t9n/Compass_fi.json +1 -1
  95. package/assets/esri/widgets/Compass/t9n/Compass_fr.json +1 -1
  96. package/assets/esri/widgets/Compass/t9n/Compass_he.json +1 -1
  97. package/assets/esri/widgets/Compass/t9n/Compass_hr.json +1 -1
  98. package/assets/esri/widgets/Compass/t9n/Compass_hu.json +1 -1
  99. package/assets/esri/widgets/Compass/t9n/Compass_id.json +1 -1
  100. package/assets/esri/widgets/Compass/t9n/Compass_it.json +1 -1
  101. package/assets/esri/widgets/Compass/t9n/Compass_ja.json +1 -1
  102. package/assets/esri/widgets/Compass/t9n/Compass_ko.json +1 -1
  103. package/assets/esri/widgets/Compass/t9n/Compass_lt.json +1 -1
  104. package/assets/esri/widgets/Compass/t9n/Compass_lv.json +1 -1
  105. package/assets/esri/widgets/Compass/t9n/Compass_nb.json +1 -1
  106. package/assets/esri/widgets/Compass/t9n/Compass_nl.json +1 -1
  107. package/assets/esri/widgets/Compass/t9n/Compass_pl.json +1 -1
  108. package/assets/esri/widgets/Compass/t9n/Compass_pt-BR.json +1 -1
  109. package/assets/esri/widgets/Compass/t9n/Compass_pt-PT.json +1 -1
  110. package/assets/esri/widgets/Compass/t9n/Compass_ro.json +1 -1
  111. package/assets/esri/widgets/Compass/t9n/Compass_ru.json +1 -1
  112. package/assets/esri/widgets/Compass/t9n/Compass_sk.json +1 -1
  113. package/assets/esri/widgets/Compass/t9n/Compass_sl.json +1 -1
  114. package/assets/esri/widgets/Compass/t9n/Compass_sr.json +1 -1
  115. package/assets/esri/widgets/Compass/t9n/Compass_sv.json +1 -1
  116. package/assets/esri/widgets/Compass/t9n/Compass_th.json +1 -1
  117. package/assets/esri/widgets/Compass/t9n/Compass_tr.json +1 -1
  118. package/assets/esri/widgets/Compass/t9n/Compass_uk.json +1 -1
  119. package/assets/esri/widgets/Compass/t9n/Compass_vi.json +1 -1
  120. package/assets/esri/widgets/Compass/t9n/Compass_zh-CN.json +1 -1
  121. package/assets/esri/widgets/Compass/t9n/Compass_zh-HK.json +1 -1
  122. package/assets/esri/widgets/Compass/t9n/Compass_zh-TW.json +1 -1
  123. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ar.json +1 -1
  124. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_bg.json +1 -1
  125. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_bs.json +1 -1
  126. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ca.json +1 -1
  127. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_cs.json +1 -1
  128. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_da.json +1 -1
  129. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_de.json +1 -1
  130. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_el.json +1 -1
  131. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_es.json +1 -1
  132. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_et.json +1 -1
  133. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_fi.json +1 -1
  134. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_fr.json +1 -1
  135. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_he.json +1 -1
  136. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_hr.json +1 -1
  137. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_hu.json +1 -1
  138. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_id.json +1 -1
  139. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_it.json +1 -1
  140. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ja.json +1 -1
  141. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ko.json +1 -1
  142. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_lt.json +1 -1
  143. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_lv.json +1 -1
  144. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_nb.json +1 -1
  145. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_nl.json +1 -1
  146. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pl.json +1 -1
  147. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pt-BR.json +1 -1
  148. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pt-PT.json +1 -1
  149. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ro.json +1 -1
  150. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ru.json +1 -1
  151. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sk.json +1 -1
  152. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sl.json +1 -1
  153. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sr.json +1 -1
  154. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sv.json +1 -1
  155. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_th.json +1 -1
  156. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_tr.json +1 -1
  157. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_uk.json +1 -1
  158. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_vi.json +1 -1
  159. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-CN.json +1 -1
  160. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-HK.json +1 -1
  161. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-TW.json +1 -1
  162. package/core/workers/workerFactory.js +1 -1
  163. package/interfaces.d.ts +820 -18
  164. package/layers/VoxelWasmPerScene.js +1 -1
  165. package/layers/mixins/ArcGISImageService.js +1 -1
  166. package/layers/mixins/ImageryTileMixin.js +1 -1
  167. package/layers/support/RasterWorker.js +1 -1
  168. package/package.json +1 -1
  169. package/renderers/support/rasterRendererHelper.js +1 -1
  170. package/smartMapping/raster/support/utils.js +1 -1
  171. package/support/revision.js +1 -1
  172. package/symbols/cim/ExpandedCIM.js +1 -1
  173. package/views/2d/engine/flow/AnimatedFlowView2D.js +1 -1
  174. package/views/2d/engine/flow/BrushFlow.js +1 -1
  175. package/views/2d/engine/flow/FlowDisplayData.js +1 -1
  176. package/views/2d/engine/flow/FlowGLResources.js +1 -1
  177. package/views/2d/engine/flow/FlowStyle.js +1 -1
  178. package/views/2d/engine/flow/animatedFlowRendererUtils.js +1 -1
  179. package/views/2d/engine/flow/dataUtils.js +5 -0
  180. package/views/2d/engine/webgl/AttributeStoreView.js +1 -1
  181. package/views/2d/engine/webgl/BufferPool.js +5 -0
  182. package/views/2d/engine/webgl/DisplayId.js +5 -0
  183. package/views/2d/engine/webgl/FeatureTile.js +1 -1
  184. package/views/2d/engine/webgl/TileData.js +1 -1
  185. package/views/2d/engine/webgl/Utils.js +1 -1
  186. package/views/2d/engine/webgl/brushes/WGLGeometryBrushFill.js +1 -1
  187. package/views/2d/engine/webgl/collisions/CollisionEngine.js +1 -1
  188. package/views/2d/engine/webgl/cpuMapped/Buffer.js +1 -1
  189. package/views/2d/engine/webgl/cpuMapped/FreeList.js +1 -1
  190. package/views/2d/engine/webgl/cpuMapped/Geometry.js +1 -1
  191. package/views/2d/engine/webgl/definitions.js +1 -1
  192. package/views/2d/engine/webgl/materialKey/MaterialKey.js +1 -1
  193. package/views/2d/engine/webgl/mesh/MeshData.js +1 -1
  194. package/views/2d/engine/webgl/mesh/VertexVector.js +1 -1
  195. package/views/2d/engine/webgl/mesh/factories/WGLMeshFactory.js +1 -1
  196. package/views/2d/engine/webgl/mesh/templates/WGLBaseFillTemplate.js +1 -1
  197. package/views/2d/engine/webgl/mesh/templates/WGLBaseLineTemplate.js +1 -1
  198. package/views/2d/engine/webgl/mesh/templates/WGLBaseMarkerTemplate.js +1 -1
  199. package/views/2d/engine/webgl/mesh/templates/WGLBaseTextTemplate.js +1 -1
  200. package/views/2d/engine/webgl/mesh/templates/WGLDynamicFillTemplate.js +1 -1
  201. package/views/2d/engine/webgl/mesh/templates/WGLFillTemplate.js +1 -1
  202. package/views/2d/engine/webgl/mesh/templates/WGLLineTemplate.js +1 -1
  203. package/views/2d/engine/webgl/mesh/templates/WGLMarkerTemplate.js +1 -1
  204. package/views/2d/engine/webgl/mesh/templates/WGLTemplateStore.js +1 -1
  205. package/views/2d/engine/webgl/number.js +1 -1
  206. package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
  207. package/views/2d/engine/webgl/util/Writer.js +1 -1
  208. package/views/2d/layers/FeatureLayerView2D.js +1 -1
  209. package/views/2d/layers/ImageryLayerView2D.js +1 -1
  210. package/views/2d/layers/features/controllers/FeatureController2D.js +1 -1
  211. package/views/2d/layers/features/controllers/support/sourceAdapters.js +1 -1
  212. package/views/2d/layers/features/processors/SymbolProcessor.js +1 -1
  213. package/views/2d/layers/features/schemaUtils.js +1 -1
  214. package/views/2d/layers/features/sources/SnapshotFeatureSource.js +1 -1
  215. package/views/2d/layers/features/support/AttributeStore.js +1 -1
  216. package/views/2d/layers/features/support/ComputedAttributeStorage.js +1 -1
  217. package/views/2d/layers/features/support/DisplayIdGenerator.js +5 -0
  218. package/views/2d/layers/features/support/FeatureSetReader.js +1 -1
  219. package/views/2d/layers/features/tileRenderers/HeatmapTileRenderer.js +1 -1
  220. package/views/2d/layers/features/tileRenderers/SymbolTileRenderer.js +1 -1
  221. package/views/2d/layers/features/tileRenderers/support/WGLFeatureView.js +1 -1
  222. package/views/2d/layers/graphics/GraphicsView2D.js +1 -1
  223. package/views/2d/layers/imagery/BaseImageryTileSubView2D.js +1 -1
  224. package/views/3d/interactive/visualElements/ExtendedLineVisualElement.js +1 -1
  225. package/views/3d/interactive/visualElements/LineVisualElement.js +1 -1
  226. package/views/3d/interactive/visualElements/OutlineVisualElement.js +1 -1
  227. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  228. package/views/3d/layers/graphics/Graphics3DExtrudeSymbolLayer.js +1 -1
  229. package/views/3d/layers/graphics/Graphics3DIconSymbolLayer.js +1 -1
  230. package/views/3d/layers/graphics/Graphics3DLineSymbolLayer.js +1 -1
  231. package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
  232. package/views/3d/layers/graphics/Graphics3DPathSymbolLayer.js +1 -1
  233. package/views/3d/layers/graphics/Graphics3DSymbol.js +1 -1
  234. package/views/3d/layers/graphics/Graphics3DSymbolLayer.js +1 -1
  235. package/views/3d/layers/graphics/Graphics3DWebStyleSymbol.js +1 -1
  236. package/views/3d/terrain/PlanarPatch.js +1 -1
  237. package/views/3d/terrain/SphericalPatch.js +1 -1
  238. package/views/3d/terrain/TerrainSurface.js +1 -1
  239. package/views/3d/terrain/Tile.js +1 -1
  240. package/views/3d/webgl-engine/core/shaderLibrary/shading/LineStipple.glsl.js +12 -11
  241. package/views/3d/webgl-engine/materials/NativeLineMaterial.js +1 -1
  242. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  243. package/views/3d/webgl-engine/shaders/NativeLineTechnique.js +1 -1
  244. package/views/3d/webgl-engine/shaders/RibbonLineTechnique.js +1 -1
  245. package/views/webgl/BufferObject.js +1 -1
  246. package/widgets/Feature/FeatureExpression/FeatureExpressionViewModel.js +1 -1
  247. package/widgets/Feature/support/arcadeFeatureUtils.js +1 -1
  248. package/widgets/FeatureForm/InputField.js +1 -1
  249. package/widgets/Sketch/SketchViewModel.js +1 -1
  250. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceViewModel.d.ts +4 -0
  251. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceViewModel.js +1 -1
  252. package/widgets/UtilityNetworkTrace.d.ts +4 -0
  253. package/widgets/UtilityNetworkTrace.js +1 -1
  254. package/assets/esri/core/workers/chunks/09fdc334ba4096a225ba.js +0 -1
  255. package/assets/esri/core/workers/chunks/0a225c0b6a82779de4dd.js +0 -1
  256. package/assets/esri/core/workers/chunks/0a3c38ce907eb1ff6e4d.js +0 -1
  257. package/assets/esri/core/workers/chunks/1120c94a972c7dbf12d8.js +0 -1
  258. package/assets/esri/core/workers/chunks/1d8a6ab5feb97d6ca846.js +0 -1
  259. package/assets/esri/core/workers/chunks/27b9aab0315a3dc7f5e4.js +0 -1
  260. package/assets/esri/core/workers/chunks/35f53c6de66eec0573db.js +0 -1
  261. package/assets/esri/core/workers/chunks/64646de7e991f3076f60.js +0 -1
  262. package/assets/esri/core/workers/chunks/746d36d268a234680ef7.js +0 -1
  263. package/assets/esri/core/workers/chunks/7495218a8fa025c0c133.js +0 -1
  264. package/assets/esri/core/workers/chunks/7b8f67fe55892fbfb17d.js +0 -1
  265. package/assets/esri/core/workers/chunks/82bb1efd0941a08e7756.js +0 -1
  266. package/assets/esri/core/workers/chunks/8aa1910de5173c976dac.js +0 -1
  267. package/assets/esri/core/workers/chunks/a00d39545a2db2a66816.js +0 -1
  268. package/assets/esri/core/workers/chunks/a0114820691d4dda8a67.js +0 -1
  269. package/assets/esri/core/workers/chunks/ad204548895f22823b98.js +0 -1
  270. package/assets/esri/core/workers/chunks/bd7a0b91157250f93aa3.js +0 -1
  271. package/assets/esri/core/workers/chunks/cb070e62a8ac85509384.js +0 -1
  272. package/assets/esri/core/workers/chunks/db5bae10b28d7908a154.js +0 -1
  273. package/assets/esri/core/workers/chunks/e9e01881e762aa389401.js +0 -1
  274. package/assets/esri/core/workers/chunks/ee3c92e7fd23e606a51b.js +0 -1
  275. package/assets/esri/core/workers/chunks/f4a6865f9fd613c789cb.js +0 -1
  276. package/assets/esri/core/workers/chunks/f7a8197264cbc51eac1d.js +0 -1
  277. package/assets/esri/core/workers/chunks/f9958a82ce78676e56eb.js +0 -1
  278. package/assets/esri/core/workers/chunks/fcde45f86962b11353a6.js +0 -1
  279. package/views/2d/engine/flow/FlowMaterial.js +0 -5
  280. package/views/2d/engine/flow/ImageryTileLayerFlowProcessor.js +0 -5
  281. package/views/2d/engine/flow/ImageryTileLayerFlowSource.js +0 -5
  282. package/views/2d/engine/flow/createStreamlinesMesh.js +0 -5
  283. package/views/2d/layers/features/support/displayIdUtils.js +0 -5
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.22/esri/copyright.txt for details.
4
4
  */
5
- import e from"../Dictionary.js";import r from"../Feature.js";import n from"../ImmutablePointArray.js";import{p as t,a as i,b as o,r as a,J as l,K as s,v as f,f as c,d as u,n as m,j as g,i as p,c as h,x as w,e as y,L as E}from"../../chunks/languageUtils.js";import R from"../../geometry/Extent.js";import I from"../../geometry/Geometry.js";import A from"../../geometry/Multipoint.js";import F from"../../geometry/Point.js";import d from"../../geometry/Polygon.js";import S from"../../geometry/Polyline.js";import{angle2D as j,angleBetween2D as b,bearing2D as x,bearingBetween2D as G,pathsSelfIntersecting as O}from"./centroid.js";import{fromJSON as N}from"../../geometry/support/jsonUtils.js";import{isClockwise as J}from"../../geometry/support/coordsUtils.js";function D(e){return e instanceof r||"object"==typeof e&&"FeatureSetReader"===e.type}function P(P,M){P.ringisclockwise=function(e,r){return M(e,r,(function(e,r,a){t(a,1,1);let l=[],s=!1,f=!1;if(null===a[0])return!1;if(i(a[0])){for(const e of a[0]){if(!(e instanceof F))throw new Error("Invalid Argument");l.push(e.hasZ?e.hasM?[e.x,e.y,e.z,e.m]:[e.x,e.y,e.z]:[e.x,e.y])}l.length>0&&(s=a[0][0].hasZ,f=a[0][0].hasM)}else if(a[0]instanceof n)l=a[0]._elements,l.length>0&&(s=a[0]._hasZ,f=a[0]._hasM);else{if(!o(a[0]))throw new Error("Invalid Argument");for(const e of a[0].toArray()){if(!(e instanceof F))throw new Error("Invalid Argument");l.push(e.hasZ?e.hasM?[e.x,e.y,e.z,e.m]:[e.x,e.y,e.z]:[e.x,e.y])}l.length>0&&(s=a[0].get(0).hasZ,f=a[0].get(0).hasM)}return!(l.length<3)&&J(l,f,s)}))},P.polygon=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(s[0]instanceof e){if(f=a(r.parseGeometryFromDictionary(s[0]),n.spatialReference),f instanceof d==!1)throw new Error("Illegal Parameter")}else f=s[0]instanceof d?N(s[0].toJSON()):a(new d(JSON.parse(s[0])),n.spatialReference);if(null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.polyline=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(s[0]instanceof e){if(f=a(r.parseGeometryFromDictionary(s[0]),n.spatialReference),f instanceof S==!1)throw new Error("Illegal Parameter")}else f=s[0]instanceof S?N(s[0].toJSON()):a(new S(JSON.parse(s[0])),n.spatialReference);if(null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.point=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(s[0]instanceof e){if(f=a(r.parseGeometryFromDictionary(s[0]),n.spatialReference),f instanceof F==!1)throw new Error("Illegal Parameter")}else f=s[0]instanceof F?N(s[0].toJSON()):a(new F(JSON.parse(s[0])),n.spatialReference);if(null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.multipoint=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(s[0]instanceof e){if(f=a(r.parseGeometryFromDictionary(s[0]),n.spatialReference),f instanceof A==!1)throw new Error("Illegal Parameter")}else f=s[0]instanceof A?N(s[0].toJSON()):a(new A(JSON.parse(s[0])),n.spatialReference);if(null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.extent=function(n,i){return M(n,i,(function(i,o,f){f=s(f),t(f,1,1);let c=null;if(f[0]instanceof e)c=a(r.parseGeometryFromDictionary(f[0]),n.spatialReference);else if(f[0]instanceof F){const e={xmin:f[0].x,ymin:f[0].y,xmax:f[0].x,ymax:f[0].y,spatialReference:f[0].spatialReference.toJSON()},r=f[0];r.hasZ?(e.zmin=r.z,e.zmax=r.z):r.hasM&&(e.mmin=r.m,e.mmax=r.m),c=N(e)}else c=f[0]instanceof d||f[0]instanceof S||f[0]instanceof A?N(f[0].extent.toJSON()):f[0]instanceof R?N(f[0].toJSON()):a(new R(JSON.parse(f[0])),n.spatialReference);if(null!==c&&!1===c.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(c)}))},P.geometry=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(f=D(s[0])?a(s[0].geometry(),n.spatialReference):s[0]instanceof e?a(r.parseGeometryFromDictionary(s[0]),n.spatialReference):a(N(JSON.parse(s[0])),n.spatialReference),null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.setgeometry=function(e,r){return M(e,r,(function(e,r,n){if(t(n,2,2),!D(n[0]))throw new Error("Illegal Argument");if(!0===n[0].immutable)throw new Error("Feature is Immutable");if(!(n[1]instanceof I||null===n[1]))throw new Error("Illegal Argument");return n[0]._geometry=n[1],f}))},P.feature=function(n,t){return M(n,t,(function(t,i,o){if(0===o.length)throw new Error("Missing Parameters");let l=null;if(1===o.length)if(c(o[0]))l=r.fromJson(JSON.parse(o[0]));else if(D(o[0]))l=r.createFromArcadeFeature(o[0]);else if(o[0]instanceof I)l=r.createFromGraphicLikeObject(o[0],null,null);else{if(!(o[0]instanceof e))throw new Error("Illegal Argument");{let n=o[0].hasField("geometry")?o[0].field("geometry"):null,t=o[0].hasField("attributes")?o[0].field("attributes"):null;null!==n&&n instanceof e&&(n=r.parseGeometryFromDictionary(n)),null!==t&&(t=r.parseAttributesFromDictionary(t)),l=r.createFromGraphicLikeObject(n,t,null)}}else if(2===o.length){let n=null,t=null;if(null!==o[0])if(o[0]instanceof I)n=o[0];else{if(!(n instanceof e))throw new Error("Illegal Argument");n=r.parseGeometryFromDictionary(o[0])}if(null!==o[1]){if(!(o[1]instanceof e))throw new Error("Illegal Argument");t=r.parseAttributesFromDictionary(o[1])}l=r.createFromGraphicLikeObject(n,t,null)}else{let n=null;const t={};if(null!==o[0])if(o[0]instanceof I)n=o[0];else{if(!(n instanceof e))throw new Error("Illegal Argument");n=r.parseGeometryFromDictionary(o[0])}for(let e=1;e<o.length;e+=2){const r=u(o[e]),n=o[e+1];if(!(null==n||c(n)||isNaN(n)||m(n)||g(n)||p(n)))throw new Error("Illegal Argument");if(h(n)||!1===w(n))throw new Error("Illegal Argument");t[r]=n===f?null:n}l=r.createFromGraphicLikeObject(n,t,null)}return l._geometry=a(l.geometry(),n.spatialReference),l.immutable=!1,l}))},P.dictionary=function(r,n){return M(r,n,(function(r,n,t){if(0===t.length){const r=new e;return r.immutable=!1,r}if(1===t.length&&c(t[0]))try{const r=JSON.parse(t[0]),n=e.convertObjectToArcadeDictionary(r,!1);return n.immutable=!1,n}catch(s){throw new Error("Missing Parameters or Illegal Json")}if(t.length%2!=0)throw new Error("Missing Parameters");const a={};for(let e=0;e<t.length;e+=2){const r=u(t[e]),n=t[e+1];if(!(null==n||c(n)||isNaN(n)||m(n)||g(n)||p(n)||i(n)||o(n)))throw new Error("Illegal Argument");if(h(n))throw new Error("Illegal Argument");a[r]=n===f?null:n}const l=new e(a);return l.immutable=!1,l}))},P.haskey=function(r,n){return M(r,n,(function(r,n,i){t(i,2,2);const o=u(i[1]);if(D(i[0]))return i[0].hasField(o);if(i[0]instanceof e)return i[0].hasField(o);throw new Error("Illegal Argument")}))},P.indexof=function(e,r){return M(e,r,(function(e,r,n){t(n,2,2);const a=n[1];if(i(n[0])){for(let e=0;e<n[0].length;e++)if(y(a,n[0][e]))return e;return-1}if(o(n[0])){const e=n[0].length();for(let r=0;r<e;r++)if(y(a,n[0].get(r)))return r;return-1}throw new Error("Illegal Argument")}))},P.angle=function(e,r){return M(e,r,(function(e,r,n){if(n=s(n),t(n,2,3),!(n[0]instanceof F))throw new Error("Illegal Argument");if(!(n[1]instanceof F))throw new Error("Illegal Argument");if(n.length>2&&!(n[2]instanceof F))throw new Error("Illegal Argument");return 2===n.length?j(n[0],n[1]):b(n[0],n[1],n[2])}))},P.bearing=function(e,r){return M(e,r,(function(e,r,n){if(n=s(n),t(n,2,3),!(n[0]instanceof F))throw new Error("Illegal Argument");if(!(n[1]instanceof F))throw new Error("Illegal Argument");if(n.length>2&&!(n[2]instanceof F))throw new Error("Illegal Argument");return 2===n.length?x(n[0],n[1]):G(n[0],n[1],n[2])}))},P.isselfintersecting=function(e,r){return M(e,r,(function(r,n,a){a=s(a),t(a,1,1);let l=a[0];if(l instanceof d)return l.isSelfIntersecting;if(l instanceof S)return l=l.paths,O(l);if(l instanceof A){const e=l.points;for(let r=0;r<e.length;r++)for(let n=0;n<e.length;n++)if(n!==r){let t=!0;for(let i=0;i<e[r].length;i++)if(e[r][i]!==e[n][i]){t=!1;break}if(!0===t)return!0}}return!(!i(l)&&!o(l))&&(l=E(l,e.spatialReference),null!==l&&(l=l.paths),O(l))}))}}export{P as registerFunctions};
5
+ import e from"../Dictionary.js";import r from"../Feature.js";import n from"../ImmutablePointArray.js";import{p as t,a as i,b as o,r as a,J as l,K as s,v as f,f as c,d as u,n as m,j as g,i as p,c as h,x as w,e as y,L as E}from"../../chunks/languageUtils.js";import R from"../../geometry/Extent.js";import I from"../../geometry/Geometry.js";import A from"../../geometry/Multipoint.js";import F from"../../geometry/Point.js";import d from"../../geometry/Polygon.js";import S from"../../geometry/Polyline.js";import{angle2D as j,angleBetween2D as b,bearing2D as x,bearingBetween2D as G,pathsSelfIntersecting as O}from"./centroid.js";import{fromJSON as N}from"../../geometry/support/jsonUtils.js";import{isClockwise as J}from"../../geometry/support/coordsUtils.js";function D(e){return e&&(e instanceof r||"object"==typeof e&&"FeatureSetReader"===e.type)}function P(P,M){P.ringisclockwise=function(e,r){return M(e,r,(function(e,r,a){t(a,1,1);let l=[],s=!1,f=!1;if(null===a[0])return!1;if(i(a[0])){for(const e of a[0]){if(!(e instanceof F))throw new Error("Invalid Argument");l.push(e.hasZ?e.hasM?[e.x,e.y,e.z,e.m]:[e.x,e.y,e.z]:[e.x,e.y])}l.length>0&&(s=a[0][0].hasZ,f=a[0][0].hasM)}else if(a[0]instanceof n)l=a[0]._elements,l.length>0&&(s=a[0]._hasZ,f=a[0]._hasM);else{if(!o(a[0]))throw new Error("Invalid Argument");for(const e of a[0].toArray()){if(!(e instanceof F))throw new Error("Invalid Argument");l.push(e.hasZ?e.hasM?[e.x,e.y,e.z,e.m]:[e.x,e.y,e.z]:[e.x,e.y])}l.length>0&&(s=a[0].get(0).hasZ,f=a[0].get(0).hasM)}return!(l.length<3)&&J(l,f,s)}))},P.polygon=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(s[0]instanceof e){if(f=a(r.parseGeometryFromDictionary(s[0]),n.spatialReference),f instanceof d==!1)throw new Error("Illegal Parameter")}else f=s[0]instanceof d?N(s[0].toJSON()):a(new d(JSON.parse(s[0])),n.spatialReference);if(null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.polyline=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(s[0]instanceof e){if(f=a(r.parseGeometryFromDictionary(s[0]),n.spatialReference),f instanceof S==!1)throw new Error("Illegal Parameter")}else f=s[0]instanceof S?N(s[0].toJSON()):a(new S(JSON.parse(s[0])),n.spatialReference);if(null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.point=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(s[0]instanceof e){if(f=a(r.parseGeometryFromDictionary(s[0]),n.spatialReference),f instanceof F==!1)throw new Error("Illegal Parameter")}else f=s[0]instanceof F?N(s[0].toJSON()):a(new F(JSON.parse(s[0])),n.spatialReference);if(null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.multipoint=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(s[0]instanceof e){if(f=a(r.parseGeometryFromDictionary(s[0]),n.spatialReference),f instanceof A==!1)throw new Error("Illegal Parameter")}else f=s[0]instanceof A?N(s[0].toJSON()):a(new A(JSON.parse(s[0])),n.spatialReference);if(null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.extent=function(n,i){return M(n,i,(function(i,o,f){f=s(f),t(f,1,1);let c=null;if(f[0]instanceof e)c=a(r.parseGeometryFromDictionary(f[0]),n.spatialReference);else if(f[0]instanceof F){const e={xmin:f[0].x,ymin:f[0].y,xmax:f[0].x,ymax:f[0].y,spatialReference:f[0].spatialReference.toJSON()},r=f[0];r.hasZ?(e.zmin=r.z,e.zmax=r.z):r.hasM&&(e.mmin=r.m,e.mmax=r.m),c=N(e)}else c=f[0]instanceof d||f[0]instanceof S||f[0]instanceof A?N(f[0].extent.toJSON()):f[0]instanceof R?N(f[0].toJSON()):a(new R(JSON.parse(f[0])),n.spatialReference);if(null!==c&&!1===c.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(c)}))},P.geometry=function(n,i){return M(n,i,(function(i,o,s){t(s,1,1);let f=null;if(null===s[0])return null;if(f=D(s[0])?a(s[0].geometry(),n.spatialReference):s[0]instanceof e?a(r.parseGeometryFromDictionary(s[0]),n.spatialReference):a(N(JSON.parse(s[0])),n.spatialReference),null!==f&&!1===f.spatialReference.equals(n.spatialReference))throw new Error("Cannot create Geometry in this SpatialReference. Engine is using a different spatial reference.");return l(f)}))},P.setgeometry=function(e,r){return M(e,r,(function(e,r,n){if(t(n,2,2),!D(n[0]))throw new Error("Illegal Argument");if(!0===n[0].immutable)throw new Error("Feature is Immutable");if(!(n[1]instanceof I||null===n[1]))throw new Error("Illegal Argument");return n[0]._geometry=n[1],f}))},P.feature=function(n,t){return M(n,t,(function(t,i,o){if(0===o.length)throw new Error("Missing Parameters");let l=null;if(1===o.length)if(c(o[0]))l=r.fromJson(JSON.parse(o[0]));else if(D(o[0]))l=r.createFromArcadeFeature(o[0]);else if(o[0]instanceof I)l=r.createFromGraphicLikeObject(o[0],null,null);else{if(!(o[0]instanceof e))throw new Error("Illegal Argument");{let n=o[0].hasField("geometry")?o[0].field("geometry"):null,t=o[0].hasField("attributes")?o[0].field("attributes"):null;null!==n&&n instanceof e&&(n=r.parseGeometryFromDictionary(n)),null!==t&&(t=r.parseAttributesFromDictionary(t)),l=r.createFromGraphicLikeObject(n,t,null)}}else if(2===o.length){let n=null,t=null;if(null!==o[0])if(o[0]instanceof I)n=o[0];else{if(!(n instanceof e))throw new Error("Illegal Argument");n=r.parseGeometryFromDictionary(o[0])}if(null!==o[1]){if(!(o[1]instanceof e))throw new Error("Illegal Argument");t=r.parseAttributesFromDictionary(o[1])}l=r.createFromGraphicLikeObject(n,t,null)}else{let n=null;const t={};if(null!==o[0])if(o[0]instanceof I)n=o[0];else{if(!(n instanceof e))throw new Error("Illegal Argument");n=r.parseGeometryFromDictionary(o[0])}for(let e=1;e<o.length;e+=2){const r=u(o[e]),n=o[e+1];if(!(null==n||c(n)||isNaN(n)||m(n)||g(n)||p(n)))throw new Error("Illegal Argument");if(h(n)||!1===w(n))throw new Error("Illegal Argument");t[r]=n===f?null:n}l=r.createFromGraphicLikeObject(n,t,null)}return l._geometry=a(l.geometry(),n.spatialReference),l.immutable=!1,l}))},P.dictionary=function(r,n){return M(r,n,(function(r,n,t){if(0===t.length){const r=new e;return r.immutable=!1,r}if(1===t.length&&c(t[0]))try{const r=JSON.parse(t[0]),n=e.convertObjectToArcadeDictionary(r,!1);return n.immutable=!1,n}catch(s){throw new Error("Missing Parameters or Illegal Json")}if(t.length%2!=0)throw new Error("Missing Parameters");const a={};for(let e=0;e<t.length;e+=2){const r=u(t[e]),n=t[e+1];if(!(null==n||c(n)||isNaN(n)||m(n)||g(n)||p(n)||i(n)||o(n)))throw new Error("Illegal Argument");if(h(n))throw new Error("Illegal Argument");a[r]=n===f?null:n}const l=new e(a);return l.immutable=!1,l}))},P.haskey=function(r,n){return M(r,n,(function(r,n,i){t(i,2,2);const o=u(i[1]);if(D(i[0]))return i[0].hasField(o);if(i[0]instanceof e)return i[0].hasField(o);throw new Error("Illegal Argument")}))},P.indexof=function(e,r){return M(e,r,(function(e,r,n){t(n,2,2);const a=n[1];if(i(n[0])){for(let e=0;e<n[0].length;e++)if(y(a,n[0][e]))return e;return-1}if(o(n[0])){const e=n[0].length();for(let r=0;r<e;r++)if(y(a,n[0].get(r)))return r;return-1}throw new Error("Illegal Argument")}))},P.angle=function(e,r){return M(e,r,(function(e,r,n){if(n=s(n),t(n,2,3),!(n[0]instanceof F))throw new Error("Illegal Argument");if(!(n[1]instanceof F))throw new Error("Illegal Argument");if(n.length>2&&!(n[2]instanceof F))throw new Error("Illegal Argument");return 2===n.length?j(n[0],n[1]):b(n[0],n[1],n[2])}))},P.bearing=function(e,r){return M(e,r,(function(e,r,n){if(n=s(n),t(n,2,3),!(n[0]instanceof F))throw new Error("Illegal Argument");if(!(n[1]instanceof F))throw new Error("Illegal Argument");if(n.length>2&&!(n[2]instanceof F))throw new Error("Illegal Argument");return 2===n.length?x(n[0],n[1]):G(n[0],n[1],n[2])}))},P.isselfintersecting=function(e,r){return M(e,r,(function(r,n,a){a=s(a),t(a,1,1);let l=a[0];if(l instanceof d)return l.isSelfIntersecting;if(l instanceof S)return l=l.paths,O(l);if(l instanceof A){const e=l.points;for(let r=0;r<e.length;r++)for(let n=0;n<e.length;n++)if(n!==r){let t=!0;for(let i=0;i<e[r].length;i++)if(e[r][i]!==e[n][i]){t=!1;break}if(!0===t)return!0}}return!(!i(l)&&!o(l))&&(l=E(l,e.spatialReference),null!==l&&(l=l.paths),O(l))}))}}export{P as registerFunctions};
@@ -1 +1 @@
1
- var RemoteClient;(()=>{var e={88277:(e,t,r)=>{r.p=self.esriConfig.assetsPath+"/esri/core/workers/"},68773:(e,t,r)=>{"use strict";r.d(t,{Z:()=>i}),r(80442);var n,o=r(78286),s=r(17202);const i={apiKey:void 0,applicationUrl:null==(n=globalThis.location)?void 0:n.href,assetsPath:"",fontsUrl:"https://static.arcgis.com/fonts",geometryService:null,geometryServiceUrl:"https://utility.arcgisonline.com/arcgis/rest/services/Geometry/GeometryServer",geoRSSServiceUrl:"https://utility.arcgis.com/sharing/rss",kmlServiceUrl:"https://utility.arcgis.com/sharing/kml",portalUrl:"https://www.arcgis.com",workers:{loaderConfig:{has:{},paths:{},map:{},packages:[]}},request:{httpsDomains:["arcgis.com","arcgisonline.com","esrikr.com","premiumservices.blackbridge.com","esripremium.accuweather.com","gbm.digitalglobe.com","firstlook.digitalglobe.com","msi.digitalglobe.com"],interceptors:[],maxUrlLength:2e3,proxyRules:[],proxyUrl:null,timeout:6e4,trustedServers:[],useIdentity:!0},log:{interceptors:[],level:null}};if(globalThis.esriConfig&&((0,o.RH)(i,globalThis.esriConfig,!0),delete i.has),!i.assetsPath){const e="4.22.0";i.assetsPath=`https://cdn.jsdelivr.net/npm/@arcgis/core@${e}-next.${s.r}/assets`}i.baseUrl&&console.warn("[esri.config]","baseUrl has been replaced by assetsPath"),Object.defineProperty(i,"baseUrl",{set(){console.warn("[esri.config]","baseUrl has been replaced by assetsPath")}}),i.request.corsEnabledServers=[],i.request.corsEnabledServers.push=function(){return console.warn("[esri.config]","request.corsEnabledServers is not supported and will be removed in a future release. See http://esriurl.com/cors8664"),0}},20102:(e,t,r)=>{"use strict";r.d(t,{Z:()=>i});var n=r(22974),o=r(92604),s=r(58896);class i extends s.Z{constructor(e,t,r){if(super(e,t,r),!(this instanceof i))return new i(e,t,r)}toJSON(){if(null!=this.details)try{return{name:this.name,message:this.message,details:JSON.parse(JSON.stringify(this.details,((e,t)=>{if(t&&"object"==typeof t&&"function"==typeof t.toJSON)return t;try{return(0,n.d9)(t)}catch(e){return"[object]"}})))}}catch(e){throw o.Z.getLogger("esri.core.Error").error(e),e}return{name:this.name,message:this.message,details:this.details}}static fromJSON(e){return new i(e.name,e.message,e.details)}}i.prototype.type="error"},92604:(e,t,r)=>{"use strict";r.d(t,{Z:()=>a});var n=r(68773),o=(r(80442),r(70586)),s=r(19153);const i={info:0,warn:1,error:2,none:3};class a{constructor(e){this.level=null,this._module="",this._parent=null,this.writer=null,this._loggedMessages={error:new Map,warn:new Map,info:new Map},null!=e.level&&(this.level=e.level),null!=e.writer&&(this.writer=e.writer),this._module=e.module,a._loggers[this.module]=this;const t=this.module.lastIndexOf(".");-1!==t&&(this._parent=a.getLogger(this.module.slice(0,t)))}get module(){return this._module}get parent(){return this._parent}error(...e){this._log("error","always",...e)}warn(...e){this._log("warn","always",...e)}info(...e){this._log("info","always",...e)}errorOnce(...e){this._log("error","once",...e)}warnOnce(...e){this._log("warn","once",...e)}infoOnce(...e){this._log("info","once",...e)}errorOncePerTick(...e){this._log("error","oncePerTick",...e)}warnOncePerTick(...e){this._log("warn","oncePerTick",...e)}infoOncePerTick(...e){this._log("info","oncePerTick",...e)}get test(){const e=this;return{loggedMessages:e._loggedMessages,clearLoggedWarnings:()=>e._loggedMessages.warn.clear()}}static get testSingleton(){return{resetLoggers(e={}){const t=a._loggers;return a._loggers=e,t},set throttlingDisabled(e){a._throttlingDisabled=e}}}static getLogger(e){let t=a._loggers[e];return t||(t=new a({module:e})),t}_log(e,t,...r){if(this._matchLevel(e)){if("always"!==t&&!a._throttlingDisabled){const n=this._argsToKey(r),o=this._loggedMessages[e].get(n);if("once"===t&&null!=o||"oncePerTick"===t&&o&&o>=a._tickCounter)return;this._loggedMessages[e].set(n,a._tickCounter),a._scheduleTickCounterIncrement()}for(const t of n.Z.log.interceptors)if(t(e,this.module,...r))return;this._inheritedWriter()(e,this.module,...r)}}_parentWithMember(e,t){let r=this;for(;(0,o.pC)(r);){const t=r[e];if((0,o.pC)(t))return t;r=r.parent}return t}_inheritedWriter(){return this._parentWithMember("writer",this._consoleWriter)}_consoleWriter(e,t,...r){console[e](`[${t}]`,...r)}_matchLevel(e){const t=n.Z.log.level?n.Z.log.level:"warn";return i[this._parentWithMember("level",t)]<=i[e]}_argsToKey(...e){return(0,s.hP)(JSON.stringify(e,((e,t)=>"object"!=typeof t||Array.isArray(t)?t:"[Object]")))}static _scheduleTickCounterIncrement(){a._tickCounterScheduled||(a._tickCounterScheduled=!0,Promise.resolve().then((()=>{a._tickCounter++,a._tickCounterScheduled=!1})))}}a._loggers={},a._tickCounter=0,a._tickCounterScheduled=!1,a._throttlingDisabled=!1},58896:(e,t,r)=>{"use strict";r.d(t,{Z:()=>o});var n=r(78286);class o{constructor(e,t,r){this.name=e,this.details=r,this.message=void 0,this instanceof o&&(this.message=t&&function(e,t){return e.replace(/\$\{([^\s\:\}]*)(?:\:([^\s\:\}]+))?\}/g,(function(e,r){if(""===r)return"$";const o=(0,n.hS)(r,t),s=null==o?"":o;if(void 0===s)throw new Error(`could not find key "${r}" in template`);return s.toString()}))}(t,r)||"")}toString(){return"["+this.name+"]: "+this.message}}},77734:(e,t,r)=>{"use strict";r.d(t,{Z:()=>n});class n{constructor(e=1){this._seed=e}set seed(e){this._seed=null==e?Math.random()*n._m:e}getInt(){return this._seed=(n._a*this._seed+n._c)%n._m,this._seed}getFloat(){return this.getInt()/(n._m-1)}getIntRange(e,t){return Math.round(this.getFloatRange(e,t))}getFloatRange(e,t){const r=t-e;return e+this.getInt()/n._m*r}}n._m=2147483647,n._a=48271,n._c=0},67676:(e,t,r)=>{"use strict";r.d(t,{SO:()=>l,a9:()=>a,fS:()=>s,cq:()=>f,w6:()=>c,Od:()=>b,e$:()=>d,FY:()=>p});var n=r(70586),o=r(77734);function s(e,t,r){if((0,n.Wi)(e)&&(0,n.Wi)(t))return!0;if((0,n.Wi)(e)||(0,n.Wi)(t)||e.length!==t.length)return!1;if(r){for(let n=0;n<e.length;n++)if(!r(e[n],t[n]))return!1}else for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}const i=!!Array.prototype.fill;function a(e,t){if(i)return new Array(e).fill(t);const r=new Array(e);for(let n=0;n<e;n++)r[n]=t;return r}function c(e,t){void 0===t&&(t=e,e=0);const r=new Array(t-e);for(let n=e;n<t;n++)r[n-e]=n;return r}class l{constructor(){this.last=0}}const u=new l;function f(e,t,r,n){n=n||u;const o=Math.max(0,n.last-10);for(let s=o;s<r;++s)if(e[s]===t)return n.last=s,s;const s=Math.min(o,r);for(let r=0;r<s;++r)if(e[r]===t)return n.last=r,r;return-1}function d(e,t,r,n){const o=null==r?e.length:r,s=f(e,t,o,n);if(-1!==s)return e[s]=e[o-1],null==r&&e.pop(),t}const h=new Set;function p(e,t,r=e.length,n=t.length,o,s){if(0===n||0===r)return r;h.clear();for(let e=0;e<n;++e)h.add(t[e]);o=o||u;const i=Math.max(0,o.last-10);for(let t=i;t<r;++t)if(h.has(e[t])&&(s&&s.push(e[t]),h.delete(e[t]),e[t]=e[r-1],--r,--t,0===h.size||0===r))return h.clear(),r;for(let t=0;t<i;++t)if(h.has(e[t])&&(s&&s.push(e[t]),h.delete(e[t]),e[t]=e[r-1],--r,--t,0===h.size||0===r))return h.clear(),r;return h.clear(),r}function b(e,t){const r=e.indexOf(t);return-1!==r?(e.splice(r,1),t):null}new o.Z},91460:(e,t,r)=>{"use strict";function n(e){return e&&("function"==typeof e.on||"function"==typeof e.addEventListener)}function o(e,t,r){if(!n(e))throw new TypeError("target is not a Evented or EventTarget object");if("on"in e)return e.on(t,r);if(Array.isArray(t)){const n=t.slice();for(const t of n)e.addEventListener(t,r);return{remove(){for(const t of n)e.removeEventListener(t,r)}}}return e.addEventListener(t,r),{remove(){e.removeEventListener(t,r)}}}function s(e,t,r){if(!n(e))throw new TypeError("target is not a Evented or EventTarget object");if("once"in e)return e.once(t,r);const s=o(e,t,(t=>{s.remove(),r.call(e,t)}));return{remove(){s.remove()}}}r.d(t,{vT:()=>n,on:()=>o,IH:()=>s})},80442:(e,t,r)=>{"use strict";var n,o;let s;var i,a;function c(e){return"function"==typeof s[e]?s[e]=s[e](globalThis):s[e]}r.d(t,{Z:()=>c}),s=null!=(n=globalThis.dojoConfig)&&n.has||null!=(o=globalThis.esriConfig)&&o.has?{...null==(i=globalThis.dojoConfig)?void 0:i.has,...null==(a=globalThis.esriConfig)?void 0:a.has}:{},c.add=(e,t,r,n)=>((n||void 0===s[e])&&(s[e]=t),r&&c(e)),c.cache=s,c.add("esri-deprecation-warnings",!0),(()=>{var e;c.add("host-webworker",void 0!==globalThis.WorkerGlobalScope&&self instanceof globalThis.WorkerGlobalScope);const t="undefined"!=typeof window&&"undefined"!=typeof location&&"undefined"!=typeof document&&window.location===location&&window.document===document;if(c.add("host-browser",t),c.add("host-node","object"==typeof globalThis.process&&(null==(e=globalThis.process.versions)?void 0:e.node)&&globalThis.process.versions.v8),c.add("dom",t),c("host-browser")){const e=navigator,t=e.userAgent,r=e.appVersion,n=parseFloat(r);if(c.add("wp",parseFloat(t.split("Windows Phone")[1])||void 0),c.add("msapp",parseFloat(t.split("MSAppHost/")[1])||void 0),c.add("khtml",r.includes("Konqueror")?n:void 0),c.add("edge",parseFloat(t.split("Edge/")[1])||void 0),c.add("opr",parseFloat(t.split("OPR/")[1])||void 0),c.add("webkit",!c("wp")&&!c("edge")&&parseFloat(t.split("WebKit/")[1])||void 0),c.add("chrome",!c("edge")&&!c("opr")&&parseFloat(t.split("Chrome/")[1])||void 0),c.add("android",!c("wp")&&parseFloat(t.split("Android ")[1])||void 0),c.add("safari",!r.includes("Safari")||c("wp")||c("chrome")||c("android")||c("edge")||c("opr")?void 0:parseFloat(r.split("Version/")[1])),c.add("mac",r.includes("Macintosh")),!c("wp")&&t.match(/(iPhone|iPod|iPad)/)){const e=RegExp.$1.replace(/P/,"p"),r=t.match(/OS ([\d_]+)/)?RegExp.$1:"1",n=parseFloat(r.replace(/_/,".").replace(/_/g,""));c.add(e,n),c.add("ios",n)}c.add("trident",parseFloat(r.split("Trident/")[1])||void 0),c("webkit")||(!t.includes("Gecko")||c("wp")||c("khtml")||c("trident")||c("edge")||c.add("mozilla",n),c("mozilla")&&c.add("ff",parseFloat(t.split("Firefox/")[1]||t.split("Minefield/")[1])||void 0))}})(),(()=>{if(globalThis.navigator){const e=navigator.userAgent,t=/Android|webOS|iPhone|iPad|iPod|BlackBerry|Opera Mini|IEMobile/i.test(e),r=/iPhone/i.test(e);t&&c.add("esri-mobile",t),r&&c.add("esri-iPhone",r),c.add("esri-geolocation",!!navigator.geolocation)}c.add("esri-canvas-svg-support",!c("trident")),c.add("esri-wasm","WebAssembly"in globalThis),c.add("esri-shared-array-buffer",(()=>{const e="SharedArrayBuffer"in globalThis,t=!1===globalThis.crossOriginIsolated;return e&&!t})),c.add("esri-atomics","Atomics"in globalThis),c.add("esri-workers","Worker"in globalThis),c.add("esri-text-decoder","TextDecoder"in globalThis),c.add("esri-text-encoder","TextEncoder"in globalThis),c.add("web-feat:cache","caches"in globalThis),c.add("esri-workers-arraybuffer-transfer",!c("safari")||Number(c("safari"))>=12),c.add("featurelayer-simplify-thresholds",[.5,.5,.5,.5]),c.add("featurelayer-simplify-payload-size-factors",[1,1,4]),c.add("featurelayer-snapshot-enabled",!0),c.add("featurelayer-snapshot-point-min-threshold",8e4),c.add("featurelayer-snapshot-point-max-threshold",4e5),c.add("featurelayer-snapshot-point-coverage",.1),c.add("featurelayer-advanced-symbols",!1),c.add("featurelayer-pbf",!0),c.add("featurelayer-pbf-statistics",!1),c.add("feature-layers-workers",!0),c.add("mapview-transitions-duration",200),c.add("mapserver-pbf-enabled",!1),c.add("vectortilelayer-max-buffers",c("ff")?160:Number.POSITIVE_INFINITY),c("host-webworker")||c("host-browser")&&(c.add("esri-csp-restrictions",(()=>{try{new Function}catch{return!0}return!1})),c.add("esri-image-decode",(()=>{if("decode"in new Image){const e=new Image;return e.src='data:image/svg+xml;charset=UTF-8,<svg version="1.1" xmlns="http://www.w3.org/2000/svg"></svg>',void e.decode().then((()=>{c.add("esri-image-decode",!0,!0,!0)})).catch((()=>{c.add("esri-image-decode",!1,!0,!0)}))}return!1})),c.add("esri-url-encodes-apostrophe",(()=>{const e=window.document.createElement("a");return e.href="?'",e.href.includes("?%27")})))})()},22974:(e,t,r)=>{"use strict";r.d(t,{d9:()=>s,fS:()=>i,yd:()=>o}),r(67676),r(80442);var n=r(1533);function o(e,t){let r;if(t)for(r in e)e.hasOwnProperty(r)&&(void 0===e[r]?delete e[r]:e[r]instanceof Object&&o(e[r],!0));else for(r in e)e.hasOwnProperty(r)&&void 0===e[r]&&delete e[r];return e}function s(e){if(!e||"object"!=typeof e||"function"==typeof e)return e;if((0,n.W0)(e)||(0,n.lq)(e)||(0,n.KZ)(e)||(0,n.z3)(e)||(0,n.Uc)(e)||(0,n.Hx)(e)||(0,n.ZY)(e)||(0,n.xZ)(e)||(0,n.fS)(e))return(0,n.tP)(e);if(e instanceof Date)return new Date(e.getTime());if(e instanceof ArrayBuffer)return e.slice(0,e.byteLength);if(e instanceof Map){const t=new Map;return e.forEach(((e,r)=>{t.set(r,s(e))})),t}if(e instanceof Set){const t=new Set;return e.forEach((e=>{t.add(s(e))})),t}let t;const r=e;if("function"==typeof r.clone)t=r.clone();else if("function"==typeof r.map&&"function"==typeof r.forEach)t=r.map(s);else if("function"==typeof r.notifyChange&&"function"==typeof r.watch)t=r.clone();else{t={};for(const r of Object.getOwnPropertyNames(e))t[r]=s(e[r])}return t}function i(e,t){return e===t||"number"==typeof e&&isNaN(e)&&"number"==typeof t&&isNaN(t)||"function"==typeof(e||{}).getTime&&"function"==typeof(t||{}).getTime&&e.getTime()===t.getTime()||!1}},70586:(e,t,r)=>{"use strict";function n(e){return null!=e}function o(e){return null==e}function s(e){return void 0===e}function i(e,t){return n(e)?t(e):null}function a(e){return e}function c(e,t){if(o(e))throw new Error(t);return e}function l(e,t){return n(e)?e:"function"==typeof t?t():t}function u(e){return n(e)&&e.destroy(),null}function f(e){return n(e)&&e.dispose(),null}function d(e){return n(e)&&e.remove(),null}function h(e){return n(e)&&e.release(),null}function p(e){return null}function b(e,t){const r=new Array;for(const n of e)r.push(m(n,null,t));return r}function g(e,t){for(const r of e)m(r,null,t)}function m(e,t,r){return n(e)?r(e):t}function y(e,t){return n(e)?t(e):null}function v(e){return e.filter((e=>n(e)))}function w(e,...t){let r=e;for(let e=0;e<t.length&&r;++e)r=r[t[e]];return r}function _(e){return e}r.d(t,{Po:()=>y,yw:()=>i,j0:()=>_,SC:()=>u,O3:()=>f,lV:()=>v,JR:()=>g,U2:()=>w,Wi:()=>o,pC:()=>n,o8:()=>s,Fd:()=>b,R2:()=>m,Bd:()=>p,RY:()=>h,hw:()=>d,Wg:()=>a,Pt:()=>l,s3:()=>c})},78286:(e,t,r)=>{"use strict";r.d(t,{RH:()=>o,hS:()=>s,RB:()=>i});var n=r(22974);function o(e,t,r=!1){return c(e,t,r)}function s(e,t){if(null!=t)return t[e]||a(e.split("."),!1,t)}function i(e,t,r){const n=e.split("."),o=n.pop(),s=a(n,!0,r);s&&o&&(s[o]=t)}function a(e,t,r){let n=r;for(const r of e){if(null==n)return;if(!(r in n)){if(!t)return;n[r]={}}n=n[r]}return n}function c(e,t,r){return t?Object.keys(t).reduce((function(e,o){let s=e[o],i=t[o];return s===i?e:void 0===s?(e[o]=(0,n.d9)(i),e):(Array.isArray(i)||Array.isArray(e)?(s=s?Array.isArray(s)?e[o]=s.concat():e[o]=[s]:e[o]=[],i&&(Array.isArray(i)||(i=[i]),r?i.forEach((e=>{-1===s.indexOf(e)&&s.push(e)})):e[o]=i.concat())):i&&"object"==typeof i?e[o]=c(s,i,r):e.hasOwnProperty(o)&&!t.hasOwnProperty(o)||(e[o]=i),e)}),e||{}):e}},95330:(e,t,r)=>{"use strict";r.d(t,{e4:()=>C,$6:()=>c,Ue:()=>l,zE:()=>u,dD:()=>_,hh:()=>M,vr:()=>j,Ds:()=>A,as:()=>O,WW:()=>P,R8:()=>w,D_:()=>v,Hc:()=>h,tI:()=>T,y8:()=>E,fu:()=>g,$F:()=>m,d1:()=>k,DB:()=>S,r9:()=>p,k_:()=>f,H9:()=>b,Yn:()=>$,gx:()=>x,Hl:()=>y});const n=(o=globalThis,{setTimeout:(e,t)=>{const r=o.setTimeout(e,t);return{remove:()=>o.clearTimeout(r)}}});var o,s=r(20102),i=r(91460),a=(r(92604),r(70586));function c(e){return Promise.all(e)}function l(e){return new Promise(((t,r)=>{try{e(t,r)}catch(e){Promise.resolve().then((()=>r(e)))}}))}function u(e="Aborted"){return new s.Z("AbortError",e)}function f(e,t="Aborted"){if(h(e))throw u(t)}function d(e){return(0,a.pC)(e)?"aborted"in e?e:e.signal:e}function h(e){const t=d(e);return(0,a.pC)(t)&&t.aborted}function p(e){if(v(e))throw e}function b(e){if(!v(e))throw e}function g(e,t){const r=d(e);if(!(0,a.Wi)(r)){if(!r.aborted)return(0,i.IH)(r,"abort",(()=>t()));t()}}function m(e,t){const r=d(e);if(!(0,a.Wi)(r))return f(r),(0,i.IH)(r,"abort",(()=>t(u())))}function y(e,t){const r=d(t);return(0,a.Wi)(r)?e:new Promise(((r,n)=>{let o=g(t,(()=>n(u())));const s=()=>o=(0,a.hw)(o);e.then(s,s),e.then(r,n)}))}function v(e){return e&&"AbortError"===e.name}function w(e){return e.catch((e=>{if(!v(e))throw e}))}function _(){let e=null;const t=new Promise(((t,r)=>{e={promise:void 0,resolve:t,reject:r}}));return e.promise=t,e}function O(e){if(!e)return;if("function"!=typeof e.forEach){const t=Object.keys(e);return O(t.map((t=>e[t]))).then((e=>{const r={};return t.forEach(((t,n)=>r[t]=e[n])),r}))}const t=e;return l((e=>{const r=[];let n=t.length;0===n&&e(r),t.forEach((t=>{const o={promise:t||Promise.resolve(t)};r.push(o),o.promise.then((e=>{o.value=e})).catch((e=>{o.error=e})).then((()=>{--n,0===n&&e(r)}))}))}))}function P(e){return O(e).then((e=>e.filter((e=>!!e.value)).map((e=>e.value))))}function k(e){return Promise.reject(e)}function S(e){return Promise.resolve(e)}function C(e,t,r){const n=new AbortController;return g(r,(()=>n.abort())),new Promise(((r,o)=>{let s=setTimeout((()=>{s=0,r(t)}),e);g(n,(()=>{s&&(clearTimeout(s),o(u()))}))}))}function E(e){return e&&"function"==typeof e.then}function x(e){return T(e)?e:Promise.resolve(e)}function T(e){return e&&"object"==typeof e&&"then"in e&&"function"==typeof e.then}function A(e,t=-1){let r,n,o,s,i=null;const c=(...l)=>{if(r){n=l,s&&s.reject(u()),s=_();const e=(0,a.j0)(s.promise);if(i){const e=i;i=null,e.abort()}return e}if(o=s||_(),s=null,t>0){const n=new AbortController;r=x(e(...l,n.signal));const o=r;C(t).then((()=>{r===o&&(s?n.abort():i=n)}))}else r=1,r=x(e(...l));const f=()=>{const e=n;n=o=r=i=null,null!=e&&c(...e)},d=r,h=o;return d.then(f,f),d.then(h.resolve,h.reject),(0,a.j0)(h.promise)};return c}function M(){let e,t;const r=new Promise(((r,n)=>{e=r,t=n})),o=t=>{e(t)};return o.resolve=t=>e(t),o.reject=e=>t(e),o.timeout=(e,t)=>n.setTimeout((()=>o.reject(t)),e),o.promise=r,o}function j(e,t){let r,n=new AbortController;const o=e(n.signal);let s={promise:o,finished:!1,abort:()=>{n&&(n.abort(),n=null)}};const i=()=>{s&&(s.finished=!0,s=null),(0,a.pC)(r)&&(r.remove(),r=null),n=null};return o.then(i,i),r=g(t,(()=>{(0,a.pC)(s)&&s.abort()})),s}function $(e){return Promise.resolve().then((()=>{f(e)}))}},19153:(e,t,r)=>{"use strict";r.d(t,{Qs:()=>a,hP:()=>c,gx:()=>i,Cb:()=>l});var n=r(78286);const o=/\{([^\}]+)\}/g;function s(e){return null==e?"":e}function i(e,t){return e.replace(o,"object"==typeof t?(e,r)=>s((0,n.hS)(r,t)):(e,r)=>s(t(r)))}function a(e,t){return e.replace(/([\.$?*|{}\(\)\[\]\\\/\+\-^])/g,(e=>t&&-1!==t.indexOf(e)?e:`\\${e}`))}function c(e){let t=0;for(let r=0;r<e.length;r++)t=(t<<5)-t+e.charCodeAt(r),t|=0;return t}function l(e){return(new DOMParser).parseFromString(e||"","text/html").body.innerText||""}},1533:(e,t,r)=>{"use strict";function n(e,t){if(e.forEach)e.forEach(t);else for(let r=0;r<e.length;r++)t(e[r],r,e)}function o(e,t,r){if(e.slice)return e.slice(t,r);void 0===t?t=0:(t<0&&(t+=e.length),t=Math.min(e.length,Math.max(0,t))),void 0===r?r=e.length:(r<0&&(r+=e.length),r=Math.min(e.length,Math.max(0,r)));const n=Math.max(0,r-t),o=new(0,e.constructor)(n);for(let r=0;r<n;r++)o[r]=e[t+r];return o}function s(e){return e instanceof ArrayBuffer||e&&e.constructor&&"ArrayBuffer"===e.constructor.name}function i(e){return e instanceof Int8Array||e&&e.constructor&&"Int8Array"===e.constructor.name}function a(e){return e instanceof Uint8Array||e&&e.constructor&&"Uint8Array"===e.constructor.name}function c(e){return e instanceof Uint8ClampedArray||e&&e.constructor&&"Uint8ClampedArray"===e.constructor.name}function l(e){return e instanceof Int16Array||e&&e.constructor&&"Int16Array"===e.constructor.name}function u(e){return e instanceof Uint16Array||e&&e.constructor&&"Uint16Array"===e.constructor.name}function f(e){return e instanceof Int32Array||e&&e.constructor&&"Int32Array"===e.constructor.name}function d(e){return e instanceof Uint32Array||e&&e.constructor&&"Uint32Array"===e.constructor.name}function h(e){return e instanceof Float32Array||e&&e.constructor&&"Float32Array"===e.constructor.name}function p(e){return e instanceof Float64Array||e&&e.constructor&&"Float64Array"===e.constructor.name}r.d(t,{Ed:()=>n,eP:()=>s,xZ:()=>h,fS:()=>p,z3:()=>l,Hx:()=>f,W0:()=>i,Uc:()=>u,ZY:()=>d,lq:()=>a,KZ:()=>c,tP:()=>o})},17452:(e,t,r)=>{"use strict";r.d(t,{R9:()=>y,qg:()=>E,tD:()=>M,ZN:()=>le,fl:()=>ue,AX:()=>_,Gd:()=>v,Ie:()=>ie,sJ:()=>Q,AH:()=>K,vt:()=>oe,oh:()=>N,P$:()=>Z,Ml:()=>fe,ed:()=>j,b7:()=>C,D6:()=>R,tm:()=>$,YP:()=>B,jc:()=>D,HK:()=>H,$U:()=>X,oC:()=>Y,kl:()=>W,v_:()=>F,hF:()=>L,_l:()=>V,PF:()=>J,Fv:()=>q,B7:()=>S,u0:()=>P,Yd:()=>ne,Hu:()=>ce,Qj:()=>se,hO:()=>ee,mN:()=>O});var n=r(68773),o=r(20102),s=r(92604),i=r(70586);const a=s.Z.getLogger("esri.core.urlUtils"),c=n.Z.request,l="esri/config: esriConfig.request.proxyUrl is not set.",u=/^\s*[a-z][a-z0-9-+.]*:(?![0-9])/i,f=/^\s*http:/i,d=/^\s*https:/i,h=/^\s*file:/i,p=/:\d+$/,b=/^https?:\/\/[^/]+\.arcgis.com\/sharing(\/|$)/i,g=new RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$"),m=new RegExp("^((([^\\[:]+):)?([^@]+)@)?(\\[([^\\]]+)\\]|([^\\[:]*))(:([0-9]+))?$");class y{constructor(e=""){this.uri=e,this.scheme=null,this.authority=null,this.path=null,this.query=null,this.fragment=null,this.user=null,this.password=null,this.host=null,this.port=null;let t=(0,i.j0)(this.uri.match(g));this.scheme=t[2]||(t[1]?"":null),this.authority=t[4]||(t[3]?"":null),this.path=t[5],this.query=t[7]||(t[6]?"":null),this.fragment=t[9]||(t[8]?"":null),null!=this.authority&&(t=(0,i.j0)(this.authority.match(m)),this.user=t[3]||null,this.password=t[4]||null,this.host=t[6]||t[7],this.port=t[9]||null)}toString(){return this.uri}}const v=new y(n.Z.applicationUrl),w={},_=(()=>{const e=(0,i.j0)(v.path),t=e.substring(0,e.lastIndexOf(e.split("/")[e.split("/").length-1]));return`${v.scheme}://${v.host}${null!=v.port?`:${v.port}`:""}${t}`})();function O(e){const t={path:null,query:null},r=new y(e),n=e.indexOf("?");return null===r.query?t.path=e:(t.path=e.substring(0,n),t.query=P(r.query)),r.fragment&&(t.hash=r.fragment,null===r.query&&(t.path=t.path.substring(0,t.path.length-(r.fragment.length+1)))),t}function P(e){const t=e.split("&"),r={};for(const e of t){if(!e)continue;const t=e.indexOf("=");let n,o;t<0?(n=decodeURIComponent(e),o=""):(n=decodeURIComponent(e.slice(0,t)),o=decodeURIComponent(e.slice(t+1)));let s=r[n];"string"==typeof s&&(s=r[n]=[s]),Array.isArray(s)?s.push(o):r[n]=o}return r}function k(e){return e&&"object"==typeof e&&"toJSON"in e&&"function"==typeof e.toJSON}function S(e,t){return e?t&&"function"==typeof t?Object.keys(e).map((r=>encodeURIComponent(r)+"="+encodeURIComponent(t(r,e[r])))).join("&"):Object.keys(e).map((r=>{const n=e[r];if(null==n)return"";const o=encodeURIComponent(r)+"=",s=t&&t[r];return s?o+encodeURIComponent(s(n)):Array.isArray(n)?n.map((e=>k(e)?o+encodeURIComponent(JSON.stringify(e)):o+encodeURIComponent(e))).join("&"):k(n)?o+encodeURIComponent(JSON.stringify(n)):o+encodeURIComponent(n)})).filter((e=>e)).join("&"):""}function C(e=!1){let t,r=c.proxyUrl;if("string"==typeof e){t=X(e);const n=j(e);n&&(r=n.proxyUrl)}else t=!!e;if(!r)throw a.warn(l),new o.Z("urlutils:proxy-not-set",l);return t&&te()&&(r=ee(r)),O(r)}function E(e){const t=j(e);let r,n;if(t){const e=T(t.proxyUrl);r=e.path,n=e.query?P(e.query):null}if(r){const t=O(e);e=r+"?"+t.path;const o=S({...n,...t.query});o&&(e=`${e}?${o}`)}return e}const x={path:"",query:""};function T(e){const t=e.indexOf("?");return-1!==t?(x.path=e.slice(0,t),x.query=e.slice(t+1)):(x.path=e,x.query=null),x}function A(e){return(e=re(e=function(e){return e&&"/"===e[e.length-1]?e:`${e}/`}(e=T(e).path),!0)).toLowerCase()}function M(e){const t={proxyUrl:e.proxyUrl,urlPrefix:A(e.urlPrefix)},r=c.proxyRules,n=t.urlPrefix;let o=r.length;for(let e=0;e<r.length;e++){const t=r[e].urlPrefix;if(0===n.indexOf(t)){if(n.length===t.length)return-1;o=e;break}0===t.indexOf(n)&&(o=e+1)}return r.splice(o,0,t),o}function j(e){const t=c.proxyRules,r=A(e);for(let e=0;e<t.length;e++)if(0===r.indexOf(t[e].urlPrefix))return t[e]}function $(e,t){return e=I(e),t=I(t),re(e)===re(t)}function I(e){const t=(e=q(e)).indexOf("/sharing");return t>0?e.substring(0,t):e.replace(/\/+$/,"")}function N(e){const t=t=>null==t||t instanceof RegExp&&t.test(e)||"string"==typeof t&&e.startsWith(t),r=c.interceptors;if(r)for(const e of r)if(Array.isArray(e.urls)){if(e.urls.some(t))return e}else if(t(e.urls))return e;return null}function R(e,t,r=!1){const n=ae(e),o=ae(t);return!(!r&&n.scheme!==o.scheme)&&null!=n.host&&null!=o.host&&n.host.toLowerCase()===o.host.toLowerCase()&&n.port===o.port}function W(e){if("string"==typeof e){if(!B(e))return!0;e=ae(e)}if(R(e,v))return!0;const t=c.trustedServers||[];for(let r=0;r<t.length;r++){const n=U(t[r]);for(let t=0;t<n.length;t++)if(R(e,n[t]))return!0}return!1}function U(e){return w[e]||(G(e)||Y(e)?w[e]=[new y(L(e))]:w[e]=[new y(`http://${e}`),new y(`https://${e}`)]),w[e]}function L(e,t=_,r){return Y(e)?r&&r.preserveProtocolRelative?e:"http"===v.scheme&&v.authority===Z(e).slice(2)?`http:${e}`:`https:${e}`:G(e)?e:(0,i.j0)(F("/"===e[0]?function(e){const t=e.indexOf("//"),r=e.indexOf("/",t+2);return-1===r?e:e.slice(0,r)}(t):t,e))}function J(e,t=_,r){if(!B(e))return e;const n=q(e),o=n.toLowerCase(),s=q(t).toLowerCase().replace(/\/+$/,""),i=r?q(r).toLowerCase().replace(/\/+$/,""):null;if(i&&0!==s.indexOf(i))return e;const a=(e,t,r)=>-1===(r=e.indexOf(t,r))?e.length:r;let c=a(o,"/",o.indexOf("//")+2),l=-1;for(;o.slice(0,c+1)===s.slice(0,c)+"/"&&(l=c+1,c!==o.length);)c=a(o,"/",c+1);if(-1===l)return e;if(i&&l<i.length)return e;e=n.slice(l);const u=s.slice(l-1).replace(/[^/]+/g,"").length;if(u>0)for(let t=0;t<u;t++)e=`../${e}`;else e=`./${e}`;return e}function q(e){return function(e){const t=c.httpsDomains;if(!function(e){return f.test(e)||"http"===v.scheme&&Y(e)}(e))return e;const r=e.indexOf("/",7);let n;if(n=-1===r?e:e.slice(0,r),n=n.toLowerCase().slice(7),p.test(n)){if(!n.endsWith(":80"))return e;n=n.slice(0,-3),e=e.replace(":80","")}return"http"===v.scheme&&n===v.authority&&!b.test(e)||(te()&&n===v.authority||t&&t.some((e=>n===e||n.endsWith(`.${e}`)))||te()&&!j(e))&&(e=ee(e)),e}(e=function(e){return e.replace(/^(https?:\/\/)(arcgis\.com)/i,"$1www.$2")}(e=function(e){if(/^https?:\/\//i.test(e)){const t=T(e);e=(e=t.path.replace(/\/{2,}/g,"/")).replace("/","//"),t.query&&(e+=`?${t.query}`)}return e}(e=L(e=e.trim()))))}function F(...e){const t=e.filter(i.pC);if(!t||!t.length)return;const r=[];if(B(t[0])){const e=t[0],n=e.indexOf("//");-1!==n&&(r.push(e.slice(0,n+1)),function(e){return h.test(e)}(t[0])&&(r[0]+="/"),t[0]=e.slice(n+2))}else"/"===t[0][0]&&r.push("");const n=t.reduce(((e,t)=>t?e.concat(t.split("/")):e),[]);for(let e=0;e<n.length;e++){const t=n[e];".."===t&&r.length>0&&".."!==r[r.length-1]?r.pop():(!t&&e===n.length-1||t&&("."!==t||0===r.length))&&r.push(t)}return r.join("/")}function Z(e,t=!1){if(D(e)||H(e))return null;let r=e.indexOf("://");if(-1===r&&Y(e))r=2;else{if(-1===r)return null;r+=3}const n=e.indexOf("/",r);return-1!==n&&(e=e.slice(0,n)),t&&(e=re(e,!0)),e}function B(e){return Y(e)||G(e)}function D(e){return null!=e&&"blob:"===e.slice(0,5)}function H(e){return"data:"===e.slice(0,5)}function K(e){const t=Q(e);if(!t||!t.isBase64)return null;const r=atob(t.data),n=new Uint8Array(r.length);for(let e=0;e<r.length;e++)n[e]=r.charCodeAt(e);return n.buffer}const z=/^data:(.*?)(;base64)?,(.*)$/;function Q(e){const t=e.match(z);if(!t)return null;const[,r,n,o]=t;return{mediaType:r,isBase64:!!n,data:o}}function V(e){return e.isBase64?`data:${e.mediaType};base64,${e.data}`:`data:${e.mediaType},${e.data}`}function Y(e){return null!=e&&void 0!==e&&"/"===e[0]&&"/"===e[1]}function G(e){return u.test(e)}function X(e){return d.test(e)||"https"===v.scheme&&Y(e)}function ee(e){return Y(e)?`https:${e}`:e.replace(f,"https:")}function te(){return"https"===v.scheme}function re(e,t=!1){return Y(e)?e.slice(2):(e=e.replace(u,""),t&&e.length>1&&"/"===e[0]&&"/"===e[1]&&(e=e.slice(2)),e)}function ne(e){let t=0;if(B(e)){const r=e.indexOf("//");-1!==r&&(t=r+2)}const r=e.lastIndexOf("/");return r<t?e:e.slice(0,r+1)}function oe(e,t){if(!e)return"";const r=O(e).path.replace(/\/+$/,""),n=r.substring(r.lastIndexOf("/")+1);if(null==t||!t.length)return n;const o=new RegExp(`.(${t.join("|")})$`,"ig");return n.replace(o,"")}function se(e){return e.replace(/\/+$/,"")}function ie(e,t,r){if(!(t&&r&&e&&B(e)))return e;const n=e.indexOf("//"),o=e.indexOf("/",n+2),s=e.indexOf(":",n+2),i=Math.min(o<0?e.length:o,s<0?e.length:s);return e.slice(n+2,i).toLowerCase()!==t.toLowerCase()?e:`${e.slice(0,n+2)}${r}${e.slice(i)}`}function ae(e){return"string"==typeof e?new y(L(e)):(e.scheme||(e.scheme=v.scheme),e)}function ce(e,t){const r=O(e),n=Object.keys(r.query||{});return n.length>0&&t&&t.warn("removeQueryParameters()",`Url query parameters are not supported, the following parameters have been removed: ${n.join(", ")}.`),r.path}function le(e,t,r){const n=O(e),o=n.query||{};return o[t]=String(r),`${n.path}?${S(o)}`}function ue(e,t){const r=O(e),n=r.query||{};for(const e in t)n[e]=t[e];const o=S(n);return o?`${r.path}?${o}`:r.path}function fe(e){if((0,i.Wi)(e))return null;const t=e.match(de);return t?t[1]:null}const de=/.*?\.([^\/]*)$/},25045:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>y});var n=r(40330),o=r(20102),s=r(91460),i=r(70586),a=r(95330),c=r(94362),l=r(17202);const u={statsWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(6841)]).then(r.bind(r,36841)),geometryEngineWorker:()=>Promise.all([r.e(5837),r.e(8227)]).then(r.bind(r,48227)),CSVSourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(411),r.e(1534),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(966)]).then(r.bind(r,27793)),EdgeProcessingWorker:()=>Promise.all([r.e(6481),r.e(8936)]).then(r.bind(r,18936)),ElevationSamplerWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(411),r.e(2781),r.e(6481),r.e(6459),r.e(3553)]).then(r.bind(r,61787)),FeatureServiceSnappingSourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(4588),r.e(411),r.e(1534),r.e(3485),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(5158)]).then(r.bind(r,41650)),GeoJSONSourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(411),r.e(1534),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(6348),r.e(7845)]).then(r.bind(r,97845)),LercWorker:()=>r.e(3027).then(r.bind(r,23027)),MemorySourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(411),r.e(1534),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(6348),r.e(639)]).then(r.bind(r,30639)),PBFDecoderWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(8961),r.e(147)]).then(r.bind(r,61916)),Pipeline:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(5638),r.e(4588),r.e(411),r.e(1534),r.e(3485),r.e(3578),r.e(8961),r.e(7054),r.e(2730),r.e(3142)]).then(r.bind(r,53142)),PointCloudWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(411),r.e(9294),r.e(9474)]).then(r.bind(r,16583)),RasterWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(411),r.e(7303),r.e(6921),r.e(5340)]).then(r.bind(r,61576)),SceneLayerWorker:()=>r.e(5265).then(r.bind(r,55265)),WFSSourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(411),r.e(1534),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(6348),r.e(4556),r.e(3230)]).then(r.bind(r,43230)),WorkerTileHandler:()=>Promise.all([r.e(2303),r.e(1785),r.e(6810),r.e(9872)]).then(r.bind(r,56456))},{CLOSE:f,ABORT:d,INVOKE:h,RESPONSE:p,OPEN_PORT:b,ON:g}=c.Cs;class m{constructor(e){this._timer=null,this._cancelledJobIds=new Set,this._invokeMessages=[],this._invoke=e,this._timer=null,this._process=this._process.bind(this)}push(e){e.type===c.Cs.ABORT?this._cancelledJobIds.add(e.jobId):(this._invokeMessages.push(e),null===this._timer&&(this._timer=setTimeout(this._process,0)))}clear(){this._invokeMessages.length=0,this._cancelledJobIds.clear(),this._timer=null}_process(){this._timer=null;for(const e of this._invokeMessages)this._cancelledJobIds.has(e.jobId)||this._invoke(e);this._cancelledJobIds.clear(),this._invokeMessages.length=0}}class y{constructor(e,t){this._port=e,this._outJobs=new Map,this._inJobs=new Map,this._invokeQueue=new m((e=>this._onInvokeMessage(e))),this._client=t.client,this._onMessage=this._onMessage.bind(this),this._channel=t.channel,this._schedule=t.schedule,this._port.addEventListener("message",this._onMessage),this._port.start()}static connect(e){const t=new MessageChannel;let r;r="function"==typeof e?new e:"default"in e&&"function"==typeof e.default?new e.default:e;const n=new y(t.port1,{channel:t,client:r});return"object"==typeof r&&"remoteClient"in r&&(r.remoteClient=n),y.clients.set(n,r),t.port2}static loadWorker(e){const t=u[e];return t?t():Promise.resolve(null)}close(){this._post({type:f}),this._close()}isBusy(){return this._outJobs.size>0}invoke(e,t,r){const n=r&&r.signal,s=r&&r.transferList;if(!this._port)return Promise.reject(new o.Z("worker:port-closed",`Cannot call invoke('${e}'), port is closed`,{methodName:e,data:t}));const i=(0,c.jt)();return new Promise(((r,o)=>{const c=(0,a.$F)(n,(()=>{var e;const t=this._outJobs.get(i);t&&(this._outJobs.delete(i),null==(e=t.abortHandle)||e.remove(),this._post({type:d,jobId:i}),o((0,a.zE)()))})),l={resolve:r,reject:o,abortHandle:c,debugInfo:e};this._outJobs.set(i,l),this._post({type:h,jobId:i,methodName:e,abortable:null!=n},t,s)}))}on(e,t){const r=new MessageChannel;function n(e){t(e.data)}return this._port.postMessage({type:c.Cs.ON,eventType:e,port:r.port2},[r.port2]),r.port1.addEventListener("message",n),r.port1.start(),{remove(){r.port1.postMessage({type:c.Cs.CLOSE}),r.port1.close(),r.port1.removeEventListener("message",n)}}}openPort(){const e=new MessageChannel;return this._post({type:b,port:e.port2}),e.port1}_close(){this._channel&&(this._channel=null),this._port.removeEventListener("message",this._onMessage),this._port.close(),this._outJobs.forEach((e=>{var t;null==(t=e.abortHandle)||t.remove(),e.reject((0,a.zE)(`Worker closing, aborting job calling '${e.debugInfo}'`))})),this._inJobs.clear(),this._outJobs.clear(),this._invokeQueue.clear(),this._port=this._client=this._schedule=null}_onMessage(e){(0,i.pC)(this._schedule)?this._schedule((()=>this._processMessage(e))):this._processMessage(e)}_processMessage(e){const t=(0,c.QM)(e);if(t)switch(t.type){case p:this._onResponseMessage(t);break;case h:this._invokeQueue.push(t);break;case d:this._onAbortMessage(t);break;case f:this._onCloseMessage();break;case b:this._onOpenPortMessage(t);break;case g:this._onOnMessage(t)}}_onAbortMessage(e){const t=this._inJobs,r=e.jobId,n=t.get(r);this._invokeQueue.push(e),n&&(n.controller&&n.controller.abort(),t.delete(r))}_onCloseMessage(){const e=this._client;this._close(),e&&"destroy"in e&&y.clients.get(this)===e&&e.destroy(),y.clients.delete(this),e&&e.remoteClient&&(e.remoteClient=null)}_onInvokeMessage(e){const{methodName:t,jobId:r,data:n,abortable:o}=e,s=o?new AbortController:null,i=this._inJobs;let l,u=this._client,f=u[t];try{if(!f&&t&&-1!==t.indexOf(".")){const e=t.split(".");for(let t=0;t<e.length-1;t++)u=u[e[t]],f=u[e[t+1]]}if("function"!=typeof f)throw new TypeError(`${t} is not a function`);l=f.call(u,n,{client:this,signal:s?s.signal:null})}catch(e){return void this._post({type:p,jobId:r,error:(0,c.AB)(e)})}(0,a.y8)(l)?(i.set(r,{controller:s,promise:l}),l.then((e=>{i.has(r)&&(i.delete(r),this._post({type:p,jobId:r},e))}),(e=>{i.has(r)&&(i.delete(r),(0,a.D_)(e)||this._post({type:p,jobId:r,error:(0,c.AB)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:p,jobId:r},l)}_onOpenPortMessage(e){new y(e.port,{client:this._client})}_onOnMessage(e){const{port:t}=e,r=this._client.on(e.eventType,(e=>{t.postMessage(e)})),n=(0,s.on)(e.port,"message",(e=>{(0,c.QM)(e).type===c.Cs.CLOSE&&(n.remove(),r.remove(),t.close())}))}_onResponseMessage(e){var t;const{jobId:r,error:n,data:s}=e,i=this._outJobs;if(!i.has(r))return;const a=i.get(r);i.delete(r),null==(t=a.abortHandle)||t.remove(),n?a.reject(o.Z.fromJSON(JSON.parse(n))):a.resolve(s)}_post(e,t,r){return(0,c.oi)(this._port,e,t,r)}}y.kernelInfo={revision:l.$,version:n.i8,buildDate:l.r},y.clients=new Map},94362:(e,t,r)=>{"use strict";r.d(t,{Cs:()=>n,jt:()=>a,oi:()=>l,QM:()=>u,AB:()=>c});var n,o,s=r(80442);(o=n||(n={}))[o.HANDSHAKE=0]="HANDSHAKE",o[o.OPEN=1]="OPEN",o[o.OPENED=2]="OPENED",o[o.RESPONSE=3]="RESPONSE",o[o.INVOKE=4]="INVOKE",o[o.ABORT=5]="ABORT",o[o.CLOSE=6]="CLOSE",o[o.OPEN_PORT=7]="OPEN_PORT",o[o.ON=8]="ON";let i=0;function a(){return i++}function c(e){return e?"string"==typeof e?JSON.stringify({name:"message",message:e}):e.toJSON?JSON.stringify(e):JSON.stringify({name:e.name,message:e.message,details:e.details||{stack:e.stack}}):null}function l(e,t,r,o){if(t.type===n.OPEN_PORT)return void e.postMessage(t,[t.port]);if(t.type!==n.INVOKE&&t.type!==n.RESPONSE)return void e.postMessage(t);let s;!function(e){return e&&"object"==typeof e&&("result"in e||"transferList"in e)}(r)?(s=f(o),t.data=r):(s=f(r.transferList),t.data=r.result),s?e.postMessage(t,s):e.postMessage(t)}function u(e){if(!e)return null;const t=e.data;return t?"string"==typeof t?JSON.parse(t):t:null}function f(e){if(!e||!e.length)return null;if((0,s.Z)("esri-workers-arraybuffer-transfer"))return e;const t=e.filter((e=>!function(e){return e instanceof ArrayBuffer||e&&e.constructor&&"ArrayBuffer"===e.constructor.name}(e)));return t.length?t:null}},40330:(e,t,r)=>{"use strict";r.d(t,{Dp:()=>l,id:()=>a,qh:()=>c,i8:()=>s,Nv:()=>i});var n=r(80442),o=r(17452);const s="4.22",i={async request(e,t){var n;const{default:s}=await r.e(3172).then(r.bind(r,3172)),i=e.options,a=i.responseType;i.signal=null==t?void 0:t.signal,i.responseType="native"===a||"native-request-init"===a?"native-request-init":["blob","json","text"].includes(a)&&null!=(n=(0,o.oh)(e.url))&&n.after?a:"array-buffer";const c=await s(e.url,i),l={data:c.data,ssl:c.ssl};switch(c.requestOptions.responseType){case"native-request-init":return delete l.data.signal,l;case"blob":l.data=await l.data.arrayBuffer();break;case"json":l.data=(new TextEncoder).encode(JSON.stringify(l.data)).buffer;break;case"text":l.data=(new TextEncoder).encode(l.data).buffer}return{result:l,transferList:[l.data]}}};let a;function c(e){a=e}function l(e){const t=a&&a.findCredential(e);return t&&t.token?(0,o.ZN)(e,"token",t.token):e}(0,n.Z)("host-webworker")||((0,n.Z)("edge")||(0,n.Z)("trident"))&&console.warn("Deprecated browser - see http://esriurl.com/oldbrowser")},17202:(e,t,r)=>{"use strict";r.d(t,{r:()=>n,$:()=>o});const n="20211129",o="ba06b8b5ebc99d6132636970c6c4cedc522d0418"}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var s=t[n]={exports:{}};return e[n](s,s.exports,r),s.exports}r.m=e,r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.f={},r.e=e=>Promise.all(Object.keys(r.f).reduce(((t,n)=>(r.f[n](e,t),t)),[])),r.u=e=>"chunks/"+{24:"db5bae10b28d7908a154",36:"457dd64964cf7f404943",102:"dc972cefa5a0e9a679a2",147:"472df5b8be9c335eb999",223:"59640d78295e2e363f18",247:"a0450fbf01de854f5c97",280:"ea05f870dda27bca4fe8",402:"09fdc334ba4096a225ba",411:"8f4714cdd325b8e28957",511:"dd8c983c153c65ebceca",565:"d53ad780789f4d9124ad",576:"38e792e037e88a74995a",635:"12576e848e14cc1fbb70",639:"b935d0c8d5951298cc53",755:"7e0b4f9a847bb2a52338",819:"6280c69d87b2a3a18780",941:"0632f22aa1af88a238ce",966:"e9af7a5eb1e3bce4f0f9",1074:"2d9b32e3e24631cd4e34",1295:"a164ca7d87bfae334347",1387:"a3a55bd894e1eb739733",1421:"7fa2d758a24bbaaab0bf",1433:"1def8845714ea745fd24",1534:"09141e5539e652edfc6c",1762:"9375938d2d708f1b0271",1765:"e6b41012ade9bdce3244",1773:"aa57f2c380132c746730",1785:"8cf9f06a7efee8eabdd1",2134:"f3c0d0d182988a8d2b3f",2303:"3c4d68029ee2787f9653",2360:"90a5a3e4b38f1f466955",2399:"96f148a556a2418038de",2515:"446f1bc9822d03aa9a7a",2730:"594029863881481feacf",2781:"1de80cd934983f4adfcd",2785:"4fdf762d805ebb17624d",3027:"f30bb46f14bf3e658711",3081:"746d36d268a234680ef7",3142:"f4a6865f9fd613c789cb",3172:"fe3ca2d2764525a8c67f",3230:"7351fbd8a9dbef027d06",3437:"7495218a8fa025c0c133",3471:"36c4bc3d84e9c3148776",3485:"c2268a36f90a9310feec",3516:"82bb1efd0941a08e7756",3529:"1229554d2f1fae96edda",3553:"a0aa8321b58109c6ae19",3578:"e39316a7998d3dde62bf",3668:"ab1aa39457f9205c9b79",3749:"701688ccf7a6c93c9147",3792:"c80c8aff0d14dd822454",3852:"62c683f44c297d239ab8",3942:"d7f77fe32bb2d69b5714",4067:"f9958a82ce78676e56eb",4166:"8a5e15bb513c65ef730d",4358:"f977977564b2b75332a9",4369:"cb5c42f598064c0c4eaa",4470:"4dca43553ef2090e4b5f",4499:"4d325ff7180a253d08c7",4556:"a465488578b87d63215d",4588:"e14b4af7eefcbc2c46a0",4599:"49bb222ee07a768e998d",4695:"14bef72154b3a19561a7",4720:"fe42716651b39518453c",4816:"d76aa27b92563db8f366",4859:"f7a8197264cbc51eac1d",4889:"0ca1ce6856620fc88011",5051:"ac9163e7b4d544b9aa78",5158:"af6251cc7973b43a1523",5265:"3131d0ebc834e33754e1",5340:"27b9aab0315a3dc7f5e4",5638:"ae7b979ce886b03937cc",5732:"469ba1b24cdeea0758ec",5823:"ddc4adb9b9997fb09b43",5837:"42c67e6579b54844ec06",5845:"3e43df5bd4cba6b0e91f",5853:"66f8544b54fab04b36e9",6104:"1120c94a972c7dbf12d8",6237:"c544df83e86a9d36b68c",6348:"1f02165e7758645b5e0d",6401:"06c34599afdb1fe03cbc",6459:"d8d182c41e8bb70db4c2",6481:"e3aed0a5b64180bdb6c3",6550:"dffef67a6e45e430afa3",6570:"55d707784090d738bb26",6619:"86245d83dd17ebe39b2a",6690:"1d8a6ab5feb97d6ca846",6710:"d11d1d294ccc4ccdf60f",6740:"7eca3800807b2cd3fda0",6748:"0a225c0b6a82779de4dd",6774:"4a830f056c4d0ed93928",6810:"bd29ea967877fc6d7c53",6841:"597f8ce30413c6e86f7c",6884:"ad204548895f22823b98",6921:"64646de7e991f3076f60",6968:"66f06faae46eb8ea1b00",7039:"30d7685fc6dc1787df44",7049:"9453fdba689296828087",7054:"89010776ebdfe8a50a0c",7055:"be1ca1154ec28d186311",7091:"63e08d2c2e9098a14ea8",7277:"f183da283af0836421ab",7284:"3414dd7ed9fadd64eb65",7303:"cb070e62a8ac85509384",7319:"3e7a0a81a1f07bce3b30",7392:"7b8f67fe55892fbfb17d",7572:"fdcdc3a5ace2eee31468",7635:"599c9acfd08aaa88ef74",7668:"4513689048bc2a704bf4",7779:"863fe8818f19f82d4d36",7845:"db075f5e0827991efcfd",7873:"93eb468381bfcf0e47d7",8008:"0a3c38ce907eb1ff6e4d",8014:"ec0be96baf84a833cb38",8062:"e9e01881e762aa389401",8121:"3a32fc4f43d87fe84fcb",8216:"fcde45f86962b11353a6",8227:"1f394b20410fddb30a96",8316:"f98f64bbcb1b24d0d290",8422:"56c34f60fdc752ca8371",8511:"bd7a0b91157250f93aa3",8589:"02ce52ca0084536bc066",8625:"caa5d1b9680a822f2070",8659:"47dab63e1b2e64a96637",8683:"7becae4fffb0090a380c",8758:"826c983100569586b61f",8778:"b957ef59aa56b5c339f4",8828:"36de1a1959f038a61cca",8835:"ff9a9e705237c55f78ff",8846:"dadf9930c296c88c3a88",8936:"7802deb733e6a2d2f369",8961:"9796d54ff12b6429164a",9070:"db202ae7dc8b584f312f",9101:"35f53c6de66eec0573db",9151:"d42f289a65a98d752e12",9169:"f7ae0344257e6e08469b",9201:"83c18c36d8829d00c280",9221:"ee3c92e7fd23e606a51b",9254:"ccaaefa20dfb940e8cc0",9291:"6e172b435a55bc72baef",9294:"95471140bd6ec868337e",9296:"e9608d8e0ea984aa35a0",9474:"d76ba25485e92bbda0c5",9489:"06a9cdf71330bf9cc774",9490:"7678b37f4f528af762e2",9561:"a0114820691d4dda8a67",9625:"39e48b3510a3c831299e",9664:"5aee3903ee34855d14f2",9767:"9e3fc6ba87fa55c33055",9872:"b245e95708cde2c403de",9884:"356db8b8297282c77291",9928:"5c561d65035d46249fb4",9932:"a00d39545a2db2a66816",9938:"8aa1910de5173c976dac"}[e]+".js",r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e;r.g.importScripts&&(e=r.g.location+"");var t=r.g.document;if(!e&&t&&(t.currentScript&&(e=t.currentScript.src),!e)){var n=t.getElementsByTagName("script");n.length&&(e=n[n.length-1].src)}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),r.p=e})(),(()=>{var e={134:1,102:1};r.f.i=(t,n)=>{e[t]||importScripts(r.p+r.u(t))};var t=self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[],n=t.push.bind(t);t.push=t=>{var[o,s,i]=t;for(var a in s)r.o(s,a)&&(r.m[a]=s[a]);for(i&&i(r);o.length;)e[o.pop()]=1;n(t)}})(),r(88277);var n=r(25045);RemoteClient=n})();
1
+ var RemoteClient;(()=>{var e={88277:(e,t,r)=>{r.p=self.esriConfig.assetsPath+"/esri/core/workers/"},68773:(e,t,r)=>{"use strict";r.d(t,{Z:()=>i}),r(80442);var n,o=r(78286),s=r(17202);const i={apiKey:void 0,applicationUrl:null==(n=globalThis.location)?void 0:n.href,assetsPath:"",fontsUrl:"https://static.arcgis.com/fonts",geometryService:null,geometryServiceUrl:"https://utility.arcgisonline.com/arcgis/rest/services/Geometry/GeometryServer",geoRSSServiceUrl:"https://utility.arcgis.com/sharing/rss",kmlServiceUrl:"https://utility.arcgis.com/sharing/kml",portalUrl:"https://www.arcgis.com",workers:{loaderConfig:{has:{},paths:{},map:{},packages:[]}},request:{httpsDomains:["arcgis.com","arcgisonline.com","esrikr.com","premiumservices.blackbridge.com","esripremium.accuweather.com","gbm.digitalglobe.com","firstlook.digitalglobe.com","msi.digitalglobe.com"],interceptors:[],maxUrlLength:2e3,proxyRules:[],proxyUrl:null,timeout:6e4,trustedServers:[],useIdentity:!0},log:{interceptors:[],level:null}};if(globalThis.esriConfig&&((0,o.RH)(i,globalThis.esriConfig,!0),delete i.has),!i.assetsPath){const e="4.22.0";i.assetsPath=`https://cdn.jsdelivr.net/npm/@arcgis/core@${e}-next.${s.r}/assets`}i.baseUrl&&console.warn("[esri.config]","baseUrl has been replaced by assetsPath"),Object.defineProperty(i,"baseUrl",{set(){console.warn("[esri.config]","baseUrl has been replaced by assetsPath")}}),i.request.corsEnabledServers=[],i.request.corsEnabledServers.push=function(){return console.warn("[esri.config]","request.corsEnabledServers is not supported and will be removed in a future release. See http://esriurl.com/cors8664"),0}},20102:(e,t,r)=>{"use strict";r.d(t,{Z:()=>i});var n=r(22974),o=r(92604),s=r(58896);class i extends s.Z{constructor(e,t,r){if(super(e,t,r),!(this instanceof i))return new i(e,t,r)}toJSON(){if(null!=this.details)try{return{name:this.name,message:this.message,details:JSON.parse(JSON.stringify(this.details,((e,t)=>{if(t&&"object"==typeof t&&"function"==typeof t.toJSON)return t;try{return(0,n.d9)(t)}catch(e){return"[object]"}})))}}catch(e){throw o.Z.getLogger("esri.core.Error").error(e),e}return{name:this.name,message:this.message,details:this.details}}static fromJSON(e){return new i(e.name,e.message,e.details)}}i.prototype.type="error"},92604:(e,t,r)=>{"use strict";r.d(t,{Z:()=>a});var n=r(68773),o=(r(80442),r(70586)),s=r(19153);const i={info:0,warn:1,error:2,none:3};class a{constructor(e){this.level=null,this._module="",this._parent=null,this.writer=null,this._loggedMessages={error:new Map,warn:new Map,info:new Map},null!=e.level&&(this.level=e.level),null!=e.writer&&(this.writer=e.writer),this._module=e.module,a._loggers[this.module]=this;const t=this.module.lastIndexOf(".");-1!==t&&(this._parent=a.getLogger(this.module.slice(0,t)))}get module(){return this._module}get parent(){return this._parent}error(...e){this._log("error","always",...e)}warn(...e){this._log("warn","always",...e)}info(...e){this._log("info","always",...e)}errorOnce(...e){this._log("error","once",...e)}warnOnce(...e){this._log("warn","once",...e)}infoOnce(...e){this._log("info","once",...e)}errorOncePerTick(...e){this._log("error","oncePerTick",...e)}warnOncePerTick(...e){this._log("warn","oncePerTick",...e)}infoOncePerTick(...e){this._log("info","oncePerTick",...e)}get test(){const e=this;return{loggedMessages:e._loggedMessages,clearLoggedWarnings:()=>e._loggedMessages.warn.clear()}}static get testSingleton(){return{resetLoggers(e={}){const t=a._loggers;return a._loggers=e,t},set throttlingDisabled(e){a._throttlingDisabled=e}}}static getLogger(e){let t=a._loggers[e];return t||(t=new a({module:e})),t}_log(e,t,...r){if(this._matchLevel(e)){if("always"!==t&&!a._throttlingDisabled){const n=this._argsToKey(r),o=this._loggedMessages[e].get(n);if("once"===t&&null!=o||"oncePerTick"===t&&o&&o>=a._tickCounter)return;this._loggedMessages[e].set(n,a._tickCounter),a._scheduleTickCounterIncrement()}for(const t of n.Z.log.interceptors)if(t(e,this.module,...r))return;this._inheritedWriter()(e,this.module,...r)}}_parentWithMember(e,t){let r=this;for(;(0,o.pC)(r);){const t=r[e];if((0,o.pC)(t))return t;r=r.parent}return t}_inheritedWriter(){return this._parentWithMember("writer",this._consoleWriter)}_consoleWriter(e,t,...r){console[e](`[${t}]`,...r)}_matchLevel(e){const t=n.Z.log.level?n.Z.log.level:"warn";return i[this._parentWithMember("level",t)]<=i[e]}_argsToKey(...e){return(0,s.hP)(JSON.stringify(e,((e,t)=>"object"!=typeof t||Array.isArray(t)?t:"[Object]")))}static _scheduleTickCounterIncrement(){a._tickCounterScheduled||(a._tickCounterScheduled=!0,Promise.resolve().then((()=>{a._tickCounter++,a._tickCounterScheduled=!1})))}}a._loggers={},a._tickCounter=0,a._tickCounterScheduled=!1,a._throttlingDisabled=!1},58896:(e,t,r)=>{"use strict";r.d(t,{Z:()=>o});var n=r(78286);class o{constructor(e,t,r){this.name=e,this.details=r,this.message=void 0,this instanceof o&&(this.message=t&&function(e,t){return e.replace(/\$\{([^\s\:\}]*)(?:\:([^\s\:\}]+))?\}/g,(function(e,r){if(""===r)return"$";const o=(0,n.hS)(r,t),s=null==o?"":o;if(void 0===s)throw new Error(`could not find key "${r}" in template`);return s.toString()}))}(t,r)||"")}toString(){return"["+this.name+"]: "+this.message}}},77734:(e,t,r)=>{"use strict";r.d(t,{Z:()=>n});class n{constructor(e=1){this._seed=e}set seed(e){this._seed=null==e?Math.random()*n._m:e}getInt(){return this._seed=(n._a*this._seed+n._c)%n._m,this._seed}getFloat(){return this.getInt()/(n._m-1)}getIntRange(e,t){return Math.round(this.getFloatRange(e,t))}getFloatRange(e,t){const r=t-e;return e+this.getInt()/n._m*r}}n._m=2147483647,n._a=48271,n._c=0},67676:(e,t,r)=>{"use strict";r.d(t,{SO:()=>l,a9:()=>a,fS:()=>s,cq:()=>f,w6:()=>c,Od:()=>b,e$:()=>d,FY:()=>p});var n=r(70586),o=r(77734);function s(e,t,r){if((0,n.Wi)(e)&&(0,n.Wi)(t))return!0;if((0,n.Wi)(e)||(0,n.Wi)(t)||e.length!==t.length)return!1;if(r){for(let n=0;n<e.length;n++)if(!r(e[n],t[n]))return!1}else for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}const i=!!Array.prototype.fill;function a(e,t){if(i)return new Array(e).fill(t);const r=new Array(e);for(let n=0;n<e;n++)r[n]=t;return r}function c(e,t){void 0===t&&(t=e,e=0);const r=new Array(t-e);for(let n=e;n<t;n++)r[n-e]=n;return r}class l{constructor(){this.last=0}}const u=new l;function f(e,t,r,n){n=n||u;const o=Math.max(0,n.last-10);for(let s=o;s<r;++s)if(e[s]===t)return n.last=s,s;const s=Math.min(o,r);for(let r=0;r<s;++r)if(e[r]===t)return n.last=r,r;return-1}function d(e,t,r,n){const o=null==r?e.length:r,s=f(e,t,o,n);if(-1!==s)return e[s]=e[o-1],null==r&&e.pop(),t}const h=new Set;function p(e,t,r=e.length,n=t.length,o,s){if(0===n||0===r)return r;h.clear();for(let e=0;e<n;++e)h.add(t[e]);o=o||u;const i=Math.max(0,o.last-10);for(let t=i;t<r;++t)if(h.has(e[t])&&(s&&s.push(e[t]),h.delete(e[t]),e[t]=e[r-1],--r,--t,0===h.size||0===r))return h.clear(),r;for(let t=0;t<i;++t)if(h.has(e[t])&&(s&&s.push(e[t]),h.delete(e[t]),e[t]=e[r-1],--r,--t,0===h.size||0===r))return h.clear(),r;return h.clear(),r}function b(e,t){const r=e.indexOf(t);return-1!==r?(e.splice(r,1),t):null}new o.Z},91460:(e,t,r)=>{"use strict";function n(e){return e&&("function"==typeof e.on||"function"==typeof e.addEventListener)}function o(e,t,r){if(!n(e))throw new TypeError("target is not a Evented or EventTarget object");if("on"in e)return e.on(t,r);if(Array.isArray(t)){const n=t.slice();for(const t of n)e.addEventListener(t,r);return{remove(){for(const t of n)e.removeEventListener(t,r)}}}return e.addEventListener(t,r),{remove(){e.removeEventListener(t,r)}}}function s(e,t,r){if(!n(e))throw new TypeError("target is not a Evented or EventTarget object");if("once"in e)return e.once(t,r);const s=o(e,t,(t=>{s.remove(),r.call(e,t)}));return{remove(){s.remove()}}}r.d(t,{vT:()=>n,on:()=>o,IH:()=>s})},80442:(e,t,r)=>{"use strict";var n,o;let s;var i,a;function c(e){return"function"==typeof s[e]?s[e]=s[e](globalThis):s[e]}r.d(t,{Z:()=>c}),s=null!=(n=globalThis.dojoConfig)&&n.has||null!=(o=globalThis.esriConfig)&&o.has?{...null==(i=globalThis.dojoConfig)?void 0:i.has,...null==(a=globalThis.esriConfig)?void 0:a.has}:{},c.add=(e,t,r,n)=>((n||void 0===s[e])&&(s[e]=t),r&&c(e)),c.cache=s,c.add("esri-deprecation-warnings",!0),(()=>{var e;c.add("host-webworker",void 0!==globalThis.WorkerGlobalScope&&self instanceof globalThis.WorkerGlobalScope);const t="undefined"!=typeof window&&"undefined"!=typeof location&&"undefined"!=typeof document&&window.location===location&&window.document===document;if(c.add("host-browser",t),c.add("host-node","object"==typeof globalThis.process&&(null==(e=globalThis.process.versions)?void 0:e.node)&&globalThis.process.versions.v8),c.add("dom",t),c("host-browser")){const e=navigator,t=e.userAgent,r=e.appVersion,n=parseFloat(r);if(c.add("wp",parseFloat(t.split("Windows Phone")[1])||void 0),c.add("msapp",parseFloat(t.split("MSAppHost/")[1])||void 0),c.add("khtml",r.includes("Konqueror")?n:void 0),c.add("edge",parseFloat(t.split("Edge/")[1])||void 0),c.add("opr",parseFloat(t.split("OPR/")[1])||void 0),c.add("webkit",!c("wp")&&!c("edge")&&parseFloat(t.split("WebKit/")[1])||void 0),c.add("chrome",!c("edge")&&!c("opr")&&parseFloat(t.split("Chrome/")[1])||void 0),c.add("android",!c("wp")&&parseFloat(t.split("Android ")[1])||void 0),c.add("safari",!r.includes("Safari")||c("wp")||c("chrome")||c("android")||c("edge")||c("opr")?void 0:parseFloat(r.split("Version/")[1])),c.add("mac",r.includes("Macintosh")),!c("wp")&&t.match(/(iPhone|iPod|iPad)/)){const e=RegExp.$1.replace(/P/,"p"),r=t.match(/OS ([\d_]+)/)?RegExp.$1:"1",n=parseFloat(r.replace(/_/,".").replace(/_/g,""));c.add(e,n),c.add("ios",n)}c.add("trident",parseFloat(r.split("Trident/")[1])||void 0),c("webkit")||(!t.includes("Gecko")||c("wp")||c("khtml")||c("trident")||c("edge")||c.add("mozilla",n),c("mozilla")&&c.add("ff",parseFloat(t.split("Firefox/")[1]||t.split("Minefield/")[1])||void 0))}})(),(()=>{if(globalThis.navigator){const e=navigator.userAgent,t=/Android|webOS|iPhone|iPad|iPod|BlackBerry|Opera Mini|IEMobile/i.test(e),r=/iPhone/i.test(e);t&&c.add("esri-mobile",t),r&&c.add("esri-iPhone",r),c.add("esri-geolocation",!!navigator.geolocation)}c.add("esri-canvas-svg-support",!c("trident")),c.add("esri-wasm","WebAssembly"in globalThis),c.add("esri-shared-array-buffer",(()=>{const e="SharedArrayBuffer"in globalThis,t=!1===globalThis.crossOriginIsolated;return e&&!t})),c.add("esri-atomics","Atomics"in globalThis),c.add("esri-workers","Worker"in globalThis),c.add("esri-text-decoder","TextDecoder"in globalThis),c.add("esri-text-encoder","TextEncoder"in globalThis),c.add("web-feat:cache","caches"in globalThis),c.add("esri-workers-arraybuffer-transfer",!c("safari")||Number(c("safari"))>=12),c.add("featurelayer-simplify-thresholds",[.5,.5,.5,.5]),c.add("featurelayer-simplify-payload-size-factors",[1,1,4]),c.add("featurelayer-snapshot-enabled",!0),c.add("featurelayer-snapshot-point-min-threshold",8e4),c.add("featurelayer-snapshot-point-max-threshold",4e5),c.add("featurelayer-snapshot-point-coverage",.1),c.add("featurelayer-advanced-symbols",!1),c.add("featurelayer-pbf",!0),c.add("featurelayer-pbf-statistics",!1),c.add("feature-layers-workers",!0),c.add("mapview-transitions-duration",200),c.add("mapserver-pbf-enabled",!1),c.add("vectortilelayer-max-buffers",c("ff")?160:Number.POSITIVE_INFINITY),c("host-webworker")||c("host-browser")&&(c.add("esri-csp-restrictions",(()=>{try{new Function}catch{return!0}return!1})),c.add("esri-image-decode",(()=>{if("decode"in new Image){const e=new Image;return e.src='data:image/svg+xml;charset=UTF-8,<svg version="1.1" xmlns="http://www.w3.org/2000/svg"></svg>',void e.decode().then((()=>{c.add("esri-image-decode",!0,!0,!0)})).catch((()=>{c.add("esri-image-decode",!1,!0,!0)}))}return!1})),c.add("esri-url-encodes-apostrophe",(()=>{const e=window.document.createElement("a");return e.href="?'",e.href.includes("?%27")})))})()},22974:(e,t,r)=>{"use strict";r.d(t,{d9:()=>s,fS:()=>i,yd:()=>o}),r(67676),r(80442);var n=r(1533);function o(e,t){let r;if(t)for(r in e)e.hasOwnProperty(r)&&(void 0===e[r]?delete e[r]:e[r]instanceof Object&&o(e[r],!0));else for(r in e)e.hasOwnProperty(r)&&void 0===e[r]&&delete e[r];return e}function s(e){if(!e||"object"!=typeof e||"function"==typeof e)return e;if((0,n.W0)(e)||(0,n.lq)(e)||(0,n.KZ)(e)||(0,n.z3)(e)||(0,n.Uc)(e)||(0,n.Hx)(e)||(0,n.ZY)(e)||(0,n.xZ)(e)||(0,n.fS)(e))return(0,n.tP)(e);if(e instanceof Date)return new Date(e.getTime());if(e instanceof ArrayBuffer)return e.slice(0,e.byteLength);if(e instanceof Map){const t=new Map;return e.forEach(((e,r)=>{t.set(r,s(e))})),t}if(e instanceof Set){const t=new Set;return e.forEach((e=>{t.add(s(e))})),t}let t;const r=e;if("function"==typeof r.clone)t=r.clone();else if("function"==typeof r.map&&"function"==typeof r.forEach)t=r.map(s);else if("function"==typeof r.notifyChange&&"function"==typeof r.watch)t=r.clone();else{t={};for(const r of Object.getOwnPropertyNames(e))t[r]=s(e[r])}return t}function i(e,t){return e===t||"number"==typeof e&&isNaN(e)&&"number"==typeof t&&isNaN(t)||"function"==typeof(e||{}).getTime&&"function"==typeof(t||{}).getTime&&e.getTime()===t.getTime()||!1}},70586:(e,t,r)=>{"use strict";function n(e){return null!=e}function o(e){return null==e}function s(e){return void 0===e}function i(e,t){return n(e)?t(e):null}function a(e){return e}function c(e,t){if(o(e))throw new Error(t);return e}function l(e,t){return n(e)?e:"function"==typeof t?t():t}function u(e){return n(e)&&e.destroy(),null}function f(e){return n(e)&&e.dispose(),null}function d(e){return n(e)&&e.remove(),null}function h(e){return n(e)&&e.release(),null}function p(e){return null}function b(e,t){const r=new Array;for(const n of e)r.push(m(n,null,t));return r}function g(e,t){for(const r of e)m(r,null,t)}function m(e,t,r){return n(e)?r(e):t}function y(e,t){return n(e)?t(e):null}function v(e){return e.filter((e=>n(e)))}function w(e,...t){let r=e;for(let e=0;e<t.length&&r;++e)r=r[t[e]];return r}function _(e){return e}r.d(t,{Po:()=>y,yw:()=>i,j0:()=>_,SC:()=>u,O3:()=>f,lV:()=>v,JR:()=>g,U2:()=>w,Wi:()=>o,pC:()=>n,o8:()=>s,Fd:()=>b,R2:()=>m,Bd:()=>p,RY:()=>h,hw:()=>d,Wg:()=>a,Pt:()=>l,s3:()=>c})},78286:(e,t,r)=>{"use strict";r.d(t,{RH:()=>o,hS:()=>s,RB:()=>i});var n=r(22974);function o(e,t,r=!1){return c(e,t,r)}function s(e,t){if(null!=t)return t[e]||a(e.split("."),!1,t)}function i(e,t,r){const n=e.split("."),o=n.pop(),s=a(n,!0,r);s&&o&&(s[o]=t)}function a(e,t,r){let n=r;for(const r of e){if(null==n)return;if(!(r in n)){if(!t)return;n[r]={}}n=n[r]}return n}function c(e,t,r){return t?Object.keys(t).reduce((function(e,o){let s=e[o],i=t[o];return s===i?e:void 0===s?(e[o]=(0,n.d9)(i),e):(Array.isArray(i)||Array.isArray(e)?(s=s?Array.isArray(s)?e[o]=s.concat():e[o]=[s]:e[o]=[],i&&(Array.isArray(i)||(i=[i]),r?i.forEach((e=>{-1===s.indexOf(e)&&s.push(e)})):e[o]=i.concat())):i&&"object"==typeof i?e[o]=c(s,i,r):e.hasOwnProperty(o)&&!t.hasOwnProperty(o)||(e[o]=i),e)}),e||{}):e}},95330:(e,t,r)=>{"use strict";r.d(t,{e4:()=>C,$6:()=>c,Ue:()=>l,zE:()=>u,dD:()=>_,hh:()=>M,vr:()=>j,Ds:()=>A,as:()=>O,WW:()=>P,R8:()=>w,D_:()=>v,Hc:()=>h,tI:()=>T,y8:()=>E,fu:()=>g,$F:()=>m,d1:()=>k,DB:()=>S,r9:()=>p,k_:()=>f,H9:()=>b,Yn:()=>$,gx:()=>x,Hl:()=>y});const n=(o=globalThis,{setTimeout:(e,t)=>{const r=o.setTimeout(e,t);return{remove:()=>o.clearTimeout(r)}}});var o,s=r(20102),i=r(91460),a=(r(92604),r(70586));function c(e){return Promise.all(e)}function l(e){return new Promise(((t,r)=>{try{e(t,r)}catch(e){Promise.resolve().then((()=>r(e)))}}))}function u(e="Aborted"){return new s.Z("AbortError",e)}function f(e,t="Aborted"){if(h(e))throw u(t)}function d(e){return(0,a.pC)(e)?"aborted"in e?e:e.signal:e}function h(e){const t=d(e);return(0,a.pC)(t)&&t.aborted}function p(e){if(v(e))throw e}function b(e){if(!v(e))throw e}function g(e,t){const r=d(e);if(!(0,a.Wi)(r)){if(!r.aborted)return(0,i.IH)(r,"abort",(()=>t()));t()}}function m(e,t){const r=d(e);if(!(0,a.Wi)(r))return f(r),(0,i.IH)(r,"abort",(()=>t(u())))}function y(e,t){const r=d(t);return(0,a.Wi)(r)?e:new Promise(((r,n)=>{let o=g(t,(()=>n(u())));const s=()=>o=(0,a.hw)(o);e.then(s,s),e.then(r,n)}))}function v(e){return e&&"AbortError"===e.name}function w(e){return e.catch((e=>{if(!v(e))throw e}))}function _(){let e=null;const t=new Promise(((t,r)=>{e={promise:void 0,resolve:t,reject:r}}));return e.promise=t,e}function O(e){if(!e)return;if("function"!=typeof e.forEach){const t=Object.keys(e);return O(t.map((t=>e[t]))).then((e=>{const r={};return t.forEach(((t,n)=>r[t]=e[n])),r}))}const t=e;return l((e=>{const r=[];let n=t.length;0===n&&e(r),t.forEach((t=>{const o={promise:t||Promise.resolve(t)};r.push(o),o.promise.then((e=>{o.value=e})).catch((e=>{o.error=e})).then((()=>{--n,0===n&&e(r)}))}))}))}function P(e){return O(e).then((e=>e.filter((e=>!!e.value)).map((e=>e.value))))}function k(e){return Promise.reject(e)}function S(e){return Promise.resolve(e)}function C(e,t,r){const n=new AbortController;return g(r,(()=>n.abort())),new Promise(((r,o)=>{let s=setTimeout((()=>{s=0,r(t)}),e);g(n,(()=>{s&&(clearTimeout(s),o(u()))}))}))}function E(e){return e&&"function"==typeof e.then}function x(e){return T(e)?e:Promise.resolve(e)}function T(e){return e&&"object"==typeof e&&"then"in e&&"function"==typeof e.then}function A(e,t=-1){let r,n,o,s,i=null;const c=(...l)=>{if(r){n=l,s&&s.reject(u()),s=_();const e=(0,a.j0)(s.promise);if(i){const e=i;i=null,e.abort()}return e}if(o=s||_(),s=null,t>0){const n=new AbortController;r=x(e(...l,n.signal));const o=r;C(t).then((()=>{r===o&&(s?n.abort():i=n)}))}else r=1,r=x(e(...l));const f=()=>{const e=n;n=o=r=i=null,null!=e&&c(...e)},d=r,h=o;return d.then(f,f),d.then(h.resolve,h.reject),(0,a.j0)(h.promise)};return c}function M(){let e,t;const r=new Promise(((r,n)=>{e=r,t=n})),o=t=>{e(t)};return o.resolve=t=>e(t),o.reject=e=>t(e),o.timeout=(e,t)=>n.setTimeout((()=>o.reject(t)),e),o.promise=r,o}function j(e,t){let r,n=new AbortController;const o=e(n.signal);let s={promise:o,finished:!1,abort:()=>{n&&(n.abort(),n=null)}};const i=()=>{s&&(s.finished=!0,s=null),(0,a.pC)(r)&&(r.remove(),r=null),n=null};return o.then(i,i),r=g(t,(()=>{(0,a.pC)(s)&&s.abort()})),s}function $(e){return Promise.resolve().then((()=>{f(e)}))}},19153:(e,t,r)=>{"use strict";r.d(t,{Qs:()=>a,hP:()=>c,gx:()=>i,Cb:()=>l});var n=r(78286);const o=/\{([^\}]+)\}/g;function s(e){return null==e?"":e}function i(e,t){return e.replace(o,"object"==typeof t?(e,r)=>s((0,n.hS)(r,t)):(e,r)=>s(t(r)))}function a(e,t){return e.replace(/([\.$?*|{}\(\)\[\]\\\/\+\-^])/g,(e=>t&&-1!==t.indexOf(e)?e:`\\${e}`))}function c(e){let t=0;for(let r=0;r<e.length;r++)t=(t<<5)-t+e.charCodeAt(r),t|=0;return t}function l(e){return(new DOMParser).parseFromString(e||"","text/html").body.innerText||""}},1533:(e,t,r)=>{"use strict";function n(e,t){if(e.forEach)e.forEach(t);else for(let r=0;r<e.length;r++)t(e[r],r,e)}function o(e,t,r){if(e.slice)return e.slice(t,r);void 0===t?t=0:(t<0&&(t+=e.length),t=Math.min(e.length,Math.max(0,t))),void 0===r?r=e.length:(r<0&&(r+=e.length),r=Math.min(e.length,Math.max(0,r)));const n=Math.max(0,r-t),o=new(0,e.constructor)(n);for(let r=0;r<n;r++)o[r]=e[t+r];return o}function s(e){return e instanceof ArrayBuffer||e&&e.constructor&&"ArrayBuffer"===e.constructor.name}function i(e){return e instanceof Int8Array||e&&e.constructor&&"Int8Array"===e.constructor.name}function a(e){return e instanceof Uint8Array||e&&e.constructor&&"Uint8Array"===e.constructor.name}function c(e){return e instanceof Uint8ClampedArray||e&&e.constructor&&"Uint8ClampedArray"===e.constructor.name}function l(e){return e instanceof Int16Array||e&&e.constructor&&"Int16Array"===e.constructor.name}function u(e){return e instanceof Uint16Array||e&&e.constructor&&"Uint16Array"===e.constructor.name}function f(e){return e instanceof Int32Array||e&&e.constructor&&"Int32Array"===e.constructor.name}function d(e){return e instanceof Uint32Array||e&&e.constructor&&"Uint32Array"===e.constructor.name}function h(e){return e instanceof Float32Array||e&&e.constructor&&"Float32Array"===e.constructor.name}function p(e){return e instanceof Float64Array||e&&e.constructor&&"Float64Array"===e.constructor.name}r.d(t,{Ed:()=>n,eP:()=>s,xZ:()=>h,fS:()=>p,z3:()=>l,Hx:()=>f,W0:()=>i,Uc:()=>u,ZY:()=>d,lq:()=>a,KZ:()=>c,tP:()=>o})},17452:(e,t,r)=>{"use strict";r.d(t,{R9:()=>y,qg:()=>E,tD:()=>M,ZN:()=>le,fl:()=>ue,AX:()=>_,Gd:()=>v,Ie:()=>ie,sJ:()=>Q,AH:()=>K,vt:()=>oe,oh:()=>N,P$:()=>Z,Ml:()=>fe,ed:()=>j,b7:()=>C,D6:()=>R,tm:()=>$,YP:()=>B,jc:()=>D,HK:()=>H,$U:()=>X,oC:()=>Y,kl:()=>W,v_:()=>F,hF:()=>L,_l:()=>V,PF:()=>J,Fv:()=>q,B7:()=>S,u0:()=>P,Yd:()=>ne,Hu:()=>ce,Qj:()=>se,hO:()=>ee,mN:()=>O});var n=r(68773),o=r(20102),s=r(92604),i=r(70586);const a=s.Z.getLogger("esri.core.urlUtils"),c=n.Z.request,l="esri/config: esriConfig.request.proxyUrl is not set.",u=/^\s*[a-z][a-z0-9-+.]*:(?![0-9])/i,f=/^\s*http:/i,d=/^\s*https:/i,h=/^\s*file:/i,p=/:\d+$/,b=/^https?:\/\/[^/]+\.arcgis.com\/sharing(\/|$)/i,g=new RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$"),m=new RegExp("^((([^\\[:]+):)?([^@]+)@)?(\\[([^\\]]+)\\]|([^\\[:]*))(:([0-9]+))?$");class y{constructor(e=""){this.uri=e,this.scheme=null,this.authority=null,this.path=null,this.query=null,this.fragment=null,this.user=null,this.password=null,this.host=null,this.port=null;let t=(0,i.j0)(this.uri.match(g));this.scheme=t[2]||(t[1]?"":null),this.authority=t[4]||(t[3]?"":null),this.path=t[5],this.query=t[7]||(t[6]?"":null),this.fragment=t[9]||(t[8]?"":null),null!=this.authority&&(t=(0,i.j0)(this.authority.match(m)),this.user=t[3]||null,this.password=t[4]||null,this.host=t[6]||t[7],this.port=t[9]||null)}toString(){return this.uri}}const v=new y(n.Z.applicationUrl),w={},_=(()=>{const e=(0,i.j0)(v.path),t=e.substring(0,e.lastIndexOf(e.split("/")[e.split("/").length-1]));return`${v.scheme}://${v.host}${null!=v.port?`:${v.port}`:""}${t}`})();function O(e){const t={path:null,query:null},r=new y(e),n=e.indexOf("?");return null===r.query?t.path=e:(t.path=e.substring(0,n),t.query=P(r.query)),r.fragment&&(t.hash=r.fragment,null===r.query&&(t.path=t.path.substring(0,t.path.length-(r.fragment.length+1)))),t}function P(e){const t=e.split("&"),r={};for(const e of t){if(!e)continue;const t=e.indexOf("=");let n,o;t<0?(n=decodeURIComponent(e),o=""):(n=decodeURIComponent(e.slice(0,t)),o=decodeURIComponent(e.slice(t+1)));let s=r[n];"string"==typeof s&&(s=r[n]=[s]),Array.isArray(s)?s.push(o):r[n]=o}return r}function k(e){return e&&"object"==typeof e&&"toJSON"in e&&"function"==typeof e.toJSON}function S(e,t){return e?t&&"function"==typeof t?Object.keys(e).map((r=>encodeURIComponent(r)+"="+encodeURIComponent(t(r,e[r])))).join("&"):Object.keys(e).map((r=>{const n=e[r];if(null==n)return"";const o=encodeURIComponent(r)+"=",s=t&&t[r];return s?o+encodeURIComponent(s(n)):Array.isArray(n)?n.map((e=>k(e)?o+encodeURIComponent(JSON.stringify(e)):o+encodeURIComponent(e))).join("&"):k(n)?o+encodeURIComponent(JSON.stringify(n)):o+encodeURIComponent(n)})).filter((e=>e)).join("&"):""}function C(e=!1){let t,r=c.proxyUrl;if("string"==typeof e){t=X(e);const n=j(e);n&&(r=n.proxyUrl)}else t=!!e;if(!r)throw a.warn(l),new o.Z("urlutils:proxy-not-set",l);return t&&te()&&(r=ee(r)),O(r)}function E(e){const t=j(e);let r,n;if(t){const e=T(t.proxyUrl);r=e.path,n=e.query?P(e.query):null}if(r){const t=O(e);e=r+"?"+t.path;const o=S({...n,...t.query});o&&(e=`${e}?${o}`)}return e}const x={path:"",query:""};function T(e){const t=e.indexOf("?");return-1!==t?(x.path=e.slice(0,t),x.query=e.slice(t+1)):(x.path=e,x.query=null),x}function A(e){return(e=re(e=function(e){return e&&"/"===e[e.length-1]?e:`${e}/`}(e=T(e).path),!0)).toLowerCase()}function M(e){const t={proxyUrl:e.proxyUrl,urlPrefix:A(e.urlPrefix)},r=c.proxyRules,n=t.urlPrefix;let o=r.length;for(let e=0;e<r.length;e++){const t=r[e].urlPrefix;if(0===n.indexOf(t)){if(n.length===t.length)return-1;o=e;break}0===t.indexOf(n)&&(o=e+1)}return r.splice(o,0,t),o}function j(e){const t=c.proxyRules,r=A(e);for(let e=0;e<t.length;e++)if(0===r.indexOf(t[e].urlPrefix))return t[e]}function $(e,t){return e=I(e),t=I(t),re(e)===re(t)}function I(e){const t=(e=q(e)).indexOf("/sharing");return t>0?e.substring(0,t):e.replace(/\/+$/,"")}function N(e){const t=t=>null==t||t instanceof RegExp&&t.test(e)||"string"==typeof t&&e.startsWith(t),r=c.interceptors;if(r)for(const e of r)if(Array.isArray(e.urls)){if(e.urls.some(t))return e}else if(t(e.urls))return e;return null}function R(e,t,r=!1){const n=ae(e),o=ae(t);return!(!r&&n.scheme!==o.scheme)&&null!=n.host&&null!=o.host&&n.host.toLowerCase()===o.host.toLowerCase()&&n.port===o.port}function W(e){if("string"==typeof e){if(!B(e))return!0;e=ae(e)}if(R(e,v))return!0;const t=c.trustedServers||[];for(let r=0;r<t.length;r++){const n=U(t[r]);for(let t=0;t<n.length;t++)if(R(e,n[t]))return!0}return!1}function U(e){return w[e]||(G(e)||Y(e)?w[e]=[new y(L(e))]:w[e]=[new y(`http://${e}`),new y(`https://${e}`)]),w[e]}function L(e,t=_,r){return Y(e)?r&&r.preserveProtocolRelative?e:"http"===v.scheme&&v.authority===Z(e).slice(2)?`http:${e}`:`https:${e}`:G(e)?e:(0,i.j0)(F("/"===e[0]?function(e){const t=e.indexOf("//"),r=e.indexOf("/",t+2);return-1===r?e:e.slice(0,r)}(t):t,e))}function J(e,t=_,r){if(!B(e))return e;const n=q(e),o=n.toLowerCase(),s=q(t).toLowerCase().replace(/\/+$/,""),i=r?q(r).toLowerCase().replace(/\/+$/,""):null;if(i&&0!==s.indexOf(i))return e;const a=(e,t,r)=>-1===(r=e.indexOf(t,r))?e.length:r;let c=a(o,"/",o.indexOf("//")+2),l=-1;for(;o.slice(0,c+1)===s.slice(0,c)+"/"&&(l=c+1,c!==o.length);)c=a(o,"/",c+1);if(-1===l)return e;if(i&&l<i.length)return e;e=n.slice(l);const u=s.slice(l-1).replace(/[^/]+/g,"").length;if(u>0)for(let t=0;t<u;t++)e=`../${e}`;else e=`./${e}`;return e}function q(e){return function(e){const t=c.httpsDomains;if(!function(e){return f.test(e)||"http"===v.scheme&&Y(e)}(e))return e;const r=e.indexOf("/",7);let n;if(n=-1===r?e:e.slice(0,r),n=n.toLowerCase().slice(7),p.test(n)){if(!n.endsWith(":80"))return e;n=n.slice(0,-3),e=e.replace(":80","")}return"http"===v.scheme&&n===v.authority&&!b.test(e)||(te()&&n===v.authority||t&&t.some((e=>n===e||n.endsWith(`.${e}`)))||te()&&!j(e))&&(e=ee(e)),e}(e=function(e){return e.replace(/^(https?:\/\/)(arcgis\.com)/i,"$1www.$2")}(e=function(e){if(/^https?:\/\//i.test(e)){const t=T(e);e=(e=t.path.replace(/\/{2,}/g,"/")).replace("/","//"),t.query&&(e+=`?${t.query}`)}return e}(e=L(e=e.trim()))))}function F(...e){const t=e.filter(i.pC);if(!t||!t.length)return;const r=[];if(B(t[0])){const e=t[0],n=e.indexOf("//");-1!==n&&(r.push(e.slice(0,n+1)),function(e){return h.test(e)}(t[0])&&(r[0]+="/"),t[0]=e.slice(n+2))}else"/"===t[0][0]&&r.push("");const n=t.reduce(((e,t)=>t?e.concat(t.split("/")):e),[]);for(let e=0;e<n.length;e++){const t=n[e];".."===t&&r.length>0&&".."!==r[r.length-1]?r.pop():(!t&&e===n.length-1||t&&("."!==t||0===r.length))&&r.push(t)}return r.join("/")}function Z(e,t=!1){if(D(e)||H(e))return null;let r=e.indexOf("://");if(-1===r&&Y(e))r=2;else{if(-1===r)return null;r+=3}const n=e.indexOf("/",r);return-1!==n&&(e=e.slice(0,n)),t&&(e=re(e,!0)),e}function B(e){return Y(e)||G(e)}function D(e){return null!=e&&"blob:"===e.slice(0,5)}function H(e){return"data:"===e.slice(0,5)}function K(e){const t=Q(e);if(!t||!t.isBase64)return null;const r=atob(t.data),n=new Uint8Array(r.length);for(let e=0;e<r.length;e++)n[e]=r.charCodeAt(e);return n.buffer}const z=/^data:(.*?)(;base64)?,(.*)$/;function Q(e){const t=e.match(z);if(!t)return null;const[,r,n,o]=t;return{mediaType:r,isBase64:!!n,data:o}}function V(e){return e.isBase64?`data:${e.mediaType};base64,${e.data}`:`data:${e.mediaType},${e.data}`}function Y(e){return null!=e&&void 0!==e&&"/"===e[0]&&"/"===e[1]}function G(e){return u.test(e)}function X(e){return d.test(e)||"https"===v.scheme&&Y(e)}function ee(e){return Y(e)?`https:${e}`:e.replace(f,"https:")}function te(){return"https"===v.scheme}function re(e,t=!1){return Y(e)?e.slice(2):(e=e.replace(u,""),t&&e.length>1&&"/"===e[0]&&"/"===e[1]&&(e=e.slice(2)),e)}function ne(e){let t=0;if(B(e)){const r=e.indexOf("//");-1!==r&&(t=r+2)}const r=e.lastIndexOf("/");return r<t?e:e.slice(0,r+1)}function oe(e,t){if(!e)return"";const r=O(e).path.replace(/\/+$/,""),n=r.substring(r.lastIndexOf("/")+1);if(null==t||!t.length)return n;const o=new RegExp(`.(${t.join("|")})$`,"ig");return n.replace(o,"")}function se(e){return e.replace(/\/+$/,"")}function ie(e,t,r){if(!(t&&r&&e&&B(e)))return e;const n=e.indexOf("//"),o=e.indexOf("/",n+2),s=e.indexOf(":",n+2),i=Math.min(o<0?e.length:o,s<0?e.length:s);return e.slice(n+2,i).toLowerCase()!==t.toLowerCase()?e:`${e.slice(0,n+2)}${r}${e.slice(i)}`}function ae(e){return"string"==typeof e?new y(L(e)):(e.scheme||(e.scheme=v.scheme),e)}function ce(e,t){const r=O(e),n=Object.keys(r.query||{});return n.length>0&&t&&t.warn("removeQueryParameters()",`Url query parameters are not supported, the following parameters have been removed: ${n.join(", ")}.`),r.path}function le(e,t,r){const n=O(e),o=n.query||{};return o[t]=String(r),`${n.path}?${S(o)}`}function ue(e,t){const r=O(e),n=r.query||{};for(const e in t)n[e]=t[e];const o=S(n);return o?`${r.path}?${o}`:r.path}function fe(e){if((0,i.Wi)(e))return null;const t=e.match(de);return t?t[1]:null}const de=/.*?\.([^\/]*)$/},25045:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>y});var n=r(40330),o=r(20102),s=r(91460),i=r(70586),a=r(95330),c=r(94362),l=r(17202);const u={statsWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(6841)]).then(r.bind(r,36841)),geometryEngineWorker:()=>Promise.all([r.e(5837),r.e(8227)]).then(r.bind(r,48227)),CSVSourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(411),r.e(1534),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(966)]).then(r.bind(r,27793)),EdgeProcessingWorker:()=>Promise.all([r.e(6481),r.e(8936)]).then(r.bind(r,18936)),ElevationSamplerWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(411),r.e(2781),r.e(6481),r.e(6459),r.e(3553)]).then(r.bind(r,61787)),FeatureServiceSnappingSourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(4588),r.e(411),r.e(1534),r.e(3485),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(5158)]).then(r.bind(r,41650)),GeoJSONSourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(411),r.e(1534),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(6348),r.e(7845)]).then(r.bind(r,97845)),LercWorker:()=>r.e(3027).then(r.bind(r,23027)),MemorySourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(411),r.e(1534),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(6348),r.e(639)]).then(r.bind(r,30639)),PBFDecoderWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(8961),r.e(147)]).then(r.bind(r,61916)),Pipeline:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(5638),r.e(4588),r.e(411),r.e(1534),r.e(3485),r.e(3578),r.e(8961),r.e(7054),r.e(2730),r.e(7783)]).then(r.bind(r,97783)),PointCloudWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(411),r.e(9294),r.e(9474)]).then(r.bind(r,16583)),RasterWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(411),r.e(176),r.e(8034)]).then(r.bind(r,61576)),SceneLayerWorker:()=>r.e(5265).then(r.bind(r,55265)),WFSSourceWorker:()=>Promise.all([r.e(8778),r.e(6570),r.e(8316),r.e(2303),r.e(7668),r.e(411),r.e(1534),r.e(3578),r.e(8961),r.e(7054),r.e(2781),r.e(6348),r.e(4556),r.e(3230)]).then(r.bind(r,43230)),WorkerTileHandler:()=>Promise.all([r.e(2303),r.e(1785),r.e(6810),r.e(9872)]).then(r.bind(r,56456))},{CLOSE:f,ABORT:d,INVOKE:h,RESPONSE:p,OPEN_PORT:b,ON:g}=c.Cs;class m{constructor(e){this._timer=null,this._cancelledJobIds=new Set,this._invokeMessages=[],this._invoke=e,this._timer=null,this._process=this._process.bind(this)}push(e){e.type===c.Cs.ABORT?this._cancelledJobIds.add(e.jobId):(this._invokeMessages.push(e),null===this._timer&&(this._timer=setTimeout(this._process,0)))}clear(){this._invokeMessages.length=0,this._cancelledJobIds.clear(),this._timer=null}_process(){this._timer=null;for(const e of this._invokeMessages)this._cancelledJobIds.has(e.jobId)||this._invoke(e);this._cancelledJobIds.clear(),this._invokeMessages.length=0}}class y{constructor(e,t){this._port=e,this._outJobs=new Map,this._inJobs=new Map,this._invokeQueue=new m((e=>this._onInvokeMessage(e))),this._client=t.client,this._onMessage=this._onMessage.bind(this),this._channel=t.channel,this._schedule=t.schedule,this._port.addEventListener("message",this._onMessage),this._port.start()}static connect(e){const t=new MessageChannel;let r;r="function"==typeof e?new e:"default"in e&&"function"==typeof e.default?new e.default:e;const n=new y(t.port1,{channel:t,client:r});return"object"==typeof r&&"remoteClient"in r&&(r.remoteClient=n),y.clients.set(n,r),t.port2}static loadWorker(e){const t=u[e];return t?t():Promise.resolve(null)}close(){this._post({type:f}),this._close()}isBusy(){return this._outJobs.size>0}invoke(e,t,r){const n=r&&r.signal,s=r&&r.transferList;if(!this._port)return Promise.reject(new o.Z("worker:port-closed",`Cannot call invoke('${e}'), port is closed`,{methodName:e,data:t}));const i=(0,c.jt)();return new Promise(((r,o)=>{const c=(0,a.$F)(n,(()=>{var e;const t=this._outJobs.get(i);t&&(this._outJobs.delete(i),null==(e=t.abortHandle)||e.remove(),this._post({type:d,jobId:i}),o((0,a.zE)()))})),l={resolve:r,reject:o,abortHandle:c,debugInfo:e};this._outJobs.set(i,l),this._post({type:h,jobId:i,methodName:e,abortable:null!=n},t,s)}))}on(e,t){const r=new MessageChannel;function n(e){t(e.data)}return this._port.postMessage({type:c.Cs.ON,eventType:e,port:r.port2},[r.port2]),r.port1.addEventListener("message",n),r.port1.start(),{remove(){r.port1.postMessage({type:c.Cs.CLOSE}),r.port1.close(),r.port1.removeEventListener("message",n)}}}openPort(){const e=new MessageChannel;return this._post({type:b,port:e.port2}),e.port1}_close(){this._channel&&(this._channel=null),this._port.removeEventListener("message",this._onMessage),this._port.close(),this._outJobs.forEach((e=>{var t;null==(t=e.abortHandle)||t.remove(),e.reject((0,a.zE)(`Worker closing, aborting job calling '${e.debugInfo}'`))})),this._inJobs.clear(),this._outJobs.clear(),this._invokeQueue.clear(),this._port=this._client=this._schedule=null}_onMessage(e){(0,i.pC)(this._schedule)?this._schedule((()=>this._processMessage(e))):this._processMessage(e)}_processMessage(e){const t=(0,c.QM)(e);if(t)switch(t.type){case p:this._onResponseMessage(t);break;case h:this._invokeQueue.push(t);break;case d:this._onAbortMessage(t);break;case f:this._onCloseMessage();break;case b:this._onOpenPortMessage(t);break;case g:this._onOnMessage(t)}}_onAbortMessage(e){const t=this._inJobs,r=e.jobId,n=t.get(r);this._invokeQueue.push(e),n&&(n.controller&&n.controller.abort(),t.delete(r))}_onCloseMessage(){const e=this._client;this._close(),e&&"destroy"in e&&y.clients.get(this)===e&&e.destroy(),y.clients.delete(this),e&&e.remoteClient&&(e.remoteClient=null)}_onInvokeMessage(e){const{methodName:t,jobId:r,data:n,abortable:o}=e,s=o?new AbortController:null,i=this._inJobs;let l,u=this._client,f=u[t];try{if(!f&&t&&-1!==t.indexOf(".")){const e=t.split(".");for(let t=0;t<e.length-1;t++)u=u[e[t]],f=u[e[t+1]]}if("function"!=typeof f)throw new TypeError(`${t} is not a function`);l=f.call(u,n,{client:this,signal:s?s.signal:null})}catch(e){return void this._post({type:p,jobId:r,error:(0,c.AB)(e)})}(0,a.y8)(l)?(i.set(r,{controller:s,promise:l}),l.then((e=>{i.has(r)&&(i.delete(r),this._post({type:p,jobId:r},e))}),(e=>{i.has(r)&&(i.delete(r),(0,a.D_)(e)||this._post({type:p,jobId:r,error:(0,c.AB)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:p,jobId:r},l)}_onOpenPortMessage(e){new y(e.port,{client:this._client})}_onOnMessage(e){const{port:t}=e,r=this._client.on(e.eventType,(e=>{t.postMessage(e)})),n=(0,s.on)(e.port,"message",(e=>{(0,c.QM)(e).type===c.Cs.CLOSE&&(n.remove(),r.remove(),t.close())}))}_onResponseMessage(e){var t;const{jobId:r,error:n,data:s}=e,i=this._outJobs;if(!i.has(r))return;const a=i.get(r);i.delete(r),null==(t=a.abortHandle)||t.remove(),n?a.reject(o.Z.fromJSON(JSON.parse(n))):a.resolve(s)}_post(e,t,r){return(0,c.oi)(this._port,e,t,r)}}y.kernelInfo={revision:l.$,version:n.i8,buildDate:l.r},y.clients=new Map},94362:(e,t,r)=>{"use strict";r.d(t,{Cs:()=>n,jt:()=>a,oi:()=>l,QM:()=>u,AB:()=>c});var n,o,s=r(80442);(o=n||(n={}))[o.HANDSHAKE=0]="HANDSHAKE",o[o.OPEN=1]="OPEN",o[o.OPENED=2]="OPENED",o[o.RESPONSE=3]="RESPONSE",o[o.INVOKE=4]="INVOKE",o[o.ABORT=5]="ABORT",o[o.CLOSE=6]="CLOSE",o[o.OPEN_PORT=7]="OPEN_PORT",o[o.ON=8]="ON";let i=0;function a(){return i++}function c(e){return e?"string"==typeof e?JSON.stringify({name:"message",message:e}):e.toJSON?JSON.stringify(e):JSON.stringify({name:e.name,message:e.message,details:e.details||{stack:e.stack}}):null}function l(e,t,r,o){if(t.type===n.OPEN_PORT)return void e.postMessage(t,[t.port]);if(t.type!==n.INVOKE&&t.type!==n.RESPONSE)return void e.postMessage(t);let s;!function(e){return e&&"object"==typeof e&&("result"in e||"transferList"in e)}(r)?(s=f(o),t.data=r):(s=f(r.transferList),t.data=r.result),s?e.postMessage(t,s):e.postMessage(t)}function u(e){if(!e)return null;const t=e.data;return t?"string"==typeof t?JSON.parse(t):t:null}function f(e){if(!e||!e.length)return null;if((0,s.Z)("esri-workers-arraybuffer-transfer"))return e;const t=e.filter((e=>!function(e){return e instanceof ArrayBuffer||e&&e.constructor&&"ArrayBuffer"===e.constructor.name}(e)));return t.length?t:null}},40330:(e,t,r)=>{"use strict";r.d(t,{Dp:()=>l,id:()=>a,qh:()=>c,i8:()=>s,Nv:()=>i});var n=r(80442),o=r(17452);const s="4.22",i={async request(e,t){var n;const{default:s}=await r.e(3172).then(r.bind(r,3172)),i=e.options,a=i.responseType;i.signal=null==t?void 0:t.signal,i.responseType="native"===a||"native-request-init"===a?"native-request-init":["blob","json","text"].includes(a)&&null!=(n=(0,o.oh)(e.url))&&n.after?a:"array-buffer";const c=await s(e.url,i),l={data:c.data,ssl:c.ssl};switch(c.requestOptions.responseType){case"native-request-init":return delete l.data.signal,l;case"blob":l.data=await l.data.arrayBuffer();break;case"json":l.data=(new TextEncoder).encode(JSON.stringify(l.data)).buffer;break;case"text":l.data=(new TextEncoder).encode(l.data).buffer}return{result:l,transferList:[l.data]}}};let a;function c(e){a=e}function l(e){const t=a&&a.findCredential(e);return t&&t.token?(0,o.ZN)(e,"token",t.token):e}(0,n.Z)("host-webworker")||((0,n.Z)("edge")||(0,n.Z)("trident"))&&console.warn("Deprecated browser - see http://esriurl.com/oldbrowser")},17202:(e,t,r)=>{"use strict";r.d(t,{r:()=>n,$:()=>o});const n="20211130",o="7b489204abc8712c46d3a229dc6b74a0c8996b5e"}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var s=t[n]={exports:{}};return e[n](s,s.exports,r),s.exports}r.m=e,r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.f={},r.e=e=>Promise.all(Object.keys(r.f).reduce(((t,n)=>(r.f[n](e,t),t)),[])),r.u=e=>"chunks/"+{24:"bd5f358d83148a97fc7a",36:"457dd64964cf7f404943",102:"64be18169516a9a488f4",147:"472df5b8be9c335eb999",176:"0a5b9fdfa77c0e690503",223:"59640d78295e2e363f18",247:"a0450fbf01de854f5c97",280:"ea05f870dda27bca4fe8",402:"362339272cf5adcf9e4b",411:"8f4714cdd325b8e28957",511:"dd8c983c153c65ebceca",565:"d53ad780789f4d9124ad",576:"38e792e037e88a74995a",635:"12576e848e14cc1fbb70",639:"b935d0c8d5951298cc53",755:"7e0b4f9a847bb2a52338",819:"6280c69d87b2a3a18780",941:"0632f22aa1af88a238ce",966:"e9af7a5eb1e3bce4f0f9",1074:"2d9b32e3e24631cd4e34",1295:"a164ca7d87bfae334347",1387:"a3a55bd894e1eb739733",1421:"7fa2d758a24bbaaab0bf",1433:"1def8845714ea745fd24",1534:"09141e5539e652edfc6c",1762:"9375938d2d708f1b0271",1765:"e6b41012ade9bdce3244",1773:"aa57f2c380132c746730",1785:"09426d106b3189de8b6f",2134:"f3c0d0d182988a8d2b3f",2303:"3c4d68029ee2787f9653",2360:"f3da8b797c8e1fcb1c21",2399:"96f148a556a2418038de",2515:"446f1bc9822d03aa9a7a",2730:"594029863881481feacf",2781:"1de80cd934983f4adfcd",2785:"4fdf762d805ebb17624d",3027:"f30bb46f14bf3e658711",3081:"058955b87ce2aa1b1809",3172:"fe3ca2d2764525a8c67f",3230:"7351fbd8a9dbef027d06",3437:"7d032d4ee9a91709aaa3",3471:"36c4bc3d84e9c3148776",3485:"c2268a36f90a9310feec",3516:"96a62dc1e07f3ef20a30",3529:"5f19c284cfcd5a4569df",3553:"a0aa8321b58109c6ae19",3578:"e39316a7998d3dde62bf",3668:"ab1aa39457f9205c9b79",3749:"701688ccf7a6c93c9147",3792:"c80c8aff0d14dd822454",3852:"62c683f44c297d239ab8",3942:"d7f77fe32bb2d69b5714",4067:"bc0b85bc1e5116836ba4",4166:"8a5e15bb513c65ef730d",4358:"f977977564b2b75332a9",4369:"cb5c42f598064c0c4eaa",4470:"4dca43553ef2090e4b5f",4499:"4d325ff7180a253d08c7",4556:"a465488578b87d63215d",4588:"e14b4af7eefcbc2c46a0",4599:"49bb222ee07a768e998d",4695:"14bef72154b3a19561a7",4720:"fe42716651b39518453c",4816:"d76aa27b92563db8f366",4859:"8bc4ea821be16a752226",4889:"0ca1ce6856620fc88011",5051:"ac9163e7b4d544b9aa78",5158:"af6251cc7973b43a1523",5265:"3131d0ebc834e33754e1",5638:"ae7b979ce886b03937cc",5732:"469ba1b24cdeea0758ec",5823:"ddc4adb9b9997fb09b43",5837:"42c67e6579b54844ec06",5845:"3e43df5bd4cba6b0e91f",5853:"66f8544b54fab04b36e9",6104:"6210b23872c362f51b12",6237:"c544df83e86a9d36b68c",6348:"1f02165e7758645b5e0d",6401:"06c34599afdb1fe03cbc",6459:"d8d182c41e8bb70db4c2",6481:"e3aed0a5b64180bdb6c3",6550:"dffef67a6e45e430afa3",6570:"55d707784090d738bb26",6619:"86245d83dd17ebe39b2a",6690:"5f2718cd77cbd5ba7920",6710:"d11d1d294ccc4ccdf60f",6740:"5cb2588d14e09af0801d",6748:"23af0b02208e20d5c07e",6774:"4a830f056c4d0ed93928",6810:"bd29ea967877fc6d7c53",6841:"597f8ce30413c6e86f7c",6884:"e02a3d456525e76ddb60",6968:"66f06faae46eb8ea1b00",7039:"30d7685fc6dc1787df44",7049:"9453fdba689296828087",7054:"89010776ebdfe8a50a0c",7055:"be1ca1154ec28d186311",7091:"63e08d2c2e9098a14ea8",7277:"f183da283af0836421ab",7284:"3414dd7ed9fadd64eb65",7319:"3e7a0a81a1f07bce3b30",7392:"0277e223fd84f3fc5501",7572:"fdcdc3a5ace2eee31468",7635:"599c9acfd08aaa88ef74",7668:"4513689048bc2a704bf4",7779:"863fe8818f19f82d4d36",7783:"320d655fcd7fe1966145",7845:"db075f5e0827991efcfd",7873:"93eb468381bfcf0e47d7",8008:"f85d95d1b2c4446257f1",8014:"ec0be96baf84a833cb38",8034:"901da7d32c04a6e4ea41",8062:"6b2a6bf7f6b87f2cc894",8121:"3a32fc4f43d87fe84fcb",8216:"6a1ce00bcb689ea95bcb",8227:"1f394b20410fddb30a96",8316:"f98f64bbcb1b24d0d290",8422:"56c34f60fdc752ca8371",8511:"52aa3b44bddb10caa343",8589:"02ce52ca0084536bc066",8625:"caa5d1b9680a822f2070",8659:"47dab63e1b2e64a96637",8683:"4417dfcb2ba50ac9f199",8758:"826c983100569586b61f",8778:"b957ef59aa56b5c339f4",8828:"36de1a1959f038a61cca",8835:"ff9a9e705237c55f78ff",8846:"dadf9930c296c88c3a88",8936:"7802deb733e6a2d2f369",8961:"9796d54ff12b6429164a",9070:"db202ae7dc8b584f312f",9101:"3bea6fa573a4daece0ed",9151:"d42f289a65a98d752e12",9169:"f7ae0344257e6e08469b",9201:"83c18c36d8829d00c280",9221:"b6b46f8e6a7d8d3cef50",9254:"ccaaefa20dfb940e8cc0",9291:"6e172b435a55bc72baef",9294:"95471140bd6ec868337e",9296:"e9608d8e0ea984aa35a0",9474:"d76ba25485e92bbda0c5",9489:"06a9cdf71330bf9cc774",9490:"7678b37f4f528af762e2",9561:"44145763617ea985cce4",9625:"39e48b3510a3c831299e",9664:"5aee3903ee34855d14f2",9767:"9e3fc6ba87fa55c33055",9872:"b245e95708cde2c403de",9884:"356db8b8297282c77291",9928:"5c561d65035d46249fb4",9932:"489147cf21d55f47d0e6",9938:"deba37055be7c2d7da26"}[e]+".js",r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e;r.g.importScripts&&(e=r.g.location+"");var t=r.g.document;if(!e&&t&&(t.currentScript&&(e=t.currentScript.src),!e)){var n=t.getElementsByTagName("script");n.length&&(e=n[n.length-1].src)}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),r.p=e})(),(()=>{var e={134:1,102:1};r.f.i=(t,n)=>{e[t]||importScripts(r.p+r.u(t))};var t=self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[],n=t.push.bind(t);t.push=t=>{var[o,s,i]=t;for(var a in s)r.o(s,a)&&(r.m[a]=s[a]);for(i&&i(r);o.length;)e[o.pop()]=1;n(t)}})(),r(88277);var n=r(25045);RemoteClient=n})();
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7392,4889],{3920:(e,t,r)=>{r.d(t,{r:()=>u,p:()=>c});var n=r(43697),i=r(15923),s=r(61247),o=r(5600),a=r(52011),l=r(89749);const c=e=>{let t=class extends e{destroy(){var e,t;this.destroyed||(null==(e=this._get("handles"))||e.destroy(),null==(t=this._get("updatingHandles"))||t.destroy())}get handles(){return this._get("handles")||new s.Z}get updatingHandles(){return this._get("updatingHandles")||new l.t}};return(0,n._)([(0,o.Cb)({readOnly:!0})],t.prototype,"handles",null),(0,n._)([(0,o.Cb)({readOnly:!0})],t.prototype,"updatingHandles",null),t=(0,n._)([(0,a.j)("esri.core.HandleOwner")],t),t};let u=class extends(c(i.Z)){};u=(0,n._)([(0,a.j)("esri.core.HandleOwner")],u)},43050:(e,t,r)=>{r.d(t,{S1:()=>o,on:()=>f,OY:()=>u,cm:()=>l,N1:()=>a,LR:()=>c,tH:()=>h});var n=r(91460),i=(r(22974),r(95330));const s=/\?(\.|$)/g;function o(e,t,r,n){const i=Array.isArray(t)?t:t.indexOf(",")>-1?t.split(","):[t],o=function(e,t,r,n){return e.watch(t,r,n)}(e,t,r,n);for(const t of i){const n=t.trim().replace(s,"$1"),i=e.get(n);r.call(e,i,i,n,e)}return o}function a(e,t,r,n){return h(e,t,d,r,n)}function l(e,t,r,n){return h(e,t,p,r,n)}function c(e,t,r,n){return h(e,t,m,r,n)}function u(e,t,r,n){return h(e,t,y,r,n)}function f(e,t,r,i,s,a,l){const c={};function u(t){const n=c[t];n&&(a&&a(n.target,t,e,r),n.handle.remove(),delete c[t])}const f=o(e,t,((t,o,a)=>{u(a),(0,n.vT)(t)&&(c[a]={handle:(0,n.on)(t,r,i),target:t},s&&s(t,a,e,r))}),l);return{remove(){f.remove();for(const e in c)u(e)}}}function h(e,t,r,n,s){const o="function"==typeof n?n:null,a="object"==typeof n?n:null;"boolean"==typeof n&&(s=n);let l,c=!1;function u(){l&&(l.remove(),l=null)}const f=(0,i.dD)();(0,i.fu)(a,(()=>{u(),f.reject((0,i.zE)())}));const h={then:f.promise.then.bind(f.promise),catch:f.promise.catch.bind(f.promise),remove:u};return Object.freeze(h),l=function(e,t,r,n,i){const s=e.watch(t,((t,i,s,o)=>{r&&!r(t)||null==n||n.call(e,t,i,s,o)}),i);if(Array.isArray(t))for(const i of t){const s=e.get(i);r&&r(s)&&(null==n||n.call(e,s,s,t,e))}else{const i=e.get(t);r&&r(i)&&(null==n||n.call(e,i,i,t,e))}return s}(e,t,r,((t,r,n,i)=>{c=!0,u(),o&&o.call(e,t,r,n,i),f.resolve({value:t,oldValue:r,propertyName:n,target:i})}),s),c&&u(),h}function d(e){return!!e}function p(e){return!e}function m(e){return!0===e}function y(e){return!1===e}},78346:(e,t,r)=>{r.d(t,{bA:()=>z});var n=r(20102),i=r(80442),s=r(95330),o=r(80903),a=r(25045),l=r(40330),c=r(92604),u=r(94362),f=r(99880),h=r(68773),d=(r(2587),r(17452));const p={};function m(e){var t;const r={async:e.async,isDebug:e.isDebug,locale:e.locale,baseUrl:e.baseUrl,has:{...e.has},map:{...e.map},packages:e.packages&&e.packages.concat()||[],paths:{...e.paths}};return e.hasOwnProperty("async")||(r.async=!0),e.hasOwnProperty("isDebug")||(r.isDebug=!1),e.baseUrl||(r.baseUrl=p.baseUrl),null==(t=p.packages)||t.forEach((e=>{!function(e,t){for(const r of e)if(r.name===t.name)return;e.push(t)}(r.packages,e)})),r}var y=r(41213);class g{constructor(){const e=document.createDocumentFragment();["addEventListener","dispatchEvent","removeEventListener"].forEach((t=>{this[t]=(...r)=>e[t](...r)}))}}class x{constructor(){this._dispatcher=new g,this._workerPostMessage({type:u.Cs.HANDSHAKE})}terminate(){}get onmessage(){return this._onmessageHandler}set onmessage(e){this._onmessageHandler&&this.removeEventListener("message",this._onmessageHandler),this._onmessageHandler=e,e&&this.addEventListener("message",e)}get onmessageerror(){return this._onmessageerrorHandler}set onmessageerror(e){this._onmessageerrorHandler&&this.removeEventListener("messageerror",this._onmessageerrorHandler),this._onmessageerrorHandler=e,e&&this.addEventListener("messageerror",e)}get onerror(){return this._onerrorHandler}set onerror(e){this._onerrorHandler&&this.removeEventListener("error",this._onerrorHandler),this._onerrorHandler=e,e&&this.addEventListener("error",e)}postMessage(e){(0,y.Y)((()=>{this._workerMessageHandler(new MessageEvent("message",{data:e}))}))}dispatchEvent(e){return this._dispatcher.dispatchEvent(e)}addEventListener(e,t,r){this._dispatcher.addEventListener(e,t,r)}removeEventListener(e,t,r){this._dispatcher.removeEventListener(e,t,r)}_workerPostMessage(e){(0,y.Y)((()=>{this.dispatchEvent(new MessageEvent("message",{data:e}))}))}async _workerMessageHandler(e){const t=(0,u.QM)(e);if(t&&t.type===u.Cs.OPEN){const{modulePath:e,jobId:r}=t;let n=await a.default.loadWorker(e);n||(n=await import(e));const i=a.default.connect(n);this._workerPostMessage({type:u.Cs.OPENED,jobId:r,data:i})}}}var w=r(70171),v=r(17202);const b=c.Z.getLogger("esri.core.workers"),{HANDSHAKE:I}=u.Cs;let _,C;const R="Failed to create Worker. Fallback to execute module in main thread";async function S(e){return new Promise((t=>{function r(i){const s=(0,u.QM)(i);s&&s.type===I&&(e.removeEventListener("message",r),e.removeEventListener("error",n),t(e))}function n(t){t.preventDefault(),e.removeEventListener("message",r),e.removeEventListener("error",n),b.warn("Failed to create Worker. Fallback to execute module in main thread",t),(e=new x).addEventListener("message",r),e.addEventListener("error",n)}e.addEventListener("message",r),e.addEventListener("error",n)}))}let k=0;const T=c.Z.getLogger("esri.core.workers"),{ABORT:M,INVOKE:P,OPEN:O,OPENED:F,RESPONSE:E}=u.Cs;class N{constructor(e,t){this._outJobs=new Map,this._inJobs=new Map,this.worker=e,this.id=t,e.addEventListener("message",this._onMessage.bind(this)),e.addEventListener("error",(e=>{e.preventDefault(),T.error(e)}))}static async create(e){const t=await async function(){if(!(0,i.Z)("esri-workers"))return S(new x);if(!_&&!C)try{const e='let globalId=0;const outgoing=new Map,configuration=JSON.parse("{CONFIGURATION}");self.esriConfig=configuration.esriConfig;const workerPath=self.esriConfig.workers.workerPath,HANDSHAKE=0,OPEN=1,OPENED=2,RESPONSE=3,INVOKE=4,ABORT=5;function createAbortError(){const e=new Error("Aborted");return e.name="AbortError",e}function receiveMessage(e){return e&&e.data?"string"==typeof e.data?JSON.parse(e.data):e.data:null}function invokeStaticMessage(e,o,r){const t=r&&r.signal,n=globalId++;return new Promise(((r,i)=>{if(t){if(t.aborted)return i(createAbortError());t.addEventListener("abort",(()=>{outgoing.get(n)&&(outgoing.delete(n),self.postMessage({type:5,jobId:n}),i(createAbortError()))}))}outgoing.set(n,{resolve:r,reject:i}),self.postMessage({type:4,jobId:n,methodName:e,abortable:null!=t,data:o})}))}let workerRevisionChecked=!1;function checkWorkerRevision(e){if(!workerRevisionChecked&&e.kernelInfo){workerRevisionChecked=!0;const{revision:o,buildDate:r,version:t}=configuration.kernelInfo,{revision:n,buildDate:i,version:s}=e.kernelInfo;o!==n&&console.warn(`[esri.core.workers] Version mismatch detected between ArcGIS API for JavaScript and assets:\nAPI version: ${t} [Date: ${r}, Revision: ${o.slice(0,8)}]\nAssets version: ${s} [Date: ${i}, Revision: ${n.slice(0,8)}]`)}}function messageHandler(e){const o=receiveMessage(e);if(!o)return;const r=o.jobId;switch(o.type){case 1:let e;function t(o){const t=e.connect(o);self.postMessage({type:2,jobId:r,data:t},[t])}"function"==typeof define&&define.amd?require([workerPath],(r=>{e=r.default||r,checkWorkerRevision(e),e.loadWorker(o.modulePath).then((e=>e||new Promise((e=>{require([o.modulePath],e)})))).then(t)})):"System"in self&&"function"==typeof System.import?System.import(workerPath).then((r=>(e=r.default,checkWorkerRevision(e),e.loadWorker(o.modulePath)))).then((e=>e||System.import(o.modulePath))).then(t):(self.RemoteClient||importScripts(workerPath),e=self.RemoteClient.default||self.RemoteClient,checkWorkerRevision(e),e.loadWorker(o.modulePath).then(t));break;case 3:if(outgoing.has(r)){const e=outgoing.get(r);outgoing.delete(r),o.error?e.reject(JSON.parse(o.error)):e.resolve(o.data)}}}self.dojoConfig=configuration.loaderConfig,esriConfig.workers.loaderUrl&&(self.importScripts(esriConfig.workers.loaderUrl),"function"==typeof require&&"function"==typeof require.config&&require.config(configuration.loaderConfig)),self.addEventListener("message",messageHandler),self.postMessage({type:0});'.replace('"{CONFIGURATION}"',`'${function(){let e;if(null!=h.Z.default){const t={...h.Z};delete t.default,e=JSON.parse(JSON.stringify(t))}else e=JSON.parse(JSON.stringify(h.Z));e.assetsPath=(0,d.hF)(e.assetsPath),e.request.interceptors=[],e.log.interceptors=[],e.locale=(0,w.Kd)(),e.has={"esri-csp-restrictions":(0,i.Z)("esri-csp-restrictions"),"esri-2d-debug":!1,"esri-2d-update-debug":(0,i.Z)("esri-2d-update-debug"),"esri-2d-query-centroid-enabled":(0,i.Z)("esri-2d-query-centroid-enabled"),"featurelayer-pbf":(0,i.Z)("featurelayer-pbf"),"featurelayer-simplify-thresholds":(0,i.Z)("featurelayer-simplify-thresholds"),"featurelayer-simplify-payload-size-factors":(0,i.Z)("featurelayer-simplify-payload-size-factors"),"featurelayer-simplify-mobile-factor":(0,i.Z)("featurelayer-simplify-mobile-factor"),"esri-atomics":(0,i.Z)("esri-atomics"),"esri-shared-array-buffer":(0,i.Z)("esri-shared-array-buffer"),"esri-tiles-debug":(0,i.Z)("esri-tiles-debug"),"esri-workers-arraybuffer-transfer":(0,i.Z)("esri-workers-arraybuffer-transfer"),"host-webworker":1},e.workers.loaderUrl&&(e.workers.loaderUrl=(0,d.hF)(e.workers.loaderUrl)),e.workers.workerPath?e.workers.workerPath=(0,d.hF)(e.workers.workerPath):e.workers.workerPath=(0,d.hF)((0,f.V)("esri/core/workers/RemoteClient.js"));const t=h.Z.workers.loaderConfig,r=m({baseUrl:null==t?void 0:t.baseUrl,locale:(0,w.Kd)(),has:{"csp-restrictions":1,"dojo-test-sniff":0,"host-webworker":1,...null==t?void 0:t.has},map:{...null==t?void 0:t.map},paths:{...null==t?void 0:t.paths},packages:(null==t?void 0:t.packages)||[]}),n={version:l.i8,buildDate:v.r,revision:v.$};return JSON.stringify({esriConfig:e,loaderConfig:r,kernelInfo:n})}()}'`);_=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))}catch(e){C=e||{}}let e;if(_)try{e=new Worker(_,{name:"esri-worker-"+k++})}catch(t){b.warn(R,C),e=new x}else b.warn(R,C),e=new x;return S(e)}();return new N(t,e)}terminate(){this.worker.terminate()}async open(e,t={}){const{signal:r}=t,n=(0,u.jt)();return new Promise(((t,i)=>{const o={resolve:t,reject:i,abortHandle:(0,s.$F)(r,(()=>{this._outJobs.delete(n),this._post({type:M,jobId:n})}))};this._outJobs.set(n,o),this._post({type:O,jobId:n,modulePath:e})}))}_onMessage(e){const t=(0,u.QM)(e);if(t)switch(t.type){case F:this._onOpenedMessage(t);break;case E:this._onResponseMessage(t);break;case M:this._onAbortMessage(t);break;case P:this._onInvokeMessage(t)}}_onAbortMessage(e){const t=this._inJobs,r=e.jobId,n=t.get(r);n&&(n.controller&&n.controller.abort(),t.delete(r))}_onInvokeMessage(e){const{methodName:t,jobId:r,data:n,abortable:i}=e,o=i?new AbortController:null,a=this._inJobs,c=l.Nv[t];let f;try{if("function"!=typeof c)throw new TypeError(`${t} is not a function`);f=c.call(null,n,{signal:o?o.signal:null})}catch(e){return void this._post({type:E,jobId:r,error:(0,u.AB)(e)})}(0,s.y8)(f)?(a.set(r,{controller:o,promise:f}),f.then((e=>{a.has(r)&&(a.delete(r),this._post({type:E,jobId:r},e))}),(e=>{a.has(r)&&(a.delete(r),e||(e={message:"Error encountered at method"+t}),(0,s.D_)(e)||this._post({type:E,jobId:r,error:(0,u.AB)(e||{message:`Error encountered at method ${t}`})}))}))):this._post({type:E,jobId:r},f)}_onOpenedMessage(e){var t;const{jobId:r,data:n}=e,i=this._outJobs.get(r);i&&(this._outJobs.delete(r),null==(t=i.abortHandle)||t.remove(),i.resolve(n))}_onResponseMessage(e){var t;const{jobId:r,error:i,data:s}=e,o=this._outJobs.get(r);o&&(this._outJobs.delete(r),null==(t=o.abortHandle)||t.remove(),i?o.reject(n.Z.fromJSON(JSON.parse(i))):o.resolve(s))}_post(e,t,r){return(0,u.oi)(this.worker,e,t,r)}}let B=(0,i.Z)("esri-workers-debug")?1:(0,i.Z)("host-browser")?navigator.hardwareConcurrency-1:0;B||(B=(0,i.Z)("safari")&&(0,i.Z)("mac")||(0,i.Z)("trident")?7:2);let Z=0;const D=[];async function A(e,t){const r=new o.Z;return await r.open(e,t),r}async function z(e,t={}){if("string"!=typeof e)throw new n.Z("workers:undefined-module","modulePath is missing");let r=t.strategy||"distributed";if((0,i.Z)("host-webworker")&&!(0,i.Z)("esri-workers")&&(r="local"),"local"===r){let r=await a.default.loadWorker(e);r||(r=await import(e)),(0,s.k_)(t.signal);const n=t.client||r;return A([a.default.connect(r)],{...t,client:n})}if(await async function(){if(L)return L;H=new AbortController;const e=[];for(let t=0;t<B;t++){const r=N.create(t).then((e=>(D[t]=e,e)));e.push(r)}return L=Promise.all(e),L}(),(0,s.k_)(t.signal),"dedicated"===r){const r=Z++%B;return A([await D[r].open(e,t)],t)}if(t.maxNumWorkers&&t.maxNumWorkers>0){const r=Math.min(t.maxNumWorkers,B);if(r<B){const n=new Array(r);for(let i=0;i<r;++i){const r=Z++%B;n[i]=D[r].open(e,t)}return A(n,t)}}return A(D.map((r=>r.open(e,t))),t)}let H,L=null},2587:(e,t,r)=>{r(90344),r(18848),r(940),r(70171);var n=r(94443),i=r(3172),s=r(20102),o=r(70586);async function a(e){if((0,o.pC)(c.fetchBundleAsset))return c.fetchBundleAsset(e);const t=await(0,i.default)(e,{responseType:"text"});return JSON.parse(t.data)}class l{constructor({base:e="",pattern:t,location:r=new URL(window.location.href)}){let n;n="string"==typeof r?e=>new URL(e,new URL(r,window.location.href)).href:r instanceof URL?e=>new URL(e,r).href:r,this.pattern="string"==typeof t?new RegExp(`^${t}`):t,this.getAssetUrl=n,e=e?e.endsWith("/")?e:e+"/":"",this.matcher=new RegExp(`^${e}(?:(.*)/)?(.*)$`)}fetchMessageBundle(e,t){return async function(e,t,r,i){const o=t.exec(r);if(!o)throw new s.Z("esri-intl:invalid-bundle",`Bundle id "${r}" is not compatible with the pattern "${t}"`);const l=o[1]?`${o[1]}/`:"",c=o[2],u=(0,n.Su)(i),f=`${l}${c}.json`,h=u?`${l}${c}_${u}.json`:f;let d;try{d=await a(e(h))}catch(t){if(h===f)throw new s.Z("intl:unknown-bundle",`Bundle "${r}" cannot be loaded`,{error:t});try{d=await a(e(f))}catch(e){throw new s.Z("intl:unknown-bundle",`Bundle "${r}" cannot be loaded`,{error:e})}}return d}(this.getAssetUrl,this.matcher,e,t)}}const c={};var u,f=r(99880);(0,n.tz)((u={pattern:"esri/",location:f.V},new l(u)))},94443:(e,t,r)=>{r.d(t,{ME:()=>d,Su:()=>p,tz:()=>h});var n=r(20102),i=r(95330),s=r(70171);const o=/^([a-z]{2})(?:[-_]([A-Za-z]{2}))?$/,a={ar:!0,bg:!0,bs:!0,ca:!0,cs:!0,da:!0,de:!0,el:!0,en:!0,es:!0,et:!0,fi:!0,fr:!0,he:!0,hr:!0,hu:!0,id:!0,it:!0,ja:!0,ko:!0,lt:!0,lv:!0,nb:!0,nl:!0,pl:!0,"pt-BR":!0,"pt-PT":!0,ro:!0,ru:!0,sk:!0,sl:!0,sr:!0,sv:!0,th:!0,tr:!0,uk:!0,vi:!0,"zh-CN":!0,"zh-HK":!0,"zh-TW":!0};function l(e){var t;return null!=(t=a[e])&&t}const c=[],u=new Map;function f(e){for(const t of u.keys())m(e.pattern,t)&&u.delete(t)}function h(e){return c.includes(e)||(f(e),c.unshift(e)),{remove(){const t=c.indexOf(e);t>-1&&(c.splice(t,1),f(e))}}}async function d(e){const t=(0,s.Kd)();u.has(e)||u.set(e,async function(e,t){const r=[];for(const n of c)if(m(n.pattern,e))try{return await n.fetchMessageBundle(e,t)}catch(e){r.push(e)}if(r.length)throw new n.Z("intl:message-bundle-error",`Errors occurred while loading "${e}"`,{errors:r});throw new n.Z("intl:no-message-bundle-loader",`No loader found for message bundle "${e}"`)}(e,t));const r=u.get(e);return await y.add(r),r}function p(e){if(!o.test(e))return null;const[,t,r]=o.exec(e),n=t+(r?"-"+r.toUpperCase():"");return l(n)?n:l(t)?t:null}function m(e,t){return"string"==typeof e?t.startsWith(e):e.test(t)}(0,s.Ze)((()=>{u.clear()}));const y=new class{constructor(){this._numLoading=0}async waitForAll(){this._dfd&&await this._dfd.promise}add(e){return this._increase(),e.then((()=>this._decrease()),(()=>this._decrease())),this.waitForAll()}_increase(){this._numLoading++,this._dfd||(this._dfd=(0,i.dD)())}_decrease(){this._numLoading=Math.max(this._numLoading-1,0),this._dfd&&0===this._numLoading&&(this._dfd.resolve(),this._dfd=null)}}},940:(e,t,r)=>{r.d(t,{n:()=>c});var n=r(92604),i=r(78286),s=r(19153),o=r(90344),a=r(18848);const l=n.Z.getLogger("esri.intl");function c(e,t,r={}){const{format:n={}}=r;return(0,s.gx)(e,(e=>function(e,t,r){let n,s;const o=e.indexOf(":");if(-1===o?n=e.trim():(n=e.slice(0,o).trim(),s=e.slice(o+1).trim()),!n)return"";const a=(0,i.hS)(n,t);if(null==a)return"";const l=r[s]||r[n];return l?u(a,l):s?f(a,s):h(a)}(e,t,n)))}function u(e,t){switch(t.type){case"date":return(0,o.p6)(e,t.intlOptions);case"number":return(0,a.uf)(e,t.intlOptions);default:return l.warn("missing format descriptor for key {key}"),h(e)}}function f(e,t){switch(t.toLowerCase()){case"dateformat":return(0,o.p6)(e);case"numberformat":return(0,a.uf)(e);default:return l.warn(`inline format is unsupported since 4.12: ${t}`),/^(dateformat|datestring)/i.test(t)?(0,o.p6)(e):/^numberformat/i.test(t)?(0,a.uf)(e):h(e)}}function h(e){switch(typeof e){case"string":return e;case"number":return(0,a.uf)(e);case"boolean":return""+e;default:return e instanceof Date?(0,o.p6)(e):""}}},54592:(e,t,r)=>{r.r(t),r.d(t,{default:()=>Xe});var n=r(43697),i=r(51773),s=r(14746),o=r(20102),a=r(70586),l=r(16453),c=r(95330),u=r(5600),f=(r(67676),r(80442),r(75215)),h=r(36030),d=r(71715),p=r(52011),m=r(29600),y=r(71612),g=r(17017),x=(r(66577),r(3172)),w=r(92604),v=r(44422),b=r(8744),I=r(66677),_=r(21506),C=r(35956),R=r(88281),S=r(11145),k=r(80676),T=r(67058),M=r(91219),P=r(23808),O=r(6570),F=r(82971);const E=w.Z.getLogger("esri.layers.mixins.ImageryTileMixin"),N=e=>{let t=class extends e{constructor(){super(...arguments),this._rasterJobHandler={instance:null,refCount:0,connectionPromise:null},this.bandIds=null,this.copyright=null,this.fullExtent=null,this.interpolation="nearest",this.multidimensionalDefinition=null,this.raster=null,this.rasterInfo=null,this.sourceJSON=null,this.spatialReference=null,this.tileInfo=null,this.symbolizer=null}set url(e){this._set("url",(0,I.Nm)(e,E))}set renderer(e){this._set("renderer",e),this.updateRenderer()}async convertVectorFieldData(e,t){if((0,a.Wi)(e))return null;const r=this._rasterJobHandler.instance,n=this.rasterInfo.dataType;return r?r.convertVectorFieldData({pixelBlock:e,dataType:n},t):(0,k.KC)(e,n)}async createStreamlinesMesh(e,t){const r=this._rasterJobHandler.instance;return r?r.createStreamlinesMesh(e,t):(0,P.z_)(e.rendererSettings,e.flowData,(0,a.pC)(t.signal)?t.signal:(new AbortController).signal)}normalizeRasterFetchOptions(e){const{multidimensionalInfo:t}=this.rasterInfo;if((0,a.Wi)(t))return e;let r=e.multidimensionalDefinition||this.multidimensionalDefinition;!(0,a.Wi)(r)&&r.length||(r=this._getDefaultSlice());const n=e.timeExtent||this.timeExtent;if((0,a.pC)(r)&&(0,a.pC)(n)&&((0,a.pC)(n.start)||(0,a.pC)(n.end))){var i,s;r=r.map((e=>e.clone()));const o=null==(i=t.variables.find((({name:e})=>e===r[0].variableName)))||null==(s=i.dimensions)?void 0:s.find((({name:e})=>"StdTime"===e)),l=r.find((({dimensionName:e})=>"StdTime"===e));if(!o||!l)return{...e,multidimensionalDefinition:null};const{start:c,end:u}=n,f=(0,a.Wi)(c)?null:c.getTime(),h=(0,a.Wi)(u)?null:u.getTime(),d=null!=f?f:h,p=null!=h?h:f;if((0,a.pC)(o.values)){const e=o.values.filter((e=>{if(Array.isArray(e)){if(d===p)return e[0]<=d&&e[1]>=d;const t=e[0]<=d&&e[1]>d||e[0]<p&&e[1]>=p,r=e[0]>=d&&e[1]<=p||e[0]<d&&e[1]>p;return t||r}return d===p?e===d:e>=d&&e<=p}));if(e.length){const t=e.sort(((e,t)=>{var r,n,i,s;return d===p?(null!=(i=e[0])?i:e)-(null!=(s=t[0])?s:t):Math.abs((null!=(r=e[1])?r:e)-p)-Math.abs((null!=(n=t[1])?n:t)-p)}))[0];l.values=[t]}else r=null}else if(o.hasRegularIntervals&&o.extent){const[e,t]=o.extent;d>t||p<e?r=null:l.values=d===p?[d]:[Math.max(e,d),Math.min(t,p)]}}return{...e,multidimensionalDefinition:r}}async updateRenderer(){if(!this.loaded)return;if(JSON.stringify(this._cachedRendererJson)===JSON.stringify(this.renderer))return;const e=this._rasterJobHandler.instance;e&&(this.symbolizer.rendererJSON=(0,T.ol)(this.renderer.toJSON()),this.symbolizer.bind(),await e.updateSymbolizer(this.symbolizer),this._cachedRendererJson=this.renderer.toJSON())}async applyRenderer(e,t){const r=e&&e.pixelBlock;if(!((0,a.pC)(r)&&r.pixels&&r.pixels.length>0))return null;let n;await this.updateRenderer();const i=this._rasterJobHandler.instance,{bandIds:s}=this;return n=i?await i.symbolize({...e,simpleStretchParams:t,bandIds:s}):this.symbolizer.symbolize({...e,simpleStretchParams:t,bandIds:s}),n}getTileUrl(e,t,r){return"RasterTileServer"===this.raster.datasetFormat?`${this.url}/tile/${e}/${t}/${r}`:""}getCompatibleTileInfo(e,t,r=!1){if(!this.loaded||(0,a.Wi)(t))return null;if(r&&e.equals(this.spatialReference))return this.tileInfo;const n=(0,b.C5)(e);return S.Z.create({size:256,spatialReference:e,origin:n?{x:n.origin[0],y:n.origin[1]}:{x:t.xmin,y:t.ymax}})}getCompatibleFullExtent(e){return this.loaded?(this._compatibleFullExtent&&this._compatibleFullExtent.spatialReference.equals(e)||(this._compatibleFullExtent=this.raster.computeExtent(e)),this._compatibleFullExtent):null}async fetchTile(e,t,r,n={}){if(n.requestAsImageElement){const i=this.getTileUrl(e,t,r);return(0,x.default)(i,{responseType:"image",query:{...this.refreshParameters,...this.raster.ioConfig.customFetchParameters},signal:n.signal}).then((e=>e.data))}if((0,a.pC)(this.rasterInfo.multidimensionalInfo)&&(n=this.normalizeRasterFetchOptions(n),(0,a.Wi)(n.multidimensionalDefinition))){const i=n.tileInfo||this.rasterInfo.storageInfo.tileInfo;return{extent:this.raster.getTileExtentFromTileInfo(e,t,r,i),pixelBlock:null}}return await this._initJobHandler(),"raster-shaded-relief"===this.renderer.type&&(n={...n,buffer:{cols:1,rows:1}}),this.raster.fetchTile(e,t,r,n)}async fetchPixels(e,t,r,n={}){return(0,a.pC)(this.rasterInfo.multidimensionalInfo)&&(n=this.normalizeRasterFetchOptions(n),(0,a.Wi)(n.multidimensionalDefinition))?{extent:e,pixelBlock:null}:(await this._initJobHandler(),this.raster.fetchPixels(e,t,r,n))}async identify(e,t={}){return(0,a.pC)(this.rasterInfo.multidimensionalInfo)&&(t=this.normalizeRasterFetchOptions(t),(0,a.Wi)(t.multidimensionalDefinition))?{location:e,value:null}:this.raster.identify(e,t)}increaseRasterJobHandlerUsage(){this._rasterJobHandler.refCount++}decreaseRasterJobHandlerUsage(){this._rasterJobHandler.refCount--,this._rasterJobHandler.refCount<=0&&this._shutdownJobHandler()}hasStandardTime(){var e;const t=this.rasterInfo.multidimensionalInfo;if(!(0,a.pC)(t)||"standard-time"!==this.rasterInfo.dataType)return!1;const r=null==(e=this.multidimensionalDefinition[0])?void 0:e.variableName;return t.variables.some((e=>e.name===r&&e.dimensions.some((e=>"StdTime"===e.name))))}getStandardTimeValue(e){return new Date(24*(e-25569)*3600*1e3).toString()}_configDefaultSettings(){this._configDefaultInterpolation(),this.multidimensionalDefinition||(this.multidimensionalDefinition=this._getDefaultSlice()),this._configDefaultRenderer()}_initJobHandler(){if(null!=this._rasterJobHandler.connectionPromise)return this._rasterJobHandler.connectionPromise;const e=new R.Z;return this._rasterJobHandler.connectionPromise=e.initialize().then((()=>{this._rasterJobHandler.instance=e,this.raster.rasterJobHandler=e,this.renderer&&this.updateRenderer()})).catch((()=>null)),this._rasterJobHandler.connectionPromise}_shutdownJobHandler(){this._rasterJobHandler.instance&&this._rasterJobHandler.instance.destroy(),this._rasterJobHandler.instance=null,this._rasterJobHandler.connectionPromise=null,this._rasterJobHandler.refCount=0,this.raster.rasterJobHandler=null}_configDefaultInterpolation(){if(null==this.interpolation){var e;const t=(0,T.In)(this.rasterInfo,this.raster.tileType,null==(e=this.sourceJSON)?void 0:e.defaultResamplingMethod);this._set("interpolation",t)}}_getDefaultSlice(){const{multidimensionalInfo:e}=this.raster.rasterInfo;if(!(0,a.pC)(e))return null;const t=e.variables[0];return t.dimensions.map((e=>{var r,n;return new C.Z({variableName:t.name,dimensionName:e.name,values:[null!=(r=null==(n=e.values)?void 0:n[0])?r:e.extent[0]],isSlice:!0})}))}_configDefaultRenderer(){const e=this.raster.rasterInfo;var t;this.bandIds||(this.bandIds=(0,T.YD)(e)),this.renderer||(this.renderer=(0,T.Ob)(e,{bandIds:this.bandIds,variableName:(0,a.pC)(this.multidimensionalDefinition)?null==(t=this.multidimensionalDefinition[0])?void 0:t.variableName:null})),this.symbolizer?(this.symbolizer.rendererJSON=(0,T.ol)(this.renderer.toJSON()),this.symbolizer.rasterInfo=e):this.symbolizer=new M.Z({rendererJSON:this.renderer.toJSON(),rasterInfo:e});const r=this.symbolizer.bind();r.success||E.warn("imagery-tile-mixin",r.error||"The given renderer is not supported by the layer.")}};return(0,n._)([(0,u.Cb)()],t.prototype,"_cachedRendererJson",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"_compatibleFullExtent",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"_rasterJobHandler",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"bandIds",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"copyright",void 0),(0,n._)([(0,u.Cb)({type:O.Z}),(0,v.B)("rasterInfo.extent")],t.prototype,"fullExtent",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"interpolation",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"ioConfig",void 0),(0,n._)([(0,u.Cb)({type:[C.Z]})],t.prototype,"multidimensionalDefinition",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"raster",void 0),(0,n._)([(0,u.Cb)({readOnly:!0}),(0,v.B)("raster.rasterInfo")],t.prototype,"rasterInfo",void 0),(0,n._)([(0,u.Cb)()],t.prototype,"sourceJSON",void 0),(0,n._)([(0,u.Cb)({type:F.Z}),(0,v.B)("rasterInfo.spatialReference")],t.prototype,"spatialReference",void 0),(0,n._)([(0,u.Cb)({type:S.Z}),(0,v.B)("rasterInfo.storageInfo.tileInfo")],t.prototype,"tileInfo",void 0),(0,n._)([(0,u.Cb)(_.HQ)],t.prototype,"url",null),(0,n._)([(0,u.Cb)({types:s.dr})],t.prototype,"renderer",null),(0,n._)([(0,u.Cb)()],t.prototype,"symbolizer",void 0),t=(0,n._)([(0,p.j)("esri.layers.ImageryTileMixin")],t),t};var B=r(38009),Z=r(16859),D=r(34760),A=r(72965),z=r(28294),H=r(1231),L=r(69608),J=r(30547),W=r(48526),j=r(36679),U=r(10736),q=r(609),$=r(73506),G=r(13473);const V=new Map,Y=new class{constructor(e=15e3,t=5e3){this._timer=null,this._cachedBlocks=new Map,this._size=-1,this._duration=e,this._interval=Math.min(e,t)}decreaseRefCount(e,t){const r=e+"/"+t,n=this._cachedBlocks;if(n.has(r)){const e=n.get(r);return e.refCount--,e.refCount<=0&&(n.delete(r),e.controller&&e.controller.abort()),e.refCount}return 0}getBlock(e,t){const r=e+"/"+t,n=this._cachedBlocks;if(n.has(r)){const e=n.get(r);return e.ts=Date.now(),e.refCount++,n.delete(r),n.set(r,e),e.block}return null}putBlock(e,t,r,n=null){const i=this._cachedBlocks,s=e+"/"+t;if(i.has(s)){const e=i.get(s);e.ts=Date.now(),e.refCount++}else i.set(s,{block:r,ts:Date.now(),refCount:1,controller:n});this.trim(),this.updateTimer()}deleteBlock(e,t){const r=this._cachedBlocks,n=e+"/"+t;r.has(n)&&r.delete(n)}updateMaxSize(e){this._size=e,this.trim()}empty(){this._cachedBlocks.clear(),this.clearTimer()}getCurrentSize(){return this._cachedBlocks.size}updateTimer(){if(null!=this._timer)return;const e=this._cachedBlocks;this._timer=setInterval((()=>{const t=Array.from(e),r=Date.now();for(let n=0;n<t.length&&t[n][1].ts<=r-this._duration;n++)e.delete(t[n][0]);0===e.size&&this.clearTimer()}),this._interval)}trim(){const e=this._cachedBlocks;if(-1===this._size||this._size>=e.size)return;const t=Array.from(e);for(let r=0;r<t.length-this._size;r++)e.delete(t[r][0])}clearTimer(){null!=this._timer&&(clearInterval(this._timer),this._timer=null)}};function X(e,t){return null==t?e:`${e}?sliceId=${t}`}function K(e,t,r){if(!V.has(e))return null==t?Y.decreaseRefCount(e,r):0;const n=V.get(e);if(null==n[t])return Y.decreaseRefCount(e,r);const i=n[t].cache;if(i.has(r)){const e=i.get(r);if(e.refCount--,0===e.refCount){i.delete(r);for(let e=0;e<n.length;e++)n[e]&&n[e].cache.has(r)&&n[e].cache.delete(r);e.controller&&e.controller.abort()}return e.refCount}return 0}function Q(e,t,r){if(!V.has(e))return null==t?Y.getBlock(e,r):null;const n=V.get(e);if(null==n[t]){for(let e=0;e<n.length;e++)if(n[e]&&n[e].cache.has(r)){const t=n[e].cache.get(r);return t.refCount++,t.block}return Y.getBlock(e,r)}const i=n[t].cache;if(i.has(r)){const e=i.get(r);return e.refCount++,e.block}for(let e=0;e<n.length;e++)if(e!==t&&n[e]&&n[e]&&n[e].cache.has(r)){const t=n[e].cache.get(r);return t.refCount++,i.set(r,t),t.block}return null}function ee(e,t,r,n,i=null){if(!V.has(e))return void(null==t&&Y.putBlock(e,r,n,i));const s=V.get(e);if(null==s[t])return void Y.putBlock(e,r,n,i);const o={refCount:1,block:n,isResolved:!1,isRejected:!1,controller:i};n.then((()=>o.isResolved=!0)).catch((()=>o.isRejected=!0)),s[t].cache.set(r,o)}function te(e,t,r){if(!V.has(e))return void(null==t&&Y.deleteBlock(e,r));const n=V.get(e);null!=n[t]?n[t].cache.delete(r):Y.deleteBlock(e,r)}var re=r(75993),ne=r(55914);let ie=class extends((0,q.v)(U.wq)){constructor(){super(...arguments),this.rasterJobHandler=null,this.datasetName=null,this.datasetFormat=null,this.rasterInfo=null,this.ioConfig={sampling:"closest"}}async init(){const e=(0,$.zD)();this.addResolvingPromise(e),await this.when()}normalizeCtorArgs(e){return e&&e.ioConfig&&(e={...e,ioConfig:{resolution:null,bandIds:null,sampling:"closest",tileInfo:S.Z.create(),...e.ioConfig}}),e}set url(e){this._set("url",(0,I.Nm)(e,w.Z.getLogger(this.declaredClass)))}async open(e){throw new o.Z("BaseRaster:open-not-implemented","open() is not implemented")}async fetchTile(e,t,r,n={}){const i=n.tileInfo||this.rasterInfo.storageInfo.tileInfo,s=this.getTileExtentFromTileInfo(e,t,r,i);return this.fetchPixels(s,i.size[0],i.size[1],n)}async identify(e,t={}){t=this._getRequestOptionsWithSliceId(t);const{spatialReference:r,extent:n}=this.rasterInfo,{datumTransformation:i}=t;let s=(0,$.nF)(e,r,i);if(!n.intersects(s))return{location:s,value:null};if((0,a.pC)(this.rasterInfo.transform)){const e=this.rasterInfo.transform.inverseTransform(s);if(!this.rasterInfo.nativeExtent.intersects(e))return{location:e,value:null};s=e}let o=0;if(t.srcResolution)o=(0,$.kr)(t.srcResolution,this.rasterInfo,this.ioConfig.sampling).pyramidLevel;else if(o=await this.computeBestPyramidLevelForLocation(e,t),null==o)return{location:s,value:null};const l=this.identifyPixelLocation(s,o,null);if(null===l)return{location:s,value:null};const{row:c,col:u,rowOffset:f,colOffset:h}=l,d=X(this.url,t.sliceId),p=`${o}/${c}/${u}`;let m=Q(d,null,p);(0,a.Wi)(m)&&(m=this.fetchRawTile(o,c,u,t),ee(d,null,p,m));const y=await m;if((0,a.Wi)(y)||!y.pixels||0===y.pixels.length)return{location:s,value:null};const g=f*this.rasterInfo.storageInfo.blockHeight+h,x=!y.mask||y.mask[g]?y.pixels.map((e=>e[g])):null,w=this.rasterInfo.dataType;return("vector-magdir"===w||"vector-uv"===w)&&(null==x?void 0:x.length)>1?{location:s,value:x,magdirValue:"vector-magdir"===w?[x[0],x[1]]:(0,k.Tg)([x[0],x[1]]),pyramidLevel:o}:{location:s,value:x,pyramidLevel:o}}async fetchPixels(e,t,r,n={}){e=(0,$.kZ)(e);const i=(0,$.ut)(e.spatialReference),s=(0,$.Hq)(e),o=(0,$.ut)(this.rasterInfo.spatialReference),l=(0,a.pC)(o)&&this.rasterInfo.extent.width>=o/2;if(n=this._getRequestOptionsWithSliceId(n),(0,a.Wi)(i)||0===s||1===s&&l)return this._fetchPixels(e,t,r,n);if(s>=3)return{extent:e,pixelBlock:null};const c=[],{xmin:u,xmax:f}=e,h=Math.round(i/(f-u)*t),d=h-Math.round((i/2-u)/(f-u)*t);let p=0;const m=[];for(let o=0;o<=s;o++){const a=new O.Z({xmin:0===o?u:-i/2,xmax:o===s?f-i*o:i/2,ymin:e.ymin,ymax:e.ymax,spatialReference:e.spatialReference}),l=0===o?h-d:o===s?t-p:h;p+=l,m.push(l);const y=this._fetchPixels(a,l,r,n);c.push(y)}const y=(await Promise.all(c)).map((e=>null==e?void 0:e.pixelBlock));let g=null;const x={width:t,height:r};return g=this.rasterJobHandler?await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:y,srcMosaicSize:x,destDimension:null,coefs:null,sampleSpacing:null,interpolation:"nearest",alignmentInfo:null,blockWidths:m},n):(0,ne.us)(y,x,{blockWidths:m}),{extent:e,srcExtent:(0,$.tB)(e,this.rasterInfo.spatialReference,n.datumTransformation),pixelBlock:g}}async fetchRawPixels(e,t,r,n){const{origin:i,blockBoundary:s}=this.rasterInfo.storageInfo,{blockWidth:o,blockHeight:l}=this.getBlockWidthHeight(e);let{x:c,y:u}=t,{width:f,height:h,wrapCount:d}=r;const p=(0,a.Wg)(this._getRasterTileAlignmentInfo(e,0));n.buffer&&(c-=n.buffer.cols,u-=n.buffer.rows,f+=2*n.buffer.cols,h+=2*n.buffer.rows);const m=Math.floor(c/o),y=Math.floor(u/l),g=Math.floor((c+f-1)/o),x=Math.floor((u+h-1)/l),w=s[e];if(!w)return null;const{minRow:v,minCol:b,maxCol:I,maxRow:_}=w;if(0===d&&(x<v||g<b||y>_||m>I))return null;const C=new Array;let R=!1;const S=null==this.ioConfig.allowPartialFill?n.allowPartialFill:this.ioConfig.allowPartialFill;for(let t=y;t<=x;t++)for(let r=m;r<=g;r++){const i=0===d||null==p||r<p.worldColumnCountFromOrigin?r:r%p.worldColumnCountFromOrigin-p.originColumnOffset;if(t>=v&&i>=b&&_>=t&&I>=i){const r=this._fetchRawTile(e,t,i,n);S?C.push(new Promise((e=>{r.then((t=>e(t))).catch((()=>{R=!0,e(null)}))}))):C.push(r)}else C.push(null)}if(0===C.length)return null;const k=await Promise.all(C),T={height:(x-y+1)*l,width:(g-m+1)*o},{spatialReference:M}=this.rasterInfo,P=this.getPyramidPixelSize(e),{x:F,y:E}=P;return{extent:new O.Z({xmin:i.x+m*o*F,xmax:i.x+(g+1)*o*F,ymin:i.y-(x+1)*l*E,ymax:i.y-y*l*E,spatialReference:M}),pixelBlocks:k,mosaicSize:T,isPartiallyFilled:R}}fetchRawTile(e,t,r,n){throw new o.Z("BaseRaster:read-not-implemented","fetchRawTile() is not implemented")}computeExtent(e){return(0,$.tB)(this.rasterInfo.extent,e)}decodePixelBlock(e,t){return!this.rasterJobHandler||t.useCanvas?(0,re.Jx)(e,t):this.rasterJobHandler.decode({data:e,options:t})}async request(e,t,r){var n,i;const{customFetchParameters:s}=this.ioConfig,{range:o,query:a,headers:l}=t;r=null!=(n=null!=(i=r)?i:t.retryCount)?n:this.ioConfig.retryCount;const c=o?{Range:`bytes=${o.from}-${o.to}`}:null;try{return await(0,x.default)(e,{...t,query:{...a,...s},headers:{...l,...c}})}catch(n){if(r>0)return r--,this.request(e,t,r);throw n}}getSliceIndex(e){const{multidimensionalInfo:t}=this.rasterInfo;if(!(0,a.pC)(t))return null;if(!(0,a.pC)(e)||0===e.length)return null;let r=0;const n=e[0].variableName;for(let i=0;i<t.variables.length;i++){const s=t.variables[i],o=s.dimensions;if(s.name!==n){r+=o.map((e=>this._getDimensionValuesCount(e))).reduce(((e,t)=>e+t));break}const a=o.map((e=>this._getDimensionValuesCount(e))),l=o.length;for(let t=0;t<l;t++){const n=e.filter((e=>e.dimensionName===o[t].name))[0];if(null==n)return null;const i=Array.isArray(n.values[0])?n.values[0][0]:n.values[0],s=this._getIndexFromDimensions(i,o[t]);if(-1===s)return null;a.shift(),r+=t===l-1?s:s*a.reduce(((e,t)=>e+t))}}return r}getTileExtentFromTileInfo(e,t,r,n){const i=n.lodAt(e);return this.getTileExtent({x:i.resolution,y:i.resolution},t,r,n.origin,n.spatialReference,n.size)}updateTileInfo(){const{storageInfo:e,spatialReference:t,extent:r,pixelSize:n}=this.rasterInfo;if(!e.tileInfo){const i=[],s=e.maximumPyramidLevel||0;let o=Math.max(n.x,n.y),a=1/.0254*96*o;for(let e=0;e<=s;e++)i.push({level:s-e,resolution:o,scale:a}),o*=2,a*=2;const l=new G.Z({x:r.xmin,y:r.ymax,spatialReference:t});e.tileInfo=new S.Z({origin:l,size:[e.blockWidth,e.blockHeight],spatialReference:t,lods:i}),e.isVirtualTileInfo=!0}}createRemoteDatasetStorageInfo(e,t=512,r=512,n){const{width:i,height:s,nativeExtent:o,pixelSize:a,spatialReference:l}=e,c=new G.Z({x:o.xmin,y:o.ymax,spatialReference:l});null==n&&(n=Math.max(0,Math.round(Math.log(Math.max(i,s))/Math.LN2-8)));const u=this.computeBlockBoundary(o,512,512,{x:o.xmin,y:o.ymax},[a],n);e.storageInfo=new j.Z({blockWidth:t,blockHeight:r,pyramidBlockWidth:t,pyramidBlockHeight:r,origin:c,firstPyramidLevel:1,maximumPyramidLevel:n,blockBoundary:u})}async computeBestPyramidLevelForLocation(e,t={}){return 0}computeBlockBoundary(e,t,r,n,i,s=0,o=2){if(1===i.length&&s>0){i=[...i];let{x:e,y:t}=i[0];for(let r=0;r<s;r++)e*=o,t*=o,i.push({x:e,y:t})}const a=[],{x:l,y:c}=n;for(let n=0;n<i.length;n++){const{x:s,y:o}=i[n];a.push({minCol:Math.floor((e.xmin-l+.1*s)/t/s),maxCol:Math.floor((e.xmax-l-.1*s)/t/s),minRow:Math.floor((c-e.ymax+.1*o)/r/o),maxRow:Math.floor((c-e.ymin-.1*o)/r/o)})}return a}getPyramidPixelSize(e){const{nativePixelSize:t}=this.rasterInfo,{pyramidResolutions:r,pyramidScalingFactor:n}=this.rasterInfo.storageInfo;if(0===e)return t;if((0,a.pC)(r)&&r.length)return r[e-1];const i=n**e;return{x:t.x*i,y:t.y*i}}identifyPixelLocation(e,t,r){const{spatialReference:n,nativeExtent:i}=this.rasterInfo,{blockWidth:s,blockHeight:o,maximumPyramidLevel:a,origin:l}=this.rasterInfo.storageInfo,c=(0,$.nF)(e,n,r);if(!i.intersects(c))return null;if(t<0||t>a)return null;const u=this.getPyramidPixelSize(t),{x:f,y:h}=u,d=(l.y-c.y)/h/o,p=(c.x-l.x)/f/s,m=Math.min(o-1,Math.floor((d-Math.floor(d))*o)),y=Math.min(s-1,Math.floor((p-Math.floor(p))*s));return{pyramidLevel:t,row:Math.floor(d),col:Math.floor(p),rowOffset:m,colOffset:y,srcLocation:c}}getTileExtent(e,t,r,n,i,s){const[o,a]=s,l=n.x+r*o*e.x,c=l+o*e.x,u=n.y-t*a*e.y,f=u-a*e.y;return new O.Z({xmin:l,xmax:c,ymin:f,ymax:u,spatialReference:i})}getBlockWidthHeight(e){return{blockWidth:e>0?this.rasterInfo.storageInfo.pyramidBlockWidth:this.rasterInfo.storageInfo.blockWidth,blockHeight:e>0?this.rasterInfo.storageInfo.pyramidBlockHeight:this.rasterInfo.storageInfo.blockHeight}}isBlockOutside(e,t,r){const n=this.rasterInfo.storageInfo.blockBoundary[e];return!n||n.maxRow<t||n.maxCol<r||n.minRow>t||n.minCol>r}async _fetchPixels(e,t,r,n={}){const i=(0,$.Hq)(e);if(i>=2)return{extent:e,pixelBlock:null};const s=this._getSourceDataInfo(e,t,r,n),{pyramidLevel:o,pyramidResolution:l,srcResolution:c,srcExtent:u,srcWidth:f,srcHeight:h}=s;if(0===f||0===h)return{extent:e,srcExtent:u,pixelBlock:null};const d=this.rasterInfo.storageInfo,p={x:Math.floor((u.xmin-d.origin.x)/l.x+.1),y:Math.floor((d.origin.y-u.ymax)/l.y+.1)},m=await this.fetchRawPixels(o,p,{width:f,height:h,wrapCount:i},n);if(!m)return{extent:e,srcExtent:u,pixelBlock:null};const y=o>0?d.pyramidBlockWidth:d.blockWidth,g=o>0?d.pyramidBlockHeight:d.blockHeight,x=y===f&&g===h&&p.x%y==0&&p.y%g==0,w=new G.Z({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/r,spatialReference:e.spatialReference}),v=!e.spatialReference.equals(this.rasterInfo.spatialReference),{datumTransformation:b}=n;if(!v&&x&&1===m.pixelBlocks.length&&y===t&&g===r&&c.x===w.x&&c.y===w.y)return{extent:e,srcExtent:u,pixelBlock:m.pixelBlocks[0]};const I=(0,a.Wg)(this.rasterInfo.transform),_=this.rasterJobHandler?await this.rasterJobHandler.getProjectionOffsetGrid({projectedExtent:e,srcBufferExtent:m.extent,pixelSize:w.toJSON(),datumTransformation:b,rasterTransform:I,hasWrapAround:i>0,isAdaptive:!1!==this.ioConfig.optimizeProjectionAccuracy},n):(0,$.Qp)({projectedExtent:e,srcBufferExtent:m.extent,pixelSize:w,datumTransformation:b,rasterTransform:I,hasWrapAround:i>0,isAdaptive:!1});let C;const R=!n.requestRawData,S={rows:_.spacing[0],cols:_.spacing[1]},k=(0,a.Wg)(this._getRasterTileAlignmentInfo(o,m.extent.xmin)),{pixelBlocks:T,mosaicSize:M,isPartiallyFilled:P}=m;if(this.rasterJobHandler)C=await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:T,srcMosaicSize:M,destDimension:R?{width:t,height:r}:null,coefs:R?_.coefficients:null,sampleSpacing:R?S:null,interpolation:n.interpolation,alignmentInfo:k,blockWidths:null},n);else{const e=(0,ne.us)(T,M,{alignmentInfo:k});C=R?(0,ne.Uk)(e,{width:t,height:r},_.coefficients,S,n.interpolation):e}return n.requestRawData?{srcExtent:u,pixelBlock:C,transformGrid:_,extent:e,isPartiallyFilled:P}:{srcExtent:u,extent:e,pixelBlock:C}}_fetchRawTile(e,t,r,n){const i=this.rasterInfo.storageInfo.blockBoundary[e];if(!i)return Promise.resolve(null);const{minRow:s,minCol:o,maxCol:l,maxRow:u}=i;if(t<s||r<o||t>u||r>l)return Promise.resolve(null);const f=X(this.url,n.sliceId),h=`${e}/${t}/${r}`;let d=Q(f,n.registryId,h);if((0,a.Wi)(d)){const i=new AbortController;d=this.fetchRawTile(e,t,r,{...n,signal:i.signal}),ee(f,n.registryId,h,d,i),d.catch((()=>te(f,n.registryId,h)))}return n.signal&&(0,c.fu)(n,(()=>{K(f,n.registryId,h)})),d}_getIndexFromDimensions(e,t){const{extent:r,interval:n,unit:i,values:s}=t;if(null!=s&&s.length)return Array.isArray(s[0])?s.findIndex((t=>t[0]<=e&&t[1]>=e)):s.indexOf(e);if(e>r[1])return-1;const o=r[0];let a=-1;if("ISO8601"===i){var l;switch((null==(l=t.intervalUnit)?void 0:l.toLowerCase())||"seconds"){case"seconds":a=Math.round((e-o)/1e3/n);break;case"minutes":a=Math.round((e-o)/6e4/n);break;case"hours":a=Math.round((e-o)/36e5/n);break;case"days":a=Math.round((e-o)/864e5/n);break;case"years":a=Math.round((new Date(e).getUTCFullYear()-new Date(o).getUTCFullYear())/n);break;case"decades":a=Math.round((new Date(e).getUTCFullYear()-new Date(o).getUTCFullYear())/10/n)}return a}return Math.round((e-o)/n)}_getDimensionValuesCount(e){const{extent:t,interval:r,unit:n,values:i}=e;let s=(null==i?void 0:i.length)||0;if(s)return s;const o=t[0];if(0===s&&"ISO8601"===n){var a;switch((null==(a=e.intervalUnit)?void 0:a.toLowerCase())||"seconds"){case"seconds":s=Math.round((t[1]-t[0])/1e3/r);break;case"minutes":s=Math.round((t[1]-t[0])/6e4/r);break;case"hours":s=Math.round((t[1]-t[0])/36e5/r);break;case"days":s=Math.round((t[1]-t[0])/864e5/r);break;case"years":s=Math.round((new Date(t[1]).getUTCFullYear()-new Date(o).getUTCFullYear())/r);break;case"decades":s=Math.round((new Date(t[1]).getUTCFullYear()-new Date(o).getUTCFullYear())/10/r)}return s}return Math.round((t[1]-t[0])/r)}_getRasterTileAlignmentInfo(e,t){return null==this._rasterTileAlighmentInfo&&(this._rasterTileAlighmentInfo=(0,$.P_)(this.rasterInfo)),(0,a.pC)(this._rasterTileAlighmentInfo.pyramidsInfo)?{startX:t,halfWorldWidth:this._rasterTileAlighmentInfo.halfWorldWidth,hasGCSSShiftTransform:this._rasterTileAlighmentInfo.hasGCSSShiftTransform,...this._rasterTileAlighmentInfo.pyramidsInfo[e]}:null}_getSourceDataInfo(e,t,r,n={}){const i={datumTransformation:n.datumTransformation,pyramidLevel:0,pyramidResolution:null,srcExtent:null,srcHeight:0,srcResolution:null,srcWidth:0};n.srcResolution&&(i.srcResolution=n.srcResolution,this._updateSourceDataInfo(e,i));const s=this.rasterInfo.storageInfo.maximumPyramidLevel||0,{srcWidth:o,srcHeight:a,pyramidLevel:l}=i,c=o/t,u=a/r,f=l<s&&c*u>=16;if(f||l===s&&(c>8||u>8)||0===o||0===a){const o=new G.Z({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/r,spatialReference:e.spatialReference});let a=(0,$.VO)(o,this.rasterInfo.spatialReference,e,i.datumTransformation);const h=!a||n.srcResolution&&a.x+a.y<n.srcResolution.x+n.srcResolution.y;if(f&&n.srcResolution&&h){const e=Math.round(Math.log(Math.max(c,u))/Math.LN2)-1;if(s-l+3>=e){const t=2**e;a={x:n.srcResolution.x*t,y:n.srcResolution.y*t}}}a&&(i.srcResolution=a,this._updateSourceDataInfo(e,i))}return(i.srcWidth/t>8||i.srcHeight/r>8)&&(i.srcWidth=0,i.srcHeight=0),i}_updateSourceDataInfo(e,t){t.srcWidth=0,t.srcHeight=0;const r=this.rasterInfo.spatialReference,{srcResolution:n,datumTransformation:i}=t,{pyramidLevel:s,pyramidResolution:o,excessiveReading:l}=(0,$.kr)(n,this.rasterInfo,this.ioConfig.sampling);if(l)return;let c=t.srcExtent||(0,$.tB)(e,r,i);if(null==c)return;const u=(0,a.Wg)(this.rasterInfo.transform);u&&(c=u.inverseTransform(c)),t.srcExtent=c;const f=Math.ceil((c.xmax-c.xmin)/o.x-.1),h=Math.ceil((c.ymax-c.ymin)/o.y-.1);t.pyramidLevel=s,t.pyramidResolution=o,t.srcWidth=f,t.srcHeight=h}_getRequestOptionsWithSliceId(e){return(0,a.pC)(this.rasterInfo.multidimensionalInfo)&&null==e.sliceId&&(e={...e,sliceId:this.getSliceIndex(e.multidimensionalDefinition)}),e}};(0,n._)([(0,u.Cb)()],ie.prototype,"_rasterTileAlighmentInfo",void 0),(0,n._)([(0,u.Cb)(_.HQ)],ie.prototype,"url",null),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],ie.prototype,"datasetName",void 0),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],ie.prototype,"datasetFormat",void 0),(0,n._)([(0,u.Cb)()],ie.prototype,"rasterInfo",void 0),(0,n._)([(0,u.Cb)()],ie.prototype,"ioConfig",void 0),(0,n._)([(0,u.Cb)()],ie.prototype,"sourceJSON",void 0),ie=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.BaseRaster")],ie);const se=ie;var oe=r(20095);function ae(e){const t=e.fields,r=e.records,n=t.some((e=>"oid"===e.name.toLowerCase()))?"OBJECTID":"OID",i=[{name:n,type:"esriFieldTypeOID",alias:"OID"}].concat(t.map((e=>({name:e.name,type:"esriFieldType"+e.typeName,alias:e.name})))),s=i.map((e=>e.name)),o=[];let a=0,l=0;return r.forEach((e=>{const t={};for(t[n]=a++,l=1;l<s.length;l++)t[s[l]]=e[l-1];o.push({attributes:t})})),{displayFieldName:"",fields:i,features:o}}var le=r(87521),ce=r(74889);const ue=new Map;ue.set("int16","esriFieldTypeSmallInteger"),ue.set("int32","esriFieldTypeInteger"),ue.set("int64","esriFieldTypeInteger"),ue.set("float32","esriFieldTypeSingle"),ue.set("float64","esriFieldTypeDouble"),ue.set("text","esriFieldTypeString");let fe=class extends se{constructor(){super(...arguments),this.storageInfo=null,this.datasetFormat="CRF"}async open(e){await this.init();const{data:t}=await this.request(this.url+"/conf.json",{signal:null==e?void 0:e.signal});if(!this._validateHeader(t))throw new o.Z("cloudraster:open","Invalid or unsupported conf.json.");this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);const{storageInfo:r,rasterInfo:n}=this._parseHeader(t);if("thematic"===n.dataType){const e=await this._fetchAuxiliaryInformation();n.attributeTable=e}this._set("storageInfo",r),this._set("rasterInfo",n),this.ioConfig.retryCount=this.ioConfig.retryCount||0}async fetchRawTile(e,t,r,n={}){const i=this.rasterInfo.storageInfo.maximumPyramidLevel-e;if(i<0)return null;const s=this._buildCacheFilePath(i,t,r,n.multidimensionalDefinition),o=this._getIndexRecordFromBundle(t,r),a=await this.request(s,{range:{from:0,to:this.storageInfo.headerSize-1},responseType:"array-buffer",signal:n.signal});if(!a)return null;const l=new Uint8Array(a.data),c=this._getTileEndAndContentType(l,o);if(0===c.recordSize)return null;const u=await this.request(s,{range:{from:c.position,to:c.position+c.recordSize},responseType:"array-buffer",signal:n.signal});return u?this.decodePixelBlock(u.data,{width:this.rasterInfo.storageInfo.tileInfo.size[0],height:this.rasterInfo.storageInfo.tileInfo.size[1],planes:null,pixelType:null}):null}_validateHeader(e){return e&&"RasterInfo"===e.type&&!["origin","extent","geodataXform","LODInfos","blockWidth","blockHeight","bandCount","pixelType","pixelSizeX","pixelSizeY","format","packetSize"].some((t=>!e[t]))}_parseHeader(e){var t,r;const n=["u1","u2","u4","u8","s8","u16","s16","u32","s32","f32","f64"][e.pixelType],{bandCount:i,histograms:s,colormap:o,blockWidth:a,blockHeight:l,firstPyramidLevel:c,maximumPyramidLevel:u}=e,f=e.statistics&&e.statistics.map((e=>({min:e.min,max:e.max,avg:e.mean,stddev:e.standardDeviation,median:e.median,mode:e.mode}))),h=e.extent.spatialReference,d=null==(t=e.geodataXform)?void 0:t.spatialReference,p=new F.Z(null!=h&&h.wkid||null!=h&&h.wkt?h:d);let m=new O.Z({xmin:e.extent.xmin,ymin:e.extent.ymin,xmax:e.extent.xmax,ymax:e.extent.ymax,spatialReference:p});const y=new G.Z({x:e.pixelSizeX,y:e.pixelSizeY,spatialReference:p}),g=Math.round((m.xmax-m.xmin)/y.x),x=Math.round((m.ymax-m.ymin)/y.y),w=this._parseTransform(e.geodataXform),v=w?m:null;w&&(m=w.forwardTransform(m),y.x=(m.xmax-m.xmin)/g,y.y=(m.ymax-m.ymin)/x);const b=null!=(r=e.properties)?r:{},I=e.format.toLowerCase().replace("cache/",""),_=new G.Z(e.origin.x,e.origin.y,p);let C,R,k,T;if(o&&o.colors)for(C=[],R=0;R<o.colors.length;R++)k=o.colors[R],T=o.values?o.values[R]:R,C.push([T,255&k,k<<16>>>24,k<<8>>>24,k>>>24]);const M=e.LODInfos,P=[];for(R=0;R<M.levels.length;R++)P.push({level:M.levels[R],resolution:M.resolutions[R],scale:96/.0254*M.resolutions[R]});const E=new S.Z({dpi:96,lods:P,format:I,origin:_,size:[a,l],spatialReference:p}),N={recordSize:8,packetSize:e.packetSize,headerSize:e.packetSize*e.packetSize*8+64},B=[{maxCol:Math.ceil(g/a)-1,maxRow:Math.ceil(x/l)-1,minCol:0,minRow:0}];let Z=2;if(u>0)for(R=0;R<u;R++)B.push({maxCol:Math.ceil(g/Z/a)-1,maxRow:Math.ceil(x/Z/l)-1,minCol:0,minRow:0}),Z*=2;const D=e.mdInfo;return{storageInfo:N,rasterInfo:new W.Z({width:g,height:x,pixelType:n,bandCount:i,extent:m,nativeExtent:v,transform:w,spatialReference:p,pixelSize:y,keyProperties:b,statistics:f,histograms:s,multidimensionalInfo:D,colormap:C,storageInfo:new j.Z({blockWidth:a,blockHeight:l,pyramidBlockWidth:a,pyramidBlockHeight:l,origin:_,tileInfo:E,firstPyramidLevel:c,maximumPyramidLevel:u,blockBoundary:B})})}}_parseTransform(e){var t,r;if(!(0,le.j)(e))throw new o.Z("cloudraster:open","the data contains unsupported geodata transform types");const n=(0,le.c)(e);if("identity"===n.type)return null;if("polynomial"!==n.type||null==(t=n.forwardCoefficients)||!t.length||null==(r=n.inverseCoefficients)||!r.length)throw new o.Z("cloudraster:open","the data contains unsupported geodata transforms - both forward and inverse coefficients are required currently");return n}async _fetchAuxiliaryInformation(e){const t=this.request(this.url+"/conf.vat.json",{signal:e}).then((e=>e.data)).catch((()=>null)),r=this.request(this.url+"/conf.vat.dbf",{responseType:"array-buffer",signal:e}).then((e=>e.data)).catch((()=>null)),n=await Promise.all([t,r]);let i;if(n[0]){let e=n[0].fields;const t=n[0].values;if(e&&t){e=e.map((e=>({type:"OID"===e.name?"esriFieldTypeOID":ue.get(e.type),name:e.name,alias:e.alias||e.name})));const r=t.map((e=>({attributes:e})));e&&t&&(i={fields:e,features:r})}}return!i&&n[1]&&(i=class{static get supportedVersions(){return[5]}static parse(e){const t=new DataView(e),r=3&t.getUint8(0);if(3!==r)return{header:{version:r},recordSet:null};const n=t.getUint32(4,!0),i=t.getUint16(8,!0),s=t.getUint16(10,!0),o={version:r,recordCount:n,headerByteCount:i,recordByteCount:s};let a=32;const l=[],c=[];let u;if(3===r){for(;13!==t.getUint8(a);)u=String.fromCharCode(t.getUint8(a+11)).trim(),l.push({name:(0,oe.f)(new Uint8Array(e,a,11)),type:u,typeName:["String","Date","Double","Boolean","String","Integer"][["C","D","F","L","M","N"].indexOf(u)],length:t.getUint8(a+16)}),a+=32;if(a+=1,l.length>0)for(;c.length<n&&e.byteLength-a>s;){const r=[];32===t.getUint8(a)?(a+=1,l.forEach((t=>{if("C"===t.type)r.push((0,oe.f)(new Uint8Array(e,a,t.length)).trim());else if("N"===t.type)r.push(parseInt(String.fromCharCode.apply(null,new Uint8Array(e,a,t.length)).trim(),10));else if("F"===t.type)r.push(parseFloat(String.fromCharCode.apply(null,new Uint8Array(e,a,t.length)).trim()));else if("D"===t.type){const n=String.fromCharCode.apply(null,new Uint8Array(e,a,t.length)).trim();r.push(new Date(parseInt(n.substring(0,4),10),parseInt(n.substring(4,6),10)-1,parseInt(n.substring(6,8),10)))}a+=t.length})),c.push(r)):a+=s}}return{header:o,fields:l,records:c,recordSet:ae({fields:l,records:c})}}}.parse(n[1]).recordSet),ce.default.fromJSON(i)}_buildCacheFilePath(e,t,r,n){const i=this.storageInfo.packetSize,s=Math.floor(t/i)*i,o=Math.floor(r/i)*i,l="R"+this._toHexString4(s)+"C"+this._toHexString4(o);let c="L";c+=e>=10?e.toString():"0"+e.toString();const{multidimensionalInfo:u}=this.rasterInfo,f=null==n?void 0:n[0];if(!(0,a.pC)(u)||!f)return`${this.url}/_alllayers/${c}/${l}.bundle`;let h=u.variables.filter((e=>e.name===f.variableName))[0].dimensions[0].values.indexOf(f.values[0]).toString(16);const d=4-h.length;for(let e=0;e<d;e++)h="0"+h;return h="S"+h,`${this.url}/_alllayers/${f.variableName}/${h}/${c}/${l}.bundle`}_getIndexRecordFromBundle(e,t){const r=this.storageInfo.packetSize,n=r*(e%r)+t%r;if(n<0)throw"Invalid level / row / col";return 20+n*this.storageInfo.recordSize+44}_getTileEndAndContentType(e,t){const r=e.subarray(t,t+8);let n,i=0;for(n=0;n<5;n++)i|=(255&r[n])<<8*n;const s=0xffffffffff&i;for(i=0,n=5;n<8;n++)i|=(255&r[n])<<8*(n-5);return{position:s,recordSize:0xffffffffff&i}}_toHexString4(e){let t=e.toString(16);if(4!==t.length){let e=4-t.length;for(;e-- >0;)t="0"+t}return t}};(0,n._)([(0,u.Cb)({readOnly:!0})],fe.prototype,"storageInfo",void 0),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],fe.prototype,"datasetFormat",void 0),fe=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.CloudRaster")],fe);const he=fe;let de=class extends se{constructor(){super(...arguments),this.datasetFormat="MEMORY"}async open(e){var t;await this.init();const{pixelBlock:r,statistics:n,histograms:i,name:s,keyProperties:o,nativeExtent:a,transform:l}=this.data,{width:c,height:u,pixelType:f}=r,h=this.data.extent||new O.Z({xmin:-.5,ymin:.5,xmax:c-.5,ymax:u-.5,spatialReference:new F.Z({wkid:3857})}),d=null!=(t=this.data.isPseudoSpatialReference)?t:!this.data.extent,p={x:h.width/c,y:h.height/u},m=new W.Z({width:c,height:u,pixelType:f,extent:h,nativeExtent:a,transform:l,pixelSize:p,spatialReference:h.spatialReference,bandCount:3,keyProperties:o||{},statistics:n,isPseudoSpatialReference:d,histograms:i});this.createRemoteDatasetStorageInfo(m,512,512),this._set("rasterInfo",m),this.updateTileInfo(),await this._buildInMemoryRaster(r,{width:512,height:512},e),this.datasetName=s,this.url="/InMemory/"+s}fetchRawTile(e,t,r,n={}){const i=this._pixelBlockTiles.get(`${e}/${t}/${r}`);return Promise.resolve(i)}async _buildInMemoryRaster(e,t,r){const n=this.rasterInfo.storageInfo.maximumPyramidLevel,i=this.rasterJobHandler?this.rasterJobHandler.split({pixelBlock:e,tileSize:t,maximumPyramidLevel:n},r):Promise.resolve((0,ne.Vl)(e,t,n)),s=(0,a.pC)(this.rasterInfo.statistics),l=(0,a.pC)(this.rasterInfo.histograms),u=s&&l?Promise.resolve({statistics:null,histograms:null}):this.rasterJobHandler?this.rasterJobHandler.estimateStatisticsHistograms({pixelBlock:e},r):Promise.resolve((0,ne.Hv)(e)),f=await(0,c.as)([i,u]);if(!f[0].value&&f[1].value)throw new o.Z("inmemory-raster:open","failed to build in memory raster");var h,d;this._pixelBlockTiles=f[0].value,s||(this.rasterInfo.statistics=null==(h=f[1].value)?void 0:h.statistics),l&&(this.rasterInfo.histograms=null==(d=f[1].value)?void 0:d.histograms)}};(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],de.prototype,"datasetFormat",void 0),(0,n._)([(0,u.Cb)()],de.prototype,"data",void 0),de=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.InMemoryRaster")],de);const pe=de;function me(e,t){if(!e||!t)return[];let r=t;t.indexOf("/")>-1?(r=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";const n=[];if(t){const i=me(e,r);for(let e=0;e<i.length;e++)me(i[e],t).forEach((e=>n.push(e)));return n}const i=e.getElementsByTagNameNS("*",r);if(!i||0===i.length)return[];for(let e=0;e<i.length;e++)n.push(i[e]||i.item[e]);return n}function ye(e,t){if(!e||!t)return null;let r=t;t.indexOf("/")>-1?(r=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";const n=me(e,r);return n.length>0?t?ye(n[0],t):n[0]:null}function ge(e,t=null){const r=t?ye(e,t):e;let n;return r?(n=r.textContent||r.nodeValue,n?n.trim():null):null}function xe(e,t){return function(e,t){const r=me(e,t),n=[];let i;for(let e=0;e<r.length;e++)i=r[e].textContent||r[e].nodeValue,i&&(i=i.trim(),""!==i&&n.push(i));return n}(e,t).map((e=>Number(e)))}function we(e,t){const r=ge(e,t);return Number(r)}function ve(e,t){var r;const n=null==e||null==(r=e.nodeName)?void 0:r.toLowerCase(),i=t.toLowerCase();return n.slice(n.lastIndexOf(":")+1)===i}var be=r(87390);function Ie(e,t){if(!e||!t)return null;const r=[];for(let n=0;n<e.length;n++)r.push(e[n]),r.push(t[n]);return r}function _e(e){if(!e)return null;let t=Number(e);if(!isNaN(t)&&0!==t)return new F.Z({wkid:t});if((e=String(e)).startsWith("COMPD_CS")){if(!e.includes("VERTCS")||!e.includes("GEOGCS")&&!e.startsWith("PROJCS"))return null;const r=e.indexOf("VERTCS"),n=e.indexOf("PROJCS"),i=n>-1?n:e.indexOf("GEOGCS");if(-1===i)return null;const s=e.slice(i,e.lastIndexOf("]",r)+1).trim(),o=e.slice(r,e.lastIndexOf("]")).trim();t=Ce(s);const a=new F.Z(t?{wkid:t}:{wkt:s}),l=Ce(o);return l&&(a.vcsWkid=l),a}return e.startsWith("GEOGCS")||e.startsWith("PROJCS")?(t=Ce(e),new F.Z(0!==t?{wkid:t}:{wkt:e})):null}function Ce(e){var t;const r=e.replace(/\]/g,"[").replace(/\"/g,"").split("[").map((e=>e.trim())).filter((e=>""!==e)),n=r[r.length-1].split(","),i=null==(t=n[0])?void 0:t.toLowerCase();if(("epsg"===i||"esri"===i)&&e.endsWith('"]]')){const e=Number(n[1]);if(!isNaN(e)&&0!==e)return e}return 0}function Re(e){var t;if("pamdataset"!==(null==e||null==(t=e.documentElement.tagName)?void 0:t.toLowerCase()))return{};const r={spatialReference:null,transform:null,metadata:{},rasterBands:[],statistics:null,histograms:null};e.documentElement.childNodes.forEach((e=>{if(1===e.nodeType)if(ve(e,"SRS")){if(!r.spatialReference){const t=ge(e);r.spatialReference=_e(t)}}else if(ve(e,"Metadata"))if("xml:ESRI"===e.getAttribute("domain")){const{spatialReference:t,transform:n}=function(e){var t;const r=ye(e,"GeodataXform"),n=_e(we(r,"SpatialReference/WKID")||ge(r,"SpatialReference/WKT"));if("typens:PolynomialXform"!==r.getAttribute("xsi:type"))return{spatialReference:n,transform:null};const i=null!=(t=we(r,"PolynomialOrder"))?t:1,s=xe(r,"CoeffX/Double"),o=xe(r,"CoeffY/Double"),a=xe(r,"InverseCoeffX/Double"),l=xe(r,"InverseCoeffY/Double"),c=Ie(s,o),u=Ie(a,l);return{spatialReference:n,transform:new be.Z({spatialReference:n,polynomialOrder:i,forwardCoefficients:c,inverseCoefficients:u})}}(e);r.transform=n,r.spatialReference||(r.spatialReference=t)}else me(e,"MDI").forEach((e=>r.metadata[e.getAttribute("key")]=ge(e)));else if(ve(e,"PAMRasterBand")){const t=function(e){var t;const r=we(e,"NoDataValue"),n=ye(e,"Histograms/HistItem"),i=we(n,"HistMin"),s=we(n,"HistMax"),o=we(n,"BucketCount"),a=null==(t=ge(n,"HistCounts"))?void 0:t.split("|").map((e=>Number(e)));let l,c,u,f;me(e,"Metadata/MDI").forEach((e=>{var t;const r=Number(null!=(t=e.textContent)?t:e.nodeValue);switch(e.getAttribute("key").toUpperCase()){case"STATISTICS_MINIMUM":l=r;break;case"STATISTICS_MAXIMUM":c=r;break;case"STATISTICS_MEAN":u=r;break;case"STATISTICS_STDDEV":f=r}}));const h=we(e,"Metadata/SourceBandIndex");return{noDataValue:r,histogram:null!=a&&a.length&&null!=l&&null!=c?{min:i,max:s,size:o||a.length,counts:a}:null,sourceBandIndex:h,statistics:null!=l&&null!=c?{min:l,max:c,avg:u,stddev:f}:null}}(e);null!=t.sourceBandIndex&&null==r.rasterBands[t.sourceBandIndex]?r.rasterBands[t.sourceBandIndex]=t:r.rasterBands.push(t)}}));const n=r.rasterBands;if(n){const e=!!n[0].statistics;r.statistics=e?n.map((e=>e.statistics)):null;const t=!!n[0].histogram;r.histograms=t?n.map((e=>e.histogram)):null}return r}let Se=class extends se{async open(e){await this.init();const t=await this._fetchData(e);let{spatialReference:r,statistics:n,histograms:i,transform:s}=await this._fetchAuxiliaryData(e);const o=!r;o&&(r=new F.Z({wkid:3857})),null!=i&&i.length&&null==n&&(n=(0,ne.Oh)(i));const{width:a,height:l}=t;let c=new O.Z({xmin:-.5,ymin:.5-l,xmax:a-.5,ymax:.5,spatialReference:r});const u=s?s.forwardTransform(c):c;let f=!0;if(s){const e=s.forwardCoefficients;f=e&&0===e[1]&&0===e[2],f&&(s=null,c=u)}const h=new pe({data:{extent:u,nativeExtent:c,transform:s,pixelBlock:t,statistics:n,histograms:i,keyProperties:{DateType:"Processed"},isPseudoSpatialReference:o}});await h.open(),this._set("rasterInfo",h.rasterInfo),this._inMemoryRaster=h}fetchRawTile(e,t,r,n={}){return this._inMemoryRaster.fetchRawTile(e,t,r,n)}async _fetchData(e){const{data:t}=await this.request(this.url,{responseType:"array-buffer",signal:null==e?void 0:e.signal}),r=(0,re.y6)(t).toUpperCase();if("JPG"!==r&&"PNG"!==r&&"GIF"!==r&&"BMP"!==r)throw new o.Z("image-aux-raster:open","the data is not a supported format");return this._set("datasetFormat",r),await this.decodePixelBlock(t,{format:"jpg",width:1,height:1,useCanvas:!0})}async _fetchAuxiliaryData(e){var t,r;const n=(0,a.Wg)(null==e?void 0:e.signal),i=null!=(t=this.ioConfig.skipExtensions)?t:[],s=i.indexOf("aux.xml")>-1?null:this.request(this.url+".aux.xml",{responseType:"xml",signal:n}),o=this.datasetFormat,l="JPG"===o?"jgw":"PNG"===o?"pgw":"BMP"===o?"bpw":null,u=i.indexOf(l)>-1?null:this.request(this.url.slice(0,this.url.lastIndexOf("."))+"."+l,{responseType:"text",signal:n}),f=await(0,c.as)([s,u]);if(null!=n&&n.aborted)throw(0,c.zE)();const h=Re(null==(r=f[0].value)?void 0:r.data);if(!h.transform){const e=f[1].value?f[1].value.data.split("\n").slice(0,6).map((e=>Number(e))):null;h.transform=6===(null==e?void 0:e.length)?new be.Z({forwardCoefficients:[e[4],e[5],e[0],-e[1],e[2],-e[3]]}):null}return h}};(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],Se.prototype,"datasetFormat",void 0),Se=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.ImageAuxRaster")],Se);const ke=Se;var Te=r(17452),Me=r(45322),Pe=r(56608),Oe=r(48700);let Fe=class extends Oe.Z{constructor(){super(...arguments),this.type="gcs-shift",this.tolerance=1e-8}forwardTransform(e){return"point"===(e=e.clone()).type?(e.x>180+this.tolerance&&(e.x-=360),e):(e.xmin>=180-this.tolerance?(e.xmax-=360,e.xmin-=360):e.xmax>180+this.tolerance&&(e.xmin=-180,e.xmax=180),e)}inverseTransform(e){return"point"===(e=e.clone()).type?(e.x<-this.tolerance&&(e.x+=360),e):(e.xmin<-this.tolerance&&(e.xmin+=360,e.xmax+=360),e)}};(0,n._)([(0,h.J)({GCSShiftXform:"gcs-shift"})],Fe.prototype,"type",void 0),(0,n._)([(0,u.Cb)()],Fe.prototype,"tolerance",void 0),Fe=(0,n._)([(0,p.j)("esri.layers.support.rasterTransforms.GCSShiftTransform")],Fe);const Ee=Fe;let Ne=class extends se{constructor(){super(...arguments),this._levelOffset=0,this._slices=null,this._tilemapCache=null,this.datasetFormat="RasterTileServer"}async open(e){await this.init();const t=e&&e.signal,r=this.sourceJSON?{data:this.sourceJSON}:await this.request(this.url,{query:{f:"json"},signal:t});r.ssl&&(this.url=this.url.replace(/^http:/i,"https:"));const n=r.data;if(this.sourceJSON=n,!n)throw new o.Z("imageserverraster:open","cannot initialize tiled image service, missing service info");if(!n.tileInfo)throw new o.Z("imageserverraster:open","use ImageryLayer to open non-tiled image services");this._fixScaleInServiceInfo(),this.tileType=n.cacheType,null==this.tileType&&(["jpg","jpeg","png","png8","png24","png32","mixed"].indexOf(n.tileInfo.format.toLowerCase())>-1?this.tileType="Map":"lerc"===n.tileInfo.format.toLowerCase()?this.tileType="Elevation":this.tileType="Raster"),this.datasetName=n.name.slice(n.name.indexOf("/")+1);const i=await this._fetchRasterInfo({signal:t});if(!(0,a.pC)(i))throw new o.Z("image-server-raster:open","cannot initialize image service");{const e="Map"===this.tileType?(0,Me.d)(n.tileInfo,n):S.Z.fromJSON(n.tileInfo),{extent:t,pixelSize:r}=i,s=.5/i.width*r.x;let o,a;const l=e.lodAt(Math.max.apply(null,e.lods.map((e=>e.level))));"Map"!==this.tileType&&0!==n.maxScale&&("Raster"===this.tileType?(o=e.lods.filter((e=>e.resolution===r.x))[0],o||(o=e.lods[e.lods.length-1])):(o=e.lods.filter((e=>Math.abs(e.scale-n.maxScale)<s))[0],o||(o=e.lods.filter((e=>e.scale>n.maxScale)).sort(((e,t)=>e.scale>t.scale?1:-1))[0])),r.x=r.y=o.resolution,i.width=Math.ceil((t.xmax-t.xmin)/r.x-.1),i.height=Math.ceil((t.ymax-t.ymin)/r.y-.1)),o||(o=l);const c=e.lodAt(Math.min.apply(null,e.lods.map((e=>e.level))));"Map"===this.tileType?this._levelOffset=e.lods[0].level:0!==n.minScale&&"Elevation"===this.tileType&&(a=e.lods.filter((e=>Math.abs(e.scale-n.minScale)<s))[0],this._levelOffset=a.level-c.level),a||(a=c);const u=Math.max(r.x,r.y);(Math.abs(r.x-r.y)>s||!e.lods.some((e=>Math.abs(e.resolution-u)<s)))&&(r.x=r.y=o.resolution,i.width=Math.ceil((t.xmax-t.xmin)/r.x-.1),i.height=Math.ceil((t.ymax-t.ymin)/r.y-.1));const f=o.level-a.level,[h,d]=e.size,p=[];e.lods.forEach((e=>{e.level>=a.level&&e.level<=o.level&&p.push({x:e.resolution,y:e.resolution})})),p.sort(((e,t)=>e.x-t.x));const m=this.computeBlockBoundary(t,h,d,e.origin,p,f),y=p.length>1?p.slice(1):null;i.storageInfo=new j.Z({blockWidth:e.size[0],blockHeight:e.size[1],pyramidBlockWidth:e.size[0],pyramidBlockHeight:e.size[1],pyramidResolutions:y,compression:e.format,origin:e.origin,firstPyramidLevel:1,maximumPyramidLevel:f,tileInfo:e,blockBoundary:m}),this._fixGCSShift(i),this._set("rasterInfo",i)}if(n.capabilities.toLowerCase().indexOf("tilemap")>-1){const e={tileInfo:i.storageInfo.tileInfo,parsedUrl:(0,Te.mN)(this.url),url:this.url,tileServers:[],type:"tile"};this._tilemapCache=new Pe.y({layer:e})}}async fetchRawTile(e,t,r,n={}){if(this._slices&&null==n.sliceId)return null;const{storageInfo:i,extent:s}=this.rasterInfo,o=i.maximumPyramidLevel-e+this._levelOffset,a=`${this.url}/tile/${o}/${t}/${r}`,l=this._slices?{sliceId:n.sliceId||0}:null,{data:c}=await this.request(a,{query:l,responseType:"array-buffer",signal:n.signal});if(!c)return null;const u=await this.decodePixelBlock(c,{width:i.tileInfo.size[0],height:i.tileInfo.size[1],planes:null,pixelType:null,isPoint:"Elevation"===this.tileType}),f=i.blockBoundary[e];if("jpg"!==i.compression||r>f.minCol&&r<f.maxCol&&t>f.minRow&&t<f.maxRow)return u;const{origin:h,blockWidth:d,blockHeight:p}=i,{x:m,y}=this.getPyramidPixelSize(e),g=Math.round((s.xmin-h.x)/m)%d,x=Math.round((s.xmax-h.x)/m)%d,w=Math.round((h.y-s.ymax)/y)%p,v=Math.round((h.y-s.ymin)/y)%p,b=r===f.minCol?g:0,I=t===f.minRow?w:0,_=r===f.maxCol?x:d,C=t===f.maxRow?v:p;return(0,ne.pW)(u,{x:b,y:I},{width:_-b,height:C-I}),u}getSliceIndex(e){if(!this._slices||(0,a.Wi)(e)||0===e.length)return null;const t=e;for(let e=0;e<this._slices.length;e++){const r=this._slices[e].multidimensionalDefinition;if(r.length===t.length&&!r.some((e=>{const r=t.filter((t=>e.variableName===t.variableName&&t.dimensionName===e.dimensionName))[0];return!r||(Array.isArray(e.values[0])?`${e.values[0][0]}-${e.values[0][1]}`:e.values[0])!==(Array.isArray(r.values[0])?`${r.values[0][0]}-${r.values[0][1]}`:r.values[0])})))return e}return null}async fetchVariableStatisticsHistograms(e,t){const r=this.request(this.url+"/statistics",{query:{variable:e,f:"json"},signal:t}).then((e=>{var t;return null==(t=e.data)?void 0:t.statistics})),n=this.request(this.url+"/histograms",{query:{variable:e,f:"json"},signal:t}).then((e=>{var t;return null==(t=e.data)?void 0:t.histograms})),i=await Promise.all([r,n]);return i[0]&&i[0].forEach((e=>{e.avg=e.mean,e.stddev=e.standardDeviation})),{statistics:i[0]||null,histograms:i[1]||null}}async computeBestPyramidLevelForLocation(e,t={}){if(!this._tilemapCache)return 0;let r=this.identifyPixelLocation(e,0,(0,a.Wg)(t.datumTransformation));if(null===r)return null;let n=0;const{maximumPyramidLevel:i}=this.rasterInfo.storageInfo;let s=i-n+this._levelOffset;const o=r.srcLocation;for(;s>=0;){try{if("available"===await this._tilemapCache.fetchAvailability(s,r.row,r.col,t))break}catch{}if(s--,n++,r=this.identifyPixelLocation(o,n,(0,a.Wg)(t.datumTransformation)),null===r)return null}return-1===s||null==r?null:n}async _fetchRasterInfo(e){const t=this.sourceJSON,r=Math.ceil((t.extent.xmax-t.extent.xmin)/t.pixelSizeX-.1),n=Math.ceil((t.extent.ymax-t.extent.ymin)/t.pixelSizeY-.1),i=F.Z.fromJSON(t.spatialReference||t.extent.spatialReference);if("Map"===this.tileType)return new W.Z({width:r,height:n,bandCount:3,extent:O.Z.fromJSON(t.extent),spatialReference:i,pixelSize:new G.Z({x:t.pixelSizeX,y:t.pixelSizeY,spatialReference:i}),pixelType:"u8",statistics:null,keyProperties:{DataType:"processed"}});const{slice:s,signal:o}=e,a=!!t.hasRasterAttributeTable&&this.request(this.url+"/rasterAttributeTable",{query:{slice:s,f:"json"},signal:o}).then((e=>ce.default.fromJSON(e.data))).catch((()=>null)),l=!!t.hasColormap&&this.request(this.url+"/colormap",{query:{slice:s,f:"json"},signal:o}).then((e=>{var t;return null==(t=e.data)?void 0:t.colormap})),c=!!t.hasHistograms&&this.request(this.url+"/histograms",{query:{slice:s,f:"json"},signal:o}).then((e=>{var t;return null==(t=e.data)?void 0:t.histograms})),u=this.request(this.url+"/keyProperties",{query:{f:"json"},signal:o}).then((e=>e.data)).catch((()=>{})),f=!!t.hasMultidimensions&&this._fetchMultidimensionalInfo(),h=!!t.hasMultidimensions&&this.request(this.url+"/slices",{query:{f:"json"},signal:o}).then((e=>e.data&&e.data.slices)).catch((()=>{}));return Promise.all([a,l,c,u,f,h]).then((e=>{let s=null;if(t.minValues&&t.minValues.length===t.bandCount){s=[];for(let e=0;e<t.minValues.length;e++)s.push({min:t.minValues[e],max:t.maxValues[e],avg:t.meanValues[e],stddev:t.stdvValues[e]})}return this._slices=e[5]||null,new W.Z({width:r,height:n,bandCount:t.bandCount,extent:O.Z.fromJSON(t.extent),spatialReference:i,pixelSize:new G.Z({x:t.pixelSizeX,y:t.pixelSizeY,spatialReference:i}),pixelType:t.pixelType.toLowerCase(),statistics:s,attributeTable:e[0]||null,colormap:e[1]||null,histograms:e[2]||null,keyProperties:e[3]||{},multidimensionalInfo:e[4]||null})}))}async _fetchMultidimensionalInfo(e){var t;const r=await this.request(this.url+"/multidimensionalInfo",{query:{f:"json"},signal:e}).then((e=>{var t;return null==(t=e.data)?void 0:t.multidimensionalInfo}));return null!=(t=r.variables)&&t.length&&r.variables.forEach((e=>{var t;null!=(t=e.statistics)&&t.length&&e.statistics.forEach((e=>{e.avg=e.mean,e.stddev=e.standardDeviation}))})),r}_fixScaleInServiceInfo(){const{sourceJSON:e}=this;e.minScale&&e.minScale<0&&(e.minScale=0),e.maxScale&&e.maxScale<0&&(e.maxScale=0)}_fixGCSShift(e){const{extent:t,spatialReference:r}=e;0===t.xmin&&360===t.xmax&&r.wkid&&r.isGeographic&&(e.nativeExtent=e.extent,e.transform=new Ee,e.extent=e.transform.forwardTransform(t))}};(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],Ne.prototype,"datasetFormat",void 0),(0,n._)([(0,u.Cb)()],Ne.prototype,"tileType",void 0),Ne=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.ImageServerRaster")],Ne);const Be=Ne;var Ze=r(54163),De=r(48279);const Ae=new Map;Ae.set("Int8","s8"),Ae.set("UInt8","u8"),Ae.set("Int16","s16"),Ae.set("UInt16","u16"),Ae.set("Int32","s32"),Ae.set("UInt32","u32"),Ae.set("Float32","f32"),Ae.set("Float64","f32"),Ae.set("Double64","f32");const ze=new Map;ze.set("none",{blobExtension:".til",isOneSegment:!0,decoderFormat:"bip"}),ze.set("lerc",{blobExtension:".lrc",isOneSegment:!1,decoderFormat:"lerc"}),ze.set("deflate",{blobExtension:".pzp",isOneSegment:!0,decoderFormat:"deflate"}),ze.set("jpeg",{blobExtension:".pjg",isOneSegment:!0,decoderFormat:"jpg"});let He=class extends se{constructor(){super(...arguments),this._files=null,this._storageIndex=null,this.datasetFormat="MRF"}async open(e){var t;await this.init(),this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);const r=e?(0,a.Wg)(e.signal):null,n=await this.request(this.url,{responseType:"xml",signal:r}),{rasterInfo:i,files:s}=this._parseHeader(n.data);if(-1===(null==(t=this.ioConfig.skipExtensions)?void 0:t.indexOf("aux.xml"))){const t=await this._fetchAuxiliaryData(e);var o;null!=t&&(i.statistics=null!=(o=t.statistics)?o:i.statistics,i.histograms=t.histograms,t.histograms&&!(0,a.pC)(i.statistics)&&(i.statistics=(0,ne.Oh)(t.histograms)))}this._set("rasterInfo",i),this._files=s;const l=await this.request(s.index,{responseType:"array-buffer",signal:r});this._storageIndex=this._parseIndex(l.data);const{blockWidth:c,blockHeight:u}=this.rasterInfo.storageInfo,f=this.rasterInfo.storageInfo.pyramidScalingFactor,{width:h,height:d}=this.rasterInfo,p=[],m=this._getBandSegmentCount();let y=0,g=-1;for(;y<this._storageIndex.length;){g++;const e=Math.ceil(h/c/f**g)-1,t=Math.ceil(d/u/f**g)-1;y+=1*e*(1*t)*m*4,p.push({maxRow:t,maxCol:e,minCol:0,minRow:0})}this.rasterInfo.storageInfo.blockBoundary=p,g>0&&(this.rasterInfo.storageInfo.firstPyramidLevel=1,this.rasterInfo.storageInfo.maximumPyramidLevel=g),this.updateTileInfo()}async fetchRawTile(e,t,r,n={}){const{blockWidth:i,blockHeight:s,blockBoundary:o}=this.rasterInfo.storageInfo,l=o[e];if(!l||l.maxRow<t||l.maxCol<r||l.minRow>t||l.minCol>r)return null;const{bandCount:c,pixelType:u}=this.rasterInfo,{ranges:f,actualTileWidth:h,actualTileHeight:d}=this._getTileLocation(e,t,r);if(!f||0===f.length)return null;if(0===f[0].from&&0===f[0].to){const e=new Uint8Array(i*s);return new Ze.Z({width:i,height:s,pixels:null,mask:e,validPixelCount:0})}const{bandIds:p}=this.ioConfig,m=this._getBandSegmentCount(),y=[];let g=0;for(g=0;g<m;g++)(!p||p.indexOf[g]>-1)&&y.push(this.request(this._files.data,{range:{from:f[g].from,to:f[g].to},responseType:"array-buffer",signal:n.signal}));const x=await Promise.all(y),w=x.map((e=>e.data.byteLength)).reduce(((e,t)=>e+t)),v=new Uint8Array(w);let b=0;for(g=0;g<m;g++)v.set(new Uint8Array(x[g].data),b),b+=x[g].data.byteLength;const I=ze.get(this.rasterInfo.storageInfo.compression).decoderFormat,_=await this.decodePixelBlock(v.buffer,{width:i,height:s,format:I,planes:(null==p?void 0:p.length)||c,pixelType:u});if((0,a.pC)(this.rasterInfo.noDataValue)&&"lerc"!==I&&!_.mask){const e=this.rasterInfo.noDataValue[0];if(null!=e){const t=_.width*_.height,r=new Uint8Array(t);if(Math.abs(e)>1e24)for(g=0;g<t;g++)Math.abs((_.pixels[0][g]-e)/e)>1e-6&&(r[g]=1);else for(g=0;g<t;g++)_.pixels[0][g]!==e&&(r[g]=1);_.mask=r}}let C=0,R=0;if(h!==i||d!==s){let e=_.mask;if(e)for(g=0;g<s;g++)if(R=g*i,g<d)for(C=h;C<i;C++)e[R+C]=0;else for(C=0;C<i;C++)e[R+C]=0;else for(e=new Uint8Array(i*s),_.mask=e,g=0;g<d;g++)for(R=g*i,C=0;C<h;C++)e[R+C]=1}return _}_parseIndex(e){if(e.byteLength%16>0)throw"invalid array buffer must be multiples of 16";let t,r,n,i,s,o;if(De.f){for(r=new Uint8Array(e),i=new ArrayBuffer(e.byteLength),n=new Uint8Array(i),s=0;s<e.byteLength/4;s++)for(o=0;o<4;o++)n[4*s+o]=r[4*s+3-o];t=new Uint32Array(i)}else t=new Uint32Array(e);return t}_getBandSegmentCount(){return ze.get(this.rasterInfo.storageInfo.compression).isOneSegment?1:this.rasterInfo.bandCount}_getTileLocation(e,t,r){const{blockWidth:n,blockHeight:i,pyramidScalingFactor:s}=this.rasterInfo.storageInfo,{width:o,height:a}=this.rasterInfo,l=this._getBandSegmentCount();let c,u,f,h=0,d=0;for(f=0;f<e;f++)d=s**f,c=Math.ceil(o/n/d),u=Math.ceil(a/i/d),h+=c*u;d=s**e,c=Math.ceil(o/n/d),u=Math.ceil(a/i/d),h+=t*c+r,h*=4*l;const p=this._storageIndex.subarray(h,h+4*l);let m=0,y=0;const g=[];for(let e=0;e<l;e++)m=p[4*e+0]*2**32+p[4*e+1],y=m+p[4*e+2]*2**32+p[4*e+3],g.push({from:m,to:y});return{ranges:g,actualTileWidth:r<c-1?n:Math.ceil(o/d)-n*(c-1),actualTileHeight:t<u-1?i:Math.ceil(a/d)-i*(u-1)}}_parseHeader(e){const t=ye(e,"MRF_META/Raster");if(!t)throw new o.Z("mrf:open","not a valid MRF format");const r=ye(t,"Size"),n=parseInt(r.getAttribute("x"),10),i=parseInt(r.getAttribute("y"),10),s=parseInt(r.getAttribute("c"),10),a=(ge(t,"Compression")||"none").toLowerCase();if(!ze.has(a))throw new o.Z("mrf:open","currently does not support compression "+a);const l=ge(t,"DataType")||"UInt8",c=Ae.get(l);if(null==c)throw new o.Z("mrf:open","currently does not support pixel type "+l);const u=ye(t,"PageSize"),f=parseInt(u.getAttribute("x"),10),h=parseInt(u.getAttribute("y"),10),d=ye(t,"DataValues");let p,m;if(d&&(m=d.getAttribute("NoData"),null!=m&&(p=m.trim().split(" ").map((e=>parseFloat(e))))),ye(e,"MRF_META/CachedSource"))throw new o.Z("mrf:open","currently does not support MRF referencing other data files");const y=ye(e,"MRF_META/GeoTags"),g=ye(y,"BoundingBox");if(null==g)throw new o.Z("mrf:open","missing node MRF_META/GeoTags/BoundingBox");const x=parseFloat(g.getAttribute("minx")),w=parseFloat(g.getAttribute("miny")),v=parseFloat(g.getAttribute("maxx")),b=parseFloat(g.getAttribute("maxy")),I=ge(y,"Projection")||"",_=ge(e,"datafile"),C=ge(e,"IndexFile");let R;if("LOCAL_CS[]"!==I)if(I.toLowerCase().startsWith("epsg:")){const e=Number(I.slice(5));isNaN(e)||0===e||(R=new F.Z({wkid:e}))}else R=_e(I);const S=new O.Z(x,w,v,b);S.spatialReference=R;const k=ye(e,"MRF_META/Rsets"),T=parseInt(k&&k.getAttribute("scale")||"2",10),M=new j.Z({origin:new G.Z({x:S.xmin,y:S.ymax,spatialReference:R}),blockWidth:f,blockHeight:h,pyramidBlockWidth:f,pyramidBlockHeight:h,compression:a,pyramidScalingFactor:T}),P=new G.Z({x:(v-x)/n,y:(b-w)/i,spatialReference:R});return{rasterInfo:new W.Z({width:n,height:i,extent:S,spatialReference:R,bandCount:s,pixelType:c,pixelSize:P,noDataValue:p,storageInfo:M}),files:{mrf:this.url,index:C||this.url.replace(".mrf",".idx"),data:_||this.url.replace(".mrf",ze.get(a).blobExtension)}}}async _fetchAuxiliaryData(e){try{const{data:t}=await this.request(this.url+".aux.xml",{responseType:"xml",signal:null==e?void 0:e.signal});return Re(t)}catch{return null}}};(0,n._)([(0,u.Cb)()],He.prototype,"_files",void 0),(0,n._)([(0,u.Cb)()],He.prototype,"_storageIndex",void 0),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],He.prototype,"datasetFormat",void 0),He=(0,n._)([(0,p.j)("esri.layers.support.rasterIO.MRFRaster")],He);const Le=He;var Je=r(29825),We=r(9832);const je=function(e,t){const r=e.get(t);return r&&r.values},Ue=function(e,t){const r=e.get(t);return r&&r.values[0]};let qe=class extends se{constructor(){super(...arguments),this._files=null,this._headerInfo=null,this._bufferSize=1048576,this.datasetFormat="TIFF"}async open(e){var t,r,n;await this.init();const i=e?(0,a.Wg)(e.signal):null,{data:s}=await this.request(this.url,{range:{from:0,to:this._bufferSize},responseType:"array-buffer",signal:i});if(!s)throw new o.Z("tiffraster:open","failed to open url "+this.url);this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);const{littleEndian:l,firstIFD:c,isBigTiff:u}=(0,Je.p)(s),f=[];await this.readIFDs(f,s,l,c,0,u?8:4,i);const h=(0,Je.g)(f),{width:d,height:p,tileWidth:m,tileHeight:y,planes:g,pixelType:x,compression:w,firstPyramidLevel:v,maximumPyramidLevel:b,pyramidBlockWidth:I,pyramidBlockHeight:_,tileBoundary:C,affine:R,metadata:S}=h;let k=_e((null==(t=h.extent.spatialReference)?void 0:t.wkt)||(null==(r=h.extent.spatialReference)?void 0:r.wkid)),T=!1;null==k&&(T=!0,k=new F.Z({wkid:3857}));const M=new O.Z({...h.extent,spatialReference:k}),P=new G.Z(M?{x:M.xmin,y:M.ymax,spatialReference:k}:{x:0,y:0}),E=new j.Z({blockWidth:m,blockHeight:y,pyramidBlockWidth:I,pyramidBlockHeight:_,compression:w,origin:P,firstPyramidLevel:v,maximumPyramidLevel:b,blockBoundary:C}),N=new G.Z({x:(M.xmax-M.xmin)/d,y:(M.ymax-M.ymin)/p,spatialReference:k}),B=S?{BandProperties:S.bandProperties,DataType:S.dataType}:{},Z=new W.Z({width:d,height:p,bandCount:g,pixelType:x,compression:w,pixelSize:N,storageInfo:E,spatialReference:k,isPseudoSpatialReference:T,keyProperties:B,extent:M,statistics:S?S.statistics:null});if(null!=R&&R.length&&(Z.nativeExtent=new O.Z({xmin:-.5,ymin:.5-p,xmax:d-.5,ymax:.5,spatialReference:k}),Z.transform=new be.Z({polynomialOrder:1,forwardCoefficients:[R[2]+R[0]/2,R[5]-R[3]/2,R[0],R[3],-R[1],-R[4]]}),Z.extent=Z.transform.forwardTransform(Z.nativeExtent),Z.pixelSize=new G.Z({x:(M.xmax-M.xmin)/d,y:(M.ymax-M.ymin)/p,spatialReference:k}),E.origin.x=-.5,E.origin.y=.5),null==(n=this.ioConfig.skipExtensions)||!n.includes("aux.xml")){const t=await this._fetchAuxiliaryData(e);if(null!=t){var D;if(Z.statistics=null!=(D=t.statistics)?D:Z.statistics,Z.histograms=t.histograms,t.histograms&&!(0,a.pC)(Z.statistics)&&(Z.statistics=(0,ne.Oh)(t.histograms)),t.transform&&!R){Z.transform=t.transform,Z.nativeExtent=Z.extent;const e=Z.transform.forwardTransform(Z.nativeExtent);Z.pixelSize=new G.Z({x:(e.xmax-e.xmin)/d,y:(e.ymax-e.ymin)/p,spatialReference:k}),Z.extent=e}Z.spatialReference||(Z.spatialReference=t.spatialReference)}}if(this._set("rasterInfo",Z),this._headerInfo={littleEndian:l,isBigTiff:u,ifds:f,...h},!this._headerInfo.isSupported)throw new o.Z("tiffraster:open","this tiff is not supported: "+this._headerInfo.message);this.updateTileInfo()}async fetchRawTile(e,t,r,n={}){var i;if(null==(i=this._headerInfo)||!i.isSupported||this.isBlockOutside(e,t,r))return null;const s=this.getTileLocation(e,t,r);if(!s)return null;const{ranges:o,actualTileWidth:a,actualTileHeight:l,ifd:c}=s,u=o.map((e=>this.request(this.url,{range:e,responseType:"array-buffer",signal:n.signal}))),f=await Promise.all(u),h=f.map((e=>e.data.byteLength)).reduce(((e,t)=>e+t)),d=1===f.length?f[0].data:new ArrayBuffer(h),p=[0],m=[0];if(f.length>1){const e=new Uint8Array(d);for(let t=0,r=0;t<f.length;t++){const n=f[t].data;e.set(new Uint8Array(n),r),p[t]=r,r+=n.byteLength,m[t]=n.byteLength}}const{blockWidth:y,blockHeight:g}=this.getBlockWidthHeight(e),x=await this.decodePixelBlock(d,{format:"tiff",customOptions:{headerInfo:this._headerInfo,ifd:c,offsets:p,sizes:m},width:y,height:g,planes:null,pixelType:null});let w,v,b;if(a!==y||l!==g){let e=x.mask;if(e)for(w=0;w<g;w++)if(b=w*y,w<l)for(v=a;v<y;v++)e[b+v]=0;else for(v=0;v<y;v++)e[b+v]=0;else for(e=new Uint8Array(y*g),x.mask=e,w=0;w<l;w++)for(b=w*y,v=0;v<a;v++)e[b+v]=1}return x}async readIFDs(e,t,r,n,i,s=4,o){if(!n)return null;(n>=t.byteLength||n<0)&&(t=(await this.request(this.url,{range:{from:n+i,to:n+i+this._bufferSize},responseType:"array-buffer",signal:o})).data,i=n+i,n=0);const a=await this.readIFD(t,r,n,i,We.Z.TIFF_TAGS,s,o);if(e.push(a.ifd),!a.nextIFD)return null;await this.readIFDs(e,t,r,a.nextIFD-i,i,s,o)}async readIFD(e,t,r,n,i=We.Z.TIFF_TAGS,s=4,o){if(!e)return null;const a=(0,Je.b)(e,t,r,n,i,s);if(a.success){const r=[];if(a.ifd.forEach((e=>{e.values||r.push(e)})),r.length>0){const i=r.map((e=>e.offlineOffsetSize)),s=Math.min.apply(null,i.map((e=>e[0])));if(Math.min.apply(null,i.map((e=>e[0]+e[1])))-s<=this._bufferSize){const{data:i}=await this.request(this.url,{range:{from:s,to:s+this._bufferSize},responseType:"array-buffer",signal:o});e=i,n=s,r.forEach((r=>(0,Je.c)(e,t,r,n)))}}if(a.ifd.has("GEOKEYDIRECTORY")){const r=a.ifd.get("GEOKEYDIRECTORY"),i=r.values;if(i&&i.length>4){const s=i[0]+"."+i[1]+"."+i[2],a=await this.readIFD(e,t,r.valueOffset+6-n,n,We.Z.GEO_KEYS,2,o);r.data=a.ifd,r.data&&r.data.set("GEOTIFFVersion",{id:0,type:2,valueCount:1,valueOffset:null,values:[s]})}}return a}if(a.requiredBufferSize&&a.requiredBufferSize!==e.byteLength){const r=await this.request(this.url,{range:{from:n,to:n+a.requiredBufferSize+4},responseType:"array-buffer",signal:o});return(e=r.data).byteLength<a.requiredBufferSize?null:this.readIFD(e,t,0,n,We.Z.TIFF_TAGS,4,o)}}getTileLocation(e,t,r){const{firstPyramidLevel:n,blockBoundary:i}=this.rasterInfo.storageInfo,s=0===e?0:e-(n-1),o=this._headerInfo.ifds[s];if(!o)return null;const a=(0,Je.i)(o,this._headerInfo),l=je(o,"TILEOFFSETS");if(void 0===l)return null;const c=je(o,"TILEBYTECOUNTS"),{minRow:u,minCol:f,maxRow:h,maxCol:d}=i[s];if(t>h||r>d||t<u||r<f)return null;const p=Ue(o,"IMAGEWIDTH"),m=Ue(o,"IMAGELENGTH"),y=Ue(o,"TILEWIDTH"),g=Ue(o,"TILELENGTH"),x=a?this.rasterInfo.bandCount:1,w=x*t*(d+1)+r,v=[{from:l[w],to:l[w+x-1]+c[w+x-1]-1}];if(a){let e=!0;for(let t=0;t<x;t++)if(l[w+t]+c[w+t]!==l[w+t+1]){e=!1;break}if(!e)for(let e=0;e<x;e++)v[e]={from:l[w+e],to:l[w+e]+c[w+e]-1}}const b=l[w],I=c[w];return null==b||null==I?null:{ranges:v,ifd:o,actualTileWidth:r===d?p%y:y,actualTileHeight:t===h?m%g:g}}async _fetchAuxiliaryData(e){try{const{data:t}=await this.request(this.url+".aux.xml",{responseType:"xml",signal:null==e?void 0:e.signal});return Re(t)}catch{return null}}};(0,n._)([(0,u.Cb)()],qe.prototype,"_files",void 0),(0,n._)([(0,u.Cb)()],qe.prototype,"_headerInfo",void 0),(0,n._)([(0,u.Cb)()],qe.prototype,"_bufferSize",void 0),(0,n._)([(0,u.Cb)({type:String,json:{write:!0}})],qe.prototype,"datasetFormat",void 0),qe=(0,n._)([(0,p.j)("esri.layers.support.rasterDatasets.TIFFRaster")],qe);const $e=qe,Ge=new Map;Ge.set("CRF",{desc:"Cloud Raster Format",constructor:he}),Ge.set("MRF",{desc:"Meta Raster Format",constructor:Le}),Ge.set("TIFF",{desc:"GeoTIFF",constructor:$e}),Ge.set("RasterTileServer",{desc:"Raster Tile Server",constructor:Be}),Ge.set("JPG",{desc:"JPG Raster Format",constructor:ke}),Ge.set("PNG",{desc:"PNG Raster Format",constructor:ke}),Ge.set("GIF",{desc:"GIF Raster Format",constructor:ke}),Ge.set("BMP",{desc:"BMP Raster Format",constructor:ke});var Ve=r(32163);let Ye=class extends((0,y.h)((0,A.M)((0,B.q)((0,Z.I)((0,g.N)(N((0,z.n)((0,D.Q)((0,l.R)(m.Z)))))))))){constructor(...e){super(...e),this.bandIds=null,this.interpolation=null,this.legendEnabled=!0,this.isReference=null,this.listMode="show",this.sourceJSON=null,this.version=null,this.title=null,this.type="imagery-tile",this.operationalLayerType="ArcGISTiledImageServiceLayer",this.popupEnabled=!0,this.popupTemplate=null,this.fields=null}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}load(e){const t=(0,a.pC)(e)?e.signal:null;return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Image Service"]},e).catch(c.r9).then((()=>this._openRaster(t)))),Promise.resolve(this)}get defaultPopupTemplate(){return this.createPopupTemplate()}get rasterFields(){var e,t;let r=[new H.Z({name:"Raster.ServicePixelValue",alias:"Pixel Value",domain:null,editable:!1,length:50,type:"string"})];const n=null==(e=this.rasterInfo)||null==(t=e.attributeTable)?void 0:t.fields;if(n){const e=n.filter((e=>"oid"!==e.type&&"value"!==e.name.toLowerCase())).map((e=>{const t=e.clone();return t.name="Raster."+e.name,t}));r=r.concat(e)}const i=this.rasterInfo.dataType;if(("vector-magdir"===i||"vector-uv"===i)&&(0,a.pC)(this.rasterInfo.multidimensionalInfo)){var s;const e=null==(s=this.rasterInfo.multidimensionalInfo.variables[0].unit)?void 0:s.trim(),t="Magnitude"+(e?` (${e})`:"");r.push(new H.Z({name:"Raster.Magnitude",alias:t,domain:null,editable:!1,type:"double"})),r.push(new H.Z({name:"Raster.Direction",alias:"Direction (°)",domain:null,editable:!1,type:"double"}))}return r}set renderer(e){this._set("renderer",e),this.updateRenderer()}readRenderer(e,t,r){const n=t&&t.layerDefinition&&t.layerDefinition.drawingInfo&&t.layerDefinition.drawingInfo.renderer,i=(0,s.ij)(n,r)||void 0;if(null!=i)return i}createPopupTemplate(e){return(0,Ve.eZ)({fields:this.rasterFields,title:this.title},e)}write(e,t){const{raster:r}=this;if(this.loaded?"RasterTileServer"===r.datasetFormat&&("Raster"===r.tileType||"Map"===r.tileType):this.url&&/\/ImageServer(\/|\/?$)/i.test(this.url))return super.write(e,t);if(t&&t.messages){const e=`${t.origin}/${t.layerContainerType||"operational-layers"}`;t.messages.push(new o.Z("layer:unsupported",`Layers (${this.title}, ${this.id}) of type '${this.declaredClass}' are not supported in the context of '${e}'`,{layer:this}))}return null}async _openRaster(e){this.raster?(this.raster.rasterInfo||await this.raster.open(),this.url=this.raster.url):this.raster=await class{static get supportedFormats(){const e=new Set;return Ge.forEach(((t,r)=>e.add(r))),e}static async open(e){const{url:t,ioConfig:r,sourceJSON:n}=e;let i=e.datasetFormat;null==i&&t.lastIndexOf(".")&&(i=t.slice(t.lastIndexOf(".")+1).toUpperCase()),"OVR"===i||"TIF"===i?i="TIFF":"JPG"!==i&&"JPEG"!==i&&"JFIF"!==i||(i="JPG"),t.toLowerCase().indexOf("/imageserver")>-1&&-1===t.toLowerCase().indexOf("/wcsserver")&&(i="RasterTileServer");const s={url:t,sourceJSON:n,datasetFormat:i,ioConfig:r||{bandIds:null,sampling:null}};let a,l;if(this.supportedFormats.has(i))return a=Ge.get(i).constructor,l=new a(s),await l.open({signal:e.signal}),l;if(i)throw new o.Z("rasterfactory:open","not a supported format "+i);const c=Array.from(Ge.keys());let u=0;const f=function(){return i=c[u++],i?(a=Ge.get(i).constructor,l=new a(s),l.open({signal:e.signal}).then((()=>l)).catch((()=>f()))):null};return f()}static register(e,t,r){Ge.has(e.toUpperCase())||Ge.set(e.toUpperCase(),{desc:t,constructor:r})}}.open({url:this.url,sourceJSON:this.sourceJSON,ioConfig:{sampling:"closest",...this.ioConfig,customFetchParameters:this.customParameters},signal:e});const{rasterInfo:t}=this.raster;if(!t)throw new o.Z("imagery-tile-layer:load","cannot load resources on "+this.url);this.sourceJSON=this.sourceJSON||this.raster.sourceJSON,null!=this.sourceJSON&&(this._set("version",this.sourceJSON.currentVersion),this._set("copyright",this.sourceJSON.copyrightText),this.sourceJSON.timeInfo&&this._set("timeInfo",J.Z.fromJSON(this.sourceJSON.timeInfo))),null==this.title&&(this.title=this.raster.datasetName),"Map"===this.raster.tileType&&(this.popupEnabled=!1),this._configDefaultSettings(),this.watch("customParameters",(e=>this.raster.ioConfig.customFetchParameters=e))}};(0,n._)([(0,u.Cb)({type:[f.z8],json:{write:{overridePolicy(){var e;return{enabled:!this.loaded||"Raster"===this.raster.tileType||"0,1,2"!==(null==(e=this.bandIds)?void 0:e.join(","))}}}}})],Ye.prototype,"bandIds",void 0),(0,n._)([(0,u.Cb)({json:{write:{overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType||"bilinear"!==this.interpolation}}}}}),(0,h.J)(L.c)],Ye.prototype,"interpolation",void 0),(0,n._)([(0,u.Cb)({json:{write:!0}})],Ye.prototype,"multidimensionalDefinition",void 0),(0,n._)([(0,u.Cb)(_.rn)],Ye.prototype,"legendEnabled",void 0),(0,n._)([(0,u.Cb)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],Ye.prototype,"isReference",void 0),(0,n._)([(0,u.Cb)({type:["show","hide"]})],Ye.prototype,"listMode",void 0),(0,n._)([(0,u.Cb)()],Ye.prototype,"sourceJSON",void 0),(0,n._)([(0,u.Cb)({readOnly:!0})],Ye.prototype,"version",void 0),(0,n._)([(0,u.Cb)()],Ye.prototype,"title",void 0),(0,n._)([(0,u.Cb)({readOnly:!0,json:{read:!1}})],Ye.prototype,"type",void 0),(0,n._)([(0,u.Cb)({type:["ArcGISTiledImageServiceLayer"]})],Ye.prototype,"operationalLayerType",void 0),(0,n._)([(0,u.Cb)({type:Boolean,value:!0,json:{read:{source:"disablePopup",reader:(e,t)=>!t.disablePopup},write:{target:"disablePopup",overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType}},writer(e,t,r){t[r]=!e}}}})],Ye.prototype,"popupEnabled",void 0),(0,n._)([(0,u.Cb)({type:i.Z,json:{read:{source:"popupInfo"},write:{target:"popupInfo",overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType}}}}})],Ye.prototype,"popupTemplate",void 0),(0,n._)([(0,u.Cb)({readOnly:!0})],Ye.prototype,"defaultPopupTemplate",null),(0,n._)([(0,u.Cb)({readOnly:!0,type:[H.Z]})],Ye.prototype,"fields",void 0),(0,n._)([(0,u.Cb)({readOnly:!0,type:[H.Z]})],Ye.prototype,"rasterFields",null),(0,n._)([(0,u.Cb)({types:s.dr,json:{name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy(){var e;const t="raster-stretch"===(null==(e=this.renderer)?void 0:e.type)&&"none"===this.renderer.stretchType&&!this.renderer.useGamma;return{enabled:!this.loaded||"Raster"===this.raster.tileType||!t}}},origins:{"web-scene":{types:s.FK,name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:e=>({enabled:e&&"vector-field"!==e.type&&"animated-flow"!==e.type})}}}}})],Ye.prototype,"renderer",null),(0,n._)([(0,d.r)("renderer")],Ye.prototype,"readRenderer",null),Ye=(0,n._)([(0,p.j)("esri.layers.ImageryTileLayer")],Ye);const Xe=Ye},73506:(e,t,r)=>{r.d(t,{Qp:()=>S,P_:()=>R,ut:()=>b,Hq:()=>C,zD:()=>p,tB:()=>w,nF:()=>g,VO:()=>m,Mk:()=>u,kZ:()=>T,kr:()=>M}),r(66577);var n=r(20102),i=r(70586),s=r(67900),o=r(90411),a=r(6570),l=r(13473);const c=5e-4;function u(e,t,r){return!(0,o.Up)(e,t,r)}function f(e,t,r){const i=u(e,t,r);if(i&&!(0,o.kR)())throw new n.Z("rasterprojectionhelper-project","projection engine is not loaded");return i}const h=function(e,t,r){const n=(e[0]+e[4]+e[4*t.cols]+e[4*t.cols+4])/4,i=(e[1]+e[5]+e[4*t.rows+1]+e[4*t.rows+5])/4,s=(e[4*t.cols]-e[0]+e[4*t.cols+4]-e[4])/r[0]*.5,o=(e[4*t.cols+1]-e[1]+e[4*t.cols+5]-e[5])/r[1]*.5;return[0===s||isNaN(s)?0:Math.abs(n-e[2*t.rows+2])/Math.abs(s),0===o||isNaN(o)?0:Math.abs(i-e[2*t.rows+3])/Math.abs(o)]},d={3395:20037508.342789244,3410:17334193.943686873,3857:20037508.342788905,3975:17367530.445161372,4087:20037508.342789244,4088:20015108.787169147,6933:17367530.445161372,32662:20037508.342789244,53001:20015086.79602057,53002:10007543.39801029,53003:20015086.79602057,53004:20015086.79602057,53016:14152803.599503474,53017:17333573.624304302,53034:20015086.79602057,53079:20015114.352186374,53080:20015114.352186374,54001:20037508.342789244,54002:10018754.171394624,54003:20037508.342789244,54004:20037508.342789244,54016:14168658.027268292,54017:17367530.44516137,54034:20037508.342789244,54079:20037508.342789244,54080:20037508.342789244,54100:20037508.342789244,54101:20037508.342789244};async function p(){if((0,o.kR)())return null;await(0,o.zD)()}function m(e,t,r,n=null){if(e.spatialReference.equals(t))return e;f(e.spatialReference,t,n);const s=r.center,l=new a.Z({xmin:s.x-e.x/2,xmax:s.x+e.x/2,ymin:s.y-e.y/2,ymax:s.y+e.y/2,spatialReference:e.spatialReference}),c=(0,o.iV)(l,t,n);return(0,i.Wi)(c)?null:{x:c.xmax-c.xmin,y:c.ymax-c.ymin}}function y(e,t=.01){return(0,s.c9)(e)?t/(0,s.c9)(e):0}function g(e,t,r=null,n=!0){const i=e.spatialReference;if(i.equals(t))return e;f(i,t,r);const s=(0,o.iV)(e,t,r);if(n&&t.isGeographic){const[t,r]=I(i,!0),n=y(i);n&&null!=t&&null!=r&&(Math.abs(e.x-t)<n&&Math.abs(180-s.x)<c?s.x-=360:Math.abs(e.x-r)<n&&Math.abs(180+s.x)<c&&(s.x+=360))}return s}function x(e){const t=b(e[0].spatialReference);if(e.length<2||!(0,i.pC)(t))return e[0];let{xmin:r,xmax:n,ymin:s,ymax:o}=e[0];for(let r=1;r<e.length;r++){const i=e[r];n=i.xmax+t*r,s=Math.min(s,i.ymin),o=Math.max(o,i.ymax)}return new a.Z({xmin:r,xmax:n,ymin:s,ymax:o,spatialReference:e[0].spatialReference})}function w(e,t,r=null,n=!0){if(e.spatialReference.equals(t))return e;const s=C(e),o=b(e.spatialReference,!0);return(0,i.pC)(o)&&0!==s?x(e.clone().normalize().map((e=>v(e,t,r,n)))):v(e,t,r,n)}function v(e,t,r=null,n=!0){const i=e.spatialReference;if(i.equals(t))return e;f(i,t,r);const s=(0,o.iV)(e,t,r);let[a,u]=I(i,!0);if(s&&n&&i.isWebMercator&&t.isGeographic&&null!=a&&null!=u){const n=.001,o=1e3;if(Math.abs(e.xmin-a)<n&&Math.abs(u-e.xmax)>o&&Math.abs(180-s.xmax)<c){s.xmin=-180;const n=[];n.push(new l.Z(e.xmax,e.ymin,i)),n.push(new l.Z(e.xmax,(e.ymin+e.ymax)/2,i)),n.push(new l.Z(e.xmax,e.ymax,i));const o=n.map((e=>g(e,t,r))).filter((e=>!isNaN(null==e?void 0:e.x))).map((e=>e.x));s.xmax=Math.max.apply(null,o)}if(Math.abs(e.xmax-u)<n&&Math.abs(a-e.xmin)>o&&Math.abs(180+s.xmin)<c){s.xmax=180;const n=[];n.push(new l.Z(e.xmin,e.ymin,i)),n.push(new l.Z(e.xmin,(e.ymin+e.ymax)/2,i)),n.push(new l.Z(e.xmin,e.ymax,i));const o=n.map((e=>g(e,t,r))).filter((e=>!isNaN(null==e?void 0:e.x))).map((e=>e.x));s.xmin=Math.min.apply(null,o)}}[a,u]=I(t,!0);const h=y(t);return h&&null!=a&&null!=u&&s&&(Math.abs(s.xmin-a)<h&&(s.xmin=a),Math.abs(s.xmax-u)<h&&(s.xmax=u)),s}function b(e,t=!1){const r=t?20037508.342787:20037508.342788905;return e.isWebMercator?2*r:e.wkid&&e.isGeographic?360:2*d[e.wkid]||null}function I(e,t=!1){const r=[],n=b(e,t);return(0,i.pC)(n)&&(r.push(-n/2),r.push(n/2)),r}function _(e,t,r,n){let i=(e-t)/r;return i-Math.floor(i)!=0?i=Math.floor(i):n&&(i-=1),i}function C(e,t=!1){const r=b(e.spatialReference);if(!(0,i.pC)(r))return 0;const n=t?0:-r/2;return _(e.xmax,n,r,!0)-_(e.xmin,n,r,!1)}function R(e){const t=e.storageInfo.origin.x,r=b(e.spatialReference,!0);if(!(0,i.pC)(r))return{originX:t,halfWorldWidth:null,pyramidsInfo:null};const n=r/2,{nativePixelSize:s,storageInfo:o,extent:a}=e,{maximumPyramidLevel:l,blockWidth:c,pyramidScalingFactor:u}=o;let f=s.x;const h=[],d=(0,i.pC)(e.transform)&&"gcs-shift"===e.transform.type,p=t+n,m=d?r-t:n-t;for(let e=0;e<=l;e++){const e=(a.xmax-t)/f/c,n=e-Math.floor(e)==0?e:Math.ceil(e),i=(r/2-t)/f/c,s=i-Math.floor(i)==0?i:Math.ceil(i),o=Math.floor(p/f/c),l=Math.round(p/f)%c,d=(c-Math.round(m/f)%c)%c;h.push({resolutionX:f,blockWidth:c,datsetColumnCount:n,worldColumnCountFromOrigin:s,leftMargin:l,rightPadding:d,originColumnOffset:o}),f*=u}return{originX:t,halfWorldWidth:n,pyramidsInfo:h,hasGCSSShiftTransform:d}}function S(e){const t=e.isAdaptive&&null==e.spacing,r=e.spacing||[32,32];let n=k(e),i={cols:n.size[0]+1,rows:n.size[1]+1},s=h(n.offsets,i,r);const o=(s[0]+s[1])/2,a=n.outofBoundPointCount>0&&n.outofBoundPointCount<n.offsets.length/2;return t&&(a||o>4)&&(n=k({...e,spacing:[4,4]}),i={cols:n.size[0]+1,rows:n.size[1]+1},s=h(n.offsets,i,r)),n.error=s,n.coefficients=function(e,t,r){const{cols:n,rows:i}=t,s=new Float32Array((n-1)*(i-1)*2*6),o=new Float32Array([-0,-1,1,-1,1,-0,1,-0,-0]),a=new Float32Array([-1,1,0,0,-1,1,1,0,0]);for(let t=0;t<n-1;t++){for(let r=0;r<i-1;r++){let l=t*i*2+2*r;const c=e[l],u=e[l+1],f=e[l+2],h=e[l+3];l+=2*i;const d=e[l],p=e[l+1],m=e[l+2],y=e[l+3];let g=0,x=12*(r*(n-1)+t);for(let e=0;e<3;e++)s[x++]=o[g++]*c+o[g++]*f+o[g++]*m;g=0;for(let e=0;e<3;e++)s[x++]=o[g++]*u+o[g++]*h+o[g++]*y;g=0;for(let e=0;e<3;e++)s[x++]=a[g++]*c+a[g++]*d+a[g++]*m;g=0;for(let e=0;e<3;e++)s[x++]=a[g++]*u+a[g++]*p+a[g++]*y}if(r)for(let e=0;e<s.length;e++)isNaN(s[e])&&(s[e]=-1)}return s}(n.offsets,i,a),n}function k(e){const{projectedExtent:t,srcBufferExtent:r,pixelSize:n,datumTransformation:s,rasterTransform:a}=e,c=t.spatialReference,u=r.spatialReference;f(c,u);const{xmin:h,ymin:d,xmax:p,ymax:m}=t,y=b(u),g=e.hasWrapAround||"gcs-shift"===(null==a?void 0:a.type),x=e.spacing||[32,32],w={x:x[0]*n.x,y:x[1]*n.y},v=Math.ceil((p-h)/w.x-.1/x[0])+1,I=Math.ceil((m-d)/w.y-.1/x[1])+1,_=w.x,C=w.y,R=[];let S,k=0;const T=[];for(let e=0;e<v;e++)for(let t=0;t<I;t++)T.push(new l.Z({x:h+_*e,y:m-C*t,spatialReference:c}));const M=function(e,t,r=null){const n=e[0].spatialReference;return n.equals(t)?e:(f(n,t,r),(0,o.iV)(e,t,r))}(T,u,s);for(let e=0;e<v;e++){const t=[];for(let n=0;n<I;n++){let s=M[e*I+n];a&&(s=a.inverseTransform(s)),t.push(s),e>0&&g&&s&&S[n]&&(0,i.pC)(y)&&s.x<S[n].x&&(s.x+=y),s?(R.push((s.x-r.xmin)/(r.xmax-r.xmin)),R.push((r.ymax-s.y)/(r.ymax-r.ymin))):(R.push(NaN),R.push(NaN),k++)}S=t}return{offsets:R,error:null,coefficients:null,outofBoundPointCount:k,spacing:x,size:[v-1,I-1]}}function T(e){const t=e.clone().normalize();return 1===t.length?t[0]:x(t)}function M(e,t,r){const{storageInfo:n,pixelSize:s}=t;let o,a=!1;const{pyramidResolutions:c}=n;if((0,i.pC)(c)&&c.length){const n=(e.x+e.y)/2,i=c[c.length-1],u=(i.x+i.y)/2,f=(s.x+s.y)/2;if(n<=f)o=0;else if(n>=u)o=c.length,a=n/u>8;else{let e,t=f;for(let i=1;i<=c.length;i++){if(e=(c[i-1].x+c[i-1].y)/2,n<=e){n===e?o=i:"down"===r?(o=i-1,a=n/t>8):o="up"===r||n-t>e-n||n/t>2?i:i-1;break}t=e}}const h=0===o?s:c[o-1];return{pyramidLevel:o,pyramidResolution:new l.Z({x:h.x,y:h.y,spatialReference:t.spatialReference}),excessiveReading:a}}const u=Math.log(e.x/s.x)/Math.LN2,f=Math.log(e.y/s.y)/Math.LN2,h=t.storageInfo.maximumPyramidLevel||0;o="down"===r?Math.floor(Math.min(u,f)):"up"===r?Math.ceil(Math.max(u,f)):Math.round((u+f)/2),o<0?o=0:o>h&&(a=o>h+3,o=h);const d=2**o;return{pyramidLevel:o,pyramidResolution:new l.Z({x:d*t.nativePixelSize.x,y:d*t.nativePixelSize.y,spatialReference:t.spatialReference}),excessiveReading:a}}},48700:(e,t,r)=>{r.d(t,{Z:()=>l});var n=r(43697),i=r(10736),s=r(5600),o=(r(67676),r(80442),r(75215),r(52011));let a=class extends i.wq{get affectsPixelSize(){return!1}forwardTransform(e){return e}inverseTransform(e){return e}};(0,n._)([(0,s.Cb)()],a.prototype,"affectsPixelSize",null),(0,n._)([(0,s.Cb)({json:{write:!0}})],a.prototype,"spatialReference",void 0),a=(0,n._)([(0,o.j)("esri.layers.support.rasterTransforms.BaseRasterTransform")],a);const l=a},87390:(e,t,r)=>{r.d(t,{Z:()=>m});var n=r(43697),i=(r(66577),r(5600)),s=(r(67676),r(80442),r(75215),r(36030)),o=r(71715),a=r(52011),l=r(30556),c=r(48700),u=r(13473),f=r(6570);function h(e,t,r){const{x:n,y:i}=t;if(r<2)return{x:e[0]+n*e[2]+i*e[4],y:e[1]+n*e[3]+i*e[5]};if(2===r){const t=n*n,r=i*i,s=n*i;return{x:e[0]+n*e[2]+i*e[4]+t*e[6]+s*e[8]+r*e[10],y:e[1]+n*e[3]+i*e[5]+t*e[7]+s*e[9]+r*e[11]}}const s=n*n,o=i*i,a=n*i,l=s*n,c=s*i,u=n*o,f=i*o;return{x:e[0]+n*e[2]+i*e[4]+s*e[6]+a*e[8]+o*e[10]+l*e[12]+c*e[14]+u*e[16]+f*e[18],y:e[1]+n*e[3]+i*e[5]+s*e[7]+a*e[9]+o*e[11]+l*e[13]+c*e[15]+u*e[17]+f*e[19]}}function d(e,t,r){const{xmin:n,ymin:i,xmax:s,ymax:o,spatialReference:a}=t;let l=[];if(r<2)l.push({x:n,y:o}),l.push({x:s,y:o}),l.push({x:n,y:i}),l.push({x:s,y:i});else{let e=10;for(let t=0;t<e;t++)l.push({x:n,y:i+(o-i)*t/(e-1)}),l.push({x:s,y:i+(o-i)*t/(e-1)});e=8;for(let t=1;t<=e;t++)l.push({x:n+(s-n)*t/e,y:i}),l.push({x:n+(s-n)*t/e,y:o})}l=l.map((t=>h(e,t,r)));const c=l.map((e=>e.x)),u=l.map((e=>e.y));return new f.Z({xmin:Math.min.apply(null,c),xmax:Math.max.apply(null,c),ymin:Math.min.apply(null,u),ymax:Math.max.apply(null,u),spatialReference:a})}let p=class extends c.Z{constructor(){super(...arguments),this.polynomialOrder=1,this.type="polynomial"}readForwardCoefficients(e,t){const{coeffX:r,coeffY:n}=t;if(null==r||!r.length||null==n||!n.length||r.length!==n.length)return null;const i=[];for(let e=0;e<r.length;e++)i.push(r[e]),i.push(n[e]);return i}writeForwardCoefficients(e,t,r){const n=[],i=[];for(let t=0;t<(null==e?void 0:e.length);t++)t%2==0?n.push(e[t]):i.push(e[t]);t.coeffX=n,t.coeffY=i}get inverseCoefficients(){let e=this._get("inverseCoefficients");const t=this._get("forwardCoefficients");return!e&&t&&this.polynomialOrder<2&&(e=function(e){const[t,r,n,i,s,o]=e,a=n*o-s*i,l=s*i-n*o;return[(s*r-t*o)/a,(n*r-t*i)/l,o/a,i/l,-s/a,-n/l]}(t)),e}set inverseCoefficients(e){this._set("inverseCoefficients",e)}readInverseCoefficients(e,t){const{inverseCoeffX:r,inverseCoeffY:n}=t;if(null==r||!r.length||null==n||!n.length||r.length!==n.length)return null;const i=[];for(let e=0;e<r.length;e++)i.push(r[e]),i.push(n[e]);return i}writeInverseCoefficients(e,t,r){const n=[],i=[];for(let t=0;t<(null==e?void 0:e.length);t++)t%2==0?n.push(e[t]):i.push(e[t]);t.inverseCoeffX=n,t.inverseCoeffY=i}get affectsPixelSize(){return this.polynomialOrder>0}forwardTransform(e){if("point"===e.type){const t=h(this.forwardCoefficients,e,this.polynomialOrder);return new u.Z({x:t.x,y:t.y,spatialReference:e.spatialReference})}return d(this.forwardCoefficients,e,this.polynomialOrder)}inverseTransform(e){if("point"===e.type){const t=h(this.inverseCoefficients,e,this.polynomialOrder);return new u.Z({x:t.x,y:t.y,spatialReference:e.spatialReference})}return d(this.inverseCoefficients,e,this.polynomialOrder)}};(0,n._)([(0,i.Cb)({json:{write:!0}})],p.prototype,"polynomialOrder",void 0),(0,n._)([(0,i.Cb)()],p.prototype,"forwardCoefficients",void 0),(0,n._)([(0,o.r)("forwardCoefficients",["coeffX","coeffY"])],p.prototype,"readForwardCoefficients",null),(0,n._)([(0,l.c)("forwardCoefficients")],p.prototype,"writeForwardCoefficients",null),(0,n._)([(0,i.Cb)({json:{write:!0}})],p.prototype,"inverseCoefficients",null),(0,n._)([(0,o.r)("inverseCoefficients",["inverseCoeffX","inverseCoeffY"])],p.prototype,"readInverseCoefficients",null),(0,n._)([(0,l.c)("inverseCoefficients")],p.prototype,"writeInverseCoefficients",null),(0,n._)([(0,i.Cb)()],p.prototype,"affectsPixelSize",null),(0,n._)([(0,s.J)({PolynomialXform:"polynomial"})],p.prototype,"type",void 0),p=(0,n._)([(0,a.j)("esri.layers.support.rasterTransforms.PolynomialTransform")],p);const m=p},87521:(e,t,r)=>{r.d(t,{j:()=>f,c:()=>h});var n=r(43697),i=(r(92604),r(75215),r(67676),r(80442),r(37697),r(36030)),s=r(52011),o=r(48700);let a=class extends o.Z{constructor(){super(...arguments),this.type="identity"}};(0,n._)([(0,i.J)({IdentityXform:"identity"})],a.prototype,"type",void 0),a=(0,n._)([(0,s.j)("esri.layers.support.rasterTransforms.IdentityTransform")],a);const l=a,c={PolynomialXform:r(87390).Z,IdentityXform:l},u=Object.keys(c);function f(e){const t=null==e?void 0:e.type;return!e||u.includes(t)}function h(e){if(!(null==e?void 0:e.type))return null;const t=c[null==e?void 0:e.type];if(t){const r=new t;return r.read(e),r}return null}},74889:(e,t,r)=>{r.r(t),r.d(t,{default:()=>x});var n=r(43697),i=r(66577),s=r(38171),o=r(35454),a=r(10736),l=r(70586),c=r(5600),u=(r(67676),r(80442),r(75215),r(71715)),f=r(52011),h=r(30556),d=r(82971),p=r(33955),m=r(1231);const y=new o.Xn({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let g=class extends a.wq{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){const r=d.Z.fromJSON(t.spatialReference),n=[];for(let t=0;t<e.length;t++){const i=e[t],o=s.Z.fromJSON(i),a=i.geometry&&i.geometry.spatialReference;(0,l.pC)(o.geometry)&&!a&&(o.geometry.spatialReference=r),n.push(o)}return n}writeGeometryType(e,t,r,n){if(e)return void y.write(e,t,r,n);const{features:i}=this;if(i)for(const e of i)if(e&&(0,l.pC)(e.geometry))return void y.write(e.geometry.type,t,r,n)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,n=(0,p.im)(e);return!r&&t.spatialReference&&(n.spatialReference=d.Z.fromJSON(t.spatialReference)),n}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:r}=this;if(r)for(const e of r)if(e&&(0,l.pC)(e.geometry)&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){const n=t.features[r];if(n.geometry){const t=e&&e[r];n.geometry=t&&t.toJSON()||n.geometry}}return t}quantize(e){const{scale:[t,r],translate:[n,i]}=e,s=this.features,o=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-n)/t)),(e=>Math.round((i-e)/r)));for(let e=0,t=s.length;e<t;e++)o((0,l.Wg)(s[e].geometry))||(s.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[n,i],scale:[s,o]}=r,a=this._getHydrationFunction(e,(e=>e*s+n),(e=>i-e*o));for(const{geometry:e}of t)(0,l.pC)(e)&&a(e);return this.transform=null,this}_quantizePoints(e,t,r){let n,i;const s=[];for(let o=0,a=e.length;o<a;o++){const a=e[o];if(o>0){const e=t(a[0]),o=r(a[1]);e===n&&o===i||(s.push([e-n,o-i]),n=e,i=o)}else n=t(a[0]),i=r(a[1]),s.push([n,i])}return s.length>0?s:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{const n=(0,p.oU)(e)?e.rings:e.paths,i=[];for(let e=0,s=n.length;e<s;e++){const s=n[e],o=this._quantizePoints(s,t,r);o&&i.push(o)}return i.length>0?((0,p.oU)(e)?e.rings=i:e.paths=i,e):null}:"multipoint"===e?e=>{const n=this._quantizePoints(e.points,t,r);return n.length>0?(e.points=n,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y)}:"polyline"===e||"polygon"===e?e=>{const n=(0,p.oU)(e)?e.rings:e.paths;let i,s;for(let e=0,o=n.length;e<o;e++){const o=n[e];for(let e=0,n=o.length;e<n;e++){const n=o[e];e>0?(i+=n[0],s+=n[1]):(i=n[0],s=n[1]),n[0]=t(i),n[1]=r(s)}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=r(e.ymin),e.xmax=t(e.xmax),e.ymax=r(e.ymax)}:"multipoint"===e?e=>{const n=e.points;let i,s;for(let e=0,o=n.length;e<o;e++){const o=n[e];e>0?(i+=o[0],s+=o[1]):(i=o[0],s=o[1]),o[0]=t(i),o[1]=r(s)}}:void 0}};(0,n._)([(0,c.Cb)({type:String,json:{write:!0}})],g.prototype,"displayFieldName",void 0),(0,n._)([(0,c.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],g.prototype,"exceededTransferLimit",void 0),(0,n._)([(0,c.Cb)({type:[s.Z],json:{write:!0}})],g.prototype,"features",void 0),(0,n._)([(0,u.r)("features")],g.prototype,"readFeatures",null),(0,n._)([(0,c.Cb)({type:[m.Z],json:{write:!0}})],g.prototype,"fields",void 0),(0,n._)([(0,c.Cb)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:y.read}}})],g.prototype,"geometryType",void 0),(0,n._)([(0,h.c)("geometryType")],g.prototype,"writeGeometryType",null),(0,n._)([(0,c.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],g.prototype,"hasM",void 0),(0,n._)([(0,c.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],g.prototype,"hasZ",void 0),(0,n._)([(0,c.Cb)({types:i.qM,json:{write:!0}})],g.prototype,"queryGeometry",void 0),(0,n._)([(0,u.r)("queryGeometry")],g.prototype,"readQueryGeometry",null),(0,n._)([(0,c.Cb)({type:d.Z,json:{write:!0}})],g.prototype,"spatialReference",void 0),(0,n._)([(0,h.c)("spatialReference")],g.prototype,"writeSpatialReference",null),(0,n._)([(0,c.Cb)({json:{write:!0}})],g.prototype,"transform",void 0),g=(0,n._)([(0,f.j)("esri.rest.support.FeatureSet")],g),g.prototype.toJSON.isDefaultToJSON=!0;const x=g},89749:(e,t,r)=>{r.d(t,{t:()=>d});var n=r(43697),i=r(15923),s=r(61247),o=r(70586),a=r(17445),l=r(1654),c=r(43050),u=r(67723),f=r(5600),h=r(52011);let d=class extends i.Z{constructor(){super(...arguments),this.updating=!1,this.handleId=0,this.handles=new s.Z,this.scheduleHandleId=0,this.pendingPromises=new Set}destroy(){this.removeAll(),this.handles.destroy()}add(e,t,r,n=0){const i=0!=(1&n),s=++this.handleId;i||this.installSyncUpdatingWatch(e,t,s);const o=0!=(2&n)?(0,c.S1)(e,t,r,i):e.watch(t,r,i);return this.handles.add(o,s),{remove:()=>this.handles.remove(s)}}addOnCollectionPropertyChange(e,t,r,n=0){const i=0!=(2&n),s=++this.handleId;return this.handles.add([(0,c.on)(e,t,"after-changes",this.createSyncUpdatingCallback()),(0,c.on)(e,t,"change",r,i?e=>{r({added:e.items,removed:[],moved:[],target:e})}:void 0)],s),{remove:()=>{this.handles.remove(s)}}}addOnCollectionChange(e,t,r=0){const n=0!=(2&r),i=++this.handleId;return this.handles.add([e.on("after-changes",this.createSyncUpdatingCallback()),e.on("change",t)],i),n&&t({added:e.items,removed:[],moved:[],target:e}),{remove:()=>{this.handles.remove(i)}}}addPromise(e){if((0,o.Wi)(e))return e;const t=++this.handleId;this.handles.add({remove:()=>{this.pendingPromises.delete(e)&&(0!==this.pendingPromises.size||this.handles.has(p)||this._set("updating",!1))}},t),this.pendingPromises.add(e),this._set("updating",!0);const r=()=>this.handles.remove(t);return e.then(r,r),e}removeAll(){this.pendingPromises.clear(),this.handles.removeAll(),this._set("updating",!1)}installSyncUpdatingWatch(e,t,r){const n=this.createSyncUpdatingCallback(),i=(0,a.Ym)((()=>(0,u.$z)(e,t)),n,{sync:!0,equals:()=>!1});return this.handles.add(i,r),i}createSyncUpdatingCallback(){return()=>{this.handles.remove(p),++this.scheduleHandleId;const e=this.scheduleHandleId;this._get("updating")||this._set("updating",!0),this.handles.add((0,l.Os)((()=>{e===this.scheduleHandleId&&(this._set("updating",this.pendingPromises.size>0),this.handles.remove(p))})),p)}}};(0,n._)([(0,f.Cb)({readOnly:!0})],d.prototype,"updating",void 0),d=(0,n._)([(0,h.j)("esri.views.support.WatchUpdatingTracking")],d);const p=-42}}]);