@arcgis/core 4.33.0-next.20250407 → 4.33.0-next.20250408

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 (251) hide show
  1. package/Color.js +1 -1
  2. package/assets/esri/core/workers/RemoteClient.js +1 -1
  3. package/assets/esri/core/workers/chunks/{69b5d0ef14fb521b0fd7.js → 04008648c59031bca8ea.js} +1 -1
  4. package/assets/esri/core/workers/chunks/07236fe57d76b1134cd4.js +1 -0
  5. package/assets/esri/core/workers/chunks/{6a8cf1f51cc4adc268d3.js → 0747c9542172241b52ab.js} +1 -1
  6. package/assets/esri/core/workers/chunks/083548c5eea5aca6404c.js +1 -0
  7. package/assets/esri/core/workers/chunks/0d37c6aa261c8d5e5b23.js +1 -0
  8. package/assets/esri/core/workers/chunks/0d7c1de47ae006277b76.js +1 -0
  9. package/assets/esri/core/workers/chunks/{9574896c90b39fa7ecb4.js → 10fd52bc5124fced5bcc.js} +1 -1
  10. package/assets/esri/core/workers/chunks/11b725421a823f6183a2.js +1 -0
  11. package/assets/esri/core/workers/chunks/{d9b2263e0a9f9068ab62.js → 14d1a970e927ebfed9c8.js} +1 -1
  12. package/assets/esri/core/workers/chunks/{0eed612e82a279ac8d1e.js → 1595f3def0ba0c4f0fe7.js} +1 -1
  13. package/assets/esri/core/workers/chunks/{1263391920fbb8926ced.js → 19eb465f91d07862926a.js} +1 -1
  14. package/assets/esri/core/workers/chunks/1c8cdae7736b6c907d95.js +1 -0
  15. package/assets/esri/core/workers/chunks/1cc4fc3353d217632a1b.js +1 -0
  16. package/assets/esri/core/workers/chunks/{91439b59260b0fb04be9.js → 238df0aee97315623638.js} +1 -1
  17. package/assets/esri/core/workers/chunks/{7ea5bbb52e84be9a608e.js → 23cc33576da66b3c4366.js} +1 -1
  18. package/assets/esri/core/workers/chunks/{358a3a9326615d5e6d3b.js → 2679da0c93f05ae956c6.js} +1 -1
  19. package/assets/esri/core/workers/chunks/26e0a0a13060cd3e4291.js +1 -0
  20. package/assets/esri/core/workers/chunks/{c2d0fc13f4b746318a38.js → 290f63304a2a81303c06.js} +1 -1
  21. package/assets/esri/core/workers/chunks/{e6544e966f14fb410157.js → 2d5cb817e6e905103068.js} +1 -1
  22. package/assets/esri/core/workers/chunks/345f428dfcaa594ee617.js +1 -0
  23. package/assets/esri/core/workers/chunks/35dccd3883d2e466c42e.js +1 -0
  24. package/assets/esri/core/workers/chunks/{fc5ca7b08915177c5e33.js → 364860a42edc0c3b8d5b.js} +1 -1
  25. package/assets/esri/core/workers/chunks/393fbd296817e813936c.js +1 -0
  26. package/assets/esri/core/workers/chunks/{82a58a405332d43a328f.js → 39fbac918ebd1b0e3a18.js} +1 -1
  27. package/assets/esri/core/workers/chunks/3a649aa78e25e3c8aa8c.js +1 -0
  28. package/assets/esri/core/workers/chunks/{4cc77769009901a112ec.js → 3b2bda2e8c08f486de27.js} +1 -1
  29. package/assets/esri/core/workers/chunks/3e1bb914aceb3a9af898.js +1 -0
  30. package/assets/esri/core/workers/chunks/3ee77b601fb0f3567e87.js +1 -0
  31. package/assets/esri/core/workers/chunks/40945669f5be487b340c.js +1 -0
  32. package/assets/esri/core/workers/chunks/43a3b1b78d214aadaaad.js +1 -0
  33. package/assets/esri/core/workers/chunks/49d03bdaa9c4476b69d6.js +1 -0
  34. package/assets/esri/core/workers/chunks/{1b87fa15470cce26feea.js → 49d6b56e21b1bc0d1948.js} +1 -1
  35. package/assets/esri/core/workers/chunks/4cbd5303f5a5a5fff391.js +1 -0
  36. package/assets/esri/core/workers/chunks/{40b33c9bd271cddbd837.js → 50ffb2620cdbcfd75723.js} +1 -1
  37. package/assets/esri/core/workers/chunks/544771f64a86b541d5bb.js +1 -0
  38. package/assets/esri/core/workers/chunks/55cc40d1b1853f779d82.js +1 -0
  39. package/assets/esri/core/workers/chunks/56e9dfd62102c32b9770.js +1 -0
  40. package/assets/esri/core/workers/chunks/576bed289aa7be03f319.js +1 -0
  41. package/assets/esri/core/workers/chunks/{b7a1185ac49480fc1410.js → 5c80452df87024fdaa75.js} +1 -1
  42. package/assets/esri/core/workers/chunks/5ef6acd36629eae225da.js +1 -0
  43. package/assets/esri/core/workers/chunks/{e592731ac12b9bc646ff.js → 60d3b329e69f3cddb7f4.js} +1 -1
  44. package/assets/esri/core/workers/chunks/{43b19c58b2d16ae8e7cc.js → 6275114e8ed9dd31465d.js} +1 -1
  45. package/assets/esri/core/workers/chunks/63ce66da1a52d6d07ccb.js +1 -0
  46. package/assets/esri/core/workers/chunks/6447d373a43ef6cd46cd.js +1 -0
  47. package/assets/esri/core/workers/chunks/64824ee75c643cee2aa9.js +1 -0
  48. package/assets/esri/core/workers/chunks/{48fbf887da6d19838bf0.js → 6a067a6ce0968d893142.js} +1 -1
  49. package/assets/esri/core/workers/chunks/6a70b858e24d98845041.js +1 -0
  50. package/assets/esri/core/workers/chunks/{c589d32f8efcca6bf712.js → 6c65b966f4c952508fc1.js} +1 -1
  51. package/assets/esri/core/workers/chunks/{cda6ae4c5cb67e22b454.js → 6d15d953baabccbbee01.js} +1 -1
  52. package/assets/esri/core/workers/chunks/6ecf2924f9f6aac61101.js +1 -0
  53. package/assets/esri/core/workers/chunks/{25a686f00479ac12a1ca.js → 6f9a17f62786af04b74e.js} +1 -1
  54. package/assets/esri/core/workers/chunks/77334c3fed1e3a06d307.js +1 -0
  55. package/assets/esri/core/workers/chunks/{7ef9bcd58af499a14a08.js → 79036c5d7569c4e94abe.js} +1 -1
  56. package/assets/esri/core/workers/chunks/{2ab7d36409e9af3ac3da.js → 7b47b08f4a58898273b9.js} +1 -1
  57. package/assets/esri/core/workers/chunks/{90442f47c9f31f26b453.js → 7f961954e59a232bfa88.js} +1 -1
  58. package/assets/esri/core/workers/chunks/{ccb289911e7445b17763.js → 86b4920f5a99576399fb.js} +2 -2
  59. package/assets/esri/core/workers/chunks/877f665c7edb26c147ea.js +1 -0
  60. package/assets/esri/core/workers/chunks/{8aae03e347ab18ae6ee2.js → 89e7cc489156ff0ebdb6.js} +1 -1
  61. package/assets/esri/core/workers/chunks/8c5619fdf125a459281d.js +1 -0
  62. package/assets/esri/core/workers/chunks/8e64687ee76e70deeb29.js +1 -0
  63. package/assets/esri/core/workers/chunks/{400f95295bbfced31076.js → 8ef755e6a7b2b71f46e6.js} +1 -1
  64. package/assets/esri/core/workers/chunks/8fe36b06a7eceeb874e9.js +1 -0
  65. package/assets/esri/core/workers/chunks/{269531e770376ed9e4fd.js → 90874dfe23035d16660c.js} +1 -1
  66. package/assets/esri/core/workers/chunks/91bb715f5ee87e97f162.js +1 -0
  67. package/assets/esri/core/workers/chunks/{5c757e20c0543e6a49b3.js → 948a3c1419ae323cca10.js} +1 -1
  68. package/assets/esri/core/workers/chunks/{7f31dbe0ca8974a10be8.js → 96cddbbeef61a4f33f29.js} +1 -1
  69. package/assets/esri/core/workers/chunks/{27b7ef3442700f6d6123.js → 9a84ff99756c7247dd39.js} +97 -96
  70. package/assets/esri/core/workers/chunks/9fddd759c308d3d5801a.js +1 -0
  71. package/assets/esri/core/workers/chunks/a29e99328d75b6ceb74d.js +1 -0
  72. package/assets/esri/core/workers/chunks/{af9fda47d02c51a2c7da.js → a32e697547f8ac345dd7.js} +1 -1
  73. package/assets/esri/core/workers/chunks/a426152e7eb550b8f15f.js +1 -0
  74. package/assets/esri/core/workers/chunks/a6de903f22f76d875005.js +1 -0
  75. package/assets/esri/core/workers/chunks/{90c893959145827961ac.js → aaf67ec3d580e1fee6c7.js} +1 -1
  76. package/assets/esri/core/workers/chunks/{d2c7067bb6654c0e2793.js → ac91bd1fee9ddadc270b.js} +1 -1
  77. package/assets/esri/core/workers/chunks/ae7c1e34ed1288773ec2.js +1 -0
  78. package/assets/esri/core/workers/chunks/ae9ebc0c0553e57e85ba.js +1 -0
  79. package/assets/esri/core/workers/chunks/{49ed3ab9bd6d7c52e864.js → af41dcc8006cd0f451c2.js} +1 -1
  80. package/assets/esri/core/workers/chunks/b199508eef1eeee72854.js +1 -0
  81. package/assets/esri/core/workers/chunks/b715fa857391931c04b9.js +1 -0
  82. package/assets/esri/core/workers/chunks/c144e00dfe6d63eaa2b1.js +1 -0
  83. package/assets/esri/core/workers/chunks/c150cd2a82260495e9de.js +1 -0
  84. package/assets/esri/core/workers/chunks/{2cbab0c078d0b844934c.js → c3c70dad8c8a93953237.js} +1 -1
  85. package/assets/esri/core/workers/chunks/c4425d5227f7e2379b0f.js +1 -0
  86. package/assets/esri/core/workers/chunks/c837379b36cf716d6215.js +1 -0
  87. package/assets/esri/core/workers/chunks/c849e3e151d78a061bf0.js +1 -0
  88. package/assets/esri/core/workers/chunks/{d2eb3802fa003c2d497e.js → caa5676636b06d743623.js} +1 -1
  89. package/assets/esri/core/workers/chunks/cb83fcfff8731c88c108.js +1 -0
  90. package/assets/esri/core/workers/chunks/cc366e4df91cf516d1b9.js +1 -0
  91. package/assets/esri/core/workers/chunks/ccd3f9b52006cd7dd11e.js +1 -0
  92. package/assets/esri/core/workers/chunks/d59aeb46bf2fb0931a9b.js +1 -0
  93. package/assets/esri/core/workers/chunks/{4ba34124054752b363c0.js → d65c30cd787b287833fb.js} +1 -1
  94. package/assets/esri/core/workers/chunks/d72d44df7e117e26e717.js +1 -0
  95. package/assets/esri/core/workers/chunks/e22cdfce2a0583f3cc50.js +1 -0
  96. package/assets/esri/core/workers/chunks/ee277dd58aa69281163f.js +1 -0
  97. package/assets/esri/core/workers/chunks/f086993f8744209d761f.js +1 -0
  98. package/assets/esri/core/workers/chunks/{8d49c79e549e90371303.js → fa2d836d4a844b26b84e.js} +1 -1
  99. package/assets/esri/core/workers/chunks/fb5b852d0f72df014377.js +1 -0
  100. package/assets/esri/core/workers/chunks/fb65796296b0422cf266.js +1 -0
  101. package/assets/esri/core/workers/chunks/fde544c090cc04581536.js +1 -0
  102. package/assets/esri/core/workers/chunks/fe2c48de24b25c45b3e7.js +1 -0
  103. package/chunks/CheckerBoard.glsl.js +3 -3
  104. package/chunks/ColorMaterial.glsl.js +3 -3
  105. package/chunks/ComponentShader.glsl.js +2 -2
  106. package/chunks/DefaultMaterial.glsl.js +5 -5
  107. package/chunks/ImageMaterial.glsl.js +1 -1
  108. package/chunks/LineMarker.glsl.js +4 -4
  109. package/chunks/Path.glsl.js +2 -2
  110. package/chunks/Pattern.glsl.js +3 -3
  111. package/chunks/Precipitation.glsl.js +1 -1
  112. package/chunks/RealisticTree.glsl.js +6 -6
  113. package/chunks/RibbonLine.glsl.js +1 -1
  114. package/chunks/ShadedColorMaterial.glsl.js +7 -7
  115. package/chunks/WaterSurface.glsl.js +3 -3
  116. package/chunks/vec32.js +1 -1
  117. package/colorUtils.js +1 -1
  118. package/core/libs/gl-matrix-2/math/quat.js +1 -1
  119. package/core/libs/gl-matrix-2/math/vec3.js +1 -1
  120. package/core/libs/gl-matrix-2/vec3.js +1 -1
  121. package/geometry/support/float16.js +1 -1
  122. package/geometry/support/meshUtils/merge.js +1 -1
  123. package/identity/IdentityManagerBase.js +1 -1
  124. package/interfaces.d.ts +13 -6
  125. package/layers/effects/parser.js +1 -1
  126. package/layers/support/rasterFunctions/creators/createDataManagementFunctions.js +1 -1
  127. package/package.json +2 -2
  128. package/support/revision.js +1 -1
  129. package/symbols/support/Symbol3DEmissive.js +5 -0
  130. package/symbols/support/Symbol3DFillMaterial.js +1 -1
  131. package/symbols/support/Symbol3DMaterial.js +1 -1
  132. package/symbols/support/materialUtils.js +1 -1
  133. package/views/2d/engine/vectorTiles/style/StyleProperty.js +1 -1
  134. package/views/2d/engine/webgl/shaderGraph/techniques/dotDensity/DotDensityMeshWriter.js +1 -1
  135. package/views/2d/engine/webgl/shaderGraph/techniques/fill/AFillMeshWriter.js +1 -1
  136. package/views/2d/engine/webgl/shaderGraph/techniques/fill/FillMeshWriter.js +1 -1
  137. package/views/2d/engine/webgl/shaderGraph/techniques/fill/GradientFillMeshWriter.js +1 -1
  138. package/views/2d/engine/webgl/shaderGraph/techniques/line/GradientStrokeMeshWriter.js +1 -1
  139. package/views/2d/engine/webgl/shaderGraph/techniques/line/LineMeshWriter.js +1 -1
  140. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/GradientStrokeShader.js +1 -1
  141. package/views/2d/layers/MediaLayerView2D.js +1 -1
  142. package/views/2d/layers/TileLayerView2D.js +1 -1
  143. package/views/3d/analysis/Dimension/lengthDimensionUtils.js +1 -1
  144. package/views/3d/analysis/LineOfSight/LineOfSightController.js +1 -1
  145. package/views/3d/analysis/LineOfSight/LineOfSightIntersectionResult.js +1 -1
  146. package/views/3d/analysis/Viewshed/ScaleOrientManipulation.js +1 -1
  147. package/views/3d/analysis/Viewshed/ViewshedSubTool.js +1 -1
  148. package/views/3d/analysis/Viewshed/ViewshedTool.js +1 -1
  149. package/views/3d/analysis/Viewshed/ViewshedVisualization.js +1 -1
  150. package/views/3d/interactive/editingTools/manipulations/MoveZManipulation.js +1 -1
  151. package/views/3d/interactive/visualElements/MeasurementArrowVisualElement.js +1 -1
  152. package/views/3d/layers/I3SMeshView3D.js +1 -1
  153. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  154. package/views/3d/layers/graphics/Deconflictor.js +1 -1
  155. package/views/3d/layers/graphics/Graphics3DExtrudeSymbolLayer.js +1 -1
  156. package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
  157. package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
  158. package/views/3d/layers/graphics/Graphics3DPathSymbolLayer.js +1 -1
  159. package/views/3d/layers/graphics/objectResourceUtils.js +1 -1
  160. package/views/3d/layers/i3s/I3SMaterialUtil.js +1 -1
  161. package/views/3d/layers/i3s/I3SViewportQueries.js +1 -1
  162. package/views/3d/layers/support/FeatureTileMeasurements3D.js +1 -1
  163. package/views/3d/layers/support/FeatureTileVisibility3D.js +1 -1
  164. package/views/3d/support/cameraUtils.js +1 -1
  165. package/views/3d/support/pointsOfInterest/Focus.js +1 -1
  166. package/views/3d/terrain/PatchRenderData.js +1 -1
  167. package/views/3d/terrain/SphericalPatch.js +1 -1
  168. package/views/3d/webgl-engine/collections/Component/Material/ComponentMaterial.js +1 -1
  169. package/views/3d/webgl-engine/core/shaderLibrary/output/Emissions.glsl.js +6 -5
  170. package/views/3d/webgl-engine/lib/ShadowAccumulator.js +1 -1
  171. package/views/3d/webgl-engine/lib/geometryDataUtils.js +1 -1
  172. package/views/3d/webgl-engine/lib/triangleIntersectionUtils.js +1 -1
  173. package/views/3d/webgl-engine/materials/DefaultMaterial.js +1 -1
  174. package/views/3d/webgl-engine/materials/LineMarkerMaterial.js +1 -1
  175. package/views/3d/webgl-engine/materials/PathMaterial.js +1 -1
  176. package/views/3d/webgl-engine/materials/PathTechnique.js +1 -1
  177. package/views/3d/webgl-engine/shaders/DefaultMaterialTechnique.js +1 -1
  178. package/views/3d/webgl-engine/shaders/OutputColorHighlightOID.glsl.js +8 -8
  179. package/views/SceneView.js +1 -1
  180. package/views/VideoView.js +1 -1
  181. package/views/interactive/SegmentLabels.js +1 -1
  182. package/views/interactive/coordinateHelper.js +1 -1
  183. package/views/interactive/editGeometry/operations/OffsetEdgeVertex.js +1 -1
  184. package/views/interactive/editGeometry/support/editPlaneUtils.js +1 -1
  185. package/views/interactive/sketch/constraints.js +1 -1
  186. package/views/interactive/snapping/GridSnappingEngine.js +1 -1
  187. package/views/interactive/tooltip/tooltipCommonUtils.js +1 -1
  188. package/views/support/geometry3dUtils.js +1 -1
  189. package/views/webgl/FramebufferObject.js +1 -1
  190. package/views/webgl/RenderbufferDescriptor.js +1 -1
  191. package/views/webgl/RenderingContext.js +1 -1
  192. package/views/webgl/TextureDescriptor.js +1 -1
  193. package/assets/esri/core/workers/chunks/066844a51cd22cbef0e6.js +0 -1
  194. package/assets/esri/core/workers/chunks/067dda58592fbf4fb812.js +0 -1
  195. package/assets/esri/core/workers/chunks/0a0e5d699ddb7052c5c0.js +0 -1
  196. package/assets/esri/core/workers/chunks/1014513c0ec85f9414a4.js +0 -1
  197. package/assets/esri/core/workers/chunks/1072b4f37eacbbfda2c8.js +0 -1
  198. package/assets/esri/core/workers/chunks/114599ed0752d9a70eef.js +0 -1
  199. package/assets/esri/core/workers/chunks/19e83b184d8b4d0b3007.js +0 -1
  200. package/assets/esri/core/workers/chunks/23de8aeed5b82c682cbe.js +0 -1
  201. package/assets/esri/core/workers/chunks/25ef080163f3f795911a.js +0 -1
  202. package/assets/esri/core/workers/chunks/277b61af8982092a4c81.js +0 -1
  203. package/assets/esri/core/workers/chunks/37e4f588a6896f98bce3.js +0 -1
  204. package/assets/esri/core/workers/chunks/3b7284516a0e34a9e85e.js +0 -1
  205. package/assets/esri/core/workers/chunks/3f6dc811b5d515c2725c.js +0 -1
  206. package/assets/esri/core/workers/chunks/4275dcec730a11173661.js +0 -1
  207. package/assets/esri/core/workers/chunks/4403b3f08907e88d0d91.js +0 -1
  208. package/assets/esri/core/workers/chunks/4523ba4a3c8987abca56.js +0 -1
  209. package/assets/esri/core/workers/chunks/47bbfc10c2a3b9e4bdd6.js +0 -1
  210. package/assets/esri/core/workers/chunks/4baef5262ce401bf81bb.js +0 -1
  211. package/assets/esri/core/workers/chunks/4e3b60156bee3b8b3367.js +0 -1
  212. package/assets/esri/core/workers/chunks/519028f42b817d3e9933.js +0 -1
  213. package/assets/esri/core/workers/chunks/61737e442b1f8e86164e.js +0 -1
  214. package/assets/esri/core/workers/chunks/705c1ebb327f680f8519.js +0 -1
  215. package/assets/esri/core/workers/chunks/7099564a8853b81ba181.js +0 -1
  216. package/assets/esri/core/workers/chunks/72d7e45e7eb28f2cc0b0.js +0 -1
  217. package/assets/esri/core/workers/chunks/72f4cea853ce9fcf2cb6.js +0 -1
  218. package/assets/esri/core/workers/chunks/759c12b0715279e3c0f6.js +0 -1
  219. package/assets/esri/core/workers/chunks/7655be1470ce39f0e494.js +0 -1
  220. package/assets/esri/core/workers/chunks/796cf1c2ca9955595836.js +0 -1
  221. package/assets/esri/core/workers/chunks/7ccc02a4ec6d3552ecca.js +0 -1
  222. package/assets/esri/core/workers/chunks/80427cd9f0c2e07f21c3.js +0 -1
  223. package/assets/esri/core/workers/chunks/8221f2e540abe1e0f048.js +0 -1
  224. package/assets/esri/core/workers/chunks/82353e59ac6d909dcf41.js +0 -1
  225. package/assets/esri/core/workers/chunks/86931186095c23e47c0c.js +0 -1
  226. package/assets/esri/core/workers/chunks/8f35416a5036897d6289.js +0 -1
  227. package/assets/esri/core/workers/chunks/8fecd1337d84c26c692b.js +0 -1
  228. package/assets/esri/core/workers/chunks/9050dad7e4f093568026.js +0 -1
  229. package/assets/esri/core/workers/chunks/9643a9516783e8c32180.js +0 -1
  230. package/assets/esri/core/workers/chunks/9e156e135f34f9b06032.js +0 -1
  231. package/assets/esri/core/workers/chunks/a3421383e48379012c9c.js +0 -1
  232. package/assets/esri/core/workers/chunks/a91f2d1deb950f46ad09.js +0 -1
  233. package/assets/esri/core/workers/chunks/b4a1f3f3a036226d6810.js +0 -1
  234. package/assets/esri/core/workers/chunks/bd0dbad694ce5531deab.js +0 -1
  235. package/assets/esri/core/workers/chunks/c6580fdcdc33153008b0.js +0 -1
  236. package/assets/esri/core/workers/chunks/c68c68e918c72932b247.js +0 -1
  237. package/assets/esri/core/workers/chunks/cc307d34a68e44e3cbc5.js +0 -1
  238. package/assets/esri/core/workers/chunks/d3b0117ad9232e36f785.js +0 -1
  239. package/assets/esri/core/workers/chunks/d46c82a55219b27c301b.js +0 -1
  240. package/assets/esri/core/workers/chunks/d89f105b8a0b13dd8e5f.js +0 -1
  241. package/assets/esri/core/workers/chunks/daa54c8a317c27881763.js +0 -1
  242. package/assets/esri/core/workers/chunks/e08bff9f8247909776a4.js +0 -1
  243. package/assets/esri/core/workers/chunks/e15c612caadf7bac4ab9.js +0 -1
  244. package/assets/esri/core/workers/chunks/e5aff9b10877fb04d6de.js +0 -1
  245. package/assets/esri/core/workers/chunks/e792603b7cc3ddd133f3.js +0 -1
  246. package/assets/esri/core/workers/chunks/eaead9e927ebadcf2cc3.js +0 -1
  247. package/assets/esri/core/workers/chunks/ed517687b3728fd2eb64.js +0 -1
  248. package/assets/esri/core/workers/chunks/f41a9ceb8e49baafe9fa.js +0 -1
  249. package/assets/esri/core/workers/chunks/f5fcba6ca6f43bf1d65d.js +0 -1
  250. package/assets/esri/core/workers/chunks/f7d33d18bf1bd4db9df8.js +0 -1
  251. package/assets/esri/core/workers/chunks/f9396af9cbfd165e72e2.js +0 -1
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5356,5613],{4513:(e,a,r)=>{r.d(a,{S:()=>t});const t={BingMapsLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(7690)]).then(r.bind(r,17029))).default,BuildingSceneLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(6213),r.e(2944),r.e(958),r.e(4654),r.e(6298),r.e(1961)]).then(r.bind(r,88303))).default,CSVLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(9070)]).then(r.bind(r,72256))).default,CatalogLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(4111),r.e(8506),r.e(364),r.e(8628),r.e(2593),r.e(2696),r.e(4178)]).then(r.bind(r,79003))).default,DimensionLayer:async()=>(await Promise.all([r.e(6131),r.e(3813)]).then(r.bind(r,71493))).default,ElevationLayer:async()=>(await Promise.all([r.e(6131),r.e(9953),r.e(9186),r.e(2955)]).then(r.bind(r,68611))).default,FeatureLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(5483)]).then(r.bind(r,13600))).default,GeoJSONLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4927)]).then(r.bind(r,17625))).default,GeoRSSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(3740)]).then(r.bind(r,63201))).default,GroupLayer:async()=>(await Promise.all([r.e(6131),r.e(3562),r.e(8256)]).then(r.bind(r,85989))).default,ImageryLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1956),r.e(9953),r.e(364),r.e(984),r.e(2439),r.e(272)]).then(r.bind(r,58434))).default,ImageryTileLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(9953),r.e(984),r.e(6049),r.e(2439),r.e(7677),r.e(5943)]).then(r.bind(r,35943))).default,IntegratedMesh3DTilesLayer:async()=>(await Promise.all([r.e(6131),r.e(107)]).then(r.bind(r,61528))).default,IntegratedMeshLayer:async()=>(await Promise.all([r.e(6131),r.e(6298),r.e(6858)]).then(r.bind(r,84453))).default,KMLLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(5026)]).then(r.bind(r,79465))).default,KnowledgeGraphLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(6760),r.e(8613),r.e(7475),r.e(2083),r.e(8692)]).then(r.bind(r,28692))).default,LineOfSightLayer:async()=>(await Promise.all([r.e(6131),r.e(6213),r.e(6360),r.e(9695)]).then(r.bind(r,49695))).default,LinkChartLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(6760),r.e(8613),r.e(7475),r.e(2083),r.e(1728)]).then(r.bind(r,71728))).default,MapImageLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(4111),r.e(364),r.e(4341),r.e(7656),r.e(6928)]).then(r.bind(r,7656))).default,MapNotesLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(7475),r.e(2936)]).then(r.bind(r,96953))).default,MediaLayer:async()=>(await Promise.all([r.e(6131),r.e(2763)]).then(r.bind(r,19647))).default,OGCFeatureLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(3029),r.e(2905),r.e(4934)]).then(r.bind(r,87152))).default,OpenStreetMapLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(5177),r.e(349)]).then(r.bind(r,40349))).default,OrientedImageryLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(9835)]).then(r.bind(r,97927))).default,PointCloudLayer:async()=>(await Promise.all([r.e(6131),r.e(8948),r.e(7984),r.e(6742)]).then(r.bind(r,76742))).default,RouteLayer:async()=>(await Promise.all([r.e(6131),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(7634)]).then(r.bind(r,64185))).default,SceneLayer:async()=>(await Promise.all([r.e(6131),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(6213),r.e(2944),r.e(958),r.e(4654),r.e(6298),r.e(6462)]).then(r.bind(r,13899))).default,StreamLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(3029),r.e(505)]).then(r.bind(r,60683))).default,SubtypeGroupLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1956),r.e(4796),r.e(4111),r.e(8506),r.e(1162)]).then(r.bind(r,59929))).default,TileLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(4111),r.e(364),r.e(9186),r.e(4341),r.e(8535)]).then(r.bind(r,71756))).default,UnknownLayer:async()=>(await r.e(146).then(r.bind(r,146))).default,UnsupportedLayer:async()=>(await r.e(5165).then(r.bind(r,45165))).default,VectorTileLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(9186),r.e(9949),r.e(5013),r.e(4429)]).then(r.bind(r,48757))).default,VideoLayer:async()=>(await r.e(6875).then(r.bind(r,86875))).default,ViewshedLayer:async()=>(await Promise.all([r.e(6131),r.e(6213),r.e(6360),r.e(6650)]).then(r.bind(r,96650))).default,VoxelLayer:async()=>(await Promise.all([r.e(6131),r.e(8948),r.e(6183)]).then(r.bind(r,16183))).default,WCSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(9953),r.e(984),r.e(6049),r.e(2439),r.e(7677),r.e(9547)]).then(r.bind(r,19547))).default,WFSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(7396)]).then(r.bind(r,16350))).default,WMSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(1904)]).then(r.bind(r,51904))).default,WMTSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(5177),r.e(309)]).then(r.bind(r,20309))).default,WebTileLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(5177)]).then(r.bind(r,47314))).default}},8947:(e,a,r)=>{r.d(a,{L:()=>s});var t=r(60999),n=r(74887),i=r(67076);async function s(e,a,r){const s=e&&e.getAtOrigin&&e.getAtOrigin("renderer",a.origin);if(s&&"unique-value"===s.type&&s.styleOrigin){const l=await(0,t.Ke)(s.populateFromStyle());if((0,n.Te)(r),!1===l.ok){const r=l.error;a?.messages&&a.messages.push(new i.A("renderer:style-reference",`Failed to create unique value renderer from style reference: ${r.message}`,{error:r,context:a})),e.clear("renderer",a?.origin)}}}},10407:(e,a,r)=>{r.d(a,{It:()=>L,LG:()=>s,OM:()=>y,Sm:()=>o,Y:()=>l,bK:()=>c,mm:()=>d,sQ:()=>u});var t=r(80586),n=r(16930),i=r(28735);function s(e,a){if(!l(e,a)){const r=e.typeKeywords;r?r.push(a):e.typeKeywords=[a]}}function l(e,a){return!!e.typeKeywords?.includes(a)}function c(e){return l(e,d.HOSTED_SERVICE)}function y(e,a){const r=e.typeKeywords;if(r){const e=r.indexOf(a);e>-1&&r.splice(e,1)}}function o(e,a,r){r?s(e,a):y(e,a)}async function u(e){const a=e.clone().normalize();let r;if(a.length>1)for(const e of a)r?e.width>r.width&&(r=e):r=e;else r=a[0];return async function(e){const a=e.spatialReference;if(a.isWGS84)return e.clone();if(a.isWebMercator)return(0,i.ci)(e);const r=n.A.WGS84;return await(0,t.initializeProjection)(a,r),(0,t.project)(e,r)}(r)}const d={DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery"};function L(e){const{portal:a,isOrgItem:r,itemControl:t}=e,n=a.user?.privileges;let i=!n||n.includes("features:user:edit"),s=!!r&&!!n?.includes("features:user:fullEdit");const l="update"===t||"admin"===t;return l?s=i=!0:s&&(i=!0),{features:{edit:i,fullEdit:s},content:{updateItem:l}}}},22429:(e,a,r)=>{r.d(a,{v:()=>n});var t=r(24183);class n{constructor(){this._serviceMetadatas=new Map,this._itemDatas=new Map}async fetchServiceMetadata(e,a){const r=this._serviceMetadatas.get(e);if(r)return r;const n=await(0,t.V)(e,a);return this._serviceMetadatas.set(e,n),n}async fetchItemData(e){const{id:a}=e;if(!a)return null;const{_itemDatas:r}=this;if(r.has(a))return r.get(a);const t=await e.fetchData();return r.set(a,t),t}async fetchCustomParameters(e,a){const r=await this.fetchItemData(e);return r&&"object"==typeof r&&(a?a(r):r.customParameters)||null}}},23154:(e,a,r)=>{r.d(a,{K:()=>d,Q:()=>i});var t=r(24183);const n=new Set(["Catalog Layer","Feature Layer","Oriented Imagery Layer"]);async function i(e,a){const{loadContext:r,...n}=a||{},i=r?await r.fetchServiceMetadata(e,n):await(0,t.V)(e,n);u(i),c(i);const s={serviceJSON:i};if((i.currentVersion??0)<10.5)return s;const l=`${e}/layers`,y=r?await r.fetchServiceMetadata(l,n):await(0,t.V)(l,n);return u(y),c(y),s.layersJSON={layers:y.layers,tables:y.tables},s}function s(e){const{type:a}=e;return!!a&&n.has(a)}function l(e){return"Table"===e.type}function c(e){e.layers=e.layers?.filter(s),e.tables=e.tables?.filter(l)}function y(e){e.type||="Feature Layer"}function o(e){e.type||="Table"}function u(e){e.layers?.forEach(y),e.tables?.forEach(o)}function d(e){switch(e){case"Feature Layer":case"Table":return"FeatureLayer";case"Oriented Imagery Layer":return"OrientedImageryLayer";case"Catalog Layer":return"CatalogLayer"}return"FeatureLayer"}},24183:(e,a,r)=>{r.d(a,{V:()=>n});var t=r(78888);async function n(e,a){const{data:r}=await(0,t.A)(e,{responseType:"json",query:{f:"json",...a?.customParameters,token:a?.apiKey}});return r}},45613:(e,a,r)=>{r.d(a,{fromItem:()=>d,n:()=>L});var t=r(49186),n=r(92009),i=r(23154),s=r(22429),l=r(83531),c=r(4513),y=r(80812),o=r(66964),u=r(10407);async function d(e){let{portalItem:a}=e;!a||a instanceof y.default||(a=new y.default(a));const r=await async function(e){await e.load();const a=new s.v;return async function(e){const a=e.className,r=c.S[a];return{constructor:await r(),properties:e.properties}}(await L(e,a))}(a);return new(0,r.constructor)({portalItem:a,...r.properties})}async function L(e,a){switch(e.type){case"3DTiles Service":return e.typeKeywords.includes("3DObject")?{className:"UnsupportedLayer"}:{className:"IntegratedMesh3DTilesLayer"};case"CSV":return{className:"CSVLayer"};case"Feature Collection":return async function(e){await e.load();const a=(0,u.Y)(e,"Map Notes"),r=(0,u.Y)(e,"Markup");if(a||r)return{className:"MapNotesLayer"};if((0,u.Y)(e,"Route Layer"))return{className:"RouteLayer"};const t=await e.fetchData();return 1===(0,o.XH)(t)?{className:"FeatureLayer"}:{className:"GroupLayer"}}(e);case"Feature Service":return async function(e,a){const r=await f(e,a);if("object"==typeof r){const{sourceJSON:e,className:a}=r,t={sourceJSON:e};return null!=r.id&&(t.layerId=r.id),{className:a||"FeatureLayer",properties:t}}return{className:"GroupLayer"}}(e,a);case"Feed":case"Stream Service":return{className:"StreamLayer"};case"GeoJson":return{className:"GeoJSONLayer"};case"Group Layer":return{className:"GroupLayer"};case"Image Service":return async function(e,a){await e.load();const r=e.typeKeywords?.map((e=>e.toLowerCase()))??[];if(r.includes("elevation 3d layer"))return{className:"ElevationLayer"};if(r.includes("tiled imagery"))return{className:"ImageryTileLayer"};const t=await a.fetchItemData(e),n=t?.layerType;if("ArcGISTiledImageServiceLayer"===n)return{className:"ImageryTileLayer"};if("ArcGISImageServiceLayer"===n)return{className:"ImageryLayer"};const i=await a.fetchServiceMetadata(e.url,{customParameters:await a.fetchCustomParameters(e)}),s=i.cacheType?.toLowerCase(),l=i.capabilities?.toLowerCase().includes("tilesonly"),c=i.tileInfo?.format?.toLowerCase()??"",y=null==s&&["jpg","jpeg","png","png8","png24","png32","mixed"].includes(c);return"map"===s||y||l?{className:"ImageryTileLayer"}:{className:"ImageryLayer"}}(e,a);case"KML":return{className:"KMLLayer"};case"Knowledge Graph Layer":return{className:"KnowledgeGraphLayer"};case"Map Service":return async function(e,a){return await async function(e,a){const{tileInfo:r}=await a.fetchServiceMetadata(e.url,{customParameters:await a.fetchCustomParameters(e)});return r}(e,a)?{className:"TileLayer"}:{className:"MapImageLayer"}}(e,a);case"Media Layer":return{className:"MediaLayer"};case"Scene Service":return async function(e,a){const r=await f(e,a,(async()=>{try{if(!e.url)return[];const{serverUrl:r}=await(0,n.L)(e.url,{sceneLayerItem:e}),t=await a.fetchServiceMetadata(r);return t?.tables??[]}catch{return[]}}));if("object"==typeof r){const t={};let n;if(null!=r.id?(t.layerId=r.id,n=`${e.url}/layers/${r.id}`):n=e.url,e.typeKeywords?.length)for(const a of Object.keys(l.XX))if(e.typeKeywords.includes(a))return{className:l.XX[a]};const i=await a.fetchServiceMetadata(n,{customParameters:await a.fetchCustomParameters(e,(e=>(0,o.pJ)(e)?.customParameters))});return{className:l.XX[i?.layerType]||"SceneLayer",properties:t}}if(!1===r){const r=await a.fetchServiceMetadata(e.url);if("Voxel"===r?.layerType)return{className:"VoxelLayer"}}return{className:"GroupLayer"}}(e,a);case"Vector Tile Service":return{className:"VectorTileLayer"};case"WCS":return{className:"WCSLayer"};case"WFS":return{className:"WFSLayer"};case"WMS":return{className:"WMSLayer"};case"WMTS":return{className:"WMTSLayer"};default:throw new t.A("portal:unknown-item-type","Unknown item type '${type}'",{type:e.type})}}async function f(e,a,r){const{url:t,type:n}=e,s="Feature Service"===n;if(!t)return{};if(/\/\d+$/.test(t)){if(s){const r=await a.fetchServiceMetadata(t,{customParameters:await a.fetchCustomParameters(e,(e=>(0,o.pJ)(e)?.customParameters))});return{id:r.id,className:(0,i.K)(r.type),sourceJSON:r}}return{}}await e.load();let l=await a.fetchItemData(e);if(s){const e=await(0,o.bO)(l,t,a),r=m(e);if("object"==typeof r){const a=(0,o.rc)(e,r.id);r.className=(0,o.K8)(a?.layerType)}return r}if("Scene Service"===n&&(l=await(0,o.nu)(e,l,a)),(0,o.XH)(l)>0)return m(l);const c=await a.fetchServiceMetadata(t);return r&&(c.tables=await r()),m(c)}function m(e){return 1===(0,o.XH)(e)&&{id:(0,o.pJ)(e)?.id}}},66964:(e,a,r)=>{r.d(a,{Ju:()=>y,K8:()=>d,XH:()=>o,_r:()=>i,bO:()=>s,l:()=>u,nu:()=>L,pJ:()=>l,rc:()=>c});var t=r(92009),n=r(23154);function i(e){const a={id:e.id,name:e.name},r=(0,n.K)(e.type);return"FeatureLayer"!==r&&(a.layerType=r),a}async function s(e,a,r){if(null==e?.layers||null==e?.tables){const t=await r.fetchServiceMetadata(a,{customParameters:l(e)?.customParameters});(e=e||{}).layers=e.layers||t?.layers?.map(i),e.tables=e.tables||t?.tables?.map(i)}return e}function l(e){if(!e)return null;const{layers:a,tables:r}=e;return a?.length?a[0]:r?.length?r[0]:null}function c(e,a){return null==a?null:[...e.layers||[],...e.tables||[]].find((e=>e.id===a))}function y(e,a){return[...e.layers||[],...e.tables||[]].filter((({layerType:e})=>e?a.includes(e):a.includes("ArcGISFeatureLayer")))}function o(e){return(e?.layers?.length??0)+(e?.tables?.length??0)}function u(e){switch(e){case"catalog":return["CatalogLayer"];case"feature":return["ArcGISFeatureLayer"];case"oriented-imagery":return["OrientedImageryLayer"];case"subtype-group":return["SubtypeGroupLayer","SubtypeGroupTable"]}return null}function d(e){switch(e){case"CatalogLayer":return"CatalogLayer";case"OrientedImageryLayer":return"OrientedImageryLayer";case"SubtypeGroupLayer":case"SubtypeGroupTable":return"SubtypeGroupLayer"}return"FeatureLayer"}async function L(e,a,r){if(!e?.url)return a??{};if(a??={},!a.layers){const t=await r.fetchServiceMetadata(e.url);a.layers=t.layers?.map(i)}const{serverUrl:n,portalItem:s}=await(0,t.L)(e.url,{sceneLayerItem:e,customParameters:l(a)?.customParameters}).catch((()=>({serverUrl:null,portalItem:null})));if(null==n)return a.tables=[],a;if(!a.tables&&s){const e=await s.fetchData().catch((()=>null));if(e?.tables)a.tables=e.tables.map(i);else{const t=await r.fetchServiceMetadata(n,{customParameters:l(e)?.customParameters}).catch((()=>null));a.tables=t?.tables?.map(i)}}if(a.tables)for(const e of a.tables)e.url=`${n}/${e.id}`;return a}},75356:(e,a,r)=>{r.d(a,{N:()=>M,populateOperationalLayers:()=>o});var t=r(5503),n=(r(44208),r(22429)),i=r(4513),s=r(80812);function l(e,a){return!(!e.layerType||"ArcGISFeatureLayer"!==e.layerType)&&e.featureCollectionType===a}var c=r(45613),y=r(8947);async function o(e,a,r){if(!a)return;const t=a.map((e=>async function(e,a){return async function(e,a,r){const t=new e;return t.read(a,r.context),"group"===t.type&&("GroupLayer"===a.layerType?await M(t,a,r):v(a)?function(e,a,r){a.itemId&&(e.portalItem=new s.default({id:a.itemId,portal:r?.portal}),e.when((()=>{const t=t=>{const n=t.layerId;G(t,e,a,n,r);const i=a.featureCollection?.layers?.[n];i&&t.read(i,r)};e.layers?.forEach(t),e.tables?.forEach(t)})))}(t,a,r.context):b(a)&&await async function(e,a,r){const t=i.S.FeatureLayer,n=await t(),s=a.featureCollection,l=s?.showLegend,c=s?.layers?.map(((t,i)=>{const s=new n;s.read(t,r);const c={...r,ignoreDefaults:!0};return G(s,e,a,i,c),null!=l&&s.read({showLegend:l},c),s}));e.layers.addMany(c??[])}(t,a,r.context)),await(0,y.L)(t,r.context),t}(await I(e,a),e,a)}(e,r))),n=await Promise.allSettled(t);for(const a of n)"rejected"===a.status||a.value&&e.add(a.value)}const u={ArcGISDimensionLayer:"DimensionLayer",ArcGISFeatureLayer:"FeatureLayer",ArcGISImageServiceLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISSceneServiceLayer:"SceneLayer",ArcGISTiledElevationServiceLayer:"ElevationLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",BuildingSceneLayer:"BuildingSceneLayer",CatalogLayer:"CatalogLayer",CSV:"CSVLayer",DefaultTileLayer:"TileLayer",GeoJSON:"GeoJSONLayer",GroupLayer:"GroupLayer",IntegratedMesh3DTilesLayer:"IntegratedMesh3DTilesLayer",Object3DTilesLayer:"UnsupportedLayer",IntegratedMeshLayer:"IntegratedMeshLayer",KML:"KMLLayer",LineOfSightLayer:"LineOfSightLayer",MediaLayer:"MediaLayer",OGCFeatureLayer:"OGCFeatureLayer",OrientedImageryLayer:"OrientedImageryLayer",PointCloudLayer:"PointCloudLayer",RasterDataLayer:"UnsupportedLayer",VectorTileLayer:"VectorTileLayer",ViewshedLayer:"ViewshedLayer",Voxel:"VoxelLayer",WCS:"WCSLayer",WFS:"WFSLayer",WMS:"WMSLayer",WebTiledLayer:"WebTileLayer"},d={ArcGISTiledElevationServiceLayer:"ElevationLayer",DefaultTileLayer:"ElevationLayer",RasterDataElevationLayer:"UnsupportedLayer"},L={ArcGISFeatureLayer:"FeatureLayer"},f={ArcGISImageServiceLayer:"UnsupportedLayer",ArcGISMapServiceLayer:"UnsupportedLayer",ArcGISSceneServiceLayer:"SceneLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",DefaultTileLayer:"TileLayer",OpenStreetMap:"OpenStreetMapLayer",VectorTileLayer:"VectorTileLayer",WCS:"UnsupportedLayer",WMS:"UnsupportedLayer",WebTiledLayer:"WebTileLayer"},m={ArcGISAnnotationLayer:"UnsupportedLayer",ArcGISDimensionLayer:"UnsupportedLayer",ArcGISFeatureLayer:"FeatureLayer",ArcGISImageServiceLayer:"ImageryLayer",ArcGISImageServiceVectorLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISStreamLayer:"StreamLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",BingMapsAerial:"BingMapsLayer",BingMapsHybrid:"BingMapsLayer",BingMapsRoad:"BingMapsLayer",CatalogLayer:"CatalogLayer",CSV:"CSVLayer",DefaultTileLayer:"TileLayer",GeoJSON:"GeoJSONLayer",GeoRSS:"GeoRSSLayer",GroupLayer:"GroupLayer",KML:"KMLLayer",KnowledgeGraphLayer:"KnowledgeGraphLayer",MediaLayer:"MediaLayer",OGCFeatureLayer:"OGCFeatureLayer",OrientedImageryLayer:"OrientedImageryLayer",SubtypeGroupLayer:"SubtypeGroupLayer",VectorTileLayer:"VectorTileLayer",WCS:"WCSLayer",WFS:"WFSLayer",WMS:"WMSLayer",WebTiledLayer:"WebTileLayer"},p={ArcGISFeatureLayer:"FeatureLayer",SubtypeGroupTable:"SubtypeGroupLayer"},S={ArcGISImageServiceLayer:"ImageryLayer",ArcGISImageServiceVectorLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",BingMapsAerial:"BingMapsLayer",BingMapsHybrid:"BingMapsLayer",BingMapsRoad:"BingMapsLayer",DefaultTileLayer:"TileLayer",OpenStreetMap:"OpenStreetMapLayer",VectorTileLayer:"VectorTileLayer",WCS:"WCSLayer",WMS:"WMSLayer",WebTiledLayer:"WebTileLayer"},w={...m,LinkChartLayer:"LinkChartLayer"},h={...p},g={...S};async function I(e,a){const r=a.context,t=T(r);let y=e.layerType||e.type;!y&&a?.defaultLayerType&&(y=a.defaultLayerType);const o=t[y];let u=o?i.S[o]:i.S.UnknownLayer;if(v(e)){const a=r?.portal;if(e.itemId){const r=new s.default({id:e.itemId,portal:a});await r.load();const t=(await(0,c.n)(r,new n.v)).className||"UnknownLayer";u=i.S[t]}}else"ArcGISFeatureLayer"===y?function(e){return l(e,"notes")}(e)||function(e){return l(e,"markup")}(e)?u=i.S.MapNotesLayer:function(e){return l(e,"route")}(e)?u=i.S.RouteLayer:b(e)&&(u=i.S.GroupLayer):e.wmtsInfo?.url&&e.wmtsInfo.layerIdentifier?u=i.S.WMTSLayer:"WFS"===y&&"2.0.0"!==e.wfsInfo?.version&&(u=i.S.UnsupportedLayer);return u()}function b(e){return"ArcGISFeatureLayer"===e.layerType&&!v(e)&&(e.featureCollection?.layers?.length??0)>1}function v(e){return"Feature Collection"===e.type}function T(e){let a;switch(e.origin){case"web-scene":switch(e.layerContainerType){case"basemap":a=f;break;case"ground":a=d;break;case"tables":a=L;break;default:a=u}break;case"link-chart":switch(e.layerContainerType){case"basemap":a=g;break;case"tables":a=h;break;default:a=w}break;default:switch(e.layerContainerType){case"basemap":a=S;break;case"tables":a=p;break;default:a=m}}return a}async function M(e,a,r){const n=new t.A,i=o(n,Array.isArray(a.layers)?a.layers:[],r);try{try{if(await i,"group"===e.type)return e.layers.addMany(n),e}catch(a){e.destroy();for(const e of n)e.destroy();throw a}}catch(e){throw e}}function G(e,a,r,t,n){e.read({id:`${a.id}-sublayer-${t}`,visibility:r.visibleLayers?.includes(t)??!0},n)}},92009:(e,a,r)=>{r.d(a,{L:()=>o});var t=r(70333),n=r(78888),i=r(49186),s=r(74887),l=r(60694),c=r(20655),y=r(80812);async function o(e,a){const r=(0,l.qg)(e);if(!r)throw new i.A("invalid-url","Invalid scene service url");const o={...a,sceneServerUrl:r.url.path,layerId:r.sublayer??void 0};if(o.sceneLayerItem??=await async function(e){const a=(await u(e)).serviceItemId;if(!a)return null;const r=new y.default({id:a,apiKey:e.apiKey}),i=await async function(e){const a=t.id?.findServerInfo(e.sceneServerUrl);if(a?.owningSystemUrl)return a.owningSystemUrl;const r=e.sceneServerUrl.replace(/(.*\/rest)\/.*/i,"$1")+"/info";try{const a=(await(0,n.A)(r,{query:{f:"json"},responseType:"json",signal:e.signal})).data.owningSystemUrl;if(a)return a}catch(e){(0,s.QP)(e)}return null}(e);null!=i&&(r.portal=new c.A({url:i}));try{return await r.load({signal:e.signal})}catch(e){return(0,s.QP)(e),null}}(o),null==o.sceneLayerItem)return d(o.sceneServerUrl.replace("/SceneServer","/FeatureServer"),o);const L=await async function({sceneLayerItem:e,signal:a}){if(!e)return null;try{const r=(await e.fetchRelatedItems({relationshipType:"Service2Service",direction:"reverse"},{signal:a})).find((e=>"Feature Service"===e.type))||null;if(!r)return null;const t=new y.default({portal:r.portal,id:r.id});return await t.load(),t}catch(e){return(0,s.QP)(e),null}}(o);if(!L?.url)throw new i.A("related-service-not-found","Could not find feature service through portal item relationship");o.featureServiceItem=L;const f=await d(L.url,o);return f.portalItem=L,f}async function u(e){if(e.rootDocument)return e.rootDocument;const a={query:{f:"json",...e.customParameters,token:e.apiKey},responseType:"json",signal:e.signal};try{const r=await(0,n.A)(e.sceneServerUrl,a);e.rootDocument=r.data}catch{e.rootDocument={}}return e.rootDocument}async function d(e,a){const r=(0,l.qg)(e);if(!r)throw new i.A("invalid-feature-service-url","Invalid feature service url");const t=r.url.path,s=a.layerId;if(null==s)return{serverUrl:t};const c=u(a),y=a.featureServiceItem?await a.featureServiceItem.fetchData("json"):null,o=(y?.layers?.[0]||y?.tables?.[0])?.customParameters,d=e=>{const r={query:{f:"json",...o},responseType:"json",authMode:e,signal:a.signal};return(0,n.A)(t,r)},L=d("anonymous").catch((()=>d("no-prompt"))),[f,m]=await Promise.all([L,c]),p=m?.layers,S=f.data&&f.data.layers;if(!Array.isArray(S))throw new Error("expected layers array");if(Array.isArray(p)){for(let e=0;e<Math.min(p.length,S.length);e++)if(p[e].id===s)return{serverUrl:t,layerId:S[e].id}}else if(null!=s&&s<S.length)return{serverUrl:t,layerId:S[s].id};throw new Error("could not find matching associated sublayer")}}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5356,5613],{4513:(e,a,r)=>{r.d(a,{S:()=>t});const t={BingMapsLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(7690)]).then(r.bind(r,17029))).default,BuildingSceneLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(6213),r.e(2944),r.e(958),r.e(4654),r.e(6298),r.e(1961)]).then(r.bind(r,88303))).default,CSVLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(9070)]).then(r.bind(r,72256))).default,CatalogLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(4111),r.e(8506),r.e(364),r.e(8628),r.e(2593),r.e(2696),r.e(4178)]).then(r.bind(r,79003))).default,DimensionLayer:async()=>(await Promise.all([r.e(6131),r.e(3813)]).then(r.bind(r,71493))).default,ElevationLayer:async()=>(await Promise.all([r.e(6131),r.e(9953),r.e(9186),r.e(2955)]).then(r.bind(r,68611))).default,FeatureLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(5483)]).then(r.bind(r,13600))).default,GeoJSONLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4927)]).then(r.bind(r,17625))).default,GeoRSSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(3740)]).then(r.bind(r,63201))).default,GroupLayer:async()=>(await Promise.all([r.e(6131),r.e(3562),r.e(8256)]).then(r.bind(r,85989))).default,ImageryLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1956),r.e(9953),r.e(364),r.e(984),r.e(2439),r.e(272)]).then(r.bind(r,58434))).default,ImageryTileLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(9953),r.e(984),r.e(6049),r.e(2439),r.e(7677),r.e(5943)]).then(r.bind(r,35943))).default,IntegratedMesh3DTilesLayer:async()=>(await Promise.all([r.e(6131),r.e(107)]).then(r.bind(r,61528))).default,IntegratedMeshLayer:async()=>(await Promise.all([r.e(6131),r.e(6298),r.e(6858)]).then(r.bind(r,84453))).default,KMLLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(5026)]).then(r.bind(r,79465))).default,KnowledgeGraphLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(6760),r.e(8613),r.e(7475),r.e(2083),r.e(8692)]).then(r.bind(r,28692))).default,LineOfSightLayer:async()=>(await Promise.all([r.e(6131),r.e(6213),r.e(6360),r.e(9695)]).then(r.bind(r,49695))).default,LinkChartLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(6760),r.e(8613),r.e(7475),r.e(2083),r.e(1728)]).then(r.bind(r,71728))).default,MapImageLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(4111),r.e(364),r.e(4341),r.e(7656),r.e(6928)]).then(r.bind(r,7656))).default,MapNotesLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(7475),r.e(2936)]).then(r.bind(r,96953))).default,MediaLayer:async()=>(await Promise.all([r.e(6131),r.e(2763)]).then(r.bind(r,19647))).default,OGCFeatureLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(3029),r.e(2905),r.e(4934)]).then(r.bind(r,87152))).default,OpenStreetMapLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(5177),r.e(349)]).then(r.bind(r,40349))).default,OrientedImageryLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(4111),r.e(8506),r.e(3600),r.e(9835)]).then(r.bind(r,97927))).default,PointCloudLayer:async()=>(await Promise.all([r.e(6131),r.e(8948),r.e(7984),r.e(6742)]).then(r.bind(r,76742))).default,RouteLayer:async()=>(await Promise.all([r.e(6131),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(7634)]).then(r.bind(r,64185))).default,SceneLayer:async()=>(await Promise.all([r.e(6131),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(6213),r.e(2944),r.e(958),r.e(4654),r.e(6298),r.e(6462)]).then(r.bind(r,13899))).default,StreamLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(3029),r.e(505)]).then(r.bind(r,60683))).default,SubtypeGroupLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1956),r.e(4796),r.e(4111),r.e(8506),r.e(1162)]).then(r.bind(r,59929))).default,TileLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(4796),r.e(4111),r.e(364),r.e(9186),r.e(4341),r.e(8535)]).then(r.bind(r,71756))).default,UnknownLayer:async()=>(await r.e(146).then(r.bind(r,146))).default,UnsupportedLayer:async()=>(await r.e(5165).then(r.bind(r,45165))).default,VectorTileLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(9186),r.e(9949),r.e(5013),r.e(4429)]).then(r.bind(r,48757))).default,VideoLayer:async()=>(await r.e(6875).then(r.bind(r,86875))).default,ViewshedLayer:async()=>(await Promise.all([r.e(6131),r.e(6213),r.e(6360),r.e(6650)]).then(r.bind(r,96650))).default,VoxelLayer:async()=>(await Promise.all([r.e(6131),r.e(8948),r.e(6183)]).then(r.bind(r,16183))).default,WCSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(9953),r.e(984),r.e(6049),r.e(2439),r.e(7677),r.e(9547)]).then(r.bind(r,19547))).default,WFSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(13),r.e(5055),r.e(1214),r.e(1956),r.e(9953),r.e(4796),r.e(3029),r.e(7396)]).then(r.bind(r,16350))).default,WMSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(8948),r.e(2106),r.e(5721),r.e(1904)]).then(r.bind(r,51904))).default,WMTSLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(5177),r.e(309)]).then(r.bind(r,20309))).default,WebTileLayer:async()=>(await Promise.all([r.e(6131),r.e(8219),r.e(5177)]).then(r.bind(r,47314))).default}},8947:(e,a,r)=>{r.d(a,{L:()=>s});var t=r(60999),n=r(74887),i=r(67076);async function s(e,a,r){const s=e&&e.getAtOrigin&&e.getAtOrigin("renderer",a.origin);if(s&&"unique-value"===s.type&&s.styleOrigin){const l=await(0,t.Ke)(s.populateFromStyle());if((0,n.Te)(r),!1===l.ok){const r=l.error;a?.messages&&a.messages.push(new i.A("renderer:style-reference",`Failed to create unique value renderer from style reference: ${r.message}`,{error:r,context:a})),e.clear("renderer",a?.origin)}}}},10407:(e,a,r)=>{r.d(a,{It:()=>L,LG:()=>s,OM:()=>y,Sm:()=>o,Y:()=>l,bK:()=>c,mm:()=>d,sQ:()=>u});var t=r(80586),n=r(16930),i=r(28735);function s(e,a){if(!l(e,a)){const r=e.typeKeywords;r?r.push(a):e.typeKeywords=[a]}}function l(e,a){return!!e.typeKeywords?.includes(a)}function c(e){return l(e,d.HOSTED_SERVICE)}function y(e,a){const r=e.typeKeywords;if(r){const e=r.indexOf(a);e>-1&&r.splice(e,1)}}function o(e,a,r){r?s(e,a):y(e,a)}async function u(e){const a=e.clone().normalize();let r;if(a.length>1)for(const e of a)r?e.width>r.width&&(r=e):r=e;else r=a[0];return async function(e){const a=e.spatialReference;if(a.isWGS84)return e.clone();if(a.isWebMercator)return(0,i.ci)(e);const r=n.A.WGS84;return await(0,t.initializeProjection)(a,r),(0,t.project)(e,r)}(r)}const d={DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery"};function L(e){const{portal:a,isOrgItem:r,itemControl:t}=e,n=a.user?.privileges;let i=!n||n.includes("features:user:edit"),s=!!r&&!!n?.includes("features:user:fullEdit");const l="update"===t||"admin"===t;return l?s=i=!0:s&&(i=!0),{features:{edit:i,fullEdit:s},content:{updateItem:l}}}},22429:(e,a,r)=>{r.d(a,{v:()=>n});var t=r(24183);class n{constructor(){this._serviceMetadatas=new Map,this._itemDatas=new Map}async fetchServiceMetadata(e,a){const r=this._serviceMetadatas.get(e);if(r)return r;const n=await(0,t.V)(e,a);return this._serviceMetadatas.set(e,n),n}async fetchItemData(e){const{id:a}=e;if(!a)return null;const{_itemDatas:r}=this;if(r.has(a))return r.get(a);const t=await e.fetchData();return r.set(a,t),t}async fetchCustomParameters(e,a){const r=await this.fetchItemData(e);return r&&"object"==typeof r&&(a?a(r):r.customParameters)||null}}},23154:(e,a,r)=>{r.d(a,{K:()=>d,Q:()=>i});var t=r(24183);const n=new Set(["Catalog Layer","Feature Layer","Oriented Imagery Layer"]);async function i(e,a){const{loadContext:r,...n}=a||{},i=r?await r.fetchServiceMetadata(e,n):await(0,t.V)(e,n);u(i),c(i);const s={serviceJSON:i};if((i.currentVersion??0)<10.5)return s;const l=`${e}/layers`,y=r?await r.fetchServiceMetadata(l,n):await(0,t.V)(l,n);return u(y),c(y),s.layersJSON={layers:y.layers,tables:y.tables},s}function s(e){const{type:a}=e;return!!a&&n.has(a)}function l(e){return"Table"===e.type}function c(e){e.layers=e.layers?.filter(s),e.tables=e.tables?.filter(l)}function y(e){e.type||="Feature Layer"}function o(e){e.type||="Table"}function u(e){e.layers?.forEach(y),e.tables?.forEach(o)}function d(e){switch(e){case"Feature Layer":case"Table":return"FeatureLayer";case"Oriented Imagery Layer":return"OrientedImageryLayer";case"Catalog Layer":return"CatalogLayer"}return"FeatureLayer"}},24183:(e,a,r)=>{r.d(a,{V:()=>n});var t=r(78888);async function n(e,a){const{data:r}=await(0,t.A)(e,{responseType:"json",query:{f:"json",...a?.customParameters,token:a?.apiKey}});return r}},45613:(e,a,r)=>{r.d(a,{fromItem:()=>d,n:()=>L});var t=r(49186),n=r(92009),i=r(23154),s=r(22429),l=r(83531),c=r(4513),y=r(80812),o=r(66964),u=r(10407);async function d(e){let{portalItem:a}=e;!a||a instanceof y.default||(a=new y.default(a));const r=await async function(e){await e.load();const a=new s.v;return async function(e){const a=e.className,r=c.S[a];return{constructor:await r(),properties:e.properties}}(await L(e,a))}(a);return new(0,r.constructor)({portalItem:a,...r.properties})}async function L(e,a){switch(e.type){case"3DTiles Service":return e.typeKeywords.includes("3DObject")?{className:"UnsupportedLayer"}:{className:"IntegratedMesh3DTilesLayer"};case"CSV":return{className:"CSVLayer"};case"Feature Collection":return async function(e){await e.load();const a=(0,u.Y)(e,"Map Notes"),r=(0,u.Y)(e,"Markup");if(a||r)return{className:"MapNotesLayer"};if((0,u.Y)(e,"Route Layer"))return{className:"RouteLayer"};const t=await e.fetchData();return 1===(0,o.XH)(t)?{className:"FeatureLayer"}:{className:"GroupLayer"}}(e);case"Feature Service":return async function(e,a){const r=await f(e,a);if("object"==typeof r){const{sourceJSON:e,className:a}=r,t={sourceJSON:e};return null!=r.id&&(t.layerId=r.id),{className:a||"FeatureLayer",properties:t}}return{className:"GroupLayer"}}(e,a);case"Feed":case"Stream Service":return{className:"StreamLayer"};case"GeoJson":return{className:"GeoJSONLayer"};case"Group Layer":return{className:"GroupLayer"};case"Image Service":return async function(e,a){await e.load();const r=e.typeKeywords?.map((e=>e.toLowerCase()))??[];if(r.includes("elevation 3d layer"))return{className:"ElevationLayer"};if(r.includes("tiled imagery"))return{className:"ImageryTileLayer"};const t=await a.fetchItemData(e),n=t?.layerType;if("ArcGISTiledImageServiceLayer"===n)return{className:"ImageryTileLayer"};if("ArcGISImageServiceLayer"===n)return{className:"ImageryLayer"};const i=await a.fetchServiceMetadata(e.url,{customParameters:await a.fetchCustomParameters(e)}),s=i.cacheType?.toLowerCase(),l=i.capabilities?.toLowerCase().includes("tilesonly"),c=i.tileInfo?.format?.toLowerCase()??"",y=null==s&&["jpg","jpeg","png","png8","png24","png32","mixed"].includes(c);return"map"===s||y||l?{className:"ImageryTileLayer"}:{className:"ImageryLayer"}}(e,a);case"KML":return{className:"KMLLayer"};case"Knowledge Graph Layer":return{className:"KnowledgeGraphLayer"};case"Map Service":return async function(e,a){return await async function(e,a){const{tileInfo:r}=await a.fetchServiceMetadata(e.url,{customParameters:await a.fetchCustomParameters(e)});return r}(e,a)?{className:"TileLayer"}:{className:"MapImageLayer"}}(e,a);case"Media Layer":return{className:"MediaLayer"};case"Scene Service":return async function(e,a){const r=await f(e,a,(async()=>{try{if(!e.url)return[];const{serverUrl:r}=await(0,n.L)(e.url,{sceneLayerItem:e}),t=await a.fetchServiceMetadata(r);return t?.tables??[]}catch{return[]}}));if("object"==typeof r){const t={};let n;if(null!=r.id?(t.layerId=r.id,n=`${e.url}/layers/${r.id}`):n=e.url,e.typeKeywords?.length)for(const a of Object.keys(l.XX))if(e.typeKeywords.includes(a))return{className:l.XX[a]};const i=await a.fetchServiceMetadata(n,{customParameters:await a.fetchCustomParameters(e,(e=>(0,o.pJ)(e)?.customParameters))});return{className:l.XX[i?.layerType]||"SceneLayer",properties:t}}if(!1===r){const r=await a.fetchServiceMetadata(e.url);if("Voxel"===r?.layerType)return{className:"VoxelLayer"}}return{className:"GroupLayer"}}(e,a);case"Vector Tile Service":return{className:"VectorTileLayer"};case"WCS":return{className:"WCSLayer"};case"WFS":return{className:"WFSLayer"};case"WMS":return{className:"WMSLayer"};case"WMTS":return{className:"WMTSLayer"};default:throw new t.A("portal:unknown-item-type","Unknown item type '${type}'",{type:e.type})}}async function f(e,a,r){const{url:t,type:n}=e,s="Feature Service"===n;if(!t)return{};if(/\/\d+$/.test(t)){if(s){const r=await a.fetchServiceMetadata(t,{customParameters:await a.fetchCustomParameters(e,(e=>(0,o.pJ)(e)?.customParameters))});return{id:r.id,className:(0,i.K)(r.type),sourceJSON:r}}return{}}await e.load();let l=await a.fetchItemData(e);if(s){const e=await(0,o.bO)(l,t,a),r=m(e);if("object"==typeof r){const a=(0,o.rc)(e,r.id);r.className=(0,o.K8)(a?.layerType)}return r}if("Scene Service"===n&&(l=await(0,o.nu)(e,l,a)),(0,o.XH)(l)>0)return m(l);const c=await a.fetchServiceMetadata(t);return r&&(c.tables=await r()),m(c)}function m(e){return 1===(0,o.XH)(e)&&{id:(0,o.pJ)(e)?.id}}},66964:(e,a,r)=>{r.d(a,{Ju:()=>y,K8:()=>d,XH:()=>o,_r:()=>i,bO:()=>s,l:()=>u,nu:()=>L,pJ:()=>l,rc:()=>c});var t=r(92009),n=r(23154);function i(e){const a={id:e.id,name:e.name},r=(0,n.K)(e.type);return"FeatureLayer"!==r&&(a.layerType=r),a}async function s(e,a,r){if(null==e?.layers||null==e?.tables){const t=await r.fetchServiceMetadata(a,{customParameters:l(e)?.customParameters});(e=e||{}).layers=e.layers||t?.layers?.map(i),e.tables=e.tables||t?.tables?.map(i)}return e}function l(e){if(!e)return null;const{layers:a,tables:r}=e;return a?.length?a[0]:r?.length?r[0]:null}function c(e,a){return null==a?null:[...e.layers||[],...e.tables||[]].find((e=>e.id===a))}function y(e,a){return[...e.layers||[],...e.tables||[]].filter((({layerType:e})=>e?a.includes(e):a.includes("ArcGISFeatureLayer")))}function o(e){return(e?.layers?.length??0)+(e?.tables?.length??0)}function u(e){switch(e){case"catalog":return["CatalogLayer"];case"feature":return["ArcGISFeatureLayer"];case"oriented-imagery":return["OrientedImageryLayer"];case"subtype-group":return["SubtypeGroupLayer","SubtypeGroupTable"]}return null}function d(e){switch(e){case"CatalogLayer":return"CatalogLayer";case"OrientedImageryLayer":return"OrientedImageryLayer";case"SubtypeGroupLayer":case"SubtypeGroupTable":return"SubtypeGroupLayer"}return"FeatureLayer"}async function L(e,a,r){if(!e?.url)return a??{};if(a??={},!a.layers){const t=await r.fetchServiceMetadata(e.url);a.layers=t.layers?.map(i)}const{serverUrl:n,portalItem:s}=await(0,t.L)(e.url,{sceneLayerItem:e,customParameters:l(a)?.customParameters}).catch((()=>({serverUrl:null,portalItem:null})));if(null==n)return a.tables=[],a;if(!a.tables&&s){const e=await s.fetchData().catch((()=>null));if(e?.tables)a.tables=e.tables.map(i);else{const t=await r.fetchServiceMetadata(n,{customParameters:l(e)?.customParameters}).catch((()=>null));a.tables=t?.tables?.map(i)}}if(a.tables)for(const e of a.tables)e.url=`${n}/${e.id}`;return a}},75356:(e,a,r)=>{r.d(a,{N:()=>M,populateOperationalLayers:()=>o});var t=r(5503),n=(r(44208),r(22429)),i=r(4513),s=r(80812);function l(e,a){return!(!e.layerType||"ArcGISFeatureLayer"!==e.layerType)&&e.featureCollectionType===a}var c=r(45613),y=r(8947);async function o(e,a,r){if(!a)return;const t=a.map((e=>async function(e,a){return async function(e,a,r){const t=new e;return t.read(a,r.context),"group"===t.type&&("GroupLayer"===a.layerType?await M(t,a,r):v(a)?function(e,a,r){a.itemId&&(e.portalItem=new s.default({id:a.itemId,portal:r?.portal}),e.when((()=>{const t=t=>{const n=t.layerId;G(t,e,a,n,r);const i=a.featureCollection?.layers?.[n];i&&t.read(i,r)};e.layers?.forEach(t),e.tables?.forEach(t)})))}(t,a,r.context):b(a)&&await async function(e,a,r){const t=i.S.FeatureLayer,n=await t(),s=a.featureCollection,l=s?.showLegend,c=s?.layers?.map(((t,i)=>{const s=new n;s.read(t,r);const c={...r,ignoreDefaults:!0};return G(s,e,a,i,c),null!=l&&s.read({showLegend:l},c),s}));e.layers.addMany(c??[])}(t,a,r.context)),await(0,y.L)(t,r.context),t}(await I(e,a),e,a)}(e,r))),n=await Promise.allSettled(t);for(const a of n)"rejected"===a.status||a.value&&e.add(a.value)}const u={ArcGISDimensionLayer:"DimensionLayer",ArcGISFeatureLayer:"FeatureLayer",ArcGISImageServiceLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISSceneServiceLayer:"SceneLayer",ArcGISTiledElevationServiceLayer:"ElevationLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",BuildingSceneLayer:"BuildingSceneLayer",CatalogLayer:"CatalogLayer",CSV:"CSVLayer",DefaultTileLayer:"TileLayer",GeoJSON:"GeoJSONLayer",GroupLayer:"GroupLayer",IntegratedMesh3DTilesLayer:"IntegratedMesh3DTilesLayer",Object3DTilesLayer:"UnsupportedLayer",IntegratedMeshLayer:"IntegratedMeshLayer",KML:"KMLLayer",LineOfSightLayer:"LineOfSightLayer",MediaLayer:"MediaLayer",OGCFeatureLayer:"OGCFeatureLayer",OrientedImageryLayer:"OrientedImageryLayer",PointCloudLayer:"PointCloudLayer",RasterDataLayer:"UnsupportedLayer",VectorTileLayer:"VectorTileLayer",ViewshedLayer:"ViewshedLayer",Voxel:"VoxelLayer",WCS:"WCSLayer",WFS:"WFSLayer",WMS:"WMSLayer",WebTiledLayer:"WebTileLayer"},d={ArcGISTiledElevationServiceLayer:"ElevationLayer",DefaultTileLayer:"ElevationLayer",RasterDataElevationLayer:"UnsupportedLayer"},L={ArcGISFeatureLayer:"FeatureLayer"},f={ArcGISImageServiceLayer:"UnsupportedLayer",ArcGISMapServiceLayer:"UnsupportedLayer",ArcGISSceneServiceLayer:"SceneLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",DefaultTileLayer:"TileLayer",OpenStreetMap:"OpenStreetMapLayer",VectorTileLayer:"VectorTileLayer",WCS:"UnsupportedLayer",WMS:"UnsupportedLayer",WebTiledLayer:"WebTileLayer"},m={ArcGISAnnotationLayer:"UnsupportedLayer",ArcGISDimensionLayer:"UnsupportedLayer",ArcGISFeatureLayer:"FeatureLayer",ArcGISImageServiceLayer:"ImageryLayer",ArcGISImageServiceVectorLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISStreamLayer:"StreamLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",BingMapsAerial:"BingMapsLayer",BingMapsHybrid:"BingMapsLayer",BingMapsRoad:"BingMapsLayer",CatalogLayer:"CatalogLayer",CSV:"CSVLayer",DefaultTileLayer:"TileLayer",GeoJSON:"GeoJSONLayer",GeoRSS:"GeoRSSLayer",GroupLayer:"GroupLayer",KML:"KMLLayer",KnowledgeGraphLayer:"KnowledgeGraphLayer",MediaLayer:"MediaLayer",OGCFeatureLayer:"OGCFeatureLayer",OrientedImageryLayer:"OrientedImageryLayer",SubtypeGroupLayer:"SubtypeGroupLayer",VectorTileLayer:"VectorTileLayer",WCS:"WCSLayer",WFS:"WFSLayer",WMS:"WMSLayer",WebTiledLayer:"WebTileLayer"},p={ArcGISFeatureLayer:"FeatureLayer",SubtypeGroupTable:"SubtypeGroupLayer"},S={ArcGISImageServiceLayer:"ImageryLayer",ArcGISImageServiceVectorLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",BingMapsAerial:"BingMapsLayer",BingMapsHybrid:"BingMapsLayer",BingMapsRoad:"BingMapsLayer",DefaultTileLayer:"TileLayer",OpenStreetMap:"OpenStreetMapLayer",VectorTileLayer:"VectorTileLayer",WCS:"WCSLayer",WMS:"WMSLayer",WebTiledLayer:"WebTileLayer"},w={...m,LinkChartLayer:"LinkChartLayer"},h={...p},g={...S};async function I(e,a){const r=a.context,t=T(r);let y=e.layerType||e.type;!y&&a?.defaultLayerType&&(y=a.defaultLayerType);const o=t[y];let u=o?i.S[o]:i.S.UnknownLayer;if(v(e)){const a=r?.portal;if(e.itemId){const r=new s.default({id:e.itemId,portal:a});await r.load();const t=(await(0,c.n)(r,new n.v)).className||"UnknownLayer";u=i.S[t]}}else"ArcGISFeatureLayer"===y?function(e){return l(e,"notes")}(e)||function(e){return l(e,"markup")}(e)?u=i.S.MapNotesLayer:function(e){return l(e,"route")}(e)?u=i.S.RouteLayer:b(e)&&(u=i.S.GroupLayer):e.wmtsInfo?.url&&e.wmtsInfo.layerIdentifier?u=i.S.WMTSLayer:"WFS"===y&&"2.0.0"!==e.wfsInfo?.version&&(u=i.S.UnsupportedLayer);return u()}function b(e){return"ArcGISFeatureLayer"===e.layerType&&!v(e)&&(e.featureCollection?.layers?.length??0)>1}function v(e){return"Feature Collection"===e.type}function T(e){let a;switch(e.origin){case"web-scene":switch(e.layerContainerType){case"basemap":a=f;break;case"ground":a=d;break;case"tables":a=L;break;default:a=u}break;case"link-chart":switch(e.layerContainerType){case"basemap":a=g;break;case"tables":a=h;break;default:a=w}break;default:switch(e.layerContainerType){case"basemap":a=S;break;case"tables":a=p;break;default:a=m}}return a}async function M(e,a,r){const n=new t.A,i=o(n,Array.isArray(a.layers)?a.layers:[],r);try{try{if(await i,"group"===e.type)return e.layers.addMany(n),e}catch(a){e.destroy();for(const e of n)e.destroy();throw a}}catch(e){throw e}}function G(e,a,r,t,n){e.read({id:`${a.id}-sublayer-${t}`,visibility:r.visibleLayers?.includes(t)??!0},n)}},92009:(e,a,r)=>{r.d(a,{L:()=>u});var t=r(70333),i=r(78888),s=r(49186),l=r(74887),c=r(60694),y=r(20655),o=r(80812);async function u(e,a){const r=(0,c.qg)(e);if(!r)throw new s.A("invalid-url","Invalid scene service url");const t={...a,sceneServerUrl:r.url.path,layerId:r.sublayer??void 0};if(t.sceneLayerItem??=await d(t),null==t.sceneLayerItem)return f(t.sceneServerUrl.replace("/SceneServer","/FeatureServer"),t);const n=await m(t);if(!n?.url)throw new s.A("related-service-not-found","Could not find feature service through portal item relationship");t.featureServiceItem=n;const i=await f(n.url,t);return i.portalItem=n,i}async function d(e){const a=(await L(e)).serviceItemId;if(!a)return null;const r=new o.default({id:a,apiKey:e.apiKey}),s=await async function(e){const a=t.id?.findServerInfo(e.sceneServerUrl);if(a?.owningSystemUrl)return a.owningSystemUrl;const r=e.sceneServerUrl.replace(/(.*\/rest)\/.*/i,"$1")+"/info";try{const a=(await(0,i.A)(r,{query:{f:"json"},responseType:"json",signal:e.signal})).data.owningSystemUrl;if(a)return a}catch(e){(0,l.QP)(e)}return null}(e);null!=s&&(r.portal=new y.A({url:s}));try{return await r.load({signal:e.signal})}catch(e){return n(e),null}}async function L(e){if(e.rootDocument)return e.rootDocument;const a={query:{f:"json",...e.customParameters,token:e.apiKey},responseType:"json",signal:e.signal};try{const r=await(0,i.A)(e.sceneServerUrl,a);e.rootDocument=r.data}catch{e.rootDocument={}}return e.rootDocument}async function f(e,a){const r=(0,c.qg)(e);if(!r)throw new s.A("invalid-feature-service-url","Invalid feature service url");const t=r.url.path,n=a.layerId;if(null==n)return{serverUrl:t};const l=L(a),y=a.featureServiceItem?await a.featureServiceItem.fetchData("json"):null,o=(y?.layers?.[0]||y?.tables?.[0])?.customParameters,u=e=>{const r={query:{f:"json",...o},responseType:"json",authMode:e,signal:a.signal};return(0,i.A)(t,r)},d=u("anonymous").catch((()=>u("no-prompt"))),[f,m]=await Promise.all([d,l]),p=m?.layers,S=f.data&&f.data.layers;if(!Array.isArray(S))throw new Error("expected layers array");if(Array.isArray(p)){for(let e=0;e<Math.min(p.length,S.length);e++)if(p[e].id===n)return{serverUrl:t,layerId:S[e].id}}else if(null!=n&&n<S.length)return{serverUrl:t,layerId:S[n].id};throw new Error("could not find matching associated sublayer")}async function m({sceneLayerItem:e,signal:a}){if(!e)return null;try{const r=(await e.fetchRelatedItems({relationshipType:"Service2Service",direction:"reverse"},{signal:a})).find((e=>"Feature Service"===e.type))||null;if(!r)return null;const t=new o.default({portal:r.portal,id:r.id});return await t.load(),t}catch(e){return n(e),null}}}}]);
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[752],{14607:(e,t,n)=>{n.d(t,{B:()=>u,GP:()=>l,qg:()=>c});var i=n(799),r=n(73444);const s={ar:[".",","],bg:[","," "],bs:[",","."],ca:[",","."],cs:[","," "],da:[",","."],de:[",","."],"de-ch":[".","’"],el:[",","."],en:[".",","],"en-au":[".",","],es:[",","."],"es-mx":[".",","],et:[","," "],fi:[","," "],fr:[","," "],"fr-ch":[","," "],he:[".",","],hi:[".",",","#,##,##0.###"],hr:[",","."],hu:[","," "],id:[",","."],it:[",","."],"it-ch":[".","’"],ja:[".",","],ko:[".",","],lt:[","," "],lv:[","," "],mk:[",","."],nb:[","," "],nl:[",","."],no:[","," "],pl:[","," "],pt:[",","."],"pt-pt":[","," "],ro:[",","."],ru:[","," "],sk:[","," "],sl:[",","."],sr:[",","."],sv:[","," "],th:[".",","],tr:[",","."],uk:[","," "],vi:[",","."],zh:[".",","]};function o(e=(0,r.JK)()){let t=(e=e.toLowerCase())in s;if(!t){const n=e.split("-");n.length>1&&n[0]in s&&(e=n[0],t=!0),t||(e="en")}const[n,i,o="#,##0.###"]=s[e];return{decimal:n,group:i,pattern:o}}function l(e,t){const n=o((t={...t}).locale);t.customs=n;const i=t.pattern||n.pattern;return isNaN(e)||Math.abs(e)===1/0?null:function(e,t,n){const i=(n=n||{}).customs.group,r=n.customs.decimal,s=t.split(";"),o=s[0];if((t=s[e<0?1:0]||"-"+o).includes("%"))e*=100;else if(t.includes("‰"))e*=1e3;else{if(t.includes("¤"))throw new Error("currency notation not supported");if(t.includes("E"))throw new Error("exponential notation not supported")}const l=a,u=o.match(l);if(!u)throw new Error("unable to find a number expression in pattern: "+t);return!1===n.fractional&&(n.places=0),t.replace(l,function(e,t,n){!0===(n=n||{}).places&&(n.places=0),n.places===1/0&&(n.places=6);const i=t.split("."),r="string"==typeof n.places&&n.places.indexOf(",");let s=n.places;r?s=n.places.slice(r+1):+s>=0||(s=(i[1]||[]).length),n.round<0||(e=Number(e.toFixed(Number(s))));const o=String(Math.abs(e)).split("."),l=o[1]||"";if(i[1]||n.places){r&&(n.places=n.places.slice(0,Math.max(0,r)));const e=void 0!==n.places?n.places:i[1]&&i[1].lastIndexOf("0")+1;+e>l.length&&(o[1]=l.padEnd(Number(e),"0")),+s<l.length&&(o[1]=l.slice(0,Math.max(0,Number(s))))}else o[1]&&o.pop();const a=i[0].replace(",","");let u=a.indexOf("0");-1!==u&&(u=a.length-u,u>o[0].length&&(o[0]=o[0].padStart(u,"0")),a.includes("#")||(o[0]=o[0].slice(-u)));let c,p,d=i[0].lastIndexOf(",");if(-1!==d){c=i[0].length-d-1;const e=i[0].slice(0,d);d=e.lastIndexOf(","),-1!==d&&(p=e.length-d-1)}const f=[];for(let e=o[0];e;){const t=e.length-c;f.push(t>0?e.slice(Math.max(0,t)):e),e=t>0?e.slice(0,t):"",p&&(c=p,p=void 0)}return o[0]=f.reverse().join(n.group||","),o.join(n.decimal||".")}(e,u[0],{decimal:r,group:i,places:n.places,round:n.round}))}(e,i,t)}const a=/[#0,]*[#0](?:\.0*#*)?/;function u(e){const t=o((e=e||{}).locale),n=e.pattern||t.pattern,r=t.group,s=t.decimal;let l=1;if(n.includes("%"))l/=100;else if(n.includes("‰"))l/=1e3;else if(n.includes("¤"))throw new Error("currency notation not supported");const u=n.split(";");1===u.length&&u.push("-"+u[0]);const c=d(u,(t=>(t="(?:"+(0,i.Cj)(t,".")+")").replace(a,(t=>{const n={signed:!1,separator:e.strict?r:[r,""],fractional:e.fractional,decimal:s,exponent:!1},i=t.split(".");let o=e.places;1===i.length&&1!==l&&(i[1]="###"),1===i.length||0===o?n.fractional=!1:(void 0===o&&(o=e.pattern?i[1].lastIndexOf("0")+1:1/0),o&&null==e.fractional&&(n.fractional=!0),!e.places&&+o<i[1].length&&(o+=","+i[1].length),n.places=o);const a=i[0].split(",");return a.length>1&&(n.groupSize=a.pop().length,a.length>1&&(n.groupSize2=a.pop().length)),"("+function(e){"places"in(e=e||{})||(e.places=1/0),"string"!=typeof e.decimal&&(e.decimal="."),"fractional"in e&&!String(e.places).startsWith("0")||(e.fractional=[!0,!1]),"exponent"in e||(e.exponent=[!0,!1]),"eSigned"in e||(e.eSigned=[!0,!1]);const t=p(e),n=d(e.fractional,(t=>{let n="";return t&&0!==e.places&&(n="\\"+e.decimal,e.places===1/0?n="(?:"+n+"\\d+)?":n+="\\d{"+e.places+"}"),n}),!0);let i=t+n;return n&&(i="(?:(?:"+i+")|(?:"+n+"))"),i+d(e.exponent,(t=>t?"([eE]"+p({signed:e.eSigned})+")":""))}(n)+")"}))),!0);return{regexp:c.replaceAll(/[\xa0 ]/g,"[\\s\\xa0]"),group:r,decimal:s,factor:l}}function c(e,t){const n=u(t),i=new RegExp("^"+n.regexp+"$").exec(e);if(!i)return NaN;let r=i[1];if(!i[1]){if(!i[2])return NaN;r=i[2],n.factor*=-1}return r=r.replaceAll(new RegExp("["+n.group+"\\s\\xa0]","g"),"").replace(n.decimal,"."),Number(r)*n.factor}function p(e){return"signed"in(e=e||{})||(e.signed=[!0,!1]),"separator"in e?"groupSize"in e||(e.groupSize=3):e.separator="",d(e.signed,(e=>e?"[-+]":""),!0)+d(e.separator,(t=>{if(!t)return"(?:\\d+)";" "===(t=(0,i.Cj)(t))?t="\\s":" "===t&&(t="\\s\\xa0");const n=e.groupSize,r=e.groupSize2;if(r){const e="(?:0|[1-9]\\d{0,"+(r-1)+"}(?:["+t+"]\\d{"+r+"})*["+t+"]\\d{"+n+"})";return n-r>0?"(?:"+e+"|(?:0|[1-9]\\d{0,"+(n-1)+"}))":e}return"(?:0|[1-9]\\d{0,"+(n-1)+"}(?:["+t+"]\\d{"+n+"})*)"}),!0)}const d=(e,t,n)=>{if(!Array.isArray(e))return t(e);const i=[];for(let n=0;n<e.length;n++)i.push(t(e[n]));return f(i.join("|"),Boolean(n))},f=(e,t)=>"("+(t?"?:":"")+e+")"},40752:(e,t,n)=>{n.r(t),n.d(t,{default:()=>J});var i=n(78888),r=n(60999),s=n(67482),o=n(49186),l=n(53966),a=n(74887),u=n(84952),c=n(80586),p=n(16930),d=n(7320),f=n(21325),h=n(28735),m=n(43334),y=n(92722),g=n(58376),_=n(83221),S=n(31464),b=n(68298),w=n(14607),x=n(30524);function N(e,t,n){t=(0,x.rS)(t)?.toLowerCase(),n=(0,x.rS)(n)?.toLowerCase();const i=e.map((e=>e.toLowerCase())),r=t?e[i.indexOf(t)]:null,s=n?e[i.indexOf(n)]:null;return{longitudeFieldName:r||e[i.indexOf(I.find((e=>i.includes(e))))],latitudeFieldName:s||e[i.indexOf(F.find((e=>i.includes(e))))]}}const F=["lat","lat83","latitude","latitude83","latdecdeg","lat_dd","y","ycenter","point_y"],I=["lon","lng","lng83","long","long83","longitude","longitude83","longdecdeg","long_dd","x","xcenter","point_x"],T=/^\s*"([\S\s]*)"\s*$/,C=/""/g,E=[","," ",";","|","\t"];function*A(e,t,n){let i=0;for(;i<=e.length;){const r=e.indexOf(t,i),s=e.slice(i,r>-1?r:void 0);i+=s.length+t.length,n&&!s.trim()||(yield s)}}function v(e){const t=e.includes("\r\n")?"\r\n":"\n";return A(e,t,!0)}function O(e,t){return A(e,t,!1)}function k(e,t,n){e=e.trim(),t=t?.trim();const i=[],r=Array.from(new Set([n?.delimiter,...E])).filter((e=>null!=e));for(const n of r){const r=M(e,n).length,s=M(t,n).length??r;r>1&&i.push({weight:Math.min(r,s),delimiter:n})}const s=i.sort((({weight:e},{weight:t})=>t-e)).map((({delimiter:e})=>e));for(const t of s){const i=N(D(e,t).names,n?.longitudeField,n?.latitudeField);if(i.longitudeFieldName&&i.latitudeFieldName)return{delimiter:t,locationInfo:i}}return{delimiter:s[0],locationInfo:null}}function*q(e,t,n,i=()=>Object.create(null)){const r=v(e);r.next();let s="",o="",l=0,a=i(),u=0;e:for(const e of r){const r=O(e,n);for(const e of r)if(s+=o+e,o="",l+=j(e),l%2==0){if(l>0){const e=T.exec(s);if(!e){a=i(),u=0,s="",l=0;continue e}a[t[u]]=e[1].replaceAll(C,'"'),u++}else a[t[u]]=s,u++;s="",l=0}else o=n;0===l?(yield a,a=i(),u=0):o="\n"}}function D(e,t){const n=M(e,t).filter((e=>null!=e)),i=n.map((e=>(0,x.rS)(e)));for(let e=i.length-1;e>=0;e--)i[e]||(i.splice(e,1),n.splice(e,1));return{names:i,aliases:n}}function M(e,t){if(!e?.length)return[];const n=[];let i="",r="",s=0;const o=O(e,t);for(const e of o)if(i+=r+e,r="",s+=j(e),s%2==0){if(s>0){const e=T.exec(i);e&&n.push(e[1].replaceAll(C,'"'))}else n.push(i);i="",s=0}else r=t;return n}function j(e){let t=0,n=0;for(n=e.indexOf('"',n);n>=0;)t++,n=e.indexOf('"',n+1);return t}function R(e){if(!e.length)return"string";const t=/[^+\-.,0-9]/;return e.map((e=>{if(""!==e){if(!t.test(e)){let t=L(e);if(!isNaN(t))return/[.,]/.test(e)||!Number.isInteger(t)||t>214783647||t<-214783648?"double":"integer";if(e.includes("E")){if(t=Number(e),!Number.isNaN(t))return"double";if(e.includes(",")&&(e=e.replace(",","."),t=Number(e),!Number.isNaN(t)))return"double"}}return(0,s.Cq)(e)?"date":"string"}})).reduce(((e,t)=>void 0===e?t:void 0===t?e:e===t?t:"string"===e||"string"===t?"string":"double"===e||"double"===t?"double":void 0))}const L=function(){const e=(0,w.B)(),t=new RegExp("^"+e.regexp+"$"),n=new RegExp("["+e.group+"\\s\\xa0]","g"),i=e.factor;return r=>{const s=t.exec(r);if(e.factor=i,!s)return NaN;let o=s[1];if(!s[1]){if(!s[2])return NaN;o=s[2],e.factor*=-1}return o=o.replace(n,"").replace(e.decimal,"."),+o*e.factor}}();function z(e){return JSON.parse(JSON.stringify(e))}var $=n(64714),P=n(95466),U=n(54218),V=n(98623);const B=(0,$.F0)("esriGeometryPoint"),Z=["csv"],G=[0,0];class Q{constructor(e,t){this.x=e,this.y=t}}class J{constructor(){this._queryEngine=null,this._snapshotFeatures=async e=>{const t=await this._fetch(e);return this._createFeatures(t)}}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t={}){this._loadOptions=e;const[n]=await Promise.all([this._fetch(t.signal),this._checkProjection(e?.parsingOptions?.spatialReference)]),i=function(e,t){const n=t.parsingOptions||{},i={delimiter:n.delimiter,layerDefinition:null,locationInfo:{latitudeFieldName:n.latitudeField,longitudeFieldName:n.longitudeField}},r=i.layerDefinition={name:(0,u.e7)(t.url,Z)||"csv",dateFieldsTimeReference:{timeZoneIANA:V.n$},drawingInfo:B,geometryType:"esriGeometryPoint",objectIdField:null,fields:[],timeInfo:n.timeInfo,extent:{xmin:Number.POSITIVE_INFINITY,ymin:Number.POSITIVE_INFINITY,xmax:Number.NEGATIVE_INFINITY,ymax:Number.NEGATIVE_INFINITY,spatialReference:n.spatialReference||{wkid:4326}}},s=v(e),l=s.next().value?.trim(),a=s.next().value?.trim();if(!l)throw new o.A("csv-layer:empty-csv","CSV is empty",{csv:e});const{delimiter:c,locationInfo:p}=k(l,a,n);if(!c)throw new o.A("csv-layer:invalid-delimiter","Unable to detect the delimiter from CSV",{firstLine:l,secondLine:a,parsingOptions:n});if(!p)throw new o.A("csv-layer:location-fields-not-found","Unable to identify latitude and longitude fields from the CSV file",{firstLine:l,secondLine:a,parsingOptions:n});i.locationInfo=p,i.delimiter=c;const{names:d,aliases:f}=D(l,c),h=function(e,t,n,i,r){const s=[],o=q(e,n,t),l=[];for(const e of o){if(10===l.length)break;l.push(e)}for(let e=0;e<n.length;e++){const t=n[e],o=i[e];if(t===r.longitudeFieldName||t===r.latitudeFieldName)s.push({name:t,type:"esriFieldTypeDouble",alias:o});else{let e;switch(R(l.map((e=>e[t])))){case"integer":e="esriFieldTypeInteger";break;case"double":e="esriFieldTypeDouble";break;case"date":e="esriFieldTypeDate";break;default:e="esriFieldTypeString"}s.push({name:t,type:e,alias:o,length:(0,x._b)(e)})}}return s}(e,i.delimiter,d,f,i.locationInfo);if(n.fields?.length){const e=new P.A(n.fields);for(const t of h){const n=e.get(t.name);n&&Object.assign(t,n)}}if(!h.some((e=>"esriFieldTypeOID"===e.type&&(r.objectIdField=e.name,!0)))){const e={name:"__OBJECTID",alias:"__OBJECTID",type:"esriFieldTypeOID",editable:!1,nullable:!1};r.objectIdField=e.name,h.unshift(e)}r.fields=h;const m=new P.A(r.fields);if(i.locationInfo&&(i.locationInfo.latitudeFieldName=m.get(i.locationInfo.latitudeFieldName).name,i.locationInfo.longitudeFieldName=m.get(i.locationInfo.longitudeFieldName).name),r.timeInfo){const e=r.timeInfo;if(e.startTimeField){const t=m.get(e.startTimeField);t?(e.startTimeField=t.name,t.type="esriFieldTypeDate"):e.startTimeField=null}if(e.endTimeField){const t=m.get(e.endTimeField);t?(e.endTimeField=t.name,t.type="esriFieldTypeDate"):e.endTimeField=null}if(e.trackIdField){const t=m.get(e.trackIdField);e.trackIdField=t?t.name:null}e.startTimeField||e.endTimeField||(r.timeInfo=null)}return i}(n,e);this._locationInfo=i.locationInfo,this._delimiter=i.delimiter,this._queryEngine=this._createQueryEngine(i);const r=await this._createFeatures(n);this._queryEngine.featureStore.addMany(r);const{fullExtent:s,timeExtent:l}=await this._queryEngine.fetchRecomputedExtents();if(i.layerDefinition.extent=s,l){const{start:e,end:t}=l;i.layerDefinition.timeInfo.timeExtent=[e,t]}return i}async applyEdits(){throw new o.A("csv-layer:editing-not-supported","applyEdits() is not supported on CSVLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),(await this._queryEngine.executeQueryForIds(e,t.signal)).filter(U.Et)}async queryExtent(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForExtent(e,t.signal)}async querySnapping(e,t={}){return await this._waitSnapshotComplete(),(0,g.J)(this._queryEngine,e,t.signal)}async queryAttributeBins(e,t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeAttributeBinsQuery(e,t.signal)}async refresh(e){this._loadOptions.customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,r.UT)(this._snapshotFeatures),this._snapshotTask.promise.then((e=>{this._queryEngine.featureStore.clear(),e&&this._queryEngine.featureStore.addMany(e)}),(e=>{this._queryEngine.featureStore.clear(),(0,a.zf)(e)||l.A.getLogger("esri.layers.CSVLayer").error(new o.A("csv-layer:refresh","An error occurred during refresh",{error:e}))})),await this._waitSnapshotComplete();const{fullExtent:t,timeExtent:n}=await this._queryEngine.fetchRecomputedExtents();return{extent:t,timeExtent:n}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _fetch(e){const{url:t,customParameters:n}=this._loadOptions;if(!t)throw new o.A("csv-layer:invalid-source","url not defined");const r=(0,u.An)(t);return(await(0,i.A)(r.path,{query:{...r.query,...n},responseType:"text",signal:e})).data}_createQueryEngine(e){const{objectIdField:t,fields:n,extent:i,timeInfo:r}=e.layerDefinition,s=new _.A({geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1});return new b.do({fieldsIndex:P.A.fromLayerJSON({fields:n,dateFieldsTimeReference:{timeZoneIANA:V.n$}}),geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1,timeInfo:r,objectIdField:t,spatialReference:i.spatialReference||{wkid:4326},featureStore:s})}async _createFeatures(e){const{latitudeFieldName:t,longitudeFieldName:n}=this._locationInfo,{objectIdField:i,fieldsIndex:r,spatialReference:o}=this._queryEngine;let l=[];const a=[],u=r.fields.filter((e=>e.name!==i)).map((e=>e.name));let g=0;const _={};for(const e of r.fields)if("esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type){const t=(0,x.lD)(e);void 0!==t&&(_[e.name]=t)}const S=q(e,u,this._delimiter,(0,$.Vx)(_,i));for(const e of S){const o=this._parseCoordinateValue(e[t]),u=this._parseCoordinateValue(e[n]);if(null!=u&&null!=o&&!isNaN(o)&&!isNaN(u)){e[t]=o,e[n]=u;for(const i in e)if(i!==t&&i!==n)if(r.isDateField(i))e[i]=(0,s._U)(e[i]);else if(r.isNumericField(i)){const t=L(e[i]);isNaN(t)?e[i]=null:e[i]=t}else null!=e[i]&&(e[i]=z(e[i]));e[i]=g,g++,l.push(new Q(u,o)),a.push(e)}}if(!(0,f.aI)({wkid:4326},o))if((0,f.K8)(o))for(const e of l)[e.x,e.y]=(0,h.je)(e.x,e.y,G);else l=(0,c.projectMany)(d.g,l,p.A.WGS84,o,null,null);const b=[];for(let e=0;e<l.length;e++){const{x:t,y:n}=l[e],r=a[e];r[i]=e+1,b.push(new m.Om(new y.A([],[t,n]),r,null,r[i]))}return b}_parseCoordinateValue(e){if(null==e||""===e)return null;let t=L(e);return(isNaN(t)||Math.abs(t)>181)&&(t=parseFloat(e)),t}async _checkProjection(e){try{await(0,S.Nk)(f.KK,e)}catch{throw new o.A("csv-layer:projection-not-supported","Projection not supported")}}}},60999:(e,t,n)=>{n.d(t,{DZ:()=>h,Ke:()=>f,Tj:()=>c,UT:()=>m,jJ:()=>u});var i=n(90237),r=n(69622),s=n(97768),o=n(74887),l=n(10107),a=n(40608);function u(e,t,n){return(0,o.Lx)(e.map(((e,i)=>t.apply(n,[e,i]))))}async function c(e,t,n){return(await(0,o.Lx)(e.map(((e,i)=>t.apply(n,[e,i]))))).map((e=>e.value))}function p(e){return{ok:!0,value:e}}function d(e){return{ok:!1,error:e}}async function f(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return p(await e)}catch(e){return d(e)}}async function h(e){try{return p(await e)}catch(e){return(0,o.QP)(e),d(e)}}function m(e,t){return new y(e,t)}let y=class extends r.A{get value(){return null!=(e=this._result)&&!0===e.ok?e.value:null;var e}get error(){return null!=(e=this._result)&&!1===e.ok?e.error:null;var e}get finished(){return null!=this._result}constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,s.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:n}=this._abortController;this.promise=e(n),this.promise.then((e=>{this._result=p(e),this._cleanup()}),(e=>{this._result=d(e),this._cleanup()})),this._abortHandle=(0,o.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,s.xt)(this._abortHandle),this._abortController=null}};(0,i._)([(0,l.MZ)()],y.prototype,"value",null),(0,i._)([(0,l.MZ)()],y.prototype,"error",null),(0,i._)([(0,l.MZ)()],y.prototype,"finished",null),(0,i._)([(0,l.MZ)()],y.prototype,"promise",void 0),(0,i._)([(0,l.MZ)()],y.prototype,"_result",void 0),y=(0,i._)([(0,a.$)("esri.core.asyncUtils.ReactiveTask")],y)},64714:(e,t,n)=>{n.d(t,{F0:()=>l,Vx:()=>c,e2:()=>d,f:()=>f});var i=n(44208),r=n(4718),s=n(99352),o=n(93470);function l(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const a=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function c(e,t){if((0,i.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let n=`this${p(t)} = null;`;for(const t in e)n+=`this${p(t)} = ${JSON.stringify(e[t])};`;const i=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${n};\n }\n }\n `)();return()=>new i}catch(n){return()=>({[t]:null,...e})}}function p(e){return a.test(e)?`.${e}`:`["${e}"]`}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,r.o8)(e)}}]}function f(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},67482:(e,t,n)=>{function i(e){return null!=l(e)||null!=o(e)}function r(e){return a.test(e)}function s(e){return l(e)??o(e)}function o(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let n=!0;if(c&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,i=0;for(;!t&&i<=e.length;)t=!u.test(e[i]),i++;n=!t}}return n}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function l(e){const t=a.exec(e);if(!t?.groups)return null;const n=t.groups,i=+n.year,r=+n.month-1,s=+n.day,o=+(n.hours??"0"),l=+(n.minutes??"0"),u=+(n.seconds??"0");if(o>23)return null;if(l>59)return null;if(u>59)return null;const c=n.ms??"0",p=c?+c.padEnd(3,"0").slice(0,3):0;let d;if(n.isUTC||!n.offsetSign)d=Date.UTC(i,r,s,o,l,u,p);else{const e=+n.offsetHours,t=+n.offsetMinutes;d=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(i,r,s,o,l,u,p)}return Number.isNaN(d)?null:d}n.d(t,{Br:()=>r,Cq:()=>i,_U:()=>s});const a=/^(?:(?<year>-?\d{4,})-(?<month>\d{2})-(?<day>\d{2}))(?:T(?<hours>\d{2}):(?<minutes>\d{2}):(?<seconds>\d{2})(?:\.(?<ms>\d+))?)?(?:(?<isUTC>Z)|(?:(?<offsetSign>\+|-)(?<offsetHours>\d{2}):(?<offsetMinutes>\d{2})))?$/,u=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,c=!Number.isNaN(new Date("technology 10").getTime())},93470:(e,t,n)=>{n.d(t,{Cb:()=>s,HW:()=>c,JR:()=>r,JZ:()=>a,WR:()=>l,b6:()=>p,fT:()=>i,nC:()=>u,yM:()=>o});const i=[252,146,31,255],r=[153,153,153,255],s={type:"esriSMS",style:"esriSMSCircle",size:6,color:i,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:i},l={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},a={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},u={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},c={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},p={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[752],{14607:(e,t,n)=>{n.d(t,{B:()=>u,GP:()=>l,qg:()=>c});var i=n(799),r=n(73444);const s={ar:[".",","],bg:[","," "],bs:[",","."],ca:[",","."],cs:[","," "],da:[",","."],de:[",","."],"de-ch":[".","’"],el:[",","."],en:[".",","],"en-au":[".",","],es:[",","."],"es-mx":[".",","],et:[","," "],fi:[","," "],fr:[","," "],"fr-ch":[","," "],he:[".",","],hi:[".",",","#,##,##0.###"],hr:[",","."],hu:[","," "],id:[",","."],it:[",","."],"it-ch":[".","’"],ja:[".",","],ko:[".",","],lt:[","," "],lv:[","," "],mk:[",","."],nb:[","," "],nl:[",","."],no:[","," "],pl:[","," "],pt:[",","."],"pt-pt":[","," "],ro:[",","."],ru:[","," "],sk:[","," "],sl:[",","."],sr:[",","."],sv:[","," "],th:[".",","],tr:[",","."],uk:[","," "],vi:[",","."],zh:[".",","]};function o(e=(0,r.JK)()){let t=(e=e.toLowerCase())in s;if(!t){const n=e.split("-");n.length>1&&n[0]in s&&(e=n[0],t=!0),t||(e="en")}const[n,i,o="#,##0.###"]=s[e];return{decimal:n,group:i,pattern:o}}function l(e,t){const n=o((t={...t}).locale);t.customs=n;const i=t.pattern||n.pattern;return isNaN(e)||Math.abs(e)===1/0?null:function(e,t,n){const i=(n=n||{}).customs.group,r=n.customs.decimal,s=t.split(";"),o=s[0];if((t=s[e<0?1:0]||"-"+o).includes("%"))e*=100;else if(t.includes("‰"))e*=1e3;else{if(t.includes("¤"))throw new Error("currency notation not supported");if(t.includes("E"))throw new Error("exponential notation not supported")}const l=a,u=o.match(l);if(!u)throw new Error("unable to find a number expression in pattern: "+t);return!1===n.fractional&&(n.places=0),t.replace(l,function(e,t,n){!0===(n=n||{}).places&&(n.places=0),n.places===1/0&&(n.places=6);const i=t.split("."),r="string"==typeof n.places&&n.places.indexOf(",");let s=n.places;r?s=n.places.slice(r+1):+s>=0||(s=(i[1]||[]).length),n.round<0||(e=Number(e.toFixed(Number(s))));const o=String(Math.abs(e)).split("."),l=o[1]||"";if(i[1]||n.places){r&&(n.places=n.places.slice(0,Math.max(0,r)));const e=void 0!==n.places?n.places:i[1]&&i[1].lastIndexOf("0")+1;+e>l.length&&(o[1]=l.padEnd(Number(e),"0")),+s<l.length&&(o[1]=l.slice(0,Math.max(0,Number(s))))}else o[1]&&o.pop();const a=i[0].replace(",","");let u=a.indexOf("0");-1!==u&&(u=a.length-u,u>o[0].length&&(o[0]=o[0].padStart(u,"0")),a.includes("#")||(o[0]=o[0].slice(-u)));let c,p,d=i[0].lastIndexOf(",");if(-1!==d){c=i[0].length-d-1;const e=i[0].slice(0,d);d=e.lastIndexOf(","),-1!==d&&(p=e.length-d-1)}const f=[];for(let e=o[0];e;){const t=e.length-c;f.push(t>0?e.slice(Math.max(0,t)):e),e=t>0?e.slice(0,t):"",p&&(c=p,p=void 0)}return o[0]=f.reverse().join(n.group||","),o.join(n.decimal||".")}(e,u[0],{decimal:r,group:i,places:n.places,round:n.round}))}(e,i,t)}const a=/[#0,]*[#0](?:\.0*#*)?/;function u(e){const t=o((e=e||{}).locale),n=e.pattern||t.pattern,r=t.group,s=t.decimal;let l=1;if(n.includes("%"))l/=100;else if(n.includes("‰"))l/=1e3;else if(n.includes("¤"))throw new Error("currency notation not supported");const u=n.split(";");1===u.length&&u.push("-"+u[0]);const c=d(u,(t=>(t="(?:"+(0,i.Cj)(t,".")+")").replace(a,(t=>{const n={signed:!1,separator:e.strict?r:[r,""],fractional:e.fractional,decimal:s,exponent:!1},i=t.split(".");let o=e.places;1===i.length&&1!==l&&(i[1]="###"),1===i.length||0===o?n.fractional=!1:(void 0===o&&(o=e.pattern?i[1].lastIndexOf("0")+1:1/0),o&&null==e.fractional&&(n.fractional=!0),!e.places&&+o<i[1].length&&(o+=","+i[1].length),n.places=o);const a=i[0].split(",");return a.length>1&&(n.groupSize=a.pop().length,a.length>1&&(n.groupSize2=a.pop().length)),"("+function(e){"places"in(e=e||{})||(e.places=1/0),"string"!=typeof e.decimal&&(e.decimal="."),"fractional"in e&&!String(e.places).startsWith("0")||(e.fractional=[!0,!1]),"exponent"in e||(e.exponent=[!0,!1]),"eSigned"in e||(e.eSigned=[!0,!1]);const t=p(e),n=d(e.fractional,(t=>{let n="";return t&&0!==e.places&&(n="\\"+e.decimal,e.places===1/0?n="(?:"+n+"\\d+)?":n+="\\d{"+e.places+"}"),n}),!0);let i=t+n;return n&&(i="(?:(?:"+i+")|(?:"+n+"))"),i+d(e.exponent,(t=>t?"([eE]"+p({signed:e.eSigned})+")":""))}(n)+")"}))),!0);return{regexp:c.replaceAll(/[\xa0 ]/g,"[\\s\\xa0]"),group:r,decimal:s,factor:l}}function c(e,t){const n=u(t),i=new RegExp("^"+n.regexp+"$").exec(e);if(!i)return NaN;let r=i[1];if(!i[1]){if(!i[2])return NaN;r=i[2],n.factor*=-1}return r=r.replaceAll(new RegExp("["+n.group+"\\s\\xa0]","g"),"").replace(n.decimal,"."),Number(r)*n.factor}function p(e){return"signed"in(e=e||{})||(e.signed=[!0,!1]),"separator"in e?"groupSize"in e||(e.groupSize=3):e.separator="",d(e.signed,(e=>e?"[-+]":""),!0)+d(e.separator,(t=>{if(!t)return"(?:\\d+)";" "===(t=(0,i.Cj)(t))?t="\\s":" "===t&&(t="\\s\\xa0");const n=e.groupSize,r=e.groupSize2;if(r){const e="(?:0|[1-9]\\d{0,"+(r-1)+"}(?:["+t+"]\\d{"+r+"})*["+t+"]\\d{"+n+"})";return n-r>0?"(?:"+e+"|(?:0|[1-9]\\d{0,"+(n-1)+"}))":e}return"(?:0|[1-9]\\d{0,"+(n-1)+"}(?:["+t+"]\\d{"+n+"})*)"}),!0)}const d=(e,t,n)=>{if(!Array.isArray(e))return t(e);const i=[];for(let n=0;n<e.length;n++)i.push(t(e[n]));return f(i.join("|"),Boolean(n))},f=(e,t)=>"("+(t?"?:":"")+e+")"},40752:(e,t,n)=>{n.r(t),n.d(t,{default:()=>J});var i=n(78888),r=n(60999),s=n(67482),o=n(49186),l=n(53966),a=n(74887),u=n(84952),c=n(80586),p=n(16930),d=n(7320),f=n(21325),h=n(28735),m=n(43334),y=n(92722),g=n(58376),_=n(83221),S=n(31464),b=n(68298),w=n(14607),x=n(30524);function N(e,t,n){t=(0,x.rS)(t)?.toLowerCase(),n=(0,x.rS)(n)?.toLowerCase();const i=e.map((e=>e.toLowerCase())),r=t?e[i.indexOf(t)]:null,s=n?e[i.indexOf(n)]:null;return{longitudeFieldName:r||e[i.indexOf(I.find((e=>i.includes(e))))],latitudeFieldName:s||e[i.indexOf(F.find((e=>i.includes(e))))]}}const F=["lat","lat83","latitude","latitude83","latdecdeg","lat_dd","y","ycenter","point_y"],I=["lon","lng","lng83","long","long83","longitude","longitude83","longdecdeg","long_dd","x","xcenter","point_x"],T=/^\s*"([\S\s]*)"\s*$/,C=/""/g,E=[","," ",";","|","\t"];function*A(e,t,n){let i=0;for(;i<=e.length;){const r=e.indexOf(t,i),s=e.slice(i,r>-1?r:void 0);i+=s.length+t.length,n&&!s.trim()||(yield s)}}function v(e){const t=e.includes("\r\n")?"\r\n":"\n";return A(e,t,!0)}function O(e,t){return A(e,t,!1)}function k(e,t,n){e=e.trim(),t=t?.trim();const i=[],r=Array.from(new Set([n?.delimiter,...E])).filter((e=>null!=e));for(const n of r){const r=M(e,n).length,s=M(t,n).length??r;r>1&&i.push({weight:Math.min(r,s),delimiter:n})}const s=i.sort((({weight:e},{weight:t})=>t-e)).map((({delimiter:e})=>e));for(const t of s){const i=N(D(e,t).names,n?.longitudeField,n?.latitudeField);if(i.longitudeFieldName&&i.latitudeFieldName)return{delimiter:t,locationInfo:i}}return{delimiter:s[0],locationInfo:null}}function*q(e,t,n,i=()=>Object.create(null)){const r=v(e);r.next();let s="",o="",l=0,a=i(),u=0;e:for(const e of r){const r=O(e,n);for(const e of r)if(s+=o+e,o="",l+=j(e),l%2==0){if(l>0){const e=T.exec(s);if(!e){a=i(),u=0,s="",l=0;continue e}a[t[u]]=e[1].replaceAll(C,'"'),u++}else a[t[u]]=s,u++;s="",l=0}else o=n;0===l?(yield a,a=i(),u=0):o="\n"}}function D(e,t){const n=M(e,t).filter((e=>null!=e)),i=n.map((e=>(0,x.rS)(e)));for(let e=i.length-1;e>=0;e--)i[e]||(i.splice(e,1),n.splice(e,1));return{names:i,aliases:n}}function M(e,t){if(!e?.length)return[];const n=[];let i="",r="",s=0;const o=O(e,t);for(const e of o)if(i+=r+e,r="",s+=j(e),s%2==0){if(s>0){const e=T.exec(i);e&&n.push(e[1].replaceAll(C,'"'))}else n.push(i);i="",s=0}else r=t;return n}function j(e){let t=0,n=0;for(n=e.indexOf('"',n);n>=0;)t++,n=e.indexOf('"',n+1);return t}function R(e){if(!e.length)return"string";const t=/[^+\-.,0-9]/;return e.map((e=>{if(""!==e){if(!t.test(e)){let t=L(e);if(!isNaN(t))return/[.,]/.test(e)||!Number.isInteger(t)||t>214783647||t<-214783648?"double":"integer";if(e.includes("E")){if(t=Number(e),!Number.isNaN(t))return"double";if(e.includes(",")&&(e=e.replace(",","."),t=Number(e),!Number.isNaN(t)))return"double"}}return(0,s.Cq)(e)?"date":"string"}})).reduce(((e,t)=>void 0===e?t:void 0===t?e:e===t?t:"string"===e||"string"===t?"string":"double"===e||"double"===t?"double":void 0))}const L=function(){const e=(0,w.B)(),t=new RegExp("^"+e.regexp+"$"),n=new RegExp("["+e.group+"\\s\\xa0]","g"),i=e.factor;return r=>{const s=t.exec(r);if(e.factor=i,!s)return NaN;let o=s[1];if(!s[1]){if(!s[2])return NaN;o=s[2],e.factor*=-1}return o=o.replace(n,"").replace(e.decimal,"."),+o*e.factor}}();function z(e){return JSON.parse(JSON.stringify(e))}var $=n(64714),P=n(95466),U=n(54218),V=n(98623);const B=(0,$.F0)("esriGeometryPoint"),Z=["csv"],G=[0,0];class Q{constructor(e,t){this.x=e,this.y=t}}class J{constructor(){this._queryEngine=null,this._snapshotFeatures=async e=>{const t=await this._fetch(e);return this._createFeatures(t)}}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t={}){this._loadOptions=e;const[n]=await Promise.all([this._fetch(t.signal),this._checkProjection(e?.parsingOptions?.spatialReference)]),i=function(e,t){const n=t.parsingOptions||{},i={delimiter:n.delimiter,layerDefinition:null,locationInfo:{latitudeFieldName:n.latitudeField,longitudeFieldName:n.longitudeField}},r=i.layerDefinition={name:(0,u.e7)(t.url,Z)||"csv",dateFieldsTimeReference:{timeZoneIANA:V.n$},drawingInfo:B,geometryType:"esriGeometryPoint",objectIdField:null,fields:[],timeInfo:n.timeInfo,extent:{xmin:Number.POSITIVE_INFINITY,ymin:Number.POSITIVE_INFINITY,xmax:Number.NEGATIVE_INFINITY,ymax:Number.NEGATIVE_INFINITY,spatialReference:n.spatialReference||{wkid:4326}}},s=v(e),l=s.next().value?.trim(),a=s.next().value?.trim();if(!l)throw new o.A("csv-layer:empty-csv","CSV is empty",{csv:e});const{delimiter:c,locationInfo:p}=k(l,a,n);if(!c)throw new o.A("csv-layer:invalid-delimiter","Unable to detect the delimiter from CSV",{firstLine:l,secondLine:a,parsingOptions:n});if(!p)throw new o.A("csv-layer:location-fields-not-found","Unable to identify latitude and longitude fields from the CSV file",{firstLine:l,secondLine:a,parsingOptions:n});i.locationInfo=p,i.delimiter=c;const{names:d,aliases:f}=D(l,c),h=function(e,t,n,i,r){const s=[],o=q(e,n,t),l=[];for(const e of o){if(10===l.length)break;l.push(e)}for(let e=0;e<n.length;e++){const t=n[e],o=i[e];if(t===r.longitudeFieldName||t===r.latitudeFieldName)s.push({name:t,type:"esriFieldTypeDouble",alias:o});else{let e;switch(R(l.map((e=>e[t])))){case"integer":e="esriFieldTypeInteger";break;case"double":e="esriFieldTypeDouble";break;case"date":e="esriFieldTypeDate";break;default:e="esriFieldTypeString"}s.push({name:t,type:e,alias:o,length:(0,x._b)(e)})}}return s}(e,i.delimiter,d,f,i.locationInfo);if(n.fields?.length){const e=new P.A(n.fields);for(const t of h){const n=e.get(t.name);n&&Object.assign(t,n)}}if(!h.some((e=>"esriFieldTypeOID"===e.type&&(r.objectIdField=e.name,!0)))){const e={name:"__OBJECTID",alias:"__OBJECTID",type:"esriFieldTypeOID",editable:!1,nullable:!1};r.objectIdField=e.name,h.unshift(e)}r.fields=h;const m=new P.A(r.fields);if(i.locationInfo&&(i.locationInfo.latitudeFieldName=m.get(i.locationInfo.latitudeFieldName).name,i.locationInfo.longitudeFieldName=m.get(i.locationInfo.longitudeFieldName).name),r.timeInfo){const e=r.timeInfo;if(e.startTimeField){const t=m.get(e.startTimeField);t?(e.startTimeField=t.name,t.type="esriFieldTypeDate"):e.startTimeField=null}if(e.endTimeField){const t=m.get(e.endTimeField);t?(e.endTimeField=t.name,t.type="esriFieldTypeDate"):e.endTimeField=null}if(e.trackIdField){const t=m.get(e.trackIdField);e.trackIdField=t?t.name:null}e.startTimeField||e.endTimeField||(r.timeInfo=null)}return i}(n,e);this._locationInfo=i.locationInfo,this._delimiter=i.delimiter,this._queryEngine=this._createQueryEngine(i);const r=await this._createFeatures(n);this._queryEngine.featureStore.addMany(r);const{fullExtent:s,timeExtent:l}=await this._queryEngine.fetchRecomputedExtents();if(i.layerDefinition.extent=s,l){const{start:e,end:t}=l;i.layerDefinition.timeInfo.timeExtent=[e,t]}return i}async applyEdits(){throw new o.A("csv-layer:editing-not-supported","applyEdits() is not supported on CSVLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),(await this._queryEngine.executeQueryForIds(e,t.signal)).filter(U.Et)}async queryExtent(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForExtent(e,t.signal)}async querySnapping(e,t={}){return await this._waitSnapshotComplete(),(0,g.J)(this._queryEngine,e,t.signal)}async queryAttributeBins(e,t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeAttributeBinsQuery(e,t.signal)}async refresh(e){this._loadOptions.customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,r.UT)(this._snapshotFeatures),this._snapshotTask.promise.then((e=>{this._queryEngine.featureStore.clear(),e&&this._queryEngine.featureStore.addMany(e)}),(e=>{this._queryEngine.featureStore.clear(),(0,a.zf)(e)||l.A.getLogger("esri.layers.CSVLayer").error(new o.A("csv-layer:refresh","An error occurred during refresh",{error:e}))})),await this._waitSnapshotComplete();const{fullExtent:t,timeExtent:n}=await this._queryEngine.fetchRecomputedExtents();return{extent:t,timeExtent:n}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _fetch(e){const{url:t,customParameters:n}=this._loadOptions;if(!t)throw new o.A("csv-layer:invalid-source","url not defined");const r=(0,u.An)(t);return(await(0,i.A)(r.path,{query:{...r.query,...n},responseType:"text",signal:e})).data}_createQueryEngine(e){const{objectIdField:t,fields:n,extent:i,timeInfo:r}=e.layerDefinition,s=new _.A({geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1});return new b.do({fieldsIndex:P.A.fromLayerJSON({fields:n,dateFieldsTimeReference:{timeZoneIANA:V.n$}}),geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1,timeInfo:r,objectIdField:t,spatialReference:i.spatialReference||{wkid:4326},featureStore:s})}async _createFeatures(e){const{latitudeFieldName:t,longitudeFieldName:n}=this._locationInfo,{objectIdField:i,fieldsIndex:r,spatialReference:o}=this._queryEngine;let l=[];const a=[],u=r.fields.filter((e=>e.name!==i)).map((e=>e.name));let g=0;const _={};for(const e of r.fields)if("esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type){const t=(0,x.lD)(e);void 0!==t&&(_[e.name]=t)}const S=q(e,u,this._delimiter,(0,$.Vx)(_,i));for(const e of S){const o=this._parseCoordinateValue(e[t]),u=this._parseCoordinateValue(e[n]);if(null!=u&&null!=o&&!isNaN(o)&&!isNaN(u)){e[t]=o,e[n]=u;for(const i in e)if(i!==t&&i!==n)if(r.isDateField(i))e[i]=(0,s._U)(e[i]);else if(r.isNumericField(i)){const t=L(e[i]);isNaN(t)?e[i]=null:e[i]=t}else null!=e[i]&&(e[i]=z(e[i]));e[i]=g,g++,l.push(new Q(u,o)),a.push(e)}}if(!(0,f.aI)({wkid:4326},o))if((0,f.K8)(o))for(const e of l)[e.x,e.y]=(0,h.je)(e.x,e.y,G);else l=(0,c.projectMany)(d.g,l,p.A.WGS84,o,null,null);const b=[];for(let e=0;e<l.length;e++){const{x:t,y:n}=l[e],r=a[e];r[i]=e+1,b.push(new m.Om(new y.A([],[t,n]),r,null,r[i]))}return b}_parseCoordinateValue(e){if(null==e||""===e)return null;let t=L(e);return(isNaN(t)||Math.abs(t)>181)&&(t=parseFloat(e)),t}async _checkProjection(e){try{await(0,S.Nk)(f.KK,e)}catch{throw new o.A("csv-layer:projection-not-supported","Projection not supported")}}}},60999:(e,t,n)=>{n.d(t,{DZ:()=>m,Ke:()=>h,Tj:()=>p,UT:()=>y,jJ:()=>c});var i=n(90237),r=n(69622),o=n(97768),l=n(74887),a=n(10107),u=n(40608);function c(e,t,n){return(0,l.Lx)(e.map(((e,i)=>t.apply(n,[e,i]))))}async function p(e,t,n){return(await(0,l.Lx)(e.map(((e,i)=>t.apply(n,[e,i]))))).map((e=>e.value))}function d(e){return{ok:!0,value:e}}function f(e){return{ok:!1,error:e}}async function h(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return d(await e)}catch(e){return f(e)}}async function m(e){try{return d(await e)}catch(e){return s(e),f(e)}}function y(e,t){return new g(e,t)}let g=class extends r.A{get value(){return null!=(e=this._result)&&!0===e.ok?e.value:null;var e}get error(){return null!=(e=this._result)&&!1===e.ok?e.error:null;var e}get finished(){return null!=this._result}constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,o.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:n}=this._abortController;this.promise=e(n),this.promise.then((e=>{this._result=d(e),this._cleanup()}),(e=>{this._result=f(e),this._cleanup()})),this._abortHandle=(0,l.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,o.xt)(this._abortHandle),this._abortController=null}};(0,i._)([(0,a.MZ)()],g.prototype,"value",null),(0,i._)([(0,a.MZ)()],g.prototype,"error",null),(0,i._)([(0,a.MZ)()],g.prototype,"finished",null),(0,i._)([(0,a.MZ)()],g.prototype,"promise",void 0),(0,i._)([(0,a.MZ)()],g.prototype,"_result",void 0),g=(0,i._)([(0,u.$)("esri.core.asyncUtils.ReactiveTask")],g)},64714:(e,t,n)=>{n.d(t,{F0:()=>l,Vx:()=>c,e2:()=>d,f:()=>f});var i=n(44208),r=n(4718),s=n(99352),o=n(93470);function l(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const a=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function c(e,t){if((0,i.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let n=`this${p(t)} = null;`;for(const t in e)n+=`this${p(t)} = ${JSON.stringify(e[t])};`;const i=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${n};\n }\n }\n `)();return()=>new i}catch(n){return()=>({[t]:null,...e})}}function p(e){return a.test(e)?`.${e}`:`["${e}"]`}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,r.o8)(e)}}]}function f(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},67482:(e,t,n)=>{function i(e){return null!=l(e)||null!=o(e)}function r(e){return a.test(e)}function s(e){return l(e)??o(e)}function o(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let n=!0;if(c&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,i=0;for(;!t&&i<=e.length;)t=!u.test(e[i]),i++;n=!t}}return n}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function l(e){const t=a.exec(e);if(!t?.groups)return null;const n=t.groups,i=+n.year,r=+n.month-1,s=+n.day,o=+(n.hours??"0"),l=+(n.minutes??"0"),u=+(n.seconds??"0");if(o>23)return null;if(l>59)return null;if(u>59)return null;const c=n.ms??"0",p=c?+c.padEnd(3,"0").slice(0,3):0;let d;if(n.isUTC||!n.offsetSign)d=Date.UTC(i,r,s,o,l,u,p);else{const e=+n.offsetHours,t=+n.offsetMinutes;d=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(i,r,s,o,l,u,p)}return Number.isNaN(d)?null:d}n.d(t,{Br:()=>r,Cq:()=>i,_U:()=>s});const a=/^(?:(?<year>-?\d{4,})-(?<month>\d{2})-(?<day>\d{2}))(?:T(?<hours>\d{2}):(?<minutes>\d{2}):(?<seconds>\d{2})(?:\.(?<ms>\d+))?)?(?:(?<isUTC>Z)|(?:(?<offsetSign>\+|-)(?<offsetHours>\d{2}):(?<offsetMinutes>\d{2})))?$/,u=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,c=!Number.isNaN(new Date("technology 10").getTime())},93470:(e,t,n)=>{n.d(t,{Cb:()=>s,HW:()=>c,JR:()=>r,JZ:()=>a,WR:()=>l,b6:()=>p,fT:()=>i,nC:()=>u,yM:()=>o});const i=[252,146,31,255],r=[153,153,153,255],s={type:"esriSMS",style:"esriSMSCircle",size:6,color:i,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:i},l={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},a={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},u={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},c={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},p={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1961,3186,4342],{4071:(e,t,r)=>{r.d(t,{$:()=>s,P:()=>i});const s={supportsDate:!1,supportsFixedInterval:!1,supportsAutoInterval:!1,supportsFixedBoundaries:!1,supportsStackBy:!1,supportsSplitBy:!1,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!1,supportedStatistics:void 0,supportedNormalizationTypes:void 0},i={analytics:{supportsCacheHint:!1},attachment:{supportsContentType:!1,supportsExifInfo:!1,supportsKeywords:!1,supportsName:!1,supportsSize:!1,supportsCacheHint:!1,supportsOrderByFields:!1,supportsResize:!1},data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:!1},editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsAsyncApplyEdits:!1,zDefault:void 0},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryBins:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s,query:{maxRecordCount:0,maxRecordCountFactor:0,standardMaxRecordCount:0,supportsCacheHint:!1,supportsCentroid:!1,supportsCompactGeometry:!1,supportsCurrentUser:!1,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsReturnMesh:!1,supportsSqlExpression:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsTrueCurve:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsStatistics:!1,tileMaxRecordCount:0}}},17311:(e,t,r)=>{r.d(t,{A:()=>c});var s=r(90237),i=r(69622),n=r(60999),o=r(5503),a=r(10107),l=(r(44208),r(53966),r(87811),r(40608)),u=r(30524),p=r(43668);let d=class extends i.A{constructor(e){super(e),this._featureUtils=null,this.effectivePopupTemplate=null}get _arcadeTask(){return this.expressionsUsedInTitle.length>0?this._get("_arcadeTask")||(0,n.UT)((()=>(0,p.l)())):null}get featureUtilsPromise(){return this._get("featureUtilsPromise")??r.e(9926).then(r.bind(r,29926)).then((e=>this._featureUtils=e))}get calculatedExpressions(){const e=new o.A;if(!this.expressionsUsedInTitle.length)return e;if(!this._arcadeTask?.value){for(const t of this.expressionsUsedInTitle??[])e.push({name:t.name,invalid:!0});return e}for(const t of this.expressionsUsedInTitle)try{const r=this._arcadeTask.value.arcade.parseScript(t.expression,["$layer","$map","$datastore"]);if(r.isAsync){e.push({name:t.name,invalid:!0});break}e.push({name:t.name,syntax:r,invalid:!1,func:this._arcadeTask.value.arcade.compileScript(r,{vars:{$feature:"any"}})})}catch{e.push({name:t.name,invalid:!0});break}return e}get expressionsUsedInTitle(){let e=this.effectivePopupTemplate?.title??"";return"string"!=typeof e?[]:(e=e.toLowerCase(),this.effectivePopupTemplate?.expressionInfos?.filter((t=>e.includes(`{expression/${t.name.toLowerCase()}}`)))??[])}get fieldInfoMap(){return this._featureUtils?this._createFieldInfoMap(this._featureUtils.getAllFieldInfos(this.effectivePopupTemplate)):null}get hasBadExpressions(){return this.calculatedExpressions.some((e=>!0===e.invalid))}get requiredFields(){const e=new Set;if(this._arcadeTask?.value&&!this.hasBadExpressions)for(const t of this.calculatedExpressions?.toArray()??[])try{const r=this._arcadeTask.value.arcade.extractFieldLiterals(t.syntax);for(const t of r){const r=t.split("."),s=this.fieldsIndex.get(r.at(-1)??"");s&&e.add(s.name)}}catch{}const t=this._extractFieldNames(this.workingTitle);for(const r of t){const t=this.fieldsIndex.get(r);t&&e.add(t.name)}return e}get titleFromDisplayField(){let e="";return this.displayField&&(e=this.fieldsIndex.get(this.displayField)?.name??""),e||(e=this.fieldsIndex.get(this.objectIdField)?.name??""),e?`{${e}}`:""}get workingTitle(){const e=this.effectivePopupTemplate?this.effectivePopupTemplate.title:"";return""===e||null==e||this.hasBadExpressions||"string"!=typeof e?this.titleFromDisplayField:e}async getTitle(e,t,r){try{const{attributes:s}=t,i=r?.timeZone??"system",[{substituteFieldsInLinksAndAttributes:n}]=await Promise.all([this.featureUtilsPromise,this._arcadeTask?.promise]);if(r.fetchMissingFields&&(t=await this._checkAndReQueryGraphic(e,t)),this.workingTitle&&this.fieldInfoMap){const r=this._createFormattedAttributes(e,t,i).global;return n({attributes:s,expressionAttributes:null,fieldInfoMap:this.fieldInfoMap,globalAttributes:r,layer:e,text:this.workingTitle})}return""}catch{}return""}async _checkAndReQueryGraphic(e,t){const r=t.getObjectId();if(null==r)return t;if(!(0,u.Kl)(this.requiredFields,t)){const t=e.createQuery();t.where="1=1",t.outFields=[...this.requiredFields],t.objectIds=[r];const s=await e.queryFeatures(t);if(1===s?.features.length)return s.features[0]}return t}_createFieldInfoMap(e){const t=new Map;if(!e)return t;for(const r of e){if(!r.fieldName)continue;const e=this.fieldsIndex.get(r.fieldName),s=e?.name??r.fieldName;r.fieldName=s,t.set(s.toLowerCase(),r)}return t}_createFormattedAttributes(e,t,r="system"){const s=this.effectivePopupTemplate?.fieldInfos??[],i={};if(!this._featureUtils)return{};if(!this.hasBadExpressions&&this.calculatedExpressions.length>0&&this._arcadeTask?.value){const r=this._arcadeTask.value.Feature.createFromGraphicLikeObject(t.geometry,t.attributes,e,null);for(const e of this.calculatedExpressions)try{i[`expression/${e.name}`]=e.func({vars:{$feature:r}})}catch{}}const n={...t.attributes,...i};return{global:this._featureUtils.formatAttributes({fieldInfos:s,attributes:n,graphic:t,timeZone:r,layer:e,fieldInfoMap:this.fieldInfoMap}),content:[]}}_extractFieldNames(e){return(0,u.nw)(e).filter((e=>!(0===e.indexOf("relationships/")||0===e.indexOf("expression/"))))}};(0,s._)([(0,a.MZ)({readOnly:!0})],d.prototype,"_arcadeTask",null),(0,s._)([(0,a.MZ)()],d.prototype,"_featureUtils",void 0),(0,s._)([(0,a.MZ)({readOnly:!0})],d.prototype,"featureUtilsPromise",null),(0,s._)([(0,a.MZ)({readOnly:!0})],d.prototype,"calculatedExpressions",null),(0,s._)([(0,a.MZ)()],d.prototype,"displayField",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"effectivePopupTemplate",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"expressionsUsedInTitle",null),(0,s._)([(0,a.MZ)()],d.prototype,"fieldsIndex",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"fieldInfoMap",null),(0,s._)([(0,a.MZ)()],d.prototype,"fields",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"objectIdField",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"requiredFields",null),d=(0,s._)([(0,l.$)("esri.layers.support.TitleCreator")],d);const c=d},22671:(e,t,r)=>{r.d(t,{A:()=>v});var s,i=r(90237),n=r(52106),o=r(66552),a=r(25482),l=r(4718),u=r(10107),p=(r(44208),r(53966),r(36005)),d=r(40608),c=r(43937),y=r(16930),h=r(65864),f=r(50498),m=r(20437);const g=new o.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let _=s=class extends a.A{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){return this.readFeaturesWithClass(e,t,n.A)}writeGeometryType(e,t,r,s){if(e)return void g.write(e,t,r,s);const{features:i}=this;if(i)for(const e of i)if(null!=e?.geometry)return void g.write(e.geometry.type,t,r,s)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,s=(0,h.rS)(e);return s&&!r&&t.spatialReference&&(s.spatialReference=y.A.fromJSON(t.spatialReference)),s}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:r}=this;if(r)for(const e of r)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new s(this.cloneProperties())}cloneProperties(){return(0,l.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){const s=t.features[r];if(s.geometry){const t=e?.[r];s.geometry=t?.toJSON()||s.geometry}}return t}quantize(e){const{scale:[t,r],translate:[s,i]}=e,n=this.features,o=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-s)/t)),(e=>Math.round((i-e)/r)));for(let e=0,t=n.length;e<t;e++)o?.(n[e].geometry)||(n.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[s,i],scale:[n,o]}=r;let a=null,l=null;if(this.hasZ&&null!=r?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=r;a=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=r;l=r=>null==r?r:r*t+e}const u=this._getHydrationFunction(e,(e=>e*n+s),(e=>i-e*o),a,l);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}readFeaturesWithClass(e,t,r){const s=y.A.fromJSON(t.spatialReference),i=[];for(let t=0;t<e.length;t++){const n=e[t],o=r.fromJSON(n),a=n.geometry?.spatialReference;null==o.geometry||a||(o.geometry.spatialReference=s);const l=n.aggregateGeometries,u=o.aggregateGeometries;if(l&&null!=u)for(const e in u){const t=u[e],r=l[e],i=r?.spatialReference;null==t||i||(t.spatialReference=s)}i.push(o)}return i}_quantizePoints(e,t,r){let s,i;const n=[];for(let o=0,a=e.length;o<a;o++){const a=e[o];if(o>0){const e=t(a[0]),o=r(a[1]);e===s&&o===i||(n.push([e-s,o-i]),s=e,i=o)}else s=t(a[0]),i=r(a[1]),n.push([s,i])}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=>{const s=(0,h.Bi)(e)?e.rings:e.paths,i=[];for(let e=0,n=s.length;e<n;e++){const n=s[e],o=this._quantizePoints(n,t,r);o&&i.push(o)}return i.length>0?((0,h.Bi)(e)?e.rings=i:e.paths=i,e):null}:"multipoint"===e?e=>{const s=this._quantizePoints(e.points,t,r);return s&&s.length>0?(e.points=s,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r,s,i){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y),s&&(e.z=s(e.z))}:"polyline"===e||"polygon"===e?e=>{const n=(0,h.Bi)(e)?e.rings:e.paths;let o,a;for(let e=0,s=n.length;e<s;e++){const s=n[e];for(let e=0,i=s.length;e<i;e++){const i=s[e];e>0?(o+=i[0],a+=i[1]):(o=i[0],a=i[1]),i[0]=t(o),i[1]=r(a)}}if(s&&i)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=s(r[2]),r[3]=i(r[3])}}else if(s)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=s(r[2])}}else if(i)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(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),s&&null!=e.zmax&&null!=e.zmin&&(e.zmax=s(e.zmax),e.zmin=s(e.zmin)),i&&null!=e.mmax&&null!=e.mmin&&(e.mmax=i(e.mmax),e.mmin=i(e.mmin))}:"multipoint"===e?e=>{const n=e.points;let o,a;for(let e=0,s=n.length;e<s;e++){const s=n[e];e>0?(o+=s[0],a+=s[1]):(o=s[0],a=s[1]),s[0]=t(o),s[1]=r(a)}if(s&&i)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=s(t[2]),t[3]=i(t[3])}else if(s)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=s(t[2])}else if(i)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=i(t[2])}}:null}};(0,i._)([(0,u.MZ)({type:String,json:{write:!0}})],_.prototype,"displayFieldName",void 0),(0,i._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"exceededTransferLimit",void 0),(0,i._)([(0,u.MZ)({type:[n.A],json:{write:!0}})],_.prototype,"features",void 0),(0,i._)([(0,p.w)("features")],_.prototype,"readFeatures",null),(0,i._)([(0,u.MZ)({type:[m.A],json:{write:!0}})],_.prototype,"fields",void 0),(0,i._)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],_.prototype,"geometryType",void 0),(0,i._)([(0,c.K)("geometryType")],_.prototype,"writeGeometryType",null),(0,i._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasM",void 0),(0,i._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasZ",void 0),(0,i._)([(0,u.MZ)({types:f.yR,json:{write:!0}})],_.prototype,"queryGeometry",void 0),(0,i._)([(0,p.w)("queryGeometry")],_.prototype,"readQueryGeometry",null),(0,i._)([(0,u.MZ)({type:y.A,json:{write:!0}})],_.prototype,"spatialReference",void 0),(0,i._)([(0,c.K)("spatialReference")],_.prototype,"writeSpatialReference",null),(0,i._)([(0,u.MZ)({json:{write:!0}})],_.prototype,"transform",void 0),_=s=(0,i._)([(0,d.$)("esri.rest.support.FeatureSet")],_),_.prototype.toJSON.isDefaultToJSON=!0;const v=_},32730:(e,t,r)=>{r.d(t,{BI:()=>m,D3:()=>h,XJ:()=>f,lc:()=>y,mX:()=>_,rU:()=>g,tH:()=>S});var s=r(799);const i="__begin__",n="__end__",o=new RegExp(i,"ig"),a=new RegExp(n,"ig"),l=new RegExp("^"+i,"i"),u=new RegExp(n+"$","i"),p='"',d=p+" + ",c=" + "+p;function y(e){return e.replaceAll(new RegExp("\\[","g"),"{").replaceAll(new RegExp("\\]","g"),"}")}function h(e){return e.replaceAll(new RegExp("\\{","g"),"[").replaceAll(new RegExp("\\}","g"),"]")}function f(e){const t={expression:"",type:"none"};return e.labelExpressionInfo?e.labelExpressionInfo.value?(t.expression=e.labelExpressionInfo.value,t.type="conventional"):e.labelExpressionInfo.expression&&(t.expression=e.labelExpressionInfo.expression,t.type="arcade"):null!=e.labelExpression&&(t.expression=y(e.labelExpression),t.type="conventional"),t}function m(e){const t=f(e);switch(t.type){case"conventional":return _(t.expression);case"arcade":return t.expression}return null}function g(e){const t=f(e);switch(t.type){case"conventional":return function(e){const t=e?.match(v);return t?.[1].trim()||null}(t.expression);case"arcade":return S(t.expression)}return null}function _(e){let t;return e?(t=(0,s.HC)(e,(e=>i+'$feature["'+e+'"]'+n)),t=l.test(t)?t.replace(l,""):p+t,t=u.test(t)?t.replace(u,""):t+p,t=t.replaceAll(o,d).replaceAll(a,c)):t='""',t}const v=/^\s*\{([^}]+)\}\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,w=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,x=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function S(e){if(!e)return null;let t=b.exec(e)||w.exec(e);return t?t[1]||t[3]:(t=x.exec(e),t?t[2]:null)}},32756:(e,t,r)=>{r.d(t,{Rr:()=>l,fY:()=>p,ne:()=>u});var s=r(90237),i=r(93637),n=r(10107),o=(r(44208),r(53966),r(87811),r(40608)),a=r(91880);function l(e,t,r){if(!e)return null;const s=e.find((e=>!!e.field));if(!s)return null;const i=new a.A;return i.read(s,r),[i]}const u={type:[a.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:l},write:{writer:function(e,t,r,s){const n=e.find((e=>!!e.field));n&&(0,i.sM)(r,[n.toJSON()],t)}}}},p=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,s._)([(0,n.MZ)(u)],t.prototype,"orderBy",void 0),t=(0,s._)([(0,o.$)("esri.layers.mixins.OrderedLayer")],t),t}},33143:(e,t,r)=>{r.d(t,{A:()=>y});var s=r(90237),i=r(69540),n=r(25482),o=r(10107),a=(r(44208),r(53966),r(87811),r(36005)),l=r(40608),u=r(43937),p=r(80451),d=r(29005);let c=class extends(i.A.ClonableMixin(n.A)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,p.rS)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,s._)([(0,o.MZ)({json:{write:!0}})],c.prototype,"id",void 0),(0,s._)([(0,o.MZ)({json:{write:!0}})],c.prototype,"name",void 0),(0,s._)([(0,o.MZ)({json:{write:!0}})],c.prototype,"domains",void 0),(0,s._)([(0,a.w)("domains")],c.prototype,"readDomains",null),(0,s._)([(0,u.K)("domains")],c.prototype,"writeDomains",null),(0,s._)([(0,o.MZ)({type:[d.A],json:{write:!0}})],c.prototype,"templates",void 0),c=(0,s._)([(0,l.$)("esri.layers.support.FeatureType")],c);const y=c},38961:(e,t,r)=>{r.d(t,{A:()=>p});var s=r(90237),i=r(5503),n=r(36708),o=r(10107),a=r(40608),l=r(80559);let u=class extends i.A{constructor(e){super(e),this.getCollections=null}initialize(){this.addHandles((0,l.fm)((()=>this._refresh()),n.OH))}destroy(){this.getCollections=null}_refresh(){const e=null!=this.getCollections?this.getCollections():null;if(null==e)return void this.removeAll();let t=0;for(const r of e)null!=r&&(t=this._processCollection(t,r));this.splice(t,this.length)}_createNewInstance(e){return new i.A(e)}_processCollection(e,t){if(!t)return e;const r=this.itemFilterFunction??(e=>!!e);for(const s of t)if(s){if(r(s)){const t=this.indexOf(s,e);t>=0?t!==e&&this.reorder(s,e):this.add(s,e),++e}if(this.getChildrenFunction){const t=this.getChildrenFunction(s);if(Array.isArray(t))for(const r of t)e=this._processCollection(e,r);else e=this._processCollection(e,t)}}return e}};(0,s._)([(0,o.MZ)()],u.prototype,"getCollections",void 0),(0,s._)([(0,o.MZ)()],u.prototype,"getChildrenFunction",void 0),(0,s._)([(0,o.MZ)()],u.prototype,"itemFilterFunction",void 0),u=(0,s._)([(0,a.$)("esri.core.CollectionFlattener")],u);const p=u},39516:(e,t,r)=>{let s;async function i(){return null==s&&(s=r.e(4123).then(r.bind(r,44123)).then((e=>new e.WhereClauseCache(500,500)))),s}async function n(e,t){const r=await i(),s=r.get(e,t);if(null==s)throw r.getError(e,t);return s}function o(e,t){return e||=null,t||=null,"1=1"===e?t??e:"1=1"===t?e??t:e&&t?`(${e}) AND (${t})`:e??t}function a(e,t){return e||=null,t||=null,"1=1"===e||"1=1"===t||e===t?"1=1"===e?e:t:e&&t?`(${e}) OR (${t})`:e??t}r.d(t,{GP:()=>n,IW:()=>a,mA:()=>o})},41366:(e,t,r)=>{r.d(t,{K:()=>c,Q:()=>u});var s=r(90237),i=r(66552),n=r(53966),o=r(10107),a=(r(44208),r(87811),r(93223)),l=r(40608);const u=(0,i.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),p="percent-of-total",d="field",c=e=>{let t=class extends e{constructor(){super(...arguments),this.normalizationField=null,this.normalizationMaxValue=null,this.normalizationMinValue=null,this.normalizationTotal=null}get normalizationType(){let e=this._get("normalizationType");const t=!!this.normalizationField,r=null!=this.normalizationTotal;return t||r?(e=t&&d||r&&p||null,t&&r&&n.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):e!==d&&e!==p||(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,s._)([(0,o.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],t.prototype,"normalizationField",void 0),(0,s._)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],t.prototype,"normalizationMaxValue",void 0),(0,s._)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],t.prototype,"normalizationMinValue",void 0),(0,s._)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],t.prototype,"normalizationTotal",void 0),(0,s._)([(0,a.e)(u,{name:"parameters.normalizationType"})],t.prototype,"normalizationType",null),t=(0,s._)([(0,l.$)("esri.rest.support.NormalizationBinParametersMixin")],t),t}},41560:(e,t,r)=>{r.d(t,{Ch:()=>o,mW:()=>n});var s=r(34727),i=r(39516);function n(e,t){return{...t,filterMode:e.mode}}function o(e,t,r){const n=function(e){if("manual"===u(e))return null;const t=[Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY];for(const{minScale:r,maxScale:s}of e.filters)t[0]=Math.max(t[0],p(r)),t[1]=Math.min(t[1],d(s));return t}(e);if(n&&((0,s.gg)(t,n[0])||(0,s.ZH)(r,n[1])))return"";const o=Array.from(a(e,t,r)),l=function(e,t,r){if(0===e.length)return!0;const i=p(e.at(0)?.minScale),n=d(e.at(-1)?.maxScale);if((0,s.ZH)(i,t)||(0,s.gg)(n,r))return!0;for(let t=0;t<e.length-1;t++){const r=e[t],i=e[t+1];if((0,s.ZH)(p(i.minScale),d(r.maxScale)))return!0}return!1}(o,t,r)?"1=1":o.map((e=>e.where||"1=1")).reduce(((e,t)=>(0,i.IW)(e,t)),"");return l&&"1=1"!==l?l:""}function*a(e,t,r){if("manual"===u(e)){const t=e.filters.find((t=>t.id===e.activeFilterId));t&&(yield t)}else{"object"==typeof t&&(t=t.scale);for(const s of e.filters)l(s.minScale,s.maxScale,t,r)&&(yield s)}}function l(e,t,r,i){return e=p(e),r=p(r),t=d(t),!(!(0,s.Sp)(r,e)&&(i??r)>e||(0,s.Hx)(t,r)||void 0!==i&&(0,s.Sp)(i,e))}function u(e){return"mode"in e?e.mode:e.filterMode}function p(e){return e||Number.POSITIVE_INFINITY}function d(e){return e||0}},45671:(e,t,r)=>{r.d(t,{D8:()=>n,TO:()=>i});var s=r(30524);async function i(e,t=e.popupTemplate){if(null==t)return[];const r=await t.getRequiredFields(e.fieldsIndex),{lastEditInfoEnabled:i}=t,{objectIdField:n,typeIdField:o,globalIdField:a,relationships:l}=e;if(r.includes("*"))return["*"];const u=i?(0,s.eX)(e):[],p=(0,s.DB)(e.fieldsIndex,[...r,...u]);return o&&p.push(o),p&&n&&e.fieldsIndex?.has(n)&&!p.includes(n)&&p.push(n),p&&a&&e.fieldsIndex?.has(a)&&!p.includes(a)&&p.push(a),l&&l.forEach((t=>{const{keyField:r}=t;p&&r&&e.fieldsIndex?.has(r)&&!p.includes(r)&&p.push(r)})),p}function n(e,t){return e.popupTemplate?e.popupTemplate:null!=t&&t.defaultPopupTemplateEnabled&&null!=e.defaultPopupTemplate?e.defaultPopupTemplate:null}},46140:(e,t,r)=>{r.d(t,{R:()=>i});var s=r(49186);let i=class e{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}validate(e){if(this.major!==e.major){const t=this._context&&this._context+":",r=this._context&&this._context+" ";throw new s.A(t+"unsupported-version",`Required major ${r}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new e(this.major,this.minor,this._context)}static parse(t,r=""){const[i,n]=t.split("."),o=/^\s*\d+\s*$/;if(!i?.match||!o.test(i))throw new s.A((r&&r+":")+"invalid-version","Expected major version to be a number, but got '${version}'",{version:t});if(!n?.match||!o.test(n))throw new s.A((r&&r+":")+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:t});const a=parseInt(i,10),l=parseInt(n,10);return new e(a,l,r)}}},55674:(e,t,r)=>{r.d(t,{Ad:()=>y,Gj:()=>m,QY:()=>c,lL:()=>g,xR:()=>h});var s=r(66131),i=r(49186),n=(r(44208),r(44729)),o=r(15032),a=r(65864),l=r(95466),u=r(43668),p=r(98623);const d=["geometry","scale","timeProperties"];function c(e,t){if(null!=t)for(const r of d)t.hasArcadeDependency(r)&&e.add(r);return e}function y(e,t){return f.create(e,t,null,["$feature","$view"])}function h(e,t,r){return f.create(e,t,r,["$feature","$view","$config"])}class f{static async create(e,t,r,s){const{arcade:n,Dictionary:o}=await(0,u.l)();let a;try{a=n.parseScript(e)}catch(t){throw new i.A("arcade-bad-expression","Failed to parse arcade script",{script:e,error:t})}const l=n.scriptUsesGeometryEngine(a);l&&await n.enableGeometrySupport(),await n.loadDependentModules(new Set,a,null,!1,l);const p={vars:s.reduce(((e,t)=>({...e,[t]:null})),{}),spatialReference:t,useAsync:!1},d=n.compileScript(a,p);let c=null;null!=r&&(c=new o(r),c.immutable=!0);const y=new o;return y.immutable=!1,y.setField("scale",0),new f(e,n,a,d,t,y,c,o)}constructor(e,t,r,s,i,n,o,a){this.script=e,this._arcade=t,this._syntaxTree=r,this._compiled=s,this._spatialReference=i,this._viewDict=n,this._configDict=o,this._dictionaryCtor=a,this._dependencies=new Map,this._featureReader=new m,this._dependencies.set("geometry",t.scriptTouchesGeometry(this._syntaxTree)),this._dependencies.set("scale",this._arcade.referencesMember(this._syntaxTree,"scale")),this._dependencies.set("timeProperties",this._arcade.scriptUsesViewProperties(this._syntaxTree,["timeProperties"]))}evaluate(e,t){const r=t.$view?.timeZone;if(t.$view){let e;if(this._viewDict.setField("scale",t.$view.scale),null!=t.$view.timeProperties){const{currentStart:i,currentEnd:n}=t.$view.timeProperties;e=new this._dictionaryCtor({currentStart:null!=i?null!=r?s.lY.epochToArcadeDate(i,r):s.lY.unknownEpochToArcadeDate(i):void 0,currentEnd:null!=n?null!=r?s.lY.epochToArcadeDate(n,r):s.lY.unknownEpochToArcadeDate(n):void 0,startIncluded:!0,endIncluded:!0})}this._viewDict.setField("timeProperties",e)}return this._compiled({vars:{$view:this._viewDict,$config:this._configDict,$feature:e},spatialReference:this._spatialReference,timeZone:r})}repurposeFeature(e,t){return this._featureReader.bind(e,t,this._spatialReference),this._featureReader}references(e){return this._dependencies.get(e)??!1}}class m{constructor(){this._boundTarget=null,this._boundSchema={fields:null,fieldsIndex:null,spatialReference:null,get geometryType(){return null},get objectIdField(){return null}},this.arcadeDeclaredClass="esri.arcade.Feature",this._contextTimeZone=null}bind(e,t,r){const s=t??new l.A(g(e.attributes));this._boundTarget=e,this._boundSchema.fields=s.fields,this._boundSchema.fieldsIndex=s,this._boundSchema.spatialReference=r}_getField(e){return this._boundSchema.fieldsIndex.get(e)}get contextTimeZone(){return this._contextTimeZone}set contextTimeZone(e){this._contextTimeZone=e}readArcadeFeature(){return this}hasField(e){return this._boundSchema.fieldsIndex.has(e)}geometry(){if("fromJSON"in this._boundTarget)return this._boundTarget.geometry;const e=(0,a.rS)(this._boundTarget.geometry);if(e){if(!this._boundSchema.spatialReference)throw new Error("InternalError: Expected spatial reference to be defined");e.spatialReference=this._boundSchema.spatialReference}return e}isUnknownDateTimeField(e){return this._boundSchema.fieldsIndex.getTimeZone(e)===p.L5}field(e,t=!0){const r=this._getField(e);if(r)switch(r.type){case"date-only":case"esriFieldTypeDateOnly":return n.n.fromReader(this._boundTarget.attributes[r.name]);case"time-only":case"esriFieldTypeTimeOnly":return o.k.fromReader(this._boundTarget.attributes[r.name]);case"esriFieldTypeTimestampOffset":case"timestamp-offset":return s.lY.fromReaderAsTimeStampOffset(this._boundTarget.attributes[r.name]);case"date":case"esriFieldTypeDate":{const t=this._boundTarget.attributes[r.name];return this.isUnknownDateTimeField(e)?s.lY.unknownEpochToArcadeDate(t):s.lY.epochToArcadeDate(t,this.contextTimeZone??p.qU)}default:return this._boundTarget.attributes[r.name]}if(t)throw new Error(`Field ${e} does not exist`);return null}setField(e,t){throw new Error("Unable to update feature attribute values, feature is readonly")}keys(){return this._boundSchema.fieldsIndex.fields.map((e=>e.name))}castToText(e=!1){return JSON.stringify(this._boundTarget)}gdbVersion(){return null}fullSchema(){return this._boundSchema}castAsJson(e=null){return{attributes:this._boundTarget.attributes,geometry:!0===e?.keepGeometryType?this.geometry():this.geometry()?.toJSON()??null}}castAsJsonAsync(e=null,t=null){return Promise.resolve(this.castAsJson(t))}}function g(e){const t=[];for(const r in e)t.push({name:r,alias:r,type:"string"==typeof e[r]?"esriFieldTypeString":"esriFieldTypeDouble"});return t}},58501:(e,t,r)=>{r.d(t,{q:()=>i});var s=r(62815);function i(e,t,r){if(!r?.features||!r.hasZ)return;const i=(0,s.N)(r.geometryType,t,e.outSpatialReference);if(null!=i)for(const e of r.features)i(e.geometry)}},73681:(e,t,r)=>{r.d(t,{n:()=>l});var s=r(49186),i=r(53966),n=r(46140),o=r(95466),a=r(55674);class l{static async from(e,t,r){const o=e.dictionary_version?n.R.parse(e.dictionary_version):null,p=new Set(e.itemsNames),d={};if(t)for(const e in t)d[e]=t[e];if(e.authoringInfo.configuration)for(const t of e.authoringInfo.configuration)d.hasOwnProperty(t.name)||(d[t.name]=t.value);const c=new Set(e.authoringInfo.symbol);for(const e of Object.keys(r))c.delete(e);c.size&&i.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:c});const y=await(0,a.xR)(e.expression,null,d);if(!y)throw new s.A("dictionary-renderer:expression-error","Unable to create dictionary renderer expression");const h=!o||!o.greaterEqual(4,0);h&&i.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:o});const f=new u(r,h);return new l(h,p,y,f)}constructor(e,t,r,s){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=s}get itemNames(){return this._itemNames}evaluate(e,t,r,s){try{return this._reader.bind(e,r,s),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){i.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new o.A(e);const t=e.map((e=>({...e,type:"esriFieldTypeString"})));return new o.A(t)}}class u extends a.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){const t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);const t=this._getField(e);return null==t?"":""+this._boundTarget.attributes[t.name]}}},81583:(e,t,r)=>{r.d(t,{L:()=>a,g:()=>o});var s=r(60999),i=r(5503),n=r(92474);async function o(e,t){return await e.load(),a(e,t)}async function a(e,t){const r=[],o=(...e)=>{for(const t of e)null!=t&&(Array.isArray(t)?o(...t):i.A.isCollection(t)?t.forEach((e=>o(e))):n.A.isLoadable(t)&&r.push(t))};t(o);let a=null;if(await(0,s.Tj)(r,(async e=>{const t=await(0,s.Ke)(function(e){return"loadAll"in e&&"function"==typeof e.loadAll}(e)?e.loadAll():e.load());!1!==t.ok||a||(a=t)})),a)throw a.error;return e}},88303:(e,t,r)=>{r.r(t),r.d(t,{default:()=>rt});var s=r(90237),i=r(5503),n=r(38961),o=r(49186),a=r(36563),l=r(4718),u=r(81583),p=r(53966),d=r(92071),c=r(74887),y=r(36708),h=r(84952),f=r(10107),m=(r(44208),r(36005)),g=r(40608),_=r(16930),v=r(4146),b=r(52106),w=r(13874),x=r(78888),S=r(66552),M=r(92474),T=r(61893),A=(r(87811),r(93223)),F=r(5443),I=r(13600),Z=r(4902),O=r(56507),E=r(10873);let j=class extends(Z.A.IdentifiableMixin(d.L)){constructor(e){super(e),this.title="",this.id=-1,this.modelName=null,this.isEmpty=null,this.legendEnabled=!0,this.visible=!0,this.opacity=1}readTitle(e,t){return"string"==typeof t.alias?t.alias:"string"==typeof t.name?t.name:""}readIdOnlyOnce(e){return-1!==this.id?this.id:"number"==typeof e?e:-1}};(0,s._)([(0,f.MZ)({type:String,json:{origins:{"web-scene":{write:!0},"portal-item":{write:!0}}}})],j.prototype,"title",void 0),(0,s._)([(0,m.w)("service","title",["alias","name"])],j.prototype,"readTitle",null),(0,s._)([(0,f.MZ)()],j.prototype,"layer",void 0),(0,s._)([(0,f.MZ)({type:O.jz,readOnly:!0,json:{read:!1,write:{ignoreOrigin:!0,isRequired:!0}}})],j.prototype,"id",void 0),(0,s._)([(0,m.w)("service","id")],j.prototype,"readIdOnlyOnce",null),(0,s._)([(0,f.MZ)((0,E.Qo)(String))],j.prototype,"modelName",void 0),(0,s._)([(0,f.MZ)((0,E.Qo)(Boolean))],j.prototype,"isEmpty",void 0),(0,s._)([(0,f.MZ)({type:Boolean,nonNullable:!0})],j.prototype,"legendEnabled",void 0),(0,s._)([(0,f.MZ)({type:Boolean,json:{name:"visibility",write:!0}})],j.prototype,"visible",void 0),(0,s._)([(0,f.MZ)({type:Number,json:{write:!0}})],j.prototype,"opacity",void 0),j=(0,s._)([(0,g.$)("esri.layers.buildingSublayers.BuildingSublayer")],j);const R=j;var P=r(4071),L=r(15426),$=r(17036),N=r(95466),B=r(30524),q=r(83898),C=r(50805),k=r(41214),D=r(61956),z=r(54218),U=r(30291),Q=r(88625),G=r(4654),V=r(45671);const J=(0,$.p)();let H=class extends(M.A.LoadableMixin(T.A.EsriPromiseMixin(R))){constructor(e){super(e),this.type="building-component",this.nodePages=null,this.materialDefinitions=[],this.textureSetDefinitions=[],this.geometryDefinitions=[],this.indexInfo=null,this.serviceUpdateTimeStamp=null,this.store=null,this.attributeStorageInfo=[],this.fields=[],this.associatedLayer=null,this.outFields=null,this.listMode="show",this.renderer=null,this.definitionExpression=null,this.popupEnabled=!0,this.popupTemplate=null,this.layerType="3d-object"}get parsedUrl(){return this.layer?{path:`${this.layer.parsedUrl?.path}/sublayers/${this.id}`,query:this.layer.parsedUrl?.query}:{path:""}}get fieldsIndex(){return new N.A(this.fields)}readAssociatedLayer(e,t){const r=this.layer.associatedFeatureServiceItem,s=t.associatedLayerID;return null!=r&&"number"==typeof s?new I.default({portalItem:r,customParameters:this.customParameters,layerId:s}):null}get objectIdField(){if(null!=this.fields)for(const e of this.fields)if("oid"===e.type)return e.name;return null}get displayField(){return null!=this.associatedLayer?this.associatedLayer.displayField:void 0}get apiKey(){return this.layer.apiKey}get customParameters(){return this.layer.customParameters}get fullExtent(){return this.layer.fullExtent}get spatialReference(){return this.layer.spatialReference}get version(){return this.layer.version}get elevationInfo(){return this.layer.elevationInfo}get minScale(){return this.layer.minScale}get maxScale(){return this.layer.maxScale}get effectiveScaleRange(){return this.layer.effectiveScaleRange}get defaultPopupTemplate(){return this.createPopupTemplate()}load(e){const t=null!=e?e.signal:null,r=this._fetchService(t).then((()=>{this.indexInfo=(0,q.F)(this.parsedUrl.path,this.rootNode,this.nodePages,this.customParameters,this.apiKey,p.A.getLogger(this),t)}));return this.addResolvingPromise(r),Promise.resolve(this)}createPopupTemplate(e){return(0,U.tn)(this,e)}async _fetchService(e){const t=(await(0,x.A)(this.parsedUrl.path,{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:e})).data;this.read(t,{origin:"service",url:this.parsedUrl})}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){const r=this.getField(e)?.domain??null;return this.associatedLayer?(0,L.Vq)(this.associatedLayer,e,t,r):r}getFeatureType(e){return e&&null!=this.associatedLayer?this.associatedLayer.getFeatureType(e):null}get types(){return null!=this.associatedLayer?this.associatedLayer.types??[]:[]}get typeIdField(){return null!=this.associatedLayer?this.associatedLayer.typeIdField:null}get geometryType(){return"3d-object"===this.layerType?"mesh":"point"}get profile(){return"3d-object"===this.layerType?"mesh-pyramids":"points"}get capabilities(){const e=null!=this.associatedLayer&&this.associatedLayer.capabilities?this.associatedLayer.capabilities:P.P,{query:t,operations:{supportsQuery:r},data:{supportsZ:s,supportsM:i,isVersioned:n}}=e;return{query:t,operations:{supportsQuery:r},data:{supportsZ:s,supportsM:i,isVersioned:n}}}createQuery(){const e=new D.A;return"mesh"!==this.geometryType&&(e.returnGeometry=!0,e.returnZ=!0),e.where=this.definitionExpression||"1=1",e.sqlFormat="standard",e}queryExtent(e,t){return this._getAssociatedLayerForQuery().then((r=>r.queryExtent(e||this.createQuery(),t)))}queryFeatureCount(e,t){return this._getAssociatedLayerForQuery().then((r=>r.queryFeatureCount(e||this.createQuery(),t)))}queryFeatures(e,t){return this._getAssociatedLayerForQuery().then((r=>r.queryFeatures(e||this.createQuery(),t))).then((e=>{if(e?.features)for(const t of e.features)t.layer=this.layer,t.sourceLayer=this;return e}))}async queryObjectIds(e,t){const r=await this._getAssociatedLayerForQuery();return(await r.queryObjectIds(e||this.createQuery(),t)).filter(z.Et)}async queryCachedAttributes(e,t){const r=(0,B.hL)(this.fieldsIndex,await(0,V.TO)(this,(0,V.D8)(this)));return(0,G.s1)(this.parsedUrl.path,this.attributeStorageInfo,e,t,r,this.apiKey,this.customParameters)}async queryCachedFeature(e,t){const r=await this.queryCachedAttributes(e,[t]);if(!r||0===r.length)throw new o.A("scenelayer:feature-not-in-cached-data","Feature not found in cached data");return new b.A({attributes:r[0],layer:this,sourceLayer:this})}getFieldUsageInfo(e){return this.fieldsIndex.has(e)?{supportsLabelingInfo:!1,supportsRenderer:!1,supportsPopupTemplate:!1,supportsLayerQuery:!1}:{supportsLabelingInfo:!1,supportsRenderer:!0,supportsPopupTemplate:!0,supportsLayerQuery:null!=this.associatedLayer}}_getAssociatedLayerForQuery(){const e=this.associatedLayer;return null!=e&&e.loaded?Promise.resolve(e):this._loadAssociatedLayerForQuery()}async _loadAssociatedLayerForQuery(){if(await this.load(),null==this.associatedLayer)throw new o.A("buildingscenelayer:query-not-available","BuildingSceneLayer component layer queries are not available without an associated feature layer",{layer:this});try{await this.associatedLayer.load()}catch(e){throw new o.A("buildingscenelayer:query-not-available","BuildingSceneLayer associated feature layer could not be loaded",{layer:this,error:e})}return this.associatedLayer}};(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"parsedUrl",null),(0,s._)([(0,f.MZ)({type:C.W4,readOnly:!0})],H.prototype,"nodePages",void 0),(0,s._)([(0,f.MZ)({type:[C.uV],readOnly:!0})],H.prototype,"materialDefinitions",void 0),(0,s._)([(0,f.MZ)({type:[C.Ot],readOnly:!0})],H.prototype,"textureSetDefinitions",void 0),(0,s._)([(0,f.MZ)({type:[C.L0],readOnly:!0})],H.prototype,"geometryDefinitions",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"serviceUpdateTimeStamp",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"store",void 0),(0,s._)([(0,f.MZ)({type:String,readOnly:!0,json:{read:{source:"store.rootNode"}}})],H.prototype,"rootNode",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"attributeStorageInfo",void 0),(0,s._)([(0,f.MZ)(J.fields)],H.prototype,"fields",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"fieldsIndex",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:I.default})],H.prototype,"associatedLayer",void 0),(0,s._)([(0,m.w)("service","associatedLayer",["associatedLayerID"])],H.prototype,"readAssociatedLayer",null),(0,s._)([(0,f.MZ)(J.outFields)],H.prototype,"outFields",void 0),(0,s._)([(0,f.MZ)({type:String,readOnly:!0})],H.prototype,"objectIdField",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:String,json:{read:!1}})],H.prototype,"displayField",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:String})],H.prototype,"apiKey",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:String})],H.prototype,"customParameters",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:F.A})],H.prototype,"fullExtent",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:_.A})],H.prototype,"spatialReference",null),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"version",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:Q.A})],H.prototype,"elevationInfo",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:Number})],H.prototype,"minScale",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:Number})],H.prototype,"maxScale",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:Number})],H.prototype,"effectiveScaleRange",null),(0,s._)([(0,f.MZ)({type:["hide","show"],json:{write:!0}})],H.prototype,"listMode",void 0),(0,s._)([(0,f.MZ)({types:k.XJ,json:{origins:{service:{read:{source:"drawingInfo.renderer"}}},name:"layerDefinition.drawingInfo.renderer",write:!0},value:null})],H.prototype,"renderer",void 0),(0,s._)([(0,f.MZ)({type:String,json:{origins:{service:{read:!1,write:!1}},name:"layerDefinition.definitionExpression",write:{enabled:!0,allowNull:!0}}})],H.prototype,"definitionExpression",void 0),(0,s._)([(0,f.MZ)(E.M6)],H.prototype,"popupEnabled",void 0),(0,s._)([(0,f.MZ)({type:w.A,json:{read:{source:"popupInfo"},write:{target:"popupInfo"}}})],H.prototype,"popupTemplate",void 0),(0,s._)([(0,f.MZ)({readOnly:!0,type:String,json:{origins:{service:{read:{source:"store.normalReferenceFrame"}}},read:!1}})],H.prototype,"normalReferenceFrame",void 0),(0,s._)([(0,f.MZ)({readOnly:!0,json:{read:!1}})],H.prototype,"defaultPopupTemplate",null),(0,s._)([(0,f.MZ)()],H.prototype,"types",null),(0,s._)([(0,f.MZ)()],H.prototype,"typeIdField",null),(0,s._)([(0,f.MZ)({json:{write:!1}}),(0,A.e)(new S.J({"3DObject":"3d-object",Point:"point"}))],H.prototype,"layerType",void 0),(0,s._)([(0,f.MZ)()],H.prototype,"geometryType",null),(0,s._)([(0,f.MZ)()],H.prototype,"profile",null),(0,s._)([(0,f.MZ)({readOnly:!0,json:{read:!1}})],H.prototype,"capabilities",null),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"statisticsInfo",void 0),H=(0,s._)([(0,g.$)("esri.layers.buildingSublayers.BuildingComponentSublayer")],H);const K=H;var W,Y=r(67076);const X={type:i.A,readOnly:!0,json:{origins:{service:{read:{source:"sublayers",reader:ee}}},read:!1}};function ee(e,t,r){if(e&&Array.isArray(e))return new i.A(e.map((e=>{const t=function(e){return"group"===e.layerType?te:K}(e);if(t){const s=new t;return s.read(e,r),s}return r?.messages&&e&&r.messages.push(new Y.A("building-scene-layer:unsupported-sublayer-type","Building scene sublayer of type '"+(e.type||"unknown")+"' are not supported",{definition:e,context:r})),null})))}let te=W=class extends R{constructor(e){super(e),this.type="building-group",this.listMode="show",this.sublayers=null}loadAll(){return(0,u.L)(this,(e=>W.forEachSublayer(this.sublayers,(t=>{"building-group"!==t.type&&e(t)}))))}};var re;(0,s._)([(0,f.MZ)({type:["hide","show","hide-children"],json:{write:!0}})],te.prototype,"listMode",void 0),(0,s._)([(0,f.MZ)(X)],te.prototype,"sublayers",void 0),te=W=(0,s._)([(0,g.$)("esri.layers.buildingSublayers.BuildingGroupSublayer")],te),(re=te||(te={})).sublayersProperty=X,re.readSublayers=ee,re.forEachSublayer=function e(t,r){t.forEach((t=>{r(t),"building-group"===t.type&&e(t.sublayers,r)}))};const se=te;var ie=r(52136),ne=r(18768),oe=r(69208),ae=r(16131),le=r(8303),ue=r(25036),pe=r(58947),de=r(92009),ce=r(25482),ye=r(13069);let he=class extends ce.A{constructor(){super(...arguments),this.type=null}};(0,s._)([(0,f.MZ)({type:String,readOnly:!0,json:{write:{isRequired:!0}}})],he.prototype,"type",void 0),he=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterAuthoringInfo")],he);const fe=he;var me;let ge=me=class extends ce.A{constructor(){super(...arguments),this.filterType=null,this.filterValues=null}clone(){return new me({filterType:this.filterType,filterValues:(0,l.o8)(this.filterValues)})}};(0,s._)([(0,f.MZ)({type:String,json:{write:{isRequired:!0}}})],ge.prototype,"filterType",void 0),(0,s._)([(0,f.MZ)({type:[String],json:{write:{isRequired:!0}}})],ge.prototype,"filterValues",void 0),ge=me=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterAuthoringInfoType")],ge);const _e=ge;var ve;const be=i.A.ofType(_e);let we=ve=class extends ce.A{clone(){return new ve({filterTypes:(0,l.o8)(this.filterTypes)})}};(0,s._)([(0,f.MZ)({type:be,json:{write:{isRequired:!0}}})],we.prototype,"filterTypes",void 0),we=ve=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterAuthoringInfoBlock")],we);const xe=we;var Se;const Me=i.A.ofType(xe);let Te=Se=class extends fe{constructor(){super(...arguments),this.type="checkbox"}clone(){return new Se({filterBlocks:(0,l.o8)(this.filterBlocks)})}};(0,s._)([(0,f.MZ)({type:["checkbox"]})],Te.prototype,"type",void 0),(0,s._)([(0,f.MZ)({type:Me,json:{write:{isRequired:!0}}})],Te.prototype,"filterBlocks",void 0),Te=Se=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterAuthoringInfoCheckbox")],Te);const Ae=Te;let Fe=class extends ce.A{};(0,s._)([(0,f.MZ)({readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],Fe.prototype,"type",void 0),Fe=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterMode")],Fe);const Ie=Fe;var Ze;let Oe=Ze=class extends Ie{constructor(){super(...arguments),this.type="solid"}clone(){return new Ze}};(0,s._)([(0,f.MZ)({type:["solid"],readOnly:!0,json:{write:{isRequired:!0}}})],Oe.prototype,"type",void 0),Oe=Ze=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterModeSolid")],Oe);const Ee=Oe;var je,Re=r(51734);let Pe=je=class extends Ie{constructor(){super(...arguments),this.type="wire-frame",this.edges=null}clone(){return new je({edges:(0,l.o8)(this.edges)})}};(0,s._)([(0,A.e)({wireFrame:"wire-frame"})],Pe.prototype,"type",void 0),(0,s._)([(0,f.MZ)(Re.J)],Pe.prototype,"edges",void 0),Pe=je=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterModeWireFrame")],Pe);const Le=Pe;var $e;let Ne=$e=class extends Ie{constructor(){super(...arguments),this.type="x-ray"}clone(){return new $e}};(0,s._)([(0,f.MZ)({type:["x-ray"],readOnly:!0,json:{write:{isRequired:!0}}})],Ne.prototype,"type",void 0),Ne=$e=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterModeXRay")],Ne);const Be=Ne;var qe;const Ce={nonNullable:!0,types:{key:"type",base:Ie,typeMap:{solid:Ee,"wire-frame":Le,"x-ray":Be}},json:{read:e=>{switch(e?.type){case"solid":return Ee.fromJSON(e);case"wireFrame":return Le.fromJSON(e);case"x-ray":return Be.fromJSON(e);default:return}},write:{enabled:!0,isRequired:!0}}};let ke=qe=class extends ce.A{constructor(){super(...arguments),this.filterExpression=null,this.filterMode=new Ee,this.title=""}clone(){return new qe({filterExpression:this.filterExpression,filterMode:(0,l.o8)(this.filterMode),title:this.title})}};(0,s._)([(0,f.MZ)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],ke.prototype,"filterExpression",void 0),(0,s._)([(0,f.MZ)(Ce)],ke.prototype,"filterMode",void 0),(0,s._)([(0,f.MZ)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],ke.prototype,"title",void 0),ke=qe=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterBlock")],ke);const De=ke;var ze;const Ue=i.A.ofType(De);let Qe=ze=class extends ce.A{constructor(){super(...arguments),this.description=null,this.filterBlocks=null,this.id=(0,ye.lk)(),this.name=null}clone(){return new ze({description:this.description,filterBlocks:(0,l.o8)(this.filterBlocks),id:this.id,name:this.name,filterAuthoringInfo:(0,l.o8)(this.filterAuthoringInfo)})}};(0,s._)([(0,f.MZ)({type:String,json:{write:!0}})],Qe.prototype,"description",void 0),(0,s._)([(0,f.MZ)({type:Ue,json:{write:{enabled:!0,isRequired:!0}}})],Qe.prototype,"filterBlocks",void 0),(0,s._)([(0,f.MZ)({types:{key:"type",base:fe,typeMap:{checkbox:Ae}},json:{read:e=>"checkbox"===e?.type?Ae.fromJSON(e):null,write:!0}})],Qe.prototype,"filterAuthoringInfo",void 0),(0,s._)([(0,f.MZ)({type:String,constructOnly:!0,json:{write:{enabled:!0,isRequired:!0}}})],Qe.prototype,"id",void 0),(0,s._)([(0,f.MZ)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],Qe.prototype,"name",void 0),Qe=ze=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilter")],Qe);const Ge=Qe;let Ve=class extends ce.A{constructor(){super(...arguments),this.fieldName=null,this.modelName=null,this.label=null,this.min=null,this.max=null,this.mostFrequentValues=null,this.subLayerIds=null}};(0,s._)([(0,f.MZ)({type:String})],Ve.prototype,"fieldName",void 0),(0,s._)([(0,f.MZ)({type:String})],Ve.prototype,"modelName",void 0),(0,s._)([(0,f.MZ)({type:String})],Ve.prototype,"label",void 0),(0,s._)([(0,f.MZ)({type:Number})],Ve.prototype,"min",void 0),(0,s._)([(0,f.MZ)({type:Number})],Ve.prototype,"max",void 0),(0,s._)([(0,f.MZ)({json:{read:e=>Array.isArray(e)&&(e.every((e=>"string"==typeof e))||e.every((e=>"number"==typeof e)))?e.slice():null}})],Ve.prototype,"mostFrequentValues",void 0),(0,s._)([(0,f.MZ)({type:[Number]})],Ve.prototype,"subLayerIds",void 0),Ve=(0,s._)([(0,g.$)("esri.layers.support.BuildingSummaryStatistics.BuildingFieldStatistics")],Ve);let Je=class extends(M.A.LoadableMixin(T.A.EsriPromiseMixin(ce.A))){constructor(){super(...arguments),this.url=null}get fields(){return this.loaded||"loading"===this.loadStatus?this._get("fields"):(p.A.getLogger(this).error("building summary statistics are not loaded"),null)}load(e){const t=null!=e?e.signal:null;return this.addResolvingPromise(this._fetchService(t)),Promise.resolve(this)}async _fetchService(e){const t=(await(0,x.A)(this.url,{query:{f:"json"},responseType:"json",signal:e})).data;this.read(t,{origin:"service"})}};(0,s._)([(0,f.MZ)({constructOnly:!0,type:String})],Je.prototype,"url",void 0),(0,s._)([(0,f.MZ)({readOnly:!0,type:[Ve],json:{read:{source:"summary"}}})],Je.prototype,"fields",null),Je=(0,s._)([(0,g.$)("esri.layers.support.BuildingSummaryStatistics")],Je);const He=Je;var Ke=r(24212);const We=i.A.ofType(Ge),Ye=(0,l.o8)(se.sublayersProperty),Xe=Ye.json?.origins;Xe&&(Xe["web-scene"]={type:[K],write:{enabled:!0,overridePolicy:()=>({enabled:!1})}},Xe["portal-item"]={type:[K],write:{enabled:!0,overridePolicy:()=>({enabled:!1})}});let et=class extends((0,pe.w6)((0,ne.b)((0,ae.q)((0,le.A)((0,ue.j)((0,d.P)((0,oe.d)((0,ie.p)(v.A))))))))){constructor(e){super(e),this.operationalLayerType="BuildingSceneLayer",this.allSublayers=new n.A({getCollections:()=>[this.sublayers],getChildrenFunction:e=>"building-group"===e.type?e.sublayers:null}),this.sublayers=null,this._allSublayerOverrides=null,this.filters=new We,this.activeFilterId=null,this.summaryStatistics=null,this.outFields=null,this.legendEnabled=!0,this.type="building-scene"}normalizeCtorArgs(e){return"string"==typeof e?{url:e}:e??{}}destroy(){this.allSublayers.destroy()}readSublayers(e,t,r){const s=se.readSublayers(e,t,r);return se.forEachSublayer(s,(e=>e.layer=this)),this._allSublayerOverrides&&(function(e,t){t.forEach((t=>tt(e,t)))}(s,this._allSublayerOverrides),this._allSublayerOverrides=null),s}write(e,t){return e=super.write(e,t),!t||"web-scene"!==t.origin&&"portal-item"!==t.origin||(this.sublayers?function(e,t,r){const s=[];se.forEachSublayer(e,(e=>{const t=e.write({},r);Object.keys(t).length>1&&s.push(t)})),s.length>0&&(t.sublayers=s)}(this.sublayers,e,t):this._allSublayerOverrides&&function(e,t,r){const s=r?.origin&&e.get(r.origin);s&&(t.sublayers=[],s.overrides.forEach((e=>{t.sublayers.push((0,l.o8)(e))})))}(this._allSublayerOverrides,e,t)),e}read(e,t){if(super.read(e,t),("web-scene"===t?.origin||"portal-item"===t?.origin)&&Array.isArray(e?.sublayers)){const r=function(e,t){const r=new Map;for(const s of e)null!=s&&"object"==typeof s&&"number"==typeof s.id?r.set(s.id,s):t.messages?.push(new o.A("building-scene-layer:invalid-sublayer-override","Invalid value for sublayer override. Not an object or no id specified.",{value:s}));return{overrides:r,context:t}}(e.sublayers,t);this.sublayers?tt(this.sublayers,r):(this._allSublayerOverrides??=new Map,this._allSublayerOverrides.set(t.origin,r))}}readSummaryStatistics(e,t){if("string"==typeof t.statisticsHRef){const e=(0,h.fj)(this.parsedUrl?.path,t.statisticsHRef);return new He({url:e})}return null}set elevationInfo(e){null!=e&&"absolute-height"!==e.mode||this._set("elevationInfo",e),this._validateElevationInfo(e)}load(e){const t=null!=e?e.signal:null,r=this.loadFromPortal({supportedTypes:["Scene Service"]},e).catch(c.QP).then((()=>this._fetchService(t))).then((()=>this._fetchAssociatedFeatureService(t)));return this.addResolvingPromise(r),Promise.resolve(this)}loadAll(){return(0,u.g)(this,(e=>{se.forEachSublayer(this.sublayers,(t=>{"building-group"!==t.type&&e(t)})),this.summaryStatistics&&e(this.summaryStatistics)}))}async saveAs(e,t){return this._debouncedSaveOperations(pe.Xh.SAVE_AS,{...t,getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"building-scene"},e)}async save(){const e={getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"building-scene"};return this._debouncedSaveOperations(pe.Xh.SAVE,e)}validateLayer(e){if(!e.layerType||"Building"!==e.layerType)throw new o.A("buildingscenelayer:layer-type-not-supported","BuildingSceneLayer does not support this layer type",{layerType:e.layerType})}_getTypeKeywords(){return["Building"]}async _fetchAssociatedFeatureService(e){try{const{portalItem:t}=await(0,de.L)(`${this.url}/layers/${this.layerId}`,{sceneLayerItem:this.portalItem,customParameters:this.customParameters,apiKey:this.apiKey,signal:e});this.associatedFeatureServiceItem=t}catch(e){(0,c.QZ)(this._logWarningOnPopupEnabled())}}async _logWarningOnPopupEnabled(){const e=new AbortController;this.addHandles((0,a.rE)(e)),await(0,y.C_)((()=>this.allSublayers.filter((e=>"building-component"===e.type)).some((e=>e.popupEnabled&&null!=e.popupTemplate))),e.signal);const t=this.allSublayers.filter((e=>"building-component"===e.type)).filter((e=>e.popupEnabled&&null!=e.popupTemplate)),r=[],s=[];for(const e of t){const t=e.title??`untitled ${e.id}`;e.attributeStorageInfo?r.push(t):s.push(t)}const i="\n ",n=r.length>0?`\nThe following sublayers will fall back to binary attributes for Popups:${i}${r.join(i)}`:"",o=s.length>0?`\nThe following sublayers have no binary attributes and will not work with Popups:${i}${s.join(i)}`:"";p.A.getLogger(this).warn(`Associated FeatureLayer could not be loaded for this BuildingSceneLayer: ${this.title}.`,n,o)}_validateElevationInfo(e){const t="Building scene layers";(0,Ke.XF)(p.A.getLogger(this),(0,Ke.B)(t,"absolute-height",e)),(0,Ke.XF)(p.A.getLogger(this),(0,Ke.tW)(t,e))}};function tt(e,t){const{overrides:r,context:s}=t;se.forEachSublayer(e,(e=>e.read(r.get(e.id),s)))}(0,s._)([(0,f.MZ)({type:["BuildingSceneLayer"]})],et.prototype,"operationalLayerType",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],et.prototype,"allSublayers",void 0),(0,s._)([(0,f.MZ)(Ye)],et.prototype,"sublayers",void 0),(0,s._)([(0,m.w)("service","sublayers")],et.prototype,"readSublayers",null),(0,s._)([(0,f.MZ)({type:We,nonNullable:!0,json:{write:!0}})],et.prototype,"filters",void 0),(0,s._)([(0,f.MZ)({type:String,json:{write:!0}})],et.prototype,"activeFilterId",void 0),(0,s._)([(0,f.MZ)({readOnly:!0,type:He})],et.prototype,"summaryStatistics",void 0),(0,s._)([(0,m.w)("summaryStatistics",["statisticsHRef"])],et.prototype,"readSummaryStatistics",null),(0,s._)([(0,f.MZ)({type:[String],json:{read:!1}})],et.prototype,"outFields",void 0),(0,s._)([(0,f.MZ)(E.Fm)],et.prototype,"fullExtent",void 0),(0,s._)([(0,f.MZ)(E.fV)],et.prototype,"legendEnabled",void 0),(0,s._)([(0,f.MZ)({type:["show","hide","hide-children"]})],et.prototype,"listMode",void 0),(0,s._)([(0,f.MZ)((0,E.Qo)(_.A))],et.prototype,"spatialReference",void 0),(0,s._)([(0,f.MZ)(E.Yj)],et.prototype,"elevationInfo",null),(0,s._)([(0,f.MZ)({json:{read:!1},readOnly:!0})],et.prototype,"type",void 0),(0,s._)([(0,f.MZ)()],et.prototype,"associatedFeatureServiceItem",void 0),et=(0,s._)([(0,g.$)("esri.layers.BuildingSceneLayer")],et);const rt=et},91880:(e,t,r)=>{r.d(t,{A:()=>d});var s,i=r(90237),n=r(66552),o=r(25482),a=r(10107),l=(r(44208),r(53966),r(87811),r(40608));const u=new n.J({asc:"ascending",desc:"descending"});let p=class extends o.A{static{s=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new s({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,i._)([(0,a.MZ)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,i._)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],p.prototype,"valueExpression",void 0),(0,i._)([(0,a.MZ)({type:u.apiValues,json:{type:u.jsonValues,read:u.read,write:u.write}})],p.prototype,"order",void 0),p=s=(0,i._)([(0,l.$)("esri.layers.support.OrderByInfo")],p);const d=p},92935:(e,t,r)=>{var s;r.d(t,{X:()=>s}),function(e){e[e.SAVE=0]="SAVE",e[e.SAVE_AS=1]="SAVE_AS"}(s||(s={}))}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1961,3186,4342],{4071:(e,t,r)=>{r.d(t,{$:()=>s,P:()=>i});const s={supportsDate:!1,supportsFixedInterval:!1,supportsAutoInterval:!1,supportsFixedBoundaries:!1,supportsStackBy:!1,supportsSplitBy:!1,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!1,supportedStatistics:void 0,supportedNormalizationTypes:void 0},i={analytics:{supportsCacheHint:!1},attachment:{supportsContentType:!1,supportsExifInfo:!1,supportsKeywords:!1,supportsName:!1,supportsSize:!1,supportsCacheHint:!1,supportsOrderByFields:!1,supportsResize:!1},data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:!1},editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsAsyncApplyEdits:!1,zDefault:void 0},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryBins:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s,query:{maxRecordCount:0,maxRecordCountFactor:0,standardMaxRecordCount:0,supportsCacheHint:!1,supportsCentroid:!1,supportsCompactGeometry:!1,supportsCurrentUser:!1,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsReturnMesh:!1,supportsSqlExpression:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsTrueCurve:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsStatistics:!1,tileMaxRecordCount:0}}},17311:(e,t,r)=>{r.d(t,{A:()=>c});var s=r(90237),i=r(69622),n=r(60999),o=r(5503),a=r(10107),l=(r(44208),r(53966),r(87811),r(40608)),u=r(30524),p=r(43668);let d=class extends i.A{constructor(e){super(e),this._featureUtils=null,this.effectivePopupTemplate=null}get _arcadeTask(){return this.expressionsUsedInTitle.length>0?this._get("_arcadeTask")||(0,n.UT)((()=>(0,p.l)())):null}get featureUtilsPromise(){return this._get("featureUtilsPromise")??r.e(9926).then(r.bind(r,29926)).then((e=>this._featureUtils=e))}get calculatedExpressions(){const e=new o.A;if(!this.expressionsUsedInTitle.length)return e;if(!this._arcadeTask?.value){for(const t of this.expressionsUsedInTitle??[])e.push({name:t.name,invalid:!0});return e}for(const t of this.expressionsUsedInTitle)try{const r=this._arcadeTask.value.arcade.parseScript(t.expression,["$layer","$map","$datastore"]);if(r.isAsync){e.push({name:t.name,invalid:!0});break}e.push({name:t.name,syntax:r,invalid:!1,func:this._arcadeTask.value.arcade.compileScript(r,{vars:{$feature:"any"}})})}catch{e.push({name:t.name,invalid:!0});break}return e}get expressionsUsedInTitle(){let e=this.effectivePopupTemplate?.title??"";return"string"!=typeof e?[]:(e=e.toLowerCase(),this.effectivePopupTemplate?.expressionInfos?.filter((t=>e.includes(`{expression/${t.name.toLowerCase()}}`)))??[])}get fieldInfoMap(){return this._featureUtils?this._createFieldInfoMap(this._featureUtils.getAllFieldInfos(this.effectivePopupTemplate)):null}get hasBadExpressions(){return this.calculatedExpressions.some((e=>!0===e.invalid))}get requiredFields(){const e=new Set;if(this._arcadeTask?.value&&!this.hasBadExpressions)for(const t of this.calculatedExpressions?.toArray()??[])try{const r=this._arcadeTask.value.arcade.extractFieldLiterals(t.syntax);for(const t of r){const r=t.split("."),s=this.fieldsIndex.get(r.at(-1)??"");s&&e.add(s.name)}}catch{}const t=this._extractFieldNames(this.workingTitle);for(const r of t){const t=this.fieldsIndex.get(r);t&&e.add(t.name)}return e}get titleFromDisplayField(){let e="";return this.displayField&&(e=this.fieldsIndex.get(this.displayField)?.name??""),e||(e=this.fieldsIndex.get(this.objectIdField)?.name??""),e?`{${e}}`:""}get workingTitle(){const e=this.effectivePopupTemplate?this.effectivePopupTemplate.title:"";return""===e||null==e||this.hasBadExpressions||"string"!=typeof e?this.titleFromDisplayField:e}async getTitle(e,t,r){try{const{attributes:s}=t,i=r?.timeZone??"system",[{substituteFieldsInLinksAndAttributes:n}]=await Promise.all([this.featureUtilsPromise,this._arcadeTask?.promise]);if(r.fetchMissingFields&&(t=await this._checkAndReQueryGraphic(e,t)),this.workingTitle&&this.fieldInfoMap){const r=this._createFormattedAttributes(e,t,i).global;return n({attributes:s,expressionAttributes:null,fieldInfoMap:this.fieldInfoMap,globalAttributes:r,layer:e,text:this.workingTitle})}return""}catch{}return""}async _checkAndReQueryGraphic(e,t){const r=t.getObjectId();if(null==r)return t;if(!(0,u.Kl)(this.requiredFields,t)){const t=e.createQuery();t.where="1=1",t.outFields=[...this.requiredFields],t.objectIds=[r];const s=await e.queryFeatures(t);if(1===s?.features.length)return s.features[0]}return t}_createFieldInfoMap(e){const t=new Map;if(!e)return t;for(const r of e){if(!r.fieldName)continue;const e=this.fieldsIndex.get(r.fieldName),s=e?.name??r.fieldName;r.fieldName=s,t.set(s.toLowerCase(),r)}return t}_createFormattedAttributes(e,t,r="system"){const s=this.effectivePopupTemplate?.fieldInfos??[],i={};if(!this._featureUtils)return{};if(!this.hasBadExpressions&&this.calculatedExpressions.length>0&&this._arcadeTask?.value){const r=this._arcadeTask.value.Feature.createFromGraphicLikeObject(t.geometry,t.attributes,e,null);for(const e of this.calculatedExpressions)try{i[`expression/${e.name}`]=e.func({vars:{$feature:r}})}catch{}}const n={...t.attributes,...i};return{global:this._featureUtils.formatAttributes({fieldInfos:s,attributes:n,graphic:t,timeZone:r,layer:e,fieldInfoMap:this.fieldInfoMap}),content:[]}}_extractFieldNames(e){return(0,u.nw)(e).filter((e=>!(0===e.indexOf("relationships/")||0===e.indexOf("expression/"))))}};(0,s._)([(0,a.MZ)({readOnly:!0})],d.prototype,"_arcadeTask",null),(0,s._)([(0,a.MZ)()],d.prototype,"_featureUtils",void 0),(0,s._)([(0,a.MZ)({readOnly:!0})],d.prototype,"featureUtilsPromise",null),(0,s._)([(0,a.MZ)({readOnly:!0})],d.prototype,"calculatedExpressions",null),(0,s._)([(0,a.MZ)()],d.prototype,"displayField",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"effectivePopupTemplate",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"expressionsUsedInTitle",null),(0,s._)([(0,a.MZ)()],d.prototype,"fieldsIndex",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"fieldInfoMap",null),(0,s._)([(0,a.MZ)()],d.prototype,"fields",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"objectIdField",void 0),(0,s._)([(0,a.MZ)()],d.prototype,"requiredFields",null),d=(0,s._)([(0,l.$)("esri.layers.support.TitleCreator")],d);const c=d},22671:(e,t,r)=>{r.d(t,{A:()=>v});var s,i=r(90237),n=r(52106),o=r(66552),a=r(25482),l=r(4718),u=r(10107),p=(r(44208),r(53966),r(36005)),d=r(40608),c=r(43937),y=r(16930),h=r(65864),f=r(50498),m=r(20437);const g=new o.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let _=s=class extends a.A{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){return this.readFeaturesWithClass(e,t,n.A)}writeGeometryType(e,t,r,s){if(e)return void g.write(e,t,r,s);const{features:i}=this;if(i)for(const e of i)if(null!=e?.geometry)return void g.write(e.geometry.type,t,r,s)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,s=(0,h.rS)(e);return s&&!r&&t.spatialReference&&(s.spatialReference=y.A.fromJSON(t.spatialReference)),s}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:r}=this;if(r)for(const e of r)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new s(this.cloneProperties())}cloneProperties(){return(0,l.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){const s=t.features[r];if(s.geometry){const t=e?.[r];s.geometry=t?.toJSON()||s.geometry}}return t}quantize(e){const{scale:[t,r],translate:[s,i]}=e,n=this.features,o=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-s)/t)),(e=>Math.round((i-e)/r)));for(let e=0,t=n.length;e<t;e++)o?.(n[e].geometry)||(n.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[s,i],scale:[n,o]}=r;let a=null,l=null;if(this.hasZ&&null!=r?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=r;a=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=r;l=r=>null==r?r:r*t+e}const u=this._getHydrationFunction(e,(e=>e*n+s),(e=>i-e*o),a,l);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}readFeaturesWithClass(e,t,r){const s=y.A.fromJSON(t.spatialReference),i=[];for(let t=0;t<e.length;t++){const n=e[t],o=r.fromJSON(n),a=n.geometry?.spatialReference;null==o.geometry||a||(o.geometry.spatialReference=s);const l=n.aggregateGeometries,u=o.aggregateGeometries;if(l&&null!=u)for(const e in u){const t=u[e],r=l[e],i=r?.spatialReference;null==t||i||(t.spatialReference=s)}i.push(o)}return i}_quantizePoints(e,t,r){let s,i;const n=[];for(let o=0,a=e.length;o<a;o++){const a=e[o];if(o>0){const e=t(a[0]),o=r(a[1]);e===s&&o===i||(n.push([e-s,o-i]),s=e,i=o)}else s=t(a[0]),i=r(a[1]),n.push([s,i])}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=>{const s=(0,h.Bi)(e)?e.rings:e.paths,i=[];for(let e=0,n=s.length;e<n;e++){const n=s[e],o=this._quantizePoints(n,t,r);o&&i.push(o)}return i.length>0?((0,h.Bi)(e)?e.rings=i:e.paths=i,e):null}:"multipoint"===e?e=>{const s=this._quantizePoints(e.points,t,r);return s&&s.length>0?(e.points=s,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r,s,i){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y),s&&(e.z=s(e.z))}:"polyline"===e||"polygon"===e?e=>{const n=(0,h.Bi)(e)?e.rings:e.paths;let o,a;for(let e=0,s=n.length;e<s;e++){const s=n[e];for(let e=0,i=s.length;e<i;e++){const i=s[e];e>0?(o+=i[0],a+=i[1]):(o=i[0],a=i[1]),i[0]=t(o),i[1]=r(a)}}if(s&&i)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=s(r[2]),r[3]=i(r[3])}}else if(s)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=s(r[2])}}else if(i)for(let e=0,t=n.length;e<t;e++){const t=n[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(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),s&&null!=e.zmax&&null!=e.zmin&&(e.zmax=s(e.zmax),e.zmin=s(e.zmin)),i&&null!=e.mmax&&null!=e.mmin&&(e.mmax=i(e.mmax),e.mmin=i(e.mmin))}:"multipoint"===e?e=>{const n=e.points;let o,a;for(let e=0,s=n.length;e<s;e++){const s=n[e];e>0?(o+=s[0],a+=s[1]):(o=s[0],a=s[1]),s[0]=t(o),s[1]=r(a)}if(s&&i)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=s(t[2]),t[3]=i(t[3])}else if(s)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=s(t[2])}else if(i)for(let e=0,t=n.length;e<t;e++){const t=n[e];t[2]=i(t[2])}}:null}};(0,i._)([(0,u.MZ)({type:String,json:{write:!0}})],_.prototype,"displayFieldName",void 0),(0,i._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"exceededTransferLimit",void 0),(0,i._)([(0,u.MZ)({type:[n.A],json:{write:!0}})],_.prototype,"features",void 0),(0,i._)([(0,p.w)("features")],_.prototype,"readFeatures",null),(0,i._)([(0,u.MZ)({type:[m.A],json:{write:!0}})],_.prototype,"fields",void 0),(0,i._)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],_.prototype,"geometryType",void 0),(0,i._)([(0,c.K)("geometryType")],_.prototype,"writeGeometryType",null),(0,i._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasM",void 0),(0,i._)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"hasZ",void 0),(0,i._)([(0,u.MZ)({types:f.yR,json:{write:!0}})],_.prototype,"queryGeometry",void 0),(0,i._)([(0,p.w)("queryGeometry")],_.prototype,"readQueryGeometry",null),(0,i._)([(0,u.MZ)({type:y.A,json:{write:!0}})],_.prototype,"spatialReference",void 0),(0,i._)([(0,c.K)("spatialReference")],_.prototype,"writeSpatialReference",null),(0,i._)([(0,u.MZ)({json:{write:!0}})],_.prototype,"transform",void 0),_=s=(0,i._)([(0,d.$)("esri.rest.support.FeatureSet")],_),_.prototype.toJSON.isDefaultToJSON=!0;const v=_},32730:(e,t,r)=>{r.d(t,{BI:()=>m,D3:()=>h,XJ:()=>f,lc:()=>y,mX:()=>_,rU:()=>g,tH:()=>S});var s=r(799);const i="__begin__",n="__end__",o=new RegExp(i,"ig"),a=new RegExp(n,"ig"),l=new RegExp("^"+i,"i"),u=new RegExp(n+"$","i"),p='"',d=p+" + ",c=" + "+p;function y(e){return e.replaceAll(new RegExp("\\[","g"),"{").replaceAll(new RegExp("\\]","g"),"}")}function h(e){return e.replaceAll(new RegExp("\\{","g"),"[").replaceAll(new RegExp("\\}","g"),"]")}function f(e){const t={expression:"",type:"none"};return e.labelExpressionInfo?e.labelExpressionInfo.value?(t.expression=e.labelExpressionInfo.value,t.type="conventional"):e.labelExpressionInfo.expression&&(t.expression=e.labelExpressionInfo.expression,t.type="arcade"):null!=e.labelExpression&&(t.expression=y(e.labelExpression),t.type="conventional"),t}function m(e){const t=f(e);switch(t.type){case"conventional":return _(t.expression);case"arcade":return t.expression}return null}function g(e){const t=f(e);switch(t.type){case"conventional":return function(e){const t=e?.match(v);return t?.[1].trim()||null}(t.expression);case"arcade":return S(t.expression)}return null}function _(e){let t;return e?(t=(0,s.HC)(e,(e=>i+'$feature["'+e+'"]'+n)),t=l.test(t)?t.replace(l,""):p+t,t=u.test(t)?t.replace(u,""):t+p,t=t.replaceAll(o,d).replaceAll(a,c)):t='""',t}const v=/^\s*\{([^}]+)\}\s*$/i,b=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*$/i,w=/^\s*(?:(?:\$feature\.(\w+))|(?:\$feature\[(["'])(.+)(\2)\]));?\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(\1|\3)(\5)\s*\));?\s*$/i,x=/^\s*(?:DomainName\(\s*\$feature\s*,\s*(["'])(.+)(\1)\s*\));?\s*$/i;function S(e){if(!e)return null;let t=b.exec(e)||w.exec(e);return t?t[1]||t[3]:(t=x.exec(e),t?t[2]:null)}},32756:(e,t,r)=>{r.d(t,{Rr:()=>l,fY:()=>p,ne:()=>u});var s=r(90237),i=r(93637),n=r(10107),o=(r(44208),r(53966),r(87811),r(40608)),a=r(91880);function l(e,t,r){if(!e)return null;const s=e.find((e=>!!e.field));if(!s)return null;const i=new a.A;return i.read(s,r),[i]}const u={type:[a.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:l},write:{writer:function(e,t,r,s){const n=e.find((e=>!!e.field));n&&(0,i.sM)(r,[n.toJSON()],t)}}}},p=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,s._)([(0,n.MZ)(u)],t.prototype,"orderBy",void 0),t=(0,s._)([(0,o.$)("esri.layers.mixins.OrderedLayer")],t),t}},33143:(e,t,r)=>{r.d(t,{A:()=>y});var s=r(90237),i=r(69540),n=r(25482),o=r(10107),a=(r(44208),r(53966),r(87811),r(36005)),l=r(40608),u=r(43937),p=r(80451),d=r(29005);let c=class extends(i.A.ClonableMixin(n.A)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,p.rS)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,s._)([(0,o.MZ)({json:{write:!0}})],c.prototype,"id",void 0),(0,s._)([(0,o.MZ)({json:{write:!0}})],c.prototype,"name",void 0),(0,s._)([(0,o.MZ)({json:{write:!0}})],c.prototype,"domains",void 0),(0,s._)([(0,a.w)("domains")],c.prototype,"readDomains",null),(0,s._)([(0,u.K)("domains")],c.prototype,"writeDomains",null),(0,s._)([(0,o.MZ)({type:[d.A],json:{write:!0}})],c.prototype,"templates",void 0),c=(0,s._)([(0,l.$)("esri.layers.support.FeatureType")],c);const y=c},38961:(e,t,r)=>{r.d(t,{A:()=>p});var s=r(90237),i=r(5503),n=r(36708),o=r(10107),a=r(40608),l=r(80559);let u=class extends i.A{constructor(e){super(e),this.getCollections=null}initialize(){this.addHandles((0,l.fm)((()=>this._refresh()),n.OH))}destroy(){this.getCollections=null}_refresh(){const e=null!=this.getCollections?this.getCollections():null;if(null==e)return void this.removeAll();let t=0;for(const r of e)null!=r&&(t=this._processCollection(t,r));this.splice(t,this.length)}_createNewInstance(e){return new i.A(e)}_processCollection(e,t){if(!t)return e;const r=this.itemFilterFunction??(e=>!!e);for(const s of t)if(s){if(r(s)){const t=this.indexOf(s,e);t>=0?t!==e&&this.reorder(s,e):this.add(s,e),++e}if(this.getChildrenFunction){const t=this.getChildrenFunction(s);if(Array.isArray(t))for(const r of t)e=this._processCollection(e,r);else e=this._processCollection(e,t)}}return e}};(0,s._)([(0,o.MZ)()],u.prototype,"getCollections",void 0),(0,s._)([(0,o.MZ)()],u.prototype,"getChildrenFunction",void 0),(0,s._)([(0,o.MZ)()],u.prototype,"itemFilterFunction",void 0),u=(0,s._)([(0,a.$)("esri.core.CollectionFlattener")],u);const p=u},39516:(e,t,r)=>{let s;async function i(){return null==s&&(s=r.e(4123).then(r.bind(r,44123)).then((e=>new e.WhereClauseCache(500,500)))),s}async function n(e,t){const r=await i(),s=r.get(e,t);if(null==s)throw r.getError(e,t);return s}function o(e,t){return e||=null,t||=null,"1=1"===e?t??e:"1=1"===t?e??t:e&&t?`(${e}) AND (${t})`:e??t}function a(e,t){return e||=null,t||=null,"1=1"===e||"1=1"===t||e===t?"1=1"===e?e:t:e&&t?`(${e}) OR (${t})`:e??t}r.d(t,{GP:()=>n,IW:()=>a,mA:()=>o})},41366:(e,t,r)=>{r.d(t,{K:()=>c,Q:()=>u});var s=r(90237),i=r(66552),n=r(53966),o=r(10107),a=(r(44208),r(87811),r(93223)),l=r(40608);const u=(0,i.O)()({naturalLog:"natural-log",squareRoot:"square-root",percentOfTotal:"percent-of-total",log:"log",field:"field"}),p="percent-of-total",d="field",c=e=>{let t=class extends e{constructor(){super(...arguments),this.normalizationField=null,this.normalizationMaxValue=null,this.normalizationMinValue=null,this.normalizationTotal=null}get normalizationType(){let e=this._get("normalizationType");const t=!!this.normalizationField,r=null!=this.normalizationTotal;return t||r?(e=t&&d||r&&p||null,t&&r&&n.A.getLogger(this).warn("warning: both normalizationField and normalizationTotal are set!")):e!==d&&e!==p||(e=null),e}set normalizationType(e){this._set("normalizationType",e)}};return(0,s._)([(0,o.MZ)({type:String,json:{name:"parameters.normalizationField",write:!0}})],t.prototype,"normalizationField",void 0),(0,s._)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMaxValue",write:!0}})],t.prototype,"normalizationMaxValue",void 0),(0,s._)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationMinValue",write:!0}})],t.prototype,"normalizationMinValue",void 0),(0,s._)([(0,o.MZ)({type:Number,json:{name:"parameters.normalizationTotal",write:!0}})],t.prototype,"normalizationTotal",void 0),(0,s._)([(0,a.e)(u,{name:"parameters.normalizationType"})],t.prototype,"normalizationType",null),t=(0,s._)([(0,l.$)("esri.rest.support.NormalizationBinParametersMixin")],t),t}},41560:(e,t,r)=>{r.d(t,{Ch:()=>o,mW:()=>n});var s=r(34727),i=r(39516);function n(e,t){return{...t,filterMode:e.mode}}function o(e,t,r){const n=function(e){if("manual"===u(e))return null;const t=[Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY];for(const{minScale:r,maxScale:s}of e.filters)t[0]=Math.max(t[0],p(r)),t[1]=Math.min(t[1],d(s));return t}(e);if(n&&((0,s.gg)(t,n[0])||(0,s.ZH)(r,n[1])))return"";const o=Array.from(a(e,t,r)),l=function(e,t,r){if(0===e.length)return!0;const i=p(e.at(0)?.minScale),n=d(e.at(-1)?.maxScale);if((0,s.ZH)(i,t)||(0,s.gg)(n,r))return!0;for(let t=0;t<e.length-1;t++){const r=e[t],i=e[t+1];if((0,s.ZH)(p(i.minScale),d(r.maxScale)))return!0}return!1}(o,t,r)?"1=1":o.map((e=>e.where||"1=1")).reduce(((e,t)=>(0,i.IW)(e,t)),"");return l&&"1=1"!==l?l:""}function*a(e,t,r){if("manual"===u(e)){const t=e.filters.find((t=>t.id===e.activeFilterId));t&&(yield t)}else{"object"==typeof t&&(t=t.scale);for(const s of e.filters)l(s.minScale,s.maxScale,t,r)&&(yield s)}}function l(e,t,r,i){return e=p(e),r=p(r),t=d(t),!(!(0,s.Sp)(r,e)&&(i??r)>e||(0,s.Hx)(t,r)||void 0!==i&&(0,s.Sp)(i,e))}function u(e){return"mode"in e?e.mode:e.filterMode}function p(e){return e||Number.POSITIVE_INFINITY}function d(e){return e||0}},45671:(e,t,r)=>{r.d(t,{D8:()=>n,TO:()=>i});var s=r(30524);async function i(e,t=e.popupTemplate){if(null==t)return[];const r=await t.getRequiredFields(e.fieldsIndex),{lastEditInfoEnabled:i}=t,{objectIdField:n,typeIdField:o,globalIdField:a,relationships:l}=e;if(r.includes("*"))return["*"];const u=i?(0,s.eX)(e):[],p=(0,s.DB)(e.fieldsIndex,[...r,...u]);return o&&p.push(o),p&&n&&e.fieldsIndex?.has(n)&&!p.includes(n)&&p.push(n),p&&a&&e.fieldsIndex?.has(a)&&!p.includes(a)&&p.push(a),l&&l.forEach((t=>{const{keyField:r}=t;p&&r&&e.fieldsIndex?.has(r)&&!p.includes(r)&&p.push(r)})),p}function n(e,t){return e.popupTemplate?e.popupTemplate:null!=t&&t.defaultPopupTemplateEnabled&&null!=e.defaultPopupTemplate?e.defaultPopupTemplate:null}},46140:(e,t,r)=>{r.d(t,{R:()=>i});var s=r(49186);let i=class e{constructor(e,t,r=""){this.major=e,this.minor=t,this._context=r}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}validate(e){if(this.major!==e.major){const t=this._context&&this._context+":",r=this._context&&this._context+" ";throw new s.A(t+"unsupported-version",`Required major ${r}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new e(this.major,this.minor,this._context)}static parse(t,r=""){const[i,n]=t.split("."),o=/^\s*\d+\s*$/;if(!i?.match||!o.test(i))throw new s.A((r&&r+":")+"invalid-version","Expected major version to be a number, but got '${version}'",{version:t});if(!n?.match||!o.test(n))throw new s.A((r&&r+":")+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:t});const a=parseInt(i,10),l=parseInt(n,10);return new e(a,l,r)}}},55674:(e,t,r)=>{r.d(t,{Ad:()=>y,Gj:()=>m,QY:()=>c,lL:()=>g,xR:()=>h});var s=r(66131),i=r(49186),n=(r(44208),r(44729)),o=r(15032),a=r(65864),l=r(95466),u=r(43668),p=r(98623);const d=["geometry","scale","timeProperties"];function c(e,t){if(null!=t)for(const r of d)t.hasArcadeDependency(r)&&e.add(r);return e}function y(e,t){return f.create(e,t,null,["$feature","$view"])}function h(e,t,r){return f.create(e,t,r,["$feature","$view","$config"])}class f{static async create(e,t,r,s){const{arcade:n,Dictionary:o}=await(0,u.l)();let a;try{a=n.parseScript(e)}catch(t){throw new i.A("arcade-bad-expression","Failed to parse arcade script",{script:e,error:t})}const l=n.scriptUsesGeometryEngine(a);l&&await n.enableGeometrySupport(),await n.loadDependentModules(new Set,a,null,!1,l);const p={vars:s.reduce(((e,t)=>({...e,[t]:null})),{}),spatialReference:t,useAsync:!1},d=n.compileScript(a,p);let c=null;null!=r&&(c=new o(r),c.immutable=!0);const y=new o;return y.immutable=!1,y.setField("scale",0),new f(e,n,a,d,t,y,c,o)}constructor(e,t,r,s,i,n,o,a){this.script=e,this._arcade=t,this._syntaxTree=r,this._compiled=s,this._spatialReference=i,this._viewDict=n,this._configDict=o,this._dictionaryCtor=a,this._dependencies=new Map,this._featureReader=new m,this._dependencies.set("geometry",t.scriptTouchesGeometry(this._syntaxTree)),this._dependencies.set("scale",this._arcade.referencesMember(this._syntaxTree,"scale")),this._dependencies.set("timeProperties",this._arcade.scriptUsesViewProperties(this._syntaxTree,["timeProperties"]))}evaluate(e,t){const r=t.$view?.timeZone;if(t.$view){let e;if(this._viewDict.setField("scale",t.$view.scale),null!=t.$view.timeProperties){const{currentStart:i,currentEnd:n}=t.$view.timeProperties;e=new this._dictionaryCtor({currentStart:null!=i?null!=r?s.lY.epochToArcadeDate(i,r):s.lY.unknownEpochToArcadeDate(i):void 0,currentEnd:null!=n?null!=r?s.lY.epochToArcadeDate(n,r):s.lY.unknownEpochToArcadeDate(n):void 0,startIncluded:!0,endIncluded:!0})}this._viewDict.setField("timeProperties",e)}return this._compiled({vars:{$view:this._viewDict,$config:this._configDict,$feature:e},spatialReference:this._spatialReference,timeZone:r})}repurposeFeature(e,t){return this._featureReader.bind(e,t,this._spatialReference),this._featureReader}references(e){return this._dependencies.get(e)??!1}}class m{constructor(){this._boundTarget=null,this._boundSchema={fields:null,fieldsIndex:null,spatialReference:null,get geometryType(){return null},get objectIdField(){return null}},this.arcadeDeclaredClass="esri.arcade.Feature",this._contextTimeZone=null}bind(e,t,r){const s=t??new l.A(g(e.attributes));this._boundTarget=e,this._boundSchema.fields=s.fields,this._boundSchema.fieldsIndex=s,this._boundSchema.spatialReference=r}_getField(e){return this._boundSchema.fieldsIndex.get(e)}get contextTimeZone(){return this._contextTimeZone}set contextTimeZone(e){this._contextTimeZone=e}readArcadeFeature(){return this}hasField(e){return this._boundSchema.fieldsIndex.has(e)}geometry(){if("fromJSON"in this._boundTarget)return this._boundTarget.geometry;const e=(0,a.rS)(this._boundTarget.geometry);if(e){if(!this._boundSchema.spatialReference)throw new Error("InternalError: Expected spatial reference to be defined");e.spatialReference=this._boundSchema.spatialReference}return e}isUnknownDateTimeField(e){return this._boundSchema.fieldsIndex.getTimeZone(e)===p.L5}field(e,t=!0){const r=this._getField(e);if(r)switch(r.type){case"date-only":case"esriFieldTypeDateOnly":return n.n.fromReader(this._boundTarget.attributes[r.name]);case"time-only":case"esriFieldTypeTimeOnly":return o.k.fromReader(this._boundTarget.attributes[r.name]);case"esriFieldTypeTimestampOffset":case"timestamp-offset":return s.lY.fromReaderAsTimeStampOffset(this._boundTarget.attributes[r.name]);case"date":case"esriFieldTypeDate":{const t=this._boundTarget.attributes[r.name];return this.isUnknownDateTimeField(e)?s.lY.unknownEpochToArcadeDate(t):s.lY.epochToArcadeDate(t,this.contextTimeZone??p.qU)}default:return this._boundTarget.attributes[r.name]}if(t)throw new Error(`Field ${e} does not exist`);return null}setField(e,t){throw new Error("Unable to update feature attribute values, feature is readonly")}keys(){return this._boundSchema.fieldsIndex.fields.map((e=>e.name))}castToText(e=!1){return JSON.stringify(this._boundTarget)}gdbVersion(){return null}fullSchema(){return this._boundSchema}castAsJson(e=null){return{attributes:this._boundTarget.attributes,geometry:!0===e?.keepGeometryType?this.geometry():this.geometry()?.toJSON()??null}}castAsJsonAsync(e=null,t=null){return Promise.resolve(this.castAsJson(t))}}function g(e){const t=[];for(const r in e)t.push({name:r,alias:r,type:"string"==typeof e[r]?"esriFieldTypeString":"esriFieldTypeDouble"});return t}},58501:(e,t,r)=>{r.d(t,{q:()=>i});var s=r(62815);function i(e,t,r){if(!r?.features||!r.hasZ)return;const i=(0,s.N)(r.geometryType,t,e.outSpatialReference);if(null!=i)for(const e of r.features)i(e.geometry)}},73681:(e,t,s)=>{s.d(t,{n:()=>u});var i=s(49186),n=s(53966),o=s(46140),a=s(95466),l=s(55674);class u{static async from(e,t,r){const s=e.dictionary_version?o.R.parse(e.dictionary_version):null,a=new Set(e.itemsNames),d={};if(t)for(const e in t)d[e]=t[e];if(e.authoringInfo.configuration)for(const t of e.authoringInfo.configuration)d.hasOwnProperty(t.name)||(d[t.name]=t.value);const c=new Set(e.authoringInfo.symbol);for(const e of Object.keys(r))c.delete(e);c.size&&n.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("missing-fields: fieldMap entries for the following symbol fields are missing",{symbolFields:c});const 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");const h=!s||!s.greaterEqual(4,0);h&&n.A.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("Dictionary script does not support native field types. Applying fallback",{version:s});const f=new p(r,h);return new u(h,a,y,f)}constructor(e,t,r,s){this._requiresFieldCoercionToString=e,this._itemNames=t,this._compiled=r,this._reader=s}get itemNames(){return this._itemNames}evaluate(e,t,s,i){try{return this._reader.bind(e,s,i),this._compiled.evaluate(this._reader,{$view:{scale:t}})}catch(e){r.getLogger("esri.renderers.support.DictionaryScriptEvaluator").warnOnce("arcade: dictionary script evaluation failed",{error:e})}return null}createDictionaryFieldsIndex(e){if(!this._requiresFieldCoercionToString)return new a.A(e);const t=e.map((e=>({...e,type:"esriFieldTypeString"})));return new a.A(t)}}class p extends l.Gj{constructor(e,t){super(),this._fieldMap=e,this._requiresFieldCoercionToString=t}_getField(e){const t=this._fieldMap[e]??e;return this._boundSchema.fieldsIndex.get(t)}field(e){if(!this._requiresFieldCoercionToString)return super.field(e,!1);const t=this._getField(e);return null==t?"":""+this._boundTarget.attributes[t.name]}}},81583:(e,t,r)=>{r.d(t,{L:()=>a,g:()=>o});var s=r(60999),i=r(5503),n=r(92474);async function o(e,t){return await e.load(),a(e,t)}async function a(e,t){const r=[],o=(...e)=>{for(const t of e)null!=t&&(Array.isArray(t)?o(...t):i.A.isCollection(t)?t.forEach((e=>o(e))):n.A.isLoadable(t)&&r.push(t))};t(o);let a=null;if(await(0,s.Tj)(r,(async e=>{const t=await(0,s.Ke)(function(e){return"loadAll"in e&&"function"==typeof e.loadAll}(e)?e.loadAll():e.load());!1!==t.ok||a||(a=t)})),a)throw a.error;return e}},88303:(e,t,r)=>{r.r(t),r.d(t,{default:()=>tt});var s=r(90237),i=r(5503),n=r(38961),o=r(49186),a=r(36563),l=r(4718),u=r(81583),p=r(53966),d=r(92071),c=r(74887),y=r(36708),h=r(84952),f=r(10107),m=(r(44208),r(36005)),g=r(40608),_=r(16930),v=r(4146),b=r(52106),w=r(13874),x=r(78888),S=r(66552),M=r(92474),T=r(61893),A=(r(87811),r(93223)),F=r(5443),I=r(13600),Z=r(4902),O=r(56507),E=r(10873);let j=class extends(Z.A.IdentifiableMixin(d.L)){constructor(e){super(e),this.title="",this.id=-1,this.modelName=null,this.isEmpty=null,this.legendEnabled=!0,this.visible=!0,this.opacity=1}readTitle(e,t){return"string"==typeof t.alias?t.alias:"string"==typeof t.name?t.name:""}readIdOnlyOnce(e){return-1!==this.id?this.id:"number"==typeof e?e:-1}};(0,s._)([(0,f.MZ)({type:String,json:{origins:{"web-scene":{write:!0},"portal-item":{write:!0}}}})],j.prototype,"title",void 0),(0,s._)([(0,m.w)("service","title",["alias","name"])],j.prototype,"readTitle",null),(0,s._)([(0,f.MZ)()],j.prototype,"layer",void 0),(0,s._)([(0,f.MZ)({type:O.jz,readOnly:!0,json:{read:!1,write:{ignoreOrigin:!0,isRequired:!0}}})],j.prototype,"id",void 0),(0,s._)([(0,m.w)("service","id")],j.prototype,"readIdOnlyOnce",null),(0,s._)([(0,f.MZ)((0,E.Qo)(String))],j.prototype,"modelName",void 0),(0,s._)([(0,f.MZ)((0,E.Qo)(Boolean))],j.prototype,"isEmpty",void 0),(0,s._)([(0,f.MZ)({type:Boolean,nonNullable:!0})],j.prototype,"legendEnabled",void 0),(0,s._)([(0,f.MZ)({type:Boolean,json:{name:"visibility",write:!0}})],j.prototype,"visible",void 0),(0,s._)([(0,f.MZ)({type:Number,json:{write:!0}})],j.prototype,"opacity",void 0),j=(0,s._)([(0,g.$)("esri.layers.buildingSublayers.BuildingSublayer")],j);const R=j;var P=r(4071),L=r(15426),$=r(17036),N=r(95466),B=r(30524),q=r(83898),C=r(50805),k=r(41214),D=r(61956),z=r(54218),U=r(30291),Q=r(88625),G=r(4654),V=r(45671);const J=(0,$.p)();let H=class extends(M.A.LoadableMixin(T.A.EsriPromiseMixin(R))){constructor(e){super(e),this.type="building-component",this.nodePages=null,this.materialDefinitions=[],this.textureSetDefinitions=[],this.geometryDefinitions=[],this.indexInfo=null,this.serviceUpdateTimeStamp=null,this.store=null,this.attributeStorageInfo=[],this.fields=[],this.associatedLayer=null,this.outFields=null,this.listMode="show",this.renderer=null,this.definitionExpression=null,this.popupEnabled=!0,this.popupTemplate=null,this.layerType="3d-object"}get parsedUrl(){return this.layer?{path:`${this.layer.parsedUrl?.path}/sublayers/${this.id}`,query:this.layer.parsedUrl?.query}:{path:""}}get fieldsIndex(){return new N.A(this.fields)}readAssociatedLayer(e,t){const r=this.layer.associatedFeatureServiceItem,s=t.associatedLayerID;return null!=r&&"number"==typeof s?new I.default({portalItem:r,customParameters:this.customParameters,layerId:s}):null}get objectIdField(){if(null!=this.fields)for(const e of this.fields)if("oid"===e.type)return e.name;return null}get displayField(){return null!=this.associatedLayer?this.associatedLayer.displayField:void 0}get apiKey(){return this.layer.apiKey}get customParameters(){return this.layer.customParameters}get fullExtent(){return this.layer.fullExtent}get spatialReference(){return this.layer.spatialReference}get version(){return this.layer.version}get elevationInfo(){return this.layer.elevationInfo}get minScale(){return this.layer.minScale}get maxScale(){return this.layer.maxScale}get effectiveScaleRange(){return this.layer.effectiveScaleRange}get defaultPopupTemplate(){return this.createPopupTemplate()}load(e){const t=null!=e?e.signal:null,r=this._fetchService(t).then((()=>{this.indexInfo=(0,q.F)(this.parsedUrl.path,this.rootNode,this.nodePages,this.customParameters,this.apiKey,p.A.getLogger(this),t)}));return this.addResolvingPromise(r),Promise.resolve(this)}createPopupTemplate(e){return(0,U.tn)(this,e)}async _fetchService(e){const t=(await(0,x.A)(this.parsedUrl.path,{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:e})).data;this.read(t,{origin:"service",url:this.parsedUrl})}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){const r=this.getField(e)?.domain??null;return this.associatedLayer?(0,L.Vq)(this.associatedLayer,e,t,r):r}getFeatureType(e){return e&&null!=this.associatedLayer?this.associatedLayer.getFeatureType(e):null}get types(){return null!=this.associatedLayer?this.associatedLayer.types??[]:[]}get typeIdField(){return null!=this.associatedLayer?this.associatedLayer.typeIdField:null}get geometryType(){return"3d-object"===this.layerType?"mesh":"point"}get profile(){return"3d-object"===this.layerType?"mesh-pyramids":"points"}get capabilities(){const e=null!=this.associatedLayer&&this.associatedLayer.capabilities?this.associatedLayer.capabilities:P.P,{query:t,operations:{supportsQuery:r},data:{supportsZ:s,supportsM:i,isVersioned:n}}=e;return{query:t,operations:{supportsQuery:r},data:{supportsZ:s,supportsM:i,isVersioned:n}}}createQuery(){const e=new D.A;return"mesh"!==this.geometryType&&(e.returnGeometry=!0,e.returnZ=!0),e.where=this.definitionExpression||"1=1",e.sqlFormat="standard",e}queryExtent(e,t){return this._getAssociatedLayerForQuery().then((r=>r.queryExtent(e||this.createQuery(),t)))}queryFeatureCount(e,t){return this._getAssociatedLayerForQuery().then((r=>r.queryFeatureCount(e||this.createQuery(),t)))}queryFeatures(e,t){return this._getAssociatedLayerForQuery().then((r=>r.queryFeatures(e||this.createQuery(),t))).then((e=>{if(e?.features)for(const t of e.features)t.layer=this.layer,t.sourceLayer=this;return e}))}async queryObjectIds(e,t){const r=await this._getAssociatedLayerForQuery();return(await r.queryObjectIds(e||this.createQuery(),t)).filter(z.Et)}async queryCachedAttributes(e,t){const r=(0,B.hL)(this.fieldsIndex,await(0,V.TO)(this,(0,V.D8)(this)));return(0,G.s1)(this.parsedUrl.path,this.attributeStorageInfo,e,t,r,this.apiKey,this.customParameters)}async queryCachedFeature(e,t){const r=await this.queryCachedAttributes(e,[t]);if(!r||0===r.length)throw new o.A("scenelayer:feature-not-in-cached-data","Feature not found in cached data");return new b.A({attributes:r[0],layer:this,sourceLayer:this})}getFieldUsageInfo(e){return this.fieldsIndex.has(e)?{supportsLabelingInfo:!1,supportsRenderer:!1,supportsPopupTemplate:!1,supportsLayerQuery:!1}:{supportsLabelingInfo:!1,supportsRenderer:!0,supportsPopupTemplate:!0,supportsLayerQuery:null!=this.associatedLayer}}_getAssociatedLayerForQuery(){const e=this.associatedLayer;return null!=e&&e.loaded?Promise.resolve(e):this._loadAssociatedLayerForQuery()}async _loadAssociatedLayerForQuery(){if(await this.load(),null==this.associatedLayer)throw new o.A("buildingscenelayer:query-not-available","BuildingSceneLayer component layer queries are not available without an associated feature layer",{layer:this});try{await this.associatedLayer.load()}catch(e){throw new o.A("buildingscenelayer:query-not-available","BuildingSceneLayer associated feature layer could not be loaded",{layer:this,error:e})}return this.associatedLayer}};(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"parsedUrl",null),(0,s._)([(0,f.MZ)({type:C.W4,readOnly:!0})],H.prototype,"nodePages",void 0),(0,s._)([(0,f.MZ)({type:[C.uV],readOnly:!0})],H.prototype,"materialDefinitions",void 0),(0,s._)([(0,f.MZ)({type:[C.Ot],readOnly:!0})],H.prototype,"textureSetDefinitions",void 0),(0,s._)([(0,f.MZ)({type:[C.L0],readOnly:!0})],H.prototype,"geometryDefinitions",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"serviceUpdateTimeStamp",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"store",void 0),(0,s._)([(0,f.MZ)({type:String,readOnly:!0,json:{read:{source:"store.rootNode"}}})],H.prototype,"rootNode",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"attributeStorageInfo",void 0),(0,s._)([(0,f.MZ)(J.fields)],H.prototype,"fields",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"fieldsIndex",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:I.default})],H.prototype,"associatedLayer",void 0),(0,s._)([(0,m.w)("service","associatedLayer",["associatedLayerID"])],H.prototype,"readAssociatedLayer",null),(0,s._)([(0,f.MZ)(J.outFields)],H.prototype,"outFields",void 0),(0,s._)([(0,f.MZ)({type:String,readOnly:!0})],H.prototype,"objectIdField",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:String,json:{read:!1}})],H.prototype,"displayField",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:String})],H.prototype,"apiKey",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:String})],H.prototype,"customParameters",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:F.A})],H.prototype,"fullExtent",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:_.A})],H.prototype,"spatialReference",null),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"version",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:Q.A})],H.prototype,"elevationInfo",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:Number})],H.prototype,"minScale",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:Number})],H.prototype,"maxScale",null),(0,s._)([(0,f.MZ)({readOnly:!0,type:Number})],H.prototype,"effectiveScaleRange",null),(0,s._)([(0,f.MZ)({type:["hide","show"],json:{write:!0}})],H.prototype,"listMode",void 0),(0,s._)([(0,f.MZ)({types:k.XJ,json:{origins:{service:{read:{source:"drawingInfo.renderer"}}},name:"layerDefinition.drawingInfo.renderer",write:!0},value:null})],H.prototype,"renderer",void 0),(0,s._)([(0,f.MZ)({type:String,json:{origins:{service:{read:!1,write:!1}},name:"layerDefinition.definitionExpression",write:{enabled:!0,allowNull:!0}}})],H.prototype,"definitionExpression",void 0),(0,s._)([(0,f.MZ)(E.M6)],H.prototype,"popupEnabled",void 0),(0,s._)([(0,f.MZ)({type:w.A,json:{read:{source:"popupInfo"},write:{target:"popupInfo"}}})],H.prototype,"popupTemplate",void 0),(0,s._)([(0,f.MZ)({readOnly:!0,type:String,json:{origins:{service:{read:{source:"store.normalReferenceFrame"}}},read:!1}})],H.prototype,"normalReferenceFrame",void 0),(0,s._)([(0,f.MZ)({readOnly:!0,json:{read:!1}})],H.prototype,"defaultPopupTemplate",null),(0,s._)([(0,f.MZ)()],H.prototype,"types",null),(0,s._)([(0,f.MZ)()],H.prototype,"typeIdField",null),(0,s._)([(0,f.MZ)({json:{write:!1}}),(0,A.e)(new S.J({"3DObject":"3d-object",Point:"point"}))],H.prototype,"layerType",void 0),(0,s._)([(0,f.MZ)()],H.prototype,"geometryType",null),(0,s._)([(0,f.MZ)()],H.prototype,"profile",null),(0,s._)([(0,f.MZ)({readOnly:!0,json:{read:!1}})],H.prototype,"capabilities",null),(0,s._)([(0,f.MZ)({readOnly:!0})],H.prototype,"statisticsInfo",void 0),H=(0,s._)([(0,g.$)("esri.layers.buildingSublayers.BuildingComponentSublayer")],H);const K=H;var W,Y=r(67076);const X={type:i.A,readOnly:!0,json:{origins:{service:{read:{source:"sublayers",reader:ee}}},read:!1}};function ee(e,t,r){if(e&&Array.isArray(e))return new i.A(e.map((e=>{const t=function(e){return"group"===e.layerType?te:K}(e);if(t){const s=new t;return s.read(e,r),s}return r?.messages&&e&&r.messages.push(new Y.A("building-scene-layer:unsupported-sublayer-type","Building scene sublayer of type '"+(e.type||"unknown")+"' are not supported",{definition:e,context:r})),null})))}let te=W=class extends R{constructor(e){super(e),this.type="building-group",this.listMode="show",this.sublayers=null}loadAll(){return(0,u.L)(this,(e=>W.forEachSublayer(this.sublayers,(t=>{"building-group"!==t.type&&e(t)}))))}};(0,s._)([(0,f.MZ)({type:["hide","show","hide-children"],json:{write:!0}})],te.prototype,"listMode",void 0),(0,s._)([(0,f.MZ)(X)],te.prototype,"sublayers",void 0),te=W=(0,s._)([(0,g.$)("esri.layers.buildingSublayers.BuildingGroupSublayer")],te),function(e){e.sublayersProperty=X,e.readSublayers=ee,e.forEachSublayer=function e(t,r){t.forEach((t=>{r(t),"building-group"===t.type&&e(t.sublayers,r)}))}}(te||(te={}));const re=te;var se=r(52136),ie=r(18768),ne=r(69208),oe=r(16131),ae=r(8303),le=r(25036),ue=r(58947),pe=r(92009),de=r(25482),ce=r(13069);let ye=class extends de.A{constructor(){super(...arguments),this.type=null}};(0,s._)([(0,f.MZ)({type:String,readOnly:!0,json:{write:{isRequired:!0}}})],ye.prototype,"type",void 0),ye=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterAuthoringInfo")],ye);const he=ye;var fe;let me=fe=class extends de.A{constructor(){super(...arguments),this.filterType=null,this.filterValues=null}clone(){return new fe({filterType:this.filterType,filterValues:(0,l.o8)(this.filterValues)})}};(0,s._)([(0,f.MZ)({type:String,json:{write:{isRequired:!0}}})],me.prototype,"filterType",void 0),(0,s._)([(0,f.MZ)({type:[String],json:{write:{isRequired:!0}}})],me.prototype,"filterValues",void 0),me=fe=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterAuthoringInfoType")],me);const ge=me;var _e;const ve=i.A.ofType(ge);let be=_e=class extends de.A{clone(){return new _e({filterTypes:(0,l.o8)(this.filterTypes)})}};(0,s._)([(0,f.MZ)({type:ve,json:{write:{isRequired:!0}}})],be.prototype,"filterTypes",void 0),be=_e=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterAuthoringInfoBlock")],be);const we=be;var xe;const Se=i.A.ofType(we);let Me=xe=class extends he{constructor(){super(...arguments),this.type="checkbox"}clone(){return new xe({filterBlocks:(0,l.o8)(this.filterBlocks)})}};(0,s._)([(0,f.MZ)({type:["checkbox"]})],Me.prototype,"type",void 0),(0,s._)([(0,f.MZ)({type:Se,json:{write:{isRequired:!0}}})],Me.prototype,"filterBlocks",void 0),Me=xe=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterAuthoringInfoCheckbox")],Me);const Te=Me;let Ae=class extends de.A{};(0,s._)([(0,f.MZ)({readOnly:!0,json:{read:!1,write:{isRequired:!0}}})],Ae.prototype,"type",void 0),Ae=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterMode")],Ae);const Fe=Ae;var Ie;let Ze=Ie=class extends Fe{constructor(){super(...arguments),this.type="solid"}clone(){return new Ie}};(0,s._)([(0,f.MZ)({type:["solid"],readOnly:!0,json:{write:{isRequired:!0}}})],Ze.prototype,"type",void 0),Ze=Ie=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterModeSolid")],Ze);const Oe=Ze;var Ee,je=r(51734);let Re=Ee=class extends Fe{constructor(){super(...arguments),this.type="wire-frame",this.edges=null}clone(){return new Ee({edges:(0,l.o8)(this.edges)})}};(0,s._)([(0,A.e)({wireFrame:"wire-frame"})],Re.prototype,"type",void 0),(0,s._)([(0,f.MZ)(je.J)],Re.prototype,"edges",void 0),Re=Ee=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterModeWireFrame")],Re);const Pe=Re;var Le;let $e=Le=class extends Fe{constructor(){super(...arguments),this.type="x-ray"}clone(){return new Le}};(0,s._)([(0,f.MZ)({type:["x-ray"],readOnly:!0,json:{write:{isRequired:!0}}})],$e.prototype,"type",void 0),$e=Le=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterModeXRay")],$e);const Ne=$e;var Be;const qe={nonNullable:!0,types:{key:"type",base:Fe,typeMap:{solid:Oe,"wire-frame":Pe,"x-ray":Ne}},json:{read:e=>{switch(e?.type){case"solid":return Oe.fromJSON(e);case"wireFrame":return Pe.fromJSON(e);case"x-ray":return Ne.fromJSON(e);default:return}},write:{enabled:!0,isRequired:!0}}};let Ce=Be=class extends de.A{constructor(){super(...arguments),this.filterExpression=null,this.filterMode=new Oe,this.title=""}clone(){return new Be({filterExpression:this.filterExpression,filterMode:(0,l.o8)(this.filterMode),title:this.title})}};(0,s._)([(0,f.MZ)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],Ce.prototype,"filterExpression",void 0),(0,s._)([(0,f.MZ)(qe)],Ce.prototype,"filterMode",void 0),(0,s._)([(0,f.MZ)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],Ce.prototype,"title",void 0),Ce=Be=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilterBlock")],Ce);const ke=Ce;var De;const ze=i.A.ofType(ke);let Ue=De=class extends de.A{constructor(){super(...arguments),this.description=null,this.filterBlocks=null,this.id=(0,ce.lk)(),this.name=null}clone(){return new De({description:this.description,filterBlocks:(0,l.o8)(this.filterBlocks),id:this.id,name:this.name,filterAuthoringInfo:(0,l.o8)(this.filterAuthoringInfo)})}};(0,s._)([(0,f.MZ)({type:String,json:{write:!0}})],Ue.prototype,"description",void 0),(0,s._)([(0,f.MZ)({type:ze,json:{write:{enabled:!0,isRequired:!0}}})],Ue.prototype,"filterBlocks",void 0),(0,s._)([(0,f.MZ)({types:{key:"type",base:he,typeMap:{checkbox:Te}},json:{read:e=>"checkbox"===e?.type?Te.fromJSON(e):null,write:!0}})],Ue.prototype,"filterAuthoringInfo",void 0),(0,s._)([(0,f.MZ)({type:String,constructOnly:!0,json:{write:{enabled:!0,isRequired:!0}}})],Ue.prototype,"id",void 0),(0,s._)([(0,f.MZ)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],Ue.prototype,"name",void 0),Ue=De=(0,s._)([(0,g.$)("esri.layers.support.BuildingFilter")],Ue);const Qe=Ue;let Ge=class extends de.A{constructor(){super(...arguments),this.fieldName=null,this.modelName=null,this.label=null,this.min=null,this.max=null,this.mostFrequentValues=null,this.subLayerIds=null}};(0,s._)([(0,f.MZ)({type:String})],Ge.prototype,"fieldName",void 0),(0,s._)([(0,f.MZ)({type:String})],Ge.prototype,"modelName",void 0),(0,s._)([(0,f.MZ)({type:String})],Ge.prototype,"label",void 0),(0,s._)([(0,f.MZ)({type:Number})],Ge.prototype,"min",void 0),(0,s._)([(0,f.MZ)({type:Number})],Ge.prototype,"max",void 0),(0,s._)([(0,f.MZ)({json:{read:e=>Array.isArray(e)&&(e.every((e=>"string"==typeof e))||e.every((e=>"number"==typeof e)))?e.slice():null}})],Ge.prototype,"mostFrequentValues",void 0),(0,s._)([(0,f.MZ)({type:[Number]})],Ge.prototype,"subLayerIds",void 0),Ge=(0,s._)([(0,g.$)("esri.layers.support.BuildingSummaryStatistics.BuildingFieldStatistics")],Ge);let Ve=class extends(M.A.LoadableMixin(T.A.EsriPromiseMixin(de.A))){constructor(){super(...arguments),this.url=null}get fields(){return this.loaded||"loading"===this.loadStatus?this._get("fields"):(p.A.getLogger(this).error("building summary statistics are not loaded"),null)}load(e){const t=null!=e?e.signal:null;return this.addResolvingPromise(this._fetchService(t)),Promise.resolve(this)}async _fetchService(e){const t=(await(0,x.A)(this.url,{query:{f:"json"},responseType:"json",signal:e})).data;this.read(t,{origin:"service"})}};(0,s._)([(0,f.MZ)({constructOnly:!0,type:String})],Ve.prototype,"url",void 0),(0,s._)([(0,f.MZ)({readOnly:!0,type:[Ge],json:{read:{source:"summary"}}})],Ve.prototype,"fields",null),Ve=(0,s._)([(0,g.$)("esri.layers.support.BuildingSummaryStatistics")],Ve);const Je=Ve;var He=r(24212);const Ke=i.A.ofType(Qe),We=(0,l.o8)(re.sublayersProperty),Ye=We.json?.origins;Ye&&(Ye["web-scene"]={type:[K],write:{enabled:!0,overridePolicy:()=>({enabled:!1})}},Ye["portal-item"]={type:[K],write:{enabled:!0,overridePolicy:()=>({enabled:!1})}});let Xe=class extends((0,ue.w6)((0,ie.b)((0,oe.q)((0,ae.A)((0,le.j)((0,d.P)((0,ne.d)((0,se.p)(v.A))))))))){constructor(e){super(e),this.operationalLayerType="BuildingSceneLayer",this.allSublayers=new n.A({getCollections:()=>[this.sublayers],getChildrenFunction:e=>"building-group"===e.type?e.sublayers:null}),this.sublayers=null,this._allSublayerOverrides=null,this.filters=new Ke,this.activeFilterId=null,this.summaryStatistics=null,this.outFields=null,this.legendEnabled=!0,this.type="building-scene"}normalizeCtorArgs(e){return"string"==typeof e?{url:e}:e??{}}destroy(){this.allSublayers.destroy()}readSublayers(e,t,r){const s=re.readSublayers(e,t,r);return re.forEachSublayer(s,(e=>e.layer=this)),this._allSublayerOverrides&&(function(e,t){t.forEach((t=>et(e,t)))}(s,this._allSublayerOverrides),this._allSublayerOverrides=null),s}write(e,t){return e=super.write(e,t),!t||"web-scene"!==t.origin&&"portal-item"!==t.origin||(this.sublayers?function(e,t,r){const s=[];re.forEachSublayer(e,(e=>{const t=e.write({},r);Object.keys(t).length>1&&s.push(t)})),s.length>0&&(t.sublayers=s)}(this.sublayers,e,t):this._allSublayerOverrides&&function(e,t,r){const s=r?.origin&&e.get(r.origin);s&&(t.sublayers=[],s.overrides.forEach((e=>{t.sublayers.push((0,l.o8)(e))})))}(this._allSublayerOverrides,e,t)),e}read(e,t){if(super.read(e,t),("web-scene"===t?.origin||"portal-item"===t?.origin)&&Array.isArray(e?.sublayers)){const r=function(e,t){const r=new Map;for(const s of e)null!=s&&"object"==typeof s&&"number"==typeof s.id?r.set(s.id,s):t.messages?.push(new o.A("building-scene-layer:invalid-sublayer-override","Invalid value for sublayer override. Not an object or no id specified.",{value:s}));return{overrides:r,context:t}}(e.sublayers,t);this.sublayers?et(this.sublayers,r):(this._allSublayerOverrides??=new Map,this._allSublayerOverrides.set(t.origin,r))}}readSummaryStatistics(e,t){if("string"==typeof t.statisticsHRef){const e=(0,h.fj)(this.parsedUrl?.path,t.statisticsHRef);return new Je({url:e})}return null}set elevationInfo(e){null!=e&&"absolute-height"!==e.mode||this._set("elevationInfo",e),this._validateElevationInfo(e)}load(e){const t=null!=e?e.signal:null,r=this.loadFromPortal({supportedTypes:["Scene Service"]},e).catch(c.QP).then((()=>this._fetchService(t))).then((()=>this._fetchAssociatedFeatureService(t)));return this.addResolvingPromise(r),Promise.resolve(this)}loadAll(){return(0,u.g)(this,(e=>{re.forEachSublayer(this.sublayers,(t=>{"building-group"!==t.type&&e(t)})),this.summaryStatistics&&e(this.summaryStatistics)}))}async saveAs(e,t){return this._debouncedSaveOperations(ue.Xh.SAVE_AS,{...t,getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"building-scene"},e)}async save(){const e={getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"building-scene"};return this._debouncedSaveOperations(ue.Xh.SAVE,e)}validateLayer(e){if(!e.layerType||"Building"!==e.layerType)throw new o.A("buildingscenelayer:layer-type-not-supported","BuildingSceneLayer does not support this layer type",{layerType:e.layerType})}_getTypeKeywords(){return["Building"]}async _fetchAssociatedFeatureService(e){try{const{portalItem:t}=await(0,pe.L)(`${this.url}/layers/${this.layerId}`,{sceneLayerItem:this.portalItem,customParameters:this.customParameters,apiKey:this.apiKey,signal:e});this.associatedFeatureServiceItem=t}catch(e){(0,c.QZ)(this._logWarningOnPopupEnabled())}}async _logWarningOnPopupEnabled(){const e=new AbortController;this.addHandles((0,a.rE)(e)),await(0,y.C_)((()=>this.allSublayers.filter((e=>"building-component"===e.type)).some((e=>e.popupEnabled&&null!=e.popupTemplate))),e.signal);const t=this.allSublayers.filter((e=>"building-component"===e.type)).filter((e=>e.popupEnabled&&null!=e.popupTemplate)),r=[],s=[];for(const e of t){const t=e.title??`untitled ${e.id}`;e.attributeStorageInfo?r.push(t):s.push(t)}const i="\n ",n=r.length>0?`\nThe following sublayers will fall back to binary attributes for Popups:${i}${r.join(i)}`:"",o=s.length>0?`\nThe following sublayers have no binary attributes and will not work with Popups:${i}${s.join(i)}`:"";p.A.getLogger(this).warn(`Associated FeatureLayer could not be loaded for this BuildingSceneLayer: ${this.title}.`,n,o)}_validateElevationInfo(e){const t="Building scene layers";(0,He.XF)(p.A.getLogger(this),(0,He.B)(t,"absolute-height",e)),(0,He.XF)(p.A.getLogger(this),(0,He.tW)(t,e))}};function et(e,t){const{overrides:r,context:s}=t;re.forEachSublayer(e,(e=>e.read(r.get(e.id),s)))}(0,s._)([(0,f.MZ)({type:["BuildingSceneLayer"]})],Xe.prototype,"operationalLayerType",void 0),(0,s._)([(0,f.MZ)({readOnly:!0})],Xe.prototype,"allSublayers",void 0),(0,s._)([(0,f.MZ)(We)],Xe.prototype,"sublayers",void 0),(0,s._)([(0,m.w)("service","sublayers")],Xe.prototype,"readSublayers",null),(0,s._)([(0,f.MZ)({type:Ke,nonNullable:!0,json:{write:!0}})],Xe.prototype,"filters",void 0),(0,s._)([(0,f.MZ)({type:String,json:{write:!0}})],Xe.prototype,"activeFilterId",void 0),(0,s._)([(0,f.MZ)({readOnly:!0,type:Je})],Xe.prototype,"summaryStatistics",void 0),(0,s._)([(0,m.w)("summaryStatistics",["statisticsHRef"])],Xe.prototype,"readSummaryStatistics",null),(0,s._)([(0,f.MZ)({type:[String],json:{read:!1}})],Xe.prototype,"outFields",void 0),(0,s._)([(0,f.MZ)(E.Fm)],Xe.prototype,"fullExtent",void 0),(0,s._)([(0,f.MZ)(E.fV)],Xe.prototype,"legendEnabled",void 0),(0,s._)([(0,f.MZ)({type:["show","hide","hide-children"]})],Xe.prototype,"listMode",void 0),(0,s._)([(0,f.MZ)((0,E.Qo)(_.A))],Xe.prototype,"spatialReference",void 0),(0,s._)([(0,f.MZ)(E.Yj)],Xe.prototype,"elevationInfo",null),(0,s._)([(0,f.MZ)({json:{read:!1},readOnly:!0})],Xe.prototype,"type",void 0),(0,s._)([(0,f.MZ)()],Xe.prototype,"associatedFeatureServiceItem",void 0),Xe=(0,s._)([(0,g.$)("esri.layers.BuildingSceneLayer")],Xe);const tt=Xe},91880:(e,t,r)=>{r.d(t,{A:()=>d});var s,i=r(90237),n=r(66552),o=r(25482),a=r(10107),l=(r(44208),r(53966),r(87811),r(40608));const u=new n.J({asc:"ascending",desc:"descending"});let p=class extends o.A{static{s=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new s({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,i._)([(0,a.MZ)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,i._)([(0,a.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],p.prototype,"valueExpression",void 0),(0,i._)([(0,a.MZ)({type:u.apiValues,json:{type:u.jsonValues,read:u.read,write:u.write}})],p.prototype,"order",void 0),p=s=(0,i._)([(0,l.$)("esri.layers.support.OrderByInfo")],p);const d=p},92935:(e,t,r)=>{var s;r.d(t,{X:()=>s}),function(e){e[e.SAVE=0]="SAVE",e[e.SAVE_AS=1]="SAVE_AS"}(s||(s={}))}}]);