@arcgis/core 5.0.0-next.66 → 5.0.0-next.68

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 (595) hide show
  1. package/Ground.d.ts +4 -4
  2. package/Map.d.ts +1 -1
  3. package/WebDocument2D.d.ts +2 -3
  4. package/WebScene.d.ts +2 -3
  5. package/analysis/ElevationProfile/ElevationProfileLineViewOptions.d.ts +9 -6
  6. package/analysis/ElevationProfile/ElevationProfileLineViewOptions.js +1 -1
  7. package/applications/Components/QuantityFormatter.d.ts +14 -1
  8. package/applications/Components/SelectionOperation.d.ts +45 -9
  9. package/applications/Components/SketchTooltipControls.d.ts +31 -6
  10. package/applications/Components/actionUtils.d.ts +1 -0
  11. package/applications/Components/analysisUtils.d.ts +98 -26
  12. package/applications/Components/arcadeEditorUtils.d.ts +3 -0
  13. package/applications/Components/arcadeFeatureUtils.d.ts +34 -6
  14. package/applications/Components/baUtils.d.ts +8 -8
  15. package/applications/Components/basemapUtils.d.ts +2 -0
  16. package/applications/Components/drawUtils.d.ts +6 -1
  17. package/applications/Components/featureUtils.d.ts +9 -0
  18. package/applications/Components/fontUtils.d.ts +2 -0
  19. package/applications/Components/formatUtils.d.ts +2 -0
  20. package/applications/Components/getDefaultUnits.d.ts +2 -0
  21. package/applications/Components/imageryUtils.d.ts +135 -27
  22. package/applications/Components/layerOriginUtils.d.ts +5 -0
  23. package/applications/Components/layersEffectsJsonUtils.d.ts +2 -0
  24. package/applications/Components/previewSymbol2D.d.ts +2 -0
  25. package/applications/Components/reactiveUtils.d.ts +13 -9
  26. package/applications/Components/sanitizerUtils.d.ts +2 -0
  27. package/applications/Components/stringUtils.d.ts +5 -0
  28. package/applications/Components/styleUtils.d.ts +2 -0
  29. package/applications/Components/svgUtils.d.ts +4 -0
  30. package/applications/Components/testUtils.d.ts +3 -0
  31. package/applications/Components/viewUtils.d.ts +2 -0
  32. package/applications/Components/webStyleSymbolUtils.d.ts +2 -0
  33. package/applications/Excalibur/videoViewUtils.d.ts +19 -3
  34. package/applications/ExperienceBuilder/sketchUtils.d.ts +10 -1
  35. package/applications/KnowledgeStudio/dataModelVisualization.d.ts +2 -0
  36. package/applications/KnowledgeStudio/generalSdkInternalAccess.d.ts +33 -4
  37. package/applications/KnowledgeStudio/generalSharedKgUtils.d.ts +73 -10
  38. package/applications/KnowledgeStudio/layerInternalAccessUtils.d.ts +12 -1
  39. package/applications/KnowledgeStudio/reshape.d.ts +144 -28
  40. package/applications/KnowledgeStudio/resourceSerializationUtils.d.ts +17 -3
  41. package/applications/MapViewer/layerUtils.d.ts +2 -0
  42. package/applications/MapViewer/mediaUtils.d.ts +42 -8
  43. package/applications/MapViewer/templateUtils.d.ts +78 -16
  44. package/applications/PortalApp/layerUtils.d.ts +2 -0
  45. package/applications/SceneViewer/colorUtils.d.ts +2 -0
  46. package/applications/SceneViewer/devEnvironmentUtils.d.ts +3 -0
  47. package/applications/SceneViewer/layerUtils.d.ts +5 -3
  48. package/applications/SceneViewer/sceneViewerUtils.d.ts +52 -5
  49. package/applications/SceneViewer/symbolUtils.d.ts +2 -0
  50. package/applications/Urban/LineImagePattern3D.d.ts +8 -2
  51. package/applications/Urban/imagePatternUtils.d.ts +10 -2
  52. package/applications/Urban/meshUtils.d.ts +2 -0
  53. package/applications/WebEditor/sketchUtils.d.ts +24 -4
  54. package/arcade/arcadeAsyncRuntime.js +1 -1
  55. package/arcade/arcadeCompiler.js +1 -1
  56. package/arcade/arcadeRuntime.js +1 -1
  57. package/arcade/batchExec.js +1 -1
  58. package/arcade/compilerUtils.js +1 -1
  59. package/arcade/featureset/actions/SpatialFilter.js +1 -1
  60. package/arcade/geometry/unitConversion.js +1 -1
  61. package/arcade/treeAnalysis.js +1 -1
  62. package/arcade.js +1 -1
  63. package/assets/components/assets/icon/fileEsl16.json +1 -0
  64. package/assets/components/assets/icon/fileEsl24.json +1 -0
  65. package/assets/components/assets/icon/fileEsl32.json +1 -0
  66. package/assets/esri/core/workers/RemoteClient.js +1 -1
  67. package/assets/esri/core/workers/chunks/{251eb6e00f99a816d55c.js → 0326314947734b8e640a.js} +1 -1
  68. package/assets/esri/core/workers/chunks/04176244b0a3539c9681.js +1 -0
  69. package/assets/esri/core/workers/chunks/04958494022f82dca473.js +1 -0
  70. package/assets/esri/core/workers/chunks/0b7bbdc0d71ee6721751.js +2 -0
  71. package/assets/esri/core/workers/chunks/{5909a0e763fddc3542e7.js.LICENSE.txt → 0b7bbdc0d71ee6721751.js.LICENSE.txt} +1 -1
  72. package/assets/esri/core/workers/chunks/0f8149fdcf0adeca268e.js +1 -0
  73. package/assets/esri/core/workers/chunks/{aa7a1705266eec353cb6.js → 0fc22ad791d3ec0a9c5e.js} +1 -1
  74. package/assets/esri/core/workers/chunks/10e474d664b20adcd917.js +1 -0
  75. package/assets/esri/core/workers/chunks/12f9a55253084a910b2e.js +1 -0
  76. package/assets/esri/core/workers/chunks/14dedd80fb797303f91f.js +1 -0
  77. package/assets/esri/core/workers/chunks/1a6d2f525dd30d08cf9b.js +1 -0
  78. package/assets/esri/core/workers/chunks/{81d89107ff82604a3ea0.js → 1b445981fbc8373f4dd8.js} +1 -1
  79. package/assets/esri/core/workers/chunks/{6ba3c2b9f699d94d62b8.js → 1ec1a1997b5577619040.js} +1 -1
  80. package/assets/esri/core/workers/chunks/204d738c8b651314ae64.js +1 -0
  81. package/assets/esri/core/workers/chunks/2085084324cd5a81783f.js +1 -0
  82. package/assets/esri/core/workers/chunks/{e95821a199e10b389e29.js → 25f3ee666f545a7a7993.js} +2 -2
  83. package/assets/esri/core/workers/chunks/{e95821a199e10b389e29.js.LICENSE.txt → 25f3ee666f545a7a7993.js.LICENSE.txt} +1 -1
  84. package/assets/esri/core/workers/chunks/2c2c0f66cffc521df736.js +1 -0
  85. package/assets/esri/core/workers/chunks/2dd347aa2a061d536e69.js +1 -0
  86. package/assets/esri/core/workers/chunks/2dfa7abf2d39fa5a3874.js +1 -0
  87. package/assets/esri/core/workers/chunks/322085d63719da6e443c.js +1 -0
  88. package/assets/esri/core/workers/chunks/{76086517591d0eb35156.js → 34a2e0462eb05986cdd1.js} +1 -1
  89. package/assets/esri/core/workers/chunks/{a6dcd13c792b6538ac50.js → 35593a9790818b689455.js} +1 -1
  90. package/assets/esri/core/workers/chunks/36ecf951c0c7dad84b69.js +1 -0
  91. package/assets/esri/core/workers/chunks/37002a46f03a9fc5f644.js.LICENSE.txt +1 -1
  92. package/assets/esri/core/workers/chunks/3a04153ca9d8e4f01185.js +1 -0
  93. package/assets/esri/core/workers/chunks/{4e9a8fce55cad841c731.js → 3b25f5d9c8f78bb6e011.js} +1 -1
  94. package/assets/esri/core/workers/chunks/3e7ea06b342e33bc48a5.js +1 -0
  95. package/assets/esri/core/workers/chunks/3ed317900f0edf635508.js +1 -0
  96. package/assets/esri/core/workers/chunks/401ce5cb98fa14c1a725.js +1 -0
  97. package/assets/esri/core/workers/chunks/4319b89cfa02894a8cae.js +1 -0
  98. package/assets/esri/core/workers/chunks/43e2c1d72cd9c8beed2f.js.LICENSE.txt +1 -1
  99. package/assets/esri/core/workers/chunks/45a9cd722e98dd1548ae.js +1 -0
  100. package/assets/esri/core/workers/chunks/4a060147d25929680ec8.js +1 -0
  101. package/assets/esri/core/workers/chunks/4bcd74951477e8977ba1.js +1 -0
  102. package/assets/esri/core/workers/chunks/4d0eaeb4cd6cd55e25fd.js +1 -0
  103. package/assets/esri/core/workers/chunks/{687d2b761dc5b5cf0c31.js → 4d4d71d24c1a9cb342b8.js} +1 -1
  104. package/assets/esri/core/workers/chunks/4fa230dc6e5e87b0dec1.js +1 -0
  105. package/assets/esri/core/workers/chunks/50f03813fba4b752ca9f.js +1 -0
  106. package/assets/esri/core/workers/chunks/{abc236e99b52be1c83b9.js → 52a14266fe239b95c5ce.js} +1 -1
  107. package/assets/esri/core/workers/chunks/53b5c77832df7df4d4e3.js +1 -0
  108. package/assets/esri/core/workers/chunks/{34178ace79e8dea3567d.js → 562cddaf63985e53ee6e.js} +1 -1
  109. package/assets/esri/core/workers/chunks/59a45533e96cedf1c480.js +1 -0
  110. package/assets/esri/core/workers/chunks/{c2aeecd27e004c6cd7e1.js → 5b9f2aa3ba1bf12c3240.js} +2 -2
  111. package/assets/esri/core/workers/chunks/{c2aeecd27e004c6cd7e1.js.LICENSE.txt → 5b9f2aa3ba1bf12c3240.js.LICENSE.txt} +1 -1
  112. package/assets/esri/core/workers/chunks/{6599cc702a46f81a5634.js → 5dd5be91038df8902dc4.js} +1 -1
  113. package/assets/esri/core/workers/chunks/{49a1b7f700b8a42de817.js → 60c7f896f2246a8aa6d7.js} +19 -19
  114. package/assets/esri/core/workers/chunks/60f363ee2add089e8f0b.js +1 -0
  115. package/assets/esri/core/workers/chunks/61801bb8c7be8fe77086.js +1 -0
  116. package/assets/esri/core/workers/chunks/679cd6424e0e2d7f372b.js +1 -0
  117. package/assets/esri/core/workers/chunks/68074a484d7f9bc713c0.js +1 -0
  118. package/assets/esri/core/workers/chunks/6acfa51b81e6f4255118.js +1 -0
  119. package/assets/esri/core/workers/chunks/{3fe7be535affae31de7e.js → 6b85a8776ec2beff63cb.js} +1 -1
  120. package/assets/esri/core/workers/chunks/6be530ab81291745485b.js.LICENSE.txt +1 -1
  121. package/assets/esri/core/workers/chunks/6df484faf54e90a6cc77.js +1 -0
  122. package/assets/esri/core/workers/chunks/6ea6ad894ac634aa4391.js +1 -0
  123. package/assets/esri/core/workers/chunks/6f8098f9fe233833245a.js +1 -0
  124. package/assets/esri/core/workers/chunks/73c416ae0ec5a1815591.js.LICENSE.txt +1 -1
  125. package/assets/esri/core/workers/chunks/75fd2ef1236a9364ca7f.js +1 -0
  126. package/assets/esri/core/workers/chunks/{23b623637126f8411a30.js → 7aec07f2482934259d12.js} +1 -1
  127. package/assets/esri/core/workers/chunks/7be9bbae23895d1cfa92.js +1 -0
  128. package/assets/esri/core/workers/chunks/{741d170187e58e81584d.js → 7d744554d14057d9b2b1.js} +1 -1
  129. package/assets/esri/core/workers/chunks/7ea48661f1087d06aa41.js +1 -0
  130. package/assets/esri/core/workers/chunks/{47e5149765beee46f208.js → 7ee68f67f9cc48a328f0.js} +1 -1
  131. package/assets/esri/core/workers/chunks/866477acdf03b8a40bc9.js +1 -0
  132. package/assets/esri/core/workers/chunks/8e83c133b201b9b61e70.js +1 -0
  133. package/assets/esri/core/workers/chunks/9086a4933d3d3d9ffa72.js +1 -0
  134. package/assets/esri/core/workers/chunks/94174d40de39dbe7d0bf.js +1 -0
  135. package/assets/esri/core/workers/chunks/98f4b44eca91c42ca08e.js +1 -0
  136. package/assets/esri/core/workers/chunks/9ccabf8142fb5de4d3e2.js.LICENSE.txt +1 -1
  137. package/assets/esri/core/workers/chunks/{dd99b77a7c0a052507bb.js → 9d88b4ba8e511da64583.js} +3 -3
  138. package/assets/esri/core/workers/chunks/a808be466812db51813d.js +1 -0
  139. package/assets/esri/core/workers/chunks/{6b4a24248182245167ca.js → a931515a2569713e743b.js} +1 -1
  140. package/assets/esri/core/workers/chunks/a95e28ade258b144cbb5.js +1 -0
  141. package/assets/esri/core/workers/chunks/adc68e2c6d2698a52bfe.js +1 -0
  142. package/assets/esri/core/workers/chunks/aeb524eded012217a865.js +1 -0
  143. package/assets/esri/core/workers/chunks/b2a1e5e9182b643909eb.js +316 -0
  144. package/assets/esri/core/workers/chunks/{ac6f002cfad42e60de8f.js → b48033645091c91e0d88.js} +1 -1
  145. package/assets/esri/core/workers/chunks/b8988771bfa4e785ebd6.js +1 -0
  146. package/assets/esri/core/workers/chunks/bb4574a87ca21e719f0d.js +1 -0
  147. package/assets/esri/core/workers/chunks/{07639f406b71bb49ffd6.js → bdbb5b33f0f49661bf6d.js} +1 -1
  148. package/assets/esri/core/workers/chunks/c042269586921e337be9.js +1 -0
  149. package/assets/esri/core/workers/chunks/c623918e289a09905cd1.js +1 -0
  150. package/assets/esri/core/workers/chunks/c7391b0b5a9c916a53f7.js +1 -0
  151. package/assets/esri/core/workers/chunks/{ac83c2999a3d2ffb4356.js → c7838ac0db8570a2d2c1.js} +1 -1
  152. package/assets/esri/core/workers/chunks/c91ef3814e7f024043cf.js +1 -0
  153. package/assets/esri/core/workers/chunks/{43d28c6509c21b8917a8.js → ca7523c14d81c470e92e.js} +1 -1
  154. package/assets/esri/core/workers/chunks/cd2708fb7636b3ace229.js +1 -0
  155. package/assets/esri/core/workers/chunks/{310f3268582e61cd86da.js → d21480925a8bc9c7de96.js} +1 -1
  156. package/assets/esri/core/workers/chunks/d445e9399fe4ca3d2a50.js +1 -0
  157. package/assets/esri/core/workers/chunks/d7683a95775c9f401a7e.js +1 -0
  158. package/assets/esri/core/workers/chunks/{9d6945cda99d14af83ac.js → d7d9656b990ce8be2152.js} +1 -1
  159. package/assets/esri/core/workers/chunks/d9ca754f51b9812bb179.js +1 -0
  160. package/assets/esri/core/workers/chunks/d9ef0b3341e2744d8f2f.js +1 -0
  161. package/assets/esri/core/workers/chunks/df4a0af329ce94a47a7b.js +1 -0
  162. package/assets/esri/core/workers/chunks/e10d6e511921394474ca.js +1 -0
  163. package/assets/esri/core/workers/chunks/e4b6aa8f67c2bd285020.js +1 -0
  164. package/assets/esri/core/workers/chunks/e5aac523c37d906eece6.js +1 -0
  165. package/assets/esri/core/workers/chunks/e6ca02f98f855024f74b.js +1 -0
  166. package/assets/esri/core/workers/chunks/{892157696e8f9e38c472.js → e6e837e43b9348050832.js} +1 -1
  167. package/assets/esri/core/workers/chunks/{d3325ed8d224e2350db7.js → e8a3ad00936f2ccaf362.js} +1 -1
  168. package/assets/esri/core/workers/chunks/{f351007cdcd0938d3b6c.js → eeb24a4ab4993f1f4e8e.js} +1 -1
  169. package/assets/esri/core/workers/chunks/ef7063ee790d2d64d4b2.js +1 -0
  170. package/assets/esri/core/workers/chunks/{b65fcfde62d49de1fa54.js → ef977be20a647aeded0a.js} +1 -1
  171. package/assets/esri/core/workers/chunks/efb631371b6bb3f043bb.js +1 -0
  172. package/assets/esri/core/workers/chunks/{0f5693541111fcae0c2f.js → f0914715e90e43466f8c.js} +1 -1
  173. package/assets/esri/core/workers/chunks/f25bebd2b6eb0d0f6626.js.LICENSE.txt +1 -1
  174. package/assets/esri/core/workers/chunks/f95e488d2b86e320624f.js +1 -0
  175. package/assets/esri/core/workers/chunks/{bfc063d4431bfa162160.js → fd09f38fb4d99bf34988.js} +1 -1
  176. package/assets/esri/libs/lyr3d/lyr3DMain.wasm +0 -0
  177. package/assets/esri/libs/lyr3d/lyr3DWorker.wasm +0 -0
  178. package/assets/esri/libs/text/pkg/bundle_bg.wasm +0 -0
  179. package/chunks/boundedPlane.js +1 -1
  180. package/chunks/bundle2.js +5 -0
  181. package/config.js +1 -1
  182. package/copyright.txt +70 -1
  183. package/core/BidiText.js +1 -1
  184. package/core/accessorSupport/ensureType.js +1 -1
  185. package/core/compilerUtils.js +1 -1
  186. package/core/typedArrayUtil.js +1 -1
  187. package/core/units.js +1 -1
  188. package/core/workers/loaderConfig.js +1 -1
  189. package/editing/sharedTemplates/SharedTemplate.js +1 -1
  190. package/geometry/support/FloatArray.js +1 -1
  191. package/geometry/support/Indices.js +1 -1
  192. package/geometry/support/MeshTexture.js +1 -1
  193. package/geometry/support/aaBoundingRect.js +1 -1
  194. package/geometry/support/boundedPlane.js +1 -1
  195. package/geometry/support/heightModelInfoUtils.js +1 -1
  196. package/geometry/support/meshUtils/External.js +1 -1
  197. package/geometry/support/meshUtils/exporters/gltf/imageutils.js +1 -1
  198. package/geometry/support/meshUtils/loadExternal.js +1 -1
  199. package/geometry/support/rotate.js +1 -1
  200. package/interfaces.d.ts +23 -24
  201. package/kernel.js +1 -1
  202. package/layers/BingMapsLayer.d.ts +2 -3
  203. package/layers/BuildingSceneLayer.d.ts +3 -5
  204. package/layers/CatalogLayer.d.ts +2 -4
  205. package/layers/DimensionLayer.d.ts +2 -3
  206. package/layers/ElevationLayer.d.ts +2 -4
  207. package/layers/FeatureLayer.d.ts +2 -4
  208. package/layers/GaussianSplatLayer.d.ts +1 -3
  209. package/layers/GeoJSONLayer.d.ts +2 -3
  210. package/layers/GeoRSSLayer.d.ts +2 -3
  211. package/layers/GroupLayer.d.ts +2 -3
  212. package/layers/ImageryLayer.d.ts +2 -5
  213. package/layers/ImageryTileLayer.d.ts +3 -7
  214. package/layers/IntegratedMesh3DTilesLayer.d.ts +2 -4
  215. package/layers/IntegratedMeshLayer.d.ts +2 -4
  216. package/layers/KMLLayer.d.ts +2 -3
  217. package/layers/KnowledgeGraphLayer.d.ts +2 -4
  218. package/layers/LineOfSightLayer.d.ts +2 -3
  219. package/layers/LinkChartLayer.d.ts +2 -3
  220. package/layers/Lyr3DWasmPerSceneView.js +1 -1
  221. package/layers/MapImageLayer.d.ts +2 -4
  222. package/layers/MapNotesLayer.d.ts +2 -3
  223. package/layers/MediaLayer.d.ts +3 -4
  224. package/layers/OGCFeatureLayer.d.ts +2 -3
  225. package/layers/ParquetLayer.d.ts +2 -3
  226. package/layers/PointCloudLayer.d.ts +2 -4
  227. package/layers/RouteLayer.d.ts +2 -3
  228. package/layers/SceneLayer.d.ts +2 -4
  229. package/layers/StreamLayer.d.ts +2 -4
  230. package/layers/SubtypeGroupLayer.d.ts +2 -4
  231. package/layers/TileLayer.d.ts +2 -4
  232. package/layers/UnknownLayer.d.ts +2 -3
  233. package/layers/UnsupportedLayer.d.ts +2 -3
  234. package/layers/VectorTileLayer.d.ts +2 -4
  235. package/layers/VideoLayer.d.ts +8 -9
  236. package/layers/ViewshedLayer.d.ts +2 -3
  237. package/layers/VoxelLayer.d.ts +2 -4
  238. package/layers/WCSLayer.d.ts +2 -4
  239. package/layers/WFSLayer.d.ts +2 -3
  240. package/layers/WMSLayer.d.ts +5 -6
  241. package/layers/WMTSLayer.d.ts +4 -5
  242. package/layers/WebTileLayer.d.ts +2 -3
  243. package/layers/buildingSublayers/BuildingGroupSublayer.d.ts +1 -1
  244. package/layers/buildingSublayers/BuildingSublayer.d.ts +3 -3
  245. package/layers/buildingSublayers/BuildingSublayer.js +1 -1
  246. package/layers/catalog/CatalogDynamicGroupLayer.d.ts +2 -3
  247. package/layers/catalog/CatalogFootprintLayer.d.ts +2 -3
  248. package/layers/graphics/controllers/FeatureTileController3D.js +1 -1
  249. package/layers/graphics/controllers/I3SOnDemandController.js +1 -1
  250. package/layers/graphics/data/QueryEngineResult.js +1 -1
  251. package/layers/graphics/dehydratedFeatureComparison.js +1 -1
  252. package/layers/graphics/dehydratedFeatures.js +1 -1
  253. package/layers/graphics/hydratedFeatures.js +1 -1
  254. package/layers/knowledgeGraph/KnowledgeGraphSublayer.d.ts +4 -6
  255. package/layers/{support/media.d.ts → media/types.d.ts} +9 -9
  256. package/layers/mixins/ArcGISImageService.d.ts +1 -1
  257. package/layers/mixins/ImageryTileMixin.d.ts +1 -1
  258. package/layers/orientedImagery/transformations/rectifyMapPoint.js +1 -1
  259. package/layers/raster/datasets/wcsCoverageParser.d.ts +1 -1
  260. package/layers/raster/functions/changeDetectionUtils.js +1 -1
  261. package/layers/raster/functions/creators/createLocalFunctions.d.ts +1 -1
  262. package/layers/raster/functions/customBandIndexUtils.js +1 -1
  263. package/layers/raster/functions/focalStatUtils.js +1 -1
  264. package/layers/raster/functions/pixelTransformUtils.js +1 -1
  265. package/layers/raster/functions/types.d.ts +1 -1
  266. package/layers/{support/RasterTypes.d.ts → raster/types.d.ts} +2 -2
  267. package/layers/save/featureLayerUtils.js +1 -1
  268. package/layers/support/ElevationQuery.d.ts +2 -2
  269. package/layers/support/ElevationSampler.js +1 -1
  270. package/layers/support/FeatureType.d.ts +2 -2
  271. package/layers/support/Field.d.ts +2 -3
  272. package/layers/support/FieldConfiguration.d.ts +1 -1
  273. package/layers/support/ImageElement.d.ts +3 -3
  274. package/layers/support/LocalMediaElementSource.d.ts +1 -1
  275. package/layers/support/MediaElementBase.d.ts +4 -7
  276. package/layers/support/PixelBlock.d.ts +1 -1
  277. package/layers/support/RasterFunction.d.ts +1 -1
  278. package/layers/support/RasterInfo.d.ts +1 -1
  279. package/layers/support/Sublayer.d.ts +2 -3
  280. package/layers/support/Subtype.d.ts +2 -2
  281. package/layers/support/SubtypeSublayer.d.ts +2 -3
  282. package/layers/support/SubtypeSublayer.js +1 -1
  283. package/layers/support/VideoElement.d.ts +2 -2
  284. package/layers/support/WMSSublayer.d.ts +6 -6
  285. package/layers/support/WMSSublayer.js +1 -1
  286. package/layers/support/domains.js +1 -1
  287. package/layers/support/rasterFunctionUtils.d.ts +1 -1
  288. package/layers/support/tiles3DUtils.js +1 -1
  289. package/layers/support/types.d.ts +33 -1
  290. package/layers/types.d.ts +17 -2
  291. package/layers/wmts/types.d.ts +2 -0
  292. package/libs/text/loadTextModule.js +5 -0
  293. package/linkChart/LinkChartProperties.d.ts +4 -6
  294. package/linkChart/LinkChartProperties.js +1 -1
  295. package/networks/Network.d.ts +2 -4
  296. package/networks/support/NamedTraceConfiguration.d.ts +3 -3
  297. package/networks/support/NamedTraceConfiguration.js +1 -1
  298. package/networks/support/TopologyValidationJobInfo.js +1 -1
  299. package/networks/support/TraceJobInfo.js +1 -1
  300. package/package.json +3 -3
  301. package/popup/FieldInfo.d.ts +1 -1
  302. package/renderers/support/RasterSymbolizer.js +1 -1
  303. package/renderers/support/rendererConversion.js +1 -1
  304. package/renderers/visualVariables/support/visualVariableUtils.js +1 -1
  305. package/request/process.js +1 -1
  306. package/rest/geometryService/types.d.ts +59 -0
  307. package/rest/geometryService.d.ts +3 -5
  308. package/rest/query/operations/pbfDehydratedFeatureSet.js +1 -1
  309. package/rest/query/operations/query.js +1 -1
  310. package/rest/query/support/AttachmentInfo.d.ts +2 -2
  311. package/rest/support/AlgorithmicColorRamp.d.ts +2 -2
  312. package/rest/support/BinParametersBase.d.ts +2 -2
  313. package/rest/support/BinParametersBase.js +1 -1
  314. package/rest/support/DateBinTimeInterval.d.ts +1 -1
  315. package/rest/support/GeneralizeParameters.d.ts +1 -1
  316. package/rest/support/ImageSampleParameters.d.ts +1 -1
  317. package/rest/support/JobInfo.js +1 -1
  318. package/rest/support/PrintTemplate.d.ts +4 -6
  319. package/rest/support/ServiceAreaParameters.js +1 -1
  320. package/rest/support/types.d.ts +17 -1
  321. package/smartMapping/heuristics/sizeRange.js +1 -1
  322. package/smartMapping/renderers/support/utils.js +1 -1
  323. package/smartMapping/statistics/support/statsWorker.js +1 -1
  324. package/smartMapping/statistics/support/utils.js +1 -1
  325. package/smartMapping/support/adapters/FeatureLayerAdapter.js +1 -1
  326. package/smartMapping/support/adapters/InMemoryLayerAdapter.js +1 -1
  327. package/smartMapping/support/adapters/support/histogramUtils.js +1 -1
  328. package/smartMapping/support/adapters/support/utils.js +1 -1
  329. package/smartMapping/support/utils.js +1 -1
  330. package/support/revision.js +1 -1
  331. package/symbols/WebStyleSymbol.d.ts +0 -24
  332. package/symbols/WebStyleSymbol.js +1 -1
  333. package/symbols/support/ElevationInfo.d.ts +2 -2
  334. package/symbols/support/IconSymbol3DLayerResource.d.ts +1 -1
  335. package/symbols/support/defaults.js +1 -1
  336. package/symbols/support/defaults3D.js +1 -1
  337. package/symbols/support/previewSymbol3D.js +1 -1
  338. package/symbols/support/symbolLayerUtils3D.js +1 -1
  339. package/symbols/support/symbolUtils.js +1 -1
  340. package/symbols/support/utils.js +1 -1
  341. package/views/2d/analysis/ElevationProfile/ElevationProfileLineVisualization2D.js +1 -1
  342. package/views/2d/analysis/ElevationProfileAnalysisView2D.d.ts +16 -11
  343. package/views/2d/analysis/ElevationProfileAnalysisView2D.js +1 -1
  344. package/views/2d/engine/imagery/RasterVFDisplayObject.js +1 -1
  345. package/views/2d/engine/vectorTiles/VectorTile.js +1 -1
  346. package/views/2d/engine/vectorTiles/shaders/sources/shaderRepository.js +1 -1
  347. package/views/2d/engine/webgl/GlyphMosaic.js +1 -1
  348. package/views/2d/engine/webgl/GlyphSDFCreator.js +5 -0
  349. package/views/2d/engine/webgl/GlyphSource.js +1 -1
  350. package/views/2d/engine/webgl/TextureManager.js +1 -1
  351. package/views/2d/engine/webgl/TextureUploadManager.js +1 -1
  352. package/views/2d/engine/webgl/definitions.js +1 -1
  353. package/views/2d/engine/webgl/mesh/templates/shapingUtils.js +1 -1
  354. package/views/2d/engine/webgl/shaderGraph/techniques/labels/LabelMeshWriter.js +1 -1
  355. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/constants.js +1 -1
  356. package/views/2d/engine/webgl/shaderGraph/techniques/text/TextMeshWriter.js +1 -1
  357. package/views/2d/engine/webgl/shaderGraph/techniques/text/TextShader.js +1 -1
  358. package/views/2d/input/handlers/DoubleTapDragZoom.js +1 -1
  359. package/views/2d/input/handlers/KeyZoom.js +1 -1
  360. package/views/2d/layers/BaseLayerView2D.d.ts +3 -6
  361. package/views/2d/layers/BaseLayerViewGL2D.d.ts +3 -6
  362. package/views/2d/layers/FeatureLayerView2D.js +1 -1
  363. package/views/2d/layers/TileLayerView2D.js +1 -1
  364. package/views/2d/layers/features/sources/strategies/support/queryAdapters.js +1 -1
  365. package/views/2d/layers/features/support/FeatureSetReaderPBF.js +1 -1
  366. package/views/3d/analysis/AreaMeasurement/support/utils.js +1 -1
  367. package/views/3d/analysis/Dimension/lengthDimensionConstraintUtils.js +1 -1
  368. package/views/3d/analysis/ElevationProfile/ElevationProfileLineVisualization3D.js +1 -1
  369. package/views/3d/analysis/ElevationProfileAnalysisView3D.d.ts +16 -11
  370. package/views/3d/analysis/ElevationProfileAnalysisView3D.js +1 -1
  371. package/views/3d/analysis/Slice/sliceToolUtils.js +1 -1
  372. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillController.js +1 -1
  373. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementTool.js +1 -1
  374. package/views/3d/analysis/VolumeMeasurementAnalysisView3D.js +1 -1
  375. package/views/3d/camera/constraintUtils/tilt.js +1 -1
  376. package/views/3d/environment/CloudsParameters.js +1 -1
  377. package/views/3d/environment/CloudsRenderer.js +1 -1
  378. package/views/3d/environment/SceneViewEnvironment.js +1 -1
  379. package/views/3d/glTF/internal/Resource.js +1 -1
  380. package/views/3d/glTF/internal/fillDefaults.js +1 -1
  381. package/views/3d/interactive/Manipulator3D.js +1 -1
  382. package/views/3d/interactive/SnappingVisualizer3D.js +1 -1
  383. package/views/3d/interactive/editingTools/isSupportedObjectUtils.js +1 -1
  384. package/views/3d/interactive/editingTools/move/isSupportedObject.js +1 -1
  385. package/views/3d/interactive/editingTools/transform/isSupportedGraphic.js +1 -1
  386. package/views/3d/interactive/visualElements/ExtendedLineVisualElement.js +1 -1
  387. package/views/3d/layers/I3SMeshView3D.js +1 -1
  388. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  389. package/views/3d/layers/PointCloudLayerView3D.js +1 -1
  390. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  391. package/views/3d/layers/graphics/Graphics3DExtrudeSymbolLayer.js +1 -1
  392. package/views/3d/layers/graphics/Graphics3DFeatureProcessor.js +1 -1
  393. package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
  394. package/views/3d/layers/graphics/Graphics3DPathSymbolLayer.js +1 -1
  395. package/views/3d/layers/graphics/Graphics3DSymbolLayer.js +1 -1
  396. package/views/3d/layers/graphics/LabelInfo.js +1 -1
  397. package/views/3d/layers/graphics/defaultSymbolComplexity.js +1 -1
  398. package/views/3d/layers/graphics/lineUtils.js +1 -1
  399. package/views/3d/layers/graphics/pipeline/rendering/FeaturePipelineRenderManager.js +1 -1
  400. package/views/3d/layers/graphics/pipeline/symbolization/primitiveObjectUtils.js +1 -1
  401. package/views/3d/layers/graphics/primitiveObjectSymbolUtils.js +1 -1
  402. package/views/3d/layers/i3s/BuildingFilterUtil.js +1 -1
  403. package/views/3d/layers/i3s/I3SIntersectionHandler.js +1 -1
  404. package/views/3d/layers/i3s/I3SNode.js +1 -1
  405. package/views/3d/layers/i3s/I3SViewportQueries.js +1 -1
  406. package/views/3d/layers/i3s/PointCloudWorkerUtil.js +1 -1
  407. package/views/3d/layers/i3s/SphereCone.js +5 -0
  408. package/views/3d/layers/support/FastSymbolUpdates.js +1 -1
  409. package/views/3d/layers/support/edgeUtils.js +1 -1
  410. package/views/3d/layers/support/featureReference.js +1 -1
  411. package/views/3d/layers/support/featureTileQuery3D.js +1 -1
  412. package/views/3d/layers/support/patternUtils.js +1 -1
  413. package/views/3d/state/controllers/GamepadKeyboardController.js +1 -1
  414. package/views/3d/state/helpers/SceneIntersectionHelper.js +1 -1
  415. package/views/3d/support/FrustumExtentIntersection.js +1 -1
  416. package/views/3d/support/buffer/glUtil.js +1 -1
  417. package/views/3d/support/engineContent/sdfPrimitives.js +1 -1
  418. package/views/3d/support/viewpointUtils.js +1 -1
  419. package/views/3d/terrain/isTerrainSurfaceLayer.js +1 -1
  420. package/views/3d/webgl/RenderNode.js +1 -1
  421. package/views/3d/webgl-engine/collections/Component/ComponentObjectCollection.js +1 -1
  422. package/views/3d/webgl-engine/collections/Component/IntersectionGeometry.js +1 -1
  423. package/views/3d/webgl-engine/collections/Component/Material/ComponentData.glsl.js +8 -8
  424. package/views/3d/webgl-engine/collections/Component/Material/ComponentMaterial.js +1 -1
  425. package/views/3d/webgl-engine/core/shaderLibrary/TextureBackedBufferFields.glsl.js +3 -3
  426. package/views/3d/webgl-engine/core/shaderLibrary/attributes/NormalAttribute.glsl.js +4 -4
  427. package/views/3d/webgl-engine/core/shaderLibrary/attributes/TextureCoordinateAttribute.glsl.js +2 -2
  428. package/views/3d/webgl-engine/core/shaderLibrary/attributes/VertexNormal.glsl.js +2 -2
  429. package/views/3d/webgl-engine/core/shaderLibrary/shading/ComputeFragmentNormals.glsl.js +6 -6
  430. package/views/3d/webgl-engine/core/shaderLibrary/shading/EvaluateSceneLighting.glsl.js +1 -1
  431. package/views/3d/webgl-engine/core/shaderLibrary/shading/Normals.glsl.js +5 -5
  432. package/views/3d/webgl-engine/core/shaderLibrary/terrain/TileBackground.glsl.js +3 -3
  433. package/views/3d/webgl-engine/core/shaderLibrary/util/BlendModes.glsl.js +1 -1
  434. package/views/3d/webgl-engine/lib/ManagedTexture.js +1 -1
  435. package/views/3d/webgl-engine/lib/edgeRendering/EdgeProcessingWorker.js +1 -1
  436. package/views/3d/webgl-engine/lib/edgeRendering/EdgeWorkerHandle.js +1 -1
  437. package/views/3d/webgl-engine/materials/lineStippleUtils.js +1 -1
  438. package/views/3d/webgl-engine/shaders/CompositingTechnique.js +1 -1
  439. package/views/3d/webgl-engine/shaders/RibbonLineTechnique.js +1 -1
  440. package/views/3d/webgl-engine/shaders/sources/edgeRenderer/LineAmplitude.glsl.js +4 -4
  441. package/views/3d/webgl-engine/shaders/sources/edgeRenderer/LineOffset.glsl.js +8 -8
  442. package/views/VideoView.d.ts +2 -3
  443. package/views/VideoView.js +1 -1
  444. package/views/View2D.d.ts +2 -3
  445. package/views/analysis/ElevationProfile/ElevationProfileController.js +1 -1
  446. package/views/analysis/ElevationProfile/ElevationProfileIndicatorPointVisualization.js +5 -0
  447. package/views/analysis/ElevationProfile/ElevationProfileLineComputation.js +1 -1
  448. package/views/analysis/ElevationProfile/ElevationProfileResult.js +1 -1
  449. package/views/analysis/ElevationProfile/ElevationProfileTool.js +1 -1
  450. package/views/analysis/ElevationProfile/constants.js +1 -1
  451. package/views/draw/Draw.js +1 -1
  452. package/views/input/ViewEvents.js +1 -1
  453. package/views/interactive/editGeometry/EditGeometry.js +1 -1
  454. package/views/interactive/snapping/featureSources/snappingCandidateElevationAlignment.js +1 -1
  455. package/views/interactive/snapping/featureSources/snappingCandidateElevationFilter.js +1 -1
  456. package/views/interactive/snapping/featureSources/symbologySnappingCandidates.js +1 -1
  457. package/views/layers/MediaLayerViewMixin.d.ts +1 -1
  458. package/views/support/PromiseQueue.js +1 -1
  459. package/views/support/screenUtils.js +1 -1
  460. package/views/support/screenshotUtils.js +1 -1
  461. package/views/types.d.ts +1 -1
  462. package/views/webgl/FramebufferObject.js +1 -1
  463. package/views/webgl/Uniform.js +1 -1
  464. package/views/webgl/Util.js +1 -1
  465. package/webdoc/applicationProperties/SearchLayerField.d.ts +1 -1
  466. package/webdoc/applicationProperties/SearchTableField.d.ts +1 -1
  467. package/webscene/Slide.d.ts +2 -2
  468. package/webscene/spec-certification/api.js +1 -1
  469. package/widgets/BatchAttributeForm/batchAttributeFormUtils.js +1 -1
  470. package/widgets/BatchAttributeForm/inputs/FieldInput.d.ts +1 -1
  471. package/widgets/BatchAttributeForm/inputs/FieldInput.js +1 -1
  472. package/widgets/BatchAttributeForm/templates/support/hashElementTemplate.js +1 -1
  473. package/widgets/BatchAttributeForm.js +1 -1
  474. package/widgets/Editor/components/PendingFeatureList.js +1 -1
  475. package/widgets/Editor/components/workflowAdapters/pendingFeatureList/{CreateFeaturesWorkflowPendingFeatureListAdapter.ts.js → CreateFeaturesWorkflowPendingFeatureListAdapter.js} +1 -1
  476. package/widgets/Editor/types.d.ts +1 -1
  477. package/widgets/Editor/workflowUtils.js +1 -1
  478. package/widgets/Feature.d.ts +3 -5
  479. package/widgets/FeatureForm/FeatureFormViewModel.js +1 -1
  480. package/widgets/FeatureForm/FieldInput.d.ts +2 -2
  481. package/widgets/FeatureForm/featureFormUtils.js +1 -1
  482. package/widgets/FeatureForm.js +1 -1
  483. package/widgets/FeatureTemplates/FeatureTemplatesViewModel.d.ts +1 -1
  484. package/widgets/FeatureTemplates/TemplateItem.d.ts +1 -1
  485. package/widgets/FeatureTemplates/types.d.ts +1 -1
  486. package/widgets/Features.d.ts +3 -5
  487. package/widgets/Print/CustomTemplate.d.ts +3 -4
  488. package/widgets/Print/TemplateOptions.d.ts +3 -4
  489. package/widgets/Print/types.d.ts +3 -4
  490. package/widgets/ShadowCast/ShadowCastViewModel.js +1 -1
  491. package/widgets/Sketch/support/OperationHandle.js +1 -1
  492. package/widgets/TimeSlider.js +1 -1
  493. package/widgets/VideoPlayer/VideoPlayerViewModel.d.ts +1 -1
  494. package/widgets/support/SelectionList/GroupLayerItem.js +1 -1
  495. package/widgets/support/dateUtils.js +1 -1
  496. package/assets/esri/core/workers/chunks/0099f4729c94c779ba35.js +0 -1
  497. package/assets/esri/core/workers/chunks/058fb2cd6387acfd458c.js +0 -1
  498. package/assets/esri/core/workers/chunks/0ae018098906d6a88904.js +0 -1
  499. package/assets/esri/core/workers/chunks/0dc3a04ce717b7ddd957.js +0 -1
  500. package/assets/esri/core/workers/chunks/0e5cd0cf6ab7cb37d723.js +0 -1
  501. package/assets/esri/core/workers/chunks/0ee407b8db5c07a00d82.js +0 -1
  502. package/assets/esri/core/workers/chunks/10373885604655f673df.js +0 -1
  503. package/assets/esri/core/workers/chunks/13d61d34e55c80e4ecdf.js +0 -1
  504. package/assets/esri/core/workers/chunks/17dea03fc4eb414f0022.js +0 -1
  505. package/assets/esri/core/workers/chunks/1967239713b58dccfd81.js +0 -1
  506. package/assets/esri/core/workers/chunks/1ab98591d2f2bc604505.js +0 -1
  507. package/assets/esri/core/workers/chunks/1b838638e66e82d76cf3.js +0 -1
  508. package/assets/esri/core/workers/chunks/1c350a2c4014146dbcd9.js +0 -1
  509. package/assets/esri/core/workers/chunks/2266a8f2c2ec37c19bb4.js +0 -1
  510. package/assets/esri/core/workers/chunks/226acd251ad7d7ee3b57.js +0 -1
  511. package/assets/esri/core/workers/chunks/22b07c54a5fcc27771b0.js +0 -1
  512. package/assets/esri/core/workers/chunks/22ca80f491e070b2a5e7.js +0 -1
  513. package/assets/esri/core/workers/chunks/22dd5cecc7e2d4d0baf8.js +0 -316
  514. package/assets/esri/core/workers/chunks/2402d305a77fef4694a0.js +0 -1
  515. package/assets/esri/core/workers/chunks/27f096c434f049b8df01.js +0 -1
  516. package/assets/esri/core/workers/chunks/2a6231db5ee6cbfd59a5.js +0 -1
  517. package/assets/esri/core/workers/chunks/3371935a4fd6346d3a17.js +0 -1
  518. package/assets/esri/core/workers/chunks/3c4f8597f602779174f1.js +0 -1
  519. package/assets/esri/core/workers/chunks/3da53c017f9c5d2d778a.js +0 -1
  520. package/assets/esri/core/workers/chunks/45b898367b6224dda46f.js +0 -1
  521. package/assets/esri/core/workers/chunks/4785cd108e2dec6e1697.js +0 -1
  522. package/assets/esri/core/workers/chunks/4d6d962d25aa836f53ee.js +0 -1
  523. package/assets/esri/core/workers/chunks/4f33a2ecb154a2c2449c.js +0 -1
  524. package/assets/esri/core/workers/chunks/52726458f590e726d52c.js +0 -1
  525. package/assets/esri/core/workers/chunks/536c492fdda30f2f1288.js +0 -1
  526. package/assets/esri/core/workers/chunks/5909a0e763fddc3542e7.js +0 -2
  527. package/assets/esri/core/workers/chunks/5cee6c3ff23fb93f857a.js +0 -1
  528. package/assets/esri/core/workers/chunks/600e2e6b51e2fb9c598c.js +0 -1
  529. package/assets/esri/core/workers/chunks/6035daa65fc3ebf86515.js +0 -1
  530. package/assets/esri/core/workers/chunks/63b8cd7d5cafbaeed894.js +0 -1
  531. package/assets/esri/core/workers/chunks/6cb44cd319cb6c2539c8.js +0 -1
  532. package/assets/esri/core/workers/chunks/7033fa18b7dd7bd3e49c.js +0 -1
  533. package/assets/esri/core/workers/chunks/7306b5b66e738a281d83.js +0 -1
  534. package/assets/esri/core/workers/chunks/7694abe44d55dae8872d.js +0 -1
  535. package/assets/esri/core/workers/chunks/7f4fa2f2e85863d3cfb9.js +0 -1
  536. package/assets/esri/core/workers/chunks/8f4c480c418eba299c2b.js +0 -1
  537. package/assets/esri/core/workers/chunks/964de713042f52d71e42.js +0 -1
  538. package/assets/esri/core/workers/chunks/a3836f6a93924ee4816e.js +0 -1
  539. package/assets/esri/core/workers/chunks/ab520fd1ae917daf07d8.js +0 -1
  540. package/assets/esri/core/workers/chunks/acc7ff44bfcb5c195114.js +0 -1
  541. package/assets/esri/core/workers/chunks/ad92427bf597a6e0a299.js +0 -1
  542. package/assets/esri/core/workers/chunks/b25a131c04092c3ab75d.js +0 -1
  543. package/assets/esri/core/workers/chunks/b285de471ca90f38ec25.js +0 -1
  544. package/assets/esri/core/workers/chunks/b8f83a272fc41765031d.js +0 -1
  545. package/assets/esri/core/workers/chunks/b9909264cfea68d5f2a1.js +0 -1
  546. package/assets/esri/core/workers/chunks/bb08359610a41e304b55.js +0 -1
  547. package/assets/esri/core/workers/chunks/bcf612eabe7577540953.js +0 -1
  548. package/assets/esri/core/workers/chunks/bfbbcaa1fb04f17fc869.js +0 -1
  549. package/assets/esri/core/workers/chunks/c02b09f16241db233103.js +0 -1
  550. package/assets/esri/core/workers/chunks/c3007b916ba933137709.js +0 -1
  551. package/assets/esri/core/workers/chunks/cc5c1887e6d7079e5fe3.js +0 -1
  552. package/assets/esri/core/workers/chunks/ce8f075c814a8378c00c.js +0 -1
  553. package/assets/esri/core/workers/chunks/cfe1506a443fc84a0b91.js +0 -1
  554. package/assets/esri/core/workers/chunks/d30cfc5fa302cc08d862.js +0 -1
  555. package/assets/esri/core/workers/chunks/d723619579cc8f5ef2cd.js +0 -1
  556. package/assets/esri/core/workers/chunks/da99fd0d3106dd357743.js +0 -1
  557. package/assets/esri/core/workers/chunks/de71db3b0fb947b13c97.js +0 -1
  558. package/assets/esri/core/workers/chunks/dfbbead4c24d13682891.js +0 -1
  559. package/assets/esri/core/workers/chunks/e69255e38ff200dda14b.js +0 -1
  560. package/assets/esri/core/workers/chunks/e705d041f6c1632bfbcc.js +0 -1
  561. package/assets/esri/core/workers/chunks/e85da52d9cc7d9396872.js +0 -1
  562. package/assets/esri/core/workers/chunks/ee186ddbb1eb5144a790.js +0 -1
  563. package/assets/esri/core/workers/chunks/f9370830051865a3435b.js +0 -1
  564. package/core/MultiOriginJSONSupport.d.ts +0 -13
  565. package/core/NumericIdentifiable.d.ts +0 -6
  566. package/core/ReadOnlyMultiOriginJSONSupport.d.ts +0 -6
  567. package/core/WriteableMultiOriginJSONMixin.d.ts +0 -6
  568. package/layers/knowledgeGraph/KnowledgeGraphSublayerBase.d.ts +0 -6
  569. package/layers/mixins/ArcGISService.d.ts +0 -6
  570. package/layers/mixins/RasterJobHandlerMixin.d.ts +0 -6
  571. package/layers/support/RasterFunctionProperties.d.ts +0 -2
  572. package/layers/support/domains.d.ts +0 -5
  573. package/layers/support/editableLayers.d.ts +0 -11
  574. package/layers/support/exifUtils.d.ts +0 -21
  575. package/layers/support/fieldFormatUtils.d.ts +0 -4
  576. package/layers/support/fieldType.d.ts +0 -2
  577. package/layers/support/layerUtils.d.ts +0 -4
  578. package/layers/support/wmtsUtils.d.ts +0 -2
  579. package/layers/video/videoUtils.d.ts +0 -5
  580. package/rest/geometryService/cut.d.ts +0 -7
  581. package/rest/geometryService/fromGeoCoordinateString.d.ts +0 -28
  582. package/rest/geometryService/toGeoCoordinateString.d.ts +0 -25
  583. package/rest/operations/generalize.d.ts +0 -3
  584. package/rest/support/DateBinUtils.d.ts +0 -2
  585. package/rest/support/colorRamps.d.ts +0 -6
  586. package/rest/support/fileFormat.d.ts +0 -4
  587. package/rest/support/layoutTemplate.d.ts +0 -2
  588. package/rest/support/reportTemplate.d.ts +0 -2
  589. package/views/2d/layers/LayerView2D.d.ts +0 -6
  590. package/views/Viewport2DBaseMixin.d.ts +0 -6
  591. package/views/analysis/ElevationProfile/ElevationProfileHoveredPointVisualization.js +0 -5
  592. package/views/layers/RefreshableLayerView.d.ts +0 -6
  593. package/widgets/Feature/support/FeatureContentMixin.d.ts +0 -6
  594. /package/layers/video/{IVideoController.d.ts → types.d.ts} +0 -0
  595. /package/layers/{support/wmsUtils.d.ts → wms/types.d.ts} +0 -0
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import e from"../../../core/Accessor.js";import{min as o}from"../../../core/arrayUtils.js";import{createTask as i}from"../../../core/asyncUtils.js";import{dedupeResult as s}from"../../../core/dedupeResult.js";import{makeHandle as r}from"../../../core/handleUtils.js";import{equalsShallow as a}from"../../../core/lang.js";import{LRUCache as n}from"../../../core/LRUCache.js";import{mapCollection as l}from"../../../core/mapCollectionUtils.js";import{destroyMaybe as p,abortMaybe as u,equalsMaybe as m}from"../../../core/maybe.js";import{throwIfAborted as c,throwIfAbortError as h}from"../../../core/promiseUtils.js";import{watch as _,syncAndInitial as d,on as f}from"../../../core/reactiveUtils.js";import{throttle as v}from"../../../core/throttle.js";import{adaptiveVerticalLengthUnit as y,adaptiveLengthUnit as g}from"../../../core/units.js";import{property as C,subclass as P}from"../../../core/accessorSupport/decorators.js";import{ElevationQueryTileCache as T}from"../../../layers/support/ElevationQueryTileCache.js";import{absoluteHeightElevationInfo as j}from"../../../support/elevationInfoUtils.js";import{getDefaultUnitForView as U}from"../../../support/getDefaultUnitForView.js";import b from"../../../symbols/support/ElevationInfo.js";import{getConfig as w}from"./constants.js";import R from"./ElevationProfileError.js";import{InvalidGeometryError as I,UnknownError as S}from"./elevationProfileErrors.js";import{createProfileQueue as E,sanitizeProgress as D,generateProfiles as q}from"./elevationProfileGenerationUtils.js";import{mergeStatistics as x,getBoundsInMeters as O}from"./elevationProfileStatisticsUtils.js";let k=class extends e{constructor(t){super(t),this.error=null,this._getStableEffectiveUnits=s(()=>{const t=O(this._activeComputations.map(t=>t.result.rawResult)),e=this.analysis.displayUnits,o=U(this.view);return{distance:g(t.maxDistance,"meters",e.distance??o),elevation:y(t.maxElevation,"meters",e.elevation??o)}},a),this._updateTask=null,this._queue=null,this._currentTileCache=null,this._parametersPerComputation=new Map,this._getStableUpdateParameters=s(()=>({stationary:this.view.stationary??!0,activeComputations:this._activeComputations,generationParameters:this._generationParameters}),a),this._getStableGenerationParameters=s(()=>{const{view:t,analysis:e}=this;return t?.ready&&this._queue?{view:t,geometry:e.geometry,geometryIsValid:e.valid,elevationInfo:this.elevationInfo,queue:this._queue,cache:this._tileCache,options:this._options,slicePlane:"3d"===t.type?t.slice.plane:null}:null},a),this._getStableElevationInfo=s(()=>this.analysis.elevationInfo??V,m),this._getStableOptions=s(()=>{const{densificationMaxSamples:t,defaultDemResolution:e,maxTotalSamples:o}=w();let i=this._minDemResolution??e;return i=parseFloat(i.toFixed(2)),{samplingDistance:i,densificationMaxSamples:Math.round(t/this._activeComputations.length),maxTotalSamples:o}},a),this._updateThrottled=v(t=>this._update(t),w().updateThrottleMillis)}initialize(){this._computationsCollection=l(()=>this.analysis.profiles,t=>this.computationFactory.create({controller:this,profile:t,onInvalidate:t=>this._invalidateComputation(t)}),{recycleItems:!0}),this.addHandles([this._computationsCollection.on("change",()=>{this._parametersPerComputation.clear(),this._updateThrottled(this._updateParameters)}),_(()=>this._updateParameters,t=>this._updateThrottled(t),d),this._updateThrottled]);const t="3d"===this.view.type?this.view.resourceController:void 0;this._queue=E(t?.scheduler),t?.addUpdatingObject(this)}destroy(){this._abortUpdate(),this._parametersPerComputation.clear(),this._computationsCollection?.destroy(),this._queue=p(this._queue),this._currentTileCache=p(this._currentTileCache)}get effectiveDisplayUnits(){return this._getStableEffectiveUnits()}get progress(){let t=0,e=0;for(const o of this._activeComputations)t++,e+=o.progress;return D(t>0?e/t:0)}get updating(){const{progress:t}=this,e=!!this._queue?.updating,o=this._updateThrottled.hasPendingUpdates(),i=null!=this._updateTask&&!this._updateTask.finished;return e||o||i||t>0&&t<1}get results(){return this._computations.map(t=>t.result)}get statistics(){return x(this._activeComputations.map(t=>t.result.statistics))}get hoveredPoints(){return this._computations.map(t=>t.hoveredPoint)}onElevationChange(t){const{view:e}=this;return"3d"===e?.type?f(()=>e.elevationProvider,"elevation-change",t,{onListenerAdd:t,onListenerRemove:t}):r()}get _tileCache(){this._currentTileCache=p(this._currentTileCache);const t=this.view;if("3d"===t?.type){const e=t.basemapTerrain?.elevationQueryCache;if(null!=e)return e}return null==this._currentTileCache&&(this._currentTileCache=new T(new n(20971520))),this._currentTileCache}get _computations(){return this._computationsCollection?.toArray()??[]}get _activeComputations(){return this._computations.filter(t=>t.profile.enabled&&t.available)}get _minDemResolution(){const t=this._minDemResolutions;return t.length>0?o(t):null}get _minDemResolutions(){const t=[];for(const{minDemResolution:e}of this._activeComputations)null!=e&&t.push(e);return t}get _updateParameters(){return this._getStableUpdateParameters()}get _generationParameters(){return this._getStableGenerationParameters()}get elevationInfo(){return this._getStableElevationInfo()}get _options(){return this._getStableOptions()}_update({stationary:t,activeComputations:e,generationParameters:o}){this._abortUpdate(),t&&(null!=o?this._updateTask=i(async t=>{this.error=null;const i=e.filter(t=>!this._isComputationValid(t,o));try{if(!o.geometryIsValid)throw new I;const e=q({...o,providers:i},{signal:t});let s=!1;for await(const r of e){c(t),s||(this._clearInvalidResults(o),s=!0);for(let t=0;t<i.length;t++)i[t].setResult(r[t])}for(const t of i)this._parametersPerComputation.set(t,o)}catch(s){h(s),this._abortUpdate(),this.error=s instanceof R?s:s instanceof I?null:new S,i.forEach(t=>t.clearResult())}}):this._clearResults())}_abortUpdate(){this._updateTask=u(this._updateTask)}_isComputationValid(t,e){return this._parametersPerComputation.has(t)&&this._parametersPerComputation.get(t)===e}_invalidateComputation(t){this._parametersPerComputation.delete(t),this._updateThrottled(this._updateParameters)}_clearInvalidResults(t){for(const e of this._computations)this._isComputationValid(e,t)||(e.clearResult(),this._parametersPerComputation.delete(e))}_clearResults(){for(const t of this._computations)t.clearResult(),this._parametersPerComputation.delete(t)}};t([C({constructOnly:!0})],k.prototype,"analysis",void 0),t([C({constructOnly:!0})],k.prototype,"analysisViewData",void 0),t([C({constructOnly:!0})],k.prototype,"computationFactory",void 0),t([C({constructOnly:!0})],k.prototype,"view",void 0),t([C()],k.prototype,"error",void 0),t([C({readOnly:!0})],k.prototype,"effectiveDisplayUnits",null),t([C()],k.prototype,"progress",null),t([C()],k.prototype,"updating",null),t([C()],k.prototype,"results",null),t([C()],k.prototype,"statistics",null),t([C()],k.prototype,"hoveredPoints",null),t([C()],k.prototype,"_updateTask",void 0),t([C()],k.prototype,"_queue",void 0),t([C()],k.prototype,"_tileCache",null),t([C()],k.prototype,"_computationsCollection",void 0),t([C()],k.prototype,"_computations",null),t([C()],k.prototype,"_activeComputations",null),t([C({readOnly:!0})],k.prototype,"_minDemResolution",null),t([C()],k.prototype,"_minDemResolutions",null),t([C()],k.prototype,"_updateParameters",null),t([C()],k.prototype,"_generationParameters",null),t([C()],k.prototype,"elevationInfo",null),t([C()],k.prototype,"_options",null),k=t([P("esri.views.analysis.ElevationProfile.ElevationProfileController")],k);const V=new b({...j});export{k as ElevationProfileController};
5
+ import{__decorate as t}from"tslib";import e from"../../../core/Accessor.js";import{min as o}from"../../../core/arrayUtils.js";import{createTask as i}from"../../../core/asyncUtils.js";import{dedupeResult as s}from"../../../core/dedupeResult.js";import{makeHandle as r}from"../../../core/handleUtils.js";import{equalsShallow as a}from"../../../core/lang.js";import{LRUCache as n}from"../../../core/LRUCache.js";import{mapCollection as l}from"../../../core/mapCollectionUtils.js";import{destroyMaybe as p,abortMaybe as u,equalsMaybe as c}from"../../../core/maybe.js";import{throwIfAborted as m,throwIfAbortError as h}from"../../../core/promiseUtils.js";import{watch as _,syncAndInitial as d,on as f}from"../../../core/reactiveUtils.js";import{throttle as v}from"../../../core/throttle.js";import{adaptiveVerticalLengthUnit as y,adaptiveLengthUnit as g}from"../../../core/units.js";import{property as C,subclass as P}from"../../../core/accessorSupport/decorators.js";import{ElevationQueryTileCache as T}from"../../../layers/support/ElevationQueryTileCache.js";import{absoluteHeightElevationInfo as j}from"../../../support/elevationInfoUtils.js";import{getDefaultUnitForView as U}from"../../../support/getDefaultUnitForView.js";import b from"../../../symbols/support/ElevationInfo.js";import{getConfig as w}from"./constants.js";import R from"./ElevationProfileError.js";import{InvalidGeometryError as I,UnknownError as S}from"./elevationProfileErrors.js";import{createProfileQueue as E,sanitizeProgress as D,generateProfiles as q}from"./elevationProfileGenerationUtils.js";import{mergeStatistics as x,getBoundsInMeters as O}from"./elevationProfileStatisticsUtils.js";let k=class extends e{constructor(t){super(t),this.error=null,this._getStableEffectiveUnits=s(()=>{const t=O(this._activeComputations.map(t=>t.result.rawResult)),e=this.analysis.displayUnits,o=U(this.view);return{distance:g(t.maxDistance,"meters",e.distance??o),elevation:y(t.maxElevation,"meters",e.elevation??o)}},a),this._updateTask=null,this._queue=null,this._currentTileCache=null,this._parametersPerComputation=new Map,this._getStableUpdateParameters=s(()=>({stationary:this.view.stationary??!0,activeComputations:this._activeComputations,generationParameters:this._generationParameters}),a),this._getStableGenerationParameters=s(()=>{const{view:t,analysis:e}=this;return t?.ready&&this._queue?{view:t,geometry:e.geometry,geometryIsValid:e.valid,elevationInfo:this.elevationInfo,queue:this._queue,cache:this._tileCache,options:this._options,slicePlane:"3d"===t.type?t.slice.plane:null}:null},a),this._getStableElevationInfo=s(()=>this.analysis.elevationInfo??V,c),this._getStableOptions=s(()=>{const{densificationMaxSamples:t,defaultDemResolution:e,maxTotalSamples:o}=w();let i=this._minDemResolution??e;return i=parseFloat(i.toFixed(2)),{samplingDistance:i,densificationMaxSamples:Math.round(t/this._activeComputations.length),maxTotalSamples:o}},a),this._updateThrottled=v(t=>this._update(t),w().updateThrottleMillis)}initialize(){this._computationsCollection=l(()=>this.analysis.profiles,t=>this.computationFactory.create({controller:this,profile:t,onInvalidate:t=>this._invalidateComputation(t)}),{recycleItems:!0}),this.addHandles([this._computationsCollection.on("change",()=>{this._parametersPerComputation.clear(),this._updateThrottled(this._updateParameters)}),_(()=>this._updateParameters,t=>this._updateThrottled(t),d),this._updateThrottled]);const t="3d"===this.view.type?this.view.resourceController:void 0;this._queue=E(t?.scheduler),t?.addUpdatingObject(this)}destroy(){this._abortUpdate(),this._parametersPerComputation.clear(),this._computationsCollection?.destroy(),this._queue=p(this._queue),this._currentTileCache=p(this._currentTileCache)}get effectiveDisplayUnits(){return this._getStableEffectiveUnits()}get progress(){let t=0,e=0;for(const o of this._activeComputations)t++,e+=o.progress;return D(t>0?e/t:0)}get updating(){const{progress:t}=this,e=!!this._queue?.updating,o=this._updateThrottled.hasPendingUpdates(),i=null!=this._updateTask&&!this._updateTask.finished;return e||o||i||t>0&&t<1}get results(){return this._computations.map(t=>t.result)}get statistics(){return x(this._activeComputations.map(t=>t.result.statistics))}get indicatorPoints(){return this._computations.map(t=>t.indicatorPoint)}onElevationChange(t){const{view:e}=this;return"3d"===e?.type?f(()=>e.elevationProvider,"elevation-change",t,{onListenerAdd:t,onListenerRemove:t}):r()}get _tileCache(){this._currentTileCache=p(this._currentTileCache);const t=this.view;if("3d"===t?.type){const e=t.basemapTerrain?.elevationQueryCache;if(null!=e)return e}return null==this._currentTileCache&&(this._currentTileCache=new T(new n(20971520))),this._currentTileCache}get _computations(){return this._computationsCollection?.toArray()??[]}get _activeComputations(){return this._computations.filter(t=>t.profile.enabled&&t.available)}get _minDemResolution(){const t=this._minDemResolutions;return t.length>0?o(t):null}get _minDemResolutions(){const t=[];for(const{minDemResolution:e}of this._activeComputations)null!=e&&t.push(e);return t}get _updateParameters(){return this._getStableUpdateParameters()}get _generationParameters(){return this._getStableGenerationParameters()}get elevationInfo(){return this._getStableElevationInfo()}get _options(){return this._getStableOptions()}_update({stationary:t,activeComputations:e,generationParameters:o}){this._abortUpdate(),t&&(null!=o?this._updateTask=i(async t=>{this.error=null;const i=e.filter(t=>!this._isComputationValid(t,o));try{if(!o.geometryIsValid)throw new I;const e=q({...o,providers:i},{signal:t});let s=!1;for await(const r of e){m(t),s||(this._clearInvalidResults(o),s=!0);for(let t=0;t<i.length;t++)i[t].setResult(r[t])}for(const t of i)this._parametersPerComputation.set(t,o)}catch(s){h(s),this._abortUpdate(),this.error=s instanceof R?s:s instanceof I?null:new S,i.forEach(t=>t.clearResult())}}):this._clearResults())}_abortUpdate(){this._updateTask=u(this._updateTask)}_isComputationValid(t,e){return this._parametersPerComputation.has(t)&&this._parametersPerComputation.get(t)===e}_invalidateComputation(t){this._parametersPerComputation.delete(t),this._updateThrottled(this._updateParameters)}_clearInvalidResults(t){for(const e of this._computations)this._isComputationValid(e,t)||(e.clearResult(),this._parametersPerComputation.delete(e))}_clearResults(){for(const t of this._computations)t.clearResult(),this._parametersPerComputation.delete(t)}};t([C({constructOnly:!0})],k.prototype,"analysis",void 0),t([C({constructOnly:!0})],k.prototype,"analysisViewData",void 0),t([C({constructOnly:!0})],k.prototype,"computationFactory",void 0),t([C({constructOnly:!0})],k.prototype,"view",void 0),t([C()],k.prototype,"error",void 0),t([C({readOnly:!0})],k.prototype,"effectiveDisplayUnits",null),t([C()],k.prototype,"progress",null),t([C()],k.prototype,"updating",null),t([C()],k.prototype,"results",null),t([C()],k.prototype,"statistics",null),t([C()],k.prototype,"indicatorPoints",null),t([C()],k.prototype,"_updateTask",void 0),t([C()],k.prototype,"_queue",void 0),t([C()],k.prototype,"_tileCache",null),t([C()],k.prototype,"_computationsCollection",void 0),t([C()],k.prototype,"_computations",null),t([C()],k.prototype,"_activeComputations",null),t([C({readOnly:!0})],k.prototype,"_minDemResolution",null),t([C()],k.prototype,"_minDemResolutions",null),t([C()],k.prototype,"_updateParameters",null),t([C()],k.prototype,"_generationParameters",null),t([C()],k.prototype,"elevationInfo",null),t([C()],k.prototype,"_options",null),k=t([P("esri.views.analysis.ElevationProfile.ElevationProfileController")],k);const V=new b({...j});export{k as ElevationProfileController};
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
+ */
5
+ import{__decorate as t}from"tslib";import e from"../../../core/Accessor.js";import{watch as o,syncAndInitial as i}from"../../../core/reactiveUtils.js";import{property as r,subclass as s}from"../../../core/accessorSupport/decorators.js";import{projectOrLoad as n}from"../../../geometry/projectionUtils.js";import{getConfig as l}from"./constants.js";let a=class extends e{constructor(t){super(t),this.visible=!1,this._element=p()}initialize(){this.view.surface?.appendChild(this._element),this.addHandles([o(()=>this.visible&&!!this._screenPoint,t=>{this._element.style.display=t?"block":"none"},i),o(()=>({color:this.line.color.toCss(),zIndex:this._zIndex}),({color:t,zIndex:e})=>{Object.assign(this._element.style,{background:t,zIndex:e.toString()})},i),o(()=>this._screenPoint,t=>{t&&(this._element.style.transform=`translate(${t.x}px, ${t.y}px)`)},i)])}destroy(){this._element.remove()}get updating(){return!1}get _result(){return this.analysisViewData.results.find(t=>t.computation.profile===this.line)}get _zIndex(){const{profiles:t}=this.analysisViewData.analysis,e=t.indexOf(this.line);return t.length-(-1===e?0:e)}get _screenPoint(){const{view:t}=this;"3d"===t.type?(t.commitProperty("size"),t.commitProperty("camera")):t.commitProperty("center");const e=t?.spatialReference,o=e?n(this._result?.indicatorPoint,e).geometry:null;return o&&t?.ready?t.toScreen(o):null}};function p(){const t=document.createElement("div"),{size:e,borderStyle:o,borderColor:i,borderWidth:r,boxShadow:s}=l().indicatorPointStyle,{style:n}=t;return n.display="block",n.position="absolute",n.top="0",n.left="0",n.contain="strict",n.boxSizing="border-box",n.width=`${e}px`,n.height=`${e}px`,n.marginTop=`-${e/2}px`,n.marginLeft=`-${e/2}px`,n.border=`${o} ${r}px ${i}`,n.borderRadius=`${e}px`,n.boxShadow=s,t}t([r()],a.prototype,"view",void 0),t([r()],a.prototype,"analysisViewData",void 0),t([r()],a.prototype,"line",void 0),t([r()],a.prototype,"visible",void 0),t([r()],a.prototype,"updating",null),t([r()],a.prototype,"_result",null),t([r()],a.prototype,"_zIndex",null),t([r()],a.prototype,"_screenPoint",null),a=t([s("esri.views.analysis.ElevationProfile.ElevationProfileIndicatorPointVisualization")],a);export{a as ElevationProfileIndicatorPointVisualization};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import e from"../../../core/Accessor.js";import{watch as o,sync as r}from"../../../core/reactiveUtils.js";import{property as s,subclass as i}from"../../../core/accessorSupport/decorators.js";import{getConfig as l}from"./constants.js";import n from"./ElevationProfileResult.js";let p=class extends e{constructor(t){super(t),this.result=new n({computation:this}),this.numSamplesForPreview=30,this.numSamplesPerChunk=200}initialize(){this.addHandles([o(()=>{const{geometry:t,elevationInfo:e}=this.controller.analysis;return[t,e]},()=>this.onInvalidate(this),r)])}setResult(t){this.result.rawResult=t}clearResult(){this.setResult(null)}get progress(){return this.result.progress}get hoveredPoint(){return this.result.hoveredPoint}get available(){return!0}get minDemResolution(){return l().defaultDemResolution}};t([s({constructOnly:!0})],p.prototype,"controller",void 0),t([s({constructOnly:!0})],p.prototype,"profile",void 0),t([s({constructOnly:!0})],p.prototype,"onInvalidate",void 0),t([s()],p.prototype,"result",void 0),t([s({readOnly:!0})],p.prototype,"progress",null),t([s()],p.prototype,"hoveredPoint",null),t([s()],p.prototype,"available",null),t([s()],p.prototype,"numSamplesForPreview",void 0),t([s()],p.prototype,"numSamplesPerChunk",void 0),t([s({readOnly:!0})],p.prototype,"minDemResolution",null),p=t([i("esri.views.analysis.ElevationProfile.ElevationProfileLineComputation")],p);export{p as ElevationProfileLineComputation};
5
+ import{__decorate as t}from"tslib";import o from"../../../core/Accessor.js";import{watch as e,sync as r}from"../../../core/reactiveUtils.js";import{property as s,subclass as i}from"../../../core/accessorSupport/decorators.js";import{getConfig as l}from"./constants.js";import n from"./ElevationProfileResult.js";let a=class extends o{constructor(t){super(t),this.result=new n({computation:this}),this.numSamplesForPreview=30,this.numSamplesPerChunk=200}initialize(){this.addHandles([e(()=>{const{geometry:t,elevationInfo:o}=this.controller.analysis;return[t,o]},()=>this.onInvalidate(this),r)])}setResult(t){this.result.rawResult=t}clearResult(){this.setResult(null)}get progress(){return this.result.progress}get indicatorPoint(){return this.result.indicatorPoint}get available(){return!0}get minDemResolution(){return l().defaultDemResolution}};t([s({constructOnly:!0})],a.prototype,"controller",void 0),t([s({constructOnly:!0})],a.prototype,"profile",void 0),t([s({constructOnly:!0})],a.prototype,"onInvalidate",void 0),t([s()],a.prototype,"result",void 0),t([s({readOnly:!0})],a.prototype,"progress",null),t([s()],a.prototype,"indicatorPoint",null),t([s()],a.prototype,"available",null),t([s()],a.prototype,"numSamplesForPreview",void 0),t([s()],a.prototype,"numSamplesPerChunk",void 0),t([s({readOnly:!0})],a.prototype,"minDemResolution",null),a=t([i("esri.views.analysis.ElevationProfile.ElevationProfileLineComputation")],a);export{a as ElevationProfileLineComputation};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import{Clonable as e}from"../../../core/Clonable.js";import{memoize as o}from"../../../core/memoize.js";import{property as l,subclass as r}from"../../../core/accessorSupport/decorators.js";import i from"../../../geometry/Point.js";import{sanitizeProgress as s,binaryFindClosest as n}from"./elevationProfileGenerationUtils.js";import{convertSamples as a,convertStatistics as p}from"./elevationProfileUnitUtils.js";let u=class extends e{constructor(t){super(t),this._getSamplesMemoized=o((t,e)=>a(t,e)),this._getStatisticsMemoized=o((t,e)=>p(t,e)),this.rawResult=null}get available(){const{computation:t}=this;return t.profile.enabled&&t.available}get profile(){return this.computation.profile}get progress(){return s(null!=this.rawResult&&this.computation.profile.enabled?this.rawResult.progress:0)}get samples(){return this._getSamplesMemoized(this.rawResult,this.computation.controller.effectiveDisplayUnits)}get statistics(){return this._getStatisticsMemoized(this.rawResult,this.computation.controller.effectiveDisplayUnits)}get hoveredPoint(){if(!this.computation.profile.enabled)return null;const t=this.computation.controller.analysisViewData.hoveredPosition;if(null==t)return null;const{rawResult:e,samples:o}=this;if(null==o||null==e)return null;const l=o.length;if(0===l)return null;const r=o[l-1].distance,s=n(o,t*r,t=>t.distance);if(null==s)return null;const{x:a,y:p,z:u}=s;return null==u?null:new i({x:a,y:p,z:u,spatialReference:e.spatialReference})}};t([l()],u.prototype,"available",null),t([l({readOnly:!0})],u.prototype,"profile",null),t([l({readOnly:!0})],u.prototype,"progress",null),t([l()],u.prototype,"samples",null),t([l()],u.prototype,"statistics",null),t([l({constructOnly:!0})],u.prototype,"computation",void 0),t([l()],u.prototype,"rawResult",void 0),t([l()],u.prototype,"hoveredPoint",null),u=t([r("esri.views.analysis.ElevationProfile.ElevationProfileResult")],u);export{u as default};
5
+ import{__decorate as t}from"tslib";import{Clonable as e}from"../../../core/Clonable.js";import{memoize as o}from"../../../core/memoize.js";import{property as i,subclass as l}from"../../../core/accessorSupport/decorators.js";import r from"../../../geometry/Point.js";import{sanitizeProgress as s,binaryFindClosest as n}from"./elevationProfileGenerationUtils.js";import{convertSamples as a,convertStatistics as p}from"./elevationProfileUnitUtils.js";let u=class extends e{constructor(t){super(t),this._getSamplesMemoized=o((t,e)=>a(t,e)),this._getStatisticsMemoized=o((t,e)=>p(t,e)),this.rawResult=null}get available(){const{computation:t}=this;return t.profile.enabled&&t.available}get profile(){return this.computation.profile}get progress(){return s(null!=this.rawResult&&this.computation.profile.enabled?this.rawResult.progress:0)}get samples(){return this._getSamplesMemoized(this.rawResult,this.computation.controller.effectiveDisplayUnits)}get statistics(){return this._getStatisticsMemoized(this.rawResult,this.computation.controller.effectiveDisplayUnits)}get indicatorPoint(){if(!this.computation.profile.enabled)return null;const t=this.computation.controller.analysisViewData.indicatorRelativePosition;if(null==t)return null;const{rawResult:e,samples:o}=this;if(null==o||null==e)return null;const i=o.length;if(0===i)return null;const l=o[i-1].distance,s=n(o,t*l,t=>t.distance);if(null==s)return null;const{x:a,y:p,z:u}=s;return null==u?null:new r({x:a,y:p,z:u,spatialReference:e.spatialReference})}};t([i()],u.prototype,"available",null),t([i({readOnly:!0})],u.prototype,"profile",null),t([i({readOnly:!0})],u.prototype,"progress",null),t([i()],u.prototype,"samples",null),t([i()],u.prototype,"statistics",null),t([i({constructOnly:!0})],u.prototype,"computation",void 0),t([i()],u.prototype,"rawResult",void 0),t([i()],u.prototype,"indicatorPoint",null),u=t([l("esri.views.analysis.ElevationProfile.ElevationProfileResult")],u);export{u as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import t from"../../../Graphic.js";import i from"../../../core/Accessor.js";import{createTask as s}from"../../../core/asyncUtils.js";import a from"../../../core/Collection.js";import"../../../core/has.js";import{makeHandle as r}from"../../../core/handleUtils.js";import{destroyMaybe as o}from"../../../core/maybe.js";import{ignoreAbortErrors as n,isAborted as l,throwIfAborted as h}from"../../../core/promiseUtils.js";import{watch as c,syncAndInitial as p}from"../../../core/reactiveUtils.js";import{property as y,subclass as d}from"../../../core/accessorSupport/decorators.js";import{UpdatingHandles as m}from"../../../core/support/UpdatingHandles.js";import u from"../../../layers/GraphicsLayer.js";import g from"../../../symbols/CIMSymbol.js";import _ from"../../../symbols/SimpleLineSymbol.js";import k from"../../../symbols/support/ElevationInfo.js";import{ExclusiveOperationManager as f}from"../ExclusiveOperationManager.js";import{isPolyline as v,isValidInputGraphic as b,isInternalGraphic as w}from"./elevationProfileGeometryUtils.js";import{ViewEventPriorities as G}from"../../input/InputManager.js";import{isCancelEvent as S}from"../../interactive/interactiveToolUtils.js";import{makeAllLayerSnappingOptions as M}from"../../interactive/snapping/allLayerSnapping.js";import j from"../../../widgets/Sketch/SketchViewModel.js";let L=class extends i{constructor(e){super(e),this._sketchViewModels=new a,this._updatingHandles=new m,this._operationManager=new f}initialize(){const{view:e}=this;this._allLayerSnappingOptions=M(this.view,{selfEnabled:!0,excludeInternal:!0}),this._graphicsLayer=new u({listMode:"hide",internal:!0}),this.addHandles([c(()=>({map:e.map,internalGraphicsLayer:this._graphicsLayer,state:this.state,geometryVisualizationVisible:this._analysis.viewOptions.geometryVisualizationVisible,visible:this.analysisViewData.visible}),({map:e,internalGraphicsLayer:t,state:i,geometryVisualizationVisible:s,visible:a})=>{O(e,t);const r=this.sketchGraphic;switch(r&&(r.visible=a),i){case"idle":case"reshaping-disabled":r&&!s&&(r.visible=!1),this._operationManager.stop(),this._ensureUpdatedSketchGraphic();break;case"reshaping":n(this._startReshape());break;case"awaiting-sketch":this.analysisViewData.interactive=!0}},p),c(()=>this._analysis.elevationInfo,e=>{this._graphicsLayer.elevationInfo=e},p),this._allLayerSnappingOptions])}destroy(){this._operationManager.destroy(),this._sketchViewModels.drain(e=>o(e));const e=this._graphicsLayer;this.view.map?.remove(e),e.destroy()}get sketchGraphic(){return this._get("sketchGraphic")}set sketchGraphic(e){e!==this._get("sketchGraphic")&&(this._set("sketchGraphic",e),this._updateAnalysisFromSketchGraphic())}get state(){const{visible:e,interactive:t}=this.analysisViewData;if(!e)return"idle";switch(this._operationManager.currentOperationType){case"place":return this._sketching?"sketching":"awaiting-sketch";case"pick-feature":return"picking";default:return this._analysis.geometry?t?"reshaping":"reshaping-disabled":"idle"}}get updating(){return this._sketchViewModels.some(e=>e.updating)||this._updatingHandles.updating}get _sketching(){return this._sketchViewModels.some(e=>e.createGraphic===this.sketchGraphic)}get _analysis(){return this.analysisViewData.analysis}get _lineSymbol(){return V(this.view.type)}place(e){return this._operationManager.start("place",async t=>{const i=this._createSketchViewModel(),s=this._analysis.clone();this._ensureUpdatedSketchGraphic();const a=this.sketchGraphic,o=this._analysis.elevationInfo,h=r(()=>{this.sketchGraphic===a&&(this._graphicsLayer.elevationInfo=o)}),c=i.on("create",e=>{switch(e.state){case"start":this._graphicsLayer.removeAll(),this.sketchGraphic=e.graphic,this._analysis.elevationInfo=this._graphicsLayer.elevationInfo;break;case"active":this._updateAnalysisFromSketchGraphic();break;case"complete":this.sketchGraphic&&(this._updateAnalysisFromSketchGraphic(),this._addSketchGraphic(this.sketchGraphic)),t.stop();break;case"cancel":t.stop()}});t.handles.push(c,r(()=>(c.remove(),i.destroy(),this._sketchViewModels.remove(i),this._updateAnalysisFromSketchGraphic(),this._analysis.valid?l(e)||s.equals(this._analysis)?t.reject():void t.resolve({}):(this._clear(),t.reject()))),h),this._graphicsLayer.elevationInfo=I,await this._updatingHandles.addPromise(n(i.create("polyline")))},e)}async pickFeature(e){return this._operationManager.start("pick-feature",async e=>{const{view:t}=this;t.closePopup();let i=null;const a=a=>{a.defer(async()=>{i?.abort(),i=s(async i=>{const{results:s}=await t.hitTest(a);h(i);let r=null;for(const e of s)if("graphic"===e.type&&b(e.graphic)&&!w(e.graphic)){r=e.graphic;break}r&&(a.preventDefault(),a.stopPropagation(),this.sketchGraphic=null,this._analysis.setGeometryFromFeature(r),e.resolve({feature:r}),e.stop())}),await i.promise})},o=t=>{S(t)&&(e.reject(),e.stop())};e.handles.push(t.on("immediate-click",a,G.TOOL),t.on("key-down",o,G.TOOL),t.acquireCursor("crosshair","high"),r(()=>{i?.abort(),e.reject()})),t.focus()},e)}_startReshape(){const e=this._createSketchViewModel();return this._sketchViewModels.add(e),this._operationManager.start("reshape",async t=>{const i=()=>{const t=this._ensureUpdatedSketchGraphic();return t?this._updatingHandles.addPromise(e.update(t,{tool:"reshape"})):Promise.resolve()};if(!this._ensureUpdatedSketchGraphic())return;const s=e.on("update",e=>{this._updateAnalysisFromSketchGraphic(),"complete"===e.state&&("reshaping"===this.state?n(i()):t.resolve())});t.handles.push(s,r(()=>{s.remove(),this._sketchViewModels.remove(e),e.destroy(),t.resolve()})),await i()})}_createSketchViewModel(){return new j({layer:this._graphicsLayer,view:this.view,defaultCreateOptions:{mode:"click",hasZ:!0},updateOnGraphicClick:!1,defaultUpdateOptions:{enableMoveAllGraphics:!1,enableRotation:!1,enableScaling:!1,enableZ:!1,highlightOptions:{enabled:!1},multipleSelectionEnabled:!1,reshapeOptions:{shapeOperation:"none"},toggleToolOnClick:!1,tool:"reshape"},polylineSymbol:this._lineSymbol,activeLineSymbol:this._lineSymbol,snappingOptions:this._allLayerSnappingOptions.options})}_ensureUpdatedSketchGraphic(){const{geometry:e}=this._analysis;if(!e)return this.sketchGraphic=null,this._graphicsLayer.removeAll(),null;const i=this.sketchGraphic??=new t({symbol:this._lineSymbol,geometry:e});return i.geometry=e,this._addSketchGraphic(i),i}_addSketchGraphic(e){const{graphics:t}=this._graphicsLayer;t.includes(e)||t.add(e),1!==t.length&&t.removeMany(t.filter(t=>t!==e))}_clear(){this.sketchGraphic=null,this._analysis.clear()}_updateAnalysisFromSketchGraphic(){let e=this.sketchGraphic?.geometry;v(e)||(e=null);const t=this._analysis;t.geometry!==e&&(t.geometry=e)}};function V(e){if("2d"===e){const e={type:"CIMSolidStroke",enable:!0,capStyle:"Butt",joinStyle:"Round",width:1.5};return new g({data:{type:"CIMSymbolReference",symbol:{type:"CIMLineSymbol",symbolLayers:[{...e,effects:[{type:"CIMGeometricEffectDashes",dashTemplate:[5,4],lineDashEnding:"FullGap",controlPointEnding:"NoConstraint"}],color:[0,0,0,255]},{...e,color:[255,255,255,255]}]}}})}return new _({color:[0,0,0,0]})}function O(e,t){t&&(t.removeFromParent(),e?.add(t))}e([y({constructOnly:!0})],L.prototype,"analysisViewData",void 0),e([y({constructOnly:!0})],L.prototype,"view",void 0),e([y()],L.prototype,"sketchGraphic",null),e([y({nonNullable:!0})],L.prototype,"state",null),e([y()],L.prototype,"updating",null),e([y()],L.prototype,"_sketching",null),e([y()],L.prototype,"_analysis",null),e([y()],L.prototype,"_lineSymbol",null),L=e([d("esri.views.analysis.ElevationProfile.ElevationProfileTool")],L);const I=new k({mode:"on-the-ground",offset:0});export{L as ElevationProfileTool};
5
+ import{__decorate as e}from"tslib";import t from"../../../Graphic.js";import i from"../../../core/Accessor.js";import{createTask as s}from"../../../core/asyncUtils.js";import a from"../../../core/Collection.js";import{makeHandle as r}from"../../../core/handleUtils.js";import{destroyMaybe as o}from"../../../core/maybe.js";import{ignoreAbortErrors as n,isAborted as h,throwIfAborted as l}from"../../../core/promiseUtils.js";import{pausable as c,sync as p,watch as y,syncAndInitial as d}from"../../../core/reactiveUtils.js";import{property as m,subclass as u}from"../../../core/accessorSupport/decorators.js";import{UpdatingHandles as g}from"../../../core/support/UpdatingHandles.js";import _ from"../../../layers/GraphicsLayer.js";import k from"../../../symbols/CIMSymbol.js";import f from"../../../symbols/SimpleLineSymbol.js";import v from"../../../symbols/support/ElevationInfo.js";import{ExclusiveOperationManager as G}from"../ExclusiveOperationManager.js";import{isPolyline as b,isValidInputGraphic as w,isInternalGraphic as S}from"./elevationProfileGeometryUtils.js";import{ViewEventPriorities as M}from"../../input/InputManager.js";import{isCancelEvent as j}from"../../interactive/interactiveToolUtils.js";import{makeAllLayerSnappingOptions as L}from"../../interactive/snapping/allLayerSnapping.js";import V from"../../../widgets/Sketch/SketchViewModel.js";let O=class extends i{constructor(e){super(e),this._sketchViewModels=new a,this._updatingHandles=new g,this._operationManager=new G}initialize(){const{view:e}=this;this._allLayerSnappingOptions=L(this.view,{selfEnabled:!0,excludeInternal:!0}),this._graphicsLayer=new _({listMode:"hide",internal:!0}),this._externalGeometryChangeHandle=c(()=>this._analysis.geometry,()=>this._ensureUpdatedSketchGraphic(),p),this.addHandles([y(()=>({map:e.map,internalGraphicsLayer:this._graphicsLayer,state:this.state,geometryVisualizationVisible:this._analysis.viewOptions.geometryVisualizationVisible,visible:this.analysisViewData.visible}),({map:e,internalGraphicsLayer:t,state:i,geometryVisualizationVisible:s,visible:a})=>{I(e,t);const r=this.sketchGraphic;switch(r&&(r.visible=a),i){case"idle":case"reshaping-disabled":r&&!s&&(r.visible=!1),this._operationManager.stop(),this._ensureUpdatedSketchGraphic();break;case"reshaping":n(this._startReshape());break;case"awaiting-sketch":this.analysisViewData.interactive=!0}},d),y(()=>this._analysis.elevationInfo,e=>{this._graphicsLayer.elevationInfo=e},d),this._allLayerSnappingOptions,this._externalGeometryChangeHandle])}destroy(){this._operationManager.destroy(),this._sketchViewModels.drain(e=>o(e));const e=this._graphicsLayer;this.view.map?.remove(e),e.destroy()}get sketchGraphic(){return this._get("sketchGraphic")}set sketchGraphic(e){e!==this._get("sketchGraphic")&&(this._set("sketchGraphic",e),this._updateAnalysisFromSketchGraphic())}get state(){const{visible:e,interactive:t}=this.analysisViewData;if(!e)return"idle";switch(this._operationManager.currentOperationType){case"place":return this._sketching?"sketching":"awaiting-sketch";case"pick-feature":return"picking";default:return this._analysis.geometry?t?"reshaping":"reshaping-disabled":"idle"}}get updating(){return this._sketchViewModels.some(e=>e.updating)||this._updatingHandles.updating}get _sketching(){return this._sketchViewModels.some(e=>e.createGraphic===this.sketchGraphic)}get _analysis(){return this.analysisViewData.analysis}get _lineSymbol(){return C(this.view.type)}place(e){return this._operationManager.start("place",async t=>{const i=this._createSketchViewModel(),s=this._analysis.clone();this._ensureUpdatedSketchGraphic();const a=this.sketchGraphic,o=this._analysis.elevationInfo,l=r(()=>{this.sketchGraphic===a&&(this._graphicsLayer.elevationInfo=o)}),c=i.on("create",e=>{switch(e.state){case"start":this._graphicsLayer.removeAll(),this.sketchGraphic=e.graphic,this._analysis.elevationInfo=this._graphicsLayer.elevationInfo;break;case"active":this._updateAnalysisFromSketchGraphic();break;case"complete":this.sketchGraphic&&(this._updateAnalysisFromSketchGraphic(),this._addSketchGraphic(this.sketchGraphic)),t.stop();break;case"cancel":t.stop()}});t.handles.push(c,r(()=>(c.remove(),i.destroy(),this._sketchViewModels.remove(i),this._updateAnalysisFromSketchGraphic(),this._analysis.valid?h(e)||s.equals(this._analysis)?t.reject():void t.resolve({}):(this._clear(),t.reject()))),l),this._graphicsLayer.elevationInfo=U,await this._updatingHandles.addPromise(n(i.create("polyline")))},e)}async pickFeature(e){return this._operationManager.start("pick-feature",async e=>{const{view:t}=this;t.closePopup();let i=null;const a=a=>{a.defer(async()=>{i?.abort(),i=s(async i=>{const{results:s}=await t.hitTest(a);l(i);let r=null;for(const e of s)if("graphic"===e.type&&w(e.graphic)&&!S(e.graphic)){r=e.graphic;break}r&&(a.preventDefault(),a.stopPropagation(),this._externalGeometryChangeHandle.pause(),this.sketchGraphic=null,this._analysis.setGeometryFromFeature(r),this._externalGeometryChangeHandle.resume(),e.resolve({feature:r}),e.stop())}),await i.promise})},o=t=>{j(t)&&(e.reject(),e.stop())};e.handles.push(t.on("immediate-click",a,M.TOOL),t.on("key-down",o,M.TOOL),t.acquireCursor("crosshair","high"),r(()=>{i?.abort(),e.reject()})),t.focus()},e)}_startReshape(){const e=this._createSketchViewModel();return this._sketchViewModels.add(e),this._operationManager.start("reshape",async t=>{const i=()=>{const t=this._ensureUpdatedSketchGraphic();return t?this._updatingHandles.addPromise(e.update(t,{tool:"reshape"})):Promise.resolve()};if(!this._ensureUpdatedSketchGraphic())return;const s=e.on("update",e=>{this._updateAnalysisFromSketchGraphic(),"complete"===e.state&&("reshaping"===this.state?n(i()):t.resolve())});t.handles.push(s,r(()=>{s.remove(),this._sketchViewModels.remove(e),e.destroy(),t.resolve()})),await i()})}_createSketchViewModel(){return new V({layer:this._graphicsLayer,view:this.view,defaultCreateOptions:{mode:"click",hasZ:!0},updateOnGraphicClick:!1,defaultUpdateOptions:{enableMoveAllGraphics:!1,enableRotation:!1,enableScaling:!1,enableZ:!1,highlightOptions:{enabled:!1},multipleSelectionEnabled:!1,reshapeOptions:{shapeOperation:"none"},toggleToolOnClick:!1,tool:"reshape"},polylineSymbol:this._lineSymbol,activeLineSymbol:this._lineSymbol,snappingOptions:this._allLayerSnappingOptions.options})}_ensureUpdatedSketchGraphic(){const{geometry:e}=this._analysis;if(!e)return this.sketchGraphic=null,this._graphicsLayer.removeAll(),null;const i=this.sketchGraphic??=new t({symbol:this._lineSymbol,geometry:e});return i.geometry=e,this._addSketchGraphic(i),i}_addSketchGraphic(e){const{graphics:t}=this._graphicsLayer;t.includes(e)||t.add(e),1!==t.length&&t.removeMany(t.filter(t=>t!==e))}_clear(){this.sketchGraphic=null,this._analysis.clear()}_updateAnalysisFromSketchGraphic(){this._externalGeometryChangeHandle.pause();let e=this.sketchGraphic?.geometry;b(e)||(e=null);const t=this._analysis;t.geometry!==e&&(t.geometry=e),this._externalGeometryChangeHandle.resume()}};function C(e){if("2d"===e){const e={type:"CIMSolidStroke",enable:!0,capStyle:"Butt",joinStyle:"Round",width:1.5};return new k({data:{type:"CIMSymbolReference",symbol:{type:"CIMLineSymbol",symbolLayers:[{...e,effects:[{type:"CIMGeometricEffectDashes",dashTemplate:[5,4],lineDashEnding:"FullGap",controlPointEnding:"NoConstraint"}],color:[0,0,0,255]},{...e,color:[255,255,255,255]}]}}})}return new f({color:[0,0,0,0]})}function I(e,t){t&&(t.removeFromParent(),e?.add(t))}e([m({constructOnly:!0})],O.prototype,"analysisViewData",void 0),e([m({constructOnly:!0})],O.prototype,"view",void 0),e([m()],O.prototype,"sketchGraphic",null),e([m({nonNullable:!0})],O.prototype,"state",null),e([m()],O.prototype,"updating",null),e([m()],O.prototype,"_sketching",null),e([m()],O.prototype,"_analysis",null),e([m()],O.prototype,"_lineSymbol",null),O=e([u("esri.views.analysis.ElevationProfile.ElevationProfileTool")],O);const U=new v({mode:"on-the-ground",offset:0});export{O as ElevationProfileTool};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{makeHandle as e}from"../../../core/handleUtils.js";import{convertUnit as t}from"../../../core/units.js";let i={noDataValue:-5e5,defaultQueryOptions:()=>({noDataValue:i.noDataValue,demResolution:"auto",maximumAutoTileRequests:150,ignoreInvisibleLayers:!0,signal:null}),updateThrottleMillis:100,delayAfterPreviewMillis:500,defaultDemResolution:t(10,"centimeters","meters"),densificationMaxSamples:3e3,largeChartSamples:1e4,maxTotalSamples:1e5,maxChartRatio:300,minSlopeSampleDistance:10,formatPrecision:1,profileLinesUpdateThrottleMillis:100,hoveredPointsStyle:{size:14,borderStyle:"solid",borderWidth:3,borderColor:"#ffffff",boxShadow:"0px 0px 0px 5px rgba(255,255,255,0.2)"}};function l(){return i}function o(t){const l=i;return i={...i,...t},e(()=>{i=l})}function a(){return o({defaultDemResolution:100,densificationMaxSamples:500,updateThrottleMillis:0,delayAfterPreviewMillis:0,profileLinesUpdateThrottleMillis:0})}const r=" ― ";export{l as getConfig,r as notAvailable,o as setConfig,a as setTestConfig};
5
+ import{makeHandle as e}from"../../../core/handleUtils.js";import{convertUnit as t}from"../../../core/units.js";let i={noDataValue:-5e5,defaultQueryOptions:()=>({noDataValue:i.noDataValue,demResolution:"auto",maximumAutoTileRequests:150,ignoreInvisibleLayers:!0,signal:null}),updateThrottleMillis:100,delayAfterPreviewMillis:500,defaultDemResolution:t(10,"centimeters","meters"),densificationMaxSamples:3e3,largeChartSamples:1e4,maxTotalSamples:1e5,maxChartRatio:300,minSlopeSampleDistance:10,formatPrecision:1,profileLinesUpdateThrottleMillis:100,indicatorPointStyle:{size:14,borderStyle:"solid",borderWidth:3,borderColor:"#ffffff",boxShadow:"0px 0px 0px 5px rgba(255,255,255,0.2)"}};function l(){return i}function o(t){const l=i;return i={...i,...t},e(()=>{i=l})}function a(){return o({defaultDemResolution:100,densificationMaxSamples:500,updateThrottleMillis:0,delayAfterPreviewMillis:0,profileLinesUpdateThrottleMillis:0})}const r=" ― ";export{l as getConfig,r as notAvailable,o as setConfig,a as setTestConfig};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import e from"../../core/Accessor.js";import"../../core/has.js";import{property as i,subclass as o}from"../../core/accessorSupport/decorators.js";import c from"./MultipointDrawAction.js";import r from"./PointDrawAction.js";import s from"./PolygonDrawAction.js";import n from"./PolylineDrawAction.js";import a from"./SegmentDrawAction.js";let p=class extends e{constructor(t){super(t),this.activeAction=null,this.type="draw",this.view=null}destroy(){this.activeAction&&(this.activeAction.destroy(),this.activeAction=null)}create(t,e){this.reset();const i={view:this.view,...e};switch(t){case"point":i.editGeometryType="point",this.activeAction=new r(i);break;case"polyline":i.editGeometryType="polyline",this.activeAction=new n(i);break;case"multipoint":i.editGeometryType="polygon",this.activeAction=new c(i);break;case"polygon":i.editGeometryType="polygon",this.activeAction=new s(i);break;case"rectangle":case"circle":case"ellipse":case"triangle":i.editGeometryType="polygon",this.activeAction=new a(i)}return this.activeAction}complete(){this.activeAction?.complete(),this.activeAction=null}reset(){this.activeAction?.destroy(),this.activeAction=null}};t([i()],p.prototype,"activeAction",void 0),t([i({readOnly:!0})],p.prototype,"type",void 0),t([i()],p.prototype,"view",void 0),p=t([o("esri.views.draw.Draw")],p);const l=p;export{l as default};
5
+ import{__decorate as t}from"tslib";import e from"../../core/Accessor.js";import{property as i,subclass as o}from"../../core/accessorSupport/decorators.js";import c from"./MultipointDrawAction.js";import r from"./PointDrawAction.js";import s from"./PolygonDrawAction.js";import n from"./PolylineDrawAction.js";import a from"./SegmentDrawAction.js";let p=class extends e{constructor(t){super(t),this.activeAction=null,this.type="draw",this.view=null}destroy(){this.activeAction&&(this.activeAction.destroy(),this.activeAction=null)}create(t,e){this.reset();const i={view:this.view,...e};switch(t){case"point":i.editGeometryType="point",this.activeAction=new r(i);break;case"polyline":i.editGeometryType="polyline",this.activeAction=new n(i);break;case"multipoint":i.editGeometryType="polygon",this.activeAction=new c(i);break;case"polygon":i.editGeometryType="polygon",this.activeAction=new s(i);break;case"rectangle":case"circle":case"ellipse":case"triangle":i.editGeometryType="polygon",this.activeAction=new a(i)}return this.activeAction}complete(){this.activeAction?.complete(),this.activeAction=null}reset(){this.activeAction?.destroy(),this.activeAction=null}};t([i()],p.prototype,"activeAction",void 0),t([i({readOnly:!0})],p.prototype,"type",void 0),t([i()],p.prototype,"view",void 0),p=t([o("esri.views.draw.Draw")],p);const l=p;export{l as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../core/has.js";import{makeHandle as e}from"../../core/handleUtils.js";import{rad2deg as t}from"../../core/mathUtils.js";import{createScreenPoint as n}from"../../core/screenUtils.js";import{InputHandler as a}from"./InputHandler.js";import{ViewEventPriorities as r}from"./InputManager.js";const i=["click","double-click","immediate-click","immediate-double-click","hold","drag","key-down","key-up","pointer-down","pointer-move","pointer-up","pointer-drag","mouse-wheel","pointer-enter","pointer-leave","gamepad","focus","blur"],o={};function s(e){return!!o[e]}function p(e){for(const t of e)if(!s(t))return!1;return!0}i.forEach(e=>{o[e]=!0});class c{constructor(e){this._handlers=new Map,this._counter=0,this._handlerCounts=new Map,this.view=e,this.inputManager=null}connect(e){e&&this.disconnect(),this.inputManager=e,this._handlers.forEach(({handler:e,priority:t},n)=>this.inputManager?.installHandlers(n,[e],t))}disconnect(){this.inputManager&&this._handlers.forEach((e,t)=>this.inputManager?.uninstallHandlers(t)),this.inputManager=null}destroy(){this.disconnect(),this._handlers.clear(),this.view=null}on(t,n,a,i){const o=Array.isArray(t)?t:t.split(",");if(!p(o))return o.some(s)&&console.error("Error: registering input events and other events on the view at the same time is not supported."),null;let c,u;Array.isArray(n)?u=n:(c=n,u=[]),"function"==typeof a?c=a:i=a,i=null!=i?i:r.DEFAULT;const d=this._createUniqueGroupName(),m=new l(this.view,o,u,c);this._handlers.set(d,{handler:m,priority:i});for(const e of o){const t=this._handlerCounts.get(e)||0;this._handlerCounts.set(e,t+1)}return this.inputManager&&this.inputManager.installHandlers(d,[m],i),e(()=>this._removeHandler(d,o))}hasHandler(e){return!!this._handlerCounts.get(e)}_removeHandler(e,t){if(this._handlers.has(e)){this._handlers.delete(e);for(const e of t){const t=this._handlerCounts.get(e);void 0===t||(1===t?this._handlerCounts.delete(e):this._handlerCounts.set(e,t-1))}}this.inputManager&&this.inputManager.uninstallHandlers(e)}_createUniqueGroupName(){return this._counter+=1,`viewEvents_${this._counter}`}}class l extends a{constructor(e,t,n,a){super(!0),this._latestDragStart=void 0,this.view=e;for(const r of t)switch(r){case"click":this.registerIncoming("click",n,t=>a(m(e,t)));break;case"double-click":this.registerIncoming("double-click",n,t=>a(g(e,t)));break;case"immediate-click":this.registerIncoming("immediate-click",n,t=>a(f(e,t)));break;case"immediate-double-click":this.registerIncoming("immediate-double-click",n,t=>a(v(e,t)));break;case"hold":this.registerIncoming("hold",n,t=>a(h(e,t)));break;case"drag":this.registerIncoming("drag",n,e=>{const t=this._wrapDrag(e);t&&a(t)});break;case"key-down":this.registerIncoming("key-down",n,e=>a(y(e)));break;case"key-up":this.registerIncoming("key-up",n,e=>a(k(e)));break;case"pointer-down":this.registerIncoming("pointer-down",n,e=>a(I(e,"pointer-down")));break;case"pointer-move":this.registerIncoming("pointer-move",n,e=>a(I(e,"pointer-move")));break;case"pointer-up":this.registerIncoming("pointer-up",n,e=>a(I(e,"pointer-up")));break;case"pointer-drag":this.registerIncoming("pointer-drag",n,e=>a(D(e)));break;case"mouse-wheel":this.registerIncoming("mouse-wheel",n,e=>a(P(e)));break;case"pointer-enter":this.registerIncoming("pointer-enter",n,e=>a(I(e,"pointer-enter")));break;case"pointer-leave":this.registerIncoming("pointer-leave",n,e=>a(I(e,"pointer-leave")));break;case"gamepad":this.registerIncoming("gamepad",n,e=>{a(_(e))});break;case"focus":this.registerIncoming("focus",n,e=>{a(u(e))});break;case"blur":this.registerIncoming("blur",n,e=>{a(d(e))})}}_wrapDrag(e){const n=e.data,{x:a,y:r}=n.center,{action:i,pointerType:o,button:s}=n;if("start"===i&&(this._latestDragStart=n),!this._latestDragStart)return;const p=n.pointer.native,c=n.buttons,{cancelable:l,timestamp:u}=e,d={x:this._latestDragStart.center.x,y:this._latestDragStart.center.y};return"end"===i&&(this._latestDragStart=void 0),{type:"drag",action:i,x:a,y:r,origin:d,pointerType:o,button:s,buttons:c,radius:n.radius,angle:t(n.angle),native:p,timestamp:u,cancelable:l,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}}function u(e){return{type:"focus",timestamp:e.timestamp,native:e.data.native,cancelable:e.cancelable,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function d(e){return{type:"blur",timestamp:e.timestamp,native:e.data.native,cancelable:e.cancelable,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function m(e,t){const{pointerType:a,button:r,buttons:i,x:o,y:s,native:p,eventId:c}=t.data,{cancelable:l,timestamp:u}=t;return{type:"click",pointerType:a,button:r,buttons:i,x:o,y:s,native:p,timestamp:u,screenPoint:n(o,s),mapPoint:b(e,o,s),eventId:c,cancelable:l,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function g(e,t){const{pointerType:n,button:a,buttons:r,x:i,y:o,native:s,eventId:p}=t.data,{cancelable:c,timestamp:l}=t;return{type:"double-click",pointerType:n,button:a,buttons:r,x:i,y:o,native:s,timestamp:l,mapPoint:b(e,i,o),eventId:p,cancelable:c,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function f(e,t){const{pointerType:n,button:a,buttons:r,x:i,y:o,native:s,eventId:p}=t.data,c=s.pointerId,{cancelable:l,timestamp:u}=t;return{type:"immediate-click",pointerId:c,pointerType:n,button:a,buttons:r,x:i,y:o,native:s,timestamp:u,mapPoint:b(e,i,o),eventId:p,cancelable:l,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function v(e,t){const{pointerType:n,button:a,buttons:r,x:i,y:o,native:s,eventId:p}=t.data,c=s.pointerId,{cancelable:l,timestamp:u}=t;return{type:"immediate-double-click",pointerId:c,pointerType:n,button:a,buttons:r,x:i,y:o,native:s,timestamp:u,mapPoint:b(e,i,o),eventId:p,cancelable:l,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function h(e,t){const{pointerType:n,button:a,buttons:r,x:i,y:o,native:s}=t.data,{cancelable:p,timestamp:c}=t;return{type:"hold",pointerType:n,button:a,buttons:r,x:i,y:o,native:s,timestamp:c,mapPoint:b(e,i,o),cancelable:p,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function b(e,t,a){return e.toMap(n(t,a),{exclude:[]})}function y(e){const{key:t,repeat:n,native:a}=e.data,{cancelable:r,timestamp:i}=e;return{type:"key-down",key:t,repeat:n,native:a,timestamp:i,cancelable:r,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function k(e){const{key:t,native:n}=e.data,{cancelable:a,timestamp:r}=e;return{type:"key-up",key:t,native:n,timestamp:r,cancelable:a,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function I(e,t){const{x:n,y:a,button:r,buttons:i,native:o,eventId:s}=e.data,p=o.pointerId,c=o.pointerType,{cancelable:l,timestamp:u}=e;return{type:t,x:n,y:a,pointerId:p,pointerType:c,button:r,buttons:i,native:o,timestamp:u,eventId:s,cancelable:l,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function D(e){const{x:t,y:n,buttons:a,native:r,eventId:i}=e.data.currentEvent,{button:o}=e.data.startEvent,s=e.data.startEvent.native.pointerId,p=e.data.startEvent.native.pointerType,c=e.data.action,l={x:e.data.startEvent.x,y:e.data.startEvent.y},{cancelable:u,timestamp:d}=e;return{type:"pointer-drag",x:t,y:n,pointerId:s,pointerType:p,button:o,buttons:a,action:c,origin:l,native:r,timestamp:d,eventId:i,cancelable:u,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function P(e){const{cancelable:t,data:n,timestamp:a}=e,{x:r,y:i,deltaY:o,native:s}=n;return{type:"mouse-wheel",x:r,y:i,deltaY:o,native:s,timestamp:a,cancelable:t,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function _(e){const{action:t,state:n,device:a}=e.data,{cancelable:r,timestamp:i}=e,{buttons:o,axes:s}=n;return{type:"gamepad",device:a,timestamp:i,action:t,buttons:o,axes:s,cancelable:r,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}export{c as ViewEvents,i as eventTypes};
5
+ import{makeHandle as e}from"../../core/handleUtils.js";import"../../core/has.js";import{rad2deg as t}from"../../core/mathUtils.js";import{createScreenPoint as n}from"../../core/screenUtils.js";import{InputHandler as a}from"./InputHandler.js";import{ViewEventPriorities as r}from"./InputManager.js";const i=["click","double-click","immediate-click","immediate-double-click","hold","drag","key-down","key-up","pointer-down","pointer-move","pointer-up","pointer-drag","mouse-wheel","pointer-enter","pointer-leave","gamepad","focus","blur"],o={};function s(e){return!!o[e]}function p(e){for(const t of e)if(!s(t))return!1;return!0}i.forEach(e=>{o[e]=!0});class c{constructor(e){this._handlers=new Map,this._counter=0,this._handlerCounts=new Map,this.view=e,this.inputManager=null}connect(e){e&&this.disconnect(),this.inputManager=e,this._handlers.forEach(({handler:e,priority:t},n)=>this.inputManager?.installHandlers(n,[e],t))}disconnect(){this.inputManager&&this._handlers.forEach((e,t)=>this.inputManager?.uninstallHandlers(t)),this.inputManager=null}destroy(){this.disconnect(),this._handlers.clear(),this.view=null}on(t,n,a,i){const o=Array.isArray(t)?t:t.split(",");if(!p(o))return o.some(s)&&console.error("Error: registering input events and other events on the view at the same time is not supported."),null;let c,u;Array.isArray(n)?u=n:(c=n,u=[]),"function"==typeof a?c=a:i=a,i=null!=i?i:r.DEFAULT;const d=this._createUniqueGroupName(),m=new l(this.view,o,u,c);this._handlers.set(d,{handler:m,priority:i});for(const e of o){const t=this._handlerCounts.get(e)||0;this._handlerCounts.set(e,t+1)}return this.inputManager&&this.inputManager.installHandlers(d,[m],i),e(()=>this._removeHandler(d,o))}hasHandler(e){return!!this._handlerCounts.get(e)}_removeHandler(e,t){if(this._handlers.has(e)){this._handlers.delete(e);for(const e of t){const t=this._handlerCounts.get(e);void 0===t||(1===t?this._handlerCounts.delete(e):this._handlerCounts.set(e,t-1))}}this.inputManager&&this.inputManager.uninstallHandlers(e)}_createUniqueGroupName(){return this._counter+=1,`viewEvents_${this._counter}`}}class l extends a{constructor(e,t,n,a){super(!0),this._latestDragStart=void 0,this.view=e;for(const r of t)switch(r){case"click":this.registerIncoming("click",n,t=>a(m(e,t)));break;case"double-click":this.registerIncoming("double-click",n,t=>a(g(e,t)));break;case"immediate-click":this.registerIncoming("immediate-click",n,t=>a(f(e,t)));break;case"immediate-double-click":this.registerIncoming("immediate-double-click",n,t=>a(v(e,t)));break;case"hold":this.registerIncoming("hold",n,t=>a(h(e,t)));break;case"drag":this.registerIncoming("drag",n,e=>{const t=this._wrapDrag(e);t&&a(t)});break;case"key-down":this.registerIncoming("key-down",n,e=>a(y(e)));break;case"key-up":this.registerIncoming("key-up",n,e=>a(k(e)));break;case"pointer-down":this.registerIncoming("pointer-down",n,e=>a(I(e,"pointer-down")));break;case"pointer-move":this.registerIncoming("pointer-move",n,e=>a(I(e,"pointer-move")));break;case"pointer-up":this.registerIncoming("pointer-up",n,e=>a(I(e,"pointer-up")));break;case"pointer-drag":this.registerIncoming("pointer-drag",n,e=>a(D(e)));break;case"mouse-wheel":this.registerIncoming("mouse-wheel",n,e=>a(P(e)));break;case"pointer-enter":this.registerIncoming("pointer-enter",n,e=>a(I(e,"pointer-enter")));break;case"pointer-leave":this.registerIncoming("pointer-leave",n,e=>a(I(e,"pointer-leave")));break;case"gamepad":this.registerIncoming("gamepad",n,e=>{a(_(e))});break;case"focus":this.registerIncoming("focus",n,e=>{a(u(e))});break;case"blur":this.registerIncoming("blur",n,e=>{a(d(e))})}}_wrapDrag(e){const n=e.data,{x:a,y:r}=n.center,{action:i,pointerType:o,button:s}=n;if("start"===i&&(this._latestDragStart=n),!this._latestDragStart)return;const p=n.pointer.native,c=n.buttons,{cancelable:l,timestamp:u}=e,d={x:this._latestDragStart.center.x,y:this._latestDragStart.center.y};return"end"===i&&(this._latestDragStart=void 0),{type:"drag",action:i,x:a,y:r,origin:d,pointerType:o,button:s,buttons:c,radius:n.radius,angle:t(n.angle),native:p,timestamp:u,cancelable:l,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}}function u(e){return{type:"focus",timestamp:e.timestamp,native:e.data.native,cancelable:e.cancelable,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function d(e){return{type:"blur",timestamp:e.timestamp,native:e.data.native,cancelable:e.cancelable,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function m(e,t){const{pointerType:a,button:r,buttons:i,x:o,y:s,native:p,eventId:c}=t.data,{cancelable:l,timestamp:u}=t;return{type:"click",pointerType:a,button:r,buttons:i,x:o,y:s,native:p,timestamp:u,screenPoint:n(o,s),mapPoint:b(e,o,s),eventId:c,cancelable:l,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function g(e,t){const{pointerType:n,button:a,buttons:r,x:i,y:o,native:s,eventId:p}=t.data,{cancelable:c,timestamp:l}=t;return{type:"double-click",pointerType:n,button:a,buttons:r,x:i,y:o,native:s,timestamp:l,mapPoint:b(e,i,o),eventId:p,cancelable:c,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function f(e,t){const{pointerType:n,button:a,buttons:r,x:i,y:o,native:s,eventId:p}=t.data,c=s.pointerId,{cancelable:l,timestamp:u}=t;return{type:"immediate-click",pointerId:c,pointerType:n,button:a,buttons:r,x:i,y:o,native:s,timestamp:u,mapPoint:b(e,i,o),eventId:p,cancelable:l,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function v(e,t){const{pointerType:n,button:a,buttons:r,x:i,y:o,native:s,eventId:p}=t.data,c=s.pointerId,{cancelable:l,timestamp:u}=t;return{type:"immediate-double-click",pointerId:c,pointerType:n,button:a,buttons:r,x:i,y:o,native:s,timestamp:u,mapPoint:b(e,i,o),eventId:p,cancelable:l,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function h(e,t){const{pointerType:n,button:a,buttons:r,x:i,y:o,native:s}=t.data,{cancelable:p,timestamp:c}=t;return{type:"hold",pointerType:n,button:a,buttons:r,x:i,y:o,native:s,timestamp:c,mapPoint:b(e,i,o),cancelable:p,stopPropagation:()=>t.stopPropagation(),defer:e=>t.defer(e),preventDefault:()=>t.preventDefault()}}function b(e,t,a){return e.toMap(n(t,a),{exclude:[]})}function y(e){const{key:t,repeat:n,native:a}=e.data,{cancelable:r,timestamp:i}=e;return{type:"key-down",key:t,repeat:n,native:a,timestamp:i,cancelable:r,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function k(e){const{key:t,native:n}=e.data,{cancelable:a,timestamp:r}=e;return{type:"key-up",key:t,native:n,timestamp:r,cancelable:a,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function I(e,t){const{x:n,y:a,button:r,buttons:i,native:o,eventId:s}=e.data,p=o.pointerId,c=o.pointerType,{cancelable:l,timestamp:u}=e;return{type:t,x:n,y:a,pointerId:p,pointerType:c,button:r,buttons:i,native:o,timestamp:u,eventId:s,cancelable:l,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function D(e){const{x:t,y:n,buttons:a,native:r,eventId:i}=e.data.currentEvent,{button:o}=e.data.startEvent,s=e.data.startEvent.native.pointerId,p=e.data.startEvent.native.pointerType,c=e.data.action,l={x:e.data.startEvent.x,y:e.data.startEvent.y},{cancelable:u,timestamp:d}=e;return{type:"pointer-drag",x:t,y:n,pointerId:s,pointerType:p,button:o,buttons:a,action:c,origin:l,native:r,timestamp:d,eventId:i,cancelable:u,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function P(e){const{cancelable:t,data:n,timestamp:a}=e,{x:r,y:i,deltaY:o,native:s}=n;return{type:"mouse-wheel",x:r,y:i,deltaY:o,native:s,timestamp:a,cancelable:t,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}function _(e){const{action:t,state:n,device:a}=e.data,{cancelable:r,timestamp:i}=e,{buttons:o,axes:s}=n;return{type:"gamepad",device:a,timestamp:i,action:t,buttons:o,axes:s,cancelable:r,stopPropagation:()=>e.stopPropagation(),defer:t=>e.defer(t),preventDefault:()=>e.preventDefault()}}export{c as ViewEvents,i as eventTypes};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{equals as t}from"../../../core/arrayUtils.js";import{neverReached as e}from"../../../core/compilerUtils.js";import{Evented as r}from"../../../core/Evented.js";import i from"../../../geometry/Multipoint.js";import s from"../../../geometry/Polygon.js";import n from"../../../geometry/Polyline.js";import{isCoordinate as o,isBezierCurve as h,isCircularArc as c,isEllipticArc4 as l,getEndpoint as a}from"../../../geometry/support/curves/curveUtils.js";import{createCoordinateHelper as p}from"../coordinateHelper.js";import{unnormalize as u,getUnnormalizationInfo as g}from"./unnormalizationHelper.js";class f{constructor(t){this.part=t,this.leftSegment=null,this.rightSegment=null,this.type="vertex",this.index=null}get pos(){return this._pos}set pos(t){this._pos=t,this.part.unnormalizeVertexPositions()}}class m{constructor(t,e,r){this.part=t,this.leftVertex=e,this.rightVertex=r,this.type="line",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){return[...this.rightVertex.pos]}}class d{constructor(t,e,r,i){this.part=t,this.leftVertex=e,this.rightVertex=r,this.curveDefinition=i,this.type="bezier",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){return{b:[[...this.rightVertex.pos],[...this.curveDefinition.controlPoint1],[...this.curveDefinition.controlPoint2]]}}}class y{constructor(t,e,r,i){this.part=t,this.leftVertex=e,this.rightVertex=r,this.curveDefinition=i,this.type="circular-arc",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){const t=this.rightVertex.pos,{interiorPoint:e}=this.curveDefinition;return{c:[[...t],[...e]]}}}class v{constructor(t,e,r,i){this.part=t,this.leftVertex=e,this.rightVertex=r,this.curveDefinition=i,this.type="elliptic-arc-4",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){const t=this.rightVertex.pos,{centerPoint:e,sweep:r,orientation:i}=this.curveDefinition;return{a:[[...t],[...e],r,i]}}}class x{constructor(t,e,r,i){this.part=t,this.leftVertex=e,this.rightVertex=r,this.curveDefinition=i,this.type="elliptic-arc-7",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){const t=this.rightVertex.pos,{centerPoint:e,sweep:r,orientation:i,rotation:s,semiMajorAxisLength:n,minorMajorAxisRatio:o}=this.curveDefinition;return{a:[[...t],e,r,i,s,n,o]}}}class V{constructor(t,e){this._spatialReference=t,this._viewingMode=e,this.vertices=[],this.segments=[],this.index=null}unnormalizeVertexPositions(){this.vertices.length<=1||u(this.vertices,g(this._spatialReference,this._viewingMode))}updateVertexIndex(t,e){const{vertices:r}=this;if(0===r.length)return;const i=r[0];let s=null,n=t,o=e;do{s=n,s.index=o++,n=s.rightSegment?s.rightSegment.rightVertex:null}while(null!=n&&n!==i);s.leftSegment&&s!==r[r.length-1]&&this.swapVertices(r.indexOf(s),r.length-1)}getFirstVertex(){return this.vertices.at(0)}getLastVertex(){return this.vertices.at(-1)}isClosed(){return null!==this.getFirstVertex()?.leftSegment}swapVertices(t,e){const{vertices:r}=this,i=r[t];r[t]=r[e],r[e]=i}*iterateVertices(){const t=this.getFirstVertex();let e=t;if(e)do{yield e,e=e.rightSegment?.rightVertex}while(e!==t&&null!=e)}}class w extends r{constructor(t,e){super(),this.type=t,this.coordinateHelper=e,this._geometry=null,this._dirty=!0,this.parts=[]}get geometry(){if(this._dirty){switch(this.type){case"point":this._geometry=this._toPoint();break;case"multipoint":this._geometry=this._toMultipoint();break;case"polyline":this._geometry=this._toPolyline();break;case"polygon":this._geometry=this._toPolygon();break;case"mesh":break;default:e(this.type)}this._dirty=!1}return this._geometry}get spatialReference(){return this.coordinateHelper.spatialReference}get allVerticesUnordered(){return Array.from(this.iterateVerticesUnordered())}*iterateVerticesUnordered(){for(const t of this.parts)for(const e of t.vertices)yield e}get allVertices(){return Array.from(this.iterateVertices())}*iterateVertices(){for(const t of this.parts)yield*t.iterateVertices()}notifyChanges(t){this._dirty=!0,this.emit("change",t)}_toPoint(){const{parts:t,coordinateHelper:e}=this;return t.at(0)?.vertices.length?e.vectorToPoint(t[0].vertices[0].pos):null}_toMultipoint(){const t=[],{coordinateHelper:e,parts:r,spatialReference:s}=this;for(const i of r){const r=i.getFirstVertex();r&&t.push(e.arrayToVector(r.pos))}return new i({hasM:e.hasM(),hasZ:e.hasZ(),spatialReference:s,points:t})}_toPolyline(){const t=[];let e=!1;for(const r of this.parts){if(r.vertices.length<1)continue;const i=r.vertices[0],s=[];s.push(i.pos);let n=i.rightSegment;for(;n;)e||="line"!==n.type,s.push(n.toCurveOrCoordinate()),n=n.rightVertex.rightSegment;t.push(s)}return new n({paths:e?void 0:t,curvePaths:e?t:void 0,spatialReference:this.spatialReference,hasZ:this.coordinateHelper.hasZ(),hasM:this.coordinateHelper.hasM()})}_toPolygon(){const t=[];let e=!1;for(const r of this.parts){if(r.vertices.length<1)continue;const i=r.vertices[0],s=[];s.push(i.pos);let n=i.rightSegment;for(;n&&(e||="line"!==n.type,s.push(n.toCurveOrCoordinate()),n=n.rightVertex.rightSegment,n?.leftVertex!==i););t.push(s)}return new s({rings:e?void 0:t,curveRings:e?t:void 0,spatialReference:this.spatialReference,hasZ:this.coordinateHelper.hasZ(),hasM:this.coordinateHelper.hasM()})}static fromGeometry(t,e,r){const i=t.spatialReference,s=p(t.hasZ,t.hasM,i),n=new w(t.type,s);switch(t.type){case"polygon":S(n,t,e,r?.allowCurves??!1);break;case"polyline":R(n,t,e,r?.allowCurves??!1);break;case"point":C(n,t,e);break;case"multipoint":M(n,t,e);break;case"mesh":C(n,t.origin,e),n._geometry=t,n._dirty=!1}return n}}function _(t,e,r,i){const s=new f(t);t.vertices.push(s);const n=a(i);return s.pos=e.arrayToVector(n),s.index=t.vertices.length-1,r&&t.segments.push(P(t,r,s,i)),s}function P(t,e,r,i){if(o(i))return new m(t,e,r);if(h(i)){const[,s,n]=i.b;return new d(t,e,r,{controlPoint1:[...s],controlPoint2:[...n]})}if(c(i)){const[,s]=i.c;return new y(t,e,r,{interiorPoint:[...s]})}if(l(i)){const[,s,n,o]=i.a;return new v(t,e,r,{centerPoint:[...s],sweep:n,orientation:o})}const[,s,n,a,p,u,g]=i.a;return new x(t,e,r,{centerPoint:[...s],sweep:n,orientation:a,rotation:p,semiMajorAxisLength:u,minorMajorAxisRatio:g})}function S(e,r,i,s){const n=r.spatialReference,o=e.coordinateHelper,{rings:h,curveRings:c}=r,l=c&&s?c:h;for(let p=0;p<l.length;++p){const r=l[p],s=new V(n,i);if(s.index=p,e.parts.push(s),r.length<1)continue;let h=null,c=null;for(let t=0;t<r.length-1;++t)c=_(s,o,c,r[t]),h??=c;r.length>1&&t(a(r[r.length-1]),h?.pos)?c&&h&&s.segments.push(P(s,c,h,r[r.length-1])):c=_(s,o,c,r[r.length-1])}}function R(t,e,r,i){const s=e.spatialReference,n=t.coordinateHelper,{curvePaths:o,paths:h}=e,c=o&&i?o:h;for(let l=0;l<c.length;++l){const e=c[l],i=new V(s,r);if(i.index=l,t.parts.push(i),e.length<1)continue;let o=null;for(let t=0;t<e.length;++t)o=_(i,n,o,e[t])}}function C(t,e,r){const i=e.spatialReference,s=t.coordinateHelper,n=new V(i,r);n.index=0;const o=new f(n);o.index=0,o.pos=s.pointToVector(e),n.vertices.push(o),t.parts.push(n)}function M(t,e,r){const i=e.spatialReference,{coordinateHelper:s,parts:n}=t,o=e.points.map(t=>s.arrayToVector(t));for(let h=0;h<o.length;h++){const t=new V(i,r);t.index=h,n.push(t);const e=new f(t);e.pos=o[h],e.index=0,t.vertices.push(e)}}function H(t){return"mesh"===t.type}function j(t,e){if(t.type!==e.type)return!1;if(t.parts.length!==e.parts.length)return!1;for(let s=0;s<t.parts.length;s++){const r=t.parts[s],i=e.parts[s];if(r.vertices.length!==i.vertices.length)return!1}const r=t.allVertices,i=e.allVertices;for(let s=0;s<r.length;s++){const t=r[s].leftSegment?.type,e=i[s].leftSegment?.type;if(t!==e)return!1}return!0}export{d as BezierSegment,y as CircularArcSegment,w as EditGeometry,v as EllipticArc4Segment,x as EllipticArc7Segment,m as LineSegment,V as Part,f as Vertex,P as createConnectingSegment,j as haveCompatibleTopologies,H as isMeshEditGeometry};
5
+ import{equals as t}from"../../../core/arrayUtils.js";import{Evented as e}from"../../../core/Evented.js";import r from"../../../geometry/Multipoint.js";import i from"../../../geometry/Polygon.js";import s from"../../../geometry/Polyline.js";import{isCoordinate as n,isBezierCurve as o,isCircularArc as h,isEllipticArc4 as c,getEndpoint as l}from"../../../geometry/support/curves/curveUtils.js";import{createCoordinateHelper as a}from"../coordinateHelper.js";import{unnormalize as p,getUnnormalizationInfo as u}from"./unnormalizationHelper.js";class g{constructor(t){this.part=t,this.leftSegment=null,this.rightSegment=null,this.type="vertex",this.index=null}get pos(){return this._pos}set pos(t){this._pos=t,this.part.unnormalizeVertexPositions()}}class f{constructor(t,e,r){this.part=t,this.leftVertex=e,this.rightVertex=r,this.type="line",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){return[...this.rightVertex.pos]}}class m{constructor(t,e,r,i){this.part=t,this.leftVertex=e,this.rightVertex=r,this.curveDefinition=i,this.type="bezier",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){return{b:[[...this.rightVertex.pos],[...this.curveDefinition.controlPoint1],[...this.curveDefinition.controlPoint2]]}}}class d{constructor(t,e,r,i){this.part=t,this.leftVertex=e,this.rightVertex=r,this.curveDefinition=i,this.type="circular-arc",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){const t=this.rightVertex.pos,{interiorPoint:e}=this.curveDefinition;return{c:[[...t],[...e]]}}}class y{constructor(t,e,r,i){this.part=t,this.leftVertex=e,this.rightVertex=r,this.curveDefinition=i,this.type="elliptic-arc-4",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){const t=this.rightVertex.pos,{centerPoint:e,sweep:r,orientation:i}=this.curveDefinition;return{a:[[...t],[...e],r,i]}}}class v{constructor(t,e,r,i){this.part=t,this.leftVertex=e,this.rightVertex=r,this.curveDefinition=i,this.type="elliptic-arc-7",e.rightSegment=this,r.leftSegment=this}toCurveOrCoordinate(){const t=this.rightVertex.pos,{centerPoint:e,sweep:r,orientation:i,rotation:s,semiMajorAxisLength:n,minorMajorAxisRatio:o}=this.curveDefinition;return{a:[[...t],e,r,i,s,n,o]}}}class x{constructor(t,e){this._spatialReference=t,this._viewingMode=e,this.vertices=[],this.segments=[],this.index=null}unnormalizeVertexPositions(){this.vertices.length<=1||p(this.vertices,u(this._spatialReference,this._viewingMode))}updateVertexIndex(t,e){const{vertices:r}=this;if(0===r.length)return;const i=r[0];let s=null,n=t,o=e;do{s=n,s.index=o++,n=s.rightSegment?s.rightSegment.rightVertex:null}while(null!=n&&n!==i);s.leftSegment&&s!==r[r.length-1]&&this.swapVertices(r.indexOf(s),r.length-1)}getFirstVertex(){return this.vertices.at(0)}getLastVertex(){return this.vertices.at(-1)}isClosed(){return null!==this.getFirstVertex()?.leftSegment}swapVertices(t,e){const{vertices:r}=this,i=r[t];r[t]=r[e],r[e]=i}*iterateVertices(){const t=this.getFirstVertex();let e=t;if(e)do{yield e,e=e.rightSegment?.rightVertex}while(e!==t&&null!=e)}}class V extends e{constructor(t,e){super(),this.type=t,this.coordinateHelper=e,this._geometry=null,this._dirty=!0,this.parts=[]}get geometry(){if(this._dirty){switch(this.type){case"point":this._geometry=this._toPoint();break;case"multipoint":this._geometry=this._toMultipoint();break;case"polyline":this._geometry=this._toPolyline();break;case"polygon":this._geometry=this._toPolygon();break;case"mesh":break;default:this.type}this._dirty=!1}return this._geometry}get spatialReference(){return this.coordinateHelper.spatialReference}get allVerticesUnordered(){return Array.from(this.iterateVerticesUnordered())}*iterateVerticesUnordered(){for(const t of this.parts)for(const e of t.vertices)yield e}get allVertices(){return Array.from(this.iterateVertices())}*iterateVertices(){for(const t of this.parts)yield*t.iterateVertices()}notifyChanges(t){this._dirty=!0,this.emit("change",t)}_toPoint(){const{parts:t,coordinateHelper:e}=this;return t.at(0)?.vertices.length?e.vectorToPoint(t[0].vertices[0].pos):null}_toMultipoint(){const t=[],{coordinateHelper:e,parts:i,spatialReference:s}=this;for(const r of i){const i=r.getFirstVertex();i&&t.push(e.arrayToVector(i.pos))}return new r({hasM:e.hasM(),hasZ:e.hasZ(),spatialReference:s,points:t})}_toPolyline(){const t=[];let e=!1;for(const r of this.parts){if(r.vertices.length<1)continue;const i=r.vertices[0],s=[];s.push(i.pos);let n=i.rightSegment;for(;n;)e||="line"!==n.type,s.push(n.toCurveOrCoordinate()),n=n.rightVertex.rightSegment;t.push(s)}return new s({paths:e?void 0:t,curvePaths:e?t:void 0,spatialReference:this.spatialReference,hasZ:this.coordinateHelper.hasZ(),hasM:this.coordinateHelper.hasM()})}_toPolygon(){const t=[];let e=!1;for(const r of this.parts){if(r.vertices.length<1)continue;const i=r.vertices[0],s=[];s.push(i.pos);let n=i.rightSegment;for(;n&&(e||="line"!==n.type,s.push(n.toCurveOrCoordinate()),n=n.rightVertex.rightSegment,n?.leftVertex!==i););t.push(s)}return new i({rings:e?void 0:t,curveRings:e?t:void 0,spatialReference:this.spatialReference,hasZ:this.coordinateHelper.hasZ(),hasM:this.coordinateHelper.hasM()})}static fromGeometry(t,e,r){const i=t.spatialReference,s=a(t.hasZ,t.hasM,i),n=new V(t.type,s);switch(t.type){case"polygon":P(n,t,e,r?.allowCurves??!1);break;case"polyline":S(n,t,e,r?.allowCurves??!1);break;case"point":R(n,t,e);break;case"multipoint":C(n,t,e);break;case"mesh":R(n,t.origin,e),n._geometry=t,n._dirty=!1}return n}}function w(t,e,r,i){const s=new g(t);t.vertices.push(s);const n=l(i);return s.pos=e.arrayToVector(n),s.index=t.vertices.length-1,r&&t.segments.push(_(t,r,s,i)),s}function _(t,e,r,i){if(n(i))return new f(t,e,r);if(o(i)){const[,s,n]=i.b;return new m(t,e,r,{controlPoint1:[...s],controlPoint2:[...n]})}if(h(i)){const[,s]=i.c;return new d(t,e,r,{interiorPoint:[...s]})}if(c(i)){const[,s,n,o]=i.a;return new y(t,e,r,{centerPoint:[...s],sweep:n,orientation:o})}const[,s,l,a,p,u,g]=i.a;return new v(t,e,r,{centerPoint:[...s],sweep:l,orientation:a,rotation:p,semiMajorAxisLength:u,minorMajorAxisRatio:g})}function P(e,r,i,s){const n=r.spatialReference,o=e.coordinateHelper,{rings:h,curveRings:c}=r,a=c&&s?c:h;for(let p=0;p<a.length;++p){const r=a[p],s=new x(n,i);if(s.index=p,e.parts.push(s),r.length<1)continue;let h=null,c=null;for(let t=0;t<r.length-1;++t)c=w(s,o,c,r[t]),h??=c;r.length>1&&t(l(r[r.length-1]),h?.pos)?c&&h&&s.segments.push(_(s,c,h,r[r.length-1])):c=w(s,o,c,r[r.length-1])}}function S(t,e,r,i){const s=e.spatialReference,n=t.coordinateHelper,{curvePaths:o,paths:h}=e,c=o&&i?o:h;for(let l=0;l<c.length;++l){const e=c[l],i=new x(s,r);if(i.index=l,t.parts.push(i),e.length<1)continue;let o=null;for(let t=0;t<e.length;++t)o=w(i,n,o,e[t])}}function R(t,e,r){const i=e.spatialReference,s=t.coordinateHelper,n=new x(i,r);n.index=0;const o=new g(n);o.index=0,o.pos=s.pointToVector(e),n.vertices.push(o),t.parts.push(n)}function C(t,e,r){const i=e.spatialReference,{coordinateHelper:s,parts:n}=t,o=e.points.map(t=>s.arrayToVector(t));for(let h=0;h<o.length;h++){const t=new x(i,r);t.index=h,n.push(t);const e=new g(t);e.pos=o[h],e.index=0,t.vertices.push(e)}}function M(t){return"mesh"===t.type}function H(t,e){if(t.type!==e.type)return!1;if(t.parts.length!==e.parts.length)return!1;for(let s=0;s<t.parts.length;s++){const r=t.parts[s],i=e.parts[s];if(r.vertices.length!==i.vertices.length)return!1}const r=t.allVertices,i=e.allVertices;for(let s=0;s<r.length;s++){const t=r[s].leftSegment?.type,e=i[s].leftSegment?.type;if(t!==e)return!1}return!0}export{m as BezierSegment,d as CircularArcSegment,V as EditGeometry,y as EllipticArc4Segment,v as EllipticArc7Segment,f as LineSegment,x as Part,g as Vertex,_ as createConnectingSegment,H as haveCompatibleTopologies,M as isMeshEditGeometry};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../../../core/has.js";import{LRUCache as e}from"../../../../core/LRUCache.js";import{getOrCreateMapValue as t}from"../../../../core/MapUtils.js";import{throwIfAborted as s}from"../../../../core/promiseUtils.js";import{getMetersPerVerticalUnitForSR as n}from"../../../../core/units.js";import{getMetersPerUnit as o}from"../../../../symbols/support/unitConversionUtils.js";function i(e=!1,t){if(e){const{elevationInfo:e,alignPointsInFeatures:s}=t;return new c(e,s)}return new a}class a{async alignCandidates(e,t,s){return e}notifyElevationSourceChange(){}}const r=1024;class c{constructor(t,s){this._elevationInfo=t,this._alignPointsInFeatures=s,this._alignmentsCache=new e(r),this._cacheVersion=0}async alignCandidates(e,t,s){const n=this._elevationInfo;return null==n||"absolute-height"!==n.mode||n.featureExpressionInfo?this._alignComputedElevationCandidates(e,t,s):(d(e,t,n),e)}notifyElevationSourceChange(){this._alignmentsCache.clear(),this._cacheVersion++}async _alignComputedElevationCandidates(e,n,o){const i=new Map;for(const s of e)t(i,s.objectId,l).push(s);const[a,r,c]=this._prepareQuery(i,n),h=await this._alignPointsInFeatures(a,o);s(o);if(c!==this._cacheVersion)return this._alignComputedElevationCandidates(e,n,o);this._applyCacheAndResponse(a,h,r);const{drapedObjectIds:u,failedObjectIds:d}=h,p=[];for(const t of e){const{objectId:e}=t;u.has(e)&&"edge"===t.type&&(t.draped=!0),d.has(e)||p.push(t)}return p}_prepareQuery(e,t){const s=[],n=[];for(const[o,i]of e){const e=[];for(const t of i)this._addToQueriesOrCachedResult(o,t.target,e,n),"edge"===t.type&&(this._addToQueriesOrCachedResult(o,t.start,e,n),this._addToQueriesOrCachedResult(o,t.end,e,n));0!==e.length&&s.push({objectId:o,points:e})}return[{spatialReference:t.toJSON(),pointsInFeatures:s},n,this._cacheVersion]}_addToQueriesOrCachedResult(e,t,s,n){const o=u(e,t),i=this._alignmentsCache.get(o);null==i?s.push(t):n.push(new h(t,i))}_applyCacheAndResponse(e,{elevations:t,drapedObjectIds:s,failedObjectIds:n},o){for(const r of o)r.apply();let i=0;const a=this._alignmentsCache;for(const{objectId:r,points:c}of e.pointsInFeatures){if(n.has(r)){i+=c.length;continue}const e=!s.has(r);for(const s of c){const n=u(r,s),o=t[i++];s.z=o,e&&a.put(n,o,1)}}}}class h{constructor(e,t){this.point=e,this.z=t}apply(){this.point.z=this.z}}function u(e,{x:t,y:s,z:n,spatialReference:o}){return`${e}-${t}-${s}-${n??0}}-wkid:${o?.wkid}`}function d(e,t,s){const{offset:i,unit:a}=s;if(null==i)return;const r=n(t),c=i*(o(a??"meters")/r);for(const n of e)switch(n.type){case"edge":n.start.z+=c,n.end.z+=c;continue;case"vertex":n.target.z+=c;continue}}function l(){return[]}export{i as getSnappingCandidateElevationAligner};
5
+ import{LRUCache as e}from"../../../../core/LRUCache.js";import{getOrCreateMapValue as t}from"../../../../core/MapUtils.js";import{throwIfAborted as s}from"../../../../core/promiseUtils.js";import{getMetersPerVerticalUnitForSR as n}from"../../../../core/units.js";import{getMetersPerUnit as o}from"../../../../symbols/support/unitConversionUtils.js";function i(e=!1,t){if(e){const{elevationInfo:e,alignPointsInFeatures:s}=t;return new c(e,s)}return new a}class a{async alignCandidates(e,t,s){return e}notifyElevationSourceChange(){}}const r=1024;class c{constructor(t,s){this._elevationInfo=t,this._alignPointsInFeatures=s,this._alignmentsCache=new e(r),this._cacheVersion=0}async alignCandidates(e,t,s){const n=this._elevationInfo;return null==n||"absolute-height"!==n.mode||n.featureExpressionInfo?this._alignComputedElevationCandidates(e,t,s):(d(e,t,n),e)}notifyElevationSourceChange(){this._alignmentsCache.clear(),this._cacheVersion++}async _alignComputedElevationCandidates(e,n,o){const i=new Map;for(const s of e)t(i,s.objectId,l).push(s);const[a,r,c]=this._prepareQuery(i,n),h=await this._alignPointsInFeatures(a,o);s(o);if(c!==this._cacheVersion)return this._alignComputedElevationCandidates(e,n,o);this._applyCacheAndResponse(a,h,r);const{drapedObjectIds:u,failedObjectIds:d}=h,p=[];for(const t of e){const{objectId:e}=t;u.has(e)&&"edge"===t.type&&(t.draped=!0),d.has(e)||p.push(t)}return p}_prepareQuery(e,t){const s=[],n=[];for(const[o,i]of e){const e=[];for(const t of i)this._addToQueriesOrCachedResult(o,t.target,e,n),"edge"===t.type&&(this._addToQueriesOrCachedResult(o,t.start,e,n),this._addToQueriesOrCachedResult(o,t.end,e,n));0!==e.length&&s.push({objectId:o,points:e})}return[{spatialReference:t.toJSON(),pointsInFeatures:s},n,this._cacheVersion]}_addToQueriesOrCachedResult(e,t,s,n){const o=u(e,t),i=this._alignmentsCache.get(o);null==i?s.push(t):n.push(new h(t,i))}_applyCacheAndResponse(e,{elevations:t,drapedObjectIds:s,failedObjectIds:n},o){for(const r of o)r.apply();let i=0;const a=this._alignmentsCache;for(const{objectId:r,points:c}of e.pointsInFeatures){if(n.has(r)){i+=c.length;continue}const e=!s.has(r);for(const s of c){const n=u(r,s),o=t[i++];s.z=o,e&&a.put(n,o,1)}}}}class h{constructor(e,t){this.point=e,this.z=t}apply(){this.point.z=this.z}}function u(e,{x:t,y:s,z:n,spatialReference:o}){return`${e}-${t}-${s}-${n??0}}-wkid:${o?.wkid}`}function d(e,t,s){const{offset:i,unit:a}=s;if(null==i)return;const r=n(t),c=i*(o(a??"meters")/r);for(const n of e)switch(n.type){case"edge":n.start.z+=c,n.end.z+=c;continue;case"vertex":n.target.z+=c;continue}}function l(){return[]}export{i as getSnappingCandidateElevationAligner};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../../../core/has.js";class t{filter(t,n){return n}notifyElevationSourceChange(){}}class n{filter(t,n){const{point:r,distance:c}=t,{z:i}=r;if(!(null!=i))return n;if(0===n.length)return n;const o=s(c),u=this._updateCandidatesTo3D(n,r,o).filter(e);return u.sort(a),u}_updateCandidatesTo3D(t,n,e){for(const r of t)switch(r.type){case"edge":c(r,n,e);continue;case"vertex":o(r,n,e);continue}return t}}function e(t){return t.distance<=1}function r(e=!1){return e?new n:new t}function c(t,n,{x:e,y:r,z:c}){const{start:o,end:s,target:a}=t;t.draped||i(a,n,o,s);const u=(n.x-a.x)/e,d=(n.y-a.y)/r,f=(n.z-a.z)/c;t.distance=Math.sqrt(u*u+d*d+f*f)}function i(t,n,e,r){const c=r.x-e.x,i=r.y-e.y,o=r.z-e.z,s=c*c+i*i+o*o,a=(n.x-e.x)*c+(n.y-e.y)*i+o*(n.z-e.z),u=Math.min(1,Math.max(0,a/s)),d=e.x+c*u,f=e.y+i*u,x=e.z+o*u;t.x=d,t.y=f,t.z=x}function o(t,n,{x:e,y:r,z:c}){const{target:i}=t,o=(n.x-i.x)/e,s=(n.y-i.y)/r,a=(n.z-i.z)/c,u=Math.sqrt(o*o+s*s+a*a);t.distance=u}function s(t){return"number"==typeof t?{x:t,y:t,z:t}:t}function a(t,n){return t.distance-n.distance}export{r as getSnappingCandidateElevationFilter};
5
+ class t{filter(t,n){return n}notifyElevationSourceChange(){}}class n{filter(t,n){const{point:r,distance:c}=t,{z:i}=r;if(!(null!=i))return n;if(0===n.length)return n;const a=o(c),u=this._updateCandidatesTo3D(n,r,a).filter(e);return u.sort(s),u}_updateCandidatesTo3D(t,n,e){for(const r of t)switch(r.type){case"edge":c(r,n,e);continue;case"vertex":a(r,n,e);continue}return t}}function e(t){return t.distance<=1}function r(e=!1){return e?new n:new t}function c(t,n,{x:e,y:r,z:c}){const{start:a,end:o,target:s}=t;t.draped||i(s,n,a,o);const u=(n.x-s.x)/e,d=(n.y-s.y)/r,f=(n.z-s.z)/c;t.distance=Math.sqrt(u*u+d*d+f*f)}function i(t,n,e,r){const c=r.x-e.x,i=r.y-e.y,a=r.z-e.z,o=c*c+i*i+a*a,s=(n.x-e.x)*c+(n.y-e.y)*i+a*(n.z-e.z),u=Math.min(1,Math.max(0,s/o)),d=e.x+c*u,f=e.y+i*u,x=e.z+a*u;t.x=d,t.y=f,t.z=x}function a(t,n,{x:e,y:r,z:c}){const{target:i}=t,a=(n.x-i.x)/e,o=(n.y-i.y)/r,s=(n.z-i.z)/c,u=Math.sqrt(a*a+o*o+s*s);t.distance=u}function o(t){return"number"==typeof t?{x:t,y:t,z:t}:t}function s(t,n){return t.distance-n.distance}export{r as getSnappingCandidateElevationFilter};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../../../core/has.js";import{clone as t}from"../../../../core/lang.js";import{LRUCache as e}from"../../../../core/LRUCache.js";import{throwIfAborted as s}from"../../../../core/promiseUtils.js";import{numericHash as o}from"../../../../core/string.js";function n(t=!1,e){return t?new i(e):new c}class c{async fetch(){return[]}notifySymbologyChange(){}}const r=1024;class i{constructor(t){this._getSymbologyCandidates=t,this._candidatesCache=new e(r),this._cacheVersion=0}async fetch(e,o){if(0===e.length)return[];const n=[],c=[],r=this._candidatesCache;for(const s of e){const e=a(s),o=r.get(e);if(o)for(const s of o)c.push(t(s));else n.push(s),r.put(e,[],1)}if(0===n.length)return c;const i=this._cacheVersion,{candidates:h,sourceCandidateIndices:d}=await this._getSymbologyCandidates(n,o);s(o);if(i!==this._cacheVersion)return this.fetch(e,o);const f=[],{length:g}=h;for(let s=0;s<g;++s){const e=h[s],o=a(n[d[s]]),c=r.get(o);c.push(e),r.put(o,c,c.length),f.push(t(e))}return c.concat(f)}notifySymbologyChange(){this._candidatesCache.clear(),this._cacheVersion++}}function a(t){switch(t.type){case"vertex":{const{objectId:e,target:s}=t,n=`${e}-vertex-${s.x}-${s.y}-${s.z??0}`;return o(n).toString()}case"edge":{const{objectId:e,start:s,end:n}=t,c=`${e}-edge-${s.x}-${s.y}-${s.z??0}-to-${n.x}-${n.y}-${n.z??0}`;return o(c).toString()}default:return""}}export{n as getSymbologySnappingCandidatesFetcher};
5
+ import{clone as t}from"../../../../core/lang.js";import{LRUCache as e}from"../../../../core/LRUCache.js";import{throwIfAborted as n}from"../../../../core/promiseUtils.js";import{numericHash as s}from"../../../../core/string.js";function o(t=!1,e){return t?new i(e):new c}class c{async fetch(){return[]}notifySymbologyChange(){}}const r=1024;class i{constructor(t){this._getSymbologyCandidates=t,this._candidatesCache=new e(r),this._cacheVersion=0}async fetch(e,s){if(0===e.length)return[];const o=[],c=[],r=this._candidatesCache;for(const n of e){const e=a(n),s=r.get(e);if(s)for(const n of s)c.push(t(n));else o.push(n),r.put(e,[],1)}if(0===o.length)return c;const i=this._cacheVersion,{candidates:h,sourceCandidateIndices:d}=await this._getSymbologyCandidates(o,s);n(s);if(i!==this._cacheVersion)return this.fetch(e,s);const f=[],{length:g}=h;for(let n=0;n<g;++n){const e=h[n],s=a(o[d[n]]),c=r.get(s);c.push(e),r.put(s,c,c.length),f.push(t(e))}return c.concat(f)}notifySymbologyChange(){this._candidatesCache.clear(),this._cacheVersion++}}function a(t){switch(t.type){case"vertex":{const{objectId:e,target:n}=t,o=`${e}-vertex-${n.x}-${n.y}-${n.z??0}`;return s(o).toString()}case"edge":{const{objectId:e,start:n,end:o}=t,c=`${e}-edge-${n.x}-${n.y}-${n.z??0}-to-${o.x}-${o.y}-${o.z??0}`;return s(c).toString()}default:return""}}export{o as getSymbologySnappingCandidatesFetcher};
@@ -1,7 +1,7 @@
1
1
  import type MediaLayer from "../../layers/MediaLayer.js";
2
2
  import type MediaLayerInteractionOptions from "../3d/layers/support/MediaLayerInteractionOptions.js";
3
3
  import type { ResourceHandle } from "../../core/Handles.js";
4
- import type { MediaElement } from "../../layers/support/media.js";
4
+ import type { MediaElement } from "../../layers/media/types.js";
5
5
  import type { LayerViewHighlightOptions } from "./types.js";
6
6
  import type { MediaLayerInteractionOptionsProperties } from "../3d/layers/support/MediaLayerInteractionOptions.js";
7
7
 
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{neverReached as t}from"../../core/compilerUtils.js";import e from"../../core/Error.js";import s from"../../core/Logger.js";import{isAborted as r,createAbortError as o,isPromiseLike as a,isAbortError as n}from"../../core/promiseUtils.js";import{signal as i}from"../../core/signal.js";import{Yield as c}from"./Yield.js";class l{constructor(){this._tasks=new Array,this._numPendingTasks=i(0),this._readyToRun=i(!1)}get length(){return this._tasks.length}get updating(){return this._numPendingTasks.value>0}get readyToRun(){return this._readyToRun.value}_updateReadyToRun(){this._readyToRun.value=this._tasks.length>0}destroy(){this.cancelAll()}runTask(t){if(0===this.length)return c;for(;!t.done&&this._process(t);)t.madeProgress()}push(t,e,s){return this._addTask((r,o)=>new d(r,o,t,e,s),Array.prototype.push)}unshift(t,e,s){return this._addTask((r,o)=>new d(r,o,t,e,s),Array.prototype.unshift)}pushGenerator(t,e,s){return this._addTask((r,o)=>new _(r,o,t,e,s),Array.prototype.push)}_process(e){if(0===this._tasks.length)return!1;const s=this._tasks.shift();this._updateReadyToRun();try{if(r(s.signal))this._cancelTask(s,o());else switch(s.type){case 0:this._processSimple(s,e);break;case 1:this._processGenerator(s,e);break;case 2:this._processIterator(s,e);break;default:t(s)}}catch(a){s.reject(a)}return!0}cancelAll(){const t=o();for(const e of this._tasks)this._cancelTask(e,t);this._tasks.length=0,this._updateReadyToRun()}_cancelTask(t,e){if(t.abortCallback){const s=t.abortCallback(e);2===t.type&&t.iterator.return&&h(t.iterator.return()),a(s)?s.then(t.resolve,t.reject):t.resolve(s)}else 2===t.type&&t.iterator.throw&&h(t.iterator.throw(e)),t.reject(e)}_onIteratorResult(t,e){e.done?t.resolve(e.value):(this._tasks.unshift(t),this._updateReadyToRun())}_processSimple(t,e){const s=t.callback(e);a(s)?s.then(t.resolve,t.reject):t.resolve(s)}_processGenerator(t,e){const s=t.generatorFunction(e),r=new k(t.resolve,t.reject,s,t.signal,t.abortCallback);this._processIterator(r,e)}_processIterator(t,e){const s=t.iterator.next(e);a(s)?s.then(e=>this._onIteratorResult(t,e),t.reject):this._onIteratorResult(t,s)}_addTask(t,e){return new Promise((s,r)=>{const o=t(s,r);e.call(this._tasks,o),++this._numPendingTasks.value,this._updateReadyToRun()}).finally(()=>--this._numPendingTasks.value)}}function h(t){a(t)?t.then(u,u):u(t)}function u(t){n(t)||t instanceof Error||t instanceof e||null!=t&&"object"==typeof t&&"done"in t&&t.done||s.getLogger("esri.layers.support.PromiseQueue").warn("Generator iterator was aborted, but it is not done.")}class p{constructor(t,e,s,r){this.resolve=t,this.reject=e,this.signal=s,this.abortCallback=r}}class d extends p{constructor(t,e,s,r,o){super(t,e,r,o),this.callback=s,this.type=0}}class _ extends p{constructor(t,e,s,r,o){super(t,e,r,o),this.generatorFunction=s,this.type=1}}class k extends p{constructor(t,e,s,r,o){super(t,e,r,o),this.iterator=s,this.type=2}}export{l as PromiseQueue};
5
+ import t from"../../core/Error.js";import e from"../../core/Logger.js";import{isAborted as s,createAbortError as r,isPromiseLike as o,isAbortError as a}from"../../core/promiseUtils.js";import{signal as n}from"../../core/signal.js";import{Yield as i}from"./Yield.js";class c{constructor(){this._tasks=new Array,this._numPendingTasks=n(0),this._readyToRun=n(!1)}get length(){return this._tasks.length}get updating(){return this._numPendingTasks.value>0}get readyToRun(){return this._readyToRun.value}_updateReadyToRun(){this._readyToRun.value=this._tasks.length>0}destroy(){this.cancelAll()}runTask(t){if(0===this.length)return i;for(;!t.done&&this._process(t);)t.madeProgress()}push(t,e,s){return this._addTask((r,o)=>new p(r,o,t,e,s),Array.prototype.push)}unshift(t,e,s){return this._addTask((r,o)=>new p(r,o,t,e,s),Array.prototype.unshift)}pushGenerator(t,e,s){return this._addTask((r,o)=>new _(r,o,t,e,s),Array.prototype.push)}_process(t){if(0===this._tasks.length)return!1;const e=this._tasks.shift();this._updateReadyToRun();try{if(s(e.signal))this._cancelTask(e,r());else switch(e.type){case 0:this._processSimple(e,t);break;case 1:this._processGenerator(e,t);break;case 2:this._processIterator(e,t)}}catch(o){e.reject(o)}return!0}cancelAll(){const t=r();for(const e of this._tasks)this._cancelTask(e,t);this._tasks.length=0,this._updateReadyToRun()}_cancelTask(t,e){if(t.abortCallback){const s=t.abortCallback(e);2===t.type&&t.iterator.return&&h(t.iterator.return()),o(s)?s.then(t.resolve,t.reject):t.resolve(s)}else 2===t.type&&t.iterator.throw&&h(t.iterator.throw(e)),t.reject(e)}_onIteratorResult(t,e){e.done?t.resolve(e.value):(this._tasks.unshift(t),this._updateReadyToRun())}_processSimple(t,e){const s=t.callback(e);o(s)?s.then(t.resolve,t.reject):t.resolve(s)}_processGenerator(t,e){const s=t.generatorFunction(e),r=new d(t.resolve,t.reject,s,t.signal,t.abortCallback);this._processIterator(r,e)}_processIterator(t,e){const s=t.iterator.next(e);o(s)?s.then(e=>this._onIteratorResult(t,e),t.reject):this._onIteratorResult(t,s)}_addTask(t,e){return new Promise((s,r)=>{const o=t(s,r);e.call(this._tasks,o),++this._numPendingTasks.value,this._updateReadyToRun()}).finally(()=>--this._numPendingTasks.value)}}function h(t){o(t)?t.then(l,l):l(t)}function l(s){a(s)||s instanceof Error||s instanceof t||null!=s&&"object"==typeof s&&"done"in s&&s.done||e.getLogger("esri.layers.support.PromiseQueue").warn("Generator iterator was aborted, but it is not done.")}class u{constructor(t,e,s,r){this.resolve=t,this.reject=e,this.signal=s,this.abortCallback=r}}class p extends u{constructor(t,e,s,r,o){super(t,e,r,o),this.callback=s,this.type=0}}class _ extends u{constructor(t,e,s,r,o){super(t,e,r,o),this.generatorFunction=s,this.type=1}}class d extends u{constructor(t,e,s,r,o){super(t,e,r,o),this.iterator=s,this.type=2}}export{c as PromiseQueue};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../core/has.js";import{createScreenPoint as e,createScreenPointArray as t}from"../../core/screenUtils.js";function n(t){return e(t.x,t.y)}function c(e){return t(e.x,e.y)}function i(t,n){const c=(t instanceof HTMLElement?t:t.surface)?.getBoundingClientRect();return c?e(n.clientX-c.left,n.clientY-c.top):e(0,0)}function r(e,t){return t instanceof Event?i(e,t):n(t)}function o(e){if(e instanceof Event)return!0;if("object"==typeof e&&"type"in e){switch(e.type){case"click":case"double-click":case"pointer-down":case"pointer-drag":case"pointer-enter":case"pointer-leave":case"pointer-up":case"pointer-move":case"immediate-click":case"immediate-double-click":case"hold":case"drag":case"mouse-wheel":return!0;default:return!1}}return!1}export{c as createScreenPointArrayFromEvent,n as createScreenPointFromEvent,i as createScreenPointFromNativeEvent,r as createScreenPointFromSupportedEvent,o as isSupportedScreenPointEvent};
5
+ import{createScreenPoint as e,createScreenPointArray as t}from"../../core/screenUtils.js";function n(t){return e(t.x,t.y)}function c(e){return t(e.x,e.y)}function i(t,n){const c=(t instanceof HTMLElement?t:t.surface)?.getBoundingClientRect();return c?e(n.clientX-c.left,n.clientY-c.top):e(0,0)}function r(e,t){return t instanceof Event?i(e,t):n(t)}function o(e){if(e instanceof Event)return!0;if("object"==typeof e&&"type"in e){switch(e.type){case"click":case"double-click":case"pointer-down":case"pointer-drag":case"pointer-enter":case"pointer-leave":case"pointer-up":case"pointer-move":case"immediate-click":case"immediate-double-click":case"hold":case"drag":case"mouse-wheel":return!0;default:return!1}}return!1}export{c as createScreenPointArrayFromEvent,n as createScreenPointFromEvent,i as createScreenPointFromNativeEvent,r as createScreenPointFromSupportedEvent,o as isSupportedScreenPointEvent};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../core/has.js";import{clamp as t}from"../../core/mathUtils.js";export{createEmptyImageData}from"../../core/imageUtils.js";const h=2048,i=1.5,e=8;function o(h,i){const{format:e,quality:o,rotation:n,disableDecorations:a}=h||{},r=b(h,i.padding),l=p(h,{width:i.width-r.left-r.right,height:i.height-r.top-r.bottom}),{width:g,height:f}=m(h,l),u=j(e),d=R[u];return{format:u,quality:t(null!=o?o:d,0,100),area:l,width:g,height:f,rotation:n,disableDecorations:!!a,ignoreBackground:!!h?.ignoreBackground,ignorePadding:!!h?.ignorePadding}}function n(t,h){const i=o(t,h),e=i.area,n=i.width/e.width,a=b(i,h.padding),r=a.left+a.right,l=a.top+a.bottom,g=h.width-r,f=h.height-l,u=Math.floor(g*n+r),d=Math.floor(f*n+l),c=t?.layers??[],s=i.ignoreBackground,w=i.ignorePadding;return{framebufferWidth:u,framebufferHeight:d,region:{x:Math.floor(e.x*n)+a.left,y:Math.floor(e.y*n)+a.top,width:i.width,height:i.height},format:i.format,quality:i.quality,rotation:i.rotation,pixelRatio:n,layers:c,disableDecorations:i.disableDecorations,ignoreBackground:s,ignorePadding:w,olidColor:!1}}function a(t,h,i){const{ctx:e,canvas:o}=l(t,i),n=e.getImageData(0,0,t.width,t.height),a=d(o,h);return g(o),{dataUrl:a,data:n}}function r(t,h){const{ctx:i,canvas:e}=l(t,h),o=i.getImageData(0,0,t.width,t.height);return g(e),o}function l(t,h){const i=f();h.premultipliedAlpha&&q(t),i.width=t.width,i.height=t.height;const e=i.getContext("2d",{willReadFrequently:!0});return e.putImageData(t,0,0),h.flipY&&D(e),{ctx:e,canvas:i}}function g(t){t.width=0,t.height=0}function f(){return null==u&&(u=document.createElement("canvas")),u}let u=null;function d(t,h){const i=v[h.format],e=h.quality/100;return t.toDataURL(i,e)}function c(h,i){const e=j(h),o=R[e];return{format:e,quality:t(null!=i?i:o,0,100)}}function s(t,h){return h/Math.max(t[0],t[1])}function w(t,h,i,e=0,o=0,n=t.width-e,a=t.height-o,r=!1){const{data:l}=t,{width:g,height:f,data:u}=h,d=n/g,c=a/f,s=Math.ceil(d/2),w=Math.ceil(c/2),M=t.width;for(let m=0;m<f;m++)for(let t=0;t<g;t++){const h=4*(t+(r?f-m-1:m)*g);let n=0,a=0,p=0,x=0,y=0,b=0;const j=(m+.5)*c;for(let r=Math.floor(m*c);r<(m+1)*c;r++){const h=Math.abs(j-(r+.5))/w,g=(t+.5)*d,f=h*h;for(let u=Math.floor(t*d);u<(t+1)*d;u++){const t=Math.abs(g-(u+.5))/s,h=Math.sqrt(f+t*t);if(h>=1)continue;let d=2*h*h*h-3*h*h+1;const c=4*(e+u+(o+r)*M);b+=d*l[c+3],a+=d,!i&&l[c+3]<255&&(d=d*l[c+3]/255),p+=d*l[c],x+=d*l[c+1],y+=d*l[c+2],n+=d}}u[h]=p/n,u[h+1]=x/n,u[h+2]=y/n,u[h+3]=b/a}return h}function M(t,o,n){if(!o)return t;const{framebufferWidth:a,framebufferHeight:r,pixelRatio:l,region:g}=t,f=b(t,n),u=f.left+f.right,d=f.top+f.bottom,c=a-u,s=r-d,w=Math.min(e,Math.min((h-u)/c,(h-d)/s));return w<i?t:{...t,framebufferWidth:Math.round(c*w)+u,framebufferHeight:Math.round(s*w)+d,pixelRatio:l*w,resample:{region:{x:Math.round((g.x-f.left)*w)+f.left,y:Math.round((g.y-f.top)*w)+f.top,width:Math.round(g.width*w),height:Math.round(g.height*w)},width:a,height:r}}}function m(t,h){if(!t)return h;const i=t.width,e=t.height;if(null!=i&&null!=e)return{width:Math.floor(i),height:Math.floor(e)};if(null==i&&null==e)return h;const o=h.width/h.height;return null==e?{width:Math.floor(i),height:Math.floor(i/o)}:{width:Math.floor(e*o),height:Math.floor(e)}}function p(t,h){const i={x:0,y:0,width:h.width,height:h.height};if(t?.area){null!=t.area.x&&(i.x=Math.floor(t.area.x)),null!=t.area.y&&(i.y=Math.floor(t.area.y));const e=null!=t.area.width?Math.floor(t.area.width):null,o=null!=t.area.height?Math.floor(t.area.height):null;if(i.width=h.width-i.x,i.height=h.height-i.y,null!=e&&null!=o)i.width=Math.min(i.width,e),i.height=Math.min(i.height,o);else if(null==e&&null!=o){const t=Math.min(i.width,e);i.height=t/i.width*i.height,i.width=t}else if(null!=e&&null==o){const t=Math.min(i.height,o);i.width=t/i.height*i.width,i.height=t}}return x(y(i,t),h)}function x(t,h){const i=Math.floor(Math.max(t.x,0)),e=Math.floor(Math.max(t.y,0)),o={x:i,y:e,width:Math.floor(Math.min(t.width,h.width-i)),height:Math.floor(Math.min(t.height,h.height-e))},n=o.width/o.height,a=t.width/t.height;if(a===n)return o;if(a>n){const t=Math.floor(o.width/a),h=o.height-t;return{x:o.x,y:Math.floor(o.y+h/2),width:o.width,height:t}}const r=Math.floor(o.height*a),l=o.width-r;return{x:Math.floor(o.x+l/2),y:o.y,width:r,height:o.height}}function y(t,h){if(null==h?.width||null==h.height)return t;const i=h.width/h.height,e=t.width/t.height;if(e===i)return t;if(e<i){const h=Math.floor(t.height*i);return t.x-=(h-t.width)/2,t.width=h,t}const o=Math.floor(t.width/i);return t.y-=(o-t.height)/2,t.height=o,t}function b(t,h){return!h||t?.ignorePadding?k:h}function j(t){switch(t){case"png":case"jpg":case"jpeg":return t;default:return P}}function D(t){t.save(),t.globalCompositeOperation="copy",t.scale(1,-1),t.translate(0,-t.canvas.height),t.drawImage(t.canvas,0,0),t.restore()}function q(t){const h=t.data,i=h.length;for(let e=0;e<i;e+=4){const t=h[e+3];if(255!==t&&t>0){const i=255/t;h[e]=h[e]*i,h[e+1]=h[e+1]*i,h[e+2]=h[e+2]*i}}}const v={png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg"},I=98,P="png",R={png:100,jpg:I,jpeg:I},k={top:0,right:0,bottom:0,left:0};export{o as completeUserSettings,a as encode,r as encodeData,c as getFormatAndQuality,s as getMaximumResolutionScale,w as resampleHermite,M as screenshotSuperSampleSettings,d as toDataUrl,n as toRenderSettings};
5
+ import{clamp as t}from"../../core/mathUtils.js";export{createEmptyImageData}from"../../core/imageUtils.js";const h=2048,i=1.5,e=8;function o(h,i){const{format:e,quality:o,rotation:n,disableDecorations:a}=h||{},r=b(h,i.padding),l=p(h,{width:i.width-r.left-r.right,height:i.height-r.top-r.bottom}),{width:g,height:f}=m(h,l),u=j(e),d=R[u];return{format:u,quality:t(null!=o?o:d,0,100),area:l,width:g,height:f,rotation:n,disableDecorations:!!a,ignoreBackground:!!h?.ignoreBackground,ignorePadding:!!h?.ignorePadding}}function n(t,h){const i=o(t,h),e=i.area,n=i.width/e.width,a=b(i,h.padding),r=a.left+a.right,l=a.top+a.bottom,g=h.width-r,f=h.height-l,u=Math.floor(g*n+r),d=Math.floor(f*n+l),c=t?.layers??[],s=i.ignoreBackground,w=i.ignorePadding;return{framebufferWidth:u,framebufferHeight:d,region:{x:Math.floor(e.x*n)+a.left,y:Math.floor(e.y*n)+a.top,width:i.width,height:i.height},format:i.format,quality:i.quality,rotation:i.rotation,pixelRatio:n,layers:c,disableDecorations:i.disableDecorations,ignoreBackground:s,ignorePadding:w,olidColor:!1}}function a(t,h,i){const{ctx:e,canvas:o}=l(t,i),n=e.getImageData(0,0,t.width,t.height),a=d(o,h);return g(o),{dataUrl:a,data:n}}function r(t,h){const{ctx:i,canvas:e}=l(t,h),o=i.getImageData(0,0,t.width,t.height);return g(e),o}function l(t,h){const i=f();h.premultipliedAlpha&&q(t),i.width=t.width,i.height=t.height;const e=i.getContext("2d",{willReadFrequently:!0});return e.putImageData(t,0,0),h.flipY&&D(e),{ctx:e,canvas:i}}function g(t){t.width=0,t.height=0}function f(){return null==u&&(u=document.createElement("canvas")),u}let u=null;function d(t,h){const i=v[h.format],e=h.quality/100;return t.toDataURL(i,e)}function c(h,i){const e=j(h),o=R[e];return{format:e,quality:t(null!=i?i:o,0,100)}}function s(t,h){return h/Math.max(t[0],t[1])}function w(t,h,i,e=0,o=0,n=t.width-e,a=t.height-o,r=!1){const{data:l}=t,{width:g,height:f,data:u}=h,d=n/g,c=a/f,s=Math.ceil(d/2),w=Math.ceil(c/2),M=t.width;for(let m=0;m<f;m++)for(let t=0;t<g;t++){const h=4*(t+(r?f-m-1:m)*g);let n=0,a=0,p=0,x=0,y=0,b=0;const j=(m+.5)*c;for(let r=Math.floor(m*c);r<(m+1)*c;r++){const h=Math.abs(j-(r+.5))/w,g=(t+.5)*d,f=h*h;for(let u=Math.floor(t*d);u<(t+1)*d;u++){const t=Math.abs(g-(u+.5))/s,h=Math.sqrt(f+t*t);if(h>=1)continue;let d=2*h*h*h-3*h*h+1;const c=4*(e+u+(o+r)*M);b+=d*l[c+3],a+=d,!i&&l[c+3]<255&&(d=d*l[c+3]/255),p+=d*l[c],x+=d*l[c+1],y+=d*l[c+2],n+=d}}u[h]=p/n,u[h+1]=x/n,u[h+2]=y/n,u[h+3]=b/a}return h}function M(t,o,n){if(!o)return t;const{framebufferWidth:a,framebufferHeight:r,pixelRatio:l,region:g}=t,f=b(t,n),u=f.left+f.right,d=f.top+f.bottom,c=a-u,s=r-d,w=Math.min(e,Math.min((h-u)/c,(h-d)/s));return w<i?t:{...t,framebufferWidth:Math.round(c*w)+u,framebufferHeight:Math.round(s*w)+d,pixelRatio:l*w,resample:{region:{x:Math.round((g.x-f.left)*w)+f.left,y:Math.round((g.y-f.top)*w)+f.top,width:Math.round(g.width*w),height:Math.round(g.height*w)},width:a,height:r}}}function m(t,h){if(!t)return h;const i=t.width,e=t.height;if(null!=i&&null!=e)return{width:Math.floor(i),height:Math.floor(e)};if(null==i&&null==e)return h;const o=h.width/h.height;return null==e?{width:Math.floor(i),height:Math.floor(i/o)}:{width:Math.floor(e*o),height:Math.floor(e)}}function p(t,h){const i={x:0,y:0,width:h.width,height:h.height};if(t?.area){null!=t.area.x&&(i.x=Math.floor(t.area.x)),null!=t.area.y&&(i.y=Math.floor(t.area.y));const e=null!=t.area.width?Math.floor(t.area.width):null,o=null!=t.area.height?Math.floor(t.area.height):null;if(i.width=h.width-i.x,i.height=h.height-i.y,null!=e&&null!=o)i.width=Math.min(i.width,e),i.height=Math.min(i.height,o);else if(null==e&&null!=o){const t=Math.min(i.width,e);i.height=t/i.width*i.height,i.width=t}else if(null!=e&&null==o){const t=Math.min(i.height,o);i.width=t/i.height*i.width,i.height=t}}return x(y(i,t),h)}function x(t,h){const i=Math.floor(Math.max(t.x,0)),e=Math.floor(Math.max(t.y,0)),o={x:i,y:e,width:Math.floor(Math.min(t.width,h.width-i)),height:Math.floor(Math.min(t.height,h.height-e))},n=o.width/o.height,a=t.width/t.height;if(a===n)return o;if(a>n){const t=Math.floor(o.width/a),h=o.height-t;return{x:o.x,y:Math.floor(o.y+h/2),width:o.width,height:t}}const r=Math.floor(o.height*a),l=o.width-r;return{x:Math.floor(o.x+l/2),y:o.y,width:r,height:o.height}}function y(t,h){if(null==h?.width||null==h.height)return t;const i=h.width/h.height,e=t.width/t.height;if(e===i)return t;if(e<i){const h=Math.floor(t.height*i);return t.x-=(h-t.width)/2,t.width=h,t}const o=Math.floor(t.width/i);return t.y-=(o-t.height)/2,t.height=o,t}function b(t,h){return!h||t?.ignorePadding?k:h}function j(t){switch(t){case"png":case"jpg":case"jpeg":return t;default:return P}}function D(t){t.save(),t.globalCompositeOperation="copy",t.scale(1,-1),t.translate(0,-t.canvas.height),t.drawImage(t.canvas,0,0),t.restore()}function q(t){const h=t.data,i=h.length;for(let e=0;e<i;e+=4){const t=h[e+3];if(255!==t&&t>0){const i=255/t;h[e]=h[e]*i,h[e+1]=h[e+1]*i,h[e+2]=h[e+2]*i}}}const v={png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg"},I=98,P="png",R={png:100,jpg:I,jpeg:I},k={top:0,right:0,bottom:0,left:0};export{o as completeUserSettings,a as encode,r as encodeData,c as getFormatAndQuality,s as getMaximumResolutionScale,w as resampleHermite,M as screenshotSuperSampleSettings,d as toDataUrl,n as toRenderSettings};
package/views/types.d.ts CHANGED
@@ -14,7 +14,7 @@ import type { ReadonlyArrayOrCollection } from "../core/Collection.js";
14
14
  import type { AbortOptions } from "../core/promiseUtils.js";
15
15
  import type { ScreenPoint } from "../core/types.js";
16
16
  import type { GeometryUnion } from "../geometry/types.js";
17
- import type { MediaElement } from "../layers/support/media.js";
17
+ import type { MediaElement } from "../layers/media/types.js";
18
18
  import type { NetworkFeature } from "../rest/support/types.js";
19
19
  import type { AnalysisViewUnion } from "./analysis/types.js";
20
20
  import type { EasingName } from "./animation/types.js";
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../core/has.js";import e from"../../core/Logger.js";import{disposeMaybe as t}from"../../core/maybe.js";import{BufferObject as r}from"./BufferObject.js";import{webglDebugEnabled as i}from"./checkWebGLError.js";import{ResourceType as s,ColorAttachment0 as n,PixelType as h,StencilAttachment as o,SizedDepthStencilFormat as c,DepthStencilAttachment as a,SizedDepthFormat as u,DepthAttachment as f}from"./enums.js";import{Renderbuffer as l}from"./Renderbuffer.js";import d from"./Texture.js";const _=()=>e.getLogger("esri.views.webgl.FramebufferObject");class m{constructor(e,t,r){if(this._context=e,this._glName=null,this._colorAttachments=new Map,this._depthStencilBuffer=null,this._depthStencilTexture=null,this._initialized=!1,e.instanceCounter.increment(s.FramebufferObject,this),null!=t){const r=E(e,t);null!=r&&(this._colorAttachments.set(n,r),p(r)?this._validateTextureDescriptor(r.descriptor):this._validateRenderbufferDescriptor(r.descriptor)),this._validateColorAttachmentPoint(n)}if(null!=r)if(x(r))this._depthStencilTexture=p(r)?r:new d(e,r),this._validateTextureDescriptor(this._depthStencilTexture.descriptor);else{const t=T(r)?r:new l(e,r);this._depthStencilBuffer=t,this._validateRenderbufferDescriptor(t.descriptor)}}dispose(){const{_colorAttachments:e,_glName:t}=this;if(0===e.size&&!this._depthStencilBuffer&&!this._depthStencilTexture&&!t)return;const{_context:r}=this,i=r.getBoundFramebufferObject();e.forEach((e,t)=>this.detachColorTexture(t)?.dispose()),this.detachDepthStencilBuffer()?.dispose(),this.detachDepthStencilTexture()?.dispose(),r.gl.deleteFramebuffer(t),this._glName=null,r.bindFramebuffer(i===this?null:i),r.instanceCounter.decrement(s.FramebufferObject,this)}get glName(){return this._glName}get colorTexture(){const e=this._colorAttachments.get(n);return p(e)?e:null}get depthStencil(){return this._depthStencilTexture||this._depthStencilBuffer}get depthStencilTexture(){return this._depthStencilTexture}get width(){const e=this._colorAttachments.get(n)??this._depthStencilTexture??this._depthStencilBuffer;return e?.descriptor?.width??0}get height(){const e=this._colorAttachments.get(n)??this._depthStencilTexture??this._depthStencilBuffer;return e?.descriptor?.height??0}get usedMemory(){return[...this._colorAttachments].reduce((e,[t,r])=>e+r.usedMemory,this.depthStencil?.usedMemory??0)}static{this._MAX_COLOR_ATTACHMENTS=-1}getColorTexture(e){const t=this._colorAttachments.get(e);return t&&p(t)?t:null}get colorAttachments(){return[...this._colorAttachments.keys()]}attachColorTexture(e,t=n){if(!e)return;this._validateColorAttachmentPoint(t);const{descriptor:r}=e;this._validateTextureDescriptor(r),this.detachColorTexture(t)?.dispose(),this._initialized&&(this._context.bindFramebuffer(this),this._framebufferTexture2D(e.glName,t)),this._colorAttachments.set(t,e)}detachColorTexture(e=n){const t=this._colorAttachments.get(e);if(!t)return;const r=p(t);return this._initialized&&this._context.temporaryBindFramebufferObject(this,()=>{if(r)this._framebufferTexture2D(null,e);else{const t=this._context.gl;t.framebufferRenderbuffer(t.FRAMEBUFFER,e,t.RENDERBUFFER,null)}}),this._colorAttachments.delete(e),r?t:void 0}setColorTextureTarget(e,t=n,r=0){const i=this._colorAttachments.get(t);i&&(35866===e?this._framebufferTextureLayer(i.glName,t,36160,0,r):this._framebufferTexture2D(i.glName,t,e,36160,0))}attachDepthStencil(e){if(e)switch(e.type){case 1:return this._attachDepthStencilTexture(e);case 2:return this._attachDepthStencilBuffer(e)}}_attachDepthStencilTexture(e){if(null==e)return;const{descriptor:t}=e,{pixelFormat:r,dataType:i}=t;34041===r||6402===r?34041!==r||i===h.UNSIGNED_INT_24_8?6402!==r||i===h.UNSIGNED_INT||i===h.UNSIGNED_SHORT?(this._validateTextureDescriptor(t),this._disposeDepthStencilAttachments(),this._initialized&&(this._context.bindFramebuffer(this),this._framebufferTexture2D(e.glName,A(r))),this._depthStencilTexture?.dispose(),this._depthStencilTexture=e):console.error("Depth texture must have data type of UNSIGNED_INT or UNSIGNED_SHORT!"):console.error("Depth/Stencil texture must have data type of UNSIGNED_INT_24_8!"):console.error("Depth/Stencil texture must have a pixel type of DEPTH_STENCIL!")}detachDepthStencilTexture(){const e=this._depthStencilTexture;return e&&this._initialized&&this._context.temporaryBindFramebufferObject(this,()=>{this._framebufferTexture2D(null,A(e.descriptor.pixelFormat))}),this._depthStencilTexture=null,e}_attachDepthStencilBuffer(e){if(null==e)return;const t=e.descriptor;if(this._validateRenderbufferDescriptor(t),this._disposeDepthStencilAttachments(),this._initialized){this._context.bindFramebuffer(this);const{gl:r}=this._context,i=this._getGLAttachmentPoint(t);r.framebufferRenderbuffer(36160,i,r.RENDERBUFFER,e.glName)}this._depthStencilBuffer=e}detachDepthStencilBuffer(){const e=this._depthStencilBuffer;if(e&&this._initialized){const{_context:t}=this,r=t.getBoundFramebufferObject();t.bindFramebuffer(this);const{gl:i}=t,s=this._getGLAttachmentPoint(e.descriptor);i.framebufferRenderbuffer(36160,s,i.RENDERBUFFER,null),t.bindFramebuffer(r)}return this._depthStencilBuffer=null,e}invalidateAttachments(e){const{_context:t}=this;t.temporaryBindFramebufferObject(this,()=>t.gl.invalidateFramebuffer(36160,e),!0)}copyToTexture(e,t,r,i,s,n,h){(e<0||t<0||s<0||n<0)&&console.error("Offsets cannot be negative!"),(r<=0||i<=0)&&console.error("Copy width and height must be greater than zero!");const o=h.descriptor;3553!==h.descriptor.target&&console.error("Texture target must be TEXTURE_2D!"),(null==o?.width||null==o?.height||e+r>this.width||t+i>this.height||s+r>o.width||n+i>o.height)&&console.error("Bad dimensions, the current input values will attempt to read or copy out of bounds!");const c=this._context,a=c.bindTexture(h,d.TEXTURE_UNIT_FOR_UPDATES);c.setActiveTexture(d.TEXTURE_UNIT_FOR_UPDATES),c.bindFramebuffer(this),c.gl.copyTexSubImage2D(3553,0,s,n,e,t,r,i),c.bindTexture(a,d.TEXTURE_UNIT_FOR_UPDATES)}readPixels(e,t,r,i,s,n,h){(r<=0||i<=0)&&console.error("Copy width and height must be greater than zero!"),h||console.error("Target memory is not initialized!"),this._context.bindFramebuffer(this),this._context.gl.readPixels(e,t,r,i,s,n,h)}async readPixelsAsync(e,t,i,s,n,h,o){const{gl:c}=this._context,a=r.createPixelPack(this._context,35041,o.byteLength);this._context.bindBuffer(a);const u=this._context.getBoundFramebufferObject();this._context.bindFramebuffer(this),c.readPixels(e,t,i,s,n,h,0),this._context.unbindBuffer(35051),this._context.bindFramebuffer(u),await a.getSubDataAsync(o),a.dispose()}resize(e,t){if(this.width===e&&this.height===t)return;const r={width:e,height:t};if(F(r,this._context.parameters.maxTextureSize),this._colorAttachments.forEach(e=>e.resize(r.width,r.height)),this._depthStencilTexture?.resize(r.width,r.height),this._initialized&&(F(r,this._context.parameters.maxRenderbufferSize),this._depthStencilBuffer?.resize(r.width,r.height),i())){const{gl:e}=this._context;e.checkFramebufferStatus(36160)!==e.FRAMEBUFFER_COMPLETE&&console.error("Framebuffer is incomplete!")}}initializeAndBind(e=36160){const{gl:t}=this._context;if(this._initialized)return void t.bindFramebuffer(e,this.glName);this._glName&&t.deleteFramebuffer(this._glName);const r=t.createFramebuffer();if(t.bindFramebuffer(e,r),this._colorAttachments.forEach((t,r)=>{if(p(t)){const i=D(t);35866===i?this._framebufferTextureLayer(t.glName,r,e,0,0):this._framebufferTexture2D(t.glName,r,i,e)}else if(T(t)){const i=this._context.gl;i.framebufferRenderbuffer(e,r,i.RENDERBUFFER,t.glName)}}),this._depthStencilBuffer){const r=this._getGLAttachmentPoint(this._depthStencilBuffer.descriptor);t.framebufferRenderbuffer(e,r,t.RENDERBUFFER,this._depthStencilBuffer.glName)}else if(this._depthStencilTexture){const t=A(this._depthStencilTexture.descriptor.pixelFormat);this._framebufferTexture2D(this._depthStencilTexture.glName,t,D(this._depthStencilTexture),e)}if(i()){t.checkFramebufferStatus(e)!==t.FRAMEBUFFER_COMPLETE&&console.error("Framebuffer is incomplete!")}this._glName=r,this._initialized=!0}_framebufferTexture2D(e,t=n,r=3553,i=36160,s=0){this._context.gl.framebufferTexture2D(i,t,r,e,s)}_framebufferTextureLayer(e,t=n,r=36160,i=0,s=0){this._context.gl.framebufferTextureLayer(r,t,e,i,s)}_disposeDepthStencilAttachments(){const e=this._context.gl;if(this._depthStencilBuffer){if(this._initialized){this._context.bindFramebuffer(this);const t=this._getGLAttachmentPoint(this._depthStencilBuffer.descriptor);e.framebufferRenderbuffer(36160,t,e.RENDERBUFFER,null)}this._depthStencilBuffer=t(this._depthStencilBuffer)}this._depthStencilTexture&&(this._initialized&&(this._context.bindFramebuffer(this),this._framebufferTexture2D(null,A(this._depthStencilTexture.descriptor.pixelFormat))),this._depthStencilTexture=t(this._depthStencilTexture))}_validateTextureDescriptor(e){3553!==e.target&&34067!==e.target&&35866!==e.target&&console.error("Texture type must be TEXTURE_2D, TEXTURE_2D_ARRAY or TEXTURE_CUBE_MAP!"),F(e,this._context.parameters.maxTextureSize),this._validateBufferDimensions(e)}_validateRenderbufferDescriptor(e){F(e,this._context.parameters.maxRenderbufferSize),this._validateBufferDimensions(e)}_validateBufferDimensions(e){e.width<=0&&(e.width=this.width),e.height<=0&&(e.height=this.height),this.width>0&&this.height>0&&(this.width===e.width&&this.height===e.height||console.error("Attachment size must match framebuffer size!"))}_getGLAttachmentPoint(e){switch(e.internalFormat){case u.DEPTH_COMPONENT16:case u.DEPTH_COMPONENT24:case u.DEPTH_COMPONENT32F:return f;case c.DEPTH24_STENCIL8:case c.DEPTH32F_STENCIL8:return a;case 36168:return o;default:return n}}_validateColorAttachmentPoint(t){if(-1===m._MAX_COLOR_ATTACHMENTS){const{gl:e}=this._context;m._MAX_COLOR_ATTACHMENTS=e.getParameter(e.MAX_COLOR_ATTACHMENTS)}const r=t-n;r+1>m._MAX_COLOR_ATTACHMENTS&&e.getLogger("esri.views.webgl.FrameBufferObject").error("esri.FrameBufferObject",`illegal attachment point for color attachment: ${r+1}. Implementation supports up to ${m._MAX_COLOR_ATTACHMENTS} color attachments`)}}function p(e){return 1===S(e)}function T(e){return 2===S(e)}function x(e){return p(e)||b(e)}function b(e){return 0===S(e)}function g(e){return 3===S(e)||null!=e&&"samples"in e}function S(e){return null!=e&&"type"in e?e.type:null}function E(e,t){return p(t)||T(t)?t:b(t)?new d(e,t):g(t)?new l(e,t):null}function F(e,t){const r=Math.max(e.width,e.height);if(r>t){_().warnOnce(`Resizing FBO attachment size ${e.width}x${e.height} to device limit ${t}`);const i=t/r;return e.width=Math.round(e.width*i),e.height=Math.round(e.height*i),!1}return!0}function D(e){return 34067===e.descriptor.target?34069:35866===e.descriptor.target?35866:3553}function A(e){return 6402===e?f:a}export{m as FramebufferObject,F as ensureAttachmentMaxSize};
5
+ import e from"../../core/Logger.js";import{disposeMaybe as t}from"../../core/maybe.js";import{BufferObject as r}from"./BufferObject.js";import{webglDebugEnabled as i}from"./checkWebGLError.js";import{ResourceType as s,ColorAttachment0 as n,PixelType as h,StencilAttachment as o,SizedDepthStencilFormat as c,DepthStencilAttachment as a,SizedDepthFormat as u,DepthAttachment as f}from"./enums.js";import{Renderbuffer as l}from"./Renderbuffer.js";import d from"./Texture.js";const _=()=>e.getLogger("esri.views.webgl.FramebufferObject");class m{constructor(e,t,r){if(this._context=e,this._glName=null,this._colorAttachments=new Map,this._depthStencilBuffer=null,this._depthStencilTexture=null,this._initialized=!1,e.instanceCounter.increment(s.FramebufferObject,this),null!=t){const r=E(e,t);null!=r&&(this._colorAttachments.set(n,r),p(r)?this._validateTextureDescriptor(r.descriptor):this._validateRenderbufferDescriptor(r.descriptor)),this._validateColorAttachmentPoint(n)}if(null!=r)if(x(r))this._depthStencilTexture=p(r)?r:new d(e,r),this._validateTextureDescriptor(this._depthStencilTexture.descriptor);else{const t=T(r)?r:new l(e,r);this._depthStencilBuffer=t,this._validateRenderbufferDescriptor(t.descriptor)}}dispose(){const{_colorAttachments:e,_glName:t}=this;if(0===e.size&&!this._depthStencilBuffer&&!this._depthStencilTexture&&!t)return;const{_context:r}=this,i=r.getBoundFramebufferObject();e.forEach((e,t)=>this.detachColorTexture(t)?.dispose()),this.detachDepthStencilBuffer()?.dispose(),this.detachDepthStencilTexture()?.dispose(),r.gl.deleteFramebuffer(t),this._glName=null,r.bindFramebuffer(i===this?null:i),r.instanceCounter.decrement(s.FramebufferObject,this)}get glName(){return this._glName}get colorTexture(){const e=this._colorAttachments.get(n);return p(e)?e:null}get depthStencil(){return this._depthStencilTexture||this._depthStencilBuffer}get depthStencilTexture(){return this._depthStencilTexture}get width(){const e=this._colorAttachments.get(n)??this._depthStencilTexture??this._depthStencilBuffer;return e?.descriptor?.width??0}get height(){const e=this._colorAttachments.get(n)??this._depthStencilTexture??this._depthStencilBuffer;return e?.descriptor?.height??0}get usedMemory(){return[...this._colorAttachments].reduce((e,[t,r])=>e+r.usedMemory,this.depthStencil?.usedMemory??0)}static{this._MAX_COLOR_ATTACHMENTS=-1}getColorTexture(e){const t=this._colorAttachments.get(e);return t&&p(t)?t:null}get colorAttachments(){return[...this._colorAttachments.keys()]}attachColorTexture(e,t=n){if(!e)return;this._validateColorAttachmentPoint(t);const{descriptor:r}=e;this._validateTextureDescriptor(r),this.detachColorTexture(t)?.dispose(),this._initialized&&(this._context.bindFramebuffer(this),this._framebufferTexture2D(e.glName,t)),this._colorAttachments.set(t,e)}detachColorTexture(e=n){const t=this._colorAttachments.get(e);if(!t)return;const r=p(t);return this._initialized&&this._context.temporaryBindFramebufferObject(this,()=>{if(r)this._framebufferTexture2D(null,e);else{const t=this._context.gl;t.framebufferRenderbuffer(t.FRAMEBUFFER,e,t.RENDERBUFFER,null)}}),this._colorAttachments.delete(e),r?t:void 0}setColorTextureTarget(e,t=n,r=0){const i=this._colorAttachments.get(t);i&&(35866===e?this._framebufferTextureLayer(i.glName,t,36160,0,r):this._framebufferTexture2D(i.glName,t,e,36160,0))}attachDepthStencil(e){if(e)switch(e.type){case 1:return this._attachDepthStencilTexture(e);case 2:return this._attachDepthStencilBuffer(e)}}_attachDepthStencilTexture(e){if(null==e)return;const{descriptor:t}=e,{pixelFormat:r,dataType:i}=t;34041===r||6402===r?34041!==r||i===h.UNSIGNED_INT_24_8?6402!==r||i===h.UNSIGNED_INT||i===h.UNSIGNED_SHORT?(this._validateTextureDescriptor(t),this._disposeDepthStencilAttachments(),this._initialized&&(this._context.bindFramebuffer(this),this._framebufferTexture2D(e.glName,A(r))),this._depthStencilTexture?.dispose(),this._depthStencilTexture=e):console.error("Depth texture must have data type of UNSIGNED_INT or UNSIGNED_SHORT!"):console.error("Depth/Stencil texture must have data type of UNSIGNED_INT_24_8!"):console.error("Depth/Stencil texture must have a pixel type of DEPTH_STENCIL!")}detachDepthStencilTexture(){const e=this._depthStencilTexture;return e&&this._initialized&&this._context.temporaryBindFramebufferObject(this,()=>{this._framebufferTexture2D(null,A(e.descriptor.pixelFormat))}),this._depthStencilTexture=null,e}_attachDepthStencilBuffer(e){if(null==e)return;const t=e.descriptor;if(this._validateRenderbufferDescriptor(t),this._disposeDepthStencilAttachments(),this._initialized){this._context.bindFramebuffer(this);const{gl:r}=this._context,i=this._getGLAttachmentPoint(t);r.framebufferRenderbuffer(36160,i,r.RENDERBUFFER,e.glName)}this._depthStencilBuffer=e}detachDepthStencilBuffer(){const e=this._depthStencilBuffer;if(e&&this._initialized){const{_context:t}=this,r=t.getBoundFramebufferObject();t.bindFramebuffer(this);const{gl:i}=t,s=this._getGLAttachmentPoint(e.descriptor);i.framebufferRenderbuffer(36160,s,i.RENDERBUFFER,null),t.bindFramebuffer(r)}return this._depthStencilBuffer=null,e}invalidateAttachments(e){const{_context:t}=this;t.temporaryBindFramebufferObject(this,()=>t.gl.invalidateFramebuffer(36160,e),!0)}copyToTexture(e,t,r,i,s,n,h){(e<0||t<0||s<0||n<0)&&console.error("Offsets cannot be negative!"),(r<=0||i<=0)&&console.error("Copy width and height must be greater than zero!");const o=h.descriptor;3553!==h.descriptor.target&&console.error("Texture target must be TEXTURE_2D!"),(null==o?.width||null==o?.height||e+r>this.width||t+i>this.height||s+r>o.width||n+i>o.height)&&console.error("Bad dimensions, the current input values will attempt to read or copy out of bounds!");const c=this._context,a=c.bindTexture(h,d.TEXTURE_UNIT_FOR_UPDATES);c.setActiveTexture(d.TEXTURE_UNIT_FOR_UPDATES),c.bindFramebuffer(this),c.gl.copyTexSubImage2D(3553,0,s,n,e,t,r,i),c.bindTexture(a,d.TEXTURE_UNIT_FOR_UPDATES)}readPixels(e,t,r,i,s,n,h){(r<=0||i<=0)&&console.error("Copy width and height must be greater than zero!"),h||console.error("Target memory is not initialized!"),this._context.bindFramebuffer(this),this._context.gl.readPixels(e,t,r,i,s,n,h)}async readPixelsAsync(e,t,i,s,n,h,o){const{gl:c}=this._context,a=r.createPixelPack(this._context,35041,o.byteLength);this._context.bindBuffer(a);const u=this._context.getBoundFramebufferObject();this._context.bindFramebuffer(this),c.readPixels(e,t,i,s,n,h,0),this._context.unbindBuffer(35051),this._context.bindFramebuffer(u),await a.getSubDataAsync(o),a.dispose()}resize(e,t){if(this.width===e&&this.height===t)return;const r={width:e,height:t};if(F(r,this._context.parameters.maxTextureSize),this._colorAttachments.forEach(e=>e.resize(r.width,r.height)),this._depthStencilTexture?.resize(r.width,r.height),this._initialized&&(F(r,this._context.parameters.maxRenderbufferSize),this._depthStencilBuffer?.resize(r.width,r.height),i())){const{gl:e}=this._context;e.checkFramebufferStatus(36160)!==e.FRAMEBUFFER_COMPLETE&&console.error("Framebuffer is incomplete!")}}initializeAndBind(e=36160){const{gl:t}=this._context;if(this._initialized)return void t.bindFramebuffer(e,this.glName);this._glName&&t.deleteFramebuffer(this._glName);const r=t.createFramebuffer();if(t.bindFramebuffer(e,r),this._colorAttachments.forEach((t,r)=>{if(p(t)){const i=D(t);35866===i?this._framebufferTextureLayer(t.glName,r,e,0,0):this._framebufferTexture2D(t.glName,r,i,e)}else if(T(t)){const i=this._context.gl;i.framebufferRenderbuffer(e,r,i.RENDERBUFFER,t.glName)}}),this._depthStencilBuffer){const r=this._getGLAttachmentPoint(this._depthStencilBuffer.descriptor);t.framebufferRenderbuffer(e,r,t.RENDERBUFFER,this._depthStencilBuffer.glName)}else if(this._depthStencilTexture){const t=A(this._depthStencilTexture.descriptor.pixelFormat);this._framebufferTexture2D(this._depthStencilTexture.glName,t,D(this._depthStencilTexture),e)}if(i()){t.checkFramebufferStatus(e)!==t.FRAMEBUFFER_COMPLETE&&console.error("Framebuffer is incomplete!")}this._glName=r,this._initialized=!0}_framebufferTexture2D(e,t=n,r=3553,i=36160,s=0){this._context.gl.framebufferTexture2D(i,t,r,e,s)}_framebufferTextureLayer(e,t=n,r=36160,i=0,s=0){this._context.gl.framebufferTextureLayer(r,t,e,i,s)}_disposeDepthStencilAttachments(){const e=this._context.gl;if(this._depthStencilBuffer){if(this._initialized){this._context.bindFramebuffer(this);const t=this._getGLAttachmentPoint(this._depthStencilBuffer.descriptor);e.framebufferRenderbuffer(36160,t,e.RENDERBUFFER,null)}this._depthStencilBuffer=t(this._depthStencilBuffer)}this._depthStencilTexture&&(this._initialized&&(this._context.bindFramebuffer(this),this._framebufferTexture2D(null,A(this._depthStencilTexture.descriptor.pixelFormat))),this._depthStencilTexture=t(this._depthStencilTexture))}_validateTextureDescriptor(e){3553!==e.target&&34067!==e.target&&35866!==e.target&&console.error("Texture type must be TEXTURE_2D, TEXTURE_2D_ARRAY or TEXTURE_CUBE_MAP!"),F(e,this._context.parameters.maxTextureSize),this._validateBufferDimensions(e)}_validateRenderbufferDescriptor(e){F(e,this._context.parameters.maxRenderbufferSize),this._validateBufferDimensions(e)}_validateBufferDimensions(e){e.width<=0&&(e.width=this.width),e.height<=0&&(e.height=this.height),this.width>0&&this.height>0&&(this.width===e.width&&this.height===e.height||console.error("Attachment size must match framebuffer size!"))}_getGLAttachmentPoint(e){switch(e.internalFormat){case u.DEPTH_COMPONENT16:case u.DEPTH_COMPONENT24:case u.DEPTH_COMPONENT32F:return f;case c.DEPTH24_STENCIL8:case c.DEPTH32F_STENCIL8:return a;case 36168:return o;default:return n}}_validateColorAttachmentPoint(t){if(-1===m._MAX_COLOR_ATTACHMENTS){const{gl:e}=this._context;m._MAX_COLOR_ATTACHMENTS=e.getParameter(e.MAX_COLOR_ATTACHMENTS)}const r=t-n;r+1>m._MAX_COLOR_ATTACHMENTS&&e.getLogger("esri.views.webgl.FrameBufferObject").error("esri.FrameBufferObject",`illegal attachment point for color attachment: ${r+1}. Implementation supports up to ${m._MAX_COLOR_ATTACHMENTS} color attachments`)}}function p(e){return 1===S(e)}function T(e){return 2===S(e)}function x(e){return p(e)||b(e)}function b(e){return 0===S(e)}function g(e){return 3===S(e)||null!=e&&"samples"in e}function S(e){return null!=e&&"type"in e?e.type:null}function E(e,t){return p(t)||T(t)?t:b(t)?new d(e,t):g(t)?new l(e,t):null}function F(e,t){const r=Math.max(e.width,e.height);if(r>t){_().warnOnce(`Resizing FBO attachment size ${e.width}x${e.height} to device limit ${t}`);const i=t/r;return e.width=Math.round(e.width*i),e.height=Math.round(e.height*i),!1}return!0}function D(e){return 34067===e.descriptor.target?34069:35866===e.descriptor.target?35866:3553}function A(e){return 6402===e?f:a}export{m as FramebufferObject,F as ensureAttachmentMaxSize};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../core/has.js";class i{constructor(i,s,e,a,t=null){if(this.name=i,this.type=s,this.arraySize=t,this.bind={0:null,1:null,2:null},a)switch(e){case void 0:break;case 0:this.bind[0]=a;break;case 1:this.bind[1]=a;break;case 2:this.bind[2]=a}}equals(i){return this.type===i.type&&this.name===i.name&&this.arraySize===i.arraySize}}export{i as Uniform};
5
+ class i{constructor(i,e,s,a,t=null){if(this.name=i,this.type=e,this.arraySize=t,this.bind={0:null,1:null,2:null},a)switch(s){case void 0:break;case 0:this.bind[0]=a;break;case 1:this.bind[1]=a;break;case 2:this.bind[2]=a}}equals(i){return this.type===i.type&&this.name===i.name&&this.arraySize===i.arraySize}}export{i as Uniform};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../core/has.js";import{webglDebugEnabled as e,getErrorMessage as s}from"./checkWebGLError.js";import{CompressedTextureFormat as c,SizedPixelFormat as a,SizedDepthStencilFormat as r,SizedDepthFormat as t,DataType as R}from"./enums.js";const n=new Set([R.BYTE,R.SHORT,R.INT,R.UNSIGNED_BYTE,R.UNSIGNED_SHORT,R.UNSIGNED_INT]);function i(c,a,r,t=0){const R=c.gl;c.bindBuffer(r);for(const i of r.layout){const r=a.get(i.name);if(null==r){console.warn(`There is no location for vertex attribute '${i.name}' defined.`);continue}const o=t*i.stride;if(i.count<=4)i.integer&&n.has(i.type)?R.vertexAttribIPointer(r,i.count,i.type,i.stride,i.offset+o):R.vertexAttribPointer(r,i.count,i.type,i.normalized,i.stride,i.offset+o),R.enableVertexAttribArray(r),i.divisor>0&&R.vertexAttribDivisor(r,i.divisor);else if(9===i.count)for(let e=0;e<3;e++)R.vertexAttribPointer(r+e,3,i.type,i.normalized,i.stride,i.offset+12*e+o),R.enableVertexAttribArray(r+e),i.divisor>0&&R.vertexAttribDivisor(r+e,i.divisor);else if(16===i.count)for(let e=0;e<4;e++)R.vertexAttribPointer(r+e,4,i.type,i.normalized,i.stride,i.offset+16*e+o),R.enableVertexAttribArray(r+e),i.divisor>0&&R.vertexAttribDivisor(r+e,i.divisor);else console.error("Unsupported vertex attribute element count: "+i.count);if(e()){const e=s(c.gl);e&&console.error(`Unable to bind vertex attribute "${i.name}" with baseInstanceOffset ${o}:`,e,i)}}}function o(e){switch(e){case 6406:case 6409:case 6403:case 36244:case 6402:case 34041:return 1;case 6410:case 33319:case 33320:return 2;case 6407:case 36248:return 3;case 6408:case 36249:return 4}return 0}function _(e){switch(e){case 6406:case 6409:case 6403:case 36244:case a.R8:case a.R8I:case a.R8UI:case a.R8_SNORM:case 36168:return 1;case 6410:case 33319:case 33320:case a.RGBA4:case a.R16F:case a.R16I:case a.R16UI:case a.RG8:case a.RG8I:case a.RG8UI:case a.RG8_SNORM:case a.RGB565:case a.RGB5_A1:case t.DEPTH_COMPONENT16:return 2;case 6407:case 36248:case a.RGB8:case a.RGB8I:case a.RGB8UI:case a.RGB8_SNORM:case a.SRGB8:case t.DEPTH_COMPONENT24:return 3;case 6408:case 36249:case a.RGBA8:case a.R32F:case a.R11F_G11F_B10F:case a.RG16F:case a.R32I:case a.R32UI:case a.RG16I:case a.RG16UI:case a.RGBA8I:case a.RGBA8UI:case a.RGBA8_SNORM:case a.SRGB8_ALPHA8:case a.RGB9_E5:case a.RGB10_A2UI:case a.RGB10_A2:case t.DEPTH_COMPONENT32F:case r.DEPTH24_STENCIL8:return 4;case r.DEPTH32F_STENCIL8:return 5;case a.RGB16F:case a.RGB16I:case a.RGB16UI:return 6;case a.RG32F:case a.RG32I:case a.RG32UI:case a.RGBA16F:case a.RGBA16I:case a.RGBA16UI:return 8;case a.RGB32F:case a.RGB32I:case a.RGB32UI:return 12;case a.RGBA32F:case a.RGBA32I:case a.RGBA32UI:return 16;case c.COMPRESSED_RGB_S3TC_DXT1_EXT:case c.COMPRESSED_RGBA_S3TC_DXT1_EXT:return.5;case c.COMPRESSED_RGBA_S3TC_DXT3_EXT:case c.COMPRESSED_RGBA_S3TC_DXT5_EXT:return 1;case c.COMPRESSED_R11_EAC:case c.COMPRESSED_SIGNED_R11_EAC:case c.COMPRESSED_RGB8_ETC2:case c.COMPRESSED_SRGB8_ETC2:case c.COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2:case c.COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2:return.5;case c.COMPRESSED_RG11_EAC:case c.COMPRESSED_SIGNED_RG11_EAC:case c.COMPRESSED_RGBA8_ETC2_EAC:case c.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC:return 1}return 0}export{i as bindVertexBufferLayout,_ as getFormatBytesPerElement,o as getFormatComponents};
5
+ import{webglDebugEnabled as e,getErrorMessage as s}from"./checkWebGLError.js";import{CompressedTextureFormat as c,SizedPixelFormat as a,SizedDepthStencilFormat as r,SizedDepthFormat as t,DataType as R}from"./enums.js";const n=new Set([R.BYTE,R.SHORT,R.INT,R.UNSIGNED_BYTE,R.UNSIGNED_SHORT,R.UNSIGNED_INT]);function _(c,a,r,t=0){const R=c.gl;c.bindBuffer(r);for(const _ of r.layout){const r=a.get(_.name);if(null==r){console.warn(`There is no location for vertex attribute '${_.name}' defined.`);continue}const i=t*_.stride;if(_.count<=4)_.integer&&n.has(_.type)?R.vertexAttribIPointer(r,_.count,_.type,_.stride,_.offset+i):R.vertexAttribPointer(r,_.count,_.type,_.normalized,_.stride,_.offset+i),R.enableVertexAttribArray(r),_.divisor>0&&R.vertexAttribDivisor(r,_.divisor);else if(9===_.count)for(let e=0;e<3;e++)R.vertexAttribPointer(r+e,3,_.type,_.normalized,_.stride,_.offset+12*e+i),R.enableVertexAttribArray(r+e),_.divisor>0&&R.vertexAttribDivisor(r+e,_.divisor);else if(16===_.count)for(let e=0;e<4;e++)R.vertexAttribPointer(r+e,4,_.type,_.normalized,_.stride,_.offset+16*e+i),R.enableVertexAttribArray(r+e),_.divisor>0&&R.vertexAttribDivisor(r+e,_.divisor);else console.error("Unsupported vertex attribute element count: "+_.count);if(e()){const e=s(c.gl);e&&console.error(`Unable to bind vertex attribute "${_.name}" with baseInstanceOffset ${i}:`,e,_)}}}function i(e){switch(e){case 6406:case 6409:case 6403:case 36244:case 6402:case 34041:return 1;case 6410:case 33319:case 33320:return 2;case 6407:case 36248:return 3;case 6408:case 36249:return 4}return 0}function E(e){switch(e){case 6406:case 6409:case 6403:case 36244:case a.R8:case a.R8I:case a.R8UI:case a.R8_SNORM:case 36168:return 1;case 6410:case 33319:case 33320:case a.RGBA4:case a.R16F:case a.R16I:case a.R16UI:case a.RG8:case a.RG8I:case a.RG8UI:case a.RG8_SNORM:case a.RGB565:case a.RGB5_A1:case t.DEPTH_COMPONENT16:return 2;case 6407:case 36248:case a.RGB8:case a.RGB8I:case a.RGB8UI:case a.RGB8_SNORM:case a.SRGB8:case t.DEPTH_COMPONENT24:return 3;case 6408:case 36249:case a.RGBA8:case a.R32F:case a.R11F_G11F_B10F:case a.RG16F:case a.R32I:case a.R32UI:case a.RG16I:case a.RG16UI:case a.RGBA8I:case a.RGBA8UI:case a.RGBA8_SNORM:case a.SRGB8_ALPHA8:case a.RGB9_E5:case a.RGB10_A2UI:case a.RGB10_A2:case t.DEPTH_COMPONENT32F:case r.DEPTH24_STENCIL8:return 4;case r.DEPTH32F_STENCIL8:return 5;case a.RGB16F:case a.RGB16I:case a.RGB16UI:return 6;case a.RG32F:case a.RG32I:case a.RG32UI:case a.RGBA16F:case a.RGBA16I:case a.RGBA16UI:return 8;case a.RGB32F:case a.RGB32I:case a.RGB32UI:return 12;case a.RGBA32F:case a.RGBA32I:case a.RGBA32UI:return 16;case c.COMPRESSED_RGB_S3TC_DXT1_EXT:case c.COMPRESSED_RGBA_S3TC_DXT1_EXT:return.5;case c.COMPRESSED_RGBA_S3TC_DXT3_EXT:case c.COMPRESSED_RGBA_S3TC_DXT5_EXT:return 1;case c.COMPRESSED_R11_EAC:case c.COMPRESSED_SIGNED_R11_EAC:case c.COMPRESSED_RGB8_ETC2:case c.COMPRESSED_SRGB8_ETC2:case c.COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2:case c.COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2:return.5;case c.COMPRESSED_RG11_EAC:case c.COMPRESSED_SIGNED_RG11_EAC:case c.COMPRESSED_RGBA8_ETC2_EAC:case c.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC:return 1}return 0}export{_ as bindVertexBufferLayout,E as getFormatBytesPerElement,i as getFormatComponents};
@@ -1,5 +1,5 @@
1
1
  import type { JSONSupport, JSONSupportMixinProperties } from "../../core/JSONSupport.js";
2
- import type { Type as FieldType } from "../../layers/support/fieldType.js";
2
+ import type { FieldType } from "../../layers/support/types.js";
3
3
 
4
4
  export interface SearchLayerFieldProperties extends JSONSupportMixinProperties, Partial<Pick<SearchLayerField, "exactMatch" | "name" | "type">> {}
5
5
 
@@ -1,5 +1,5 @@
1
1
  import type { JSONSupport, JSONSupportMixinProperties } from "../../core/JSONSupport.js";
2
- import type { Type as FieldType } from "../../layers/support/fieldType.js";
2
+ import type { FieldType } from "../../layers/support/types.js";
3
3
 
4
4
  export interface SearchTableFieldProperties extends JSONSupportMixinProperties, Partial<Pick<SearchTableField, "exactMatch" | "name" | "type">> {}
5
5
 
@@ -106,7 +106,7 @@ export type SlideLayout = "caption" | "cover" | "none";
106
106
  export interface SlideEvents {
107
107
  /**
108
108
  * Emitted just after applying the slide was interrupted. In this case the
109
- * {@link webscene/Slide#apply-side-complete} event is not emitted.
109
+ * [apply-slide-complete](https://developers.arcgis.com/javascript/latest/api-reference/esri-webscene-Slide.html#event-apply-slide-complete) event is not emitted.
110
110
  *
111
111
  * @see [applyTo()](https://developers.arcgis.com/javascript/latest/api-reference/esri-webscene-Slide.html#applyTo)
112
112
  * @since 5.0
@@ -114,7 +114,7 @@ export interface SlideEvents {
114
114
  "apply-slide-cancel": void;
115
115
  /**
116
116
  * Emitted just after applying the slide has successfully completed. If applying the slide is interrupted then the
117
- * {@link webscene/Slide#apply-side-cancel} event is emitted instead.
117
+ * [apply-slide-cancel](https://developers.arcgis.com/javascript/latest/api-reference/esri-webscene-Slide.html#event-apply-slide-cancel) event is emitted instead.
118
118
  *
119
119
  * @see [applyTo()](https://developers.arcgis.com/javascript/latest/api-reference/esri-webscene-Slide.html#applyTo)
120
120
  * @since 5.0