@arcgis/core 4.34.0-next.7 → 4.34.0-next.8

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 (355) hide show
  1. package/Map.js +1 -1
  2. package/applications/ExperienceBuilder/sketchUtils.d.ts +1 -0
  3. package/applications/ExperienceBuilder/sketchUtils.js +1 -1
  4. package/assets/esri/core/workers/RemoteClient.js +1 -1
  5. package/assets/esri/core/workers/chunks/{feaf79b69d2e2a1f2aa2.js → 06877ea5b9df7de89aff.js} +1 -1
  6. package/assets/esri/core/workers/chunks/{44db659fd4e711f8e22f.js → 076f830d6d0337dfce9d.js} +1 -1
  7. package/assets/esri/core/workers/chunks/09907c9ff597df9bc954.js +1 -0
  8. package/assets/esri/core/workers/chunks/0dbb350ce651bc236ec8.js +1 -0
  9. package/assets/esri/core/workers/chunks/0ed4ec00ef16aa58a33d.js +1 -0
  10. package/assets/esri/core/workers/chunks/{0624ae07d3af8d5f1ac8.js → 15b3eb60f86954783fab.js} +1 -1
  11. package/assets/esri/core/workers/chunks/{b845586219f284a215b2.js → 1db026cc25338dbc208e.js} +1 -1
  12. package/assets/esri/core/workers/chunks/21de4516bf5c9630edfd.js +1 -0
  13. package/assets/esri/core/workers/chunks/2254989ca3ff3960f2fe.js +1 -0
  14. package/assets/esri/core/workers/chunks/248a198f97871a8d6dd6.js +1 -0
  15. package/assets/esri/core/workers/chunks/2dbd18df5c691c8d0a61.js +1 -0
  16. package/assets/esri/core/workers/chunks/2e1ceff3f88a6c78dfa2.js +1 -0
  17. package/assets/esri/core/workers/chunks/{847e88e1d6da1e74cdc8.js → 2ecc1057d53e0b4a60b7.js} +1 -1
  18. package/assets/esri/core/workers/chunks/3025e420e13e2bc8c0a1.js +1 -0
  19. package/assets/esri/core/workers/chunks/32537e2b014bc3d82f5c.js +346 -0
  20. package/assets/esri/core/workers/chunks/34f55bb89ddf26b10260.js +1 -0
  21. package/assets/esri/core/workers/chunks/355ab428a04ee9fcf888.js +1 -0
  22. package/assets/esri/core/workers/chunks/{28e31ac00dc95a1318e9.js → 3916879b9ca8c6979011.js} +1 -1
  23. package/assets/esri/core/workers/chunks/3a74654fa539f78ceb86.js +1 -0
  24. package/assets/esri/core/workers/chunks/3bec10a4f01757590c1c.js +1 -0
  25. package/assets/esri/core/workers/chunks/{a4c108e913d2dc0edc7b.js → 4088f4c25a09932a3eb1.js} +1 -1
  26. package/assets/esri/core/workers/chunks/427318722815bef1496b.js +1 -0
  27. package/assets/esri/core/workers/chunks/4c3bd6cc0badb78c7112.js +1 -0
  28. package/assets/esri/core/workers/chunks/500fb5f615f0c1db1b66.js +1 -0
  29. package/assets/esri/core/workers/chunks/5222523fff30d07f88de.js +1 -0
  30. package/assets/esri/core/workers/chunks/{412eef58cb0d24826375.js → 52c34d6ecd9d45a33e69.js} +1 -1
  31. package/assets/esri/core/workers/chunks/539541dec5fcf3b657aa.js +1 -0
  32. package/assets/esri/core/workers/chunks/53e8c061f36516c3c3e4.js +1 -0
  33. package/assets/esri/core/workers/chunks/{ca76950d81ab4ebb65e1.js → 58f403f956b7b3467344.js} +1 -1
  34. package/assets/esri/core/workers/chunks/5a01bd7a9ee24be7bac4.js +1 -0
  35. package/assets/esri/core/workers/chunks/5bfcb3d87380e7f85b08.js +1 -0
  36. package/assets/esri/core/workers/chunks/5d3246b8fc50f9d9e2c4.js +1 -0
  37. package/assets/esri/core/workers/chunks/{4dd0a5f327fa5fc7249d.js → 5ef1095842e21090f1f4.js} +1 -1
  38. package/assets/esri/core/workers/chunks/614bc3f05873b37af091.js +1 -0
  39. package/assets/esri/core/workers/chunks/6194636638b0439fccd8.js +1 -0
  40. package/assets/esri/core/workers/chunks/66e4cb2479bed1384ed5.js +1 -0
  41. package/assets/esri/core/workers/chunks/6b0ae9ccdd1acef5b5b4.js +1 -0
  42. package/assets/esri/core/workers/chunks/7112b092d98172b7db8b.js +1 -0
  43. package/assets/esri/core/workers/chunks/72ea996b03932c0f004f.js +1 -0
  44. package/assets/esri/core/workers/chunks/74d18c22fa1c178bd9df.js +1 -0
  45. package/assets/esri/core/workers/chunks/766e08d0c56b2b31b63b.js +1 -0
  46. package/assets/esri/core/workers/chunks/77dbb1d5d5e1a6ced932.js +1 -0
  47. package/assets/esri/core/workers/chunks/{bd7b54db7fd278b15500.js → 7a2189614f2dad49ffcd.js} +1 -1
  48. package/assets/esri/core/workers/chunks/7ae88c141a5d85e5bb88.js +1 -0
  49. package/assets/esri/core/workers/chunks/7aef81778155be373d3e.js +1 -0
  50. package/assets/esri/core/workers/chunks/7e1906d35a764f7f10b0.js +1 -0
  51. package/assets/esri/core/workers/chunks/80777a9db53bee2ad8a8.js +1 -0
  52. package/assets/esri/core/workers/chunks/8249b5de5c15461a6787.js +1 -0
  53. package/assets/esri/core/workers/chunks/8385c13ac10e595374cb.js +1 -0
  54. package/assets/esri/core/workers/chunks/83db8bd42f94f97c7cf1.js +1 -0
  55. package/assets/esri/core/workers/chunks/87623ebe32c6ae9cb223.js +1 -0
  56. package/assets/esri/core/workers/chunks/88b1214c284c2ec7d51b.js +1 -0
  57. package/assets/esri/core/workers/chunks/8b86c75426c55b29ebed.js +1 -0
  58. package/assets/esri/core/workers/chunks/8c4b26d86483646c70d2.js +1 -0
  59. package/assets/esri/core/workers/chunks/9cb242dfc3765b590f51.js +1 -0
  60. package/assets/esri/core/workers/chunks/9ddb0b07be31c3747238.js +1 -0
  61. package/assets/esri/core/workers/chunks/9f0f1472f36b42c507d1.js +1 -0
  62. package/assets/esri/core/workers/chunks/{f840e1655c4f6b6630be.js → 9f964467f7353039dd9c.js} +19 -19
  63. package/assets/esri/core/workers/chunks/9fe62638dc7dce466612.js +1 -0
  64. package/assets/esri/core/workers/chunks/a2e9141ff4efd13413a1.js +66 -0
  65. package/assets/esri/core/workers/chunks/adf6982e2d8102669cdf.js +1 -0
  66. package/assets/esri/core/workers/chunks/{d9b2263e0a9f9068ab62.js → b6c3a2d93a59df9a1418.js} +1 -1
  67. package/assets/esri/core/workers/chunks/b763292829aa4d3fab60.js +1 -0
  68. package/assets/esri/core/workers/chunks/ba015f4f72714820a12f.js +1 -0
  69. package/assets/esri/core/workers/chunks/bbbd58b02a3ee8fe595e.js +1 -0
  70. package/assets/esri/core/workers/chunks/c3d95f7f4370486eed2c.js +1 -0
  71. package/assets/esri/core/workers/chunks/c3df693d1bce8f189fa2.js +1 -0
  72. package/assets/esri/core/workers/chunks/{6993a59cbb78bc26f029.js → c45a314ace9725aa250e.js} +1 -1
  73. package/assets/esri/core/workers/chunks/c96fed4889712f5a9135.js +1 -0
  74. package/assets/esri/core/workers/chunks/c9fbada1e84981784f6c.js +1 -0
  75. package/assets/esri/core/workers/chunks/cefcecbeef4f0a46f58c.js +1 -0
  76. package/assets/esri/core/workers/chunks/d2317b87aa2ac3ad97a6.js +1 -0
  77. package/assets/esri/core/workers/chunks/{0bbb38f59f37c51c72f0.js → d45a4e5806a80b69ceec.js} +1 -1
  78. package/assets/esri/core/workers/chunks/{7a23dc625a812a562c21.js → d5f770302dc686e55ba7.js} +1 -1
  79. package/assets/esri/core/workers/chunks/dc14507cfc052faa5890.js +1 -0
  80. package/assets/esri/core/workers/chunks/e7a440476cd1eb4c6547.js +1 -0
  81. package/assets/esri/core/workers/chunks/ede9738ac20e7dd5ce63.js +1 -0
  82. package/assets/esri/core/workers/chunks/eec034d88db320880133.js +1 -0
  83. package/assets/esri/core/workers/chunks/f1e87720b425d7fb348a.js +1 -0
  84. package/assets/esri/core/workers/chunks/f2863c501d62dece5fdd.js +1 -0
  85. package/assets/esri/core/workers/chunks/f5741d09fd4e1809f580.js +1 -0
  86. package/assets/esri/core/workers/chunks/f9e1b73976027e17cd03.js +1 -0
  87. package/assets/esri/core/workers/chunks/fd207a40faf882d3b2a3.js +1 -0
  88. package/assets/esri/core/workers/chunks/fe3832107278244dc04d.js +1 -0
  89. package/assets/esri/widgets/Editor/t9n/Editor.json +1 -1
  90. package/assets/esri/widgets/Editor/t9n/Editor_ar.json +1 -1
  91. package/assets/esri/widgets/Editor/t9n/Editor_bg.json +1 -1
  92. package/assets/esri/widgets/Editor/t9n/Editor_bs.json +1 -1
  93. package/assets/esri/widgets/Editor/t9n/Editor_ca.json +1 -1
  94. package/assets/esri/widgets/Editor/t9n/Editor_cs.json +1 -1
  95. package/assets/esri/widgets/Editor/t9n/Editor_da.json +1 -1
  96. package/assets/esri/widgets/Editor/t9n/Editor_de.json +1 -1
  97. package/assets/esri/widgets/Editor/t9n/Editor_el.json +1 -1
  98. package/assets/esri/widgets/Editor/t9n/Editor_en.json +1 -1
  99. package/assets/esri/widgets/Editor/t9n/Editor_es.json +1 -1
  100. package/assets/esri/widgets/Editor/t9n/Editor_et.json +1 -1
  101. package/assets/esri/widgets/Editor/t9n/Editor_fi.json +1 -1
  102. package/assets/esri/widgets/Editor/t9n/Editor_fr.json +1 -1
  103. package/assets/esri/widgets/Editor/t9n/Editor_he.json +1 -1
  104. package/assets/esri/widgets/Editor/t9n/Editor_hr.json +1 -1
  105. package/assets/esri/widgets/Editor/t9n/Editor_hu.json +1 -1
  106. package/assets/esri/widgets/Editor/t9n/Editor_id.json +1 -1
  107. package/assets/esri/widgets/Editor/t9n/Editor_it.json +1 -1
  108. package/assets/esri/widgets/Editor/t9n/Editor_ja.json +1 -1
  109. package/assets/esri/widgets/Editor/t9n/Editor_ko.json +1 -1
  110. package/assets/esri/widgets/Editor/t9n/Editor_lt.json +1 -1
  111. package/assets/esri/widgets/Editor/t9n/Editor_lv.json +1 -1
  112. package/assets/esri/widgets/Editor/t9n/Editor_nl.json +1 -1
  113. package/assets/esri/widgets/Editor/t9n/Editor_no.json +1 -1
  114. package/assets/esri/widgets/Editor/t9n/Editor_pl.json +1 -1
  115. package/assets/esri/widgets/Editor/t9n/Editor_pt-BR.json +1 -1
  116. package/assets/esri/widgets/Editor/t9n/Editor_pt-PT.json +1 -1
  117. package/assets/esri/widgets/Editor/t9n/Editor_ro.json +1 -1
  118. package/assets/esri/widgets/Editor/t9n/Editor_ru.json +1 -1
  119. package/assets/esri/widgets/Editor/t9n/Editor_sk.json +1 -1
  120. package/assets/esri/widgets/Editor/t9n/Editor_sl.json +1 -1
  121. package/assets/esri/widgets/Editor/t9n/Editor_sr.json +1 -1
  122. package/assets/esri/widgets/Editor/t9n/Editor_sv.json +1 -1
  123. package/assets/esri/widgets/Editor/t9n/Editor_th.json +1 -1
  124. package/assets/esri/widgets/Editor/t9n/Editor_tr.json +1 -1
  125. package/assets/esri/widgets/Editor/t9n/Editor_uk.json +1 -1
  126. package/assets/esri/widgets/Editor/t9n/Editor_vi.json +1 -1
  127. package/assets/esri/widgets/Editor/t9n/Editor_zh-CN.json +1 -1
  128. package/assets/esri/widgets/Editor/t9n/Editor_zh-HK.json +1 -1
  129. package/assets/esri/widgets/Editor/t9n/Editor_zh-TW.json +1 -1
  130. package/chunks/aiServices.js +1 -1
  131. package/config.js +1 -1
  132. package/core/workers/Connection.js +1 -1
  133. package/core/workers/RemoteClient.js +1 -1
  134. package/core/workers/WorkerHandle.js +1 -1
  135. package/effects/FocusArea.d.ts +4 -0
  136. package/effects/FocusArea.js +1 -1
  137. package/effects/FocusAreaOutline.d.ts +4 -0
  138. package/effects/FocusAreaOutline.js +1 -1
  139. package/effects/FocusAreas.d.ts +4 -0
  140. package/effects/FocusAreas.js +1 -1
  141. package/geometry.js +1 -1
  142. package/interfaces.d.ts +307 -43
  143. package/kernel.js +1 -1
  144. package/layers/BuildingSceneLayer.js +1 -1
  145. package/layers/GroupLayer.js +1 -1
  146. package/layers/ImageryLayer.js +1 -1
  147. package/layers/ImageryTileLayer.js +1 -1
  148. package/layers/VideoLayer.js +1 -1
  149. package/layers/buildingSublayers/BuildingComponentSublayer.js +1 -1
  150. package/layers/graphics/controllers/I3SOnDemandController.js +1 -1
  151. package/layers/graphics/editingSupport.js +1 -1
  152. package/layers/mixins/ImageryTileMixin.js +1 -1
  153. package/layers/mixins/operationalLayerModuleMap.js +1 -1
  154. package/layers/mixins/operationalLayers.js +1 -1
  155. package/layers/support/BuildingSummaryStatistics.js +1 -1
  156. package/layers/support/PromiseQueue.js +1 -1
  157. package/layers/support/TelemetryDisplay.js +1 -1
  158. package/layers/support/TitleCreator.js +1 -1
  159. package/layers/support/arcgisLayers.js +1 -1
  160. package/layers/support/featurePopupQueryUtils.js +5 -0
  161. package/layers/support/fieldUtils.js +1 -1
  162. package/layers/support/layersCreator.js +1 -1
  163. package/layers/support/multiLayerServiceUtils.js +5 -0
  164. package/networks/CircuitManager.js +1 -1
  165. package/networks/UnitIdentifierManager.js +1 -1
  166. package/networks/UtilityNetwork.js +1 -1
  167. package/networks/support/UNTraceConfiguration.js +1 -1
  168. package/networks/support/typeUtils.js +1 -1
  169. package/package.json +1 -1
  170. package/portal/PortalItem.js +1 -1
  171. package/portal/support/layersLoader.js +1 -1
  172. package/portal/support/portalLayers.js +1 -1
  173. package/rasterRenderers.js +1 -1
  174. package/renderers.js +1 -1
  175. package/rest/featureService/FeatureService.js +1 -1
  176. package/rest/networks/circuits/queryCircuits.js +1 -1
  177. package/rest/networks/circuits/support/QueryCircuitsParameters.js +1 -1
  178. package/rest/networks/support/CircuitTraceResult.js +5 -0
  179. package/rest/networks/support/TraceResult.js +1 -1
  180. package/rest/networks/unitIdentifiers/support/{QueryUnitIdentifiersParamters.js → QueryUnitIdentifiersParameters.js} +1 -1
  181. package/support/revision.js +1 -1
  182. package/symbols/cim/animationUtils.js +1 -1
  183. package/symbols/cim/cimAnalyzer.js +1 -1
  184. package/symbols/cim/defaultCIMValues.js +1 -1
  185. package/symbols/cim/effects/EffectEnclosingPolygon.js +1 -1
  186. package/symbols/cim/utils.js +1 -1
  187. package/symbols/support/cimSymbolUtils.js +1 -1
  188. package/symbols/support/previewCIMSymbol.js +1 -1
  189. package/symbols.js +1 -1
  190. package/views/2d/engine/webgl/animations/infos.js +1 -1
  191. package/views/2d/engine/webgl/animations/instructions.js +1 -1
  192. package/views/2d/engine/webgl/animations/utils.js +1 -1
  193. package/views/2d/engine/webgl/shaderGraph/techniques/GraphicInstanceStore.js +1 -1
  194. package/views/2d/engine/webgl/shaderGraph/techniques/TechniqueRegistry.js +1 -1
  195. package/views/2d/engine/webgl/shaderGraph/techniques/TechniqueType.js +1 -1
  196. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AAnimatedPolyShader.js +5 -0
  197. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AAnimatedShader.js +5 -0
  198. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedFillShader.js +5 -0
  199. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedLineShader.js +5 -0
  200. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedMarkerMeshWriter.js +1 -1
  201. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedMarkerShader.js +1 -1
  202. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedPolyMeshWriters.js +5 -0
  203. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedTechnique.js +1 -1
  204. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedTechniques.js +5 -0
  205. package/views/2d/engine/webgl/shaderGraph/techniques/animated/ComputedAnimatedParams.js +5 -0
  206. package/views/2d/engine/webgl/shaderGraph/techniques/animated/attributes.js +5 -0
  207. package/views/2d/engine/webgl/shaderGraph/techniques/animated/enums.js +1 -1
  208. package/views/2d/engine/webgl/shaderGraph/techniques/createGraphicSymbolMeshSchemas.js +1 -1
  209. package/views/2d/engine/webgl/shaderGraph/techniques/line/LineMeshWriter.js +1 -1
  210. package/views/2d/engine/webgl/shaderGraph/techniques/markers/MarkerShader.js +1 -1
  211. package/views/2d/engine/webgl/shaderGraph/techniques/mesh/MeshWriterRegistry.js +1 -1
  212. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/ComplexFillShader.js +1 -1
  213. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/LineShader.js +1 -1
  214. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/hittestUtils.js +1 -1
  215. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/utils.js +1 -1
  216. package/views/2d/layers/MediaLayerView2D.js +1 -1
  217. package/views/2d/layers/TileLayerView2D.js +1 -1
  218. package/views/2d/layers/features/schema/processor/symbols/ComplexSymbolSchema.js +1 -1
  219. package/views/2d/layers/features/schema/processor/symbols/utils.js +1 -1
  220. package/views/3d/interactive/editingTools/reshape/ReshapeTool3D.js +1 -1
  221. package/views/3d/interactive/visualElements/DrapedVisualElementResources.js +1 -1
  222. package/views/3d/layers/BuildingComponentSublayerView3D.js +1 -1
  223. package/views/3d/layers/I3SMeshView3D.js +1 -1
  224. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  225. package/views/3d/layers/PointCloudLayerView3D.js +1 -1
  226. package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
  227. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  228. package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
  229. package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
  230. package/views/3d/layers/graphics/Graphics3DSymbolCreationContext.js +1 -1
  231. package/views/3d/layers/graphics/objectResourceUtils.js +1 -1
  232. package/views/3d/layers/i3s/I3SMaterialUtil.js +1 -1
  233. package/views/3d/layers/i3s/I3SUtil.js +1 -1
  234. package/views/3d/layers/support/DefinitionExpressionSceneLayerView.js +1 -1
  235. package/views/3d/layers/support/FeatureVisibilityFilter.js +1 -1
  236. package/views/3d/layers/support/PopupSceneLayerView.js +1 -1
  237. package/views/3d/terrain/OverlayRenderer.js +1 -1
  238. package/views/3d/terrain/TerrainRenderer.js +1 -1
  239. package/views/3d/terrain/TerrainSurface.js +1 -1
  240. package/views/3d/terrain/TileRenderer.js +1 -1
  241. package/views/3d/webgl-engine/core/renderPasses/AllRenderPasses.js +1 -1
  242. package/views/3d/webgl-engine/core/renderPasses/RenderPassManager.js +1 -1
  243. package/views/3d/webgl-engine/core/shaderLibrary/terrain/Overlay.glsl.js +3 -3
  244. package/views/3d/webgl-engine/lib/Texture.js +1 -1
  245. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  246. package/views/SelectionManager.js +1 -1
  247. package/views/VideoView.js +1 -1
  248. package/views/draw/support/GraphicMover.js +1 -1
  249. package/views/layers/CatalogDynamicGroupLayerView.js +1 -1
  250. package/views/layers/FeatureLayerView.js +1 -1
  251. package/views/layers/ImageryLayerView.js +1 -1
  252. package/views/layers/ImageryTileLayerView.js +1 -1
  253. package/views/layers/PointCloudLayerView.js +1 -1
  254. package/views/support/TextureCompressionTracker.js +5 -0
  255. package/views/webgl/Texture.js +1 -1
  256. package/webdoc/support/writeUtils.js +1 -1
  257. package/webmap/utils.js +1 -1
  258. package/widgets/Attachments.js +1 -1
  259. package/widgets/BatchAttributeForm.js +1 -1
  260. package/widgets/Directions/DirectionsVisibleElements.js +1 -1
  261. package/widgets/Directions.js +1 -1
  262. package/widgets/Editor/AddAssociationWorkflowData.js +1 -1
  263. package/widgets/Editor/EditorViewModel.js +1 -1
  264. package/widgets/Editor/UpdateFeatureWorkflow.js +1 -1
  265. package/widgets/Editor/UpdateFeaturesWorkflow.js +1 -1
  266. package/widgets/Editor/UpdateRecordWorkflowData.js +1 -1
  267. package/widgets/Editor/workflowUtils.js +1 -1
  268. package/widgets/Feature/support/featureUtils.js +1 -1
  269. package/widgets/FeatureForm/FeatureFormUtilityNetworkAssociations/UtilityNetworkAssociationItemList.js +1 -1
  270. package/widgets/FeatureForm/FeatureFormViewModel.js +1 -1
  271. package/widgets/FeatureForm/featureFormUtils.js +1 -1
  272. package/widgets/FeatureForm.js +1 -1
  273. package/widgets/FeatureTable/Grid/Grid.js +1 -1
  274. package/widgets/Features/FeaturesViewModel.js +1 -1
  275. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  276. package/widgets/OrientedImageryViewer/adapters/sketch/TriangulatedMeasurementAdapter.js +1 -1
  277. package/widgets/OrientedImageryViewer/components/OrientedImageryVideoViewModel.js +1 -1
  278. package/widgets/OrientedImageryViewer/components/SequentialNavigationUI.js +1 -1
  279. package/widgets/OrientedImageryViewer/navigation/queries.js +1 -1
  280. package/widgets/OrientedImageryViewer/videoViewerUtils.js +5 -0
  281. package/widgets/OrientedImageryViewer.js +1 -1
  282. package/widgets/Sketch.js +1 -1
  283. package/widgets/support/SelectionToolbar/SelectionToolbarViewModel.js +1 -1
  284. package/widgets/support/SelectionToolbar.js +1 -1
  285. package/widgets/support/Selector2D/SelectionOperation.js +1 -1
  286. package/widgets/support/Selector2D/selectorUtils.js +1 -1
  287. package/assets/esri/core/workers/chunks/003ddb190a5cc56f7925.js +0 -1
  288. package/assets/esri/core/workers/chunks/03db109e9b695528c35d.js +0 -1
  289. package/assets/esri/core/workers/chunks/09da6b3085fc84cd69d5.js +0 -1
  290. package/assets/esri/core/workers/chunks/0a770f283eb77c8dc97a.js +0 -1
  291. package/assets/esri/core/workers/chunks/0b70b2ee62904318a12c.js +0 -1
  292. package/assets/esri/core/workers/chunks/0c2dccec20c0994366fe.js +0 -1
  293. package/assets/esri/core/workers/chunks/0d78fc2c2bc1152f84db.js +0 -1
  294. package/assets/esri/core/workers/chunks/0fb5de3f8a4d69b2d514.js +0 -1
  295. package/assets/esri/core/workers/chunks/17e43a050fbf8dc87588.js +0 -1
  296. package/assets/esri/core/workers/chunks/1d7f2abfccc54659d6f2.js +0 -1
  297. package/assets/esri/core/workers/chunks/1f9c6fbcd4d0eae1e574.js +0 -1
  298. package/assets/esri/core/workers/chunks/22e53cb1c8c575fa4d46.js +0 -1
  299. package/assets/esri/core/workers/chunks/2cf82d3645c75d311e99.js +0 -1
  300. package/assets/esri/core/workers/chunks/2d90806faa4269828948.js +0 -1
  301. package/assets/esri/core/workers/chunks/377a7f0f7d304ff9fe5b.js +0 -1
  302. package/assets/esri/core/workers/chunks/3bf1cf6c3cba172e2f6d.js +0 -1
  303. package/assets/esri/core/workers/chunks/3d7eedb787c1e3b9fbfc.js +0 -1
  304. package/assets/esri/core/workers/chunks/3fe7be535affae31de7e.js +0 -1
  305. package/assets/esri/core/workers/chunks/417293f00b2c21cc3175.js +0 -1
  306. package/assets/esri/core/workers/chunks/41cbba9b286cf5558a9c.js +0 -1
  307. package/assets/esri/core/workers/chunks/42bb9bb6fe44a47d9b81.js +0 -1
  308. package/assets/esri/core/workers/chunks/465f2db4ab8aa9c9f907.js +0 -1
  309. package/assets/esri/core/workers/chunks/4ca0738ed38c15b68a77.js +0 -1
  310. package/assets/esri/core/workers/chunks/515e3295495d0958db7e.js +0 -1
  311. package/assets/esri/core/workers/chunks/51ba7345c31e6eb79060.js +0 -1
  312. package/assets/esri/core/workers/chunks/5200be8bce60fa831026.js +0 -1
  313. package/assets/esri/core/workers/chunks/52a57106a41b8c9483d7.js +0 -1
  314. package/assets/esri/core/workers/chunks/536d7986ebb710a8a452.js +0 -1
  315. package/assets/esri/core/workers/chunks/5617532299f73d186968.js +0 -1
  316. package/assets/esri/core/workers/chunks/56d2a20c1b143697aa19.js +0 -1
  317. package/assets/esri/core/workers/chunks/5890740d5a761b038560.js +0 -1
  318. package/assets/esri/core/workers/chunks/5dbd8d81d94cfda5bb32.js +0 -1
  319. package/assets/esri/core/workers/chunks/5e1f7fe6bbc5754efee1.js +0 -1
  320. package/assets/esri/core/workers/chunks/61f9747c960d959b571b.js +0 -346
  321. package/assets/esri/core/workers/chunks/74182421ba425720dc7f.js +0 -1
  322. package/assets/esri/core/workers/chunks/74c0db9e3a62e9839b23.js +0 -1
  323. package/assets/esri/core/workers/chunks/7b12607633bbdc318936.js +0 -1
  324. package/assets/esri/core/workers/chunks/86023cc5ccbc7ac43479.js +0 -1
  325. package/assets/esri/core/workers/chunks/87eca6de502d18d8b7eb.js +0 -1
  326. package/assets/esri/core/workers/chunks/8aa8f9986b966ccb64e2.js +0 -1
  327. package/assets/esri/core/workers/chunks/8d14e957219364a81d5f.js +0 -66
  328. package/assets/esri/core/workers/chunks/937b653b10e8704b38bf.js +0 -1
  329. package/assets/esri/core/workers/chunks/98ef17d15517368d2383.js +0 -1
  330. package/assets/esri/core/workers/chunks/9cac00d4bfac14aaae12.js +0 -1
  331. package/assets/esri/core/workers/chunks/a0c35521e677459f6fa3.js +0 -1
  332. package/assets/esri/core/workers/chunks/a32dcd5bc4680374d30c.js +0 -1
  333. package/assets/esri/core/workers/chunks/aaa6d45316a7d3466d0f.js +0 -1
  334. package/assets/esri/core/workers/chunks/ae733c963d61065faa54.js +0 -1
  335. package/assets/esri/core/workers/chunks/b2a6afa0cd537805b4b8.js +0 -1
  336. package/assets/esri/core/workers/chunks/bf9b6b74654d303a6dae.js +0 -1
  337. package/assets/esri/core/workers/chunks/c6580fdcdc33153008b0.js +0 -1
  338. package/assets/esri/core/workers/chunks/c779335f5d5455c77a62.js +0 -1
  339. package/assets/esri/core/workers/chunks/c77cfd8790877393353a.js +0 -1
  340. package/assets/esri/core/workers/chunks/c9ab067b07d1eab974d1.js +0 -1
  341. package/assets/esri/core/workers/chunks/d3c0d7799c92c6f0e7d3.js +0 -1
  342. package/assets/esri/core/workers/chunks/d52f5214a0330ed2e05e.js +0 -1
  343. package/assets/esri/core/workers/chunks/dbe10c20df7e0e563a0b.js +0 -1
  344. package/assets/esri/core/workers/chunks/df7ca2fe12e22ccfde17.js +0 -1
  345. package/assets/esri/core/workers/chunks/df933eac03dc63064723.js +0 -1
  346. package/assets/esri/core/workers/chunks/e89345c7af9d3d4d8452.js +0 -1
  347. package/assets/esri/core/workers/chunks/ee6240636d04d7d37b7b.js +0 -1
  348. package/assets/esri/core/workers/chunks/ef7955a2509be0f03ca2.js +0 -1
  349. package/assets/esri/core/workers/chunks/f1c6df5cf2ccb6ac47a1.js +0 -1
  350. package/assets/esri/core/workers/chunks/f3d97a4c4f433adbdab5.js +0 -1
  351. package/assets/esri/core/workers/chunks/fc0a3db3d6d26c763fb9.js +0 -1
  352. package/assets/esri/core/workers/chunks/fd4c020297badcb81947.js +0 -1
  353. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedMarkerTechnique.js +0 -5
  354. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedShader.js +0 -5
  355. package/views/support/TextureCompressionHandle.js +0 -5
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3910],{3904:(e,t,o)=>{o.d(t,{A:()=>a});var r=o(90237),s=o(25482),i=o(10107),l=(o(44208),o(53966),o(87811),o(40608)),n=o(43937);let a=class extends s.A{constructor(e){super(e),this.enabled=!0,this.type=null,this.ignoreDrivers=!1}writeEnabled(e,t,o){e||(t[o]=e)}};(0,r._)([(0,i.MZ)({type:Boolean,json:{read:{source:"enable"},write:{target:"enable"}}})],a.prototype,"enabled",void 0),(0,r._)([(0,n.K)("enabled")],a.prototype,"writeEnabled",null),(0,r._)([(0,i.MZ)({type:["icon","object","line","path","fill","water","extrude","text"],readOnly:!0,json:{write:{isRequired:!0}}})],a.prototype,"type",void 0),a=(0,r._)([(0,l.$)("esri.symbols.Symbol3DLayer")],a)},3955:(e,t,o)=>{o.d(t,{A:()=>n});var r=o(90237),s=o(25482),i=o(10107),l=(o(44208),o(53966),o(87811),o(40608));let n=class extends s.A{constructor(e){super(e),this.type="style"}clone(){throw new Error("Subclasses of Pattern3D should implement their own clone method.")}};(0,r._)([(0,i.MZ)({type:["style"],readOnly:!0,json:{read:!0,write:{ignoreOrigin:!0}}})],n.prototype,"type",void 0),n=(0,r._)([(0,l.$)("esri.symbols.patterns.Pattern3D")],n)},4595:(e,t,o)=>{o.d(t,{A:()=>n});var r=o(90237),s=o(25482),i=o(10107),l=(o(44208),o(53966),o(87811),o(40608));let n=class extends s.A{constructor(e){super(e),this.visible=!0}clone(){throw new Error("Subclasses of Callout3D should implement their own clone method.")}};(0,r._)([(0,i.MZ)({type:["line"],constructOnly:!0,json:{read:!1,write:{ignoreOrigin:!0,isRequired:!0}}})],n.prototype,"type",void 0),(0,r._)([(0,i.MZ)({readOnly:!0})],n.prototype,"visible",void 0),n=(0,r._)([(0,l.$)("esri.symbols.callouts.Callout3D")],n)},4792:(e,t,o)=>{o.d(t,{A:()=>h});var r=o(90237),s=o(68197),i=o(25482),l=o(4718),n=o(90629),a=o(10107),y=(o(44208),o(53966),o(40608)),p=o(67222);let c=class extends i.A{constructor(e){super(e),this.color=new s.A([0,0,0,1]),this.extensionLength=0,this.size=(0,n.PN)(1)}clone(){}cloneProperties(){return{color:(0,l.o8)(this.color),size:this.size,extensionLength:this.extensionLength}}};(0,r._)([(0,a.MZ)({type:["solid","sketch"],readOnly:!0,json:{read:!0,write:{ignoreOrigin:!0,isRequired:!0}}})],c.prototype,"type",void 0),(0,r._)([(0,a.MZ)((0,p.EW)({colorRequiredOnWrite:!0}))],c.prototype,"color",void 0),(0,r._)([(0,a.MZ)({...p.pI,json:{write:{overridePolicy:e=>({enabled:!!e})}}})],c.prototype,"extensionLength",void 0),(0,r._)([(0,a.MZ)(p.pI)],c.prototype,"size",void 0),c=(0,r._)([(0,y.$)("esri.symbols.edges.Edges3D")],c);const h=c},4900:(e,t,o)=>{o.d(t,{A:()=>y});var r,s=o(90237),i=o(25482),l=o(10107),n=(o(44208),o(53966),o(87811),o(40608)),a=o(67222);let y=r=class extends i.A{constructor(e){super(e),this.screenLength=0,this.minWorldLength=0,this.maxWorldLength=null}clone(){return new r({screenLength:this.screenLength,minWorldLength:this.minWorldLength,maxWorldLength:this.maxWorldLength})}};(0,s._)([(0,l.MZ)({...a.pI,json:{write:{isRequired:!0}}})],y.prototype,"screenLength",void 0),(0,s._)([(0,l.MZ)({type:Number,nonNullable:!0,json:{write:!0,default:0}})],y.prototype,"minWorldLength",void 0),(0,s._)([(0,l.MZ)({type:Number,json:{write:!0}})],y.prototype,"maxWorldLength",void 0),y=r=(0,s._)([(0,n.$)("esri.symbols.support.Symbol3DVerticalOffset")],y)},6847:(e,t,o)=>{o.d(t,{i:()=>m,r:()=>b});var r,s=o(90237),i=o(66552),l=o(25482),n=o(84952),a=o(10107),y=(o(44208),o(53966),o(87811),o(93223)),p=o(36005),c=o(40608),h=o(43937),u=o(97159);const d=(0,i.O)()({circle:"circle",square:"square",cross:"cross",x:"x",kite:"kite",triangle:"triangle"});let m=r=class extends l.A{constructor(e){super(e)}readHref(e,t,o){return e?(0,u.f)(e,o):t.dataURI}writeHref(e,t,o,r){e&&((0,n.DB)(e)?t.dataURI=e:(t.href=(0,u.t)(e,r),(0,n.oP)(t.href)&&(t.href=(0,n.S8)(t.href))))}clone(){return new r({href:this.href,primitive:this.primitive})}};(0,s._)([(0,a.MZ)({type:String,json:{write:!0,read:{source:["href","dataURI"]}}})],m.prototype,"href",void 0),(0,s._)([(0,p.w)("href")],m.prototype,"readHref",null),(0,s._)([(0,h.K)("href",{href:{type:String},dataURI:{type:String}})],m.prototype,"writeHref",null),(0,s._)([(0,y.e)(d)],m.prototype,"primitive",void 0),m=r=(0,s._)([(0,c.$)("esri.symbols.support.IconSymbol3DLayerResource")],m);const b="circle"},8887:(e,t,o)=>{o.d(t,{Bb:()=>i,Fq:()=>y,M4:()=>p,Nv:()=>c,e:()=>h}),o(44208);var r=o(51850),s=o(70328);function i(e,{isPrimitive:t,width:o,depth:s,height:i}){const l=t?10:1;if(null==o&&null==i&&null==s)return[l*e[0],l*e[1],l*e[2]];const n=(0,r.fA)(o,s,i);let a;for(let t=0;t<3;t++){const o=n[t];if(null!=o){a=o/e[t];break}}for(let t=0;t<3;t++)null==n[t]&&(n[t]=e[t]*a);return n}const l=(0,s.fA)(-.5,-.5,-.5,.5,.5,.5),n=(0,s.fA)(-.5,-.5,0,.5,.5,1),a=(0,s.fA)(-.5,-.5,0,.5,.5,.5);function y(e){switch(e){case"sphere":case"cube":case"diamond":return l;case"cylinder":case"cone":case"inverted-cone":return n;case"tetrahedron":return a;default:return}}const p=["butt","square","round"],c=[...p,"none"],h=["miter","bevel","round"]},8893:(e,t,o)=>{o.d(t,{A:()=>w});var r,s=o(90237),i=o(68197),l=o(4718),n=o(90629),a=o(10107),y=(o(44208),o(53966),o(93223)),p=o(40608),c=o(4595),h=o(25482),u=o(67222);let d=r=class extends h.A{constructor(e){super(e),this.color=new i.A("white")}clone(){return new r({color:(0,l.o8)(this.color)})}};(0,s._)([(0,a.MZ)((0,u.EW)({colorRequiredOnWrite:!0}))],d.prototype,"color",void 0),d=r=(0,s._)([(0,p.$)("esri.symbols.callouts.LineCallout3DBorder")],d);const m=d;var b;let w=b=class extends c.A{constructor(e){super(e),this.type="line",this.color=new i.A([0,0,0,1]),this.size=(0,n.PN)(1),this.border=null}get visible(){return this.size>0&&null!=this.color&&this.color.a>0}clone(){return new b({color:(0,l.o8)(this.color),size:this.size,border:(0,l.o8)(this.border)})}};(0,s._)([(0,y.e)({line:"line"})],w.prototype,"type",void 0),(0,s._)([(0,a.MZ)((0,u.EW)({colorRequiredOnWrite:!0}))],w.prototype,"color",void 0),(0,s._)([(0,a.MZ)({...u.pI,json:{write:{isRequired:!0}}})],w.prototype,"size",void 0),(0,s._)([(0,a.MZ)({type:m,json:{write:!0}})],w.prototype,"border",void 0),(0,s._)([(0,a.MZ)({readOnly:!0})],w.prototype,"visible",null),w=b=(0,s._)([(0,p.$)("esri.symbols.callouts.LineCallout3D")],w)},10224:(e,t,o)=>{o.d(t,{A:()=>A});var r,s=o(90237),i=o(4718),l=o(10107),n=(o(44208),o(53966),o(93223)),a=o(40608),y=o(43937),p=o(11831),c=o(3904),h=o(67222),u=o(68197),d=o(25482);let m=r=class extends d.A{constructor(){super(...arguments),this.color=new u.A([0,0,0,1]),this.size=0}clone(){const e={color:(0,i.o8)(this.color),size:this.size};return new r(e)}};(0,s._)([(0,l.MZ)((0,h.EW)())],m.prototype,"color",void 0),(0,s._)([(0,l.MZ)(h.pI)],m.prototype,"size",void 0),m=r=(0,s._)([(0,a.$)("esri.symbols.support.Symbol3DHalo")],m);var b=o(28975),w=o(69540);o(87811);let v=class extends(w.A.ClonableMixin(d.A)){constructor(e){super(e),this.color=null}};(0,s._)([(0,l.MZ)((0,h.EW)())],v.prototype,"color",void 0),v=(0,s._)([(0,a.$)("esri.symbols.support.Symbol3DTextBackground")],v);var f,g=o(5760);let A=class extends c.A{static{f=this}constructor(e){super(e),this._userSize=void 0,this.halo=null,this.horizontalAlignment="center",this.lineHeight=1,this.material=null,this.background=null,this.text=null,this.type="text",this.verticalAlignment="baseline"}get font(){return this._get("font")||null}set font(e){null!=e&&null!=this._userSize&&(e.size=this._userSize),this._set("font",e)}writeFont(e,t,o,r){const s={...r,textSymbol3D:!0};t.font=e.write({},s),delete t.font.size}get size(){return null!=this._userSize?this._userSize:null!=this.font?.size?this.font.size:9}set size(e){this._userSize=e,null!=this.font&&(this.font.size=this._userSize),this.notifyChange("size")}clone(){const e=new f({enabled:this.enabled,font:this.font&&(0,i.o8)(this.font),halo:this.halo&&(0,i.o8)(this.halo),horizontalAlignment:this.horizontalAlignment,lineHeight:this.lineHeight,material:null!=this.material?this.material.clone():null,text:this.text,verticalAlignment:this.verticalAlignment,background:(0,i.o8)(this.background)});return e._userSize=this._userSize,e}static fromTextSymbol(e){return new f({font:null!=e.font?e.font.clone():new p.A,halo:_(e.haloColor,e.haloSize),horizontalAlignment:e.horizontalAlignment,lineHeight:e.lineHeight,material:e.color?new b.N({color:e.color.clone()}):null,text:e.text,verticalAlignment:e.verticalAlignment,background:e.backgroundColor?new v({color:e.backgroundColor.clone()}):null})}};function _(e,t){return e&&null!=t&&t>0?new m({color:(0,i.o8)(e),size:t}):null}(0,s._)([(0,l.MZ)({type:p.A,json:{write:!0}})],A.prototype,"font",null),(0,s._)([(0,y.K)("font")],A.prototype,"writeFont",null),(0,s._)([(0,l.MZ)({type:m,json:{write:!0}})],A.prototype,"halo",void 0),(0,s._)([(0,l.MZ)({...g.rM,json:{default:"center",write:!0}})],A.prototype,"horizontalAlignment",void 0),(0,s._)([(0,l.MZ)({...g.Tb,json:{default:1,write:!0}})],A.prototype,"lineHeight",void 0),(0,s._)([(0,l.MZ)({type:b.N,json:{write:!0}})],A.prototype,"material",void 0),(0,s._)([(0,l.MZ)({type:v,json:{write:!0}})],A.prototype,"background",void 0),(0,s._)([(0,l.MZ)(h.pI)],A.prototype,"size",null),(0,s._)([(0,l.MZ)({type:String,json:{write:!0}})],A.prototype,"text",void 0),(0,s._)([(0,n.e)({Text:"text"},{readOnly:!0})],A.prototype,"type",void 0),(0,s._)([(0,l.MZ)({...g.x0,json:{default:"baseline",write:!0}})],A.prototype,"verticalAlignment",void 0),A=f=(0,s._)([(0,a.$)("esri.symbols.TextSymbol3DLayer")],A)},11506:(e,t,o)=>{o.d(t,{A:()=>_});var r=o(90237),s=o(90629),i=o(10107),l=(o(44208),o(53966),o(87811),o(93223)),n=o(40608),a=o(68197),y=o(69540),p=o(25482),c=o(56507),h=o(83213);let u=class extends(y.A.ClonableMixin(p.A)){constructor(e){super(e),this.type="style",this.placement="begin-end",this.style="arrow",this.color=null}equals(e){return null!=e&&e.placement===this.placement&&e.style===this.style&&(null==this.color&&null==e.color||null!=this.color&&null!=e.color&&this.color.toJSON()===e.color.toJSON())}};(0,r._)([(0,i.MZ)({type:["style"],readOnly:!0,json:{read:!0,write:{ignoreOrigin:!0,isRequired:!0}}})],u.prototype,"type",void 0),(0,r._)([(0,i.MZ)({type:h.x,json:{default:"begin-end",write:!0}})],u.prototype,"placement",void 0),(0,r._)([(0,i.MZ)({type:h.z,json:{default:"arrow",write:!0}})],u.prototype,"style",void 0),(0,r._)([(0,i.MZ)({type:a.A,json:{type:[c.jz],default:null,write:!0}})],u.prototype,"color",void 0),u=(0,r._)([(0,n.$)("esri.symbols.LineStyleMarker3D")],u);var d,m=o(3904),b=o(44633),w=o(20603),v=o(33386),f=o(67222),g=o(28975),A=o(8887);let _=class extends m.A{static{d=this}constructor(e){super(e),this.material=null,this.type="line",this.join="miter",this.cap="butt",this.size=(0,s.PN)(1),this.pattern=null,this.marker=null}clone(){const e={enabled:this.enabled,material:null!=this.material?this.material.clone():null,size:this.size,join:this.join,cap:this.cap,pattern:null!=this.pattern?this.pattern.clone():null,marker:null!=this.marker?this.marker.clone():null};return new d(e)}static fromSimpleLineSymbol(e){const t={enabled:!0,size:e.width??(0,s.PN)(1),cap:e.cap||"butt",join:e.join||"miter",pattern:e.style?new b.A({style:e.style}):null,material:new g.N({color:(e.color||v.ON).clone()}),marker:e.marker?new u({placement:e.marker.placement,style:e.marker.style,color:e.marker.color?.clone()??null}):null};return new d(t)}};(0,r._)([(0,i.MZ)({type:g.N,json:{write:!0}})],_.prototype,"material",void 0),(0,r._)([(0,l.e)({Line:"line"},{readOnly:!0})],_.prototype,"type",void 0),(0,r._)([(0,i.MZ)({type:A.e,json:{write:!0,default:"miter"}})],_.prototype,"join",void 0),(0,r._)([(0,i.MZ)({type:A.M4,json:{write:!0,default:"butt"}})],_.prototype,"cap",void 0),(0,r._)([(0,i.MZ)({...f.pI,json:{write:{isRequired:!0}}})],_.prototype,"size",void 0),(0,r._)([(0,i.MZ)(w.v)],_.prototype,"pattern",void 0),(0,r._)([(0,i.MZ)({types:{key:"type",base:u,typeMap:{style:u}},json:{write:!0}})],_.prototype,"marker",void 0),_=d=(0,r._)([(0,n.$)("esri.symbols.LineSymbol3DLayer")],_)},13313:(e,t,o)=>{o.d(t,{A:()=>m});var r,s=o(90237),i=o(5503),l=o(4718),n=o(10107),a=(o(44208),o(53966),o(93223)),y=o(40608),p=o(58185),c=o(10224),h=o(59483),u=o(4900);const d=i.A.ofType({base:null,key:"type",typeMap:{text:c.A}});let m=r=class extends p.A{constructor(e){super(e),this.verticalOffset=null,this.callout=null,this.styleOrigin=null,this.symbolLayers=new d,this.type="label-3d"}supportsCallout(){return!0}hasVisibleCallout(){return(0,h.LH)(this)}hasVisibleVerticalOffset(){return(0,h.Yq)(this)}clone(){return new r({styleOrigin:(0,l.o8)(this.styleOrigin),symbolLayers:(0,l.o8)(this.symbolLayers),thumbnail:(0,l.o8)(this.thumbnail),callout:(0,l.o8)(this.callout),verticalOffset:(0,l.o8)(this.verticalOffset)})}static fromTextSymbol(e){return new r({symbolLayers:new i.A([c.A.fromTextSymbol(e)])})}};(0,s._)([(0,n.MZ)({type:u.A,json:{write:!0}})],m.prototype,"verticalOffset",void 0),(0,s._)([(0,n.MZ)(h.oG)],m.prototype,"callout",void 0),(0,s._)([(0,n.MZ)({json:{read:!1,write:!1}})],m.prototype,"styleOrigin",void 0),(0,s._)([(0,n.MZ)({type:d})],m.prototype,"symbolLayers",void 0),(0,s._)([(0,a.e)({LabelSymbol3D:"label-3d"},{readOnly:!0})],m.prototype,"type",void 0),m=r=(0,s._)([(0,y.$)("esri.symbols.LabelSymbol3D")],m)},16264:(e,t,o)=>{o.d(t,{A:()=>a});var r,s=o(90237),i=o(10107),l=(o(44208),o(53966),o(87811),o(40608)),n=o(3955);let a=r=class extends n.A{constructor(e){super(e),this.type="style",this.style="solid"}clone(){return new r({style:this.style})}};(0,s._)([(0,i.MZ)({type:["style"],json:{write:{isRequired:!0}}})],a.prototype,"type",void 0),(0,s._)([(0,i.MZ)({type:["backward-diagonal","cross","diagonal-cross","forward-diagonal","horizontal","none","solid","vertical"],json:{read:!0,write:{isRequired:!0}}})],a.prototype,"style",void 0),a=r=(0,s._)([(0,l.$)("esri.symbols.patterns.StylePattern3D")],a)},18574:(e,t,o)=>{o.d(t,{A:()=>S});var r,s=o(90237),i=o(4718),l=o(53966),n=o(84952),a=o(10107),y=(o(44208),o(93223)),p=o(40608),c=o(3904),h=o(33386),u=o(6847),d=o(67222),m=o(69622);o(87811);let b=r=class extends m.A{constructor(){super(...arguments),this.x=0,this.y=0}clone(){return new r({x:this.x,y:this.y})}};(0,s._)([(0,a.MZ)({type:Number})],b.prototype,"x",void 0),(0,s._)([(0,a.MZ)({type:Number})],b.prototype,"y",void 0),b=r=(0,s._)([(0,p.$)("esri.symbols.support.Symbol3DAnchorPosition2D")],b);var w,v=o(68197),f=o(25482),g=o(90629);let A=w=class extends f.A{constructor(e){super(e),this.color=new v.A([0,0,0,1]),this.size=(0,g.PN)(1)}clone(){const e={color:null!=this.color?this.color.clone():null,size:this.size};return new w(e)}};(0,s._)([(0,a.MZ)((0,d.EW)({colorRequiredOnWrite:!0}))],A.prototype,"color",void 0),(0,s._)([(0,a.MZ)({...d.pI,json:{write:{isRequired:!0}}})],A.prototype,"size",void 0),A=w=(0,s._)([(0,p.$)("esri.symbols.support.Symbol3DIconOutline")],A);var _,M=o(28975);let S=class extends c.A{static{_=this}constructor(e){super(e),this.material=null,this.resource=null,this.type="icon",this.size=12,this.anchor="center",this.anchorPosition=null,this.outline=null,this.angle=0}clone(){return new _({anchor:this.anchor,anchorPosition:(0,i.o8)(this.anchorPosition),enabled:this.enabled,material:(0,i.o8)(this.material),outline:(0,i.o8)(this.outline),resource:(0,i.o8)(this.resource),angle:this.angle,size:this.size})}static fromSimpleMarkerSymbol(e){const t=e.color||h.ON,o=x(e),r=e.outline&&e.outline.width>0?{size:e.outline.width,color:(e.outline.color||h.ON).clone()}:null;return new _({size:e.size,angle:e.angle,resource:{primitive:L((()=>l.A.getLogger(this.prototype)),e.style)},material:{color:t},outline:r,anchor:o?"relative":void 0,anchorPosition:o})}static fromPictureMarkerSymbol(e){const t=!e.color||(0,h.U9)(e.color)?h.ON:e.color,o=x(e);return new _({size:e.width<=e.height?e.height:e.width,angle:e.angle,resource:{href:e.url},material:{color:t.clone()},anchor:o?"relative":void 0,anchorPosition:o})}static fromCIMSymbol(e){return new _({resource:{href:(0,n.Hg)({mediaType:"application/json",data:JSON.stringify(e.data)})}})}};function x(e){const t="width"in e?e.width:e.size,o="height"in e?e.height:e.size,r=Z(e.xoffset),s=Z(e.yoffset);return(r||s)&&t&&o?{x:-r/t,y:s/o}:null}function Z(e){return isFinite(e)?e:0}(0,s._)([(0,a.MZ)({type:M.N,json:{write:!0}})],S.prototype,"material",void 0),(0,s._)([(0,a.MZ)({type:u.i,json:{write:!0}})],S.prototype,"resource",void 0),(0,s._)([(0,y.e)({Icon:"icon"},{readOnly:!0})],S.prototype,"type",void 0),(0,s._)([(0,a.MZ)({...d.pI,json:{write:{isRequired:!0}}})],S.prototype,"size",void 0),(0,s._)([(0,y.e)({center:"center",left:"left",right:"right",top:"top",bottom:"bottom",topLeft:"top-left",topRight:"top-right",bottomLeft:"bottom-left",bottomRight:"bottom-right",relative:"relative"},{default:"center"})],S.prototype,"anchor",void 0),(0,s._)([(0,a.MZ)({type:b,json:{type:[Number],read:{reader:e=>new b({x:e[0],y:e[1]})},write:{writer:(e,t)=>{t.anchorPosition=[e.x,e.y]},overridePolicy(){return{enabled:"relative"===this.anchor}}}}})],S.prototype,"anchorPosition",void 0),(0,s._)([(0,a.MZ)({type:A,json:{write:!0}})],S.prototype,"outline",void 0),(0,s._)([(0,a.MZ)({type:Number,json:{write:!0,default:0}})],S.prototype,"angle",void 0),S=_=(0,s._)([(0,p.$)("esri.symbols.IconSymbol3DLayer")],S);const j={circle:"circle",cross:"cross",diamond:"kite",square:"square",x:"x",triangle:"triangle",path:null};function L(e,t){return j[t]||(e().warn(`${t} cannot be mapped to Icon symbol. Fallback to "circle"`),"circle")}},20603:(e,t,o)=>{o.d(t,{r:()=>n,v:()=>a});var r=o(36533),s=o(44633),i=o(3955),l=o(16264);const n={types:{key:"type",base:i.A,typeMap:{style:l.A}},json:{write:!0}},a={types:{key:"type",base:r.A,typeMap:{style:s.A}},json:{write:!0}}},26449:(e,t,o)=>{o.d(t,{A:()=>c});var r,s=o(90237),i=o(10107),l=(o(44208),o(53966),o(87811),o(93223)),n=o(40608),a=o(3904),y=o(51734),p=o(28975);let c=class extends a.A{static{r=this}constructor(e){super(e),this.type="extrude",this.size=1,this.material=null,this.castShadows=!0,this.edges=null}clone(){return new r({edges:this.edges?.clone(),enabled:this.enabled,material:this.material?.clone(),castShadows:this.castShadows,size:this.size})}};(0,s._)([(0,l.e)({Extrude:"extrude"},{readOnly:!0})],c.prototype,"type",void 0),(0,s._)([(0,i.MZ)({type:Number,json:{write:{enabled:!0,isRequired:!0}},nonNullable:!0})],c.prototype,"size",void 0),(0,s._)([(0,i.MZ)({type:p.N,json:{write:!0}})],c.prototype,"material",void 0),(0,s._)([(0,i.MZ)({type:Boolean,nonNullable:!0,json:{write:!0,default:!0}})],c.prototype,"castShadows",void 0),(0,s._)([(0,i.MZ)(y.J)],c.prototype,"edges",void 0),c=r=(0,s._)([(0,n.$)("esri.symbols.ExtrudeSymbol3DLayer")],c)},27845:(e,t,o)=>{o.d(t,{A:()=>S});var r,s=o(90237),i=o(10107),l=(o(44208),o(53966),o(87811),o(93223)),n=o(40608),a=o(3904),y=o(51734),p=o(44633),c=o(16264),h=o(20603),u=o(33386),d=(o(49186),o(28975));let m=r=class extends d.N{constructor(e){super(e),this.colorMixMode=null}clone(){const e={color:this.color?.clone()??null,colorMixMode:this.colorMixMode,emissive:this.emissive?.clone()??null};return new r(e)}};(0,s._)([(0,l.e)({multiply:"multiply",replace:"replace",tint:"tint"})],m.prototype,"colorMixMode",void 0),m=r=(0,s._)([(0,n.$)("esri.symbols.support.Symbol3DFillMaterial")],m);var b,w=o(68197),v=o(25482),f=o(90629),g=o(67222),A=o(8887);let _=b=class extends v.A{constructor(e){super(e),this.color=new w.A([0,0,0,1]),this.size=(0,f.PN)(1),this.pattern=null,this.patternCap="butt"}clone(){const e={color:null!=this.color?this.color.clone():null,size:this.size,pattern:null!=this.pattern?this.pattern.clone():null,patternCap:this.patternCap};return new b(e)}};var M;(0,s._)([(0,i.MZ)((0,g.EW)({colorRequiredOnWrite:!0}))],_.prototype,"color",void 0),(0,s._)([(0,i.MZ)({...g.pI,json:{write:{isRequired:!0}}})],_.prototype,"size",void 0),(0,s._)([(0,i.MZ)(h.v)],_.prototype,"pattern",void 0),(0,s._)([(0,i.MZ)({type:A.M4,json:{default:"butt",write:{overridePolicy(){return{enabled:null!=this.pattern}}}}})],_.prototype,"patternCap",void 0),_=b=(0,s._)([(0,n.$)("esri.symbols.support.Symbol3DOutline")],_);let S=class extends a.A{static{M=this}constructor(e){super(e),this.type="fill",this.material=null,this.pattern=null,this.castShadows=!0,this.outline=null,this.edges=null}clone(){const e={edges:null!=this.edges?this.edges.clone():null,enabled:this.enabled,material:null!=this.material?this.material.clone():null,pattern:null!=this.pattern?this.pattern.clone():null,castShadows:this.castShadows,outline:null!=this.outline?this.outline.clone():null};return new M(e)}static fromSimpleFillSymbol(e){const t=e.outline&&e.outline.style&&"solid"!==e.outline.style?new p.A({style:e.outline.style}):null,o={size:e.outline?.width??0,color:(e.outline?.color??u.ON).clone(),pattern:t};return t&&e.outline?.cap&&(o.patternCap=e.outline.cap),new M({material:new m({color:(e.color??u.u7).clone()}),pattern:e.style&&"solid"!==e.style?new c.A({style:e.style}):null,outline:o})}};(0,s._)([(0,l.e)({Fill:"fill"},{readOnly:!0})],S.prototype,"type",void 0),(0,s._)([(0,i.MZ)({type:m,json:{write:!0}})],S.prototype,"material",void 0),(0,s._)([(0,i.MZ)(h.r)],S.prototype,"pattern",void 0),(0,s._)([(0,i.MZ)({type:Boolean,nonNullable:!0,json:{write:!0,default:!0}})],S.prototype,"castShadows",void 0),(0,s._)([(0,i.MZ)({type:_,json:{write:!0}})],S.prototype,"outline",void 0),(0,s._)([(0,i.MZ)(y.J)],S.prototype,"edges",void 0),S=M=(0,s._)([(0,n.$)("esri.symbols.FillSymbol3DLayer")],S)},28975:(e,t,o)=>{o.d(t,{N:()=>c});var r,s=o(90237),i=o(25482),l=o(10107),n=(o(44208),o(53966),o(87811),o(40608)),a=o(67222);let y=r=class extends i.A{constructor(){super(...arguments),this.strength=null,this.source="emissive"}clone(){const e={strength:this.strength,source:this.source};return new r(e)}};var p;(0,s._)([(0,l.MZ)({json:{write:!1}})],y.prototype,"strength",void 0),(0,s._)([(0,l.MZ)({json:{write:!1}})],y.prototype,"source",void 0),y=r=(0,s._)([(0,n.$)("esri.symbols.support.Symbol3DEmissive")],y);let c=p=class extends i.A{constructor(e){super(e),this.color=null,this.emissive=new y({source:"emissive"})}clone(){const e={color:this.color?.clone()??null,emissive:this.emissive?.clone()??null};return new p(e)}};(0,s._)([(0,l.MZ)((0,a.EW)())],c.prototype,"color",void 0),(0,s._)([(0,l.MZ)({type:y,json:{write:!1}})],c.prototype,"emissive",void 0),c=p=(0,s._)([(0,n.$)("esri.symbols.support.Symbol3DMaterial")],c)},30809:(e,t,o)=>{o.d(t,{E:()=>h,r:()=>u});var r,s=o(90237),i=o(66552),l=o(25482),n=o(10107),a=(o(44208),o(53966),o(87811),o(93223)),y=o(40608),p=o(97159);const c=(0,i.O)()({sphere:"sphere",cylinder:"cylinder",cube:"cube",cone:"cone",diamond:"diamond",tetrahedron:"tetrahedron",invertedCone:"inverted-cone"});let h=r=class extends l.A{clone(){return new r({href:this.href,primitive:this.primitive})}};(0,s._)([(0,n.MZ)({type:String,json:{read:p.r,write:p.w}})],h.prototype,"href",void 0),(0,s._)([(0,a.e)(c)],h.prototype,"primitive",void 0),h=r=(0,s._)([(0,y.$)("esri.symbols.support.ObjectSymbol3DLayerResource")],h);const u="sphere"},33386:(e,t,o)=>{o.d(t,{ON:()=>s,U9:()=>l,u7:()=>i});var r=o(68197);const s=new r.A("white"),i=new r.A([255,255,255,0]);function l(e){return 0===e.r&&0===e.g&&0===e.b}},33910:(e,t,o)=>{o.d(t,{dp:()=>I,$y:()=>L,wk:()=>O,Y7:()=>k,wC:()=>N,Ac:()=>D,Bu:()=>C,Es:()=>z,q8:()=>$,em:()=>R,Rv:()=>W,xK:()=>P,On:()=>q});var r,s=o(56507),i=o(90360),l=o(40863),n=o(13313),a=o(97887),y=o(68548),p=o(90237),c=o(4718),h=o(90629),u=o(10107),d=(o(44208),o(53966),o(93223)),m=o(40608),b=o(65851),w=o(77040);let v=r=class extends b.A{constructor(...e){super(...e),this.type="picture-fill",this.url=null,this.xscale=1,this.yscale=1,this.width=12,this.height=12,this.xoffset=0,this.yoffset=0,this.source=null}normalizeCtorArgs(e,t,o,r){if(e&&"string"!=typeof e&&null==e.imageData)return e;const s={};return e&&(s.url=e),t&&(s.outline=t),null!=o&&(s.width=(0,h.cr)(o)),null!=r&&(s.height=(0,h.cr)(r)),s}clone(){const e=new r({color:(0,c.o8)(this.color),height:this.height,outline:(0,c.o8)(this.outline),url:this.url,width:this.width,xoffset:this.xoffset,xscale:this.xscale,yoffset:this.yoffset,yscale:this.yscale});return e._set("source",(0,c.o8)(this.source)),e}hash(){return`${super.hash()}.${this.color?.hash()}.${this.height}.${this.url}.${this.width}.${this.xoffset}.${this.xscale}.${this.yoffset}.${this.yscale}`}};(0,p._)([(0,d.e)({esriPFS:"picture-fill"},{readOnly:!0})],v.prototype,"type",void 0),(0,p._)([(0,u.MZ)(w.ku)],v.prototype,"url",void 0),(0,p._)([(0,u.MZ)({type:Number,json:{write:!0}})],v.prototype,"xscale",void 0),(0,p._)([(0,u.MZ)({type:Number,json:{write:!0}})],v.prototype,"yscale",void 0),(0,p._)([(0,u.MZ)({type:Number,cast:h.cr,json:{write:!0}})],v.prototype,"width",void 0),(0,p._)([(0,u.MZ)({type:Number,cast:h.cr,json:{write:!0}})],v.prototype,"height",void 0),(0,p._)([(0,u.MZ)({type:Number,cast:h.cr,json:{write:!0}})],v.prototype,"xoffset",void 0),(0,p._)([(0,u.MZ)({type:Number,cast:h.cr,json:{write:!0}})],v.prototype,"yoffset",void 0),(0,p._)([(0,u.MZ)(w.k7)],v.prototype,"source",void 0),v=r=(0,p._)([(0,m.$)("esri.symbols.PictureFillSymbol")],v);var f=o(58592),g=o(75981),A=o(65365),_=o(94985),M=o(31593),S=o(53930),x=o(20378),Z=o(68249),j=o(37757);function L(e){if(!e)return!1;switch(e.type){case"picture-fill":case"picture-marker":case"simple-fill":case"simple-line":case"simple-marker":case"text":case"cim":return!0;default:return!1}}function O(e){switch(e?.type){case"label-3d":case"line-3d":case"mesh-3d":case"point-3d":case"polygon-3d":return!0;default:return!1}}const z={base:x.A,key:"type",typeMap:{"simple-fill":_.A,"picture-fill":v,"picture-marker":f.A,"simple-line":M.A,"simple-marker":S.A,text:Z.A,"label-3d":n.A,"line-3d":a.A,"mesh-3d":y.A,"point-3d":g.A,"polygon-3d":A.A,"web-style":j.A,cim:l.A},errorContext:"symbol"},N=(x.A,_.A,l.A,{base:x.A,key:"type",typeMap:{"picture-marker":f.A,"simple-marker":S.A,"point-3d":g.A,cim:l.A},errorContext:"symbol"}),k={base:x.A,key:"type",typeMap:{"simple-line":M.A,"line-3d":a.A,cim:l.A},errorContext:"symbol"},D={base:x.A,key:"type",typeMap:{"simple-fill":_.A,"picture-fill":v,"polygon-3d":A.A,cim:l.A},errorContext:"symbol"},$={base:x.A,key:"type",typeMap:{"picture-marker":f.A,"simple-marker":S.A,text:Z.A,"web-style":j.A,cim:l.A},errorContext:"symbol"},C=(0,i.C)({types:z}),P={base:x.A,key:"type",typeMap:{"simple-fill":_.A,"picture-fill":v,"picture-marker":f.A,"simple-line":M.A,"simple-marker":S.A,text:Z.A,"line-3d":a.A,"mesh-3d":y.A,"point-3d":g.A,"polygon-3d":A.A,"web-style":j.A,cim:l.A},errorContext:"symbol"},R={base:x.A,key:"type",typeMap:{text:Z.A,"label-3d":n.A},errorContext:"symbol"},q=(x.A,n.A,a.A,y.A,g.A,A.A,j.A,{base:x.A,key:"type",typeMap:{"line-3d":a.A,"mesh-3d":y.A,"point-3d":g.A,"polygon-3d":A.A,"web-style":j.A,cim:l.A},errorContext:"symbol"}),W={base:x.A,key:"type",typeMap:{"label-3d":n.A},errorContext:"symbol"},I=(0,s.aq)(z)},34723:(e,t,o)=>{o.d(t,{A:()=>h});var r,s=o(90237),i=o(68197),l=o(4718),n=o(10107),a=o(56507),y=o(93223),p=o(40608),c=o(3904);let h=class extends c.A{static{r=this}constructor(e){super(e),this.color=u.clone(),this.type="water",this.waterbodySize="medium",this.waveDirection=null,this.waveStrength="moderate"}clone(){return new r({color:(0,l.o8)(this.color),waterbodySize:this.waterbodySize,waveDirection:this.waveDirection,waveStrength:this.waveStrength})}};(0,s._)([(0,n.MZ)({type:i.A,nonNullable:!0,json:{type:[a.jz],write:(e,t,o)=>t[o]=e.toArray(i.A.AlphaMode.UNLESS_OPAQUE),default:()=>u.clone(),defaultEquals:e=>e.toCss(!0)===u.toCss(!0)}})],h.prototype,"color",void 0),(0,s._)([(0,y.e)({Water:"water"},{readOnly:!0})],h.prototype,"type",void 0),(0,s._)([(0,n.MZ)({type:["small","medium","large"],json:{write:!0,default:"medium"}})],h.prototype,"waterbodySize",void 0),(0,s._)([(0,n.MZ)({type:Number,json:{write:!0,default:null}})],h.prototype,"waveDirection",void 0),(0,s._)([(0,n.MZ)({type:["calm","rippled","slight","moderate"],json:{write:!0,default:"moderate"}})],h.prototype,"waveStrength",void 0),h=r=(0,s._)([(0,p.$)("esri.symbols.WaterSymbol3DLayer")],h);const u=new i.A([0,119,190])},36533:(e,t,o)=>{o.d(t,{A:()=>n});var r=o(90237),s=o(25482),i=o(10107),l=(o(44208),o(53966),o(87811),o(40608));let n=class extends s.A{constructor(e){super(e)}clone(){throw new Error("Subclasses of LinePattern3D should implement their own clone method.")}};(0,r._)([(0,i.MZ)({type:["style"],readOnly:!0,json:{read:!0,write:{ignoreOrigin:!0}}})],n.prototype,"type",void 0),n=(0,r._)([(0,l.$)("esri.symbols.patterns.LinePattern3D")],n)},37757:(e,t,o)=>{o.d(t,{A:()=>b});var r,s=o(90237),i=o(51447),l=o(49186),n=o(53966),a=o(74887),y=o(10107),p=(o(44208),o(87811),o(93223)),c=o(40608),h=o(20655),u=o(97159),d=o(20378),m=o(57212);let b=r=class extends d.A{constructor(e){super(e),this.color=null,this.styleName=null,this.portal=null,this.styleUrl=null,this.thumbnail=null,this.name=null,this.type="web-style"}get _fetchCacheKey(){const e=null!=this.portal?this.portal:h.A.getDefault(),t=e.user?e.user.username:null;return`${this.styleName}:${this.styleUrl}:${this.name}:${t}:${e.url}`}read(e,t){this.portal=t?.portal,super.read(e,t)}clone(){return new r({name:this.name,styleUrl:this.styleUrl,styleName:this.styleName,portal:this.portal})}fetchSymbol(e){return this._fetchSymbol(e)}async fetchCIMSymbol(e){(0,i.eO)(n.A.getLogger(this),"WebStyleSymbol.fetchCIMSymbol is deprecated in favour of WebStyleSymbol.fetchSymbol which now supports both web and cim symbology",{version:"4.33",replacement:"WebStyleSymbol.fetchSymbol",see:"https://arcg.is/0CXPTr#fetchSymbol",warnOnce:!0});const t=await this._fetchSymbol({...e,acceptedFormats:["cim"]});if("cim"!==t?.type)throw new l.A("webstylesymbol:fetchCIMSymbol","Resolved web style symbol is not of type 'cim'");return t}async _fetchSymbol(e){const t=null!=e?e.cache:null,r=t?this._fetchCacheKey:null;if(null!=t){const e=r&&t.get(r);if(e)return e.clone()}const{resolveWebStyleSymbol:s}=await o.e(7883).then(o.bind(o,27883));(0,a.Te)(e);const i=s(this,{portal:this.portal},e);i.catch((e=>{n.A.getLogger(this).error("#fetchSymbol()","Failed to create symbol from style",e)}));const l=await i;return null!=t&&t.set(r,l.clone()),l}};(0,s._)([(0,y.MZ)({json:{write:!1}})],b.prototype,"color",void 0),(0,s._)([(0,y.MZ)({type:String,json:{write:!0}})],b.prototype,"styleName",void 0),(0,s._)([(0,y.MZ)({type:h.A,json:{write:!1}})],b.prototype,"portal",void 0),(0,s._)([(0,y.MZ)({type:String,json:{read:u.r,write:u.w}})],b.prototype,"styleUrl",void 0),(0,s._)([(0,y.MZ)({type:m.V,json:{read:!1}})],b.prototype,"thumbnail",void 0),(0,s._)([(0,y.MZ)({type:String,json:{write:!0}})],b.prototype,"name",void 0),(0,s._)([(0,p.e)({styleSymbolReference:"web-style"},{readOnly:!0})],b.prototype,"type",void 0),(0,s._)([(0,y.MZ)()],b.prototype,"_fetchCacheKey",null),b=r=(0,s._)([(0,c.$)("esri.symbols.WebStyleSymbol")],b)},39065:(e,t,o)=>{o.d(t,{A:()=>y});var r,s=o(90237),i=(o(53966),o(44208),o(87811),o(49186),o(93223)),l=o(40608),n=o(4792);let a=r=class extends n.A{constructor(e){super(e),this.type="solid"}clone(){return new r(this.cloneProperties())}};(0,s._)([(0,i.e)({solid:"solid"},{readOnly:!0})],a.prototype,"type",void 0),a=r=(0,s._)([(0,l.$)("esri.symbols.edges.SolidEdges3D")],a);const y=a},40863:(e,t,o)=>{o.d(t,{A:()=>d});var r,s=o(90237),i=o(4718),l=o(799),n=o(10107),a=(o(44208),o(53966),o(93223)),y=o(36005),p=o(40608),c=o(43937),h=o(30524),u=o(20378);let d=r=class extends u.A{constructor(e){super(e),this.data=null,this.type="cim"}readData(e,t){return t}writeData(e,t){Object.assign(t,e)}async collectRequiredFields(e,t){if("CIMSymbolReference"===this.data?.type){const o=this.data.primitiveOverrides;if(o){const r=o.map((o=>{const r=o.valueExpressionInfo;return r?(0,h.Dx)(e,t,r.expression):null}));await Promise.all(r)}}}clone(){return new r({data:(0,i.o8)(this.data)})}hash(){return(0,l.Wm)(JSON.stringify(this.data)).toString()}};(0,s._)([(0,n.MZ)({json:{write:!1}})],d.prototype,"color",void 0),(0,s._)([(0,n.MZ)({json:{write:!0}})],d.prototype,"data",void 0),(0,s._)([(0,y.w)("data",["symbol"])],d.prototype,"readData",null),(0,s._)([(0,c.K)("data",{})],d.prototype,"writeData",null),(0,s._)([(0,a.e)({CIMSymbolReference:"cim"},{readOnly:!0})],d.prototype,"type",void 0),d=r=(0,s._)([(0,p.$)("esri.symbols.CIMSymbol")],d)},44633:(e,t,o)=>{o.d(t,{A:()=>c});var r,s=o(90237),i=o(66552),l=o(10107),n=(o(44208),o(53966),o(87811),o(93223)),a=o(40608),y=o(36533);const p=(0,i.O)()({dash:"dash","dash-dot":"dash-dot","dash-dot-dot":"long-dash-dot-dot",dot:"dot","long-dash":"long-dash","long-dash-dot":"long-dash-dot",null:"none","short-dash":"short-dash","short-dash-dot":"short-dash-dot","short-dash-dot-dot":"short-dash-dot-dot","short-dot":"short-dot",solid:"solid"});let c=r=class extends y.A{constructor(e){super(e),this.type="style",this.style="solid"}clone(){const e={style:this.style};return new r(e)}};(0,s._)([(0,l.MZ)({type:["style"],json:{write:{isRequired:!0}}})],c.prototype,"type",void 0),(0,s._)([(0,n.e)(p),(0,l.MZ)({type:["dash","dash-dot","dot","long-dash","long-dash-dot","long-dash-dot-dot","none","short-dash","short-dash-dot","short-dash-dot-dot","short-dot","solid"],json:{write:{isRequired:!0}}})],c.prototype,"style",void 0),c=r=(0,s._)([(0,a.$)("esri.symbols.patterns.LineStylePattern3D")],c)},51734:(e,t,o)=>{o.d(t,{J:()=>c});var r,s=o(4792),i=o(90237),l=(o(53966),o(44208),o(87811),o(49186),o(93223)),n=o(40608);let a=r=class extends s.A{constructor(e){super(e),this.type="sketch"}clone(){return new r(this.cloneProperties())}};(0,i._)([(0,l.e)({sketch:"sketch"},{readOnly:!0})],a.prototype,"type",void 0),a=r=(0,i._)([(0,n.$)("esri.symbols.edges.SketchEdges3D")],a);const y=a;var p=o(39065);const c={types:{key:"type",base:s.A,typeMap:{solid:p.A,sketch:y}},json:{write:!0}}},57212:(e,t,o)=>{o.d(t,{V:()=>a});var r,s=o(90237),i=o(69622),l=o(10107),n=(o(44208),o(53966),o(87811),o(40608));let a=r=class extends i.A{constructor(){super(...arguments),this.url=""}clone(){return new r({url:this.url})}};(0,s._)([(0,l.MZ)({type:String})],a.prototype,"url",void 0),a=r=(0,s._)([(0,n.$)("esri.symbols.support.Thumbnail")],a)},58185:(e,t,o)=>{o.d(t,{A:()=>z});var r=o(90237),s=o(5503),i=o(62885),l=o(53966),n=o(84952),a=o(67076),y=o(10107),p=o(79901),c=(o(44208),o(87811),o(36005)),h=o(40608),u=o(43937),d=o(20655),m=o(97159),b=o(26449),w=o(27845),v=o(18574),f=o(11506),g=o(87403),A=o(66525),_=o(20378),M=o(3904),S=o(10224),x=o(34723),Z=o(98751),j=o(57212);const L={icon:v.A,object:g.A,line:f.A,path:A.A,fill:w.A,extrude:b.A,text:S.A,water:x.A},O=s.A.ofType({base:M.A,key:"type",typeMap:L,errorContext:"symbol-layer"});let z=class extends _.A{constructor(e){super(e),this.styleOrigin=null,this.thumbnail=null,this.type=null;const t=this.__accessor__&&this.__accessor__.metadata&&this.__accessor__.metadata.symbolLayers,o=t?.type,r=o||s.A;this._set("symbolLayers",new r)}get color(){return null}set color(e){this.constructed&&l.A.getLogger(this).error("Symbol3D does not support colors on the symbol level. Colors may be set on individual symbol layer materials instead.")}set symbolLayers(e){(0,i.V)(e,this._get("symbolLayers"))}readStyleOrigin(e,t,o){if(e.styleUrl&&e.name){const t=(0,m.f)(e.styleUrl,o);return new Z.A({styleUrl:t,name:e.name})}if(e.styleName&&e.name)return new Z.A({portal:o?.portal||d.A.getDefault(),styleName:e.styleName,name:e.name});o?.messages&&o.messages.push(new a.A("symbol3d:incomplete-style-origin","Style origin requires either a 'styleUrl' or 'styleName' and a 'name' property",{context:o,definition:e}))}writeStyleOrigin(e,t,o,r){if(e.styleUrl&&e.name){let o=(0,m.t)(e.styleUrl,r);(0,n.oP)(o)&&(o=(0,n.S8)(o)),t.styleOrigin={styleUrl:o,name:e.name}}else e.styleName&&e.name&&(e.portal&&r?.portal&&!(0,n.ut)(e.portal.restUrl,r.portal.restUrl)?r?.messages&&r.messages.push(new a.A("symbol:cross-portal","The symbol style origin cannot be persisted because it refers to an item on a different portal than the one being saved to.",{symbol:this})):t.styleOrigin={styleName:e.styleName,name:e.name})}normalizeCtorArgs(e){return e instanceof M.A||e&&L[e.type]?{symbolLayers:[e]}:Array.isArray(e)?{symbolLayers:e}:e}};(0,r._)([(0,y.MZ)({json:{read:!1,write:!1}})],z.prototype,"color",null),(0,r._)([(0,y.MZ)({type:O,nonNullable:!0,json:{write:!0}}),(0,p.w)(i.H)],z.prototype,"symbolLayers",null),(0,r._)([(0,y.MZ)({type:Z.A})],z.prototype,"styleOrigin",void 0),(0,r._)([(0,c.w)("styleOrigin")],z.prototype,"readStyleOrigin",null),(0,r._)([(0,u.K)("styleOrigin",{"styleOrigin.styleUrl":{type:String},"styleOrigin.styleName":{type:String},"styleOrigin.name":{type:String}})],z.prototype,"writeStyleOrigin",null),(0,r._)([(0,y.MZ)({type:j.V,json:{read:!1}})],z.prototype,"thumbnail",void 0),(0,r._)([(0,y.MZ)({type:["point-3d","line-3d","polygon-3d","mesh-3d","label-3d"],readOnly:!0})],z.prototype,"type",void 0),z=(0,r._)([(0,h.$)("esri.symbols.Symbol3D")],z)},58592:(e,t,o)=>{o.d(t,{A:()=>u});var r,s=o(90237),i=o(4718),l=o(90629),n=o(10107),a=(o(44208),o(53966),o(93223)),y=o(36005),p=o(40608),c=o(89420),h=o(77040);let u=r=class extends c.A{constructor(...e){super(...e),this.color=null,this.type="picture-marker",this.url=null,this.source=null,this.height=12,this.width=12,this.size=null}normalizeCtorArgs(e,t,o){if(e&&"string"!=typeof e&&null==e.imageData)return e;const r={};return e&&(r.url=e),null!=t&&(r.width=(0,l.cr)(t)),null!=o&&(r.height=(0,l.cr)(o)),r}readHeight(e,t){return t.size||e}readWidth(e,t){return t.size||e}clone(){const e=new r({angle:this.angle,height:this.height,url:this.url,width:this.width,xoffset:this.xoffset,yoffset:this.yoffset});return e._set("source",(0,i.o8)(this.source)),e}hash(){return`${super.hash()}.${this.height}.${this.url}.${this.width}`}};(0,s._)([(0,n.MZ)({json:{write:!1}})],u.prototype,"color",void 0),(0,s._)([(0,a.e)({esriPMS:"picture-marker"},{readOnly:!0})],u.prototype,"type",void 0),(0,s._)([(0,n.MZ)(h.ku)],u.prototype,"url",void 0),(0,s._)([(0,n.MZ)(h.k7)],u.prototype,"source",void 0),(0,s._)([(0,n.MZ)({type:Number,cast:l.cr,json:{write:!0}})],u.prototype,"height",void 0),(0,s._)([(0,y.w)("height",["height","size"])],u.prototype,"readHeight",null),(0,s._)([(0,n.MZ)({type:Number,cast:l.cr,json:{write:!0}})],u.prototype,"width",void 0),(0,s._)([(0,n.MZ)({json:{write:!1}})],u.prototype,"size",void 0),u=r=(0,s._)([(0,p.$)("esri.symbols.PictureMarkerSymbol")],u)},59483:(e,t,o)=>{o.d(t,{LH:()=>l,Yq:()=>i,oG:()=>n});var r=o(4595),s=o(8893);function i(e){if(!e)return!1;const t=e.verticalOffset;return!(!t||t.screenLength<=0||null!=t.maxWorldLength&&t.maxWorldLength<=0)}function l(e){if(!e||!e.supportsCallout||!e.supportsCallout())return!1;const t=e.callout;return!!t?.visible&&!!i(e)}const n={types:{key:"type",base:r.A,typeMap:{line:s.A}},json:{write:!0}}},62885:(e,t,o)=>{o.d(t,{H:()=>i,V:()=>s});var r=o(5503);function s(e,t,o=r.A){return t||(t=new o),t===e||(t.removeAll(),(s=e)&&(Array.isArray(s)||"items"in s&&Array.isArray(s.items))?t.addMany(e):e&&t.add(e)),t;var s}function i(e){return e}},65365:(e,t,o)=>{o.d(t,{A:()=>_});var r,s=o(90237),i=o(5503),l=o(51447),n=o(4718),a=o(53966),y=o(36708),p=o(10107),c=(o(44208),o(93223)),h=o(40608),u=o(26449),d=o(27845),m=o(18574),b=o(11506),w=o(87403),v=o(58185),f=o(10224),g=o(34723);const A=i.A.ofType({base:null,key:"type",typeMap:{extrude:u.A,fill:d.A,icon:m.A,line:b.A,object:w.A,text:f.A,water:g.A}});let _=r=class extends v.A{constructor(e){super(e),this.symbolLayers=new A,this.type="polygon-3d"}initialize(){const e=e=>{"line"===e.type&&(0,l.io)(a.A.getLogger(this),"LineSymbol3DLayer can not be used as a SymbolLayer with a PolygonSymbol3D symbol anymore.",{replacement:"Use FillSymbol3DLayer.outline instead.",version:"4.28"}),"text"===e.type&&(0,l.io)(a.A.getLogger(this),"TextSymbol3DLayer can not be used as a SymbolLayer with a PolygonSymbol3D symbol anymore.",{replacement:"Use Labels instead.",version:"4.28"})};for(const t of this.symbolLayers)e(t);this.addHandles((0,y.on)((()=>this.symbolLayers),"after-add",(({item:t})=>e(t)),y.OH))}clone(){return new r({styleOrigin:(0,n.o8)(this.styleOrigin),symbolLayers:(0,n.o8)(this.symbolLayers),thumbnail:(0,n.o8)(this.thumbnail)})}static fromJSON(e){const t=new r;if(t.read(e),2===t.symbolLayers.length&&"fill"===t.symbolLayers.at(0).type&&"line"===t.symbolLayers.at(1).type){const o=t.symbolLayers.at(0),r=t.symbolLayers.at(1);!r.enabled||e.symbolLayers?.[1]&&!1===e.symbolLayers[1].enable||(o.outline={size:r.size,color:null!=r.material?r.material.color:null}),t.symbolLayers.removeAt(1)}return t}static fromSimpleFillSymbol(e){return new r({symbolLayers:new i.A([d.A.fromSimpleFillSymbol(e)])})}};(0,s._)([(0,p.MZ)({type:A,json:{write:!0}})],_.prototype,"symbolLayers",void 0),(0,s._)([(0,c.e)({PolygonSymbol3D:"polygon-3d"},{readOnly:!0})],_.prototype,"type",void 0),_=r=(0,s._)([(0,h.$)("esri.symbols.PolygonSymbol3D")],_)},66525:(e,t,o)=>{o.d(t,{A:()=>h});var r,s=o(90237),i=o(10107),l=(o(44208),o(53966),o(87811),o(93223)),n=o(36005),a=o(40608),y=o(3904),p=o(28975),c=o(8887);let h=class extends y.A{static{r=this}constructor(e){super(e),this.material=null,this.castShadows=!0,this.type="path",this.profile="circle",this.join="miter",this.cap="butt",this.width=void 0,this.height=void 0,this.anchor="center",this.profileRotation="all"}readWidth(e,t){return null!=e?e:null==t.height&&null!=t.size?t.size:void 0}readHeight(e,t){return null!=e?e:null==t.width&&null!=t.size?t.size:void 0}clone(){return new r({enabled:this.enabled,material:null!=this.material?this.material.clone():null,castShadows:this.castShadows,profile:this.profile,join:this.join,cap:this.cap,width:this.width,height:this.height,profileRotation:this.profileRotation,anchor:this.anchor})}};(0,s._)([(0,i.MZ)({type:p.N,json:{write:!0}})],h.prototype,"material",void 0),(0,s._)([(0,i.MZ)({type:Boolean,nonNullable:!0,json:{write:!0,default:!0}})],h.prototype,"castShadows",void 0),(0,s._)([(0,l.e)({Path:"path"},{readOnly:!0})],h.prototype,"type",void 0),(0,s._)([(0,i.MZ)({type:["circle","quad"],json:{write:!0,default:"circle"}})],h.prototype,"profile",void 0),(0,s._)([(0,i.MZ)({type:c.e,json:{write:!0,default:"miter"}})],h.prototype,"join",void 0),(0,s._)([(0,i.MZ)({type:c.Nv,json:{write:!0,default:"butt"}})],h.prototype,"cap",void 0),(0,s._)([(0,i.MZ)({type:Number,json:{write:{enabled:!0,target:{width:{type:Number},size:{type:Number}}}}})],h.prototype,"width",void 0),(0,s._)([(0,n.w)("width",["width","size","height"])],h.prototype,"readWidth",null),(0,s._)([(0,i.MZ)({type:Number,json:{write:!0}})],h.prototype,"height",void 0),(0,s._)([(0,n.w)("height",["height","size","width"])],h.prototype,"readHeight",null),(0,s._)([(0,i.MZ)({type:["center","bottom","top"],json:{write:!0,default:"center"}})],h.prototype,"anchor",void 0),(0,s._)([(0,i.MZ)({type:["heading","all"],json:{write:!0,default:"all"}})],h.prototype,"profileRotation",void 0),h=r=(0,s._)([(0,a.$)("esri.symbols.PathSymbol3DLayer")],h)},67222:(e,t,o)=>{o.d(t,{EW:()=>y,YJ:()=>c,pI:()=>p});var r=o(68197),s=o(90629),i=o(56507),l=o(78553);function n(e,t){const o=null!=t.transparency?(0,l.D)(t.transparency):1,s=t.color;return s&&Array.isArray(s)?new r.A([s[0]||0,s[1]||0,s[2]||0,o]):null}function a(e,t){t.color=e.toJSON().slice(0,3);const o=(0,l.p)(e.a);0!==o&&(t.transparency=o)}function y(e){return{type:r.A,nonNullable:e?.nonNullable,json:{type:[i.jz],default:null,read:{source:["color","transparency"],reader:n},write:{target:{color:{type:[i.jz],isRequired:e?.colorRequiredOnWrite},transparency:{type:i.jz}},writer:a}}}}const p={type:Number,cast:s.cr,json:{write:!0}};var c,h;(h=c||(c={}))[h.Emissive=0]="Emissive",h[h.Color=1]="Color"},68548:(e,t,o)=>{o.d(t,{A:()=>u});var r,s=o(90237),i=o(5503),l=o(4718),n=o(10107),a=(o(44208),o(53966),o(93223)),y=o(40608),p=o(27845),c=o(58185);const h=i.A.ofType({base:null,key:"type",typeMap:{fill:p.A}});let u=r=class extends c.A{constructor(e){super(e),this.symbolLayers=new h,this.type="mesh-3d"}clone(){return new r({styleOrigin:(0,l.o8)(this.styleOrigin),symbolLayers:(0,l.o8)(this.symbolLayers),thumbnail:(0,l.o8)(this.thumbnail)})}static fromSimpleFillSymbol(e){return new r({symbolLayers:new i.A([p.A.fromSimpleFillSymbol(e)])})}};(0,s._)([(0,n.MZ)({type:h})],u.prototype,"symbolLayers",void 0),(0,s._)([(0,a.e)({MeshSymbol3D:"mesh-3d"},{readOnly:!0})],u.prototype,"type",void 0),u=r=(0,s._)([(0,y.$)("esri.symbols.MeshSymbol3D")],u)},75981:(e,t,o)=>{o.d(t,{A:()=>f});var r,s=o(90237),i=o(68197),l=o(5503),n=o(4718),a=o(10107),y=(o(44208),o(53966),o(93223)),p=o(40608),c=o(18574),h=o(87403),u=o(58185),d=o(10224),m=o(59483),b=o(8893),w=o(4900);const v=l.A.ofType({base:null,key:"type",typeMap:{icon:c.A,object:h.A,text:d.A}});let f=r=class extends u.A{constructor(e){super(e),this.verticalOffset=null,this.callout=null,this.symbolLayers=new v,this.type="point-3d"}supportsCallout(){if((this.symbolLayers?this.symbolLayers.length:0)<1)return!1;for(const e of this.symbolLayers.items)switch(e.type){case"icon":case"text":case"object":continue;default:return!1}return!0}hasVisibleCallout(){return(0,m.LH)(this)}hasVisibleVerticalOffset(){return(0,m.Yq)(this)}clone(){return new r({verticalOffset:(0,n.o8)(this.verticalOffset),callout:(0,n.o8)(this.callout),styleOrigin:(0,n.o8)(this.styleOrigin),symbolLayers:(0,n.o8)(this.symbolLayers),thumbnail:(0,n.o8)(this.thumbnail)})}static fromSimpleMarkerSymbol(e){return new r({symbolLayers:new l.A([c.A.fromSimpleMarkerSymbol(e)])})}static fromPictureMarkerSymbol(e){return new r({symbolLayers:new l.A([c.A.fromPictureMarkerSymbol(e)])})}static fromCIMSymbol(e){const t=e.data?.symbol?.type;if("CIMPointSymbol"!==t)return null;const o=e.data.symbol;return new r(o?.callout?{symbolLayers:new l.A([c.A.fromCIMSymbol(e)]),callout:new b.A({size:.5,color:new i.A([0,0,0])}),verticalOffset:new w.A({screenLength:40})}:{symbolLayers:new l.A([c.A.fromCIMSymbol(e)])})}static fromTextSymbol(e){return new r({symbolLayers:new l.A([d.A.fromTextSymbol(e)])})}};(0,s._)([(0,a.MZ)({type:w.A,json:{write:!0}})],f.prototype,"verticalOffset",void 0),(0,s._)([(0,a.MZ)(m.oG)],f.prototype,"callout",void 0),(0,s._)([(0,a.MZ)({type:v,json:{origins:{"web-scene":{write:!0}}}})],f.prototype,"symbolLayers",void 0),(0,s._)([(0,y.e)({PointSymbol3D:"point-3d"},{readOnly:!0})],f.prototype,"type",void 0),f=r=(0,s._)([(0,p.$)("esri.symbols.PointSymbol3D")],f)},77040:(e,t,o)=>{o.d(t,{k7:()=>n,ku:()=>l});var r=o(84952),s=o(97159);function i(e,t){if(!(0,r.oP)(e)){const o=function(e){if(!e)return null;const{origin:t,layer:o}=e;if("service"!==t&&"portal-item"!==t)return null;const r=o?.type;return"feature"===r||"stream"===r?o.parsedUrl?.path:"map-image"===r||"tile"===r?e.url?.path:null}(t);if(o)return(0,r.fj)(o,"images",e)}return(0,s.f)(e,t)}const l={json:{read:{source:["imageData","url"],reader:function(e,t,o){return t.imageData?(0,r.Hg)({mediaType:t.contentType||"image/png",isBase64:!0,data:t.imageData}):i(t.url,o)}},write:{writer(e,t,o,i){!function(e,t,o,i){if((0,r.DB)(e)){const l=(0,r.r$)(e);if(!l)return;t.contentType=l.mediaType,t.imageData=l.data,o&&o.imageData===t.imageData&&o.url&&(0,s.w)(o.url,t,"url",i)}else(0,s.w)(e,t,"url",i)}(e,t,this.source,i)}}}},n={readOnly:!0,json:{read:{source:["imageData","url"],reader(e,t,o){const r={};return t.imageData&&(r.imageData=t.imageData),t.contentType&&(r.contentType=t.contentType),t.url&&(r.url=i(t.url,o)),r}}}}},87403:(e,t,o)=>{o.d(t,{A:()=>d});var r,s=o(90237),i=o(10107),l=(o(44208),o(53966),o(87811),o(93223)),n=o(40608),a=o(3904),y=o(30809),p=o(69622);let c=r=class extends p.A{constructor(){super(...arguments),this.x=0,this.y=0,this.z=0}clone(){return new r({x:this.x,y:this.y,z:this.z})}};(0,s._)([(0,i.MZ)({type:Number})],c.prototype,"x",void 0),(0,s._)([(0,i.MZ)({type:Number})],c.prototype,"y",void 0),(0,s._)([(0,i.MZ)({type:Number})],c.prototype,"z",void 0),c=r=(0,s._)([(0,n.$)("esri.symbols.support.Symbol3DAnchorPosition3D")],c);var h,u=o(28975);let d=class extends a.A{static{h=this}constructor(e){super(e),this.material=null,this.castShadows=!0,this.resource=null,this.type="object",this.width=void 0,this.height=void 0,this.depth=void 0,this.anchor=void 0,this.anchorPosition=void 0,this.heading=void 0,this.tilt=void 0,this.roll=void 0}clone(){return new h({heading:this.heading,tilt:this.tilt,roll:this.roll,anchor:this.anchor,anchorPosition:this.anchorPosition?.clone(),depth:this.depth,enabled:this.enabled,height:this.height,material:this.material?.clone()??null,castShadows:this.castShadows,resource:this.resource?.clone(),width:this.width})}get isPrimitive(){return!this.resource||"string"!=typeof this.resource.href}};(0,s._)([(0,i.MZ)({type:u.N,json:{write:!0}})],d.prototype,"material",void 0),(0,s._)([(0,i.MZ)({type:Boolean,nonNullable:!0,json:{write:!0,default:!0}})],d.prototype,"castShadows",void 0),(0,s._)([(0,i.MZ)({type:y.E,json:{write:!0}})],d.prototype,"resource",void 0),(0,s._)([(0,l.e)({Object:"object"},{readOnly:!0})],d.prototype,"type",void 0),(0,s._)([(0,i.MZ)({type:Number,json:{write:!0}})],d.prototype,"width",void 0),(0,s._)([(0,i.MZ)({type:Number,json:{write:!0}})],d.prototype,"height",void 0),(0,s._)([(0,i.MZ)({type:Number,json:{write:!0}})],d.prototype,"depth",void 0),(0,s._)([(0,l.e)({center:"center",top:"top",bottom:"bottom",origin:"origin",relative:"relative"},{default:"origin"})],d.prototype,"anchor",void 0),(0,s._)([(0,i.MZ)({type:c,json:{type:[Number],read:{reader:e=>new c({x:e[0],y:e[1],z:e[2]})},write:{writer:(e,t)=>{t.anchorPosition=[e.x,e.y,e.z]},overridePolicy(){return{enabled:"relative"===this.anchor}}}}})],d.prototype,"anchorPosition",void 0),(0,s._)([(0,i.MZ)({type:Number,json:{write:!0}})],d.prototype,"heading",void 0),(0,s._)([(0,i.MZ)({type:Number,json:{write:!0}})],d.prototype,"tilt",void 0),(0,s._)([(0,i.MZ)({type:Number,json:{write:!0}})],d.prototype,"roll",void 0),(0,s._)([(0,i.MZ)({readOnly:!0})],d.prototype,"isPrimitive",null),d=h=(0,s._)([(0,n.$)("esri.symbols.ObjectSymbol3DLayer")],d)},97887:(e,t,o)=>{o.d(t,{A:()=>m});var r,s=o(90237),i=o(5503),l=o(4718),n=o(10107),a=(o(44208),o(53966),o(93223)),y=o(40608),p=o(11506),c=o(66525),h=o(58185);const u=i.A.ofType({base:null,key:"type",typeMap:{line:p.A,path:c.A}}),d=i.A.ofType({base:null,key:"type",typeMap:{line:p.A,path:c.A}});let m=r=class extends h.A{constructor(e){super(e),this.symbolLayers=new u,this.type="line-3d"}clone(){return new r({styleOrigin:(0,l.o8)(this.styleOrigin),symbolLayers:(0,l.o8)(this.symbolLayers),thumbnail:(0,l.o8)(this.thumbnail)})}static fromSimpleLineSymbol(e){return new r({symbolLayers:new i.A([p.A.fromSimpleLineSymbol(e)])})}};(0,s._)([(0,n.MZ)({type:u,json:{type:d}})],m.prototype,"symbolLayers",void 0),(0,s._)([(0,a.e)({LineSymbol3D:"line-3d"},{readOnly:!0})],m.prototype,"type",void 0),m=r=(0,s._)([(0,y.$)("esri.symbols.LineSymbol3D")],m)},98751:(e,t,o)=>{o.d(t,{A:()=>y});var r,s=o(90237),i=o(69622),l=o(10107),n=(o(44208),o(53966),o(87811),o(40608)),a=o(20655);let y=r=class extends i.A{constructor(e){super(e),this.name=null,this.styleUrl=null,this.styleName=null,this.portal=null}clone(){return new r({name:this.name,styleUrl:this.styleUrl,styleName:this.styleName,portal:this.portal})}};(0,s._)([(0,l.MZ)({type:String})],y.prototype,"name",void 0),(0,s._)([(0,l.MZ)({type:String})],y.prototype,"styleUrl",void 0),(0,s._)([(0,l.MZ)({type:String})],y.prototype,"styleName",void 0),(0,s._)([(0,l.MZ)({type:a.A})],y.prototype,"portal",void 0),y=r=(0,s._)([(0,n.$)("esri.symbols.support.StyleOrigin")],y)}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2042,7136],{4197:(e,t,n)=>{n.d(t,{jh:()=>r,l5:()=>o,xm:()=>s});var i=n(34275);function r(e,t=!1){return e<=i.y9?t?new Array(e).fill(0):new Array(e):new Float64Array(e)}function s(e){return((0,i.iu)(e)?e.byteLength/8:e.length)<=i.y9?Array.from(e):new Float64Array(e)}function o(e,t,n){return Array.isArray(e)?e.slice(t,t+n):e.subarray(t,t+n)}},13069:(e,t,n)=>{n.d(t,{AG:()=>l,lk:()=>r,vD:()=>o,yS:()=>s});const i="randomUUID"in crypto;function r(){if(i)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function s(){return`{${r().toUpperCase()}}`}function o(){return`{${r()}}`}function l(e){const t=e.toUpperCase();return"{"!==e[0]?`{${t}}`:t}},17136:(e,t,n)=>{n.d(t,{O7:()=>T,el:()=>x});var i=n(92602),r=n(49186),s=n(53966),o=n(39829),l=n(82799),a=n(80754),u=n(21325),p=n(28735),c=n(78888),h=n(65864),f=n(2272),m=n(84952),y=n(92300);const g=()=>s.A.getLogger("esri.geometry.support.normalizeUtils");function d(e){return"polygon"===e[0].type}function M(e){return"polyline"===e[0].type}function _(e,t,n){if(t){const t=function(e,t){if(!(e instanceof l.A||e instanceof o.A)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw g().error(e),new r.A("internal:geometry",e)}const n=(0,a.r8)(e),i=[];for(const e of n){const n=[];i.push(n),n.push([e[0][0],e[0][1]]);for(let i=0;i<e.length-1;i++){const r=e[i][0],s=e[i][1],o=e[i+1][0],l=e[i+1][1],a=Math.sqrt((o-r)*(o-r)+(l-s)*(l-s)),u=(l-s)/a,p=(o-r)/a,c=a/t;if(c>1){for(let e=1;e<=c-1;e++){const i=e*t,o=p*i+r,l=u*i+s;n.push([o,l])}const e=(a+Math.floor(c-1)*t)/2,i=p*e+r,o=u*e+s;n.push([i,o])}n.push([o,l])}}return function(e){return"polygon"===e.type}(e)?new o.A({rings:i,spatialReference:e.spatialReference}):new l.A({paths:i,spatialReference:e.spatialReference})}(e,1e6);e=(0,p.ci)(t,!0)}return n&&(e=(0,a.kS)(e,n)),e}function b(e,t,n){if(Array.isArray(e)){const i=e[0];if(i>t){const n=(0,a.kd)(i,t);e[0]=i+n*(-2*t)}else if(i<n){const t=(0,a.kd)(i,n);e[0]=i+t*(-2*n)}}else{const i=e.x;if(i>t){const n=(0,a.kd)(i,t);e=e.clone().offset(n*(-2*t),0)}else if(i<n){const t=(0,a.kd)(i,n);e=e.clone().offset(t*(-2*n),0)}}return e}function F(e,t){let n=-1;for(let i=0;i<t.cutIndexes.length;i++){const r=t.cutIndexes[i],s=t.geometries[i],o=(0,a.r8)(s);for(let e=0;e<o.length;e++){const t=o[e];t.some((n=>{if(n[0]<180)return!0;{let n=0;for(let e=0;e<t.length;e++){const i=t[e][0];n=i>n?i:n}n=Number(n.toFixed(9));const i=-360*(0,a.kd)(n,180);for(let n=0;n<t.length;n++){const t=s.getPoint(e,n);s.setPoint(e,n,t.clone().offset(i,0))}return!0}}))}if(r===n){if(d(e))for(const t of(0,a.r8)(s))e[r]=e[r].addRing(t);else if(M(e))for(const t of(0,a.r8)(s))e[r]=e[r].addPath(t)}else n=r,e[r]=s}return e}async function x(e,t,n){if(!Array.isArray(e))return x([e],t);t&&"string"!=typeof t&&g().warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const r="string"==typeof t?t:t?.url??i.A.geometryServiceUrl;let s,d,M,T,v,A,w,S,N=0;const R=[],Z=[];for(const t of e)if(null!=t)if(s||(s=t.spatialReference,d=(0,u.Vp)(s),M=s.isWebMercator,A=M?102100:4326,T=a.j7[A].maxX,v=a.j7[A].minX,w=a.j7[A].plus180Line,S=a.j7[A].minus180Line),d)if("mesh"===t.type)Z.push(t);else if("point"===t.type)Z.push(b(t.clone(),T,v));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>b(e,T,v))),Z.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,d);Z.push(e.rings?new o.A(e):e)}else if(t.extent){const e=t.extent,n=(0,a.kd)(e.xmin,v)*(2*T);let i=0===n?t.clone():(0,a.kS)(t.clone(),n);e.offset(n,0);let{xmin:r,xmax:s}=e;r=Number(r.toFixed(9)),s=Number(s.toFixed(9)),e.intersects(w)&&s!==T?(N=s>N?s:N,i=_(i,M),R.push(i),Z.push("cut")):e.intersects(S)&&r!==v?(N=s*(2*T)>N?s*(2*T):N,i=_(i,M,360),R.push(i),Z.push("cut")):Z.push(i)}else Z.push(t.clone());else Z.push(t);else Z.push(t);let G=(0,a.kd)(N,T),I=-90;const O=G,L=new l.A;for(;G>0;){const e=360*G-180;L.addPath([[e,I],[e,-1*I]]),I*=-1,G--}if(R.length>0&&O>0){const t=F(R,await async function(e,t,n,i){const r=(0,f.Dl)(e),s=t[0].spatialReference,o={...i,responseType:"json",query:{...r.query,f:"json",sr:(0,u.YX)(s),target:JSON.stringify({geometryType:(0,h.$B)(t[0]),geometries:t}),cutter:JSON.stringify(n)}},l=await(0,c.A)(r.path+"/cut",o),{cutIndexes:a,geometries:p=[]}=l.data;return{cutIndexes:a,geometries:p.map((e=>{const t=(0,h.rS)(e);return t.spatialReference=s,t}))}}(r,R,L,n)),i=[],s=[];for(let n=0;n<Z.length;n++){const r=Z[n];if("cut"!==r)s.push(r);else{const r=t.shift(),o=e[n];null!=o&&"polygon"===o.type&&o.rings&&o.rings.length>1&&r.rings.length>=o.rings.length?(i.push(r),s.push("simplify")):s.push(M?(0,p.Gh)(r):r)}}if(!i.length)return s;const o=await async function(e,t,n){const i="string"==typeof e?(0,m.An)(e):e,r=t[0].spatialReference,s=(0,h.$B)(t[0]),o={...n,query:{...i.query,f:"json",sr:(0,u.YX)(r),geometries:JSON.stringify((0,y.X)(t))}},{data:l}=await(0,c.A)(i.path+"/simplify",o);return(0,y.V)(l.geometries,s,r)}(r,i,n),l=[];for(let e=0;e<s.length;e++){const t=s[e];"simplify"!==t?l.push(t):l.push(M?(0,p.Gh)(o.shift()):o.shift())}return l}const j=[];for(let e=0;e<Z.length;e++){const t=Z[e];if("cut"!==t)j.push(t);else{const e=R.shift();j.push(!0===M?(0,p.Gh)(e):e)}}return j}function T(e,t,n){const i=(0,u.Vp)(n);if(null==i)return e;const[r,s]=i.valid,o=2*s;let l=0,a=0;t>s?l=Math.ceil(Math.abs(t-s)/o):t<r&&(l=-Math.ceil(Math.abs(t-r)/o)),e>s?a=Math.ceil(Math.abs(e-s)/o):e<r&&(a=-Math.ceil(Math.abs(e-r)/o));let p=e+(l-a)*o;const c=p-t;return c>s?p-=o:c<r&&(p+=o),p}},22671:(e,t,n)=>{n.d(t,{A:()=>M});var i,r=n(90237),s=n(52106),o=n(66552),l=n(25482),a=n(4718),u=n(10107),p=(n(44208),n(53966),n(36005)),c=n(40608),h=n(43937),f=n(16930),m=n(65864),y=n(50498),g=n(20437);const d=new o.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let M=i=class extends l.A{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){return this.readFeaturesWithClass(e,t,s.A)}writeGeometryType(e,t,n,i){if(e)return void d.write(e,t,n,i);const{features:r}=this;if(r)for(const e of r)if(null!=e?.geometry)return void d.write(e.geometry.type,t,n,i)}readQueryGeometry(e,t){if(!e)return null;const n=!!e.spatialReference,i=(0,m.rS)(e);return i&&!n&&t.spatialReference&&(i.spatialReference=f.A.fromJSON(t.spatialReference)),i}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:n}=this;if(n)for(const e of n)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new i(this.cloneProperties())}cloneProperties(){return(0,a.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let n=0;n<t.features.length;n++){const i=t.features[n];if(i.geometry){const t=e?.[n];i.geometry=t?.toJSON()||i.geometry}}return t}quantize(e){const{scale:[t,n],translate:[i,r]}=e,s=this.features,o=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-i)/t)),(e=>Math.round((r-e)/n)));for(let e=0,t=s.length;e<t;e++)o?.(s[e].geometry)||(s.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:n}=this;if(!n)return this;const{translate:[i,r],scale:[s,o]}=n;let l=null,a=null;if(this.hasZ&&null!=n?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=n;l=n=>n*t+e}if(this.hasM&&null!=n?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=n;a=n=>null==n?n:n*t+e}const u=this._getHydrationFunction(e,(e=>e*s+i),(e=>r-e*o),l,a);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}readFeaturesWithClass(e,t,n){const i=f.A.fromJSON(t.spatialReference),r=[];for(let t=0;t<e.length;t++){const s=e[t],o=n.fromJSON(s),l=s.geometry?.spatialReference;null==o.geometry||l||(o.geometry.spatialReference=i);const a=s.aggregateGeometries,u=o.aggregateGeometries;if(a&&null!=u)for(const e in u){const t=u[e],n=a[e],r=n?.spatialReference;null==t||r||(t.spatialReference=i)}r.push(o)}return r}_quantizePoints(e,t,n){let i,r;const s=[];for(let o=0,l=e.length;o<l;o++){const l=e[o];if(o>0){const e=t(l[0]),o=n(l[1]);e===i&&o===r||(s.push([e-i,o-r]),i=e,r=o)}else i=t(l[0]),r=n(l[1]),s.push([i,r])}return s.length>0?s:null}_getQuantizationFunction(e,t,n){return"point"===e?e=>(e.x=t(e.x),e.y=n(e.y),e):"polyline"===e||"polygon"===e?e=>{const i=(0,m.Bi)(e)?e.rings:e.paths,r=[];for(let e=0,s=i.length;e<s;e++){const s=i[e],o=this._quantizePoints(s,t,n);o&&r.push(o)}return r.length>0?((0,m.Bi)(e)?e.rings=r:e.paths=r,e):null}:"multipoint"===e?e=>{const i=this._quantizePoints(e.points,t,n);return i&&i.length>0?(e.points=i,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,n,i,r){return"point"===e?e=>{e.x=t(e.x),e.y=n(e.y),i&&(e.z=i(e.z))}:"polyline"===e||"polygon"===e?e=>{const s=(0,m.Bi)(e)?e.rings:e.paths;let o,l;for(let e=0,i=s.length;e<i;e++){const i=s[e];for(let e=0,r=i.length;e<r;e++){const r=i[e];e>0?(o+=r[0],l+=r[1]):(o=r[0],l=r[1]),r[0]=t(o),r[1]=n(l)}}if(i&&r)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=i(n[2]),n[3]=r(n[3])}}else if(i)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=i(n[2])}}else if(r)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,n=t.length;e<n;e++){const n=t[e];n[2]=r(n[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=n(e.ymin),e.xmax=t(e.xmax),e.ymax=n(e.ymax),i&&null!=e.zmax&&null!=e.zmin&&(e.zmax=i(e.zmax),e.zmin=i(e.zmin)),r&&null!=e.mmax&&null!=e.mmin&&(e.mmax=r(e.mmax),e.mmin=r(e.mmin))}:"multipoint"===e?e=>{const s=e.points;let o,l;for(let e=0,i=s.length;e<i;e++){const i=s[e];e>0?(o+=i[0],l+=i[1]):(o=i[0],l=i[1]),i[0]=t(o),i[1]=n(l)}if(i&&r)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=i(t[2]),t[3]=r(t[3])}else if(i)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=i(t[2])}else if(r)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=r(t[2])}}:null}};(0,r._)([(0,u.MZ)({type:String,json:{write:!0}})],M.prototype,"displayFieldName",void 0),(0,r._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],M.prototype,"exceededTransferLimit",void 0),(0,r._)([(0,u.MZ)({type:[s.A],json:{write:!0}})],M.prototype,"features",void 0),(0,r._)([(0,p.w)("features")],M.prototype,"readFeatures",null),(0,r._)([(0,u.MZ)({type:[g.A],json:{write:!0}})],M.prototype,"fields",void 0),(0,r._)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:d.read}}})],M.prototype,"geometryType",void 0),(0,r._)([(0,h.K)("geometryType")],M.prototype,"writeGeometryType",null),(0,r._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],M.prototype,"hasM",void 0),(0,r._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],M.prototype,"hasZ",void 0),(0,r._)([(0,u.MZ)({types:y.yR,json:{write:!0}})],M.prototype,"queryGeometry",void 0),(0,r._)([(0,p.w)("queryGeometry")],M.prototype,"readQueryGeometry",null),(0,r._)([(0,u.MZ)({type:f.A,json:{write:!0}})],M.prototype,"spatialReference",void 0),(0,r._)([(0,h.K)("spatialReference")],M.prototype,"writeSpatialReference",null),(0,r._)([(0,u.MZ)({json:{write:!0}})],M.prototype,"transform",void 0),M=i=(0,r._)([(0,c.$)("esri.rest.support.FeatureSet")],M),M.prototype.toJSON.isDefaultToJSON=!0},50498:(e,t,n)=>{n.d(t,{Ye:()=>c,gy:()=>p,yR:()=>h});var i=n(66552),r=n(5443),s=n(91075),o=n(48526),l=n(86738),a=n(39829),u=n(82799);const p=(0,i.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),c=(0,i.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"}),h={base:s.A,key:"type",typeMap:{extent:r.A,multipoint:o.A,point:l.A,polyline:u.A,polygon:a.A}}},52106:(e,t,n)=>{n.d(t,{A:()=>b});var i,r=n(90237),s=n(13874),o=n(69540),l=n(51447),a=n(25482),u=n(53966),p=n(36708),c=n(24326),h=n(10107),f=(n(44208),n(87811),n(40608)),m=n(12195),y=n(65864),g=n(50498),d=n(54339),M=n(33910);function _(e){if(null==e)return null;const t={};for(const n in e){const i=e[n];i&&(t[n]=i.toJSON())}return 0!==Object.keys(t).length?t:null}let b=class extends(o.A.ClonableMixin(a.A)){static{i=this}constructor(e){super(e),this.isAggregate=!1,this.layer=null,this.origin=null,this.sourceLayer=null,this._version=0,Object.defineProperty(this,"uid",{value:(0,c.c)(),configurable:!0}),Object.defineProperty(this,"_lastMeshTransform",{value:{},configurable:!0,writable:!0,enumerable:!1}),arguments.length>1&&(0,l.eF)(u.A.getLogger(this),"Graphic",{version:"4.30"})}initialize(){this._watchMeshGeometryChanges()}set aggregateGeometries(e){const t=this._get("aggregateGeometries");JSON.stringify(t)!==JSON.stringify(e)&&this._set("aggregateGeometries",e)}set attributes(e){const t=this._get("attributes");t!==e&&(this._set("attributes",e),this._notifyLayer("attributes",t,e))}set geometry(e){const t=this._get("geometry");t!==e&&(this._set("geometry",e),"mesh"!==e?.type&&this._notifyLayer("geometry",t,e))}set popupTemplate(e){const t=this._get("popupTemplate");t!==e&&(this._set("popupTemplate",e),this._notifyLayer("popupTemplate",t,e))}set symbol(e){const t=this._get("symbol");t!==e&&(this._set("symbol",e),this._notifyLayer("symbol",t,e))}get version(){return this._version}set visible(e){const t=this._get("visible");t!==e&&(this._set("visible",e),this._notifyLayer("visible",t,e))}cloneShallow(){return new i({aggregateGeometries:this.aggregateGeometries,attributes:this.attributes,geometry:this.geometry,isAggregate:this.isAggregate,layer:this.layer,popupTemplate:this.popupTemplate,sourceLayer:this.sourceLayer,symbol:this.symbol,visible:this.visible,origin:this.origin})}getEffectivePopupTemplate(e=!1){if(this.popupTemplate)return this.popupTemplate;const t=this.origin&&"layer"in this.origin?this.origin.layer:null;for(const n of[t,this.sourceLayer,this.layer])if(n){if("popupTemplate"in n&&n.popupTemplate)return n.popupTemplate;if(e&&"defaultPopupTemplate"in n&&null!=n.defaultPopupTemplate)return n.defaultPopupTemplate}return null}getAttribute(e){return this.attributes?.[e]}setAttribute(e,t){if(this.attributes){const n=this.getAttribute(e);this.attributes[e]=t,this._notifyLayer("attributes",n,t,e)}else this.attributes={[e]:t}}getObjectId(){const e=this.sourceLayer??this.layer;return e?(0,d.r)(this,e):null}getGlobalId(){const e=this.sourceLayer??this.layer;return e&&"globalIdField"in e&&e.globalIdField?this.getAttribute(e.globalIdField):null}toJSON(){return{aggregateGeometries:_(this.aggregateGeometries),geometry:null!=this.geometry?this.geometry.toJSON():null,symbol:null!=this.symbol?this.symbol.toJSON():null,attributes:(0,m.W)(this.attributes)?this.attributes.toJSON():{...this.attributes},popupTemplate:this.popupTemplate?.toJSON()??null}}notifyMeshTransformChanged(e={}){const{geometry:t}=this;if("mesh"===t?.type){const n={origin:t.origin,transform:t.transform};this._notifyLayer("origin-transform",n,n,e.action)}}_notifyLayer(e,t,n,i){if(this._version++,!this.layer||!("graphicChanged"in this.layer))return;const r={graphic:this,property:e,oldValue:t,newValue:n};"origin-transform"===e&&(r.action=i),"attributes"===e&&(r.attributeName=i),this.layer.graphicChanged(r)}_watchMeshGeometryChanges(){this.addHandles([(0,p.z7)((()=>"mesh"===this.geometry?.type&&this.geometry.vertexSpace.origin?{localMatrix:this.geometry.transform?.localMatrix,origin:this.geometry.vertexSpace.origin}:void 0),(({localMatrix:e,origin:t})=>{this._lastMeshTransform.localMatrix===e&&this._lastMeshTransform.origin===t||(this._lastMeshTransform.localMatrix=e,this._lastMeshTransform.origin=t,this.notifyMeshTransformChanged())})),(0,p.z7)((()=>"mesh"===this.geometry?.type?{vertexAttributes:this.geometry.vertexAttributes}:void 0),(()=>{const e=this.geometry;"mesh"===e?.type&&e.vertexSpace.origin?(this._lastMeshTransform.localMatrix=e.transform?.localMatrix,this._lastMeshTransform.origin=e.vertexSpace.origin):(this._lastMeshTransform.localMatrix=void 0,this._lastMeshTransform.origin=void 0),this._notifyLayer("geometry",this.geometry,this.geometry)}),{equals:(e,t)=>e===t,sync:!0})])}};(0,r._)([(0,h.MZ)({value:null,json:{read:function(e){if(!e)return null;const t={};for(const n in e){const i=(0,y.rS)(e[n]);i&&(t[n]=i)}return 0!==Object.keys(t).length?t:null}}})],b.prototype,"aggregateGeometries",null),(0,r._)([(0,h.MZ)({value:null})],b.prototype,"attributes",null),(0,r._)([(0,h.MZ)({value:null,types:g.yR,json:{read:y.rS}})],b.prototype,"geometry",null),(0,r._)([(0,h.MZ)({type:Boolean})],b.prototype,"isAggregate",void 0),(0,r._)([(0,h.MZ)({clonable:!1})],b.prototype,"layer",void 0),(0,r._)([(0,h.MZ)({clonable:"reference"})],b.prototype,"origin",void 0),(0,r._)([(0,h.MZ)({type:s.A,value:null})],b.prototype,"popupTemplate",null),(0,r._)([(0,h.MZ)({clonable:"reference"})],b.prototype,"sourceLayer",void 0),(0,r._)([(0,h.MZ)({value:null,types:M.Es})],b.prototype,"symbol",null),(0,r._)([(0,h.MZ)({clonable:!1,json:{read:!1,write:!1}})],b.prototype,"_version",void 0),(0,r._)([(0,h.MZ)({type:Boolean,value:!0})],b.prototype,"visible",null),b=i=(0,r._)([(0,f.$)("esri.Graphic")],b)},54339:(e,t,n)=>{function i(e,t){switch(t.type){case"object-id":case"unique-id-simple":return e.attributes[t.fieldName];case"unique-id-composite":{const n=[];for(const i of t.fieldNames)n.push(e.attributes[i]??null);return JSON.stringify(n)}}}function r(e,t){if("uniqueIdFields"in t&&t.uniqueIdFields?.length){if(1===t.uniqueIdFields.length)return e.attributes?.[t.uniqueIdFields[0]];const n=t.uniqueIdFields.map((t=>e.attributes?.[t]));return JSON.stringify(n)}return"objectIdField"in t&&t.objectIdField?e.attributes?.[t.objectIdField]:null}n.d(t,{W:()=>i,r:()=>r})},70328:(e,t,n)=>{n.d(t,{BI:()=>M,Ej:()=>h,Ie:()=>g,Jt:()=>d,Ne:()=>f,RF:()=>p,aI:()=>b,fA:()=>o,gE:()=>a,hZ:()=>y,iT:()=>c,is:()=>_,qv:()=>F,vI:()=>m,vY:()=>l,v_:()=>x,vt:()=>s,w1:()=>u});var i=n(5443),r=(n(19419),n(4197));function s(e=x){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function o(e,t,n,i,r,o,l=s()){return l[0]=e,l[1]=t,l[2]=n,l[3]=i,l[4]=r,l[5]=o,l}function l(e,t=s()){return function(e,t,n,i=s()){return y(i,F),function(e,t,n=0,i=t.length/3){let r=e[0],s=e[1],o=e[2],l=e[3],a=e[4],u=e[5];for(let e=0;e<i;e++)r=Math.min(r,t[n+3*e]),s=Math.min(s,t[n+3*e+1]),o=Math.min(o,t[n+3*e+2]),l=Math.max(l,t[n+3*e]),a=Math.max(a,t[n+3*e+1]),u=Math.max(u,t[n+3*e+2]);e[0]=r,e[1]=s,e[2]=o,e[3]=l,e[4]=a,e[5]=u}(i,e,t,n),i}(e,0,e.length/3,t)}function a(e,t=(0,r.jh)(24)){const[n,i,s,o,l,a]=e;return t[0]=n,t[1]=i,t[2]=s,t[3]=n,t[4]=i,t[5]=a,t[6]=n,t[7]=l,t[8]=s,t[9]=n,t[10]=l,t[11]=a,t[12]=o,t[13]=i,t[14]=s,t[15]=o,t[16]=i,t[17]=a,t[18]=o,t[19]=l,t[20]=s,t[21]=o,t[22]=l,t[23]=a,t}function u(e,t){const n=isFinite(e[2])||isFinite(e[5]);return new i.A(n?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function p(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}function c(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}function h(e,t=[0,0,0]){return t[0]=function(e){return e[0]>=e[3]?0:e[3]-e[0]}(e),t[1]=function(e){return e[1]>=e[4]?0:e[4]-e[1]}(e),t[2]=function(e){return e[2]>=e[5]?0:e[5]-e[2]}(e),t}function f(e,t,n=e){return n[0]=t[0],n[1]=t[1],n[2]=t[2],n!==e&&(n[3]=e[3],n[4]=e[4],n[5]=e[5]),n}function m(e,t,n=e){return n[3]=t[0],n[4]=t[1],n[5]=t[2],n!==e&&(n[0]=e[0],n[1]=e[1],n[2]=e[2]),e}function y(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function g(e){return e?y(e,F):s(F)}function d(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function M(e,t,n,i,r){return e[0]=t,e[1]=n,e[2]=Number.NEGATIVE_INFINITY,e[3]=i,e[4]=r,e[5]=Number.POSITIVE_INFINITY,e}function _(e){return 6===e.length}function b(e,t,n){if(null==e||null==t)return e===t;if(!_(e)||!_(t))return!1;if(n){for(let i=0;i<e.length;i++)if(!n(e[i],t[i]))return!1}else for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}const F=[1/0,1/0,1/0,-1/0,-1/0,-1/0],x=[0,0,0,0,0,0];s()},80754:(e,t,n)=>{n.d(t,{j7:()=>o,kS:()=>a,kd:()=>l,r8:()=>u});var i=n(82799),r=n(16930),s=n(65864);const o={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new i.A({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:r.A.WebMercator}),minus180Line:new i.A({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:r.A.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new i.A({paths:[[[180,-180],[180,180]]],spatialReference:r.A.WGS84}),minus180Line:new i.A({paths:[[[-180,-180],[-180,180]]],spatialReference:r.A.WGS84})}};function l(e,t){return Math.ceil((e-t)/(2*t))}function a(e,t){const n=u(e);for(const e of n)for(const n of e)n[0]+=t;return e}function u(e){return(0,s.Bi)(e)?e.rings:e.paths}},92300:(e,t,n)=>{n.d(t,{V:()=>s,X:()=>r});var i=n(65864);function r(e){return{geometryType:(0,i.$B)(e[0]),geometries:e.map((e=>e.toJSON()))}}function s(e,t,n){const r=(0,i.xD)(t);return e.map((e=>{const t=r.fromJSON(e);return t.spatialReference=n,t}))}},95466:(e,t,n)=>{n.d(t,{A:()=>f});var i=n(49186),r=n(53966),s=n(91869),o=n(3330),l=n(12195),a=n(30524),u=n(98623),p=n(56400),c=n(96285);const h=new Map;class f{static fromJSON(e){return new f(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new f(e.fields??[],d(e))}static fromLayerJSON(e){return new f(e.fields??[],d(e))}constructor(e=[],t){this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this._requiredFields=null,this.dateFields=[],this.numericFields=[],this.fields=e||[],this._timeZoneByFieldName=t?new Map(t):null;const n=[];for(const e of this.fields){const t=e?.name,i=y(t);if(t&&i){const r=m(t);this._fieldsMap.set(t,e),this._fieldsMap.set(r,e),this._normalizedFieldsMap.set(i,e),n.push(`${r}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,a.vE)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,a.WA)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,a.te)(e)||(0,a.Xz)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}n.sort(),this.uid=n.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,a.te)(e)||(0,a.Xz)(e)||e.nullable||void 0!==(0,a.lD)(e)||this._requiredFields.push(e)}return this._requiredFields}equals(e){return this.uid===e?.uid}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(m(e))??this._normalizedFieldsMap.get(y(e)),t&&this._fieldsMap.set(e,t),t)}getTimeZone(e){const t=this.get(e&&"string"!=typeof e?e.name:e);return t?this._timeZoneByFieldName?this._timeZoneByFieldName.get(t.name):"date"===t.type||"esriFieldTypeDate"===t.type?(r.A.getLogger("esri.layers.support.FieldsIndex").errorOnce(new i.A("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),u.n$):g.has(t.type)?u.L5:null:null}getLuxonTimeZone(e){const t=this.getTimeZone(e);return t?t===u.L5?o.GB.instance:t===u.n$?c.mQ.utcInstance:(0,s.tE)(h,t,(()=>c.oh.create(t))):null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,a.OH)(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){return this.get(e)?.name??void 0}toJSON(){return{fields:this.fields.map((e=>(0,l.W)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function m(e){return e.trim().toLowerCase()}function y(e){return(0,a.rS)(e)?.toLowerCase()??""}const g=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function d(e){const t=new Map;if(!e.fields)return t;const n=!0===e.datesInUnknownTimezone,{timeInfo:i,editFieldsInfo:r}=e,s=(i?"startField"in i?i.startField:i.startTimeField:"")??"",o=(i?"endField"in i?i.endField:i.endTimeField:"")??"",l=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,p.ZS)(e.dateFieldsTimeReference):null,a=r?function(e){return"timeZone"in e}(r)?r.timeZone??l:r.dateFieldsTimeReference?(0,p.ZS)(r.dateFieldsTimeReference):l??u.n$:null,c=i?function(e){return"timeZone"in e}(i)?i.timeZone??l:i.timeReference?(0,p.ZS)(i.timeReference):l:null,h=new Map([[m(r?.creationDateField??""),a],[m(r?.editDateField??""),a],[m(s),c],[m(o),c]]);for(const{name:i,type:r}of e.fields)if(g.has(r))t.set(i,u.L5);else if("date"!==r&&"esriFieldTypeDate"!==r)t.set(i,null);else if(n)t.set(i,u.L5);else{const e=h.get(m(i??""))??l;t.set(i,e)}return t}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[788,3186,3447,4697,7799,8407,8608],{5503:(e,t,i)=>{i.d(t,{A:()=>E});var s,r=i(90237),n=i(98291),a=i(65529),l=i(36563),o=i(4718),u=i(93687);!function(e){e[e.ADD=1]="ADD",e[e.REMOVE=2]="REMOVE",e[e.MOVE=4]="MOVE"}(s||(s={}));var c,h=i(11932),d=i(56507),p=i(62788),f=i(10107),y=i(7695),_=i(40608),g=i(95488),m=i(12195);class w{constructor(e,t,i,s,r){this.target=e,this.added=t,this.removed=i,this.start=s,this.deleteCount=r}}const b=new u.A(class{constructor(){this.target=null,this.cancellable=!1,this.defaultPrevented=!1,this.item=void 0,this.type=void 0}preventDefault(){this.cancellable&&(this.defaultPrevented=!0)}reset(e){this.defaultPrevented=!1,this.item=e}},void 0,(e=>{e.item=null,e.target=null,e.defaultPrevented=!1,e.cancellable=!1}));function F(e){e&&"object"==typeof e&&"destroy"in e&&"function"==typeof e.destroy&&e.destroy()}function S(e){return e?e instanceof k?e.toArray():e.length?Array.prototype.slice.apply(e):[]:[]}function v(e){if(e?.length)return e[0]}function I(e,t,i,s){const r=Math.min(e.length-i,t.length-s);let n=0;for(;n<r&&e[i+n]===t[s+n];)n++;return n}function A(e,t,i,s){t&&t.forEach(((t,r,n)=>{e.push(t),A(e,i.call(s,t,r,n),i,s)}))}const T=new Set,x=new Set,C=new Set,D=new Map;let R=0,k=class extends a.A.EventedAccessor{static{c=this}static{this.ofType=e=>{if(!e)return c;if(D.has(e))return D.get(e);let t=null;if("function"==typeof e)t=e.prototype.declaredClass;else if(e.base)t=e.base.prototype.declaredClass;else for(const i in e.typeMap){const s=e.typeMap[i].prototype.declaredClass;t?t+=` | ${s}`:t=s}let i=class extends c{};return(0,r._)([(0,y.u)({Type:e,ensureType:"function"==typeof e?(0,d.dp)(e):(0,d.aq)(e)})],i.prototype,"itemType",void 0),i=(0,r._)([(0,_.$)(`esri.core.Collection<${t}>`)],i),D.set(e,i),i}}static isCollection(e){return null!=e&&e instanceof c}constructor(e){super(e),this._chgListeners=[],this._notifications=null,this._updating=!1,this._timer=null,this._observable=new g.I,this.length=0,this._items=[],Object.defineProperty(this,"uid",{value:R++})}normalizeCtorArgs(e){return e?Array.isArray(e)||e instanceof c?{items:e}:e:{}}destroy(){this._removeAllRaw(),this._timer&&this._timer.remove(),this._emitter.destroy(),this._notifications=null}*[Symbol.iterator](){yield*this.items}get items(){return(0,p.gc)(this._observable),this._items}set items(e){this._emitBeforeChanges(s.ADD)||(this._splice(0,this.length,S(e)),this._emitAfterChanges(s.ADD))}hasEventListener(e){return!this.destroyed&&("change"===e?this._chgListeners.length>0:this._emitter.hasEventListener(e))}on(e,t){if(this.destroyed)return(0,l.hA)();if("change"===e){const e=this._chgListeners,i={removed:!1,callback:t};return e.push(i),this._notifications&&this._notifications.push({listeners:e.slice(),items:this._items.slice(),changes:[]}),(0,l.hA)((()=>{i.removed=!0,e.splice(e.indexOf(i),1)}))}return this._emitter.on(e,t)}once(e,t){const i="deref"in t?()=>t.deref():()=>t,s=this.on(e,(e=>{i()?.call(null,e),s.remove()}));return s}add(e,t){if((0,p.gc)(this._observable),this._emitBeforeChanges(s.ADD))return this;const i=this.getNextIndex(t??null);return this._splice(i,0,[e]),this._emitAfterChanges(s.ADD),this}addMany(e,t=this._items.length){if((0,p.gc)(this._observable),!e?.length)return this;if(this._emitBeforeChanges(s.ADD))return this;const i=this.getNextIndex(t);return this._splice(i,0,S(e)),this._emitAfterChanges(s.ADD),this}at(e){if((0,p.gc)(this._observable),(e=Math.trunc(e)||0)<0&&(e+=this.length),!(e<0||e>=this.length))return this._items[e]}removeAll(){if((0,p.gc)(this._observable),!this.length||this._emitBeforeChanges(s.REMOVE))return[];const e=this._removeAllRaw();return this._emitAfterChanges(s.REMOVE),e}_removeAllRaw(){return 0===this.length?[]:this._splice(0,this.length)||[]}clone(){return(0,p.gc)(this._observable),this._createNewInstance({items:this._items.map(o.o8)})}concat(...e){(0,p.gc)(this._observable);const t=e.map(S);return this._createNewInstance({items:this._items.concat(...t)})}drain(e,t){if((0,p.gc)(this._observable),!this.length||this._emitBeforeChanges(s.REMOVE))return;const i=this._splice(0,this.length),r=i.length;for(let s=0;s<r;s++)e.call(t,i[s],s,i);this._emitAfterChanges(s.REMOVE)}destroyAll(){this.drain(F)}destroyMany(e){const t=this.removeMany(e);return t.forEach(F),t}every(e,t){return(0,p.gc)(this._observable),this._items.every(e,t)}filter(e,t){(0,p.gc)(this._observable);const i=2===arguments.length?this._items.filter(e,t):this._items.filter(e);return this._createNewInstance({items:i})}find(e,t){return(0,p.gc)(this._observable),this._items.find(e,t)}findIndex(e,t){return(0,p.gc)(this._observable),this._items.findIndex(e,t)}flatten(e,t){(0,p.gc)(this._observable);const i=[];return A(i,this,e,t),new c(i)}forEach(e,t){return(0,p.gc)(this._observable),this._items.forEach(e,t)}getItemAt(e){return(0,p.gc)(this._observable),this._items[e]}getNextIndex(e){(0,p.gc)(this._observable);const t=this.length;return(e=e??t)<0?e=0:e>t&&(e=t),e}includes(e,t=0){return(0,p.gc)(this._observable),this._items.includes(e,t)}indexOf(e,t=0){return(0,p.gc)(this._observable),this._items.indexOf(e,t)}join(e=","){return(0,p.gc)(this._observable),this._items.join(e)}lastIndexOf(e,t=this.length-1){return(0,p.gc)(this._observable),this._items.lastIndexOf(e,t)}map(e,t){(0,p.gc)(this._observable);const i=this._items.map(e,t);return new c({items:i})}reorder(e,t=this.length-1){(0,p.gc)(this._observable);const i=this.indexOf(e);if(-1!==i){if(t<0?t=0:t>=this.length&&(t=this.length-1),i!==t){if(this._emitBeforeChanges(s.MOVE))return e;this._splice(i,1),this._splice(t,0,[e]),this._emitAfterChanges(s.MOVE)}return e}}pop(){if((0,p.gc)(this._observable),!this.length||this._emitBeforeChanges(s.REMOVE))return;const e=v(this._splice(this.length-1,1));return this._emitAfterChanges(s.REMOVE),e}push(...e){return(0,p.gc)(this._observable),this._emitBeforeChanges(s.ADD)||(this._splice(this.length,0,e),this._emitAfterChanges(s.ADD)),this.length}reduce(e,t){(0,p.gc)(this._observable);const i=this._items;return 2===arguments.length?i.reduce(e,t):i.reduce(e)}reduceRight(e,t){(0,p.gc)(this._observable);const i=this._items;return 2===arguments.length?i.reduceRight(e,t):i.reduceRight(e)}remove(e){return(0,p.gc)(this._observable),this.removeAt(this.indexOf(e))}removeAt(e){if((0,p.gc)(this._observable),e<0||e>=this.length||this._emitBeforeChanges(s.REMOVE))return;const t=v(this._splice(e,1));return this._emitAfterChanges(s.REMOVE),t}removeMany(e){if((0,p.gc)(this._observable),!e?.length||this._emitBeforeChanges(s.REMOVE))return[];const t=e instanceof c?e.toArray():e,i=this._items,r=[],n=t.length;for(let e=0;e<n;e++){const s=t[e],n=i.indexOf(s);if(n>-1){const s=1+I(t,i,e+1,n+1),a=this._splice(n,s);a&&a.length>0&&r.push.apply(r,a),e+=s-1}}return this._emitAfterChanges(s.REMOVE),r}reverse(){if((0,p.gc)(this._observable),this._emitBeforeChanges(s.MOVE))return this;const e=this._splice(0,this.length);return e&&(e.reverse(),this._splice(0,0,e)),this._emitAfterChanges(s.MOVE),this}shift(){if((0,p.gc)(this._observable),!this.length||this._emitBeforeChanges(s.REMOVE))return;const e=v(this._splice(0,1));return this._emitAfterChanges(s.REMOVE),e}slice(e=0,t=this.length){return(0,p.gc)(this._observable),this._createNewInstance({items:this._items.slice(e,t)})}some(e,t){return(0,p.gc)(this._observable),this._items.some(e,t)}sort(e){if((0,p.gc)(this._observable),!this.length||this._emitBeforeChanges(s.MOVE)||!this._requiresSort(e))return this;const t=this._splice(0,this.length);return arguments.length?t.sort(e):t.sort(),this._splice(0,0,t),this._emitAfterChanges(s.MOVE),this}_requiresSort(e=(e,t)=>e===t?0:e<t?-1:1){const t=this.length-1;for(let i=0;i<t;i++)if(e(this.items[i],this.items[i+1])>0)return!0;return!1}splice(e,t,...i){(0,p.gc)(this._observable),1===arguments.length&&(t=this.length),t??=0;const r=(t?s.REMOVE:0)|(i.length?s.ADD:0);if(this._emitBeforeChanges(r))return[];const n=this._splice(e,t,i)||[];return this._emitAfterChanges(r),n}toArray(){return(0,p.gc)(this._observable),this._items.slice()}toJSON(e){return(0,p.gc)(this._observable),this.toArray().map((t=>(0,m.W)(t)?t.toJSON(e):t))}toLocaleString(){return(0,p.gc)(this._observable),this._items.toLocaleString()}toString(){return(0,p.gc)(this._observable),this._items.toString()}unshift(...e){return(0,p.gc)(this._observable),!e.length||this._emitBeforeChanges(s.ADD)||(this._splice(0,0,e),this._emitAfterChanges(s.ADD)),this.length}_createNewInstance(e){return new this.constructor(e)}_splice(e,t,i){const s=this._items,r=this.itemType;let n,a;if(!this._notifications&&this.hasEventListener("change")&&(this._notifications=[{listeners:this._chgListeners.slice(),items:this._items.slice(),changes:[]}],this._timer&&this._timer.remove(),this._updating=!0,this._timer=(0,h._)((()=>this._dispatchChange()))),e<0&&(e+=this.length),t){if(a=s.splice(e,t),this.hasEventListener("before-remove")){const t=b.acquire();t.target=this,t.cancellable=!0;for(let i=0,r=a.length;i<r;i++)n=a[i],t.reset(n),this.emit("before-remove",t),t.defaultPrevented&&(a.splice(i,1),s.splice(e,0,n),e+=1,i-=1,r-=1);b.release(t)}if(this.length=this._items.length,this.hasEventListener("after-remove")){const e=b.acquire();e.target=this,e.cancellable=!1;const t=a.length;for(let i=0;i<t;i++)e.reset(a[i]),this.emit("after-remove",e);b.release(e)}}if(i?.length){if(r){const e=[];for(const t of i){const i=r.ensureType(t);null==i&&null!=t||e.push(i)}i=e}const t=this.hasEventListener("before-add"),n=this.hasEventListener("after-add"),a=e===this.length;if(t||n){const r=b.acquire();r.target=this,r.cancellable=!0;const l=b.acquire();l.target=this,l.cancellable=!1;for(const o of i)t?(r.reset(o),this.emit("before-add",r),r.defaultPrevented||(a?s.push(o):s.splice(e++,0,o),this._set("length",s.length),n&&(l.reset(o),this.emit("after-add",l)))):(a?s.push(o):s.splice(e++,0,o),this._set("length",s.length),l.reset(o),this.emit("after-add",l));b.release(l),b.release(r)}else{if(a)for(const e of i)s.push(e);else s.splice(e,0,...i);this._set("length",s.length)}}if((i?.length||a?.length)&&this._notifyChangeEvent(i,a),this.hasEventListener("after-splice")){const s=new w(this,i,a,e,t);this.emit("after-splice",s)}return a}_emitBeforeChanges(e){let t=!1;if(this.hasEventListener("before-changes")){const i=b.acquire();i.target=this,i.cancellable=!0,i.type=e,this.emit("before-changes",i),t=i.defaultPrevented,b.release(i)}return t}_emitAfterChanges(e){if(this.hasEventListener("after-changes")){const t=b.acquire();t.target=this,t.cancellable=!1,t.type=e,this.emit("after-changes",t),b.release(t)}this._observable.notify()}_notifyChangeEvent(e,t){this.hasEventListener("change")&&this._notifications&&this._notifications[this._notifications.length-1].changes.push({added:e,removed:t})}get updating(){return this._updating}_dispatchChange(){if(this._timer&&(this._timer.remove(),this._timer=null),this._updating=!1,!this._notifications)return;const e=this._notifications;this._notifications=null;for(const t of e){const e=t.changes;T.clear(),x.clear(),C.clear();for(const{added:t,removed:i}of e){if(t)if(0===C.size&&0===x.size)for(const e of t)T.add(e);else for(const e of t)x.has(e)?(C.add(e),x.delete(e)):C.has(e)||T.add(e);if(i)if(0===C.size&&0===T.size)for(const e of i)x.add(e);else for(const e of i)T.has(e)?T.delete(e):(C.delete(e),x.add(e))}const i=n.A.acquire();T.forEach((e=>{i.push(e)}));const s=n.A.acquire();x.forEach((e=>{s.push(e)}));const r=this._items,a=t.items,l=n.A.acquire();if(C.forEach((e=>{a.indexOf(e)!==r.indexOf(e)&&l.push(e)})),t.listeners&&(i.length||s.length||l.length)){const e={target:this,added:i,removed:s,moved:l},r=t.listeners.length;for(let i=0;i<r;i++){const s=t.listeners[i];s.removed||s.callback.call(this,e)}}n.A.release(i),n.A.release(s),n.A.release(l)}T.clear(),x.clear(),C.clear()}};(0,r._)([(0,f.MZ)()],k.prototype,"_updating",void 0),(0,r._)([(0,f.MZ)()],k.prototype,"length",void 0),(0,r._)([(0,f.MZ)()],k.prototype,"items",null),(0,r._)([(0,f.MZ)({readOnly:!0})],k.prototype,"updating",null),k=c=(0,r._)([(0,_.$)("esri.core.Collection")],k);const E=k},7695:(e,t,i)=>{function s(e){return(t,i)=>{t[i]=e}}i.d(t,{u:()=>s})},10407:(e,t,i)=>{i.d(t,{It:()=>p,LG:()=>a,OM:()=>u,Sm:()=>c,Y:()=>l,bK:()=>o,mm:()=>d,sQ:()=>h});var s=i(98988),r=i(16930),n=i(28735);function a(e,t){if(!l(e,t)){const i=e.typeKeywords;i?i.push(t):e.typeKeywords=[t]}}function l(e,t){return!!e.typeKeywords?.includes(t)}function o(e){return l(e,d.HOSTED_SERVICE)}function u(e,t){const i=e.typeKeywords;if(i){const e=i.indexOf(t);e>-1&&i.splice(e,1)}}function c(e,t,i){i?a(e,t):u(e,t)}async function h(e){const t=e.clone().normalize();let i;if(t.length>1)for(const e of t)i?e.width>i.width&&(i=e):i=e;else i=t[0];return async function(e){const t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,n.ci)(e);const i=r.A.WGS84;return await(0,s.initializeProjection)(t,i),(0,s.project)(e,i)}(i)}const d={CHARTS:"Charts",DYNAMIC:"Dynamic",DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery"};function p(e){const{portal:t,isOrgItem:i,itemControl:s}=e,r=t.user?.privileges;let n=!r||r.includes("features:user:edit"),a=!!i&&!!r?.includes("features:user:fullEdit");const l="update"===s||"admin"===s;return l?a=n=!0:a&&(n=!0),{features:{edit:n,fullEdit:a},content:{updateItem:l}}}},17311:(e,t,i)=>{i.d(t,{A:()=>h});var s=i(90237),r=i(69622),n=i(60999),a=i(5503),l=i(10107),o=(i(44208),i(53966),i(87811),i(40608)),u=i(30524),c=i(43668);let h=class extends r.A{constructor(e){super(e),this._featureUtils=null,this.effectivePopupTemplate=null}get _arcadeTask(){return this.expressionsUsedInTitle.length>0?this._get("_arcadeTask")||(0,n.UT)((()=>(0,c.l)())):null}get featureUtilsPromise(){return this._get("featureUtilsPromise")??Promise.all([i.e(4560),i.e(9926)]).then(i.bind(i,29926)).then((e=>this._featureUtils=e))}get calculatedExpressions(){const e=new a.A;if(!this.expressionsUsedInTitle.length)return e;if(!this._arcadeTask?.value){for(const t of this.expressionsUsedInTitle??[])e.push({name:t.name,invalid:!0});return e}for(const t of this.expressionsUsedInTitle)try{const i=this._arcadeTask.value.arcade.parseScript(t.expression,["$layer","$map","$datastore"]);if(i.isAsync){e.push({name:t.name,invalid:!0});break}e.push({name:t.name,syntax:i,invalid:!1,func:this._arcadeTask.value.arcade.compileScript(i,{vars:{$feature:"any"}})})}catch{e.push({name:t.name,invalid:!0});break}return e}get expressionsUsedInTitle(){let e=this.effectivePopupTemplate?.title??"";return"string"!=typeof e?[]:(e=e.toLowerCase(),this.effectivePopupTemplate?.expressionInfos?.filter((t=>e.includes(`{expression/${t.name.toLowerCase()}}`)))??[])}get fieldInfoMap(){return this._featureUtils?this._createFieldInfoMap(this._featureUtils.getAllFieldInfos(this.effectivePopupTemplate)):null}get hasBadExpressions(){return this.calculatedExpressions.some((e=>!0===e.invalid))}get requiredFields(){const e=new Set;if(this._arcadeTask?.value&&!this.hasBadExpressions)for(const t of this.calculatedExpressions?.toArray()??[])try{const i=this._arcadeTask.value.arcade.extractFieldLiterals(t.syntax);for(const t of i){const i=t.split("."),s=this.fieldsIndex.get(i.at(-1)??"");s&&e.add(s.name)}}catch{}const t=this._extractFieldNames(this.workingTitle);for(const i of t){const t=this.fieldsIndex.get(i);t&&e.add(t.name)}return e}get titleFromDisplayField(){let e="";return this.displayField&&(e=this.fieldsIndex.get(this.displayField)?.name??""),e||(e=this.fieldsIndex.get(this.objectIdField)?.name??""),e?`{${e}}`:""}get workingTitle(){const e=this.effectivePopupTemplate?this.effectivePopupTemplate.title:"";return""===e||null==e||this.hasBadExpressions||"string"!=typeof e?this.titleFromDisplayField:e}async getTitle(e,t,i){try{const{attributes:s}=t,r=i?.timeZone??"system",[{substituteFieldsInLinksAndAttributes:n}]=await Promise.all([this.featureUtilsPromise,this._arcadeTask?.promise]);if(i.fetchMissingFields&&(t=await this._checkAndReQueryGraphic(e,t)),this.workingTitle&&this.fieldInfoMap){const i=this._createFormattedAttributes(e,t,r).global;return n({attributes:s,expressionAttributes:null,fieldInfoMap:this.fieldInfoMap,globalAttributes:i,layer:e,text:this.workingTitle})}return""}catch{}return""}async _checkAndReQueryGraphic(e,t){const i=t.getObjectId();if(null==i)return t;if(!(0,u.Kl)(t,this.requiredFields)){const t=e.createQuery();t.where="1=1",t.outFields=[...this.requiredFields],t.objectIds=[i];const s=await e.queryFeatures(t);if(1===s?.features.length)return s.features[0]}return t}_createFieldInfoMap(e){const t=new Map;if(!e)return t;for(const i of e){if(!i.fieldName)continue;const e=this.fieldsIndex.get(i.fieldName),s=e?.name??i.fieldName;i.fieldName=s,t.set(s.toLowerCase(),i)}return t}_createFormattedAttributes(e,t,i="system"){const s=this.effectivePopupTemplate?.fieldInfos??[],r={};if(!this._featureUtils)return{};if(!this.hasBadExpressions&&this.calculatedExpressions.length>0&&this._arcadeTask?.value){const i=this._arcadeTask.value.Feature.createFromGraphicLikeObject(t.geometry,t.attributes,e,null);for(const e of this.calculatedExpressions)try{r[`expression/${e.name}`]=e.func({vars:{$feature:i}})}catch{}}const n={...t.attributes,...r};return{global:this._featureUtils.formatAttributes({fieldInfos:s,attributes:n,graphic:t,timeZone:i,layer:e,fieldInfoMap:this.fieldInfoMap}),content:[]}}_extractFieldNames(e){return(0,u.nw)(e).filter((e=>!(0===e.indexOf("relationships/")||0===e.indexOf("expression/"))))}};(0,s._)([(0,l.MZ)({readOnly:!0})],h.prototype,"_arcadeTask",null),(0,s._)([(0,l.MZ)()],h.prototype,"_featureUtils",void 0),(0,s._)([(0,l.MZ)({readOnly:!0})],h.prototype,"featureUtilsPromise",null),(0,s._)([(0,l.MZ)({readOnly:!0})],h.prototype,"calculatedExpressions",null),(0,s._)([(0,l.MZ)()],h.prototype,"displayField",void 0),(0,s._)([(0,l.MZ)()],h.prototype,"effectivePopupTemplate",void 0),(0,s._)([(0,l.MZ)()],h.prototype,"expressionsUsedInTitle",null),(0,s._)([(0,l.MZ)()],h.prototype,"fieldsIndex",void 0),(0,s._)([(0,l.MZ)()],h.prototype,"fieldInfoMap",null),(0,s._)([(0,l.MZ)()],h.prototype,"fields",void 0),(0,s._)([(0,l.MZ)()],h.prototype,"objectIdField",void 0),(0,s._)([(0,l.MZ)()],h.prototype,"requiredFields",null),h=(0,s._)([(0,o.$)("esri.layers.support.TitleCreator")],h)},22671:(e,t,i)=>{i.d(t,{A:()=>m});var s,r=i(90237),n=i(52106),a=i(66552),l=i(25482),o=i(4718),u=i(10107),c=(i(44208),i(53966),i(36005)),h=i(40608),d=i(43937),p=i(16930),f=i(65864),y=i(50498),_=i(20437);const g=new a.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let m=s=class extends l.A{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){return this.readFeaturesWithClass(e,t,n.A)}writeGeometryType(e,t,i,s){if(e)return void g.write(e,t,i,s);const{features:r}=this;if(r)for(const e of r)if(null!=e?.geometry)return void g.write(e.geometry.type,t,i,s)}readQueryGeometry(e,t){if(!e)return null;const i=!!e.spatialReference,s=(0,f.rS)(e);return s&&!i&&t.spatialReference&&(s.spatialReference=p.A.fromJSON(t.spatialReference)),s}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:i}=this;if(i)for(const e of i)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new s(this.cloneProperties())}cloneProperties(){return(0,o.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let i=0;i<t.features.length;i++){const s=t.features[i];if(s.geometry){const t=e?.[i];s.geometry=t?.toJSON()||s.geometry}}return t}quantize(e){const{scale:[t,i],translate:[s,r]}=e,n=this.features,a=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-s)/t)),(e=>Math.round((r-e)/i)));for(let e=0,t=n.length;e<t;e++)a?.(n[e].geometry)||(n.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:i}=this;if(!i)return this;const{translate:[s,r],scale:[n,a]}=i;let l=null,o=null;if(this.hasZ&&null!=i?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=i;l=i=>i*t+e}if(this.hasM&&null!=i?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=i;o=i=>null==i?i:i*t+e}const u=this._getHydrationFunction(e,(e=>e*n+s),(e=>r-e*a),l,o);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}readFeaturesWithClass(e,t,i){const s=p.A.fromJSON(t.spatialReference),r=[];for(let t=0;t<e.length;t++){const n=e[t],a=i.fromJSON(n),l=n.geometry?.spatialReference;null==a.geometry||l||(a.geometry.spatialReference=s);const o=n.aggregateGeometries,u=a.aggregateGeometries;if(o&&null!=u)for(const e in u){const t=u[e],i=o[e],r=i?.spatialReference;null==t||r||(t.spatialReference=s)}r.push(a)}return r}_quantizePoints(e,t,i){let s,r;const n=[];for(let a=0,l=e.length;a<l;a++){const l=e[a];if(a>0){const e=t(l[0]),a=i(l[1]);e===s&&a===r||(n.push([e-s,a-r]),s=e,r=a)}else s=t(l[0]),r=i(l[1]),n.push([s,r])}return n.length>0?n:null}_getQuantizationFunction(e,t,i){return"point"===e?e=>(e.x=t(e.x),e.y=i(e.y),e):"polyline"===e||"polygon"===e?e=>{const s=(0,f.Bi)(e)?e.rings:e.paths,r=[];for(let e=0,n=s.length;e<n;e++){const n=s[e],a=this._quantizePoints(n,t,i);a&&r.push(a)}return r.length>0?((0,f.Bi)(e)?e.rings=r:e.paths=r,e):null}:"multipoint"===e?e=>{const s=this._quantizePoints(e.points,t,i);return s&&s.length>0?(e.points=s,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,i,s,r){return"point"===e?e=>{e.x=t(e.x),e.y=i(e.y),s&&(e.z=s(e.z))}:"polyline"===e||"polygon"===e?e=>{const n=(0,f.Bi)(e)?e.rings:e.paths;let a,l;for(let e=0,s=n.length;e<s;e++){const s=n[e];for(let e=0,r=s.length;e<r;e++){const r=s[e];e>0?(a+=r[0],l+=r[1]):(a=r[0],l=r[1]),r[0]=t(a),r[1]=i(l)}}if(s&&r)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,i=t.length;e<i;e++){const i=t[e];i[2]=s(i[2]),i[3]=r(i[3])}}else if(s)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,i=t.length;e<i;e++){const i=t[e];i[2]=s(i[2])}}else if(r)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,i=t.length;e<i;e++){const i=t[e];i[2]=r(i[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=i(e.ymin),e.xmax=t(e.xmax),e.ymax=i(e.ymax),s&&null!=e.zmax&&null!=e.zmin&&(e.zmax=s(e.zmax),e.zmin=s(e.zmin)),r&&null!=e.mmax&&null!=e.mmin&&(e.mmax=r(e.mmax),e.mmin=r(e.mmin))}:"multipoint"===e?e=>{const n=e.points;let a,l;for(let e=0,s=n.length;e<s;e++){const s=n[e];e>0?(a+=s[0],l+=s[1]):(a=s[0],l=s[1]),s[0]=t(a),s[1]=i(l)}if(s&&r)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=s(t[2]),t[3]=r(t[3])}else if(s)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=s(t[2])}else if(r)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=r(t[2])}}:null}};(0,r._)([(0,u.MZ)({type:String,json:{write:!0}})],m.prototype,"displayFieldName",void 0),(0,r._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],m.prototype,"exceededTransferLimit",void 0),(0,r._)([(0,u.MZ)({type:[n.A],json:{write:!0}})],m.prototype,"features",void 0),(0,r._)([(0,c.w)("features")],m.prototype,"readFeatures",null),(0,r._)([(0,u.MZ)({type:[_.A],json:{write:!0}})],m.prototype,"fields",void 0),(0,r._)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],m.prototype,"geometryType",void 0),(0,r._)([(0,d.K)("geometryType")],m.prototype,"writeGeometryType",null),(0,r._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],m.prototype,"hasM",void 0),(0,r._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],m.prototype,"hasZ",void 0),(0,r._)([(0,u.MZ)({types:y.yR,json:{write:!0}})],m.prototype,"queryGeometry",void 0),(0,r._)([(0,c.w)("queryGeometry")],m.prototype,"readQueryGeometry",null),(0,r._)([(0,u.MZ)({type:p.A,json:{write:!0}})],m.prototype,"spatialReference",void 0),(0,r._)([(0,d.K)("spatialReference")],m.prototype,"writeSpatialReference",null),(0,r._)([(0,u.MZ)({json:{write:!0}})],m.prototype,"transform",void 0),m=s=(0,r._)([(0,h.$)("esri.rest.support.FeatureSet")],m),m.prototype.toJSON.isDefaultToJSON=!0},27865:(e,t,i)=>{i.d(t,{O9:()=>n,dw:()=>a,mj:()=>r});var s=i(59247);function r(e,t){const i=e.length>t.length?e:t;return(e.length>t.length?t:e).every(((e,t)=>e.type===i[t].type))}function n(e,t){const i=e.length>t.length?e:t,r=e.length>t.length?t:e;for(let e=r.length;e<i.length;e++)r.push((0,s.sK)(i[e]))}function a(e){const t=e[0];return!!t&&"type"in t}},30235:(e,t,i)=>{i.d(t,{A:()=>f});var s=i(52106),r=i(87449),n=i(11221),a=i(89169),l=i(33325),o=i(80609),u=i(39516),c=i(91075),h=i(13600),d=i(33143),p=i(20437);class f extends n.A{constructor(e){super(e),this.declaredClass="esri.arcade.featureset.sources.FeatureLayerMemory",this._removeGeometry=!1,this._overrideFields=null,this._forceIsTable=!1,e.spatialReference&&(this.spatialReference=e.spatialReference),this._transparent=!0,this._maxProcessing=1e3,this._layer=e.layer,this._wset=null,!0===e.isTable&&(this._forceIsTable=!0),void 0!==e.outFields&&(this._overrideFields=e.outFields),void 0!==e.includeGeometry&&(this._removeGeometry=!1===e.includeGeometry)}_maxQueryRate(){return l.gO}end(){return this._layer}optimisePagingFeatureQueries(){}async loadImpl(){return!0===this._layer.loaded?(this._initialiseFeatureSet(),this):(await this._layer.load(),this._initialiseFeatureSet(),this)}get gdbVersion(){return""}_initialiseFeatureSet(){if(null==this.spatialReference&&(this.spatialReference=this._layer.spatialReference),this.geometryType=this._layer.geometryType??"",this.fields=this._layer.fields.slice(),null!==this._overrideFields)if(1===this._overrideFields.length&&"*"===this._overrideFields[0])this._overrideFields=null;else{const e=[],t=[];for(const i of this.fields)if("oid"===i.type||this._layer.objectIdField===i.name)e.push(i),t.push(i.name);else for(const s of this._overrideFields)if(s.toLowerCase()===i.name.toLowerCase()){e.push(i),t.push(i.name);break}this.fields=e,this._overrideFields=t}this.objectIdField=this._layer.objectIdField;for(const e of this.fields)"global-id"===e.type&&(this.globalIdField=e.name);this._databaseType=l.zl.Standardised,this.hasZ=!0===this._layer?.capabilities?.data?.supportsZ,this.hasM=!0===this._layer?.capabilities?.data?.supportsM,this.subtypeField=("subtypeField"in this._layer?this._layer.subtypeField:null)??"",this.subtypes="subtypes"in this._layer?this._layer.subtypes:null,this.typeIdField=("typeIdField"in this._layer?this._layer.typeIdField:null)??"",this.types="types"in this._layer?this._layer.types:null}isTable(){return this._forceIsTable||"isTable"in this._layer&&this._layer.isTable||"table"===this._layer.type||!this._layer.geometryType}_isInFeatureSet(){return l.J6.InFeatureSet}_candidateIdTransform(e){return e}async _getSet(e){if(null===this._wset){await this._ensureLoaded();const t=await this._getFilteredSet("",null,null,null,e);return this._wset=t,t}return this._wset}_createQuery(){const e=this._layer.createQuery();return e.returnZ=this.hasZ,e.returnM=this.hasM,e.outFields=this._overrideFields??["*"],e.returnGeometry=!this._removeGeometry,e}_changeFeature(e){const t={};for(const i of this.fields)t[i.name]=e.attributes[i.name];return new s.A({geometry:!0===this._removeGeometry?null:e.geometry,attributes:t})}async _getFilteredSet(e,t,i,s,r){let n="",c=!1;if(null!==s&&(n=s.constructClause(),c=!0),this.isTable()&&t&&null!==e&&""!==e)return new a.A([],[],!0,null);const h=this._createQuery();h.where=(0,u.mA)(h.where,null===i?null===t?"1=1":"":(0,o.YY)(i,l.zl.Standardised)),h.spatialRelationship=this._makeRelationshipEnum(e),h.outSpatialReference=this.spatialReference,h.orderByFields=""!==n?n.split(","):null,h.geometry=null===t?null:t,h.relationParameter=this._makeRelationshipParam(e);const d=await this._layer.queryFeatures(h);if(null===d)return new a.A([],[],c,null);this._checkCancelled(r);const p=[];return d.features.forEach((e=>{const t=e.attributes[this._layer.objectIdField];p.push(t),this._featureCache[t]=this._changeFeature(e)})),new a.A([],p,c,null)}_makeRelationshipEnum(e){if(e.includes("esriSpatialRelRelation"))return"relation";switch(e){case"esriSpatialRelRelation":return"relation";case"esriSpatialRelIntersects":return"intersects";case"esriSpatialRelContains":return"contains";case"esriSpatialRelOverlaps":return"overlaps";case"esriSpatialRelWithin":return"within";case"esriSpatialRelTouches":return"touches";case"esriSpatialRelCrosses":return"crosses";case"esriSpatialRelEnvelopeIntersects":return"envelope-intersects"}return e}_makeRelationshipParam(e){return e.includes("esriSpatialRelRelation")?e.split(":")[1]:""}async _queryAllFeatures(){if(this._wset)return this._wset;if(await this._ensureLoaded(),this._layer.source&&this._layer.source.items){const e=[];return this._layer.source.items.forEach((t=>{const i=t.attributes[this._layer.objectIdField];e.push(i),this._featureCache[i]=this._changeFeature(t)})),this._wset=new a.A([],e,!1,null),this._wset}const e=this._createQuery();e.where="1=1";const t=await this._layer.queryFeatures(e),i=[];return t.features.forEach((e=>{const t=e.attributes[this._layer.objectIdField];i.push(t),this._featureCache[t]=this._changeFeature(e)})),this._wset=new a.A([],i,!1,null),this._wset}async _getFeatures(e,t,i){const s=[];-1!==t&&void 0===this._featureCache[t]&&s.push(t);for(let r=e._lastFetchedIndex;r<e._known.length&&(e._lastFetchedIndex+=1,!(void 0===this._featureCache[e._known[r]]&&(e._known[r]!==t&&s.push(e._known[r]),s.length>i)));r++);if(0===s.length)return"success";throw new r.dr(r.D_.MissingFeatures)}async _refineSetBlock(e){return e}async _stat(){return{calculated:!1}}async _canDoAggregates(){return!1}relationshipMetaData(){return[]}static _cloneAttr(e){const t={};for(const i in e)t[i]=e[i];return t}nativeCapabilities(){return{title:this._layer.title??"",canQueryRelated:!1,source:this,capabilities:this._layer.capabilities,databaseType:this._databaseType,requestStandardised:!0}}static create(e,t){let i=e.layerDefinition.objectIdField;const s=e.layerDefinition.typeIdField??"",r=[];if(e.layerDefinition.types)for(const t of e.layerDefinition.types)r.push(d.A.fromJSON(t));let n=e.layerDefinition.geometryType;void 0===n&&(n=e.featureSet.geometryType||"");let a=e.featureSet.features;const l=t.toJSON();if(!i){let t=!1;for(const s of e.layerDefinition.fields)if("oid"===s.type||"esriFieldTypeOID"===s.type){i=s.name,t=!0;break}if(!1===t){let t="FID",s=!0,r=0;for(;s;){let i=!0;for(const s of e.layerDefinition.fields)if(s.name===t){i=!1;break}!0===i?s=!1:(r++,t="FID"+r.toString())}e.layerDefinition.fields.push({type:"esriFieldTypeOID",name:t,alias:t});const n=[];for(let i=0;i<a.length;i++)n.push({geometry:e.featureSet.features[i].geometry,attributes:e.featureSet.features[i].attributes?this._cloneAttr(e.featureSet.features[i].attributes):{}}),n[i].attributes[t]=i;a=n,i=t}}const o=[];for(const t of e.layerDefinition.fields)t instanceof p.A?o.push(t):o.push(p.A.fromJSON(t));let u=n;switch(u||(u=""),u){case"esriGeometryPoint":u="point";break;case"esriGeometryPolyline":u="polyline";break;case"esriGeometryPolygon":u="polygon";break;case"esriGeometryEnvelope":u="extent";break;case"esriGeometryMultipoint":u="multipoint";break;case"":case"esriGeometryNull":u="esriGeometryNull"}if("esriGeometryNull"!==u)for(const e of a)e.geometry&&e.geometry instanceof c.A==0&&(e.geometry.type=u,void 0===e.geometry.spatialReference&&(e.geometry.spatialReference=l));else for(const e of a)e.geometry&&(e.geometry=null);const y={outFields:["*"],source:a,fields:o,hasZ:!0===e?.layerDefinition?.hasZ||!0===e?.featureSet?.hasZ,hasM:!0===e?.layerDefinition?.hasM||!0===e?.featureSet?.hasM,types:r,typeIdField:s,objectIdField:i,spatialReference:t},_="esriGeometryNull"===u||null===u;_||(y.geometryType=u);const g=new h.default(y);return e?.layerDefinition?.subtypeField&&e?.layerDefinition?.subtypes&&g.read({subtypes:e.layerDefinition.subtypes,subtypeField:e.layerDefinition.subtypeField}),new f({layer:g,spatialReference:t,isTable:_})}async queryAttachments(){return[]}async getFeatureByObjectId(e){const t=this._createQuery();t.where=this.objectIdField+"="+e.toString();const i=await this._layer.queryFeatures(t);return 1===i.features.length?i.features[0]:null}async getOwningSystemUrl(){return""}async getIdentityUser(){return""}get preferredTimeZone(){return"preferredTimeZone"in this._layer?this._layer.preferredTimeZone:null}get dateFieldsTimeZone(){return"dateFieldsTimeZone"in this._layer?this._layer.dateFieldsTimeZone:null}get datesInUnknownTimezone(){return"datesInUnknownTimezone"in this._layer&&this._layer.datesInUnknownTimezone}get editFieldsInfo(){return"editFieldsInfo"in this._layer?this._layer.editFieldsInfo:null}get timeInfo(){return this._layer?.timeInfo}async getFeatureSetInfo(){const e=this._layer.title&&this._layer.parent;return this.fsetInfo??{layerId:null,layerName:null,itemId:null,serviceLayerUrl:null,webMapLayerId:e?this._layer.id??null:null,webMapLayerTitle:e?this._layer.title??null:null,className:null,objectClassId:null}}}},32730:(e,t,i)=>{i.d(t,{BI:()=>_,D3:()=>f,XJ:()=>y,lc:()=>p,mX:()=>m,rU:()=>g,tH:()=>v});var s=i(799);const r="__begin__",n="__end__",a=new RegExp(r,"ig"),l=new RegExp(n,"ig"),o=new RegExp("^"+r,"i"),u=new RegExp(n+"$","i"),c='"',h=c+" + ",d=" + "+c;function p(e){return e.replaceAll(new RegExp("\\[","g"),"{").replaceAll(new RegExp("\\]","g"),"}")}function f(e){return e.replaceAll(new RegExp("\\{","g"),"[").replaceAll(new RegExp("\\}","g"),"]")}function y(e){const t={expression:"",type:"none"};return e.labelExpressionInfo?e.labelExpressionInfo.value?(t.expression=e.labelExpressionInfo.value,t.type="conventional"):e.labelExpressionInfo.expression&&(t.expression=e.labelExpressionInfo.expression,t.type="arcade"):null!=e.labelExpression&&(t.expression=p(e.labelExpression),t.type="conventional"),t}function _(e){const t=y(e);if(!t)return null;switch(t.type){case"conventional":return m(t.expression);case"arcade":return t.expression}return null}function g(e){const t=y(e);if(!t)return null;switch(t.type){case"conventional":return function(e){const t=e?.match(w);return t?.[1].trim()||null}(t.expression);case"arcade":return v(t.expression)}return null}function m(e){let t;return e?(t=(0,s.HC)(e,(e=>r+'$feature["'+e+'"]'+n)),t=o.test(t)?t.replace(o,""):c+t,t=u.test(t)?t.replace(u,""):t+c,t=t.replaceAll(a,h).replaceAll(l,d)):t='""',t}const w=/^\s*\{([^}]+)\}\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,F=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,S=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function v(e){if(!e)return null;let t=b.exec(e)||F.exec(e);return t?t[1]||t[3]:(t=S.exec(e),t?t[2]:null)}},32756:(e,t,i)=>{i.d(t,{Rr:()=>o,fY:()=>c,ne:()=>u});var s=i(90237),r=i(93637),n=i(10107),a=(i(44208),i(53966),i(87811),i(40608)),l=i(91880);function o(e,t,i){if(!e)return null;const s=e.find((e=>!!e.field));if(!s)return null;const r=new l.A;return r.read(s,i),[r]}const u={type:[l.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:o},write:{writer:function(e,t,i,s){const n=e.find((e=>!!e.field));n&&(0,r.sM)(i,[n.toJSON()],t)}}}},c=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,s._)([(0,n.MZ)(u)],t.prototype,"orderBy",void 0),t=(0,s._)([(0,a.$)("esri.layers.mixins.OrderedLayer")],t),t}},33143:(e,t,i)=>{i.d(t,{A:()=>d});var s=i(90237),r=i(69540),n=i(25482),a=i(10107),l=(i(44208),i(53966),i(87811),i(36005)),o=i(40608),u=i(43937),c=i(80451),h=i(29005);let d=class extends(r.A.ClonableMixin(n.A)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const i of Object.keys(e))t[i]=(0,c.rS)(e[i]);return t}writeDomains(e,t){const i={};for(const t of Object.keys(e))e[t]&&(i[t]=e[t]?.toJSON());t.domains=i}};(0,s._)([(0,a.MZ)({json:{write:!0}})],d.prototype,"id",void 0),(0,s._)([(0,a.MZ)({json:{write:!0}})],d.prototype,"name",void 0),(0,s._)([(0,a.MZ)({json:{write:!0}})],d.prototype,"domains",void 0),(0,s._)([(0,l.w)("domains")],d.prototype,"readDomains",null),(0,s._)([(0,u.K)("domains")],d.prototype,"writeDomains",null),(0,s._)([(0,a.MZ)({type:[h.A],json:{write:!0}})],d.prototype,"templates",void 0),d=(0,s._)([(0,o.$)("esri.layers.support.FeatureType")],d)},35704:(e,t,i)=>{i.d(t,{A:()=>h});var s=i(87449),r=i(11221),n=i(89169),a=i(33325),l=i(80609),o=i(74887),u=i(88368),c=i(16930);class h extends r.A{constructor(e){super(e),this.declaredClass="esri.arcade.featureset.actions.AttributeFilter",this._maxProcessing=1e3,this._parent=e.parentfeatureset,e.whereclause instanceof u.A?(this._whereclause=e.whereclause,this._whereClauseFunction=null):(this._whereClauseFunction=e.whereclause,this._whereclause=null)}_initialiseFeatureSet(){null!==this._parent?(this.fields=this._parent.fields.slice(),this.geometryType=this._parent.geometryType,this.objectIdField=this._parent.objectIdField,this.globalIdField=this._parent.globalIdField,this.spatialReference=this._parent.spatialReference,this.hasM=this._parent.hasM,this.hasZ=this._parent.hasZ,this.typeIdField=this._parent.typeIdField,this.types=this._parent.types,this.subtypeField=this._parent.subtypeField,this.subtypes=this._parent.subtypes):(this.fields=[],this.typeIdField="",this.subtypeField="",this.objectIdField="",this.globalIdField="",this.spatialReference=new c.A({wkid:4326}),this.geometryType=a.ik.point)}async _getSet(e){if(null===this._wset){await this._ensureLoaded();const t=await this._parent._getFilteredSet("",null,this._whereclause,null,e);return this._checkCancelled(e),null!==this._whereClauseFunction?this._wset=new n.A(t._candidates.slice().concat(t._known.slice()),[],t._ordered,this._clonePageDefinition(t.pagesDefinition)):this._wset=new n.A(t._candidates.slice(),t._known.slice(),t._ordered,this._clonePageDefinition(t.pagesDefinition)),this._wset}return this._wset}_isInFeatureSet(e){let t=this._parent?._isInFeatureSet(e);return t===a.J6.NotInFeatureSet?t:(t=this._idstates[e],void 0===t?a.J6.Unknown:t)}_getFeature(e,t,i){return this._parent._getFeature(e,t,i)}_getFeatures(e,t,i,s){return this._parent._getFeatures(e,t,i,s)}_featureFromCache(e){return this._parent._featureFromCache(e)}executeWhereClause(e){return this._whereclause?.testFeature(e)??!1}async executeWhereClauseDeferred(e){if(null!==this._whereClauseFunction){const t=this._whereClauseFunction(e);return(0,o.$X)(t),t}return this.executeWhereClause(e)}async _fetchAndRefineFeatures(e,t,i){const s=new n.A([],e,!1,null),r=Math.min(t,e.length);if(await(this._parent?._getFeatures(s,-1,r,i)),this._checkCancelled(i),null==this._whereClauseFunction){for(let t=0;t<r;t++){const i=this._parent?._featureFromCache(e[t]);!0===this.executeWhereClause(i)?this._idstates[e[t]]=a.J6.InFeatureSet:this._idstates[e[t]]=a.J6.NotInFeatureSet}return"success"}const l=[];for(let t=0;t<r;t++){const i=this._parent?._featureFromCache(e[t]);l.push(await this.executeWhereClauseDeferred(i))}for(let i=0;i<t;i++)!0===l[i]?this._idstates[e[i]]=a.J6.InFeatureSet:this._idstates[e[i]]=a.J6.NotInFeatureSet;return"success"}async _getFilteredSet(e,t,i,s,r){null!==this._whereClauseFunction||(null!==i?null!==this._whereclause&&(i=(0,l.kg)(this._whereclause,i)):i=this._whereclause),await this._ensureLoaded();const a=await this._parent._getFilteredSet(e,t,i,s,r);let o;return this._checkCancelled(r),o=null!==this._whereClauseFunction?new n.A(a._candidates.slice().concat(a._known.slice()),[],a._ordered,this._clonePageDefinition(a.pagesDefinition)):new n.A(a._candidates.slice(),a._known.slice(),a._ordered,this._clonePageDefinition(a.pagesDefinition)),o}async _stat(e,t,i,s,r,n,a){if(null!==this._whereClauseFunction)return null===r&&""===i&&null===s?this._manualStat(e,t,n,a):{calculated:!1};let o=this._whereclause;null!==r&&null!==this._whereclause&&(o=(0,l.kg)(this._whereclause,r));const u=await this._parent._stat(e,t,i,s,o,n,a);return!1===u.calculated?null===r&&""===i&&null===s?this._manualStat(e,t,n,a):{calculated:!1}:u}async _canDoAggregates(e,t,i,s,r){return null===this._whereClauseFunction&&(null!==r?null!==this._whereclause&&(r=(0,l.kg)(this._whereclause,r)):r=this._whereclause,null!==this._parent&&this._parent._canDoAggregates(e,t,i,s,r))}async _getAggregatePagesDataSourceDefinition(e,t,i,r,n,a,o){if(null===this._parent)throw new s.dr(s.D_.NeverReach);return null!==n?null!==this._whereclause&&(n=(0,l.kg)(this._whereclause,n)):n=this._whereclause,this._parent._getAggregatePagesDataSourceDefinition(e,t,i,r,n,a,o)}static registerAction(){r.A._featuresetFunctions.filter=function(e){if("function"==typeof e)return new h({parentfeatureset:this,whereclause:e});let t=null;return e instanceof u.A&&(t=e),new h({parentfeatureset:this,whereclause:t})}}getFieldsIndex(){return this._parent.getFieldsIndex()}}},36708:(e,t,i)=>{i.d(t,{C_:()=>d,OH:()=>y,Vh:()=>_,on:()=>h,pc:()=>g,wB:()=>o,z7:()=>u});var s=i(37955),r=i(36563),n=i(97768),a=i(74887),l=i(14012);function o(e,t,i={}){return c(e,t,i,p)}function u(e,t,i={}){return c(e,t,i,f)}function c(e,t,i={},s){let r=null;const a=i.once?(e,i)=>{s(e)&&((0,n.xt)(r),t(e,i))}:(e,i)=>{s(e)&&t(e,i)};if(r=(0,l.Cn)(e,a,i.sync,i.equals),i.initial){const t=e();a(t,t)}return r}function h(e,t,i,a={}){let l=null,u=null,c=null;function h(){l&&u&&(u.remove(),a.onListenerRemove?.(l),l=null,u=null)}function d(e){a.once&&a.once&&(0,n.xt)(c),i(e)}const p=o(e,((e,i)=>{h(),(0,s.wb)(e)&&(l=e,u=(0,s.on)(e,t,d),a.onListenerAdd?.(e))}),{sync:a.sync,initial:!0});return c=(0,r.hA)((()=>{p.remove(),h()})),c}function d(e,t){return function(e,t,i){if((0,a.G4)(i))return Promise.reject((0,a.NK)());const s=e();if(t?.(s))return Promise.resolve(s);let l=null;function o(){l=(0,n.xt)(l)}return new Promise(((s,n)=>{l=(0,r.vE)([(0,a.u7)(i,(()=>{o(),n((0,a.NK)())})),c(e,(e=>{o(),s(e)}),{sync:!1,once:!0},t??p)])}))}(e,f,t)}function p(e){return!0}function f(e){return!!e}i(80559);const y={sync:!0},_={initial:!0},g={sync:!0,initial:!0}},39516:(e,t,i)=>{let s;async function r(){return null==s&&(s=Promise.all([i.e(8368),i.e(4123)]).then(i.bind(i,44123)).then((e=>new e.WhereClauseCache(500,500)))),s}async function n(e,t){const i=await r(),s=i.get(e,t);if(null==s)throw i.getError(e,t);return s}function a(e,t){return e||=null,t||=null,"1=1"===e?t??e:"1=1"===t?e??t:e&&t?`(${e}) AND (${t})`:e??t}function l(e,t){return e||=null,t||=null,"1=1"===e||"1=1"===t||e===t?"1=1"===e?e:t:e&&t?`(${e}) OR (${t})`:e??t}i.d(t,{GP:()=>n,IW:()=>l,mA:()=>a})},40334:(e,t,i)=>{i.r(t),i.d(t,{constructAssociationMetaDataFeatureSetFromUrl:()=>re,constructFeatureSet:()=>ie,constructFeatureSetFromPortalItem:()=>he,constructFeatureSetFromRelationship:()=>ne,constructFeatureSetFromUrl:()=>te,convertToFeatureSet:()=>ce,createFeatureSetCollectionFromMap:()=>oe,createFeatureSetCollectionFromService:()=>ue,initialiseMetaDataCache:()=>X});var s=i(78888);class r{constructor(){this.declaredRootClass="esri.arcade.featureSetCollection",this._layerById={},this._layerByName={}}add(e,t,i){this._layerById[t]=i,this._layerByName[e]=i}async featureSetByName(e,t=!0,i=["*"]){return void 0===this._layerByName[e]?null:this._layerByName[e]}async featureSetById(e,t=!0,i=["*"]){return void 0===this._layerById[e]?null:this._layerById[e]}castToText(e=!1){return"object, FeatureSetCollection"}}var n=i(78878),a=i(35704),l=i(52106),o=i(59534),u=i(68423),c=i(86691),h=i(87449),d=i(11221),p=i(89169),f=i(87594),y=i(33325),_=i(80609),g=i(1262),m=i(88368);class w{constructor(){this.field="",this.tofieldname="",this.typeofstat="MIN",this.workingexpr=null}clone(){const e=new w;return e.field=this.field,e.tofieldname=this.tofieldname,e.typeofstat=this.typeofstat,e.workingexpr=this.workingexpr,e}static parseStatField(e,t,i,s){const r=new w;r.field=e;const n=m.A.create(t,{fieldsIndex:i,timeZone:s}),a=function(e){if("function"===e.parseTree.type){if(0===e.parseTree.args.value.length)return{name:e.parseTree.name,expr:null};if(e.parseTree.args.value.length>1)throw new g.L8(g.Z7.MissingStatisticParameters);const t=m.A.create((0,_.Mi)(e.parseTree.args.value[0],y.zl.Standardised,e.parameters),{fieldsIndex:e.fieldsIndex,timeZone:e.timeZone,currentUser:e.currentUser});return{name:e.parseTree.name,expr:t}}return null}(n);if(null===a)throw new g.L8(g.Z7.UnsupportedSqlFunction,{function:""});const l=a.name.toUpperCase().trim();if("MIN"===l){if(r.typeofstat="MIN",r.workingexpr=a.expr,null===n)throw new g.L8(g.Z7.InvalidFunctionParameters,{function:"min"})}else if("MAX"===l){if(r.typeofstat="MAX",r.workingexpr=a.expr,null===n)throw new g.L8(g.Z7.InvalidFunctionParameters,{function:"max"})}else if("COUNT"===l)r.typeofstat="COUNT",r.workingexpr=a.expr;else if("STDEV"===l){if(r.typeofstat="STDDEV",r.workingexpr=a.expr,null===n)throw new g.L8(g.Z7.InvalidFunctionParameters,{function:"stdev"})}else if("SUM"===l){if(r.typeofstat="SUM",r.workingexpr=a.expr,null===n)throw new g.L8(g.Z7.InvalidFunctionParameters,{function:"sum"})}else if("MEAN"===l){if(r.typeofstat="AVG",r.workingexpr=a.expr,null===n)throw new g.L8(g.Z7.InvalidFunctionParameters,{function:l})}else if("AVG"===l){if(r.typeofstat="AVG",r.workingexpr=a.expr,null===n)throw new g.L8(g.Z7.InvalidFunctionParameters,{function:"avg"})}else{if("VAR"!==l)throw new g.L8(g.Z7.UnsupportedSqlFunction,{function:l});if(r.typeofstat="VAR",r.workingexpr=a.expr,null===n)throw new g.L8(g.Z7.InvalidFunctionParameters,{function:"var"})}return r}toStatisticsName(){switch(this.typeofstat.toUpperCase()){case"MIN":return"min";case"MAX":return"max";case"SUM":return"sum";case"COUNT":default:return"count";case"VAR":return"var";case"STDDEV":return"stddev";case"AVG":return"avg"}}}var b=i(53966),F=i(80200),S=i(74639),v=i(44729),I=i(55612),A=i(15032),T=i(16930),x=i(20437),C=i(95466);const D=new o.b(["MIN","MAX","VAR","STDDEV","COUNT","SUM","AVG"],[["VARIANCE","VAR"],["AVERAGE","AVG"],["MEAN","AVG"],["STDEV","STDDEV"]]);class R extends d.A{constructor(e){super(e),this._decodedStatsfield=[],this._decodedGroupbyfield=[],this._candosimplegroupby=!0,this.phsyicalgroupbyfields=[],this.objectIdField="ROW__ID",this._internalObjectIdField="ROW__ID",this._adaptedFields=[],this.declaredClass="esri.arcade.featureset.actions.Aggregate",this._uniqueIds=1,this._maxQuery=10,this._maxProcessing=10,this._parent=e.parentfeatureset,this._config=e}isTable(){return!0}async _getSet(e){if(null===this._wset){const t=await this._getFilteredSet("",null,null,null,e);return this._wset=t,this._wset}return this._wset}_isInFeatureSet(){return y.J6.InFeatureSet}_nextUniqueName(e){for(;1===e["T"+this._uniqueIds.toString()];)this._uniqueIds++;const t="T"+this._uniqueIds.toString();return e[t]=1,t}_convertToEsriFieldType(e){return e}_initialiseFeatureSet(){const e={};let t=!1,i=1;const s=this._parent?this._parent.getFieldsIndex():new C.A([]);for(this.objectIdField="ROW__ID",this.globalIdField="";!1===t;){let e=!1;for(let t=0;t<this._config.groupbyfields.length;t++)if(this._config.groupbyfields[t].name.toLowerCase()===this.objectIdField.toLowerCase()){e=!0;break}if(!1===e)for(let t=0;t<this._config.statsfields.length;t++)if(this._config.statsfields[t].name.toLowerCase()===this.objectIdField.toLowerCase()){e=!0;break}!1===e?t=!0:(this.objectIdField="ROW__ID"+i.toString(),i++)}for(const e of this._config.statsfields){const t=new w;t.field=e.name,t.tofieldname=e.name,t.workingexpr=e.expression instanceof m.A?e.expression:m.A.create(e.expression,{fieldsIndex:s,timeZone:this.dateFieldsTimeZoneDefaultUTC}),t.typeofstat=D.lookup(e.statistic)??"COUNT",this._decodedStatsfield.push(t)}this._decodedGroupbyfield=[];for(const e of this._config.groupbyfields){const t={name:e.name,singlefield:null,tofieldname:e.name,expression:e.expression instanceof m.A?e.expression:m.A.create(e.expression,{fieldsIndex:s,timeZone:this.dateFieldsTimeZoneDefaultUTC}),sqlType:null};this._decodedGroupbyfield.push(t)}if(null!==this._parent){this.geometryType=this._parent.geometryType,this.spatialReference=this._parent.spatialReference,this.hasM=this._parent.hasM,this.hasZ=this._parent.hasZ,this.typeIdField="";for(const t of this._parent.fields)e[t.name.toUpperCase()]=1;this.types=null,this.subtypes=null,this.subtypeField=""}else this.geometryType=y.ik.point,this.typeIdField="",this.types=null,this.subtypes=null,this.subtypeField="",this.spatialReference=new T.A({wkid:4326});this.fields=[];const r=new w;r.field=this._nextUniqueName(e),r.tofieldname=this.objectIdField,r.workingexpr=m.A.create(this._parent.objectIdField,{fieldsIndex:this._parent.getFieldsIndex(),timeZone:this.dateFieldsTimeZoneDefaultUTC}),r.typeofstat="MIN",this._decodedStatsfield.push(r);for(const t of this._decodedGroupbyfield){const i=new x.A;if(t.name=this._nextUniqueName(e),i.name=t.tofieldname,i.alias=i.name,(0,_.DA)(t.expression)){const e=this._parent.getField((0,_.YY)(t.expression,y.zl.Standardised));if(!e)throw new h.dr(h.D_.AggregationFieldNotFound);t.name=e.name,t.singlefield=e.name,this.phsyicalgroupbyfields.push(e.name),i.type=e.type,t.sqlType=e.type}else{i.type=this._convertToEsriFieldType((0,_.IY)(t.expression,this._parent.fields));const e=new x.A;e.name=t.name,e.alias=e.name,this.phsyicalgroupbyfields.push(t.name),this._adaptedFields.push(new u.Gr(e,t.expression)),this._candosimplegroupby=!1,t.sqlType=i.type}this.fields.push(i)}if(this._adaptedFields.length>0)for(const e of this._parent.fields)this._adaptedFields.push(new u.IO(e));for(let t=0;t<this._decodedStatsfield.length;t++){const i=new x.A;let s=null;const r=this._decodedStatsfield[t];r.field=this._nextUniqueName(e),r.tofieldname===this.objectIdField&&(this._internalObjectIdField=r.field),i.name=r.tofieldname,i.alias=i.name;const n=null!==r.workingexpr&&(0,_.DA)(r.workingexpr)?(0,_.YY)(r.workingexpr,y.zl.Standardised):"";switch(this._decodedStatsfield[t].typeofstat){case"SUM":if(""!==n){if(s=this._parent.getField(n),!s)throw new h.dr(h.D_.AggregationFieldNotFound);i.type=s.type}else i.type="double";break;case"MIN":case"MAX":if(""!==n){if(s=this._parent.getField(n),!s)throw new h.dr(h.D_.AggregationFieldNotFound);i.type=s.type}else i.type="double";break;case"COUNT":i.type="integer";break;case"STDDEV":case"VAR":case"AVG":if(""!==n&&(s=this._parent.getField(n),!s))throw new h.dr(h.D_.AggregationFieldNotFound);i.type="double"}this.fields.push(i)}}async _canDoAggregates(){return!1}async _getFeatures(e,t,i,s){-1!==t&&this._featureCache[t];const r=this._maxQuery;return!0===this._checkIfNeedToExpandKnownPage(e,r)?(await this._expandPagedSet(e,r,0,0,s),this._getFeatures(e,t,i,s)):"success"}async _getFilteredSet(e,t,i,s,r){if(""!==e)return new p.A([],[],!0,null);let n=null;const l={ordered:!1,nowhereclause:!1};if(await this._ensureLoaded(),null!==i)for(let e=0;e<this._decodedStatsfield.length;e++)if(!0===(0,_.Ju)(i,this._decodedStatsfield[e].tofieldname)){l.nowhereclause=!0,i=null;break}if(null!==s){l.ordered=!0;for(let e=0;e<this._decodedStatsfield.length;e++)if(!0===s.scanForField(this._decodedStatsfield[e].tofieldname)){s=null,l.ordered=!1;break}if(null!==s)for(const e of this._decodedGroupbyfield)if(null===e.singlefield&&!0===s.scanForField(e.tofieldname)){s=null,l.ordered=!1;break}}if(!1!==this._candosimplegroupby&&await this._parent._canDoAggregates(this.phsyicalgroupbyfields,this._decodedStatsfield,"",null,null)){let e=null;i&&(e=this._reformulateWhereClauseWithoutGroupByFields(i));let t=null;s&&(t=this._reformulateOrderClauseWithoutGroupByFields(s));const a=await this._parent._getAggregatePagesDataSourceDefinition(this.phsyicalgroupbyfields,this._decodedStatsfield,"",null,e,t,this._internalObjectIdField);return this._checkCancelled(r),n=!0===l.nowhereclause?new p.A(a._candidates.slice().concat(a._known.slice()),[],!0===l.ordered&&a._ordered,this._clonePageDefinition(a.pagesDefinition)):new p.A(a._candidates.slice(),a._known.slice(),!0===l.ordered&&a._ordered,this._clonePageDefinition(a.pagesDefinition)),n}let o=this._parent;if(this._adaptedFields.length>0&&(o=new u.a({parentfeatureset:this._parent,adaptedFields:this._adaptedFields,extraFilter:null})),!0===l.nowhereclause)n=new p.A(["GETPAGES"],[],!1,{aggregatefeaturesetpagedefinition:!0,resultOffset:0,resultRecordCount:this._maxQuery,internal:{fullyResolved:!1,workingItem:null,type:"manual",iterator:null,set:[],subfeatureset:new c.A({parentfeatureset:o,orderbyclause:new f.A(this.phsyicalgroupbyfields.join(",")+","+this._parent.objectIdField+" ASC")})}});else{let e=o;if(null!==i){let t=null;i&&(t=this._reformulateWhereClauseWithoutGroupByFields(i)),e=new a.A({parentfeatureset:e,whereclause:t})}n=new p.A(["GETPAGES"],[],!1,{aggregatefeaturesetpagedefinition:!0,resultOffset:0,resultRecordCount:this._maxQuery,internal:{fullyResolved:!1,workingItem:null,type:"manual",iterator:null,set:[],subfeatureset:new c.A({parentfeatureset:e,orderbyclause:new f.A(this.phsyicalgroupbyfields.join(",")+","+this._parent.objectIdField+" ASC")})}})}return n}_reformulateWhereClauseWithoutStatsFields(e){for(const t of this._decodedStatsfield)e=(0,_.bD)(e,t.tofieldname,(0,_.YY)(t.workingexpr,y.zl.Standardised),this._parent.getFieldsIndex());return e}_reformulateWhereClauseWithoutGroupByFields(e){for(const t of this._decodedGroupbyfield)t.tofieldname!==t.name&&(e=(0,_.bD)(e,t.tofieldname,(0,_.YY)(t.expression,y.zl.Standardised),this._parent.getFieldsIndex()));return e}_reformulateOrderClauseWithoutGroupByFields(e){const t=[];for(const e of this._decodedGroupbyfield)e.tofieldname!==e.name&&t.push({field:e.tofieldname,newfield:e.name});return t.length>0?e.replaceFields(t):e}_clonePageDefinition(e){return null===e?null:!0===e.aggregatefeaturesetpagedefinition?{aggregatefeaturesetpagedefinition:!0,resultRecordCount:e.resultRecordCount,resultOffset:e.resultOffset,internal:e.internal}:this._parent._clonePageDefinition(e)}async _refineSetBlock(e,t,i){return!0===this._checkIfNeedToExpandCandidatePage(e,this._maxQuery)?(await this._expandPagedSet(e,this._maxQuery,0,0,i),this._refineSetBlock(e,t,i)):(this._checkCancelled(i),e._candidates.length,this._refineKnowns(e,t),e._candidates.length,e._candidates.length,e)}_expandPagedSet(e,t,i,s,r){return this._expandPagedSetFeatureSet(e,t,i,s,r)}async _getPhysicalPage(e,t,i){if(!0===e.pagesDefinition.aggregatefeaturesetpagedefinition)return this._sequentialGetPhysicalItem(e,e.pagesDefinition.resultRecordCount,i,[]);const s=await this._getAgregagtePhysicalPage(e,t,i);for(const e of s){const t={geometry:e.geometry,attributes:{}},i={};for(const t in e.attributes)i[t.toLowerCase()]=e.attributes[t];for(const e of this._decodedGroupbyfield)t.attributes[e.tofieldname]=i[e.name.toLowerCase()];for(const e of this._decodedStatsfield)t.attributes[e.tofieldname]=i[e.field.toLowerCase()];if(null!=this._featureCache[t.attributes[this.objectIdField]])throw b.A.getLogger("esri.arcade.featureset.actions.GroupBy").error(`Duplicate object id returned: ${t.attributes[this.objectIdField]}`),new h.dr(h.D_.NeverReach);this._featureCache[t.attributes[this.objectIdField]]=new l.A(t)}return s.length}_sequentialGetPhysicalItem(e,t,i,s){return new Promise(((r,n)=>{null===e.pagesDefinition.internal.iterator&&(e.pagesDefinition.internal.iterator=e.pagesDefinition.internal.subfeatureset.iterator(i)),!0===e.pagesDefinition.internal.fullyResolved||0===t?r(s.length):this._nextAggregateItem(e,t,i,s,(n=>{null===n?r(s.length):(t-=1,r(this._sequentialGetPhysicalItem(e,t,i,s)))}),n)}))}_nextAggregateItem(e,t,i,s,r,a){try{(0,n.a0)(e.pagesDefinition.internal.iterator.next()).then((n=>{if(null===n)if(null!==e.pagesDefinition.internal.workingItem){const t=this._calculateAndAppendAggregateItem(e.pagesDefinition.internal.workingItem);s.push(t),e.pagesDefinition.internal.workingItem=null,e.pagesDefinition.internal.set.push(t.attributes[this.objectIdField]),e.pagesDefinition.internal.fullyResolved=!0,r(null)}else e.pagesDefinition.internal.fullyResolved=!0,r(null);else{const l=this._generateAggregateHash(n);if(null===e.pagesDefinition.internal.workingItem)e.pagesDefinition.internal.workingItem={features:[n],id:l};else{if(l!==e.pagesDefinition.internal.workingItem.id){const i=this._calculateAndAppendAggregateItem(e.pagesDefinition.internal.workingItem);return s.push(i),e.pagesDefinition.internal.workingItem=null,e.pagesDefinition.internal.set.push(i.attributes[this.objectIdField]),t-=1,e.pagesDefinition.internal.workingItem={features:[n],id:l},void r(i)}e.pagesDefinition.internal.workingItem.features.push(n)}this._nextAggregateItem(e,t,i,s,r,a)}}),a)}catch(e){a(e)}}_calculateFieldStat(e,t,i){const s=[];for(const i of e.features)if(null!==t.workingexpr){const e=t.workingexpr.calculateValue(i);null!==e&&(e instanceof v.n||e instanceof A.k?s.push(e.toNumber()):e instanceof I.g?s.push(e.toMilliseconds()):s.push(e))}else s.push(null);i.attributes[t.tofieldname]=(0,S.s)(t.typeofstat,[s])}_calculateAndAppendAggregateItem(e){const t={attributes:{},geometry:null};for(const i of this._decodedGroupbyfield){const s=i.singlefield?e.features[0].attributes[i.singlefield]:m.A.convertValueToStorageFormat(i.expression.calculateValue(e.features[0]),i.sqlType);t.attributes[i.tofieldname]=s}for(const i of this._decodedStatsfield)this._calculateFieldStat(e,i,t);const i=[];for(let s=0;s<this._decodedStatsfield.length;s++)i.push(this._calculateFieldStat(e,this._decodedStatsfield[s],t));if(null!=this._featureCache[t.attributes[this.objectIdField]])throw b.A.getLogger("esri.arcade.featureset.actions.GroupBy").error(`Duplicate object id returned: ${t.attributes[this.objectIdField]}`),new h.dr(h.D_.NeverReach);return this._featureCache[t.attributes[this.objectIdField]]=new l.A({attributes:t.attributes,geometry:t.geometry}),t}_generateAggregateHash(e){let t="";for(const i of this._decodedGroupbyfield){const s=i.singlefield?e.attributes[i.singlefield]:i.expression.calculateValue(e);t+=null==s?":":":"+s.toString()}return(0,F.d)(t,F.T.String)}async _stat(){return{calculated:!1}}async getFeatureByObjectId(){return null}static registerAction(){d.A._featuresetFunctions.groupby=function(e,t){return new R({parentfeatureset:this,groupbyfields:e,statsfields:t})}}}var k=i(54784),E=i(54461),L=i(70333),N=i(61454),M=i(66395),O=i(50145),P=i(4576),j=i(39516),G=i(65864),B=i(21325),q=i(13600),U=i(54546),Z=i(61956),V=i(7562);class W extends d.A{constructor(e){super(e),this.declaredClass="esri.arcade.featureset.sources.FeatureLayerDynamic",this._removeGeometry=!1,this._overrideFields=null,this.formulaCredential=null,this._pageJustIds=!1,this._requestStandardised=!1,this._useDefinitionExpression=!0,e.spatialReference&&(this.spatialReference=e.spatialReference),this._transparent=!0,this._maxProcessing=1e3,this._layer=e.layer,this._wset=null,void 0!==e.outFields&&(this._overrideFields=e.outFields),void 0!==e.includeGeometry&&(this._removeGeometry=!1===e.includeGeometry)}_maxQueryRate(){return y.gO}end(){return this._layer}optimisePagingFeatureQueries(e){this._pageJustIds=e}get urlQueryPath(){return this._layer.parsedUrl.path||""}convertQueryToLruCacheKey(e){const t=this.urlQueryPath+","+(0,y.JB)(e.toJSON());return(0,F.d)(t,F.T.String)}async loadImpl(){return!0===this._layer.loaded?(this._initialiseFeatureSet(),this):(await this._layer.load(),this._initialiseFeatureSet(),this)}_initialiseFeatureSet(){if(null==this.spatialReference&&(this.spatialReference=this._layer.spatialReference),this.geometryType=this._layer.geometryType??"",this.fields=this._layer.fields.slice(),this.hasZ=!0===this._layer?.capabilities?.data?.supportsZ,this.hasM=!0===this._layer?.capabilities?.data?.supportsM,null!==this._overrideFields)if(1===this._overrideFields.length&&"*"===this._overrideFields[0])this._overrideFields=null;else{const e=[],t=[];for(const i of this.fields)if("oid"===i.type)e.push(i),t.push(i.name);else for(const s of this._overrideFields)if(s.toLowerCase()===i.name.toLowerCase()){e.push(i),t.push(i.name);break}this.fields=e,this._overrideFields=t}if(this._layer.source&&this._layer.source.sourceJSON){const e=this._layer.source.sourceJSON.currentVersion;!0===this._layer.source.sourceJSON.useStandardizedQueries?(this._databaseType=y.zl.StandardisedNoInterval,null!=e&&e>=10.61&&(this._databaseType=y.zl.Standardised)):null!=e&&(e>=10.5&&(this._databaseType=y.zl.StandardisedNoInterval,this._requestStandardised=!0),e>=10.61&&(this._databaseType=y.zl.Standardised))}this.objectIdField=this._layer.objectIdField;for(const e of this.fields)"global-id"===e.type&&(this.globalIdField=e.name);this.subtypeField=this._layer.subtypeField??"",this.subtypes=this._layer.subtypes,this.typeIdField=("typeIdField"in this._layer?this._layer.typeIdField:null)??"",this.types="types"in this._layer?this._layer.types:null}_isInFeatureSet(){return y.J6.InFeatureSet}async _refineSetBlock(e){return e}_candidateIdTransform(e){return e}async _getSet(e){if(null===this._wset){await this._ensureLoaded();const t=await this._getFilteredSet("",null,null,null,e);return this._wset=t,t}return this._wset}async _runDatabaseProbe(e){await this._ensureLoaded();const t=new Z.A;this.datesInUnknownTimezone&&(t.timeReferenceUnknownClient=!0),t.where=e.replace("OBJECTID",this._layer.objectIdField);try{return await this._layer.queryObjectIds(t),!0}catch(e){return!1}}_canUsePagination(){return!(!this._layer.capabilities||!this._layer.capabilities.query||!0!==this._layer.capabilities.query.supportsPagination)}_cacheableFeatureSetSourceKey(){return this._layer.url}get gdbVersion(){return this._layer&&this._layer.capabilities&&this._layer.capabilities.data&&this._layer.capabilities.data.isVersioned?this._layer.gdbVersion||"SDE.DEFAULT":""}nativeCapabilities(){return{title:this._layer.title??"",source:this,canQueryRelated:!0,capabilities:this._layer.capabilities,databaseType:this._databaseType,requestStandardised:this._requestStandardised}}_createQuery(){const e=this._layer.createQuery();return e.returnZ=this.hasZ,e.returnM=this.hasM,this.datesInUnknownTimezone&&(e.timeReferenceUnknownClient=!0),this._requestStandardised&&(e.sqlFormat="standard"),this._useDefinitionExpression?"subtype-group"===this._layer.type&&(e.where=this._layer.definitionExpression):e.where=null,e}executeQuery(e,t){const i="execute"===t?this._layer.queryFeatures.bind(this._layer):"executeForCount"===t?this._layer.queryFeatureCount.bind(this._layer):this._layer.queryObjectIds.bind(this._layer);let s=null;if(this.recentlyUsedQueries){const t=this.convertQueryToLruCacheKey(e);s=this.recentlyUsedQueries.getFromCache(t),null===s&&(s=i(e),this.recentlyUsedQueries.addToCache(t,s),s=s.catch((e=>{throw this.recentlyUsedQueries?.removeFromCache(t),e})))}return this.featureSetQueryInterceptor&&this.featureSetQueryInterceptor.preLayerQueryCallback({layer:this._layer,query:e,method:t}),null===s&&(s=i(e)),s}async _getFilteredSet(e,t,i,s,r){const n=await this.databaseType();if(this.isTable()&&t&&null!==e&&""!==e)return new p.A([],[],!0,null);if(this._canUsePagination())return this._getFilteredSetUsingPaging(e,t,i,s,r);let a="",l=!1;null!==s&&this._layer.capabilities&&this._layer.capabilities.query&&!0===this._layer.capabilities.query.supportsOrderBy&&(a=s.constructClause(),l=!0);const o=this._createQuery();o.where=(0,j.mA)(o.where,null===i?null===t?"1=1":"":(0,_.YY)(i,n)),o.spatialRelationship=this._makeRelationshipEnum(e),o.outSpatialReference=this.spatialReference,o.orderByFields=""!==a?a.split(","):null,o.geometry=null===t?null:t,o.relationParameter=this._makeRelationshipParam(e);let u=await this.executeQuery(o,"executeForIds");return null===u&&(u=[]),this._checkCancelled(r),new p.A([],u,l,null)}_expandPagedSet(e,t,i,s,r){return this._expandPagedSetFeatureSet(e,t,i,s,r)}async _getFilteredSetUsingPaging(e,t,i,s,r){let n="",a=!1;null!==s&&this._layer.capabilities&&this._layer.capabilities.query&&!0===this._layer.capabilities.query.supportsOrderBy&&(n=s.constructClause(),a=!0);const l=await this.databaseType(),o=null===i?null===t?"1=1":"":(0,_.YY)(i,l);let u=this._maxQueryRate();const c=this._layer.capabilities?.query.maxRecordCount;null!=c&&c<u&&(u=c);let h=null;if(!0===this._pageJustIds)h=new p.A([],["GETPAGES"],a,{spatialRel:this._makeRelationshipEnum(e),relationParam:this._makeRelationshipParam(e),outFields:this._layer.objectIdField,resultRecordCount:u,resultOffset:0,geometry:null===t?null:t,where:o,orderByFields:n,returnGeometry:!1,returnIdsOnly:"false",internal:{set:[],lastRetrieved:0,lastPage:0,fullyResolved:!1}});else{let i=!0;!0===this._removeGeometry&&(i=!1);const s=this._overrideFields??this._fieldsIncludingObjectId(["*"]);h=new p.A([],["GETPAGES"],a,{spatialRel:this._makeRelationshipEnum(e),relationParam:this._makeRelationshipParam(e),outFields:s.join(","),resultRecordCount:u,resultOffset:0,geometry:null===t?null:t,where:o,orderByFields:n,returnGeometry:i,returnIdsOnly:"false",internal:{set:[],lastRetrieved:0,lastPage:0,fullyResolved:!1}})}return await this._expandPagedSet(h,u,0,1,r),h}_clonePageDefinition(e){return null===e?null:!0!==e.groupbypage?{groupbypage:!1,spatialRel:e.spatialRel,relationParam:e.relationParam,outFields:e.outFields,resultRecordCount:e.resultRecordCount,resultOffset:e.resultOffset,geometry:e.geometry,where:e.where,orderByFields:e.orderByFields,returnGeometry:e.returnGeometry,returnIdsOnly:e.returnIdsOnly,internal:e.internal}:{groupbypage:!0,spatialRel:e.spatialRel,relationParam:e.relationParam,outFields:e.outFields,resultRecordCount:e.resultRecordCount,useOIDpagination:e.useOIDpagination,generatedOid:e.generatedOid,groupByFieldsForStatistics:e.groupByFieldsForStatistics,resultOffset:e.resultOffset,outStatistics:e.outStatistics,geometry:e.geometry,where:e.where,orderByFields:e.orderByFields,returnGeometry:e.returnGeometry,returnIdsOnly:e.returnIdsOnly,internal:e.internal}}async _getPhysicalPage(e,t,i){const s=e.pagesDefinition.internal.lastRetrieved,r=s,n=e.pagesDefinition.internal.lastPage,a=this._createQuery();a.spatialRelationship=e.pagesDefinition.spatialRel,a.relationParameter=e.pagesDefinition.relationParam,a.outFields=e.pagesDefinition.outFields.split(","),a.num=e.pagesDefinition.resultRecordCount,a.start=e.pagesDefinition.internal.lastPage,a.geometry=e.pagesDefinition.geometry,a.where=(0,j.mA)(a.where,e.pagesDefinition.where),a.orderByFields=""!==e.pagesDefinition.orderByFields?e.pagesDefinition.orderByFields.split(","):null,a.returnGeometry=e.pagesDefinition.returnGeometry,a.outSpatialReference=this.spatialReference;const l=await this.executeQuery(a,"execute");if(this._checkCancelled(i),e.pagesDefinition.internal.lastPage!==n)return"done";const o=this._layer.objectIdField;for(let t=0;t<l.features.length;t++)e.pagesDefinition.internal.set[r+t]=l.features[t].attributes[o];if(!1===this._pageJustIds)for(let e=0;e<l.features.length;e++)this._featureCache[l.features[e].attributes[o]]=l.features[e];return(void 0===l.exceededTransferLimit&&l.features.length!==e.pagesDefinition.resultRecordCount||!1===l.exceededTransferLimit)&&(e.pagesDefinition.internal.fullyResolved=!0),e.pagesDefinition.internal.lastRetrieved=s+l.features.length,e.pagesDefinition.internal.lastPage+=e.pagesDefinition.resultRecordCount,"done"}_fieldsIncludingObjectId(e){if(null===e)return[this.objectIdField];const t=e.slice();if(t.includes("*"))return t;let i=!1;for(const e of t)if(e.toUpperCase()===this.objectIdField.toUpperCase()){i=!0;break}return!1===i&&t.push(this.objectIdField),t}async _getFeatures(e,t,i,s){const r=[];if(-1!==t&&void 0===this._featureCache[t]&&r.push(t),!0===this._checkIfNeedToExpandKnownPage(e,this._maxProcessingRate()))return await this._expandPagedSet(e,this._maxProcessingRate(),0,0,s),this._getFeatures(e,t,i,s);let n=0;for(let s=e._lastFetchedIndex;s<e._known.length;s++){if(e._lastFetchedIndex+=1,n++,void 0===this._featureCache[e._known[s]]){let i=!1;if(null!==this._layer._mode&&void 0!==this._layer._mode){const t=this._layer._mode;if(void 0!==t._featureMap[e._known[s]]){const r=t._featureMap[e._known[s]];null!==r&&(i=!0,this._featureCache[e._known[s]]=r)}}if(!1===i&&(e._known[s]!==t&&r.push(e._known[s]),r.length>=this._maxProcessingRate()-1))break}if(n>=i&&0===r.length)break}if(0===r.length)return"success";const a=this._createQuery();a.objectIds=r,a.outFields=this._overrideFields??this._fieldsIncludingObjectId(["*"]),a.returnGeometry=!0,!0===this._removeGeometry&&(a.returnGeometry=!1),a.outSpatialReference=this.spatialReference;const l=await this.executeQuery(a,"execute");if(this._checkCancelled(s),void 0!==l.error)throw new h.dr(h.D_.RequestFailed,{reason:l.error});const o=this._layer.objectIdField;for(let e=0;e<l.features.length;e++)this._featureCache[l.features[e].attributes[o]]=l.features[e];return"success"}async _getDistinctPages(e,t,i,s,r,n,a,l,o){await this._ensureLoaded();const u=await this.databaseType();let c=i.parseTree.column;const d=this._layer.fields??[];for(let e=0;e<d.length;e++)if(d[e].name.toLowerCase()===c.toLowerCase()){c=d[e].name;break}const p=this._createQuery();p.where=(0,j.mA)(p.where,null===n?null===r?"1=1":"":(0,_.YY)(n,u)),p.spatialRelationship=this._makeRelationshipEnum(s),p.relationParameter=this._makeRelationshipParam(s),p.geometry=null===r?null:r,p.returnDistinctValues=!0,p.returnGeometry=!1,p.outFields=[c];const f=await this.executeQuery(p,"execute");if(this._checkCancelled(o),!f.hasOwnProperty("features"))throw new h.dr(h.D_.InvalidStatResponse);let y=!1;for(let e=0;e<d.length;e++)if(d[e].name===c){"date"===d[e].type&&(y=!0);break}for(let e=0;e<f.features.length;e++){if(y){const t=f.features[e].attributes[c];null!==t?l.push(new Date(t)):l.push(t)}else l.push(f.features[e].attributes[c]);if(l.length>=a)break}return 0===f.features.length?l:f.features.length===this._layer.capabilities?.query.maxRecordCount&&l.length<a?{calculated:!0,result:await this._getDistinctPages(e+f.features.length,t,i,s,r,n,a,l,o)}:l}async _distinctStat(e,t,i,s,r,n,a){return{calculated:!0,result:await this._getDistinctPages(0,e,t,i,s,r,n,[],a)}}isTable(){return this._layer.isTable||null===this._layer.geometryType||"table"===this._layer.type||""===this._layer.geometryType||"esriGeometryNull"===this._layer.geometryType}async _countstat(e,t,i,s){const r=await this.databaseType();if(this.isTable()&&i&&null!==t&&""!==t)return{calculated:!0,result:0};const n=this._createQuery();return n.where=(0,j.mA)(n.where,null===s?null===i?"1=1":"":(0,_.YY)(s,r)),n.spatialRelationship=this._makeRelationshipEnum(t),n.relationParameter=this._makeRelationshipParam(t),n.geometry=null===i?null:i,n.returnGeometry=!1,{calculated:!0,result:await this.executeQuery(n,"executeForCount")}}async _stats(e,t,i,s,r,n,a){await this._ensureLoaded();const l=this._layer.capabilities?.query,o=!!l?.supportsSqlExpression,u=!!l?.supportsStatistics,c=!!l?.supportsDistinct;if("count"===e)return c?this._countstat(e,i,s,r):{calculated:!1};if(!1===u||!1===(0,_.DA)(t)&&!1===o||!1===t.isStandardized)return""!==i||null!==r?{calculated:!1}:this._manualStat(e,t,n,a);if("distinct"===e)return!1===c?""!==i||null!==r?{calculated:!1}:this._manualStat(e,t,n,a):this._distinctStat(e,t,i,s,r,n,a);const d=await this.databaseType();if(this.isTable()&&s&&null!==i&&""!==i)return{calculated:!0,result:null};const p=this._createQuery();p.where=(0,j.mA)(p.where,null===r?null===s?"1=1":"":(0,_.YY)(r,d)),p.spatialRelationship=this._makeRelationshipEnum(i),p.relationParameter=this._makeRelationshipParam(i),p.geometry=null===s?null:s;const f=new V.A;f.statisticType=(0,O.Dp)(e),f.onStatisticField=(0,_.YY)(t,d),f.outStatisticFieldName="ARCADE_STAT_RESULT",p.returnGeometry=!1;let y="ARCADE_STAT_RESULT";p.outStatistics=[f];const g=await this.executeQuery(p,"execute");if(!g.hasOwnProperty("features")||0===g.features.length)throw new h.dr(h.D_.InvalidStatResponse);let m=!1;const w=g.fields??[];for(let e=0;e<w.length;e++)if("ARCADE_STAT_RESULT"===w[e].name.toUpperCase()){y=w[e].name,"date"===w[e].type&&(m=!0);break}if(m){let e=g.features[0].attributes[y];return null!==e&&(e=new Date(g.features[0].attributes[y])),{calculated:!0,result:e}}return{calculated:!0,result:g.features[0].attributes[y]}}_stat(e,t,i,s,r,n,a){return this._stats(e,t,i,s,r,n,a)}async _canDoAggregates(e,t){await this._ensureLoaded();let i=!1;const s=this._layer.capabilities?.query,r=!0===s?.supportsSqlExpression;if(null!=s&&!0===s.supportsStatistics&&!0===s.supportsOrderBy&&(i=!0),i)for(let e=0;e<t.length-1;e++)(!1===t[e].workingexpr?.isStandardized||!1===(0,_.DA)(t[e].workingexpr)&&!1===r)&&(i=!1);return!1!==i}_makeRelationshipEnum(e){if(e.includes("esriSpatialRelRelation"))return"relation";switch(e){case"esriSpatialRelRelation":return"relation";case"esriSpatialRelIntersects":return"intersects";case"esriSpatialRelContains":return"contains";case"esriSpatialRelOverlaps":return"overlaps";case"esriSpatialRelWithin":return"within";case"esriSpatialRelTouches":return"touches";case"esriSpatialRelCrosses":return"crosses";case"esriSpatialRelEnvelopeIntersects":return"envelope-intersects"}return e}_makeRelationshipParam(e){return e.includes("esriSpatialRelRelation")?e.split(":")[1]:""}async _getAggregatePagesDataSourceDefinition(e,t,i,s,r,n,a){await this._ensureLoaded();const l=await this.databaseType();let o=null;if(!this._layer.capabilities.query.supportsPaginationOnAggregatedQueries){const t=this.getFieldsIndex();o={keyFields:e.map(((e,i)=>({name:t.normalizeFieldName(e)??e,asc:null==n||1===n._directions[i]})))}}let u="",c=!1;null!=n&&!0===this._layer.capabilities?.query?.supportsOrderBy&&(null==o||(0,P.MJ)(e,0,e.length,n._fields,0,Math.min(n._fields.length,e.length),((e,t)=>e.toLowerCase()===t.toLowerCase())))&&(u=n.constructClause(),c=!0),""===u&&(u=e.join(","));const h=[];for(let e=0;e<t.length;e++){const i=new V.A;i.onStatisticField=null!==t[e].workingexpr?(0,_.YY)(t[e].workingexpr,l):"",i.outStatisticFieldName=t[e].field,i.statisticType=t[e].toStatisticsName(),h.push(i)}let d=this._maxQueryRate();const f=this._layer.capabilities?.query.maxRecordCount;null!=f&&f<d&&(d=f);const y=null===r?null===s?"1=1":"":(0,_.YY)(r,l);return new p.A([],["GETPAGES"],c,{groupbypage:!0,spatialRel:this._makeRelationshipEnum(i),relationParam:this._makeRelationshipParam(i),outFields:["*"],useOIDpagination:!1,generatedOid:a,resultRecordCount:d,resultOffset:0,groupByFieldsForStatistics:e,outStatistics:h,geometry:null===s?null:s,where:y,orderByFields:u,returnGeometry:!1,returnIdsOnly:!1,internal:{lastMaxId:-1,set:[],lastRetrieved:0,lastPage:0,fullyResolved:!1,keysetPagination:o}})}async _getAgregagtePhysicalPage(e,t,i){let s=e.pagesDefinition.where;if(!0===e.pagesDefinition.useOIDpagination&&(s=(0,j.mA)(s,e.pagesDefinition.generatedOid+">"+e.pagesDefinition.internal.lastMaxId.toString())),null!=e.pagesDefinition.internal.keysetPagination?.clause){if(!this._layer.capabilities.query.supportsOrderBy)throw new h.dr(h.D_.NotImplemented);s=(0,j.mA)(s,(0,_.YY)(e.pagesDefinition.internal.keysetPagination.clause,await this.databaseType()))}const r=e.pagesDefinition.internal.lastRetrieved,n=r,a=e.pagesDefinition.internal.lastPage,o=this._createQuery();if(o.where=(0,j.mA)(o.where,s),o.spatialRelationship=e.pagesDefinition.spatialRel,o.relationParameter=e.pagesDefinition.relationParam,o.outFields=e.pagesDefinition.outFields,o.outStatistics=e.pagesDefinition.outStatistics,o.geometry=e.pagesDefinition.geometry,o.groupByFieldsForStatistics=e.pagesDefinition.groupByFieldsForStatistics,o.num=e.pagesDefinition.resultRecordCount,o.start=e.pagesDefinition.internal.lastPage,o.returnGeometry=e.pagesDefinition.returnGeometry,o.orderByFields=""!==e.pagesDefinition.orderByFields?e.pagesDefinition.orderByFields.split(","):null,this.isTable()&&o.geometry&&o.spatialRelationship)return[];const u=await this.executeQuery(o,"execute");if(this._checkCancelled(i),!u.hasOwnProperty("features"))throw new h.dr(h.D_.InvalidStatResponse);const c=[];if(e.pagesDefinition.internal.lastPage!==a)return[];u.features.length>0&&void 0===u.features[0].attributes[e.pagesDefinition.generatedOid]&&(e.pagesDefinition.generatedOid=e.pagesDefinition.generatedOid.toLowerCase());for(let t=0;t<u.features.length;t++)e.pagesDefinition.internal.set[n+t]=u.features[t].attributes[e.pagesDefinition.generatedOid];for(let e=0;e<u.features.length;e++)c.push(new l.A({attributes:u.features[e].attributes,geometry:null}));return e.pagesDefinition.internal.keysetPagination?0!==u.features.length&&u.exceededTransferLimit?function(e,t){null==e.clause&&(e.clause=function(e){if(0===e.length)throw new h.dr(h.D_.NeverReach);const t=[];for(let i=0;i<e.length;i++){const s=e[i],r=[`"${s.name.replace('"','""')}" ${s.asc?">":"<"} @last_${i}`];for(let t=0;t<i;t++){const i=e[t];r.push(`"${i.name.replace('"','""')}" = @last_${t}`)}t.push(r.join(" AND "))}const i=t.join(" OR ");return m.A.create(i)}(e.keyFields));for(let i=0;i<e.keyFields.length;i++){const s=e.keyFields[i].name;e.clause.parameters[`last_${i}`]=t.attributes[s]}}(e.pagesDefinition.internal.keysetPagination,c.at(-1)):e.pagesDefinition.internal.fullyResolved=!0:!0===e.pagesDefinition.useOIDpagination?0===u.features.length?e.pagesDefinition.internal.fullyResolved=!0:e.pagesDefinition.internal.lastMaxId=u.features[u.features.length-1].attributes[e.pagesDefinition.generatedOid]:(void 0===u.exceededTransferLimit&&u.features.length!==e.pagesDefinition.resultRecordCount||!1===u.exceededTransferLimit)&&(e.pagesDefinition.internal.fullyResolved=!0),e.pagesDefinition.internal.lastRetrieved=r+u.features.length,e.pagesDefinition.internal.lastPage+=e.pagesDefinition.resultRecordCount,c}static create(e,t,i,s,r){const n=new q.default({url:e,outFields:null===t?["*"]:t});return new W({layer:n,spatialReference:i,lrucache:s,interceptor:r})}relationshipMetaData(){return this._layer&&this._layer.source&&this._layer.source.sourceJSON?.relationships?this._layer.source.sourceJSON.relationships:[]}serviceUrl(){return(0,y.Qi)(this._layer.parsedUrl.path)}async queryAttachments(e,t,i,s,r){const n=this._layer;if(function(e){const t=e.capabilities;return t?.data.supportsAttachment&&t?.operations.supportsQueryAttachments}(n)){const a={objectIds:[e],returnMetadata:r};(t&&t>0||i&&i>0)&&(a.size=[t&&t>0?t:0,i&&i>0?i:t+1]),s&&s.length>0&&(a.attachmentTypes=s),this.featureSetQueryInterceptor&&this.featureSetQueryInterceptor.preLayerQueryCallback({layer:n,query:a,method:"attachments"});const l=await n.queryAttachments(new U.A(a)),o=[];return l&&l[e]&&l[e].forEach((t=>{const i=this._layer.parsedUrl.path+"/"+e.toString()+"/attachments/"+t.id.toString();let s=null;r&&t.exifInfo&&(s=M.A.convertJsonToArcade(t.exifInfo,"system",!0)),o.push(new N.A(t.id,t.name,t.contentType,t.size,i,s,t.keywords??null))})),o}return[]}async queryRelatedFeatures(e){const t={f:"json",relationshipId:e.relationshipId.toString(),definitionExpression:e.where,outFields:e.outFields?.join(","),returnGeometry:e.returnGeometry.toString()};void 0!==e.resultOffset&&null!==e.resultOffset&&(t.resultOffset=e.resultOffset.toString()),void 0!==e.resultRecordCount&&null!==e.resultRecordCount&&(t.resultRecordCount=e.resultRecordCount.toString()),e.orderByFields&&(t.orderByFields=e.orderByFields.join(",")),e.objectIds&&e.objectIds.length>0&&(t.objectIds=e.objectIds.join(",")),e.outSpatialReference&&(t.outSR=(0,B.YX)(e.outSpatialReference)),this.featureSetQueryInterceptor&&this.featureSetQueryInterceptor.preRequestCallback({layer:this._layer,queryPayload:t,method:"relatedrecords",url:this._layer.parsedUrl.path+"/queryRelatedRecords"});const i=await(0,s.A)(this._layer.parsedUrl.path+"/queryRelatedRecords",{responseType:"json",query:t});if(i.data){const e={},t=i.data;if(t?.relatedRecordGroups){const i=t.spatialReference;for(const s of t.relatedRecordGroups){const r=s.objectId,n=[];for(const e of s.relatedRecords){e.geometry&&(e.geometry.spatialReference=i);const t=new l.A({geometry:e.geometry?(0,G.rS)(e.geometry):null,attributes:e.attributes});n.push(t)}e[r]={features:n,exceededTransferLimit:!0===t.exceededTransferLimit}}}return e}throw new h.dr(h.D_.InvalidRequest)}async getFeatureByObjectId(e,t){const i=this._createQuery();i.outFields=t,i.returnGeometry=!1,i.outSpatialReference=this.spatialReference,i.where=(0,j.mA)(i.where,this.objectIdField+"="+e.toString()),this.featureSetQueryInterceptor&&this.featureSetQueryInterceptor.preLayerQueryCallback({layer:this._layer,query:i,method:"execute"});const s=await this._layer.queryFeatures(i);return 1===s.features.length?s.features[0]:null}async getIdentityUser(){await this.load();const e=L.id?.findCredential(this._layer.url);return e?e.userId:null}async getOwningSystemUrl(){await this.load();const e=L.id?.findServerInfo(this._layer.url);if(e)return e.owningSystemUrl;let t=this._layer.url;const i=t.toLowerCase().indexOf("/rest/services");if(t=i>-1?t.slice(0,i):t,t){t+="/rest/info";try{const e=await(0,s.A)(t,{query:{f:"json"}});let i="";return e.data?.owningSystemUrl&&(i=e.data.owningSystemUrl),i}catch(e){return""}}return""}getDataSourceFeatureSet(){const e=new W({layer:this._layer,spatialReference:this.spatialReference??void 0,outFields:this._overrideFields??void 0,includeGeometry:!this._removeGeometry,lrucache:this.recentlyUsedQueries??void 0,interceptor:this.featureSetQueryInterceptor??void 0});return e._useDefinitionExpression=!1,e}get preferredTimeZone(){return this._layer.preferredTimeZone??null}get dateFieldsTimeZone(){return this._layer.dateFieldsTimeZone??null}get datesInUnknownTimezone(){return this._layer.datesInUnknownTimezone??!1}get editFieldsInfo(){return this._layer.editFieldsInfo??null}get timeInfo(){return this._layer.timeInfo??null}async getFeatureSetInfo(){if(this.fsetInfo)return this.fsetInfo;let e=null,t="serviceItemId"in this._layer?this._layer.serviceItemId:null;const i=this._layer.parsedUrl?.path??null;if(i){const r=await(0,s.A)(i,{responseType:"json",query:{f:"json"}});e=r?.data?.name??null,t=r?.data?.serviceItemId??null}const r=this._layer.title&&null!==(this._layer.parent??null);return this.featureSetInfo={layerId:this._layer.layerId,layerName:""===e?null:e,itemId:""===t?null:t,serviceLayerUrl:""===i?null:i,webMapLayerId:r?this._layer.id??null:null,webMapLayerTitle:r?this._layer.title??null:null,className:null,objectClassId:null},this.fsetInfo}}var J=i(30235),z=i(26591);class Q extends d.A{constructor(e){super(e),this.declaredClass="esri.arcade.featureset.sources.FeatureLayerRelated",this._findObjectId=-1,this._requestStandardised=!1,this._removeGeometry=!1,this._overrideFields=null,this.featureObjectId=null,e.spatialReference&&(this.spatialReference=e.spatialReference),this._transparent=!0,this._maxProcessing=1e3,this._layer=e.layer,this._wset=null,this._findObjectId=e.objectId,this.featureObjectId=e.objectId,this.relationship=e.relationship,this._relatedLayer=e.relatedLayer,void 0!==e.outFields&&(this._overrideFields=e.outFields),void 0!==e.includeGeometry&&(this._removeGeometry=!1===e.includeGeometry)}_maxQueryRate(){return y.gO}end(){return this._layer}optimisePagingFeatureQueries(){}async loadImpl(){return await Promise.all([this._layer.load(),this._relatedLayer?.load()]),this._initialiseFeatureSet(),this}nativeCapabilities(){return this._relatedLayer.nativeCapabilities()}_initialiseFeatureSet(){if(null==this.spatialReference&&(this.spatialReference=this._layer.spatialReference),this.geometryType=this._relatedLayer.geometryType,this.fields=this._relatedLayer.fields.slice(),this.hasZ=this._relatedLayer.hasZ,this.hasM=this._relatedLayer.hasM,null!==this._overrideFields)if(1===this._overrideFields.length&&"*"===this._overrideFields[0])this._overrideFields=null;else{const e=[],t=[];for(const i of this.fields)if("oid"===i.type)e.push(i),t.push(i.name);else for(const s of this._overrideFields)if(s.toLowerCase()===i.name.toLowerCase()){e.push(i),t.push(i.name);break}this.fields=e,this._overrideFields=t}const e=this._layer.nativeCapabilities();e&&(this._databaseType=e.databaseType,this._requestStandardised=e.requestStandardised),this.objectIdField=this._relatedLayer.objectIdField,this.globalIdField=this._relatedLayer.globalIdField,this.hasM=this._relatedLayer.supportsM,this.hasZ=this._relatedLayer.supportsZ,this.typeIdField=this._relatedLayer.typeIdField,this.types=this._relatedLayer.types,this.subtypeField=this._relatedLayer.subtypeField,this.subtypes=this._relatedLayer.subtypes}async databaseType(){return await this._relatedLayer.databaseType(),this._databaseType=this._relatedLayer._databaseType,this._databaseType}isTable(){return this._relatedLayer.isTable()}_isInFeatureSet(){return y.J6.InFeatureSet}_candidateIdTransform(e){return e}async _getSet(e){if(null===this._wset){await this._ensureLoaded();const t=await this._getFilteredSet("",null,null,null,e);return this._wset=t,t}return this._wset}_changeFeature(e){const t={};for(const i of this.fields)t[i.name]=e.attributes[i.name];return new l.A({geometry:!0===this._removeGeometry?null:e.geometry,attributes:t})}async _getFilteredSet(e,t,i,s,r){if(await this.databaseType(),this.isTable()&&t&&null!==e&&""!==e)return new p.A([],[],!0,null);const n=this._layer.nativeCapabilities();if(!1===n.canQueryRelated)return new p.A([],[],!0,null);if(n.capabilities?.queryRelated.supportsPagination)return this._getFilteredSetUsingPaging(e,t,i,s,r);let a="",l=!1;null!==s&&!0===n.capabilities?.queryRelated.supportsOrderBy&&(a=s.constructClause(),l=!0);const o=new z.default;o.objectIds=[this._findObjectId];const u=null!==this._overrideFields?this._overrideFields:this._fieldsIncludingObjectId(this._relatedLayer.fields?this._relatedLayer.fields.map((e=>e.name)):["*"]);o.outFields=u,o.relationshipId=this.relationship.id,o.where="1=1";let c=!0;!0===this._removeGeometry&&(c=!1),o.returnGeometry=c,this._requestStandardised&&(o.sqlFormat="standard"),o.outSpatialReference=this.spatialReference,o.orderByFields=""!==a?a.split(","):null;const h=await n.source.queryRelatedFeatures(o);this._checkCancelled(r);const d=h[this._findObjectId]?h[this._findObjectId].features:[],f=[];for(let e=0;e<d.length;e++)this._featureCache[d[e].attributes[this._relatedLayer.objectIdField]]=d[e],f.push(d[e].attributes[this._relatedLayer.objectIdField]);const y=t&&null!==e&&""!==e,_=null!=i;return new p.A(y||_?f:[],y||_?[]:f,l,null)}_fieldsIncludingObjectId(e){if(null===e)return[this.objectIdField];const t=e.slice();if(t.includes("*"))return t;let i=!1;for(const e of t)if(e.toUpperCase()===this.objectIdField.toUpperCase()){i=!0;break}return!1===i&&t.push(this.objectIdField),t}async _getFilteredSetUsingPaging(e,t,i,s,r){let n="",a=!1;const l=this._layer.nativeCapabilities();null!==s&&!0===l.capabilities?.queryRelated.supportsOrderBy&&(n=s.constructClause(),a=!0),await this.databaseType();let o=this._maxQueryRate();const u=l.capabilities?.query.maxRecordCount;null!=u&&u<o&&(o=u);const c=t&&null!==e&&""!==e,h=null!=i;let d=null,f=!0;!0===this._removeGeometry&&(f=!1);const y=null!==this._overrideFields?this._overrideFields:this._fieldsIncludingObjectId(this._relatedLayer.fields?this._relatedLayer.fields.map((e=>e.name)):["*"]);return d=new p.A(c||h?["GETPAGES"]:[],c||h?[]:["GETPAGES"],a,{outFields:y.join(","),resultRecordCount:o,resultOffset:0,objectIds:[this._findObjectId],where:"1=1",orderByFields:n,returnGeometry:f,returnIdsOnly:"false",internal:{set:[],lastRetrieved:0,lastPage:0,fullyResolved:!1}}),await this._expandPagedSet(d,o,0,0,r),d}_expandPagedSet(e,t,i,s,r){return this._expandPagedSetFeatureSet(e,t,i,s,r)}_clonePageDefinition(e){return null===e?null:!0!==e.groupbypage?{groupbypage:!1,outFields:e.outFields,resultRecordCount:e.resultRecordCount,resultOffset:e.resultOffset,where:e.where,objectIds:e.objectIds,orderByFields:e.orderByFields,returnGeometry:e.returnGeometry,returnIdsOnly:e.returnIdsOnly,internal:e.internal}:{groupbypage:!0,outFields:e.outFields,resultRecordCount:e.resultRecordCount,useOIDpagination:e.useOIDpagination,generatedOid:e.generatedOid,groupByFieldsForStatistics:e.groupByFieldsForStatistics,resultOffset:e.resultOffset,outStatistics:e.outStatistics,geometry:e.geometry,where:e.where,objectIds:e.objectIds,orderByFields:e.orderByFields,returnGeometry:e.returnGeometry,returnIdsOnly:e.returnIdsOnly,internal:e.internal}}async _getPhysicalPage(e,t,i){const s=e.pagesDefinition.internal.lastRetrieved,r=s,n=e.pagesDefinition.internal.lastPage,a=this._layer.nativeCapabilities(),l=new z.default;!0===this._requestStandardised&&(l.sqlFormat="standard"),l.relationshipId=this.relationship.id,l.objectIds=e.pagesDefinition.objectIds,l.resultOffset=e.pagesDefinition.internal.lastPage,l.resultRecordCount=e.pagesDefinition.resultRecordCount,l.outFields=e.pagesDefinition.outFields.split(","),l.where=e.pagesDefinition.where,l.orderByFields=""!==e.pagesDefinition.orderByFields?e.pagesDefinition.orderByFields.split(","):null,l.returnGeometry=e.pagesDefinition.returnGeometry,l.outSpatialReference=this.spatialReference;const o=await a.source.queryRelatedFeatures(l);if(this._checkCancelled(i),e.pagesDefinition.internal.lastPage!==n)return 0;const u=o[this._findObjectId]?o[this._findObjectId].features:[];for(let t=0;t<u.length;t++)e.pagesDefinition.internal.set[r+t]=u[t].attributes[this._relatedLayer.objectIdField];for(let e=0;e<u.length;e++)this._featureCache[u[e].attributes[this._relatedLayer.objectIdField]]=u[e];const c=!o[this._findObjectId]||!1===o[this._findObjectId].exceededTransferLimit;return u.length!==e.pagesDefinition.resultRecordCount&&c&&(e.pagesDefinition.internal.fullyResolved=!0),e.pagesDefinition.internal.lastRetrieved=s+u.length,e.pagesDefinition.internal.lastPage+=e.pagesDefinition.resultRecordCount,u.length}async _getFeatures(e,t,i,s){const r=[];-1!==t&&void 0===this._featureCache[t]&&r.push(t);const n=this._maxQueryRate();if(!0===this._checkIfNeedToExpandKnownPage(e,n))return await this._expandPagedSet(e,n,0,0,s),this._getFeatures(e,t,i,s);let a=0;for(let s=e._lastFetchedIndex;s<e._known.length&&(a++,a<=i&&(e._lastFetchedIndex+=1),!("GETPAGES"!==e._known[s]&&void 0===this._featureCache[e._known[s]]&&(e._known[s]!==t&&r.push(e._known[s]),r.length>i)))&&!(a>=i&&0===r.length);s++);if(0===r.length)return"success";throw new h.dr(h.D_.MissingFeatures)}async _refineSetBlock(e,t,i){return e}async _stat(e,t,i,s,r,n,a){return{calculated:!1}}get gdbVersion(){return this._relatedLayer.gdbVersion}async _canDoAggregates(e,t,i,s,r){return!1}relationshipMetaData(){return this._relatedLayer.relationshipMetaData()}serviceUrl(){return this._relatedLayer.serviceUrl()}queryAttachments(e,t,i,s,r){return this._relatedLayer.queryAttachments(e,t,i,s,r)}getFeatureByObjectId(e,t){return this._relatedLayer.getFeatureByObjectId(e,t)}getOwningSystemUrl(){return this._relatedLayer.getOwningSystemUrl()}getIdentityUser(){return this._relatedLayer.getIdentityUser()}getDataSourceFeatureSet(){return this._relatedLayer}get preferredTimeZone(){return this._relatedLayer?.preferredTimeZone??null}get dateFieldsTimeZone(){return this._relatedLayer?.dateFieldsTimeZone??null}get datesInUnknownTimezone(){return this._relatedLayer?.datesInUnknownTimezone}get editFieldsInfo(){return this._relatedLayer?.editFieldsInfo??null}get timeInfo(){return this._relatedLayer?.timeInfo??null}async getFeatureSetInfo(){return this.fsetInfo??this._layer.featureSetInfo}}var $=i(23732),Y=i(92474),K=i(4146),H=i(80812);function X(){null===$.A.applicationCache&&($.A.applicationCache=new $.A)}async function ee(e,t,i){if($.A.applicationCache){const i=$.A.applicationCache.getLayerInfo(e);if(i){const s=await i;return new q.default({url:e,outFields:t,sourceJSON:s})}const s=new q.default({url:e,outFields:t}),r=(async()=>(await s.load(),s.sourceJSON))();if($.A.applicationCache){$.A.applicationCache.setLayerInfo(e,r);try{return await r,s}catch(t){throw $.A.applicationCache.clearLayerInfo(e),t}}return await r,s}if(null!=i){const s=i.getCachedLayerMetadata(e);if(s){const i=await s;return new q.default({url:e,outFields:t,sourceJSON:i})}const r=new q.default({url:e,outFields:t}),n=(async()=>(await r.load(),r.sourceJSON))();i.setCachedLayerMetadata(e,n);try{return await n,r}catch(t){throw i.removeCachedLayerMetadata(e,n),t}}return new q.default({url:e,outFields:t})}async function te(e,t,i,s,r,n=null){return ie(await ee(e,["*"],r),t,i,s,r,n)}function ie(e,t=null,i=null,s=!0,r=null,n=null){switch(e.type){case"catalog-footprint":return ie(e.parent,t,i,s,r,n);case"subtype-sublayer":{const a=ie(e.parent,t,i,s,r,n);return a.filter(m.A.create(e.parent.subtypeField+"="+e.subtypeCode.toString(),{fieldsIndex:e.parent.fieldsIndex,timeZone:a.dateFieldsTimeZoneDefaultUTC}))}case"csv":case"geojson":case"knowledge-graph-sublayer":case"wfs":return new J.A({layer:e,spatialReference:t,outFields:i,includeGeometry:s,lrucache:r,interceptor:n});case"catalog":case"feature":case"oriented-imagery":case"subtype-group":{const a={layer:e,spatialReference:t,outFields:i,includeGeometry:s,lrucache:r,interceptor:n};return!e.url&&e.source?new J.A(a):new W(a)}default:throw new Error(`Unsupported layer type: ${e.type}`)}}async function se(e,t){if(null!==$.A.applicationCache){const t=$.A.applicationCache.getLayerInfo(e);if(null!==t)return t}if(null!=t){const i=t.getCachedServiceMetadata(e);if(null!=i)return i}const i=(async()=>{const t=await(0,s.A)(e,{responseType:"json",query:{f:"json"}});if(t.data){const e=t.data;return e.layers||(e.layers=[]),e.tables||(e.tables=[]),e}return{layers:[],tables:[]}})();if(null!==$.A.applicationCache){$.A.applicationCache.setLayerInfo(e,i);try{return await i}catch(t){throw $.A.applicationCache.clearLayerInfo(e),t}}if(null!=t){t.setCachedServiceMetadata(e,i);try{return await i}catch(s){throw t.removeCachedServiceMetadata(e,i),s}}return i}async function re(e,t,i){const r={metadata:null,networkId:-1,unVersion:3,terminals:[],layerIdLookup:new Map,sourceIdLookup:new Map,queryelem:null,layerNameLkp:{},lkp:null},n=await se(e,null);if(r.metadata=n,void 0!==n.controllerDatasetLayers?.utilityNetworkLayerId&&null!==n.controllerDatasetLayers.utilityNetworkLayerId){if(n.layers)for(const e of n.layers)r.layerNameLkp[e.id]=e.name;if(n.tables)for(const e of n.tables)r.layerNameLkp[e.id]=e.name;const a=n.controllerDatasetLayers.utilityNetworkLayerId;r.networkId=a;const l=await async function(e,t){const i="QUERYDATAELEMTS:"+t.toString()+":"+e;if(null!==$.A.applicationCache){const e=$.A.applicationCache.getLayerInfo(i);if(null!==e)return e}const r=(async()=>{const i=await(0,s.A)(e+"/queryDataElements",{method:"post",responseType:"json",query:{layers:JSON.stringify([t.toString()]),f:"json"}});if(i.data){const e=i.data;if(e.layerDataElements?.[0])return e.layerDataElements[0]}throw new h.dr(h.D_.DataElementsNotFound)})();if(null!==$.A.applicationCache){$.A.applicationCache.setLayerInfo(i,r);try{return await r}catch(e){throw $.A.applicationCache.clearLayerInfo(i),e}}return r}(e,a);if(l){r.queryelem=l,r.queryelem?.dataElement&&void 0!==r.queryelem.dataElement.schemaGeneration&&(r.unVersion=r.queryelem.dataElement.schemaGeneration),r.lkp={},r.queryelem.dataElement.domainNetworks||(r.queryelem.dataElement.domainNetworks=[]);for(const e of r.queryelem.dataElement.domainNetworks){for(const t of e.edgeSources??[]){const e={layerId:t.layerId,sourceId:t.sourceId,className:r.layerNameLkp[t.layerId]??null};r.layerIdLookup.set(e.layerId,e),r.sourceIdLookup.set(e.sourceId,e),e.className&&(r.lkp[e.className]=e)}for(const t of e.junctionSources??[]){const e={layerId:t.layerId,sourceId:t.sourceId,className:r.layerNameLkp[t.layerId]??null};r.layerIdLookup.set(e.layerId,e),r.sourceIdLookup.set(e.sourceId,e),e.className&&(r.lkp[e.className]=e)}}if(r.queryelem.dataElement.terminalConfigurations)for(const e of r.queryelem.dataElement.terminalConfigurations)for(const t of e.terminals)r.terminals.push({terminalId:t.terminalId,terminalName:t.terminalName});const n=await async function(e){if(null!==$.A.applicationCache){const t=$.A.applicationCache.getLayerInfo(e);if(null!==t)return t}const t=(async()=>{const t=await(0,s.A)(e,{responseType:"json",query:{f:"json"}});return t.data?t.data:null})();if(null!==$.A.applicationCache){$.A.applicationCache.setLayerInfo(e,t);try{return await t}catch(t){throw $.A.applicationCache.clearLayerInfo(e),t}}return t}(e+"/"+a);if(void 0!==n.systemLayers?.associationsTableId&&null!==n.systemLayers.associationsTableId){let s=null;if(i&&r.unVersion<8){const i=[];r.unVersion>=4&&(i.push("STATUS"),i.push("PERCENTALONG")),s=await te(e+"/"+n.systemLayers.associationsTableId,t,["OBJECTID","FROMNETWORKSOURCEID","TONETWORKSOURCEID","FROMGLOBALID","TOGLOBALID","TOTERMINALID","FROMTERMINALID","ASSOCIATIONTYPE","ISCONTENTVISIBLE","GLOBALID",...i],!1,null,null),await s.load(),r.unVersion>=4&&(s=s.filter(m.A.create("STATUS NOT IN (1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 17, 18, 19, 20, 21, 22, 23, 25, 26, 27, 28, 29, 30, 31, 33, 34, 35, 36, 37, 38, 39, 41, 42, 43, 44, 45, 46, 47, 49, 50, 51, 52, 53, 54, 55, 57, 58, 59, 60, 61, 62, 63)",{fieldsIndex:s.getFieldsIndex(),timeZone:s.dateFieldsTimeZoneDefaultUTC})),await s.load())}return{lkp:r.lkp,associations:s,unVersion:r.unVersion,terminals:r.terminals,layerIdLookup:r.layerIdLookup,sourceIdLookup:r.sourceIdLookup}}return{associations:null,unVersion:r.unVersion,lkp:null,terminals:[],layerIdLookup:new Map,sourceIdLookup:new Map}}return{associations:null,unVersion:r.unVersion,lkp:null,terminals:[],layerIdLookup:new Map,sourceIdLookup:new Map}}return{associations:null,unVersion:r.unVersion,lkp:null,terminals:[],layerIdLookup:new Map,sourceIdLookup:new Map}}async function ne(e,t,i,s=null,r=null,n=!0,a=null,l=null){let o=e.serviceUrl();if(!o)return null;o="/"===o.charAt(o.length-1)?o+t.relatedTableId.toString():o+"/"+t.relatedTableId.toString();const u=await te(o,s,r,n,a,l);return new Q({layer:e,relatedLayer:u,relationship:t,objectId:i,spatialReference:s,outFields:r,includeGeometry:n,lrucache:a,interceptor:l})}a.A.registerAction(),R.registerAction(),c.A.registerAction(),k.A.registerAction(),E.A.registerAction();class ae extends r{constructor(e,t=null,i=null,s=null){super(),this._map=e,this._overrideSpatialReference=t,this._lrucache=i,this._interceptor=s,this._instantLayers=[]}_makeAndAddFeatureSet(e,t=!0,i=null){const s=ie(e,this._overrideSpatialReference,null===i?["*"]:i,t,this._lrucache,this._interceptor);return this._instantLayers.push({featureset:s,opitem:e,includeGeometry:t,outFields:JSON.stringify(i)}),s}async featureSetByName(e,t=!0,i=null){if(Y.A.isLoadable(this._map)&&!this._map.loaded)return await this._map.load(),this.featureSetByName(e,t,i);null===i&&(i=["*"]),i=(i=i.slice()).sort();const s=JSON.stringify(i);for(let i=0;i<this._instantLayers.length;i++){const r=this._instantLayers[i];if(r.opitem.title===e&&r.includeGeometry===t&&r.outFields===s)return this._instantLayers[i].featureset}const r=this._map.allLayers.find((t=>(0,y.eB)(t)&&t.title===e));if(null!=r)return this._makeAndAddFeatureSet(r,t,i);if(this._map.allTables){const s=this._map.allTables.find((t=>(0,y.eB)(t)&&t.title===e));if(null!=s)return this._makeAndAddFeatureSet(s,t,i)}return null}async featureSetById(e,t=!0,i=["*"]){if(Y.A.isLoadable(this._map)&&!this._map.loaded)return await this._map.load(),this.featureSetById(e,t,i);null===i&&(i=["*"]),i=(i=i.slice()).sort();const s=JSON.stringify(i);for(let i=0;i<this._instantLayers.length;i++){const r=this._instantLayers[i];if(r.opitem.id===e&&r.includeGeometry===t&&r.outFields===s)return this._instantLayers[i].featureset}const r=this._map.allLayers.find((t=>(0,y.eB)(t)&&t.id===e));if(r)return this._makeAndAddFeatureSet(r,t,i);if(this._map.allTables){const s=this._map.allTables.find((t=>(0,y.eB)(t)&&t.id===e));if(null!=s)return this._makeAndAddFeatureSet(s,t,i)}return null}}class le extends r{constructor(e,t=null,i=null,s=null){super(),this._url=e,this._overrideSpatialReference=t,this._lrucache=i,this._interceptor=s,this.metadata=null,this._instantLayers=[]}get url(){return this._url}_makeAndAddFeatureSet(e,t=!0,i=null){const s=ie(e,this._overrideSpatialReference,null===i?["*"]:i,t,this._lrucache);return this._instantLayers.push({featureset:s,opitem:e,includeGeometry:t,outFields:JSON.stringify(i)}),s}async _loadMetaData(){const e=await se(this._url,this._lrucache);return this.metadata=e,e}load(){return this._loadMetaData()}clone(){return new le(this._url,this._overrideSpatialReference,this._lrucache,this._interceptor)}async featureSetByName(e,t=!0,i=null){null===i&&(i=["*"]),i=(i=i.slice()).sort();const s=JSON.stringify(i);for(let i=0;i<this._instantLayers.length;i++){const r=this._instantLayers[i];if(r.opitem.title===e&&r.includeGeometry===t&&r.outFields===s)return this._instantLayers[i].featureset}const r=await this._loadMetaData();let n=null;for(const t of r.layers??[])t.name===e&&(n=t);if(!n)for(const t of r.tables??[])t.name===e&&(n=t);if(n){const e=await ee(this._url+"/"+n.id,["*"],this._lrucache);return this._makeAndAddFeatureSet(e,t,i)}return null}async featureSetById(e,t=!0,i=["*"]){null===i&&(i=["*"]),i=(i=i.slice()).sort();const s=JSON.stringify(i);e=null!=e?e.toString():"";for(let i=0;i<this._instantLayers.length;i++){const r=this._instantLayers[i];if(r.opitem.id===e&&r.includeGeometry===t&&r.outFields===s)return this._instantLayers[i].featureset}const r=await this._loadMetaData();let n=null;for(const t of r.layers??[])null!==t.id&&void 0!==t.id&&t.id.toString()===e&&(n=t);if(!n)for(const t of r.tables??[])null!==t.id&&void 0!==t.id&&t.id.toString()===e&&(n=t);if(n){const e=await ee(this._url+"/"+n.id,["*"],this._lrucache);return this._makeAndAddFeatureSet(e,t,i)}return null}}function oe(e,t,i=null,s=null){return new ae(e,t,i,s)}function ue(e,t,i=null,s=null){return new le(e,t,i,s)}function ce(e,t,i,s,r){if(null===e)return null;if((0,n.p)(e)){switch(t){case"datasource":return e.getDataSourceFeatureSet();case"parent":return e;case"root":return e.getRootFeatureSet()}return null}if(e instanceof K.A&&(0,y.NI)(e)){const n=e;switch(t){case"datasource":return ie(n,r,"outFields"in n?n.outFields:null,!0,i,s).getDataSourceFeatureSet();case"parent":case"root":return ie(n,r,"outFields"in n?n.outFields:null,!0,i,s)}return null}if((0,n.$)(e)){switch(t){case"datasource":return ie(e.parent,r,e.parent.outFields,!0,i,s).getDataSourceFeatureSet();case"parent":case"root":return ie(e,r,e.parent.outFields,!0,i,s)}return null}return null}async function he(e,t,i,s,r,n,a,l=null){if($.A.applicationCache){const o=$.A.applicationCache.getLayerInfo(e+":"+n.url);if(o)return de(await o,t,i,s,r,a,l)}if(null!=a){const o=a.getCachedPortalItem(n.url,e);if(null!=o)return await de(await o,t,i,s,r,a,l)}const o=new H.default({id:e,portal:n}).load();$.A.applicationCache?$.A.applicationCache.setLayerInfo(e+":"+n.url,o):null!=a&&a.setCachedPortalItem(n.url,e,o);try{return await de(await o,t,i,s,r,a,l)}catch(t){throw $.A.applicationCache&&$.A.applicationCache.clearLayerInfo(e+":"+n.url),null!=a&&a.removeCachedPortalItem(n.url,e,o),t}}async function de(e,t,i,s,r,n,a){let l;if("Feature Service"===e.type||"Map Service"===e.type)l=await ee((0,y.Qi)(e.url??"")+"/"+t,["*"],n);else{if(t)throw new Error(`layerId=${t} provided for ${e.type} item`);if(null!=n){const t=n.getCachedPortalItemLayer(e.portal.url,e.id);if(null!=t)l=await t;else{const t=K.A.fromPortalItem(e);n.setCachedPortalItemLayer(e.portal.url,e.id,t);try{l=await t}catch(i){throw n.removeCachedPortalItemLayer(e.portal.url,e.id,t),i}}}else l=await K.A.fromPortalItem(e)}return ie(l,i,s,r,n,a)}},41366:(e,t,i)=>{i.d(t,{K:()=>d,Q:()=>u});var s=i(90237),r=i(66552),n=i(53966),a=i(10107),l=(i(44208),i(87811),i(93223)),o=i(40608);const u=(0,r.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),c="percent-of-total",h="field",d=e=>{let t=class extends e{constructor(){super(...arguments),this.normalizationField=null,this.normalizationMaxValue=null,this.normalizationMinValue=null,this.normalizationTotal=null}get normalizationType(){let e=this._get("normalizationType");const t=!!this.normalizationField,i=null!=this.normalizationTotal;return t||i?(e=t&&h||i&&c||null,t&&i&&n.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):e!==h&&e!==c||(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,s._)([(0,a.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],t.prototype,"normalizationField",void 0),(0,s._)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],t.prototype,"normalizationMaxValue",void 0),(0,s._)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],t.prototype,"normalizationMinValue",void 0),(0,s._)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],t.prototype,"normalizationTotal",void 0),(0,s._)([(0,l.e)(u,{name:"parameters.normalizationType"})],t.prototype,"normalizationType",null),t=(0,s._)([(0,o.$)("esri.rest.support.NormalizationBinParametersMixin")],t),t}},41560:(e,t,i)=>{i.d(t,{Ch:()=>a,mW:()=>n});var s=i(34727),r=i(39516);function n(e,t){return{...t,filterMode:e.mode}}function a(e,t,i){const n=function(e){if("manual"===u(e))return null;const t=[Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY];for(const{minScale:i,maxScale:s}of e.filters)t[0]=Math.max(t[0],c(i)),t[1]=Math.min(t[1],h(s));return t}(e);if(n&&((0,s.gg)(t,n[0])||(0,s.ZH)(i,n[1])))return"";const a=Array.from(l(e,t,i)),o=function(e,t,i){if(0===e.length)return!0;const r=c(e.at(0)?.minScale),n=h(e.at(-1)?.maxScale);if((0,s.ZH)(r,t)||(0,s.gg)(n,i))return!0;for(let t=0;t<e.length-1;t++){const i=e[t],r=e[t+1];if((0,s.ZH)(c(r.minScale),h(i.maxScale)))return!0}return!1}(a,t,i)?"1=1":a.map((e=>e.where||"1=1")).reduce(((e,t)=>(0,r.IW)(e,t)),"");return o&&"1=1"!==o?o:""}function*l(e,t,i){if("manual"===u(e)){const t=e.filters.find((t=>t.id===e.activeFilterId));t&&(yield t)}else{"object"==typeof t&&(t=t.scale);for(const s of e.filters)o(s.minScale,s.maxScale,t,i)&&(yield s)}}function o(e,t,i,r){return e=c(e),i=c(i),t=h(t),!(!(0,s.Sp)(i,e)&&(r??i)>e||(0,s.Hx)(t,i)||void 0!==r&&(0,s.Sp)(r,e))}function u(e){return"mode"in e?e.mode:e.filterMode}function c(e){return e||Number.POSITIVE_INFINITY}function h(e){return e||0}},46140:(e,t,i)=>{i.d(t,{R:()=>r});var s=i(49186);let r=class e{constructor(e,t,i=""){this.major=e,this.minor=t,this._context=i}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}validate(e){if(this.major!==e.major){const t=this._context&&this._context+":",i=this._context&&this._context+" ";throw new s.A(t+"unsupported-version",`Required major ${i}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new e(this.major,this.minor,this._context)}static parse(t,i=""){const[r,n]=t.split("."),a=/^\s*\d+\s*$/;if(!r?.match||!a.test(r))throw new s.A((i&&i+":")+"invalid-version","Expected major version to be a number, but got '${version}'",{version:t});if(!n?.match||!a.test(n))throw new s.A((i&&i+":")+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:t});const l=parseInt(r,10),o=parseInt(n,10);return new e(l,o,i)}}},50498:(e,t,i)=>{i.d(t,{Ye:()=>h,gy:()=>c,yR:()=>d});var s=i(66552),r=i(5443),n=i(91075),a=i(48526),l=i(86738),o=i(39829),u=i(82799);const c=(0,s.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),h=(0,s.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"}),d={base:n.A,key:"type",typeMap:{extent:r.A,multipoint:a.A,point:l.A,polyline:u.A,polygon:o.A}}},52106:(e,t,i)=>{i.d(t,{A:()=>b});var s,r=i(90237),n=i(13874),a=i(69540),l=i(51447),o=i(25482),u=i(53966),c=i(36708),h=i(24326),d=i(10107),p=(i(44208),i(87811),i(40608)),f=i(12195),y=i(65864),_=i(50498),g=i(54339),m=i(33910);function w(e){if(null==e)return null;const t={};for(const i in e){const s=e[i];s&&(t[i]=s.toJSON())}return 0!==Object.keys(t).length?t:null}let b=class extends(a.A.ClonableMixin(o.A)){static{s=this}constructor(e){super(e),this.isAggregate=!1,this.layer=null,this.origin=null,this.sourceLayer=null,this._version=0,Object.defineProperty(this,"uid",{value:(0,h.c)(),configurable:!0}),Object.defineProperty(this,"_lastMeshTransform",{value:{},configurable:!0,writable:!0,enumerable:!1}),arguments.length>1&&(0,l.eF)(u.A.getLogger(this),"Graphic",{version:"4.30"})}initialize(){this._watchMeshGeometryChanges()}set aggregateGeometries(e){const t=this._get("aggregateGeometries");JSON.stringify(t)!==JSON.stringify(e)&&this._set("aggregateGeometries",e)}set attributes(e){const t=this._get("attributes");t!==e&&(this._set("attributes",e),this._notifyLayer("attributes",t,e))}set geometry(e){const t=this._get("geometry");t!==e&&(this._set("geometry",e),"mesh"!==e?.type&&this._notifyLayer("geometry",t,e))}set popupTemplate(e){const t=this._get("popupTemplate");t!==e&&(this._set("popupTemplate",e),this._notifyLayer("popupTemplate",t,e))}set symbol(e){const t=this._get("symbol");t!==e&&(this._set("symbol",e),this._notifyLayer("symbol",t,e))}get version(){return this._version}set visible(e){const t=this._get("visible");t!==e&&(this._set("visible",e),this._notifyLayer("visible",t,e))}cloneShallow(){return new s({aggregateGeometries:this.aggregateGeometries,attributes:this.attributes,geometry:this.geometry,isAggregate:this.isAggregate,layer:this.layer,popupTemplate:this.popupTemplate,sourceLayer:this.sourceLayer,symbol:this.symbol,visible:this.visible,origin:this.origin})}getEffectivePopupTemplate(e=!1){if(this.popupTemplate)return this.popupTemplate;const t=this.origin&&"layer"in this.origin?this.origin.layer:null;for(const i of[t,this.sourceLayer,this.layer])if(i){if("popupTemplate"in i&&i.popupTemplate)return i.popupTemplate;if(e&&"defaultPopupTemplate"in i&&null!=i.defaultPopupTemplate)return i.defaultPopupTemplate}return null}getAttribute(e){return this.attributes?.[e]}setAttribute(e,t){if(this.attributes){const i=this.getAttribute(e);this.attributes[e]=t,this._notifyLayer("attributes",i,t,e)}else this.attributes={[e]:t}}getObjectId(){const e=this.sourceLayer??this.layer;return e?(0,g.r)(this,e):null}getGlobalId(){const e=this.sourceLayer??this.layer;return e&&"globalIdField"in e&&e.globalIdField?this.getAttribute(e.globalIdField):null}toJSON(){return{aggregateGeometries:w(this.aggregateGeometries),geometry:null!=this.geometry?this.geometry.toJSON():null,symbol:null!=this.symbol?this.symbol.toJSON():null,attributes:(0,f.W)(this.attributes)?this.attributes.toJSON():{...this.attributes},popupTemplate:this.popupTemplate?.toJSON()??null}}notifyMeshTransformChanged(e={}){const{geometry:t}=this;if("mesh"===t?.type){const i={origin:t.origin,transform:t.transform};this._notifyLayer("origin-transform",i,i,e.action)}}_notifyLayer(e,t,i,s){if(this._version++,!this.layer||!("graphicChanged"in this.layer))return;const r={graphic:this,property:e,oldValue:t,newValue:i};"origin-transform"===e&&(r.action=s),"attributes"===e&&(r.attributeName=s),this.layer.graphicChanged(r)}_watchMeshGeometryChanges(){this.addHandles([(0,c.z7)((()=>"mesh"===this.geometry?.type&&this.geometry.vertexSpace.origin?{localMatrix:this.geometry.transform?.localMatrix,origin:this.geometry.vertexSpace.origin}:void 0),(({localMatrix:e,origin:t})=>{this._lastMeshTransform.localMatrix===e&&this._lastMeshTransform.origin===t||(this._lastMeshTransform.localMatrix=e,this._lastMeshTransform.origin=t,this.notifyMeshTransformChanged())})),(0,c.z7)((()=>"mesh"===this.geometry?.type?{vertexAttributes:this.geometry.vertexAttributes}:void 0),(()=>{const e=this.geometry;"mesh"===e?.type&&e.vertexSpace.origin?(this._lastMeshTransform.localMatrix=e.transform?.localMatrix,this._lastMeshTransform.origin=e.vertexSpace.origin):(this._lastMeshTransform.localMatrix=void 0,this._lastMeshTransform.origin=void 0),this._notifyLayer("geometry",this.geometry,this.geometry)}),{equals:(e,t)=>e===t,sync:!0})])}};(0,r._)([(0,d.MZ)({value:null,json:{read:function(e){if(!e)return null;const t={};for(const i in e){const s=(0,y.rS)(e[i]);s&&(t[i]=s)}return 0!==Object.keys(t).length?t:null}}})],b.prototype,"aggregateGeometries",null),(0,r._)([(0,d.MZ)({value:null})],b.prototype,"attributes",null),(0,r._)([(0,d.MZ)({value:null,types:_.yR,json:{read:y.rS}})],b.prototype,"geometry",null),(0,r._)([(0,d.MZ)({type:Boolean})],b.prototype,"isAggregate",void 0),(0,r._)([(0,d.MZ)({clonable:!1})],b.prototype,"layer",void 0),(0,r._)([(0,d.MZ)({clonable:"reference"})],b.prototype,"origin",void 0),(0,r._)([(0,d.MZ)({type:n.A,value:null})],b.prototype,"popupTemplate",null),(0,r._)([(0,d.MZ)({clonable:"reference"})],b.prototype,"sourceLayer",void 0),(0,r._)([(0,d.MZ)({value:null,types:m.Es})],b.prototype,"symbol",null),(0,r._)([(0,d.MZ)({clonable:!1,json:{read:!1,write:!1}})],b.prototype,"_version",void 0),(0,r._)([(0,d.MZ)({type:Boolean,value:!0})],b.prototype,"visible",null),b=s=(0,r._)([(0,p.$)("esri.Graphic")],b)},54461:(e,t,i)=>{i.d(t,{A:()=>l});var s=i(87449),r=i(11221),n=i(89169),a=i(33325);class l extends r.A{constructor(e){super(e),this._topnum=0,this.declaredClass="esri.arcade.featureset.actions.Top",this._countedin=0,this._maxProcessing=100,this._topnum=e.topnum,this._parent=e.parentfeatureset}async _getSet(e){if(null===this._wset){await this._ensureLoaded();const t=await this._parent._getSet(e);return this._wset=new n.A(t._candidates.slice(),t._known.slice(),!1,this._clonePageDefinition(t.pagesDefinition)),this._setKnownLength(this._wset)>this._topnum&&(this._wset._known=this._wset._known.slice(0,this._topnum)),this._setKnownLength(this._wset)>=this._topnum&&(this._wset._candidates=[]),this._wset}return this._wset}_setKnownLength(e){return e._known.length>0&&"GETPAGES"===e._known[e._known.length-1]?e._known.length-1:e._known.length}_isInFeatureSet(e){const t=this._parent._isInFeatureSet(e);if(t===a.J6.NotInFeatureSet)return t;const i=this._idstates[e];return i===a.J6.InFeatureSet||i===a.J6.NotInFeatureSet?i:t===a.J6.InFeatureSet&&void 0===i?this._countedin<this._topnum?(this._idstates[e]=a.J6.InFeatureSet,this._countedin++,a.J6.InFeatureSet):(this._idstates[e]=a.J6.NotInFeatureSet,a.J6.NotInFeatureSet):a.J6.Unknown}async _expandPagedSet(e,t,i,r,n){if(null===this._parent)throw new s.dr(s.D_.NotImplemented);if(t>this._topnum&&(t=this._topnum),this._countedin>=this._topnum&&e.pagesDefinition.internal.set.length<=e.pagesDefinition.resultOffset){let t=e._known.length;return t>0&&"GETPAGES"===e._known[t-1]&&(e._known.length=t-1),t=e._candidates.length,t>0&&"GETPAGES"===e._candidates[t-1]&&(e._candidates.length=t-1),"success"}const a=await this._parent._expandPagedSet(e,t,i,r,n);return this._setKnownLength(e)>this._topnum&&(e._known.length=this._topnum),this._setKnownLength(e)>=this._topnum&&(e._candidates.length=0),a}async _getFeatures(e,t,i,s){const r=[],a=this._maxQueryRate();if(!0===this._checkIfNeedToExpandKnownPage(e,a))return await this._expandPagedSet(e,a,0,0,s),this._getFeatures(e,t,i,s);-1!==t&&void 0===this._featureCache[t]&&r.push(t);let l=0;for(let s=e._lastFetchedIndex;s<e._known.length&&(l++,l<=i&&(e._lastFetchedIndex+=1),!(void 0===this._featureCache[e._known[s]]&&(e._known[s]!==t&&r.push(e._known[s]),r.length>a)));s++);if(0===r.length)return"success";const o=new n.A([],r,!1,null),u=Math.min(r.length,i);await this._parent._getFeatures(o,-1,u,s);for(let e=0;e<u;e++){const t=this._parent._featureFromCache(r[e]);void 0!==t&&(this._featureCache[r[e]]=t)}return"success"}async _getFilteredSet(e,t,i,s,r){await this._ensureLoaded();const a=await this._getSet(r);return new n.A(a._candidates.slice().concat(a._known.slice()),[],!1,this._clonePageDefinition(a.pagesDefinition))}_refineKnowns(e,t){let i=0,s=null;const r=[];for(let n=0;n<e._candidates.length;n++){const l=this._isInFeatureSet(e._candidates[n]);if(l===a.J6.InFeatureSet){if(e._known.push(e._candidates[n]),i+=1,null===s?s={start:n,end:n}:s.end===n-1?s.end=n:(r.push(s),s={start:n,end:n}),e._known.length>=this._topnum)break}else if(l===a.J6.NotInFeatureSet)null===s?s={start:n,end:n}:s.end===n-1?s.end=n:(r.push(s),s={start:n,end:n}),i+=1;else if(l===a.J6.Unknown)break;if(i>=t)break}null!==s&&r.push(s);for(let t=r.length-1;t>=0;t--)e._candidates.splice(r[t].start,r[t].end-r[t].start+1);this._setKnownLength(e)>this._topnum&&(e._known=e._known.slice(0,this._topnum)),this._setKnownLength(e)>=this._topnum&&(e._candidates=[])}async _stat(){return{calculated:!1}}async _canDoAggregates(){return!1}static registerAction(){r.A._featuresetFunctions.top=function(e){return new l({parentfeatureset:this,topnum:e})}}getFieldsIndex(){return this._parent.getFieldsIndex()}}},55674:(e,t,i)=>{i.d(t,{Ad:()=>p,Gj:()=>_,QY:()=>d,lL:()=>g,xR:()=>f});var s=i(66131),r=i(49186),n=(i(44208),i(44729)),a=i(15032),l=i(65864),o=i(95466),u=i(43668),c=i(98623);const h=["geometry","scale","timeProperties"];function d(e,t){if(null!=t)for(const i of h)t.hasArcadeDependency(i)&&e.add(i);return e}function p(e,t){return y.create(e,t,null,["$feature","$view"])}function f(e,t,i){return y.create(e,t,i,["$feature","$view","$config"])}class y{static async create(e,t,i,s){const{arcade:n,Dictionary:a}=await(0,u.l)();let l;try{l=n.parseScript(e)}catch(t){throw new r.A("arcade-bad-expression","Failed to parse arcade script",{script:e,error:t})}const o=n.scriptUsesGeometryEngine(l);o&&await n.enableGeometrySupport(),await n.loadDependentModules(new Set,l,null,!1,o);const c={vars:s.reduce(((e,t)=>({...e,[t]:null})),{}),spatialReference:t,useAsync:!1},h=n.compileScript(l,c);let d=null;null!=i&&(d=new a(i),d.immutable=!0);const p=new a;return p.immutable=!1,p.setField("scale",0),new y(e,n,l,h,t,p,d,a)}constructor(e,t,i,s,r,n,a,l){this.script=e,this._arcade=t,this._syntaxTree=i,this._compiled=s,this._spatialReference=r,this._viewDict=n,this._configDict=a,this._dictionaryCtor=l,this._dependencies=new Map,this._featureReader=new _,this._dependencies.set("geometry",t.scriptTouchesGeometry(this._syntaxTree)),this._dependencies.set("scale",this._arcade.referencesMember(this._syntaxTree,"scale")),this._dependencies.set("timeProperties",this._arcade.scriptUsesViewProperties(this._syntaxTree,["timeProperties"]))}evaluate(e,t){const i=t.$view?.timeZone;if(t.$view){let e;if(this._viewDict.setField("scale",t.$view.scale),null!=t.$view.timeProperties){const{currentStart:r,currentEnd:n}=t.$view.timeProperties;e=new this._dictionaryCtor({currentStart:null!=r?null!=i?s.lY.epochToArcadeDate(r,i):s.lY.unknownEpochToArcadeDate(r):void 0,currentEnd:null!=n?null!=i?s.lY.epochToArcadeDate(n,i):s.lY.unknownEpochToArcadeDate(n):void 0,startIncluded:!0,endIncluded:!0})}this._viewDict.setField("timeProperties",e)}return this._compiled({vars:{$view:this._viewDict,$config:this._configDict,$feature:e},spatialReference:this._spatialReference,timeZone:i})}repurposeFeature(e,t){return this._featureReader.bind(e,t,this._spatialReference),this._featureReader}references(e){return this._dependencies.get(e)??!1}}class _{constructor(){this._boundTarget=null,this._boundSchema={fields:null,fieldsIndex:null,spatialReference:null,get geometryType(){return null},get objectIdField(){return null}},this.arcadeDeclaredClass="esri.arcade.Feature",this._contextTimeZone=null}bind(e,t,i){const s=t??new o.A(g(e.attributes));this._boundTarget=e,this._boundSchema.fields=s.fields,this._boundSchema.fieldsIndex=s,this._boundSchema.spatialReference=i}_getField(e){return this._boundSchema.fieldsIndex.get(e)}get contextTimeZone(){return this._contextTimeZone}set contextTimeZone(e){this._contextTimeZone=e}readArcadeFeature(){return this}hasField(e){return this._boundSchema.fieldsIndex.has(e)}geometry(){if("fromJSON"in this._boundTarget)return this._boundTarget.geometry;const e=(0,l.rS)(this._boundTarget.geometry);if(e){if(!this._boundSchema.spatialReference)throw new Error("InternalError: Expected spatial reference to be defined");e.spatialReference=this._boundSchema.spatialReference}return e}isUnknownDateTimeField(e){return this._boundSchema.fieldsIndex.getTimeZone(e)===c.L5}field(e,t=!0){const i=this._getField(e);if(i)switch(i.type){case"date-only":case"esriFieldTypeDateOnly":return n.n.fromReader(this._boundTarget.attributes[i.name]);case"time-only":case"esriFieldTypeTimeOnly":return a.k.fromReader(this._boundTarget.attributes[i.name]);case"esriFieldTypeTimestampOffset":case"timestamp-offset":return s.lY.fromReaderAsTimeStampOffset(this._boundTarget.attributes[i.name]);case"date":case"esriFieldTypeDate":{const t=this._boundTarget.attributes[i.name];return this.isUnknownDateTimeField(e)?s.lY.unknownEpochToArcadeDate(t):s.lY.epochToArcadeDate(t,this.contextTimeZone??c.qU)}default:return this._boundTarget.attributes[i.name]}if(t)throw new Error(`Field ${e} does not exist`);return null}setField(e,t){throw new Error("Unable to update feature attribute values, feature is readonly")}keys(){return this._boundSchema.fieldsIndex.fields.map((e=>e.name))}castToText(e=!1){return JSON.stringify(this._boundTarget)}gdbVersion(){return null}fullSchema(){return this._boundSchema}castAsJson(e=null){return{attributes:this._boundTarget.attributes,geometry:!0===e?.keepGeometryType?this.geometry():this.geometry()?.toJSON()??null}}castAsJsonAsync(e=null,t=null){return Promise.resolve(this.castAsJson(t))}}function g(e){const t=[];for(const i in e)t.push({name:i,alias:i,type:"string"==typeof e[i]?"esriFieldTypeString":"esriFieldTypeDouble"});return t}},58501:(e,t,i)=>{i.d(t,{q:()=>r});var s=i(62815);function r(e,t,i){if(!i?.features||!i.hasZ)return;const r=(0,s.N)(i.geometryType,t,e.outSpatialReference);if(null!=r)for(const e of i.features)r(e.geometry)}},59247:(e,t,i)=>{i.d(t,{bv:()=>o,Fk:()=>u,yG:()=>c,$b:()=>h,Nd:()=>d,jm:()=>p,sK:()=>_});var s=i(40876),r=i(90629);function n(){const e=new Float32Array(16);return e[0]=1,e[5]=1,e[10]=1,e[15]=1,e}const a=n();Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:a,clone:function(e){const t=new Float32Array(16);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t},create:n,fromValues:function(e,t,i,s,r,n,a,l,o,u,c,h,d,p,f,y){const _=new Float32Array(16);return _[0]=e,_[1]=t,_[2]=i,_[3]=s,_[4]=r,_[5]=n,_[6]=a,_[7]=l,_[8]=o,_[9]=u,_[10]=c,_[11]=h,_[12]=d,_[13]=p,_[14]=f,_[15]=y,_}},Symbol.toStringTag,{value:"Module"}));var l=i(58083);class o{constructor(e,t,i){this.strength=e,this.radius=t,this.threshold=i,this.type="bloom"}interpolate(e,t,i){this.strength=f(e.strength,t.strength,i),this.radius=f(e.radius,t.radius,i),this.threshold=f(e.threshold,t.threshold,i)}clone(){return new o(this.strength,this.radius,this.threshold)}toJSON(){return{type:"bloom",radius:y(this.radius),strength:this.strength,threshold:this.threshold}}}class u{constructor(e){this.radius=e,this.type="blur"}interpolate(e,t,i){this.radius=Math.round(f(e.radius,t.radius,i))}clone(){return new u(this.radius)}toJSON(){return{type:"blur",radius:y(this.radius)}}}class c{constructor(e,t){this.type=e,this.amount=t,"invert"!==this.type&&"grayscale"!==this.type&&"sepia"!==this.type||(this.amount=Math.min(this.amount,1))}get colorMatrix(){return this._colorMatrix||this._updateMatrix(),this._colorMatrix}interpolate(e,t,i){this.amount=f(e.amount,t.amount,i),this._updateMatrix()}clone(){return new c(this.type,this.amount)}toJSON(){return{type:this.type,amount:this.amount}}_updateMatrix(){const e=this._colorMatrix||n();switch(this.type){case"brightness":this._colorMatrix=((e,t)=>{const i=(0,l.hZ)(e,t,0,0,0,0,t,0,0,0,0,t,0,0,0,0,1);return(0,l.mg)(i,i)})(e,this.amount);break;case"contrast":this._colorMatrix=((e,t)=>{const i=(0,l.hZ)(e,t,0,0,.5-.5*t,0,t,0,.5-.5*t,0,0,t,.5-.5*t,0,0,0,1);return(0,l.mg)(i,i)})(e,this.amount);break;case"grayscale":this._colorMatrix=(e=>{const t=1-this.amount,i=(0,l.hZ)(e,.2126+.7874*t,.7152-.7152*t,.0722-.0722*t,0,.2126-.2126*t,.7152+.2848*t,.0722-.0722*t,0,.2126-.2126*t,.7152-.7152*t,.0722+.9278*t,0,0,0,0,1);return(0,l.mg)(i,i)})(e);break;case"invert":this._colorMatrix=((e,t)=>{const i=1-2*t,s=(0,l.hZ)(e,i,0,0,t,0,i,0,t,0,0,i,t,0,0,0,1);return(0,l.mg)(s,s)})(e,this.amount);break;case"saturate":this._colorMatrix=((e,t)=>{const i=(0,l.hZ)(e,.213+.787*t,.715-.715*t,.072-.072*t,0,.213-.213*t,.715+.285*t,.072-.072*t,0,.213-.213*t,.715-.715*t,.072+.928*t,0,0,0,0,1);return(0,l.mg)(i,i)})(e,this.amount);break;case"sepia":this._colorMatrix=(e=>{const t=1-this.amount,i=(0,l.hZ)(e,.393+.607*t,.769-.769*t,.189-.189*t,0,.349-.349*t,.686+.314*t,.168-.168*t,0,.272-.272*t,.534-.534*t,.131+.869*t,0,0,0,0,1);return(0,l.mg)(i,i)})(e)}}}class h{constructor(e,t,i,s){this.offsetX=e,this.offsetY=t,this.blurRadius=i,this.color=s,this.type="drop-shadow"}interpolate(e,t,i){this.offsetX=f(e.offsetX,t.offsetX,i),this.offsetY=f(e.offsetY,t.offsetY,i),this.blurRadius=f(e.blurRadius,t.blurRadius,i),this.color[0]=Math.round(f(e.color[0],t.color[0],i)),this.color[1]=Math.round(f(e.color[1],t.color[1],i)),this.color[2]=Math.round(f(e.color[2],t.color[2],i)),this.color[3]=f(e.color[3],t.color[3],i)}clone(){return new h(this.offsetX,this.offsetY,this.blurRadius,[...this.color])}toJSON(){const e=[...this.color];return e[3]*=255,{type:"drop-shadow",xoffset:y(this.offsetX),yoffset:y(this.offsetY),blurRadius:y(this.blurRadius),color:e}}}class d{constructor(e){this.angle=e,this.type="hue-rotate"}get colorMatrix(){return this._colorMatrix||this._updateMatrix(),this._colorMatrix}interpolate(e,t,i){this.angle=f(e.angle,t.angle,i),this._updateMatrix()}clone(){return new d(this.angle)}toJSON(){return{type:"hue-rotate",angle:this.angle}}_updateMatrix(){const e=this._colorMatrix||n();this._colorMatrix=((e,t)=>{const i=Math.sin(t*Math.PI/180),s=Math.cos(t*Math.PI/180),r=(0,l.hZ)(e,.213+.787*s-.213*i,.715-.715*s-.715*i,.072-.072*s+.928*i,0,.213-.213*s+.143*i,.715+.285*s+.14*i,.072-.072*s-.283*i,0,.213-.213*s-.787*i,.715-.715*s+.715*i,.072+.928*s+.072*i,0,0,0,0,1);return(0,l.mg)(r,r)})(e,this.angle)}}class p{constructor(e){this.amount=e,this.type="opacity",this.amount=Math.min(this.amount,1)}interpolate(e,t,i){this.amount=f(e.amount,t.amount,i)}clone(){return new p(this.amount)}toJSON(){return{type:"opacity",amount:this.amount}}}function f(e,t,i){return e+(t-e)*i}function y(e){return Math.round(1e3*(0,r.PN)(e))/1e3}function _(e){switch(e.type){case"grayscale":case"sepia":case"invert":return new c(e.type,0);case"saturate":case"brightness":case"contrast":return new c(e.type,1);case"opacity":return new p(1);case"hue-rotate":return new d(0);case"blur":return new u(0);case"drop-shadow":return new h(0,0,0,[...(0,s.TS)("transparent")]);case"bloom":return new o(0,0,1)}}},60999:(e,t,i)=>{i.d(t,{DZ:()=>f,Ke:()=>p,Tj:()=>c,UT:()=>y,jJ:()=>u});var s=i(90237),r=i(69622),n=i(97768),a=i(74887),l=i(10107),o=i(40608);function u(e,t,i){return(0,a.Lx)(e.map(((e,s)=>t.apply(i,[e,s]))))}async function c(e,t,i){return(await(0,a.Lx)(e.map(((e,s)=>t.apply(i,[e,s]))))).map((e=>e.value))}function h(e){return{ok:!0,value:e}}function d(e){return{ok:!1,error:e}}async function p(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return h(await e)}catch(e){return d(e)}}async function f(e){try{return h(await e)}catch(e){return(0,a.QP)(e),d(e)}}function y(e,t){return new _(e,t)}let _=class extends r.A{get value(){return null!=(e=this._result)&&!0===e.ok?e.value:null;var e}get error(){return null!=(e=this._result)&&!1===e.ok?e.error:null;var e}get finished(){return null!=this._result}constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,n.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:i}=this._abortController;this.promise=e(i),this.promise.then((e=>{this._result=h(e),this._cleanup()}),(e=>{this._result=d(e),this._cleanup()})),this._abortHandle=(0,a.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,n.xt)(this._abortHandle),this._abortController=null}};(0,s._)([(0,l.MZ)()],_.prototype,"value",null),(0,s._)([(0,l.MZ)()],_.prototype,"error",null),(0,s._)([(0,l.MZ)()],_.prototype,"finished",null),(0,s._)([(0,l.MZ)()],_.prototype,"promise",void 0),(0,s._)([(0,l.MZ)()],_.prototype,"_result",void 0),_=(0,s._)([(0,o.$)("esri.core.asyncUtils.ReactiveTask")],_)},61760:(e,t,i)=>{i.d(t,{PU:()=>a,YW:()=>o,ex:()=>r,hv:()=>l,zp:()=>n}),i(34727);var s=i(90629);i(87317),i(91829);const r=2.4;function n(e){return(0,s.PN)(e*r)}function a(e){return(0,s.Lz)(e)/r}function l(e,t,i){const s=Math.sqrt(e**2+t**2)/i;return s>1?0:3/(Math.PI*i**2)*(1-s**2)**2}function o(e){return"function"==typeof e?e:e?t=>+t[e]:()=>1}},65529:(e,t,i)=>{i.d(t,{A:()=>o});var s=i(90237),r=i(69622),n=i(36563),a=i(40608);class l{constructor(){this._emitter=new l.EventEmitter(this)}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}}!function(e){class t{constructor(e=null){this._target=e,this._listenersMap=null}clear(){this._listenersMap?.clear(),this._listenersMap=null}destroy(){this.clear()}emit(e,t){let i=this._listenersMap?.get(e);if(!i)return!1;const s=this._target||this;let r=!1;for(const e of i.slice()){const i="deref"in e?e.deref():e;i?i?.call(s,t):r=!0}return r&&(i=i.filter((e=>!("deref"in e)||null!=e.deref())),this._listenersMap.set(e,i)),i.length>0}on(e,t){if(Array.isArray(e)){const i=e.map((e=>this.on(e,t)));return(0,n.vE)(i)}if(e.includes(","))throw new TypeError("Evented.on() with a comma delimited string of event types is not supported");this._listenersMap??=new Map;const i=this._listenersMap.get(e)||[];return i.push(t),this._listenersMap.set(e,i),(0,n.hA)((()=>{const i=this._listenersMap?.get(e),s=i?.indexOf(t)??-1;s>=0&&i.splice(s,1)}))}once(e,t){const i=this.on(e,(e=>{i.remove();const s="deref"in t?t.deref():t;s?.call(null,e)}));return i}hasEventListener(e){const t=this._listenersMap?.get(e);return null!=t&&t.length>0}}e.EventEmitter=t,e.EventedMixin=e=>{let i=class extends e{constructor(){super(...arguments),this._emitter=new t}destroy(){this._emitter.clear()}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}};return i=(0,s._)([(0,a.$)("esri.core.Evented")],i),i};let i=class extends r.A{constructor(){super(...arguments),this._emitter=new l.EventEmitter(this)}destroy(){this._emitter.clear()}emit(e,t){return this._emitter.emit(e,t)}on(e,t){return this._emitter.on(e,t)}once(e,t){return this._emitter.once(e,t)}hasEventListener(e){return this._emitter.hasEventListener(e)}};i=(0,s._)([(0,a.$)("esri.core.Evented.EventedAccessor")],i),e.EventedAccessor=i}(l||(l={}));const o=l},68423:(e,t,i)=>{i.d(t,{Gr:()=>m,IO:()=>y,a:()=>w,bV:()=>g,p8:()=>_});var s=i(52106),r=i(78502),n=i(87449),a=i(11221),l=i(89169),o=i(33325),u=i(80609),c=i(97768),h=i(1262),d=i(88368),p=i(16930);class f{constructor(e){this.field=e,this.sqlRewritable=!1}postInitialization(e,t){}}class y extends f{constructor(e){super(e),this.sqlRewritable=!0}extractValue(e){return e.attributes[this.field.name]}rewriteSql(e){return{rewritten:this.sqlRewritable,where:e}}}class _ extends f{constructor(e,t,i){super((0,o.ke)(e)),this.originalField=e,this.sqlRewritable=!0,this.field.name=t,this.field.alias=i}rewriteSql(e,t){return{rewritten:this.sqlRewritable,where:(0,u.bD)(e,this.field.name,this.originalField.name,t.getFieldsIndex())}}extractValue(e){return e.attributes[this.originalField.name]}}class g extends f{constructor(e,t,i){super(e),this.codefield=t,this.lkp=i,this.reverseLkp={};for(const e in i)this.reverseLkp[i[e]]=e;this.sqlRewritable=!0}static{this.BADNESS="_!!!_BAD_LKP_!!!!"}rewriteSql(e,t){const i=this.evaluateNodeToWhereClause(e.parseTree,o.zl.Standardised,this.field.name,this.codefield instanceof d.A?(0,u.YY)(this.codefield,o.zl.Standardised):this.codefield,e.parameters);return i.includes(g.BADNESS)?{rewritten:!1,where:e}:{rewritten:this.sqlRewritable,where:d.A.create(i,{fieldsIndex:t._parent.getFieldsIndex(),timeZone:t.dateFieldsTimeZoneDefaultUTC})}}evaluateNodeToWhereClause(e,t,i=null,s=null,r){let n,a,l,c;switch(e.type){case"interval":return(0,u.oj)(this.evaluateNodeToWhereClause(e.value,t,i,s,r),e.qualifier,e.op);case"case-expression":{let s=" CASE ";"simple"===e.format&&(s+=this.evaluateNodeToWhereClause(e.operand,t,i,g.BADNESS,r));for(let n=0;n<e.clauses.length;n++)s+=" WHEN "+this.evaluateNodeToWhereClause(e.clauses[n].operand,t,i,g.BADNESS,r)+" THEN "+this.evaluateNodeToWhereClause(e.clauses[n].value,t,i,g.BADNESS,r);return null!==e.else&&(s+=" ELSE "+this.evaluateNodeToWhereClause(e.else,t,i,g.BADNESS,r)),s+=" END ",s}case"parameter":{const i=r[e.value.toLowerCase()];if("string"==typeof i)return"'"+i.toString().replaceAll("'","''")+"'";if((0,o.$P)(i))return(0,u.bm)(i,t);if((0,o.Lk)(i))return(0,u.bm)(i,t);if((0,o.eg)(i))return(0,u.F1)(i,t);if((0,o.rX)(i))return(0,u.R8)(i,t);if((0,o.f0)(i))return(0,u.Nf)(i,t);if(Array.isArray(i)){const e=[];for(let s=0;s<i.length;s++)"string"==typeof i[s]?e.push("'"+i[s].toString().replaceAll("'","''")+"'"):(0,o.$P)(i[s])||(0,o.Lk)(i[s])?e.push((0,u.bm)(i[s],t)):(0,o.eg)(i[s])?e.push((0,u.F1)(i[s],t)):(0,o.rX)(i[s])?e.push((0,u.R8)(i[s],t)):(0,o.f0)(i[s])?e.push((0,u.Nf)(i[s],t)):e.push(i[s].toString());return e}return i.toString()}case"expression-list":a=[];for(const n of e.value)a.push(this.evaluateNodeToWhereClause(n,t,i,s,r));return a;case"unary-expression":return" ( NOT "+this.evaluateNodeToWhereClause(e.expr,t,i,g.BADNESS,r)+" ) ";case"binary-expression":switch(e.operator){case"AND":return" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" AND "+this.evaluateNodeToWhereClause(e.right,t,i,s,r)+") ";case"OR":return" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" OR "+this.evaluateNodeToWhereClause(e.right,t,i,s,r)+") ";case"IS":if("null"!==e.right.type)throw new h.L8(h.Z7.UnsupportedIsRhs);return" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" IS NULL )";case"ISNOT":if("null"!==e.right.type)throw new h.L8(h.Z7.UnsupportedIsRhs);return" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" IS NOT NULL )";case"IN":if(n=[],"expression-list"===e.right.type){if("column-reference"===e.left.type&&e.left.column.toUpperCase()===this.field.name.toUpperCase()){const n=[];let a=!0;for(const t of e.right.value){if("string"!==t.type){a=!1;break}if(void 0===this.lkp[t.value]){a=!1;break}n.push(this.lkp[t.value].toString())}if(a)return" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" IN ("+n.join(",")+")) "}return n=this.evaluateNodeToWhereClause(e.right,t,i,s,r)," ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" IN ("+n.join(",")+")) "}return c=this.evaluateNodeToWhereClause(e.right,t,i,s,r),Array.isArray(c)?" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" IN ("+c.join(",")+")) ":" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" IN ("+c+")) ";case"NOT IN":if(n=[],"expression-list"===e.right.type){if("column-reference"===e.left.type&&e.left.column.toUpperCase()===this.field.name.toUpperCase()){const n=[];let a=!0;for(const t of e.right.value){if("string"!==t.type){a=!1;break}if(void 0===this.lkp[t.value]){a=!1;break}n.push(this.lkp[t.value].toString())}if(a)return" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" NOT IN ("+n.join(",")+")) "}return n=this.evaluateNodeToWhereClause(e.right,t,i,s,r)," ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" NOT IN ("+n.join(",")+")) "}return c=this.evaluateNodeToWhereClause(e.right,t,i,s,r),Array.isArray(c)?" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" NOT IN ("+c.join(",")+")) ":" ("+this.evaluateNodeToWhereClause(e.left,t,i,s,r)+" NOT IN ("+c+")) ";case"BETWEEN":return l=this.evaluateNodeToWhereClause(e.right,t,i,g.BADNESS,r)," ("+this.evaluateNodeToWhereClause(e.left,t,i,g.BADNESS,r)+" BETWEEN "+l[0]+" AND "+l[1]+" ) ";case"NOTBETWEEN":return l=this.evaluateNodeToWhereClause(e.right,t,i,g.BADNESS,r)," ("+this.evaluateNodeToWhereClause(e.left,t,i,g.BADNESS,r)+" NOT BETWEEN "+l[0]+" AND "+l[1]+" ) ";case"LIKE":return""!==e.escape?" ("+this.evaluateNodeToWhereClause(e.left,t,i,g.BADNESS,r)+" LIKE "+this.evaluateNodeToWhereClause(e.right,t,i,g.BADNESS,r)+" ESCAPE '"+e.escape+"') ":" ("+this.evaluateNodeToWhereClause(e.left,t,i,g.BADNESS,r)+" LIKE "+this.evaluateNodeToWhereClause(e.right,t,i,g.BADNESS,r)+") ";case"NOT LIKE":return""!==e.escape?" ("+this.evaluateNodeToWhereClause(e.left,t,i,g.BADNESS,r)+" NOT LIKE "+this.evaluateNodeToWhereClause(e.right,t,i,g.BADNESS,r)+" ESCAPE '"+e.escape+"') ":" ("+this.evaluateNodeToWhereClause(e.left,t,i,g.BADNESS,r)+" NOT LIKE "+this.evaluateNodeToWhereClause(e.right,t,i,g.BADNESS,r)+") ";case"<>":case"=":if("column-reference"===e.left.type&&"string"===e.right.type){if(e.left.column.toUpperCase()===this.field.name.toUpperCase()&&void 0!==this.lkp[e.right.value.toString()])return" ("+s+" "+e.operator+" "+this.lkp[e.right.value.toString()].toString()+") "}else if("column-reference"===e.right.type&&"string"===e.left.type&&e.right.column.toUpperCase()===this.field.name.toUpperCase())return" ("+this.lkp[e.right.value.toString()].toString()+" "+e.operator+" "+s+") ";return" ("+this.evaluateNodeToWhereClause(e.left,t,i,g.BADNESS,r)+" "+e.operator+" "+this.evaluateNodeToWhereClause(e.right,t,i,g.BADNESS,r)+") ";case"<":case">":case">=":case"<=":case"*":case"-":case"+":case"/":case"||":return" ("+this.evaluateNodeToWhereClause(e.left,t,i,g.BADNESS,r)+" "+e.operator+" "+this.evaluateNodeToWhereClause(e.right,t,i,g.BADNESS,r)+") "}case"null":return"null";case"boolean":return!0===e.value?"1":"0";case"string":return"'"+e.value.toString().replaceAll("'","''")+"'";case"timestamp":return`timestamp '${e.value}'`;case"date":return`date '${e.value}'`;case"time":return`time '${e.value}'`;case"number":return e.value.toString();case"current-time":return(0,u.C6)(e.mode,t);case"current-user":return"CURRENT_USER";case"column-reference":return i&&i.toLowerCase()===e.column.toLowerCase()?"("+s+")":(0,u.Kb)(e.column);case"data-type":return e.value;case"function":{const s=this.evaluateNodeToWhereClause(e.args,t,i,g.BADNESS,r);return(0,u.F6)(e.name,s,t)}}throw new h.L8(h.Z7.UnsupportedSyntax,{node:e.type})}extractValue(e){return this.codefield instanceof d.A?this.reverseLkp[d.A.convertValueToStorageFormat(this.codefield.calculateValueCompiled(e))]:this.reverseLkp[e.attributes[this.codefield]]}}class m extends f{constructor(e,t){super(e),this._sql=t}rewriteSql(e,t){return{rewritten:!0,where:(0,u.bD)(e,this.field.name,(0,u.YY)(this._sql,o.zl.Standardised),t.getFieldsIndex())}}extractValue(e){return d.A.convertValueToStorageFormat(this._sql.calculateValueCompiled(e),this.field.type)}}class w extends a.A{static findField(e,t){for(const i of e)if(i.name.toLowerCase()===t.toString().toLowerCase())return i;return null}constructor(e){super(e),this._calcFunc=null,this.declaredClass="esri.arcade.featureset.actions.Adapted",this.adaptedFields=[],this._extraFilter=null,this._extraFilter=e.extraFilter,this._parent=e.parentfeatureset,this._maxProcessing=30,this.adaptedFields=e.adaptedFields}_initialiseFeatureSet(){null!==this._parent?(this.geometryType=this._parent.geometryType,this.objectIdField=this._parent.objectIdField,this.globalIdField=this._parent.globalIdField,this.spatialReference=this._parent.spatialReference,this.hasM=this._parent.hasM,this.hasZ=this._parent.hasZ,this.typeIdField=this._parent.typeIdField,this.types=this._parent.types):(this.spatialReference=new p.A({wkid:4326}),this.objectIdField="",this.globalIdField="",this.geometryType=o.ik.point,this.typeIdField="",this.types=null,this.subtypeField=null,this.subtypes=null),this.fields=[];for(const e of this.adaptedFields)e.postInitialization(this,this._parent),this.fields.push(e.field)}async _getSet(e){if(null===this._wset){await this._ensureLoaded();let t=null;return t=this._extraFilter?await this._getFilteredSet("",null,null,null,e):await(this._parent?._getSet(e)),this._checkCancelled(e),(0,c.Lw)(t),this._wset=new l.A(t._candidates.slice(),t._known.slice(),t._ordered,this._clonePageDefinition(t.pagesDefinition)),this._wset}return this._wset}_isInFeatureSet(e){return this._parent._isInFeatureSet(e)}async _getFeatures(e,t,i,n){const a=[];-1!==t&&void 0===this._featureCache[t]&&a.push(t);const o=this._maxQueryRate();if(!0===this._checkIfNeedToExpandKnownPage(e,o))return await this._expandPagedSet(e,o,0,0,n),this._getFeatures(e,t,i,n);let u=0;for(let s=e._lastFetchedIndex;s<e._known.length&&(u++,u<=i&&(e._lastFetchedIndex+=1),!(void 0===this._featureCache[e._known[s]]&&(e._known[s]!==t&&a.push(e._known[s]),a.length>=o)));s++);if(0===a.length)return"success";e=new l.A([],a,e._ordered,null);const c=Math.min(a.length,i);await(this._parent?._getFeatures(e,-1,c,n)),this._checkCancelled(n);const h=[];for(let e=0;e<c;e++){const t=this._parent?._featureFromCache(a[e]);void 0!==t&&h.push({geometry:t.geometry,attributes:t.attributes,id:a[e]})}for(const e of h){const t=[];for(const i of this.adaptedFields)t[i.field.name]=i.extractValue(e);this._featureCache[e.id]=new s.A({attributes:t,geometry:(0,r.Yq)(e.geometry)})}return"success"}async _fetchAndRefineFeatures(){throw new n.dr(n.D_.NeverReach)}async _getFilteredSet(e,t,i,s,r){let n=!1;const a=this._reformulateWithoutAdaptions(i);n=a.cannot,i=a.where;let o=!1;if(null!==s){o=!0;const e=[];for(const t of this.adaptedFields)if(!(t instanceof y)&&!0===s.scanForField(t.field.name)){if(!(t instanceof _)){s=null,o=!1;break}e.push({field:t.field.name,newfield:t.originalField.name})}s&&e.length>0&&(s=s.replaceFields(e))}null!==i?null!==this._extraFilter&&(i=(0,u.kg)(this._extraFilter,i)):i=this._extraFilter,await this._ensureLoaded();const c=await this._parent._getFilteredSet(e,t,i,s,r);let h;return this._checkCancelled(r),h=!0===n?new l.A(c._candidates.slice().concat(c._known.slice()),[],!0===o&&c._ordered,this._clonePageDefinition(c.pagesDefinition)):new l.A(c._candidates.slice(),c._known.slice(),!0===o&&c._ordered,this._clonePageDefinition(c.pagesDefinition)),h}_reformulateWithoutAdaptions(e){const t={cannot:!1,where:e};if(null!==e)for(const i of this.adaptedFields)if(!0===(0,u.Ju)(e,i.field.name)){const s=i.rewriteSql(e,this);if(!0!==s.rewritten){t.cannot=!0,t.where=null;break}t.where=s.where}return t}async _stat(e,t,i,s,r,n,a){let l=!1,o=this._reformulateWithoutAdaptions(t);if(l=o.cannot,t=o.where,o=this._reformulateWithoutAdaptions(r),l=l||o.cannot,null!==(r=o.where)?null!==this._extraFilter&&(r=(0,u.kg)(this._extraFilter,r)):r=this._extraFilter,!0===l)return null===r&&""===i&&null===s?this._manualStat(e,t,n,a):{calculated:!1};const c=await this._parent._stat(e,t,i,s,r,n,a);return!1===c.calculated?null===r&&""===i&&null===s?this._manualStat(e,t,n,a):{calculated:!1}:c}async _canDoAggregates(e,t,i,s,r){if(null===this._parent)return!1;for(let t=0;t<e.length;t++)for(const i of this.adaptedFields)if(e[t].toLowerCase()===i.field.name.toLowerCase()&&!(i instanceof y))return!1;const n=[];for(let e=0;e<t.length;e++){const i=t[e];if(null!==i.workingexpr){const e=this._reformulateWithoutAdaptions(i.workingexpr);if(e.cannot)return!1;const t=i.clone();t.workingexpr=e.where,n.push(t)}else n.push(i)}const a=this._reformulateWithoutAdaptions(r);return!a.cannot&&(null!==(r=a.where)?null!==this._extraFilter&&(r=(0,u.kg)(this._extraFilter,r)):r=this._extraFilter,this._parent._canDoAggregates(e,n,i,s,r))}async _getAggregatePagesDataSourceDefinition(e,t,i,s,r,a,l){if(null===this._parent)throw new n.dr(n.D_.NeverReach);const o=[];for(let e=0;e<t.length;e++){const i=t[e];if(null!==i.workingexpr){const e=this._reformulateWithoutAdaptions(i.workingexpr);if(e.cannot)throw new n.dr(n.D_.NeverReach);const t=i.clone();t.workingexpr=e.where,o.push(t)}else o.push(i)}const c=this._reformulateWithoutAdaptions(r);if(c.cannot)throw new n.dr(n.D_.NeverReach);return null!==(r=c.where)?null!==this._extraFilter&&(r=(0,u.kg)(this._extraFilter,r)):r=this._extraFilter,this._parent._getAggregatePagesDataSourceDefinition(e,o,i,s,r,a,l)}}},73681:(e,t,i)=>{i.d(t,{n:()=>o});var s=i(49186),r=i(53966),n=i(46140),a=i(95466),l=i(55674);class o{static async from(e,t,i){const a=e.dictionary_version?n.R.parse(e.dictionary_version):null,c=new Set(e.itemsNames),h={};if(t)for(const e in t)h[e]=t[e];if(e.authoringInfo.configuration)for(const t of e.authoringInfo.configuration)h.hasOwnProperty(t.name)||(h[t.name]=t.value);const d=new Set(e.authoringInfo.symbol);for(const e of Object.keys(i))d.delete(e);d.size&&r.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:d});const p=await(0,l.xR)(e.expression,null,h);if(!p)throw new s.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");const f=!a||!a.greaterEqual(4,0);f&&r.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:a});const y=new u(i,f);return new o(f,c,p,y)}constructor(e,t,i,s){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=i,this._reader=s}get itemNames(){return this._itemNames}evaluate(e,t,i,s){try{return this._reader.bind(e,i,s),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){r.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new a.A(e);const t=e.map((e=>({...e,type:"esriFieldTypeString"})));return new a.A(t)}}class u extends l.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){const t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);const t=this._getField(e);return null==t?"":""+this._boundTarget.attributes[t.name]}}},77548:(e,t,i)=>{i.d(t,{tk:()=>h,BR:()=>c,wI:()=>u,Ov:()=>l,W_:()=>o,TU:()=>a,XX:()=>n});var s=i(70333),r=i(78888);i(5503),i(36563),i(36708),new WeakMap;const n={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};function a(e){const t=e?.type;return"building-scene"===t||"integrated-mesh"===t||"point-cloud"===t||"scene"===t}function l(e){return"feature"===e?.type&&!e.url&&"memory"===e.source?.type}function o(e){const t=e?.type;return("feature"===t||"subtype-group"===t||"oriented-imagery"===t)&&"feature-layer"===e?.source?.type}async function u(e,t){const i=s.id?.findServerInfo(e);if(null!=i?.currentVersion)return i.owningSystemUrl||null;const n=e.toLowerCase().indexOf("/rest/services");if(-1===n)return null;const a=`${e.slice(0,n)}/rest/info`,l=null!=t?t.signal:null,{data:o}=await(0,r.A)(a,{query:{f:"json"},responseType:"json",signal:l});return o?.owningSystemUrl||null}function c(e){return function(e){if(!("capabilities"in e))return!1;switch(e.type){case"catalog":case"catalog-footprint":case"csv":case"feature":case"geojson":case"imagery":case"knowledge-graph-sublayer":case"ogc-feature":case"oriented-imagery":case"scene":case"sublayer":case"subtype-group":case"subtype-sublayer":case"wfs":return!0;default:return!1}}(e)?"effectiveCapabilities"in e?e.effectiveCapabilities:e.capabilities:null}function h(e){return!!function(e){if(!("editingEnabled"in e))return!1;switch(e.type){case"csv":case"feature":case"geojson":case"oriented-imagery":case"scene":case"subtype-group":case"subtype-sublayer":return!0;default:return!1}}(e)&&("effectiveEditingEnabled"in e?e.effectiveEditingEnabled:e.editingEnabled)}},86691:(e,t,i)=>{i.d(t,{A:()=>o});var s=i(78878),r=i(87449),n=i(11221),a=i(89169),l=i(87594);class o extends n.A{constructor(e){super(e),this._orderbyclause=null,this.declaredClass="esri.arcade.featureset.actions.OrderBy",this._maxProcessing=100,this._orderbyclause=e.orderbyclause,this._parent=e.parentfeatureset}async _getSet(e){if(null===this._wset){await this._ensureLoaded();const t=await this._getFilteredSet("",null,null,this._orderbyclause,e);return this._checkCancelled(e),this._wset=t,this._wset}return this._wset}async manualOrderSet(e,t){const i=await this.getIdColumnDictionary(e,[],-1,t);this._orderbyclause?.order(i);const s=new a.A([],[],!0,null);for(let e=0;e<i.length;e++)s._known.push(i[e].id);return s}async getIdColumnDictionary(e,t,i,r){if(i<e._known.length-1){const n=this._maxQueryRate();if("GETPAGES"===e._known[i+1])return await(0,s.a0)(this._parent._expandPagedSet(e,n,0,0,r)),this.getIdColumnDictionary(e,t,i,r);let a=i+1;const l=[];for(;a<e._known.length&&"GETPAGES"!==e._known[a];)l.push(e._known[a]),a++;i+=l.length;const o=await(0,s.a0)(this._parent._getFeatureBatch(l,r));this._checkCancelled(r);for(const e of o)t.push({id:e.attributes[this.objectIdField],feature:e});return this.getIdColumnDictionary(e,t,i,r)}return e._candidates.length>0?(await(0,s.a0)(this._refineSetBlock(e,this._maxProcessingRate(),r)),this._checkCancelled(r),this.getIdColumnDictionary(e,t,i,r)):t}_isInFeatureSet(e){return this._parent._isInFeatureSet(e)}_getFeatures(e,t,i,s){return this._parent._getFeatures(e,t,i,s)}_featureFromCache(e){if(void 0===this._featureCache[e]){const t=this._parent._featureFromCache(e);if(void 0===t)return;return null===t?null:(this._featureCache[e]=t,t)}return this._featureCache[e]}async _fetchAndRefineFeatures(){throw new r.dr(r.D_.NeverReach)}async _getFilteredSet(e,t,i,s,r){await this._ensureLoaded();const n=await this._parent._getFilteredSet(e,t,i,null===s?this._orderbyclause:s,r);this._checkCancelled(r);const l=new a.A(n._candidates.slice(),n._known.slice(),n._ordered,this._clonePageDefinition(n.pagesDefinition));let o=!0;if(n._candidates.length>0&&(o=!1),!1===l._ordered){let e=await this.manualOrderSet(l,r);return!1===o&&(null===t&&null===i||(e=new a.A(e._candidates.slice().concat(e._known.slice()),[],e._ordered,this._clonePageDefinition(e.pagesDefinition)))),e}return l}static registerAction(){n.A._featuresetFunctions.orderBy=function(e){return""===e?this:new o({parentfeatureset:this,orderbyclause:new l.A(e)})}}getFieldsIndex(){return this._parent.getFieldsIndex()}}},87594:(e,t,i)=>{function s(e,t){return e===t?0:null===e?-1:null===t?1:e<t?-1:1}i.d(t,{A:()=>r});class r{constructor(e){const t=e.split(",");this._fields=[],this._directions=[];for(let e=0;e<t.length;e++){const i=t[e].match(/\S+/g);this._fields.push(i[0]),2===i.length?"asc"===i[1].toLowerCase()?this._directions.push(1):this._directions.push(0):this._directions.push(1)}}constructClause(){let e="";for(let t=0;t<this._fields.length;t++)0!==t&&(e+=","),e+=this._fields[t],1===this._directions[t]?e+=" ASC":e+=" DESC";return e}order(e){e.sort(((e,t)=>{for(let i=0;i<this._fields.length;i++){const r=this.featureValue(e.feature,this._fields[i],i),n=this.featureValue(t.feature,this._fields[i],i);let a=0;if(a=1===this._directions[i]?s(r,n):-1*s(r,n),0!==a)return a}return 0}))}scanForField(e){for(let t=0;t<this._fields.length;t++)if(this._fields[t].toLowerCase().trim()===e.toLowerCase().trim())return!0;return!1}replaceFields(e){let t="";for(let i=0;i<this._fields.length;i++){0!==i&&(t+=",");let s=this._fields[i];for(const t of e)if(s.toLowerCase()===t.field.toLowerCase()){s=t.newfield;break}t+=s,1===this._directions[i]?t+=" ASC":t+=" DESC"}return new r(t)}featureValue(e,t,i){const s=e.attributes[t];if(void 0!==s)return s;for(const s in e.attributes)if(t.toLowerCase()===s.toLowerCase())return this._fields[i]=s,e.attributes[s];return null}}},91880:(e,t,i)=>{i.d(t,{A:()=>c});var s,r=i(90237),n=i(66552),a=i(25482),l=i(10107),o=(i(44208),i(53966),i(87811),i(40608));const u=new n.J({asc:"ascending",desc:"descending"});let c=class extends a.A{static{s=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new s({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,r._)([(0,l.MZ)({type:String,json:{write:!0}})],c.prototype,"field",void 0),(0,r._)([(0,l.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],c.prototype,"valueExpression",void 0),(0,r._)([(0,l.MZ)({type:u.apiValues,json:{type:u.jsonValues,read:u.read,write:u.write}})],c.prototype,"order",void 0),c=s=(0,r._)([(0,o.$)("esri.layers.support.OrderByInfo")],c)},92935:(e,t,i)=>{var s;i.d(t,{X:()=>s}),function(e){e[e.SAVE=0]="SAVE",e[e.SAVE_AS=1]="SAVE_AS"}(s||(s={}))}}]);