@arcgis/core 5.0.0-next.4 → 5.0.0-next.5

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 (363) hide show
  1. package/Map.js +1 -1
  2. package/analysis/ElevationProfileAnalysis.js +1 -1
  3. package/analysis/VolumeMeasurement/volumeMeasurementConfiguration.js +1 -1
  4. package/applications/KnowledgeStudio/generalSdkInternalAccess.d.ts +4 -0
  5. package/applications/KnowledgeStudio/generalSdkInternalAccess.js +5 -0
  6. package/applications/KnowledgeStudio/generalSharedKgUtils.d.ts +1 -0
  7. package/applications/KnowledgeStudio/generalSharedKgUtils.js +1 -1
  8. package/applications/KnowledgeStudio/layerInternalAccessUtils.d.ts +2 -0
  9. package/applications/KnowledgeStudio/layerInternalAccessUtils.js +1 -1
  10. package/applications/KnowledgeStudio/resourceSerializationUtils.js +1 -1
  11. package/assets/components/assets/sort-handle/t9n/messages.uk.json +1 -1
  12. package/assets/esri/core/workers/RemoteClient.js +1 -1
  13. package/assets/esri/core/workers/chunks/0366b78b0ccf4ed5f6ac.js +1 -0
  14. package/assets/esri/core/workers/chunks/037b2548bf85e2d7c6ac.js +1 -0
  15. package/assets/esri/core/workers/chunks/{c0feec6e2f0e45900ae0.js → 0686243904381ef863dc.js} +1 -1
  16. package/assets/esri/core/workers/chunks/06ba43843e9c4988049b.js +1 -0
  17. package/assets/esri/core/workers/chunks/0f100e163e1847e04155.js +1 -0
  18. package/assets/esri/core/workers/chunks/{388482cea4b9fdeaf06e.js → 0f30a9514571c7be9978.js} +1 -1
  19. package/assets/esri/core/workers/chunks/0f8847f9ae3068833fa4.js +1 -0
  20. package/assets/esri/core/workers/chunks/{14ace5dc4b8984212a57.js → 17d5f8dba6ebb1184506.js} +1 -1
  21. package/assets/esri/core/workers/chunks/{b2add7338258ca7c24dd.js → 1da74aa308ded5748ef5.js} +1 -1
  22. package/assets/esri/core/workers/chunks/{651b9144abb1895cc510.js → 1e848d9da1c61a27cf18.js} +1 -1
  23. package/assets/esri/core/workers/chunks/1eedac33c9fcd7681427.js +1 -0
  24. package/assets/esri/core/workers/chunks/239377336a2009caea01.js +1 -0
  25. package/assets/esri/core/workers/chunks/285762ff92d5388b6024.js +1 -0
  26. package/assets/esri/core/workers/chunks/{40b81d1c2d53cf598b8e.js → 2f03d33f4ca8a48461fc.js} +1 -1
  27. package/assets/esri/core/workers/chunks/{4f01be74dd26e639330f.js → 2f24017e72d41c259faa.js} +1 -1
  28. package/assets/esri/core/workers/chunks/3271614322ba4b44fb5a.js +1 -0
  29. package/assets/esri/core/workers/chunks/36b1f47d70b57d79df7b.js +1 -0
  30. package/assets/esri/core/workers/chunks/{3d65b8a2fbe1df050a25.js → 377a66034e7c1bad5599.js} +1 -1
  31. package/assets/esri/core/workers/chunks/37f2ef14399546e697e6.js +1 -0
  32. package/assets/esri/core/workers/chunks/{0f9bb3187306f89e3d63.js → 398f356b11fd33bd3831.js} +1 -1
  33. package/assets/esri/core/workers/chunks/3a457e718a901a45902e.js.LICENSE.txt +1 -1
  34. package/assets/esri/core/workers/chunks/4442817beb7a76c95770.js +1 -0
  35. package/assets/esri/core/workers/chunks/4c5a7249a311070d8f43.js +1 -0
  36. package/assets/esri/core/workers/chunks/551c6c89b51b99f4864b.js +1 -0
  37. package/assets/esri/core/workers/chunks/{9a723d739ac44b45432c.js → 557960763695abee4a83.js} +1 -1
  38. package/assets/esri/core/workers/chunks/655360995c1cbc78a5a3.js +1 -0
  39. package/assets/esri/core/workers/chunks/67d9cfe02613cb73ee37.js.LICENSE.txt +1 -1
  40. package/assets/esri/core/workers/chunks/6a69dafeb7c9ca8a3d84.js +1 -0
  41. package/assets/esri/core/workers/chunks/6c3b99209d542efa64d4.js +1 -0
  42. package/assets/esri/core/workers/chunks/{8215015f11221a354273.js → 6d049182bec34a22abcd.js} +1 -1
  43. package/assets/esri/core/workers/chunks/71762199aef5d3107da2.js +1 -0
  44. package/assets/esri/core/workers/chunks/72c851c400752094b162.js +1 -0
  45. package/assets/esri/core/workers/chunks/7558919912f7fdc4837b.js +1 -0
  46. package/assets/esri/core/workers/chunks/7596d005a4dc3964b140.js +1 -0
  47. package/assets/esri/core/workers/chunks/762fe93015b705546188.js +1 -0
  48. package/assets/esri/core/workers/chunks/79dbfa2b9b332ca0002f.js +1 -0
  49. package/assets/esri/core/workers/chunks/7a23ab84e1144f081c92.js +1 -0
  50. package/assets/esri/core/workers/chunks/{2a5f331c0f18d8574b4e.js → 811d4c46c75cf6a63e78.js} +1 -1
  51. package/assets/esri/core/workers/chunks/829bc5dbda2f51561446.js +1 -0
  52. package/assets/esri/core/workers/chunks/8372f142c4d7a65c7954.js +1 -0
  53. package/assets/esri/core/workers/chunks/8605ec4678eb4511c715.js +1 -0
  54. package/assets/esri/core/workers/chunks/883ffaa69b3e6eb158bf.js +1 -0
  55. package/assets/esri/core/workers/chunks/{3d22fe2f2c40abbc246e.js → 88d942cd25bef74fd50a.js} +1 -1
  56. package/assets/esri/core/workers/chunks/{0086a09441627842d34a.js → 8f3503b2fb6cd38757b9.js} +1 -1
  57. package/assets/esri/core/workers/chunks/9786f91455350eaae493.js +1 -0
  58. package/assets/esri/core/workers/chunks/98311fec6c16a1b23586.js +1 -0
  59. package/assets/esri/core/workers/chunks/9c5cbf8810f37b1a4718.js +1 -0
  60. package/assets/esri/core/workers/chunks/a091623bbfb3d771c8d8.js +1 -0
  61. package/assets/esri/core/workers/chunks/a137c27ce078bea44f89.js +1 -0
  62. package/assets/esri/core/workers/chunks/a29d7205394cb8b2a847.js +1 -0
  63. package/assets/esri/core/workers/chunks/a2a284d4dd5caaecbc2e.js +1 -0
  64. package/assets/esri/core/workers/chunks/{135e270b4f03c4270870.js → a4db5c9a90107e097df8.js} +1 -1
  65. package/assets/esri/core/workers/chunks/a61cb4f1ca282bf8b75d.js +1 -0
  66. package/assets/esri/core/workers/chunks/a6ac1ff89c40f3a4797a.js +1 -0
  67. package/assets/esri/core/workers/chunks/{dc31865edea480f0ebba.js → a8c4fd779e454e4075c4.js} +1 -1
  68. package/assets/esri/core/workers/chunks/a8f998b8ec8c56150479.js.LICENSE.txt +1 -1
  69. package/assets/esri/core/workers/chunks/aa6eb55e4fb57c4e8eeb.js +1 -0
  70. package/assets/esri/core/workers/chunks/aa78b69219d9a0ef1c54.js.LICENSE.txt +1 -1
  71. package/assets/esri/core/workers/chunks/af3fc2562bb6d217adf6.js +1 -0
  72. package/assets/esri/core/workers/chunks/{46ef545d2b3b3f4e6d32.js → b017bac40dc8328013e3.js} +2 -2
  73. package/assets/esri/core/workers/chunks/{46ef545d2b3b3f4e6d32.js.LICENSE.txt → b017bac40dc8328013e3.js.LICENSE.txt} +1 -1
  74. package/assets/esri/core/workers/chunks/b59f9c3f7a149214256f.js +1 -0
  75. package/assets/esri/core/workers/chunks/b96eb0ea506379182d62.js +2 -0
  76. package/assets/esri/core/workers/chunks/{24921d31efa8d222ad2d.js.LICENSE.txt → b96eb0ea506379182d62.js.LICENSE.txt} +1 -1
  77. package/assets/esri/core/workers/chunks/{b5863afafd3a7d2d5c05.js → bb5484b5eeacc9ad2ceb.js} +3 -3
  78. package/assets/esri/core/workers/chunks/bb56717c4e36f28d4c08.js +1 -0
  79. package/assets/esri/core/workers/chunks/bb7976e2f883b544add6.js +1 -0
  80. package/assets/esri/core/workers/chunks/c0b7e86860838638537f.js +1 -0
  81. package/assets/esri/core/workers/chunks/c134ebbaeac514cbd657.js +1 -0
  82. package/assets/esri/core/workers/chunks/c2b47a7dc961863d283f.js +1 -0
  83. package/assets/esri/core/workers/chunks/{0eaa4dccba0d844b9da3.js → c3ddcf9148dd2640c402.js} +1 -1
  84. package/assets/esri/core/workers/chunks/c476643002387f60ea42.js +1 -0
  85. package/assets/esri/core/workers/chunks/ce16489cf7eb0d78c741.js.LICENSE.txt +1 -1
  86. package/assets/esri/core/workers/chunks/d048e4926e78458afa3e.js +1 -0
  87. package/assets/esri/core/workers/chunks/d39a10155317e6f7a21c.js +1 -0
  88. package/assets/esri/core/workers/chunks/d6e0528eacee7ea4c1ce.js.LICENSE.txt +1 -1
  89. package/assets/esri/core/workers/chunks/d886fb97bdb348a16f25.js +1 -0
  90. package/assets/esri/core/workers/chunks/{00aa85ae6419aad183ea.js → dc4982b0ac007bd70213.js} +1 -1
  91. package/assets/esri/core/workers/chunks/e1258b6a404e58878c7a.js +1 -0
  92. package/assets/esri/core/workers/chunks/e31192ae920e3e19b6aa.js +1 -0
  93. package/assets/esri/core/workers/chunks/e6a86cad44056735ed26.js +1 -0
  94. package/assets/esri/core/workers/chunks/e82f5437bd66779c6740.js +1 -0
  95. package/assets/esri/core/workers/chunks/{039ec0fbe3b4b398b8c6.js → f26dc1d83beed63b6045.js} +1 -1
  96. package/assets/esri/core/workers/chunks/{fa5c87889c2f0bef896b.js → f35aaa04cca676c2d3f8.js} +1 -1
  97. package/assets/esri/core/workers/chunks/f5b7e7f2860a825ed373.js +1 -0
  98. package/assets/esri/core/workers/chunks/f651c05604eab83aef5f.js.LICENSE.txt +1 -1
  99. package/assets/esri/core/workers/chunks/{18da83afbc324fef9fd8.js → f779034623980bf9a37c.js} +2 -2
  100. package/assets/esri/libs/parquet/pkg/bundle_bg.wasm +0 -0
  101. package/assets/esri/themes/base/widgets/_Directions.scss +17 -18
  102. package/assets/esri/themes/dark/main.css +1 -1
  103. package/assets/esri/themes/light/main.css +1 -1
  104. package/assets/esri/themes/light/view.css +1 -1
  105. package/chunks/ComponentShader.glsl.js +72 -39
  106. package/chunks/OITBlend.glsl.js +3 -3
  107. package/chunks/bundle.js +1 -1
  108. package/config.js +1 -1
  109. package/core/QueueProcessor.js +1 -1
  110. package/core/has.js +1 -1
  111. package/core/sanitizerUtils.js +1 -1
  112. package/core/workers/Connection.js +1 -1
  113. package/core/workers/WorkerHandle.js +1 -1
  114. package/core/workers/utils.js +1 -1
  115. package/geohash/GeohashCell.js +1 -1
  116. package/geohash/geohashUtils.js +1 -1
  117. package/geometry/GeometryCursor.js +1 -1
  118. package/geometry/geometryCursorCollectUtils.js +1 -1
  119. package/geometry/libtess.js +1 -1
  120. package/geometry/support/jsonUtils.js +1 -1
  121. package/geometry/support/normalizeUtilsSync.js +1 -1
  122. package/geometry/support/triangulationUtils.js +1 -1
  123. package/interfaces.d.ts +426 -347
  124. package/intl/date.js +1 -1
  125. package/intl.d.ts +2 -0
  126. package/intl.js +1 -1
  127. package/kernel.js +1 -1
  128. package/layers/FeatureLayer.js +1 -1
  129. package/layers/graphics/OptimizedFeature.js +1 -1
  130. package/layers/graphics/OptimizedGeometry.js +1 -1
  131. package/layers/graphics/centroid.js +1 -1
  132. package/layers/graphics/contains.js +1 -1
  133. package/layers/graphics/data/AttributesBuilder.js +1 -1
  134. package/layers/graphics/data/FeatureStore.js +1 -1
  135. package/layers/graphics/data/QueryEngine.js +1 -1
  136. package/layers/graphics/data/QueryEngineResult.js +1 -1
  137. package/layers/graphics/data/geometryUtils.js +1 -1
  138. package/layers/graphics/data/spatialQuerySupport.js +1 -1
  139. package/layers/graphics/featureConversionUtils.js +1 -1
  140. package/layers/graphics/sources/OGCFeatureSource.js +1 -1
  141. package/layers/graphics/sources/geojson/GeoJSONSourceWorker.js +1 -1
  142. package/layers/graphics/sources/geojson/geojson.js +1 -1
  143. package/layers/graphics/sources/support/MemorySourceWorker.js +1 -1
  144. package/layers/graphics/sources/support/ParquetSourceWorker.js +1 -1
  145. package/layers/graphics/sources/support/clientSideDefaults.js +1 -1
  146. package/layers/knowledgeGraph/layerUtils.js +1 -1
  147. package/layers/mixins/ArcGISImageService.js +1 -1
  148. package/layers/mixins/ImageryTileMixin.js +1 -1
  149. package/layers/support/PixelBlock.js +1 -1
  150. package/layers/support/RasterInfo.js +1 -1
  151. package/layers/support/RasterJobHandler.js +1 -1
  152. package/layers/support/RasterSensorInfo.js +1 -1
  153. package/layers/support/RasterStorageInfo.js +1 -1
  154. package/layers/support/RasterWorker.js +1 -1
  155. package/layers/support/TitleCreator.js +1 -1
  156. package/layers/support/arcgisLayerUrl.js +1 -1
  157. package/layers/support/capabilities.js +1 -1
  158. package/layers/support/rasterDatasets/BaseRaster.js +1 -1
  159. package/layers/support/rasterDatasets/pixelReader.js +1 -1
  160. package/layers/support/rasterFieldUtils.js +1 -1
  161. package/layers/support/rasterFunctions/pixelUtils.js +1 -1
  162. package/layers/support/serviceCapabilitiesUtils.js +1 -1
  163. package/package.json +5 -5
  164. package/request.js +1 -1
  165. package/rest/print.js +1 -1
  166. package/rest/query/operations/pbfDehydratedFeatureSet.js +1 -1
  167. package/rest/query/operations/pbfJSONFeatureSet.js +1 -1
  168. package/rest/query/operations/query.js +1 -1
  169. package/rest/query/operations/queryZScale.js +1 -1
  170. package/rest/versionManagement/getVersionInfos.js +1 -1
  171. package/smartMapping/statistics/histogram.js +1 -1
  172. package/smartMapping/support/adapters/FeatureLayerAdapter.js +1 -1
  173. package/smartMapping/support/utils.js +1 -1
  174. package/support/elevationInfoUtils.js +1 -1
  175. package/support/requestImageUtils.js +1 -1
  176. package/support/revision.js +1 -1
  177. package/views/2d/GoToManager.js +1 -1
  178. package/views/2d/analysis/ElevationProfile/ElevationProfileLineVisualization2D.js +1 -1
  179. package/views/2d/engine/vectorTiles/shaders/sources/shaderRepository.js +1 -1
  180. package/views/2d/engine/webgl/Mesh2D.js +1 -1
  181. package/views/2d/engine/webgl/brushes/WGLBrushVTLSymbol.js +1 -1
  182. package/views/2d/engine/webgl/mesh/templates/templateUtils.js +1 -1
  183. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedMarkerMeshWriter.js +1 -1
  184. package/views/2d/engine/webgl/shaderGraph/techniques/fill/AFillMeshWriter.js +1 -1
  185. package/views/2d/engine/webgl/shaderGraph/techniques/labels/LabelMeshWriter.js +1 -1
  186. package/views/2d/layers/features/aggregation/GridCell.js +1 -1
  187. package/views/2d/layers/features/processor/AAggregateStrategy.js +1 -1
  188. package/views/2d/layers/features/processor/BinningStrategy.js +1 -1
  189. package/views/2d/layers/features/processor/FeatureUpdateStrategy.js +1 -1
  190. package/views/2d/layers/features/processor/TrackStrategy.js +1 -1
  191. package/views/2d/layers/features/schema/SourceSchema.js +1 -1
  192. package/views/2d/layers/features/sources/FeatureSource.js +1 -1
  193. package/views/2d/layers/features/sources/strategies/ParquetTileLoadStrategy.js +1 -1
  194. package/views/2d/layers/features/sources/strategies/chunks/Overrides.js +1 -1
  195. package/views/2d/layers/features/sources/strategies/chunks/SourceChunkStore.js +1 -1
  196. package/views/2d/layers/features/support/AttributeStore.js +1 -1
  197. package/views/2d/layers/features/support/FeatureFilterEvaluator.js +1 -1
  198. package/views/2d/layers/features/support/FeatureSetReader.js +1 -1
  199. package/views/2d/layers/features/support/FeatureSetReaderIndirect.js +1 -1
  200. package/views/2d/layers/features/support/FeatureSetReaderPBF.js +1 -1
  201. package/views/2d/layers/features/support/FeatureSetReaderParquet.js +1 -1
  202. package/views/2d/layers/features/support/GraphicsReader.js +1 -1
  203. package/views/2d/layers/imagery/ImageryTileView2D.js +1 -1
  204. package/views/3d/FocusAreasView.js +1 -1
  205. package/views/3d/GroundView3D.js +1 -1
  206. package/views/3d/analysis/ElevationProfile/ElevationProfileLineSceneComputation.js +1 -1
  207. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillController.js +1 -1
  208. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillVisualization.js +1 -1
  209. package/views/3d/glTF/DefaultLoadingContext.js +1 -1
  210. package/views/3d/layers/FeatureLayerViewBase3D.js +1 -1
  211. package/views/3d/layers/FlowSubView3D.js +1 -1
  212. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  213. package/views/3d/layers/PointCloudLayerView3D.js +1 -1
  214. package/views/3d/layers/graphics/Graphics3DExtrudeSymbolLayer.js +1 -1
  215. package/views/3d/layers/graphics/Graphics3DFeatureStore.js +1 -1
  216. package/views/3d/layers/graphics/Graphics3DIconSymbolLayer.js +1 -1
  217. package/views/3d/layers/graphics/Graphics3DLineSymbolLayer.js +1 -1
  218. package/views/3d/layers/graphics/Graphics3DPolygonFillSymbolLayer.js +1 -1
  219. package/views/3d/layers/graphics/Graphics3DWaterSymbolLayer.js +1 -1
  220. package/views/3d/layers/graphics/pipeline/featureSet/PBFPointFeatureSetView.js +1 -1
  221. package/views/3d/layers/graphics/pipeline/featureSet/TiledFeatureStore.js +1 -1
  222. package/views/3d/layers/i3s/I3SIndex.js +1 -1
  223. package/views/3d/layers/i3s/I3SQueryFeatureAdapter.js +1 -1
  224. package/views/3d/layers/support/FeatureTileFetcher3D.js +1 -1
  225. package/views/3d/layers/support/FeatureTileFetcher3DContext.js +1 -1
  226. package/views/3d/layers/support/HeatmapFeatureProcessor.js +1 -1
  227. package/views/3d/layers/support/featureTileQuery3D.js +1 -1
  228. package/views/3d/state/ViewStateManager.js +1 -1
  229. package/views/3d/state/controllers/PinchAndPanControllerGlobal.js +1 -1
  230. package/views/3d/state/controllers/PinchAndPanControllerLocal.js +1 -1
  231. package/views/3d/state/controllers/RotateController.js +1 -1
  232. package/views/3d/state/controllers/ZoomControllerGlobal.js +1 -1
  233. package/views/3d/state/controllers/ZoomControllerLocal.js +1 -1
  234. package/views/3d/state/controllers/ZoomStepControllerGlobal.js +1 -1
  235. package/views/3d/state/controllers/ZoomStepControllerLocal.js +1 -1
  236. package/views/3d/state/utils/navigationUtils.js +1 -1
  237. package/views/3d/support/DisplayQualityProfile.js +1 -1
  238. package/views/3d/support/QualitySettings.js +1 -1
  239. package/views/3d/support/StreamDataLoader.js +1 -1
  240. package/views/3d/support/engineContent/line.js +1 -1
  241. package/views/3d/support/flow/FlowSubViewTiles3D.js +1 -1
  242. package/views/3d/support/flow/FlowWorker.js +1 -1
  243. package/views/3d/support/flow/StreamlineResources3D.js +1 -1
  244. package/views/3d/support/flow/constants.js +1 -1
  245. package/views/3d/support/hitTest.js +1 -1
  246. package/views/3d/support/renderInfoUtils/polygon.js +1 -1
  247. package/views/3d/terrain/Tile.js +1 -1
  248. package/views/3d/terrain/TileOverlayData.js +1 -1
  249. package/views/3d/webgl-engine/collections/Component/ComponentObject.js +1 -1
  250. package/views/3d/webgl-engine/collections/Component/ComponentObjectCollection.js +1 -1
  251. package/views/3d/webgl-engine/collections/Component/Material/ComponentMaterial.js +1 -1
  252. package/views/3d/webgl-engine/collections/Component/Material/ComponentTechniqueConfiguration.js +1 -1
  253. package/views/3d/webgl-engine/collections/Component/Material/shader/ComponentShader.glsl.js +1 -1
  254. package/views/3d/webgl-engine/core/shaderLibrary/terrain/Overlay.glsl.js +7 -7
  255. package/views/3d/webgl-engine/core/shaderModules/BooleanDrawUniform.js +5 -0
  256. package/views/3d/webgl-engine/core/shaderTechnique/ShaderTechniqueConstructionContext.js +1 -1
  257. package/views/3d/webgl-engine/lib/CutFillDepth.js +1 -1
  258. package/views/3d/webgl-engine/lib/Object3D.js +1 -1
  259. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  260. package/views/3d/webgl-engine/parts/RenderView.js +1 -1
  261. package/views/3d/webgl-engine/shaders/AnimatedLine.glsl.js +4 -4
  262. package/views/analysis/ElevationProfile/ElevationProfileController.js +1 -1
  263. package/views/analysis/ElevationProfile/ElevationProfileLineInputComputation.js +1 -1
  264. package/views/analysis/ElevationProfile/ElevationProfileResult.js +1 -1
  265. package/views/analysis/ElevationProfile/ElevationProfileTool.js +1 -1
  266. package/views/analysis/ElevationProfile/elevationProfileGenerationUtils.js +1 -1
  267. package/views/draw/support/Reshape.js +1 -1
  268. package/views/draw/support/reshapeUtils.js +1 -1
  269. package/views/interactive/dragEventPipeline.js +1 -1
  270. package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTileStore.js +1 -1
  271. package/views/webgl/ShaderBuilder.js +1 -1
  272. package/views/webgl/Texture.js +1 -1
  273. package/widgets/BatchAttributeForm/BatchAttributeFormViewModel.js +1 -1
  274. package/widgets/BatchAttributeForm.js +1 -1
  275. package/widgets/Directions/css.js +1 -1
  276. package/widgets/Directions.js +1 -1
  277. package/widgets/Editor/AddAssociationWorkflow.js +1 -1
  278. package/widgets/Editor/CreateFeaturesWorkflow.js +1 -1
  279. package/widgets/Editor/EditorViewModel.js +1 -1
  280. package/widgets/Editor/Edits.js +1 -1
  281. package/widgets/Editor/MergeFeaturesWorkflow.d.ts +4 -0
  282. package/widgets/Editor/MergeFeaturesWorkflow.js +5 -0
  283. package/widgets/Editor/MergeFeaturesWorkflowData.d.ts +4 -0
  284. package/widgets/Editor/MergeFeaturesWorkflowData.js +5 -0
  285. package/widgets/Editor/SplitFeatureWorkflow.js +1 -1
  286. package/widgets/Editor/UpdateFeaturesWorkflow.js +1 -1
  287. package/widgets/Editor/UpdateFeaturesWorkflowData.js +1 -1
  288. package/widgets/Editor/UpdateRecordWorkflow.js +1 -1
  289. package/widgets/Editor/components/UploadDetails.js +1 -1
  290. package/widgets/Editor/support/EditorItem.js +1 -1
  291. package/widgets/Editor/support/mergeFeaturesUtils.js +5 -0
  292. package/widgets/Editor/workflowUtils.js +1 -1
  293. package/widgets/Editor.js +1 -1
  294. package/widgets/Feature/FeatureExpression.js +1 -1
  295. package/widgets/Feature/FeatureFields/FeatureFieldsViewModel.js +1 -1
  296. package/widgets/Feature/FeatureFields.js +1 -1
  297. package/widgets/Feature/FeatureMedia/FeatureMediaViewModel.js +1 -1
  298. package/widgets/Feature/FeatureMedia.js +1 -1
  299. package/widgets/Feature/FeatureViewModel.js +1 -1
  300. package/widgets/Feature/support/featureUtils.js +1 -1
  301. package/widgets/Feature.js +1 -1
  302. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  303. package/widgets/OrientedImageryViewer/components/SequentialNavigationUI.js +1 -1
  304. package/widgets/OrientedImageryViewer/components/SketchTools.js +1 -1
  305. package/widgets/Print.js +1 -1
  306. package/widgets/support/ColorPicker.js +1 -1
  307. package/widgets/support/SelectionList/LayerItem.js +1 -1
  308. package/widgets/support/jsxWidgetSupport.js +1 -1
  309. package/assets/esri/core/workers/chunks/065f2bbcaeef1f13fd48.js +0 -1
  310. package/assets/esri/core/workers/chunks/0731e588afd1f561ec3b.js +0 -1
  311. package/assets/esri/core/workers/chunks/188272af9a6470ccfe31.js +0 -1
  312. package/assets/esri/core/workers/chunks/1a9f544f20f643161a36.js +0 -1
  313. package/assets/esri/core/workers/chunks/1cfcadaa98ac528fea37.js +0 -1
  314. package/assets/esri/core/workers/chunks/1db0bf570a04687b3130.js +0 -1
  315. package/assets/esri/core/workers/chunks/24921d31efa8d222ad2d.js +0 -2
  316. package/assets/esri/core/workers/chunks/2a900a632a1231deb713.js +0 -1
  317. package/assets/esri/core/workers/chunks/31c6e951b99315e8e68a.js +0 -1
  318. package/assets/esri/core/workers/chunks/35491fbdd287470d40a4.js +0 -1
  319. package/assets/esri/core/workers/chunks/36247c6f6fc2891df2cf.js +0 -1
  320. package/assets/esri/core/workers/chunks/3d53307efbc3f07d7bf2.js +0 -1
  321. package/assets/esri/core/workers/chunks/42a72e1d963e4636323b.js +0 -1
  322. package/assets/esri/core/workers/chunks/456161a323be7d640c61.js +0 -1
  323. package/assets/esri/core/workers/chunks/500d09d2191127371081.js +0 -1
  324. package/assets/esri/core/workers/chunks/5707713c2f27588b9194.js +0 -1
  325. package/assets/esri/core/workers/chunks/5713f96bade5ebb54c81.js +0 -1
  326. package/assets/esri/core/workers/chunks/5718cf135e105e1e026b.js +0 -1
  327. package/assets/esri/core/workers/chunks/5c585b338a9e9aa0e205.js +0 -1
  328. package/assets/esri/core/workers/chunks/5d1d909354c90cb8eb60.js +0 -1
  329. package/assets/esri/core/workers/chunks/5ea03f53d4d64d9e7cae.js +0 -1
  330. package/assets/esri/core/workers/chunks/63019a7eb5222dc5e420.js +0 -1
  331. package/assets/esri/core/workers/chunks/64629ddcf008349eaf41.js +0 -1
  332. package/assets/esri/core/workers/chunks/64ee8d2acae2d6fce608.js +0 -1
  333. package/assets/esri/core/workers/chunks/6fcacfcb3d83515c37c9.js +0 -1
  334. package/assets/esri/core/workers/chunks/72ecf49d03bb24bf0998.js +0 -1
  335. package/assets/esri/core/workers/chunks/7421f9575487cdc9e28e.js +0 -1
  336. package/assets/esri/core/workers/chunks/77a11d7d53325d108ed8.js +0 -1
  337. package/assets/esri/core/workers/chunks/7a05b1f6163112bc9db2.js +0 -1
  338. package/assets/esri/core/workers/chunks/7d9882ddfa6495f72baa.js +0 -1
  339. package/assets/esri/core/workers/chunks/7fffad8ff6878fa1fd56.js +0 -1
  340. package/assets/esri/core/workers/chunks/81bbe5251ed13c0d91cc.js +0 -1
  341. package/assets/esri/core/workers/chunks/8b16aa50d879b92a5375.js +0 -1
  342. package/assets/esri/core/workers/chunks/8bc64fc7c4b9eb8fca4d.js +0 -1
  343. package/assets/esri/core/workers/chunks/8bfa19c24be0e3f3fd74.js +0 -1
  344. package/assets/esri/core/workers/chunks/8eefa133c36a004c054c.js +0 -1
  345. package/assets/esri/core/workers/chunks/9834bc11586a2d8d6f35.js +0 -1
  346. package/assets/esri/core/workers/chunks/9c6fc4fe2c46f40d63d9.js +0 -1
  347. package/assets/esri/core/workers/chunks/a5f25104938ab33e7a85.js +0 -1
  348. package/assets/esri/core/workers/chunks/a7bd294996e6c8b8354a.js +0 -1
  349. package/assets/esri/core/workers/chunks/abf4f018c692c18c3320.js +0 -1
  350. package/assets/esri/core/workers/chunks/b1f667006cba60ef4aa7.js +0 -1
  351. package/assets/esri/core/workers/chunks/b2d9f4e057af26a538fb.js +0 -1
  352. package/assets/esri/core/workers/chunks/b62807c6fcfb70a87cd4.js +0 -1
  353. package/assets/esri/core/workers/chunks/b8339c1d60847a9eed3e.js +0 -1
  354. package/assets/esri/core/workers/chunks/c362fbbafec91c44eeb2.js +0 -1
  355. package/assets/esri/core/workers/chunks/c941d15190fc08523d0d.js +0 -1
  356. package/assets/esri/core/workers/chunks/cc70a4a915b0b2ccb2a0.js +0 -1
  357. package/assets/esri/core/workers/chunks/d121045cddbe55c2ecb2.js +0 -1
  358. package/assets/esri/core/workers/chunks/d2120a623b1bd91b9ed9.js +0 -1
  359. package/assets/esri/core/workers/chunks/d78c2833cdc4730a88a3.js +0 -1
  360. package/assets/esri/core/workers/chunks/df438b62702007267798.js +0 -1
  361. package/assets/esri/core/workers/chunks/f4eb090bcc3eca64306a.js +0 -1
  362. package/assets/esri/core/workers/chunks/f7846523adacbfe5047e.js +0 -1
  363. package/assets/esri/core/workers/chunks/f839b86bee15deaf84e4.js +0 -1
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2568],{35448:(e,t,r)=>{r.d(t,{Eq:()=>n,bV:()=>a,nP:()=>s,r5:()=>o,ti:()=>d,vy:()=>l,wr:()=>i});const n={Regular:0,Provenance:1,Document:2},o={esriFieldTypeSmallInteger:0,esriFieldTypeInteger:1,esriFieldTypeSingle:2,esriFieldTypeDouble:3,esriFieldTypeString:4,esriFieldTypeDate:5,esriFieldTypeOID:6,esriFieldTypeGeometry:7,esriFieldTypeBlob:8,esriFieldTypeRaster:9,esriFieldTypeGUID:10,esriFieldTypeGlobalID:11,esriFieldTypeXML:12,esriFieldTypeBigInteger:13,esriFieldTypeDateOnly:14,esriFieldTypeTimeOnly:15,esriFieldTypeTimestampOffset:16},a={esriGeometryNull:0,esriGeometryPoint:1,esriGeometryMultipoint:2,esriGeometryPolyline:3,esriGeometryPolygon:4,esriGeometryEnvelope:5,esriGeometryAny:7,esriGeometryMultiPatch:9},i={esriMethodHintUNSPECIFIED:0,esriUUIDESRI:1,esriUUIDRFC4122:2},s={esriTypeUNSPECIFIED:0,esriTypeEntity:1,esriTypeRelationship:2,esriTypeBoth:4,esriTypeMetaEntityProvenance:8},d={esriGraphPropertyUNSPECIFIED:0,esriGraphPropertyRegular:1,esriGraphPropertyDocumentName:2,esriGraphPropertyDocumentTitle:3,esriGraphPropertyDocumentUrl:4,esriGraphPropertyDocumentText:5,esriGraphPropertyDocumentKeywords:6,esriGraphPropertyDocumentContentType:7,esriGraphPropertyDocumentMetadata:8,esriGraphPropertyDocumentFileExtension:9,esriGraphPropertyProvenanceInstanceId:10,esriGraphPropertyProvenanceSourceType:11,esriGraphPropertyProvenanceSourceName:12,esriGraphPropertyProvenanceSource:13,esriGraphPropertyProvenanceComment:14,esriGraphPropertyProvenanceTypeName:15,esriGraphPropertyProvenancePropertyName:16},l={esriIdentifierInfoTypeUNSPECIFIED:0,esriIdentifierInfoTypeDatabaseNative:1,esriIdentifierInfoTypeUniformProperty:2}},45724:(e,t,r)=>{r.d(t,{I:()=>d});var n=r(2741),o=r(44208);const a="esri/rest/knowledgeGraph/wasmInterface/";let i,s;async function d(){const e=i??s;if(e)return e;const t=!!(0,o.A)("wasm-simd");return s=l(t),s}async function l(e){if(e){const{default:e}=await r.e(5367).then(r.bind(r,15367)).then(e=>e.a);return e({locateFile:e=>(0,n.s)(a+e)})}const{default:t}=await r.e(9013).then(r.bind(r,29013)).then(e=>e.a);return t({locateFile:e=>(0,n.s)(a+e)})}},62568:(e,t,r)=>{r.r(t),r.d(t,{_checkAuthentication:()=>or,_esriRequestWrapper:()=>nr,_fetchWrapper:()=>tr,_getClientDataCacheCopy:()=>St,_setMaxQueryParsingDurationForTesting:()=>lr,_submitJobWrapper:()=>rr,clearClientDataCache:()=>er,clientDataCache:()=>kt,executeAddGraphFieldIndex:()=>qt,executeAddGraphProperties:()=>Et,executeAddNamedTypes:()=>It,executeApplyEdits:()=>jt,executeDeleteGraphFieldIndex:()=>$t,executeDeleteGraphProperty:()=>Ft,executeDeleteNamedType:()=>Dt,executeFindPaths:()=>Yt,executeFindPathsAsynchronous:()=>Wt,executeQuery:()=>Lt,executeQueryStreaming:()=>Ut,executeSearch:()=>zt,executeSearchStreaming:()=>Jt,executeUpdateGraphProperty:()=>Nt,executeUpdateNamedType:()=>Zt,executeUpdateSearchIndex:()=>Ot,fetchAllClientDataKeys:()=>Kt,fetchAsynchronousFindPathsResultData:()=>Xt,fetchClientDataAtKeys:()=>Vt,fetchKnowledgeGraph:()=>Qt,kgRestServices:()=>Rt,refreshDataModel:()=>Bt,refreshServiceDefinition:()=>Ht});var n,o=r(70333),a=r(78888),i=r(49186),s=r(53966),d=r(74887),l=r(91075),p=r(16930),u=r(31635),c=r(69622),h=r(10107),y=r(56507),g=(r(44208),r(87811),r(64108)),f=r(5443);let w=n=class extends c.A{constructor(e){super(e),this.outSpatialReference=null,this.processExtent=null,this.processSpatialReference=null,this.returnColumnName=!1,this.returnFeatureCollection=!1,this.returnM=!1,this.returnZ=!1}static from(e){return(0,y.PZ)(n,e)}};(0,u.Cg)([(0,h.MZ)({type:p.A})],w.prototype,"outSpatialReference",void 0),(0,u.Cg)([(0,h.MZ)({type:f.A})],w.prototype,"processExtent",void 0),(0,u.Cg)([(0,h.MZ)({type:p.A})],w.prototype,"processSpatialReference",void 0),(0,u.Cg)([(0,h.MZ)({nonNullable:!0})],w.prototype,"returnColumnName",void 0),(0,u.Cg)([(0,h.MZ)({nonNullable:!0})],w.prototype,"returnFeatureCollection",void 0),(0,u.Cg)([(0,h.MZ)({nonNullable:!0})],w.prototype,"returnM",void 0),(0,u.Cg)([(0,h.MZ)({nonNullable:!0})],w.prototype,"returnZ",void 0),w=n=(0,u.Cg)([(0,g.$)("esri.rest.geoprocessor.GPOptions")],w);var m=r(17136),_=r(20437),v=r(25482);let b=class extends v.o{constructor(e){super(e),this.extent=null,this.height=null,this.href=null,this.opacity=1,this.rotation=0,this.scale=null,this.visible=!0,this.width=null}};(0,u.Cg)([(0,h.MZ)({type:f.A})],b.prototype,"extent",void 0),(0,u.Cg)([(0,h.MZ)()],b.prototype,"height",void 0),(0,u.Cg)([(0,h.MZ)()],b.prototype,"href",void 0),(0,u.Cg)([(0,h.MZ)()],b.prototype,"opacity",void 0),(0,u.Cg)([(0,h.MZ)()],b.prototype,"rotation",void 0),(0,u.Cg)([(0,h.MZ)()],b.prototype,"scale",void 0),(0,u.Cg)([(0,h.MZ)()],b.prototype,"visible",void 0),(0,u.Cg)([(0,h.MZ)()],b.prototype,"width",void 0),b=(0,u.Cg)([(0,g.$)("esri.layers.support.MapImage")],b);var C=r(2272),A=r(93223),G=r(2073);let M=class extends v.o{constructor(e){super(e),this.area=0,this.units=null}};(0,u.Cg)([(0,h.MZ)({json:{write:!0}})],M.prototype,"area",void 0),(0,u.Cg)([(0,A.e)(G.UO)],M.prototype,"units",void 0),M=(0,u.Cg)([(0,g.$)("esri.rest.support.ArealUnit")],M);let x=class extends v.o{constructor(e){super(e),this.itemId=null,this.url=null}};(0,u.Cg)([(0,h.MZ)({type:String,json:{read:{source:"itemID"},write:{target:"itemID"}}})],x.prototype,"itemId",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],x.prototype,"url",void 0),x=(0,u.Cg)([(0,g.$)("esri.rest.support.DataFile")],x);var T=r(22671);let P=class extends v.o{constructor(e){super(e),this.distance=0,this.units=null}};(0,u.Cg)([(0,h.MZ)({json:{write:!0}})],P.prototype,"distance",void 0),(0,u.Cg)([(0,A.e)(G.Y8)],P.prototype,"units",void 0),P=(0,u.Cg)([(0,g.$)("esri.rest.support.LinearUnit")],P);var k=r(66552);const S="multi-value-",R=new k.J({GPArealUnit:"areal-unit",GPBoolean:"boolean",GPComposite:"composite",GPDataFile:"data-file",GPDate:"date",GPDouble:"double",GPFeatureRecordSetLayer:"feature-record-set-layer",Field:"field",GPLinearUnit:"linear-unit",GPLong:"long",GPRasterData:"raster-data",GPRasterDataLayer:"raster-data-layer",GPRecordSet:"record-set",GPString:"string",GPValueTable:"value-table","GPMultiValue:GPArealUnit":`${S}areal-unit`,"GPMultiValue:GPBoolean":`${S}boolean`,"GPMultiValue:GPComposite":`${S}composite`,"GPMultiValue:GPDataFile":`${S}data-file`,"GPMultiValue:GPDate":`${S}date`,"GPMultiValue:GPDouble":`${S}double`,"GPMultiValue:GPFeatureRecordSetLayer":`${S}feature-record-set-layer`,"GPMultiValue:Field":`${S}field`,"GPMultiValue:GPLinearUnit":`${S}linear-unit`,"GPMultiValue:GPLong":`${S}long`,"GPMultiValue:GPRasterData":`${S}raster-data`,"GPMultiValue:GPRasterDataLayer":`${S}raster-data-layer`,"GPMultiValue:GPRecordSet":`${S}record-set`,"GPMultiValue:GPString":`${S}string`});let j=class extends v.o{constructor(e){super(e),this.dataType=null,this.paramName=null,this.value=null}};(0,u.Cg)([(0,A.e)(R,{ignoreUnknown:!1})],j.prototype,"dataType",void 0),(0,u.Cg)([(0,h.MZ)()],j.prototype,"paramName",void 0),(0,u.Cg)([(0,h.MZ)()],j.prototype,"value",void 0),j=(0,u.Cg)([(0,g.$)("esri.rest.support.ParameterValue")],j);var I=r(36005);let D=class extends v.o{constructor(e){super(e),this.format=null,this.itemId=null,this.type=null,this.url=null}readType(e){return"ImageService"===e?"image-service":null}};async function Z(e,t){switch(e){case"areal-unit":return M.fromJSON(t);case"boolean":case"double":case"long":case"string":case"value-table":return t;case"date":return new Date(t);case"data-file":return x.fromJSON(t);case"linear-unit":return P.fromJSON(t);case"feature-record-set-layer":if("url"in t)return x.fromJSON(t);if("layerDefinition"in t){const e=new(0,(await Promise.all([r.e(7330),r.e(4045),r.e(6554),r.e(8303),r.e(4903),r.e(1214),r.e(9953),r.e(1956),r.e(8399),r.e(1017),r.e(957),r.e(8506),r.e(8654),r.e(3548)]).then(r.bind(r,68654))).default),{layerDefinition:n,featureSet:o}=t;return e.read({layerDefinition:n,featureSet:o},{origin:"portal-item"}),e.spatialReference=p.A.fromJSON(o.spatialReference??n.spatialReference??n.extent.spatialReference),e}return T.A.fromJSON(t);case"record-set":return"url"in t?x.fromJSON(t):T.A.fromJSON(t);case"raster-data":case"raster-data-layer":return"mapImage"in t?b.fromJSON(t.mapImage):D.fromJSON(t);case"field":return _.A.fromJSON(t)}}async function E(e){const t=R.fromJSON(e.dataType),{paramName:r}=e,n=function(e){return e.startsWith(S)}(t)?await async function(e,t){const r=function(e){return e.replace(S,"")}(e),n="composite"===r?t.map(e=>Z(R.fromJSON(e.dataType),e.value)):t.map(e=>Z(r,e));return Promise.all(n)}(t,e.value):await Z(t,e.value);return new j({dataType:t,paramName:r,value:n})}function F(e,t,r){for(const t in e){const r=e[t];Array.isArray(r)?e[t]=JSON.stringify(r.map(e=>F({item:e},!0).item)):r instanceof Date&&(e[t]=r.getTime())}return(0,C.lF)(e,t,r)}(0,u.Cg)([(0,h.MZ)()],D.prototype,"format",void 0),(0,u.Cg)([(0,h.MZ)({json:{name:"itemID",write:!0}})],D.prototype,"itemId",void 0),(0,u.Cg)([(0,h.MZ)()],D.prototype,"type",void 0),(0,u.Cg)([(0,I.w)("type")],D.prototype,"readType",null),(0,u.Cg)([(0,h.MZ)({json:{write:!0}})],D.prototype,"url",void 0),D=(0,u.Cg)([(0,g.$)("esri.rest.support.RasterData")],D);var N,q=r(37807);const $=(0,k.O)()({esriJobCancelled:"job-cancelled",esriJobCancelling:"job-cancelling",esriJobDeleted:"job-deleted",esriJobDeleting:"job-deleting",esriJobTimedOut:"job-timed-out",esriJobExecuting:"job-executing",esriJobFailed:"job-failed",esriJobNew:"job-new",esriJobSubmitted:"job-submitted",esriJobSucceeded:"job-succeeded",esriJobWaiting:"job-waiting"},{ignoreUnknown:!1}),O=1e3;let L=class extends v.o{static{N=this}constructor(e){super(e),this.jobId=null,this.jobStatus=null,this.messages=null,this.progress=null,this.requestOptions=null,this.sourceUrl=null,this._cancelJobTimer=void 0,this._jobCompletionTimer=void 0}async cancelJob(e){const{jobId:t,sourceUrl:r}=this,{path:n}=(0,C.Dl)(r),o={...this.requestOptions,...e,query:{f:"json"}},i=`${n}/jobs/${t}/cancel`,{data:s}=await(0,a.A)(i,o),{messages:l,jobStatus:p,progress:u}=N.fromJSON(s);return this.set({messages:l,jobStatus:p,progress:u}),"job-cancelled"===p?this:new Promise((t,r)=>{(0,d.u7)(o.signal,()=>{this.clearCancelJobTimer(),r((0,d.NK)())}),this.clearCancelJobTimer();const n=()=>{this._cancelJobTimer||r((0,d.NK)()),this.checkJobStatus(e).then(({jobStatus:e})=>{switch(e){case"job-cancelling":default:this._cancelJobTimer=setTimeout(n,O);break;case"job-deleted":case"job-deleting":case"job-executing":case"job-failed":case"job-new":case"job-submitted":case"job-succeeded":case"job-timed-out":case"job-waiting":r(this);break;case"job-cancelled":t(this)}}).catch(e=>{r(e)})};this._cancelJobTimer=setTimeout(n,O)})}destroy(){clearInterval(this._cancelJobTimer),clearInterval(this._jobCompletionTimer)}async checkJobStatus(e){const{path:t}=(0,C.Dl)(this.sourceUrl),r={...this.requestOptions,...e,query:{...e?.query,f:"json"}},n=`${t}/jobs/${this.jobId}`,{data:o}=await(0,a.A)(n,r),{messages:i,jobStatus:s,progress:d}=N.fromJSON(o);return this.set({messages:i,jobStatus:s,progress:d}),this}async fetchResultData(e,t,r){t=w.from(t||{});const{returnColumnName:n,returnFeatureCollection:o,returnM:i,returnZ:s,outSpatialReference:d}=t,{path:l}=(0,C.Dl)(this.sourceUrl),p=F({returnColumnName:n||null,returnFeatureCollection:o||null,returnM:i||null,returnZ:s||null,outSR:d,returnType:"data",f:"json",...r?.query},null),u={...this.requestOptions,...r,query:p},c=`${l}/jobs/${this.jobId}/results/${e}`,{data:h}=await(0,a.A)(c,u);return E(h)}async fetchResultImage(e,t,r){const{path:n}=(0,C.Dl)(this.sourceUrl),o=F({...t.toJSON(),f:"json"}),i={...this.requestOptions,...r,query:o},s=`${n}/jobs/${this.jobId}/results/${e}`,{data:d}=await(0,a.A)(s,i);return E(d)}async fetchResultMapImageLayer(){const{path:e}=(0,C.Dl)(this.sourceUrl),t=e.indexOf("/GPServer/"),n=`${e.slice(0,Math.max(0,t))}/MapServer/jobs/${this.jobId}`;return new(0,(await Promise.all([r.e(4045),r.e(6554),r.e(8303),r.e(4903),r.e(1214),r.e(1956),r.e(8399),r.e(957),r.e(364),r.e(7048),r.e(7656),r.e(7548)]).then(r.bind(r,7656))).default)({url:n})}async waitForJobCompletion(e={}){const{interval:t=O,signal:r,statusCallback:n,apiKey:o}=e;return new Promise((e,a)=>{(0,d.u7)(r,()=>{this.clearJobCompletionTimer(),a((0,d.NK)())}),this.clearJobCompletionTimer();const i=()=>{this._jobCompletionTimer||a((0,d.NK)()),this.checkJobStatus({query:{token:o}}).then(({jobStatus:r})=>{switch(r){case"job-succeeded":e(this);break;case"job-executing":case"job-new":case"job-submitted":case"job-waiting":n&&n(this),this._jobCompletionTimer=setTimeout(i,t);break;case"job-cancelled":case"job-cancelling":case"job-deleted":case"job-deleting":case"job-failed":case"job-timed-out":a(this);break;default:this._jobCompletionTimer=setTimeout(i,t)}}).catch(e=>{a(e)})};this._jobCompletionTimer=setTimeout(i,t)})}clearCancelJobTimer(){clearTimeout(this._cancelJobTimer),this._cancelJobTimer=void 0}clearJobCompletionTimer(){clearTimeout(this._jobCompletionTimer),this._jobCompletionTimer=void 0}};(0,u.Cg)([(0,h.MZ)()],L.prototype,"jobId",void 0),(0,u.Cg)([(0,A.e)($,{ignoreUnknown:!1})],L.prototype,"jobStatus",void 0),(0,u.Cg)([(0,h.MZ)({type:[q.A]})],L.prototype,"messages",void 0),(0,u.Cg)([(0,h.MZ)()],L.prototype,"progress",void 0),(0,u.Cg)([(0,h.MZ)()],L.prototype,"requestOptions",void 0),(0,u.Cg)([(0,h.MZ)({json:{write:!0}})],L.prototype,"sourceUrl",void 0),L=N=(0,u.Cg)([(0,g.$)("esri.rest.support.JobInfo")],L);let U=class extends c.A{constructor(e){super(e),this.headerKeys=[],this.outSpatialReference=null,this.exceededTransferLimit=!1}};(0,u.Cg)([(0,h.MZ)()],U.prototype,"headerKeys",void 0),(0,u.Cg)([(0,h.MZ)()],U.prototype,"outSpatialReference",void 0),(0,u.Cg)([(0,h.MZ)()],U.prototype,"exceededTransferLimit",void 0),U=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphQueryResultHeader")],U);let z=class extends c.A{constructor(e){super(e),this.resultRows=[],this.resultHeader=new U}};(0,u.Cg)([(0,h.MZ)()],z.prototype,"resultRows",void 0),(0,u.Cg)([(0,h.MZ)()],z.prototype,"resultHeader",void 0),z=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphQueryResult")],z);let J=class extends c.A{constructor(e){super(e),this.resultRowsStream=new ReadableStream,this.resultHeader=new U}};(0,u.Cg)([(0,h.MZ)()],J.prototype,"resultRowsStream",void 0),(0,u.Cg)([(0,h.MZ)()],J.prototype,"resultHeader",void 0),J=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphQueryStreamingResult")],J);let K=class extends v.o{constructor(e){super(e),this.name=null,this.unique=null,this.ascending=!0,this.description="",this.fieldNames=[]}};(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],K.prototype,"name",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],K.prototype,"unique",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],K.prototype,"ascending",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],K.prototype,"description",void 0),(0,u.Cg)([(0,h.MZ)({type:[String],json:{write:!0}})],K.prototype,"fieldNames",void 0),K=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.FieldIndex")],K);let V=class extends v.o{constructor(e){super(e),this.name=null,this.alias=null,this.fieldType=null,this.geometryType=null,this.hasM=null,this.hasZ=null,this.nullable=null,this.editable=!0,this.required=!1,this.defaultVisibility=!0,this.systemMaintained=null,this.role="esriGraphPropertyUNSPECIFIED",this.defaultValue=null}};(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],V.prototype,"name",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],V.prototype,"alias",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],V.prototype,"fieldType",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],V.prototype,"geometryType",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],V.prototype,"hasM",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],V.prototype,"hasZ",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],V.prototype,"nullable",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],V.prototype,"editable",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],V.prototype,"required",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],V.prototype,"defaultVisibility",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],V.prototype,"systemMaintained",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],V.prototype,"role",void 0),(0,u.Cg)([(0,h.MZ)({json:{write:!0}})],V.prototype,"defaultValue",void 0),V=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphProperty")],V);let Q=class extends v.o{constructor(e){super(e),this.name=null,this.alias=null,this.role="Regular",this.strict=null,this.properties=[],this.fieldIndexes=[],this.type=null}};(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],Q.prototype,"name",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],Q.prototype,"alias",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],Q.prototype,"role",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],Q.prototype,"strict",void 0),(0,u.Cg)([(0,h.MZ)({type:[V],json:{write:!0}})],Q.prototype,"properties",void 0),(0,u.Cg)([(0,h.MZ)({type:[K],json:{write:!0}})],Q.prototype,"fieldIndexes",void 0),Q=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphObjectType")],Q);let B=class extends Q{constructor(e){super(e),this.type="entity"}};B=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.EntityType")],B);let H=class extends Q{constructor(e){super(e),this.endPoints=[],this.type="relationship"}};(0,u.Cg)([(0,h.MZ)({json:{write:!0}})],H.prototype,"endPoints",void 0),H=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.RelationshipType")],H);let W=class extends v.o{constructor(e){super(e),this.value=null,this.behavior=null}};(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],W.prototype,"value",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],W.prototype,"behavior",void 0),W=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.SourceTypeValueBehavior")],W);let Y=class extends v.o{constructor(e){super(e),this.timestamp=null,this.spatialReference=null,this.strict=null,this.objectIdField=null,this.globalIdField=null,this.arcgisManaged=null,this.identifierInfo=null,this.searchIndexes=[],this.entityTypes=[],this.relationshipTypes=[],this.metaEntityTypes=[],this.provenanceSourceTypeValues=[]}};(0,u.Cg)([(0,h.MZ)({type:Date,json:{type:Number,write:{writer:(e,t)=>{t.timestamp=e?.getTime()}}}})],Y.prototype,"timestamp",void 0),(0,u.Cg)([(0,h.MZ)({type:p.A,json:{write:!0}})],Y.prototype,"spatialReference",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],Y.prototype,"strict",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],Y.prototype,"objectIdField",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],Y.prototype,"globalIdField",void 0),(0,u.Cg)([(0,h.MZ)()],Y.prototype,"arcgisManaged",void 0),(0,u.Cg)([(0,h.MZ)()],Y.prototype,"identifierInfo",void 0),(0,u.Cg)([(0,h.MZ)()],Y.prototype,"searchIndexes",void 0),(0,u.Cg)([(0,h.MZ)({type:[B],json:{write:!0}})],Y.prototype,"entityTypes",void 0),(0,u.Cg)([(0,h.MZ)({type:[H],json:{write:!0}})],Y.prototype,"relationshipTypes",void 0),(0,u.Cg)([(0,h.MZ)({type:[B],json:{write:!0}})],Y.prototype,"metaEntityTypes",void 0),(0,u.Cg)([(0,h.MZ)({type:[W],json:{write:!0}})],Y.prototype,"provenanceSourceTypeValues",void 0),Y=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.DataModel")],Y);let X=class extends v.o{constructor(e){super(e),this.capabilities=[],this.supportsSearch=!1,this.supportedQueryFormats=[],this.allowGeometryUpdates=!1,this.searchMaxRecordCount=null,this.serviceCapabilities=null,this.maxRecordCount=null,this.description="",this.copyrightText="",this.units="",this.spatialReference=null,this.currentVersion=null,this.dateFieldsTimeReference=null,this.serviceItemId="",this.supportsDocuments=!1,this.dataEditingNotSupported=!1,this.schemaEditingNotSupported=!1,this.supportsProvenance=!1}};(0,u.Cg)([(0,h.MZ)({type:[String],json:{write:!0}})],X.prototype,"capabilities",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],X.prototype,"supportsSearch",void 0),(0,u.Cg)([(0,h.MZ)({type:[String],json:{write:!0}})],X.prototype,"supportedQueryFormats",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],X.prototype,"allowGeometryUpdates",void 0),(0,u.Cg)([(0,h.MZ)({type:Number,json:{write:!0}})],X.prototype,"searchMaxRecordCount",void 0),(0,u.Cg)([(0,h.MZ)({type:Object,json:{write:!0}})],X.prototype,"serviceCapabilities",void 0),(0,u.Cg)([(0,h.MZ)({type:Number,json:{write:!0}})],X.prototype,"maxRecordCount",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],X.prototype,"description",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],X.prototype,"copyrightText",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],X.prototype,"units",void 0),(0,u.Cg)([(0,h.MZ)({type:p.A,json:{write:!0}})],X.prototype,"spatialReference",void 0),(0,u.Cg)([(0,h.MZ)({type:Number,json:{write:!0}})],X.prototype,"currentVersion",void 0),(0,u.Cg)([(0,h.MZ)({type:Object,json:{write:!0}})],X.prototype,"dateFieldsTimeReference",void 0),(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],X.prototype,"serviceItemId",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],X.prototype,"supportsDocuments",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],X.prototype,"dataEditingNotSupported",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],X.prototype,"schemaEditingNotSupported",void 0),(0,u.Cg)([(0,h.MZ)({type:Boolean,json:{write:!0}})],X.prototype,"supportsProvenance",void 0),X=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.ServiceDefinition")],X);let ee=class extends v.o{constructor(e){super(e),this.url=null,this.dataModel=null,this.serviceDefinition=null}};function te(e,t,r){if(0!==e.error_code)throw new i.A(t,r,{errorCode:e.error_code,errorMessage:e.error_message})}function re(e){return e?.error_code?new i.A("knowledgeGraphService:server-or-decoding-error",e.error_message,{errorCode:e.error_code}):void 0}function ne(e,t,r,n=!1){const o=new r.ClientDataFetchRequestEncoder;o.deleteLater();for(const a of e){const e=oe(a,t,r,n);o.add_client_data_fetch_request_parameter(e)}o.encode();const a=o.get_encoding_result();return te(a.error,"knowledge-graph:fetchClientDataAtKeys-encoding-failed","Attempting to encode the fetchClientDataAtKeys failed"),structuredClone(a.get_byte_buffer())}function oe(e,t,r,n){const o=new r.ClientDataKey;o.deleteLater(),o.key_string=e;const a=new r.ClientDataFetchRequestParameter;a.deleteLater(),a.set_key(o);const i=t.get(e);return i&&!n&&(a.v_tag={v_tag:i.version}),a}(0,u.Cg)([(0,h.MZ)({type:String,json:{write:!0}})],ee.prototype,"url",void 0),(0,u.Cg)([(0,h.MZ)({type:Y,json:{write:!0}})],ee.prototype,"dataModel",void 0),(0,u.Cg)([(0,h.MZ)({type:X,json:{write:!0}})],ee.prototype,"serviceDefinition",void 0),ee=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.KnowledgeGraph")],ee);var ae=r(45724),ie=r(48526),se=r(86738),de=r(39829),le=r(82799);const pe={exclude:0,include:1};function ue(e,t){const r=new t.ArrayValue;return r.deleteLater(),e.forEach(e=>{r.add_value(ye(e,t))}),r}function ce(e,t){const r=new t.ObjectValue;r.deleteLater();for(const[n,o]of Object.entries(e))r.set_key_value(n,ye(o,t));return r}function he(e,t){if(e instanceof ie.A)return function(e,t){const r=new t.GeometryValue;r.deleteLater(),r.geometry_type=r.geometry_type=t.esriGeometryType.esriGeometryMultipoint,r.has_z=e.hasZ,r.has_m=e.hasM;const n=[],o=[];o[0]=e.points.length;let a=0;return e.points.forEach(e=>{e.forEach(e=>{n[a]=e,a++})}),r.coords=new Float64Array(n),r.lengths=new Uint32Array(o),r}(e,t);if(e instanceof se.A)return function(e,t){const r=new t.GeometryValue;r.deleteLater(),r.geometry_type=t.esriGeometryType.esriGeometryPoint,r.has_z=e.hasZ,r.has_m=e.hasM;const n=[],o=[];o[0]=1,n[0]=e.x,n[1]=e.y;let a=2;return e.hasZ&&(n[a]=e.z,a++),e.hasM&&(n[a]=e.m,a++),r.coords=new Float64Array(n),r.lengths=new Uint32Array(o),r}(e,t);if(e instanceof le.A||e instanceof de.A)return function(e,t){const r=new t.GeometryValue;r.deleteLater(),r.has_z=e.hasZ,r.has_m=e.hasM;const n=[],o=[];let a=[];e instanceof le.A?(r.geometry_type=t.esriGeometryType.esriGeometryPolyline,a=e.paths):e instanceof de.A&&(r.geometry_type=t.esriGeometryType.esriGeometryPolygon,a=e.rings);let i=0,s=0;return a.forEach(e=>{let t=0;e.forEach(e=>{t++,e.forEach(e=>{n[s]=e,s++})}),o[i]=t,i++}),r.coords=new Float64Array(n),r.lengths=new Uint32Array(o),r}(e,t);throw new i.A("knowledge-graph:unsupported-geometry","Only Point, Multipoint, Polyline, and Polygon geometry are supported by ArcGIS Knowledge",{geometry:e})}function ye(e,t){if(null==e)return"";if("object"!=typeof e)return e;if(e instanceof Date)return e;if(e instanceof l.A)return he(e,t);if(Array.isArray(e)){const r=new t.ArrayValue;return r.deleteLater(),e.forEach(e=>{r.add_value(ye(e,t))}),r}return ce(e,t)}var ge=r(35448);function fe(e,t){if(!e.typeName)throw new i.A("knowledge-graph:no-type-name","You must indicate the entity/relationship named object type to apply edits");if(!("originId"in e)){const r=new t.EntityValue;r.deleteLater(),r.type_name=e.typeName;for(const[n,o]of Object.entries(e.properties))r.set_key_value(n,be(o,t));return e.id&&r.set_id(e.id),r}if("originId"in e&&"destinationId"in e){const r=new t.RelationshipValue;r.deleteLater(),r.type_name=e.typeName;for(const[n,o]of Object.entries(e.properties))r.set_key_value(n,be(o,t));return e.id&&r.set_id(e.id),e.originId&&e.destinationId&&r.set_related_entity_ids(e.originId,e.destinationId),r}throw new i.A("knowledge-graph:applyEdits-encoding-failure","Could not determine the type of a named graph object passed to the encoder")}function we(e,t){const r=new t.GraphProperty;return r.deleteLater(),r.name=e.name,r.alias=e.alias??"",r.field_type={value:ge.r5[e.fieldType]},r.geometry_type={value:e.geometryType?ge.bV[e.geometryType]:ge.bV.esriGeometryNull},r.has_m=e.hasM??!1,r.has_z=e.hasZ??!1,r.nullable=e.nullable??!1,r.editable=e.editable,r.required=e.required,r.default_visibility=e.defaultVisibility,r.system_maintained=e.systemMaintained??!1,r.role={value:ge.ti[e.role]},r.default_value=be(e.defaultValue,t),r}function me(e,t){const r=new t.SearchIndexProperties;r.deleteLater();for(const t of e.propertyNames)r.add_search_property_name(t);return r}function _e(e,t,r){r.name=e.name,r.alias=e.alias??"",r.role={value:ge.Eq[e.role]},r.strict=e.strict;for(const n of e.properties){const e=we(n,t);r.add_property(e)}return r}function ve(e,t){return e.hasOwnProperty("alias")&&(t.alias=e.alias),t}function be(e,t){return null==e?null:"object"!=typeof e||e instanceof Date?e:e instanceof l.A?he(e,t):null}let Ce=class extends c.A{constructor(e){super(e),this.decoderError=null,this.resultsCount=0,this.results=[],this.updatedKnowledgeGraph=null}};(0,u.Cg)([(0,h.MZ)()],Ce.prototype,"decoderError",void 0),(0,u.Cg)([(0,h.MZ)()],Ce.prototype,"resultsCount",void 0),(0,u.Cg)([(0,h.MZ)()],Ce.prototype,"results",void 0),(0,u.Cg)([(0,h.MZ)()],Ce.prototype,"updatedKnowledgeGraph",void 0),Ce=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphDataModelOperationResult")],Ce);const Ae=Ce;let Ge=class extends Ae{constructor(e){super(e)}};Ge=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphAddFieldIndexResult")],Ge);const Me=Ge;let xe=class extends Ae{constructor(e){super(e),this.entityAddResultsCount=0,this.relationshipAddResultsCount=0,this.entityAddResults=[],this.relationshipAddResults=[]}};(0,u.Cg)([(0,h.MZ)()],xe.prototype,"entityAddResultsCount",void 0),(0,u.Cg)([(0,h.MZ)()],xe.prototype,"relationshipAddResultsCount",void 0),(0,u.Cg)([(0,h.MZ)()],xe.prototype,"entityAddResults",void 0),(0,u.Cg)([(0,h.MZ)()],xe.prototype,"relationshipAddResults",void 0),xe=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphAddNamedTypesResult")],xe);const Te=xe;let Pe=class extends Ae{constructor(e){super(e)}};Pe=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphAddPropertyResult")],Pe);const ke=Pe;let Se=class extends Ae{constructor(e){super(e)}};Se=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphDeleteFieldIndexResult")],Se);const Re=Se;let je=class extends Ae{constructor(e){super(e)}};je=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphDeleteNamedTypeResult")],je);const Ie=je;let De=class extends Ae{constructor(e){super(e)}};De=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphDeletePropertyResult")],De);const Ze=De;let Ee=class extends Ae{constructor(e){super(e)}};Ee=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphUpdateNamedTypesResult")],Ee);const Fe=Ee;let Ne=class extends Ae{constructor(e){super(e)}};Ne=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphUpdatePropertyResult")],Ne);const qe=Ne;let $e=class extends Ae{constructor(e){super(e)}};$e=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphUpdateSearchIndexResult")],$e);const Oe=$e;function Le(e,t){const r=[];for(let n=0;n<t;n++){const t=e.get_result_at(n);r.push({name:t.get_name(),error:re(t.get_error())})}return r}function Ue(e){const t=e.get_results_count(),r=e.get_entity_type_add_results_count(),n=e.get_relationship_type_add_results_count(),o=new Te({resultsCount:t,results:Le(e,t),decoderError:re(e.error),entityAddResultsCount:r,relationshipAddResultsCount:n});for(let t=0;t<r;t++){const r=e.get_entity_type_add_results_at(t),n=r.get_name(),a=r.get_error();o.entityAddResults.push({name:n,error:re(a)})}for(let t=0;t<n;t++){const r=e.get_relationship_type_add_results_at(t),n=r.get_name(),a=r.get_error();o.relationshipAddResults.push({name:n,error:re(a)})}return o}function ze(e){const t=e.get_results_count();return new Fe({resultsCount:t,results:Le(e,t),decoderError:re(e.error)})}function Je(e){const t=e.get_results_count();return new Ie({resultsCount:t,results:Le(e,t),decoderError:re(e.error)})}function Ke(e){const t=e.get_results_count();return new ke({resultsCount:t,results:Le(e,t),decoderError:re(e.error)})}function Ve(e){const t=e.get_results_count();return new Ze({resultsCount:t,results:Le(e,t),decoderError:re(e.error)})}function Qe(e){const t=e.get_results_count();return new qe({resultsCount:t,results:Le(e,t),decoderError:re(e.error)})}function Be(e){const t=e.get_results_count();return new Oe({resultsCount:t,results:Le(e,t),decoderError:re(e.error)})}function He(e){const t=e.get_results_count();return new Me({resultsCount:t,results:Le(e,t),decoderError:re(e.error)})}function We(e){const t=e.get_results_count();return new Re({resultsCount:t,results:Le(e,t),decoderError:re(e.error)})}var Ye=r(93637);let Xe=class extends c.A{constructor(e){super(e),this.name=null,this.supportedCategory="esriTypeUNSPECIFIED",this.analyzers=[],this.searchProperties=new Map}};(0,u.Cg)([(0,h.MZ)()],Xe.prototype,"name",void 0),(0,u.Cg)([(0,h.MZ)()],Xe.prototype,"supportedCategory",void 0),(0,u.Cg)([(0,h.MZ)()],Xe.prototype,"analyzers",void 0),(0,u.Cg)([(0,h.MZ)()],Xe.prototype,"searchProperties",void 0),Xe=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.SearchIndex")],Xe);let et=!1;function tt(e){return e.deleteLater(),new B(nt(e))}function rt(e){return e.deleteLater(),new K({name:e.name,unique:e.unique,ascending:e.ascending,description:e.description,fieldNames:dt(e.fields)})}function nt(e){return{name:e.name,alias:e.alias,role:(0,Ye.i7)(ge.Eq,e.role.value),strict:e.strict,properties:lt(e.properties),fieldIndexes:pt(e.field_indexes)}}function ot(e){return e.deleteLater(),new V({alias:e.alias,name:e.name,fieldType:(0,Ye.i7)(ge.r5,e.field_type.value)??void 0,geometryType:(0,Ye.i7)(ge.bV,e.geometry_type.value)??null,hasM:e.has_m,hasZ:e.has_z,nullable:e.nullable,editable:e.editable,required:e.required,defaultVisibility:e.default_visibility,systemMaintained:e.system_maintained,role:(0,Ye.i7)(ge.ti,e.role.value),defaultValue:e.default_value})}function at(e){e.deleteLater();const t=nt(e),r=[];for(let t=0;t<e.end_points.size();t++){const n=e.end_points.get(t);r.push({originEntityType:n.origin_entity_type,destinationEntityType:n.dest_entity_type})}return e.end_points.delete(),new H(Object.assign({endPoints:r},t))}function it(e){return new W({behavior:e.behavior,value:e.value})}function st(e){const t=[];for(let r=0;r<e.size();r++)t.push(tt(e.get(r)));return e.delete(),t}function dt(e){const t=[];for(let r=0;r<e.size();r++)t.push(e.get(r));return e.delete(),t}function lt(e){const t=[];for(let r=0;r<e.size();r++){const n=ot(e.get(r));"esriFieldTypeBigInteger"===n.fieldType&&(et=!0),t.push(n)}return e.delete(),t}function pt(e){const t=[];for(let r=0;r<e.size();r++)t.push(rt(e.get(r)));return e.delete(),t}function ut(e){const t=[];for(let r=0;r<e.size();r++)t.push(at(e.get(r)));return e.delete(),t}function ct(e){const t=[];for(let r=0;r<e.size();r++){const n=e.get(r);n.deleteLater(),t.push(it(n))}return e.delete(),t}function ht(e){const t=[];for(let r=0;r<e.size();r++){const n=new Xe,o=e.get(r);n.name=o.name,n.supportedCategory=(0,Ye.i7)(ge.nP,o.supported_category.value);const a=o.analyzers.size();for(let e=0;e<a;e++)n.analyzers.push({name:o.analyzers.get(e).name});o.analyzers.delete();for(let e=0;e<o.search_properties.keys().size();e++){const t=o.search_properties.keys().get(e),r=o.search_properties.get(t),a=[];for(let e=0;e<r.property_names.size();e++)a.push(r.property_names.get(e));n.searchProperties.set(t,{propertyNames:a})}t.push(n)}return e.delete(),t}var yt=r(25927),gt=(r(77901),r(40662)),ft=r(42095),wt=r(23150);function mt(e,t){const r={paths:[],hasM:!1,hasZ:!1},n=_t(e,r),{coords:o,geometry_type:a,lengths:s}=e;if(a.value!==t)throw new i.A("KnowledgeGraph:illegal-geometry-type","Illegal Geometry type for multipath conversion");let d=0;return s.forEach(e=>{const t=[];for(let r=0;r<e;r++){const e=[];for(let t=0;t<n;t++)e[t]=o[d],d++;t.push(e)}r.paths.push(t)}),r}function _t(e,t){let r=2;return e.has_z?(t.hasZ=e.has_z,r++):t.hasZ=!1,e.has_m?(t.hasM=e.has_m,r++):t.hasM=!1,r}const vt=()=>s.A.getLogger("esri.rest.knowledgeGraph.WasmToQueryResponseObjConstructors");function bt(e,t,r){return((e,t,r)=>{if(null==e)return null;if("object"!=typeof e)return e;if("getDate"in e)return e;if("geometry_type"in e)switch(e.geometry_type.value){case null:return null;case 1:return function(e,t){const r={spatialReference:t};let n=2;_t(e,r);const o=e.coords;return r.x=o[0],r.y=o[1],e.has_z&&(r.z=o[n],n++),e.has_m&&(r.m=o[n]),new se.A(r)}(e,r);case 2:return function(e,t){const r={spatialReference:t},n=_t(e,r),o=e.lengths,a=e.coords,i=o[0];r.points=[];let s=0;for(let e=0;e<i;e++){const e=[];for(let t=0;t<n;t++)e[t]=a[s],s++;r.points.push(e)}return new ie.A(r)}(e,r);case 3:return function(e,t){const{paths:r,hasM:n,hasZ:o}=mt(e,3);return new le.A({paths:r,hasM:n,hasZ:o,spatialReference:t})}(e,r);case 4:return function(e,t){const{paths:r,hasM:n,hasZ:o}=mt(e,4);return new de.A({rings:r,hasM:n,hasZ:o,spatialReference:t})}(e,r);case 5:case 7:return vt().warnOnce("Envelope and Multipatch are not supported on knowledge entities, but one of those geometry types was detected. Result interpreted as null"),null;default:return vt().warnOnce("Unknown or blank geometry type returned - Result interpreted as null"),null}else{if(!("object_value_type"in e))return vt().warnOnce("A decoded value came back of a type that is not supported. Result interpreted as null"),null;switch(e.object_value_type.value){case 0:return function(e,t,r){return new gt.A(At(e,t,r))}(e,t,r);case 1:return Ct(e,t,r);case 2:return Gt(e,t,r);case 3:return function(e,t,r){const n=e.entity_count(),o=e.relationship_count(),a=[];for(let i=0;i<n;i++)a.push(Ct(e.get_entity_at(i),t,r)),i<o&&a.push(Gt(e.get_relationship_at(i),t,r));return new ft.A({path:a})}(e,t,r);case 4:return function(e,t,r){const n=[],o=e.count();for(let a=0;a<o;a++){const o=e.get_value_at(a);n.push(bt(o,t,r))}return n}(e,t,r);default:return vt().warnOnce("Unknown graph object type detected! Result interpreted as null"),null}}})(e,t,r)}function Ct(e,t,r){const n=e.type_name,o=At(e,t,r),a=e.get_id();return new yt.A(Object.assign({typeName:n,id:a},o))}function At(e,t,r){const n={},o=e.key_count();for(let a=0;a<o;a++)n[e.get_key_at(a)]=bt(e.get_value_at(a),t,r);return{properties:n}}function Gt(e,t,r){const n=e.type_name,o=At(e,t,r);return new wt.A(Object.assign({typeName:n,id:e.get_id(),originId:e.get_origin_entity_id(),destinationId:e.get_destination_entity_id()},o))}function Mt(e){const t=[];for(let r=0;r<e.get_header_keys().size();r++)t.push(e.get_header_keys().get(r));const r=new p.A(e.get_out_sr());return new U({headerKeys:t,outSpatialReference:r,exceededTransferLimit:e.exceeded_transfer_limit()})}let xt=class extends c.A{constructor(e){super(e),this.hasError=!1,this.error=null,this.editResults=[],this.cascadeRelationshipDeleteResults=[],this.cascadeProvenanceDeleteResults=[]}};(0,u.Cg)([(0,h.MZ)()],xt.prototype,"hasError",void 0),(0,u.Cg)([(0,h.MZ)()],xt.prototype,"error",void 0),(0,u.Cg)([(0,h.MZ)()],xt.prototype,"editResults",void 0),(0,u.Cg)([(0,h.MZ)()],xt.prototype,"cascadeRelationshipDeleteResults",void 0),(0,u.Cg)([(0,h.MZ)()],xt.prototype,"cascadeProvenanceDeleteResults",void 0),xt=(0,u.Cg)([(0,g.$)("esri.rest.knowledgeGraph.GraphApplyEditsResult")],xt);const Tt=xt;function Pt(e){const t=e.has_error(),r=new Tt({hasError:t,error:t?re(e.error):null}),n=e.get_edit_results_count();for(let t=0;t<n;t++){const n=e.get_edit_results_at(t);n.deleteLater();const o=e.get_edit_results_type_name_at(t),a=[],i=[],s=[],d=n.get_add_results_count(),l=n.get_update_results_count(),p=n.get_delete_results_count();for(let e=0;e<d;e++){const t=n.get_add_result_at(e);t.deleteLater(),a.push({id:t.id,error:re(t.error)})}for(let e=0;e<l;e++){const t=n.get_update_result_at(e);t.deleteLater(),i.push({id:t.id,error:re(t.error)})}for(let e=0;e<p;e++){const t=n.get_delete_result_at(e);t.deleteLater(),s.push({id:t.id,error:re(t.error)})}r.editResults.push({typeName:o,adds:a,updates:i,deletes:s})}const o=e.get_cascaded_rel_deletes_count();for(let t=0;t<o;t++){const n=e.get_cascaded_rel_deletes_at(t);n.deleteLater();const o=e.get_cascaded_rel_deletes_type_name_at(t),a=[];for(let e=0;e<n.get_count();e++){const t=n.get_result_at(e);t.deleteLater(),a.push({id:t.id,originId:t.origin_id,destinationId:t.dest_id,error:re(t.error)})}r.cascadeRelationshipDeleteResults.push({typeName:o,cascadeRelationshipDeletes:a})}if(e.has_cascading_provenance_deletes()){const t=e.get_cascading_provenance_deletes();t.deleteLater();const n=t.get_count();for(let e=0;e<n;e++){const n=t.get_result_at(e);n.deleteLater(),r.cascadeProvenanceDeleteResults.push({id:n.id,error:re(n.error)})}}return r}const kt=new Map,St=()=>new Map(kt.entries()),Rt={fetchKnowledgeGraph:async e=>{const t=new ee({url:e}),r=[];return r.push(Bt(t)),r.push(Ht(t)),await Promise.all(r),t},refreshDataModel:async e=>{e.dataModel=await cr(e)},refreshServiceDefinition:async e=>{const t=(await(0,a.A)(e.url,{query:{f:"json"}})).data;return t.capabilities=t?.capabilities?.split(","),t.supportedQueryFormats=t?.supportedQueryFormats?.split(","),e.serviceDefinition=new X(t),e.serviceDefinition},executeFindPathsAsynchronous:async(e,t)=>{const r=e.inKnowledgeGraphUrl.split("/rest/services");if(r.length<2)throw new i.A("knowledge-graph:invalid-tool-url","The URL for the KG Service was not correctly formatted. It should contain /rest/services/");const n=r[0],o=(await nr(`${n}/rest/info`,{query:{f:"json"}})).data.currentVersion,a=`/rest/services/${o&&o<12?"System":"Utilities"}/KnowledgeGraphServerToolsAsync/GPServer/ServerFilteredFindPaths`;return await rr(`${n}${a}`,{in_knowledge_graph_url:e.inKnowledgeGraphUrl,config_type:"STRING",config_string:e.config.toJSON(),result_type:"STRING"},{},t)},executeFindPaths:async(e,t)=>{const r=e.inKnowledgeGraphUrl.split("/rest/services");if(r.length<2)throw new i.A("knowledge-graph:invalid-tool-url","The URL for the KG Service was not correctly formatted. It should contain /rest/services/");const n=r[0],o=(await nr(`${n}/rest/info`,{query:{f:"json"}})).data.currentVersion,a=`/rest/services/${o&&o<12?"System":"Utilities"}/KnowledgeGraphServerTools/GPServer/ServerFilteredFindPaths/execute`,s=await nr(`${n}${a}`,{method:"post",query:{f:"pjson",in_knowledge_graph_url:e.inKnowledgeGraphUrl,config_type:"STRING",config_string:JSON.stringify(e.config),result_type:"STRING"},...t});if(s.data.results.length<1)throw new i.A("knowledge-graph:no-results","No results were returned from the FindPaths tool - no results returned",s);let d;for(const e of s.data.results)if("out_results_string"===e.paramName){d=e.value;break}if(!d)throw new i.A("knowledge-graph:no-results","No results were returned from the FindPaths tool - no results were returned on the expected paramater out_results_string",s);return d},fetchAsynchronousFindPathsResultData:async(e,t)=>(await e.fetchResultData("out_results_string",null,t)).value,executeQueryStreaming:async(e,t,r)=>{const n=`${e.url}/graph/query`;await or(e);const o=await ir(n,r);if(!e.serviceDefinition?.supportsProvenance&&"include"===t.provenanceBehavior)throw new i.A("knowledge-graph:provenance-not-supported","The Knowledge Graph Service definition indicated that provenance is not supported");o.data.body=await async function(e,t){const r=await(0,ae.I)(),n=new r.GraphQueryRequestEncoder;if(n.deleteLater(),e.outputSpatialReference?n.output_spatial_reference={wkid:e.outputSpatialReference.wkid,latestWkid:e.outputSpatialReference.latestWkid,vcsWkid:e.outputSpatialReference.vcsWkid,latestVcsWkid:e.outputSpatialReference.latestVcsWkid,wkt:e.outputSpatialReference.wkt??""}:n.output_spatial_reference=r.SpatialReferenceUtil.WGS84(),n.open_cypher_query=e.openCypherQuery,e.bindParameters)for(const[t,o]of Object.entries(e.bindParameters))ar(t,o,n,r);if(e.bindGeometryQuantizationParameters)!function(e,t){t.input_quantization_parameters={xy_resolution:e.xyResolution,x_false_origin:e.xFalseOrigin,y_false_origin:e.yFalseOrigin,z_resolution:e.zResolution,z_false_origin:e.zFalseOrigin,m_resolution:e.mResolution,m_false_origin:e.mFalseOrigin}}(e.bindGeometryQuantizationParameters,n);else{if(t.dataModel||await Bt(t),4326!==t.dataModel?.spatialReference?.wkid)throw new i.A("knowledge-graph:SR-quantization-mismatch","If the DataModel indicates a coordinate system other than WGS84, inputQuantizationParameters must be provided to the query encoder");n.input_quantization_parameters=r.InputQuantizationUtil.WGS84_lossless()}e.outputQuantizationParameters&&function(e,t,r){if(!e.extent)throw new i.A("knowledge-graph:illegal-output-quantization","The Output quantization provided to the encoder had an illegal value as part of its extent",e.extent);if(!e.quantizeMode)throw new i.A("knowledge-graph:illegal-output-quantization","The Output quantization contained an illegal mode setting",e.quantizeMode);if(!e.tolerance)throw new i.A("knowledge-graph:illegal-output-quantization","The Output quantization contained an illegal tolerance setting",e.quantizeMode);t.output_quantization_parameters={extent:{xmax:e.extent.xmax,ymax:e.extent.ymax,xmin:e.extent.xmin,ymin:e.extent.ymin},quantize_mode:r.esriQuantizeMode[e.quantizeMode],tolerance:e.tolerance}}(e.outputQuantizationParameters,n,r),e.provenanceBehavior&&function(e,t){t.provenance_behavior={value:pe[e]}}(e.provenanceBehavior,n);try{n.encode()}catch(e){throw new i.A("knowledge-graph:query-encoding-failed","Attempting to encode the query failed",{error:e})}const o=n.get_encoding_result();if(0!==o.error.error_code)throw new i.A("knowledge-graph:query-encoding-failed","Attempting to encode the query failed",{errorCode:o.error.error_code,errorMessage:o.error.error_message});return structuredClone(o.get_byte_buffer())}(t,e);const a=await tr(o.data.url,o.data);if(e.dataModel){const t=await ur(a,e.dataModel);return new J({resultRowsStream:t.readableStream,resultHeader:t.resultHeader})}throw new i.A("knowledge-graph:undefined-data-model","The KnowledgeGraph supplied did not have a data model")},executeApplyEdits:async(e,t,r)=>{if(e.serviceDefinition?.dataEditingNotSupported)throw new i.A("knowledge-graph:data-editing-not-supported","The Knowledge Graph Service definition indicated that data editing is not supported");const n=`${e.url}/graph/applyEdits`;await or(e);const o=await ir(n,r);return o.data.body=await async function(e,t){if(t.dataModel||await Bt(t),!t.dataModel)throw new i.A("knowledge-graph:data-model-undefined","Encoding could not proceed because a data model was not provided and it could not be determined from the service");const r=await(0,ae.I)(),n=!!e.options?.cascadeDelete,o=!!e.options?.cascadeProvenanceDelete,a=new r.GraphApplyEditsEncoder(r.SpatialReferenceUtil.WGS84(),e.options?.inputQuantizationParameters?function(e){return{xy_resolution:e.xyResolution,x_false_origin:e.xFalseOrigin,y_false_origin:e.yFalseOrigin,z_resolution:e.zResolution,z_false_origin:e.zFalseOrigin,m_resolution:e.mResolution,m_false_origin:e.mFalseOrigin}}(e.options?.inputQuantizationParameters):r.InputQuantizationUtil.WGS84_lossless());a.deleteLater(),a.cascade_delete=n,a.cascade_delete_provenance=o;try{let t;e.entityAdds?.forEach(e=>{t=a.add_entity(fe(e,r)),te(t,"knowledge-graph:applyEdits-encoding-failed","Attempting to encode the applyEdits - an entity failed to be added to the encoder")}),e.relationshipAdds?.forEach(e=>{if(!e.originId||!e.destinationId)throw new i.A("knowledge-graph:relationship-origin-destination-missing","When adding a new relationship, you must provide both an origin and destination id on the appropriate class property");t=a.add_relationship(fe(e,r)),te(t,"knowledge-graph:applyEdits-encoding-failed","Attempting to encode the applyEdits - a relationship failed to be added to the encoder")}),e.entityUpdates?.forEach(e=>{if(!e.id)throw new i.A("knowledge-graph:entity-id-missing","When updating an entity or relationship, you must specify the id on the class level property");t=a.update_entity(fe(e,r)),te(t,"knowledge-graph:applyEdits-encoding-failed","Attempting to encode the applyEdits - an entity failed to be added to the encoder")}),e.relationshipUpdates?.forEach(e=>{if(!e.id)throw new i.A("knowledge-graph:relationship-id-missing","When updating an entity or relationship, you must specify the id on the class level property");t=a.update_relationship(fe(e,r)),te(t,"knowledge-graph:applyEdits-encoding-failed","Attempting to encode the applyEdits - a relationship failed to be added to the encoder")}),e.entityDeletes?.forEach(e=>{if(!e.typeName)throw new i.A("knowledge-graph:no-type-name","You must indicate the entity/relationship named object type to apply edits - delete");const t=a.make_delete_helper(e.typeName,!0);t.deleteLater(),e.ids?.forEach(e=>{t.delete_by_id(e)})}),e.relationshipDeletes?.forEach(e=>{if(!e.typeName)throw new i.A("knowledge-graph:no-type-name","You must indicate the entity/relationship named object type to apply edits - delete");const t=a.make_delete_helper(e.typeName,!1);e.ids?.forEach(e=>{t.delete_by_id(e)})}),a.encode()}catch(e){throw new i.A("knowledge-graph:applyEdits-encoding-failed","Attempting to encode the applyEdits failed",{error:e})}const s=a.get_encoding_result();return te(s.error,"knowledge-graph:applyEdits-encoding-failed","Attempting to encode the applyEdits failed"),structuredClone(s.get_byte_buffer())}(t,e),async function(e){return sr(e,(await(0,ae.I)()).GraphApplyEditsDecoder,Pt)}(await tr(o.data.url,o.data))},executeAddNamedTypes:async(e,t,r)=>{if(!t.newEntityTypes?.length&&!t.newRelationshipTypes?.length)throw new i.A("knowledge-graph:no-arguments","The operation to add types to the data model contained no values");const n=`${e.url}/dataModel/edit/namedTypes/add`;await or(e);const o=await ir(n,r);o.data.body=await async function(e){const t=await(0,ae.I)(),r=new t.GraphNamedObjectTypeAddsRequestEncoder;r.deleteLater(),e.newEntityTypes?.forEach(e=>{r.add_entity_type(function(e,t){const r=new t.EntityType;return r.deleteLater(),_e(e,t,r)}(e,t))}),e.newRelationshipTypes?.forEach(e=>{r.add_relationship_type(function(e,t){const r=new t.RelationshipType;r.deleteLater();for(const n of e.endPoints){const e=new t.EndPoint;e.deleteLater(),e.origin_entity_type=n.originEntityType,e.dest_entity_type=n.destinationEntityType,r.add_end_point(e)}return _e(e,t,r)}(e,t))});try{r.encode()}catch(e){throw new i.A("knowledge-graph:addNamedTypes-encoding-failed","Attempting to encode the addNamedTypes failed",{error:e})}const n=r.get_encoding_result();return te(n.error,"knowledge-graph:addNamedTypes-encoding-failed","Attempting to encode the addNamedTypes failed"),structuredClone(n.get_byte_buffer())}(t);const a=await tr(o.data.url,o.data),s=await async function(e){return sr(e,(await(0,ae.I)()).GraphNamedObjectTypeAddsResponseDecoder,Ue)}(a);return s.updatedKnowledgeGraph=await Qt(e.url),s},executeDeleteNamedType:async(e,t,r)=>{if(!t)throw new i.A("knowledge-graph:no-arguments","The operation to delete a named type from the data model contained no value");const n=`${e.url}/dataModel/edit/namedTypes/${t}/delete`;await or(e);const o=await ir(n,r);o.data.body="";const a=await tr(o.data.url,o.data),s=await async function(e){return sr(e,(await(0,ae.I)()).GraphNamedObjectTypeDeleteResponseDecoder,Je)}(a);return s.updatedKnowledgeGraph=await Qt(e.url),s},executeUpdateNamedType:async(e,t,r,n)=>{if(!t&&!Object.keys(r).length)throw new i.A("knowledge-graph:no-arguments","The operation to update types in the data model contained missing or empty values");const o=`${e.url}/dataModel/edit/namedTypes/${t}/update`;await or(e);const a=await ir(o,n);a.data.body=await async function(e,t,r){const n=await(0,ae.I)(),o=new n.GraphNamedObjectTypeUpdateRequestEncoder;if(o.deleteLater(),r.entityTypes.some(e=>e.name===t))o.update_entity_type(function(e,t){const r=new t.EntityType;return r.deleteLater(),ve(e,r)}(e,n));else{if(!r.relationshipTypes.some(e=>e.name===t))throw new i.A("knowledge-graph:updateNamedType-encoding-failed","The named type you are trying to update does not exist in the data model");o.update_relationship_type(function(e,t){const r=new t.RelationshipType;return r.deleteLater(),ve(e,r)}(e,n))}o.update_alias=e.hasOwnProperty("alias");try{o.encode()}catch(e){throw new i.A("knowledge-graph:updateNamedType-encoding-failed","Attempting to encode the updateNamedType failed",{error:e})}const a=o.get_encoding_result();return te(a.error,"knowledge-graph:updateNamedType-encoding-failed","Attempting to encode the updateNamedType failed"),structuredClone(a.get_byte_buffer())}(r,t,e.dataModel);const s=await tr(a.data.url,a.data),d=await async function(e){return sr(e,(await(0,ae.I)()).GraphNamedObjectTypeUpdateResponseDecoder,ze)}(s);return d.updatedKnowledgeGraph=await Qt(e.url),d},executeAddGraphProperties:async(e,t,r,n)=>{if(!t&&!r.length)throw new i.A("knowledge-graph:no-arguments","The operation to add properties to the data model contained missing or empty values");const o=`${e.url}/dataModel/edit/namedTypes/${t}/fields/add`;await or(e);const a=await ir(o,n);a.data.body=await async function(e){const t=await(0,ae.I)(),r=new t.GraphPropertyAddsRequestEncoder;r.deleteLater(),e.forEach(e=>{r.add_graph_property(we(e,t))});try{r.encode()}catch(e){throw new i.A("knowledge-graph:addGraphProperties-encoding-failed","Attempting to encode the addGraphProperties failed",{error:e})}const n=r.get_encoding_result();return te(n.error,"knowledge-graph:addGraphProperties-encoding-failed","Attempting to encode the addGraphProperties failed"),structuredClone(n.get_byte_buffer())}(r);const s=await tr(a.data.url,a.data),d=await async function(e){return sr(e,(await(0,ae.I)()).GraphPropertyAddsResponseDecoder,Ke)}(s);return d.updatedKnowledgeGraph=await Qt(e.url),d},executeDeleteGraphProperty:async(e,t,r,n)=>{if(!t&&!r)throw new i.A("knowledge-graph:no-arguments","The operation to delete property contained missing or empty values");const o=`${e.url}/dataModel/edit/namedTypes/${t}/fields/delete`;await or(e);const a=await ir(o,n);a.data.body=await async function(e){const t=new((await(0,ae.I)()).GraphPropertyDeleteRequestEncoder);t.deleteLater(),t.field_name=e;try{t.encode()}catch(e){throw new i.A("knowledge-graph:deleteGraphProperty-encoding-failed","Attempting to encode the deleteGraphProperty failed",{error:e})}const r=t.get_encoding_result();return te(r.error,"knowledge-graph:deleteGraphProperty-encoding-failed","Attempting to encode the deleteGraphProperty failed"),structuredClone(r.get_byte_buffer())}(r);const s=await tr(a.data.url,a.data),d=await async function(e){return sr(e,(await(0,ae.I)()).GraphPropertyDeleteResponseDecoder,Ve)}(s);return d.updatedKnowledgeGraph=await Qt(e.url),d},executeUpdateGraphProperty:async(e,t,r,n,o)=>{if(!t&&!r&&!Object.keys(n).length)throw new i.A("knowledge-graph:no-arguments","The operation to update properties in the data model contained missing or empty values");const a=`${e.url}/dataModel/edit/namedTypes/${t}/fields/update`;await or(e);const s=await ir(a,o);s.data.body=await async function(e,t){const r=await(0,ae.I)(),n=new r.GraphPropertyUpdateRequestEncoder;n.deleteLater(),n.update_graph_property(function(e,t){const r=new t.GraphProperty;return r.deleteLater(),e.hasOwnProperty("alias")&&(r.alias=e.alias),e.hasOwnProperty("editable")&&(r.editable=e.editable),e.hasOwnProperty("required")&&(r.required=e.required),e.hasOwnProperty("defaultVisibility")&&(r.default_visibility=e.defaultVisibility),e.hasOwnProperty("defaultValue")&&(r.default_value=be(e.defaultValue,t)),r}(t,r)),n.set_property_name(e),n.update_alias=t.hasOwnProperty("alias"),n.update_editable=t.hasOwnProperty("editable"),n.update_required=t.hasOwnProperty("required"),n.update_visible=t.hasOwnProperty("defaultVisibility"),n.update_default_value=t.hasOwnProperty("defaultValue");try{n.encode()}catch(e){throw new i.A("knowledge-graph:updateGraphProperty-encoding-failed","Attempting to encode the updateGraphProperty failed",{error:e})}const o=n.get_encoding_result();return te(o.error,"knowledge-graph:updateGraphProperty-encoding-failed","Attempting to encode the updateGraphProperty failed"),structuredClone(o.get_byte_buffer())}(r,n);const d=await tr(s.data.url,s.data),l=await async function(e){return sr(e,(await(0,ae.I)()).GraphPropertyUpdateResponseDecoder,Qe)}(d);return l.updatedKnowledgeGraph=await Qt(e.url),l},executeAddGraphFieldIndex:async(e,t,r,n)=>{if(!t)throw new i.A("knowledge-graph:no-arguments","The operation to update search index in the data model contained missing named type");if(!r?.length)throw new i.A("knowledge-graph:no-arguments","The operation to update search index in the data model contained missing or empty field index values");const o=`${e.url}/dataModel/edit/namedTypes/${t}/indexes/add`;await or(e);const a=await ir(o,n);a.data.body=await async function(e){const t=await(0,ae.I)(),r=new t.GraphIndexAddsRequestEncoder;r.deleteLater(),e.forEach(e=>{r.add_field_index(function(e,t){const r=new t.FieldIndex;r.deleteLater(),r.name=e.name,r.unique=e.unique,r.ascending=e.ascending,r.description=e.description??"";for(const t of e.fieldNames)r.add_field(t);return r}(e,t))});try{r.encode()}catch(e){throw new i.A("knowledge-graph:addGraphFieldIndex-encoding-failed","Attempting to encode the addGraphFieldIndex failed",{error:e})}const n=r.get_encoding_result();return te(n.error,"knowledge-graph:addGraphFieldIndex-encoding-failed","Attempting to encode the addGraphFieldIndex failed"),structuredClone(n.get_byte_buffer())}(r);const s=await tr(a.data.url,a.data),d=await async function(e){return sr(e,(await(0,ae.I)()).GraphIndexAddsResponseDecoder,He)}(s);return d.updatedKnowledgeGraph=await Qt(e.url),d},executeDeleteGraphFieldIndex:async(e,t,r,n)=>{if(!t)throw new i.A("knowledge-graph:no-arguments","The operation to update search index in the data model contained missing named type");if(!r?.length)throw new i.A("knowledge-graph:no-arguments","The operation to update search index in the data model contained missing or empty field index values");const o=`${e.url}/dataModel/edit/namedTypes/${t}/indexes/delete`;await or(e);const a=await ir(o,n);a.data.body=await async function(e){const t=new((await(0,ae.I)()).GraphIndexDeleteRequestEncoder);t.deleteLater(),e.forEach(e=>{t.add_index_name(e)});try{t.encode()}catch(e){throw new i.A("knowledge-graph:deleteGraphFieldIndex-encoding-failed","Attempting to encode the deleteGraphFieldIndex failed",{error:e})}const r=t.get_encoding_result();return te(r.error,"knowledge-graph:deleteGraphFieldIndex-encoding-failed","Attempting to encode the deleteGraphFieldIndex failed"),structuredClone(r.get_byte_buffer())}(r);const s=await tr(a.data.url,a.data),d=await async function(e){return sr(e,(await(0,ae.I)()).GraphIndexDeleteResponseDecoder,We)}(s);return d.updatedKnowledgeGraph=await Qt(e.url),d},executeUpdateSearchIndex:async(e,t,r,n)=>{if(!t)throw new i.A("knowledge-graph:no-arguments","The operation to update search index in the data model contained missing named type");if(!Object.keys(r.addSearchProperties??{}).length&&!Object.keys(r.removeSearchProperties??{}).length)throw new i.A("knowledge-graph:no-arguments","The operation to update search index in the data model contained missing or empty properties values");const o=`${e.url}/dataModel/searchIndex/update`;await or(e);const a=await ir(o,n);a.data.body=await async function(e,t){const r=await(0,ae.I)(),n=new r.GraphUpdateSearchIndexRequestEncoder;n.deleteLater(),t.hasOwnProperty("addSearchProperties")&&n.insert_add_search_property(e,me(t.addSearchProperties,r)),t.hasOwnProperty("removeSearchProperties")&&n.insert_delete_search_property(e,me(t.removeSearchProperties,r));try{n.encode()}catch(e){throw new i.A("knowledge-graph:updateSearchIndex-encoding-failed","Attempting to encode the updateSearchIndex failed",{error:e})}const o=n.get_encoding_result();return te(o.error,"knowledge-graph:updateSearchIndex-encoding-failed","Attempting to encode the updateSearchIndex failed"),structuredClone(o.get_byte_buffer())}(t,r);const s=await tr(a.data.url,a.data),d=await async function(e){return sr(e,(await(0,ae.I)()).GraphUpdateSearchIndexResponseDecoder,Be)}(s);return d.updatedKnowledgeGraph=await Qt(e.url),d},executeQuery:async(e,t,r)=>{const n=`${e.url}/graph/query`,o=await(0,a.A)(n,{responseType:"array-buffer",query:{f:"pbf",openCypherQuery:t.openCypherQuery,...r?.query},signal:r?.signal,timeout:r?.timeout}),s=o.getHeader?.("content-type"),d=o.data;if(s?.includes("application/x-protobuf")){const t=new((await(0,ae.I)()).GraphQueryDecoder);if(t.deleteLater(),e.dataModel){const r=pr({wasmQueryDecoder:t,newArrayBufferToParse:d,dataModel:e.dataModel});return new z({resultRows:r.resultRows,resultHeader:r.resultHeader})}throw new i.A("knowledge-graph:undefined-data-model","The KnowledgeGraph supplied did not have a data model")}throw new i.A("knowledge-graph:unexpected-server-response","server returned an unexpected response",{responseType:s,data:o.data})},executeSearch:async(e,t,r)=>{const n="provenance"===t.typeCategoryFilter?"metaEntityProvenance":t.typeCategoryFilter,o=`${e.url}/graph/search`,s=await(0,a.A)(o,{responseType:"array-buffer",query:{f:"pbf",searchQuery:`"${t.searchQuery}"`,typeCategoryFilter:n,...r?.query},signal:r?.signal,timeout:r?.timeout}),d=s.getHeader?.("content-type"),l=s.data;if(d?.includes("application/x-protobuf")){const t=new((await(0,ae.I)()).GraphQueryDecoder);if(t.deleteLater(),e.dataModel){const r=pr({wasmQueryDecoder:t,newArrayBufferToParse:l,dataModel:e.dataModel});return new z({resultRows:r.resultRows,resultHeader:r.resultHeader})}throw new i.A("knowledge-graph:undefined-data-model","The KnowledgeGraph supplied did not have a data model")}throw new i.A("knowledge-graph:unexpected-server-response","server returned an unexpected response",{responseType:d,data:s.data})},executeSearchStreaming:async(e,t,r)=>{const n=`${e.url}/graph/search`;await or(e);const o=await ir(n,r);o.data.body=await async function(e){const t=await(0,ae.I)(),r=new t.GraphSearchRequestEncoder;r.deleteLater(),r.search_query=e.searchQuery;const n="provenance"===e.typeCategoryFilter?"meta_entity_provenance":e.typeCategoryFilter;if(r.type_category_filter=t.esriNamedTypeCategory[n],!0===e.returnSearchContext&&(r.return_search_context=e.returnSearchContext),null!=e.start&&e.start>0&&(r.start_index=e.start),null!=e.num&&(r.max_num_results=e.num),null!=e.idsFilter&&Array.isArray(e.idsFilter)&&e.idsFilter.length>0)try{r.set_ids_filter(ue(e.idsFilter,t))}catch(e){throw new i.A("knowledge-graph:ids-format-error","Attempting to set ids filter failed. This is usually caused by an incorrectly formatted UUID string",{error:e})}e.namedTypesFilter?.forEach(e=>{r.add_named_type_filter(e)});try{r.encode()}catch(e){throw new i.A("knowledge-graph:search-encoding-failed","Attempting to encode the search failed",{error:e})}const o=r.get_encoding_result();if(0!==o.error.error_code)throw new i.A("knowledge-graph:search-encoding-failed","Attempting to get encoding result from the query failed",{errorCode:o.error.error_code,errorMessage:o.error.error_message});return structuredClone(o.get_byte_buffer())}(t);const a=await tr(o.data.url,o.data);if(e.dataModel){const t=await ur(a,e.dataModel);return new J({resultRowsStream:t.readableStream,resultHeader:t.resultHeader})}throw new i.A("knowledge-graph:undefined-data-model","The KnowledgeGraph supplied did not have a data model")},fetchClientDataAtKeys:async(e,t,r={ignoreCache:!1})=>{if(!t.length)return new Map;let n=kt.get(e.url||"");n||(n=new Map,kt.set(e.url||"",n));const o=new Map(n.entries()),a=`${e.url}/clientData/fetch`;t=Array.from(new Set(t));const s=await(0,ae.I)(),d=ne(t,n,s,r.ignoreCache),l=await ir(a,r.requestOptions);l.data.body=d;const p=await tr(l.data.url,l.data),u=p.headers.get("content-type");if(u?.includes("application/x-protobuf")){const e=new s.ClientDataFetchResponseDecoder;e.deleteLater();const t=await p.arrayBuffer();return e.decode(new Uint8Array(t)),e.has_error()&&te(e.error,"knowledge-graph:fetchClientDataAtKeys-decoding-error","An error occurred while decoding the client data keys response"),function(e,t,r,n=!1){const o=new Map;for(let a=0;a<e.get_results_count();a++){const i=e.get_result_at(a);if(2!==i.get_fetch_result_case().value||0!==i.error().error_code){const e=i.get_key().key_string;r.has(e)&&t.delete(e);continue}const s=i.get_value(),d=i.get_key().key_string,l=r.get(d);let p;if(2===s.get_data_case().value&&l)p=l.value;else{if(1!==s.get_data_case().value)continue;{p=s.get_data().client_data_string;const e=i.get_value().get_v_tag().v_tag;n||t.set(d,{key:d,version:e,value:p})}}o.set(d,p)}return o}(e,n,o,r.ignoreCache)}throw new i.A("knowledge-graph:unexpected-server-response","server returned an unexpected response when fetching client data",{responseType:u,data:p})},fetchAllClientDataKeys:async(e,t)=>{const r=`${e.url}/clientData`,n=await(0,a.A)(r,{responseType:"array-buffer",query:{f:"pbf"},signal:t?.signal,timeout:t?.timeout}),o=n.getHeader?.("content-type"),s=n.data;if(o?.includes("application/x-protobuf")){const e=new((await(0,ae.I)()).ClientDataKeysResponseDecoder);return e.deleteLater(),e.decode(new Uint8Array(s)),e.has_error()&&te(e.error,"knowledge-graph:fetchAllClientDataKeys-decoding-error","An error occurred while decoding the client data keys response"),function(e){const t=e.get_keys(),r=new Array;for(let e=0;e<t.get_keys_count();e++){const n=t.get_key_at(e);1===n.get_client_data_key_type().value&&r.push(n.key_string)}return r}(e)}throw new i.A("knowledge-graph:unexpected-server-response","server returned an unexpected response",{responseType:o,data:n.data})},clearClientDataCache:()=>kt.clear(),_fetchWrapper:async(e,t)=>fetch(e,t),_submitJobWrapper:async(e,t,r,n)=>async function(e,t,r,n){return r=w.from(r||{}),async function(e,t,r,n,o){const i={},s={},d=[];return function(e,t,r){for(const n in e){const o=e[n];if(o&&"object"==typeof o&&o instanceof T.A){const{features:e}=o;r[n]=[t.length,t.length+e.length],e.forEach(e=>{t.push(e.geometry)})}}}(n,d,i),(0,m.el)(d).then(d=>{const{outSpatialReference:l,processExtent:p,processSpatialReference:u,returnColumnName:c,returnFeatureCollection:h,returnM:y,returnZ:g}=r,{path:f}=(0,C.Dl)(e);for(const e in i){const[t,r]=i[e];s[e]=d.slice(t,r)}const w=l?l.wkid||l:null,m=u?u.wkid||u:null,_="execute"===t?{returnColumnName:c||void 0,returnFeatureCollection:h||void 0,returnM:y||void 0,returnZ:g||void 0}:null,v=F({...p?{context:{extent:p,outSR:w,processSR:m}}:{"env:outSR":w,"env:processSR":m},...n,..._,f:"json"},null,s),b={...o,query:v};return(0,a.A)(`${f}/${t}`,b)})}(e,"submitJob",r,t??{},n).then(({data:t})=>{const r=L.fromJSON(t);return r.sourceUrl=e,r})}(e,t,r,n),_esriRequestWrapper:async(e,t)=>(0,a.A)(e,t)};async function jt(e,t,r){return Rt.executeApplyEdits(e,t,r)}async function It(e,t,r){return Rt.executeAddNamedTypes(e,t,r)}async function Dt(e,t,r){return Rt.executeDeleteNamedType(e,t,r)}async function Zt(e,t,r,n){return Rt.executeUpdateNamedType(e,t,r,n)}async function Et(e,t,r,n){return Rt.executeAddGraphProperties(e,t,r,n)}async function Ft(e,t,r,n){return Rt.executeDeleteGraphProperty(e,t,r,n)}async function Nt(e,t,r,n,o){return Rt.executeUpdateGraphProperty(e,t,r,n,o)}async function qt(e,t,r,n){return Rt.executeAddGraphFieldIndex(e,t,r,n)}async function $t(e,t,r,n){return Rt.executeDeleteGraphFieldIndex(e,t,r,n)}async function Ot(e,t,r,n){return Rt.executeUpdateSearchIndex(e,t,r,n)}async function Lt(e,t,r){return Rt.executeQuery(e,t,r)}async function Ut(e,t,r){return Rt.executeQueryStreaming(e,t,r)}async function zt(e,t,r){return Rt.executeSearch(e,t,r)}async function Jt(e,t,r){return Rt.executeSearchStreaming(e,t,r)}function Kt(e,t){return Rt.fetchAllClientDataKeys(e,t)}function Vt(e,t,r){return Rt.fetchClientDataAtKeys(e,t,r)}async function Qt(e){return Rt.fetchKnowledgeGraph(e)}async function Bt(e){return Rt.refreshDataModel(e)}async function Ht(e){return Rt.refreshServiceDefinition(e)}async function Wt(e,t){return Rt.executeFindPathsAsynchronous(e,t)}async function Yt(e,t){return Rt.executeFindPaths(e,t)}async function Xt(e,t){return Rt.fetchAsynchronousFindPathsResultData(e,t)}function er(){return Rt.clearClientDataCache()}async function tr(e,t){return Rt._fetchWrapper(e,t)}async function rr(e,t,r,n){return Rt._submitJobWrapper(e,t,r,n)}async function nr(e,t){return Rt._esriRequestWrapper(e,t)}async function or(e){const t=o.id?.findCredential(e.url);t||(e.dataModel?await cr(e):await Bt(e))}function ar(e,t,r,n){null==t?r.set_param_key_value(e,""):"object"!=typeof t||t instanceof Date?r.set_param_key_value(e,t):t instanceof l.A?r.set_param_key_value(e,he(t,n)):Array.isArray(t)?r.set_param_key_value(e,ue(t,n)):r.set_param_key_value(e,ce(t,n))}async function ir(e,t){return(0,a.A)(e,{responseType:"native-request-init",method:"post",query:{f:"pbf",...t?.query},body:"x",headers:{"Content-Type":"application/octet-stream"},signal:t?.signal,timeout:t?.timeout})}async function sr(e,t,r){const n=e.headers.get("content-type");if(n?.includes("application/x-protobuf")){const n=await e.arrayBuffer(),o=new t;try{return o.decode(new Uint8Array(n)),r(o)}finally{o.deleteLater()}}throw new i.A("knowledge-graph:unexpected-server-response","server returned an unexpected response",{responseType:n,data:await e.text()})}let dr=50;function lr(e){dr=e}function pr({wasmQueryDecoder:e,newArrayBufferToParse:t,dataModel:r,decodedHeader:n,limitMaxProcessingTime:o=!1}){t&&e.push_buffer(new Uint8Array(t));const a=[];let s,d,l=0;const u=Date.now();let c=!0;for(;e.next_row();){s&&d||(s=n??Mt(e),d=s.outSpatialReference??new p.A({wkid:4326})),l||(l=e.get_header_keys().size());const t=new Array(l);for(let n=0;n<l;n++){const o=e.get_value(n);t[n]=bt(o,r,d)}if(a.push(t),o&&Date.now()-u>dr){c=!1;break}}if(e.has_error())throw new i.A("knowledge-graph:stream-decoding-error","One or more result rows were not successfully decoded - inner row decoding",{errorCode:e.error.error_code,errorMessage:e.error.error_message});return{resultHeader:s,resultRows:a,parsedAllResultsFromBuffer:c}}async function ur(e,t){const r=e.headers.get("content-type");if(e.headers.get("content-length")&&s.A.getLogger("esri.rest.knowledgeGraph.knowledgeGraphService").warnOnce("Found `Content-Length` header when expecting a streaming HTTP response! Please investigate whether all intermediate HTTP proxies and/or load balancers are configured such that they don't forcefully buffer the entire response before returning it to the client. A valid HTTP streaming response should use Chunked Transfer Encoding and not have a Content Length defined."),r?.includes("application/x-protobuf")){const r=e.body?.getReader(),n=new((await(0,ae.I)()).GraphQueryDecoder);let o,a,l;n.deleteLater();const p=new Promise((e,t)=>{a=e,l=t});let u=!1,c=null;const h=new ReadableStream({pull:async function e(p){if(!r){const e=new i.A("knowledge-graph:stream-decoding-error","Error reading from stream - reader is undefined");throw l(e),e}const{done:h,value:y}=c?{done:!1,value:null}:await r.read().catch(e=>{throw l(e),r.releaseLock(),e});y&&(c=y);try{if(h){let e;if(n.has_error()?e=new i.A("knowledge-graph:stream-decoding-error","One or more result rows were not successfully decoded - query stream done",{errorCode:n.error.error_code,errorMessage:n.error.error_message}):u||a(new U),r.releaseLock(),e)throw p.error(e),l(e),e;return void p.close()}const{resultHeader:s,resultRows:d,parsedAllResultsFromBuffer:g}=pr({wasmQueryDecoder:n,newArrayBufferToParse:y,dataModel:t,decodedHeader:o,limitMaxProcessingTime:!0});return g&&(c=null),!o&&s&&(o=s,a(s),u=!0),d.length>0?void p.enqueue(d):await e(p)}catch(e){throw s.A.getLogger("esri.rest.knowledgeGraph.knowledgeGraphService").error(e),l(e),r.releaseLock(),(0,d.zf)(e)?e:new i.A("knowledge-graph:unexpected-server-response","Error inside streaming data return parsing",{error:e})}}});return{readableStream:h,resultHeader:await p}}throw new i.A("knowledge-graph:unexpected-server-response","server returned an unexpected response",{responseType:r,data:e.text()})}async function cr(e){const t=`${e.url}/dataModel/queryDataModel`,r=await(0,a.A)(t,{responseType:"array-buffer",query:{f:"pbf"}}),n=r.getHeader?.("content-type"),o=r.data;if(n?.includes("application/x-protobuf")){const e=(await(0,ae.I)()).decode_data_model_from_protocol_buffer(new Uint8Array(o));if(!e)throw new i.A("knowledge-graph:data-model-decode-failure","The server responded to the data model query, but the response failed to be decoded. This typically occurs when the Knowledge JS API (4.26 or later) is used with an unsupported backend (11.0 or earlier)");return function(e){e.deleteLater(),et=!1;const t=new Y({timestamp:e.timestamp,spatialReference:new p.A(e.spatial_reference),strict:e.strict,objectIdField:e.objectid_property,globalIdField:e.globalid_property,arcgisManaged:e.arcgis_managed,identifierInfo:{identifierMappingInfo:{identifierInfoType:(0,Ye.i7)(ge.vy,e.identifier_info?.identifier_mapping_info?.identifier_info_type?.value),databaseNativeIdentifier:e.identifier_info?.identifier_mapping_info?.database_native_identifier,uniformPropertyIdentifier:{identifierPropertyName:e.identifier_info?.identifier_mapping_info?.uniform_property_identifier?.identifier_property_name}},identifierGenerationInfo:{uuidMethodHint:(0,Ye.i7)(ge.wr,e.identifier_info?.identifier_generation_info?.uuid_method_hint?.value)}},searchIndexes:ht(e.search_indexes),entityTypes:st(e.entity_types),relationshipTypes:ut(e.relationship_types),metaEntityTypes:st(e.meta_entity_types),provenanceSourceTypeValues:ct(e.provenance_source_type_values.value_behavior_array)});return et&&s.A.getLogger("esri.rest.knowledgeGraph.knowledgeGraphService").warnOnce("A big integer field was detected in the retrieved data model. The `big-integer` field type is not fully supported in web clients. Please see https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-Field.html#type"),t}(e)}throw new i.A("knowledge-graph:unexpected-server-response","server returned an unexpected response",{responseType:n,data:r.data})}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3548,7548,7694],{4146:(e,t,r)=>{r.d(t,{A:()=>v});var i=r(31635),n=r(78888),s=r(49186),o=r(65529),a=r(4902),l=r(92474),u=r(53966),c=r(74887),d=r(84952),p=r(10107),h=(r(44208),r(87811),r(64108)),f=r(5443),y=r(16930),m=r(92602),g=r(79677);let w=0,v=class extends((0,o.Zt)((0,a.sA)(l.x_))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new f.A(-180,-90,180,90,y.A.WGS84),this.id=Date.now().toString(16)+"-layer-"+w++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.persistenceEnabled=!1,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=y.A.WGS84,this.title=null,this.type=null,this.url=null,this.visibilityTimeExtent=null,this.visible=!0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e;return(await Promise.all([r.e(812),r.e(7982)]).then(r.bind(r,27982))).fromUrl(t)}static fromPortalItem(e){return async function(e){const t="portalItem"in e?e:{portalItem:e},{fromItem:i}=await Promise.all([r.e(812),r.e(5613),r.e(5710)]).then(r.bind(r,45613));try{return await i(t)}catch(e){const r=t?.portalItem,i=r?.id||"unset",n=r?.portal?.url||m.A.portalUrl;throw u.A.getLogger("esri.layers.support.fromPortalItem").error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+n+"', id: '"+i+"')",e),e}}(e)}initialize(){this.when().catch(e=>{(0,c.zf)(e)||u.A.getLogger(this).error("#load()",`Failed to load layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}')`,{error:e})})}destroy(){const{parent:e}=this;e&&(this.parent=null,e.removeChildLayer?.(this))}get effectiveVisible(){return this.visible&&(this.parent?.effectiveVisible??!0)}get hasAttributionData(){return null!=this.attributionDataUrl}get loaded(){return super.loaded}removeFromParent(){const{parent:e}=this;e&&(e.removeChildLayer?.(this),this.parent=null)}get parsedUrl(){return(0,d.An)(this.url)}createLayerView(e,t){return Promise.reject(new s.A("layer:create-layer-view","Layer does not support creating a layer view"))}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,n.A)(e,{query:{f:"json"},responseType:"json"})).data;throw new s.A("layer:no-attribution-data","Layer does not have attribution data")}};(0,i.Cg)([(0,p.MZ)({type:String})],v.prototype,"attributionDataUrl",void 0),(0,i.Cg)([(0,p.MZ)({readOnly:!0})],v.prototype,"effectiveVisible",null),(0,i.Cg)([(0,p.MZ)({type:f.A})],v.prototype,"fullExtent",void 0),(0,i.Cg)([(0,p.MZ)({readOnly:!0})],v.prototype,"hasAttributionData",null),(0,i.Cg)([(0,p.MZ)({type:String,clonable:!1})],v.prototype,"id",void 0),(0,i.Cg)([(0,p.MZ)({type:Boolean,nonNullable:!0})],v.prototype,"legendEnabled",void 0),(0,i.Cg)([(0,p.MZ)({type:["show","hide","hide-children"]})],v.prototype,"listMode",void 0),(0,i.Cg)([(0,p.MZ)({type:Number,range:{min:0,max:1},nonNullable:!0})],v.prototype,"opacity",void 0),(0,i.Cg)([(0,p.MZ)({clonable:!1})],v.prototype,"parent",void 0),(0,i.Cg)([(0,p.MZ)({readOnly:!0})],v.prototype,"parsedUrl",null),(0,i.Cg)([(0,p.MZ)({type:Boolean,readOnly:!0})],v.prototype,"persistenceEnabled",void 0),(0,i.Cg)([(0,p.MZ)({type:Boolean})],v.prototype,"popupEnabled",void 0),(0,i.Cg)([(0,p.MZ)({type:Boolean})],v.prototype,"attributionVisible",void 0),(0,i.Cg)([(0,p.MZ)({type:y.A})],v.prototype,"spatialReference",void 0),(0,i.Cg)([(0,p.MZ)({type:String})],v.prototype,"title",void 0),(0,i.Cg)([(0,p.MZ)({readOnly:!0,json:{read:!1}})],v.prototype,"type",void 0),(0,i.Cg)([(0,p.MZ)()],v.prototype,"url",void 0),(0,i.Cg)([(0,p.MZ)({type:g.A})],v.prototype,"visibilityTimeExtent",void 0),(0,i.Cg)([(0,p.MZ)({type:Boolean,nonNullable:!0})],v.prototype,"visible",void 0),v=(0,i.Cg)([(0,h.$)("esri.layers.Layer")],v)},6797:(e,t,r)=>{r.d(t,{Ui:()=>p});var i=r(69622),n=r(7762),s=r(88620);const o=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function a(e){return e instanceof i.A}function l(e){return e instanceof n.A?Object.keys(e.items):a(e)?(0,s.oY)(e).keys():e?Object.keys(e):[]}function u(e,t){return e instanceof n.A?e.items[t]:e[t]}function c(e){return e?e.declaredClass:null}function d(e,t){const r=e.diff;if(r&&"function"==typeof r)return r(e,t);const i=l(e),n=l(t);if(0===i.length&&0===n.length)return;if(!i.length||!n.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};const s=n.filter(e=>!i.includes(e)),p=i.filter(e=>!n.includes(e)),h=i.filter(r=>n.includes(r)&&u(e,r)!==u(t,r)).concat(s,p).sort(),f=c(e);if(f&&o.has(f)&&h.length)return{type:"complete",oldValue:e,newValue:t};let y;const m=a(e)&&a(t);for(const i of h){const n=u(e,i),s=u(t,i);let o;if((m||"function"!=typeof n&&"function"!=typeof s)&&n!==s&&(null!=n||null!=s)){if(r&&r[i]&&"function"==typeof r[i])o=r[i]?.(n,s);else if(n instanceof Date&&s instanceof Date){if(n.getTime()===s.getTime())continue;o={type:"complete",oldValue:n,newValue:s}}else o="object"==typeof n&&"object"==typeof s&&c(n)===c(s)?d(n,s):{type:"complete",oldValue:n,newValue:s};null!=o&&(null!=y?y.diff[i]=o:y={type:"partial",diff:{[i]:o}})}}return y}function p(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&c(e)!==c(t)?{type:"complete",oldValue:e,newValue:t}:d(e,t)}},16215:(e,t,r)=>{r.d(t,{S:()=>n,Y:()=>i});const i=Symbol("BasemapInstance");function n(e){return null!=e&&"object"==typeof e&&i in e}},16494:(e,t,r)=>{r.d(t,{Nd:()=>a,W5:()=>o});var i=r(37330);const n=["dd","dl","dt","h1","h2","h3","h4","h5","h6","sub","sup","animate","animatetransform","circle","clippath","defs","ellipse","g","image","line","lineargradient","marker","mask","path","pattern","polygon","polyline","radialgradient","rect","stop","svg","switch","symbol","text","textpath","tspan","use"].reduce((e,t)=>(e[t]=[],e),{}),s=["align","alink","alt","bgcolor","border","cellpadding","cellspacing","class","color","cols","colspan","coords","d","dir","face","height","hspace","ismap","lang","marginheight","marginwidth","multiple","nohref","noresize","noshade","nowrap","ref","rel","rev","rows","rowspan","scrolling","shape","span","summary","tabindex","title","usemap","valign","value","vlink","vspace","width"],o=new i.I({whiteList:n,onTagAttr:(e,t,r)=>{const i=`${t}="${r}"`;if(s.includes(t))return i},stripIgnoreTag:!0,stripIgnoreTagBody:["script","style"]},!0),a=new i.I({whiteList:{br:[]},stripIgnoreTag:!0,escapeHtml:e=>e},!1)},17311:(e,t,r)=>{r.d(t,{A:()=>f});var i=r(31635),n=r(69622),s=r(4576),o=r(60999),a=r(7762),l=r(16494),u=r(10107),c=(r(44208),r(53966),r(64108)),d=r(30524),p=r(43668);const h=/<br\s*\/*>/gi;let f=class extends n.A{constructor(e){super(e),this._featureUtils=null,this.effectivePopupTemplate=null}get _arcadeTask(){return this.expressionsUsedInTitle.length>0?this._get("_arcadeTask")||(0,o.UT)(()=>(0,p.l)()):null}get featureUtilsPromise(){return this._get("featureUtilsPromise")??r.e(9926).then(r.bind(r,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 r=this._arcadeTask.value.arcade.parseScript(t.expression,["$layer","$map","$datastore"]);if(r.isAsync){e.push({name:t.name,invalid:!0});break}e.push({name:t.name,syntax:r,invalid:!1,func:this._arcadeTask.value.arcade.compileScript(r,{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 r=this._arcadeTask.value.arcade.extractFieldLiterals(t.syntax);for(const t of r){const r=t.split("."),i=this.fieldsIndex.get(r.at(-1)??"");i&&e.add(i.name)}}catch{}const t=this._extractFieldNames(this.workingTitle);for(const r of t){const t=this.fieldsIndex.get(r);t&&e.add(t.name)}return null!=this.objectIdField&&e.add(this.objectIdField),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,r){const i=t.getObjectId()??t.attributes[e.objectIdField];return(await this.getTitles(e,[t],r)).get(i)??""}async getTitles(e,t,r){const i=new Map,n=r?.timeZone??"system";try{const[{substituteFieldsInLinksAndAttributes:s}]=await Promise.all([this.featureUtilsPromise,this._arcadeTask?.promise]);r?.fetchMissingFields&&(t=await this._checkAndReQueryGraphics(e,t));const{fieldInfoMap:o,workingTitle:a}=this,u=a&&o;t.forEach(t=>{const c=t.getObjectId()??t.attributes[e.objectIdField];let d=u?s({attributes:t.attributes,expressionAttributes:null,fieldInfoMap:o,globalAttributes:this._createFormattedAttributes(e,t,n).global,layer:e,text:a}):"";r?.removeHTML&&(d=l.Nd.sanitize(d).replaceAll(h," ")),i.set(c,d)})}catch{}return i}async _checkAndReQueryGraphics(e,t){const r=t.map(t=>t.getObjectId()??t.attributes[e.objectIdField]).filter(s.Ru);if(r.length!==t.length)return t;if(t.some(e=>!(0,d.Kl)(e,this.requiredFields))){const i=e.createQuery();i.where="1=1",i.outFields=[...this.requiredFields],i.objectIds=r;const n=await e.queryFeatures(i);if(n?.features.length===t.length)return n.features}return t}_createFieldInfoMap(e){const t=new Map;if(!e)return t;for(const r of e){if(!r.fieldName)continue;const e=this.fieldsIndex.get(r.fieldName),i=e?.name??r.fieldName;r.fieldName=i,t.set(i.toLowerCase(),r)}return t}_createFormattedAttributes(e,t,r="system"){const i=this.effectivePopupTemplate?.fieldInfos??[],n={};if(!this._featureUtils)return{};if(!this.hasBadExpressions&&this.calculatedExpressions.length>0&&this._arcadeTask?.value){const r=this._arcadeTask.value.Feature.createFromGraphicLikeObject(t.geometry,t.attributes,e,null);for(const e of this.calculatedExpressions)try{n[`expression/${e.name}`]=e.func({vars:{$feature:r}})}catch{}}const s={...t.attributes,...n};return{global:this._featureUtils.formatAttributes({fieldInfos:i,attributes:s,graphic:t,timeZone:r,layer:e,fieldInfoMap:this.fieldInfoMap}),content:[]}}_extractFieldNames(e){return(0,d.nw)(e).filter(e=>!(e.startsWith("relationships/")||e.startsWith("expression/")))}};(0,i.Cg)([(0,u.MZ)({readOnly:!0})],f.prototype,"_arcadeTask",null),(0,i.Cg)([(0,u.MZ)()],f.prototype,"_featureUtils",void 0),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],f.prototype,"featureUtilsPromise",null),(0,i.Cg)([(0,u.MZ)({readOnly:!0})],f.prototype,"calculatedExpressions",null),(0,i.Cg)([(0,u.MZ)()],f.prototype,"displayField",void 0),(0,i.Cg)([(0,u.MZ)()],f.prototype,"effectivePopupTemplate",void 0),(0,i.Cg)([(0,u.MZ)()],f.prototype,"expressionsUsedInTitle",null),(0,i.Cg)([(0,u.MZ)()],f.prototype,"fieldsIndex",void 0),(0,i.Cg)([(0,u.MZ)()],f.prototype,"fieldInfoMap",null),(0,i.Cg)([(0,u.MZ)()],f.prototype,"fields",void 0),(0,i.Cg)([(0,u.MZ)()],f.prototype,"objectIdField",void 0),(0,i.Cg)([(0,u.MZ)()],f.prototype,"requiredFields",null),f=(0,i.Cg)([(0,c.$)("esri.layers.support.TitleCreator")],f)},29005:(e,t,r)=>{r.d(t,{A:()=>c});var i=r(31635),n=r(69540),s=r(66552),o=r(25482),a=r(10107),l=(r(44208),r(53966),r(87811),r(64108));const u=new s.J({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let c=class extends((0,n.OU)(o.o)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"name",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"description",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:u.read,write:u.write}})],c.prototype,"drawingTool",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"prototype",void 0),(0,i.Cg)([(0,a.MZ)({json:{write:!0}})],c.prototype,"thumbnail",void 0),c=(0,i.Cg)([(0,l.$)("esri.layers.support.FeatureTemplate")],c)},32730:(e,t,r)=>{r.d(t,{BI:()=>m,D3:()=>f,XJ:()=>y,lc:()=>h,mX:()=>w,rU:()=>g,tH:()=>_});var i=r(799);const n="__begin__",s="__end__",o=new RegExp(n,"ig"),a=new RegExp(s,"ig"),l=new RegExp("^"+n,"i"),u=new RegExp(s+"$","i"),c='"',d=c+" + ",p=" + "+c;function h(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=h(e.labelExpression),t.type="conventional"),t}function m(e){const t=y(e);if(!t)return null;switch(t.type){case"conventional":return w(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(v);return t?.[1].trim()||null}(t.expression);case"arcade":return _(t.expression)}return null}function w(e){let t;return e?(t=(0,i.HC)(e,e=>n+'$feature["'+e+'"]'+s),t=l.test(t)?t.replace(l,""):c+t,t=u.test(t)?t.replace(u,""):t+c,t=t.replaceAll(o,d).replaceAll(a,p)):t='""',t}const v=/^\s*\{([^}]+)\}\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,T=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,x=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function _(e){if(!e)return null;let t=b.exec(e)||T.exec(e);return t?t[1]||t[3]:(t=x.exec(e),t?t[2]:null)}},32756:(e,t,r)=>{r.d(t,{Rr:()=>l,fY:()=>c,ne:()=>u});var i=r(31635),n=r(93637),s=r(10107),o=(r(44208),r(53966),r(87811),r(64108)),a=r(91880);function l(e,t,r){if(!e)return null;const i=e.find(e=>!!e.field);if(!i)return null;const n=new a.A;return n.read(i,r),[n]}const u={type:[a.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:l},write:{writer:function(e,t,r,i){const s=e.find(e=>!!e.field);s&&(0,n.sM)(r,[s.toJSON()],t)}}}},c=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,i.Cg)([(0,s.MZ)(u)],r.prototype,"orderBy",void 0),r=(0,i.Cg)([(0,o.$)("esri.layers.mixins.OrderedLayer")],r),r}},33143:(e,t,r)=>{r.d(t,{A:()=>p});var i=r(31635),n=r(69540),s=r(25482),o=r(10107),a=(r(44208),r(53966),r(87811),r(36005)),l=r(64108),u=r(43937),c=r(80451),d=r(29005);let p=class extends((0,n.OU)(s.o)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,c.rS)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,i.Cg)([(0,o.MZ)({json:{write:!0}})],p.prototype,"id",void 0),(0,i.Cg)([(0,o.MZ)({json:{write:!0}})],p.prototype,"name",void 0),(0,i.Cg)([(0,o.MZ)({json:{write:!0}})],p.prototype,"domains",void 0),(0,i.Cg)([(0,a.w)("domains")],p.prototype,"readDomains",null),(0,i.Cg)([(0,u.K)("domains")],p.prototype,"writeDomains",null),(0,i.Cg)([(0,o.MZ)({type:[d.A],json:{write:!0}})],p.prototype,"templates",void 0),p=(0,i.Cg)([(0,l.$)("esri.layers.support.FeatureType")],p)},37352:(e,t,r)=>{r.d(t,{A:()=>u});var i,n=r(31635),s=r(7762),o=r(25482),a=r(10107),l=(r(44208),r(53966),r(87811),r(64108));let u=i=class extends o.o{constructor(e){super(e),this.floorField=null,this.viewAllMode=!1,this.viewAllLevelIds=new s.A}clone(){return new i({floorField:this.floorField,viewAllMode:this.viewAllMode,viewAllLevelIds:this.viewAllLevelIds})}};(0,n.Cg)([(0,a.MZ)({type:String,json:{write:{isRequired:!0}}})],u.prototype,"floorField",void 0),(0,n.Cg)([(0,a.MZ)({json:{read:!1,write:!1}})],u.prototype,"viewAllMode",void 0),(0,n.Cg)([(0,a.MZ)({json:{read:!1,write:!1}})],u.prototype,"viewAllLevelIds",void 0),u=i=(0,n.Cg)([(0,l.$)("esri.layers.support.LayerFloorInfo")],u)},41366:(e,t,r)=>{r.d(t,{K:()=>p,Q:()=>u});var i=r(31635),n=r(66552),s=r(53966),o=r(10107),a=(r(44208),r(87811),r(93223)),l=r(64108);const u=(0,n.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),c="percent-of-total",d="field",p=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.normalizationField=null,this.normalizationMaxValue=null,this.normalizationMinValue=null,this.normalizationTotal=null}get normalizationType(){let e=this._get("normalizationType");const t=!!this.normalizationField,r=null!=this.normalizationTotal;return t||r?(e=t&&d||r&&c||null,t&&r&&s.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):e!==d&&e!==c||(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,i.Cg)([(0,o.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],r.prototype,"normalizationField",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],r.prototype,"normalizationMaxValue",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],r.prototype,"normalizationMinValue",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],r.prototype,"normalizationTotal",void 0),(0,i.Cg)([(0,a.e)(u,{name:"parameters.normalizationType"})],r.prototype,"normalizationType",null),r=(0,i.Cg)([(0,l.$)("esri.rest.support.NormalizationBinParametersMixin")],r),r}},41560:(e,t,r)=>{r.d(t,{Ch:()=>o,mW:()=>s});var i=r(34727),n=r(39516);function s(e,t){return{...t,filterMode:e.mode}}function o(e,t,r){const s=function(e){if("manual"===u(e))return null;const t=[Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY];for(const{minScale:r,maxScale:i}of e.filters)t[0]=Math.max(t[0],c(r)),t[1]=Math.min(t[1],d(i));return t}(e);if(s&&((0,i.gg)(t,s[0])||(0,i.ZH)(r,s[1])))return"";const o=Array.from(a(e,t,r)),l=function(e,t,r){if(0===e.length)return!0;const n=c(e.at(0)?.minScale),s=d(e.at(-1)?.maxScale);if((0,i.ZH)(n,t)||(0,i.gg)(s,r))return!0;for(let t=0;t<e.length-1;t++){const r=e[t],n=e[t+1];if((0,i.ZH)(c(n.minScale),d(r.maxScale)))return!0}return!1}(o,t,r)?"1=1":o.map(e=>e.where||"1=1").reduce((e,t)=>(0,n.IW)(e,t),"");return l&&"1=1"!==l?l:""}function*a(e,t,r){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 i of e.filters)l(i.minScale,i.maxScale,t,r)&&(yield i)}}function l(e,t,r,n){return e=c(e),r=c(r),t=d(t),!(!(0,i.Sp)(r,e)&&(n??r)>e||(0,i.Hx)(t,r)||void 0!==n&&(0,i.Sp)(n,e))}function u(e){return"mode"in e?e.mode:e.filterMode}function c(e){return e||Number.POSITIVE_INFINITY}function d(e){return e||0}},45067:(e,t,r)=>{r.d(t,{A:()=>d});var i=r(31635),n=r(69540),s=r(66552),o=r(25482),a=r(10107),l=(r(44208),r(53966),r(87811),r(64108));const u=new s.J({esriRelCardinalityOneToOne:"one-to-one",esriRelCardinalityOneToMany:"one-to-many",esriRelCardinalityManyToMany:"many-to-many"}),c=new s.J({esriRelRoleOrigin:"origin",esriRelRoleDestination:"destination"});let d=class extends((0,n.OU)(o.o)){constructor(e){super(e),this.cardinality=null,this.catalogId=null,this.composite=null,this.id=null,this.keyField=null,this.keyFieldInRelationshipTable=null,this.name=null,this.relatedTableId=null,this.relationshipTableId=null,this.role=null}};(0,i.Cg)([(0,a.MZ)({json:{read:u.read,write:u.write}})],d.prototype,"cardinality",void 0),(0,i.Cg)([(0,a.MZ)({json:{name:"catalogID"}})],d.prototype,"catalogId",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],d.prototype,"composite",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],d.prototype,"id",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],d.prototype,"keyField",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],d.prototype,"keyFieldInRelationshipTable",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],d.prototype,"name",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],d.prototype,"relatedTableId",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:!0,write:!0}})],d.prototype,"relationshipTableId",void 0),(0,i.Cg)([(0,a.MZ)({json:{read:c.read,write:c.write}})],d.prototype,"role",void 0),d=(0,i.Cg)([(0,l.$)("esri.layers.support.Relationship")],d)},46140:(e,t,r)=>{r.d(t,{R:()=>n});var i=r(49186);let n=class e{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}validate(e){if(this.major!==e.major){const t=this._context&&this._context+":",r=this._context&&this._context+" ";throw new i.A(t+"unsupported-version",`Required major ${r}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new e(this.major,this.minor,this._context)}static parse(t,r=""){const[n,s]=t.split("."),o=/^\s*\d+\s*$/;if(!n?.match||!o.test(n))throw new i.A((r&&r+":")+"invalid-version","Expected major version to be a number, but got '${version}'",{version:t});if(!s?.match||!o.test(s))throw new i.A((r&&r+":")+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:t});const a=parseInt(n,10),l=parseInt(s,10);return new e(a,l,r)}}},52136:(e,t,r)=>{r.d(t,{p:()=>o});var i=r(31635),n=r(10107),s=(r(44208),r(53966),r(87811),r(64108));const o=e=>{const t=e;let r=class extends t{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,i.Cg)([(0,n.MZ)({type:String})],r.prototype,"apiKey",null),r=(0,i.Cg)([(0,s.$)("esri.layers.mixins.APIKeyMixin")],r),r}},55674:(e,t,r)=>{r.d(t,{Ad:()=>h,Gj:()=>m,QY:()=>p,lL:()=>g,xR:()=>f});var i=r(66131),n=r(49186),s=(r(44208),r(44729)),o=r(15032),a=r(65864),l=r(95466),u=r(43668),c=r(98623);const d=["geometry","scale","timeProperties"];function p(e,t){if(null!=t)for(const r of d)t.hasArcadeDependency(r)&&e.add(r);return e}function h(e,t){return y.create(e,t,null,["$feature","$view"])}function f(e,t,r){return y.create(e,t,r,["$feature","$view","$config"])}class y{static async create(e,t,r,i){const{arcade:s,Dictionary:o}=await(0,u.l)();let a;try{a=s.parseScript(e)}catch(t){throw new n.A("arcade-bad-expression","Failed to parse arcade script",{script:e,error:t})}const l=s.scriptUsesGeometryEngine(a);l&&await s.enableGeometrySupport(),await s.loadDependentModules(new Set,a,null,!1,l);const c={vars:i.reduce((e,t)=>({...e,[t]:null}),{}),spatialReference:t,useAsync:!1},d=s.compileScript(a,c);let p=null;null!=r&&(p=new o(r),p.immutable=!0);const h=new o;return h.immutable=!1,h.setField("scale",0),new y(e,s,a,d,t,h,p,o)}constructor(e,t,r,i,n,s,o,a){this.script=e,this._arcade=t,this._syntaxTree=r,this._compiled=i,this._spatialReference=n,this._viewDict=s,this._configDict=o,this._dictionaryCtor=a,this._dependencies=new Map,this._featureReader=new m,this._dependencies.set("geometry",t.scriptTouchesGeometry(this._syntaxTree)),this._dependencies.set("scale",this._arcade.referencesMember(this._syntaxTree,"scale")),this._dependencies.set("timeProperties",this._arcade.scriptUsesViewProperties(this._syntaxTree,["timeProperties"]))}evaluate(e,t){const r=t.$view?.timeZone;if(t.$view){let e;if(this._viewDict.setField("scale",t.$view.scale),null!=t.$view.timeProperties){const{currentStart:n,currentEnd:s}=t.$view.timeProperties;e=new this._dictionaryCtor({currentStart:null!=n?null!=r?i.lY.epochToArcadeDate(n,r):i.lY.unknownEpochToArcadeDate(n):void 0,currentEnd:null!=s?null!=r?i.lY.epochToArcadeDate(s,r):i.lY.unknownEpochToArcadeDate(s):void 0,startIncluded:!0,endIncluded:!0})}this._viewDict.setField("timeProperties",e)}return this._compiled({vars:{$view:this._viewDict,$config:this._configDict,$feature:e},spatialReference:this._spatialReference,timeZone:r})}repurposeFeature(e,t){return this._featureReader.bind(e,t,this._spatialReference),this._featureReader}references(e){return this._dependencies.get(e)??!1}}class m{constructor(){this._boundTarget=null,this._boundSchema={fields:null,fieldsIndex:null,spatialReference:null,get geometryType(){return null},get objectIdField(){return null}},this.arcadeDeclaredClass="esri.arcade.Feature",this._contextTimeZone=null}bind(e,t,r){const i=t??new l.A(g(e.attributes));this._boundTarget=e,this._boundSchema.fields=i.fields,this._boundSchema.fieldsIndex=i,this._boundSchema.spatialReference=r}_getField(e){return this._boundSchema.fieldsIndex.get(e)}get contextTimeZone(){return this._contextTimeZone}set contextTimeZone(e){this._contextTimeZone=e}readArcadeFeature(){return this}hasField(e){return this._boundSchema.fieldsIndex.has(e)}geometry(){if("fromJSON"in this._boundTarget)return this._boundTarget.geometry;const e=(0,a.rS)(this._boundTarget.geometry);if(e){if(!this._boundSchema.spatialReference)throw new Error("InternalError: Expected spatial reference to be defined");e.spatialReference=this._boundSchema.spatialReference}return e}_hasGeometry(){return null!=this._boundTarget.geometry}isUnknownDateTimeField(e){return this._boundSchema.fieldsIndex.getTimeZone(e)===c.L5}field(e,t=!0){const r=this._getField(e);if(r){const t=this._boundTarget.attributes[r.name];if(null==t)return null;switch(r.type){case"date-only":case"esriFieldTypeDateOnly":return s.n.fromReader(t);case"time-only":case"esriFieldTypeTimeOnly":return o.k.fromReader(t);case"esriFieldTypeTimestampOffset":case"timestamp-offset":return i.lY.fromReaderAsTimeStampOffset(t);case"date":case"esriFieldTypeDate":return this.isUnknownDateTimeField(e)?i.lY.unknownEpochToArcadeDate(t):i.lY.epochToArcadeDate(t,this.contextTimeZone??c.qU);default:return t}}if(t)throw new Error(`Field ${e} does not exist`);return null}setField(e,t){throw new Error("Unable to update feature attribute values, feature is readonly")}keys(){return this._boundSchema.fieldsIndex.fields.map(e=>e.name)}isEmpty(){return this._boundSchema.fields.length<=0&&!this._hasGeometry()}castToText(e=!1){return JSON.stringify(this._boundTarget)}gdbVersion(){return null}fullSchema(){return this._boundSchema}castAsJson(e=null){return{attributes:this._boundTarget.attributes,geometry:!0===e?.keepGeometryType?this.geometry():this.geometry()?.toJSON()??null}}castAsJsonAsync(e=null,t=null){return Promise.resolve(this.castAsJson(t))}}function g(e){const t=[];for(const r in e)t.push({name:r,alias:r,type:"string"==typeof e[r]?"esriFieldTypeString":"esriFieldTypeDouble"});return t}},58501:(e,t,r)=>{r.d(t,{q:()=>n});var i=r(62815);function n(e,t,r){if(!r?.features||!r.hasZ)return;const n=(0,i.N)(r.geometryType,t,e.outSpatialReference);if(n)for(const e of r.features)n(e.geometry)}},73681:(e,t,r)=>{r.d(t,{n:()=>l});var i=r(49186),n=r(53966),s=r(46140),o=r(95466),a=r(55674);class l{static async from(e,t,r){const o=e.dictionary_version?s.R.parse(e.dictionary_version):null,c=new Set(e.itemsNames),d={};if(t)for(const e in t)d[e]=t[e];if(e.authoringInfo.configuration)for(const t of e.authoringInfo.configuration)d.hasOwnProperty(t.name)||(d[t.name]=t.value);const p=new Set(e.authoringInfo.symbol);for(const e of Object.keys(r))p.delete(e);p.size&&n.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:p});const h=await(0,a.xR)(e.expression,null,d);if(!h)throw new i.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");const f=!o||!o.greaterEqual(4,0);f&&n.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:o});const y=new u(r,f);return new l(f,c,h,y)}constructor(e,t,r,i){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=i}get itemNames(){return this._itemNames}evaluate(e,t,r,i){try{return this._reader.bind(e,r,i),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){n.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new o.A(e);const t=e.map(e=>({...e,type:"esriFieldTypeString"}));return new o.A(t)}}class u extends a.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){const t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);const t=this._getField(e);return null==t||null==this._boundTarget.attributes[t.name]?"":""+this._boundTarget.attributes[t.name]}}},77548:(e,t,r)=>{r.d(t,{Gh:()=>m,tk:()=>p,BR:()=>d,wI:()=>c,G$:()=>f,$x:()=>h,Ov:()=>a,W_:()=>l,OP:()=>y,TU:()=>o,XX:()=>s,jy:()=>u});var i=r(70333),n=r(78888);r(7762),r(84952),r(36563),r(36708),r(4146),new WeakMap,r(16215);const s={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};function o(e){const t=e?.type;return"building-scene"===t||"integrated-mesh"===t||"point-cloud"===t||"scene"===t}function a(e){return"feature"===e?.type&&!e.url&&"memory"===e.source?.type}function l(e){const t=e?.type;return("feature"===t||"subtype-group"===t||"oriented-imagery"===t)&&"feature-layer"===e?.source?.type}function u(e){return function(e){return null!=e&&"object"==typeof e&&"type"in e&&"feature"===e.type}(e)&&function(e){return"feature"===e?.type&&"feature-layer"===e.source?.type}(e)}async function c(e,t){const r=i.id?.findServerInfo(e);if(null!=r?.currentVersion)return r.owningSystemUrl||null;const s=e.toLowerCase().indexOf("/rest/services");if(-1===s)return null;const o=`${e.slice(0,s)}/rest/info`,a=null!=t?t.signal:null,{data:l}=await(0,n.A)(o,{query:{f:"json"},responseType:"json",signal:a});return l?.owningSystemUrl||null}function d(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 p(e){return!!function(e){if(!("editingEnabled"in e))return!1;switch(e.type){case"csv":case"feature":case"geojson":case"oriented-imagery":case"scene":case"subtype-group":case"subtype-sublayer":case"knowledge-graph-sublayer":return!0;default:return!1}}(e)&&("effectiveEditingEnabled"in e?e.effectiveEditingEnabled:e.editingEnabled)}function h(e,t){return null}function f(e){return null}function y(e){return!e||"Feature Service"===e.type&&!e.sourceUrl}function m(e,t){if(!t||!y(e))return;const r=(e.url,null);r&&(e.url=r)}},79677:(e,t,r)=>{r.d(t,{A:()=>p});var i,n=r(31635),s=r(25482),o=r(88930),a=r(10107),l=(r(44208),r(53966),r(87811),r(36005)),u=r(64108),c=r(43937),d=r(98623);let p=class extends s.o{static{i=this}static get allTime(){return h}static get empty(){return f}static fromArray(e){return new i({start:null!=e[0]?new Date(e[0]):e[0],end:null!=e[1]?new Date(e[1]):e[1]})}constructor(e){super(e),this.end=null,this.start=null}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?.getTime()??null}get isAllTime(){return this.equals(i.allTime)}get isEmpty(){return this.equals(i.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?.getTime()??null}clone(){return new i({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=this.start?.getTime()??this.start,r=this.end?.getTime()??this.end,i=e.start?.getTime()??e.start,n=e.end?.getTime()??e.end;return t===i&&r===n}expandTo(e,t=d.qU){if(this.isEmpty||this.isAllTime)return this.clone();let r=this.start;r&&(r=(0,o.lL)(r,e,t));let n=this.end;if(n){const r=(0,o.lL)(n,e,t);n=n.getTime()===r.getTime()?r:(0,o.S1)(r,1,e,t)}return new i({start:r,end:n})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return i.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=this.start?.getTime()??-1/0,r=this.end?.getTime()??1/0,n=e.start?.getTime()??-1/0,s=e.end?.getTime()??1/0;let o,a;return n>=t&&n<=r?o=n:t>=n&&t<=s&&(o=t),r>=n&&r<=s?a=r:s>=t&&s<=r&&(a=s),null==o||null==a||isNaN(o)||isNaN(a)?i.empty:new i({start:o===-1/0?null:new Date(o),end:a===1/0?null:new Date(a)})}offset(e,t,r=d.qU){if(this.isEmpty||this.isAllTime)return this.clone();const n=new i,{start:s,end:a}=this;return null!=s&&(n.start=(0,o.S1)(s,e,t,r)),null!=a&&(n.end=(0,o.S1)(a,e,t,r)),n}toArray(){return this.isEmpty?[void 0,void 0]:[this.start?.getTime()??null,this.end?.getTime()??null]}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return h.clone();const t=null!=this.start&&null!=e.start?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,r=null!=this.end&&null!=e.end?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new i({start:t,end:r})}};(0,n.Cg)([(0,a.MZ)({type:Date,json:{write:{allowNull:!0}}})],p.prototype,"end",void 0),(0,n.Cg)([(0,l.w)("end")],p.prototype,"readEnd",null),(0,n.Cg)([(0,c.K)("end")],p.prototype,"writeEnd",null),(0,n.Cg)([(0,a.MZ)({readOnly:!0,json:{read:!1}})],p.prototype,"isAllTime",null),(0,n.Cg)([(0,a.MZ)({readOnly:!0,json:{read:!1}})],p.prototype,"isEmpty",null),(0,n.Cg)([(0,a.MZ)({type:Date,json:{write:{allowNull:!0}}})],p.prototype,"start",void 0),(0,n.Cg)([(0,l.w)("start")],p.prototype,"readStart",null),(0,n.Cg)([(0,c.K)("start")],p.prototype,"writeStart",null),p=i=(0,n.Cg)([(0,u.$)("esri.time.TimeExtent")],p);const h=new p,f=new p({start:void 0,end:void 0})},91880:(e,t,r)=>{r.d(t,{A:()=>c});var i,n=r(31635),s=r(66552),o=r(25482),a=r(10107),l=(r(44208),r(53966),r(87811),r(64108));const u=new s.J({asc:"ascending",desc:"descending"});let c=class extends o.o{static{i=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new i({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,n.Cg)([(0,a.MZ)({type:String,json:{write:!0}})],c.prototype,"field",void 0),(0,n.Cg)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],c.prototype,"valueExpression",void 0),(0,n.Cg)([(0,a.MZ)({type:u.apiValues,json:{type:u.jsonValues,read:u.read,write:u.write}})],c.prototype,"order",void 0),c=i=(0,n.Cg)([(0,l.$)("esri.layers.support.OrderByInfo")],c)}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3747],{13069:(e,t,r)=>{r.d(t,{AG:()=>a,lk:()=>i,vD:()=>o,yS:()=>n});const s="randomUUID"in crypto;function i(){if(s)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 n(){return`{${i().toUpperCase()}}`}function o(){return`{${i()}}`}function a(e){const t=e.toUpperCase();return e.startsWith("{")?t:`{${t}}`}},16494:(e,t,r)=>{r.d(t,{Nd:()=>a,W5:()=>o});var s=r(37330);const i=["dd","dl","dt","h1","h2","h3","h4","h5","h6","sub","sup","animate","animatetransform","circle","clippath","defs","ellipse","g","image","line","lineargradient","marker","mask","path","pattern","polygon","polyline","radialgradient","rect","stop","svg","switch","symbol","text","textpath","tspan","use"].reduce((e,t)=>(e[t]=[],e),{}),n=["align","alink","alt","bgcolor","border","cellpadding","cellspacing","class","color","cols","colspan","coords","d","dir","face","height","hspace","ismap","lang","marginheight","marginwidth","multiple","nohref","noresize","noshade","nowrap","ref","rel","rev","rows","rowspan","scrolling","shape","span","summary","tabindex","title","usemap","valign","value","vlink","vspace","width"],o=new s.I({whiteList:i,onTagAttr:(e,t,r)=>{const s=`${t}="${r}"`;if(n.includes(t))return s},stripIgnoreTag:!0,stripIgnoreTagBody:["script","style"]},!0),a=new s.I({whiteList:{br:[]},stripIgnoreTag:!0,escapeHtml:e=>e},!1)},18047:(e,t,r)=>{r.d(t,{Up:()=>l,ZV:()=>h,yx:()=>a});var s=r(73444);const i={ar:"ar-u-nu-latn",bs:"sr-Latn-CS",nn:"no-NN"};let n=new WeakMap,o={};function a(e={}){const t={};return null!=e.digitSeparator&&(t.useGrouping=e.digitSeparator),null!=e.places&&(t.minimumFractionDigits=t.maximumFractionDigits=e.places),t}function l(e){const{minimumFractionDigits:t,maximumFractionDigits:r,useGrouping:s}=e;return{minimumFractionDigits:t,maximumFractionDigits:r,useGrouping:"auto"===s?"auto":"always"===s}}function h(e,t){return Object.is(e,-0)&&(e=0),function(e){const t=e||o;if(!n.has(t)){const r=(0,s.lR)(),o=r&&i[r]||(0,s.QC)();n.set(t,new Intl.NumberFormat(o,e))}return n.get(t)}(t).format(e)}(0,s.Ml)(()=>{n=new WeakMap,o={}}),new Map},36708:(e,t,r)=>{r.d(t,{C_:()=>u,OH:()=>g,Vh:()=>m,on:()=>c,pc:()=>v,wB:()=>l,z7:()=>h});var s=r(37955),i=r(36563),n=r(97768),o=r(74887),a=r(14012);function l(e,t,r={}){return d(e,t,r,p)}function h(e,t,r={}){return d(e,t,r,f)}function d(e,t,r={},s){let i=null;const o=r.once?(e,r)=>{s(e)&&((0,n.xt)(i),t(e,r))}:(e,r)=>{s(e)&&t(e,r)};if(i=(0,a.Cn)(e,o,r.sync,r.equals),r.initial){const t=e();o(t,t)}return i}function c(e,t,r,o={}){let a=null,h=null,d=null;function c(){a&&h&&(h.remove(),o.onListenerRemove?.(a),a=null,h=null)}function u(e){o.once&&o.once&&(0,n.xt)(d),r(e)}const p=l(e,(e,r)=>{c(),(0,s.wb)(e)&&(a=e,h=(0,s.on)(e,t,u),o.onListenerAdd?.(e))},{sync:o.sync,initial:!0});return d=(0,i.hA)(()=>{p.remove(),c()}),d}function u(e,t){return function(e,t,r){if((0,o.G4)(r))return Promise.reject((0,o.NK)());const s=e();if(t?.(s))return Promise.resolve(s);let a=null;function l(){a=(0,n.xt)(a)}return new Promise((s,n)=>{a=(0,i.vE)([(0,o.u7)(r,()=>{l(),n((0,o.NK)())}),d(e,e=>{l(),s(e)},{sync:!1,once:!0},t??p)])})}(e,f,t)}function p(e){return!0}function f(e){return!!e}r(80559);const g={sync:!0},m={initial:!0},v={sync:!0,initial:!0}},47566:(e,t,r)=>{r(97770),r(18047),r(71754),r(73444);var s=r(10838),i=r(78888),n=r(49186);async function o(e){if(null!=l.fetchBundleAsset)return l.fetchBundleAsset(e);const t=await(0,i.A)(e,{responseType:"text"});return JSON.parse(t.data)}class a{constructor({base:e="",pattern:t,location:r=new URL(window.location.href)}){let s;s="string"==typeof r?e=>new URL(e,new URL(r,window.location.href)).href:r instanceof URL?e=>new URL(e,r).href:r,this.pattern="string"==typeof t?new RegExp(`^${t}`):t,this.getAssetUrl=s,e=e?e.endsWith("/")?e:e+"/":"",this.matcher=new RegExp(`^${e}(?:(.*)\\/)?(.*)$`)}fetchMessageBundle(e,t){return async function(e,t,r,i){const a=t.exec(r);if(!a)throw new n.A("esri-intl:invalid-bundle",`Bundle id "${r}" is not compatible with the pattern "${t}"`);const l=a[1]?`${a[1]}/`:"",h=a[2],d=(0,s.xO)(i),c=`${l}${h}.json`,u=d?`${l}${h}_${d}.json`:c;let p;try{p=await o(e(u))}catch(t){if(u===c)throw new n.A("intl:unknown-bundle",`Bundle "${r}" cannot be loaded`,{error:t});try{p=await o(e(c))}catch(e){throw new n.A("intl:unknown-bundle",`Bundle "${r}" cannot be loaded`,{error:e})}}return p}(this.getAssetUrl,this.matcher,e,t)}}const l={};var h,d=r(2741);(0,s.ao)((h={pattern:"esri/",location:d.s},new a(h)))},61893:(e,t,r)=>{r.d(t,{Z:()=>d,g:()=>h});var s=r(31635),i=r(69622),n=r(36563),o=r(74887),a=r(64108);class l{constructor(){this._resolver=(0,o.Tw)(),this._status=0,this._resolvingPromises=[],this._resolver.promise.then(()=>{this._status=1,this._cleanUp()},()=>{this._status=2,this._cleanUp()}),this.promise=this._resolver.promise}destroy(){this._cleanUp()}addResolvingPromise(e){this._resolvingPromises.push(e),this._tryResolve()}isResolved(){return 1===this._status}isRejected(){return 2===this._status}isFulfilled(){return 0!==this._status}abort(){this._resolver.reject((0,o.NK)())}_cleanUp(){this._allPromise=null,this._resolvingPromises=null}_tryResolve(){if(this.isFulfilled())return;const e=(0,o.Tw)(),t=[...this._resolvingPromises,e.promise],r=this._allPromise=Promise.all(t);r.then(()=>{this.isFulfilled()||this._allPromise!==r||this._resolver.resolve()},e=>{this.isFulfilled()||this._allPromise!==r||(0,o.zf)(e)||this._resolver.reject(e)}),e.resolve()}}const h=e=>{const t=e;let r=class extends t{constructor(...e){super(...e),this._promiseProps=new l,this.addResolvingPromise(Promise.resolve())}destroy(){this._promiseProps.destroy()}isResolved(){return this._promiseProps.isResolved()}isRejected(){return this._promiseProps.isRejected()}isFulfilled(){return this._promiseProps.isFulfilled()}when(e,t){return this._promiseProps.promise.then(()=>this).then(e,t)}catch(e){return this.when(null,e)}addResolvingPromise(e){e&&!this._promiseProps.isFulfilled()&&this._promiseProps.addResolvingPromise("_promiseProps"in e?e.when():e)}addResolvingTask(e){e&&!this._promiseProps.isFulfilled()&&(this.addHandles((0,n.rE)(e)),this._promiseProps.addResolvingPromise(e.promise))}};return r=(0,s.Cg)([(0,a.$)("esri.core.Promise")],r),r},d=h(i.A)},71754:(e,t,r)=>{r.d(t,{V:()=>h});var s=r(53966),i=r(93637),n=r(799),o=r(97770),a=r(18047);const l=()=>s.A.getLogger("esri.intl.substitute");function h(e,t,r={}){const{format:s={}}=r;return(0,n.HC)(e,e=>function(e,t,r){let s,n;const o=e.indexOf(":");if(-1===o?s=e.trim():(s=e.slice(0,o).trim(),n=e.slice(o+1).trim()),!s)return"";const a=(0,i.wc)(s,t);if(null==a)return"";const l=(n?r?.[n]:null)??r?.[s];return l?d(a,l):n?c(a,n):u(a)}(e,t,s))}function d(e,t){switch(t.type){case"date":return(0,o.Yq)(e,t.intlOptions);case"number":return(0,a.ZV)(e,t.intlOptions);default:return l().warn("missing format descriptor for key {key}"),u(e)}}function c(e,t){switch(t.toLowerCase()){case"dateformat":return(0,o.Yq)(e);case"numberformat":return(0,a.ZV)(e);default:return l().warn(`inline format is unsupported since 4.12: ${t}`),/^(dateformat|datestring)/i.test(t)?(0,o.Yq)(e):/^numberformat/i.test(t)?(0,a.ZV)(e):u(e)}}function u(e){switch(typeof e){case"string":return e;case"number":return(0,a.ZV)(e);case"boolean":return""+e;default:return e instanceof Date?(0,o.Yq)(e):""}}},73747:(e,t,r)=>{r.r(t),r.d(t,{default:()=>dt});var s=r(70333),i=r(31635),n=r(92602),o=r(78888),a=r(49186),l=r(65529),h=r(37955),d=r(4718),c=r(93637),u=r(74887),p=r(84952),f=r(10107),g=(r(44208),r(53966)),m=r(64108);r(47566),r(87811);var v=r(97768),_=r(61893),y=r(36708),w=r(13069),S=r(79901),I=r(62788),A=r(71429),k=r(16494);const U="http://www.w3.org/",C=`${U}2000/svg`,b=`${U}1999/xlink`;let P=[],x=(e,t)=>{let r={};return Object.keys(e).forEach(t=>{r[t]=e[t]}),t&&Object.keys(t).forEach(e=>{r[e]=t[e]}),r},T=(e,t)=>e.vnodeSelector===t.vnodeSelector&&(e.properties&&t.properties?e.properties.key===t.properties.key&&e.properties.bind===t.properties.bind:!e.properties&&!t.properties),R=e=>{if("string"!=typeof e)throw new Error("Style values must be strings")},O=(e,t,r)=>{if(""!==t.vnodeSelector)for(let s=r;s<e.length;s++)if(T(e[s],t))return s;return-1},N=(e,t,r,s)=>{let i=e[t];if(""===i.vnodeSelector)return;let n=i.properties;if(!(n?void 0===n.key?n.bind:n.key:void 0))for(let n=0;n<e.length;n++)if(n!==t){let t=e[n];if(T(t,i))throw new Error(`${r.vnodeSelector} had a ${i.vnodeSelector} child ${"added"===s?s:"removed"}, but there is now more than one. You must add unique key properties to make them distinguishable.`)}},M=e=>{if(e.properties){let t=e.properties.enterAnimation;t&&t(e.domNode,e.properties)}},D=[],j=!1,E=e=>{(e.children||[]).forEach(E),e.properties&&e.properties.afterRemoved&&e.properties.afterRemoved.apply(e.properties.bind||e.properties,[e.domNode])},L=()=>{j=!1,D.forEach(E),D.length=0},q=e=>{D.push(e),j||(j=!0,"undefined"!=typeof window&&"requestIdleCallback"in window?window.requestIdleCallback(L,{timeout:16}):setTimeout(L,16))},$=e=>{let t=e.domNode;if(e.properties){let r=e.properties.exitAnimation;if(r){t.style.pointerEvents="none";let s=()=>{t.parentNode&&(t.parentNode.removeChild(t),q(e))};return void r(t,s,e.properties)}}t.parentNode&&(t.parentNode.removeChild(t),q(e))},Z=(e,t,r)=>{if(!t)return;let s=r.eventHandlerInterceptor,i=Object.keys(t),n=i.length;for(let o=0;o<n;o++){let n=i[o],a=t[n];if("className"===n)throw new Error('Property "className" is not supported, use "class".');if("class"===n)z(e,a,!0);else if("classes"===n){let t=Object.keys(a),r=t.length;for(let s=0;s<r;s++){let r=t[s];a[r]&&e.classList.add(r)}}else if("styles"===n){let t=Object.keys(a),s=t.length;for(let i=0;i<s;i++){let s=t[i],n=a[s];n&&(R(n),r.styleApplyer(e,s,n))}}else if("key"!==n&&null!=a){let i=typeof a;"function"===i?(0===n.lastIndexOf("on",0)&&(s&&(a=s(n,a,e,t)),"oninput"===n&&function(){let e=a;a=function(t){e.apply(this,[t]),t.target["oninput-value"]=t.target.value}}()),e[n]=a):r.namespace===C?"href"===n?e.setAttributeNS(b,n,a):e.setAttribute(n,a):"string"===i&&"value"!==n?"innerHTML"===n?e[n]=k.W5.sanitize(a):F(e)&&n in e?e[n]=a:e.setAttribute(n,a):e[n]=a}}};function F(e){if(!(e instanceof Element&&e.tagName.includes("-")))return!1;const t=window.customElements.get(e.tagName.toLowerCase());return!!t&&e instanceof t}let V,B=(e,t,r)=>{((e,t,r)=>{if(t)for(let s of t)H(s,e,void 0,r)})(e,t.children,r),t.text&&(e.textContent=t.text),Z(e,t.properties,r),t.properties&&t.properties.afterCreate&&t.properties.afterCreate.apply(t.properties.bind||t.properties,[e,r,t.vnodeSelector,t.properties,t.children])},H=(e,t,r,s)=>{let i,n=0,o=e.vnodeSelector,a=t.ownerDocument;if(""===o)i=e.domNode=a.createTextNode(e.text),void 0!==r?t.insertBefore(i,r):t.appendChild(i);else{for(let l=0;l<=o.length;++l){let h=o.charAt(l);if(l===o.length||"."===h||"#"===h){let h=o.charAt(n-1),d=o.slice(n,l);"."===h?i.classList.add(d):"#"===h?i.id=d:("svg"===d&&(s=x(s,{namespace:C})),void 0!==s.namespace?i=e.domNode=a.createElementNS(s.namespace,d):(i=e.domNode=e.domNode||a.createElement(d),"input"===d&&e.properties&&void 0!==e.properties.type&&i.setAttribute("type",e.properties.type)),void 0!==r?t.insertBefore(i,r):i.parentNode!==t&&t.appendChild(i)),n=l+1}}B(i,e,s)}},z=(e,t,r)=>{t&&t.split(" ").forEach(t=>{t&&e.classList.toggle(t,r)})},W=(e,t,r,s)=>{if(!r)return;let i=!1,n=Object.keys(r),o=n.length;for(let a=0;a<o;a++){let o=n[a],l=r[o],h=t[o];if("class"===o)h!==l&&(z(e,h,!1),z(e,l,!0));else if("classes"===o){let t=e.classList,r=Object.keys(l),s=r.length;for(let e=0;e<s;e++){let s=r[e],n=!!l[s];n!==!!h[s]&&(i=!0,n?t.add(s):t.remove(s))}}else if("styles"===o){let t=Object.keys(l),r=t.length;for(let n=0;n<r;n++){let r=t[n],o=l[r];o!==h[r]&&(i=!0,o?(R(o),s.styleApplyer(e,r,o)):s.styleApplyer(e,r,""))}}else if(l||"string"!=typeof h||(l=""),"value"!==o||F(e)){if(l!==h){let t=typeof l;"function"===t&&s.eventHandlerInterceptor||(s.namespace===C?"href"===o?e.setAttributeNS(b,o,l):e.setAttribute(o,l):"string"===t?"innerHTML"===o?e[o]=k.W5.sanitize(l):"role"===o&&""===l?e.removeAttribute(o):F(e)&&o in e?e[o]=l:e.setAttribute(o,l):e[o]!==l&&(e[o]=l),i=!0)}}else{let t=e[o];t!==l&&(e["oninput-value"]?t===e["oninput-value"]:l!==h)&&(e[o]=l,e["oninput-value"]=void 0),l!==h&&(i=!0)}}return i},G=(e,t,r,s,i)=>{if(r===s)return!1;s=s||P;let n,o=(r=r||P).length,a=s.length,l=0,h=0,d=!1;for(;h<a;){let a=l<o?r[l]:void 0,c=s[h];if(void 0!==a&&T(a,c))d=V(a,c,i)||d,l++;else{let a=O(r,c,l+1);if(a>=0){for(n=l;n<a;n++)$(r[n]),N(r,n,e,"removed");d=V(r[a],c,i)||d,l=a+1}else H(c,t,l<o?r[l].domNode:void 0,i),M(c),N(s,h,e,"added")}h++}if(o>l)for(n=l;n<o;n++)$(r[n]),N(r,n,e,"removed");return d};V=(e,t,r)=>{let s=e.domNode,i=!1;if(e===t)return!1;let n=!1;if(""===t.vnodeSelector){if(t.text!==e.text){let e=s.ownerDocument.createTextNode(t.text);return s.parentNode.replaceChild(e,s),t.domNode=e,i=!0,i}t.domNode=s}else 0===t.vnodeSelector.lastIndexOf("svg",0)&&(r=x(r,{namespace:C})),e.text!==t.text&&(n=!0,void 0===t.text?s.removeChild(s.firstChild):s.textContent=t.text),t.domNode=s,n=G(t,s,e.children,t.children,r)||n,n=W(s,e.properties,t.properties,r)||n,t.properties&&t.properties.afterUpdate&&t.properties.afterUpdate.apply(t.properties.bind||t.properties,[s,r,t.vnodeSelector,t.properties,t.children]);return n&&t.properties&&t.properties.updateAnimation&&t.properties.updateAnimation(s,t.properties,e.properties),i};let J=(e,t)=>({getLastRender:()=>e,update:r=>{if(e.vnodeSelector!==r.vnodeSelector)throw new Error("The selector for the root VNode may not be changed. (consider using dom.merge and add one extra level to the virtual DOM)");let s=e;e=r,V(s,r,t)},domNode:e.domNode});const X={namespace:void 0,performanceLogger:()=>{},eventHandlerInterceptor:void 0,styleApplyer:(e,t,r)=>{"-"===t.charAt(0)?e.style.setProperty(t,r):e.style[t]=r}};let Y,K=e=>x(X,e),Q=(e,t,r)=>(r=K(r),H(t,e,void 0,r),J(t,r)),ee=(e,t,r)=>(r=K(r),H(t,e.parentNode,e,r),J(t,r)),te=(e,t,r)=>(r=K(r),t.domNode=e,B(e,t,r),J(t,r)),re=(e,t,r)=>(r=K(r),H(t,e.parentNode,e,r),e.parentNode.removeChild(e),J(t,r));Y=Array.prototype.find?(e,t)=>e.find(t):(e,t)=>e.filter(t)[0];const se={handleInterceptedEvent:(e,t,r,s)=>(e.scheduleRender(),t.properties[`on${s.type}`].apply(t.properties.bind||r,[s]))},ie={namespace:void 0,performanceLogger:()=>{},eventHandlerInterceptor:void 0,styleApplyer:(e,t,r)=>{t.startsWith("-")?e.style.setProperty(t,r):e.style[t]=r}},ne=(e,t,r=!1)=>{let s=e;return t.forEach((e,i)=>{const n=s?.children?((e,t)=>e.find(t))(s.children,t=>t.domNode===e):void 0;r&&!n&&i!==t.length-1||(s=n)}),s};var oe=r(14813),ae=r(2741);let le;le="components/assets";var he=r(36563);const de=Symbol("widget"),ce=Symbol("widget-test-data"),ue=[],pe={},fe=new WeakMap;function ge(e,t){let r=t.children;if(r?.length)for(let t=0;t<r.length;++t)r[t]=ge(e,r[t]);else r=ue;const s=t.vnodeSelector;if(ye(s)){const i=t.properties||pe,n=i.key||s,o={key:n,afterCreate:me,afterUpdate:ve,afterRemoved:_e,parentWidget:e,widgetConstructor:s,widgetProperties:{...i,key:n,children:r}};return{vnodeSelector:s.vnodeSelector,properties:o,children:void 0,text:void 0,domNode:null}}return t}function me(e,t,r,{parentWidget:s,widgetConstructor:i,widgetProperties:n}){const o=new i(n);o.container=e,fe.set(e,o),o.afterCreate?.(o,e),s.addHandles((0,he.hA)(()=>_e(e))),queueMicrotask(()=>{o[ce].projector?.renderNow()})}function ve(e,t,r,{widgetProperties:s}){const i=fe.get(e);i&&(i.set(s),i.afterUpdate?.(i,e))}function _e(e){const t=fe.get(e);t&&(t.afterRemoved?.(t,e),t.destroy(),fe.delete(e))}function ye(e){return"function"==typeof e&&e[de]}const we=new Set;new Map;const Se=new Map;function Ie(){Se.clear()}function Ae(e){Se.delete(e)}var ke=r(98291),Ue=r(96211);function Ce(...e){const t=ke.A.acquire();for(let r=0;r<e.length;r++){const s=e[r],i=typeof s;if("string"===i)t.push(s);else if(Array.isArray(s))t.push.apply(t,s);else if("object"===i)for(const e in s)s[e]&&t.push(e)}const r=t.join(" ");return ke.A.release(t),r}(()=>{const e=new Map;new ResizeObserver(t=>{Ie();for(const r of t)e.get(r.target)?.(r)})})();var be,Pe=r(10838),xe=r(73444);let Te=0;function Re(e,t){const r=Object.prototype.hasOwnProperty;for(const s in t)r.call(t,s)&&r.call(e,s)&&(null!=e[s]&&null!=t[s]&&"object"==typeof e[s]&&"object"==typeof t[s]?Re(e[s],t[s]):e[s]=t[s]);return e}const Oe=(e=>{let t;const r={...se,...e},s=(n=r,{...ie,...n}),i=s.performanceLogger;var n;let o,a=!0,l=!1;const h=[],d=[],c=(e,n,o)=>{let a;s.eventHandlerInterceptor=(e,s,n,o)=>function(e){let s;i("domEvent",e);const n=((e,t)=>{const r=[];for(;e&&e!==t;)r.push(e),e=e.parentNode;return r})(e.currentTarget,a.domNode),o=n.some(e=>customElements.get(e?.tagName?.toLowerCase()));if(e.eventPhase!==Event.CAPTURING_PHASE&&o){const t=e.composedPath(),r=t.slice(t.indexOf(e.currentTarget),t.indexOf(a.domNode)).reverse();s=ne(a.getLastRender(),r,!0)}else n.reverse(),s=ne(a.getLastRender(),n);let l;return s&&(l=r.handleInterceptedEvent(t,s,this,e)),i("domEventProcessed",e),l},r.postProcessProjectionOptions?.(s);const l=o();a=e(n,l,s),s.eventHandlerInterceptor=void 0,h.push(a),d.push(o),r.afterFirstVNodeRendered&&r.afterFirstVNodeRendered(a,l)};let u=()=>{if(o=void 0,a){a=!1,i("renderStart",void 0);for(let e=0;e<h.length;e++){const t=d[e]();i("rendered",void 0);try{h[e].update(t)}catch(e){console.error(e)}i("patched",void 0)}i("renderDone",void 0),a=!0}};return r.modifyDoRenderImplementation&&(u=r.modifyDoRenderImplementation(u,h,d)),t={renderNow:u,scheduleRender:()=>{o||l||(o=requestAnimationFrame(u))},stop:()=>{o&&(cancelAnimationFrame(o),o=void 0),l=!0},resume:()=>{l=!1,a=!0,t.scheduleRender()},append:(e,t)=>{c(Q,e,t)},insertBefore:(e,t)=>{c(ee,e,t)},merge:(e,t)=>{c(te,e,t)},replace:(e,t)=>{c(re,e,t)},detach:e=>{for(let t=0;t<d.length;t++)if(d[t]===e)return d.splice(t,1),h.splice(t,1)[0];throw new Error("renderFunction was not found")}},t})({postProcessProjectionOptions(e){const t=e.eventHandlerInterceptor,r=/capture$/i;e.eventHandlerInterceptor=(e,s,i,n)=>{const o=t?.(e,s,i,n),a=r.test(e);if(!((e=e.replace(r,"")).toLowerCase()in i)||a){const t=e[2].toLowerCase()+e.slice(3),r=e=>o?.call(i,e);i.addEventListener(t,r,a);const s=()=>i.removeEventListener(t,r,a),l=n.afterRemoved;n.afterRemoved=e=>{l?.(e),s()}}return o}},handleInterceptedEvent(e,t,r,s){const{eventPhase:i,type:n}=s,o=i===Event.CAPTURING_PHASE;let a=`on${n}${o?"capture":""}`;const l=t.properties;(l&&a in l||(a=`on${n[0].toUpperCase()}${n.slice(1)}${o?"Capture":""}`,l&&a in l))&&(Ie(),e.scheduleRender(),l[a].call(l.bind||r,s))}});let Ne=!1,Me=class extends((0,_.g)(l.nJ)){static{this[be]=!0}constructor(e,t){super(e,t),this._attached=!1,this._projector=Oe,this._readyForTrueRender=!1,this.key=this,this.autoRenderingEnabled=!0,this._loadLocale=(0,u.sg)(async()=>{if(this._messageBundleProps?.length){const e=await Promise.allSettled(this._messageBundleProps.map(async({bundlePath:e,propertyName:t})=>{if(this.destroyed)return;let r=await(0,Pe.ud)(e);this.destroyed||(this.uiStrings&&Object.keys(this.uiStrings)&&(r=Re((0,d.o8)(r),this.uiStrings)),this[t]=r)}));if(this.destroyed)return;for(const t of e)"rejected"===t.status&&g.A.getLogger(this).error("widget-intl:locale-error",this.declaredClass,t.reason)}await this.loadLocale()}),this.addHandles((0,he.hA)()),oe.qu||(0,oe.Qu)((0,p.s2)((0,ae.s)("components/assets")));const r="esri-widget-uid-"+(0,w.lk)(),s=this.render.bind(this);this._trackingTarget=new A.r(()=>{this.autoRenderingEnabled&&this.scheduleRender()});const i=()=>({vnodeSelector:"div",properties:{key:`${r}-hidden`,class:"",styles:{display:"none"}},domNode:null,children:void 0,text:void 0}),n=()=>{if(!this._readyForTrueRender||this.destroyed)return null;const e=s()??i(),t=e.properties??={};if(t.key??=r,ye(e.vnodeSelector)){if(!this.visible)return i()}else this.visible?t.styles||(t.styles={}):(t.class="",t.styles={display:"none"}),t.styles.display??="";let n=0;return e.children?.forEach(e=>{ye(e.vnodeSelector)||(e.properties??={},e.properties.key??=`${this.id}--${n++}`)}),ge(this,e)};this.render=()=>{if(Ne)return n();let e=function(e){return Se.get(e)}(this)??null;if(e)return e;this._trackingTarget.clear(),Ne=!0;try{e=(0,I.a)(this._trackingTarget,n)}catch(e){throw g.A.getLogger(this).error(e),e}finally{Ne=!1}return e&&function(e,t){Se.set(e,t)}(this,e),e};const o=this.beforeFirstRender();o?this._resourcesFetch=o.then(()=>{this.destroyed||(this._readyForTrueRender=!0,this._postInitialize())}):(this._resourcesFetch=Promise.resolve().then(()=>{this.destroyed||this._postInitialize()}),this._readyForTrueRender=!0),this.addResolvingPromise(this._resourcesFetch),function(e){we.add(e),e.finally(()=>we.delete(e))}(this._resourcesFetch)}normalizeCtorArgs(e,t){const r={...e};return t&&(r.container=t),r}postInitialize(){}beforeFirstRender(){const e=this.loadDependencies();return this._messageBundleProps?.length||e?Promise.all([e,this._loadLocale()]).then(()=>{}).catch(u.jH):null}loadDependencies(){return null}loadLocale(){return null}destroy(){this.destroyed||((0,v.pR)(this._trackingTarget),(0,v.pR)(this.viewModel),this._detach(this.container),this._set("container",null),this.render=()=>null,this._projector=null,Ae(this))}set container(e){this._get("container")||this._set("container",e)}castContainer(e){return"string"==typeof(t=e)?document.getElementById(t):t??null;var t}get destroyed(){return super.destroyed}get domNode(){return this.container}set domNode(e){this.container=e}get icon(){return null}set icon(e){this._overrideIfSome("icon",e)}get id(){return this._get("id")||this.container?.id||Date.now().toString(16)+"-widget-"+Te++}set id(e){e&&this._set("id",e)}get label(){return this.declaredClass.split(".").pop()}set label(e){this._overrideIfSome("label",e)}get renderable(){return this._resourcesFetch}get visible(){return this._get("visible")}set visible(e){this._set("visible",e)}get[(be=de,ce)](){return{projector:this._projector}}static{this.vnodeSelector="div"}render(){throw new Error("not implemented")}scheduleRender(){this.destroyed||(Ae(this),this._projector.scheduleRender())}classes(...e){return Ce.apply(this,e)}renderNow(){Ae(this),this._projector.renderNow()}_postInitialize(){if(this.destroyed)return;this.scheduleRender(),this._delegatedEventNames?.length&&this.addHandles((0,y.wB)(()=>this.viewModel,(e,t)=>{t&&this.removeHandles("delegated-events"),e&&(0,h.wb)(e)&&this.addHandles(this._delegatedEventNames.map(t=>(0,h.on)(e,t,e=>{this.emit(t,e)})),"delegated-events")},y.pc)),this.postInitialize();const e=async()=>{await this._loadLocale().catch(u.jH),this.scheduleRender()};this.addHandles([(0,xe.oQ)(e),(0,y.wB)(()=>this.uiStrings,e)]),this.addHandles((0,y.z7)(()=>this.container,e=>{this.destroyed||this._attach(e)},{initial:!0,once:!0}))}_attach(e){e&&(this._projector.merge(e,this.render),this._attached=!0)}_detach(e){this._attached&&(this._projector.detach(this.render),this._attached=!1),e?.parentNode?.removeChild(e)}};(0,i.Cg)([(0,f.MZ)()],Me.prototype,"_readyForTrueRender",void 0),(0,i.Cg)([(0,f.MZ)({value:null})],Me.prototype,"container",null),(0,i.Cg)([(0,S.w)("container")],Me.prototype,"castContainer",null),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"icon",null),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"id",null),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"label",null),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"renderable",null),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"uiStrings",void 0),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"viewModel",void 0),(0,i.Cg)([(0,f.MZ)({value:!0})],Me.prototype,"visible",null),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"key",void 0),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"children",void 0),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"afterCreate",void 0),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"afterUpdate",void 0),(0,i.Cg)([(0,f.MZ)()],Me.prototype,"afterRemoved",void 0),Me=(0,i.Cg)([(0,m.$)("esri.widgets.Widget")],Me);const De=Me;function je(e){return(t,r)=>{t.hasOwnProperty("_messageBundleProps")||(t._messageBundleProps=t._messageBundleProps?t._messageBundleProps.slice():[]),t._messageBundleProps.push({bundlePath:e,propertyName:r})}}var Ee=function(e){return{vnodeSelector:"",properties:void 0,children:void 0,text:e.toString(),domNode:null}},Le=function(e,t){for(var r=0,s=e.length;r<s;r++){var i=e[r];Array.isArray(i)?Le(i,t):null!=i&&!1!==i&&(i.hasOwnProperty("vnodeSelector")||(i=Ee(i)),t.push(i))}};function qe(e,t,...r){return"function"!=typeof e||ye(e)?function(e,t){for(var r=[],s=2;s<arguments.length;s++)r[s-2]=arguments[s];if(1===r.length&&"string"==typeof r[0])return{vnodeSelector:e,properties:t||void 0,children:void 0,text:r[0],domNode:null};var i=[];return Le(r,i),{vnodeSelector:e,properties:t||void 0,children:i,text:void 0,domNode:null}}(e,t??null,...r):e(t,...r)}var $e=r(20150);function Ze(e){return`calcite-mode-${function(e){return function(){const e=getComputedStyle(document.body).getPropertyValue("--esri-calcite-mode-name").replaceAll(/\W/g,"").toLowerCase();return"dark"===e||"light"===e?e:void 0}()??(0,$e.eg)(e??document.body)}(e)}`}var Fe=r(71754);const Ve="esri-identity-modal",Be={base:Ve,info:`${Ve}__info`,notice:`${Ve}__notice`};let He=class extends De{constructor(e,t){super(e,t),this.container=document.createElement("div"),this.error=null,this.oAuthPrompt=!1,this.open=!1,this.signingIn=!1,this.server=null,this.resource=null,this._usernameInputNode=null,this._passwordInputNode=null,document.body.appendChild(this.container)}loadDependencies(){return function(e){const t=[];for(const r of Object.keys(e))customElements.get(`calcite-${r}`)||t.push(e[r]?.());return t.length>0?Promise.all(t):null}({button:()=>Promise.all([r.e(9e3),r.e(1436),r.e(6395),r.e(5455)]).then(r.bind(r,37836)),dialog:()=>Promise.all([r.e(9e3),r.e(1436),r.e(6395),r.e(985)]).then(r.bind(r,70985)),input:()=>Promise.all([r.e(9e3),r.e(1436),r.e(3263)]).then(r.bind(r,63263)),label:()=>Promise.all([r.e(9e3),r.e(224)]).then(r.bind(r,87843)),notice:()=>Promise.all([r.e(9e3),r.e(1436),r.e(8098)]).then(r.bind(r,48098))})}get title(){return this.commonMessages?.auth.signIn}render(){const{open:e,title:t,messages:r,signingIn:s,oAuthPrompt:i,server:n,resource:o,error:a}=this,{info:l,oAuthInfo:h,lblItem:d,invalidUser:c,noAuthService:u,lblUser:p,lblPwd:f,lblCancel:g,lblSigning:m,lblOk:v}=r;return qe("div",{class:this.classes(Be.base,Ze(this.container))},qe("form",{bind:this,onsubmit:this._submit},qe("calcite-dialog",{bind:this,heading:t,modal:!0,open:e,outsideCloseDisabled:!0,scale:"s",widthScale:"s",onCalciteDialogClose:this._cancel,onCalciteDialogOpen:this._focusUsernameInput},qe("div",{class:Be.info},(0,Fe.V)(i?h:l,{server:n&&/\.arcgis\.com/i.test(n)?"ArcGIS Online":n,resource:`(${o||d})`})),a?qe("calcite-notice",{class:Be.notice,icon:"exclamation-mark-triangle",kind:"danger",open:!0},qe("div",{slot:"message"},a.details?.httpStatus?c:u)):null,i?null:[qe("calcite-label",null,p,qe("calcite-input",{afterCreate:e=>this._usernameInputNode=e,autocomplete:"off",bind:this,name:"username",required:!0,spellcheck:!1,type:"text",value:""})),qe("calcite-label",null,f,qe("calcite-input",{afterCreate:e=>this._passwordInputNode=e,bind:this,name:"password",required:!0,type:"password",value:""}))],qe("calcite-button",{appearance:"outline",bind:this,onclick:this._cancel,slot:"footer-end",type:"button"},g),qe("calcite-button",{loading:!!s,slot:"footer-end",type:"submit"},s?m:v))))}_focusUsernameInput(){return async function(e){await(0,Ue.$m)((0,u.Mq)(void 0));const t=e();t&&("setFocus"in t&&"function"==typeof t.setFocus?await t.setFocus():t instanceof HTMLElement&&t.focus())}(()=>this._usernameInputNode)}_cancel(){this._set("signingIn",!1),this.open=!1,this._usernameInputNode&&(this._usernameInputNode.value=""),this._passwordInputNode&&(this._passwordInputNode.value=""),this.emit("cancel")}_submit(e){e.preventDefault(),this._set("signingIn",!0);const t=this.oAuthPrompt?{}:{username:this._usernameInputNode?.value,password:this._passwordInputNode?.value};this.emit("submit",t)}};(0,i.Cg)([(0,f.MZ)({readOnly:!0})],He.prototype,"container",void 0),(0,i.Cg)([(0,f.MZ)(),je("esri/t9n/common")],He.prototype,"commonMessages",void 0),(0,i.Cg)([(0,f.MZ)()],He.prototype,"error",void 0),(0,i.Cg)([(0,f.MZ)(),je("esri/identity/t9n/identity")],He.prototype,"messages",void 0),(0,i.Cg)([(0,f.MZ)()],He.prototype,"oAuthPrompt",void 0),(0,i.Cg)([(0,f.MZ)()],He.prototype,"open",void 0),(0,i.Cg)([(0,f.MZ)()],He.prototype,"signingIn",void 0),(0,i.Cg)([(0,f.MZ)()],He.prototype,"server",void 0),(0,i.Cg)([(0,f.MZ)({readOnly:!0})],He.prototype,"title",null),(0,i.Cg)([(0,f.MZ)()],He.prototype,"resource",void 0),He=(0,i.Cg)([(0,m.$)("esri.identity.IdentityModal")],He);const ze=He,We="esriJSAPIOAuth";class Ge{constructor(e,t){this.oAuthInfo=null,this.storage=null,this.appId=null,this.codeVerifier=null,this.expires=null,this.refreshToken=null,this.ssl=null,this.stateUID=null,this.token=null,this.userId=null,this.oAuthInfo=e,this.storage=t,this._init()}isValid(){let e=!1;if(this.oAuthInfo&&this.userId&&(this.refreshToken||this.token))if(null==this.expires&&this.refreshToken)e=!0;else if(this.expires){const t=Date.now();this.expires>t&&(this.expires-t)/1e3>60*this.oAuthInfo.minTimeUntilExpiration&&(e=!0)}return e}save(){if(!this.storage)return!1;const e=this._load(),t=this.oAuthInfo;if(t?.authNamespace&&t.portalUrl){let r=e[t.authNamespace];r||(r=e[t.authNamespace]={}),this.appId||(this.appId=t.appId),r[t.portalUrl]={appId:this.appId,codeVerifier:this.codeVerifier,expires:this.expires,refreshToken:this.refreshToken,ssl:this.ssl,stateUID:this.stateUID,token:this.token,userId:this.userId};try{this.storage.setItem(We,JSON.stringify(e))}catch(e){return console.warn(e),!1}return!0}return!1}destroy(){const e=this._load(),t=this.oAuthInfo;if(t?.appId&&t?.portalUrl&&(null==this.expires||this.expires>Date.now())&&(this.refreshToken||this.token)){const e=t.portalUrl.replace(/^http:/i,"https:")+"/sharing/rest/oauth2/revokeToken";(0,o.A)(e,{authMode:"anonymous",keepAlive:!0,method:"post",query:{f:"json",auth_token:this.refreshToken||this.token,client_id:t.appId,token_type_hint:this.refreshToken?"refresh_token":"access_token"}})}if(t?.authNamespace&&t.portalUrl&&this.storage){const r=e[t.authNamespace];if(r){delete r[t.portalUrl];try{this.storage.setItem(We,JSON.stringify(e))}catch(e){console.log(e)}}}t&&(t._oAuthCred=null,this.oAuthInfo=null)}_init(){const e=this._load(),t=this.oAuthInfo;if(t?.authNamespace&&t.portalUrl){let r=e[t.authNamespace];r&&(r=r[t.portalUrl],r&&(this.appId=r.appId,this.codeVerifier=r.codeVerifier,this.expires=r.expires,this.refreshToken=r.refreshToken,this.ssl=r.ssl,this.stateUID=r.stateUID,this.token=r.token,this.userId=r.userId))}}_load(){let e={};if(this.storage){const t=this.storage.getItem(We);if(t)try{e=JSON.parse(t)}catch(e){console.warn(e)}}return e}}Ge.prototype.declaredClass="esri.identity.OAuthCredential";var Je,Xe=r(25482);let Ye=class extends Xe.o{static{Je=this}constructor(e){super(e),this._oAuthCred=null,this.appId=null,this.authNamespace="/",this.expiration=20160,this.flowType="auto",this.forceLogin=!1,this.forceUserId=!1,this.locale=null,this.minTimeUntilExpiration=30,this.popup=!1,this.popupCallbackUrl="oauth-callback.html",this.popupWindowFeatures="height=490,width=800,resizable,scrollbars,status",this.portalUrl="https://www.arcgis.com",this.preserveUrlHash=!1,this.userId=null}clone(){return Je.fromJSON(this.toJSON())}};(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"appId",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"authNamespace",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"expiration",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"flowType",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"forceLogin",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"forceUserId",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"locale",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"minTimeUntilExpiration",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"popup",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"popupCallbackUrl",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"popupWindowFeatures",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"portalUrl",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"preserveUrlHash",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Ye.prototype,"userId",void 0),Ye=Je=(0,i.Cg)([(0,m.$)("esri.identity.OAuthInfo")],Ye);const Ke=Ye;let Qe=class extends Xe.o{constructor(e){super(e),this.adminTokenServiceUrl=null,this.currentVersion=null,this.hasPortal=null,this.hasServer=null,this.owningSystemUrl=null,this.owningTenant=null,this.server=null,this.shortLivedTokenValidity=null,this.tokenServiceUrl=null,this.webTierAuth=null}};(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"adminTokenServiceUrl",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"currentVersion",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"hasPortal",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"hasServer",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"owningSystemUrl",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"owningTenant",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"server",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"shortLivedTokenValidity",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"tokenServiceUrl",void 0),(0,i.Cg)([(0,f.MZ)({json:{write:!0}})],Qe.prototype,"webTierAuth",void 0),Qe=(0,i.Cg)([(0,m.$)("esri.identity.ServerInfo")],Qe);const et=Qe;var tt=r(39131);const rt={},st=e=>{const t=new p.s0(e.owningSystemUrl).host,r=new p.s0(e.server).host,s=/.+\.arcgis\.com$/i;return s.test(t)&&s.test(r)},it=(e,t)=>!!(st(e)&&t&&t.some(t=>t.test(e.server)));let nt=null,ot=null;try{nt=window.localStorage,ot=window.sessionStorage}catch{}class at extends l.a${constructor(){super(),this._portalConfig=globalThis.esriGeowConfig,this.serverInfos=[],this.oAuthInfos=[],this.credentials=[],this._soReqs=[],this._xoReqs=[],this._portals=[],this._defaultOAuthInfo=null,this._defaultTokenValidity=60,this.dialog=null,this.tokenValidity=null,this.normalizeWebTierAuth=!1,this._appOrigin="null"!==window.origin?window.origin:window.location.origin,this._appUrlObj=(0,p.An)(window.location.href),this._busy=null,this._rejectOnPersistedPageShow=!1,this._oAuthLocationParams=null,this._gwTokenUrl="/sharing/rest/generateToken",this._agsRest="/rest/services",this._agsPortal=/\/sharing(\/|$)/i,this._agsAdmin=/(https?:\/\/[^/]+\/[^/]+)\/admin\/?(\/.*)?$/i,this._adminSvcs=/\/rest\/admin\/services(\/|$)/i,this._gwDomains=[{regex:/^https?:\/\/www\.arcgis\.com/i,customBaseUrl:"maps.arcgis.com",tokenServiceUrl:"https://www.arcgis.com/sharing/rest/generateToken"},{regex:/^https?:\/\/(?:dev|[a-z\d-]+\.mapsdev)\.arcgis\.com/i,customBaseUrl:"mapsdev.arcgis.com",tokenServiceUrl:"https://dev.arcgis.com/sharing/rest/generateToken"},{regex:/^https?:\/\/(?:devext|[a-z\d-]+\.mapsdevext)\.arcgis\.com/i,customBaseUrl:"mapsdevext.arcgis.com",tokenServiceUrl:"https://devext.arcgis.com/sharing/rest/generateToken"},{regex:/^https?:\/\/(?:qaext|[a-z\d-]+\.mapsqa)\.arcgis\.com/i,customBaseUrl:"mapsqa.arcgis.com",tokenServiceUrl:"https://qaext.arcgis.com/sharing/rest/generateToken"},{regex:/^https?:\/\/[a-z\d-]+\.maps\.arcgis\.com/i,customBaseUrl:"maps.arcgis.com",tokenServiceUrl:"https://www.arcgis.com/sharing/rest/generateToken"}],this._legacyFed=[],this._regexSDirUrl=/http.+\/rest\/services\/?/gi,this._regexServerType=/(\/(FeatureServer|GPServer|GeoDataServer|GeocodeServer|GeoenrichmentServer|GeometryServer|GlobeServer|ImageServer|KnowledgeGraphServer|MapServer|MissionServer|MobileServer|NAServer|NetworkDiagramServer|OGCFeatureServer|ParcelFabricServer|RelationalCatalogServer|SceneServer|StreamServer|UtilityNetworkServer|ValidationServer|VectorTileServer|VersionManagementServer|VideoServer)).*/gi,this._gwUser=/http.+\/users\/([^/]+).*/i,this._gwItem=/http.+\/items\/([^/]+).*/i,this._gwGroup=/http.+\/groups\/([^/]+).*/i,this._rePortalTokenSvc=/\/sharing(\/rest)?\/generatetoken/i,this._createDefaultOAuthInfo=!0,this._hasTestedIfAppIsOnPortal=!1,this._getPlatformSelfError=null,this._getOAuthLocationParams(),window.addEventListener("pageshow",e=>{this._pageShowHandler(e)})}registerServers(e){const t=this.serverInfos;t?(e=e.filter(e=>!this.findServerInfo(e.server)),this.serverInfos=t.concat(e)):this.serverInfos=e,e.forEach(e=>{e.owningSystemUrl&&this._portals.push(e.owningSystemUrl),e.hasPortal&&this._portals.push(e.server)})}registerOAuthInfos(e){const t=this.oAuthInfos;if(t){for(const r of e){const e=this.findOAuthInfo(r.portalUrl);e&&t.splice(t.indexOf(e),1)}this.oAuthInfos=t.concat(e)}else this.oAuthInfos=e}registerToken(e){e={...e};const t=this._sanitizeUrl(e.server),r=this._isServerRsrc(t);let s,i=this.findServerInfo(t),n=!0;i||(i=new et,i.server=this._getServerInstanceRoot(t),r?i.hasServer=!0:(i.tokenServiceUrl=this._getTokenSvcUrl(t),i.hasPortal=!0),this.registerServers([i])),s=this._findCredential(t),s?(delete e.server,Object.assign(s,e),n=!1):(s=new lt({userId:e.userId,server:i.server??void 0,token:e.token,expires:e.expires,ssl:e.ssl,scope:r?"server":"portal"}),s.resources=[t],this.credentials.push(s)),s.emitTokenChange(!1),n||s.refreshServerTokens()}toJSON(){return(0,d.oy)({serverInfos:this.serverInfos.map(e=>e.toJSON()),oAuthInfos:this.oAuthInfos.map(e=>e.toJSON()),credentials:this.credentials.map(e=>e.toJSON())})}initialize(e){if(!e)return;"string"==typeof e&&(e=JSON.parse(e));const t=e.serverInfos,r=e.oAuthInfos,s=e.credentials;if(t){const e=[];t.forEach(t=>{t.server&&t.tokenServiceUrl&&e.push(t.declaredClass?t:new et(t))}),e.length&&this.registerServers(e)}if(r){const e=[];r.forEach(t=>{t.appId&&e.push(t.declaredClass?t:new Ke(t))}),e.length&&this.registerOAuthInfos(e)}s&&s.forEach(e=>{e.server&&e.token&&e.expires&&e.expires>Date.now()&&((e=e.declaredClass?e:new lt(e)).emitTokenChange(),this.credentials.push(e))})}findServerInfo(e){let t;e=this._sanitizeUrl(e);for(const r of this.serverInfos)if(this._hasSameServerInstance(r.server,e)){t=r;break}return t}findOAuthInfo(e){let t;e=this._sanitizeUrl(e);for(const r of this.oAuthInfos)if(this._hasSameServerInstance(r.portalUrl,e)){t=r;break}return t}findCredential(e,t){if(!e)return;let r;e=this._sanitizeUrl(e);const s=this._isServerRsrc(e)?"server":"portal";if(t){for(const i of this.credentials)if(this._hasSameServerInstance(i.server,e)&&t===i.userId&&i.scope===s){r=i;break}}else for(const t of this.credentials)if(this._hasSameServerInstance(t.server,e)&&-1!==this._getIdenticalSvcIdx(e,t)&&t.scope===s){r=t;break}return r}getCredential(e,t){let r,s=!1,i=!0;t&&(s=!(!t.token&&!t.credential),r=t.error,i=!1!==t.prompt),t={...t},e=this._sanitizeUrl(e);const n=new AbortController,o=(0,u.Tw)();if(t.signal&&(0,u.u7)(t.signal,()=>{n.abort()}),(0,u.u7)(n,()=>{o.reject(new a.A("identity-manager:user-aborted","ABORTED"))}),(0,u.G4)(n))return o.promise;t.signal=n.signal;const l=this._isAdminResource(e),h=s?this.findCredential(e):null;let d;if(h&&498===r?.details?.httpStatus)h.destroy();else if(h)return d=new a.A("identity-manager:not-authorized","You are currently signed in as: '"+h.userId+"'. You do not have access to this resource: "+e,{error:r}),o.reject(d),o.promise;const c=this._findCredential(e,t);if(c)return o.resolve(c),o.promise;let f=this.findServerInfo(e);if(f)!f.hasPortal&&f.server&&f.owningSystemUrl&&this._hasSameServerInstance(f.server,f.owningSystemUrl)&&(f.hasPortal=!0),!f.hasServer&&this._isServerRsrc(e)&&(f._restInfoPms=this._getTokenSvcUrl(e),f.hasServer=!0);else{const t=this._getTokenSvcUrl(e);if(!t)return d=new a.A("identity-manager:unknown-resource","Unknown resource - could not find token service endpoint."),o.reject(d),o.promise;f=new et,f.server=this._getServerInstanceRoot(e),"string"==typeof t?(f.tokenServiceUrl=t,f.hasPortal=!0):(f._restInfoPms=t,f.hasServer=!0),this.registerServers([f])}return f.hasPortal&&void 0===f._selfReq&&(i||(0,p.FX)(f.tokenServiceUrl,this._appOrigin)||this._gwDomains.some(e=>e.tokenServiceUrl===f.tokenServiceUrl))&&(f._selfReq={owningTenant:t?.owningTenant,selfDfd:this._getPortalSelf(f.tokenServiceUrl.replace(this._rePortalTokenSvc,"/sharing/rest/portals/self"),e)}),this._enqueue(e,f,t,o,l)}getResourceName(e){return this._isRESTService(e)?e.replace(this._regexSDirUrl,"").replace(this._regexServerType,"")||"":this._gwUser.test(e)&&e.replace(this._gwUser,"$1")||this._gwItem.test(e)&&e.replace(this._gwItem,"$1")||this._gwGroup.test(e)&&e.replace(this._gwGroup,"$1")||""}generateToken(e,t,r){const s=this._rePortalTokenSvc.test(e.tokenServiceUrl),i=new p.s0(this._appOrigin),n=e.shortLivedTokenValidity;let l,h,d,c,u,f,g,m;t&&(m=this.tokenValidity||n||this._defaultTokenValidity,m>n&&n>0&&(m=n)),r&&(l=r.isAdmin,h=r.serverUrl,d=r.token,f=r.signal,g=r.ssl,e.customParameters=r.customParameters),l?c=e.adminTokenServiceUrl:(c=e.tokenServiceUrl,u=new p.s0(c.toLowerCase()),e.webTierAuth&&r?.serverUrl&&!g&&"http"===i.scheme&&((0,p.FX)(i.uri,c,!0)||"https"===u.scheme&&i.host===u.host&&"7080"===i.port&&"7443"===u.port)&&(c=c.replace(/^https:/i,"http:").replace(/:7443/i,":7080")));const v={query:{request:"getToken",username:t?.username,password:t?.password,serverUrl:h,token:d,expiration:m,referer:l||s?this._appOrigin:null,client:l?"referer":null,f:"json",...e.customParameters},method:"post",authMode:"anonymous",useProxy:this._useProxy(e,r),signal:f};return s||(v.withCredentials=!1),(0,o.A)(c,v).then(r=>{const s=r.data;if(!s?.token)return new a.A("identity-manager:authentication-failed","Unable to generate token");const i=e.server;return rt[i]||(rt[i]={}),t&&(rt[i][t.username]=t.password),s.validity=m,s})}isBusy(){return!!this._busy}async checkSignInStatus(e){return(await this.checkAppAccess(e,"")).credential}checkAppAccess(e,t,r){let s=!1;return this.getCredential(e,{prompt:!1}).then(i=>{let n;const l={f:"json"};if("portal"===i.scope)if(t&&(this._doPortalSignIn(e)||r?.force))n=i.server+"/sharing/rest/oauth2/validateAppAccess",l.client_id=t;else{if(!i.token)return{credential:i};n=i.server+"/sharing/rest"}else{if(!i.token)return{credential:i};n=i.server+"/rest/services"}return i.token&&(l.token=i.token),(0,o.A)(n,{query:l,authMode:"anonymous"}).then(e=>{if(!1===e.data.valid)throw new a.A("identity-manager:not-authorized",`You are currently signed in as: '${i.userId}'.`,e.data);return s=!!e.data.viewOnlyUserTypeApp,{credential:i}}).catch(e=>{if("identity-manager:not-authorized"===e.name)throw e;const t=e.details?.httpStatus;if(498===t)throw i.destroy(),new a.A("identity-manager:not-authenticated","User is not signed in.");if(400===t)throw new a.A("identity-manager:invalid-request","Bad request");return{credential:i}})}).then(e=>({credential:e.credential,viewOnly:s}))}setOAuthResponseHash(e){e&&(e.startsWith("#")&&(e=e.slice(1)),this._processOAuthPopupParams((0,p.zf)(e)))}setOAuthRedirectionHandler(e){this._oAuthRedirectFunc=e}setProtocolErrorHandler(e){this._protocolFunc=e}signIn(e,t,r={}){const s=(0,u.Tw)(),i=()=>{l?.remove(),h?.remove(),this.dialog?.destroy(),this.dialog=l=h=null},n=()=>{i(),this._oAuthDfd=null,s.reject(new a.A("identity-manager:user-aborted","ABORTED"))};r.signal&&(0,u.u7)(r.signal,()=>{n()});const o=new ze({open:!0,resource:this.getResourceName(e),server:t.server});this.dialog=o,this.emit("dialog-create");let l=o.on("cancel",n),h=o.on("submit",e=>{this.generateToken(t,e,{isAdmin:r.isAdmin,signal:r.signal}).then(n=>{i();const o=new lt({userId:e.username,server:t.server??void 0,token:n.token,expires:null!=n.expires?Number(n.expires):null,ssl:!!n.ssl,isAdmin:r.isAdmin,validity:n.validity});s.resolve(o)}).catch(e=>{o.error=e,o.signingIn=!1})});return s.promise}oAuthSignIn(e,t,r,s){this._oAuthDfd=(0,u.Tw)();const i=this._oAuthDfd;let n;s?.signal&&(0,u.u7)(s.signal,()=>{const e=this._oAuthDfd&&this._oAuthDfd.oAuthWin_;e&&!e.closed?e.close():this.dialog&&d()}),i.resUrl_=e,i.sinfo_=t,i.oinfo_=r;const o=r._oAuthCred;if(o.storage&&("authorization-code"===r.flowType||"auto"===r.flowType&&t.currentVersion>=8.4)){let e=crypto.getRandomValues(new Uint8Array(32));n=(0,p.$1)(e),o.codeVerifier=n,e=crypto.getRandomValues(new Uint8Array(32)),o.stateUID=(0,p.$1)(e),o.save()||(o.codeVerifier=n=null)}else o.codeVerifier=null;let l,h;this._getCodeChallenge(n).then(i=>{const n=!s||!1!==s.oAuthPopupConfirmation;if(!r.popup||!n)return void this._doOAuthSignIn(e,t,r,i);const o=new ze({oAuthPrompt:!0,server:t.server,open:!0});this.dialog=o,this.emit("dialog-create"),l=o.on("cancel",d),h=o.on("submit",()=>{c(),this._doOAuthSignIn(e,t,r,i)})});const d=()=>{c(),this._oAuthDfd=null,i.reject(new a.A("identity-manager:user-aborted","ABORTED"))},c=()=>{l?.remove(),h?.remove(),this.dialog?.destroy(),this.dialog=null};return i.promise}destroyCredentials(){this.credentials&&this.credentials.slice().forEach(e=>{e.destroy()}),this.emit("credentials-destroy")}enablePostMessageAuth(e="https://www.arcgis.com/sharing/rest"){this._postMessageAuthHandle&&this._postMessageAuthHandle.remove(),this._postMessageAuthHandle=(0,h.on)(window,"message",t=>{if((t.origin===this._appOrigin||t.origin.endsWith(".arcgis.com"))&&"arcgis:auth:requestCredential"===t.data?.type){const r=t.source;this.getCredential(e).then(e=>{r.postMessage({type:"arcgis:auth:credential",credential:{expires:e.expires,server:e.server,ssl:e.ssl,token:e.token,userId:e.userId}},t.origin)}).catch(e=>{r.postMessage({type:"arcgis:auth:error",error:{name:e.name,message:e.message}},t.origin)})}})}disablePostMessageAuth(){this._postMessageAuthHandle&&(this._postMessageAuthHandle.remove(),this._postMessageAuthHandle=null)}_getOAuthLocationParams(){let e=window.location.hash;if(e){e.startsWith("#")&&(e=e.slice(1));const t=(0,p.zf)(e);let r=!1;if(t.access_token&&t.expires_in&&t.state&&t.hasOwnProperty("username"))try{t.state=JSON.parse(t.state),t.state.portalUrl&&(this._oAuthLocationParams=t,r=!0)}catch{}else if(t.error&&t.error_description&&(console.log("IdentityManager OAuth Error: ",t.error," - ",t.error_description),"access_denied"===t.error&&(r=!0,t.state)))try{t.state=JSON.parse(t.state)}catch{}r&&(window.location.hash=t.state?.hash||"")}let t=window.location.search;if(t){t.startsWith("?")&&(t=t.slice(1));const e=(0,p.zf)(t);let r=!1;if(e.code&&e.state)try{e.state=JSON.parse(e.state),e.state.portalUrl&&e.state.uid&&(this._oAuthLocationParams=e,r=!0)}catch{}else if(e.error&&e.error_description&&(console.log("IdentityManager OAuth Error: ",e.error," - ",e.error_description),"access_denied"===e.error&&(r=!0,e.state)))try{e.state=JSON.parse(e.state)}catch{}if(r){const t={...e};["code","error","error_description","message_code","persist","state"].forEach(e=>{delete t[e]});const r=(0,p.x0)(t),s=window.location.pathname+(r?`?${r}`:"")+(e.state?.hash||"");window.history.replaceState(window.history.state,"",s)}}}_getOAuthToken(e,t,r,s,i){return e=e.replace(/^http:/i,"https:"),(0,o.A)(`${e}/sharing/rest/oauth2/token`,{authMode:"anonymous",method:"post",query:s&&i?{grant_type:"authorization_code",code:t,redirect_uri:s,client_id:r,code_verifier:i}:{grant_type:"refresh_token",refresh_token:t,client_id:r}}).then(e=>e.data)}async _getCodeChallenge(e){if(e&&globalThis.isSecureContext){const t=(new TextEncoder).encode(e),r=await crypto.subtle.digest("SHA-256",t);return(0,p.$1)(new Uint8Array(r))}return null}_pageShowHandler(e){if(e.persisted&&this.isBusy()&&this._rejectOnPersistedPageShow){const e=new a.A("identity-manager:user-aborted","ABORTED");this._errbackFunc(e)}}_findCredential(e,t){let r,s,i,n,o=-1;const a=t?.token,l=t?.resource,h=this._isServerRsrc(e)?"server":"portal",d=this.credentials.filter(t=>this._hasSameServerInstance(t.server,e)&&t.scope===h);if(e=l||e,d.length)if(1===d.length){if(r=d[0],i=this.findServerInfo(r.server),s=i?.owningSystemUrl,n=s?this.findCredential(s,r.userId):void 0,o=this._getIdenticalSvcIdx(e,r),!a)return-1===o&&r.resources.push(e),this._addResource(e,n),r;-1!==o&&(r.resources.splice(o,1),this._removeResource(e,n))}else{let t,r;if(d.some(a=>(r=this._getIdenticalSvcIdx(e,a),-1!==r&&(t=a,i=this.findServerInfo(t.server),s=i?.owningSystemUrl,n=s?this.findCredential(s,t.userId):void 0,o=r,!0))),a)t&&(t.resources.splice(o,1),this._removeResource(e,n));else if(t)return this._addResource(e,n),t}}_findOAuthInfo(e){let t=this.findOAuthInfo(e);if(!t)for(const r of this.oAuthInfos)if(this._isIdProvider(r.portalUrl,e)){t=r;break}return t}_addResource(e,t){t&&-1===this._getIdenticalSvcIdx(e,t)&&t.resources.push(e)}_removeResource(e,t){let r=-1;t&&(r=this._getIdenticalSvcIdx(e,t),r>-1&&t.resources.splice(r,1))}_useProxy(e,t){return t?.isAdmin&&!(0,p.FX)(e.adminTokenServiceUrl,this._appOrigin)||!this._isPortalDomain(e.tokenServiceUrl)&&"10.1"===String(e.currentVersion)&&!(0,p.FX)(e.tokenServiceUrl,this._appOrigin)}_getOrigin(e){const t=new p.s0(e);return t.scheme+"://"+t.host+(null!=t.port?":"+t.port:"")}_getServerInstanceRoot(e){const t=e.toLowerCase();let r=t.indexOf(this._agsRest);return-1===r&&this._isAdminResource(e)&&(r=this._agsAdmin.test(e)?e.replace(this._agsAdmin,"$1").length:e.search(this._adminSvcs)),-1!==r||(0,tt.$E)(t)||(r=t.indexOf("/sharing")),-1===r&&t.endsWith("/")&&(r=t.length-1),r>-1?e.slice(0,r):e}_hasSameServerInstance(e,t){return e.endsWith("/")&&(e=e.slice(0,-1)),e=e.toLowerCase(),t=this._getServerInstanceRoot(t).toLowerCase(),e=(0,tt.qG)(e),t=(0,tt.qG)(t),(e=e.slice(Math.max(0,e.indexOf(":"))))===t.slice(Math.max(0,t.indexOf(":")))}_sanitizeUrl(e){const t=(n.A.request.proxyUrl||"").toLowerCase(),r=t?e.toLowerCase().indexOf(t+"?"):-1;return-1!==r&&(e=e.slice(r+t.length+1)),e=(0,p.S8)(e),(0,p.An)(e).path}_isRESTService(e){return e.includes(this._agsRest)}_isAdminResource(e){return this._agsAdmin.test(e)||this._adminSvcs.test(e)}_isServerRsrc(e){return this._isRESTService(e)||this._isAdminResource(e)}_isIdenticalService(e,t){let r=!1;if(this._isRESTService(e)&&this._isRESTService(t)){const s=this._getSuffix(e).toLowerCase(),i=this._getSuffix(t).toLowerCase();if(r=s===i,!r){const e=/(.*)\/(MapServer|FeatureServer|UtilityNetworkServer).*/gi;r=s.replaceAll(e,"$1")===i.replaceAll(e,"$1")}}else this._isAdminResource(e)&&this._isAdminResource(t)?r=!0:this._isServerRsrc(e)||this._isServerRsrc(t)||!this._isPortalDomain(e)||(r=!0);return r}_isPortalDomain(e){const t=new p.s0(e.toLowerCase()),r=this._portalConfig;let s=this._gwDomains.some(e=>e.regex.test(t.uri));return!s&&r&&(s=this._hasSameServerInstance(this._getServerInstanceRoot(r.restBaseUrl),t.uri)),s||n.A.portalUrl&&(s=(0,p.FX)(t,n.A.portalUrl,!0)),s||(s=this._portals.some(e=>this._hasSameServerInstance(e,t.uri))),s=s||this._agsPortal.test(t.path),s}_isIdProvider(e,t){let r=-1,s=-1;this._gwDomains.forEach((i,n)=>{-1===r&&i.regex.test(e)&&(r=n),-1===s&&i.regex.test(t)&&(s=n)});let i=!1;if(r>-1&&s>-1&&(0===r||4===r?0!==s&&4!==s||(i=!0):1===r?1!==s&&2!==s||(i=!0):2===r?2===s&&(i=!0):3===r&&3===s&&(i=!0)),!i){const r=this.findServerInfo(t),s=r?.owningSystemUrl;s&&st(r)&&this._isPortalDomain(s)&&this._isIdProvider(e,s)&&(i=!0)}return i}_getIdenticalSvcIdx(e,t){let r=-1;for(let s=0;s<t.resources.length;s++){const i=t.resources[s];if(this._isIdenticalService(e,i)){r=s;break}}return r}_getSuffix(e){return e.replace(this._regexSDirUrl,"").replace(this._regexServerType,"$1")}_getTokenSvcUrl(e){let t,r,s;if(this._isRESTService(e)||this._isAdminResource(e)){const s=this._getServerInstanceRoot(e);return t=s+"/admin/generateToken",r=(0,o.A)(e=s+"/rest/info",{query:{f:"json"}}).then(e=>e.data),{adminUrl:t,promise:r}}if(this._isPortalDomain(e)){let t="";if(this._gwDomains.some(r=>(r.regex.test(e)&&(t=r.tokenServiceUrl),!!t)),t||this._portals.some(r=>(this._hasSameServerInstance(r,e)&&(t=r+this._gwTokenUrl),!!t)),t||(s=e.toLowerCase().indexOf("/sharing"),-1!==s&&(t=e.slice(0,s)+this._gwTokenUrl)),t||(t=this._getOrigin(e)+this._gwTokenUrl),t){const r=new p.s0(e).port;/^http:\/\//i.test(e)&&"7080"===r&&(t=t.replace(/:7080/i,":7443")),t=t.replace(/http:/i,"https:")}return t}}_processOAuthResponseParams(e,t,r){const s=t._oAuthCred;if(e.code){const i=s.codeVerifier;return s.codeVerifier=null,s.stateUID=null,s.save(),this._getOAuthToken(r.server,e.code,t.appId,this._getRedirectURI(t,!0),i).then(i=>{const n=new lt({userId:i.username,server:r.server??void 0,token:i.access_token,expires:Date.now()+1e3*i.expires_in,ssl:i.ssl,oAuthState:e.state,_oAuthCred:s});return t.userId=n.userId,s.storage=i.persist?nt:ot,s.refreshToken=i.refresh_token,s.token=null,s.expires=i.refresh_token_expires_in?Date.now()+1e3*i.refresh_token_expires_in:null,s.userId=n.userId,s.ssl=n.ssl,s.save(),n})}const i=new lt({userId:e.username,server:r.server??void 0,token:e.access_token,expires:Date.now()+1e3*Number(e.expires_in),ssl:"true"===e.ssl,oAuthState:e.state,_oAuthCred:s});return t.userId=i.userId,s.storage=e.persist?nt:ot,s.refreshToken=null,s.token=i.token,s.expires=i.expires,s.userId=i.userId,s.ssl=i.ssl,s.save(),Promise.resolve(i)}_processOAuthPopupParams(e){const t=this._oAuthDfd;if(this._oAuthDfd=null,t)if(clearInterval(this._oAuthIntervalId),this._oAuthOnPopupHandle?.remove(),e.error){const r="access_denied"===e.error,s=new a.A(r?"identity-manager:user-aborted":"identity-manager:authentication-failed",r?"ABORTED":"OAuth: "+e.error+" - "+e.error_description);t.reject(s)}else this._processOAuthResponseParams(e,t.oinfo_,t.sinfo_).then(e=>{t.resolve(e)}).catch(e=>{t.reject(e)})}_setOAuthResponseQueryString(e){e&&(e.startsWith("?")&&(e=e.slice(1)),this._processOAuthPopupParams((0,p.zf)(e)))}async _exchangeToken(e,t,r){return(await(0,o.A)(`${e}/sharing/rest/oauth2/exchangeToken`,{authMode:"anonymous",method:"post",query:{f:"json",client_id:t,token:r}})).data.token}async _getPlatformSelf(e,t){if(this._getPlatformSelfError&&Date.now()-this._getPlatformSelfError[1]<1e3)throw this._getPlatformSelfError[0];e=e.replace(/^http:/i,"https:");try{const r=await(0,o.A)(`${e}/sharing/rest/oauth2/platformSelf`,{authMode:"anonymous",headers:{"X-Esri-Auth-Client-Id":t,"X-Esri-Auth-Redirect-Uri":window.location.href.replace(/#.*$/,"")},method:"post",query:{f:"json",expiration:30},withCredentials:!0});return this._getPlatformSelfError=null,r.data}catch(e){throw"OAUTH_0066"===e.details?.messageCode&&(this._getPlatformSelfError=[e,Date.now()]),e}}_getPortalSelf(e,t){let r;return this._gwDomains.some(t=>(t.regex.test(e)&&(r=t.customBaseUrl),!!r)),r?Promise.resolve({allSSL:!0,currentVersion:"8.4",customBaseUrl:r,portalMode:"multitenant",supportsOAuth:!0}):(this._appOrigin.startsWith("https:")?e=e.replace(/^http:/i,"https:").replace(/:7080/i,":7443"):/^http:/i.test(t)&&(e=e.replace(/^https:/i,"http:").replace(/:7443/i,":7080")),(0,o.A)(e,{query:{f:"json"},authMode:"anonymous",withCredentials:!0}).then(e=>e.data))}_doPortalSignIn(e){const t=this._portalConfig,r=window.location.href,s=this.findServerInfo(e);return!(!t&&!this._isPortalDomain(r)||!(s?s.hasPortal||s.owningSystemUrl&&this._isPortalDomain(s.owningSystemUrl):this._isPortalDomain(e))||!(this._isIdProvider(r,e)||t&&(this._hasSameServerInstance(this._getServerInstanceRoot(t.restBaseUrl),e)||this._isIdProvider(t.restBaseUrl,e))||(0,p.FX)(r,e,!0)))}_checkProtocol(e,t,r,s){let i=!0;const n=s?t.adminTokenServiceUrl:t.tokenServiceUrl;return n.trim().toLowerCase().startsWith("https:")&&!this._appOrigin.startsWith("https:")&&(0,p.zs)(n)&&(i=!!this._protocolFunc&&!!this._protocolFunc({resourceUrl:e,serverInfo:t}),!i)&&r(new a.A("identity-manager:aborted","Aborted the Sign-In process to avoid sending password over insecure connection.")),i}_enqueue(e,t,r,s,i,n){return s||(s=(0,u.Tw)()),s.resUrl_=e,s.sinfo_=t,s.options_=r,s.admin_=i,s.refresh_=n,this._busy?this._hasSameServerInstance(this._getServerInstanceRoot(e),this._busy.resUrl_)?(this._oAuthDfd&&this._oAuthDfd.oAuthWin_&&this._oAuthDfd.oAuthWin_.focus(),this._soReqs.push(s)):this._xoReqs.push(s):this._doSignIn(s),s.promise}_doSignIn(e){this._busy=e,this._rejectOnPersistedPageShow=!1;const t=t=>{const r=e.options_?.resource,s=e.resUrl_,i=e.refresh_;let n=!1;this.credentials.includes(t)||(i&&this.credentials.includes(i)?(i.userId=t.userId,i.token=t.token,i.expires=t.expires,i.validity=t.validity,i.ssl=t.ssl,i.creationTime=t.creationTime,n=!0,t=i):this.credentials.push(t)),t.resources||(t.resources=[]),t.resources.includes(r||s)||t.resources.push(r||s),t.scope=this._isServerRsrc(s)?"server":"portal",t.emitTokenChange();const o=this._soReqs,a={};this._soReqs=[],o.forEach(e=>{if(!this._isIdenticalService(s,e.resUrl_)){const r=this._getSuffix(e.resUrl_);a[r]||(a[r]=!0,t.resources.push(e.resUrl_))}}),e.resolve(t),o.forEach(e=>{this._hasSameServerInstance(this._getServerInstanceRoot(s),e.resUrl_)?e.resolve(t):this._soReqs.push(e)}),this._busy=e.resUrl_=e.sinfo_=e.refresh_=null,n||this.emit("credential-create",{credential:t}),this._soReqs.length?this._doSignIn(this._soReqs.shift()):this._xoReqs.length&&this._doSignIn(this._xoReqs.shift())},r=t=>{e.reject(t),this._busy=e.resUrl_=e.sinfo_=e.refresh_=null,this._soReqs.length?this._doSignIn(this._soReqs.shift()):this._xoReqs.length&&this._doSignIn(this._xoReqs.shift())},s=(i,n,o,l)=>{const d=e.sinfo_,c=!e.options_||!1!==e.options_.prompt,f=d.hasPortal&&this._findOAuthInfo(e.resUrl_);let g,m;if(i)t(new lt({userId:i,server:d.server??void 0,token:o??void 0,expires:null!=l?Number(l):null,ssl:!!n}));else if(window!==window.parent&&this._appUrlObj.query?.["arcgis-auth-origin"]&&this._appUrlObj.query?.["arcgis-auth-portal"]&&this._hasSameServerInstance(this._getServerInstanceRoot(this._appUrlObj.query["arcgis-auth-portal"]),e.resUrl_)){window.parent.postMessage({type:"arcgis:auth:requestCredential"},this._appUrlObj.query["arcgis-auth-origin"]);const s=(0,h.on)(window,"message",e=>{e.source===window.parent&&e.data&&("arcgis:auth:credential"===e.data.type?(s.remove(),e.data.credential.expires<Date.now()?r(new a.A("identity-manager:credential-request-failed","Parent application's token has expired.")):t(new lt(e.data.credential))):"arcgis:auth:error"===e.data.type&&(s.remove(),"tokenExpiredError"===e.data.error.name?r(new a.A("identity-manager:credential-request-failed","Parent application's token has expired.")):r(a.A.fromJSON(e.data.error))))});(0,u.u7)(e.options_?.signal,()=>{s.remove()})}else if(f){let i=f._oAuthCred;if(!i){const e=new Ge(f,nt),t=new Ge(f,ot);e.isValid()&&t.isValid()?e.expires>t.expires?(i=e,t.destroy()):(i=t,e.destroy()):i=e.isValid()?e:t,f._oAuthCred=i}if(i.isValid()){g=new lt({userId:i.userId??void 0,server:d.server??void 0,token:i.token??void 0,expires:i.expires,ssl:i.ssl??void 0,_oAuthCred:i});const n=f.appId!==i.appId&&this._doPortalSignIn(e.resUrl_);n||i.refreshToken?(e._pendingDfd=i.refreshToken?this._getOAuthToken(d.server,i.refreshToken,i.appId).then(e=>(g.expires=Date.now()+1e3*e.expires_in,g.token=e.access_token,g)):Promise.resolve(g),e._pendingDfd.then(e=>n?this._exchangeToken(e.server,f.appId,e.token).then(t=>(e.token=t,e)).catch(()=>e):e).then(e=>{t(e)}).catch(e=>{const t=e.details?.httpStatus;t>0&&404!==t?(i.destroy(),s()):r(e)})):t(g)}else if(this._oAuthLocationParams&&this._hasSameServerInstance(f.portalUrl,this._oAuthLocationParams.state.portalUrl)&&(this._oAuthLocationParams.access_token||this._oAuthLocationParams.code&&this._oAuthLocationParams.state.uid===i.stateUID&&i.codeVerifier)){const s=this._oAuthLocationParams;this._oAuthLocationParams=null,e._pendingDfd=this._processOAuthResponseParams(s,f,d).then(e=>{t(e)}).catch(r)}else{const s=()=>{c?e._pendingDfd=this.oAuthSignIn(e.resUrl_,d,f,e.options_).then(t,r):(m=new a.A("identity-manager:not-authenticated","User is not signed in."),r(m))};this._doPortalSignIn(e.resUrl_)?e._pendingDfd=this._getPlatformSelf(d.server,f.appId).then(e=>{(0,p.FX)(e.portalUrl,this._appOrigin,!0)?(g=new lt({userId:e.username,server:d.server??void 0,expires:Date.now()+1e3*e.expires_in,token:e.token}),t(g)):s()}).catch(s):s()}}else if(c){if(this._checkProtocol(e.resUrl_,d,r,e.admin_)){let s=e.options_;e.admin_&&(s=s||{},s.isAdmin=!0),e._pendingDfd=this.signIn(e.resUrl_,d,s).then(t,r)}}else m=new a.A("identity-manager:not-authenticated","User is not signed in."),r(m)},i=()=>{const s=e.sinfo_,i=s.owningSystemUrl,n=e.options_;let o,a,l,h;if(n&&(o=n.token,a=n.error,l=n.prompt),h=this._findCredential(i,{token:o,resource:e.resUrl_}),!h)for(const e of this.credentials)if(this._isIdProvider(i,e.server)){h=e;break}if(h){const i=this.findCredential(e.resUrl_,h.userId);if(i)t(i);else if(it(s,this._legacyFed)){const e=h.toJSON();e.server=s.server,e.resources=null,t(new lt(e))}else(e._pendingDfd=this.generateToken(this.findServerInfo(h.server),null,{serverUrl:e.resUrl_,token:h.token,signal:e.options_.signal,ssl:h.ssl})).then(r=>{t(new lt({userId:h?.userId,server:s.server??void 0,token:r.token,expires:null!=r.expires?Number(r.expires):null,ssl:!!r.ssl,isAdmin:e.admin_,validity:r.validity}))},r)}else this._busy=null,o&&(e.options_.token=null),(e._pendingDfd=this.getCredential(i.replace(/\/?$/,"/sharing"),{resource:e.resUrl_,owningTenant:s.owningTenant,signal:e.options_.signal,token:o,error:a,prompt:l})).then(()=>{this._enqueue(e.resUrl_,e.sinfo_,e.options_,e,e.admin_)},t=>{e.resUrl_=e.sinfo_=e.refresh_=null,e.reject(t)})};this._errbackFunc=r;const n=e.sinfo_.owningSystemUrl,o=this._isServerRsrc(e.resUrl_),l=e.sinfo_._restInfoPms;l?l.promise.then(t=>{const r=e.sinfo_;if(r._restInfoPms){r.adminTokenServiceUrl=r._restInfoPms.adminUrl,r._restInfoPms=null,r.tokenServiceUrl=((0,c.wc)("authInfo.tokenServicesUrl",t)||(0,c.wc)("authInfo.tokenServiceUrl",t)||(0,c.wc)("tokenServiceUrl",t))??null,r.shortLivedTokenValidity=(0,c.wc)("authInfo.shortLivedTokenValidity",t)??null,r.currentVersion=t.currentVersion,r.owningTenant=t.owningTenant;const e=r.owningSystemUrl=t.owningSystemUrl;e&&this._portals.push(e)}o&&r.owningSystemUrl?i():s()},()=>{e.sinfo_._restInfoPms=null;const t=new a.A("identity-manager:server-identification-failed","Unknown resource - could not find token service endpoint.");r(t)}):o&&n?i():e.sinfo_._selfReq?e.sinfo_._selfReq.selfDfd.then(t=>{const r={};let s,i,n,o;return t&&(s=t.user?.username,r.username=s,r.allSSL=t.allSSL,i=t.supportsOAuth,o=parseFloat(t.currentVersion),"multitenant"===t.portalMode&&(n=t.customBaseUrl),e.sinfo_.currentVersion=o),e.sinfo_.webTierAuth=!!s,s&&this.normalizeWebTierAuth?this.generateToken(e.sinfo_,null,{ssl:r.allSSL}).catch(()=>null).then(e=>(r.portalToken=e?.token,r.tokenExpiration=e?.expires,r)):!s&&i&&o>=4.4&&!this._findOAuthInfo(e.resUrl_)?this._generateOAuthInfo({portalUrl:e.sinfo_.server,customBaseUrl:n,owningTenant:e.sinfo_._selfReq.owningTenant}).catch(()=>null).then(()=>r):r}).catch(()=>null).then(t=>{e.sinfo_._selfReq=null,t?s(t.username,t.allSSL,t.portalToken,t.tokenExpiration):s()}):s()}_generateOAuthInfo(e){let t,r=null,s=e.portalUrl;const i=e.customBaseUrl,n=e.owningTenant,a=!this._defaultOAuthInfo&&this._createDefaultOAuthInfo&&!this._hasTestedIfAppIsOnPortal;if(a){r=this._appUrlObj.path;const e=r.search(/\/(apps|home)\//);r=e>-1?r.slice(0,e):null}return a&&r?(this._hasTestedIfAppIsOnPortal=!0,t=(0,o.A)(r+"/sharing/rest",{query:{f:"json"}}).then(()=>{this._defaultOAuthInfo=new Ke({appId:"arcgisonline",popupCallbackUrl:r+"/home/oauth-callback.html"})})):t=Promise.resolve(),t.then(()=>{if(this._defaultOAuthInfo)return s=s.replace(/^http:/i,"https:"),(0,o.A)(s+"/sharing/rest/oauth2/validateRedirectUri",{query:{accountId:n,client_id:this._defaultOAuthInfo.appId,redirect_uri:(0,p.s2)(this._defaultOAuthInfo.popupCallbackUrl),f:"json"}}).then(e=>{if(e.data.valid){const t=this._defaultOAuthInfo.clone();e.data.urlKey&&i?t.portalUrl="https://"+e.data.urlKey.toLowerCase()+"."+i:t.portalUrl=s,t.popup=window!==window.top||!((0,p.FX)(s,this._appOrigin)||this._gwDomains.some(e=>e.regex.test(s)&&e.regex.test(this._appOrigin))),this.oAuthInfos.push(t)}})})}_doOAuthSignIn(e,t,r,s){const i=r._oAuthCred,n={portalUrl:r.portalUrl};!r.popup&&r.preserveUrlHash&&window.location.hash&&(n.hash=window.location.hash),i.stateUID&&(n.uid=i.stateUID);const o={client_id:r.appId,response_type:i.codeVerifier?"code":"token",state:JSON.stringify(n),expiration:r.expiration,locale:r.locale,redirect_uri:this._getRedirectURI(r,!!i.codeVerifier)};r.forceLogin&&(o.force_login=!0),r.forceUserId&&r.userId&&(o.prepopulatedusername=r.userId),!r.popup&&this._doPortalSignIn(e)&&(o.redirectToUserOrgUrl=!0),i.codeVerifier&&(o.code_challenge=s||i.codeVerifier,o.code_challenge_method=s?"S256":"plain");const l=r.portalUrl.replace(/^http:/i,"https:")+"/sharing/oauth2/authorize",d=l+"?"+(0,p.x0)(o);if(r.popup){const e=window.open(d,"esriJSAPIOAuth",r.popupWindowFeatures);if(e)e.focus(),this._oAuthDfd.oAuthWin_=e,this._oAuthIntervalId=setInterval(()=>{if(e.closed){clearInterval(this._oAuthIntervalId),this._oAuthOnPopupHandle.remove();const e=this._oAuthDfd;if(e){const t=new a.A("identity-manager:user-aborted","ABORTED");e.reject(t)}}},500),this._oAuthOnPopupHandle=(0,h.on)(window,["arcgis:auth:hash","arcgis:auth:location:search"],e=>{"arcgis:auth:hash"===e.type?this.setOAuthResponseHash(e.detail):this._setOAuthResponseQueryString(e.detail)});else{const e=new a.A("identity-manager:popup-blocked","ABORTED");this._oAuthDfd.reject(e)}}else this._rejectOnPersistedPageShow=!0,this._oAuthRedirectFunc?this._oAuthRedirectFunc({authorizeParams:o,authorizeUrl:l,resourceUrl:e,serverInfo:t,oAuthInfo:r}):window.location.href=d}_getRedirectURI(e,t){const r=window.location.href.replace(/#.*$/,"");if(e.popup)return(0,p.s2)(e.popupCallbackUrl);if(t){const e=(0,p.An)(r);return e.query&&["code","error","error_description","message_code","persist","state"].forEach(t=>{delete e.query[t]}),(0,p.a6)(e.path,e.query)}return r}}at.prototype.declaredClass="esri.identity.IdentityManagerBase";let lt=class extends l.nJ{constructor(e){super(e),this._oAuthCred=null,this.tokenRefreshBuffer=2,e?._oAuthCred&&(this._oAuthCred=e._oAuthCred)}initialize(){this.resources=this.resources||[],null==this.creationTime&&(this.creationTime=Date.now())}refreshToken(){const e=s.id,t=e.findServerInfo(this.server),r=t?.owningSystemUrl,i=!!r&&"server"===this.scope,n=i&&it(t,e._legacyFed),o=t.webTierAuth,a=o&&e.normalizeWebTierAuth,l=rt[this.server],h=l?.[this.userId];let d,c=this.resources&&this.resources[0],u=i?e.findServerInfo(r):null,p={username:this.userId,password:h};if(o&&!a)return;i&&!u&&e.serverInfos.some(t=>(e._isIdProvider(r,t.server)&&(u=t),!!u));const f=u?e.findCredential(u.server,this.userId):null;if(!i||f){if(!n){if(i)d={serverUrl:c,token:f?.token,ssl:f?.ssl};else if(a)p=null,d={ssl:this.ssl};else{if(!h){let r;return c&&(c=e._sanitizeUrl(c),this._enqueued=1,r=e._enqueue(c,t,null,null,this.isAdmin,this),r.then(()=>{this._enqueued=0,this.refreshServerTokens()}).catch(()=>{this._enqueued=0})),r}this.isAdmin&&(d={isAdmin:!0})}return e.generateToken(i?u:t,i?null:p,d).then(e=>{this.token=e.token,this.expires=null!=e.expires?Number(e.expires):null,this.creationTime=Date.now(),this.validity=e.validity,this.emitTokenChange(),this.refreshServerTokens()}).catch(()=>{})}f?.refreshToken()}}refreshServerTokens(){if("portal"===this.scope){const e=s.id;e.credentials.forEach(t=>{const r=e.findServerInfo(t.server),s=r?.owningSystemUrl;t!==this&&t.userId===this.userId&&s&&"server"===t.scope&&(e._hasSameServerInstance(this.server,s)||e._isIdProvider(s,this.server))&&(it(r,e._legacyFed)?(t.token=this.token,t.expires=this.expires,t.creationTime=this.creationTime,t.validity=this.validity,t.emitTokenChange()):t.refreshToken())})}}emitTokenChange(e){clearTimeout(this._refreshTimer);const t=s.id,r=this.server?t.findServerInfo(this.server):null,i=r?.owningSystemUrl,n=i?t.findServerInfo(i):null;!1===e||i&&"portal"!==this.scope&&(!n?.webTierAuth||t.normalizeWebTierAuth)||null==this.expires&&null==this.validity||this._startRefreshTimer(),this.emit("token-change")}destroy(){this.userId=this.server=this.token=this.expires=this.validity=this.resources=this.creationTime=null,this._oAuthCred&&(this._oAuthCred.destroy(),this._oAuthCred=null);const e=s.id,t=e.credentials.indexOf(this);t>-1&&e.credentials.splice(t,1),this.emitTokenChange(),this.emit("destroy")}toJSON(){const e=(0,d.oy)({userId:this.userId,server:this.server,token:this.token,expires:this.expires,validity:this.validity,ssl:this.ssl,isAdmin:this.isAdmin,creationTime:this.creationTime,scope:this.scope}),t=this.resources;return t&&t.length>0&&(e.resources=t.slice()),e}_startRefreshTimer(){clearTimeout(this._refreshTimer);const e=6e4*this.tokenRefreshBuffer,t=2**31-1;let r=(this.validity?this.creationTime+6e4*this.validity:this.expires)-Date.now();r<0?r=0:r>t&&(r=t),this._refreshTimer=setTimeout(this.refreshToken.bind(this),r>e?r-e:r)}};(0,i.Cg)([(0,f.MZ)()],lt.prototype,"creationTime",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"expires",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"isAdmin",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"oAuthState",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"resources",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"scope",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"server",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"ssl",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"token",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"tokenRefreshBuffer",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"userId",void 0),(0,i.Cg)([(0,f.MZ)()],lt.prototype,"validity",void 0),lt=(0,i.Cg)([(0,m.$)("esri.identity.Credential")],lt);class ht extends at{}ht.prototype.declaredClass="esri.identity.IdentityManager";const dt=new ht;(0,s.Aq)(dt)}}]);
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2507],{10838:(a,t,e)=>{e.d(t,{ao:()=>u,ud:()=>h,xO:()=>T});var n=e(49186),r=e(36563),i=e(74887),o=e(73444);const s={ar:!0,bg:!0,bs:!0,ca:!0,cs:!0,da:!0,de:!0,el:!0,en:!0,es:!0,et:!0,fi:!0,fr:!0,he:!0,hr:!0,hu:!0,id:!0,it:!0,ja:!0,ko:!0,lt:!0,lv:!0,nb:"no",nl:!0,no:!0,nn:"no",pl:!0,pt:"pt-BR","pt-BR":!0,"pt-PT":!0,ro:!0,ru:!0,sk:!0,sl:!0,sr:!0,sv:!0,th:!0,tr:!0,uk:!0,vi:!0,zh:"zh-CN","zh-CN":!0,"zh-HK":!0,"zh-TW":!0};function d(a){if(function(a){return a in s}(a)){const t=s[a];return!0===t?a:t}return null}const m=[],c=new Map;function l(a){for(const t of c.keys())S(a.pattern,t)&&c.delete(t)}function u(a){return m.includes(a)||(l(a),m.unshift(a)),(0,r.hA)(()=>{const t=m.indexOf(a);t>-1&&(m.splice(t,1),l(a))})}async function h(a){const t=(0,o.JK)();c.has(a)||c.set(a,async function(a,t){const e=[];for(const n of m)if(S(n.pattern,a))try{return await n.fetchMessageBundle(a,t)}catch(a){e.push(a)}if(e.length)throw new n.A("intl:message-bundle-error",`Errors occurred while loading "${a}"`,{errors:e});throw new n.A("intl:no-message-bundle-loader",`No loader found for message bundle "${a}"`)}(a,t));const e=c.get(a);return e&&await g.add(e),e}function T(a){const t=(0,o.lR)(a);return t?d(a)??d(t):null}function S(a,t){return"string"==typeof a?t.startsWith(a):a.test(t)}(0,o.Ml)(()=>{c.clear()});const g=new class{constructor(){this._numLoading=0,this._dfd=null}async waitForAll(){this._dfd&&await this._dfd.promise}add(a){return this._increase(),a.then(()=>this._decrease(),()=>this._decrease()),this.waitForAll()}_increase(){this._numLoading++,this._dfd||(this._dfd=(0,i.Tw)())}_decrease(){this._numLoading=Math.max(this._numLoading-1,0),this._dfd&&0===this._numLoading&&(this._dfd.resolve(),this._dfd=null)}}},56400:(a,t,e)=>{e.d(t,{ZS:()=>d,hv:()=>m,wr:()=>c,P6:()=>s});var n=e(98623);const r=new Map([["AUS Central Standard Time","Australia/Darwin"],["AUS Eastern Standard Time","Australia/Sydney"],["Afghanistan Standard Time","Asia/Kabul"],["Alaskan Standard Time","America/Anchorage"],["Aleutian Standard Time","America/Adak"],["Altai Standard Time","Asia/Barnaul"],["Arab Standard Time","Asia/Riyadh"],["Arabian Standard Time","Asia/Dubai"],["Arabic Standard Time","Asia/Baghdad"],["Argentina Standard Time","America/Buenos_Aires"],["Astrakhan Standard Time","Europe/Astrakhan"],["Atlantic Standard Time","America/Halifax"],["Aus Central W. Standard Time","Australia/Eucla"],["Azerbaijan Standard Time","Asia/Baku"],["Azores Standard Time","Atlantic/Azores"],["Bahia Standard Time","America/Bahia"],["Bangladesh Standard Time","Asia/Dhaka"],["Belarus Standard Time","Europe/Minsk"],["Bougainville Standard Time","Pacific/Bougainville"],["Canada Central Standard Time","America/Regina"],["Cape Verde Standard Time","Atlantic/Cape_Verde"],["Caucasus Standard Time","Asia/Yerevan"],["Cen. Australia Standard Time","Australia/Adelaide"],["Central America Standard Time","America/Guatemala"],["Central Asia Standard Time","Asia/Bishkek"],["Central Brazilian Standard Time","America/Cuiaba"],["Central Europe Standard Time","Europe/Budapest"],["Central European Standard Time","Europe/Warsaw"],["Central Pacific Standard Time","Pacific/Guadalcanal"],["Central Standard Time","America/Chicago"],["Central Standard Time (Mexico)","America/Mexico_City"],["Chatham Islands Standard Time","Pacific/Chatham"],["China Standard Time","Asia/Shanghai"],["Cuba Standard Time","America/Havana"],["Dateline Standard Time","Etc/GMT+12"],["E. Africa Standard Time","Africa/Nairobi"],["E. Australia Standard Time","Australia/Brisbane"],["E. Europe Standard Time","Europe/Chisinau"],["E. South America Standard Time","America/Sao_Paulo"],["Easter Island Standard Time","Pacific/Easter"],["Eastern Standard Time","America/New_York"],["Eastern Standard Time (Mexico)","America/Cancun"],["Egypt Standard Time","Africa/Cairo"],["Ekaterinburg Standard Time","Asia/Yekaterinburg"],["FLE Standard Time","Europe/Kiev"],["Fiji Standard Time","Pacific/Fiji"],["GMT Standard Time","Europe/London"],["GTB Standard Time","Europe/Bucharest"],["Georgian Standard Time","Asia/Tbilisi"],["Greenland Standard Time","America/Godthab"],["Greenwich Standard Time","Atlantic/Reykjavik"],["Haiti Standard Time","America/Port-au-Prince"],["Hawaiian Standard Time","Pacific/Honolulu"],["India Standard Time","Asia/Calcutta"],["Iran Standard Time","Asia/Tehran"],["Israel Standard Time","Asia/Jerusalem"],["Jordan Standard Time","Asia/Amman"],["Kaliningrad Standard Time","Europe/Kaliningrad"],["Korea Standard Time","Asia/Seoul"],["Libya Standard Time","Africa/Tripoli"],["Line Islands Standard Time","Pacific/Kiritimati"],["Lord Howe Standard Time","Australia/Lord_Howe"],["Magadan Standard Time","Asia/Magadan"],["Magallanes Standard Time","America/Punta_Arenas"],["Marquesas Standard Time","Pacific/Marquesas"],["Mauritius Standard Time","Indian/Mauritius"],["Middle East Standard Time","Asia/Beirut"],["Montevideo Standard Time","America/Montevideo"],["Morocco Standard Time","Africa/Casablanca"],["Mountain Standard Time","America/Denver"],["Mountain Standard Time (Mexico)","America/Mazatlan"],["Myanmar Standard Time","Asia/Rangoon"],["N. Central Asia Standard Time","Asia/Novosibirsk"],["Namibia Standard Time","Africa/Windhoek"],["Nepal Standard Time","Asia/Katmandu"],["New Zealand Standard Time","Pacific/Auckland"],["Newfoundland Standard Time","America/St_Johns"],["Norfolk Standard Time","Pacific/Norfolk"],["North Asia East Standard Time","Asia/Irkutsk"],["North Asia Standard Time","Asia/Krasnoyarsk"],["North Korea Standard Time","Asia/Pyongyang"],["Omsk Standard Time","Asia/Omsk"],["Pacific SA Standard Time","America/Santiago"],["Pacific Standard Time","America/Los_Angeles"],["Pacific Standard Time (Mexico)","America/Tijuana"],["Pakistan Standard Time","Asia/Karachi"],["Paraguay Standard Time","America/Asuncion"],["Qyzylorda Standard Time","Asia/Qyzylorda"],["Romance Standard Time","Europe/Paris"],["Russia Time Zone 10","Asia/Srednekolymsk"],["Russia Time Zone 11","Asia/Kamchatka"],["Russia Time Zone 3","Europe/Samara"],["Russian Standard Time","Europe/Moscow"],["SA Eastern Standard Time","America/Cayenne"],["SA Pacific Standard Time","America/Bogota"],["SA Western Standard Time","America/La_Paz"],["SE Asia Standard Time","Asia/Bangkok"],["Saint Pierre Standard Time","America/Miquelon"],["Sakhalin Standard Time","Asia/Sakhalin"],["Samoa Standard Time","Pacific/Apia"],["Sao Tome Standard Time","Africa/Sao_Tome"],["Saratov Standard Time","Europe/Saratov"],["Singapore Standard Time","Asia/Singapore"],["South Africa Standard Time","Africa/Johannesburg"],["South Sudan Standard Time","Africa/Juba"],["Sri Lanka Standard Time","Asia/Colombo"],["Sudan Standard Time","Africa/Khartoum"],["Syria Standard Time","Asia/Damascus"],["Taipei Standard Time","Asia/Taipei"],["Tasmania Standard Time","Australia/Hobart"],["Tocantins Standard Time","America/Araguaina"],["Tokyo Standard Time","Asia/Tokyo"],["Tomsk Standard Time","Asia/Tomsk"],["Tonga Standard Time","Pacific/Tongatapu"],["Transbaikal Standard Time","Asia/Chita"],["Turkey Standard Time","Europe/Istanbul"],["Turks And Caicos Standard Time","America/Grand_Turk"],["US Eastern Standard Time","America/Indianapolis"],["US Mountain Standard Time","America/Phoenix"],["UTC","Etc/GMT"],["UTC+01","Etc/GMT-1"],["UTC+02","Etc/GMT-2"],["UTC+03","Etc/GMT-3"],["UTC+04","Etc/GMT-4"],["UTC+05","Etc/GMT-5"],["UTC+06","Etc/GMT-6"],["UTC+07","Etc/GMT-7"],["UTC+08","Etc/GMT-8"],["UTC+09","Etc/GMT-9"],["UTC+10","Etc/GMT-10"],["UTC+11","Etc/GMT-11"],["UTC+12","Etc/GMT-12"],["UTC+13","Etc/GMT-13"],["UTC+14","Etc/GMT-14"],["UTC-01","Etc/GMT+1"],["UTC-02","Etc/GMT+2"],["UTC-03","Etc/GMT+3"],["UTC-04","Etc/GMT+4"],["UTC-05","Etc/GMT+5"],["UTC-06","Etc/GMT+6"],["UTC-07","Etc/GMT+7"],["UTC-08","Etc/GMT+8"],["UTC-09","Etc/GMT+9"],["UTC-10","Etc/GMT+10"],["UTC-11","Etc/GMT+11"],["UTC-12","Etc/GMT+12"],["Ulaanbaatar Standard Time","Asia/Ulaanbaatar"],["Venezuela Standard Time","America/Caracas"],["Vladivostok Standard Time","Asia/Vladivostok"],["Volgograd Standard Time","Europe/Volgograd"],["W. Australia Standard Time","Australia/Perth"],["W. Central Africa Standard Time","Africa/Lagos"],["W. Europe Standard Time","Europe/Berlin"],["W. Mongolia Standard Time","Asia/Hovd"],["West Asia Standard Time","Asia/Tashkent"],["West Bank Standard Time","Asia/Hebron"],["West Pacific Standard Time","Pacific/Port_Moresby"],["Yakutsk Standard Time","Asia/Yakutsk"],["Yukon Standard Time","America/Whitehorse"]]);var i=e(28097);const o="shortOffset";function s(a,t=!1){return{json:{read:{source:a,reader:(t,e)=>e[a]?d(e[a]):null},write:!!t&&{allowNull:!0,writer(t,e){e[a]=t?function(a){return{timeZoneIANA:a}}(t):null}}}}}function d(a,t=n.qU){return a?"timeZoneIANA"in a?a.timeZoneIANA:function(a,t=n.qU){if(!a||!r.has(a.timeZone))return t;const e=r.get(a.timeZone);return a.timeZone.startsWith("UTC")||a.respectsDaylightSaving?e:function(a){const t=i.c9.local().setZone(a),e=Math.min(t.set({month:1,day:1}).offset,t.set({month:5}).offset);return 0===e?"Etc/UTC":`Etc/GMT${i.mQ.instance(-e).formatOffset(0,"narrow")}`}(e)}(a,t):t}function m(a,t,e,r,i){if(t&&"date"===i)return{timeZone:n.n$,timeZoneName:void 0};const s=r.timeStyle||r.hour,d=e===n.L5;return{timeZone:d?"timestamp-offset"===i?void 0:a??n.n$:e,timeZoneName:d&&s?o:void 0}}function c(a){const t=new Set(["etc/utc","etc/gmt","gmt"]),e=new Set(Intl.supportedValuesOf("timeZone").map(a=>a.toLowerCase()));return a===n.qU||a===n.L5||t.has(a.toLowerCase())||e.has(a.toLowerCase())}},65529:(a,t,e)=>{e.d(t,{Zt:()=>i,a$:()=>o,bk:()=>s,nJ:()=>d});var n=e(69622),r=e(36563);const i=a=>{const t=a;return class extends t{constructor(){super(...arguments),this._listenersMap=null}clearEvents(){this._listenersMap?.clear(),this._listenersMap=null}destroy(){this.clearEvents()}emit(a,t){let e=this._listenersMap?.get(a);if(!e)return!1;let n=!1;for(const a of e.slice()){const e="deref"in a?a.deref():a;e?e?.call(this,t):n=!0}return n&&(e=e.filter(a=>!("deref"in a)||null!=a.deref()),this._listenersMap.set(a,e)),e.length>0}on(a,t){if(Array.isArray(a)){const e=a.map(a=>this.on(a,t));return(0,r.vE)(e)}if(a.includes(","))throw new TypeError("Evented.on() with a comma delimited string of event types is not supported");this._listenersMap??=new Map;const e=this._listenersMap.get(a)||[];return e.push(t),this._listenersMap.set(a,e),(0,r.hA)(()=>{const e=this._listenersMap?.get(a),n=e?.indexOf(t)??-1;n>=0&&e.splice(n,1)})}once(a,t){const e=this.on(a,a=>{e.remove();const n="deref"in t?t.deref():t;n?.call(null,a)});return e}hasEventListener(a){const t=this._listenersMap?.get(a);return null!=t&&t.length>0}}},o=i(class{}),s=o,d=i(n.A)},66552:(a,t,e)=>{e.d(t,{J:()=>r,O:()=>o});var n=e(93637);class r{constructor(a,t={ignoreUnknown:!1,useNumericKeys:!1}){this._jsonToAPI=a,this._options=t,this.apiValues=[],this.jsonValues=[],this._apiToJSON=function(a){const t={};for(const e in a)t[a[e]]=e;return t}(a),this.apiValues=i(this._apiToJSON),this.jsonValues=i(this._jsonToAPI),this.read=a=>this.fromJSON(a),this.write=(a,t,e)=>{const r=this.toJSON(a);void 0!==r&&(0,n.sM)(e,r,t)},this.write.isJSONMapWriter=!0}toJSON(a){if(null==a)return null;if(this._apiToJSON.hasOwnProperty(a)){const t=this._apiToJSON[a];return this._options.useNumericKeys?+t:t}return this._options.ignoreUnknown?null:a}fromJSON(a){return null!=a&&this._jsonToAPI.hasOwnProperty(a)?this._jsonToAPI[a]:this._options.ignoreUnknown?void 0:a}}function i(a){const t=[];for(const e in a)t.push(e);return t.sort(),t}function o(){return function(a,t){return new r(a,{ignoreUnknown:!0,...t})}}},73444:(a,t,e)=>{e.d(t,{JK:()=>d,Ml:()=>g,QC:()=>l,lR:()=>c,oQ:()=>T});var n=e(36563);let r;e(44208);const i=globalThis.esriConfig?.locale??globalThis.dojoConfig?.locale,o=globalThis.document?.documentElement;function s(){const a=o?.getAttribute("lang"),t=globalThis.navigator?.language;return i??a??t??"en"}function d(){return void 0===r&&(r=s()),r}const m=/^(?<language>[a-z]{2,3})(?:-(?<extlang>[a-z]{3}))?(?:-[A-Z][a-z]{3})?(?:-(?<region>[A-Z]{2}|\d{3}))?(?:-.*)?$/;function c(a=d()){return u(a)?.language}function l(a=d()){const t=u(a);return t?.language&&t?.extlang?a.replace(`${t.language}-`,""):a}function u(a=d()){return m.exec(a)?.groups}const h=[];function T(a){return h.push(a),(0,n.hA)(()=>{h.splice(h.indexOf(a),1)})}new Map;const S=[];function g(a){return S.push(a),(0,n.hA)(()=>S.splice(S.indexOf(a),1))}function A(){const a=s();r!==a&&([...S].forEach(t=>t(a)),r=a,[...h].forEach(t=>t(a)))}globalThis.addEventListener?.("languagechange",A),o&&new MutationObserver(()=>{A()}).observe(o,{attributeFilter:["lang"]})},79901:(a,t,e)=>{e.d(t,{w:()=>d});var n=e(56507),r=e(96156);const i=Object.prototype.toString;function o(a){const t="__accessorMetadata__"in a?(0,n.dp)(a):a;return function(...a){if(a.push(t),"number"==typeof a[2])throw new Error("Using @cast has parameter decorator is not supported since 4.16");return s.apply(this,a)}}function s(a,t,e,n){(0,r.z4)(a,t).cast=n}function d(...a){if(3!==a.length||"string"!=typeof a[1])return 1===a.length&&"[object Function]"===i.call(a[0])?o(a[0]):1===a.length&&"string"==typeof a[0]?function(a){return(t,e)=>{(0,r.z4)(t,a).cast=t[e]}}(a[0]):void 0}},97770:(a,t,e)=>{e.d(t,{Ey:()=>P,F8:()=>L,J2:()=>v,Yq:()=>b,_v:()=>p,iS:()=>U,wj:()=>G});var n=e(66552),r=e(73444),i=e(98623),o=(e(56400),e(28097));const s={year:void 0,month:void 0,day:void 0,weekday:void 0},d={hour:void 0,minute:void 0,second:void 0},m={timeZone:i.n$},c={year:"numeric",month:"numeric",day:"numeric"},l={year:"numeric",month:"long",day:"numeric"},u={year:"numeric",month:"short",day:"numeric"},h={year:"numeric",month:"long",weekday:"long",day:"numeric"},T={hour:"numeric",minute:"numeric"},S={...T,second:"numeric"},g={hourCycle:"h23"},A={...T,...g},f={...S,...g},y={"short-date":c,"short-date-short-time":{...c,...T},"short-date-short-time-24":{...c,...A},"short-date-long-time":{...c,...S},"short-date-long-time-24":{...c,...f},"short-date-le":c,"short-date-le-short-time":{...c,...T},"short-date-le-short-time-24":{...c,...A},"short-date-le-long-time":{...c,...S},"short-date-le-long-time-24":{...c,...f},"long-month-day-year":l,"long-month-day-year-short-time":{...l,...T},"long-month-day-year-short-time-24":{...l,...A},"long-month-day-year-long-time":{...l,...S},"long-month-day-year-long-time-24":{...l,...f},"day-short-month-year":u,"day-short-month-year-short-time":{...u,...T},"day-short-month-year-short-time-24":{...u,...A},"day-short-month-year-long-time":{...u,...S},"day-short-month-year-long-time-24":{...u,...f},"long-date":h,"long-date-short-time":{...h,...T},"long-date-short-time-24":{...h,...A},"long-date-long-time":{...h,...S},"long-date-long-time-24":{...h,...f},"long-month-year":{month:"long",year:"numeric"},"short-month-year":{month:"short",year:"numeric"},year:{year:"numeric"},"short-time":T,"long-time":S},p=(0,n.O)()({shortDate:"short-date",shortDateShortTime:"short-date-short-time",shortDateShortTime24:"short-date-short-time-24",shortDateLongTime:"short-date-long-time",shortDateLongTime24:"short-date-long-time-24",shortDateLE:"short-date-le",shortDateLEShortTime:"short-date-le-short-time",shortDateLEShortTime24:"short-date-le-short-time-24",shortDateLELongTime:"short-date-le-long-time",shortDateLELongTime24:"short-date-le-long-time-24",longMonthDayYear:"long-month-day-year",longMonthDayYearShortTime:"long-month-day-year-short-time",longMonthDayYearShortTime24:"long-month-day-year-short-time-24",longMonthDayYearLongTime:"long-month-day-year-long-time",longMonthDayYearLongTime24:"long-month-day-year-long-time-24",dayShortMonthYear:"day-short-month-year",dayShortMonthYearShortTime:"day-short-month-year-short-time",dayShortMonthYearShortTime24:"day-short-month-year-short-time-24",dayShortMonthYearLongTime:"day-short-month-year-long-time",dayShortMonthYearLongTime24:"day-short-month-year-long-time-24",longDate:"long-date",longDateShortTime:"long-date-short-time",longDateShortTime24:"long-date-short-time-24",longDateLongTime:"long-date-long-time",longDateLongTime24:"long-date-long-time-24",longMonthYear:"long-month-year",shortMonthYear:"short-month-year",year:"year"}),M={ar:"ar-u-nu-latn-ca-gregory",nn:"no-NN"},E=new Intl.DateTimeFormat("bs",{month:"long"}).formatToParts(new Date(2025,2)),C=E.find(({type:a})=>"month"===a)?.value.toLowerCase();function k(){const a=(0,r.lR)();return(a&&M[a])??(0,r.QC)()}"mart"!==C&&(M.bs="sr-Latn-CS");let w=new WeakMap;const _=y["short-date-short-time"];function v(a){return y[a]}function b(a,t=_){return function(a){let t=w.get(a);if(!t){const e=k(),n=G(a.timeZone??i.qU),r={...a,timeZone:n};t=new Intl.DateTimeFormat(e,r),w.set(a,t)}return t}(t).format(a)}function U(a,t=_){return b(new Date(a),{...t,...m,...d})}function L(a,t=_){return b(new Date(`1970-01-01T${a}Z`),{...t,...m,...s})}function P(a,t=_){if(t.timeZone)return b(new Date(a),t);const e=o.c9.fromISO(a,{setZone:!0}),n=0===e.offset?i.n$:t.timeZone,r={...t,timeZone:n};return e.toLocaleString(r,{locale:k()})}function G(a){switch(a){case i.qU:return i.N5;case i.L5:return i.n$;default:return a}}y["short-date"],(0,r.Ml)(()=>{w=new WeakMap})},98623:(a,t,e)=>{e.d(t,{L5:()=>r,N5:()=>o,n$:()=>i,qU:()=>n});const n="system",r="unknown",i="UTC",o=Intl.DateTimeFormat().resolvedOptions().timeZone}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2507],{10838:(a,t,e)=>{e.d(t,{ao:()=>u,ud:()=>h,xO:()=>T});var n=e(49186),r=e(36563),i=e(74887),o=e(73444);const s={ar:!0,bg:!0,bs:!0,ca:!0,cs:!0,da:!0,de:!0,el:!0,en:!0,es:!0,et:!0,fi:!0,fr:!0,he:!0,hr:!0,hu:!0,id:!0,it:!0,ja:!0,ko:!0,lt:!0,lv:!0,nb:"no",nl:!0,no:!0,nn:"no",pl:!0,pt:"pt-BR","pt-BR":!0,"pt-PT":!0,ro:!0,ru:!0,sk:!0,sl:!0,sr:!0,sv:!0,th:!0,tr:!0,uk:!0,vi:!0,zh:"zh-CN","zh-CN":!0,"zh-HK":!0,"zh-TW":!0};function d(a){if(function(a){return a in s}(a)){const t=s[a];return!0===t?a:t}return null}const m=[],c=new Map;function l(a){for(const t of c.keys())S(a.pattern,t)&&c.delete(t)}function u(a){return m.includes(a)||(l(a),m.unshift(a)),(0,r.hA)(()=>{const t=m.indexOf(a);t>-1&&(m.splice(t,1),l(a))})}async function h(a){const t=(0,o.JK)();c.has(a)||c.set(a,async function(a,t){const e=[];for(const n of m)if(S(n.pattern,a))try{return await n.fetchMessageBundle(a,t)}catch(a){e.push(a)}if(e.length)throw new n.A("intl:message-bundle-error",`Errors occurred while loading "${a}"`,{errors:e});throw new n.A("intl:no-message-bundle-loader",`No loader found for message bundle "${a}"`)}(a,t));const e=c.get(a);return e&&await g.add(e),e}function T(a){const t=(0,o.lR)(a);return t?d(a)??d(t):null}function S(a,t){return"string"==typeof a?t.startsWith(a):a.test(t)}(0,o.Ml)(()=>{c.clear()});const g=new class{constructor(){this._numLoading=0,this._dfd=null}async waitForAll(){this._dfd&&await this._dfd.promise}add(a){return this._increase(),a.then(()=>this._decrease(),()=>this._decrease()),this.waitForAll()}_increase(){this._numLoading++,this._dfd||(this._dfd=(0,i.Tw)())}_decrease(){this._numLoading=Math.max(this._numLoading-1,0),this._dfd&&0===this._numLoading&&(this._dfd.resolve(),this._dfd=null)}}},56400:(a,t,e)=>{e.d(t,{ZS:()=>d,hv:()=>m,wr:()=>c,P6:()=>s});var n=e(98623);const r=new Map([["AUS Central Standard Time","Australia/Darwin"],["AUS Eastern Standard Time","Australia/Sydney"],["Afghanistan Standard Time","Asia/Kabul"],["Alaskan Standard Time","America/Anchorage"],["Aleutian Standard Time","America/Adak"],["Altai Standard Time","Asia/Barnaul"],["Arab Standard Time","Asia/Riyadh"],["Arabian Standard Time","Asia/Dubai"],["Arabic Standard Time","Asia/Baghdad"],["Argentina Standard Time","America/Buenos_Aires"],["Astrakhan Standard Time","Europe/Astrakhan"],["Atlantic Standard Time","America/Halifax"],["Aus Central W. Standard Time","Australia/Eucla"],["Azerbaijan Standard Time","Asia/Baku"],["Azores Standard Time","Atlantic/Azores"],["Bahia Standard Time","America/Bahia"],["Bangladesh Standard Time","Asia/Dhaka"],["Belarus Standard Time","Europe/Minsk"],["Bougainville Standard Time","Pacific/Bougainville"],["Canada Central Standard Time","America/Regina"],["Cape Verde Standard Time","Atlantic/Cape_Verde"],["Caucasus Standard Time","Asia/Yerevan"],["Cen. Australia Standard Time","Australia/Adelaide"],["Central America Standard Time","America/Guatemala"],["Central Asia Standard Time","Asia/Bishkek"],["Central Brazilian Standard Time","America/Cuiaba"],["Central Europe Standard Time","Europe/Budapest"],["Central European Standard Time","Europe/Warsaw"],["Central Pacific Standard Time","Pacific/Guadalcanal"],["Central Standard Time","America/Chicago"],["Central Standard Time (Mexico)","America/Mexico_City"],["Chatham Islands Standard Time","Pacific/Chatham"],["China Standard Time","Asia/Shanghai"],["Cuba Standard Time","America/Havana"],["Dateline Standard Time","Etc/GMT+12"],["E. Africa Standard Time","Africa/Nairobi"],["E. Australia Standard Time","Australia/Brisbane"],["E. Europe Standard Time","Europe/Chisinau"],["E. South America Standard Time","America/Sao_Paulo"],["Easter Island Standard Time","Pacific/Easter"],["Eastern Standard Time","America/New_York"],["Eastern Standard Time (Mexico)","America/Cancun"],["Egypt Standard Time","Africa/Cairo"],["Ekaterinburg Standard Time","Asia/Yekaterinburg"],["FLE Standard Time","Europe/Kiev"],["Fiji Standard Time","Pacific/Fiji"],["GMT Standard Time","Europe/London"],["GTB Standard Time","Europe/Bucharest"],["Georgian Standard Time","Asia/Tbilisi"],["Greenland Standard Time","America/Godthab"],["Greenwich Standard Time","Atlantic/Reykjavik"],["Haiti Standard Time","America/Port-au-Prince"],["Hawaiian Standard Time","Pacific/Honolulu"],["India Standard Time","Asia/Calcutta"],["Iran Standard Time","Asia/Tehran"],["Israel Standard Time","Asia/Jerusalem"],["Jordan Standard Time","Asia/Amman"],["Kaliningrad Standard Time","Europe/Kaliningrad"],["Korea Standard Time","Asia/Seoul"],["Libya Standard Time","Africa/Tripoli"],["Line Islands Standard Time","Pacific/Kiritimati"],["Lord Howe Standard Time","Australia/Lord_Howe"],["Magadan Standard Time","Asia/Magadan"],["Magallanes Standard Time","America/Punta_Arenas"],["Marquesas Standard Time","Pacific/Marquesas"],["Mauritius Standard Time","Indian/Mauritius"],["Middle East Standard Time","Asia/Beirut"],["Montevideo Standard Time","America/Montevideo"],["Morocco Standard Time","Africa/Casablanca"],["Mountain Standard Time","America/Denver"],["Mountain Standard Time (Mexico)","America/Mazatlan"],["Myanmar Standard Time","Asia/Rangoon"],["N. Central Asia Standard Time","Asia/Novosibirsk"],["Namibia Standard Time","Africa/Windhoek"],["Nepal Standard Time","Asia/Katmandu"],["New Zealand Standard Time","Pacific/Auckland"],["Newfoundland Standard Time","America/St_Johns"],["Norfolk Standard Time","Pacific/Norfolk"],["North Asia East Standard Time","Asia/Irkutsk"],["North Asia Standard Time","Asia/Krasnoyarsk"],["North Korea Standard Time","Asia/Pyongyang"],["Omsk Standard Time","Asia/Omsk"],["Pacific SA Standard Time","America/Santiago"],["Pacific Standard Time","America/Los_Angeles"],["Pacific Standard Time (Mexico)","America/Tijuana"],["Pakistan Standard Time","Asia/Karachi"],["Paraguay Standard Time","America/Asuncion"],["Qyzylorda Standard Time","Asia/Qyzylorda"],["Romance Standard Time","Europe/Paris"],["Russia Time Zone 10","Asia/Srednekolymsk"],["Russia Time Zone 11","Asia/Kamchatka"],["Russia Time Zone 3","Europe/Samara"],["Russian Standard Time","Europe/Moscow"],["SA Eastern Standard Time","America/Cayenne"],["SA Pacific Standard Time","America/Bogota"],["SA Western Standard Time","America/La_Paz"],["SE Asia Standard Time","Asia/Bangkok"],["Saint Pierre Standard Time","America/Miquelon"],["Sakhalin Standard Time","Asia/Sakhalin"],["Samoa Standard Time","Pacific/Apia"],["Sao Tome Standard Time","Africa/Sao_Tome"],["Saratov Standard Time","Europe/Saratov"],["Singapore Standard Time","Asia/Singapore"],["South Africa Standard Time","Africa/Johannesburg"],["South Sudan Standard Time","Africa/Juba"],["Sri Lanka Standard Time","Asia/Colombo"],["Sudan Standard Time","Africa/Khartoum"],["Syria Standard Time","Asia/Damascus"],["Taipei Standard Time","Asia/Taipei"],["Tasmania Standard Time","Australia/Hobart"],["Tocantins Standard Time","America/Araguaina"],["Tokyo Standard Time","Asia/Tokyo"],["Tomsk Standard Time","Asia/Tomsk"],["Tonga Standard Time","Pacific/Tongatapu"],["Transbaikal Standard Time","Asia/Chita"],["Turkey Standard Time","Europe/Istanbul"],["Turks And Caicos Standard Time","America/Grand_Turk"],["US Eastern Standard Time","America/Indianapolis"],["US Mountain Standard Time","America/Phoenix"],["UTC","Etc/GMT"],["UTC+01","Etc/GMT-1"],["UTC+02","Etc/GMT-2"],["UTC+03","Etc/GMT-3"],["UTC+04","Etc/GMT-4"],["UTC+05","Etc/GMT-5"],["UTC+06","Etc/GMT-6"],["UTC+07","Etc/GMT-7"],["UTC+08","Etc/GMT-8"],["UTC+09","Etc/GMT-9"],["UTC+10","Etc/GMT-10"],["UTC+11","Etc/GMT-11"],["UTC+12","Etc/GMT-12"],["UTC+13","Etc/GMT-13"],["UTC+14","Etc/GMT-14"],["UTC-01","Etc/GMT+1"],["UTC-02","Etc/GMT+2"],["UTC-03","Etc/GMT+3"],["UTC-04","Etc/GMT+4"],["UTC-05","Etc/GMT+5"],["UTC-06","Etc/GMT+6"],["UTC-07","Etc/GMT+7"],["UTC-08","Etc/GMT+8"],["UTC-09","Etc/GMT+9"],["UTC-10","Etc/GMT+10"],["UTC-11","Etc/GMT+11"],["UTC-12","Etc/GMT+12"],["Ulaanbaatar Standard Time","Asia/Ulaanbaatar"],["Venezuela Standard Time","America/Caracas"],["Vladivostok Standard Time","Asia/Vladivostok"],["Volgograd Standard Time","Europe/Volgograd"],["W. Australia Standard Time","Australia/Perth"],["W. Central Africa Standard Time","Africa/Lagos"],["W. Europe Standard Time","Europe/Berlin"],["W. Mongolia Standard Time","Asia/Hovd"],["West Asia Standard Time","Asia/Tashkent"],["West Bank Standard Time","Asia/Hebron"],["West Pacific Standard Time","Pacific/Port_Moresby"],["Yakutsk Standard Time","Asia/Yakutsk"],["Yukon Standard Time","America/Whitehorse"]]);var i=e(28097);const o="shortOffset";function s(a,t=!1){return{json:{read:{source:a,reader:(t,e)=>e[a]?d(e[a]):null},write:!!t&&{allowNull:!0,writer(t,e){e[a]=t?function(a){return{timeZoneIANA:a}}(t):null}}}}}function d(a,t=n.qU){return a?"timeZoneIANA"in a?a.timeZoneIANA:function(a,t=n.qU){if(!a||!r.has(a.timeZone))return t;const e=r.get(a.timeZone);return a.timeZone.startsWith("UTC")||a.respectsDaylightSaving?e:function(a){const t=i.c9.local().setZone(a),e=Math.min(t.set({month:1,day:1}).offset,t.set({month:5}).offset);return 0===e?"Etc/UTC":`Etc/GMT${i.mQ.instance(-e).formatOffset(0,"narrow")}`}(e)}(a,t):t}function m(a,t,e,r,i){if(t&&"date"===i)return{timeZone:n.n$,timeZoneName:void 0};const s=r.timeStyle||r.hour,d=e===n.L5;return{timeZone:d?"timestamp-offset"===i?void 0:a??n.n$:e,timeZoneName:d&&s?o:void 0}}function c(a){const t=new Set(["etc/utc","etc/gmt","gmt"]),e=new Set(Intl.supportedValuesOf("timeZone").map(a=>a.toLowerCase()));return a===n.qU||a===n.L5||t.has(a.toLowerCase())||e.has(a.toLowerCase())}},65529:(a,t,e)=>{e.d(t,{Zt:()=>i,a$:()=>o,bk:()=>s,nJ:()=>d});var n=e(69622),r=e(36563);const i=a=>{const t=a;return class extends t{constructor(){super(...arguments),this._listenersMap=null}clearEvents(){this._listenersMap?.clear(),this._listenersMap=null}destroy(){this.clearEvents()}emit(a,t){let e=this._listenersMap?.get(a);if(!e)return!1;let n=!1;for(const a of e.slice()){const e="deref"in a?a.deref():a;e?e?.call(this,t):n=!0}return n&&(e=e.filter(a=>!("deref"in a)||null!=a.deref()),this._listenersMap.set(a,e)),e.length>0}on(a,t){if(Array.isArray(a)){const e=a.map(a=>this.on(a,t));return(0,r.vE)(e)}if(a.includes(","))throw new TypeError("Evented.on() with a comma delimited string of event types is not supported");this._listenersMap??=new Map;const e=this._listenersMap.get(a)||[];return e.push(t),this._listenersMap.set(a,e),(0,r.hA)(()=>{const e=this._listenersMap?.get(a),n=e?.indexOf(t)??-1;n>=0&&e.splice(n,1)})}once(a,t){const e=this.on(a,a=>{e.remove();const n="deref"in t?t.deref():t;n?.call(null,a)});return e}hasEventListener(a){const t=this._listenersMap?.get(a);return null!=t&&t.length>0}}},o=i(class{}),s=o,d=i(n.A)},66552:(a,t,e)=>{e.d(t,{J:()=>r,O:()=>o});var n=e(93637);class r{constructor(a,t={ignoreUnknown:!1,useNumericKeys:!1}){this._jsonToAPI=a,this._options=t,this.apiValues=[],this.jsonValues=[],this._apiToJSON=function(a){const t={};for(const e in a)t[a[e]]=e;return t}(a),this.apiValues=i(this._apiToJSON),this.jsonValues=i(this._jsonToAPI),this.read=a=>this.fromJSON(a),this.write=(a,t,e)=>{const r=this.toJSON(a);void 0!==r&&(0,n.sM)(e,r,t)},this.write.isJSONMapWriter=!0}toJSON(a){if(null==a)return null;if(this._apiToJSON.hasOwnProperty(a)){const t=this._apiToJSON[a];return this._options.useNumericKeys?+t:t}return this._options.ignoreUnknown?null:a}fromJSON(a){return null!=a&&this._jsonToAPI.hasOwnProperty(a)?this._jsonToAPI[a]:this._options.ignoreUnknown?void 0:a}}function i(a){const t=[];for(const e in a)t.push(e);return t.sort(),t}function o(){return function(a,t){return new r(a,{ignoreUnknown:!0,...t})}}},73444:(a,t,e)=>{e.d(t,{JK:()=>d,Ml:()=>g,QC:()=>l,lR:()=>c,oQ:()=>T});var n=e(36563);let r;e(44208);const i=globalThis.esriConfig?.locale??globalThis.dojoConfig?.locale,o=globalThis.document?.documentElement;function s(){const a=o?.getAttribute("lang"),t=globalThis.navigator?.language;return i??a??t??"en"}function d(){return void 0===r&&(r=s()),r}const m=/^(?<language>[a-z]{2,3})(?:-(?<extlang>[a-z]{3}))?(?:-[A-Z][a-z]{3})?(?:-(?<region>[A-Z]{2}|\d{3}))?(?:-.*)?$/;function c(a=d()){return u(a)?.language}function l(a=d()){const t=u(a);return t?.language&&t?.extlang?a.replace(`${t.language}-`,""):a}function u(a=d()){return m.exec(a)?.groups}const h=[];function T(a){return h.push(a),(0,n.hA)(()=>{h.splice(h.indexOf(a),1)})}new Map;const S=[];function g(a){return S.push(a),(0,n.hA)(()=>S.splice(S.indexOf(a),1))}function A(){const a=s();r!==a&&([...S].forEach(t=>t(a)),r=a,[...h].forEach(t=>t(a)))}globalThis.addEventListener?.("languagechange",A),o&&new MutationObserver(()=>{A()}).observe(o,{attributeFilter:["lang"]})},79901:(a,t,e)=>{e.d(t,{w:()=>d});var n=e(56507),r=e(96156);const i=Object.prototype.toString;function o(a){const t="__accessorMetadata__"in a?(0,n.dp)(a):a;return function(...a){if(a.push(t),"number"==typeof a[2])throw new Error("Using @cast has parameter decorator is not supported since 4.16");return s.apply(this,a)}}function s(a,t,e,n){(0,r.z4)(a,t).cast=n}function d(...a){if(3!==a.length||"string"!=typeof a[1])return 1===a.length&&"[object Function]"===i.call(a[0])?o(a[0]):1===a.length&&"string"==typeof a[0]?function(a){return(t,e)=>{(0,r.z4)(t,a).cast=t[e]}}(a[0]):void 0}},97770:(a,t,e)=>{e.d(t,{Ey:()=>G,F8:()=>P,J2:()=>_,Yq:()=>U,_m:()=>b,_v:()=>p,iS:()=>L,wj:()=>N});var n=e(66552),r=e(73444),i=e(98623),o=(e(56400),e(28097));const s={dateStyle:void 0,year:void 0,month:void 0,day:void 0,weekday:void 0},d={timeStyle:void 0,hour12:void 0,hourCycle:void 0,hour:void 0,minute:void 0,second:void 0},m={timeZone:i.n$},c={year:"numeric",month:"numeric",day:"numeric"},l={year:"numeric",month:"long",day:"numeric"},u={year:"numeric",month:"short",day:"numeric"},h={year:"numeric",month:"long",weekday:"long",day:"numeric"},T={hour:"numeric",minute:"numeric"},S={...T,second:"numeric"},g={hourCycle:"h23"},A={...T,...g},f={...S,...g},y={"short-date":c,"short-date-short-time":{...c,...T},"short-date-short-time-24":{...c,...A},"short-date-long-time":{...c,...S},"short-date-long-time-24":{...c,...f},"short-date-le":c,"short-date-le-short-time":{...c,...T},"short-date-le-short-time-24":{...c,...A},"short-date-le-long-time":{...c,...S},"short-date-le-long-time-24":{...c,...f},"long-month-day-year":l,"long-month-day-year-short-time":{...l,...T},"long-month-day-year-short-time-24":{...l,...A},"long-month-day-year-long-time":{...l,...S},"long-month-day-year-long-time-24":{...l,...f},"day-short-month-year":u,"day-short-month-year-short-time":{...u,...T},"day-short-month-year-short-time-24":{...u,...A},"day-short-month-year-long-time":{...u,...S},"day-short-month-year-long-time-24":{...u,...f},"long-date":h,"long-date-short-time":{...h,...T},"long-date-short-time-24":{...h,...A},"long-date-long-time":{...h,...S},"long-date-long-time-24":{...h,...f},"long-month-year":{month:"long",year:"numeric"},"short-month-year":{month:"short",year:"numeric"},year:{year:"numeric"},"short-time":T,"long-time":S},p=(0,n.O)()({shortDate:"short-date",shortDateShortTime:"short-date-short-time",shortDateShortTime24:"short-date-short-time-24",shortDateLongTime:"short-date-long-time",shortDateLongTime24:"short-date-long-time-24",shortDateLE:"short-date-le",shortDateLEShortTime:"short-date-le-short-time",shortDateLEShortTime24:"short-date-le-short-time-24",shortDateLELongTime:"short-date-le-long-time",shortDateLELongTime24:"short-date-le-long-time-24",longMonthDayYear:"long-month-day-year",longMonthDayYearShortTime:"long-month-day-year-short-time",longMonthDayYearShortTime24:"long-month-day-year-short-time-24",longMonthDayYearLongTime:"long-month-day-year-long-time",longMonthDayYearLongTime24:"long-month-day-year-long-time-24",dayShortMonthYear:"day-short-month-year",dayShortMonthYearShortTime:"day-short-month-year-short-time",dayShortMonthYearShortTime24:"day-short-month-year-short-time-24",dayShortMonthYearLongTime:"day-short-month-year-long-time",dayShortMonthYearLongTime24:"day-short-month-year-long-time-24",longDate:"long-date",longDateShortTime:"long-date-short-time",longDateShortTime24:"long-date-short-time-24",longDateLongTime:"long-date-long-time",longDateLongTime24:"long-date-long-time-24",longMonthYear:"long-month-year",shortMonthYear:"short-month-year",year:"year"}),M={ar:"ar-u-nu-latn-ca-gregory",nn:"no-NN"},E=new Intl.DateTimeFormat("bs",{month:"long"}).formatToParts(new Date(2025,2)),C=E.find(({type:a})=>"month"===a)?.value.toLowerCase();function w(){const a=(0,r.lR)();return(a&&M[a])??(0,r.QC)()}"mart"!==C&&(M.bs="sr-Latn-CS");let k=new WeakMap;const v=y["short-date-short-time"];function _(a){return y[a]}function b(a){const{dateStyle:t,timeStyle:e,hour12:n,year:r,month:i}=a,o={};return t?o.dateStyle=t:r&&(o.year=r,o.month=i||void 0),e&&!o.year&&(o.timeStyle=e,o.hour12="auto"===n?void 0:"always"===n),o}function U(a,t=v){return function(a){let t=k.get(a);if(!t){const e=w(),n=N(a.timeZone??i.qU),r={...a,timeZone:n};t=new Intl.DateTimeFormat(e,r),k.set(a,t)}return t}(t).format(a)}function L(a,t=v){return U(new Date(a),{...t,...m,...d})}function P(a,t=v){return U(new Date(`1970-01-01T${a}Z`),{...t,...m,...s})}function G(a,t=v){if(t.timeZone)return U(new Date(a),t);const e=o.c9.fromISO(a,{setZone:!0}),n=0===e.offset?i.n$:t.timeZone,r={...t,timeZone:n};return e.toLocaleString(r,{locale:w()})}function N(a){switch(a){case i.qU:return i.N5;case i.L5:return i.n$;default:return a}}y["short-date"],(0,r.Ml)(()=>{k=new WeakMap})},98623:(a,t,e)=>{e.d(t,{L5:()=>r,N5:()=>o,n$:()=>i,qU:()=>n});const n="system",r="unknown",i="UTC",o=Intl.DateTimeFormat().resolvedOptions().timeZone}}]);