@arcgis/core 6.0.0-next.42 → 6.0.0-next.43

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 (489) hide show
  1. package/Basemap.js +1 -1
  2. package/Graphic.js +1 -1
  3. package/Ground.js +1 -1
  4. package/WebDocument2D.js +1 -1
  5. package/WebScene.js +1 -1
  6. package/analysis/ElevationProfile/ElevationProfileLineScene.d.ts +1 -0
  7. package/analysis/ElevationProfileAnalysis.d.ts +15 -0
  8. package/analysis/LineOfSightAnalysis.d.ts +6 -1
  9. package/analysis/ShadowCastAnalysis.d.ts +18 -22
  10. package/analysis/ShadowCastAnalysis.js +1 -1
  11. package/analysis/ViewshedAnalysis.d.ts +6 -1
  12. package/applications/Components/analysisUtils.d.ts +6 -0
  13. package/applications/Components/analysisUtils.js +1 -1
  14. package/arcade/ArcadeModuleResolver.js +1 -1
  15. package/arcade/arcadeCompiler.js +1 -1
  16. package/arcade/featureset/actions/Adapted.js +1 -1
  17. package/arcade/featureset/sources/FeatureLayerMemory.js +1 -1
  18. package/arcade/featureset/support/FeatureSet.js +1 -1
  19. package/arcade/featureset/support/shared.js +1 -1
  20. package/arcade/featureset/support/sqlUtils.js +1 -1
  21. package/arcade/functions/knowledgegraph.js +1 -1
  22. package/arcade/functions/maths.js +1 -1
  23. package/assets/esri/core/workers/RemoteClient.js +1 -1
  24. package/assets/esri/core/workers/chunks/{2f54e4feb554c1a7b9c4.js → 02debe67e6fef9d88bdd.js} +1 -1
  25. package/assets/esri/core/workers/chunks/{bd046399e05e759e0bc2.js → 035204000954973b0ebc.js} +1 -1
  26. package/assets/esri/core/workers/chunks/05225506fdba0c827407.js +1 -0
  27. package/assets/esri/core/workers/chunks/{4c73c493dabe949c2512.js → 077b755688346e0dc8d3.js} +1 -1
  28. package/assets/esri/core/workers/chunks/0c1d8e0c2eae21f97fc0.js +1 -0
  29. package/assets/esri/core/workers/chunks/105865a4d8cb4ddf8a8a.js +1 -0
  30. package/assets/esri/core/workers/chunks/{afe3e89737fb45189a99.js → 14ed0c34b910eba3434e.js} +1 -1
  31. package/assets/esri/core/workers/chunks/{f67b37253d6d05d1e339.js → 14ef986665b4a1f6ccdc.js} +1 -1
  32. package/assets/esri/core/workers/chunks/158cbf4075d3eca83a6a.js +1 -0
  33. package/assets/esri/core/workers/chunks/{a03f15f2cbc3fed291c2.js → 15f2b27b8edc0d53e399.js} +1 -1
  34. package/assets/esri/core/workers/chunks/181d24ced5ef6b1f959b.js +1 -0
  35. package/assets/esri/core/workers/chunks/18dbee576b7b9dbe69fb.js +1 -0
  36. package/assets/esri/core/workers/chunks/1aebb8fe0692058bf2fb.js +1 -0
  37. package/assets/esri/core/workers/chunks/1cdb55d9a5ab1a5e3f08.js +1 -0
  38. package/assets/esri/core/workers/chunks/{cf2e5f827cea7d7319ce.js → 1e5c5029b0653047a769.js} +1 -1
  39. package/assets/esri/core/workers/chunks/20db6e844708d3e71437.js +1 -0
  40. package/assets/esri/core/workers/chunks/21a4c3d8265aca775616.js +1 -0
  41. package/assets/esri/core/workers/chunks/23fff0505e02fd364909.js +1 -0
  42. package/assets/esri/core/workers/chunks/286e3e050b29e6158e6f.js +1 -0
  43. package/assets/esri/core/workers/chunks/29ef9d357e30082d267a.js +1 -0
  44. package/assets/esri/core/workers/chunks/29feef121b0916fb90bf.js +1 -0
  45. package/assets/esri/core/workers/chunks/2ef91e8da260454f46d8.js +1 -0
  46. package/assets/esri/core/workers/chunks/32b9bedd4bb0504f0b1d.js +1 -0
  47. package/assets/esri/core/workers/chunks/{279089a6a3f08022c678.js → 361d620b3f91868b1490.js} +1 -1
  48. package/assets/esri/core/workers/chunks/37c16e20f022ca27cdae.js +1 -0
  49. package/assets/esri/core/workers/chunks/380aefa522dfeccb8c65.js +1 -0
  50. package/assets/esri/core/workers/chunks/394ae3199c78a94c6a2a.js +1 -0
  51. package/assets/esri/core/workers/chunks/{fdd2b35388f9fe42b623.js → 3a90b6eafa92f1a68ac5.js} +1 -1
  52. package/assets/esri/core/workers/chunks/{6a65fc1a2931230fe994.js → 3bb1e06861cd0563ed9f.js} +1 -1
  53. package/assets/esri/core/workers/chunks/3f92afa58c895bf87e62.js +1 -0
  54. package/assets/esri/core/workers/chunks/422784ceae0d511868a0.js +1 -0
  55. package/assets/esri/core/workers/chunks/44782e8318dc47cb08a0.js +1 -0
  56. package/assets/esri/core/workers/chunks/{5882f349f3771868e67f.js → 4521f72ab0ea872e5d7c.js} +1 -1
  57. package/assets/esri/core/workers/chunks/45b5a61c4e9fbd9ca0b3.js +1 -0
  58. package/assets/esri/core/workers/chunks/47af220003adfca2167e.js +1 -0
  59. package/assets/esri/core/workers/chunks/487500443a6037d3599f.js +1 -0
  60. package/assets/esri/core/workers/chunks/4a4fab74442c3d914505.js +1 -0
  61. package/assets/esri/core/workers/chunks/4a8903fb1a5d30a68df9.js +1 -0
  62. package/assets/esri/core/workers/chunks/4d818b231e6d1fa73cc5.js +1 -0
  63. package/assets/esri/core/workers/chunks/{e0cf6e1e21d0ee739009.js → 4e03aa5518d46a36661c.js} +1 -1
  64. package/assets/esri/core/workers/chunks/{1a614bac5db42c6263f8.js → 4fe10650ba3cd30aa9a2.js} +1 -1
  65. package/assets/esri/core/workers/chunks/50b8b1cce0a5f77c8372.js +1 -0
  66. package/assets/esri/core/workers/chunks/5470a29a69010c8361c4.js +1 -0
  67. package/assets/esri/core/workers/chunks/564d7f2e58fbc16853c0.js +1 -0
  68. package/assets/esri/core/workers/chunks/5c2e79f2ca401741bf3e.js +1 -0
  69. package/assets/esri/core/workers/chunks/5c9ab86bec07264dc9f2.js +1 -0
  70. package/assets/esri/core/workers/chunks/{04d55ed51e8b2683c4b4.js → 5d908a823b324bafda1e.js} +1 -1
  71. package/assets/esri/core/workers/chunks/5e6d6676a5c47c0e132a.js +1 -0
  72. package/assets/esri/core/workers/chunks/5fd4d3cb3c9350131a59.js +1 -0
  73. package/assets/esri/core/workers/chunks/60637f38159e9bf68d4e.js +1 -0
  74. package/assets/esri/core/workers/chunks/69b73251257088ce7099.js +1 -0
  75. package/assets/esri/core/workers/chunks/6cd17c3a254a0b5c2476.js +1 -0
  76. package/assets/esri/core/workers/chunks/{06102715e9a8f218e07c.js → 6f3732e7ba2d031ba789.js} +1 -1
  77. package/assets/esri/core/workers/chunks/7191ab31fa040a7c561e.js +1 -0
  78. package/assets/esri/core/workers/chunks/71ba848c3352ea3ff96f.js +1 -0
  79. package/assets/esri/core/workers/chunks/76dc8e3264a456f33e61.js +1 -0
  80. package/assets/esri/core/workers/chunks/77d80b6d65d761214a7c.js +1 -0
  81. package/assets/esri/core/workers/chunks/{e2430bc3a1edeb5c3266.js → 78a69594c82d37aecbfb.js} +1 -1
  82. package/assets/esri/core/workers/chunks/{787c1a8bda7d745633f2.js → 81b9894e81cce3490984.js} +1 -1
  83. package/assets/esri/core/workers/chunks/85cd525705eec6803dd3.js +1 -0
  84. package/assets/esri/core/workers/chunks/863f04cacdc843d3f208.js +1 -0
  85. package/assets/esri/core/workers/chunks/8766832c7253557da8fe.js +1 -0
  86. package/assets/esri/core/workers/chunks/87992070008812f8ae6f.js +1 -0
  87. package/assets/esri/core/workers/chunks/892fd2c3533ce46a9258.js +1 -0
  88. package/assets/esri/core/workers/chunks/89b9d716d96135d4f057.js +1 -0
  89. package/assets/esri/core/workers/chunks/{4b2d392ad8e381bfd6b3.js → 89e9ebc8d5c1022cb265.js} +1 -1
  90. package/assets/esri/core/workers/chunks/8b38798ac6d774185238.js +1 -0
  91. package/assets/esri/core/workers/chunks/8b53369cace136ed1329.js +1 -0
  92. package/assets/esri/core/workers/chunks/8ba4f5e1912edf397947.js +1 -0
  93. package/assets/esri/core/workers/chunks/{987424121cf30b0f3c50.js → 8d3e92a3367a3ddc02bd.js} +1 -1
  94. package/assets/esri/core/workers/chunks/8e7a3b1b088c160f4db7.js +1 -0
  95. package/assets/esri/core/workers/chunks/8f4fba4d2339c91c8b3f.js +1 -0
  96. package/assets/esri/core/workers/chunks/{45aaefbdffe5e15dfb24.js → 919a6aedf38e9631ee09.js} +1 -1
  97. package/assets/esri/core/workers/chunks/{487c46d5245cfb35c4bb.js → 921917e53bac82693ec8.js} +1 -1
  98. package/assets/esri/core/workers/chunks/92809b209b68abcb97ee.js +1 -0
  99. package/assets/esri/core/workers/chunks/{beccbfff549902733c4e.js → 9869c696e6321c8db0a9.js} +1 -1
  100. package/assets/esri/core/workers/chunks/98957dba728c93506e50.js +1 -0
  101. package/assets/esri/core/workers/chunks/99ffb839407cb3c26ad8.js +1 -0
  102. package/assets/esri/core/workers/chunks/9b517c8d26a86dedb921.js +1 -0
  103. package/assets/esri/core/workers/chunks/{cb2329d1ea72ce5cc057.js → 9c3f56f22e9baa80a387.js} +1 -1
  104. package/assets/esri/core/workers/chunks/{1860104c2b33f68785dd.js → 9d0976f5979c4f9154dc.js} +1 -1
  105. package/assets/esri/core/workers/chunks/9fe1812aad6e566aea31.js +1 -0
  106. package/assets/esri/core/workers/chunks/a1602995ef96beb7df29.js +1 -0
  107. package/assets/esri/core/workers/chunks/{dff845574c0037a1dca6.js → a332e31165b65a6fb92e.js} +1 -1
  108. package/assets/esri/core/workers/chunks/a553478664a688f32488.js +1 -0
  109. package/assets/esri/core/workers/chunks/a7937b06f4b0860c7671.js +1 -0
  110. package/assets/esri/core/workers/chunks/{1980fd7ae1617ef4d19d.js → a95186214f1206efd8ed.js} +1 -1
  111. package/assets/esri/core/workers/chunks/{853563c66ecf58d53d36.js → ab60e8fbe0f92340616a.js} +1 -1
  112. package/assets/esri/core/workers/chunks/acea0946049136578354.js +1 -0
  113. package/assets/esri/core/workers/chunks/{342a97974a78007b25e0.js → ad94f54b4c88b3a047bc.js} +1 -1
  114. package/assets/esri/core/workers/chunks/ae29fec228e70a93ced1.js +1 -0
  115. package/assets/esri/core/workers/chunks/ae6dc159be974ca0e8da.js +1 -0
  116. package/assets/esri/core/workers/chunks/ae70972bf88d586fd453.js +1 -0
  117. package/assets/esri/core/workers/chunks/b021fa4654ede1d04279.js +1 -0
  118. package/assets/esri/core/workers/chunks/b03f32f02858244c6cd0.js +1 -0
  119. package/assets/esri/core/workers/chunks/b2d922ecc2c4899dbee1.js +1 -0
  120. package/assets/esri/core/workers/chunks/b42e50ec6b819f669400.js +1 -0
  121. package/assets/esri/core/workers/chunks/b6a82775b83d20599635.js +1 -0
  122. package/assets/esri/core/workers/chunks/b6d365b9198b74b05338.js +1 -0
  123. package/assets/esri/core/workers/chunks/{48c6230b8a6d3a8a7906.js → bc21241bc9acb83d1b1c.js} +1 -1
  124. package/assets/esri/core/workers/chunks/bd02d927b0b4991b61c5.js +1 -0
  125. package/assets/esri/core/workers/chunks/bdf1c4c038d556527483.js +1 -0
  126. package/assets/esri/core/workers/chunks/c1273f14a5ef3d81de0d.js +1 -0
  127. package/assets/esri/core/workers/chunks/c752f1e732bb019f657d.js +1 -0
  128. package/assets/esri/core/workers/chunks/{3f74c61359b4bd6dcf00.js → c7f49493bd548d5dc1e0.js} +1 -1
  129. package/assets/esri/core/workers/chunks/{36bafcc29ac133a05558.js → c86d3af148b28ded5875.js} +10 -10
  130. package/assets/esri/core/workers/chunks/{692f0093c444fcc752b5.js → cadd60fa4370284c7ae3.js} +1 -1
  131. package/assets/esri/core/workers/chunks/{d5e251cddd41d643510c.js → cb62326b6526cde429c1.js} +1 -1
  132. package/assets/esri/core/workers/chunks/cd8304b1db83d48c57db.js +1 -0
  133. package/assets/esri/core/workers/chunks/cdf0c7706d3e1221f49b.js +1 -0
  134. package/assets/esri/core/workers/chunks/d00dd961a5b79f563123.js +1 -0
  135. package/assets/esri/core/workers/chunks/d893c3bb093104d3db95.js +1 -0
  136. package/assets/esri/core/workers/chunks/d8fb1d9da16492574a11.js +1 -0
  137. package/assets/esri/core/workers/chunks/{520f499d79fa71f262c7.js → dd7e4c94a88452425750.js} +1 -1
  138. package/assets/esri/core/workers/chunks/ddb4689624d091922471.js +1 -0
  139. package/assets/esri/core/workers/chunks/df32a3fe81d60f0d7462.js +1 -0
  140. package/assets/esri/core/workers/chunks/dfc6b33f51dc81f3a7be.js +1 -0
  141. package/assets/esri/core/workers/chunks/e55934eb4a17a5b24c94.js +1 -0
  142. package/assets/esri/core/workers/chunks/{5473409fee59db80f87d.js → e5bdfef7c2cc5354be52.js} +1 -1
  143. package/assets/esri/core/workers/chunks/e8cdec961e9cff1cb73b.js +1 -0
  144. package/assets/esri/core/workers/chunks/{446d172834f8675f1202.js → eaf720dfdf6ceca31249.js} +1 -1
  145. package/assets/esri/core/workers/chunks/ef274db3fa260eadf371.js +1 -0
  146. package/assets/esri/core/workers/chunks/efca82a4dc494f57380b.js +1 -0
  147. package/assets/esri/core/workers/chunks/f05990e6fb378e2e1a3b.js +1 -0
  148. package/assets/esri/core/workers/chunks/f0fc89cdf50a40913c02.js +1 -0
  149. package/assets/esri/core/workers/chunks/{8b5dcc4282772bf6b675.js → f11eaab5354cc6aa9569.js} +1 -1
  150. package/assets/esri/core/workers/chunks/f1c2f7c7ce4bd4096eb0.js +1 -0
  151. package/assets/esri/core/workers/chunks/f4e63c5f82b8c2bbfacb.js +1 -0
  152. package/assets/esri/core/workers/chunks/f86ff791a10c802879ec.js +1 -0
  153. package/assets/esri/core/workers/chunks/{7452b5ae971a9ff2e6e9.js → fdffefd7de540272a8a6.js} +1 -1
  154. package/assets/esri/core/workers/chunks/fe0248af95d3f37e099e.js +1 -0
  155. package/chunks/languageUtils.js +1 -1
  156. package/config.js +1 -1
  157. package/core/Accessor.js +1 -1
  158. package/core/Collection.js +1 -1
  159. package/core/LRUCache.js +1 -1
  160. package/core/MapUtils.js +1 -1
  161. package/core/Version.js +1 -1
  162. package/core/asyncUtils.js +1 -1
  163. package/core/fontUtils.js +1 -1
  164. package/core/has.js +1 -1
  165. package/core/sql/SqlInterval.js +1 -1
  166. package/core/sql/WhereClause.js +1 -1
  167. package/core/sql/writeUtils.js +1 -1
  168. package/core/sql.js +1 -1
  169. package/core/urlUtils.js +1 -1
  170. package/editing/sharedTemplates/executor/builders/pointAtIntersectionVerticesOfLine.js +1 -1
  171. package/editing/sharedTemplates/executor/builders/polygonBoundary.js +1 -1
  172. package/editing/sharedTemplates/executor/builders/support/builderUtils.js +1 -1
  173. package/editing/sharedTemplates/executor/support/createFeatureServiceEdit.js +1 -1
  174. package/geometry/Point.js +1 -1
  175. package/geometry/Polygon.js +1 -1
  176. package/geometry/SpatialReference.js +1 -1
  177. package/geometry/support/webMercatorUtils.js +1 -1
  178. package/kernel.js +1 -1
  179. package/layers/FeatureLayer.js +1 -1
  180. package/layers/GeoJSONLayer.d.ts +5 -1
  181. package/layers/GeospatialPDFLayer.js +1 -1
  182. package/layers/KnowledgeGraphLayer.js +1 -1
  183. package/layers/LineOfSightLayer.d.ts +6 -1
  184. package/layers/LinkChartLayer.js +1 -1
  185. package/layers/Lyr3DWasmPerSceneView.js +1 -1
  186. package/layers/SubtypeGroupLayer.js +1 -1
  187. package/layers/TileLayer.js +1 -1
  188. package/layers/VectorTileLayer.d.ts +53 -0
  189. package/layers/VectorTileLayer.js +1 -1
  190. package/layers/VideoLayer.js +1 -1
  191. package/layers/ViewshedLayer.d.ts +6 -1
  192. package/layers/VoxelLayer.js +1 -1
  193. package/layers/effects/jsonUtils.js +1 -1
  194. package/layers/geospatialPDF/GeospatialPDFLayerWorker.js +1 -1
  195. package/layers/geospatialPDF/GeospatialPDFWorkerClient.js +1 -1
  196. package/layers/graphics/data/QueryEngineResult.js +1 -1
  197. package/layers/graphics/data/projectionSupport.js +1 -1
  198. package/layers/graphics/sources/connections/WebSocketConnection.js +1 -1
  199. package/layers/graphics/sources/geojson/GeoJSONSourceWorker.js +1 -1
  200. package/layers/graphics/sources/geojson/geojson.js +1 -1
  201. package/layers/graphics/sources/parquet/FileProvider.js +1 -1
  202. package/layers/graphics/sources/support/QueryTask.js +1 -1
  203. package/layers/graphics/sources/support/uploads.js +1 -1
  204. package/layers/knowledgeGraph/cypherUtils.js +1 -1
  205. package/layers/mixins/refresh.js +1 -1
  206. package/layers/ogc/ogcFeatureUtils.js +1 -1
  207. package/layers/ogc/wfsUtils.js +1 -1
  208. package/layers/parquet.js +1 -1
  209. package/layers/raster/datasets/BaseRaster.js +1 -1
  210. package/layers/raster/datasets/GeospatialPDFRaster.js +1 -1
  211. package/layers/raster/datasets/TIFFRaster.js +1 -1
  212. package/layers/raster/datasets/wcsCoverageParser.js +1 -1
  213. package/layers/raster/formats/Lerc.js +1 -1
  214. package/layers/support/ClientSideConnection.js +1 -1
  215. package/layers/support/ElevationSampler.js +1 -1
  216. package/layers/support/MultidimensionalSubset.js +1 -1
  217. package/layers/support/SpriteSource.js +1 -1
  218. package/layers/support/TileInfo.js +1 -1
  219. package/layers/support/fieldUtils.js +1 -1
  220. package/layers/support/infoFor3D.js +1 -1
  221. package/layers/support/vectorTileLayerLoader.js +1 -1
  222. package/layers/support/wmsUtils.js +1 -1
  223. package/layers/support/wmtsUtils.js +1 -1
  224. package/layers/video/videoUtils.js +1 -1
  225. package/libs/lyr3d/Lyr3DModule.js +1 -1
  226. package/linkChart/utils.js +1 -1
  227. package/networks/support/Circuit.js +1 -1
  228. package/networks/support/CircuitSection.js +1 -1
  229. package/package.json +2 -2
  230. package/portal/Portal.js +1 -1
  231. package/portal/PortalItemResource.js +1 -1
  232. package/portal/PortalQueryParams.js +1 -1
  233. package/renderers/HeatmapRenderer.js +1 -1
  234. package/renderers/UniqueValueRenderer.js +1 -1
  235. package/rest/knowledgeGraphService.js +1 -1
  236. package/rest/query/operations/pbfFeatureServiceParser.js +1 -1
  237. package/rest/query/operations/queryAttachments.js +1 -1
  238. package/symbols/cim/placements/PlacementInsidePolygon.js +1 -1
  239. package/symbols/cim/types.d.ts +15 -11
  240. package/symbols/support/previewSymbol3D.js +1 -1
  241. package/tables/support/templateUtils.js +1 -1
  242. package/views/2d/engine/vectorTiles/SourceLayerData.js +1 -1
  243. package/views/2d/engine/vectorTiles/SpriteMosaic.js +1 -1
  244. package/views/2d/engine/vectorTiles/TileHandler.js +1 -1
  245. package/views/2d/engine/vectorTiles/TileHandler3D.js +1 -1
  246. package/views/2d/engine/vectorTiles/TileManager.js +1 -1
  247. package/views/2d/engine/vectorTiles/TileParser.js +1 -1
  248. package/views/2d/engine/vectorTiles/VectorTileFeatureIndex.js +1 -1
  249. package/views/2d/engine/vectorTiles/VectorTileSourceData.js +2 -0
  250. package/views/2d/engine/vectorTiles/WorkerTile.js +1 -1
  251. package/views/2d/engine/vectorTiles/WorkerTileHandler.js +1 -1
  252. package/views/2d/engine/vectorTiles/buckets/SymbolBucket.js +1 -1
  253. package/views/2d/engine/vectorTiles/expression/expression.js +1 -1
  254. package/views/2d/engine/vectorTiles/style/Filter.js +1 -1
  255. package/views/2d/engine/vectorTiles/style/GeoJSONVectorTileSourceWorker.js +1 -1
  256. package/views/2d/engine/vectorTiles/style/StyleProperty.js +1 -1
  257. package/views/2d/engine/webgl/mesh/MeshData.js +1 -1
  258. package/views/2d/engine/webgl/mesh/factories/MeshWriterGroupCoordinator.js +1 -1
  259. package/views/2d/engine/webgl/shaderGraph/graph/ShaderGraphContext.js +4 -4
  260. package/views/2d/interactive/editingTools/draw/DrawGraphicTool2D.js +1 -1
  261. package/views/2d/layers/VectorTileLayerView2D.js +1 -1
  262. package/views/2d/layers/features/Processor.js +1 -1
  263. package/views/2d/layers/features/support/TileStore.js +1 -1
  264. package/views/2d/layers/graphics/GraphicsView2D.js +1 -1
  265. package/views/2d/tiling/TileKey.js +1 -1
  266. package/views/2d/tiling/TileStrategy.js +1 -1
  267. package/views/3d/analysis/Dimension/LengthDimensionComputation.js +1 -1
  268. package/views/3d/analysis/LineOfSight/LineOfSightManipulators.js +1 -1
  269. package/views/3d/analysis/ShadowCastAnalysisView3D.js +1 -1
  270. package/views/3d/analysis/images/generateTextures.js +1 -1
  271. package/views/3d/environment/EnvironmentView.js +1 -1
  272. package/views/3d/interactive/editingTools/draw/DrawGraphicTool3D.js +1 -1
  273. package/views/3d/interactive/editingTools/manipulations/MoveZManipulation.js +1 -1
  274. package/views/3d/interactive/visualElements/PointVisualElement.js +1 -1
  275. package/views/3d/layers/I3SMeshView3D.js +1 -1
  276. package/views/3d/layers/IntegratedMeshLayerView3D.js +1 -1
  277. package/views/3d/layers/VectorTileLayerView3D.js +1 -1
  278. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  279. package/views/3d/layers/graphics/Graphics3DExtrudeSymbolLayer.js +1 -1
  280. package/views/3d/layers/graphics/Graphics3DFeatureProcessor.js +1 -1
  281. package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
  282. package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
  283. package/views/3d/layers/graphics/Graphics3DPolygonFillSymbolLayer.js +1 -1
  284. package/views/3d/layers/graphics/Graphics3DSymbol.js +1 -1
  285. package/views/3d/layers/graphics/Graphics3DSymbolCreationContext.js +1 -1
  286. package/views/3d/layers/graphics/Graphics3DWaterSymbolLayer.js +1 -1
  287. package/views/3d/layers/graphics/MeshFastUpdateProcessor.js +1 -1
  288. package/views/3d/layers/graphics/defaultSymbolComplexity.js +1 -1
  289. package/views/3d/layers/graphics/objectResourceUtils.js +1 -1
  290. package/views/3d/layers/graphics/polygonUtils.js +1 -1
  291. package/views/3d/layers/graphics/wosrLoader.js +1 -1
  292. package/views/3d/layers/i3s/I3SAsyncElevationUpdater.js +1 -1
  293. package/views/3d/layers/i3s/I3SClientNodeLoader.js +1 -1
  294. package/views/3d/layers/i3s/I3SQueryEngine.js +1 -1
  295. package/views/3d/layers/i3s/LayerElevationProvider.js +1 -1
  296. package/views/3d/layers/support/StageLayerElevationProvider.js +1 -1
  297. package/views/3d/state/ConstraintsManager.js +1 -1
  298. package/views/3d/state/controllers/GroundNavigationController.js +1 -1
  299. package/views/3d/support/QualityProfile.js +1 -1
  300. package/views/3d/support/TextureCollection.js +1 -1
  301. package/views/3d/terrain/PatchGeometryFactory.js +1 -1
  302. package/views/3d/terrain/TerrainRenderer.js +1 -1
  303. package/views/3d/terrain/Tile.js +1 -1
  304. package/views/3d/webgl-engine/collections/Component/ComponentObject.js +1 -1
  305. package/views/3d/webgl-engine/collections/Component/ComponentObjectCollection.js +1 -1
  306. package/views/3d/webgl-engine/core/shaderTechnique/ShaderTechnique.js +1 -1
  307. package/views/3d/webgl-engine/effects/laserlines/LaserLineRenderer.js +1 -1
  308. package/views/3d/webgl-engine/effects/laserlines/LaserlinePathTechniqueConfiguration.js +1 -1
  309. package/views/3d/webgl-engine/lib/BindParameters.js +1 -1
  310. package/views/3d/webgl-engine/lib/CutFill.js +1 -1
  311. package/views/3d/webgl-engine/lib/OrderIndependentTransparency.js +1 -1
  312. package/views/3d/webgl-engine/lib/TextureRepository.js +1 -1
  313. package/views/3d/webgl-engine/lib/TriangleIntersectionData.js +1 -1
  314. package/views/3d/webgl-engine/materials/ColorMaterial.js +1 -1
  315. package/views/3d/webgl-engine/materials/DefaultMaterial.js +1 -1
  316. package/views/3d/webgl-engine/materials/PathMaterial.js +1 -1
  317. package/views/3d/webgl-engine/materials/TriangleMaterial.js +1 -1
  318. package/views/3d/webgl-engine/materials/intersectWithPolygonOffset.js +1 -1
  319. package/views/3d/webgl-engine/shaders/DefaultMaterialTechnique.js +1 -1
  320. package/views/SceneView.js +1 -1
  321. package/views/SelectionManager.js +1 -1
  322. package/views/analysis/ElevationProfile/ElevationProfileChart.js +2 -2
  323. package/views/analysis/ElevationProfile/elevationProfileChartBoundsUtils.js +1 -1
  324. package/views/draw/DrawAction.js +1 -1
  325. package/views/draw/support/PluginContext.js +1 -1
  326. package/views/interactive/sketch/normalizedPoint.js +1 -1
  327. package/views/interactive/tooltip/fields/TooltipFieldElevation.js +1 -1
  328. package/views/interactive/tooltip/fields/TooltipFieldOrientation.js +1 -1
  329. package/views/interactive/tooltip/fields/TooltipFieldSize.js +1 -1
  330. package/widgets/AreaMeasurement2D/AreaMeasurement2DViewModel.js +1 -1
  331. package/widgets/Attachments.js +1 -1
  332. package/widgets/Attribution/AttributionViewModel.js +1 -1
  333. package/widgets/BasemapGallery/BasemapGalleryViewModel.js +1 -1
  334. package/widgets/BasemapLayerList/BasemapLayerListViewModel.js +1 -1
  335. package/widgets/BasemapToggle/BasemapToggleViewModel.js +1 -1
  336. package/widgets/BatchAttributeForm/ReactiveContingentValuesManager.js +1 -1
  337. package/widgets/BatchAttributeForm/inputs/AttachmentElementInput.js +1 -1
  338. package/widgets/BatchAttributeForm.js +1 -1
  339. package/widgets/Bookmarks/BookmarksViewModel.js +1 -1
  340. package/widgets/BuildingExplorer/BuildingExplorerViewModel.js +1 -1
  341. package/widgets/BuildingExplorer/BuildingNumericFilterViewModel.js +1 -1
  342. package/widgets/CatalogLayerList/CatalogLayerListViewModel.js +1 -1
  343. package/widgets/CatalogLayerList.js +1 -1
  344. package/widgets/Compass/CompassViewModel.js +1 -1
  345. package/widgets/CoordinateConversion/support/Format.js +1 -1
  346. package/widgets/CoordinateConversion/support/formatUtils.js +1 -1
  347. package/widgets/Daylight/DaylightViewModel.js +1 -1
  348. package/widgets/DistanceMeasurement2D/DistanceMeasurement2DViewModel.js +1 -1
  349. package/widgets/Editor/support/SketchController.js +1 -1
  350. package/widgets/ElevationProfile/ElevationProfileLine.js +1 -1
  351. package/widgets/ElevationProfile/ElevationProfileViewModel.js +1 -1
  352. package/widgets/Expand/ExpandViewModel.js +1 -1
  353. package/widgets/Expand.js +1 -1
  354. package/widgets/Feature/FeatureMedia.js +1 -1
  355. package/widgets/Feature/FeatureViewModel.js +1 -1
  356. package/widgets/Feature.js +1 -1
  357. package/widgets/FeatureForm.js +1 -1
  358. package/widgets/FeatureTemplates.js +1 -1
  359. package/widgets/Features/FeaturesViewModel.js +1 -1
  360. package/widgets/Features.js +1 -1
  361. package/widgets/FloorFilter/FloorFilterViewModel.js +1 -1
  362. package/widgets/Fullscreen/FullscreenViewModel.js +1 -1
  363. package/widgets/Histogram/HistogramViewModel.js +1 -1
  364. package/widgets/Histogram.js +1 -1
  365. package/widgets/HistogramRangeSlider/HistogramRangeSliderViewModel.js +1 -1
  366. package/widgets/Home/HomeViewModel.js +1 -1
  367. package/widgets/LayerList/LayerListViewModel.js +1 -1
  368. package/widgets/Legend/LegendViewModel.js +1 -1
  369. package/widgets/Legend/styles/card/CardView.js +1 -1
  370. package/widgets/Legend/styles/classic/ClassicView.js +1 -1
  371. package/widgets/Locate/LocateViewModel.js +1 -1
  372. package/widgets/Locate.js +1 -1
  373. package/widgets/NavigationToggle/NavigationToggleViewModel.js +1 -1
  374. package/widgets/NavigationToggle.js +1 -1
  375. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  376. package/widgets/OrientedImageryViewer/galleryUtils.js +1 -1
  377. package/widgets/OrientedImageryViewer/services/SuperimposeService.js +1 -1
  378. package/widgets/OrientedImageryViewer/support/urlUtils.js +1 -1
  379. package/widgets/ScaleRangeSlider/ScaleRangeSliderViewModel.js +1 -1
  380. package/widgets/Search.js +1 -1
  381. package/widgets/ShadowCast/DiscreteOptions.js +1 -1
  382. package/widgets/ShadowCast/DurationOptions.js +1 -1
  383. package/widgets/ShadowCast/ShadowCastViewModel.js +1 -1
  384. package/widgets/ShadowCast/ThresholdOptions.js +1 -1
  385. package/widgets/Sketch.js +1 -1
  386. package/widgets/Slider/SliderViewModel.js +1 -1
  387. package/widgets/Slider.js +1 -1
  388. package/widgets/TableList/TableListViewModel.js +1 -1
  389. package/widgets/TimeSlider/TimeSliderViewModel.js +1 -1
  390. package/widgets/Weather/WeatherViewModel.js +1 -1
  391. package/widgets/Widget.js +1 -1
  392. package/widgets/Zoom/ZoomViewModel.js +1 -1
  393. package/widgets/support/AnalysisViewModelMixin.js +1 -1
  394. package/widgets/support/GridControls.js +1 -1
  395. package/widgets/support/dateUtils.js +1 -1
  396. package/assets/esri/core/workers/chunks/00d43f02119167531d1b.js +0 -1
  397. package/assets/esri/core/workers/chunks/0696fa44a04b99738d7b.js +0 -1
  398. package/assets/esri/core/workers/chunks/091ec4fe83038f3558f4.js +0 -1
  399. package/assets/esri/core/workers/chunks/098ac10877d92fde1006.js +0 -1
  400. package/assets/esri/core/workers/chunks/0a29d87b6e58a3c6df8f.js +0 -1
  401. package/assets/esri/core/workers/chunks/0d04353843ccb7440342.js +0 -1
  402. package/assets/esri/core/workers/chunks/0d87cb6417672de95d53.js +0 -1
  403. package/assets/esri/core/workers/chunks/1132e28aaa5825b10b6e.js +0 -1
  404. package/assets/esri/core/workers/chunks/1380cec385426673f294.js +0 -1
  405. package/assets/esri/core/workers/chunks/1b24a40c0fa197014873.js +0 -1
  406. package/assets/esri/core/workers/chunks/1c7096eb48a3a7f27d4f.js +0 -1
  407. package/assets/esri/core/workers/chunks/1cc03067f8405285057c.js +0 -1
  408. package/assets/esri/core/workers/chunks/1f76f6dcdae9f55389cb.js +0 -1
  409. package/assets/esri/core/workers/chunks/21e1d423ee33f916547e.js +0 -1
  410. package/assets/esri/core/workers/chunks/247617c0dbae2386ab3b.js +0 -1
  411. package/assets/esri/core/workers/chunks/25657f70c5f04a4ed978.js +0 -1
  412. package/assets/esri/core/workers/chunks/2690d5fcd9d5ca92ebf6.js +0 -1
  413. package/assets/esri/core/workers/chunks/2853606099602f73d379.js +0 -1
  414. package/assets/esri/core/workers/chunks/28ed020d9995b6577be5.js +0 -1
  415. package/assets/esri/core/workers/chunks/2b27d3bc492e000bbe58.js +0 -1
  416. package/assets/esri/core/workers/chunks/2d64a13c2303e9cae613.js +0 -1
  417. package/assets/esri/core/workers/chunks/36e5f070009b29b7ac3d.js +0 -1
  418. package/assets/esri/core/workers/chunks/3b5e9e0b180dc10491ec.js +0 -1
  419. package/assets/esri/core/workers/chunks/46edd6c9ed6701e6b975.js +0 -1
  420. package/assets/esri/core/workers/chunks/4e17665dd9048c300d87.js +0 -1
  421. package/assets/esri/core/workers/chunks/4e4f747de424941a0bfa.js +0 -1
  422. package/assets/esri/core/workers/chunks/4e8e322b469657ac22e2.js +0 -1
  423. package/assets/esri/core/workers/chunks/5396b6e99a0546a25d19.js +0 -1
  424. package/assets/esri/core/workers/chunks/553a8bf5bc5c56d1bcaf.js +0 -1
  425. package/assets/esri/core/workers/chunks/55c0c074e4afe05f5d4d.js +0 -1
  426. package/assets/esri/core/workers/chunks/5bfb962ca192f90a2724.js +0 -1
  427. package/assets/esri/core/workers/chunks/60c8eedd06080edab3e3.js +0 -1
  428. package/assets/esri/core/workers/chunks/61d36730564c5ac5edab.js +0 -1
  429. package/assets/esri/core/workers/chunks/6588725275c75fae0d9c.js +0 -1
  430. package/assets/esri/core/workers/chunks/661c6324529dd17b297e.js +0 -1
  431. package/assets/esri/core/workers/chunks/6699fac01ccd842851ba.js +0 -1
  432. package/assets/esri/core/workers/chunks/672a5390182b20d632be.js +0 -1
  433. package/assets/esri/core/workers/chunks/67caef2ecf0dc5f2eed3.js +0 -1
  434. package/assets/esri/core/workers/chunks/68dd1fd2025c7125ead1.js +0 -1
  435. package/assets/esri/core/workers/chunks/68fd7b314377d27aaa54.js +0 -1
  436. package/assets/esri/core/workers/chunks/69627b2634da64dd885f.js +0 -1
  437. package/assets/esri/core/workers/chunks/6f2e7e663229b223b4df.js +0 -1
  438. package/assets/esri/core/workers/chunks/7390af96250e89194332.js +0 -1
  439. package/assets/esri/core/workers/chunks/7b45ac83e279fe9516a5.js +0 -1
  440. package/assets/esri/core/workers/chunks/7e0ed6e8f7b77e43f628.js +0 -1
  441. package/assets/esri/core/workers/chunks/832c887fdc5af4c08cf2.js +0 -1
  442. package/assets/esri/core/workers/chunks/84fb27e3425515cd0e3f.js +0 -1
  443. package/assets/esri/core/workers/chunks/8502274806ea52308822.js +0 -1
  444. package/assets/esri/core/workers/chunks/867502158997cb2d6406.js +0 -1
  445. package/assets/esri/core/workers/chunks/8ceb6697e8adbeffe019.js +0 -1
  446. package/assets/esri/core/workers/chunks/8e391b5b82429f39791e.js +0 -1
  447. package/assets/esri/core/workers/chunks/8e6276ddd8d094c61f08.js +0 -1
  448. package/assets/esri/core/workers/chunks/8fe22c2370219f25c15b.js +0 -1
  449. package/assets/esri/core/workers/chunks/90d797ab82d4a68ba32f.js +0 -1
  450. package/assets/esri/core/workers/chunks/91586bf29492735e692d.js +0 -1
  451. package/assets/esri/core/workers/chunks/96f87c8efd4b11b37686.js +0 -1
  452. package/assets/esri/core/workers/chunks/9826baa3c15ea2062669.js +0 -1
  453. package/assets/esri/core/workers/chunks/9c3de54513bf8619271c.js +0 -1
  454. package/assets/esri/core/workers/chunks/a125650edbed802e419a.js +0 -1
  455. package/assets/esri/core/workers/chunks/a18c3cbe505a19d29569.js +0 -1
  456. package/assets/esri/core/workers/chunks/a422a801e55fa125546e.js +0 -1
  457. package/assets/esri/core/workers/chunks/a5f17e9a025ac2b6e1bf.js +0 -1
  458. package/assets/esri/core/workers/chunks/a6e846361bf5dd3a11c7.js +0 -1
  459. package/assets/esri/core/workers/chunks/a91dc05a6a609d04ed04.js +0 -1
  460. package/assets/esri/core/workers/chunks/a99c50b4e1c7568210e1.js +0 -1
  461. package/assets/esri/core/workers/chunks/ab48faea5432e2dbd45c.js +0 -1
  462. package/assets/esri/core/workers/chunks/ac107079342251a984dd.js +0 -1
  463. package/assets/esri/core/workers/chunks/acf4737ba509cbd73cce.js +0 -1
  464. package/assets/esri/core/workers/chunks/b7205620ca248f4efc88.js +0 -1
  465. package/assets/esri/core/workers/chunks/bbddeb1c893ff8bbae5d.js +0 -1
  466. package/assets/esri/core/workers/chunks/bc2e2bdf1194e6e9eb5e.js +0 -1
  467. package/assets/esri/core/workers/chunks/c0eb27263f608dc3684b.js +0 -1
  468. package/assets/esri/core/workers/chunks/c3ba1a3247e14f6b7b3a.js +0 -1
  469. package/assets/esri/core/workers/chunks/c5d0a034ff31d5954571.js +0 -1
  470. package/assets/esri/core/workers/chunks/c8057b47c7c6c02a0bda.js +0 -1
  471. package/assets/esri/core/workers/chunks/ca21786e519c914fc9e1.js +0 -1
  472. package/assets/esri/core/workers/chunks/cd46d9b4a8de644e7332.js +0 -1
  473. package/assets/esri/core/workers/chunks/d4c8673ca65df874a7ce.js +0 -1
  474. package/assets/esri/core/workers/chunks/da1e6962ba0c85c37953.js +0 -1
  475. package/assets/esri/core/workers/chunks/dcdf837a452dc0cac582.js +0 -1
  476. package/assets/esri/core/workers/chunks/e0864ca82ffa3c9a0776.js +0 -1
  477. package/assets/esri/core/workers/chunks/e69cd62f824ce7a22fa0.js +0 -1
  478. package/assets/esri/core/workers/chunks/e9457a67befc61e11095.js +0 -1
  479. package/assets/esri/core/workers/chunks/f190a3124d6d03417d73.js +0 -1
  480. package/assets/esri/core/workers/chunks/f4135779bfdaf349352a.js +0 -1
  481. package/assets/esri/core/workers/chunks/f6bd7b52745b82ba73dc.js +0 -1
  482. package/assets/esri/core/workers/chunks/fbe3a3b9d6c8c0b52f65.js +0 -1
  483. package/assets/esri/core/workers/chunks/fc77eb7683e708774168.js +0 -1
  484. package/assets/esri/core/workers/chunks/fe7184993ef5713d13fb.js +0 -1
  485. package/assets/esri/core/workers/chunks/fecaf0bc28aeea4d15db.js +0 -1
  486. package/views/2d/engine/vectorTiles/style/VectorTilePbfWriter.js +0 -2
  487. package/views/2d/engine/vectorTiles/style/encodeVectorTileFeatures.js +0 -2
  488. package/views/2d/layers/features/support/FeatureSetReaderVectorTileFeatureCursor.js +0 -2
  489. /package/views/2d/engine/vectorTiles/{Feature.js → PbfFeature.js} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8245],{11006(e,t,i){function r(e,t,i,r,s){n(e,t,i||0,r||e.length-1,s||a)}function n(e,t,i,r,a){for(;r>i;){if(r-i>600){var l=r-i+1,o=t-i+1,u=Math.log(l),d=.5*Math.exp(2*u/3),c=.5*Math.sqrt(u*d*(l-d)/l)*(o-l/2<0?-1:1);n(e,t,Math.max(i,Math.floor(t-o*d/l+c)),Math.min(r,Math.floor(t+(l-o)*d/l+c)),a)}var h=e[t],f=i,p=r;for(s(e,i,t),a(e[r],h)>0&&s(e,i,r);f<p;){for(s(e,f,p),f++,p--;a(e[f],h)<0;)f++;for(;a(e[p],h)>0;)p--}0===a(e[i],h)?s(e,i,p):s(e,++p,r),p<=t&&(i=p+1),t<=p&&(r=p-1)}}function s(e,t,i){var r=e[t];e[t]=e[i],e[i]=r}function a(e,t){return e<t?-1:+(e>t)}i.d(t,{q:()=>r})},69052(e,t,i){i.d(t,{hr:()=>n});var r=i(34727);class n{constructor(e,t){this.min=e,this.max=t,this.range=t-e}normalize(e,t=0,i=!1){return s(this.range,this.min,this.max,e,t,i)}clamp(e,t=0){return(0,r.qE)(e-t,this.min,this.max)+t}monotonic(e,t,i){return e<t?t:t+a(this.range,e-t,i)}minimalMonotonic(e,t,i){return s(this.range,e,e+this.range,t,i)}center(e,t,i){return t=this.monotonic(e,t,i),this.normalize((e+t)/2,i)}diff(e,t,i){return this.monotonic(e,t,i)-e}shortestSignedDiff(e,t){e=this.normalize(e);let i=(t=this.normalize(t))-e,r=t<e?this.minimalMonotonic(e,t)-e:t-this.minimalMonotonic(t,e);return Math.abs(i)<Math.abs(r)?i:r}contains(e,t,i){return t=this.minimalMonotonic(e,t),(i=this.minimalMonotonic(e,i))>e&&i<t}}function s(e,t,i,r,n=0,s=!1){return(r-=n)<t?r+=a(e,t-r):r>i&&(r-=a(e,r-i)),s&&r===i&&(r=t),r+n}function a(e,t,i=0){return Math.ceil((t-i)/e)*e+i}const l=new n(0,2*Math.PI),o=(new n(-Math.PI,Math.PI),new n(0,360));i.d(t,["ie",0,o,"uC",0,l])},18370(e,t,i){i.d(t,{z:()=>n});class r{constructor(e){this._import=e,this.module=null,this._promise=null}getImportPromise(){return this._promise??=this._import().then(async e=>(this.module=e,e)),this._promise}}function n(e){return new r(e)}},44123(e,t,i){i.d(t,{WhereClauseCache:()=>s});var r=i(66344),n=i(89696);class s{constructor(e,t){this._cache=new r.q(e),this._invalidCache=new r.q(t)}get(e,t){let i=`${t?.uid}:${e}`,r=this._cache.get(i);if(r)return r;if(null!=this._invalidCache.get(i))return null;try{let r=n.A.create(e,{fieldsIndex:t});return this._cache.put(i,r),r}catch(e){return this._invalidCache.put(i,e),null}}getError(e,t){let i=`${t?.uid}:${e}`;return this._invalidCache.get(i)??null}}},52039(e,t,i){i.d(t,{O7:()=>h,el:()=>u});var r=i(69052),n=(i(49186),i(18370)),s=i(17676),a=(i(5443),i(39829)),l=(i(82799),i(16930)),o=(i(80754),i(21325));async function u(e,t,i){Array.isArray(e)||(e=[e]),"object"==typeof t&&t&&"authMode"in t&&(i=t);let r=null;for(let t of e)r??=t?.spatialReference;if(!r)return e;let n=(0,o.Vp)(r);if(!n)return e;if(1===e.length&&"extent"===e[0]?.type){let t=e[0].clone().normalizeAsSingleGeometry(n);return["xmin"in t?t:new a.A(t)]}let[l,u]=n.valid,h=!1;for(let t of e){if(!t)continue;if("point"===t.type){h||=t.x>=u,h||=t.x<=l;continue}let{extent:e}=t;if(null==e){h=!0;break}h||=e.xmin>=u,h||=e.xmin<=l,h||=e.xmax>=u,h||=e.xmax<=l}if(!h)return e;let[{foldInto360Range:f},p]=await(0,s.qr)(Promise.all([d.getImportPromise(),c.getImportPromise()]),i),m=p.fromSpatialReference(r);return e.map(e=>{if(null==e||"mesh"===e.type)return e;let t=p.fromGeometry(e),i=p.toGeometry(f(t,m),r);return"extent"===e.type&&1===i?.rings.length?i.extent:i})}const d=(0,n.z)(()=>i.e(4144).then(()=>i(4144)).then(e=>e.load().then(()=>e))),c=(0,n.z)(()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(1550)]).then(()=>i(78125)));function h(e,t,i){let r=(0,o.Vp)(i);if(null==r)return e;let[n,s]=r.valid,a=2*s,l=0,u=0;t>s?l=Math.ceil(Math.abs(t-s)/a):t<n&&(l=-Math.ceil(Math.abs(t-n)/a)),e>s?u=Math.ceil(Math.abs(e-s)/a):e<n&&(u=-Math.ceil(Math.abs(e-n)/a));let d=e+(l-u)*a,c=d-t;return c>s?d-=a:c<n&&(d+=a),d}function f(e){let t=(0,o.Vp)(e);if(null==t)return null;let[i,n]=t.valid;return new r.hr(i,n)}const p=f(l.A.WGS84);f(l.A.WebMercator),i.d(t,["Y_",0,p])},80754(e,t,i){i.d(t,{kS:()=>u,kd:()=>o});var r=i(82799),n=i(16930),s=i(60408),a=i(52006);const l={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new r.A({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:n.A.WebMercator}),minus180Line:new r.A({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:n.A.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new r.A({paths:[[[180,-180],[180,180]]],spatialReference:n.A.WGS84}),minus180Line:new r.A({paths:[[[-180,-180],[-180,180]]],spatialReference:n.A.WGS84})}};function o(e,t){return Math.ceil((e-t)/(2*t))}function u(e,t){if((0,a.Ed)(e))for(let i of function(e){return(0,s.Bi)(e)?e.curveRings:e.curvePaths}(e))for(let e of i)if((0,a.aO)(e)){let[i,r]=e.c;i[0]+=t,r[0]+=t}else if((0,a.FG)(e)){let[i,r]=e.a;i[0]+=t,r[0]+=t}else if((0,a.n1)(e)){let[i,r,n]=e.b;i[0]+=t,r[0]+=t,n[0]+=t}else e[0]+=t;for(let i of function(e){return(0,s.Bi)(e)?e.rings:e.paths}(e))for(let e of i)e[0]+=t;return e}i.d(t,["j7",0,l])},62577(e,t,i){function r(e){return e?{originPosition:"upper-left"===e.originPosition?"upperLeft":"lower-left"===e.originPosition?"lowerLeft":e.originPosition,scale:e.tolerance?[e.tolerance,e.tolerance,1,1]:[1,1,1,1],translate:null==e.extent?[0,0,0,0]:[e.extent.xmin,e.extent.ymax,e.extent.zmin??0,e.extent.mmin??0]}:null}function n(e){if(function(e){return"lowerLeft"===e.originPosition&&4===e.scale.length&&4===e.translate.length}(e))return e;let{originPosition:t,scale:i,translate:r}=e,n=i[0]??1,s=i[1]??1;return{originPosition:"lowerLeft",scale:[n,"lowerLeft"===t?s:-s,i[2]??1,i[3]??1],translate:[r[0]??0,r[1]??0,r[2]??0,r[3]??0]}}function s({scale:e,translate:t},i){return Math.round((i-t[0])/e[0])}function a({scale:e,translate:t},i){return Math.round((i-t[1])/e[1])}function l({scale:e,translate:t},i){return i*e[0]+t[0]}function o({scale:e,translate:t},i){return i*e[1]+t[1]}function u({scale:e,translate:t},i){return(i??0)*e[2]+t[2]}function d({scale:e,translate:t},i){return i?i*e[3]+t[3]:0}function c(e,t){return e&&t?m:e&&!t?f:!e&&t?p:h}i.d(t,{$X:()=>v,B2:()=>a,Gy:()=>g,IE:()=>s,P5:()=>T,Q1:()=>n,SW:()=>x,Tr:()=>_,VV:()=>r});const h=(e,t)=>{let i=Array(t.length);if(!t.length)return i;let r=t[0],n=l(e,r[0]),s=o(e,r[1]);i[0]=[n,s];let{scale:a,originPosition:u}=e,d=a[0],c="lowerLeft"===u?a[1]:-a[1];for(let e=1;e<t.length;e++){let[r,a]=t[e];n+=d*r,s+=c*a,i[e]=[n,s]}return i},f=(e,t)=>{let i=Array(t.length);if(!t.length)return i;let r=t[0],n=l(e,r[0]),s=o(e,r[1]);i[0]=[n,s,u(e,r[2])];let{scale:a,originPosition:d}=e,c=a[0],h="lowerLeft"===d?a[1]:-a[1];for(let r=1;r<t.length;r++){let[a,l,o]=t[r];n+=c*a,s+=h*l,i[r]=[n,s,u(e,o)]}return i},p=(e,t)=>{let i=Array(t.length);if(!t.length)return i;let r=t[0],n=l(e,r[0]),s=o(e,r[1]);i[0]=[n,s,d(e,r[2])];let{scale:a,originPosition:u}=e,c=a[0],h="lowerLeft"===u?a[1]:-a[1];for(let r=1;r<t.length;r++){let[a,l,o]=t[r];n+=c*a,s+=h*l,i[r]=[n,s,d(e,o)]}return i},m=(e,t)=>{let i=Array(t.length);if(!t.length)return i;let r=t[0],n=l(e,r[0]),s=o(e,r[1]);i[0]=[n,s,u(e,r[2]),d(e,r[3])];let{scale:a,originPosition:c}=e,h=a[0],f="lowerLeft"===c?a[1]:-a[1];for(let r=1;r<t.length;r++){let[a,l,o,c]=t[r];n+=h*a,s+=f*l,i[r]=[n,s,u(e,o),d(e,c)]}return i};function y(e,t,i){let r=Array(i.length);for(let n=0;n<i.length;n++)r[n]=t(e,i[n]);return r}function g(e,t,i){let r=n(e);return t.x=s(r,i.x),t.y=a(r,i.y),null!=i.z&&(t.z=function({scale:e,translate:t},i){return Math.round(((i??0)-t[2])/e[2])}(r,i.z)),null!=i.m&&(t.m=function({scale:e,translate:t},i){return i?Math.round((i-t[3])/e[3]):0}(r,i.m)),t}function x(e,t,i,r=i?.hasZ??!1,s=i?.hasM??!1){if(null!=i){let a=n(e);t.points=c(r,s)(a,i.points),t.hasZ=r,t.hasM=s}return t}function _(e,t,i,r=null!=i?.z,s=null!=i?.m){if(null==i)return t;let a=n(e);return t.x=l(a,i.x),t.y=o(a,i.y),r&&(t.z=u(a,i.z)),s&&(t.m=d(a,i.m)),t}function v(e,t,i,r=i?.hasZ??!1,s=i?.hasM??!1){return null!=i&&(t.rings=y(n(e),c(r,s),i.rings),t.hasZ=r,t.hasM=s),t}function T(e,t,i,r=i?.hasZ??!1,s=i?.hasM??!1){return null!=i&&(t.paths=y(n(e),c(r,s),i.paths),t.hasZ=r,t.hasM=s),t}},43334(e,t,i){i.d(t,{N3:()=>l,Om:()=>a});var r=i(69397),n=i(27647),s=i(92722);class a{constructor(e,t,i,r,n=0,s=null,a=null){this.geometry=e,this.attributes=t,this.centroid=i,this.objectId=r,this.displayId=n,this.distance=s,this.vertexCount=a}static fromJSON(e){let t=e.geometry?s.A.fromJSON(e.geometry):null,i=e.centroid?s.A.fromJSON(e.centroid):null,r=e.objectId;return new a(t,e.attributes,i,r,void 0,e.distance,e.vertexCount)}weakClone(){return new a(this.geometry,this.attributes,this.centroid,this.objectId,this.displayId,this.distance,this.vertexCount)}clone(){return new a(this.geometry?.clone(),{...this.attributes},this.centroid?.clone(),this.objectId,this.displayId,this.distance,this.vertexCount)}ensureCentroid(e){return this.centroid??=(0,n.Q)(this.geometry),this.centroid}get usedMemory(){return 128+(0,r.lM)(this.attributes)+(this.geometry?.usedMemory??0)}}function l(e){return!!e.geometry?.coords?.length}},58512(e,t,i){i.d(t,{A:()=>r});class r{constructor(){this.globalIdFieldName=null,this.geohashFieldName=null,this.geometryProperties=null,this.geometryType=null,this.spatialReference=null,this.hasZ=!1,this.hasM=!1,this.features=[],this.fields=[],this.transform=null,this.exceededTransferLimit=!1,this.uniqueIdField=null,this.queryGeometryType=null,this.queryGeometry=null}weakClone(){let e=new r;return e.globalIdFieldName=this.globalIdFieldName,e.geohashFieldName=this.geohashFieldName,e.geometryProperties=this.geometryProperties,e.geometryType=this.geometryType,e.spatialReference=this.spatialReference,e.hasZ=this.hasZ,e.hasM=this.hasM,e.features=this.features,e.fields=this.fields,e.transform=this.transform,e.exceededTransferLimit=this.exceededTransferLimit,e.uniqueIdField=this.uniqueIdField,e.queryGeometry=this.queryGeometry,e.queryGeometryType=this.queryGeometryType,e}}},92722(e,t,i){i.d(t,{A:()=>n});var r=i(69397);class n{constructor(e=[],t=[],i=!1,r=!1){this.lengths=e??[],this.coords=t??[],this.hasZ=i,this.hasM=r}static fromJSON({lengths:e,coords:t,hasZ:i,hasM:r}){return new n(e,t,i||!1,r||!1)}static fromRect([e,t,i,r]){let s=i-e,a=r-t;return new n([5],[e,t,s,0,0,a,-s,0,0,-a])}get isPoint(){return 0===this.lengths.length&&this.coords.length>=2}get maxLength(){return Math.max(...this.lengths)}get size(){return this.isPoint?1:this.lengths.reduce((e,t)=>e+t,0)}get usedMemory(){return 64+(0,r.Qf)(this.lengths,this.coords)}get stride(){return+!!this.hasZ+2+ +!!this.hasM}area(){if(this.isPoint)return 0;let e=0,t=0;for(let i of this.lengths){if(i<3)continue;let{stride:r}=this,n=this.coords[r*t],s=this.coords[r*t+1];for(let a=1;a<i;a+=1){let i=r*(t+a),l=this.coords[i],o=this.coords[i+1];e+=-.5*(l-n)*(o+s),n=l,s=o}t+=i}return e}forEachVertex(e){let t=0;if(this.isPoint)return e(this.coords[0],this.coords[1]);let{stride:i}=this;for(let r of this.lengths){for(let n=0;n<r;n++){let r=i*(t+n);e(this.coords[r],this.coords[r+1])}t+=r}}deltaDecode(){let e=this.clone(),{coords:t,lengths:i}=e,r=0,{stride:n}=this;for(let e of i){for(let i=1;i<e;i++){let e=n*(r+i);t[e]+=t[e-n],t[e+1]+=t[e+1-n]}r+=e}return e}clone(e){if(this.isPoint)return new n([],Array.from(this.coords.slice(0,this.stride)),this.hasZ,this.hasM);let t=Array.from(this.lengths),{stride:i,size:r}=this,s=this.coords.slice(0,r*i);return e?(e.set(s),new n(t,e,this.hasZ,this.hasM)):new n(t,Array.from(s),this.hasZ,this.hasM)}justXY(){let{stride:e,size:t}=this;if(2===e)return this;let i=Array(t*e);for(let t=0,r=0;t<i.length;t+=e)i[r++]=this.coords[t],i[r++]=this.coords[t+1];return new n(this.lengths,i,!1,!1)}}},27647(e,t,i){i.d(t,{Q:()=>s});var r=i(92722);function n(e,t){return e?t?4:3:t?3:2}function s(e){if(null==e||!e?.lengths.length)return null;let{lengths:t,coords:i,stride:n,hasZ:s,hasM:o}=e,u=new r.A([],[],s,!1),d=u.coords,c=[],h=s?[1/0,-1/0,1/0,-1/0,1/0,-1/0]:[1/0,-1/0,1/0,-1/0],f=0;for(let e of t){let t=a(h,i,f,e,s,o);t&&c.push(t),f+=e*n}if(c.sort((e,t)=>{let i=e[2]-t[2];return 0===i&&s&&(i=e[4]-t[4]),i}),c.length){let e=6*c[0][2];d[0]=c[0][0]/e,d[1]=c[0][1]/e,s&&(e=6*c[0][4],d[2]=0===e?0:c[0][3]/e),(d[0]<h[0]||d[0]>h[1]||d[1]<h[2]||d[1]>h[3]||s&&(d[2]<h[4]||d[2]>h[5]))&&(d.length=0)}if(!d.length){let r=e.lengths[0]?l(i,0,t[0],s,o):null;if(!r)return null;d[0]=r[0],d[1]=r[1],s&&(d[2]=r[2]??0)}return u}function a(e,t,i,r,s,a){let l=n(s,a),o=i,u=i+l,d=0,c=0,h=0,f=0,p=0;for(let i=0,n=r-1;i<n;i++,o+=l,u+=l){let i=t[o],r=t[o+1],n=t[o+2],a=t[u],l=t[u+1],m=t[u+2],y=i*l-a*r;f+=y,d+=(i+a)*y,c+=(r+l)*y,s&&(y=i*m-a*n,h+=(n+m)*y,p+=y),i<e[0]&&(e[0]=i),i>e[1]&&(e[1]=i),r<e[2]&&(e[2]=r),r>e[3]&&(e[3]=r),s&&(n<e[4]&&(e[4]=n),n>e[5]&&(e[5]=n))}if(f>0&&(f*=-1),p>0&&(p*=-1),!f)return null;let m=[d,c,.5*f];return s&&(m[3]=h,m[4]=.5*p),m}function l(e,t,i,r,s){let a=n(r,s),l=t,h=t+a,f=0,p=0,m=0,y=0;for(let t=0,n=i-1;t<n;t++,l+=a,h+=a){let t=e[l],i=e[l+1],n=e[l+2],s=e[h],a=e[h+1],g=e[h+2],x=r?u(t,i,n,s,a,g):o(t,i,s,a);if(x)if(f+=x,r){let e=c(t,i,n,s,a,g);p+=x*e[0],m+=x*e[1],y+=x*e[2]}else{let e=d(t,i,s,a);p+=x*e[0],m+=x*e[1]}}return f>0?r?[p/f,m/f,y/f]:[p/f,m/f]:i>0?r?[e[t],e[t+1],e[t+2]]:[e[t],e[t+1]]:null}function o(e,t,i,r){let n=i-e,s=r-t;return Math.sqrt(n*n+s*s)}function u(e,t,i,r,n,s){let a=r-e,l=n-t,o=s-i;return Math.sqrt(a*a+l*l+o*o)}function d(e,t,i,r){return[e+.5*(i-e),t+.5*(r-t)]}function c(e,t,i,r,n,s){return[e+.5*(r-e),t+.5*(n-t),i+.5*(s-i)]}},75752(e,t,i){i.d(t,{do:()=>B,qo:()=>L,Wc:()=>q});var r=i(4576),n=i(21818),s=i(49186),a=(i(44208),i(4718)),l=i(97768),o=i(17676),u=i(86211),d=i(12195),c=i(99917),h=i(70328),f=i(19419),p=i(537),m=i(60408),y=i(65864),g=i(52039),x=i(21325),_=i(90708),v=i(29441),T=i(51441),F=i(31464);class S{constructor(){this._storage=new Map,this._purgeInterval=5,this._sweep=()=>{if(this._timer=void 0,!this._storage)return;let e=1e3*this._purgeInterval,t=performance.now()-e;for(let[i,r]of this._storage){if(!(r.time<t))return void(this._storage.size>0&&(this._timer=setTimeout(this._sweep,e)));this._storage.delete(i)}}}destroy(){this._storage?.clear(),this._storage=null,clearTimeout(this._timer)}put(e,t){this._storage?.set(e,new w(t)),this._scheduleSweep()}get(e){let t=this._storage?.get(e);if(t)return this._storage?.delete(e),t.time=performance.now(),this._storage?.set(e,t),t.items}clear(){this._storage?.clear()}_scheduleSweep(){this._storage&&(this._timer??=setTimeout(this._sweep,1e3*this._purgeInterval))}get test(){}}let I=0;class w{constructor(e){this.items=e,this.time=performance.now(),this.id=I++}}var R=i(99352),E=i(8384),A=i(58727),M=i(62660),b=i(43668);const C="unsupported-query";async function O(e,{fieldsIndex:t,geometryType:i,spatialReference:r,availableFields:n}){if(null!=e.geometryPrecision||e.multipatchOption&&"xyFootprint"!==e.multipatchOption||e.pixelSize||e.relationParam||e.text)throw new s.A(C,"Unsupported query options",{query:e});return N(t,n,e),function(e,t,i){let{outStatistics:r,groupByFieldsForStatistics:n,having:a}=i,l=n?.length,o=r?.length;if(a){if(!l||!o)throw new s.A(C,"outStatistics and groupByFieldsForStatistics should be specified with having",{query:i});(0,v.eD)(e,t,a,r,i)}if(o){if(!(0,v._d)(r))return;let a=(0,v.g9)(e,r,n);(0,v.MG)(e,t,a,{expressionName:"statistics",query:i});for(let n of r){let{onStatisticField:r,statisticType:a}=n;if("percentile_disc"!==a&&"percentile_cont"!==a||!("statisticParameters"in n))e.get(r)&&"count"!==a&&"min"!==a&&"max"!==a&&(0,v.MG)(e,t,[r],{expressionName:`outStatistics with '${a}' statistic type`,allowedFieldTypes:V,query:i});else{let{statisticParameters:e}=n;if(!e)throw new s.A(C,"statisticParameters should be set for percentile type",{definition:n,query:i})}}}}(t,n,e),Promise.all([(0,M.c0)(e,i,r),(0,F.Nk)(r,e.outSR)]).then(()=>e)}function N(e,t,i){let{returnDistinctValues:r,outStatistics:n}=i,a=n?n.map(e=>e.outStatisticFieldName&&e.outStatisticFieldName.toLowerCase()).filter(Boolean):[];if("orderByFields"in i&&i.orderByFields&&i.orderByFields.length>0){let r=" asc",n=" desc",s=i.orderByFields.map(e=>{let t=e.toLowerCase();return t.includes(r)?t.split(r)[0]:t.includes(n)?t.split(n)[0]:e}).filter(e=>!a.includes(e));(0,v.MG)(e,t,s,{expressionName:"orderByFields",query:i})}if("outFields"in i)if(i.outFields?.length)(0,v.MG)(e,t,i.outFields,{expressionName:"outFields",query:i,allowedFieldTypes:"all"});else if(r)throw new s.A(C,"outFields should be specified for returnDistinctValues",{query:i});(0,v.SN)(e,t,i.where,i)}const V=new Set([...v.vl,...v.VW]);async function z(e,t,i,r){let n=[];if(i.valueExpression){let{arcadeUtils:e}=await(0,b.l)();n=e.extractFieldNames(i.valueExpression)}if(i.field&&n.push(i.field),i.field2&&n.push(i.field2),i.field3&&n.push(i.field3),i.normalizationField&&n.push(i.normalizationField),!n.length&&!i.valueExpression)throw new s.A(C,"field or valueExpression is required",{params:i});(0,v.MG)(e,t,n,{expressionName:"statistics",query:r})}var P=i(86420),G=i(95466),D=i(92359);class B{constructor(e){this._changeHandle=null,this.capabilities={query:R.F},this.geometryType=e.geometryType,this.hasM=!!e.hasM,this.hasZ=!!e.hasZ,this.spatialReference=e.spatialReference,this.definitionExpression=e.definitionExpression,this.featureStore=e.featureStore,this.aggregateAdapter=e.aggregateAdapter,this._cache=e.cache??new S,this.timeInfo=e.timeInfo,this.featureIdInfo=e.featureIdInfo,this._changeHandle=this.featureStore.events.on("changed",()=>this._clearCache()),this.fieldsIndex=(0,d.W)(e.fieldsIndex)?e.fieldsIndex:G.A.fromJSON(e.fieldsIndex),this.availableFields=!e.availableFields||1===e.availableFields.length&&"*"===e.availableFields[0]?new Set(this.fieldsIndex.fields.map(e=>e.name)):new Set(e.availableFields.map(e=>this.fieldsIndex.get(e)?.name).filter(e=>null!=e)),this._frameTask=e.scheduler&&e.priority?e.scheduler.registerTask(e.priority):D.nu}destroy(){this._changeHandle=(0,l.xt)(this._changeHandle),this._frameTask=(0,l.xt)(this._frameTask),this._clearCache(),(0,l.pR)(this._cache)}get featureAdapter(){return this.featureStore.featureAdapter}async executeQuery(e,t){let i=(0,o.Mq)(t);return await this._frameTask.scheduleGenerator(()=>this._executeQueryFeatureSet(e),i)}async executeQueryForCount(e={},t){let i=(0,o.Mq)(t);return await this._frameTask.scheduleGenerator(()=>this._executeQueryForCount(e),i)}async executeQueryForExtent(e,t){let i=(0,o.Mq)(t);return await this._frameTask.scheduleGenerator(()=>this._executeQueryForExtent(e),i)}async executeQueryForIds(e,t){return Array.from(await this.executeQueryForIdSet(e,t))}async executeQueryForIdSet(e,t){let i=(0,o.Mq)(t);return await this._frameTask.scheduleGenerator(()=>this._executeQueryForIdSet(e),i)}async executeQueryForLatestObservations(e,t){let i=(0,o.Mq)(t);if(!this.timeInfo?.trackIdField)throw new s.A("unsupported-query","Missing timeInfo or timeInfo.trackIdField",{query:e,timeInfo:this.timeInfo});return await this._frameTask.scheduleGenerator(()=>this._executeQueryForLatestObservations(e),i)}async executeQueryForOpaqueFeatures(e,t){let i=(0,o.Mq)(t);return(await this._frameTask.scheduleGenerator(()=>this._executeQuery(e,{}),i)).items}async executeAttributeBinsQuery(e,t){let i=(0,o.Mq)(t);return e=(0,a.o8)(e),await this._frameTask.scheduleGenerator(()=>this._executeAttributeBinsQuery(e),i)}async executeQueryForSummaryStatistics(e={},t,i){let r=(0,o.Mq)(i);return await this._frameTask.scheduleGenerator(()=>this._executeQueryForSummaryStatistics(e,t),r)}async executeQueryForUniqueValues(e={},t,i){let r=(0,o.Mq)(i);return await this._frameTask.scheduleGenerator(()=>this._executeQueryForUniqueValues(e,t),r)}async executeQueryForClassBreaks(e={},t,i){let r=(0,o.Mq)(i);return await this._frameTask.scheduleGenerator(()=>this._executeQueryForClassBreaks(e,t),r)}async executeQueryForHistogram(e={},t,i){let r=(0,o.Mq)(i);return await this._frameTask.scheduleGenerator(()=>this._executeQueryForHistogram(e,t),r)}async executeQueryForSnapping(e,t){let i=(0,o.Mq)(t);return await this._frameTask.scheduleGenerator(()=>this._executeQueryForSnapping(e,i),i)}async fetchRecomputedExtents(e){let t=(0,o.Mq)(e);this._timeExtentPromise||=(0,P.W)(this.timeInfo,this.featureStore);let[i,r]=await Promise.all([this._getFullExtent(),this._timeExtentPromise]);return(0,o.Te)(t),{fullExtent:i,timeExtent:r}}_clearCache(){this._cache.clear(),this._allFeaturesPromise=null,this._timeExtentPromise=null,this._fullExtentPromise=null}async*_executeQueryFeatureSet(e){try{let t=yield*this._executeQuery(e,{});return yield,await t.createQueryResponse()}catch(t){if(t!==A.v8)throw t;return await new E.G([],e,this).createQueryResponse()}}async*_executeQueryForCount(e){try{let t=yield*this._executeQuery(e,{returnGeometry:!1,returnCentroid:!1,outSR:null});return yield,t.createQueryResponseForCount()}catch(e){if(e!==A.v8)throw e;return 0}}async*_executeQueryForExtent(e){let t=e.outSR;try{let i=yield*this._executeQuery(e,{returnGeometry:!0,returnCentroid:!1,outSR:null});yield;let r=i.size;if(!r)return{count:0,extent:null};let n=await this._getBounds(i.items,i.spatialReference,t??this.spatialReference);return yield,{count:r,extent:n}}catch(e){if(e===A.v8)return{count:0,extent:null};throw e}}async*_executeQueryForIdSet(e){try{let t=yield*this._executeQuery(e,{returnGeometry:!0,returnCentroid:!1,outSR:null});yield;let i=t.items,r=new Set;for(let e of i)r.add(t.featureAdapter.getObjectId(e));return r}catch(e){if(e===A.v8)return new Set;throw e}}async*_executeQueryForLatestObservations(e){try{let t=yield*this._executeQuery(e,{});return yield,this._filterLatest(t),yield,await t.createQueryResponse()}catch(t){if(t!==A.v8)throw t;return await new E.G([],e,this).createQueryResponse()}}async*_executeAttributeBinsQuery(e){let t;try{e=await(0,A.iJ)(e,this.definitionExpression,this.spatialReference),yield,e=await async function(e,t){let i=e.bin;if(!i.onField&&!i.onExpression?.value||"autoIntervalBin"===i.type&&null==i.parameters.numberOfBins||"dateBin"===i.type&&(null==i.parameters.number||null==i.parameters.unit)||"fixedBoundariesBin"===i.type&&null==i.parameters.boundaries||"fixedIntervalBin"===i.type&&null==i.parameters.interval)throw new s.A(C,"Unsupported query options",{query:e});return O(e,t)}(e,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference}),yield;let i=yield*this._executeSceneFilterQuery(e);yield,t=yield*this._executeGeometryQuery(e,i),yield,this._executeAggregateIdsQuery(t),yield,this._executeObjectIdsQuery(t),yield,this._executeTimeQuery(t),yield,this._executeAttributesQuery(t),yield}catch(i){if(i!==A.v8)throw i;t=new E.G([],e,this)}return await t.createQueryBinsResponse(e)}async*_executeQueryForSummaryStatistics(e={},t){let{field:i,normalizationField:r,valueExpression:n}=t,s=yield*this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n});return yield,await s.createSummaryStatisticsResponse(t)}async*_executeQueryForUniqueValues(e={},t){let{field:i,field2:r,field3:n,valueExpression:s}=t,a=yield*this._executeQueryForStatistics(e,{field:i,field2:r,field3:n,valueExpression:s});return yield,await a.createUniqueValuesResponse(t)}async*_executeQueryForClassBreaks(e,t){let{field:i,normalizationField:r,valueExpression:n}=t,s=yield*this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n});return yield,await s.createClassBreaksResponse(t)}async*_executeQueryForHistogram(e,t){let{field:i,normalizationField:r,valueExpression:n}=t,s=yield*this._executeQueryForStatistics(e,{field:i,normalizationField:r,valueExpression:n});return yield,await s.createHistogramResponse(t)}async*_executeQueryForSnapping(e,t){let{point:i,distance:r,returnEdge:n,vertexMode:s}=e;if(!n&&"none"===s)return{candidates:[]};let l=(0,a.o8)(e.query);l=await(0,A.T2)(l,this.definitionExpression,this.spatialReference),yield,l=await O(l,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference}),yield;let o=!(0,x.aI)(i.spatialReference,this.spatialReference);o&&(await(0,F.Nk)(i.spatialReference,this.spatialReference),yield);let u="number"==typeof r?r:r.x,d="number"==typeof r?r:r.y,c={xmin:i.x-u,xmax:i.x+u,ymin:i.y-d,ymax:i.y+d,spatialReference:i.spatialReference},h=o?(0,F.Cv)(c,this.spatialReference):c;if(!h)return{candidates:[]};let[f]=await(0,g.el)((0,y.rS)(i),{signal:t});yield;let[p]=await(0,g.el)((0,y.rS)(h),{signal:t});if(yield,null==f||null==p)return{candidates:[]};let m=await this._searchFeatures(L(p.toJSON()));yield;let _=new E.G(m,l,this);this._executeObjectIdsQuery(_),yield,this._executeTimeQuery(_),yield,this._executeAttributesQuery(_),yield,yield*this._executeGeometryQueryForSnapping(_),yield;let v=f.toJSON(),T=o?(0,F.Cv)(v,this.spatialReference):v,S=o?Math.max(h.xmax-h.xmin,h.ymax-h.ymin)/2:r;return _.createSnappingResponse({...e,point:T,distance:S},l.returnZ,i.spatialReference)}async _getBounds(e,t,i){let r=(0,h.hZ)((0,h.vt)(),h.qv);return await this.featureStore.forEachBounds(e,e=>(0,h.RF)(r,e)),q(r,t,i,this.spatialReference,this.hasZ)}_getFullExtent(){return this._fullExtentPromise||="getFullExtent"in this.featureStore&&this.featureStore.getFullExtent?Promise.resolve(this.featureStore.getFullExtent(this.spatialReference)):this._getAllFeatures().then(e=>this._getBounds(e,this.spatialReference,this.spatialReference)),this._fullExtentPromise}async _getAllFeaturesQueryEngineResult(e){return new E.G(await this._getAllFeatures(),e,this)}async _getAllFeatures(){if(null==this._allFeaturesPromise){let e=[];this._allFeaturesPromise=(async()=>await this.featureStore.forEach(t=>e.push(t)))().then(()=>(0,n.z)(e))}let e=this._allFeaturesPromise,t=await e;return e===this._allFeaturesPromise?t.slice():this._getAllFeatures()}async*_executeQuery(e,t){e=(0,a.o8)(e),e=await(0,A.GC)(e,this.definitionExpression,this.spatialReference),yield,e=await O(e,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference}),yield,e={...e,...t};let i=yield*this._executeSceneFilterQuery(e);yield;let r=yield*this._executeGeometryQuery(e,i);return yield,this._executeAggregateIdsQuery(r),yield,this._executeObjectIdsQuery(r),yield,this._executeTimeQuery(r),yield,this._executeAttributesQuery(r),r}async*_executeSceneFilterQuery(e){if(null==e.sceneFilter)return null;let{outSR:t,returnGeometry:i,returnCentroid:r}=e,n=this.featureStore.featureSpatialReference,s=e.sceneFilter.geometry,a=null==n||(0,x.aI)(n,s.spatialReference)?s:(0,F.Cv)(s,n);if(!a)return null;let l=i||r,o=(0,x.fn)(t)&&!(0,x.aI)(this.spatialReference,t)&&l?async e=>this._project(e,t):e=>e;yield;let u=this.featureAdapter,d=await this._searchFeatures(L(a));if(yield,"disjoint"===e.sceneFilter.spatialRelationship){if(!d.length)return null;let t=new Set;for(let e of d)t.add(u.getObjectId(e));let i=await this._getAllFeatures();yield;let r=await(0,M.xt)("esriSpatialRelDisjoint",a,this.geometryType);yield;let n=yield*this._runSpatialFilter(i,e=>!t.has(u.getObjectId(e))||r(u.getGeometry(e)));return yield,await o(new E.G(n,e,this))}if(!d.length)return new E.G([],e,this);if(this._canExecuteSinglePass(a,e))return await o(new E.G(d,e,this));let c=await(0,M.xt)("esriSpatialRelContains",a,this.geometryType);yield;let h=yield*this._runSpatialFilter(d,e=>c(u.getGeometry(e)));return yield,await o(new E.G(h,e,this))}async*_executeGeometryQuery(e,t){if(null!=t&&0===t.items.length)return t;let{geometry:i,outSR:n,returnGeometry:s,returnCentroid:a}=e,l=t?null:this._getCacheKey(e),o=l?this._cache.get(l):null;if(o)return new E.G(o,e,this);let u=(0,x.fn)(n)&&!(0,x.aI)(this.spatialReference,n),d=s||a,c=async e=>(u&&d&&await this._project(e,n),l&&this._cache.put(l,e.items),e),h=this.featureStore.featureSpatialReference,f=!i||null==h||(0,x.aI)(h,i.spatialReference)?i:(0,F.Cv)(i,h);if(!f)return await c(t??await this._getAllFeaturesQueryEngineResult(e));yield;let p=this.featureAdapter,m=await this._searchFeatures(L(i));yield;let y=e.spatialRel??"esriSpatialRelIntersects";if("esriSpatialRelDisjoint"===y){if(!m.length)return await c(t??await this._getAllFeaturesQueryEngineResult(e));let i,r=new Set;for(let e of m)r.add(p.getObjectId(e));null==t?(yield,i=await this._getAllFeatures(),yield):i=t.items;let n=await(0,M.xt)(y,f,this.geometryType);yield;let s=yield*this._runSpatialFilter(i,e=>!r.has(p.getObjectId(e))||n(p.getGeometry(e)));return yield,await c(new E.G(s,e,this))}if(null!=t){let e=new r.vW;m=m.filter(i=>(0,r.qh)(t.items,i,t.items.length,e)>=0)}if(!m.length){let t=new E.G([],e,this);return l&&this._cache.put(l,t.items),t}if(this._canExecuteSinglePass(f,e))return await c(new E.G(m,e,this));let g=await(0,M.xt)(y,f,this.geometryType);yield;let _=yield*this._runSpatialFilter(m,e=>g(p.getGeometry(e)));return yield,await c(new E.G(_,e,this))}_executeAggregateIdsQuery(e){if(0===e.items.length||!e.query.aggregateIds?.length||null==this.aggregateAdapter)return;let t=new Set;for(let i of e.query.aggregateIds)this.aggregateAdapter.getFeatureObjectIds(i).forEach(e=>t.add(e));let i=this.featureAdapter.getObjectId;e.items=e.items.filter(e=>t.has(i(e)))}_executeObjectIdsQuery(e){if(0===e.items.length||!e.query.objectIds?.length)return;let t=new Set(e.query.objectIds),i=this.featureAdapter.getObjectId;e.items=e.items.filter(e=>t.has(i(e)))}_executeTimeQuery(e){if(0===e.items.length)return;let t=(0,P.I)(this.timeInfo,e.query.timeExtent,this.featureAdapter);null!=t&&(e.items=e.items.filter(t))}_executeAttributesQuery(e){if(0===e.items.length)return;let t=(0,v.j4)(e.query.where,this.fieldsIndex);if(t){if(!t.isStandardized)throw TypeError("Where clause is not standardized");e.items=e.items.filter(e=>t.testFeature(e,this.featureAdapter))}}async*_executeGeometryQueryForSnapping(e){let{query:t}=e,{spatialRel:i}=t;if(!e?.items?.length||!t.geometry||!i)return;let r=await(0,M.xt)(i,t.geometry,this.geometryType);yield;let n=this.featureAdapter;e.items=yield*this._runSpatialFilter(e.items,e=>r(n.getGeometry(e)))}*_runSpatialFilter(e,t){if(!t)return e;if(null==this._frameTask)return e.filter(e=>t(e));let i=yield,r=[];for(let n of e)t(n)&&r.push(n),i.madeProgress(),i.done&&(i=yield);return r}_filterLatest(e){let{trackIdField:t,startTimeField:i,endTimeField:r}=this.timeInfo,n=r||i,s=new Map,a=this.featureAdapter.getAttribute;for(let i of e.items){let e=a(i,t),r=a(i,n),l=s.get(e);(!l||r>a(l,n))&&s.set(e,i)}e.items=Array.from(s.values())}_getCacheKey(e){let{geometry:t,spatialRel:i,returnGeometry:r,returnCentroid:n,outSR:s,resultType:a,cacheHint:l}=e;if("tile"!==a&&!l)return null;let o=r||n,u=(0,x.fn)(s)&&!(0,x.aI)(this.spatialReference,s);return JSON.stringify(u&&o?[t,i,s]:[t,i])}_canExecuteSinglePass(e,t){let{spatialRel:i}=t;return(0,M.tC)(e)&&("esriSpatialRelEnvelopeIntersects"===i||"esriGeometryPoint"===this.geometryType&&("esriSpatialRelIntersects"===i||"esriSpatialRelContains"===i))}async _project(e,t){if(!t||(0,x.aI)(this.spatialReference,t))return e;let i=this.featureAdapter,r=(0,c.isLoaded)()?await this._getFullExtent():void 0,s=await(0,F.lK)(e.items.map(e=>(0,T.p)(this.geometryType,i.getGeometry(e))),this.spatialReference,t,{areaOfInterestExtent:r});return e.items=(0,n.z)(s.map((t,r)=>i.cloneWithGeometry(e.items[r],(0,_.Ux)(t,this.hasZ,this.hasM),this.geometryType))),e}async _searchFeatures(e){let t=new Set;await Promise.all(e.map(e=>this.featureStore.forEachInBounds(e,e=>t.add(e))));let i=Array.from(t.values());return t.clear(),i}async*_executeQueryForStatistics(e,t){e=(0,a.o8)(e);try{e=await(0,A.GC)(e,this.definitionExpression,this.spatialReference),yield,e=await async function(e,t,{fieldsIndex:i,geometryType:r,spatialReference:n,availableFields:a}){if(null!=e.geometryPrecision||e.multipatchOption||e.pixelSize||e.relationParam||e.text||e.outStatistics||e.groupByFieldsForStatistics||e.having||e.orderByFields)throw new s.A(C,"Unsupported query options",{query:e});return N(i,a,e),Promise.all([z(i,a,t,e),(0,M.c0)(e,r,n),(0,F.Nk)(n,e.outSR)]).then(()=>e)}(e,t,{availableFields:this.availableFields,fieldsIndex:this.fieldsIndex,geometryType:this.geometryType,spatialReference:this.spatialReference}),yield;let i=yield*this._executeSceneFilterQuery(e);yield;let r=yield*this._executeGeometryQuery(e,i);return yield,this._executeAggregateIdsQuery(r),yield,this._executeObjectIdsQuery(r),yield,this._executeTimeQuery(r),yield,this._executeAttributesQuery(r),yield,r}catch(t){if(t!==A.v8)throw t;return new E.G([],e,this)}}get test(){}}function L(e){if((0,M.tC)(e)){if((0,m.ZC)(e))return[(0,f.fA)(Math.min(e.xmin,e.xmax),Math.min(e.ymin,e.ymax),Math.max(e.xmin,e.xmax),Math.max(e.ymin,e.ymax))];if((0,m.Bi)(e))return e.rings.map(e=>(0,f.fA)(Math.min(e[0][0],e[2][0]),Math.min(e[0][1],e[2][1]),Math.max(e[0][0],e[2][0]),Math.max(e[0][1],e[2][1])))}return[(0,p.Rg)((0,f.vt)(),e)]}function q(e,t,i,r,n){let s={xmin:e[0],ymin:e[1],xmax:e[3],ymax:e[4],spatialReference:r};n&&isFinite(e[2])&&isFinite(e[5])&&(s.zmin=e[2],s.zmax=e[5],s.hasZ=!0);let a=(0,F.Cv)(s,t,i);if(a.spatialReference=i,a.xmax-a.xmin===0){let e=(0,u.GA)(a.spatialReference);a.xmin-=e,a.xmax+=e}if(a.ymax-a.ymin===0){let e=(0,u.GA)(a.spatialReference);a.ymin-=e,a.ymax+=e}if(n&&null!=a.zmin&&null!=a.zmax&&a.zmax-a.zmin===0){let e=(0,u.GA)(a.spatialReference);a.zmin-=e,a.zmax+=e}return a}},99352(e,t,i){i.d(t,["F",0,{supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!0,supportedSpatialAggregationStatistics:{envelope:!0,centroid:!0,convexHull:!0},supportsStatisticsAggregatedIds:!0,supportsCentroid:!0,supportsCentroidOnDegeneratedQuantizedGeometry:!0,supportsCacheHint:!0,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDistance:!0,supportsOutDistance:!1,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsPaginationOnAggregatedQueries:!1,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!0,supportsReturnMesh:!1,supportsReturnExceededLimitGeometries:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsFormatPBFWithCurves:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,maxUniqueIDCount:void 0,relativeTimeBinWindow:0,standardMaxRecordCount:void 0,standardMaxRecordCountNoGeometry:void 0,tileMaxRecordCount:void 0,supportsTrueCurve:!1},"P",0,{supportsDate:!0,supportsFixedInterval:!0,supportsAutoInterval:!0,supportsFixedBoundaries:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!0,supportedStatistics:{count:!0,sum:!0,avg:!0,var:!0,stddev:!0,min:!0,max:!0,percentileContinuous:!0,percentileDiscrete:!0,envelope:!0,centroid:!0,convexHull:!0},supportedNormalizationTypes:{field:!0,log:!0,naturalLog:!0,percentOfTotal:!0,squareRoot:!0}}])},8384(e,t,i){i.d(t,{G:()=>O});var r=i(4576),n=i(18370),s=i(4718),a=i(16930),l=i(12359),o=i(90634),u=i(62577),d=i(21325),c=i(46329),h=i(52006),f=i(88930),p=i(29441),m=i(51441),y=i(30524),g=i(1873),x=i(43668);class _{constructor(e,t,i){this._fieldDataCache=new Map,this._returnDistinctMap=new Map,this.returnDistinctValues=e.returnDistinctValues??!1,this.fieldsIndex=i,this.featureAdapter=t;let r=e.outFields;if(r&&!r.includes("*")){this.outFields=r;let e=0;for(let t of r){let r=(0,p.Wq)(t),n=this.fieldsIndex.get(r),s=n?null:(0,p.j4)(r,i),a=n?n.name:(0,p.SY)(t)||"FIELD_EXP_"+e++;this._fieldDataCache.set(t,{alias:a,clause:s})}}}countDistinctValues(e){return this.returnDistinctValues?(e.forEach(e=>this.getAttributes(e)),this._returnDistinctMap.size):e.length}getAttributes(e){let t=this._processAttributesForOutFields(e);return this._processAttributesForDistinctValues(t)}getFieldValue(e,t,i){if(i)return this.featureAdapter.getAttribute(e,i.name);let r=t,n=null;return this._fieldDataCache.has(r)?n=this._fieldDataCache.get(r)?.clause:i||(n=(0,p.j4)(t,this.fieldsIndex),this._fieldDataCache.set(r,{alias:r,clause:n})),n?.calculateValue(e,this.featureAdapter)}getDataValues(e,t,i=!0){let r=t.normalizationType,n=t.normalizationTotal,s=this.fieldsIndex.get(t.field),a=(0,y.zD)(s)||(0,y.Ah)(s),l=(0,y.OH)(s);return e.map(e=>{let s=t.field&&this.getFieldValue(e,t.field,this.fieldsIndex.get(t.field));if(t.field2?(s=`${(0,g.gJ)(s)}${t.fieldDelimiter}${(0,g.gJ)(this.getFieldValue(e,t.field2,this.fieldsIndex.get(t.field2)))}`,t.field3&&(s=`${s}${t.fieldDelimiter}${(0,g.gJ)(this.getFieldValue(e,t.field3,this.fieldsIndex.get(t.field3)))}`)):"string"==typeof s&&i&&(a?s=s?new Date(s).getTime():null:l&&(s=s?(0,f.rb)(s):null)),r&&Number.isFinite(s)){let i="field"===r&&t.normalizationField?this.getFieldValue(e,t.normalizationField,this.fieldsIndex.get(t.normalizationField)):null;s=(0,g.zS)(s,r,i,n)}return s})}async getExpressionValues(e,t,i,r,n){let{arcadeUtils:s}=await(0,x.l)(),a=s.hasGeometryOperations(t);a&&await s.enableGeometryOperations();let l=s.createFunction(t),o=s.getViewInfo(i),u={fields:this.fieldsIndex.fields};return e.map(e=>{let t={attributes:this.featureAdapter.getAttributes(e),layer:u,geometry:a?{...(0,m.p)(r.geometryType,this.featureAdapter.getGeometry(e)),spatialReference:i.spatialReference}:null},d=s.createExecContext(t,o,n);return s.executeFunction(l,d)})}validateItem(e,t){return this._fieldDataCache.has(t)||this._fieldDataCache.set(t,{alias:t,clause:(0,p.j4)(t,this.fieldsIndex)}),this._fieldDataCache.get(t)?.clause?.testFeature(e,this.featureAdapter)??!1}validateItems(e,t){return this._fieldDataCache.has(t)||this._fieldDataCache.set(t,{alias:t,clause:(0,p.j4)(t,this.fieldsIndex)}),this._fieldDataCache.get(t)?.clause?.testSet(e,this.featureAdapter)??!1}_processAttributesForOutFields(e){let t=this.outFields;if(!t?.length)return this.featureAdapter.getAttributes(e);let i={};for(let r of t){let{alias:t,clause:n}=this._fieldDataCache.get(r);i[t]=n?n.calculateValue(e,this.featureAdapter):this.featureAdapter.getAttribute(e,t)}return i}_processAttributesForDistinctValues(e){if(null==e||!this.returnDistinctValues)return e;let t=this.outFields,i=[];if(t)for(let r of t){let{alias:t}=this._fieldDataCache.get(r);i.push(e[t])}else for(let t in e)i.push(e[t]);let r=`${(t||["*"]).join(",")}=${i.join(",")}`,n=this._returnDistinctMap.get(r)||0;return this._returnDistinctMap.set(r,++n),n>1?null:e}}var v=i(31464),T=i(58727);class F{constructor(e,t,i){this.objectId=e,this.target=t,this.distance=i}}class S extends F{constructor(e,t,i){super(e,t,i),this.type="vertex"}}class I extends F{constructor(e,t,i,r,n,s=!1,a=null){super(e,t,i),this.start=r,this.end=n,this.draped=s,this.curve=a,this.type="edge"}}var w=i(5834),R=i(59977),E=i(57231),A=i(11440),M=i(60909),b=(i(98623),i(34747));const C=(0,n.z)(()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(6491)]).then(()=>i(55666)));class O{constructor(e,t,i){this.items=e,this.query=t,this.geometryType=i.geometryType,this.hasZ=!!t.returnZ&&i.hasZ,this.hasM=!!t.returnM&&i.hasM,this.fieldsIndex=i.fieldsIndex,this.spatialReference=i.spatialReference,this.featureAdapter=i.featureAdapter,this.featureIdInfo=i.featureIdInfo}get size(){return this.items.length}createQueryResponseForCount(){let e=new _(this.query,this.featureAdapter,this.fieldsIndex);if(!this.query.outStatistics)return e.countDistinctValues(this.items);let{groupByFieldsForStatistics:t,having:i,outStatistics:r}=this.query;if(!t?.length)return 1;let n=new Map,s=new Map,a=new Set;for(let l of r){let{statisticType:r}=l,o="exceedslimit"===r?void 0:l.onStatisticField;if(!s.has(o)){let i=[];for(let r of t){let t=this._getAttributeValues(e,r,this.items,n);i.push(t)}s.set(o,this._calculateUniqueValues(i,this.items,e.returnDistinctValues))}let u=s.get(o);for(let t in u){let{data:r,items:n}=u[t],s=r.join(",");(!i||e.validateItems(n,i))&&a.add(s)}}return a.size}async createQueryResponse(){let e;if(e=this.query.outStatistics?this.query.outStatistics.some(e=>"exceedslimit"===e.statisticType)?this._createExceedsLimitQueryResponse():await this._createStatisticsQueryResponse(this.query,this.items):this._createFeatureQueryResponse(this.query),this.query.returnQueryGeometry){let t=this.query.geometry;e.queryGeometry={spatialReference:this.query.outSR,...(0,d.fn)(this.query.outSR)&&!(0,d.aI)(t.spatialReference,this.query.outSR)?(0,v.Cv)(t,t.spatialReference,this.query.outSR):t}}return e}createSnappingResponse(e,t,i){let r=this.featureAdapter,{point:n}=e,s="number"==typeof e.distance?e.distance:e.distance.x,a="number"==typeof e.distance?e.distance:e.distance.y;function l(e,t){let i=(e-n.x)/s,r=(t-n.y)/a;return i*i+r*r}let o={candidates:[]},u="esriGeometryPolygon"===this.geometryType,d="esriGeometryPolyline"===this.geometryType||"esriGeometryPoint"===this.geometryType,f=this._getPointCreator(t,this.spatialReference,i),p=new z(null,0),m=new z(null,0),y={x:0,y:0,z:0};for(let e of this.items){let t=r.getObjectId(e),i=r.getGeometryWithCurves?.(e);if(null!=i){x(i,t);continue}let n=r.getGeometry(e);null!=n&&g(n,t)}return o.candidates.sort((e,t)=>e.distance-t.distance),o;function g(t,i){let{coords:r,stride:s}=t,a=t.isPoint?P:t.lengths;if(p.coords=r,m.coords=r,e.returnEdge){let e=0;for(let t=0;t<a.length;t++){let r=a[t],d=e;for(let t=0;t<r;t++,e+=s){if(!u&&t===r-1||(p.coordsIndex=e,m.coordsIndex=t===r-1?d:e+s,!V(y,n,p,m)))continue;let a=l(y.x,y.y);a<=1&&o.candidates.push(new I(i,f(y),Math.sqrt(a),f(p),f(m)))}}}if("all"===e.vertexMode){let e=0;for(let t=0;t<a.length;t++){let r=a[t],n=e,d=m;d.coordsIndex=n;for(let t=0;t<r;t++,e+=s){if(p.coordsIndex=e,u&&t===r-1&&p.x===d.x&&p.y===d.y)continue;let n=l(p.x,p.y);n<=1&&o.candidates.push(new S(i,f(p),Math.sqrt(n)))}}}else if(d&&"ends"===e.vertexMode){let e=0,t=[];for(let i=0;i<a.length;i++){t.push(e);let r=a[i];e+=r*s,r>1&&t.push(e-s)}for(let e of t){p.coordsIndex=e;let t=l(p.x,p.y);t<=1&&o.candidates.push(new S(i,f(p),Math.sqrt(t)))}}}function x(t,i){let{candidates:r}=o,s={x:0,y:0,z:0};if(e.returnEdge){let e=[n.x,n.y],a=new z(e,0),o=new z(e,0);for(let{segments:n}of t.parts)for(let{start:t,curve:u}of n){let{curvePoint:n}=(0,c.y)(t,u,e),d=l(...n);if(d>1)continue;[s.x,s.y]=n,a.coords=t,o.coords=(0,h.yP)(u);let p=(0,h.Xq)(u)?null:(0,h.tk)(u);r.push(new I(i,f(s),Math.sqrt(d),f(a),f(o),!1,p))}}function a(e){s.x=t.vertexXY[2*e],s.y=t.vertexXY[2*e+1];let n=l(s.x,s.y);n>1||(s.z=t.vertexZ?.[e]??0,r.push(new S(i,f(s),Math.sqrt(n))))}if("all"===e.vertexMode){let{vertexCount:e}=t;for(let t=0;t<e;++t)a(t)}else if("ends"===e.vertexMode)switch(t.type){case"point":a(0);break;case"polyline":for(let e=0;e<t.partCount;++e){let i=t.partOffsets[e],r=t.partOffsets[e+1]-1;a(i),r!==i&&a(r)}}}}_getPointCreator(e,t,i){let r=null==i||(0,d.aI)(t,i)?e=>e:e=>(0,v.Cv)(e,t,i),{hasZ:n}=this;return n&&e?({x:e,y:t,z:i})=>r({x:e,y:t,z:i}):({x:e,y:t})=>r({x:e,y:t,z:0})}async createSummaryStatisticsResponse(e){let{field:t,valueExpression:i,normalizationField:r,normalizationType:n,normalizationTotal:s,minValue:a,maxValue:l,scale:o,timeZone:u,outStatisticTypes:d}=e,c=this.fieldsIndex.get(t),h=(0,y.vE)(c)||(0,y.zD)(c)||(0,y.Ah)(c),f=await this._getDataValues({field:t,valueExpression:i,normalizationField:r,normalizationType:n,normalizationTotal:s,scale:o,timeZone:u},this.items),p=(0,g.Vb)({normalizationType:n,normalizationField:r,minValue:a,maxValue:l}),m={value:.5,fieldType:c?.type},x=(0,y.yM)(c)?(0,g.z9)({values:f,supportsNullCount:p,percentileParams:m,outStatisticTypes:d}):(0,g.G_)({values:f,minValue:a,maxValue:l,useSampleStdDev:!n,supportsNullCount:p,percentileParams:m,outStatisticTypes:d});return(0,g.oZ)(x,d,h)}async createUniqueValuesResponse(e){let{field:t,valueExpression:i,domains:r,returnAllCodedValues:n,scale:s,timeZone:a}=e,l=await this._getDataValues({field:t,field2:e.field2,field3:e.field3,fieldDelimiter:e.fieldDelimiter,valueExpression:i,scale:s,timeZone:a},this.items,!1),o=(0,g.b3)(l);return(0,g.lv)(o,r,n,e.fieldDelimiter)}async createClassBreaksResponse(e){let{field:t,valueExpression:i,normalizationField:r,normalizationType:n,normalizationTotal:s,classificationMethod:a,standardDeviationInterval:l,minValue:o,maxValue:u,numClasses:d,scale:c,timeZone:h}=e,f=await this._getDataValues({field:t,valueExpression:i,normalizationField:r,normalizationType:n,normalizationTotal:s,scale:c,timeZone:h},this.items),p=(0,g.Rw)(f,{field:t,normalizationField:r,normalizationType:n,normalizationTotal:s,classificationMethod:a,standardDeviationInterval:l,minValue:o,maxValue:u,numClasses:d});return(0,g.jM)(p,a)}async createHistogramResponse(e){let{field:t,valueExpression:i,normalizationField:r,normalizationType:n,normalizationTotal:s,classificationMethod:a,standardDeviationInterval:l,minValue:o,maxValue:u,numBins:d,scale:c,timeZone:h}=e,f=await this._getDataValues({field:t,valueExpression:i,normalizationField:r,normalizationType:n,normalizationTotal:s,scale:c,timeZone:h},this.items);return(0,g.$y)(f,{field:t,normalizationField:r,normalizationType:n,normalizationTotal:s,classificationMethod:a,standardDeviationInterval:l,minValue:o,maxValue:u,numBins:d})}_sortFeatures(e,t,i){if(e.length>1&&t?.length)for(let r of t.slice().reverse()){let{compare:t,fieldOrExpression:n,fieldInfo:s}=G(r,this.fieldsIndex);e.sort((e,r)=>t(i(e,n,s),i(r,n,s)))}}_topNFeatures(e,t,i,n){if(e.length>1&&t?.length){let s=t.map(e=>{let{compare:t,fieldOrExpression:i,fieldInfo:r}=G(e,this.fieldsIndex);return(e,s)=>t(n(e,i,r),n(s,i,r))}).reduceRight((e,t)=>(i,r)=>{let n=t(i,r);return 0===n||Number.isNaN(n)?e(i,r):n}),a=[];for(let t of e)(0,r.HX)(a,t,i,s);return a}return e.slice(0,i)}_createFeatureQueryResponse(e){let{items:t,geometryType:i,hasM:r,hasZ:n,featureIdInfo:s,spatialReference:a}=this,{outFields:l,outSR:o,quantizationParameters:d,resultRecordCount:c,resultOffset:h,returnZ:f,returnM:p}=e,m=null!=c&&t.length>(h||0)+c,y=l&&(l.includes("*")?[...this.fieldsIndex.fields]:l.map(e=>this.fieldsIndex.get(e)));return{exceededTransferLimit:m,features:this._createFeatures(e,t),fields:y,geometryType:i,hasM:r&&p,hasZ:n&&f,objectIdFieldName:"object-id"===s.type?s.fieldName:null,spatialReference:o||a,transform:d&&(0,u.VV)(d)||null}}_createFeatures(e,t){let i,r=new _(e,this.featureAdapter,this.fieldsIndex),{hasM:n,hasZ:s}=this,{orderByFields:a,quantizationParameters:l,returnGeometry:o,returnCentroid:d,maxAllowableOffset:c,resultOffset:h,resultRecordCount:f,returnZ:p=!1,returnM:y=!1}=e,g=s&&p,x=n&&y,v=h||0,T=null==f?null:v+f;null!=T&&T<=5e3&&T<t.length?i=this._topNFeatures(t,a,T,(e,t,i)=>r.getFieldValue(e,t,i)):(i=[...t],this._sortFeatures(i,a,(e,t,i)=>r.getFieldValue(e,t,i))),(v>0||null!=T)&&(i=i.slice(v,T??void 0));let F=[],S=0;if(this.geometryType&&(o||d)){let e=(0,u.VV)(l)??void 0,t="esriGeometryPolygon"===this.geometryType||"esriGeometryPolyline"===this.geometryType;if(o&&!d)for(let n of i){let i=this.featureAdapter.getGeometry(n),s=this._addFeatureJSONMetadata(n,{attributes:r.getAttributes(n),geometry:(0,m.p)(this.geometryType,i,c,e,g,x)});t&&i&&!s.geometry&&(s.centroid=(0,m.L)(this,this.featureAdapter.getCentroid(n,this),e)),F[S++]=s}else if(!o&&d)for(let t of i)F[S++]=this._addFeatureJSONMetadata(t,{attributes:r.getAttributes(t),centroid:(0,m.L)(this,this.featureAdapter.getCentroid(t,this),e)});else for(let t of i)F[S++]=this._addFeatureJSONMetadata(t,{attributes:r.getAttributes(t),centroid:(0,m.L)(this,this.featureAdapter.getCentroid(t,this),e),geometry:(0,m.p)(this.geometryType,this.featureAdapter.getGeometry(t),c,e,g,x)})}else for(let e of i){let t=r.getAttributes(e);t&&(F[S++]=this._addFeatureJSONMetadata(e,{attributes:t}))}return F}_addFeatureJSONMetadata(e,t){let i=this.featureAdapter.getMetadata?.(e);return void 0!==i&&(t.metadata=i),t}_createExceedsLimitQueryResponse(){let e=!1,t=1/0,i=1/0,r=1/0;for(let e of this.query.outStatistics??[])if("exceedslimit"===e.statisticType){t=null==e.maxPointCount?1/0:e.maxPointCount,i=null==e.maxRecordCount?1/0:e.maxRecordCount,r=null==e.maxVertexCount?1/0:e.maxVertexCount;break}return e="esriGeometryPoint"===this.geometryType?this.items.length>t:this.items.length>i||this.items.reduce((e,t)=>e+(this.featureAdapter.getGeometry(t)?.size??0),0)>r,{fields:[{name:"exceedslimit",type:"esriFieldTypeInteger",alias:"exceedslimit",sqlType:"sqlTypeInteger",domain:null,defaultValue:null}],features:[{attributes:{exceedslimit:Number(e)}}]}}async _createStatisticsQueryResponse(e,t,i={attributes:{}}){let r=[],n=new Map,s=new Map,a=new Map,l=new Map,o=new _(e,this.featureAdapter,this.fieldsIndex),u=e.outStatistics,{groupByFieldsForStatistics:d,having:c,orderByFields:h,resultRecordCount:f}=e,p=d?.length,m=!!p,g=m?d[0]:null,x=m&&!this.fieldsIndex.get(g);for(let h of u??[]){let{outStatisticFieldName:u,statisticType:f}=h,_=h,v="exceedslimit"===f?void 0:h.onStatisticField,T="percentile_disc"===f||"percentile_cont"===f,F="EnvelopeAggregate"===f||"CentroidAggregate"===f||"ConvexHullAggregate"===f,S=m&&1===p&&(v===g||x)&&"count"===f;if(m){if(!a.has(v)){let e=[];for(let i of d){let r=this._getAttributeValues(o,i,t,n);e.push(r)}a.set(v,this._calculateUniqueValues(e,t,!F&&o.returnDistinctValues))}let i=a.get(v);if(!i)continue;let r=Object.keys(i);for(let s of r){let{count:r,data:a,items:h,itemPositions:f}=i[s],p=a.join(",");if(!c||o.validateItems(h,c)){let i=l.get(p)||{attributes:{}};if(e.returnAggIds&&(i.aggregateIds=h.map(e=>this.featureAdapter.getObjectId(e)).filter(e=>null!=e)),F){i.aggregateGeometries||={};let{aggregateGeometries:e,outStatisticFieldName:t}=await this._getAggregateGeometry(_,h);i.aggregateGeometries[t]=e}else{let e=null;if(S)e=r;else{let i=this._getAttributeValues(o,v,t,n),r=f.map(e=>i[e]);e=T&&"statisticParameters"in _?this._getPercentileValue(_,r):this._getStatisticValue(_,r,null,o.returnDistinctValues)}i.attributes[u]=e}let s=0;d.forEach((e,t)=>i.attributes[this.fieldsIndex.get(e)?e:"EXPR_"+ ++s]=a[t]),l.set(p,i)}}}else if(F){i.aggregateGeometries||={};let{aggregateGeometries:e,outStatisticFieldName:r}=await this._getAggregateGeometry(_,t);i.aggregateGeometries[r]=e}else{let e=this._getAttributeValues(o,v,t,n);i.attributes[u]=T&&"statisticParameters"in _?this._getPercentileValue(_,e):this._getStatisticValue(_,e,s,o.returnDistinctValues)}let I="min"!==f&&"max"!==f||!(0,y.yM)(this.fieldsIndex.get(v))&&!this._isAnyDateField(v)?null:this.fieldsIndex.get(v)?.type;r.push({name:u,alias:u,type:I||"esriFieldTypeDouble"})}let v=m?Array.from(l.values()):[i];return this._sortFeatures(v,h,(e,t)=>e.attributes[t]),f&&(v.length=Math.min(f,v.length)),{fields:r,features:v}}_isAnyDateField(e){let t=this.fieldsIndex.get(e);return(0,y.vE)(t)||(0,y.zD)(t)||(0,y.Ah)(t)||(0,y.OH)(t)}async _getAggregateGeometry(e,t){let{statisticType:i,outStatisticFieldName:r}=e,{featureAdapter:n,spatialReference:s,geometryType:a}=this,u=t.map(e=>(0,m.p)(a,n.getGeometry(e))),d={aggregateGeometries:null,outStatisticFieldName:null},{convexHullExecuteMany:c}=await C.getImportPromise(),[h]=c(u,{merge:!0});if(h&&h.rings[0].length<=3&&(h=null),"EnvelopeAggregate"===i)d.aggregateGeometries={...h?(0,o.v)(h):N(u),spatialReference:s},d.outStatisticFieldName=r||"extent";else if("CentroidAggregate"===i){let[e,t]=h?(0,l.l8)(h):(0,l.Z4)(N(u));d.aggregateGeometries={x:e,y:t,spatialReference:s},d.outStatisticFieldName=r||"centroid"}else"ConvexHullAggregate"===i&&(d.aggregateGeometries=h&&{...h,spatialReference:s},d.outStatisticFieldName=r||"convexHull");return d}_getStatisticValue(e,t,i,r){let{onStatisticField:n,statisticType:s}=e,a=null;return a=i?.has(n)?i.get(n):(0,y.yM)(this.fieldsIndex.get(n))||this._isAnyDateField(n)?(0,g.z9)({values:t,returnDistinct:r}):(0,g.G_)({values:r?[...new Set(t)]:t,minValue:null,maxValue:null,useSampleStdDev:!0}),i&&i.set(n,a),a["var"===s?"variance":s]}_getPercentileValue(e,t){let{onStatisticField:i,statisticParameters:r,statisticType:n}=e,{value:s,orderBy:a}=r,l={value:s,orderBy:a,fieldType:this.fieldsIndex.get(i)?.type,isDiscrete:"percentile_disc"===n};return(0,g.qg)(t,l)}_getAttributeValues(e,t,i,r){if(r.has(t))return r.get(t);let n=this.fieldsIndex.get(t),s=i.map(i=>e.getFieldValue(i,t,n));return r.set(t,s),s}_calculateUniqueValues(e,t,i){let r={},n=t.length;for(let s=0;s<n;s++){let n=t[s],a=[];for(let t of e)a.push(t[s]);let l=a.join(",");null==r[l]?r[l]={count:1,data:a,items:[n],itemPositions:[s]}:(i||r[l].count++,r[l].items.push(n),r[l].itemPositions.push(s))}return r}async _getDataValues(e,t,i=!0){let r=new _(this.query,this.featureAdapter,this.fieldsIndex),{valueExpression:n,scale:l,timeZone:o}=e,u=a.A.fromJSON(this.query.outSR||this.spatialReference);return n?r.getExpressionValues(t,n,{viewingMode:"map",scale:l,spatialReference:u},{geometryType:this.geometryType,hasZ:this.hasZ,hasM:this.hasM},o):r.getDataValues(t,(0,s.o8)(e),i)}_calculateHistogramBins(e,t,i){if(null==t.min&&null==t.max)return[];let r=t.intervals,n=t.min??0,s=t.max??0,a=r.map(([e,t])=>({minValue:e,maxValue:t,count:0,items:[]}));for(let t=0;t<e.length;t++){let l=e[t],o=i[t];if(null!=l&&l>=n&&l<=s){let e=(0,g.Ak)(r,l);e>-1&&(a[e].count++,a[e].items.push(o))}}return a}async createQueryBinsResponse(e){let t=e.bin?.splitBy;if(!t)return this._createBinsResponse(e);let{value:i,outAlias:r,valueType:n}=t,s=[],a=[{name:r??i,alias:r??i,type:n??"esriFieldTypeString"},{name:"bin",alias:"bin",type:"esriFieldTypeInteger"}],l=new _(e,this.featureAdapter,this.fieldsIndex),o=new Map,u=[...this.items];this._sortFeatures(u,[i],(e,t,i)=>l.getFieldValue(e,t,i));let d=this._getAttributeValues(l,i,u,o),c=this._calculateUniqueValues([d],u,l.returnDistinctValues);for(let t in c){let{items:n}=c[t],l=await this._createBinsResponse(e,n);if(s.push(...l.features.map(e=>({...e,attributes:{...e.attributes,[r??i]:t}}))),l.fields)for(let e of l.fields)a.some(t=>t.name===e.name)||a.push(e)}return{fields:a,features:s}}async _createBinsResponse(e,t){let i=e.bin;switch(t??=this.items,i.type){case"autoIntervalBin":return this._createAutoIntervalBinsResponse(w.A.fromJSON(i),e,t);case"dateBin":return this._createDateBinsResponse(R.A.fromJSON(i),e,t);case"fixedBoundariesBin":return this._createFixedBoundariesBinsResponse(A.A.fromJSON(i),e,t);case"fixedIntervalBin":return this._createFixedIntervalBinsResponse(M.A.fromJSON(i),e,t)}}async _createAutoIntervalBinsResponse(e,t,i){let{field:r,normalizationField:n,numBins:s,normalizationType:a,normalizationTotal:l,start:o,end:u}=e,d=await this._getDataValues({field:e.field||e.expression,normalizationField:e.normalizationField,normalizationType:e.normalizationType,normalizationTotal:e.normalizationTotal,timeZone:t.outTimeReference?.ianaTimeZone},i),c=(0,g.sU)(d,{field:r,normalizationField:n,normalizationType:a,normalizationTotal:l,numBins:s,minValue:(0,T.dO)(a?e.normalizationMinValue:o,!1),maxValue:(0,T.dO)(a?e.normalizationMaxValue:u,!1)}),h=this._calculateHistogramBins(d,c,i);return this._createFeaturesFromHistogramBins(h,t)}async _createDateBinsResponse(e,t,i){let{field:r,interval:n,start:s,end:a,snapToData:l,returnFullIntervalBin:o,offset:u,firstDayOfWeek:d}=e,c=n.unit,h=await this._getDataValues({field:r||e.expression,timeZone:t.outTimeReference?.ianaTimeZone},i),f=(0,y.OH)(this.fieldsIndex.get(r)),p=E.g.toJSON(c),m=h.filter(Boolean).sort((e,t)=>e-t),g=null==s?m[0]:(0,T.dO)(s,f),x=null==a?m[m.length-1]:(0,T.dO)(a,f),_=[];if(null!=g&&null!=x){let e={zone:t.outTimeReference?.ianaTimeZone??"UTC"},i={[u?.unit?E.g.toJSON(u.unit):"milliseconds"]:u?.value||0},r=b.c9.fromMillis(g,e).minus(i),s=b.c9.fromMillis(x,e).minus(i),a="number"==typeof d&&d>=1&&d<=7?d:7,c=(e,t)=>{let i=(e.weekday-t+7)%7;return e.minus({days:i}).startOf("day")},h=(e,t)=>c(e,t).plus({days:7});if("last"===l){let e="week"===p?h(s,a):s;for(;e>r;){let t=e.minus({[p]:n.value});if(t<r){_.unshift([o?t.plus(i).toMillis():r.plus(i).toMillis(),e.plus(i).toMillis()]);break}_.unshift([t.plus(i).toMillis(),e.plus(i).toMillis()]),e=t}}else{let e="first"===l?r:"week"===p?c(r,a):r.startOf(p);for(;e<=s;){let t=e.plus({[p]:n.value});if(t>s){_.push([e.plus(i).toMillis(),o?t.plus(i).toMillis():s.plus(i).toMillis()]);break}_.push([e.plus(i).toMillis(),t.plus(i).toMillis()]),e=t}}}let v=this._calculateHistogramBins(h,{intervals:_,min:g,max:x},i);return this._createFeaturesFromHistogramBins(v,t)}async _createFixedBoundariesBinsResponse(e,t,i){let{field:r}=e,n=await this._getDataValues({field:r||e.expression,timeZone:t.outTimeReference?.ianaTimeZone},i),s=(0,y.OH)(this.fieldsIndex.get(r)),a=e.boundaries.map(e=>(0,T.dO)(e,s)).sort((e,t)=>e-t),l=[];for(let e=0;e<a.length-1;e++)l.push([a[e],a[e+1]]);let o={intervals:l,min:a.at(0),max:a.at(-1)},u=this._calculateHistogramBins(n,o,i);return this._createFeaturesFromHistogramBins(u,t)}async _createFixedIntervalBinsResponse(e,t,i){let{field:r,interval:n,normalizationType:s,start:a,end:l}=e,o=await this._getDataValues({field:r||e.expression,normalizationField:e.normalizationField,normalizationType:s,normalizationTotal:e.normalizationTotal,timeZone:t.outTimeReference?.ianaTimeZone},i),u=(0,y.OH)(this.fieldsIndex.get(r)),d=(0,g.sU)(o,{field:r,classificationMethod:"defined-interval",definedInterval:n,minValue:(0,T.dO)(s?e.normalizationMinValue:a,u),maxValue:(0,T.dO)(s?e.normalizationMaxValue:l,u)},!0),c=this._calculateHistogramBins(o,d,i);return this._createFeaturesFromHistogramBins(c,t)}async _createFeaturesFromHistogramBins(e,t){let{upperBoundaryAlias:i,lowerBoundaryAlias:r}=t,n=r||"lowerBoundary",s=i||"upperBoundary",a=[],l=[{name:n,alias:n,type:"esriFieldTypeDouble"},{name:s,alias:s,type:"esriFieldTypeDouble"}],o=t.bin?.stackBy?.value,u=t.bin?.stackBy?.outAlias;o&&l.push({name:"bin",alias:"bin",type:"esriFieldTypeInteger"},{name:u??o,alias:u??o,type:"esriFieldTypeString"});let d=0,c="dateBin"===t.bin.type,h=t.outTimeReference?.ianaTimeZone;for(let i of e){let e,{minValue:r,maxValue:f,items:p}=i,m={attributes:{}};if(m.attributes[n]=c&&h&&null!=r?b.c9.fromMillis(r,{zone:h}).toISO():r,t.bin.hideUpperBound||(m.attributes[s]=c&&h&&null!=f?b.c9.fromMillis(f,{zone:h}).toISO():f),t.returnAggIds&&(m.aggregateIds=p.map(e=>this.featureAdapter.getObjectId(e)).filter(e=>null!=e)),o?(e=await this._createStatisticsQueryResponse({...t,groupByFieldsForStatistics:[o],orderByFields:[o]},p),m.attributes.bin=++d,"flat"===t.bin.jsonStyle?a.push(...e.features.map(({attributes:{EXPR_1:e,...t},...i})=>({...i,attributes:u??e?{...t,[u??e]:e,...m.attributes}:{...t,...m.attributes}}))):(m.stackedAttributes=e.features.map(({attributes:{EXPR_1:e,...t}})=>u??e?{...t,[u??e]:e}:t),a.push(m))):(t.bin?.splitBy&&(m.attributes.bin=++d),e=await this._createStatisticsQueryResponse(t,p,m),a.push(m)),e.fields)for(let t of e.fields)l.some(e=>e.name===t.name)||l.push(t)}return"desc"===t.binOrder&&a.reverse(),{fields:l,features:a}}}function N(e){let t=(0,o.HA)(e[0]);for(let i of e.slice(1))(0,o.JM)(t,(0,o.HA)(i));return t}function V(e,t,i,r){let n=r.x-i.x,s=r.y-i.y,a=t.x-i.x,l=t.y-i.y,o=n*n+s*s;if(0===o)return!1;let u=a*n+l*s,d=Math.min(1,Math.max(0,u/o));return e.x=i.x+n*d,e.y=i.y+s*d,!0}class z{constructor(e,t){this.coords=e,this.coordsIndex=t}get x(){return this.coords[this.coordsIndex]}get y(){return this.coords[this.coordsIndex+1]}get z(){return this.coords[this.coordsIndex+2]}}const P=[1];function G(e,t){let i=e.split(" "),r=i[0],n=t.get(r),s=!!i[1]&&"desc"===i[1].toLowerCase();return{compare:(0,g.FM)(n?.type,s,"case-insensitive"),fieldOrExpression:r,fieldInfo:n}}},29441(e,t,i){i.d(t,{MG:()=>_,SN:()=>f,SY:()=>g,Wq:()=>y,_d:()=>F,eD:()=>p,g9:()=>x,j4:()=>m});var r=i(49186),n=i(44123),s=i(98453);const a=new n.WhereClauseCache(50,500),l="unsupported-query",o=" as ",u=new Set(["esriFieldTypeOID","esriFieldTypeSmallInteger","esriFieldTypeBigInteger","esriFieldTypeInteger","esriFieldTypeSingle","esriFieldTypeDouble","esriFieldTypeLong"]),d=new Set(["esriFieldTypeDate","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]),c=new Set(["esriFieldTypeString","esriFieldTypeGUID","esriFieldTypeGlobalID",...u,...d]);function h(e,t,i={}){let n=m(t,e);if(!n){let i=a.getError(t,e);throw new r.A(l,"invalid SQL expression",{expression:t,error:i})}let s=i.expressionName||"expression";if(i.validateStandardized&&!n.isStandardized)throw new r.A(l,`${s} is not standard`,{expression:t});if(i.validateAggregate&&!n.isAggregate)throw new r.A(l,`${s} does not contain a valid aggregate function`,{expression:t});return n.fieldNames}function f(e,t,i,r){if(!i)return!0;let n="where clause";return _(e,t,h(e,i,{validateStandardized:!0,expressionName:n}),{expressionName:n,query:r}),!0}function p(e,t,i,n,s){if(!i)return!0;let a="having clause";if(_(e,t,h(e,i,{validateAggregate:!0,expressionName:a}),{expressionName:a,query:s}),!m(i,e)?.getExpressions().every(t=>{let{aggregateType:i,field:r}=t,s=e.get(r)?.name;return n.some(t=>{let{onStatisticField:r,statisticType:n}=t;return e.get(r)?.name===s&&n.toLowerCase().trim()===i})}))throw new r.A(l,"expressions in having clause should also exist in outStatistics",{having:i});return!0}function m(e,t){return e?a.get(e,t):null}function y(e){return/\((.*?)\)/.test(e)?e:e.split(o)[0]}function g(e){return e.split(o)[1]}function x(e,t,i){if(!F(t))return[];let r=new Set,n=t=>{if(t&&"*"!==t)for(let i of v(e,t))r.add(i)};for(let e of t)n(e.onStatisticField);for(let e of i??[])n(e);return Array.from(r)}function _(e,t,i,n={}){let s=new Map;if(function(e,t,i,r,n){let s=n.includes("*")?[...i,...n.filter(e=>"*"!==e)]:n;for(let n of s)if(t.get(n))T(e,t,i,r,n);else try{for(let s of v(t,n))T(e,t,i,r,s)}catch(t){e.set(n,{type:"expression-error",expression:n,error:t})}}(s,e,t,n.allowedFieldTypes??c,i),s.size){let e=`${n.expressionName??"expression"} contains invalid or missing fields`;throw new r.A(l,e,{errors:Array.from(s.values()),query:n.query})}}function v(e,t){let i=e.get(t);return i?[i.name]:h(e,y(t),{validateStandardized:!0})}function T(e,t,i,r,n){let a=t.get(n);a?i.has(a.name)?"all"!==r&&!1===r?.has(a.type)&&e.set(n,{type:"invalid-type",fieldName:a.name,fieldType:s.m.fromJSON(a.type),allowedFieldTypes:Array.from(r,e=>s.m.fromJSON(e))}):e.set(n,{type:"missing-field",fieldName:a.name}):e.set(n,{type:"invalid-field",fieldName:n})}function F(e){return null!=e&&e.every(e=>"exceedslimit"!==e.statisticType)}i.d(t,["VW",0,d,"vl",0,u])},54339(e,t,i){function r(e,t){switch(t.type){case"object-id":case"unique-id-simple":return e.attributes[t.fieldName];case"unique-id-composite":{let i=[];for(let r of t.fieldNames)i.push(e.attributes[r]??null);return JSON.stringify(i)}}}function n(e,t){if("uniqueIdFields"in t&&t.uniqueIdFields?.length){if(1===t.uniqueIdFields.length)return e.attributes?.[t.uniqueIdFields[0]];let i=t.uniqueIdFields.map(t=>e.attributes?.[t]);return JSON.stringify(i)}return"objectIdField"in t&&t.objectIdField?e.attributes?.[t.objectIdField]:null}i.d(t,{W:()=>r,r:()=>n})},51441(e,t,i){i.d(t,{L:()=>n,p:()=>s});var r=i(90708);function n(e,t,i,n=e.hasZ,s=e.hasM){if(null==t)return null;let a=e.hasZ&&n,l=e.hasM&&s;if(i){let e=(0,r.Nl)(t,"esriGeometryPoint",i,n,s);return(0,r.DF)(e,a,l)}return(0,r.DF)(t,a,l)}function s(e,t,i,n,s,a){if(null==t)return null;let l="coords"in t?t:t.geometry;if(null==l)return null;let{hasZ:o,hasM:u}=l,d=o&&(s??=o),c=u&&(a??=u);if(i){let t=(0,r.kz)(l,e,i,s,a);return n&&(t=(0,r.Nl)(t,e,n)),(0,r.zv)(t,e,d,c)}if(n){let t=(0,r.Nl)(l,e,n,s,a);return(0,r.zv)(t,e,d,c)}return(0,r.zv)(l,e,d,c)}},31464(e,t,i){i.d(t,{Cv:()=>f,Nk:()=>h,lK:()=>m});var r=i(4576),n=i(99917),s=i(60408),a=i(21325),l=i(28735);const o=[0,0];function u(e,t){let i=(0,a.K8)(e)?l.je:l.tD;if((0,s.fT)(t)){let e={x:0,y:0};return[e.x,e.y]=i(t.x,t.y,o),null!=t.z&&(e.z=t.z),null!=t.m&&(e.m=t.m),e}if((0,s.ZC)(t)){let e={xmin:0,ymin:0,xmax:0,ymax:0};return[e.xmin,e.ymin]=i(t.xmin,t.ymin,o),[e.xmax,e.ymax]=i(t.xmax,t.ymax,o),t.hasZ&&(e.zmin=t.zmin,e.zmax=t.zmax,e.hasZ=!0),t.hasM&&(e.mmin=t.mmin,e.mmax=t.mmax,e.hasM=!0),e}if((0,s.Bi)(t))return{rings:d(t.rings,i),hasM:t.hasM,hasZ:t.hasZ};if((0,s.Rg)(t))return{paths:d(t.paths,i),hasM:t.hasM,hasZ:t.hasZ};if((0,s.U9)(t))return{points:c(t.points,i),hasM:t.hasM,hasZ:t.hasZ};throw Error()}function d(e,t){let i=[];for(let r of e)i.push(c(r,t));return i}function c(e,t){let i=[];for(let r of e){let e=t(r[0],r[1],[0,0]);i.push(e),r.length>2&&e.push(r[2]),r.length>3&&e.push(r[3])}return i}async function h(e,t){if(!e||!t)return;let i=Array.isArray(e)?e.map(e=>null==e.geometry?null:e.geometry.spatialReference).filter(r.Ru):[e];await(0,n.initializeProjection)(i.map(e=>({source:e,dest:t})))}function f(e,t,i,r){if(!e)return null;if(i||(i=t,t=e.spatialReference),!(0,a.fn)(t)||!(0,a.fn)(i)||(0,a.aI)(t,i))return e;if((0,l.y7)(t,i)){let t=u(i,e);return t.spatialReference=i,t}let[s]=(0,n.projectMany)([e],t,i,r);return s}const p=new class{constructor(){this._jobs=[],this._timer=null,this._process=this._process.bind(this)}async push(e,t,i,r){if(!e?.length||!t||!i||(0,a.aI)(t,i))return e;let n={geometries:e,inSpatialReference:t,outSpatialReference:i,options:r,resolve:Promise.withResolvers()};return this._jobs.push(n),this._timer??=setTimeout(this._process,10),n.resolve.promise}_process(){this._timer=null;let e=this._jobs.shift();if(!e)return;let t,{geometries:i,inSpatialReference:r,outSpatialReference:s,resolve:a,options:o}=e,d=i.filter(e=>null!=e);t=(0,l.y7)(r,s)&&null==o?.extendedParams?d.map(e=>u(s,e)):(0,n.projectMany)(d,r,s,o);let c=0,h=i.map(e=>null==e?null:t[c++]);a.resolve(h),this._jobs.length>0&&(this._timer=setTimeout(this._process,10))}};function m(e,t,i,r){return p.push(e,t,i,r)}},58727(e,t,i){i.d(t,{GC:()=>g,T2:()=>x,dO:()=>v,iJ:()=>y});var r=i(49186),n=i(66552),s=i(86211),a=i(39829),l=i(99917),o=i(90634),u=i(60408),d=i(65864),c=i(52039),h=i(21325),f=i(31464);const p=new n.J({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"}),m=Object.freeze({});async function y(e,t,i){let r=e.bin;return r.onField&&=r.onField.trim(),r.onExpression?.value&&(r.onExpression.value=r.onExpression.value.trim()),r.splitBy&&(r.splitBy.value&&(r.splitBy.value=r.splitBy.value.trim()),r.splitBy.outAlias&&(r.splitBy.outAlias=r.splitBy.outAlias.trim())),r.stackBy&&(r.stackBy.value&&(r.stackBy.value=r.stackBy.value.trim()),r.stackBy.outAlias&&(r.stackBy.outAlias=r.stackBy.outAlias.trim())),"normalizationField"in r.parameters&&r.parameters.normalizationField&&(r.parameters.normalizationField=r.parameters.normalizationField.trim()),e.outStatistics?.length||(e.outStatistics=[{statisticType:"count",onStatisticField:"1",outStatisticFieldName:"frequency"}]),g(e,t,i)}async function g(e,t,i){let{outFields:r,orderByFields:n,groupByFieldsForStatistics:s,outStatistics:a}=e;if(r)for(let e=0;e<r.length;e++)r[e]=r[e].trim();if(n)for(let e=0;e<n.length;e++)n[e]=n[e].trim();if(s)for(let e=0;e<s.length;e++)s[e]=s[e].trim();if(a)for(let e=0;e<a.length;e++)a[e].onStatisticField&&(a[e].onStatisticField=a[e].onStatisticField.trim());return e.geometry&&!e.outSR&&(e.outSR=e.geometry.spatialReference),x(e,t,i)}async function x(e,t,i){if(!e)return null;let{where:r}=e;if(e.where=r=r?.trim(),(!r||/^1 *= *1$/.test(r)||t&&t===r)&&(e.where=null),!e.geometry)return e;let n=await _(e);if(e.distance=0,e.units=null,"esriSpatialRelEnvelopeIntersects"===e.spatialRel){let{spatialReference:t}=e.geometry;n=(0,o.HA)(n),n.spatialReference=t}if(!n)return e;await(0,f.Nk)(n.spatialReference,i);let[s]=await(0,c.el)((0,d.rS)(n));if(null==s)throw m;let p=!1;((0,u.ZC)(s)||(0,u.Bi)(s)||(0,u.Rg)(s))&&(p=!(0,h.aI)(s.spatialReference,i)&&!(0,l.canProjectWithoutEngine)(s.spatialReference,i)),p&&(0,u.ZC)(s)&&(s=a.A.fromExtent(s));let y="quantizationParameters"in e&&e.quantizationParameters?.tolerance||"maxAllowableOffset"in e&&e.maxAllowableOffset||0,g=p&&y?{extendedParams:{densificationStep:8*y}}:void 0,x=s.toJSON(),v=(0,f.Cv)(x,x.spatialReference,i,g);if(!v)throw m;return v.spatialReference=i,e.geometry=v,e}async function _(e){let{distance:t,units:n}=e,a=e.geometry;if(!t||"vertexAttributes"in a)return a;let l=a.spatialReference,o=n?p.fromJSON(n):(0,s.Ij)(l),d=l&&((0,h.EA)(l)||(0,h.K8)(l))?a:await(0,f.Nk)(l,h.KK).then(()=>(0,f.Cv)(a,h.KK)),{geodesicBufferExecute:c,geodesicBufferLoad:m}=await i.e(9159).then(()=>i(49159));await m();let y=c(d,t||1,{unit:o})??void 0;if(!y||!(0,u.Bi)(y)||0===y.rings.length)throw new r.A("unsupported-query:invalid-parameters","Invalid parameters for query by distance");return y}function v(e,t){return null==e?null:"string"==typeof e?t?new Date(`1970-01-01T${e}Z`).getTime():new Date(e).getTime():e instanceof Date?e.getTime():e}i.d(t,["VY",0,p,"v8",0,m])},62660(e,t,i){i.d(t,{tC:()=>v,c0:()=>_,xt:()=>x});var r=i(49186),n=i(94078),s=i(12176),a=i(60408),l=i(21325);function o(e,t,i){if(!e)return!1;let{coords:r,lengths:n,stride:s}=e,a=!1,l=0;for(let e of n)a=u(a,r,s,l,e,t,i),l+=e*s;return a}function u(e,t,i,r,n,s,a){let l=e,o=r;for(let e=r,u=r+n*i;e<u;e+=i){o=e+i,o===u&&(o=r);let n=t[e],d=t[e+1],c=t[o],h=t[o+1];(d<a&&h>=a||h<a&&d>=a)&&n+(a-d)/(h-d)*(c-n)<s&&(l=!l)}return l}var d=i(90708),c=i(51441),h=i(31464);const f="unsupported-query",p={esriSpatialRelIntersects:!0,esriSpatialRelContains:!0,esriSpatialRelWithin:!0,esriSpatialRelCrosses:!0,esriSpatialRelDisjoint:!0,esriSpatialRelTouches:!0,esriSpatialRelOverlaps:!0,esriSpatialRelEnvelopeIntersects:!0,esriSpatialRelIndexIntersects:!1,esriSpatialRelRelation:!1},m={esriGeometryPoint:!0,esriGeometryMultiPatch:!1,esriGeometryMultipoint:!0,esriGeometryPolyline:!0,esriGeometryPolygon:!0,esriGeometryEnvelope:!0},y={esriGeometryPoint:!0,esriGeometryMultiPatch:!0,esriGeometryMultipoint:!0,esriGeometryPolyline:!0,esriGeometryPolygon:!0,esriGeometryEnvelope:!1},g={esriSpatialRelIntersects:()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(6033)]).then(()=>i(55284)).then(e=>e.intersectsExecute),esriSpatialRelContains:()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(2990)]).then(()=>i(29127)).then(e=>e.containsExecute),esriSpatialRelCrosses:()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(919)]).then(()=>i(87778)).then(e=>e.crossesExecute),esriSpatialRelDisjoint:()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(9722)]).then(()=>i(3157)).then(e=>e.disjointExecute),esriSpatialRelEnvelopeIntersects:null,esriSpatialRelIndexIntersects:null,esriSpatialRelOverlaps:()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(8740)]).then(()=>i(83371)).then(e=>e.overlapsExecute),esriSpatialRelTouches:()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(8307)]).then(()=>i(67658)).then(e=>e.touchesExecute),esriSpatialRelWithin:()=>Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(100)]).then(()=>i(65487)).then(e=>e.withinExecute),esriSpatialRelRelation:null};async function x(e,t,i){if((0,a.Bi)(t)){if("esriGeometryPoint"===i&&("esriSpatialRelIntersects"===e||"esriSpatialRelContains"===e)){let e=(0,d.Ye)(t,!1,!1);return t=>function(e,t){return o(e,t.coords[0],t.coords[1])}(e,t)}if("esriGeometryMultipoint"===i){let i=(0,d.Ye)(t,!1,!1);if("esriSpatialRelContains"===e)return e=>function(e,t){let{coords:i,lengths:r,stride:n}=t;if(!r)return!1;for(let t=0,s=0;t<r.length;t++,s+=n)if(!o(e,i[s],i[s+1]))return!1;return!0}(i,e)}}if((0,a.ZC)(t)){if("esriGeometryPoint"===i&&("esriSpatialRelIntersects"===e||"esriSpatialRelContains"===e))return e=>(0,n.qz)(t,(0,c.p)(i,e));if("esriGeometryMultipoint"===i&&"esriSpatialRelContains"===e)return e=>(0,n.rL)(t,(0,c.p)(i,e));if("esriSpatialRelIntersects"===e){let e="mesh"===(r=i)?s.xB:(0,s.xK)(r);return r=>e(t,(0,c.p)(i,r))}}var r;"esriSpatialRelEnvelopeIntersects"===e&&(e="esriSpatialRelIntersects");let l=await function(e){let t=g[e];if(null==t)throw Error(`Cannot load unsupported spatial operator: ${e}`);return t()}(e);return e=>l(t,(0,c.p)(i,e))}async function _(e,t,i){let{spatialRel:n,geometry:s}=e;if(s){if(null==(o=n)||!0!==p[o])throw new r.A(f,"Unsupported query spatial relationship",{query:e});if((0,l.fn)(s.spatialReference)&&(0,l.fn)(i)){if(!function(e){return null!=e&&!0===m[(0,a.$B)(e)]}(s))throw new r.A(f,"Unsupported query geometry type",{query:e});if(!function(e){return null!=e&&!0===y[e]}(t))throw new r.A(f,"Unsupported layer geometry type",{query:e});if(e.outSR)return(0,h.Nk)(e.geometry?.spatialReference,e.outSR)}}var o}function v(e){if((0,a.ZC)(e))return!0;if((0,a.Bi)(e)){for(let t of e.rings)if(5!==t.length||t[0][0]!==t[1][0]||t[0][0]!==t[4][0]||t[2][0]!==t[3][0]||t[0][1]!==t[3][1]||t[0][1]!==t[4][1]||t[1][1]!==t[2][1])return!1;return!0}return!1}},86420(e,t,i){i.d(t,{I:()=>s,W:()=>n});var r=i(21818);async function n(e,t){if(!e)return null;let i=t.featureAdapter,{startTimeField:n,endTimeField:s}=e,a=1/0,l=-1/0;if(n&&s)await t.forEach(e=>{let t=i.getAttribute((0,r.z)(e),n),o=i.getAttribute((0,r.z)(e),s);null!=t&&!isNaN(t)&&(a=Math.min(a,t)),null!=o&&!isNaN(o)&&(l=Math.max(l,o))});else{let e=n||s;await t.forEach(t=>{let n=i.getAttribute((0,r.z)(t),e);null!=n&&!isNaN(n)&&(a=Math.min(a,n),l=Math.max(l,n))})}return{start:a,end:l}}function s(e,t,i){if(!t||!e)return null;let{startTimeField:r,endTimeField:n}=e;if(!r&&!n)return null;let{start:s,end:a}=t;if(null===s&&null===a)return null;if(void 0===s&&void 0===a)return()=>!1;let l=i.getAttributeAsTimestamp?.bind(i)??i.getAttribute.bind(i);return r&&n?function(e,t,i,r,n){return null!=r&&null!=n?s=>{let a=e(s,t),l=e(s,i);return(null==a||a<=n)&&(null==l||l>=r)}:null!=r?t=>{let n=e(t,i);return null==n||n>=r}:null!=n?i=>{let r=e(i,t);return null==r||r<=n}:void 0}(l,r,n,s,a):function(e,t,i,r){return null!=i&&null!=r&&i===r?r=>e(r,t)===i:null!=i&&null!=r?n=>{let s=e(n,t);return null!=s&&s>=i&&s<=r}:null!=i?r=>{let n=e(r,t);return null!=n&&n>=i}:null!=r?i=>{let n=e(i,t);return null!=n&&n<=r}:void 0}(l,r||n,s,a)}},90708(e,t,i){i.d(t,{Ap:()=>E,B2:()=>y,DF:()=>F,Di:()=>N,E2:()=>O,IE:()=>m,Nl:()=>q,PR:()=>w,Rk:()=>W,Ux:()=>z,Ye:()=>M,ZF:()=>D,aQ:()=>j,jH:()=>L,jQ:()=>k,kz:()=>Q,oN:()=>V,q3:()=>B,qN:()=>S,zv:()=>P});var r=i(49186),n=i(53966),s=i(97768),a=i(70328),l=i(19419),o=i(60408),u=i(43334),d=i(58512),c=i(92722),h=i(54339);const f=()=>n.A.getLogger("esri.layers.graphics.featureConversionUtils"),p={esriGeometryPoint:0,esriGeometryPolyline:2,esriGeometryPolygon:3,esriGeometryMultipoint:0,esriGeometryMultiPatch:3,esriGeometryEnvelope:0};function m({scale:e,translate:t},i){return Math.round((i-t[0])/e[0])}function y({scale:e,translate:t},i){return Math.round((t[1]-i)/e[1])}function g({scale:e,translate:t},i){return Math.round((i-t[0])/e[0])}function x({scale:e,translate:t},i){return Math.round((i-t[1])/e[1])}function _({scale:e,translate:t},i,r){return i*e[r]+t[r]}function v(e,t,i){return t&&(e.hasZ=!0),i&&(e.hasM=!0),e}function T(e,t,i,r){if(t&&r&&e!==i)return(t,i,r,n)=>{r[n++]=t[i++],r[n++]=t[i++],e?i++:r[n++]=0,r[n++]=t[i++]??0};let n=+!!i+2+ +!!r,s=n-((!e&&i?1:0)+(!t&&r?1:0));return(e,t,i,r)=>{for(let a=0;a<n;++a)i[r++]=a<s?e[t++]??0:0}}function F(e,t,i){if(!e)return null;let{coords:r,hasZ:n,hasM:s}=e,[a,l]=r,o=n?r[2]:0,u=s?r[+!!n+2]:0;return{x:a,y:l,z:t?o:void 0,m:i?u:void 0}}function S(e,t=(0,o.Pv)(e),i=(0,o.W0)(e)){let{x:r,y:n,z:s,m:a}=e,l=[r,n];return t&&l.push(s??0),i&&l.push(a??0),new c.A([],l,t,i)}function I(e,t,i){if(null==e)return null;let{coords:r,stride:n,hasZ:s,hasM:a}=e,l=T(s,a,t,i),o=[];for(let e=0;e<r.length;e+=n){let t=[];l(r,e,t,0),o.push(t)}return v({points:o},t,i)}function w(e,t=(0,o.Pv)(e),i=(0,o.W0)(e)){let{points:r,hasZ:n,hasM:s}=e,a=new c.A([r.length],[],t,i),{coords:l,stride:u}=a,d=0,h=T(n??!1,s??!1,t,i);for(let e of r)h(e,0,l,d),d+=u;return a}function R(e,t,i){if(!e)return null;let{coords:r,lengths:n,stride:s,hasZ:a,hasM:l}=e,o=0,u=T(a,l,t,i),d=[];for(let e of n){let t=[];for(let i=0;i<e;i++){let e=[];u(r,o,e,0),o+=s,t.push(e)}d.push(t)}return v({paths:d},t,i)}function E(e,t=(0,o.Pv)(e),i=(0,o.W0)(e)){let{paths:r,hasZ:n,hasM:s}=e,a=T(n??!1,s??!1,t,i),l=new c.A([],[],t,i),{lengths:u,coords:d,stride:h}=l,f=0;for(let e of r){for(let t of e)a(t,0,d,f),f+=h;u.push(e.length)}return l}function A(e,t,i){if(!e)return null;let{coords:r,lengths:n,stride:s,hasZ:a,hasM:l}=e,o=0,u=T(a,l,t,i),d=[];for(let e of n){let t=[];for(let i=0;i<e;i++){let e=[];u(r,o,e,0),o+=s,t.push(e)}d.push(t)}return v({rings:d},t,i)}function M(e,t=(0,o.Pv)(e),i=(0,o.W0)(e)){let{rings:r,hasZ:n,hasM:s}=e,a=new c.A([],[],t,i),{lengths:l,coords:u,stride:d}=a,h=0,f=T(n??!1,s??!1,t,i);for(let e of r){for(let t of e)f(t,0,u,h),h+=d;l.push(e.length)}return a}const b=[],C=[];function O(e,t,i,r,n){b[0]=e;let[s]=N(C,b,t,i,r,n);return $(b),$(C),s}function N(e,t,i,n,s,a){if($(e),!i){for(let i of t){let t=(0,h.W)(i,a);e.push(new u.Om(null,i.attributes,null,t,void 0,i.distance,i.vertexCount))}return e}switch(i){case"esriGeometryPoint":return function(e,t,i,r,n){for(let s of t){let{geometry:t,attributes:a,centroid:l}=s,d=(0,o.Pv)(t),c=(0,o.W0)(t);e.push(new u.Om(t?S(t,i&&d,r&&c):null,a,l?S(l,!1,!1):null,(0,h.W)(s,n),s.displayId,s.distance,s.vertexCount))}return e}(e,t,n,s,a);case"esriGeometryMultipoint":return function(e,t,i,r,n){for(let s of t){let{geometry:t,attributes:a}=s,l=(0,o.Pv)(t),d=(0,o.W0)(t);e.push(new u.Om(t?w(t,i&&l,r&&d):null,a,null,(0,h.W)(s,n),s.displayId,s.distance,s.vertexCount))}return e}(e,t,n,s,a);case"esriGeometryPolyline":return function(e,t,i,r,n){for(let s of t){let{geometry:t,attributes:a,centroid:l}=s,d=(0,o.Pv)(t),c=(0,o.W0)(t);e.push(new u.Om(t?E(t,i&&d,r&&c):null,a,l?S(l,!1,!1):null,(0,h.W)(s,n),s.displayId,s.distance,s.vertexCount))}return e}(e,t,n,s,a);case"esriGeometryPolygon":case"esriGeometryMultiPatch":return function(e,t,i,r,n){for(let s of t){let{geometry:t,attributes:a,centroid:l}=s,d=(0,o.Pv)(t),c=(0,o.W0)(t);e.push(new u.Om(t?M(t,i&&d,r&&c):null,a,l?S(l,!1,!1):null,(0,h.W)(s,n),s.displayId,s.distance,s.vertexCount))}return e}(e,t,n,s,a);default:f().error("convertToFeatureSet:unknown-geometry",new r.A("internal:geometry",`Unable to parse unknown geometry type '${i}'`)),$(e)}return e}function V(e,t,i,r){C[0]=e,G(b,C,t,i,r);let n=b[0];return $(b),$(C),n}function z(e,t=(0,o.Pv)(e),i=(0,o.W0)(e)){return null==e?null:(0,o.fT)(e)?S(e,t,i):(0,o.Bi)(e)?M(e,t,i):(0,o.Rg)(e)?E(e,t,i):(0,o.U9)(e)?w(e,t,i):void f().error("convertFromGeometry:unknown-geometry",new r.A("internal:geometry",`Unable to parse unknown geometry type '${e}'`))}function P(e,t,i,n){if(null==e)return null;let s="coords"in e?e:e.geometry;if(null==s)return null;switch(t){case"esriGeometryPoint":return F(s,i,n);case"esriGeometryMultipoint":return I(s,i,n);case"esriGeometryPolyline":return R(s,i,n);case"esriGeometryPolygon":return A(s,i,n);default:return f().error("convertToGeometry:unknown-geometry",new r.A("internal:geometry",`Unable to parse unknown geometry type '${t}'`)),null}}function G(e,t,i,n,s){if($(e),null==i)return function(e,t){for(let i of t)e.push({attributes:i.attributes});return e}(e,t);switch(i){case"esriGeometryPoint":return function(e,t,i,r){for(let{geometry:n,attributes:s}of t)e.push({attributes:s,geometry:F(n,i,r)});return e}(e,t,n,s);case"esriGeometryMultipoint":return function(e,t,i,r){for(let{geometry:n,attributes:s}of t)e.push({geometry:n&&I(n,i,r),attributes:s});return e}(e,t,n,s);case"esriGeometryPolyline":return function(e,t,i,r){for(let{geometry:n,attributes:s}of t)e.push({geometry:n&&R(n,i,r),attributes:s});return e}(e,t,n,s);case"esriGeometryPolygon":return function(e,t,i,r){for(let{geometry:n,attributes:s,centroid:a}of t){let t=A(n,i,r),l=F(a,!1,!1);e.push(a?{geometry:t,attributes:s,centroid:l}:{geometry:t,attributes:s})}return e}(e,t,n,s);default:f().error("convertToFeatureSet:unknown-geometry",new r.A("internal:geometry",`Unable to parse unknown geometry type '${i}'`))}return e}function D(e){let{spatialReference:t,transform:i,fields:r,hasM:n,hasZ:s,features:a,geometryType:l,exceededTransferLimit:o,queryGeometry:u,queryGeometryType:d}=e,c={features:G([],a,l,s,n),fields:r,geometryType:l,spatialReference:t,queryGeometry:P(u,d,s,n)};return i&&(c.transform=i),o&&(c.exceededTransferLimit=o),n&&(c.hasM=n),s&&(c.hasZ=s),c}function B(e,t){let i=new d.A,{hasM:r,hasZ:n,features:s,spatialReference:a,geometryType:l,exceededTransferLimit:o,transform:u,fields:c,globalIdFieldName:h}=e;return c&&(i.fields=c),i.geometryType=l??null,i.spatialReference=a??null,s&&N(i.features,s,l,n,r,t),o&&(i.exceededTransferLimit=o),r&&(i.hasM=r),n&&(i.hasZ=n),u&&(i.transform=u),h&&(i.globalIdFieldName=h),i}function L(e,t){let{geometryType:i,features:r}=t;if(!e)return t;for(let t=0;t<r.length;t++){let n=r[t],s=n.weakClone();s.geometry=q(n.geometry,i,e),s.centroid=q(n.centroid,"esriGeometryPoint",e),r[t]=s}return t.transform=e,t}function q(e,t,i,r,n,s=!1){if(null==e||!e?.coords.length)return null;let a=p[t],{coords:l,lengths:o,stride:u,hasZ:d,hasM:h}=e;r??=d,n??=h;let f=new c.A([],[],r,n),_=f.stride,v=T(d,h,r,n),F=0,S=[0,0,0,0].slice(_),I=s?g:m,w=s?x:y;function R(){v(l,F,S,0),F+=u,S[0]=I(i,S[0]),S[1]=w(i,S[1])}if(e.isPoint)return R(),f.coords.push(...S),f;let E=0;for(let e of o){if(e<a)continue;let t=1;R(),f.coords.push(...S);let[i,r]=S;for(let n=1;n<e;n++){R();let[e,n]=S;(i!==e||r!==n)&&(s||(S[0]-=i,S[1]-=r),f.coords.push(...S),i=e,r=n,t++)}t>=a?(f.lengths.push(t),E=f.coords.length):$(f.coords,E)}return $(f.coords,E),f.coords.length?f:null}function Q(e,t,i,r=e.hasZ,n=e.hasM){if(!e.coords.length)return null;let s=p[t],{coords:a,lengths:l,stride:o,hasZ:u,hasM:d}=e,h=new c.A([],[],r,n),f=h.stride,m=T(u,d,r,n);if(e.isPoint)return m(a,0,h.coords,0),h;let y=0,g=i*i;for(let e of l){if(e<s){y+=e*o;continue}let t=h.coords.length/f,i=y,r=y+(e-1)*o;m(a,i,h.coords,h.coords.length),U(h.coords,a,o,g,m,i,r),m(a,r,h.coords,h.coords.length);let n=h.coords.length/f-t;n>=s?h.lengths.push(n):$(h.coords,t*f),y+=e*o}return h.coords.length?h:null}function Z(e,t,i,r){let n=e[t],s=e[t+1],a=e[i],l=e[i+1],o=e[r],u=e[r+1],d=a,c=l,h=o-d,f=u-c;if(0!==h||0!==f){let e=((n-d)*h+(s-c)*f)/(h*h+f*f);e>1?(d=o,c=u):e>0&&(d+=h*e,c+=f*e)}return h=n-d,f=s-c,h*h+f*f}function U(e,t,i,r,n,s,a){let l,o=r,u=0;for(let e=s+i;e<a;e+=i)l=Z(t,e,s,a),l>o&&(u=e,o=l);o>r&&(u-s>i&&U(e,t,i,r,n,s,u),n(t,u,e,e.length),a-u>i&&U(e,t,i,r,n,u,a))}function k(e,t){if(!t?.coords?.length)return null;let i=1/0,r=1/0,n=-1/0,s=-1/0,{coords:o,stride:u}=t;for(let e=0;e<o.length;e+=u){let t=o[e],a=o[e+1];i=Math.min(i,t),n=Math.max(n,t),r=Math.min(r,a),s=Math.max(s,a)}return(0,a.is)(e)?(0,a.BI)(e,i,r,n,s):(0,l.fA)(i,r,n,s,e),e}function j(e,t){let{coords:i,lengths:r,stride:n,hasZ:a,hasM:l}=e;if(!i.length)return void(r.length=0);(0,s.Lw)(t);let{originPosition:o,scale:u,translate:d}=t,c=J;c.originPosition=o;let h=c.scale;h[0]=u[0]??1,h[1]=-(u[1]??1),h[2]=u[2]??1,h[3]=u[3]??1;let f=c.translate;if(f[0]=d[0]??0,f[1]=d[1]??0,f[2]=d[2]??0,f[3]=d[3]??0,l&&!a&&(h[2]=h[3],f[2]=f[3]),!r.length){for(let e=0;e<n;++e)i[e]=_(c,i[e],e);return void(r.length=0)}let p=0;for(let e=0;e<r.length;e++){let t=r[e];r[e]=t;for(let e=0;e<n;++e)i[p+e]=_(c,i[p+e],e);let s=i[p],a=i[p+1];p+=n;for(let e=1;e<t;e++,p+=n){s+=i[p]*h[0],a+=i[p+1]*h[1],i[p]=s,i[p+1]=a;for(let e=2;e<n;++e)i[p+e]=_(c,i[p+e],e)}}}function H(e,t,i,r){let n=0,s=e[r*t],a=e[r*(t+1)];for(let l=1;l<i;l++){let i=s+e[r*(t+l)],o=a+e[r*(t+l)+1],u=(i-s)*(o+a);s=i,a=o,n+=u}return.5*n}function W(e,t){let{coords:i,lengths:r}=e,n=0,s=0;for(let e=0;e<r.length;e++){let a=r[e];s+=H(i,n,a,t),n+=a}return Math.abs(s)}function $(e,t=0){e.length!==t&&(e.length=t)}const J={originPosition:"lowerLeft",scale:[1,1,1,1],translate:[0,0,0,0]}},5834(e,t,i){i.d(t,{A:()=>c});var r=i(32198),n=i(93637),s=i(91429),a=i(78888),l=i(41266),o=i(41366),u=i(93223);function d(e,t,i){(0,n.sM)(i,e instanceof Date?e.getTime():e,t)}let c=class extends((0,o.K)(l.A)){constructor(e){super(e),this.numBins=null,this.end=null,this.start=null,this.type="auto-interval"}};(0,r.Cg)([(0,s.MZ)({type:Number,json:{name:"parameters.numberOfBins",write:!0}})],c.prototype,"numBins",void 0),(0,r.Cg)([(0,s.MZ)({json:{name:"parameters.end",write:{writer:d}}})],c.prototype,"end",void 0),(0,r.Cg)([(0,s.MZ)({json:{name:"parameters.start",write:{writer:d}}})],c.prototype,"start",void 0),(0,r.Cg)([(0,u.e)({autoIntervalBin:"auto-interval"},{readOnly:!0})],c.prototype,"type",void 0),c=(0,r.Cg)([(0,s.$K)("esri.rest.support.AutoIntervalBinParameters")],c),c.from=(0,a.dp)(c)},41266(e,t,i){i.d(t,{A:()=>m});var r=i(32198),n=i(69540),s=i(66552),a=i(25482),l=i(91429),o=i(78888),u=i(93223);const d=new s.J({esriFieldTypeInteger:"integer",esriFieldTypeString:"string"});let c=class extends((0,n.OU)(a.o)){constructor(e){super(e),this.alias=null,this.responseType=null,this.type=null,this.value=null,this.valueType=null}};(0,r.Cg)([(0,l.MZ)({type:String,json:{name:"outAlias",write:!0}})],c.prototype,"alias",void 0),(0,r.Cg)([(0,l.MZ)({type:String})],c.prototype,"responseType",void 0),(0,r.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],c.prototype,"type",void 0),(0,r.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],c.prototype,"value",void 0),(0,r.Cg)([(0,u.e)(d)],c.prototype,"valueType",void 0),c=(0,r.Cg)([(0,l.$K)("esri.rest.support.AttributeBinsGrouping")],c);const h=c;c.from=(0,o.dp)(c);const f=new s.J({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeDate:"date",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"}),p=new s.J({naturalLog:"natural-log",squareRoot:"square-root"});let m=class extends((0,n.OU)(a.o)){constructor(e){super(e),this.expression=null,this.expressionValueType=null,this.field=null,this.firstDayOfWeek=null,this.hideUpperBound=null,this.splitBy=null,this.stackBy=null,this.transformation=null}};(0,r.Cg)([(0,l.MZ)({type:String,json:{name:"onExpression.value",write:!0}})],m.prototype,"expression",void 0),(0,r.Cg)([(0,u.e)(f,{name:"onExpression.valueType"})],m.prototype,"expressionValueType",void 0),(0,r.Cg)([(0,l.MZ)({type:String,json:{name:"onField",write:!0}})],m.prototype,"field",void 0),(0,r.Cg)([(0,l.MZ)({type:Number,json:{write:!0}})],m.prototype,"firstDayOfWeek",void 0),(0,r.Cg)([(0,l.MZ)({type:Boolean,json:{write:!0}})],m.prototype,"hideUpperBound",void 0),(0,r.Cg)([(0,l.MZ)({type:h,json:{write:{overridePolicy(){return{enabled:null!=this.splitBy?.value||null!=this.splitBy?.type}}}}})],m.prototype,"splitBy",void 0),(0,r.Cg)([(0,l.MZ)({type:h,json:{write:{target:{stackBy:{type:h},jsonStyle:{type:String}},writer:(e,t)=>{e&&(t.stackBy=e.toJSON(),null!=e.responseType&&(t.jsonStyle=e.responseType))},overridePolicy(){return{enabled:null!=this.stackBy?.value||null!=this.stackBy?.type}}},read:{source:["stackBy","jsonStyle"],reader:(e,t)=>h.fromJSON({...t.stackBy,responseType:t.jsonStyle})}}})],m.prototype,"stackBy",void 0),(0,r.Cg)([(0,u.e)(p)],m.prototype,"transformation",void 0),m=(0,r.Cg)([(0,l.$K)("esri.rest.support.BinParametersBase")],m)},9760(e,t,i){i.d(t,{A:()=>d});var r=i(32198),n=i(66552),s=i(25482),a=i(91429),l=i(93223);const o=new n.J({esriClassifyEqualInterval:"equal-interval",esriClassifyManual:"manual",esriClassifyNaturalBreaks:"natural-breaks",esriClassifyQuantile:"quantile",esriClassifyStandardDeviation:"standard-deviation",esriClassifyDefinedInterval:"defined-interval"}),u=new n.J({esriNormalizeByLog:"log",esriNormalizeByPercentOfTotal:"percent-of-total",esriNormalizeByField:"field"});let d=class extends s.o{constructor(e){super(e),this.type="class-breaks-definition",this.breakCount=null,this.classificationField=null,this.classificationMethod=null,this.normalizationField=null,this.normalizationType=null}set standardDeviationInterval(e){"standard-deviation"===this.classificationMethod&&this._set("standardDeviationInterval",e)}set definedInterval(e){"defined-interval"===this.classificationMethod&&this._set("definedInterval",e)}};(0,r.Cg)([(0,l.e)({classBreaksDef:"class-breaks-definition"})],d.prototype,"type",void 0),(0,r.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"breakCount",void 0),(0,r.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"classificationField",void 0),(0,r.Cg)([(0,a.MZ)({type:String,json:{read:o.read,write:o.write}})],d.prototype,"classificationMethod",void 0),(0,r.Cg)([(0,a.MZ)({json:{write:!0}})],d.prototype,"normalizationField",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:u.read,write:u.write}})],d.prototype,"normalizationType",void 0),(0,r.Cg)([(0,a.MZ)({value:null,json:{write:!0}})],d.prototype,"standardDeviationInterval",null),(0,r.Cg)([(0,a.MZ)({value:null,json:{write:!0}})],d.prototype,"definedInterval",null),d=(0,r.Cg)([(0,a.$K)("esri.rest.support.ClassBreaksDefinition")],d)},59977(e,t,i){i.d(t,{A:()=>y});var r=i(32198),n=i(93637),s=i(91429),a=i(78888),l=i(41266),o=i(69540),u=i(25482),d=i(57231),c=i(93223);let h=class extends((0,o.OU)(u.o)){constructor(e){super(e),this.value=null,this.unit=null}};(0,r.Cg)([(0,s.MZ)({type:Number,json:{name:"number",write:!0}})],h.prototype,"value",void 0),(0,r.Cg)([(0,c.e)(d.g)],h.prototype,"unit",void 0),h=(0,r.Cg)([(0,s.$K)("esri.rest.support.DateBinTimeInterval")],h);const f=h;function p(e,t,i){(0,n.sM)(i,"string"==typeof e?e:e?.getTime(),t)}function m(e,t){let i=e.parameters[t];return i?"string"==typeof i?i:new Date(i):null}h.from=(0,a.dp)(h);let y=class extends l.A{constructor(e){super(e),this.end=null,this.interval=null,this.offset=null,this.returnFullIntervalBin=!1,this.start=null,this.snapToData=null,this.type="date"}};(0,r.Cg)([(0,s.MZ)({cast:e=>null==e?null:"string"==typeof e?e:new Date(e),json:{name:"parameters.end",read:{reader:(e,t)=>m(t,"end")},write:{writer:p}}})],y.prototype,"end",void 0),(0,r.Cg)([(0,s.MZ)({type:f,json:{name:"parameters",write:!0}})],y.prototype,"interval",void 0),(0,r.Cg)([(0,s.MZ)({type:f,json:{name:"parameters.offset",write:!0}})],y.prototype,"offset",void 0),(0,r.Cg)([(0,s.MZ)({type:Boolean,json:{name:"parameters.returnFullIntervalBin",write:!0}})],y.prototype,"returnFullIntervalBin",void 0),(0,r.Cg)([(0,s.MZ)({cast:e=>null==e?null:"string"==typeof e?e:new Date(e),json:{name:"parameters.start",read:{reader:(e,t)=>m(t,"start")},write:{writer:p}}})],y.prototype,"start",void 0),(0,r.Cg)([(0,s.MZ)({type:String,json:{name:"parameters.snapToData",write:!0}})],y.prototype,"snapToData",void 0),(0,r.Cg)([(0,c.e)({dateBin:"date"},{readOnly:!0})],y.prototype,"type",void 0),y=(0,r.Cg)([(0,s.$K)("esri.rest.support.DateBinParameters")],y),y.from=(0,a.dp)(y)},57231(e,t,i){const r=(0,i(66552).O)()({year:"years",quarter:"quarters",month:"months",week:"weeks",day:"days",hour:"hours",minute:"minutes",second:"seconds"});i.d(t,["g",0,r])},11440(e,t,i){i.d(t,{A:()=>u});var r=i(32198),n=i(93637),s=i(91429),a=i(78888),l=i(41266),o=i(93223);let u=class extends l.A{constructor(e){super(e),this.boundaries=[],this.type="fixed-boundaries"}};(0,r.Cg)([(0,s.MZ)({json:{name:"parameters.boundaries",write:{writer:function(e,t,i){(0,n.sM)(i,e&&function(e){return e[0]instanceof Date}(e)?e.map(e=>e.getTime()):e,t)}}}})],u.prototype,"boundaries",void 0),(0,r.Cg)([(0,o.e)({fixedBoundariesBin:"fixed-boundaries"},{readOnly:!0})],u.prototype,"type",void 0),u=(0,r.Cg)([(0,s.$K)("esri.rest.support.FixedBoundariesBinParameters")],u),u.from=(0,a.dp)(u)},60909(e,t,i){i.d(t,{A:()=>c});var r=i(32198),n=i(93637),s=i(91429),a=i(78888),l=i(41266),o=i(41366),u=i(93223);function d(e,t,i){(0,n.sM)(i,e instanceof Date?e.getTime():e,t)}let c=class extends((0,o.K)(l.A)){constructor(e){super(e),this.end=null,this.interval=null,this.start=null,this.type="fixed-interval"}};(0,r.Cg)([(0,s.MZ)({json:{name:"parameters.end",write:{writer:d}}})],c.prototype,"end",void 0),(0,r.Cg)([(0,s.MZ)({type:Number,json:{name:"parameters.interval",write:!0}})],c.prototype,"interval",void 0),(0,r.Cg)([(0,s.MZ)({json:{name:"parameters.start",write:{writer:d}}})],c.prototype,"start",void 0),(0,r.Cg)([(0,u.e)({fixedIntervalBin:"fixed-interval"},{readOnly:!0})],c.prototype,"type",void 0),c=(0,r.Cg)([(0,s.$K)("esri.rest.support.FixedIntervalBinParameters")],c),c.from=(0,a.dp)(c)},41366(e,t,i){var r=i(32198),n=i(66552),s=i(53966),a=i(91429),l=i(93223);const o=(0,n.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),u="percent-of-total",d="field";i.d(t,["K",0,e=>{let t=e,i=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"),t=!!this.normalizationField,i=null!=this.normalizationTotal;return t||i?(e=t&&d||i&&u||null,t&&i&&s.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):(e===d||e===u)&&(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,r.Cg)([(0,a.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],i.prototype,"normalizationField",void 0),(0,r.Cg)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],i.prototype,"normalizationMaxValue",void 0),(0,r.Cg)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],i.prototype,"normalizationMinValue",void 0),(0,r.Cg)([(0,a.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],i.prototype,"normalizationTotal",void 0),(0,r.Cg)([(0,l.e)(o,{name:"parameters.normalizationType"})],i.prototype,"normalizationType",null),i=(0,r.Cg)([(0,a.$K)("esri.rest.support.NormalizationBinParametersMixin")],i),i},"Q",0,o])},84892(e,t,i){i.d(t,{t:()=>s});var r=i(53966);function n(e,t){return Number(e.toFixed(t))}function s(e,t){let{normalizationTotal:i}=e;return{classBreaks:a(e,t),normalizationTotal:i}}function a(e,t){let i=e.definition,{classificationMethod:r,normalizationType:s,definedInterval:a}=i,u=i.breakCount??1,d=[],c=e.values;if(0===c.length)return[];c=c.sort((e,t)=>e-t);let[h,f]=t??[c.at(0),c.at(-1)];if("equal-interval"===r)if(c.length>=u){let e=(f-h)/u,t=h;for(let i=1;i<u;i++){let r=n(h+i*e,6);d.push({minValue:t,maxValue:r,label:l(t,r,s)}),t=r}d.push({minValue:t,maxValue:f,label:l(t,f,s)})}else c.forEach(e=>{d.push({minValue:e,maxValue:e,label:l(e,e,s)})});else if("natural-breaks"===r){let t=function(e){let t=[],i=[],r=Number.MIN_VALUE,n=1,s=-1;for(let a=0;a<e.length;a++){let l=e[a];l===r?(n++,i[s]=n):null!==l&&(t.push(l),r=l,n=1,i.push(n),s++)}return{uniqueValues:t,valueFrequency:i}}(c),i=e.valueFrequency||t.valueFrequency,r=o(t.uniqueValues,i,u),a=h;for(let e=1;e<u;e++)if(t.uniqueValues.length>e){let i=n(t.uniqueValues[r[e]],6);d.push({minValue:a,maxValue:i,label:l(a,i,s)}),a=i}d.push({minValue:a,maxValue:f,label:l(a,f,s)})}else if("quantile"===r)if(c.length>=u&&h!==f){let e=h,t=Math.ceil(c.length/u),i=0;for(let r=1;r<u;r++){let n=t+i-1;n>c.length&&(n=c.length-1),n<0&&(n=0),d.push({minValue:e,maxValue:c[n],label:l(e,c[n],s)}),e=c[n],i+=t,t=Math.ceil((c.length-i)/(u-r))}d.push({minValue:e,maxValue:f,label:l(e,f,s)})}else{let e=-1;for(let t=0;t<c.length;t++){let i=c[t];i!==e&&(e=i,d.push({minValue:e,maxValue:i,label:l(e,i,s)}),e=i)}}else if("standard-deviation"===r){let e=function(e){let t=0;for(let i=0;i<e.length;i++)t+=e[i];return t/=e.length,t}(c),t=function(e,t){let i=0;for(let r=0;r<e.length;r++){let n=e[r];i+=(n-t)*(n-t)}return i/=e.length,Math.sqrt(i)}(c,e);if(0===t)d.push({minValue:c[0],maxValue:c[0],label:l(c[0],c[0],s)});else{let i=function(e,t,i,r,n){let s=Math.max(r-e,t-r)/n/i;return s=s>=1?1:s>=.5?.5:.25,s}(h,f,u,e,t)*t,r=0,a=h;for(let t=u;t>=1;t--){let o=n(e-(t-.5)*i,6);d.push({minValue:a,maxValue:o,label:l(a,o,s)}),a=o,r++}let o=n(e+.5*i,6);d.push({minValue:a,maxValue:o,label:l(a,o,s)}),a=o,r++;for(let t=1;t<=u;t++)o=r===2*u?f:n(e+(t+.5)*i,6),d.push({minValue:a,maxValue:o,label:l(a,o,s)}),a=o,r++}}else if("defined-interval"===r){if(!a)return d;let[e,i]=t??[c.at(0),c.at(-1)],r=Math.ceil((i-e)/a),o=e;for(let t=1;t<r;t++){let i=n(e+t*a,6);d.push({minValue:o,maxValue:i,label:l(o,i,s)}),o=i}d.push({minValue:o,maxValue:i,label:l(o,i,s)})}return d}function l(e,t,i){let r=null;return r=e===t?i&&"percent-of-total"===i?e+"%":e.toString():i&&"percent-of-total"===i?e+"% - "+t+"%":e+" - "+t,r}function o(e,t,i){let r=e.length,n=[];i>r&&(i=r);for(let e=0;e<i;e++)n.push(Math.round(e*r/i-1));n.push(r-1);let s=u(n,e,t,i);return function(e,t,i,r,n,s){let a=0,l=0,o=0,u=0,c=!0;for(let h=0;h<2&&c;h++){0===h&&(c=!1);for(let h=0;h<s-1;h++)for(;i[h+1]+1!==i[h+2];){i[h+1]=i[h+1]+1;let s=d(h,i,r,n);o=s.sbMean,a=s.sbSdcm;let f=d(h+1,i,r,n);if(u=f.sbMean,l=f.sbSdcm,!(a+l<t[h]+t[h+1])){i[h+1]=i[h+1]-1;break}t[h]=a,t[h+1]=l,e[h]=o,e[h+1]=u,c=!0}for(let h=s-1;h>0;h--)for(;i[h]!==i[h-1]+1;){i[h]=i[h]-1;let s=d(h-1,i,r,n);o=s.sbMean,a=s.sbSdcm;let f=d(h,i,r,n);if(u=f.sbMean,l=f.sbSdcm,!(a+l<t[h-1]+t[h])){i[h]=i[h]+1;break}t[h-1]=a,t[h]=l,e[h-1]=o,e[h]=u,c=!0}}return c}(s.mean,s.sdcm,n,e,t,i)&&(s=u(n,e,t,i)),n}function u(e,t,i,r){let n=[],s=[],a=[],l=0,o=[],u=[];for(let n=0;n<r;n++){let r=d(n,e,t,i);o.push(r.sbMean),u.push(r.sbSdcm),l+=u[n]}let c,h=l,f=!0;for(;f||l<h;){f=!1,n=[];for(let t=0;t<r;t++)n.push(e[t]);for(let i=0;i<r;i++)for(let n=e[i]+1;n<=e[i+1];n++)if(c=t[n],i>0&&n!==e[i+1]&&Math.abs(c-o[i])>Math.abs(c-o[i-1]))e[i]=n;else if(i<r-1&&e[i]!==n-1&&Math.abs(c-o[i])>Math.abs(c-o[i+1])){e[i+1]=n-1;break}h=l,l=0,s=[],a=[];for(let n=0;n<r;n++){s.push(o[n]),a.push(u[n]);let r=d(n,e,t,i);o[n]=r.sbMean,u[n]=r.sbSdcm,l+=u[n]}}if(l>h){for(let t=0;t<r;t++)e[t]=n[t],o[t]=s[t],u[t]=a[t];l=h}return{mean:o,sdcm:u}}function d(e,t,i,n){let s=0,a=0;for(let r=t[e]+1;r<=t[e+1];r++){let e=n[r];s+=i[r]*e,a+=e}a<=0&&r.A.getLogger("esri.rest.support.generateRendererUtils").warn("Exception in Natural Breaks calculation");let l=s/a,o=0;for(let r=t[e]+1;r<=t[e+1];r++)o+=n[r]*(i[r]-l)**2;return{sbMean:l,sbSdcm:o}}},1873(e,t,i){i.d(t,{$y:()=>V,Ak:()=>P,FM:()=>p,G_:()=>h,Rw:()=>O,Vb:()=>d,b3:()=>A,gJ:()=>u,jM:()=>N,lv:()=>b,oZ:()=>E,qg:()=>f,sU:()=>z,z9:()=>c,zS:()=>C});var r=i(9760),n=i(84892);const s=/\s*(\+|-)?((\d+(\.\d+)?)|(\.\d+))\s*/gi,a=new Set(["esriFieldTypeDate","esriFieldTypeInteger","esriFieldTypeSmallInteger","esriFieldTypeSingle","esriFieldTypeDouble","esriFieldTypeLong","esriFieldTypeOID","esriFieldTypeBigInteger"]),l=new Set(["esriFieldTypeTimeOnly","esriFieldTypeDateOnly"]),o=["min","max","avg","stddev","count","sum","variance","nullcount","median"];function u(e){return null==e||"string"==typeof e&&!e?"<Null>":e}function d(e){let t=null!=e.normalizationField||null!=e.normalizationType,i=null!=e.minValue||null!=e.maxValue,r=!!e.sqlExpression&&e.supportsSQLExpression;return!t&&!i&&!r}function c(e){let{outStatisticTypes:t}=e,i=e.returnDistinct?[...new Set(e.values)]:e.values,r=i.filter(e=>null!=e).sort(),n=r.length,s={count:n,min:r[0],max:r[n-1]};return e.supportsNullCount&&(s.nullcount=i.length-n),!e.percentileParams||t?.include?.length&&!t.include.includes("median")||t?.exclude?.length&&t.exclude.includes("median")||(s.median=f(i,e.percentileParams)),s}function h(e){let{values:t,useSampleStdDev:i,supportsNullCount:r,outStatisticTypes:n}=e,s=1/0,a=-1/0,l=null,o=null,u=null,d=null,c=0,h=null==e.minValue?-1/0:e.minValue,p=null==e.maxValue?1/0:e.maxValue;for(let e of t)Number.isFinite(e)?e>=h&&e<=p&&(l=null===l?e:l+e,s=Math.min(s,e),a=Math.max(a,e),c++):"string"==typeof e&&c++;if(c&&null!=l){o=l/c;let e=0;for(let i of t)Number.isFinite(i)&&i>=h&&i<=p&&(e+=(i-o)**2);d=i?c>1?e/(c-1):0:c>0?e/c:0,u=Math.sqrt(d)}else s=null,a=null;let m={avg:o,count:c,max:a,min:s,stddev:u,sum:l,variance:d};return r&&(m.nullcount=t.length-c),!e.percentileParams||n?.include?.length&&!n.include.includes("median")||n?.exclude?.length&&n.exclude.includes("median")||(m.median=f(t,e.percentileParams)),m}function f(e,t){let{fieldType:i,value:r,orderBy:n,isDiscrete:s}=t,a=p(i,"desc"===n,"case-insensitive");if(e=[...e].filter(e=>null!=e).sort((e,t)=>a(e,t)),0===e.length)return null;if(r<=0)return e[0];if(r>=1)return e[e.length-1];let l=(e.length-1)*r,o=Math.floor(l),u=o+1,d=l%1,c=e[o],h=e[u];return u>=e.length||s||"string"==typeof c||"string"==typeof h?c:c*(1-d)+h*d}function p(e,t,i="case-sensitive"){if(e){if(a.has(e))return w(t);if(l.has(e))return F(t,!0);if("esriFieldTypeTimestampOffset"===e)return function(e){return e?_:x}(t);let r=F(t,"case-sensitive"===i);if("esriFieldTypeString"===e)return r;if("esriFieldTypeGUID"===e||"esriFieldTypeGlobalID"===e)return(e,t)=>r(R(e),R(t))}let r=t?1:-1,n=w(t),s=F(t,"case-sensitive"===i),o=g(t);return(e,t)=>"number"==typeof e&&"number"==typeof t?n(e,t):"string"==typeof e&&"string"==typeof t?s(e,t):o(e,t)??r}const m=(e,t)=>null==e?null==t?0:1:null==t?-1:null,y=(e,t)=>null==e?null==t?0:-1:null==t?1:null;function g(e){return e?m:y}const x=(e,t)=>y(e,t)??(e===t?0:new Date(e).getTime()-new Date(t).getTime()),_=(e,t)=>m(e,t)??(e===t?0:new Date(t).getTime()-new Date(e).getTime()),v=(e,t)=>y(e,t)??(e===t?0:e<t?-1:1),T=(e,t)=>m(e,t)??(e===t?0:e<t?1:-1);function F(e,t){if(t)return e?T:v;let i=g(e);return e?(e,t)=>i(e,t)??((e=e.toUpperCase())>(t=t.toUpperCase())?-1:+(e<t)):(e,t)=>i(e,t)??((e=e.toUpperCase())<(t=t.toUpperCase())?-1:+(e>t))}const S=(e,t)=>m(e,t)??t-e,I=(e,t)=>y(e,t)??e-t;function w(e){return e?S:I}function R(e){return e.slice(24,36)+e.slice(19,23)+e.slice(16,18)+e.slice(14,16)+e.slice(11,13)+e.slice(9,11)+e.slice(6,8)+e.slice(4,6)+e.slice(2,4)+e.slice(0,2)}function E(e,t,i){let r;for(r in e)t?.include?.length&&!t.include.includes(r)||t?.exclude?.length&&t.exclude.includes(r)?delete e[r]:o.includes(r)&&(Number.isFinite(e[r])||(e[r]=null));return i&&["avg","stddev","variance"].forEach(t=>{null!=e[t]&&(e[t]=Math.ceil(e[t]??0))}),e}function A(e){let t={};for(let i of e)(null==i||"string"==typeof i&&""===i.trim())&&(i=null),null==t[i]?t[i]={count:1,data:i}:t[i].count++;return{count:t}}function M(e){return"coded-value"===e?.type?e.codedValues.map(e=>e.code):[]}function b(e,t,i,r){let n=e.count,s=[];if(i&&t){let e=[],i=M(t[0]);for(let n of i)if(t[1]){let i=M(t[1]);for(let s of i)if(t[2]){let i=M(t[2]);for(let t of i)e.push(`${u(n)}${r}${u(s)}${r}${u(t)}`)}else e.push(`${u(n)}${r}${u(s)}`)}else e.push(n);for(let t of e)n.hasOwnProperty(t)||(n[t]={data:t,count:0})}for(let e in n){let t=n[e];s.push({value:t.data,count:t.count,label:t.label})}return{uniqueValueInfos:s}}function C(e,t,i,r){let n=null;switch(t){case"log":0!==e&&(n=Math.log(e)*Math.LOG10E);break;case"percent-of-total":Number.isFinite(r)&&0!==r&&(n=e/r*100);break;case"field":Number.isFinite(i)&&0!==i&&(n=e/i);break;case"natural-log":e>0&&(n=Math.log(e));break;case"square-root":e>0&&(n=e**.5)}return n}function O(e,t,i){let s=function(e){let{breakCount:t,field:i,normalizationField:n,normalizationType:s}=e,a=e.classificationMethod||"equal-interval",l="standard-deviation"===a?e.standardDeviationInterval||1:void 0,o="defined-interval"===a?e.definedInterval:void 0;return new r.A({breakCount:t,classificationField:i,classificationMethod:a,normalizationField:"field"===s?n:void 0,normalizationType:s,standardDeviationInterval:l,definedInterval:o})}({field:t.field,normalizationType:t.normalizationType,normalizationField:t.normalizationField,classificationMethod:t.classificationMethod,standardDeviationInterval:t.standardDeviationInterval,definedInterval:t.definedInterval,breakCount:t.numClasses||5});return e=function(e,t,i){let r=t??-1/0,n=i??1/0;return e.filter(e=>Number.isFinite(e)&&e>=r&&e<=n)}(e,t.minValue,t.maxValue),(0,n.t)({definition:s,values:e,normalizationTotal:t.normalizationTotal},i)}function N(e,t){let i=e.classBreaks,r=i.length,n=i[0]?.minValue,a=i[r-1]?.maxValue,l="standard-deviation"===t,o=s;return i=i.map(e=>{let t=e.label,i={minValue:e.minValue,maxValue:e.maxValue,label:t};if(l&&t){let e=t.match(o)?.map(e=>+e.trim())??[];2===e.length?(i.minStdDev=e[0],i.maxStdDev=e[1],e[0]<0&&e[1]>0&&(i.hasAvg=!0)):1===e.length&&(t.includes("<")?(i.minStdDev=null,i.maxStdDev=e[0]):t.includes(">")&&(i.minStdDev=e[0],i.maxStdDev=null))}return i}),{minValue:n,maxValue:a,classBreakInfos:i,normalizationTotal:e.normalizationTotal}}function V(e,t){let i=z(e,t);if(null==i.min&&null==i.max)return{bins:[],minValue:i.min,maxValue:i.max,normalizationTotal:t.normalizationTotal};let r=i.intervals,n=i.min??0,s=i.max??0,a=r.map((e,t)=>({minValue:r[t][0],maxValue:r[t][1],count:0}));for(let t of e)if(null!=t&&t>=n&&t<=s){let e=P(r,t);e>-1&&a[e].count++}return{bins:a,minValue:n,maxValue:s,normalizationTotal:t.normalizationTotal}}function z(e,t,i=!1){let{field:r,classificationMethod:n,standardDeviationInterval:s,definedInterval:a,normalizationType:l,normalizationField:o,normalizationTotal:u,minValue:c,maxValue:f}=t,p=t.numBins||10,m=null,y=null,g=null;if(n&&"equal-interval"!==n||l){let{classBreaks:t}=O(e,{field:r,normalizationType:l,normalizationField:o,normalizationTotal:u,classificationMethod:n,standardDeviationInterval:s,definedInterval:a,minValue:c,maxValue:f,numClasses:p},null!=c&&null!=f?[c,f]:void 0);m=t[0]?.minValue,y=t[t.length-1]?.maxValue,g=t.map(e=>[e.minValue,e.maxValue])}else{if(null!=c&&null!=f)m=c,y=f;else{let t=h({values:e,minValue:c,maxValue:f,useSampleStdDev:!l,supportsNullCount:d({normalizationType:l,normalizationField:o,minValue:c,maxValue:f})});m=t.min??null,y=t.max??null}g=function(e,t,i){let r,n=(t-e)/i,s=[],a=e;for(let e=1;e<=i;e++)r=a+n,r=Number(r.toFixed(16)),s.push([a,e===i?t:r]),a=r;return s}(m??0,y??0,p)}if(i&&g.length){let e=g.at(-1)[1];g.push([e,e])}return{min:m,max:y,intervals:g}}function P(e,t){let i=-1;for(let r=e.length-1;r>=0;r--)if(t>=e[r][0]){i=r;break}return i}},92359(e,t,i){i.d(t,{nu:()=>h,W6:()=>u}),i(4576),i(71511),i(44208),i(53966);var r=i(17676),n=(i(36708),i(44794),i(78659)),s=i(32198),a=i(69622),l=i(91429);let o=class extends a.A{constructor(){super(...arguments),this.SCHEDULER_LOG_SLOW_TASKS=!1,this.FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES=!1}};(0,s.Cg)([(0,l.MZ)()],o.prototype,"SCHEDULER_LOG_SLOW_TASKS",void 0),(0,s.Cg)([(0,l.MZ)()],o.prototype,"FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES",void 0),o=(0,s.Cg)([(0,l.$K)("esri.views.support.debugFlags")],o),new o,i(49186),Symbol("Yield");const u={RESOURCE_CONTROLLER_IMMEDIATE:"immediate",RESOURCE_CONTROLLER:"schedule",SLIDE:"slide",STREAM_DATA_LOADER:"stream loader",ELEVATION_QUERY:"elevation query",TERRAIN_SURFACE:"terrain",SURFACE_GEOMETRY_UPDATES:"surface geometry updates",LOD_RENDERER:"LoD renderer",GRAPHICS_CORE:"Graphics3D",I3S:"I3S",LYR3D:"Lyr3D",TILES3D:"3DTiles",POINT_CLOUD_LAYER:"point cloud",FEATURE_TILE_FETCHER:"feature fetcher",STREAM_CONTROLLER:"stream controller",SCREEN_POLYGON_INTERSECTION:"screen polygon intersection",OCCLUSION_QUERY:"occlusion query",OVERLAY:"overlay",OVERLAY_RENDERER:"overlay renderer",STAGE:"stage",GRAPHICS_DECONFLICTOR:"graphics deconflictor",FILTER_VISIBILITY:"graphics filter visibility",SCALE_VISIBILITY:"graphics scale visibility",FRUSTUM_VISIBILITY:"graphics frustum visibility",POINT_OF_INTEREST_FREQUENT:"POI frequent",POINT_OF_INTEREST_INFREQUENT:"POI infrequent",LABELER:"labeler",FEATURE_FILTER_HIGHLIGHT:"feature filter highlight",FEATURE_QUERY_ENGINE:"feature query",FEATURE_TILE_TREE:"feature tile tree",FEATURE_TILE_TREE_ACTIVE:"fast feature tile tree",ELEVATION_ALIGNMENT:"elevation alignment",ELEVATION_ALIGNMENT_SCENE:"elevation alignment scene",TEXT_TEXTURE_ATLAS:"text texture atlas",TEXTURE_UNLOAD:"texture unload",LINE_OF_SIGHT_TOOL:"line of sight tool",LINE_OF_SIGHT_TOOL_INTERACTIVE:"interactive line of sight tool",VOLUME_MEASUREMENT:"volume measurement",ELEVATION_PROFILE:"elevation profile",SNAPPING:"snapping",SHADOW_ACCUMULATOR:"shadow accumulator",CLOUDS_GENERATOR:"clouds generator",FLOW_GENERATOR:"flow generator",GAUSSIAN_SPLAT_SORTING:"gaussian splat sorting",GAUSSIAN_SPLAT_TEXTURE_ATLAS:"gaussian splat texture atlas",MAPVIEW_FETCH_QUEUE:"mapview fetch queue",MAPVIEW_LAYERVIEW_UPDATE:"mapview layerview update",MAPVIEW_VECTOR_TILE_PARSING_QUEUE:"mapview vector tile parsing queue",NONE:0,TEST_PRIO:1};new Map([[u.RESOURCE_CONTROLLER_IMMEDIATE,0],[u.RESOURCE_CONTROLLER,4],[u.SLIDE,0],[u.STREAM_DATA_LOADER,0],[u.ELEVATION_QUERY,0],[u.TERRAIN_SURFACE,1],[u.SURFACE_GEOMETRY_UPDATES,1],[u.LOD_RENDERER,2],[u.GRAPHICS_CORE,2],[u.I3S,2],[u.LYR3D,2],[u.TILES3D,3],[u.POINT_CLOUD_LAYER,2],[u.FEATURE_TILE_FETCHER,2],[u.STREAM_CONTROLLER,2],[u.SCREEN_POLYGON_INTERSECTION,0],[u.CLOUDS_GENERATOR,2],[u.OCCLUSION_QUERY,2],[u.OVERLAY,4],[u.OVERLAY_RENDERER,4],[u.STAGE,4],[u.GRAPHICS_DECONFLICTOR,4],[u.FILTER_VISIBILITY,4],[u.SCALE_VISIBILITY,4],[u.FRUSTUM_VISIBILITY,4],[u.POINT_OF_INTEREST_FREQUENT,6],[u.POINT_OF_INTEREST_INFREQUENT,30],[u.LABELER,8],[u.FEATURE_FILTER_HIGHLIGHT,2],[u.FEATURE_QUERY_ENGINE,8],[u.FEATURE_TILE_TREE,16],[u.FEATURE_TILE_TREE_ACTIVE,0],[u.ELEVATION_ALIGNMENT,12],[u.ELEVATION_ALIGNMENT_SCENE,14],[u.TEXT_TEXTURE_ATLAS,12],[u.TEXTURE_UNLOAD,12],[u.LINE_OF_SIGHT_TOOL,16],[u.LINE_OF_SIGHT_TOOL_INTERACTIVE,0],[u.VOLUME_MEASUREMENT,4],[u.SNAPPING,0],[u.SHADOW_ACCUMULATOR,30],[u.FLOW_GENERATOR,12],[u.GAUSSIAN_SPLAT_SORTING,2],[u.GAUSSIAN_SPLAT_TEXTURE_ATLAS,12],[u.MAPVIEW_FETCH_QUEUE,0],[u.MAPVIEW_LAYERVIEW_UPDATE,2],[u.MAPVIEW_VECTOR_TILE_PARSING_QUEUE,0]]),(0,n.l5)(6.5),(0,n.l5)(1),(0,n.l5)(30),(0,n.l5)(1e3/30),(0,n.l5)(100),Symbol.dispose;const d=new class{constructor(){this._begin=performance?.now()??0,this._budget=0,this._done=!1,this._progressed=!1,this._enabled=!0}run(e){return!this.done&&(!0===e()&&this.madeProgress(),!0)}get done(){return this._done}get budget(){return this._budget}madeProgress(){return this._progressed=!0,this._done=this._enabled&&this._budget!==1/0&&this.elapsed>=this._budget,this._done}get enabled(){return this._enabled}set enabled(e){this._enabled=e}reset(e){this._begin=this.now(),this._budget=e,this.resetProgress()}get remaining(){return Math.max(this._budget-this.elapsed,0)}now(){return performance.now()}get elapsed(){return this.now()-this._begin}resetProgress(){this._progressed=!1,this._done=!1}get hasProgressed(){return this._progressed}};d.enabled=!1;class c{remove(){}[Symbol.dispose](){this.remove()}processQueue(){}schedule(e,t,i){try{if((0,r.G4)(t)){let e=(0,r.NK)();return i?Promise.resolve(i(e)):Promise.reject(e)}return(0,r.z7)(e(d))}catch(e){return Promise.reject(e)}}reschedule(e,t,i){return this.schedule(e,t,i)}async scheduleGenerator(e,t,i){if((0,r.G4)(t)){let e=(0,r.NK)();if(i)return i(e);throw e}let n=e(d);for(;;){let e=n.next(d),s=(0,r.$X)(e)?await e:e;if((0,r.G4)(t)){let e=(0,r.NK)();if(i){let t=i(e),s=n.return(null);return(0,r.$X)(s)&&await(0,r.QZ)(s),t}let t=n.throw(e);throw(0,r.$X)(t)&&await(0,r.QZ)(t),e}if(s.done)return s.value}}}const h=new c}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5077,8169,8826],{52106(e,t,i){i.d(t,{A:()=>I});var r,o,l=i(32198),s=i(40124),n=i(69540),a=i(51447),u=i(25482),p=i(53966),d=i(36708),y=i(24326),h=i(91429),c=i(12195),g=i(65864),m=i(50498),f=i(55156),v=i(60950),b=i(54339),M=i(94128),S=i(33910);const T=Symbol("meshGeometryHandles");function C(e){if(null==e)return null;let t={};for(let i in e){let r=e[i];r&&(t[i]=r.toJSON())}return 0===Object.keys(t).length?null:t}let I=class extends((0,n.OU)(u.o)){static{r=M.Z}static{o=this}constructor(e){super(e),this[r]=!0,this.distance=null,this.isAggregate=!1,this.layer=null,this.origin=null,this.sourceLayer=null,this.statisticsAggregatedIds=void 0,this._version=0,Object.defineProperty(this,"uid",{value:(0,y.c)(),configurable:!0}),Object.defineProperty(this,"_lastMeshTransform",{value:{},configurable:!0,writable:!0,enumerable:!1}),arguments.length>1&&(0,a.eF)(p.A.getLogger(this),"Graphic",{version:"4.30"})}set aggregateGeometries(e){let t=this._get("aggregateGeometries");JSON.stringify(t)!==JSON.stringify(e)&&this._set("aggregateGeometries",e)}set attributes(e){let t=this._get("attributes");t!==e&&(this._set("attributes",e),this._notifyLayer("attributes",t,e))}set geometry(e){let t=this._get("geometry");t!==e&&(this._set("geometry",e),this._watchMeshGeometryChanges(),this._notifyLayer("geometry",t,e))}set popupTemplate(e){let t=this._get("popupTemplate");t!==e&&(this._set("popupTemplate",e),this._notifyLayer("popupTemplate",t,e))}set symbol(e){let t=this._get("symbol");t!==e&&(this._set("symbol",e),this._notifyLayer("symbol",t,e))}get version(){return this._version}set visible(e){let t=this._get("visible");t!==e&&(this._set("visible",e),this._notifyLayer("visible",t,e))}cloneShallow(){return new o({aggregateGeometries:this.aggregateGeometries,statisticsAggregatedIds:this.statisticsAggregatedIds,attributes:this.attributes,geometry:this.geometry,isAggregate:this.isAggregate,layer:this.layer,popupTemplate:this.popupTemplate,sourceLayer:this.sourceLayer,symbol:this.symbol,visible:this.visible,origin:this.origin})}getEffectivePopupTemplate(e=!1){if(this.popupTemplate)return this.popupTemplate;let t=(0,v.E_)(this.origin);if(t)return t.popupTemplate??(e?t.defaultPopupTemplate:null)??null;let i=this.origin&&"layer"in this.origin?this.origin.layer:null;for(let t of[i,this.sourceLayer,this.layer])if(t&&"object"==typeof t){if("popupTemplate"in t&&t.popupTemplate)return t.popupTemplate;if(e&&"defaultPopupTemplate"in t&&null!=t.defaultPopupTemplate)return t.defaultPopupTemplate}return null}getAttribute(e){return this.attributes?.[e]}setAttribute(e,t){if(this.attributes){let i=this.getAttribute(e);this.attributes[e]=t,this._notifyLayer("attributes",i,t,e)}else this.attributes={[e]:t}}getObjectId(){let e=(0,f.I)(this.origin);if(e)return(0,b.r)(this,e);let t=this.sourceLayer??this.layer;return t?(0,b.r)(this,t):null}getGlobalId(){let e=(0,f.I)(this.origin);if(e?.globalIdField)return this.getAttribute(e.globalIdField);let t=this.sourceLayer??this.layer;return t&&"globalIdField"in t&&t.globalIdField?this.getAttribute(t.globalIdField):null}toJSON(){let e={aggregateGeometries:C(this.aggregateGeometries),geometry:this.geometry?.toJSON()??null,symbol:this.symbol?.toJSON()??null,attributes:(0,c.W)(this.attributes)?this.attributes.toJSON():{...this.attributes},popupTemplate:this.popupTemplate?.toJSON()??null};return this.statisticsAggregatedIds?.length&&(e.aggregateIds=[...this.statisticsAggregatedIds]),null!=this.distance&&(e.distance=this.distance),e}notifyMeshTransformChanged(e={}){let{geometry:t}=this;if("mesh"===t?.type){let i={origin:t.origin,transform:t.transform};this._notifyLayer("origin-transform",i,i,e.action)}}_notifyLayer(e,t,i,r){if(this._version++,!this.layer||!("graphicChanged"in this.layer))return;let o={graphic:this,property:e,oldValue:t,newValue:i};"origin-transform"===e&&(o.action=r),"attributes"===e&&(o.attributeName=r),this.layer.graphicChanged(o)}_watchMeshGeometryChanges(){this.removeHandles(T);let e=this.geometry;"mesh"===e?.type&&this.addHandles([(0,d.z7)(()=>e.vertexSpace.origin?{localMatrix:e.transform?.localMatrix,origin:e.vertexSpace.origin}:void 0,({localMatrix:e,origin:t})=>{(this._lastMeshTransform.localMatrix!==e||this._lastMeshTransform.origin!==t)&&(this._lastMeshTransform.localMatrix=e,this._lastMeshTransform.origin=t,this.notifyMeshTransformChanged())}),(0,d.z7)(()=>({vertexAttributes:e.vertexAttributes}),()=>{e.vertexSpace.origin?(this._lastMeshTransform.localMatrix=e.transform?.localMatrix,this._lastMeshTransform.origin=e.vertexSpace.origin):(this._lastMeshTransform.localMatrix=void 0,this._lastMeshTransform.origin=void 0),this._notifyLayer("geometry",e,e)},{equals:(e,t)=>e===t,sync:!0})],T)}};(0,l.Cg)([(0,h.MZ)({value:null,json:{read:function(e){if(!e)return null;let t={};for(let i in e){let r=(0,g.rS)(e[i]);r&&(t[i]=r)}return 0===Object.keys(t).length?null:t}}})],I.prototype,"aggregateGeometries",null),(0,l.Cg)([(0,h.MZ)({value:null})],I.prototype,"attributes",null),(0,l.Cg)([(0,h.MZ)({value:null,types:m.yR,json:{read:g.rS}})],I.prototype,"geometry",null),(0,l.Cg)([(0,h.MZ)()],I.prototype,"distance",void 0),(0,l.Cg)([(0,h.MZ)({type:Boolean})],I.prototype,"isAggregate",void 0),(0,l.Cg)([(0,h.MZ)({clonable:!1})],I.prototype,"layer",void 0),(0,l.Cg)([(0,h.MZ)({clonable:"reference"})],I.prototype,"origin",void 0),(0,l.Cg)([(0,h.MZ)({type:s.A,value:null})],I.prototype,"popupTemplate",null),(0,l.Cg)([(0,h.MZ)({clonable:"reference"})],I.prototype,"sourceLayer",void 0),(0,l.Cg)([(0,h.MZ)({json:{name:"aggregateIds",read:e=>e?.map(e=>Array.isArray(e)?JSON.stringify(e):e)}})],I.prototype,"statisticsAggregatedIds",void 0),(0,l.Cg)([(0,h.MZ)({value:null,types:S.Es})],I.prototype,"symbol",null),(0,l.Cg)([(0,h.MZ)({clonable:!1,json:{read:!1,write:!1}})],I.prototype,"_version",void 0),(0,l.Cg)([(0,h.MZ)({type:Boolean,value:!0})],I.prototype,"visible",null),I=o=(0,l.Cg)([(0,h.$K)("esri.Graphic")],I)},6797(e,t,i){i.d(t,{Ui:()=>y});var r=i(69622),o=i(7762),l=i(88620);const s=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function n(e){return e instanceof r.A}function a(e){return e instanceof o.A?Object.keys(e.items):n(e)?(0,l.oY)(e).keys():e?Object.keys(e):[]}function u(e,t){return e instanceof o.A?e.items[t]:e[t]}function p(e){return e?e.declaredClass:null}function d(e,t){let i=e.diff;if(i&&"function"==typeof i)return i(e,t);let r=a(e),o=a(t);if(0===r.length&&0===o.length)return;if(!r.length||!o.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};let l=o.filter(e=>!r.includes(e)),y=r.filter(e=>!o.includes(e)),h=r.filter(i=>o.includes(i)&&u(e,i)!==u(t,i)).concat(l,y).sort(),c=p(e);if(c&&s.has(c)&&h.length)return{type:"complete",oldValue:e,newValue:t};let g,m=n(e)&&n(t);for(let r of h){let o,l=u(e,r),s=u(t,r);if((m||"function"!=typeof l&&"function"!=typeof s)&&l!==s&&(null!=l||null!=s)){if(i&&i[r]&&"function"==typeof i[r])o=i[r]?.(l,s);else if(l instanceof Date&&s instanceof Date){if(l.getTime()===s.getTime())continue;o={type:"complete",oldValue:l,newValue:s}}else o="object"==typeof l&&"object"==typeof s&&p(l)===p(s)?d(l,s):{type:"complete",oldValue:l,newValue:s};null!=o&&(null==g?g={type:"partial",diff:{[r]:o}}:g.diff[r]=o)}}return g}function y(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&p(e)!==p(t)?{type:"complete",oldValue:e,newValue:t}:d(e,t)}},55156(e,t,i){i.d(t,{I:()=>o});const r=Symbol("idFieldsProviderSymbol");function o(e){return(t=e)&&r in t?e[r]:void 0;var t}i.d(t,["e",0,r])},25077(e,t,i){i.r(t),i.d(t,{default:()=>Y});var r=i(32198),o=i(40124),l=i(56507),s=i(69540),n=i(49186),a=i(36563),u=i(25728),p=i(17676),d=i(91429),y=i(16930),h=i(41910),c=i(55156),g=i(60950),m=i(89808),f=i(99959);const v=Symbol("isDimensionFeatureGraphicOrigin");var b;class M extends f.A{get[(b=v,g.ym)](){return this.layer}get[c.e](){return this.layer}get[m.Q](){return this.layer}get[h.e7](){return this.layer}constructor(e){super(),this[b]=!0,this.type="dimension-feature",this.layer=e}get id(){return this.layer.id}}var S=i(4146),T=i(52136),C=i(18768),I=i(63074),w=i(69208),A=i(40775),F=i(10086),E=i(34287),L=i(8303),Z=i(54310),O=i(23502),D=i(25036),j=i(82935),x=i(60694),_=i(10873),P=i(15426),N=i(17036),G=i(30524),z=i(91908),R=i(97552),q=i(30291),k=i(36005);const V="dimension-feature-layer",K=(0,N.p)();let J=class extends((0,O.Z)((0,A.I)((0,F.j)((0,I.dM)((0,j.e)((0,D.j)((0,Z.J)((0,C.b)((0,E.q)((0,L.A)((0,u.M)((0,w.d)((0,T.p)((0,s.OU)(S.A))))))))))))))){constructor(e){super(e),this.barrierWeight="high",this.fields=null,this.fieldsIndex=null,this.graphicOrigin=new M(this),this.operationalLayerType="ArcGISDimensionLayer",this.outFields=null,this.popupEnabled=!0,this.popupTemplate=null,this.referenceScale=0,this.source=null,this.styleCollection=null,this.sublayerTitleMode="item-title",this.supportedPortalItemTypes=["Feature Service"],this.supportedSourceTypes=new Set(["Dimension Layer"]),this.symbolFields=["STYLEID","BEGINX","BEGINY","ENDX","ENDY","DIMDISPLAY","EXTDISPLAY","MARKERDISPLAY","DIMX","DIMY","TEXTX","TEXTY","DIMLENGTH","DIMTYPE","EXTANGLE","TEXTANGLE","USECUSTOMLENGTH","CUSTOMLENGTH "],this.type="dimension-feature",this._debouncedSaveOperations=(0,p.sg)(async(e,t,r)=>{let{save:o,saveAs:l}=await i.e(5740).then(()=>i(33359));switch(e){case 0:return o(this,t);case 1:return l(this,r,t)}})}destroy(){this.source?.destroy()}load(e){let t=e?.signal,i=this.loadFromPortal({supportedTypes:this.supportedPortalItemTypes},e).catch(p.QP).then(async()=>{if(this.url&&null==this.layerId&&/FeatureServer|MapServer\/*$/i.test(this.url)){let e=await this._fetchFirstValidLayerId(t);null!=e&&(this.layerId=e)}if(!this.url)throw new n.A(`${V}:missing-url`,"DimensionFeatureLayer must be created with a url");return Promise.all([this.loadDataElement(e).then(()=>{if(!this.styleCollection)throw new n.A(`${V}:missing-style-collection`,"Invalid service with no style collection")}),this.initLayerProperties(await this.createGraphicsSource(t))])}).then(()=>(0,P.VA)(this,"load",e));return this.addResolvingPromise(i),Promise.resolve(this)}get editingEnabled(){return this._isOverridden("editingEnabled")?this._get("editingEnabled"):this.loaded&&null!=this.capabilities&&this.capabilities.operations.supportsEditing&&this.userHasEditingPrivileges}set editingEnabled(e){this._overrideIfSome("editingEnabled",e)}get effectiveEditingEnabled(){return!1}get defaultPopupTemplate(){return this.createPopupTemplate()}readTitleFromService(e,t){let{url:i}=this,r=t.name||(0,x.qg)(i)?.title;switch(this.sublayerTitleMode){case"item-title":if(i)return(0,x.yG)(i,r);break;case"item-title-and-service-name":{let e=this.portalItem?.title;if(e&&e!==r)return e=(0,x.cr)(e),r?`${e} - ${(0,x.cr)(r)}`:e;break}}return r?(0,x.cr)(r):void 0}readTitleFromPortalItem(e){return"item-title"===this.sublayerTitleMode?e:void 0}createPopupTemplate(e){return(0,q.tn)(this,e)}async createGraphicsSource(e){let t={stack:[],error:void 0,hasError:!1};try{let{default:o}=await(0,p.qr)(Promise.all([i.e(893),i.e(7),i.e(3283)]).then(()=>i(60845)),e),l=new o({layer:this,supportedSourceTypes:this.supportedSourceTypes});return(0,r.mS)(t,(0,a.Bf)((0,p.u7)(e,()=>l.cancelLoad())??(0,a.hA)()),!1),await l.load({signal:e}),l}catch(e){t.error=e,t.hasError=!0}finally{(0,r.hk)(t)}}createQuery(){let e=(0,P.VZ)(this);return e.where=this.definitionExpression||"1=1",e}getFieldDomain(e,t){return(0,P.Vq)(this,e,t,this.getField(e)?.domain??null)}async queryFeatures(e,t){let i=await this.load(),r=await i.source.queryFeatures(R.A.from(e)??i.createQuery(),t),o=this.graphicOrigin;if(r?.features)for(let e of r.features)e.layer=e.sourceLayer=i,e.origin=o;return r}async queryObjectIds(e,t){let i=await this.load();return i.source.queryObjectIds(R.A.from(e)??i.createQuery(),t)}async queryFeatureCount(e,t){let i=await this.load();return i.source.queryFeatureCount(R.A.from(e)??i.createQuery(),t)}async queryExtent(e,t){let i=await this.load();return i.source.queryExtent(R.A.from(e)??i.createQuery(),t)}async save(e){return this._debouncedSaveOperations(0,e)}async saveAs(e,t){return this._debouncedSaveOperations(1,t,e)}serviceSupportsSpatialReference(e){return this.loaded&&(0,z.D)(this,e)}async initLayerProperties(e){this._set("source",e),e.sourceJSON&&(this.sourceJSON=e.sourceJSON,this.read(e.sourceJSON,{origin:"service",portalItem:this.portalItem,portal:this.portalItem?.portal,url:this.parsedUrl})),this._verifySource(),(0,G.sv)(this.timeInfo,this.fieldsIndex)}async reloadFromService(e){let t=this.source;await Promise.all([t.reload({signal:e}),this.loadDataElement({signal:e})]),await this.initLayerProperties(t)}async hasDataChanged(){return(0,P.jp)(this)}_verifySource(){if(this.version&&this.version<10.8)throw new n.A(V+":unsupported-version","The feature service must be version 10.8 or above.");let e=["DIMLENGTH","BEGINX","BEGINY","ENDX","ENDY","DIMX","DIMY","TEXTX","TEXTY","DIMTYPE","EXTANGLE","STYLEID","USECUSTOMLENGTH","CUSTOMLENGTH","DIMDISPLAY","EXTDISPLAY","MARKERDISPLAY","TEXTANGLE"],t=e.filter(e=>!this.fieldsIndex.has(e));if(t.length)throw new n.A(V+":missing-fields","There are missing fields to operate properly",{requiredFields:e,missingFields:t})}_fetchFirstValidLayerId(e){return(0,l.A)(this.url??"",{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:e}).then(e=>{let t=e.data;return t?(this.applyPreferredHost(t),[...t.layers||[],...t.tables||[]].find(({type:e})=>!e||this.supportedSourceTypes.has(e))?.id):void 0})}};(0,r.Cg)([(0,d.MZ)({type:y.A,json:{origins:{service:{read:{source:"sourceSpatialReference"}}}}})],J.prototype,"attributeSpatialReference",void 0),(0,r.Cg)([(0,d.MZ)(_.es)],J.prototype,"barrierWeight",void 0),(0,r.Cg)([(0,d.MZ)({nonNullable:!0,json:{name:"enableEditing",write:!0}})],J.prototype,"editingEnabled",null),(0,r.Cg)([(0,d.MZ)({readOnly:!0})],J.prototype,"effectiveEditingEnabled",null),(0,r.Cg)([(0,d.MZ)({...K.fields,readOnly:!0,json:{read:!1,origins:{service:{read:!0}}}})],J.prototype,"fields",void 0),(0,r.Cg)([(0,d.MZ)(K.fieldsIndex)],J.prototype,"fieldsIndex",void 0),(0,r.Cg)([(0,d.MZ)({readOnly:!0,clonable:!1})],J.prototype,"graphicOrigin",void 0),(0,r.Cg)([(0,d.MZ)(_.id)],J.prototype,"id",void 0),(0,r.Cg)([(0,d.MZ)({type:["show","hide"],json:{origins:{"portal-item":{read:!1,write:!1}}}})],J.prototype,"listMode",void 0),(0,r.Cg)([(0,d.MZ)({type:["ArcGISDimensionLayer"],json:{origins:{"portal-item":{name:"layerType",write:{enabled:!0,ignoreOrigin:!0,isRequired:!0}}}}})],J.prototype,"operationalLayerType",void 0),(0,r.Cg)([(0,d.MZ)(K.outFields)],J.prototype,"outFields",void 0),(0,r.Cg)([(0,d.MZ)(_.M6)],J.prototype,"popupEnabled",void 0),(0,r.Cg)([(0,d.MZ)({type:o.A,json:{name:"popupInfo",write:!0}})],J.prototype,"popupTemplate",void 0),(0,r.Cg)([(0,d.MZ)({readOnly:!0})],J.prototype,"defaultPopupTemplate",null),(0,r.Cg)([(0,d.MZ)({readOnly:!0})],J.prototype,"referenceScale",void 0),(0,r.Cg)([(0,d.MZ)({clonable:!1,readOnly:!0})],J.prototype,"source",void 0),(0,r.Cg)([(0,d.MZ)()],J.prototype,"styleCollection",void 0),(0,r.Cg)([(0,d.MZ)({type:String})],J.prototype,"sublayerTitleMode",void 0),(0,r.Cg)([(0,d.MZ)({readOnly:!0})],J.prototype,"symbolFields",void 0),(0,r.Cg)([(0,k.w)("service","title",["name"])],J.prototype,"readTitleFromService",null),(0,r.Cg)([(0,k.w)("portal-item","title")],J.prototype,"readTitleFromPortalItem",null),(0,r.Cg)([(0,d.MZ)({json:{read:!1},value:"dimension-feature",readOnly:!0})],J.prototype,"type",void 0),J=(0,r.Cg)([(0,d.$K)("esri.layers.DimensionFeatureLayer")],J);const Y=J},54339(e,t,i){function r(e,t){switch(t.type){case"object-id":case"unique-id-simple":return e.attributes[t.fieldName];case"unique-id-composite":{let i=[];for(let r of t.fieldNames)i.push(e.attributes[r]??null);return JSON.stringify(i)}}}function o(e,t){if("uniqueIdFields"in t&&t.uniqueIdFields?.length){if(1===t.uniqueIdFields.length)return e.attributes?.[t.uniqueIdFields[0]];let i=t.uniqueIdFields.map(t=>e.attributes?.[t]);return JSON.stringify(i)}return"objectIdField"in t&&t.objectIdField?e.attributes?.[t.objectIdField]:null}i.d(t,{W:()=>r,r:()=>o})},52136(e,t,i){var r=i(32198),o=i(91429);i.d(t,["p",0,e=>{let t=e,i=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._clearOverride("apiKey"),this.clear("apiKey","user")):this._override("apiKey",e)}};return(0,r.Cg)([(0,o.MZ)({type:String})],i.prototype,"apiKey",null),i=(0,r.Cg)([(0,o.$K)("esri.layers.mixins.APIKeyMixin")],i),i}])},40775(e,t,i){var r=i(32198),o=i(56507),l=i(49186),s=i(84952),n=i(91429),a=i(95250);function u(e,t){let i=e.indexOf(t);return-1===i?void 0:e[i+1]}function p(e,t){let i=u(e,t);return i&&"string"==typeof i?JSON.parse(i):null}function d(e){let t=u(e,"ReferenceScale")??0;return"string"==typeof t?parseFloat(t):t}function y(e){return p(e,"SymbolCollection")??void 0}function h(e){return p(e,"StyleCollection")??void 0}i.d(t,["I",0,e=>{let t=e,i=class extends t{async loadDataElement(e){if(!this.url||null==this.layerId)throw new l.A("fetchDataElement:missing-url-or-layerId","The layer must have a url and a layerId to fetch the data element.");let t=(0,s.fj)(this.url,"queryDataElements"),i={f:"json",layers:this.layerId},{data:r}=await(0,o.A)(t,{...e,responseType:"json",query:i}),n=r.layerDataElements.find(e=>e.layerId===this.layerId)?.dataElement;if(!n)throw new l.A("fetchDataElement:not-available","A data element for this layer could not be retrieved.");let u=n.extensionProperties?.propertySetItems??[],p=d(u),c=(0,a.S)(y(u)),g=(0,a.S)(h(u));this.read({referenceScale:p,symbolCollection:c,styleCollection:g},{origin:"service"})}};return i=(0,r.Cg)([(0,n.$K)("esri.layers.mixins.DataElementMixin")],i),i}])},28032(e,t,i){i.d(t,{A:()=>a});var r=i(32198),o=i(69540),l=i(25482),s=i(91429),n=i(56400);let a=class extends((0,o.OU)(l.o)){constructor(e){super(e),this.creatorField=null,this.creationDateField=null,this.editorField=null,this.editDateField=null,this.realm=null,this.timeZone=null}};(0,r.Cg)([(0,s.MZ)()],a.prototype,"creatorField",void 0),(0,r.Cg)([(0,s.MZ)()],a.prototype,"creationDateField",void 0),(0,r.Cg)([(0,s.MZ)()],a.prototype,"editorField",void 0),(0,r.Cg)([(0,s.MZ)()],a.prototype,"editDateField",void 0),(0,r.Cg)([(0,s.MZ)()],a.prototype,"realm",void 0),(0,r.Cg)([(0,s.MZ)((0,n.P6)("dateFieldsTimeReference",!0))],a.prototype,"timeZone",void 0),a=(0,r.Cg)([(0,s.$K)("esri.layers.support.EditFieldsInfo")],a)},37352(e,t,i){i.d(t,{A:()=>a});var r,o=i(32198),l=i(7762),s=i(25482),n=i(91429);let a=r=class extends s.o{constructor(e){super(e),this.floorField=null,this.viewAllMode=!1,this.viewAllLevelIds=new l.A}clone(){return new r({floorField:this.floorField,viewAllMode:this.viewAllMode,viewAllLevelIds:this.viewAllLevelIds})}};(0,o.Cg)([(0,n.MZ)({type:String,json:{write:{isRequired:!0}}})],a.prototype,"floorField",void 0),(0,o.Cg)([(0,n.MZ)({json:{read:!1,write:!1}})],a.prototype,"viewAllMode",void 0),(0,o.Cg)([(0,n.MZ)({json:{read:!1,write:!1}})],a.prototype,"viewAllLevelIds",void 0),a=r=(0,o.Cg)([(0,n.$K)("esri.layers.support.LayerFloorInfo")],a)},45067(e,t,i){i.d(t,{A:()=>p});var r=i(32198),o=i(69540),l=i(66552),s=i(25482),n=i(91429);const a=new l.J({esriRelCardinalityOneToOne:"one-to-one",esriRelCardinalityOneToMany:"one-to-many",esriRelCardinalityManyToMany:"many-to-many"}),u=new l.J({esriRelRoleOrigin:"origin",esriRelRoleDestination:"destination"});let p=class extends((0,o.OU)(s.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,r.Cg)([(0,n.MZ)({json:{read:a.read,write:a.write}})],p.prototype,"cardinality",void 0),(0,r.Cg)([(0,n.MZ)({json:{name:"catalogID"}})],p.prototype,"catalogId",void 0),(0,r.Cg)([(0,n.MZ)({json:{read:!0,write:!0}})],p.prototype,"composite",void 0),(0,r.Cg)([(0,n.MZ)({json:{read:!0,write:!0}})],p.prototype,"id",void 0),(0,r.Cg)([(0,n.MZ)({json:{read:!0,write:!0}})],p.prototype,"keyField",void 0),(0,r.Cg)([(0,n.MZ)({json:{read:!0,write:!0}})],p.prototype,"keyFieldInRelationshipTable",void 0),(0,r.Cg)([(0,n.MZ)({json:{read:!0,write:!0}})],p.prototype,"name",void 0),(0,r.Cg)([(0,n.MZ)({json:{read:!0,write:!0}})],p.prototype,"relatedTableId",void 0),(0,r.Cg)([(0,n.MZ)({json:{read:!0,write:!0}})],p.prototype,"relationshipTableId",void 0),(0,r.Cg)([(0,n.MZ)({json:{read:u.read,write:u.write}})],p.prototype,"role",void 0),p=(0,r.Cg)([(0,n.$K)("esri.layers.support.Relationship")],p)},41366(e,t,i){var r=i(32198),o=i(66552),l=i(53966),s=i(91429),n=i(93223);const a=(0,o.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),u="percent-of-total",p="field";i.d(t,["K",0,e=>{let t=e,i=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"),t=!!this.normalizationField,i=null!=this.normalizationTotal;return t||i?(e=t&&p||i&&u||null,t&&i&&l.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):(e===p||e===u)&&(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,r.Cg)([(0,s.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],i.prototype,"normalizationField",void 0),(0,r.Cg)([(0,s.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],i.prototype,"normalizationMaxValue",void 0),(0,r.Cg)([(0,s.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],i.prototype,"normalizationMinValue",void 0),(0,r.Cg)([(0,s.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],i.prototype,"normalizationTotal",void 0),(0,r.Cg)([(0,n.e)(a,{name:"parameters.normalizationType"})],i.prototype,"normalizationType",null),i=(0,r.Cg)([(0,s.$K)("esri.rest.support.NormalizationBinParametersMixin")],i),i},"Q",0,a])},95250(e,t,i){function r(e){return o(e,{CIMRGBColor:l,CIMCharacterMarker:s})}function o(e,t){if(null==e)return e;if(Array.isArray(e))return e.map(e=>o(e,t));if("object"==typeof e){if("type"in e&&"string"==typeof e.type&&t[e.type])return t[e.type](e);let i={};for(let[r,l]of Object.entries(e))i[r]=o(l,t);return i}return e}function l(e){let[t,i,r,o]=e.values;return[t,i,r,255*o/100]}function s(){return{type:"CIMVectorMarker",enable:!0,size:40,colorLocked:!1,anchorPointUnits:"Relative",frame:{xmin:-10,ymin:-10,xmax:10,ymax:10},markerGraphics:[{type:"CIMMarkerGraphic",textString:"■",geometry:{x:0,y:0},symbol:{type:"CIMTextSymbol",underline:!1,blockProgression:"TTB",depth3D:0,extrapolateBaselines:!0,flipAngle:90,fontEffects:"Normal",fontEncoding:"Unicode",haloSize:0,height:8,hinting:"Default",horizontalAlignment:"Center",kerning:!0,letterSpacing:10,letterWidth:100,ligatures:!1,lineGapType:"ExtraLeading",symbol:{type:"CIMPolygonSymbol",symbolLayers:[{type:"CIMSolidFill",enable:!0,color:[0,0,0,255]}]},symbol3DProperties:{type:"CIM3DSymbolProperties",dominantSizeAxis3D:"Z",rotationOrder3D:"XYZ",scaleZ:1,scaleY:1},textCase:"Normal",textDirection:"LTR",verticalAlignment:"Center",verticalGlyphOrientation:"Right",wordSpacing:100,billboardMode3D:"FaceNearPlane"}}],scaleSymbolsProportionally:!0,respectFrame:!0}}i.d(t,{S:()=>r})},93470(e,t,i){const r=[252,146,31,255],o={type:"esriSMS",style:"esriSMSCircle",size:6,color:r,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},l={type:"esriSLS",style:"esriSLSSolid",width:.75,color:r};i.d(t,["Cb",0,o,"HW",0,{type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},"JR",0,[153,153,153,255],"JZ",0,{type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},"WR",0,{type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},"b6",0,{type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null},"fT",0,r,"nC",0,{type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},"yM",0,l])}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1560,4506,8747],{46140(e,t,r){r.d(t,{A:()=>o});var i=r(49186);class o{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}toString(){return`${this.major}.${this.minor}`}validate(e){if(this.major!==e.major){let 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 o(this.major,this.minor,this._context)}static parse(e,t=""){let[r,n]=e.split("."),s=/^\s*\d+\s*$/;if(!r?.match||!s.test(r)){let r=t&&t+":";throw new i.A(r+"invalid-version","Expected major version to be a number, but got '${version}'",{version:e})}if(!n?.match||!s.test(n)){let r=t&&t+":";throw new i.A(r+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:e})}return new o(parseInt(r,10),parseInt(n,10),t)}}},9352(e,t,r){r.r(t),r.d(t,{default:()=>H});var i=r(32198),o=r(49186),n=r(93637),s=r(91429),l=r(16930),a=r(41910),p=r(55156),u=r(60950),d=r(89808),c=r(99959);const y=Symbol("isOrientedImageryGraphicOrigin");var g;class f extends c.A{get[(g=y,u.ym)](){return this.layer}get[p.e](){return this.layer}get[d.Q](){return this.layer}get[a.e7](){return this.layer}constructor(e){super(),this[g]=!0,this.type="oriented-imagery",this.layer=e}get id(){return this.layer.id}}var m=r(18589),h=r(66552),v=(r(86211),r(28735),r(69540)),w=r(25482),C=r(69622),b=r(21325);let M=class extends C.A{set horizontalWKID(e){e?(0,b.fn)({wkid:+e})?this._set("horizontalWKID",+e):this._set("horizontalWKID",e):this._set("horizontalWKID",null)}set verticalWKID(e){e?this._set("verticalWKID",isFinite(e)&&(0,b.fn)({wkid:+e})?+e:null):this._set("verticalWKID",null)}get isAdvanced(){let{affineTransformations:e,focalLength:t,principalOffsetPoint:r,radialDistortionCoefficients:i,tangentialDistortionCoefficients:o}=this;return e?.length>1&&!Number.isNaN(t)&&r?.length>1&&i?.length>1&&o?.length>1}};(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"affineTransformations",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"focalLength",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"principalOffsetPoint",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"radialDistortionCoefficients",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"tangentialDistortionCoefficients",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"horizontalWKID",null),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"verticalWKID",null),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"x",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"y",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"z",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],M.prototype,"type",void 0),M=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.CameraOrientation")],M);const x=M;let S=class extends((0,v.OU)((0,w.T)(x))){constructor(){super(...arguments),this.type=1}toString(){let{type:e,horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,heading:s,pitch:l,roll:a,affineTransformations:p,focalLength:u,principalOffsetPoint:d,radialDistortionCoefficients:c,tangentialDistortionCoefficients:y}=this,g=[e,t,r,i,o,n,s,l,a];return this.isAdvanced&&(p?.forEach(e=>g.push(e)),g.push(u),d?.forEach(e=>g.push(e)),c?.forEach(e=>g.push(e)),y?.forEach(e=>g.push(e))),g.map(e=>Number.isNaN(e)?"":e).join("|")}};(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],S.prototype,"type",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],S.prototype,"affineTransformations",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],S.prototype,"focalLength",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],S.prototype,"principalOffsetPoint",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],S.prototype,"radialDistortionCoefficients",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],S.prototype,"tangentialDistortionCoefficients",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],S.prototype,"heading",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],S.prototype,"pitch",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],S.prototype,"roll",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],S.prototype,"x",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],S.prototype,"y",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],S.prototype,"z",void 0),S=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.CameraOrientationHPR")],S);const j=S;let Z=class extends((0,v.OU)((0,w.T)(x))){constructor(){super(...arguments),this.type=4}toString(){let{type:e,latitude:t,longitude:r,ellipsoidRadius:i,squaredEccentricity:o,properties:n}=this,s=`${n}`.split("|");return s.splice(1,1),`${e}|${t}|${r}|${i}|${o}|${s.join("|")}`}};(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],Z.prototype,"type",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0},type:Number})],Z.prototype,"latitude",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0},type:Number})],Z.prototype,"longitude",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0},type:Number})],Z.prototype,"ellipsoidRadius",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0},type:Number})],Z.prototype,"squaredEccentricity",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],Z.prototype,"properties",void 0),Z=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.CameraOrientationLTP")],Z);const P=Z;let O=class extends((0,v.OU)((0,w.T)(x))){constructor(){super(...arguments),this.type=2}toString(){let{type:e,horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,omega:s,phi:l,kappa:a,affineTransformations:p,focalLength:u,principalOffsetPoint:d,radialDistortionCoefficients:c,tangentialDistortionCoefficients:y}=this,g=[e,t,r,i,o,n,s,l,a];return this.isAdvanced&&(p?.forEach(e=>g.push(e)),g.push(u),d?.forEach(e=>g.push(e)),c?.forEach(e=>g.push(e)),y?.forEach(e=>g.push(e))),g.map(e=>isNaN(e)?"":e).join("|")}};(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],O.prototype,"type",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],O.prototype,"affineTransformations",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],O.prototype,"focalLength",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],O.prototype,"principalOffsetPoint",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],O.prototype,"radialDistortionCoefficients",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],O.prototype,"tangentialDistortionCoefficients",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],O.prototype,"omega",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],O.prototype,"phi",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],O.prototype,"kappa",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],O.prototype,"x",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],O.prototype,"y",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],O.prototype,"z",void 0),O=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.CameraOrientationOPK")],O);const I=O;let N=class extends((0,v.OU)((0,w.T)(x))){constructor(){super(...arguments),this.type=3}get isAdvanced(){let{affineTransformations:e,focalLength:t,principalOffsetPoint:r,radialDistortionCoefficients:i,tangentialDistortionCoefficients:o}=this;return e?.length>1||!Number.isNaN(t)||r?.length>1||i?.length>1||o?.length>1}toString(){let{type:e,horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,yaw:s,pitch:l,roll:a,affineTransformations:p,focalLength:u,principalOffsetPoint:d,radialDistortionCoefficients:c,tangentialDistortionCoefficients:y}=this,g=[e,t,r,i,o,n,s,l,a];return this.isAdvanced&&(p?.forEach(e=>g.push(e)),g.push(u),d?.forEach(e=>g.push(e)),d?.forEach(e=>g.push(e)),c?.forEach(e=>g.push(e)),y?.forEach(e=>g.push(e))),g.map(e=>Number.isNaN(e)?"":e).join("|")}};(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],N.prototype,"type",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],N.prototype,"affineTransformations",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],N.prototype,"focalLength",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],N.prototype,"principalOffsetPoint",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],N.prototype,"radialDistortionCoefficients",void 0),(0,i.Cg)([(0,s.MZ)({type:[Number],json:{write:!0}})],N.prototype,"tangentialDistortionCoefficients",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],N.prototype,"yaw",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],N.prototype,"pitch",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],N.prototype,"roll",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],N.prototype,"x",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],N.prototype,"y",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],N.prototype,"z",void 0),N=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.CameraOrientationYPR")],N);const E=N,L=new Map;L.set("2",{desc:"Using Omega Phi Kappa",constructor:I}),L.set("1",{desc:"Using Heading, Pitch and Roll",constructor:j}),L.set("3",{desc:"Using Yaw, Pitch and Roll",constructor:E}),L.set("4",{desc:"Using Local Tangent Plane",constructor:P});let A=class extends((0,v.OU)(w.o)){constructor(){super(...arguments),this.url=null}};(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],A.prototype,"lod",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],A.prototype,"rasterFunction",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],A.prototype,"url",void 0),A=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.ElevationSourceDefinitions.ElevationSource")],A);let D=class extends((0,v.OU)(w.o)){constructor(e){super(e),this.constantElevation=null}};(0,i.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],D.prototype,"constantElevation",void 0),D=(0,i.Cg)([(0,s.$K)("esri.layers.orientedImagery.core.ElevationSourceDefinitions.ConstantElevation")],D);const T=new h.J({Minutes:"minutes",Hours:"hours",Days:"days",Weeks:"weeks",Months:"months",Years:"years"}),F=new h.J({Feet:"feet",Meter:"meter"}),R=new h.J({360:"360",Horizontal:"horizontal",Inspection:"inspection",Nadir:"nadir",Oblique:"oblique",Terrestrial360Video:"terrestrial-360-video",TerrestrialFrameVideo:"terrestrial-frame-video",Aerial360Video:"aerial-360-video",AerialFrameVideo:"aerial-frame-video","":null}),z=new Map;z.set("1",function(e){let[t,r,i,o,n,s,l,a,p,u,d,c,y,g,f,m,h,v,w,C,b,M]=e.slice(1);return{horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,heading:s,pitch:l,roll:a,...K([p,u,d,c,y,g],[m,h],[v,w,C],[b,M],f)}}),z.set("3",function(e){let[t,r,i,o,n,s,l,a,p,u,d,c,y,g,f,m,h,v,w,C,b,M]=e.slice(1);return{horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,yaw:s,pitch:l,roll:a,...K([p,u,d,c,y,g],[m,h],[v,w,C],[b,M],f)}}),z.set("2",function(e){let[t,r,i,o,n,s,l,a,p,u,d,c,y,g,f,m,h,v,w,C,b,M]=e.slice(1);return{horizontalWKID:t,verticalWKID:r,x:i,y:o,z:n,omega:s,phi:l,kappa:a,...K([p,u,d,c,y,g],[m,h],[v,w,C],[b,M],f)}}),z.set("4",function(e){let[t,r,i,o,n,...s]=e.slice(1),l=z.get(n),a=L.get(n)?.constructor;return l&&a?{latitude:t,longitude:r,ellipsoidRadius:i,squaredEccentricity:o,properties:new a(l([n,"",...s]))}:null});const $=e=>{let t=e.map(e=>parseFloat(e)).filter(e=>!isNaN(e));if(t.length===e.length)return t};function K(e,t,r,i,o){let n=$(e),s=$(t),l=$(r),a=$(i);return{affineTransformations:6===n?.length?n:void 0,focalLength:6===n?.length?parseFloat(o):void 0,principalOffsetPoint:2===s?.length?s:[0,0],radialDistortionCoefficients:3===l?.length?l:[0,0,0],tangentialDistortionCoefficients:2===a?.length?a:[0,0]}}var _=r(20437),q=r(43440),G=r(79677);const U=new Set(["demPathPrefix","demPathSuffix","depthImagePathPrefix","depthImagePathSuffix","elevationSource","horizontalMeasurementUnit","imageGeometryField","imageReferenceField","referenceIDField","sequenceOrderField","sequenceOrderFields","verticalMeasurementUnit","videoPathPrefix","videoPathSuffix","timeAnimation","visibilityTimeExtent"]),B=new Set(["elevationSource"]),W=(e,t)=>!U.has(t)&&e;function V(e,t,r,i){let{name:o,write:n,read:s}=((e,t,r)=>{let i=`orientedImageryProperties.${e}`,o={allowNull:B.has(e),ignoreOrigin:!0};return{name:i,write:t?{...o,target:i,writer:t}:o,read:r?{ignoreOrigin:!0,source:i,reader:r}:{ignoreOrigin:!0}}})(e,t,r),l={name:o,write:n,read:s,origins:{service:{name:`orientedImageryInfo.${o}`,write:t,read:r},"web-scene":{name:o,write:W(n,e),read:W(s,e)},"web-map":{name:o,write:n,read:s}}};return!i||!l.origins||(l.type=i,l.origins["web-map"].type=i,l.origins["web-scene"].type=i),l}let J=class extends m.default{constructor(e){super(e),this.attributeTableTemplate=null,this.cameraHeading=null,this.cameraHeight=null,this.cameraPitch=null,this.cameraRoll=null,this.coveragePercent=null,this.demPathPrefix=null,this.demPathSuffix=null,this.depthImagePathPrefix=null,this.depthImagePathSuffix=null,this.elevationSource=null,this.farDistance=null,this.geometryType="point",this.graphicOrigin=new f(this),this.horizontalFieldOfView=null,this.horizontalMeasurementUnit=null,this.imageGeometryField="ImageGeometry",this.imagePathPrefix=null,this.imagePathSuffix=null,this.imageReferenceField="OIObjectID",this.imageRotation=null,this.maximumDistance=null,this.nearDistance=null,this.operationalLayerType="OrientedImageryLayer",this.orientationAccuracy=null,this.orientedImageryType=null,this.referenceIDField="OBJECTID",this.sequenceOrderField="SequenceOrder",this.sequenceOrderFields=[],this.subtypeField=null,this.subtypes=null,this.supportedSourceTypes=new Set(["Oriented Imagery Layer"]),this.type="oriented-imagery",this.timeIntervalUnit="days",this.verticalFieldOfView=null,this.verticalMeasurementUnit=null,this.verticalSearchRange=null,this.videoPathPrefix=null,this.videoPathSuffix=null,this.virtualCacheDirectory=null,this.dataStoreID=null,this.imageAccessPaths=null,this.visibilityTimeExtent=null}get effectiveElevationSource(){let{elevationSource:e,demPathPrefix:t,demPathSuffix:r}=this;return function(e,t,r){return e&&((e=>null!=e&&"number"==typeof e.constantElevation)(e)?new D(e):function(e,t,r){let{url:i}=e;return i?(i=function(e,t,r){return t&&(e=`${t}${e}`),r&&(e+=`${r}`),e}(i,t,r),new A({...e,url:i})):null}(e,t,r))}(e,t,r)}get effectiveSequenceOrderField(){let{sequenceOrderField:e,fields:t,sequenceOrderFields:r}=this;return function(e,t,r){let i=function(e,t){return e?.length?e.map(({field:e,order:r})=>{let i=t.find(t=>t.name.toLowerCase()===e.toLowerCase());return i?{fieldName:i.name,sortOrder:"desc"===r?.toLowerCase()?"desc":"asc"}:null}).filter(e=>null!=e):null}(r,t);if(i?.length)return i;if(!e){let e=t.find(e=>e.name.toLocaleLowerCase()==="sequenceorder".toLocaleLowerCase());return e?[{fieldName:e.name,sortOrder:"asc"}]:null}let o=t.find(t=>t.name.toLowerCase()===e.trim().toLowerCase());return o?[{fieldName:o.name,sortOrder:"asc"}]:null}(e,t,r)}get fieldConfigurations(){return super.fieldConfigurations}set fieldConfigurations(e){super.fieldConfigurations=e}get portalItem(){return super.portalItem}set portalItem(e){super.portalItem=e}async save(e){return this._debouncedSaveOperations(0,e)}async saveAs(e,t){return this._debouncedSaveOperations(1,t,e)}findFirstValidLayerId(e){return e.layers?.find(({type:e})=>!!e&&this.supportedSourceTypes.has(e))?.id}_verifySource(){if(super._verifySource(),"point"!==this.geometryType)throw new o.A("oriented-imagery-layer:invalid-geometry-type","OrientedImageryLayer only supports point geometry type")}};(0,i.Cg)([(0,s.MZ)({type:q.A,json:{write:!1,read:!1}})],J.prototype,"attributeTableTemplate",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("cameraHeading")})],J.prototype,"cameraHeading",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("cameraHeight")})],J.prototype,"cameraHeight",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("cameraPitch")})],J.prototype,"cameraPitch",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("cameraRoll")})],J.prototype,"cameraRoll",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("coveragePercent")})],J.prototype,"coveragePercent",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("demPathPrefix")})],J.prototype,"demPathPrefix",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("demPathSuffix")})],J.prototype,"demPathSuffix",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("depthImagePathPrefix")})],J.prototype,"depthImagePathPrefix",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("depthImagePathSuffix")})],J.prototype,"depthImagePathSuffix",void 0),(0,i.Cg)([(0,s.MZ)({type:Object,json:V("elevationSource")})],J.prototype,"elevationSource",void 0),(0,i.Cg)([(0,s.MZ)({readOnly:!0})],J.prototype,"effectiveElevationSource",null),(0,i.Cg)([(0,s.MZ)({readOnly:!0})],J.prototype,"effectiveSequenceOrderField",null),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("farDistance")})],J.prototype,"farDistance",void 0),(0,i.Cg)([(0,s.MZ)({type:[_.A]})],J.prototype,"fields",void 0),(0,i.Cg)([(0,s.MZ)()],J.prototype,"geometryType",void 0),(0,i.Cg)([(0,s.MZ)({readOnly:!0,clonable:!1})],J.prototype,"graphicOrigin",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("horizontalFieldOfView")})],J.prototype,"horizontalFieldOfView",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("horizontalMeasurementUnit")})],J.prototype,"horizontalMeasurementUnit",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{...V("imageGeometryField"),default:"ImageGeometry"}})],J.prototype,"imageGeometryField",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("imagePathPrefix")})],J.prototype,"imagePathPrefix",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("imagePathSuffix")})],J.prototype,"imagePathSuffix",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{...V("imageReferenceField"),default:"OIObjectID"}})],J.prototype,"imageReferenceField",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("imageRotation")})],J.prototype,"imageRotation",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("maximumDistance")})],J.prototype,"maximumDistance",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("nearDistance")})],J.prototype,"nearDistance",void 0),(0,i.Cg)([(0,s.MZ)({type:["OrientedImageryLayer"],json:{origins:{"portal-item":{name:"layerType",write:{enabled:!0,ignoreOrigin:!0}}}}})],J.prototype,"operationalLayerType",void 0),(0,i.Cg)([(0,s.MZ)({json:{...V("orientationAccuracy",(e,t,r)=>{(0,n.sM)(r,e.join(";"),t)},e=>function(e){if("string"!=typeof e)return null;let t=e.split(";");return t.some(e=>!/^[+-]?(?:\d+(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+)?$/.test(e.trim()))?null:function(e){return function(e){if(!Array.isArray(e)||e.length<=5)return!1;for(let t of e)if("number"!=typeof t||!Number.isFinite(t)||t<0)return!1;return!0}(e)?function(e){for(e=e.slice(0,8);e.length<8;)e.push(0);return e}(e):null}(t.map(e=>Number(e.trim())))}(e)??[0,0,0,0,0,0,0,0],String)}})],J.prototype,"orientationAccuracy",void 0),(0,i.Cg)([(0,s.MZ)({json:{...V("orientedImageryType",R.write,R.read,R.jsonValues.slice(1))}})],J.prototype,"orientedImageryType",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{...V("referenceIDField"),default:"OBJECTID"}})],J.prototype,"referenceIDField",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{...V("sequenceOrderField"),default:"SequenceOrder"}})],J.prototype,"sequenceOrderField",void 0),(0,i.Cg)([(0,s.MZ)({json:{...V("sequenceOrderFields",function(e,t,r){e?.length&&(0,n.sM)(r,e,t)}),default:[]}})],J.prototype,"sequenceOrderFields",void 0),(0,i.Cg)([(0,s.MZ)({type:l.A})],J.prototype,"spatialReference",void 0),(0,i.Cg)([(0,s.MZ)({readOnly:!0})],J.prototype,"subtypeField",void 0),(0,i.Cg)([(0,s.MZ)({readOnly:!0})],J.prototype,"subtypes",void 0),(0,i.Cg)([(0,s.MZ)({json:{read:!1},value:"oriented-imagery",readOnly:!0})],J.prototype,"type",void 0),(0,i.Cg)([(0,s.MZ)({type:T.apiValues,json:{...V("timeIntervalUnit",T.write,T.read,T.jsonValues)}})],J.prototype,"timeIntervalUnit",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("verticalFieldOfView")})],J.prototype,"verticalFieldOfView",void 0),(0,i.Cg)([(0,s.MZ)({type:F.apiValues,json:{...V("verticalMeasurementUnit",F.write,F.read,F.jsonValues)}})],J.prototype,"verticalMeasurementUnit",void 0),(0,i.Cg)([(0,s.MZ)({type:Number,json:V("verticalSearchRange")})],J.prototype,"verticalSearchRange",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("videoPathPrefix")})],J.prototype,"videoPathPrefix",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:V("videoPathSuffix")})],J.prototype,"videoPathSuffix",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.orientedImageryProperties.virtualCacheDirectory",read:!0}}}})],J.prototype,"virtualCacheDirectory",void 0),(0,i.Cg)([(0,s.MZ)({type:String,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.dsid",read:!0}}}})],J.prototype,"dataStoreID",void 0),(0,i.Cg)([(0,s.MZ)({type:Object,readOnly:!0,json:{read:!1,write:!1,origins:{service:{name:"orientedImageryInfo.imageAccessPaths",read:!0}}}})],J.prototype,"imageAccessPaths",void 0),(0,i.Cg)([(0,s.MZ)({type:G.A,json:{origins:{"web-scene":{write:!1,read:!1}}}})],J.prototype,"visibilityTimeExtent",void 0),J=(0,i.Cg)([(0,s.$K)("esri.layers.OrientedImageryLayer")],J);const H=J},32756(e,t,r){r.d(t,{Rr:()=>l});var i=r(32198),o=r(93637),n=r(91429),s=r(91880);function l(e,t,r){if(!e)return null;let i=e.find(e=>!!e.field);if(!i)return null;let o=new s.A;return o.read(i,r),[o]}const a={type:[s.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:l},write:{writer:function(e,t,r,i){let n=e.find(e=>!!e.field);n&&(0,o.sM)(r,[n.toJSON()],t)}}}};r.d(t,["fY",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,i.Cg)([(0,n.MZ)(a)],r.prototype,"orderBy",void 0),r=(0,i.Cg)([(0,n.$K)("esri.layers.mixins.OrderedLayer")],r),r},"ne",0,a])},29005(e,t,r){r.d(t,{A:()=>p});var i=r(32198),o=r(69540),n=r(66552),s=r(25482),l=r(91429);const a=new n.J({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let p=class extends((0,o.OU)(s.o)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,i.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"name",void 0),(0,i.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"description",void 0),(0,i.Cg)([(0,l.MZ)({json:{read:a.read,write:a.write}})],p.prototype,"drawingTool",void 0),(0,i.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"prototype",void 0),(0,i.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"thumbnail",void 0),p=(0,i.Cg)([(0,l.$K)("esri.layers.support.FeatureTemplate")],p)},33143(e,t,r){r.d(t,{A:()=>d});var i=r(32198),o=r(69540),n=r(25482),s=r(91429),l=r(8631),a=r(29005),p=r(36005),u=r(43937);let d=class extends((0,o.OU)(n.o)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){let t={};for(let r of Object.keys(e))t[r]=(0,l.r)(e[r]);return t}writeDomains(e,t){let r={};for(let t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],d.prototype,"id",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],d.prototype,"name",void 0),(0,i.Cg)([(0,s.MZ)({json:{write:!0}})],d.prototype,"domains",void 0),(0,i.Cg)([(0,p.w)("domains")],d.prototype,"readDomains",null),(0,i.Cg)([(0,u.K)("domains")],d.prototype,"writeDomains",null),(0,i.Cg)([(0,s.MZ)({type:[a.A],json:{write:!0}})],d.prototype,"templates",void 0),d=(0,i.Cg)([(0,s.$K)("esri.layers.support.FeatureType")],d)},46499(e,t,r){var i,o,n=r(32198),s=(r(44208),r(66552)),l=r(25482),a=r(4718),p=r(90629),u=r(91429),d=r(90360),c=r(73913),y=r(32730),g=r(77548),f=r(59868),m=r(73838),h=r(33910),v=r(36005),w=r(43937);const C=new s.J({esriServerPointLabelPlacementAboveCenter:"above-center",esriServerPointLabelPlacementAboveLeft:"above-left",esriServerPointLabelPlacementAboveRight:"above-right",esriServerPointLabelPlacementBelowCenter:"below-center",esriServerPointLabelPlacementBelowLeft:"below-left",esriServerPointLabelPlacementBelowRight:"below-right",esriServerPointLabelPlacementCenterCenter:"center-center",esriServerPointLabelPlacementCenterLeft:"center-left",esriServerPointLabelPlacementCenterRight:"center-right",esriServerLinePlacementAboveAfter:"above-after",esriServerLinePlacementAboveAlong:"above-along",esriServerLinePlacementAboveBefore:"above-before",esriServerLinePlacementAboveStart:"above-start",esriServerLinePlacementAboveEnd:"above-end",esriServerLinePlacementBelowAfter:"below-after",esriServerLinePlacementBelowAlong:"below-along",esriServerLinePlacementBelowBefore:"below-before",esriServerLinePlacementBelowStart:"below-start",esriServerLinePlacementBelowEnd:"below-end",esriServerLinePlacementCenterAfter:"center-after",esriServerLinePlacementCenterAlong:"center-along",esriServerLinePlacementCenterBefore:"center-before",esriServerLinePlacementCenterStart:"center-start",esriServerLinePlacementCenterEnd:"center-end",esriServerPolygonPlacementAlwaysHorizontal:"always-horizontal"},{ignoreUnknown:!0});function b(e,t,r){return{enabled:!(0,g.TU)(r?.layer)}}function M(e){return!e||"service"!==e.origin&&"map-image"!==e.layer?.type}function x(e){return!!function(e){return"map-image"===e?.type}(e)&&!!e.capabilities?.exportMap?.supportsArcadeExpressionForLabeling}let S=class extends l.o{static{i=y.vK}static{o=this}static evaluateWhere(e,t){let r=(e,t,r)=>{switch(t){case"=":return e==r;case"<>":return e!=r;case">":return e>r;case">=":return e>=r;case"<":return e<r;case"<=":return e<=r}return!1};try{if(null==e)return!0;let i=e.split(" ");if(3===i.length)return r(t[i[0]],i[1],i[2]);if(7===i.length){let e=r(t[i[0]],i[1],i[2]),o=i[3],n=r(t[i[4]],i[5],i[6]);switch(o){case"AND":return e&&n;case"OR":return e||n}}return!1}catch{}}constructor(e){super(e),this[i]=!0,this.type="label",this.name=null,this.allowOverrun=!1,this.deconflictionStrategy="static",this.labelExpression=null,this.labelExpressionInfo=null,this.labelPlacement=null,this.offsetDistance=0,this.labelPosition="curved",this.maxScale=0,this.minScale=0,this.repeatLabel=!0,this.symbol=f.Hk,this.useCodedValues=void 0,this.where=null}readLabelExpression(e,t){let r=t.labelExpressionInfo;if(!r||!r.value&&!r.expression)return e}writeLabelExpression(e,t,r){if(this.labelExpressionInfo)if(null!=this.labelExpressionInfo.value)e=(0,y.D3)(this.labelExpressionInfo.value);else if(null!=this.labelExpressionInfo.expression){let t=(0,y.tH)(this.labelExpressionInfo.expression);t&&(e="["+t+"]")}null!=e&&(t[r]=e)}writeLabelExpressionInfo(e,t,r,i){if(null==e&&null!=this.labelExpression&&M(i))e=new c.A({expression:this.getLabelExpressionArcade()});else if(!e)return;let o=e.toJSON(i);o.expression&&(t[r]=o)}writeMaxScale(e,t){(e||this.minScale)&&(t.maxScale=e)}writeMinScale(e,t){(e||this.maxScale)&&(t.minScale=e)}get repeatLabelDistance(){return this._get("repeatLabelDistance")}set repeatLabelDistance(e){this._set("repeatLabelDistance",e)}getLabelExpression(){return(0,y.XJ)(this)}getLabelExpressionArcade(){return(0,y.BI)(this)}getLabelExpressionSingleField(){return(0,y.rU)(this)}hash(){return JSON.stringify(this)}clone(){return new o({allowOverrun:this.allowOverrun,deconflictionStrategy:this.deconflictionStrategy,labelExpression:this.labelExpression,labelExpressionInfo:(0,a.o8)(this.labelExpressionInfo),labelPosition:this.labelPosition,labelPlacement:this.labelPlacement,offsetDistance:this.offsetDistance,maxScale:this.maxScale,minScale:this.minScale,name:this.name,repeatLabel:this.repeatLabel,repeatLabelDistance:this.repeatLabelDistance,symbol:(0,a.o8)(this.symbol),where:this.where,useCodedValues:this.useCodedValues})}};(0,n.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],S.prototype,"name",void 0),(0,n.Cg)([(0,u.MZ)({type:Boolean,json:{write:!0,default:!1,origins:{"web-scene":{write:!1},"portal-item":{default:!1,write:{overridePolicy:b}}}}})],S.prototype,"allowOverrun",void 0),(0,n.Cg)([(0,u.MZ)({type:String,json:{write:!0,default:"static",origins:{"web-scene":{write:!1},"portal-item":{default:"static",write:{overridePolicy:b}}}}})],S.prototype,"deconflictionStrategy",void 0),(0,n.Cg)([(0,u.MZ)({type:String,json:{write:{overridePolicy(e,t,r){return this.labelExpressionInfo&&"service"===r?.origin&&x(r.layer)?{enabled:!1}:{allowNull:!0}}}}})],S.prototype,"labelExpression",void 0),(0,n.Cg)([(0,v.w)("labelExpression")],S.prototype,"readLabelExpression",null),(0,n.Cg)([(0,w.K)("labelExpression")],S.prototype,"writeLabelExpression",null),(0,n.Cg)([(0,u.MZ)({type:c.A,json:{write:{overridePolicy:(e,t,r)=>function(e){return M(e)||x(e?.layer)}(r)?{allowNull:!0}:{enabled:!1}}}})],S.prototype,"labelExpressionInfo",void 0),(0,n.Cg)([(0,w.K)("labelExpressionInfo")],S.prototype,"writeLabelExpressionInfo",null),(0,n.Cg)([(0,u.MZ)({type:C.apiValues,json:{type:C.jsonValues,read:C.read,write:C.write}})],S.prototype,"labelPlacement",void 0),(0,n.Cg)([(0,u.MZ)({type:Number,json:{read:!0,write:!0,default:0,origins:{"web-scene":{write:!1}}}})],S.prototype,"offsetDistance",void 0),(0,n.Cg)([(0,u.MZ)({type:["curved","parallel"],json:{write:!0,origins:{"web-map":{write:!1},"web-scene":{write:!1},"portal-item":{write:!1}}}})],S.prototype,"labelPosition",void 0),(0,n.Cg)([(0,u.MZ)({type:Number})],S.prototype,"maxScale",void 0),(0,n.Cg)([(0,w.K)("maxScale")],S.prototype,"writeMaxScale",null),(0,n.Cg)([(0,u.MZ)({type:Number})],S.prototype,"minScale",void 0),(0,n.Cg)([(0,w.K)("minScale")],S.prototype,"writeMinScale",null),(0,n.Cg)([(0,u.MZ)({type:Boolean,json:{write:!0,origins:{"web-scene":{write:!1},"portal-item":{write:{overridePolicy:b}}}}})],S.prototype,"repeatLabel",void 0),(0,n.Cg)([(0,u.MZ)({type:Number,cast:p.cr,json:{write:!0,origins:{"web-scene":{write:!1},"portal-item":{write:{overridePolicy:b}}}}})],S.prototype,"repeatLabelDistance",null),(0,n.Cg)([(0,u.MZ)({types:h.em,json:{types:h.em,origins:{"portal-item":{types:h.em,read:{reader:(0,d.C)({types:h.em})},default:null},"web-scene":{types:h.Rv,read:{reader:(0,d.C)({types:h.Rv})},write:m.oO,default:null}},write:m.oO,default:null}})],S.prototype,"symbol",void 0),(0,n.Cg)([(0,u.MZ)({type:Boolean,json:{write:!0}})],S.prototype,"useCodedValues",void 0),(0,n.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],S.prototype,"where",void 0),S=o=(0,n.Cg)([(0,u.$K)("esri.layers.support.LabelClass")],S);const j=S;r.d(t,["A",0,j])},73913(e,t,r){var i,o=r(32198),n=r(25482),s=r(91429),l=r(32730),a=r(36005),p=r(43937);let u=class extends n.o{static{i=this}constructor(e){super(e),this.name=null,this.expression=null,this.title=null,this.value=null}readExpression(e,t){return t.value?(0,l.mX)(t.value):e}writeExpression(e,t,r){null!=this.value&&(e=(0,l.mX)(this.value)),null!=e&&(t[r]=e)}clone(){return new i({name:this.name,expression:this.expression,title:this.title,value:this.value})}};(0,o.Cg)([(0,s.MZ)({type:String,json:{write:!0,origins:{"web-scene":{write:!1}}}})],u.prototype,"name",void 0),(0,o.Cg)([(0,s.MZ)({type:String,json:{write:{writerEnsuresNonNull:!0}}})],u.prototype,"expression",void 0),(0,o.Cg)([(0,a.w)("expression",["expression","value"])],u.prototype,"readExpression",null),(0,o.Cg)([(0,p.K)("expression")],u.prototype,"writeExpression",null),(0,o.Cg)([(0,s.MZ)({type:String,json:{write:!0,origins:{"web-scene":{write:!1}}}})],u.prototype,"title",void 0),(0,o.Cg)([(0,s.MZ)({json:{read:!1,write:!1}})],u.prototype,"value",void 0),u=i=(0,o.Cg)([(0,s.$K)("esri.layers.support.LabelExpressionInfo")],u);const d=u;r.d(t,["A",0,d])},91880(e,t,r){r.d(t,{A:()=>p});var i,o=r(32198),n=r(66552),s=r(25482),l=r(91429);const a=new n.J({asc:"ascending",desc:"descending"});let p=class extends s.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,o.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,o.Cg)([(0,l.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],p.prototype,"valueExpression",void 0),(0,o.Cg)([(0,l.MZ)({type:a.apiValues,json:{type:a.jsonValues,read:a.read,write:a.write}})],p.prototype,"order",void 0),p=i=(0,o.Cg)([(0,l.$K)("esri.layers.support.OrderByInfo")],p)},41560(e,t,r){r.d(t,{Ch:()=>s,mW:()=>n});var i=r(34727),o=r(39516);function n(e,t){return{...t,filterMode:e.mode}}function s(e,t,r){let n=function(e){if("manual"===p(e))return null;let t=[-1/0,1/0];for(let{minScale:r,maxScale:i}of e.filters)t[0]=Math.max(t[0],u(r)),t[1]=Math.min(t[1],d(i));return t}(e);if(n&&((0,i.gg)(t,n[0])||(0,i.ZH)(r,n[1])))return"";let s=Array.from(l(e,t,r)),a=function(e,t,r){if(0===e.length)return!0;let o=u(e.at(0)?.minScale),n=d(e.at(-1)?.maxScale);if((0,i.ZH)(o,t)||(0,i.gg)(n,r))return!0;for(let t=0;t<e.length-1;t++){let r=e[t],o=e[t+1];if((0,i.ZH)(u(o.minScale),d(r.maxScale)))return!0}return!1}(s,t,r)?"1=1":s.map(e=>e.where||"1=1").reduce((e,t)=>(0,o.IW)(e,t),"");return a&&"1=1"!==a?a:""}function*l(e,t,r){if("manual"===p(e)){let t=e.filters.find(t=>t.id===e.activeFilterId);t&&(yield t)}else{"object"==typeof t&&(t=t.scale);for(let i of e.filters)a(i.minScale,i.maxScale,t,r)&&(yield i)}}function a(e,t,r,o){return e=u(e),r=u(r),t=d(t),!(!(0,i.Sp)(r,e)&&(o??r)>e||(0,i.Hx)(t,r)||void 0!==o&&(0,i.Sp)(o,e))}function p(e){return"mode"in e?e.mode:e.filterMode}function u(e){return e||1/0}function d(e){return e||0}},39383(e,t,r){r.d(t,{w:()=>a,z:()=>d});var i=r(49186),o=r(53966),n=r(46499);const s=()=>o.A.getLogger("esri.layers.support.labelingInfo"),l=/\[([^[\]]+)\]/gi;function a(e,t,r){return e?e.map(e=>{let i=new n.A;if(i.read(e,r),i.labelExpression){let e=t.fields||t.layerDefinition?.fields||this.fields;i.labelExpression=i.labelExpression.replaceAll(l,(t,r)=>`[${function(e,t){if(!t)return e;let r=e.toLowerCase();for(let e=0;e<t.length;e++){let i=t[e].name;if(i.toLowerCase()===r)return i}return e}(r,e)}]`)}return i}):null}const p=["above-right","above-center","above-left","center-center","center-left","center-right","below-center","below-left","below-right"],u={esriGeometryPoint:p,esriGeometryMultiPatch:["always-horizontal"],esriGeometryPolygon:["always-horizontal"],esriGeometryPolyline:["center-along","above-along","below-along"],esriGeometryMultipoint:p,esriGeometryEnvelope:null};function d(e,t){let r=[];for(let o of e){let e=o.labelPlacement,n=u[t];if(!o.symbol)return s().warn("No ILabelClass symbol specified."),[];if(!n)return s().error(new i.A("labeling:unsupported-geometry-type",`Unable to create labels for layer, geometry type '${t}' is not supported`)),[];if(n.includes(e))r.push(o);else{let i=n[0];e&&s().warn(`Found invalid label placement type ${e} for ${t}. Defaulting to ${i}`);let l=o.clone();l.labelPlacement=i,r.push(l)}}return r}},73681(e,t,r){r.d(t,{n:()=>a});var i=r(49186),o=r(53966),n=r(46140),s=r(95466),l=r(55674);class a{static async from(e,t,r){let s=e.dictionary_version?n.A.parse(e.dictionary_version):null,u=new Set(e.itemsNames),d={};if(t)for(let e in t)d[e]=t[e];if(e.authoringInfo.configuration)for(let t of e.authoringInfo.configuration)d.hasOwnProperty(t.name)||(d[t.name]=t.value);let c=new Set(e.authoringInfo.symbol);for(let e of Object.keys(r))c.delete(e);c.size&&o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:c});let y=await(0,l.xR)(e.expression,null,d);if(!y)throw new i.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");let g=!s||!s.greaterEqual(4,0);g&&o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:s});let f=new p(r,g);return new a(g,u,y,f)}constructor(e,t,r,i){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=i}get itemNames(){return this._itemNames}evaluate(e,t,r,i){try{return this._reader.bind(e,r,i),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){o.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new s.A(e);let t=e.map(e=>({...e,type:"esriFieldTypeString"}));return new s.A(t)}}class p extends l.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){let t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);let t=this._getField(e);return null==t||null==this._boundTarget.attributes[t.name]?"":""+this._boundTarget.attributes[t.name]}}},22671(e,t,r){r.d(t,{A:()=>v});var i,o=r(32198),n=r(52106),s=r(66552),l=r(25482),a=r(4718),p=r(91429),u=r(16930),d=r(60408),c=r(65864),y=r(50498),g=r(20437),f=r(36005),m=r(43937);const h=new s.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let v=i=class extends l.o{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){return this.readFeaturesWithClass(e,t,n.A)}writeGeometryType(e,t,r,i){if(e)return void h.write(e,t,r,i);let{features:o}=this;if(o)for(let e of o)if(null!=e?.geometry)return void h.write(e.geometry.type,t,r,i)}readQueryGeometry(e,t){if(!e)return null;let r=!!e.spatialReference,i=(0,c.rS)(e);return i&&!r&&t.spatialReference&&(i.spatialReference=u.A.fromJSON(t.spatialReference)),i}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());let{features:r}=this;if(r)for(let e of r)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new i(this.cloneProperties())}cloneProperties(){return(0,a.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){let t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){let i=t.features[r];i.geometry&&=(e?.[r])?.toJSON()||i.geometry}return t}quantize(e){let{scale:[t,r],translate:[i,o]}=e,n=this.features,s=this._getQuantizationFunction(this.geometryType,e=>Math.round((e-i)/t),e=>Math.round((o-e)/r));for(let e=0,t=n.length;e<t;e++)s?.(n[e].geometry)||(n.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){let{geometryType:e,features:t,transform:r}=this;if(!r)return this;let{translate:[i,o],scale:[n,s]}=r,l=null,a=null;if(this.hasZ&&null!=r?.scale?.[2]){let{translate:[,,e],scale:[,,t]}=r;l=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){let{translate:[,,,e],scale:[,,,t]}=r;a=r=>null==r?r:r*t+e}let p=this._getHydrationFunction(e,e=>e*n+i,e=>o-e*s,l,a);for(let{geometry:e}of t)null!=e&&p&&p(e);return this.transform=null,this}readFeaturesWithClass(e,t,r){let i=u.A.fromJSON(t.spatialReference),o=[];for(let t=0;t<e.length;t++){let n=e[t],s=r.fromJSON(n),l=n.geometry?.spatialReference;null!=s.geometry&&!l&&(s.geometry.spatialReference=i);let a=n.aggregateGeometries,p=s.aggregateGeometries;if(a&&null!=p)for(let e in p){let t=p[e],r=a[e]?.spatialReference;null!=t&&!r&&(t.spatialReference=i)}o.push(s)}return o}_quantizePoints(e,t,r){let i,o,n=[];for(let s=0,l=e.length;s<l;s++){let l=e[s];if(s>0){let e=t(l[0]),s=r(l[1]);(e!==i||s!==o)&&(n.push([e-i,s-o]),i=e,o=s)}else i=t(l[0]),o=r(l[1]),n.push([i,o])}return n.length>0?n:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{let i=(0,d.Bi)(e)?e.rings:e.paths,o=[];for(let e=0,n=i.length;e<n;e++){let n=i[e],s=this._quantizePoints(n,t,r);s&&o.push(s)}return o.length>0?((0,d.Bi)(e)?e.rings=o:e.paths=o,e):null}:"multipoint"===e?e=>{let i=this._quantizePoints(e.points,t,r);return i&&i.length>0?(e.points=i,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r,i,o){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y),i&&(e.z=i(e.z))}:"polyline"===e||"polygon"===e?e=>{let n,s,l=(0,d.Bi)(e)?e.rings:e.paths;for(let e=0,i=l.length;e<i;e++){let i=l[e];for(let e=0,o=i.length;e<o;e++){let o=i[e];e>0?(n+=o[0],s+=o[1]):(n=o[0],s=o[1]),o[0]=t(n),o[1]=r(s)}}if(i&&o)for(let e=0,t=l.length;e<t;e++){let t=l[e];for(let e=0,r=t.length;e<r;e++){let r=t[e];r[2]=i(r[2]),r[3]=o(r[3])}}else if(i)for(let e=0,t=l.length;e<t;e++){let t=l[e];for(let e=0,r=t.length;e<r;e++){let r=t[e];r[2]=i(r[2])}}else if(o)for(let e=0,t=l.length;e<t;e++){let t=l[e];for(let e=0,r=t.length;e<r;e++){let r=t[e];r[2]=o(r[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=r(e.ymin),e.xmax=t(e.xmax),e.ymax=r(e.ymax),i&&null!=e.zmax&&null!=e.zmin&&(e.zmax=i(e.zmax),e.zmin=i(e.zmin)),o&&null!=e.mmax&&null!=e.mmin&&(e.mmax=o(e.mmax),e.mmin=o(e.mmin))}:"multipoint"===e?e=>{let n,s,l=e.points;for(let e=0,i=l.length;e<i;e++){let i=l[e];e>0?(n+=i[0],s+=i[1]):(n=i[0],s=i[1]),i[0]=t(n),i[1]=r(s)}if(i&&o)for(let e=0,t=l.length;e<t;e++){let t=l[e];t[2]=i(t[2]),t[3]=o(t[3])}else if(i)for(let e=0,t=l.length;e<t;e++){let t=l[e];t[2]=i(t[2])}else if(o)for(let e=0,t=l.length;e<t;e++){let t=l[e];t[2]=o(t[2])}}:null}};(0,o.Cg)([(0,p.MZ)({type:String,json:{write:!0}})],v.prototype,"displayFieldName",void 0),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"exceededTransferLimit",void 0),(0,o.Cg)([(0,p.MZ)({type:[n.A],json:{write:!0}})],v.prototype,"features",void 0),(0,o.Cg)([(0,f.w)("features")],v.prototype,"readFeatures",null),(0,o.Cg)([(0,p.MZ)({type:[g.A],json:{write:!0}})],v.prototype,"fields",void 0),(0,o.Cg)([(0,p.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:h.read}}})],v.prototype,"geometryType",void 0),(0,o.Cg)([(0,m.K)("geometryType")],v.prototype,"writeGeometryType",null),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"hasM",void 0),(0,o.Cg)([(0,p.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"hasZ",void 0),(0,o.Cg)([(0,p.MZ)({types:y.yR,json:{write:!0}})],v.prototype,"queryGeometry",void 0),(0,o.Cg)([(0,f.w)("queryGeometry")],v.prototype,"readQueryGeometry",null),(0,o.Cg)([(0,p.MZ)({type:u.A,json:{write:!0}})],v.prototype,"spatialReference",void 0),(0,o.Cg)([(0,m.K)("spatialReference")],v.prototype,"writeSpatialReference",null),(0,o.Cg)([(0,p.MZ)({json:{write:!0}})],v.prototype,"transform",void 0),v=i=(0,o.Cg)([(0,p.$K)("esri.rest.support.FeatureSet")],v),v.prototype.toJSON.isDefaultToJSON=!0},2991(e,t,r){r.d(t,{G9:()=>p,RZ:()=>a});var i=r(39516);const o="=",n=">=",s="<=";function l(e,t,r,o){let n=o.get(e)?.type,s=o.getTimeZone(e);return`${(0,i.iA)(e)} ${t} ${(0,i.YG)(r,{type:"date"},{type:n,timeZone:s})}`}function a(e,t,r,a){if(!t||!r)return;let{startField:p,endField:u}=t,{start:d,end:c}=e;if(!d&&!c||!p&&!u)return;let y=p??u,g=u??p;if(y&&g){if(d&&c){if(d.getTime()===c.getTime())return(0,i.mA)(a,l(y,o,d,r));if(!p||!u){let e=l(y,n,d,r),t=l(y,s,c,r);return(0,i.mA)(a,(0,i.mA)(e,t))}let e=l(p,n,d,r),t=l(u,s,c,r);return(0,i.mA)(a,(0,i.mA)(e,t))}if(d)return(0,i.mA)(a,l(y,n,d,r));if(c)return(0,i.mA)(a,l(g,s,c,r))}}function p(e){let{start:t,end:r}=e;if(t||r){if(!t&&r)return`null,${r.getTime()}`;if(!r&&t)return`${t.getTime()},null`;if(r&&t)return t.getTime()===r.getTime()?`${t.getTime()}`:`${t.getTime()},${r.getTime()}`}}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3309],{93309(e,t,i){i.r(t),i.d(t,{default:()=>q});var a=i(32198),n=i(67996),o=i(7762),r=i(51447),s=i(49186),l=i(53966),h=i(91869),d=i(25728),p=i(17676),u=i(36708),g=i(91429),y=i(35666),c=i(5443),m=i(86738),f=i(82799),L=i(12359),C=i(4146),M=i(90708),w=i(15375);const b={MULTIPLIER:"multiplier",ABSOLUTE:"absolute-value"};var k=i(24137),T=i(62796),v=i(40736),E=i(69860),N=i(99916),D=i(63074),S=i(34287),x=i(25036),I=i(10873),A=i(8460),_=i(69540),R=i(25482),Z=i(78888),B=i(69647),z=i(93223);let O=class extends((0,_.OU)(R.o)){constructor(e){super(e),this.durationLineWidth=5,this.entityPositionAtDurationRatio=1,this.eventsTicksVisualization="start-and-end",this.lineSeparationMultiplier=1,this.moveFirstBends=!0,this.secondBendRatio=.3,this.separateTimeOverlaps=!0,this.separateTimelineOverlaps=!0,this.separatedLineShapeRatio=0,this.showDurationLineForNonZeroDurationEntityEvents=!1,this.showNonZeroDurationIntervalBounds=!1,this.spaceSeparatedLinesEvenly=!1,this.timeBannerUTCOffsetInMinutes=0,this.timeDirection="right",this.useBezierCurves=!1}};(0,a.Cg)([(0,g.MZ)({type:Z.jz,range:{min:1,max:10},json:{write:!0}})],O.prototype,"durationLineWidth",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:1},json:{write:!0}})],O.prototype,"entityPositionAtDurationRatio",void 0),(0,a.Cg)([(0,z.e)(B.SJ)],O.prototype,"eventsTicksVisualization",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0},json:{write:!0}})],O.prototype,"lineSeparationMultiplier",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"moveFirstBends",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:1},json:{write:!0}})],O.prototype,"secondBendRatio",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"separateTimeOverlaps",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"separateTimelineOverlaps",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:1},json:{write:!0}})],O.prototype,"separatedLineShapeRatio",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"showDurationLineForNonZeroDurationEntityEvents",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"showNonZeroDurationIntervalBounds",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"spaceSeparatedLinesEvenly",void 0),(0,a.Cg)([(0,g.MZ)({type:Z.jz,json:{write:!0}})],O.prototype,"timeBannerUTCOffsetInMinutes",void 0),(0,a.Cg)([(0,g.MZ)({type:["bottom","left","right","top"],json:{write:!0}})],O.prototype,"timeDirection",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],O.prototype,"useBezierCurves",void 0),O=(0,a.Cg)([(0,g.$K)("esri.linkChart.ChronologicalLayoutSettings")],O);const P=O;let U=class extends((0,_.OU)(R.o)){constructor(e){super(e),this.absoluteIdealEdgeLength=1,this.autoRepulsionRadius=!0,this.computationBudgetTime=2,this.idealEdgeLengthType="multiplier",this.multiplicativeIdealEdgeLength=1,this.repulsionRadiusMultiplier=1}};(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:360},json:{write:!0}})],U.prototype,"absoluteIdealEdgeLength",void 0),(0,a.Cg)([(0,g.MZ)({type:Boolean,json:{write:!0}})],U.prototype,"autoRepulsionRadius",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,json:{write:!1}})],U.prototype,"computationBudgetTime",void 0),(0,a.Cg)([(0,z.e)(B.lg)],U.prototype,"idealEdgeLengthType",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:0,max:5},json:{write:!0}})],U.prototype,"multiplicativeIdealEdgeLength",void 0),(0,a.Cg)([(0,g.MZ)({type:Number,range:{min:1,max:99},json:{write:!0}})],U.prototype,"repulsionRadiusMultiplier",void 0),U=(0,a.Cg)([(0,g.$K)("esri.linkChart.OrganicLayoutSettings")],U);const j=U;let F=class extends((0,_.OU)(R.o)){constructor(e){super(e),this.rootEntities=[]}};(0,a.Cg)([(0,g.MZ)({type:[Object],json:{write:!0}})],F.prototype,"rootEntities",void 0),F=(0,a.Cg)([(0,g.$K)("esri.linkChart.RootedLayoutSettings")],F);const G=F;let H=class extends((0,_.OU)(R.o)){constructor(e){super(e),this.chronologicalLayoutSettings=null,this.organicLayoutSettings=null,this.rootedLayoutSettings=null}};(0,a.Cg)([(0,g.MZ)({type:P,json:{write:!0}})],H.prototype,"chronologicalLayoutSettings",void 0),(0,a.Cg)([(0,g.MZ)({type:j,json:{write:!0}})],H.prototype,"organicLayoutSettings",void 0),(0,a.Cg)([(0,g.MZ)({type:G,json:{write:!0}})],H.prototype,"rootedLayoutSettings",void 0),H=(0,a.Cg)([(0,g.$K)("esri.linkChart.LayoutSettings")],H);const $=H;var K=i(54628),Q=i(53902),V=i(56400);let W=class extends((0,S.q)((0,D.dM)((0,x.j)((0,d.M)(C.A))))){constructor(e){if(super(e),this.url=null,this.dataPreloadedInLocalCache=!1,this.initializationLinkChartConfig=null,this.membershipModified=!0,this._currentLinkChartConfig={layoutMode:"organic-standard"},this._graphTypeLookup=new Map,this.dataManager=null,this.knowledgeGraph=null,this.layers=new(o.A.ofType(T.A)),this.entityLinkChartDiagramLookup=new Map,this.relationshipLinkChartDiagramLookup=new Map,this.linkChartExtent=new c.A({xmin:-1e-7,ymin:-1e-7,xmax:1e-7,ymax:1e-7}),this.memberEntityTypes=null,this.memberRelationshipTypes=null,this.operationalLayerType="LinkChartLayer",this.sublayerIdsCache=new Map,this.tables=new(o.A.ofType(T.A)),this.type="link-chart",this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1,this.chronologicalAuxiliaryGraphics=null,this._originalInclusionList=e?.initializationInclusionModeDefinition,e?.dataPreloadedInLocalCache&&!e?.initializationInclusionModeDefinition)throw new s.A("knowledge-graph:linkchart-layer-constructor","If creating a link chart composite layer and configured that data is already loaded in the cache, you must specify an inclusion list so the Composite Layer knows what records belong to it");this.addHandles((0,u.wB)(()=>this.layers.concat(this.tables),(e,t)=>this._handleSublayersChange(e,t),u.OH))}normalizeCtorArgs(e){if(!e)return{};let{url:t,dataPreloadedInLocalCache:i,initializationLinkChartConfig:a}=e,{title:n}=e;return!n&&e?.url&&(n=(0,v.$L)(e.url)),{url:t,title:n,dataPreloadedInLocalCache:i,initializationLinkChartConfig:a}}_initializeLayerProperties(e){let t=new Set,i=[],a=[];if(e.inclusionModeDefinition&&(!e.inclusionModeDefinition.namedTypeDefinitions||e.inclusionModeDefinition.namedTypeDefinitions.size<1))throw new s.A("knowledge-graph:composite-layer-constructor","If an explicit inclusion definition is defined, at least one namedTypeDefinition must also be defined");e.inclusionModeDefinition?.generateAllSublayers?(i=e.knowledgeGraph.dataModel.entityTypes??[],a=e.knowledgeGraph.dataModel.relationshipTypes??[]):e.inclusionModeDefinition?.namedTypeDefinitions&&e.inclusionModeDefinition?.namedTypeDefinitions.size>0?e.inclusionModeDefinition?.namedTypeDefinitions.forEach((n,o)=>{let r=this._graphTypeLookup.get(o);r?"relationship"===r.type?t.has(o)||(t.add(o),a.push(r)):"entity"===r.type?t.has(o)||(t.add(o),i.push(r)):(l.A.getLogger(this).warn(`A named type, ${o}, was in the inclusion list that wasn't properly modeled and will be removed`),e.inclusionModeDefinition?.namedTypeDefinitions.delete(o)):(l.A.getLogger(this).warn(`A named type, ${o}, was in the inclusion list that wasn't in the data model and will be removed`),e.inclusionModeDefinition?.namedTypeDefinitions.delete(o))}):(i=e.knowledgeGraph.dataModel.entityTypes??[],a=e.knowledgeGraph.dataModel.relationshipTypes??[]);let n=new k.P({knowledgeGraph:e.knowledgeGraph,inclusionModeDefinition:e.inclusionModeDefinition});this.knowledgeGraph=e.knowledgeGraph,this.memberEntityTypes=i,this.memberRelationshipTypes=a,this.dataManager=n}load(e){let t=async()=>{let e=[],t=[];this.loadLayerAssumingLocalCache(),this._layersLoadedFromAuthoritativeItem()||await(0,v.qN)(this),this.dataManager.inclusionModeDefinition&&(this.dataManager.inclusionModeDefinition.generateAllSublayers=!1),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.forEach(e=>{e.useAllData=!1}),await this._initializeDiagram(),this.layers.forEach(i=>{t.push(i.refreshCachedQueryEngine()),e.push(new Promise(e=>{i.on("layerview-create",()=>{e(null)})}))}),this.tables.forEach(e=>{t.push(e.refreshCachedQueryEngine())}),await Promise.all(t)};return this.addResolvingPromise(new Promise(i=>{(0,Q.fetchKnowledgeGraph)(this.url).then(async a=>{(0,p.Te)(e),a.dataModel.entityTypes?.forEach(e=>{e.name&&this._graphTypeLookup.set(e.name,e)}),a.dataModel.relationshipTypes?.forEach(e=>{e.name&&this._graphTypeLookup.set(e.name,e)});let o=this.linkChart?.linkChartProperties;6===o?.originIdOf("entitiesUrl")&&(this.membershipModified=!1,(0,K.lV)([o.entitiesUrl??"",o.relationshipsUrl??""],this.linkChart?.portalItem?.itemUrl??"").then(e=>{this.linkChart?.linkChartProperties?.setCreationDatesForResources?.(e)},()=>{}),this._originalInclusionList=await n.XW.fetchAndConvertSerializedLinkChart({entitiesUrl:o?.entitiesUrl,relationshipsUrl:o?.relationshipsUrl},{signal:e?.signal}),this._alignLayersDataModelAndInclusionDefinition(a.dataModel),this.initializationLinkChartConfig={layoutSettings:o?.layoutSettings??void 0,layoutMode:(0,N.k5)(o.layoutType)}),this._initializeLayerProperties({knowledgeGraph:a,inclusionModeDefinition:this._originalInclusionList}),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.size||(this.dataManager.inclusionModeDefinition={generateAllSublayers:!1,namedTypeDefinitions:new Map},this.dataManager.knowledgeGraph.dataModel.entityTypes?.forEach(e=>{e.name&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.set(e.name,{useAllData:!0})}),this.dataManager.knowledgeGraph.dataModel.relationshipTypes?.forEach(e=>{e.name&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.set(e.name,{useAllData:!0})}));let{edit:r,fullEdit:s,updateItem:l}=await(0,v.N1)(a.serviceDefinition.serviceItemId,this.url,e);if((0,p.Te)(e),this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",s),this._set("userHasUpdateItemPrivileges",l),this.read({dateFieldsTimeReference:a.serviceDefinition.dateFieldsTimeReference},{origin:"service"}),this.dataPreloadedInLocalCache){let e=E.A.getInstance();for(let[t,i]of this.dataManager.inclusionModeDefinition?.namedTypeDefinitions??[])for(let a of i.members?.values()??[]){let i=e.readFromStoreById(`${t}__${a.id}`);i&&(0,h.tE)(this.dataManager.sublayerCaches,t,()=>new Map).set(a.id,i)}await t()}else{let i="geographic-organic-standard"===this.initializationLinkChartConfig?.layoutMode;this.addResolvingPromise(this.dataManager.refreshCacheContent(void 0,!1,i,!0).then(async()=>{(0,p.Te)(e),await t()}))}i(null)}).catch(()=>{})})),Promise.resolve(this)}set initializationInclusionModeDefinition(e){"loaded"===this.loadStatus||"failed"===this.loadStatus?l.A.getLogger(this).error("#initializationInclusionModeDefinition","initializationInclusionModeDefinition cannot be changed after the layer is loaded."):this._set("initializationInclusionModeDefinition",e)}get linkChart(){return this.parent}get sublayerCapabilities(){return(0,v.hZ)(this.knowledgeGraph)}async addRecords(e,t){let i=[];t?.cascadeAddRelationshipEndNodes&&this.dataManager.knowledgeGraph.dataModel&&(i=await(0,N.aq)(e,this.dataManager.knowledgeGraph));let a=e.concat(i).filter(e=>!this.sublayerIdsCache.get(e.typeName)?.has(e.id));a.length>0&&(this.membershipModified=!0),await this._handleNewRecords(a,t)}async createSublayerForNamedType(e){await this.load();let t=this._graphTypeLookup.get(e);if(!t)throw new s.A("knowledge-graph:missing-type","The specified type does not exist in the knowledge graph.");if(this.dataManager.sublayerCaches.has(e))throw new s.A("knowledge-graph:duplicate-type","The specified type already exists as a sublayer.");this.dataManager.sublayerCaches.set(e,new Map),(0,h.tE)(this.sublayerIdsCache,e,()=>new Set);let i=this._createSublayer(t);return"entity"===t.type?this.dataManager.entityTypeNames.add(e):this.dataManager.relationshipTypeNames.add(e),this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.set(e,{useAllData:!1,members:new Map}),i.geometryType?this.layers.push(i):this.tables.push(i),await(0,v.qN)(this,[e]),this._refreshNamedTypes(),i}async removeRecords(e,{cascadeRemoveRelationships:t=!0,recalculateLayout:i=!1,overrideMembershipCheck:a=!1}={cascadeRemoveRelationships:!0,recalculateLayout:!1,overrideMembershipCheck:!1}){let n=[];for(let t of e)(a||!1===this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.get(t.typeName)?.useAllData&&this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.get(t.typeName)?.members?.has(t.id))&&n.push(t);if(t){let e=new Set,t=[];for(let t of n)if(this.dataManager.nodeConnectionsLookup.has(t.id))for(let i of this.dataManager.nodeConnectionsLookup.get(t.id))e.add(i);for(let i of e)if(this.dataManager.memberIdTypeLookup.has(i))for(let e of this.dataManager.memberIdTypeLookup.get(i))this.dataManager.relationshipTypeNames.has(e)&&t.push({id:i,typeName:e});n=n.concat(t)}let o=this._currentLinkChartConfig.layoutSettings?.rootedLayoutSettings?.rootEntities;if(o?.length){let e=new Set(n.map(({id:e})=>e)),t=o.filter(({id:t})=>!e.has(t));if(t.length!==o.length){this._currentLinkChartConfig.layoutSettings.rootedLayoutSettings.rootEntities=t;let e=this.linkChart?.linkChartProperties;e?.layoutSettings?.rootedLayoutSettings&&(e.layoutSettings.rootedLayoutSettings.rootEntities=t)}}this.dataManager.removeFromLayer(n);for(let e of n)this.sublayerIdsCache.get(e.typeName)?.delete(e.id),this.dataManager.relationshipTypeNames.has(e.typeName)?this.relationshipLinkChartDiagramLookup.delete(e.id):this.entityLinkChartDiagramLookup.delete(e.id);let r=i?void 0:this.getCurrentNodeLocations();await this._calculateLayoutWithSublayerTimeInfo(this._currentLinkChartConfig.layoutMode,{layoutSettings:this._currentLinkChartConfig.layoutSettings,lockedEntityLocations:r}),n.length>0&&(this.membershipModified=!0);let s=[];return this.layers.forEach(e=>{s.push(e.refreshCachedQueryEngine())}),await Promise.all(s),this._refreshNamedTypes(),n}async expand(e,t){let i=[];try{let a=await this.dataManager.getConnectedRecordIds(e,t?.relationshipTypeNames,t);i=a.filter(e=>!this.sublayerIdsCache.get(e.typeName)?.has(e.id)),await this._handleNewRecords(i,t),a.length>0&&(this.membershipModified=!0),(0,p.Te)(t?.signal)}catch(e){throw(0,p.zf)(e)&&i.length>0&&await this.removeRecords(i,{overrideMembershipCheck:!0}),e}return{records:i}}loadLayerAssumingLocalCache(){let e=[...this.memberRelationshipTypes,...this.memberEntityTypes];this.layers.length||0===this.originIdOf("tables")?0===this.originIdOf("layers")?this._createSublayers(e,this.layers,e=>!!e.geometryType):this._updateSublayers(e,this.layers):this.layers=new o.A,this.tables.length||0===this.originIdOf("layers")?0===this.originIdOf("tables")?this._createSublayers(e,this.tables,e=>!e.geometryType):this._updateSublayers(e,this.tables):this.tables=new o.A,this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{let i=(0,h.tE)(this.sublayerIdsCache,t,()=>new Set);e.members?.forEach(({id:e,linkChartLocation:a})=>{if(i.add(e),a){let i="coords"in a&&"lengths"in a?a:(0,M.Ux)(a);this.dataManager.relationshipTypeNames.has(t)?this.relationshipLinkChartDiagramLookup.set(e,i):this.entityLinkChartDiagramLookup.set(e,i)}})})}async calculateLinkChartLayout(e="organic-standard",t){let i=[],a=[],n=[];this.dataManager.sublayerCaches.forEach((e,t)=>{this.dataManager.entityTypeNames.has(t)?e.forEach(e=>{i.push({typeName:t,feature:e})}):this.dataManager.relationshipTypeNames.has(t)&&e.forEach(e=>{a.push({typeName:t,feature:e})})}),this.entityLinkChartDiagramLookup=new Map,this.relationshipLinkChartDiagramLookup=new Map;let o,r=new Map,d=new Map,u=new Map,g=new Map,y=new Uint8Array(i.length),C=new Float64Array(i.length),b=new Float64Array(i.length),k=new Float64Array(i.length),T=new Float64Array(i.length),v=new Uint32Array(a.length),E=new Uint32Array(a.length),N=new Float64Array(a.length),D=new Float64Array(a.length),S=[],x=!1,I=new c.A({xmin:-1e-7,ymin:-1e-7,xmax:1e-7,ymax:1e-7}),_="organic-standard",R=0,Z=0,B=A.i6.apply;switch(_="geographic-organic-standard"===e?"organic-standard":e,_){case"organic-standard":o=A.pM.apply;break;case"organic-community":o=A.Tu.apply;break;case"hierarchical-bottom-to-top":o=A.$C.apply;break;case"radial-root-centric":o=A.vJ.apply;break;case"tree-left-to-right":o=A.Xq.apply;break;default:o=A.Wg.apply}let z=!1,O=new Set(t?.layoutSettings?.rootedLayoutSettings?.rootEntities?.map(({id:e})=>e));i.forEach(({typeName:i,feature:a})=>{if("chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e&&t?.lockedEntityLocations?.has(a.attributes[w.dr])){"geographic-organic-standard"===e&&this.dataManager.geographicLookup.has(i)?y[R]=2:y[R]=0;let n=t.lockedEntityLocations.get(a.attributes[w.dr]);C[R]=n.x,b[R]=n.y}else if("geographic-organic-standard"===e&&this.dataManager.geographicLookup.has(i)){y[R]=2;let e=null,t=a.attributes[this.dataManager.geographicLookup.get(i).name];switch(this.dataManager.geographicLookup.get(i)?.geometryType){case"esriGeometryPoint":C[R]=t?.x,b[R]=t?.y;break;case"esriGeometryPolygon":{let i=t?(0,L.Ve)(t):null;e=i?m.A.fromJSON(i):null,null!=e?.x&&null!=e?.y?(C[R]=e.x,b[R]=e.y):y[R]=1;break}case"esriGeometryPolyline":case"esriGeometryMultipoint":e=t?.extent?.center,null!=e?.x&&null!=e?.y?(C[R]=e.x,b[R]=e.y):y[R]=1;break;default:y[R]=1}(null==C[R]||null==b[R]||Number.isNaN(C[R])||Number.isNaN(b[R]))&&(y[R]=1,C[R]=0,b[R]=0)}else if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){!z&&t?.lockedEntityLocations?.has(a.attributes[w.dr])&&(z=!0);let e=t?.timeInfoByTypeName?.get(i),n=e?.startField,o=n&&e?.startField?a.attributes[n]:null;k[R]=o?new Date(o).getTime():NaN;let r=e?.endField,s=r&&e?.endField?a.attributes[r]:null;T[R]=s?new Date(s).getTime():NaN,C[R]=0,b[R]=0,y[R]=1}else y[R]=1,C[R]=0,b[R]=0;O.has(a.attributes[w.dr])&&(y[R]|=4),g.set(a.attributes[w.dr],R),S[R]={feature:a,typeName:i},R++}),z&&l.A.getLogger(this).warn("Locked node locations are not supported for chronological layout at this time. Requested node locations were ignored");let P=!1,U=new Map;a.forEach(i=>{let a=i.feature.attributes[w.Cz],o=i.feature.attributes[w.KQ],r=g.get(a),s=g.get(o),l=t?.timeInfoByTypeName?.get(i.typeName),h=t?.timeInfoByTypeName?l?.startField:null,d=h?i.feature.attributes[h]:null,p=l?.endField,u=p?i.feature.attributes[p]:null;if(void 0!==r&&void 0!==s){let t=a+"-"+o;("chronological-mono-timeline"===e||"chronological-multi-timeline"===e)&&(t=t+"-"+d+"-"+u);let l=U.get(t);l?.has(i.typeName)||(v[Z]=r,E[Z]=s,("chronological-mono-timeline"===e||"chronological-multi-timeline"===e)&&(N[Z]=d?new Date(d).getTime():NaN,D[Z]=u?new Date(u).getTime():NaN),void 0===l?U.set(t,new Map([[i.typeName,Z]])):l.set(i.typeName,Z),Z++),n.push(i)}else P=!0,this.relationshipLinkChartDiagramLookup.set(a,null)}),P&&l.A.getLogger(this).warn("A relationship is a member of this layer that has either origin or destination entity nodes that are not members. The diagram geometry will be set to null");let j=this._validateOrganicLayoutSettings(e,t?.layoutSettings?.organicLayoutSettings),F=this._convertValidatedOrganicSettingsToCalculationSettings(j);await(0,A.Hh)();let G=1,H=null;if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){let i;({status:G,links:H,graphics:i}=B(()=>t?.signal?.aborted??!1,y,C,b,k,T,v.subarray(0,Z),E.subarray(0,Z),N.subarray(0,Z),D.subarray(0,Z),"chronological-multi-timeline"===e,t?.layoutSettings?.chronologicalLayoutSettings)),0===G&&(this.chronologicalAuxiliaryGraphics=i)}else({status:G,links:H}=o(()=>t?.signal?.aborted??!1,y,C,b,v.subarray(0,Z),E.subarray(0,Z),F.computationBudgetTime,F.idealEdgeLengthMultiplier,F.repulsionRadiusMultiplier));if((0,p.Te)(t?.signal),1===G)throw new s.A("knowledge-graph:layout-failed","Attempting to arrange the records in the specified layout failed");if(2===G)throw(0,p.NK)();for(let e=0;e<S.length;e++){if(b[e]>84.9999?b[e]=84.9999:b[e]<-84.9999&&(b[e]=-84.9999),C[e]>179.9999?C[e]=179.9999:C[e]<-179.9999&&(C[e]=-179.9999),S[e].feature.attributes[w.T1]=new m.A({x:C[e],y:b[e]}),r.has(S[e].typeName))r.get(S[e].typeName)?.set(S[e].feature.attributes[w.dr],S[e].feature);else{let t=new Map;t.set(S[e].feature.attributes[w.dr],S[e].feature),r.set(S[e].typeName,t)}u.set(S[e].feature.attributes[w.dr],S[e].feature);let t=(0,M.Ux)(S[e].feature.attributes[w.T1]);this.entityLinkChartDiagramLookup.set(S[e].feature.attributes[w.dr],S[e].feature.attributes[w.T1]?t:null);let i=(0,h.tE)(this.dataManager.inclusionModeDefinition.namedTypeDefinitions,S[e].typeName,()=>({useAllData:!1,members:new Map}));(0,h.tE)(i.members,S[e].feature.attributes[w.dr],()=>({id:S[e].feature.attributes[w.dr],linkChartLocation:void 0})).linkChartLocation=S[e].feature.attributes[w.T1];let{x:a,y:n}=S[e].feature.attributes[w.T1];if(x)I.xmin=Math.min(I.xmin,a),I.xmax=Math.max(I.xmax,a),I.ymin=Math.min(I.ymin,n),I.ymax=Math.max(I.ymax,n);else{let e=1e-7;I.xmin=a-e,I.xmax=a+e,I.ymin=n-e,I.ymax=n+e,x=!0}}if(this.linkChartExtent.xmin=I.xmin,this.linkChartExtent.xmax=I.xmax,this.linkChartExtent.ymin=I.ymin,this.linkChartExtent.ymax=I.ymax,!H)throw new s.A("knowledge-graph:layout-failed","Attempting to retrieve link geometry from diagram engine failed");let $=new Map,K=new Map,Q=new Map,V=new Set;for(let i=0;i<n.length;i++){let a=[],o=n[i],r=o.feature.attributes[w.Cz],s=o.feature.attributes[w.KQ],p=r+"-"+s;if("chronological-mono-timeline"===e||"chronological-multi-timeline"===e){let e=t?.timeInfoByTypeName?.get(o.typeName),i=t?.timeInfoByTypeName?e?.startField:null,a=i?o.feature.attributes[i]:null,n=e?.endField;p+="-"+a+"-"+(n?o.feature.attributes[n]:null)}let y=U.get(p).get(o.typeName),c=0===y?0:H?.vertexEndIndex[y-1];if(!V.has(y)){if(V.add(y),2===H.types[y]){let e=[H.vertices[2*c],H.vertices[2*c+1]],t=[H.vertices[2*(c+1)],H.vertices[2*(c+1)+1]],i=[.5*(e[0]+t[0]),.5*(e[1]+t[1])],n=[i[0]-e[0],i[1]-e[1]],o=[i[0]+n[1],i[1]-n[0]],r=[i[0]-n[1],i[1]+n[0]];a.push(e),a.push(o),a.push(t),a.push(r),a.push(e)}else{if(0!==H.types[y]){l.A.getLogger(this).warn("A relationship generated an unsupported link geometry type. It will not be rendered");continue}for(let e=c;e<H.vertexEndIndex[y];e++)a.push([H.vertices[2*e],H.vertices[2*e+1]])}if("chronological-mono-timeline"!==e&&"chronological-multi-timeline"!==e){let e=S[g.get(r)]?.feature.attributes[w.T1],t=S[g.get(s)]?.feature.attributes[w.T1];(a[0][0]!==e.x||a[0][1]!==e.y)&&(a[0]=[e.x,e.y]),(a[a.length-1][0]!==t.x||a[a.length-1][1]!==t.y)&&(a[a.length-1]=[t.x,t.y])}for(let e=1;e<a.length-1;e++)a[e][1]>85.5?a[e][1]=85.5:a[e][1]<-85.5&&(a[e][1]=-85.5),a[e][0]>179.9999?a[e][0]=179.9999:a[e][0]<-179.9999&&(a[e][0]=-179.9999);$.has(p)?$.get(p).push(a):$.set(p,[a])}let m=$.get(p);K.has(p)||(K.set(p,new Map),Q.set(p,new Map));let L=K.get(p),C=Q.get(p);L.has(o.typeName)||(L.set(o.typeName,m.shift()),C.set(o.typeName,0));let b=L.get(o.typeName);C.set(o.typeName,C.get(o.typeName)+1);let k=new f.A({paths:[b]});if(o.feature.attributes[w.T1]=k,d.has(o.typeName))d.get(o.typeName)?.set(o.feature.attributes[w.dr],o.feature);else{let e=new Map;e.set(o.feature.attributes[w.dr],o.feature),d.set(o.typeName,e)}u.set(o.feature.attributes[w.dr],o.feature);let T=(0,M.Ux)(o.feature.attributes[w.T1]);this.relationshipLinkChartDiagramLookup.set(o.feature.attributes[w.dr],o.feature.attributes[w.T1]?T:null);let v=(0,h.tE)(this.dataManager.inclusionModeDefinition.namedTypeDefinitions,o.typeName,()=>({useAllData:!1,members:new Map}));(0,h.tE)(v.members,o.feature.attributes[w.dr],()=>({id:o.feature.attributes[w.dr],linkChartLocation:void 0})).linkChartLocation=T}for(let e of n)e.feature.attributes[w.M1]=Q.get(e.feature.attributes[w.Cz]+"-"+e.feature.attributes[w.KQ])?.get(e.typeName)??null;return this._currentLinkChartConfig={layoutMode:e,layoutSettings:t?.layoutSettings?.clone()},{nodes:r,links:d,idMap:u}}async applyNewLinkChartLayout(e="organic-standard",t){let{lockedNodeLocations:i,lockedEntityLocations:a,rootEntityIds:n,...o}=t??{};!a&&i?((0,r.io)(l.A.getLogger(this),"lockedNodeLocations is deprecated in 5.0. Use lockedEntityLocations instead.",{replacement:"Use lockedEntityLocations instead.",version:"5.0"}),a=i):a&&i&&(0,r.io)(l.A.getLogger(this),"Both lockedNodeLocations (deprecated in 5.0) and lockedEntityLocations are defined. Use lockedEntityLocations only instead.",{replacement:"Use lockedEntityLocations instead.",version:"5.0"});let s=o.layoutSettings?.rootedLayoutSettings?.rootEntities;if(!s&&n){(0,r.io)(l.A.getLogger(this),"rootEntityIds is deprecated in 5.1. Use layoutSettings.rootedLayoutSettings.rootEntities instead.",{replacement:"Use layoutSettings.rootedLayoutSettings.rootEntities instead.",version:"5.1"});let e=[];for(let t of n){let i=this.dataManager.memberIdTypeLookup.get(t),a=Array.from(i??[]).find(e=>this.dataManager.entityTypeNames.has(e));a&&e.push({id:t,typeName:a})}o.layoutSettings=o.layoutSettings??new $,o.layoutSettings.rootedLayoutSettings=o.layoutSettings.rootedLayoutSettings??new G,o.layoutSettings.rootedLayoutSettings.rootEntities=e}else s&&n&&(0,r.io)(l.A.getLogger(this),"Both rootEntityIds (deprecated in 5.1) and layoutSettings.rootedLayoutSettings.rootEntities are defined. Use layoutSettings.rootedLayoutSettings.rootEntities only instead.",{replacement:"Use layoutSettings.rootedLayoutSettings.rootEntities instead.",version:"5.1"});let h=[];await this._calculateLayoutWithSublayerTimeInfo(e,{...o,lockedEntityLocations:a}),this.layers.forEach(e=>{h.push(e.refreshCachedQueryEngine())}),this.membershipModified=!0,await Promise.all(h),this._refreshNamedTypes()}getCurrentNodeLocations(){let e=new Map;for(let[t,i]of this.dataManager.inclusionModeDefinition?.namedTypeDefinitions.entries()??[])this.dataManager.relationshipTypeNames.has(t)||i?.members?.forEach(t=>{let i,a=t.linkChartLocation,n=t.id;a&&(i="x"in a?{x:a.x,y:a.y}:{x:a.coords[0],y:a.coords[1]},e.set(n,new m.A({x:i.x,y:i.y})))});return e}async refreshLinkChartCache(e){await this.dataManager.refreshCacheContent(e);let t=[];this.layers.forEach(e=>{t.push(e.refreshCachedQueryEngine())}),await Promise.all(t),this._refreshNamedTypes()}async connectBetweenEntities(e,t){if(!e.length)return{records:[]};let i=[];try{let a=[];for(let e of this.dataManager.relationshipTypeNames){let t=this.sublayerIdsCache.get(e);t&&(a=a.concat(Array.from(t.keys())))}i=await this.dataManager.getRelationshipsBetweenNodes(e,a,t),await this._handleNewRecords(i,t),(0,p.Te)(t)}catch(e){throw(0,p.zf)(e)&&this.removeRecords(i),e}return{records:i}}async connectFromEntities(e,t){if(!e.length)return{records:[]};let i=[];try{let a=[];for(let e of this.dataManager.relationshipTypeNames){let t=this.sublayerIdsCache.get(e);t&&(a=a.concat(Array.from(t.keys())))}let n=[];for(let e of this.dataManager.entityTypeNames){let t=this.sublayerIdsCache.get(e);t&&(n=n.concat(Array.from(t)))}i=await this.dataManager.getRelationshipsFromNodes(e,n,a,t),await this._handleNewRecords(i,t),i.length>0&&(this.membershipModified=!0),(0,p.Te)(t)}catch(e){throw(0,p.zf)(e)&&this.removeRecords(i),e}return{records:i}}getCurrentLayout(){return this._currentLinkChartConfig.layoutMode}async _calculateLayoutWithSublayerTimeInfo(e="organic-standard",t){let i=new Map;this.layers.forEach(e=>{i.set(e.objectType.name,e.timeInfo)}),await this.calculateLinkChartLayout(e,{timeInfoByTypeName:i,...t}),this.linkChart?.handleChronologicalOverlay()}async _handleNewRecords(e,t){let i=new Set,a=[],n=this.layers.concat(this.tables);for(let t of e)this._graphTypeLookup.has(t.typeName)&&(!1===n.some(e=>e.objectType.name===t.typeName)&&(this.dataManager.sublayerCaches.set(t.typeName,new Map),i.add(t.typeName)),(0,h.tE)(this.sublayerIdsCache,t.typeName,()=>new Set).add(t.id),a.push(t));this.dataManager.addToLayer(a);for(let e of i){let t=this._graphTypeLookup.get(e);if(t){let i=this._createSublayer(t);"entity"===t.type?this.dataManager.entityTypeNames.add(e):this.dataManager.relationshipTypeNames.add(e),i.geometryType?this.layers.push(i):this.tables.push(i)}}await(0,v.qN)(this,Array.from(i),t),await this.dataManager.refreshCacheContent(e.map(e=>e.id),void 0,void 0,void 0,t);let o={layoutSettings:this._currentLinkChartConfig.layoutSettings,lockedEntityLocations:new Map};for(let[e,t]of this.entityLinkChartDiagramLookup.entries())t&&o.lockedEntityLocations.set(e,new m.A({x:t.coords[0],y:t.coords[1]}));await this.applyNewLinkChartLayout(this._currentLinkChartConfig.layoutMode,o)}_createSublayers(e,t,i){e.forEach(e=>{let a=this._createSublayer(e);i(a)&&t.push(a),this._updateSublayerCaches(e)})}_updateSublayers(e,t){t.forEach(t=>{t.parentCompositeLayer=this;let i=e.find(e=>e.type===t.graphType&&e.name===t.graphTypeName);i&&(t.objectType=i,t.read({title:i.name},{origin:"service"}),this._updateSublayerCaches(i))})}_updateSublayerCaches({name:e}){if(!e)return;let t=this.dataManager.sublayerCaches;t.has(e)||t.set(e,new Map)}_layersLoadedFromAuthoritativeItem(){let e=this.originIdOf("layers");return e>=3&&e<7}async _initializeDiagram(){this.initializationLinkChartConfig?this.initializationLinkChartConfig.doNotRecalculateLayout?(this.dataManager.inclusionModeDefinition?.namedTypeDefinitions?.forEach((e,t)=>{e?.members?.forEach(e=>{let i,a=e.linkChartLocation,n=e.id;if(!a)return;i="x"in a?{x:a.x,y:a.y}:{x:a.coords[0],y:a.coords[1]};let o=(0,M.Ux)(i);this.dataManager.relationshipTypeNames.has(t)?this.relationshipLinkChartDiagramLookup.set(n,o):this.entityLinkChartDiagramLookup.set(n,o),this.linkChartExtent.xmin>i.x&&(this.linkChartExtent.xmin=i.x),this.linkChartExtent.xmax<i.x&&(this.linkChartExtent.xmax=i.x),this.linkChartExtent.ymin>i.y&&(this.linkChartExtent.ymin=i.y),this.linkChartExtent.ymax<i.y&&(this.linkChartExtent.ymax=i.y)})}),this.memberRelationshipTypes.forEach(e=>{e.name&&this.dataManager.sublayerCaches.get(e.name)?.forEach(e=>{let t=this.relationshipLinkChartDiagramLookup.get(e.attributes[w.Cz]),i=this.relationshipLinkChartDiagramLookup.get(e.attributes[w.KQ]);if(t&&i){let a=(0,M.Ux)(new f.A({paths:[[[t.coords[0],t.coords[1]],[i.coords[0],i.coords[1]]]]}));this.relationshipLinkChartDiagramLookup.set(e.attributes[w.dr],a)}else this.relationshipLinkChartDiagramLookup.set(e.attributes[w.dr],null)})})):await this._calculateLayoutWithSublayerTimeInfo(this.initializationLinkChartConfig.layoutMode,{lockedEntityLocations:this.getCurrentNodeLocations(),...this.initializationLinkChartConfig}):await this._calculateLayoutWithSublayerTimeInfo("organic-standard",{lockedEntityLocations:this.getCurrentNodeLocations()})}_refreshNamedTypes(){for(let e of this.layers)e.emit("refresh",{dataChanged:!0});for(let e of this.tables)e.emit("refresh",{dataChanged:!0})}_validateOrganicLayoutSettings(e,t){let i=e=>"number"==typeof e&&!isNaN(e),a=e=>i(e)&&e>=0,n={};if(!new Set(["organic-standard","organic-community","geographic-organic-standard","chronological-multi-timeline","chronological-mono-timeline"]).has(e)||!t)return n;let{computationBudgetTime:o,autoRepulsionRadius:r,repulsionRadiusMultiplier:s,absoluteIdealEdgeLength:h,multiplicativeIdealEdgeLength:d,idealEdgeLengthType:p}=t;return(e=>i(e)&&e>=1)(o)?n.computationBudgetTime=o:o&&l.A.getLogger(this).warn("Invalid layout computationBudgetTime setting, will revert to default setting"),n.autoRepulsionRadius=r,!r&&(e=>i(e)&&e>=1)(s)?n.repulsionRadiusMultiplier=s:r||(n.autoRepulsionRadius=!0,l.A.getLogger(this).warn("Invalid layout repulsionRadiusMultiplier setting, will revert to default setting")),"geographic-organic-standard"===e&&((e=>Object.values(b).includes(e))(p)?n.idealEdgeLengthType=p:void 0!==p&&l.A.getLogger(this).warn('Invalid layout idealEdgeLengthType setting, will revert to "multiplier" setting'),"absolute-value"===p&&a(h)?n.absoluteIdealEdgeLength=h:"absolute-value"===p&&void 0!==h?l.A.getLogger(this).warn("Invalid layout idealEdgeLength setting, will revert to default setting"):"multiplier"===p&&a(d)?n.multiplicativeIdealEdgeLength=d:"multiplier"===p&&void 0!==d&&l.A.getLogger(this).warn("Invalid layout idealEdgeLength setting, will revert to default setting")),n}_convertValidatedOrganicSettingsToCalculationSettings(e){let t=e.idealEdgeLengthType===b.ABSOLUTE?e.absoluteIdealEdgeLength:e.multiplicativeIdealEdgeLength;return e.idealEdgeLengthType===b.ABSOLUTE&&(t=void 0===t?-1:-1*t),{computationBudgetTime:e.computationBudgetTime??void 0,repulsionRadiusMultiplier:e.repulsionRadiusMultiplier&&!e.autoRepulsionRadius?e.repulsionRadiusMultiplier:void 0,idealEdgeLengthMultiplier:t}}_createSublayer(e){return new T.A({objectType:e,parentCompositeLayer:this,graphType:e.type})}_handleSublayersChange(e,t){if(t&&(t.forEach(e=>{e.parent=null}),this.removeHandles("sublayers-owner")),e){let t=[];e.forEach(e=>{e.parent=this,t.push(this._createVisibleRefreshHandle(e))}),this.addHandles([...t,e.on("after-add",({item:e})=>{e.parent=this,this.addHandles(this._createVisibleRefreshHandle(e),"sublayers-owner")}),e.on("after-remove",({item:e})=>{e.parent=null})],"sublayers-owner")}}_createVisibleRefreshHandle(e){return(0,u.wB)(()=>e.visible,(t,i)=>{!0===t&&!1===i&&e.emit("refresh",{dataChanged:!0})})}_alignLayersDataModelAndInclusionDefinition(e){let t=new Set((e.entityTypes??[]).map(e=>e.name).concat((e.relationshipTypes??[]).map(e=>e.name))),i=new Set((e.entityTypes??[]).map(e=>e.name)),a=new Set((e.relationshipTypes??[]).map(e=>e.name));if(this.layers){for(let e of this.layers)!e.graphType&&t.has(e.graphTypeName)&&(e.graphType=i.has(e.graphTypeName)?"entity":"relationship");let e=this.layers.filter(e=>t.has(e.graphTypeName)&&("entity"===e.graphType?i.has(e.graphTypeName):a.has(e.graphTypeName)));this.setAtOrigin("layers",e,(0,y.OL)(this.originIdOf("layers")))}else this.layers=new o.A;if(this.layers&&this._originalInclusionList){let e=new Set(this._originalInclusionList.namedTypeDefinitions.keys()),t=this.tables?.map(e=>e.graphTypeName)??[],i=this.layers.map(e=>e.graphTypeName).concat(t);for(let t of i)e.has(t)||this._originalInclusionList.namedTypeDefinitions.set(t,{useAllData:!1,members:new Map});let a=[];for(let e of this._originalInclusionList.namedTypeDefinitions.keys())i.includes(e)||(l.A.getLogger(this).warn(`A named type, ${e}, was in the serialized feature collection but did not have a sublayer config in the item, so will be removed`),a.push(e));for(let e of a)this._originalInclusionList.namedTypeDefinitions.delete(e)}}};(0,a.Cg)([(0,g.MZ)(I.OZ)],W.prototype,"url",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"dataPreloadedInLocalCache",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"initializationLinkChartConfig",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"membershipModified",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"dataManager",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"initializationInclusionModeDefinition",null),(0,a.Cg)([(0,g.MZ)()],W.prototype,"knowledgeGraph",void 0),(0,a.Cg)([(0,g.MZ)({type:o.A.ofType(T.A),json:{write:{ignoreOrigin:!0}}})],W.prototype,"layers",void 0),(0,a.Cg)([(0,g.MZ)({readOnly:!0})],W.prototype,"linkChart",null),(0,a.Cg)([(0,g.MZ)()],W.prototype,"entityLinkChartDiagramLookup",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"relationshipLinkChartDiagramLookup",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"linkChartExtent",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"memberEntityTypes",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"memberRelationshipTypes",void 0),(0,a.Cg)([(0,g.MZ)({type:["LinkChartLayer"]})],W.prototype,"operationalLayerType",void 0),(0,a.Cg)([(0,g.MZ)()],W.prototype,"sublayerCapabilities",null),(0,a.Cg)([(0,g.MZ)()],W.prototype,"sublayerIdsCache",void 0),(0,a.Cg)([(0,g.MZ)({type:o.A.ofType(T.A),json:{write:{ignoreOrigin:!0}}})],W.prototype,"tables",void 0),(0,a.Cg)([(0,g.MZ)({json:{read:!1}})],W.prototype,"type",void 0),(0,a.Cg)([(0,g.MZ)({readOnly:!0})],W.prototype,"userHasEditingPrivileges",void 0),(0,a.Cg)([(0,g.MZ)({readOnly:!0})],W.prototype,"userHasFullEditingPrivileges",void 0),(0,a.Cg)([(0,g.MZ)({readOnly:!0})],W.prototype,"userHasUpdateItemPrivileges",void 0),(0,a.Cg)([(0,g.MZ)({json:{read:!1}})],W.prototype,"chronologicalAuxiliaryGraphics",void 0),(0,a.Cg)([(0,g.MZ)((0,V.P6)("dateFieldsTimeReference"))],W.prototype,"dateFieldsTimeZone",void 0),W=(0,a.Cg)([(0,g.$K)("esri.layers.LinkChartLayer")],W);const q=W}}]);